diff --git a/software/dashboard/grafana/csv/Node-RED.html b/software/dashboard/grafana/csv/Node-RED.html new file mode 100644 index 0000000..74b7978 --- /dev/null +++ b/software/dashboard/grafana/csv/Node-RED.html @@ -0,0 +1,24404 @@ + + + + + + + + + +Node-RED + + + + + + + + +
/iot-platform/energy-monitor/test-device/wattVerbundenInflux watttoNumberconsumptiontele/tasmota_A4D1F3/SENSORVerbundenInflux plant sensordebug 1plant2Influxtele/tasmota_891E97/SENSORVerbundenInflux Shelly deviceshellyshelly2Influx
  • Node 'function' bearbeiten
+ + + + + + + + + + +
+ + + + + +
+
+
+
+
+
+ + + +
+
Subflows
Allgemein
inject
debug
complete
catch
status
link in
link call
link out
comment
Funktion
function
switch
change
range
template
delay
trigger
exec
filter
Netzwerk
mqtt in
mqtt out
http in
http response
http request
websocket in
websocket
out
tcp in
tcp out
tcp request
udp in
udp out
Eingabe
Ausgabe
Sequenz
split
join
sort
batch
Parser
csv
html
json
xml
yaml
Speicher
write file
read file
watch
influxdb in
influxdb out
influx batch
Analyse
Soziale Medien
Fortgeschritten
Dashboard
button
dropdown
switch
slider
numeric
text input
date picker
colour picker
form
text
gauge
chart
audio out
notification
ui control
template
  1. Flow
    1. MQTT2Influxdb
    2. CSV2Influxdb
    3. Debug Dashboard
  2. Subflow
  3. Globale Konfigurations-Nodes
shelly2Influx
Node"5e4f2b3e1acad45b"
Typfunction
Mehr anzeigenWeniger anzeigen
Modulnode-red
func
outputs1
noerr0
initialize""
finalize""
libs
Wenn Sie ein Node auf eine Verbindung ziehen, wird es in die Verbindung eingefügt
  1. Node-RED
  2. Node-Hilfe
    1. node-red
      1. batch
      2. catch
      3. change
      4. comment
      5. complete
      6. csv
      7. debug
      8. delay
      9. exec
      10. write file
      11. read file
      12. function
      13. html
      14. http in
      15. http proxy
      16. http request
      17. http response
      18. inject
      19. join
      20. json
      21. link in
      22. link out
      23. mqtt in
      24. mqtt out
      25. mqtt-broker
      26. range
      27. filter
      28. sort
      29. split
      30. status
      31. switch
      32. tcp in
      33. tcp out
      34. tcp request
      35. template
      36. tls-config
      37. trigger
      38. udp in
      39. udp out
      40. unknown
      41. watch
      42. websocket in
      43. websocket out
      44. websocket-client
      45. websocket-listener
      46. xml
      47. yaml
    2. node-red-contrib-influxdb
      1. influx batch
      2. influxdb in
      3. influxdb out
    3. node-red-dashboard

function

+

JavaScript-Funktion zur Weiterverarbeitung eingehender Nachrichten.

+

Die empfangenen Nachrichten werden der Funktion als JavaScript-Objekt mit dem Namen msg übergeben.

+

Per Konvention enthält die msg.payload-Eigenschaft die eigentliche Nachricht.

+

Von der Funktion wird erwartet, dass sie ein (oder mehrere) Nachrichtenobjekt(e) zurückgibt. + Es kann aber auch nichts zurückgeben werden, um einen Flow zu stoppen.

+

In den Start-Tab kann Code eingetragen werden, der beim Node-Start ausgeführt wird. + In den Stopp-Tab kann Code eingetragen werden, der beim Node-Stopp ausgeführt wird.

+

Wenn ein promise-Objekt aus dem Start-Code zurückgegeben wird, + beginnt danach die reguläre Verarbeitung der Eingangsnachrichten.

+

Details

+

Siehe Onlinedokumentation + für weitere Informationen zum Schreiben von Funktionen.

+

Nachrichten senden

+

Die Funktion kann die Nachrichten zurückgeben, die sie an die nächsten Nodes im Flow weitergeben möchte, + oder kann node.send(msg) aufrufen.

+

Es kann folgendes zurückgeben/senden werden:

+
    +
  • Ein einzelnes Nachrichtenobjekt, das an Nodes am ersten Ausgang übergeben wird
  • +
  • Ein Array von Nachrichtenobjekten, die an die Nodes an den entsprechenden Ausgängen übergeben werden
  • +
+

Hinweis: Der Start-Code wird nur während der Initialisierung des Nodes ausgeführt. + Wenn node.send im Start-Code aufgerufen wird, können nachfolgende Nodes die Nachricht möglicherweise nicht empfangen.

+

Wenn ein Element des Arrays selbst ein Array von Nachrichten ist, werden mehrere Nachrichten an den entsprechenden Ausgang gesendet.

+

Wenn null zurückgegeben wird, entweder direkt oder als ein Array-Element, wird keine Nachricht weitergegeben.

+

Protokollierung und Fehlerbehandlung

+

Um alle Informationen zu protokollieren oder einen Fehler zu melden, sind die folgenden Funktionen verfügbar:

+
    +
  • node.log("Protokollnachricht")
  • +
  • node.warn("Warnmeldungstext")
  • +
  • node.error("Fehlermeldungstext")
  • +
+

+

Der catch-Node kann auch zur Bearbeitung von Fehlern verwendet werden. + Er wird aufgerufen, indem msg als zweites Argument an node.error übergeben wird:

+
node.error("Fehlermeldungstext" ,msg);
+

Zugriff auf Node-Informationen

+

Im Funktionsblock können die ID und der Name des Nodes mit den folgenden Eigenschaften referenziert werden:

+
    +
  • node.id - ID des Nodes
  • +
  • node.name - Name des Nodes
  • +
+

Umgebungsvariablen verwenden

+

Auf Umgebungsvariablen kann mit env.get("Umgebungsvariablenname") zugegriffen werden.

+
Bei allen Flows
  • influxdb
  • [v1.x] test
    0
  • [v2.0] influx
  • mqtt-broker
  • mosquitto:1833
  • tls-config
  • TLS-Konfiguration
  • ui_base
  • Node-RED Dashboard
  • ui_group
  • [Powermonitor] Power
  • ui_tab
  • Powermonitor
MQTT2Influxdb
CSV2Influxdb
Debug Dashboard
Node
 
Zum Aktualisieren neu laden
Flow
 
Zum Aktualisieren neu laden
Global
 
Zum Aktualisieren neu laden
Lokale Änderungen
Lokale Dateien
    Nicht zusammengeführte (merge) Änderungen
      Änderungen für Commit
        Commit-Historie
          Alle Nodes/Flows all
          1. MQTT2Influxdb
          27/02/2023, 17:02:48node: shellymsg.payload : Object
          27/02/2023, 17:02:58node: shellymsg.payload : Object
          27/02/2023, 17:03:08node: shellymsg.payload : Object
          27/02/2023, 17:03:18node: shellymsg.payload : Object
          27/02/2023, 17:03:28node: shellymsg.payload : Object
          27/02/2023, 17:03:38node: shellymsg.payload : Object
          27/02/2023, 17:03:48node: shellymsg.payload : Object
          27/02/2023, 17:03:58node: shellymsg.payload : Object
          27/02/2023, 17:04:08node: shellymsg.payload : Object
          27/02/2023, 17:04:18node: shellymsg.payload : Object
          27/02/2023, 17:04:28node: shellymsg.payload : Object
          27/02/2023, 17:04:38node: shellymsg.payload : Object
          27/02/2023, 17:04:48node: shellymsg.payload : Object
          27/02/2023, 17:04:58node: shellymsg.payload : Object
          27/02/2023, 17:05:08node: shellymsg.payload : Object
          27/02/2023, 17:05:18node: shellymsg.payload : Object
          27/02/2023, 17:05:28node: shellymsg.payload : Object
          27/02/2023, 17:05:38node: shellymsg.payload : Object
          27/02/2023, 17:05:48node: shellymsg.payload : Object
          27/02/2023, 17:05:58node: shellymsg.payload : Object
          27/02/2023, 17:06:08node: shellymsg.payload : Object
          27/02/2023, 17:06:18node: shellymsg.payload : Object
          27/02/2023, 17:06:28node: shellymsg.payload : Object
          27/02/2023, 17:06:38node: shellymsg.payload : Object
          27/02/2023, 17:06:48node: shellymsg.payload : Object
          27/02/2023, 17:06:58node: shellymsg.payload : Object
          27/02/2023, 17:07:08node: shellymsg.payload : Object
          27/02/2023, 17:07:18node: shellymsg.payload : Object
          27/02/2023, 17:07:28node: shellymsg.payload : Object
          27/02/2023, 17:07:38node: shellymsg.payload : Object
          27/02/2023, 17:07:48node: shellymsg.payload : Object
          27/02/2023, 17:07:58node: shellymsg.payload : Object
          27/02/2023, 17:08:08node: shellymsg.payload : Object
          27/02/2023, 17:08:18node: shellymsg.payload : Object
          27/02/2023, 17:08:28node: shellymsg.payload : Object
          27/02/2023, 17:08:38node: shellymsg.payload : Object
          27/02/2023, 17:08:48node: shellymsg.payload : Object
          27/02/2023, 17:08:58node: shellymsg.payload : Object
          27/02/2023, 17:09:08node: shellymsg.payload : Object
          27/02/2023, 17:09:18node: shellymsg.payload : Object
          27/02/2023, 17:09:28node: shellymsg.payload : Object
          27/02/2023, 17:09:38node: shellymsg.payload : Object
          27/02/2023, 17:09:48node: shellymsg.payload : Object
          27/02/2023, 17:09:58node: shellymsg.payload : Object
          27/02/2023, 17:10:08node: shellymsg.payload : Object
          27/02/2023, 17:10:18node: shellymsg.payload : Object
          27/02/2023, 17:10:28node: shellymsg.payload : Object
          27/02/2023, 17:10:38node: shellymsg.payload : Object
          27/02/2023, 17:10:48node: shellymsg.payload : Object
          27/02/2023, 17:10:58node: shellymsg.payload : Object
          27/02/2023, 17:11:08node: shellymsg.payload : Object
          27/02/2023, 17:11:18node: shellymsg.payload : Object
          27/02/2023, 17:11:28node: shellymsg.payload : Object
          27/02/2023, 17:11:38node: shellymsg.payload : Object
          27/02/2023, 17:11:48node: shellymsg.payload : Object
          27/02/2023, 17:11:58node: shellymsg.payload : Object
          27/02/2023, 17:12:08node: shellymsg.payload : Object
          27/02/2023, 17:12:18node: shellymsg.payload : Object
          27/02/2023, 17:12:28node: shellymsg.payload : Object
          27/02/2023, 17:12:38node: shellymsg.payload : Object
          27/02/2023, 17:12:48node: shellymsg.payload : Object
          27/02/2023, 17:12:58node: shellymsg.payload : Object
          27/02/2023, 17:13:08node: shellymsg.payload : Object
          27/02/2023, 17:13:18node: shellymsg.payload : Object
          27/02/2023, 17:13:28node: shellymsg.payload : Object
          27/02/2023, 17:13:38node: shellymsg.payload : Object
          27/02/2023, 17:13:48node: shellymsg.payload : Object
          27/02/2023, 17:13:58node: shellymsg.payload : Object
          27/02/2023, 17:14:08node: shellymsg.payload : Object
          27/02/2023, 17:14:18node: shellymsg.payload : Object
          27/02/2023, 17:14:28node: shellymsg.payload : Object
          27/02/2023, 17:14:38node: shellymsg.payload : Object
          27/02/2023, 17:14:48node: shellymsg.payload : Object
          27/02/2023, 17:14:58node: shellymsg.payload : Object
          27/02/2023, 17:15:08node: shellymsg.payload : Object
          27/02/2023, 17:15:18node: shellymsg.payload : Object
          27/02/2023, 17:15:28node: shellymsg.payload : Object
          27/02/2023, 17:15:38node: shellymsg.payload : Object
          27/02/2023, 17:15:48node: shellymsg.payload : Object
          27/02/2023, 17:15:58node: shellymsg.payload : Object
          27/02/2023, 17:16:08node: shellymsg.payload : Object
          27/02/2023, 17:16:18node: shellymsg.payload : Object
          27/02/2023, 17:16:28node: shellymsg.payload : Object
          27/02/2023, 17:16:38node: shellymsg.payload : Object
          27/02/2023, 17:16:48node: shellymsg.payload : Object
          27/02/2023, 17:16:58node: shellymsg.payload : Object
          27/02/2023, 17:17:08node: shellymsg.payload : Object
          27/02/2023, 17:17:18node: shellymsg.payload : Object
          27/02/2023, 17:17:28node: shellymsg.payload : Object
          27/02/2023, 17:17:38node: shellymsg.payload : Object
          27/02/2023, 17:17:48node: shellymsg.payload : Object
          27/02/2023, 17:17:58node: shellymsg.payload : Object
          27/02/2023, 17:18:08node: shellymsg.payload : Object
          27/02/2023, 17:18:18node: shellymsg.payload : Object
          27/02/2023, 17:18:28node: shellymsg.payload : Object
          27/02/2023, 17:18:38node: shellymsg.payload : Object
          27/02/2023, 17:18:48node: shellymsg.payload : Object
          27/02/2023, 17:18:58node: shellymsg.payload : Object
          27/02/2023, 17:19:08node: shellymsg.payload : Object
          + + +
          + + + + + + + + + +
          + + + + + + + + + + +
          + + + + + + +
          + + + + + + + +
          + + + + + + + + +
          + + + + + + + + + + + + + +
          + + + + + + + + +
          + + + + + + + + +
          + + + + + + + +
          + + + + + + + + + +
          + + + + + + + + +
          + + + + + + + + +
          + + + + + + + + +
          + + + + + + + + +
          + + + + + + + + + +
          + + + + + + + + + +
          + + + + + + +
          + + + + + + + + + +
          + + + + + + + + + +
          + + + + + + + + + + + + + + + + + + +
          + + + + + + + + + + + + + +
          + + + + + + + + + +
          + + + + + + + + + + + + + + + + + + + + + + + + +
          + + + + + + + + + + + + + + + + + + + + + + + +
          + + + + + + + + + + + + + + + + + + +
          + + + + + + + + + +
          + + + + + + + + +
          + + + + + + + + +
          + + + + + + + + +
          + + + + + + + + +
          + + + + + + + + + + + + + + + + +
          + + + + + + + + + +
          + + + + + + + + + +
          + + + + + + + + + + + + +
          + + + + + + + + + +
          + + + + + + + + + + + + + + + + + + + + + + +
          + + + + + + + + + + + + + +
          + + + + + +
          + + + + + +
          + + + + + +
          + + + + + +
          + + + + + +
          + + + + + +
          + + + + + +
          + + + + + +
          + + + + +
          + + + + + + +
          + + + + + + +
          + + + + + + +
          + + + + + + + +
          + + + + + +
          + + + + + +
          + + + + + +
          + + + + + +
          + + + + + +
          + + + + + +
          + + + +

          Hier kann der Flow eingefügt werden
          ui controlshelly2Influx
          + + + + + + + + +
          \ No newline at end of file diff --git a/software/dashboard/grafana/csv/Node-RED_files/debug-utils.js b/software/dashboard/grafana/csv/Node-RED_files/debug-utils.js new file mode 100644 index 0000000..70dc336 --- /dev/null +++ b/software/dashboard/grafana/csv/Node-RED_files/debug-utils.js @@ -0,0 +1,733 @@ +/** + * Copyright JS Foundation and other contributors, http://js.foundation + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + **/ + +if (!RED) { + var RED = {} +} +RED.debug = (function() { + var config; + var messageList; + var messageTable; + var filterType = "filterAll"; + var filteredNodes = {}; // id->true means hide, so default to all visible + + var view = 'list'; + var messages = []; + var messagesByNode = {}; + var sbc; + var activeWorkspace; + var numMessages = 100; // Hardcoded number of message to show in debug window scrollback + + var debugNodeTreeList; + + function init(_config) { + config = _config; + + var content = $("
          ").css({"position":"relative","height":"100%"}); + var toolbar = $('
          '+ + ''+ + ' '+ + ''+ + ''+ + ' all' + + ''+ + '
          ').appendTo(content); + + var footerToolbar = $('
          '+ + ' ' + + '
          '); + + messageList = $('
          ').appendTo(content); + sbc = messageList[0]; + messageTable = $('
          ').appendTo(content); + + var filterDialogCloseTimeout; + var filterDialogShown = false; + var filterDialog = $('
          ').appendTo(toolbar);//content); + filterDialog.on('mouseleave' ,function(evt) { + if (filterDialogShown) { + filterDialogCloseTimeout = setTimeout(function() { + filterDialog.slideUp(200); + filterDialogShown = false; + },500) + } + }) + filterDialog.on('mouseenter' ,function(evt) { + clearTimeout(filterDialogCloseTimeout) + }) + var filterToolbar = $('
          '+ + ''+ + '' + + '' + + ''+ + ''+ + '
          ').appendTo(filterDialog); + + filterToolbar.find("#red-ui-sidebar-filter-select-close").on('click', function(evt) { + clearTimeout(filterDialogCloseTimeout) + filterDialogShown = false; + filterDialog.slideUp(200); + }) + + filterToolbar.find("#red-ui-sidebar-filter-select-all").on('click', function(evt) { + evt.preventDefault(); + var data = debugNodeTreeList.treeList('data'); + data.forEach(function(flow) { + if (!flow.selected) { + if (flow.treeList.checkbox) { + flow.treeList.checkbox.trigger('click') + } + } else { + flow.children.forEach(function(item) { + if (!item.selected) { + item.treeList.select(); + } + }) + } + }); + refreshMessageList(); + }) + + filterToolbar.find("#red-ui-sidebar-filter-select-none").on('click', function(evt) { + evt.preventDefault(); + debugNodeTreeList.treeList('clearSelection'); + var data = debugNodeTreeList.treeList('data'); + data.forEach(function(flow) { + if (flow.children) { + flow.children.forEach(function(item) { + filteredNodes[item.node.id] = true; + }) + } + }); + RED.settings.set('debug.filteredNodes',Object.keys(filteredNodes)) + refreshMessageList(); + }) + var debugNodeListRow = $('
          ').appendTo(filterDialog); + debugNodeTreeList = $("
          ").appendTo(debugNodeListRow).css({width: "100%", height: "300px"}) + .treeList({autoSelect: false}).on("treelistitemmouseover", function(e, item) { + if (item.node) { + item.node.highlighted = true; + item.node.dirty = true; + RED.view.redraw(); + } + }).on("treelistitemmouseout", function(e, item) { + if (item.node) { + item.node.highlighted = false; + item.node.dirty = true; + RED.view.redraw(); + } + }).on("treelistselect", function(e, item) { + if (item.children) { + item.children.forEach(function(child) { + if (child.checkbox) { + child.treeList.select(item.selected) + } + }) + } else { + if (item.node) { + if (item.selected) { + delete filteredNodes[item.node.id] + } else { + filteredNodes[item.node.id] = true; + } + RED.settings.set('debug.filteredNodes',Object.keys(filteredNodes)) + refreshMessageList(); + } + } + }) + + try { + content.i18n(); + } catch(err) { + console.log("TODO: i18n library support"); + } + + toolbar.find('#red-ui-sidebar-debug-filter span').text(RED._('node-red:debug.sidebar.filterAll')); + + toolbar.find('#red-ui-sidebar-debug-filter').on("click",function(e) { + e.preventDefault(); + var options = [ + { label: $(' ').i18n() , value: "filterAll" }, + { label: $(' ...').i18n(), value: "filterSelected" }, + { label: $(' ').i18n(), value: "filterCurrent" } + ] + var menu = RED.popover.menu({ + options: options, + onselect: function(item) { + if (item.value !== filterType) { + filterType = item.value; + $('#red-ui-sidebar-debug-filter span').text(RED._('node-red:debug.sidebar.'+filterType)); + refreshMessageList(); + RED.settings.set("debug.filter",filterType) + } + if (filterType === 'filterSelected') { + refreshDebugNodeList(); + filterDialog.slideDown(200); + filterDialogShown = true; + debugNodeTreeList.focus(); + } + + } + }); + menu.show({ + target: $("#red-ui-sidebar-debug-filter"), + align: "left", + offset: [$("#red-ui-sidebar-debug-filter").outerWidth()-2, -1] + }) + $('input[name="filter-type"][value="'+RED.settings.get("debug.filter","filterAll")+'"]').prop("checked", true) + }); + RED.popover.tooltip(toolbar.find('#red-ui-sidebar-debug-filter'),RED._('node-red:debug.sidebar.filterLog')); + + toolbar.find("#red-ui-sidebar-debug-clear").on("click", function(e) { + e.preventDefault(); + var action = RED.settings.get("debug.clearType","all") + clearMessageList(false, action === 'filtered'); + }); + var clearTooltip = RED.popover.tooltip(toolbar.find("#red-ui-sidebar-debug-clear"),RED._('node-red:debug.sidebar.clearLog'),"core:clear-debug-messages"); + toolbar.find("#red-ui-sidebar-debug-clear-opts").on("click", function(e) { + e.preventDefault(); + var options = [ + { label: $(' ').i18n() , value: "all" }, + { label: $(' ').i18n(), value: "filtered" } + ] + var menu = RED.popover.menu({ + options: options, + onselect: function(item) { + if (item.value === "all") { + $("#red-ui-sidebar-debug-clear > span").text(RED._('node-red:debug.sidebar.all')); + clearTooltip.setAction("core:clear-debug-messages"); + clearTooltip.setContent(RED._('node-red:debug.sidebar.clearLog')) + RED.settings.set("debug.clearType","all") + } else { + $("#red-ui-sidebar-debug-clear > span").text(RED._('node-red:debug.sidebar.filtered')); + clearTooltip.setAction("core:clear-filtered-debug-messages"); + clearTooltip.setContent(RED._('node-red:debug.sidebar.clearFilteredLog')) + RED.settings.set("debug.clearType","filtered") + } + } + }); + menu.show({ + target: $("#red-ui-sidebar-debug-clear-opts"), + align: "left", + offset: [$("#red-ui-sidebar-debug-clear-opts").outerWidth()-2, -1] + }) + $('input[name="clear-type"][value="'+RED.settings.get("debug.clearType","all")+'"]').prop("checked", true) + }) + + var clearType = RED.settings.get("debug.clearType","all"); + if (clearType === "all") { + toolbar.find("#red-ui-sidebar-debug-clear > span").text(RED._('node-red:debug.sidebar.all')); + clearTooltip.setAction("core:clear-debug-messages"); + clearTooltip.setContent(RED._('node-red:debug.sidebar.clearLog')) + } else { + toolbar.find("#red-ui-sidebar-debug-clear > span").text(RED._('node-red:debug.sidebar.filtered')); + clearTooltip.setAction("core:clear-filtered-debug-messages"); + clearTooltip.setContent(RED._('node-red:debug.sidebar.clearFilteredLog')) + } + + filterType = RED.settings.get("debug.filter","filterAll") + var filteredNodeList = RED.settings.get("debug.filteredNodes",[]); + filteredNodes = {} + filteredNodeList.forEach(function(id) { + filteredNodes[id] = true + }) + toolbar.find('#red-ui-sidebar-debug-filter span').text(RED._('node-red:debug.sidebar.'+filterType)); + refreshMessageList(); + + return { + content: content, + footer: footerToolbar + }; + + } + + + function containsDebug(sid, map) { + var item = map[sid]; + if (item) { + if (item.debug === undefined) { + var sfs = Object.keys(item.subflows); + var contain = false; + for (var i = 0; i < sfs.length; i++) { + var sf = sfs[i]; + if (containsDebug(sf, map)) { + contain = true; + break; + } + } + item.debug = contain; + } + return item.debug; + } + return false; + } + + + function refreshDebugNodeList() { + var workspaceOrder = RED.nodes.getWorkspaceOrder(); + var workspaceOrderMap = {}; + workspaceOrder.forEach(function(ws,i) { + workspaceOrderMap[ws] = i; + }); + + var candidateNodes = []; + var candidateSFs = []; + var subflows = {}; + RED.nodes.eachNode(function (n) { + var nt = n.type; + if (nt === "debug") { + if (n.z in workspaceOrderMap) { + candidateNodes.push(n); + } + else { + var sf = RED.nodes.subflow(n.z); + if (sf) { + subflows[sf.id] = { + debug: true, + subflows: {} + }; + } + } + } + else if(nt.substring(0, 8) === "subflow:") { + if (n.z in workspaceOrderMap) { + candidateSFs.push(n); + } + else { + var psf = RED.nodes.subflow(n.z); + if (psf) { + var sid = nt.substring(8); + var item = subflows[psf.id]; + if (!item) { + item = { + debug: undefined, + subflows: {} + }; + subflows[psf.id] = item; + } + item.subflows[sid] = true; + } + } + } + }); + candidateSFs.forEach(function (sf) { + var sid = sf.type.substring(8); + if (containsDebug(sid, subflows)) { + candidateNodes.push(sf); + } + }); + + candidateNodes.sort(function(A,B) { + var wsA = workspaceOrderMap[A.z]; + var wsB = workspaceOrderMap[B.z]; + if (wsA !== wsB) { + return wsA-wsB; + } + var labelA = RED.utils.getNodeLabel(A,A.id); + var labelB = RED.utils.getNodeLabel(B,B.id); + return labelA.localeCompare(labelB); + }); + var currentWs = null; + var data = []; + var currentFlow; + var currentSelectedCount = 0; + candidateNodes.forEach(function(node) { + if (currentWs !== node.z) { + if (currentFlow && currentFlow.checkbox) { + currentFlow.selected = currentSelectedCount === currentFlow.children.length + } + currentSelectedCount = 0; + currentWs = node.z; + var parent = RED.nodes.workspace(currentWs) || RED.nodes.subflow(currentWs); + currentFlow = { + label: RED.utils.getNodeLabel(parent, currentWs), + } + if (!parent.disabled) { + currentFlow.children = []; + currentFlow.checkbox = true; + } else { + currentFlow.class = "disabled" + } + data.push(currentFlow); + } + if (currentFlow.children) { + if (!filteredNodes[node.id]) { + currentSelectedCount++; + } + currentFlow.children.push({ + label: RED.utils.getNodeLabel(node,node.id), + node: node, + checkbox: true, + selected: !filteredNodes[node.id] + }); + } + }); + if (currentFlow && currentFlow.checkbox) { + currentFlow.selected = currentSelectedCount === currentFlow.children.length + } + + debugNodeTreeList.treeList("data", data); + } + + function getTimestamp() { + var d = new Date(); + return d.toLocaleString(); + } + + function sanitize(m) { + return m.replace(/&/g,"&").replace(//g,">"); + } + + var refreshTimeout; + function refreshMessageList(_activeWorkspace) { + if (refreshTimeout) { + clearTimeout(refreshTimeout); + } + refreshTimeout = setTimeout(function() { + _refreshMessageList(_activeWorkspace); + },200); + } + function _refreshMessageList(_activeWorkspace) { + if (_activeWorkspace) { + activeWorkspace = _activeWorkspace.replace(/\./g,"_"); + } + if (filterType === "filterAll") { + $(".red-ui-debug-msg").removeClass("hide"); + } else { + $(".red-ui-debug-msg").each(function() { + if (filterType === 'filterCurrent') { + $(this).toggleClass('hide',!$(this).hasClass('red-ui-debug-msg-flow-'+activeWorkspace)); + } else if (filterType === 'filterSelected') { + var id = $(this).data('source'); + if (id) { + $(this).toggleClass('hide',!!filteredNodes[id]); + } + } + }); + } + } + function refreshMessageTable() { + + } + + function showMessageList() { + view = 'list'; + messageTable.hide(); + messageTable.empty(); + + messages.forEach(function(m) { + messageList.append(m.el); + }) + messageList.show(); + } + function showMessageTable() { + view = 'table'; + messageList.hide(); + messageList.empty(); + + Object.keys(messagesByNode).forEach(function(id) { + var m = messagesByNode[id]; + var msg = m.el; + var sourceNode = m.source; + if (sourceNode) { + var wrapper = $("
          ",{id:"red-ui-debug-msg-source-"+sourceNode.id.replace(/\./g,"_")}).appendTo(messageTable); + wrapper.append(msg); + } + }); + messageTable.show(); + } + function formatString(str) { + return str.replace(/\n/g,"↵").replace(/\t/g,"→"); + } + + + var menuOptionMenu; + var activeMenuMessage; + function showMessageMenu(button,dbgMessage,sourceId) { + activeMenuMessage = dbgMessage; + if (!menuOptionMenu) { + var opts = [ + {id:"red-ui-debug-msg-menu-item-collapse",label:RED._("node-red:debug.messageMenu.collapseAll"),onselect:function(){ + activeMenuMessage.collapse(); + }}, + ]; + if (activeMenuMessage.clearPinned) { + opts.push( + {id:"red-ui-debug-msg-menu-item-clear-pins",label:RED._("node-red:debug.messageMenu.clearPinned"),onselect:function(){ + activeMenuMessage.clearPinned(); + }}, + ); + } + opts.push( + null, + {id:"red-ui-debug-msg-menu-item-filter", label:RED._("node-red:debug.messageMenu.filterNode"),onselect:function(){ + var candidateNodes = RED.nodes.filterNodes({type:'debug'}); + candidateNodes.forEach(function(n) { + filteredNodes[n.id] = true; + }); + delete filteredNodes[sourceId]; + $("#red-ui-sidebar-debug-filterSelected").trigger("click"); + RED.settings.set('debug.filteredNodes',Object.keys(filteredNodes)) + refreshMessageList(); + }}, + {id:"red-ui-debug-msg-menu-item-clear-filter",label:RED._("node-red:debug.messageMenu.clearFilter"),onselect:function(){ + $("#red-ui-sidebar-debug-filterAll").trigger("click"); + refreshMessageList(); + }} + ); + + menuOptionMenu = RED.menu.init({id:"red-ui-debug-msg-option-menu", + options: opts + }); + menuOptionMenu.css({ + position: "absolute" + }) + menuOptionMenu.on('mouseleave', function(){ $(this).hide() }); + menuOptionMenu.on('mouseup', function() { $(this).hide() }); + menuOptionMenu.appendTo("body"); + } + + var filterOptionDisabled = false; + var sourceNode = RED.nodes.node(sourceId); + if (sourceNode && sourceNode.type !== 'debug') { + filterOptionDisabled = true; + } + RED.menu.setDisabled('red-ui-debug-msg-menu-item-filter',filterOptionDisabled); + RED.menu.setDisabled('red-ui-debug-msg-menu-item-clear-filter',filterOptionDisabled); + + var elementPos = button.offset(); + menuOptionMenu.css({ + top: elementPos.top+"px", + left: (elementPos.left - menuOptionMenu.width() + 20)+"px" + }) + menuOptionMenu.show(); + } + + var stack = []; + var busy = false; + function handleDebugMessage(o) { + if (o) { stack.push(o); } + if (!busy && (stack.length > 0)) { + busy = true; + processDebugMessage(stack.shift()); + setTimeout(function() { + busy = false; + handleDebugMessage(); + }, 15); // every 15mS = 66 times a second + if (stack.length > numMessages) { stack = stack.splice(-numMessages); } + } + } + + function processDebugMessage(o) { + var msg = $("
          "); + var sourceNode = o._source; + + msg.on("mouseenter", function() { + msg.addClass('red-ui-debug-msg-hover'); + if (o._source) { + // highlight the top-level node (could be subflow instance) + config.messageMouseEnter(o._source.id); + if (o._source._alias) { + // this is inside a subflow - highlight the node itself + config.messageMouseEnter(o._source._alias); + } + // if path.length > 2, we are nested - highlight subflow instances + for (var i=2;i
          ').appendTo(msg); + $(''+ getTimestamp()+'').appendTo(metaRow); + if (sourceNode) { + + var nodeLink = $('',{href:"#",class:"red-ui-debug-msg-name"}).text(RED._("node-red:debug.node")+": "+(o.name||sourceNode.name||sourceNode.id)) + .appendTo(metaRow) + .on("click", function(evt) { + evt.preventDefault(); + config.messageSourceClick(sourceNode.id, sourceNode._alias, sourceNode.path); + }); + + if (sourceNode.pathHierarchy) { + RED.popover.create({ + tooltip: true, + target:nodeLink, + trigger: "hover", + size: "small", + direction: "bottom", + interactive: true, + content: function() { + const content = $("
          ") + sourceNode.pathHierarchy.forEach((pathPart,idx) => { + const link = $("", {href:"#" ,style:'display: block'}) + .css({ + paddingLeft:((idx*10)+((idx === sourceNode.pathHierarchy.length - 1)?10:0))+"px", + paddingRight:'2px' + }) + .text(pathPart.label) + .appendTo(content) + .on("click", function(evt) { + evt.preventDefault(); + config.messageSourceClick(pathPart.id); + }) + if (idx < sourceNode.pathHierarchy.length - 1) { + $('').prependTo(link) + } + }) + return content + }, + delay: { show: 50, hide: 150 } + }); + } + } else if (name) { + $(''+name+'').appendTo(metaRow); + } + + payload = RED.utils.decodeObject(payload,format); + + var el = $('').appendTo(msg); + var path = o.property||''; + var debugMessage = RED.utils.createObjectElement(payload, { + key: /*true*/null, + typeHint: format, + hideKey: false, + path: path, + sourceId: sourceNode&&sourceNode.id, + rootPath: path + }); + // Do this in a separate step so the element functions aren't stripped + debugMessage.appendTo(el); + // NOTE: relying on function error to have a "type" that all other msgs don't + if (o.hasOwnProperty("type") && (o.type === "function")) { + var errorLvlType = 'error'; + var errorLvl = 20; + if (o.hasOwnProperty("level") && o.level === 30) { + errorLvl = 30; + errorLvlType = 'warn'; + } + msg.addClass('red-ui-debug-msg-level-' + errorLvl); + $('function : (' + errorLvlType + ')').appendTo(metaRow); + } else { + var tools = $('').appendTo(metaRow); + var filterMessage = $('').appendTo(tools); + filterMessage.on("click", function(e) { + e.preventDefault(); + e.stopPropagation(); + showMessageMenu(filterMessage,debugMessage,sourceNode&&sourceNode.id); + }); + $(''+ + (o.topic?topic+' : ':'')+ + (o.property?'msg.'+property:'msg')+" : "+format+ + '').appendTo(metaRow); + } + + var atBottom = (sbc.scrollHeight-messageList.height()-sbc.scrollTop) < 5; + var m = { + el: msg + }; + messages.push(m); + if (sourceNode) { + m.source = sourceNode; + messagesByNode[sourceNode.id] = m; + } + if (view == "list") { + messageList.append(msg); + } else { + if (sourceNode) { + var wrapper = $("#red-ui-debug-msg-source-"+sourceNode.id.replace(/\./g,"_")); + if (wrapper.length === 0 ) { + wrapper = $("
          ",{id:"red-ui-debug-msg-source-"+sourceNode.id.replace(/\./g,"_")}).appendTo(messageTable); + } + wrapper.empty(); + wrapper.append(msg); + } + } + + if (messages.length === numMessages) { + m = messages.shift(); + if (view === "list") { + m.el.remove(); + } + } + if (atBottom) { + messageList.scrollTop(sbc.scrollHeight); + } + } + + function clearMessageList(clearFilter, filteredOnly) { + if (!filteredOnly) { + $(".red-ui-debug-msg").remove(); + } else { + $(".red-ui-debug-msg:not(.hide)").remove(); + } + config.clear(); + if (!!clearFilter) { + clearFilterSettings(); + } + refreshDebugNodeList(); + } + + function clearFilterSettings() { + filteredNodes = {}; + filterType = 'filterAll'; + RED.settings.set("debug.filter",filterType); + RED.settings.set('debug.filteredNodes',Object.keys(filteredNodes)) + $('#red-ui-sidebar-debug-filter span').text(RED._('node-red:debug.sidebar.filterAll')); + } + + return { + init: init, + refreshMessageList:refreshMessageList, + handleDebugMessage: handleDebugMessage, + clearMessageList: clearMessageList + } +})(); diff --git a/software/dashboard/grafana/csv/Node-RED_files/deploy-flows.svg b/software/dashboard/grafana/csv/Node-RED_files/deploy-flows.svg new file mode 100644 index 0000000..0b00692 --- /dev/null +++ b/software/dashboard/grafana/csv/Node-RED_files/deploy-flows.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/software/dashboard/grafana/csv/Node-RED_files/deploy-full-o.svg b/software/dashboard/grafana/csv/Node-RED_files/deploy-full-o.svg new file mode 100644 index 0000000..fc3221f --- /dev/null +++ b/software/dashboard/grafana/csv/Node-RED_files/deploy-full-o.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/software/dashboard/grafana/csv/Node-RED_files/deploy-full.svg b/software/dashboard/grafana/csv/Node-RED_files/deploy-full.svg new file mode 100644 index 0000000..e4448e1 --- /dev/null +++ b/software/dashboard/grafana/csv/Node-RED_files/deploy-full.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/software/dashboard/grafana/csv/Node-RED_files/deploy-nodes.svg b/software/dashboard/grafana/csv/Node-RED_files/deploy-nodes.svg new file mode 100644 index 0000000..12d4c89 --- /dev/null +++ b/software/dashboard/grafana/csv/Node-RED_files/deploy-nodes.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/software/dashboard/grafana/csv/Node-RED_files/deploy-reload.svg b/software/dashboard/grafana/csv/Node-RED_files/deploy-reload.svg new file mode 100644 index 0000000..00f3190 --- /dev/null +++ b/software/dashboard/grafana/csv/Node-RED_files/deploy-reload.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/software/dashboard/grafana/csv/Node-RED_files/editor.js b/software/dashboard/grafana/csv/Node-RED_files/editor.js new file mode 100644 index 0000000..51feda7 --- /dev/null +++ b/software/dashboard/grafana/csv/Node-RED_files/editor.js @@ -0,0 +1,2 @@ +/*! For license information please see editor.js.LICENSE.txt */ +!function(){var e={89982:function(e,t,i){"use strict";function n(e,t){let i;return i=0===t.length?e:e.replace(/\{(\d+)\}/g,(function(e,i){const n=i[0];return void 0!==t[n]?t[n]:e})),i}function o(e,t,i){const o="object"==typeof t?t.key:t,r=(window.MonacoLocale||{}||{}).data||{};let s=(r[e]||{})[o];s||(s=i);const a=[];for(let e=3;e .action-label {\n\tmargin-right: 1px;\n}\n",""]),t.Z=s},15479:function(e,t,i){"use strict";var n=i(8081),o=i.n(n),r=i(23645),s=i.n(r)()(o());s.push([e.id,"/*---------------------------------------------------------------------------------------------\n * Copyright (c) Microsoft Corporation. All rights reserved.\n * Licensed under the MIT License. See License.txt in the project root for license information.\n *--------------------------------------------------------------------------------------------*/\n\n.monaco-aria-container {\n\tposition: absolute; /* try to hide from window but not from screen readers */\n\tleft:-999em;\n}",""]),t.Z=s},33767:function(e,t,i){"use strict";var n=i(8081),o=i.n(n),r=i(23645),s=i.n(r)()(o());s.push([e.id,"/*---------------------------------------------------------------------------------------------\n * Copyright (c) Microsoft Corporation. All rights reserved.\n * Licensed under the MIT License. See License.txt in the project root for license information.\n *--------------------------------------------------------------------------------------------*/\n\n.monaco-text-button {\n\tbox-sizing: border-box;\n\tdisplay: flex;\n\twidth: 100%;\n\tpadding: 4px;\n\ttext-align: center;\n\tcursor: pointer;\n\tjustify-content: center;\n\talign-items: center;\n}\n\n.monaco-text-button:focus {\n\toutline-offset: 2px !important;\n}\n\n.monaco-text-button:hover {\n\ttext-decoration: none !important;\n}\n\n.monaco-button.disabled:focus,\n.monaco-button.disabled {\n\topacity: 0.4 !important;\n\tcursor: default;\n}\n\n.monaco-text-button > .codicon {\n\tmargin: 0 0.2em;\n\tcolor: inherit !important;\n}\n\n.monaco-button-dropdown {\n\tdisplay: flex;\n\tcursor: pointer;\n}\n\n.monaco-button-dropdown > .monaco-dropdown-button {\n\tmargin-left: 1px;\n}\n\n.monaco-description-button {\n\tflex-direction: column;\n}\n\n.monaco-description-button .monaco-button-label {\n\tfont-weight: 500;\n}\n\n.monaco-description-button .monaco-button-description {\n\tfont-style: italic;\n}\n\n.monaco-description-button .monaco-button-label,\n.monaco-description-button .monaco-button-description\n{\n\tdisplay: flex;\n\tjustify-content: center;\n\talign-items: center;\n}\n\n.monaco-description-button .monaco-button-label > .codicon,\n.monaco-description-button .monaco-button-description > .codicon\n{\n\tmargin: 0 0.2em;\n\tcolor: inherit !important;\n}\n",""]),t.Z=s},25222:function(e,t,i){"use strict";var n=i(8081),o=i.n(n),r=i(23645),s=i.n(r)()(o());s.push([e.id,"/*---------------------------------------------------------------------------------------------\n * Copyright (c) Microsoft Corporation. All rights reserved.\n * Licensed under the MIT License. See License.txt in the project root for license information.\n *--------------------------------------------------------------------------------------------*/\n\n.monaco-custom-checkbox {\n\tmargin-left: 2px;\n\tfloat: left;\n\tcursor: pointer;\n\toverflow: hidden;\n\twidth: 20px;\n\theight: 20px;\n\tborder-radius: 3px;\n\tborder: 1px solid transparent;\n\tpadding: 1px;\n\tbox-sizing:\tborder-box;\n\tuser-select: none;\n\t-webkit-user-select: none;\n\t-ms-user-select: none;\n}\n\n.monaco-custom-checkbox:hover {\n\tbackground-color: var(--vscode-inputOption-hoverBackground);\n}\n\n.hc-black .monaco-custom-checkbox:hover {\n\tborder: 1px dashed var(--vscode-focusBorder);\n}\n\n.hc-black .monaco-custom-checkbox {\n\tbackground: none;\n}\n\n.hc-black .monaco-custom-checkbox:hover {\n\tbackground: none;\n}\n\n.monaco-custom-checkbox.monaco-simple-checkbox {\n\theight: 18px;\n\twidth: 18px;\n\tborder: 1px solid transparent;\n\tborder-radius: 3px;\n\tmargin-right: 9px;\n\tmargin-left: 0px;\n\tpadding: 0px;\n\topacity: 1;\n\tbackground-size: 16px !important;\n}\n\n/* hide check when unchecked */\n.monaco-custom-checkbox.monaco-simple-checkbox:not(.checked)::before {\n\tvisibility: hidden;\n}\n",""]),t.Z=s},38533:function(e,t,i){"use strict";var n=i(8081),o=i.n(n),r=i(23645),s=i.n(r)()(o());s.push([e.id,"/*---------------------------------------------------------------------------------------------\n * Copyright (c) Microsoft Corporation. All rights reserved.\n * Licensed under the MIT License. See License.txt in the project root for license information.\n *--------------------------------------------------------------------------------------------*/\n\n.codicon-wrench-subaction {\n\topacity: 0.5;\n}\n\n@keyframes codicon-spin {\n\t100% {\n\t\ttransform:rotate(360deg);\n\t}\n}\n\n.codicon-sync.codicon-modifier-spin,\n.codicon-loading.codicon-modifier-spin,\n.codicon-gear.codicon-modifier-spin,\n.codicon-notebook-state-executing.codicon-modifier-spin {\n\t/* Use steps to throttle FPS to reduce CPU usage */\n\tanimation: codicon-spin 1.5s steps(30) infinite;\n}\n\n.codicon-modifier-disabled {\n\topacity: 0.4;\n}\n\n/* custom speed & easing for loading icon */\n.codicon-loading,\n.codicon-tree-item-loading::before {\n\tanimation-duration: 1s !important;\n\tanimation-timing-function: cubic-bezier(0.53, 0.21, 0.29, 0.67) !important;\n}\n",""]),t.Z=s},65077:function(e,t,i){"use strict";var n=i(8081),o=i.n(n),r=i(23645),s=i.n(r),a=i(61667),l=i.n(a),c=new URL(i(38137),i.b),d=s()(o()),u=l()(c);d.push([e.id,'/*---------------------------------------------------------------------------------------------\n * Copyright (c) Microsoft Corporation. All rights reserved.\n * Licensed under the MIT License. See License.txt in the project root for license information.\n *--------------------------------------------------------------------------------------------*/\n\n@font-face {\n\tfont-family: "codicon";\n\tfont-display: block;\n\tsrc: url('+u+") format(\"truetype\");\n}\n\n.codicon[class*='codicon-'] {\n\tfont: normal normal normal 16px/1 codicon;\n\tdisplay: inline-block;\n\ttext-decoration: none;\n\ttext-rendering: auto;\n\ttext-align: center;\n\ttext-transform: none;\n\t-webkit-font-smoothing: antialiased;\n\t-moz-osx-font-smoothing: grayscale;\n\tuser-select: none;\n\t-webkit-user-select: none;\n\t-ms-user-select: none;\n}\n\n/* icon rules are dynamically created by the platform theme service (see iconsStyleSheet.ts) */\n",""]),t.Z=d},3726:function(e,t,i){"use strict";var n=i(8081),o=i.n(n),r=i(23645),s=i.n(r)()(o());s.push([e.id,"/*---------------------------------------------------------------------------------------------\n * Copyright (c) Microsoft Corporation. All rights reserved.\n * Licensed under the MIT License. See License.txt in the project root for license information.\n *--------------------------------------------------------------------------------------------*/\n\n.context-view {\n\tposition: absolute;\n\tz-index: 2500;\n}\n\n.context-view.fixed {\n\tall: initial;\n\tfont-family: inherit;\n\tfont-size: 13px;\n\tposition: fixed;\n\tz-index: 2500;\n\tcolor: inherit;\n}\n",""]),t.Z=s},76558:function(e,t,i){"use strict";var n=i(8081),o=i.n(n),r=i(23645),s=i.n(r)()(o());s.push([e.id,"/*---------------------------------------------------------------------------------------------\n * Copyright (c) Microsoft Corporation. All rights reserved.\n * Licensed under the MIT License. See License.txt in the project root for license information.\n *--------------------------------------------------------------------------------------------*/\n\n.monaco-count-badge {\n\tpadding: 3px 6px;\n\tborder-radius: 11px;\n\tfont-size: 11px;\n\tmin-width: 18px;\n\tmin-height: 18px;\n\tline-height: 11px;\n\tfont-weight: normal;\n\ttext-align: center;\n\tdisplay: inline-block;\n\tbox-sizing: border-box;\n}\n\n.monaco-count-badge.long {\n\tpadding: 2px 3px;\n\tborder-radius: 2px;\n\tmin-height: auto;\n\tline-height: normal;\n}\n",""]),t.Z=s},68904:function(e,t,i){"use strict";var n=i(8081),o=i.n(n),r=i(23645),s=i.n(r)()(o());s.push([e.id,"/*---------------------------------------------------------------------------------------------\n * Copyright (c) Microsoft Corporation. All rights reserved.\n * Licensed under the MIT License. See License.txt in the project root for license information.\n *--------------------------------------------------------------------------------------------*/\n\n.monaco-dropdown {\n\theight: 100%;\n\tpadding: 0;\n}\n\n.monaco-dropdown > .dropdown-label {\n\tcursor: pointer;\n\theight: 100%;\n\tdisplay: flex;\n\talign-items: center;\n\tjustify-content: center;\n}\n\n.monaco-dropdown > .dropdown-label > .action-label.disabled {\n\tcursor: default;\n}\n\n.monaco-dropdown-with-primary {\n\tdisplay: flex !important;\n\tflex-direction: row;\n\tborder-radius: 5px;\n}\n\n.monaco-dropdown-with-primary > .action-container > .action-label {\n\tmargin-right: 0;\n}\n\n.monaco-dropdown-with-primary > .dropdown-action-container > .monaco-dropdown > .dropdown-label .codicon[class*='codicon-'] {\n\tfont-size: 12px;\n\tpadding-left: 0px;\n\tpadding-right: 0px;\n\tline-height: 16px;\n\tmargin-left: -3px;\n}\n\n.monaco-dropdown-with-primary > .dropdown-action-container > .monaco-dropdown > .dropdown-label > .action-label {\n\tdisplay: block;\n\tbackground-size: 16px;\n\tbackground-position: center center;\n\tbackground-repeat: no-repeat;\n}\n",""]),t.Z=s},13737:function(e,t,i){"use strict";var n=i(8081),o=i.n(n),r=i(23645),s=i.n(r)()(o());s.push([e.id,"/*---------------------------------------------------------------------------------------------\n * Copyright (c) Microsoft Corporation. All rights reserved.\n * Licensed under the MIT License. See License.txt in the project root for license information.\n *--------------------------------------------------------------------------------------------*/\n/* ---------- Find input ---------- */\n\n.monaco-findInput {\n\tposition: relative;\n}\n\n.monaco-findInput .monaco-inputbox {\n\tfont-size: 13px;\n\twidth: 100%;\n}\n\n.monaco-findInput > .controls {\n\tposition: absolute;\n\ttop: 3px;\n\tright: 2px;\n}\n\n.vs .monaco-findInput.disabled {\n\tbackground-color: #E1E1E1;\n}\n\n/* Theming */\n.vs-dark .monaco-findInput.disabled {\n\tbackground-color: #333;\n}\n\n/* Highlighting */\n.monaco-findInput.highlight-0 .controls {\n\tanimation: monaco-findInput-highlight-0 100ms linear 0s;\n}\n.monaco-findInput.highlight-1 .controls {\n\tanimation: monaco-findInput-highlight-1 100ms linear 0s;\n}\n.hc-black .monaco-findInput.highlight-0 .controls,\n.vs-dark .monaco-findInput.highlight-0 .controls {\n\tanimation: monaco-findInput-highlight-dark-0 100ms linear 0s;\n}\n.hc-black .monaco-findInput.highlight-1 .controls,\n.vs-dark .monaco-findInput.highlight-1 .controls {\n\tanimation: monaco-findInput-highlight-dark-1 100ms linear 0s;\n}\n\n@keyframes monaco-findInput-highlight-0 {\n\t0% { background: rgba(253, 255, 0, 0.8); }\n\t100% { background: transparent; }\n}\n@keyframes monaco-findInput-highlight-1 {\n\t0% { background: rgba(253, 255, 0, 0.8); }\n\t/* Made intentionally different such that the CSS minifier does not collapse the two animations into a single one*/\n\t99% { background: transparent; }\n}\n\n@keyframes monaco-findInput-highlight-dark-0 {\n\t0% { background: rgba(255, 255, 255, 0.44); }\n\t100% { background: transparent; }\n}\n@keyframes monaco-findInput-highlight-dark-1 {\n\t0% { background: rgba(255, 255, 255, 0.44); }\n\t/* Made intentionally different such that the CSS minifier does not collapse the two animations into a single one*/\n\t99% { background: transparent; }\n}",""]),t.Z=s},33016:function(e,t,i){"use strict";var n=i(8081),o=i.n(n),r=i(23645),s=i.n(r)()(o());s.push([e.id,"/*---------------------------------------------------------------------------------------------\n * Copyright (c) Microsoft Corporation. All rights reserved.\n * Licensed under the MIT License. See License.txt in the project root for license information.\n *--------------------------------------------------------------------------------------------*/\n\n.monaco-hover {\n\tcursor: default;\n\tposition: absolute;\n\toverflow: hidden;\n\tz-index: 50;\n\tuser-select: text;\n\t-webkit-user-select: text;\n\t-ms-user-select: text;\n\tbox-sizing: initial;\n\tanimation: fadein 100ms linear;\n\tline-height: 1.5em;\n}\n\n.monaco-hover.hidden {\n\tdisplay: none;\n}\n\n.monaco-hover a:hover {\n\tcursor: pointer;\n}\n\n.monaco-hover .hover-contents:not(.html-hover-contents) {\n\tpadding: 4px 8px;\n}\n\n.monaco-hover .markdown-hover > .hover-contents:not(.code-hover-contents) {\n\tmax-width: 500px;\n\tword-wrap: break-word;\n}\n\n.monaco-hover .markdown-hover > .hover-contents:not(.code-hover-contents) hr {\n\tmin-width: 100%;\n}\n\n.monaco-hover p,\n.monaco-hover .code,\n.monaco-hover ul {\n\tmargin: 8px 0;\n}\n\n.monaco-hover code {\n\tfont-family: var(--monaco-monospace-font);\n}\n\n.monaco-hover hr {\n\tbox-sizing: border-box;\n\tborder-left: 0px;\n\tborder-right: 0px;\n\tmargin-top: 4px;\n\tmargin-bottom: -4px;\n\tmargin-left: -8px;\n\tmargin-right: -8px;\n\theight: 1px;\n}\n\n.monaco-hover p:first-child,\n.monaco-hover .code:first-child,\n.monaco-hover ul:first-child {\n\tmargin-top: 0;\n}\n\n.monaco-hover p:last-child,\n.monaco-hover .code:last-child,\n.monaco-hover ul:last-child {\n\tmargin-bottom: 0;\n}\n\n/* MarkupContent Layout */\n.monaco-hover ul {\n\tpadding-left: 20px;\n}\n.monaco-hover ol {\n\tpadding-left: 20px;\n}\n\n.monaco-hover li > p {\n\tmargin-bottom: 0;\n}\n\n.monaco-hover li > ul {\n\tmargin-top: 0;\n}\n\n.monaco-hover code {\n\tborder-radius: 3px;\n\tpadding: 0 0.4em;\n}\n\n.monaco-hover .monaco-tokenized-source {\n\twhite-space: pre-wrap;\n}\n\n.monaco-hover .hover-row.status-bar {\n\tfont-size: 12px;\n\tline-height: 22px;\n}\n\n.monaco-hover .hover-row.status-bar .actions {\n\tdisplay: flex;\n\tpadding: 0px 8px;\n}\n\n.monaco-hover .hover-row.status-bar .actions .action-container {\n\tmargin-right: 16px;\n\tcursor: pointer;\n}\n\n.monaco-hover .hover-row.status-bar .actions .action-container .action .icon {\n\tpadding-right: 4px;\n}\n\n.monaco-hover .markdown-hover .hover-contents .codicon {\n\tcolor: inherit;\n\tfont-size: inherit;\n\tvertical-align: middle;\n}\n\n.monaco-hover .hover-contents a.code-link:hover,\n.monaco-hover .hover-contents a.code-link {\n\tcolor: inherit;\n}\n\n.monaco-hover .hover-contents a.code-link:before {\n\tcontent: '(';\n}\n\n.monaco-hover .hover-contents a.code-link:after {\n\tcontent: ')';\n}\n\n.monaco-hover .hover-contents a.code-link > span {\n\ttext-decoration: underline;\n\t/** Hack to force underline to show **/\n\tborder-bottom: 1px solid transparent;\n\ttext-underline-position: under;\n}\n\n/** Spans in markdown hovers need a margin-bottom to avoid looking cramped: https://github.com/microsoft/vscode/issues/101496 **/\n.monaco-hover .markdown-hover .hover-contents:not(.code-hover-contents):not(.html-hover-contents) span {\n\tmargin-bottom: 4px;\n\tdisplay: inline-block;\n}\n\n.monaco-hover-content .action-container a {\n\t-webkit-user-select: none;\n\tuser-select: none;\n}\n\n.monaco-hover-content .action-container.disabled {\n\tpointer-events: none;\n\topacity: 0.4;\n\tcursor: default;\n}\n",""]),t.Z=s},78963:function(e,t,i){"use strict";var n=i(8081),o=i.n(n),r=i(23645),s=i.n(r)()(o());s.push([e.id,"/*---------------------------------------------------------------------------------------------\n * Copyright (c) Microsoft Corporation. All rights reserved.\n * Licensed under the MIT License. See License.txt in the project root for license information.\n *--------------------------------------------------------------------------------------------*/\n\n/* ---------- Icon label ---------- */\n\n.monaco-icon-label {\n\tdisplay: flex; /* required for icons support :before rule */\n\toverflow: hidden;\n\ttext-overflow: ellipsis;\n}\n\n.monaco-icon-label::before {\n\n\t/* svg icons rendered as background image */\n\tbackground-size: 16px;\n\tbackground-position: left center;\n\tbackground-repeat: no-repeat;\n\tpadding-right: 6px;\n\twidth: 16px;\n\theight: 22px;\n\tline-height: inherit !important;\n\tdisplay: inline-block;\n\n\t/* fonts icons */\n\t-webkit-font-smoothing: antialiased;\n\t-moz-osx-font-smoothing: grayscale;\n\tvertical-align: top;\n\n\tflex-shrink: 0; /* fix for https://github.com/microsoft/vscode/issues/13787 */\n}\n\n.monaco-icon-label > .monaco-icon-label-container {\n\tmin-width: 0;\n\toverflow: hidden;\n\ttext-overflow: ellipsis;\n\tflex: 1;\n}\n\n.monaco-icon-label > .monaco-icon-label-container > .monaco-icon-name-container > .label-name {\n\tcolor: inherit;\n\twhite-space: pre; /* enable to show labels that include multiple whitespaces */\n}\n\n.monaco-icon-label > .monaco-icon-label-container > .monaco-icon-name-container > .label-name > .label-separator {\n\tmargin: 0 2px;\n\topacity: 0.5;\n}\n\n.monaco-icon-label > .monaco-icon-label-container > .monaco-icon-description-container > .label-description {\n\topacity: .7;\n\tmargin-left: 0.5em;\n\tfont-size: 0.9em;\n\twhite-space: pre; /* enable to show labels that include multiple whitespaces */\n}\n\n.monaco-icon-label.nowrap > .monaco-icon-label-container > .monaco-icon-description-container > .label-description{\n\twhite-space: nowrap\n}\n\n.vs .monaco-icon-label > .monaco-icon-label-container > .monaco-icon-description-container > .label-description {\n\topacity: .95;\n}\n\n.monaco-icon-label.italic > .monaco-icon-label-container > .monaco-icon-name-container > .label-name,\n.monaco-icon-label.italic > .monaco-icon-label-container > .monaco-icon-description-container > .label-description {\n\tfont-style: italic;\n}\n\n.monaco-icon-label.deprecated {\n\ttext-decoration: line-through;\n\topacity: 0.66;\n}\n\n/* make sure apply italic font style to decorations as well */\n.monaco-icon-label.italic::after {\n\tfont-style: italic;\n}\n\n.monaco-icon-label.strikethrough > .monaco-icon-label-container > .monaco-icon-name-container > .label-name,\n.monaco-icon-label.strikethrough > .monaco-icon-label-container > .monaco-icon-description-container > .label-description {\n\ttext-decoration: line-through;\n}\n\n.monaco-icon-label::after {\n\topacity: 0.75;\n\tfont-size: 90%;\n\tfont-weight: 600;\n\tmargin: auto 16px 0 5px; /* https://github.com/microsoft/vscode/issues/113223 */\n\ttext-align: center;\n}\n\n/* make sure selection color wins when a label is being selected */\n.monaco-list:focus .selected .monaco-icon-label, /* list */\n.monaco-list:focus .selected .monaco-icon-label::after\n{\n\tcolor: inherit !important;\n}\n\n.monaco-list-row.focused.selected .label-description,\n.monaco-list-row.selected .label-description {\n\topacity: .8;\n}\n",""]),t.Z=s},7121:function(e,t,i){"use strict";var n=i(8081),o=i.n(n),r=i(23645),s=i.n(r)()(o());s.push([e.id,"/*---------------------------------------------------------------------------------------------\n * Copyright (c) Microsoft Corporation. All rights reserved.\n * Licensed under the MIT License. See License.txt in the project root for license information.\n *--------------------------------------------------------------------------------------------*/\n\n.monaco-inputbox {\n\tposition: relative;\n\tdisplay: block;\n\tpadding: 0;\n\tbox-sizing:\tborder-box;\n\n\t/* Customizable */\n\tfont-size: inherit;\n}\n\n.monaco-inputbox.idle {\n\tborder: 1px solid transparent;\n}\n\n.monaco-inputbox > .ibwrapper > .input,\n.monaco-inputbox > .ibwrapper > .mirror {\n\n\t/* Customizable */\n\tpadding: 4px;\n}\n\n.monaco-inputbox > .ibwrapper {\n\tposition: relative;\n\twidth: 100%;\n\theight: 100%;\n}\n\n.monaco-inputbox > .ibwrapper > .input {\n\tdisplay: inline-block;\n\tbox-sizing:\tborder-box;\n\twidth: 100%;\n\theight: 100%;\n\tline-height: inherit;\n\tborder: none;\n\tfont-family: inherit;\n\tfont-size: inherit;\n\tresize: none;\n\tcolor: inherit;\n}\n\n.monaco-inputbox > .ibwrapper > input {\n\ttext-overflow: ellipsis;\n}\n\n.monaco-inputbox > .ibwrapper > textarea.input {\n\tdisplay: block;\n\t-ms-overflow-style: none; /* IE 10+: hide scrollbars */\n\tscrollbar-width: none; /* Firefox: hide scrollbars */\n\toutline: none;\n}\n\n.monaco-inputbox > .ibwrapper > textarea.input::-webkit-scrollbar {\n\tdisplay: none; /* Chrome + Safari: hide scrollbar */\n}\n\n.monaco-inputbox > .ibwrapper > textarea.input.empty {\n\twhite-space: nowrap;\n}\n\n.monaco-inputbox > .ibwrapper > .mirror {\n\tposition: absolute;\n\tdisplay: inline-block;\n\twidth: 100%;\n\ttop: 0;\n\tleft: 0;\n\tbox-sizing: border-box;\n\twhite-space: pre-wrap;\n\tvisibility: hidden;\n\tword-wrap: break-word;\n}\n\n/* Context view */\n\n.monaco-inputbox-container {\n\ttext-align: right;\n}\n\n.monaco-inputbox-container .monaco-inputbox-message {\n\tdisplay: inline-block;\n\toverflow: hidden;\n\ttext-align: left;\n\twidth: 100%;\n\tbox-sizing:\tborder-box;\n\tpadding: 0.4em;\n\tfont-size: 12px;\n\tline-height: 17px;\n\tmargin-top: -1px;\n\tword-wrap: break-word;\n}\n\n/* Action bar support */\n.monaco-inputbox .monaco-action-bar {\n\tposition: absolute;\n\tright: 2px;\n\ttop: 4px;\n}\n\n.monaco-inputbox .monaco-action-bar .action-item {\n\tmargin-left: 2px;\n}\n\n.monaco-inputbox .monaco-action-bar .action-item .codicon {\n\tbackground-repeat: no-repeat;\n\twidth: 16px;\n\theight: 16px;\n}\n",""]),t.Z=s},17200:function(e,t,i){"use strict";var n=i(8081),o=i.n(n),r=i(23645),s=i.n(r)()(o());s.push([e.id,"/*---------------------------------------------------------------------------------------------\n * Copyright (c) Microsoft Corporation. All rights reserved.\n * Licensed under the MIT License. See License.txt in the project root for license information.\n *--------------------------------------------------------------------------------------------*/\n\n.monaco-keybinding {\n\tdisplay: flex;\n\talign-items: center;\n\tline-height: 10px;\n}\n\n.monaco-keybinding > .monaco-keybinding-key {\n\tdisplay: inline-block;\n\tborder-style: solid;\n\tborder-width: 1px;\n\tborder-radius: 3px;\n\tvertical-align: middle;\n\tfont-size: 11px;\n\tpadding: 3px 5px;\n\tmargin: 0 2px;\n}\n\n.monaco-keybinding > .monaco-keybinding-key:first-child {\n\tmargin-left: 0;\n}\n\n.monaco-keybinding > .monaco-keybinding-key:last-child {\n\tmargin-right: 0;\n}\n\n.monaco-keybinding > .monaco-keybinding-key-separator {\n\tdisplay: inline-block;\n}\n\n.monaco-keybinding > .monaco-keybinding-key-chord-separator {\n\twidth: 6px;\n}\n",""]),t.Z=s},41859:function(e,t,i){"use strict";var n=i(8081),o=i.n(n),r=i(23645),s=i.n(r)()(o());s.push([e.id,"/*---------------------------------------------------------------------------------------------\n * Copyright (c) Microsoft Corporation. All rights reserved.\n * Licensed under the MIT License. See License.txt in the project root for license information.\n *--------------------------------------------------------------------------------------------*/\n\n.monaco-list {\n\tposition: relative;\n\theight: 100%;\n\twidth: 100%;\n\twhite-space: nowrap;\n}\n\n.monaco-list.mouse-support {\n\tuser-select: none;\n\t-webkit-user-select: none;\n\t-ms-user-select: none;\n}\n\n.monaco-list > .monaco-scrollable-element {\n\theight: 100%;\n}\n\n.monaco-list-rows {\n\tposition: relative;\n\twidth: 100%;\n\theight: 100%;\n}\n\n.monaco-list.horizontal-scrolling .monaco-list-rows {\n\twidth: auto;\n\tmin-width: 100%;\n}\n\n.monaco-list-row {\n\tposition: absolute;\n\tbox-sizing: border-box;\n\toverflow: hidden;\n\twidth: 100%;\n}\n\n.monaco-list.mouse-support .monaco-list-row {\n\tcursor: pointer;\n\ttouch-action: none;\n}\n\n/* for OS X ballistic scrolling */\n.monaco-list-row.scrolling {\n\tdisplay: none !important;\n}\n\n/* Focus */\n.monaco-list.element-focused,\n.monaco-list.selection-single,\n.monaco-list.selection-multiple {\n\toutline: 0 !important;\n}\n\n/* Dnd */\n.monaco-drag-image {\n\tdisplay: inline-block;\n\tpadding: 1px 7px;\n\tborder-radius: 10px;\n\tfont-size: 12px;\n\tposition: absolute;\n\tz-index: 1000;\n}\n\n/* Type filter */\n\n.monaco-list-type-filter {\n\tdisplay: flex;\n\talign-items: center;\n\tposition: absolute;\n\tborder-radius: 2px;\n\tpadding: 0px 3px;\n\tmax-width: calc(100% - 10px);\n\ttext-overflow: ellipsis;\n\toverflow: hidden;\n\ttext-align: right;\n\tbox-sizing: border-box;\n\tcursor: all-scroll;\n\tfont-size: 13px;\n\tline-height: 18px;\n\theight: 20px;\n\tz-index: 1;\n\ttop: 4px;\n}\n\n.monaco-list-type-filter.dragging {\n\ttransition: top 0.2s, left 0.2s;\n}\n\n.monaco-list-type-filter.ne {\n\tright: 4px;\n}\n\n.monaco-list-type-filter.nw {\n\tleft: 4px;\n}\n\n.monaco-list-type-filter > .controls {\n\tdisplay: flex;\n\talign-items: center;\n\tbox-sizing: border-box;\n\ttransition: width 0.2s;\n\twidth: 0;\n}\n\n.monaco-list-type-filter.dragging > .controls,\n.monaco-list-type-filter:hover > .controls {\n\twidth: 36px;\n}\n\n.monaco-list-type-filter > .controls > * {\n\tborder: none;\n\tbox-sizing: border-box;\n\t-webkit-appearance: none;\n\t-moz-appearance: none;\n\tbackground: none;\n\twidth: 16px;\n\theight: 16px;\n\tflex-shrink: 0;\n\tmargin: 0;\n\tpadding: 0;\n\tdisplay: flex;\n\talign-items: center;\n\tjustify-content: center;\n\tcursor: pointer;\n}\n\n.monaco-list-type-filter > .controls > .filter {\n\tmargin-left: 4px;\n}\n\n.monaco-list-type-filter-message {\n\tposition: absolute;\n\tbox-sizing: border-box;\n\twidth: 100%;\n\theight: 100%;\n\ttop: 0;\n\tleft: 0;\n\tpadding: 40px 1em 1em 1em;\n\ttext-align: center;\n\twhite-space: normal;\n\topacity: 0.7;\n\tpointer-events: none;\n}\n\n.monaco-list-type-filter-message:empty {\n\tdisplay: none;\n}\n\n/* Electron */\n\n.monaco-list-type-filter {\n\tcursor: grab;\n}\n\n.monaco-list-type-filter.dragging {\n\tcursor: grabbing;\n}\n",""]),t.Z=s},12422:function(e,t,i){"use strict";var n=i(8081),o=i.n(n),r=i(23645),s=i.n(r)()(o());s.push([e.id,"/*---------------------------------------------------------------------------------------------\n * Copyright (c) Microsoft Corporation. All rights reserved.\n * Licensed under the MIT License. See License.txt in the project root for license information.\n *--------------------------------------------------------------------------------------------*/\n\n.monaco-mouse-cursor-text {\n\tcursor: text;\n}\n",""]),t.Z=s},451:function(e,t,i){"use strict";var n=i(8081),o=i.n(n),r=i(23645),s=i.n(r)()(o());s.push([e.id,"/*---------------------------------------------------------------------------------------------\n * Copyright (c) Microsoft Corporation. All rights reserved.\n * Licensed under the MIT License. See License.txt in the project root for license information.\n *--------------------------------------------------------------------------------------------*/\n\n.monaco-progress-container {\n\twidth: 100%;\n\theight: 5px;\n\toverflow: hidden; /* keep progress bit in bounds */\n}\n\n.monaco-progress-container .progress-bit {\n\twidth: 2%;\n\theight: 5px;\n\tposition: absolute;\n\tleft: 0;\n\tdisplay: none;\n}\n\n.monaco-progress-container.active .progress-bit {\n\tdisplay: inherit;\n}\n\n.monaco-progress-container.discrete .progress-bit {\n\tleft: 0;\n\ttransition: width 100ms linear;\n}\n\n.monaco-progress-container.discrete.done .progress-bit {\n\twidth: 100%;\n}\n\n.monaco-progress-container.infinite .progress-bit {\n\tanimation-name: progress;\n\tanimation-duration: 4s;\n\tanimation-iteration-count: infinite;\n\ttransform: translate3d(0px, 0px, 0px);\n\tanimation-timing-function: linear;\n}\n\n.monaco-progress-container.infinite.infinite-long-running .progress-bit {\n\t/*\n\t\tThe more smooth `linear` timing function can cause\n\t\thigher GPU consumption as indicated in\n\t\thttps://github.com/microsoft/vscode/issues/97900 &\n\t\thttps://github.com/microsoft/vscode/issues/138396\n\t*/\n\tanimation-timing-function: steps(100);\n}\n\n/**\n * The progress bit has a width: 2% (1/50) of the parent container. The animation moves it from 0% to 100% of\n * that container. Since translateX is relative to the progress bit size, we have to multiple it with\n * its relative size to the parent container:\n * parent width: 5000%\n * bit width: 100%\n * translateX should be as follow:\n * 50%: 5000% * 50% - 50% (set to center) = 2450%\n * 100%: 5000% * 100% - 100% (do not overflow) = 4900%\n */\n@keyframes progress { from { transform: translateX(0%) scaleX(1) } 50% { transform: translateX(2500%) scaleX(3) } to { transform: translateX(4900%) scaleX(1) } }\n",""]),t.Z=s},68126:function(e,t,i){"use strict";var n=i(8081),o=i.n(n),r=i(23645),s=i.n(r)()(o());s.push([e.id,"/*---------------------------------------------------------------------------------------------\n * Copyright (c) Microsoft Corporation. All rights reserved.\n * Licensed under the MIT License. See License.txt in the project root for license information.\n *--------------------------------------------------------------------------------------------*/\n\n:root {\n\t--sash-size: 4px;\n}\n\n.monaco-sash {\n\tposition: absolute;\n\tz-index: 35;\n\ttouch-action: none;\n}\n\n.monaco-sash.disabled {\n\tpointer-events: none;\n}\n\n.monaco-sash.mac.vertical {\n\tcursor: col-resize;\n}\n\n.monaco-sash.vertical.minimum {\n\tcursor: e-resize;\n}\n\n.monaco-sash.vertical.maximum {\n\tcursor: w-resize;\n}\n\n.monaco-sash.mac.horizontal {\n\tcursor: row-resize;\n}\n\n.monaco-sash.horizontal.minimum {\n\tcursor: s-resize;\n}\n\n.monaco-sash.horizontal.maximum {\n\tcursor: n-resize;\n}\n\n.monaco-sash.disabled {\n\tcursor: default !important;\n\tpointer-events: none !important;\n}\n\n.monaco-sash.vertical {\n\tcursor: ew-resize;\n\ttop: 0;\n\twidth: var(--sash-size);\n\theight: 100%;\n}\n\n.monaco-sash.horizontal {\n\tcursor: ns-resize;\n\tleft: 0;\n\twidth: 100%;\n\theight: var(--sash-size);\n}\n\n.monaco-sash:not(.disabled) > .orthogonal-drag-handle {\n\tcontent: \" \";\n\theight: calc(var(--sash-size) * 2);\n\twidth: calc(var(--sash-size) * 2);\n\tz-index: 100;\n\tdisplay: block;\n\tcursor: all-scroll;\n\tposition: absolute;\n}\n\n.monaco-sash.horizontal.orthogonal-edge-north:not(.disabled)\n\t> .orthogonal-drag-handle.start,\n.monaco-sash.horizontal.orthogonal-edge-south:not(.disabled)\n\t> .orthogonal-drag-handle.end {\n\tcursor: nwse-resize;\n}\n\n.monaco-sash.horizontal.orthogonal-edge-north:not(.disabled)\n\t> .orthogonal-drag-handle.end,\n.monaco-sash.horizontal.orthogonal-edge-south:not(.disabled)\n\t> .orthogonal-drag-handle.start {\n\tcursor: nesw-resize;\n}\n\n.monaco-sash.vertical > .orthogonal-drag-handle.start {\n\tleft: calc(var(--sash-size) * -0.5);\n\ttop: calc(var(--sash-size) * -1);\n}\n.monaco-sash.vertical > .orthogonal-drag-handle.end {\n\tleft: calc(var(--sash-size) * -0.5);\n\tbottom: calc(var(--sash-size) * -1);\n}\n.monaco-sash.horizontal > .orthogonal-drag-handle.start {\n\ttop: calc(var(--sash-size) * -0.5);\n\tleft: calc(var(--sash-size) * -1);\n}\n.monaco-sash.horizontal > .orthogonal-drag-handle.end {\n\ttop: calc(var(--sash-size) * -0.5);\n\tright: calc(var(--sash-size) * -1);\n}\n\n.monaco-sash:before {\n\tcontent: '';\n\tpointer-events: none;\n\tposition: absolute;\n\twidth: 100%;\n\theight: 100%;\n\ttransition: background-color 0.1s ease-out;\n\tbackground: transparent;\n}\n\n.monaco-sash.vertical:before {\n\twidth: var(--sash-hover-size);\n\tleft: calc(50% - (var(--sash-hover-size) / 2));\n}\n\n.monaco-sash.horizontal:before {\n\theight: var(--sash-hover-size);\n\ttop: calc(50% - (var(--sash-hover-size) / 2));\n}\n\n.pointer-events-disabled {\n\tpointer-events: none !important;\n}\n\n/** Debug **/\n\n.monaco-sash.debug {\n\tbackground: cyan;\n}\n\n.monaco-sash.debug.disabled {\n\tbackground: rgba(0, 255, 255, 0.2);\n}\n\n.monaco-sash.debug:not(.disabled) > .orthogonal-drag-handle {\n\tbackground: red;\n}\n",""]),t.Z=s},33304:function(e,t,i){"use strict";var n=i(8081),o=i.n(n),r=i(23645),s=i.n(r)()(o());s.push([e.id,"/*---------------------------------------------------------------------------------------------\n * Copyright (c) Microsoft Corporation. All rights reserved.\n * Licensed under the MIT License. See License.txt in the project root for license information.\n *--------------------------------------------------------------------------------------------*/\n\n/* Arrows */\n.monaco-scrollable-element > .scrollbar > .scra {\n\tcursor: pointer;\n\tfont-size: 11px !important;\n}\n\n.monaco-scrollable-element > .visible {\n\topacity: 1;\n\n\t/* Background rule added for IE9 - to allow clicks on dom node */\n\tbackground:rgba(0,0,0,0);\n\n\ttransition: opacity 100ms linear;\n}\n.monaco-scrollable-element > .invisible {\n\topacity: 0;\n\tpointer-events: none;\n}\n.monaco-scrollable-element > .invisible.fade {\n\ttransition: opacity 800ms linear;\n}\n\n/* Scrollable Content Inset Shadow */\n.monaco-scrollable-element > .shadow {\n\tposition: absolute;\n\tdisplay: none;\n}\n.monaco-scrollable-element > .shadow.top {\n\tdisplay: block;\n\ttop: 0;\n\tleft: 3px;\n\theight: 3px;\n\twidth: 100%;\n}\n.monaco-scrollable-element > .shadow.left {\n\tdisplay: block;\n\ttop: 3px;\n\tleft: 0;\n\theight: 100%;\n\twidth: 3px;\n}\n.monaco-scrollable-element > .shadow.top-left-corner {\n\tdisplay: block;\n\ttop: 0;\n\tleft: 0;\n\theight: 3px;\n\twidth: 3px;\n}\n",""]),t.Z=s},42254:function(e,t,i){"use strict";var n=i(8081),o=i.n(n),r=i(23645),s=i.n(r)()(o());s.push([e.id,"/*---------------------------------------------------------------------------------------------\n * Copyright (c) Microsoft Corporation. All rights reserved.\n * Licensed under the MIT License. See License.txt in the project root for license information.\n *--------------------------------------------------------------------------------------------*/\n\n.monaco-split-view2 {\n\tposition: relative;\n\twidth: 100%;\n\theight: 100%;\n}\n\n.monaco-split-view2 > .sash-container {\n\tposition: absolute;\n\twidth: 100%;\n\theight: 100%;\n\tpointer-events: none;\n}\n\n.monaco-split-view2 > .sash-container > .monaco-sash {\n\tpointer-events: initial;\n}\n\n.monaco-split-view2 > .monaco-scrollable-element {\n\twidth: 100%;\n\theight: 100%;\n}\n\n.monaco-split-view2 > .monaco-scrollable-element > .split-view-container {\n\twidth: 100%;\n\theight: 100%;\n\twhite-space: nowrap;\n\tposition: relative;\n}\n\n.monaco-split-view2 > .monaco-scrollable-element > .split-view-container > .split-view-view {\n\twhite-space: initial;\n\tposition: absolute;\n}\n\n.monaco-split-view2 > .monaco-scrollable-element > .split-view-container > .split-view-view:not(.visible) {\n\tdisplay: none;\n}\n\n.monaco-split-view2.vertical > .monaco-scrollable-element > .split-view-container > .split-view-view {\n\twidth: 100%;\n}\n\n.monaco-split-view2.horizontal > .monaco-scrollable-element > .split-view-container > .split-view-view {\n\theight: 100%;\n}\n\n.monaco-split-view2.separator-border > .monaco-scrollable-element > .split-view-container > .split-view-view:not(:first-child)::before {\n\tcontent: ' ';\n\tposition: absolute;\n\ttop: 0;\n\tleft: 0;\n\tz-index: 5;\n\tpointer-events: none;\n\tbackground-color: var(--separator-border);\n}\n\n.monaco-split-view2.separator-border.horizontal > .monaco-scrollable-element > .split-view-container > .split-view-view:not(:first-child)::before {\n\theight: 100%;\n\twidth: 1px;\n}\n\n.monaco-split-view2.separator-border.vertical > .monaco-scrollable-element > .split-view-container > .split-view-view:not(:first-child)::before {\n\theight: 1px;\n\twidth: 100%;\n}\n",""]),t.Z=s},51383:function(e,t,i){"use strict";var n=i(8081),o=i.n(n),r=i(23645),s=i.n(r)()(o());s.push([e.id,'/*---------------------------------------------------------------------------------------------\n * Copyright (c) Microsoft Corporation. All rights reserved.\n * Licensed under the MIT License. See License.txt in the project root for license information.\n *--------------------------------------------------------------------------------------------*/\n\n.monaco-table {\n\tdisplay: flex;\n\tflex-direction: column;\n\tposition: relative;\n\theight: 100%;\n\twidth: 100%;\n\twhite-space: nowrap;\n}\n\n.monaco-table > .monaco-split-view2 {\n\tborder-bottom: 1px solid transparent;\n}\n\n.monaco-table > .monaco-list {\n\tflex: 1;\n}\n\n.monaco-table-tr {\n\tdisplay: flex;\n\theight: 100%;\n}\n\n.monaco-table-th {\n\twidth: 100%;\n\theight: 100%;\n\tfont-weight: bold;\n\toverflow: hidden;\n\ttext-overflow: ellipsis;\n}\n\n.monaco-table-th,\n.monaco-table-td {\n\tbox-sizing: border-box;\n\tflex-shrink: 0;\n\toverflow: hidden;\n\twhite-space: nowrap;\n\ttext-overflow: ellipsis;\n}\n\n.monaco-table > .monaco-split-view2 .monaco-sash.vertical::before {\n\tcontent: "";\n\tposition: absolute;\n\tleft: calc(var(--sash-size) / 2);\n\twidth: 0;\n\tborder-left: 1px solid transparent;\n}\n\n.monaco-table > .monaco-split-view2,\n.monaco-table > .monaco-split-view2 .monaco-sash.vertical::before {\n\ttransition: border-color 0.2s ease-out;\n}\n/*\n.monaco-table:hover > .monaco-split-view2,\n.monaco-table:hover > .monaco-split-view2 .monaco-sash.vertical::before {\n\tborder-color: rgba(204, 204, 204, 0.2);\n} */\n',""]),t.Z=s},4434:function(e,t,i){"use strict";var n=i(8081),o=i.n(n),r=i(23645),s=i.n(r)()(o());s.push([e.id,"/*---------------------------------------------------------------------------------------------\n * Copyright (c) Microsoft Corporation. All rights reserved.\n * Licensed under the MIT License. See License.txt in the project root for license information.\n *--------------------------------------------------------------------------------------------*/\n\n.monaco-tl-row {\n\tdisplay: flex;\n\theight: 100%;\n\talign-items: center;\n\tposition: relative;\n}\n\n.monaco-tl-indent {\n\theight: 100%;\n\tposition: absolute;\n\ttop: 0;\n\tleft: 16px;\n\tpointer-events: none;\n}\n\n.hide-arrows .monaco-tl-indent {\n\tleft: 12px;\n}\n\n.monaco-tl-indent > .indent-guide {\n\tdisplay: inline-block;\n\tbox-sizing: border-box;\n\theight: 100%;\n\tborder-left: 1px solid transparent;\n}\n\n.monaco-tl-indent > .indent-guide {\n\ttransition: border-color 0.1s linear;\n}\n\n.monaco-tl-twistie,\n.monaco-tl-contents {\n\theight: 100%;\n}\n\n.monaco-tl-twistie {\n\tfont-size: 10px;\n\ttext-align: right;\n\tpadding-right: 6px;\n\tflex-shrink: 0;\n\twidth: 16px;\n\tdisplay: flex !important;\n\talign-items: center;\n\tjustify-content: center;\n\ttransform: translateX(3px);\n}\n\n.monaco-tl-contents {\n\tflex: 1;\n\toverflow: hidden;\n}\n\n.monaco-tl-twistie::before {\n\tborder-radius: 20px;\n}\n\n.monaco-tl-twistie.collapsed::before {\n\ttransform: rotate(-90deg);\n}\n\n.monaco-tl-twistie.codicon-tree-item-loading::before {\n\t/* Use steps to throttle FPS to reduce CPU usage */\n\tanimation: codicon-spin 1.25s steps(30) infinite;\n}\n",""]),t.Z=s},61699:function(e,t,i){"use strict";var n=i(8081),o=i.n(n),r=i(23645),s=i.n(r)()(o());s.push([e.id,"/*---------------------------------------------------------------------------------------------\n * Copyright (c) Microsoft Corporation. All rights reserved.\n * Licensed under the MIT License. See License.txt in the project root for license information.\n *--------------------------------------------------------------------------------------------*/\n\n.quick-input-widget {\n\tposition: absolute;\n\twidth: 600px;\n\tz-index: 2000;\n\tpadding: 0 1px 1px 1px;\n\tleft: 50%;\n\tmargin-left: -300px;\n}\n\n.quick-input-titlebar {\n\tdisplay: flex;\n\talign-items: center;\n}\n\n.quick-input-left-action-bar {\n\tdisplay: flex;\n\tmargin-left: 4px;\n\tflex: 1;\n}\n\n.quick-input-title {\n\tpadding: 3px 0px;\n\ttext-align: center;\n\ttext-overflow: ellipsis;\n\toverflow: hidden;\n}\n\n.quick-input-right-action-bar {\n\tdisplay: flex;\n\tmargin-right: 4px;\n\tflex: 1;\n}\n\n.quick-input-right-action-bar > .actions-container {\n\tjustify-content: flex-end;\n}\n\n.quick-input-titlebar .monaco-action-bar .action-label.codicon {\n\tbackground-position: center;\n\tbackground-repeat: no-repeat;\n\tpadding: 2px;\n}\n\n.quick-input-description {\n\tmargin: 6px;\n}\n\n.quick-input-header .quick-input-description {\n\tmargin: 4px 2px;\n}\n\n.quick-input-header {\n\tdisplay: flex;\n\tpadding: 6px 6px 0px 6px;\n\tmargin-bottom: -2px;\n}\n\n.quick-input-widget.hidden-input .quick-input-header {\n\t/* reduce margins and paddings when input box hidden */\n\tpadding: 0;\n\tmargin-bottom: 0;\n}\n\n.quick-input-and-message {\n\tdisplay: flex;\n\tflex-direction: column;\n\tflex-grow: 1;\n\tmin-width: 0;\n\tposition: relative;\n}\n\n.quick-input-check-all {\n\talign-self: center;\n\tmargin: 0;\n}\n\n.quick-input-filter {\n\tflex-grow: 1;\n\tdisplay: flex;\n\tposition: relative;\n}\n\n.quick-input-box {\n\tflex-grow: 1;\n}\n\n.quick-input-widget.show-checkboxes .quick-input-box,\n.quick-input-widget.show-checkboxes .quick-input-message {\n\tmargin-left: 5px;\n}\n\n.quick-input-visible-count {\n\tposition: absolute;\n\tleft: -10000px;\n}\n\n.quick-input-count {\n\talign-self: center;\n\tposition: absolute;\n\tright: 4px;\n\tdisplay: flex;\n\talign-items: center;\n}\n\n.quick-input-count .monaco-count-badge {\n\tvertical-align: middle;\n\tpadding: 2px 4px;\n\tborder-radius: 2px;\n\tmin-height: auto;\n\tline-height: normal;\n}\n\n.quick-input-action {\n\tmargin-left: 6px;\n}\n\n.quick-input-action .monaco-text-button {\n\tfont-size: 11px;\n\tpadding: 0 6px;\n\tdisplay: flex;\n\theight: 27.5px;\n\talign-items: center;\n}\n\n.quick-input-message {\n\tmargin-top: -1px;\n\tpadding: 5px;\n\toverflow-wrap: break-word;\n}\n\n.quick-input-message > .codicon {\n\tmargin: 0 0.2em;\n\tvertical-align: text-bottom;\n}\n\n.quick-input-progress.monaco-progress-container {\n\tposition: relative;\n}\n\n.quick-input-progress.monaco-progress-container,\n.quick-input-progress.monaco-progress-container .progress-bit {\n\theight: 2px;\n}\n\n.quick-input-list {\n\tline-height: 22px;\n\tmargin-top: 6px;\n}\n\n.quick-input-widget.hidden-input .quick-input-list {\n\tmargin-top: 0; /* reduce margins when input box hidden */\n}\n\n.quick-input-list .monaco-list {\n\toverflow: hidden;\n\tmax-height: calc(20 * 22px);\n}\n\n.quick-input-list .quick-input-list-entry {\n\tbox-sizing: border-box;\n\toverflow: hidden;\n\tdisplay: flex;\n\theight: 100%;\n\tpadding: 0 6px;\n}\n\n.quick-input-list .quick-input-list-entry.quick-input-list-separator-border {\n\tborder-top-width: 1px;\n\tborder-top-style: solid;\n}\n\n.quick-input-list .monaco-list-row[data-index=\"0\"] .quick-input-list-entry.quick-input-list-separator-border {\n\tborder-top-style: none;\n}\n\n.quick-input-list .quick-input-list-label {\n\toverflow: hidden;\n\tdisplay: flex;\n\theight: 100%;\n\tflex: 1;\n}\n\n.quick-input-list .quick-input-list-checkbox {\n\talign-self: center;\n\tmargin: 0;\n}\n\n.quick-input-list .quick-input-list-rows {\n\toverflow: hidden;\n\ttext-overflow: ellipsis;\n\tdisplay: flex;\n\tflex-direction: column;\n\theight: 100%;\n\tflex: 1;\n\tmargin-left: 5px;\n}\n\n.quick-input-widget.show-checkboxes .quick-input-list .quick-input-list-rows {\n\tmargin-left: 10px;\n}\n\n.quick-input-widget .quick-input-list .quick-input-list-checkbox {\n\tdisplay: none;\n}\n.quick-input-widget.show-checkboxes .quick-input-list .quick-input-list-checkbox {\n\tdisplay: inline;\n}\n\n.quick-input-list .quick-input-list-rows > .quick-input-list-row {\n\tdisplay: flex;\n\talign-items: center;\n}\n\n.quick-input-list .quick-input-list-rows > .quick-input-list-row .monaco-icon-label,\n.quick-input-list .quick-input-list-rows > .quick-input-list-row .monaco-icon-label .monaco-icon-label-container > .monaco-icon-name-container {\n\tflex: 1; /* make sure the icon label grows within the row */\n}\n\n.quick-input-list .quick-input-list-rows > .quick-input-list-row .codicon[class*='codicon-'] {\n\tvertical-align: text-bottom;\n}\n\n.quick-input-list .quick-input-list-rows .monaco-highlighted-label span {\n\topacity: 1;\n}\n\n.quick-input-list .quick-input-list-entry .quick-input-list-entry-keybinding {\n\tmargin-right: 8px; /* separate from the separator label or scrollbar if any */\n}\n\n.quick-input-list .quick-input-list-label-meta {\n\topacity: 0.7;\n\tline-height: normal;\n\ttext-overflow: ellipsis;\n\toverflow: hidden;\n}\n\n.quick-input-list .monaco-highlighted-label .highlight {\n\tfont-weight: bold;\n}\n\n.quick-input-list .quick-input-list-entry .quick-input-list-separator {\n\tmargin-right: 8px; /* separate from keybindings or actions */\n}\n\n.quick-input-list .quick-input-list-entry-action-bar {\n\tdisplay: flex;\n\tflex: 0;\n\toverflow: visible;\n}\n\n.quick-input-list .quick-input-list-entry-action-bar .action-label {\n\t/*\n\t * By default, actions in the quick input action bar are hidden\n\t * until hovered over them or selected.\n\t */\n\tdisplay: none;\n}\n\n.quick-input-list .quick-input-list-entry-action-bar .action-label.codicon {\n\tmargin-right: 4px;\n\tpadding: 0px 2px 2px 2px;\n}\n\n.quick-input-list .quick-input-list-entry-action-bar {\n\tmargin-top: 1px;\n}\n\n.quick-input-list .quick-input-list-entry-action-bar {\n\tmargin-right: 4px; /* separate from scrollbar */\n}\n\n.quick-input-list .quick-input-list-entry .quick-input-list-entry-action-bar .action-label.always-visible,\n.quick-input-list .quick-input-list-entry:hover .quick-input-list-entry-action-bar .action-label,\n.quick-input-list .monaco-list-row.focused .quick-input-list-entry-action-bar .action-label {\n\tdisplay: flex;\n}\n\n/* focused items in quick pick */\n.quick-input-list .monaco-list-row.focused .monaco-keybinding-key,\n.quick-input-list .monaco-list-row.focused .quick-input-list-entry .quick-input-list-separator {\n\tcolor: inherit\n}\n.quick-input-list .monaco-list-row.focused .monaco-keybinding-key {\n\tbackground: none;\n}\n",""]),t.Z=s},58767:function(e,t,i){"use strict";var n=i(8081),o=i.n(n),r=i(23645),s=i.n(r)()(o());s.push([e.id,"/*---------------------------------------------------------------------------------------------\n * Copyright (c) Microsoft Corporation. All rights reserved.\n * Licensed under the MIT License. See License.txt in the project root for license information.\n *--------------------------------------------------------------------------------------------*/\n\n.monaco-editor .inputarea {\n\tmin-width: 0;\n\tmin-height: 0;\n\tmargin: 0;\n\tpadding: 0;\n\tposition: absolute;\n\toutline: none !important;\n\tresize: none;\n\tborder: none;\n\toverflow: hidden;\n\tcolor: transparent;\n\tbackground-color: transparent;\n}\n/*.monaco-editor .inputarea {\n\tposition: fixed !important;\n\twidth: 800px !important;\n\theight: 500px !important;\n\ttop: initial !important;\n\tleft: initial !important;\n\tbottom: 0 !important;\n\tright: 0 !important;\n\tcolor: black !important;\n\tbackground: white !important;\n\tline-height: 15px !important;\n\tfont-size: 14px !important;\n}*/\n.monaco-editor .inputarea.ime-input {\n\tz-index: 10;\n}\n",""]),t.Z=s},77884:function(e,t,i){"use strict";var n=i(8081),o=i.n(n),r=i(23645),s=i.n(r)()(o());s.push([e.id,"/*---------------------------------------------------------------------------------------------\n * Copyright (c) Microsoft Corporation. All rights reserved.\n * Licensed under the MIT License. See License.txt in the project root for license information.\n *--------------------------------------------------------------------------------------------*/\n\n.monaco-editor .view-overlays .current-line {\n\tdisplay: block;\n\tposition: absolute;\n\tleft: 0;\n\ttop: 0;\n\tbox-sizing: border-box;\n}\n\n.monaco-editor .margin-view-overlays .current-line {\n\tdisplay: block;\n\tposition: absolute;\n\tleft: 0;\n\ttop: 0;\n\tbox-sizing: border-box;\n}\n\n.monaco-editor .margin-view-overlays .current-line.current-line-margin.current-line-margin-both {\n\tborder-right: 0;\n}\n",""]),t.Z=s},10408:function(e,t,i){"use strict";var n=i(8081),o=i.n(n),r=i(23645),s=i.n(r)()(o());s.push([e.id,"/*---------------------------------------------------------------------------------------------\n * Copyright (c) Microsoft Corporation. All rights reserved.\n * Licensed under the MIT License. See License.txt in the project root for license information.\n *--------------------------------------------------------------------------------------------*/\n\n/*\n\tKeeping name short for faster parsing.\n\tcdr = core decorations rendering (div)\n*/\n.monaco-editor .lines-content .cdr {\n\tposition: absolute;\n}",""]),t.Z=s},91745:function(e,t,i){"use strict";var n=i(8081),o=i.n(n),r=i(23645),s=i.n(r)()(o());s.push([e.id,"/*---------------------------------------------------------------------------------------------\n * Copyright (c) Microsoft Corporation. All rights reserved.\n * Licensed under the MIT License. See License.txt in the project root for license information.\n *--------------------------------------------------------------------------------------------*/\n\n.monaco-editor .glyph-margin {\n\tposition: absolute;\n\ttop: 0;\n}\n\n/*\n\tKeeping name short for faster parsing.\n\tcgmr = core glyph margin rendering (div)\n*/\n.monaco-editor .margin-view-overlays .cgmr {\n\tposition: absolute;\n\tdisplay: flex;\n\talign-items: center;\n\tjustify-content: center;\n}\n",""]),t.Z=s},4088:function(e,t,i){"use strict";var n=i(8081),o=i.n(n),r=i(23645),s=i.n(r)()(o());s.push([e.id,"/*---------------------------------------------------------------------------------------------\n * Copyright (c) Microsoft Corporation. All rights reserved.\n * Licensed under the MIT License. See License.txt in the project root for license information.\n *--------------------------------------------------------------------------------------------*/\n\n.monaco-editor .lines-content .core-guide {\n\tposition: absolute;\n\tbox-sizing: border-box;\n}\n",""]),t.Z=s},20013:function(e,t,i){"use strict";var n=i(8081),o=i.n(n),r=i(23645),s=i.n(r)()(o());s.push([e.id,"/*---------------------------------------------------------------------------------------------\n * Copyright (c) Microsoft Corporation. All rights reserved.\n * Licensed under the MIT License. See License.txt in the project root for license information.\n *--------------------------------------------------------------------------------------------*/\n\n.monaco-editor .margin-view-overlays .line-numbers {\n\tfont-variant-numeric: tabular-nums;\n\tposition: absolute;\n\ttext-align: right;\n\tdisplay: inline-block;\n\tvertical-align: middle;\n\tbox-sizing: border-box;\n\tcursor: default;\n\theight: 100%;\n}\n\n.monaco-editor .relative-current-line-number {\n\ttext-align: left;\n\tdisplay: inline-block;\n\twidth: 100%;\n}\n\n.monaco-editor .margin-view-overlays .line-numbers.lh-odd {\n\tmargin-top: 1px;\n}\n",""]),t.Z=s},14076:function(e,t,i){"use strict";var n=i(8081),o=i.n(n),r=i(23645),s=i.n(r)()(o());s.push([e.id,"/*---------------------------------------------------------------------------------------------\n * Copyright (c) Microsoft Corporation. All rights reserved.\n * Licensed under the MIT License. See License.txt in the project root for license information.\n *--------------------------------------------------------------------------------------------*/\n.monaco-editor .lines-decorations {\n\tposition: absolute;\n\ttop: 0;\n\tbackground: white;\n}\n\n/*\n\tKeeping name short for faster parsing.\n\tcldr = core lines decorations rendering (div)\n*/\n.monaco-editor .margin-view-overlays .cldr {\n\tposition: absolute;\n\theight: 100%;\n}",""]),t.Z=s},75354:function(e,t,i){"use strict";var n=i(8081),o=i.n(n),r=i(23645),s=i.n(r)()(o());s.push([e.id,"/*---------------------------------------------------------------------------------------------\n * Copyright (c) Microsoft Corporation. All rights reserved.\n * Licensed under the MIT License. See License.txt in the project root for license information.\n *--------------------------------------------------------------------------------------------*/\n\n/* Uncomment to see lines flashing when they're painted */\n/*.monaco-editor .view-lines > .view-line {\n\tbackground-color: none;\n\tanimation-name: flash-background;\n\tanimation-duration: 800ms;\n}\n@keyframes flash-background {\n\t0% { background-color: lightgreen; }\n\t100% { background-color: none }\n}*/\n\n.mtkcontrol {\n\tcolor: rgb(255, 255, 255) !important;\n\tbackground: rgb(150, 0, 0) !important;\n}\n\n.monaco-editor.no-user-select .lines-content,\n.monaco-editor.no-user-select .view-line,\n.monaco-editor.no-user-select .view-lines {\n\tuser-select: none;\n\t-webkit-user-select: none;\n\t-ms-user-select: none;\n}\n\n.monaco-editor .view-lines {\n\twhite-space: nowrap;\n}\n\n.monaco-editor .view-line {\n\tposition: absolute;\n\twidth: 100%;\n}\n\n.monaco-editor .mtkz {\n\tdisplay: inline-block;\n}\n\n/* TODO@tokenization bootstrap fix */\n/*.monaco-editor .view-line > span > span {\n\tfloat: none;\n\tmin-height: inherit;\n\tmargin-left: inherit;\n}*/\n",""]),t.Z=s},87690:function(e,t,i){"use strict";var n=i(8081),o=i.n(n),r=i(23645),s=i.n(r)()(o());s.push([e.id,"/*---------------------------------------------------------------------------------------------\n * Copyright (c) Microsoft Corporation. All rights reserved.\n * Licensed under the MIT License. See License.txt in the project root for license information.\n *--------------------------------------------------------------------------------------------*/\n\n/*\n\tKeeping name short for faster parsing.\n\tcmdr = core margin decorations rendering (div)\n*/\n.monaco-editor .margin-view-overlays .cmdr {\n\tposition: absolute;\n\tleft: 0;\n\twidth: 100%;\n\theight: 100%;\n}",""]),t.Z=s},78846:function(e,t,i){"use strict";var n=i(8081),o=i.n(n),r=i(23645),s=i.n(r)()(o());s.push([e.id,"/*---------------------------------------------------------------------------------------------\n * Copyright (c) Microsoft Corporation. All rights reserved.\n * Licensed under the MIT License. See License.txt in the project root for license information.\n *--------------------------------------------------------------------------------------------*/\n\n/* START cover the case that slider is visible on mouseover */\n.monaco-editor .minimap.slider-mouseover .minimap-slider {\n\topacity: 0;\n\ttransition: opacity 100ms linear;\n}\n.monaco-editor .minimap.slider-mouseover:hover .minimap-slider {\n\topacity: 1;\n}\n.monaco-editor .minimap.slider-mouseover .minimap-slider.active {\n\topacity: 1;\n}\n/* END cover the case that slider is visible on mouseover */\n\n.monaco-editor .minimap-shadow-hidden {\n\tposition: absolute;\n\twidth: 0;\n}\n.monaco-editor .minimap-shadow-visible {\n\tposition: absolute;\n\tleft: -6px;\n\twidth: 6px;\n}\n.monaco-editor.no-minimap-shadow .minimap-shadow-visible {\n\tposition: absolute;\n\tleft: -1px;\n\twidth: 1px;\n}\n",""]),t.Z=s},32083:function(e,t,i){"use strict";var n=i(8081),o=i.n(n),r=i(23645),s=i.n(r)()(o());s.push([e.id,"/*---------------------------------------------------------------------------------------------\n * Copyright (c) Microsoft Corporation. All rights reserved.\n * Licensed under the MIT License. See License.txt in the project root for license information.\n *--------------------------------------------------------------------------------------------*/\n.monaco-editor .overlayWidgets {\n\tposition: absolute;\n\ttop: 0;\n\tleft:0;\n}",""]),t.Z=s},66945:function(e,t,i){"use strict";var n=i(8081),o=i.n(n),r=i(23645),s=i.n(r)()(o());s.push([e.id,"/*---------------------------------------------------------------------------------------------\n * Copyright (c) Microsoft Corporation. All rights reserved.\n * Licensed under the MIT License. See License.txt in the project root for license information.\n *--------------------------------------------------------------------------------------------*/\n\n.monaco-editor .view-ruler {\n\tposition: absolute;\n\ttop: 0;\n}",""]),t.Z=s},50297:function(e,t,i){"use strict";var n=i(8081),o=i.n(n),r=i(23645),s=i.n(r)()(o());s.push([e.id,"/*---------------------------------------------------------------------------------------------\n * Copyright (c) Microsoft Corporation. All rights reserved.\n * Licensed under the MIT License. See License.txt in the project root for license information.\n *--------------------------------------------------------------------------------------------*/\n\n.monaco-editor .scroll-decoration {\n\tposition: absolute;\n\ttop: 0;\n\tleft: 0;\n\theight: 6px;\n}",""]),t.Z=s},91618:function(e,t,i){"use strict";var n=i(8081),o=i.n(n),r=i(23645),s=i.n(r)()(o());s.push([e.id,"/*---------------------------------------------------------------------------------------------\n * Copyright (c) Microsoft Corporation. All rights reserved.\n * Licensed under the MIT License. See License.txt in the project root for license information.\n *--------------------------------------------------------------------------------------------*/\n\n/*\n\tKeeping name short for faster parsing.\n\tcslr = core selections layer rendering (div)\n*/\n.monaco-editor .lines-content .cslr {\n\tposition: absolute;\n}\n\n.monaco-editor\t\t\t.top-left-radius\t\t{ border-top-left-radius: 3px; }\n.monaco-editor\t\t\t.bottom-left-radius\t\t{ border-bottom-left-radius: 3px; }\n.monaco-editor\t\t\t.top-right-radius\t\t{ border-top-right-radius: 3px; }\n.monaco-editor\t\t\t.bottom-right-radius\t{ border-bottom-right-radius: 3px; }\n\n.monaco-editor.hc-black .top-left-radius\t\t{ border-top-left-radius: 0; }\n.monaco-editor.hc-black .bottom-left-radius\t\t{ border-bottom-left-radius: 0; }\n.monaco-editor.hc-black .top-right-radius\t\t{ border-top-right-radius: 0; }\n.monaco-editor.hc-black .bottom-right-radius\t{ border-bottom-right-radius: 0; }\n",""]),t.Z=s},29038:function(e,t,i){"use strict";var n=i(8081),o=i.n(n),r=i(23645),s=i.n(r)()(o());s.push([e.id,"/*---------------------------------------------------------------------------------------------\n * Copyright (c) Microsoft Corporation. All rights reserved.\n * Licensed under the MIT License. See License.txt in the project root for license information.\n *--------------------------------------------------------------------------------------------*/\n.monaco-editor .cursors-layer {\n\tposition: absolute;\n\ttop: 0;\n}\n\n.monaco-editor .cursors-layer > .cursor {\n\tposition: absolute;\n\toverflow: hidden;\n}\n\n/* -- smooth-caret-animation -- */\n.monaco-editor .cursors-layer.cursor-smooth-caret-animation > .cursor {\n\ttransition: all 80ms;\n}\n\n/* -- block-outline-style -- */\n.monaco-editor .cursors-layer.cursor-block-outline-style > .cursor {\n\tbox-sizing: border-box;\n\tbackground: transparent !important;\n\tborder-style: solid;\n\tborder-width: 1px;\n}\n\n/* -- underline-style -- */\n.monaco-editor .cursors-layer.cursor-underline-style > .cursor {\n\tborder-bottom-width: 2px;\n\tborder-bottom-style: solid;\n\tbackground: transparent !important;\n\tbox-sizing: border-box;\n}\n\n/* -- underline-thin-style -- */\n.monaco-editor .cursors-layer.cursor-underline-thin-style > .cursor {\n\tborder-bottom-width: 1px;\n\tborder-bottom-style: solid;\n\tbackground: transparent !important;\n\tbox-sizing: border-box;\n}\n\n@keyframes monaco-cursor-smooth {\n\t0%,\n\t20% {\n\t\topacity: 1;\n\t}\n\t60%,\n\t100% {\n\t\topacity: 0;\n\t}\n}\n\n@keyframes monaco-cursor-phase {\n\t0%,\n\t20% {\n\t\topacity: 1;\n\t}\n\t90%,\n\t100% {\n\t\topacity: 0;\n\t}\n}\n\n@keyframes monaco-cursor-expand {\n\t0%,\n\t20% {\n\t\ttransform: scaleY(1);\n\t}\n\t80%,\n\t100% {\n\t\ttransform: scaleY(0);\n\t}\n}\n\n.cursor-smooth {\n\tanimation: monaco-cursor-smooth 0.5s ease-in-out 0s 20 alternate;\n}\n\n.cursor-phase {\n\tanimation: monaco-cursor-phase 0.5s ease-in-out 0s 20 alternate;\n}\n\n.cursor-expand > .cursor {\n\tanimation: monaco-cursor-expand 0.5s ease-in-out 0s 20 alternate;\n}\n",""]),t.Z=s},67093:function(e,t,i){"use strict";var n=i(8081),o=i.n(n),r=i(23645),s=i.n(r)()(o());s.push([e.id,"/*---------------------------------------------------------------------------------------------\n * Copyright (c) Microsoft Corporation. All rights reserved.\n * Licensed under the MIT License. See License.txt in the project root for license information.\n *--------------------------------------------------------------------------------------------*/\n/* ---------- DiffEditor ---------- */\n\n.monaco-diff-editor .diffOverview {\n\tz-index: 9;\n}\n\n.monaco-diff-editor .diffOverview .diffViewport {\n\tz-index: 10;\n}\n\n/* colors not externalized: using transparancy on background */\n.monaco-diff-editor.vs\t\t\t.diffOverview { background: rgba(0, 0, 0, 0.03); }\n.monaco-diff-editor.vs-dark\t\t.diffOverview { background: rgba(255, 255, 255, 0.01); }\n\n.monaco-scrollable-element.modified-in-monaco-diff-editor.vs\t\t.scrollbar { background: rgba(0,0,0,0); }\n.monaco-scrollable-element.modified-in-monaco-diff-editor.vs-dark\t.scrollbar { background: rgba(0,0,0,0); }\n.monaco-scrollable-element.modified-in-monaco-diff-editor.hc-black\t.scrollbar { background: none; }\n\n.monaco-scrollable-element.modified-in-monaco-diff-editor .slider {\n\tz-index: 10;\n}\n.modified-in-monaco-diff-editor\t\t\t\t.slider.active { background: rgba(171, 171, 171, .4); }\n.modified-in-monaco-diff-editor.hc-black\t.slider.active { background: none; }\n\n/* ---------- Diff ---------- */\n\n.monaco-editor .insert-sign,\n.monaco-diff-editor .insert-sign,\n.monaco-editor .delete-sign,\n.monaco-diff-editor .delete-sign {\n\tfont-size: 11px !important;\n\topacity: 0.7 !important;\n\tdisplay: flex !important;\n\talign-items: center;\n}\n.monaco-editor.hc-black .insert-sign,\n.monaco-diff-editor.hc-black .insert-sign,\n.monaco-editor.hc-black .delete-sign,\n.monaco-diff-editor.hc-black .delete-sign {\n\topacity: 1;\n}\n\n.monaco-editor .inline-deleted-margin-view-zone {\n\ttext-align: right;\n}\n.monaco-editor .inline-added-margin-view-zone {\n\ttext-align: right;\n}\n\n/* ---------- Inline Diff ---------- */\n\n.monaco-editor .view-zones .view-lines .view-line span {\n\tdisplay: inline-block;\n}\n\n.monaco-editor .margin-view-zones .lightbulb-glyph:hover {\n\tcursor: pointer;\n}\n",""]),t.Z=s},5899:function(e,t,i){"use strict";var n=i(8081),o=i.n(n),r=i(23645),s=i.n(r)()(o());s.push([e.id,"/*---------------------------------------------------------------------------------------------\n * Copyright (c) Microsoft Corporation. All rights reserved.\n * Licensed under the MIT License. See License.txt in the project root for license information.\n *--------------------------------------------------------------------------------------------*/\n\n.monaco-diff-editor .diff-review-line-number {\n\ttext-align: right;\n\tdisplay: inline-block;\n}\n\n.monaco-diff-editor .diff-review {\n\tposition: absolute;\n\tuser-select: none;\n\t-webkit-user-select: none;\n\t-ms-user-select: none;\n}\n\n.monaco-diff-editor .diff-review-summary {\n\tpadding-left: 10px;\n}\n\n.monaco-diff-editor .diff-review-shadow {\n\tposition: absolute;\n}\n\n.monaco-diff-editor .diff-review-row {\n\twhite-space: pre;\n}\n\n.monaco-diff-editor .diff-review-table {\n\tdisplay: table;\n\tmin-width: 100%;\n}\n\n.monaco-diff-editor .diff-review-row {\n\tdisplay: table-row;\n\twidth: 100%;\n}\n\n.monaco-diff-editor .diff-review-spacer {\n\tdisplay: inline-block;\n\twidth: 10px;\n\tvertical-align: middle;\n}\n\n.monaco-diff-editor .diff-review-spacer > .codicon {\n\tfont-size: 9px !important;\n}\n\n.monaco-diff-editor .diff-review-actions {\n\tdisplay: inline-block;\n\tposition: absolute;\n\tright: 10px;\n\ttop: 2px;\n}\n\n.monaco-diff-editor .diff-review-actions .action-label {\n\twidth: 16px;\n\theight: 16px;\n\tmargin: 2px 0;\n}\n",""]),t.Z=s},6698:function(e,t,i){"use strict";var n=i(8081),o=i.n(n),r=i(23645),s=i.n(r)()(o());s.push([e.id,"/*---------------------------------------------------------------------------------------------\n * Copyright (c) Microsoft Corporation. All rights reserved.\n * Licensed under the MIT License. See License.txt in the project root for license information.\n *--------------------------------------------------------------------------------------------*/\n\n/* -------------------- IE10 remove auto clear button -------------------- */\n\n::-ms-clear {\n\tdisplay: none;\n}\n\n/* All widgets */\n/* I am not a big fan of this rule */\n.monaco-editor .editor-widget input {\n\tcolor: inherit;\n}\n\n/* -------------------- Editor -------------------- */\n\n.monaco-editor {\n\tposition: relative;\n\toverflow: visible;\n\t-webkit-text-size-adjust: 100%;\n}\n\n/* -------------------- Misc -------------------- */\n\n.monaco-editor .overflow-guard {\n\tposition: relative;\n\toverflow: hidden;\n}\n\n.monaco-editor .view-overlays {\n\tposition: absolute;\n\ttop: 0;\n}\n\n/*\n.monaco-editor .auto-closed-character {\n\topacity: 0.3;\n}\n*/\n",""]),t.Z=s},21674:function(e,t,i){"use strict";var n=i(8081),o=i.n(n),r=i(23645),s=i.n(r)()(o());s.push([e.id,"/*---------------------------------------------------------------------------------------------\n * Copyright (c) Microsoft Corporation. All rights reserved.\n * Licensed under the MIT License. See License.txt in the project root for license information.\n *--------------------------------------------------------------------------------------------*/\n\n.monaco-editor .selection-anchor {\n\tbackground-color: #007ACC;\n\twidth: 2px !important;\n}\n",""]),t.Z=s},86777:function(e,t,i){"use strict";var n=i(8081),o=i.n(n),r=i(23645),s=i.n(r)()(o());s.push([e.id,"/*---------------------------------------------------------------------------------------------\n * Copyright (c) Microsoft Corporation. All rights reserved.\n * Licensed under the MIT License. See License.txt in the project root for license information.\n *--------------------------------------------------------------------------------------------*/\n\n.monaco-editor .bracket-match {\n\tbox-sizing: border-box;\n}\n",""]),t.Z=s},70825:function(e,t,i){"use strict";var n=i(8081),o=i.n(n),r=i(23645),s=i.n(r)()(o());s.push([e.id,"/*---------------------------------------------------------------------------------------------\n * Copyright (c) Microsoft Corporation. All rights reserved.\n * Licensed under the MIT License. See License.txt in the project root for license information.\n *--------------------------------------------------------------------------------------------*/\n\n.monaco-editor .contentWidgets .codicon-light-bulb,\n.monaco-editor .contentWidgets .codicon-lightbulb-autofix {\n\tdisplay: flex;\n\talign-items: center;\n\tjustify-content: center;\n}\n\n.monaco-editor .contentWidgets .codicon-light-bulb:hover,\n.monaco-editor .contentWidgets .codicon-lightbulb-autofix:hover {\n\tcursor: pointer;\n}\n",""]),t.Z=s},66064:function(e,t,i){"use strict";var n=i(8081),o=i.n(n),r=i(23645),s=i.n(r)()(o());s.push([e.id,"/*---------------------------------------------------------------------------------------------\n * Copyright (c) Microsoft Corporation. All rights reserved.\n * Licensed under the MIT License. See License.txt in the project root for license information.\n *--------------------------------------------------------------------------------------------*/\n\n.monaco-editor .codelens-decoration {\n\toverflow: hidden;\n\tdisplay: inline-block;\n\ttext-overflow: ellipsis;\n\twhite-space: nowrap;\n\tcolor: var(--vscode-editorCodeLens-foreground)\n}\n\n.monaco-editor .codelens-decoration > span,\n.monaco-editor .codelens-decoration > a {\n\tuser-select: none;\n\t-webkit-user-select: none;\n\t-ms-user-select: none;\n\twhite-space: nowrap;\n\tvertical-align: sub;\n}\n\n.monaco-editor .codelens-decoration > a {\n\ttext-decoration: none;\n}\n\n.monaco-editor .codelens-decoration > a:hover {\n\tcursor: pointer;\n\tcolor: var(--vscode-editorLink-activeForeground) !important;\n}\n\n.monaco-editor .codelens-decoration > a:hover .codicon {\n\tcolor: var(--vscode-editorLink-activeForeground) !important;\n}\n\n.monaco-editor .codelens-decoration .codicon {\n\tvertical-align: middle;\n\tcolor: currentColor !important;\n\tcolor: var(--vscode-editorCodeLens-foreground);\n}\n\n.monaco-editor .codelens-decoration > a:hover .codicon::before {\n\tcursor: pointer;\n}\n\n@keyframes fadein {\n\t0% { opacity: 0; visibility: visible;}\n\t100% { opacity: 1; }\n}\n\n.monaco-editor .codelens-decoration.fadein {\n\tanimation: fadein 0.1s linear;\n}\n",""]),t.Z=s},59033:function(e,t,i){"use strict";var n=i(8081),o=i.n(n),r=i(23645),s=i.n(r),a=i(61667),l=i.n(a),c=new URL(i(94748),i.b),d=s()(o()),u=l()(c);d.push([e.id,"/*---------------------------------------------------------------------------------------------\n * Copyright (c) Microsoft Corporation. All rights reserved.\n * Licensed under the MIT License. See License.txt in the project root for license information.\n *--------------------------------------------------------------------------------------------*/\n\n.colorpicker-widget {\n\theight: 190px;\n\tuser-select: none;\n\t-webkit-user-select: none;\n\t-ms-user-select: none;\n}\n\n/* Decoration */\n\n.colorpicker-color-decoration {\n\tborder: solid 0.1em #000;\n\tbox-sizing: border-box;\n\tmargin: 0.1em 0.2em 0 0.2em;\n\twidth: 0.8em;\n\theight: 0.8em;\n\tline-height: 0.8em;\n\tdisplay: inline-block;\n\tcursor: pointer;\n}\n\n.hc-black .colorpicker-color-decoration,\n.vs-dark .colorpicker-color-decoration {\n\tborder: solid 0.1em #eee;\n}\n\n/* Header */\n\n.colorpicker-header {\n\tdisplay: flex;\n\theight: 24px;\n\tposition: relative;\n\tbackground: url("+u+");\n\tbackground-size: 9px 9px;\n\timage-rendering: pixelated;\n}\n\n.colorpicker-header .picked-color {\n\twidth: 216px;\n\tdisplay: flex;\n\talign-items: center;\n\tjustify-content: center;\n\tline-height: 24px;\n\tcursor: pointer;\n\tcolor: white;\n\tflex: 1;\n}\n\n.colorpicker-header .picked-color .codicon {\n\tcolor: inherit;\n\tfont-size: 14px;\n\tposition: absolute;\n\tleft: 8px;\n}\n\n.colorpicker-header .picked-color.light {\n\tcolor: black;\n}\n\n.colorpicker-header .original-color {\n\twidth: 74px;\n\tz-index: inherit;\n\tcursor: pointer;\n}\n\n\n/* Body */\n\n.colorpicker-body {\n\tdisplay: flex;\n\tpadding: 8px;\n\tposition: relative;\n}\n\n.colorpicker-body .saturation-wrap {\n\toverflow: hidden;\n\theight: 150px;\n\tposition: relative;\n\tmin-width: 220px;\n\tflex: 1;\n}\n\n.colorpicker-body .saturation-box {\n\theight: 150px;\n\tposition: absolute;\n}\n\n.colorpicker-body .saturation-selection {\n\twidth: 9px;\n\theight: 9px;\n\tmargin: -5px 0 0 -5px;\n\tborder: 1px solid rgb(255, 255, 255);\n\tborder-radius: 100%;\n\tbox-shadow: 0px 0px 2px rgba(0, 0, 0, 0.8);\n\tposition: absolute;\n}\n\n.colorpicker-body .strip {\n\twidth: 25px;\n\theight: 150px;\n}\n\n.colorpicker-body .hue-strip {\n\tposition: relative;\n\tmargin-left: 8px;\n\tcursor: grab;\n\tbackground: linear-gradient(to bottom, #ff0000 0%, #ffff00 17%, #00ff00 33%, #00ffff 50%, #0000ff 67%, #ff00ff 83%, #ff0000 100%);\n}\n\n.colorpicker-body .opacity-strip {\n\tposition: relative;\n\tmargin-left: 8px;\n\tcursor: grab;\n\tbackground: url("+u+");\n\tbackground-size: 9px 9px;\n\timage-rendering: pixelated;\n}\n\n.colorpicker-body .strip.grabbing {\n\tcursor: grabbing;\n}\n\n.colorpicker-body .slider {\n\tposition: absolute;\n\ttop: 0;\n\tleft: -2px;\n\twidth: calc(100% + 4px);\n\theight: 4px;\n\tbox-sizing: border-box;\n\tborder: 1px solid rgba(255, 255, 255, 0.71);\n\tbox-shadow: 0px 0px 1px rgba(0, 0, 0, 0.85);\n}\n\n.colorpicker-body .strip .overlay {\n\theight: 150px;\n\tpointer-events: none;\n}\n",""]),t.Z=d},71525:function(e,t,i){"use strict";var n=i(8081),o=i.n(n),r=i(23645),s=i.n(r)()(o());s.push([e.id,"/*---------------------------------------------------------------------------------------------\n * Copyright (c) Microsoft Corporation. All rights reserved.\n * Licensed under the MIT License. See License.txt in the project root for license information.\n *--------------------------------------------------------------------------------------------*/\n\n.monaco-editor.vs .dnd-target {\n\tborder-right: 2px dotted black;\n\tcolor: white; /* opposite of black */\n}\n.monaco-editor.vs-dark .dnd-target {\n\tborder-right: 2px dotted #AEAFAD;\n\tcolor: #51504f; /* opposite of #AEAFAD */\n}\n.monaco-editor.hc-black .dnd-target {\n\tborder-right: 2px dotted #fff;\n\tcolor: #000; /* opposite of #fff */\n}\n\n.monaco-editor.mouse-default .view-lines,\n.monaco-editor.vs-dark.mac.mouse-default .view-lines,\n.monaco-editor.hc-black.mac.mouse-default .view-lines {\n\tcursor: default;\n}\n.monaco-editor.mouse-copy .view-lines,\n.monaco-editor.vs-dark.mac.mouse-copy .view-lines,\n.monaco-editor.hc-black.mac.mouse-copy .view-lines {\n\tcursor: copy;\n}",""]),t.Z=s},99096:function(e,t,i){"use strict";var n=i(8081),o=i.n(n),r=i(23645),s=i.n(r)()(o());s.push([e.id,"/*---------------------------------------------------------------------------------------------\n * Copyright (c) Microsoft Corporation. All rights reserved.\n * Licensed under the MIT License. See License.txt in the project root for license information.\n *--------------------------------------------------------------------------------------------*/\n\n/* Find widget */\n.monaco-editor .find-widget {\n\tposition: absolute;\n\tz-index: 35;\n\theight: 33px;\n\toverflow: hidden;\n\tline-height: 19px;\n\ttransition: transform 200ms linear;\n\tpadding: 0 4px;\n\tbox-sizing: border-box;\n\ttransform: translateY(calc(-100% - 10px)); /* shadow (10px) */\n}\n\n.monaco-editor .find-widget textarea {\n\tmargin: 0px;\n}\n\n.monaco-editor .find-widget.hiddenEditor {\n\tdisplay: none;\n}\n\n/* Find widget when replace is toggled on */\n.monaco-editor .find-widget.replaceToggled > .replace-part {\n\tdisplay: flex;\n}\n\n.monaco-editor .find-widget.visible {\n\ttransform: translateY(0);\n}\n\n.monaco-editor .find-widget .monaco-inputbox.synthetic-focus {\n\toutline: 1px solid -webkit-focus-ring-color;\n\toutline-offset: -1px;\n}\n\n.monaco-editor .find-widget .monaco-inputbox .input {\n\tbackground-color: transparent;\n\tmin-height: 0;\n}\n\n.monaco-editor .find-widget .monaco-findInput .input {\n\tfont-size: 13px;\n}\n\n.monaco-editor .find-widget > .find-part,\n.monaco-editor .find-widget > .replace-part {\n\tmargin: 4px 0 0 17px;\n\tfont-size: 12px;\n\tdisplay: flex;\n}\n\n.monaco-editor .find-widget > .find-part .monaco-inputbox,\n.monaco-editor .find-widget > .replace-part .monaco-inputbox {\n\tmin-height: 25px;\n}\n\n\n.monaco-editor .find-widget > .replace-part .monaco-inputbox > .ibwrapper > .mirror {\n\tpadding-right: 22px;\n}\n\n.monaco-editor .find-widget > .find-part .monaco-inputbox > .ibwrapper > .input,\n.monaco-editor .find-widget > .find-part .monaco-inputbox > .ibwrapper > .mirror,\n.monaco-editor .find-widget > .replace-part .monaco-inputbox > .ibwrapper > .input,\n.monaco-editor .find-widget > .replace-part .monaco-inputbox > .ibwrapper > .mirror {\n\tpadding-top: 2px;\n\tpadding-bottom: 2px;\n}\n\n.monaco-editor .find-widget > .find-part .find-actions {\n\theight: 25px;\n\tdisplay: flex;\n\talign-items: center;\n}\n\n.monaco-editor .find-widget > .replace-part .replace-actions {\n\theight: 25px;\n\tdisplay: flex;\n\talign-items: center;\n}\n\n.monaco-editor .find-widget .monaco-findInput {\n\tvertical-align: middle;\n\tdisplay: flex;\n\tflex:1;\n}\n\n.monaco-editor .find-widget .monaco-findInput .monaco-scrollable-element {\n\t/* Make sure textarea inherits the width correctly */\n\twidth: 100%;\n}\n\n.monaco-editor .find-widget .monaco-findInput .monaco-scrollable-element .scrollbar.vertical {\n\t/* Hide vertical scrollbar */\n\topacity: 0;\n}\n\n.monaco-editor .find-widget .matchesCount {\n\tdisplay: flex;\n\tflex: initial;\n\tmargin: 0 0 0 3px;\n\tpadding: 2px 0 0 2px;\n\theight: 25px;\n\tvertical-align: middle;\n\tbox-sizing: border-box;\n\ttext-align: center;\n\tline-height: 23px;\n}\n\n.monaco-editor .find-widget .button {\n\twidth: 16px;\n\theight: 16px;\n\tpadding: 3px;\n\tborder-radius: 5px;\n\tdisplay: flex;\n\tflex: initial;\n\tmargin-left: 3px;\n\tbackground-position: center center;\n\tbackground-repeat: no-repeat;\n\tcursor: pointer;\n\tdisplay: flex;\n\talign-items: center;\n\tjustify-content: center;\n}\n\n/* find in selection button */\n.monaco-editor .find-widget .codicon-find-selection {\n\twidth: 22px;\n\theight: 22px;\n\tpadding: 3px;\n\tborder-radius: 5px;\n}\n\n.monaco-editor .find-widget .button.left {\n\tmargin-left: 0;\n\tmargin-right: 3px;\n}\n\n.monaco-editor .find-widget .button.wide {\n\twidth: auto;\n\tpadding: 1px 6px;\n\ttop: -1px;\n}\n\n.monaco-editor .find-widget .button.toggle {\n\tposition: absolute;\n\ttop: 0;\n\tleft: 3px;\n\twidth: 18px;\n\theight: 100%;\n\tborder-radius: 0;\n\tbox-sizing: border-box;\n}\n\n.monaco-editor .find-widget .button.toggle.disabled {\n\tdisplay: none;\n}\n\n.monaco-editor .find-widget .disabled {\n\topacity: 0.3;\n\tcursor: default;\n}\n\n.monaco-editor .find-widget > .replace-part {\n\tdisplay: none;\n}\n\n.monaco-editor .find-widget > .replace-part > .monaco-findInput {\n\tposition: relative;\n\tdisplay: flex;\n\tvertical-align: middle;\n\tflex: auto;\n\tflex-grow: 0;\n\tflex-shrink: 0;\n}\n\n.monaco-editor .find-widget > .replace-part > .monaco-findInput > .controls {\n\tposition: absolute;\n\ttop: 3px;\n\tright: 2px;\n}\n\n/* REDUCED */\n.monaco-editor .find-widget.reduced-find-widget .matchesCount {\n\tdisplay:none;\n}\n\n/* NARROW (SMALLER THAN REDUCED) */\n.monaco-editor .find-widget.narrow-find-widget {\n\tmax-width: 257px !important;\n}\n\n/* COLLAPSED (SMALLER THAN NARROW) */\n.monaco-editor .find-widget.collapsed-find-widget {\n\tmax-width: 170px !important;\n}\n\n.monaco-editor .find-widget.collapsed-find-widget .button.previous,\n.monaco-editor .find-widget.collapsed-find-widget .button.next,\n.monaco-editor .find-widget.collapsed-find-widget .button.replace,\n.monaco-editor .find-widget.collapsed-find-widget .button.replace-all,\n.monaco-editor .find-widget.collapsed-find-widget > .find-part .monaco-findInput .controls {\n\tdisplay:none;\n}\n\n.monaco-editor .findMatch {\n\tanimation-duration: 0;\n\tanimation-name: inherit !important;\n}\n\n.monaco-editor .find-widget .monaco-sash {\n\tleft: 0 !important;\n}\n\n.monaco-editor.hc-black .find-widget .button:before {\n\tposition: relative;\n\ttop: 1px;\n\tleft: 2px;\n}\n",""]),t.Z=s},56610:function(e,t,i){"use strict";var n=i(8081),o=i.n(n),r=i(23645),s=i.n(r)()(o());s.push([e.id,'/*---------------------------------------------------------------------------------------------\n * Copyright (c) Microsoft Corporation. All rights reserved.\n * Licensed under the MIT License. See License.txt in the project root for license information.\n *--------------------------------------------------------------------------------------------*/\n\n.monaco-editor .margin-view-overlays .codicon-folding-expanded,\n.monaco-editor .margin-view-overlays .codicon-folding-collapsed {\n\tcursor: pointer;\n\topacity: 0;\n\ttransition: opacity 0.5s;\n\tdisplay: flex;\n\talign-items: center;\n\tjustify-content: center;\n\tfont-size: 140%;\n\tmargin-left: 2px;\n}\n\n.monaco-editor .margin-view-overlays:hover .codicon,\n.monaco-editor .margin-view-overlays .codicon.codicon-folding-collapsed,\n.monaco-editor .margin-view-overlays .codicon.alwaysShowFoldIcons {\n\topacity: 1;\n}\n\n.monaco-editor .inline-folded:after {\n\tcolor: grey;\n\tmargin: 0.1em 0.2em 0 0.2em;\n\tcontent: "⋯";\n\tdisplay: inline;\n\tline-height: 1em;\n\tcursor: pointer;\n}\n',""]),t.Z=s},77200:function(e,t,i){"use strict";var n=i(8081),o=i.n(n),r=i(23645),s=i.n(r)()(o());s.push([e.id,"/*---------------------------------------------------------------------------------------------\n * Copyright (c) Microsoft Corporation. All rights reserved.\n * Licensed under the MIT License. See License.txt in the project root for license information.\n *--------------------------------------------------------------------------------------------*/\n\n/* marker zone */\n\n.monaco-editor .peekview-widget .head .peekview-title .severity-icon {\n\tdisplay: inline-block;\n\tvertical-align: text-top;\n\tmargin-right: 4px;\n}\n\n.monaco-editor .marker-widget {\n\ttext-overflow: ellipsis;\n\twhite-space: nowrap;\n}\n\n.monaco-editor .marker-widget > .stale {\n\topacity: 0.6;\n\tfont-style: italic;\n}\n\n.monaco-editor .marker-widget .title {\n\tdisplay: inline-block;\n\tpadding-right: 5px;\n}\n\n.monaco-editor .marker-widget .descriptioncontainer {\n\tposition: absolute;\n\twhite-space: pre;\n\tuser-select: text;\n\t-webkit-user-select: text;\n\t-ms-user-select: text;\n\tpadding: 8px 12px 0 20px;\n}\n\n.monaco-editor .marker-widget .descriptioncontainer .message {\n\tdisplay: flex;\n\tflex-direction: column;\n}\n\n.monaco-editor .marker-widget .descriptioncontainer .message .details {\n\tpadding-left: 6px;\n}\n\n.monaco-editor .marker-widget .descriptioncontainer .message .source,\n.monaco-editor .marker-widget .descriptioncontainer .message span.code {\n\topacity: 0.6;\n}\n\n.monaco-editor .marker-widget .descriptioncontainer .message a.code-link {\n\topacity: 0.6;\n\tcolor: inherit;\n}\n\n.monaco-editor .marker-widget .descriptioncontainer .message a.code-link:before {\n\tcontent: '(';\n}\n\n.monaco-editor .marker-widget .descriptioncontainer .message a.code-link:after {\n\tcontent: ')';\n}\n\n.monaco-editor .marker-widget .descriptioncontainer .message a.code-link > span {\n\ttext-decoration: underline;\n\t/** Hack to force underline to show **/\n\tborder-bottom: 1px solid transparent;\n\ttext-underline-position: under;\n\tcolor: var(--vscode-textLink-foreground);\n}\n\n.monaco-editor .marker-widget .descriptioncontainer .message a.code-link > span {\n\tcolor: var(--vscode-textLink-activeForeground);\n}\n\n.monaco-editor .marker-widget .descriptioncontainer .filename {\n\tcursor: pointer;\n}\n",""]),t.Z=s},71072:function(e,t,i){"use strict";var n=i(8081),o=i.n(n),r=i(23645),s=i.n(r)()(o());s.push([e.id,"/*---------------------------------------------------------------------------------------------\n * Copyright (c) Microsoft Corporation. All rights reserved.\n * Licensed under the MIT License. See License.txt in the project root for license information.\n *--------------------------------------------------------------------------------------------*/\n\n.monaco-editor .goto-definition-link {\n\ttext-decoration: underline;\n\tcursor: pointer;\n}",""]),t.Z=s},4633:function(e,t,i){"use strict";var n=i(8081),o=i.n(n),r=i(23645),s=i.n(r)()(o());s.push([e.id,"/*---------------------------------------------------------------------------------------------\n * Copyright (c) Microsoft Corporation. All rights reserved.\n * Licensed under the MIT License. See License.txt in the project root for license information.\n *--------------------------------------------------------------------------------------------*/\n\n/* -- zone widget */\n.monaco-editor .zone-widget .zone-widget-container.reference-zone-widget {\n\tborder-top-width: 1px;\n\tborder-bottom-width: 1px;\n}\n\n.monaco-editor .reference-zone-widget .inline {\n\tdisplay: inline-block;\n\tvertical-align: top;\n}\n\n.monaco-editor .reference-zone-widget .messages {\n\theight: 100%;\n\twidth: 100%;\n\ttext-align: center;\n\tpadding: 3em 0;\n}\n\n.monaco-editor .reference-zone-widget .ref-tree {\n\tline-height: 23px;\n\tbackground-color: var(--vscode-peekViewResult-background);\n\tcolor: var(--vscode-peekViewResult-lineForeground);\n}\n\n.monaco-editor .reference-zone-widget .ref-tree .reference {\n\ttext-overflow: ellipsis;\n\toverflow: hidden;\n}\n\n.monaco-editor .reference-zone-widget .ref-tree .reference-file {\n\tdisplay: inline-flex;\n\twidth: 100%;\n\theight: 100%;\n\tcolor: var(--vscode-peekViewResult-fileForeground);\n}\n\n.monaco-editor .reference-zone-widget .ref-tree .monaco-list:focus .selected .reference-file {\n\tcolor: inherit !important;\n}\n\n.monaco-editor .reference-zone-widget .ref-tree .monaco-list:focus .monaco-list-rows > .monaco-list-row.selected:not(.highlighted) {\n\tbackground-color: var(--vscode-peekViewResult-selectionBackground);\n\tcolor: var(--vscode-peekViewResult-selectionForeground) !important;\n}\n\n.monaco-editor .reference-zone-widget .ref-tree .reference-file .count {\n\tmargin-right: 12px;\n\tmargin-left: auto;\n}\n\n.monaco-editor .reference-zone-widget .ref-tree .referenceMatch .highlight {\n\tbackground-color: var(--vscode-peekViewResult-matchHighlightBackground);\n}\n\n.monaco-editor .reference-zone-widget .preview .reference-decoration {\n\tbackground-color: var(--vscode-peekViewEditor-matchHighlightBackground);\n\tborder: 2px solid var(--vscode-peekViewEditor-matchHighlightBorder);\n\tbox-sizing: border-box;\n}\n\n.monaco-editor .reference-zone-widget .preview .monaco-editor .monaco-editor-background,\n.monaco-editor .reference-zone-widget .preview .monaco-editor .inputarea.ime-input {\n\tbackground-color: var(--vscode-peekViewEditor-background);\n}\n\n.monaco-editor .reference-zone-widget .preview .monaco-editor .margin {\n\tbackground-color: var(--vscode-peekViewEditorGutter-background);\n}\n\n/* High Contrast Theming */\n\n.monaco-editor.hc-black .reference-zone-widget .ref-tree .reference-file {\n\tfont-weight: bold;\n}\n\n.monaco-editor.hc-black .reference-zone-widget .ref-tree .referenceMatch .highlight {\n\tborder: 1px dotted var(--vscode-contrastActiveBorder, transparent);\n\tbox-sizing: border-box;\n}\n",""]),t.Z=s},22740:function(e,t,i){"use strict";var n=i(8081),o=i.n(n),r=i(23645),s=i.n(r)()(o());s.push([e.id,"/*---------------------------------------------------------------------------------------------\n * Copyright (c) Microsoft Corporation. All rights reserved.\n * Licensed under the MIT License. See License.txt in the project root for license information.\n *--------------------------------------------------------------------------------------------*/\n\n.monaco-editor .suggest-preview-additional-widget {\n\twhite-space: nowrap;\n}\n\n.monaco-editor .suggest-preview-additional-widget .content-spacer {\n\tcolor: transparent;\n\twhite-space: pre;\n}\n\n.monaco-editor .suggest-preview-additional-widget .button {\n\tdisplay: inline-block;\n\tcursor: pointer;\n\ttext-decoration: underline;\n\ttext-underline-position: under;\n}\n\n.monaco-editor .ghost-text-hidden {\n\topacity: 0;\n\tfont-size: 0;\n}\n\n.monaco-editor .ghost-text-decoration {\n\tfont-style: italic;\n}\n\n.monaco-editor .suggest-preview-text {\n\tfont-style: italic;\n}\n",""]),t.Z=s},42938:function(e,t,i){"use strict";var n=i(8081),o=i.n(n),r=i(23645),s=i.n(r)()(o());s.push([e.id,"/*---------------------------------------------------------------------------------------------\n * Copyright (c) Microsoft Corporation. All rights reserved.\n * Licensed under the MIT License. See License.txt in the project root for license information.\n *--------------------------------------------------------------------------------------------*/\n.monaco-editor .detected-link,\n.monaco-editor .detected-link-active {\n\ttext-decoration: underline;\n\ttext-underline-position: under;\n}\n\n.monaco-editor .detected-link-active {\n\tcursor: pointer;\n}\n",""]),t.Z=s},89009:function(e,t,i){"use strict";var n=i(8081),o=i.n(n),r=i(23645),s=i.n(r)()(o());s.push([e.id,"/*---------------------------------------------------------------------------------------------\n * Copyright (c) Microsoft Corporation. All rights reserved.\n * Licensed under the MIT License. See License.txt in the project root for license information.\n *--------------------------------------------------------------------------------------------*/\n\n.monaco-editor .monaco-editor-overlaymessage {\n\tpadding-bottom: 8px;\n\tz-index: 10000;\n}\n\n.monaco-editor .monaco-editor-overlaymessage.below {\n\tpadding-bottom: 0;\n\tpadding-top: 8px;\n\tz-index: 10000;\n}\n\n@keyframes fadeIn {\n\tfrom { opacity: 0; }\n\tto { opacity: 1; }\n}\n.monaco-editor .monaco-editor-overlaymessage.fadeIn {\n\tanimation: fadeIn 150ms ease-out;\n}\n\n@keyframes fadeOut {\n\tfrom { opacity: 1; }\n\tto { opacity: 0; }\n}\n.monaco-editor .monaco-editor-overlaymessage.fadeOut {\n\tanimation: fadeOut 100ms ease-out;\n}\n\n.monaco-editor .monaco-editor-overlaymessage .message {\n\tpadding: 1px 4px;\n\tcolor: var(--vscode-inputValidation-infoForeground);\n\tbackground-color: var(--vscode-inputValidation-infoBackground);\n\tborder: 1px solid var(--vscode-inputValidation-infoBorder);\n}\n\n.monaco-editor.hc-black .monaco-editor-overlaymessage .message {\n\tborder-width: 2px;\n}\n\n.monaco-editor .monaco-editor-overlaymessage .anchor {\n\twidth: 0 !important;\n\theight: 0 !important;\n\tborder-color: transparent;\n\tborder-style: solid;\n\tz-index: 1000;\n\tborder-width: 8px;\n\tposition: absolute;\n}\n\n.monaco-editor .monaco-editor-overlaymessage .anchor.top {\n\tborder-bottom-color: var(--vscode-inputValidation-infoBorder);\n}\n\n.monaco-editor .monaco-editor-overlaymessage .anchor.below {\n\tborder-top-color: var(--vscode-inputValidation-infoBorder);\n}\n\n.monaco-editor .monaco-editor-overlaymessage:not(.below) .anchor.top,\n.monaco-editor .monaco-editor-overlaymessage.below .anchor.below {\n\tdisplay: none;\n}\n\n.monaco-editor .monaco-editor-overlaymessage.below .anchor.top {\n\tdisplay: inherit;\n\ttop: -8px;\n}\n",""]),t.Z=s},88846:function(e,t,i){"use strict";var n=i(8081),o=i.n(n),r=i(23645),s=i.n(r)()(o());s.push([e.id,"/*---------------------------------------------------------------------------------------------\n * Copyright (c) Microsoft Corporation. All rights reserved.\n * Licensed under the MIT License. See License.txt in the project root for license information.\n *--------------------------------------------------------------------------------------------*/\n\n.monaco-editor .parameter-hints-widget {\n\t/* Must be higher than the sash's z-index and terminal canvases but lower than the suggest widget */\n\tz-index: 39;\n\tdisplay: flex;\n\tflex-direction: column;\n\tline-height: 1.5em;\n}\n\n.monaco-editor .parameter-hints-widget > .phwrapper {\n\tmax-width: 440px;\n\tdisplay: flex;\n\tflex-direction: row;\n}\n\n.monaco-editor .parameter-hints-widget.multiple {\n\tmin-height: 3.3em;\n\tpadding: 0;\n}\n\n.monaco-editor .parameter-hints-widget.visible {\n\ttransition: left .05s ease-in-out;\n}\n\n.monaco-editor .parameter-hints-widget p,\n.monaco-editor .parameter-hints-widget ul {\n\tmargin: 8px 0;\n}\n\n.monaco-editor .parameter-hints-widget .monaco-scrollable-element,\n.monaco-editor .parameter-hints-widget .body {\n\tdisplay: flex;\n\tflex: 1;\n\tflex-direction: column;\n\tmin-height: 100%;\n}\n\n.monaco-editor .parameter-hints-widget .signature {\n\tpadding: 4px 5px;\n}\n\n.monaco-editor .parameter-hints-widget .docs {\n\tpadding: 0 10px 0 5px;\n\twhite-space: pre-wrap;\n}\n\n.monaco-editor .parameter-hints-widget .docs.empty {\n\tdisplay: none;\n}\n\n.monaco-editor .parameter-hints-widget .docs .markdown-docs {\n\twhite-space: initial;\n}\n\n.monaco-editor .parameter-hints-widget .docs .markdown-docs code {\n\tfont-family: var(--monaco-monospace-font);\n}\n\n.monaco-editor .parameter-hints-widget .docs .monaco-tokenized-source,\n.monaco-editor .parameter-hints-widget .docs .code {\n\twhite-space: pre-wrap;\n}\n\n.monaco-editor .parameter-hints-widget .docs code {\n\tborder-radius: 3px;\n\tpadding: 0 0.4em;\n}\n\n.monaco-editor .parameter-hints-widget .controls {\n\tdisplay: none;\n\tflex-direction: column;\n\talign-items: center;\n\tmin-width: 22px;\n\tjustify-content: flex-end;\n}\n\n.monaco-editor .parameter-hints-widget.multiple .controls {\n\tdisplay: flex;\n\tpadding: 0 2px;\n}\n\n.monaco-editor .parameter-hints-widget.multiple .button {\n\twidth: 16px;\n\theight: 16px;\n\tbackground-repeat: no-repeat;\n\tcursor: pointer;\n}\n\n.monaco-editor .parameter-hints-widget .button.previous {\n\tbottom: 24px;\n}\n\n.monaco-editor .parameter-hints-widget .overloads {\n\ttext-align: center;\n\theight: 12px;\n\tline-height: 12px;\n\tfont-family: var(--monaco-monospace-font);\n}\n\n.monaco-editor .parameter-hints-widget .signature .parameter.active {\n\tfont-weight: bold;\n}\n\n.monaco-editor .parameter-hints-widget .documentation-parameter > .parameter {\n\tfont-weight: bold;\n\tmargin-right: 0.5em;\n}\n",""]),t.Z=s},66458:function(e,t,i){"use strict";var n=i(8081),o=i.n(n),r=i(23645),s=i.n(r)()(o());s.push([e.id,"/*---------------------------------------------------------------------------------------------\n * Copyright (c) Microsoft Corporation. All rights reserved.\n * Licensed under the MIT License. See License.txt in the project root for license information.\n *--------------------------------------------------------------------------------------------*/\n\n.monaco-editor .peekview-widget .head {\n\tbox-sizing: border-box;\n\tdisplay: flex;\n\tjustify-content: space-between;\n\tflex-wrap: nowrap;\n}\n\n.monaco-editor .peekview-widget .head .peekview-title {\n\tdisplay: flex;\n\talign-items: center;\n\tfont-size: 13px;\n\tmargin-left: 20px;\n\tmin-width: 0;\n\ttext-overflow: ellipsis;\n\toverflow: hidden;\n}\n\n.monaco-editor .peekview-widget .head .peekview-title.clickable {\n\tcursor: pointer;\n}\n\n.monaco-editor .peekview-widget .head .peekview-title .dirname:not(:empty) {\n\tfont-size: 0.9em;\n\tmargin-left: 0.5em;\n\ttext-overflow: ellipsis;\n\toverflow: hidden;\n}\n\n.monaco-editor .peekview-widget .head .peekview-title .meta {\n\twhite-space: nowrap;\n\toverflow: hidden;\n\ttext-overflow: ellipsis;\n}\n\n.monaco-editor .peekview-widget .head .peekview-title .dirname {\n\twhite-space: nowrap;\n}\n\n.monaco-editor .peekview-widget .head .peekview-title .filename {\n\toverflow: hidden;\n\ttext-overflow: ellipsis;\n\twhite-space: nowrap;\n}\n\n.monaco-editor .peekview-widget .head .peekview-title .meta:not(:empty)::before {\n\tcontent: '-';\n\tpadding: 0 0.3em;\n}\n\n.monaco-editor .peekview-widget .head .peekview-actions {\n\tflex: 1;\n\ttext-align: right;\n\tpadding-right: 2px;\n}\n\n.monaco-editor .peekview-widget .head .peekview-actions > .monaco-action-bar {\n\tdisplay: inline-block;\n}\n\n.monaco-editor .peekview-widget .head .peekview-actions > .monaco-action-bar,\n.monaco-editor .peekview-widget .head .peekview-actions > .monaco-action-bar > .actions-container {\n\theight: 100%;\n}\n\n.monaco-editor .peekview-widget > .body {\n\tborder-top: 1px solid;\n\tposition: relative;\n}\n\n.monaco-editor .peekview-widget .head .peekview-title .codicon {\n\tmargin-right: 4px;\n}\n\n.monaco-editor .peekview-widget .monaco-list .monaco-list-row.focused .codicon {\n\tcolor: inherit !important;\n}\n",""]),t.Z=s},68747:function(e,t,i){"use strict";var n=i(8081),o=i.n(n),r=i(23645),s=i.n(r)()(o());s.push([e.id,"/*---------------------------------------------------------------------------------------------\n * Copyright (c) Microsoft Corporation. All rights reserved.\n * Licensed under the MIT License. See License.txt in the project root for license information.\n *--------------------------------------------------------------------------------------------*/\n\n.monaco-editor .rename-box {\n\tz-index: 100;\n\tcolor: inherit;\n}\n\n.monaco-editor .rename-box.preview {\n\tpadding: 3px 3px 0 3px;\n}\n\n.monaco-editor .rename-box .rename-input {\n\tpadding: 3px;\n\twidth: calc(100% - 6px);\n}\n\n.monaco-editor .rename-box .rename-label {\n\tdisplay: none;\n\topacity: .8;\n}\n\n.monaco-editor .rename-box.preview .rename-label {\n\tdisplay: inherit;\n}\n",""]),t.Z=s},842:function(e,t,i){"use strict";var n=i(8081),o=i.n(n),r=i(23645),s=i.n(r)()(o());s.push([e.id,"/*---------------------------------------------------------------------------------------------\n * Copyright (c) Microsoft Corporation. All rights reserved.\n * Licensed under the MIT License. See License.txt in the project root for license information.\n *--------------------------------------------------------------------------------------------*/\n\n.monaco-editor .snippet-placeholder {\n\tmin-width: 2px;\n\toutline-style: solid;\n\toutline-width: 1px;\n\tbackground-color: var(--vscode-editor-snippetTabstopHighlightBackground, transparent);\n\toutline-color: var(--vscode-editor-snippetTabstopHighlightBorder, transparent);\n}\n\n.monaco-editor .finish-snippet-placeholder {\n\toutline-style: solid;\n\toutline-width: 1px;\n\tbackground-color: var(--vscode-editor-snippetFinalTabstopHighlightBackground, transparent);\n\toutline-color: var(--vscode-editor-snippetFinalTabstopHighlightBorder, transparent);\n}\n",""]),t.Z=s},73929:function(e,t,i){"use strict";var n=i(8081),o=i.n(n),r=i(23645),s=i.n(r)()(o());s.push([e.id,"/*---------------------------------------------------------------------------------------------\n * Copyright (c) Microsoft Corporation. All rights reserved.\n * Licensed under the MIT License. See License.txt in the project root for license information.\n *--------------------------------------------------------------------------------------------*/\n\n/* Suggest widget*/\n\n.monaco-editor .suggest-widget {\n\twidth: 430px;\n\tz-index: 40;\n\tdisplay: flex;\n\tflex-direction: column;\n}\n\n.monaco-editor .suggest-widget.message {\n\tflex-direction: row;\n\talign-items: center;\n}\n\n.monaco-editor .suggest-widget,\n.monaco-editor .suggest-details {\n\tflex: 0 1 auto;\n\twidth: 100%;\n\tborder-style: solid;\n\tborder-width: 1px;\n\tborder-color: var(--vscode-editorSuggestWidget-border);\n\tbackground-color: var(--vscode-editorSuggestWidget-background);\n}\n\n.monaco-editor.hc-black .suggest-widget,\n.monaco-editor.hc-black .suggest-details {\n\tborder-width: 2px;\n}\n\n/* Styles for status bar part */\n\n\n.monaco-editor .suggest-widget .suggest-status-bar {\n\tbox-sizing: border-box;\n\tdisplay: none;\n\tflex-flow: row nowrap;\n\tjustify-content: space-between;\n\twidth: 100%;\n\tfont-size: 80%;\n\tpadding: 0 4px 0 4px;\n\tborder-top: 1px solid var(--vscode-editorSuggestWidget-border);\n\toverflow: hidden;\n}\n\n.monaco-editor .suggest-widget.with-status-bar .suggest-status-bar {\n\tdisplay: flex;\n}\n\n.monaco-editor .suggest-widget .suggest-status-bar .left {\n\tpadding-right: 8px;\n}\n\n.monaco-editor .suggest-widget.with-status-bar .suggest-status-bar .action-label {\n\tcolor: var(--vscode-editorSuggestWidgetStatus-foreground);\n}\n\n.monaco-editor .suggest-widget.with-status-bar .suggest-status-bar .action-item:not(:last-of-type) .action-label {\n\tmargin-right: 0;\n}\n\n.monaco-editor .suggest-widget.with-status-bar .suggest-status-bar .action-item:not(:last-of-type) .action-label::after {\n\tcontent: ', ';\n\tmargin-right: 0.3em;\n}\n\n.monaco-editor .suggest-widget.with-status-bar .monaco-list .monaco-list-row>.contents>.main>.right>.readMore,\n.monaco-editor .suggest-widget.with-status-bar .monaco-list .monaco-list-row.focused.string-label>.contents>.main>.right>.readMore {\n\tdisplay: none;\n}\n\n.monaco-editor .suggest-widget.with-status-bar:not(.docs-side) .monaco-list .monaco-list-row:hover>.contents>.main>.right.can-expand-details>.details-label {\n\twidth: 100%;\n}\n\n/* Styles for Message element for when widget is loading or is empty */\n\n.monaco-editor .suggest-widget>.message {\n\tpadding-left: 22px;\n}\n\n/** Styles for the list element **/\n\n.monaco-editor .suggest-widget>.tree {\n\theight: 100%;\n\twidth: 100%;\n}\n\n.monaco-editor .suggest-widget .monaco-list {\n\tuser-select: none;\n\t-webkit-user-select: none;\n\t-ms-user-select: none;\n}\n\n/** Styles for each row in the list element **/\n\n.monaco-editor .suggest-widget .monaco-list .monaco-list-row {\n\tdisplay: flex;\n\t-mox-box-sizing: border-box;\n\tbox-sizing: border-box;\n\tpadding-right: 10px;\n\tbackground-repeat: no-repeat;\n\tbackground-position: 2px 2px;\n\twhite-space: nowrap;\n\tcursor: pointer;\n\ttouch-action: none;\n}\n\n.monaco-editor .suggest-widget .monaco-list .monaco-list-row.focused {\n\tcolor: var(--vscode-editorSuggestWidget-selectedForeground);\n}\n\n.monaco-editor .suggest-widget .monaco-list .monaco-list-row.focused .codicon {\n\tcolor: var(--vscode-editorSuggestWidget-selectedIconForeground);\n}\n\n.monaco-editor .suggest-widget .monaco-list .monaco-list-row>.contents {\n\tflex: 1;\n\theight: 100%;\n\toverflow: hidden;\n\tpadding-left: 2px;\n}\n\n.monaco-editor .suggest-widget .monaco-list .monaco-list-row>.contents>.main {\n\tdisplay: flex;\n\toverflow: hidden;\n\ttext-overflow: ellipsis;\n\twhite-space: pre;\n\tjustify-content: space-between;\n}\n\n.monaco-editor .suggest-widget .monaco-list .monaco-list-row>.contents>.main>.left, .monaco-editor .suggest-widget .monaco-list .monaco-list-row>.contents>.main>.right {\n\tdisplay: flex;\n}\n\n.monaco-editor .suggest-widget .monaco-list .monaco-list-row:not(.focused)>.contents>.main .monaco-icon-label {\n\tcolor: var(--vscode-editorSuggestWidget-foreground);\n}\n\n.monaco-editor .suggest-widget:not(.frozen) .monaco-highlighted-label .highlight {\n\tfont-weight: bold;\n}\n\n.monaco-editor .suggest-widget .monaco-list .monaco-list-row>.contents>.main .monaco-highlighted-label .highlight {\n\tcolor: var(--vscode-editorSuggestWidget-highlightForeground);\n}\n\n.monaco-editor .suggest-widget .monaco-list .monaco-list-row.focused>.contents>.main .monaco-highlighted-label .highlight {\n\tcolor: var(--vscode-editorSuggestWidget-focusHighlightForeground);\n}\n\n/** ReadMore Icon styles **/\n\n.monaco-editor .suggest-details>.monaco-scrollable-element>.body>.header>.codicon-close,\n.monaco-editor .suggest-widget .monaco-list .monaco-list-row>.contents>.main>.right>.readMore::before {\n\tcolor: inherit;\n\topacity: 1;\n\tfont-size: 14px;\n\tcursor: pointer;\n}\n\n.monaco-editor .suggest-details>.monaco-scrollable-element>.body>.header>.codicon-close {\n\tposition: absolute;\n\ttop: 6px;\n\tright: 2px;\n}\n\n.monaco-editor .suggest-details>.monaco-scrollable-element>.body>.header>.codicon-close:hover,\n.monaco-editor .suggest-widget .monaco-list .monaco-list-row>.contents>.main>.right>.readMore:hover {\n\topacity: 1;\n}\n\n/** signature, qualifier, type/details opacity **/\n\n.monaco-editor .suggest-widget .monaco-list .monaco-list-row>.contents>.main>.right>.details-label {\n\topacity: 0.7;\n}\n\n.monaco-editor .suggest-widget .monaco-list .monaco-list-row>.contents>.main>.left>.signature-label {\n\toverflow: hidden;\n\ttext-overflow: ellipsis;\n\topacity: 0.6;\n}\n\n.monaco-editor .suggest-widget .monaco-list .monaco-list-row>.contents>.main>.left>.qualifier-label {\n\tmargin-left: 12px;\n\topacity: 0.4;\n\tfont-size: 85%;\n\tline-height: initial;\n\ttext-overflow: ellipsis;\n\toverflow: hidden;\n\talign-self: center;\n}\n\n/** Type Info and icon next to the label in the focused completion item **/\n\n.monaco-editor .suggest-widget .monaco-list .monaco-list-row>.contents>.main>.right>.details-label {\n\tfont-size: 85%;\n\tmargin-left: 1.1em;\n\toverflow: hidden;\n\ttext-overflow: ellipsis;\n\twhite-space: nowrap;\n}\n\n.monaco-editor .suggest-widget .monaco-list .monaco-list-row>.contents>.main>.right>.details-label>.monaco-tokenized-source {\n\tdisplay: inline;\n}\n\n/** Details: if using CompletionItem#details, show on focus **/\n\n.monaco-editor .suggest-widget .monaco-list .monaco-list-row>.contents>.main>.right>.details-label {\n\tdisplay: none;\n}\n\n.monaco-editor .suggest-widget:not(.shows-details) .monaco-list .monaco-list-row.focused>.contents>.main>.right>.details-label {\n\tdisplay: inline;\n}\n\n/** Details: if using CompletionItemLabel#details, always show **/\n\n.monaco-editor .suggest-widget .monaco-list .monaco-list-row:not(.string-label)>.contents>.main>.right>.details-label,\n.monaco-editor .suggest-widget.docs-side .monaco-list .monaco-list-row.focused:not(.string-label)>.contents>.main>.right>.details-label {\n\tdisplay: inline;\n}\n\n/** Ellipsis on hover **/\n\n.monaco-editor .suggest-widget:not(.docs-side) .monaco-list .monaco-list-row.focused:hover>.contents>.main>.right.can-expand-details>.details-label {\n\twidth: calc(100% - 26px);\n}\n\n.monaco-editor .suggest-widget .monaco-list .monaco-list-row>.contents>.main>.left {\n\tflex-shrink: 1;\n\tflex-grow: 1;\n\toverflow: hidden;\n}\n\n.monaco-editor .suggest-widget .monaco-list .monaco-list-row>.contents>.main>.left>.monaco-icon-label {\n\tflex-shrink: 0;\n}\n\n.monaco-editor .suggest-widget .monaco-list .monaco-list-row:not(.string-label)>.contents>.main>.left>.monaco-icon-label {\n\tmax-width: 100%;\n}\n\n.monaco-editor .suggest-widget .monaco-list .monaco-list-row.string-label>.contents>.main>.left>.monaco-icon-label {\n\tflex-shrink: 1;\n}\n\n.monaco-editor .suggest-widget .monaco-list .monaco-list-row>.contents>.main>.right {\n\toverflow: hidden;\n\tflex-shrink: 4;\n\tmax-width: 70%;\n}\n\n.monaco-editor .suggest-widget .monaco-list .monaco-list-row>.contents>.main>.right>.readMore {\n\tdisplay: inline-block;\n\tposition: absolute;\n\tright: 10px;\n\twidth: 18px;\n\theight: 18px;\n\tvisibility: hidden;\n}\n\n/** Do NOT display ReadMore when docs is side/below **/\n\n.monaco-editor .suggest-widget.docs-side .monaco-list .monaco-list-row>.contents>.main>.right>.readMore {\n\tdisplay: none !important;\n}\n\n/** Do NOT display ReadMore when using plain CompletionItemLabel (details/documentation might not be resolved) **/\n\n.monaco-editor .suggest-widget .monaco-list .monaco-list-row.string-label>.contents>.main>.right>.readMore {\n\tdisplay: none;\n}\n\n/** Focused item can show ReadMore, but can't when docs is side/below **/\n\n.monaco-editor .suggest-widget .monaco-list .monaco-list-row.focused.string-label>.contents>.main>.right>.readMore {\n\tdisplay: inline-block;\n}\n\n.monaco-editor .suggest-widget .monaco-list .monaco-list-row.focused:hover>.contents>.main>.right>.readMore {\n\tvisibility: visible;\n}\n\n/** Styles for each row in the list **/\n\n.monaco-editor .suggest-widget .monaco-list .monaco-list-row .monaco-icon-label.deprecated {\n\topacity: 0.66;\n\ttext-decoration: unset;\n}\n\n.monaco-editor .suggest-widget .monaco-list .monaco-list-row .monaco-icon-label.deprecated>.monaco-icon-label-container>.monaco-icon-name-container {\n\ttext-decoration: line-through;\n}\n\n.monaco-editor .suggest-widget .monaco-list .monaco-list-row .monaco-icon-label::before {\n\theight: 100%;\n}\n\n.monaco-editor .suggest-widget .monaco-list .monaco-list-row .icon {\n\tdisplay: block;\n\theight: 16px;\n\twidth: 16px;\n\tmargin-left: 2px;\n\tbackground-repeat: no-repeat;\n\tbackground-size: 80%;\n\tbackground-position: center;\n}\n\n.monaco-editor .suggest-widget .monaco-list .monaco-list-row .icon.hide {\n\tdisplay: none;\n}\n\n.monaco-editor .suggest-widget .monaco-list .monaco-list-row .suggest-icon {\n\tdisplay: flex;\n\talign-items: center;\n\tmargin-right: 4px;\n}\n\n.monaco-editor .suggest-widget.no-icons .monaco-list .monaco-list-row .icon, .monaco-editor .suggest-widget.no-icons .monaco-list .monaco-list-row .suggest-icon::before {\n\tdisplay: none;\n}\n\n.monaco-editor .suggest-widget .monaco-list .monaco-list-row .icon.customcolor .colorspan {\n\tmargin: 0 0 0 0.3em;\n\tborder: 0.1em solid #000;\n\twidth: 0.7em;\n\theight: 0.7em;\n\tdisplay: inline-block;\n}\n\n/** Styles for the docs of the completion item in focus **/\n\n.monaco-editor .suggest-details-container {\n\tz-index: 41;\n}\n\n.monaco-editor .suggest-details {\n\tdisplay: flex;\n\tflex-direction: column;\n\tcursor: default;\n\tcolor: var(--vscode-editorSuggestWidget-foreground);\n}\n\n.monaco-editor .suggest-details.focused {\n\tborder-color: var(--vscode-focusBorder);\n}\n\n.monaco-editor .suggest-details a {\n\tcolor: var(--vscode-textLink-foreground);\n}\n\n.monaco-editor .suggest-details a:hover {\n\tcolor: var(--vscode-textLink-activeForeground);\n}\n\n.monaco-editor .suggest-details code {\n\tbackground-color: var(--vscode-textCodeBlock-background);\n}\n\n.monaco-editor .suggest-details.no-docs {\n\tdisplay: none;\n}\n\n.monaco-editor .suggest-details>.monaco-scrollable-element {\n\tflex: 1;\n}\n\n.monaco-editor .suggest-details>.monaco-scrollable-element>.body {\n\tbox-sizing: border-box;\n\theight: 100%;\n\twidth: 100%;\n}\n\n.monaco-editor .suggest-details>.monaco-scrollable-element>.body>.header>.type {\n\tflex: 2;\n\toverflow: hidden;\n\ttext-overflow: ellipsis;\n\topacity: 0.7;\n\twhite-space: pre;\n\tmargin: 0 24px 0 0;\n\tpadding: 4px 0 12px 5px;\n}\n\n.monaco-editor .suggest-details>.monaco-scrollable-element>.body>.header>.type.auto-wrap {\n\twhite-space: normal;\n\tword-break: break-all;\n}\n\n.monaco-editor .suggest-details>.monaco-scrollable-element>.body>.docs {\n\tmargin: 0;\n\tpadding: 4px 5px;\n\twhite-space: pre-wrap;\n}\n\n.monaco-editor .suggest-details.no-type>.monaco-scrollable-element>.body>.docs {\n\tmargin-right: 24px;\n\toverflow: hidden;\n}\n\n.monaco-editor .suggest-details>.monaco-scrollable-element>.body>.docs.markdown-docs {\n\tpadding: 0;\n\twhite-space: initial;\n\tmin-height: calc(1rem + 8px);\n}\n\n.monaco-editor .suggest-details>.monaco-scrollable-element>.body>.docs.markdown-docs>div,\n.monaco-editor .suggest-details>.monaco-scrollable-element>.body>.docs.markdown-docs>span:not(:empty) {\n\tpadding: 4px 5px;\n}\n\n.monaco-editor .suggest-details>.monaco-scrollable-element>.body>.docs.markdown-docs>div>p:first-child {\n\tmargin-top: 0;\n}\n\n.monaco-editor .suggest-details>.monaco-scrollable-element>.body>.docs.markdown-docs>div>p:last-child {\n\tmargin-bottom: 0;\n}\n\n.monaco-editor .suggest-details>.monaco-scrollable-element>.body>.docs.markdown-docs .monaco-tokenized-source {\n\twhite-space: pre;\n}\n\n.monaco-editor .suggest-details>.monaco-scrollable-element>.body>.docs .code {\n\twhite-space: pre-wrap;\n\tword-wrap: break-word;\n}\n\n.monaco-editor .suggest-details>.monaco-scrollable-element>.body>.docs.markdown-docs .codicon {\n\tvertical-align: sub;\n}\n\n.monaco-editor .suggest-details>.monaco-scrollable-element>.body>p:empty {\n\tdisplay: none;\n}\n\n.monaco-editor .suggest-details code {\n\tborder-radius: 3px;\n\tpadding: 0 0.4em;\n}\n\n.monaco-editor .suggest-details ul {\n\tpadding-left: 20px;\n}\n\n.monaco-editor .suggest-details ol {\n\tpadding-left: 20px;\n}\n\n.monaco-editor .suggest-details p code {\n\tfont-family: var(--monaco-monospace-font);\n}\n",""]),t.Z=s},9604:function(e,t,i){"use strict";var n=i(8081),o=i.n(n),r=i(23645),s=i.n(r)()(o());s.push([e.id,"/*---------------------------------------------------------------------------------------------\n * Copyright (c) Microsoft Corporation. All rights reserved.\n * Licensed under the MIT License. See License.txt in the project root for license information.\n *--------------------------------------------------------------------------------------------*/\n\n.editor-banner {\n\tbox-sizing: border-box;\n\tcursor: default;\n\twidth: 100%;\n\tfont-size: 12px;\n\tdisplay: flex;\n\toverflow: visible;\n\n\theight: 26px;\n\n\tbackground: var(--vscode-banner-background);\n}\n\n\n.editor-banner .icon-container {\n\tdisplay: flex;\n\tflex-shrink: 0;\n\talign-items: center;\n\tpadding: 0 6px 0 10px;\n}\n\n.editor-banner .icon-container.custom-icon {\n\tbackground-repeat: no-repeat;\n\tbackground-position: center center;\n\tbackground-size: 16px;\n\twidth: 16px;\n\tpadding: 0;\n\tmargin: 0 6px 0 10px;\n}\n\n.editor-banner .message-container {\n\tdisplay: flex;\n\talign-items: center;\n\tline-height: 26px;\n\ttext-overflow: ellipsis;\n\twhite-space: nowrap;\n\toverflow: hidden;\n}\n\n.editor-banner .message-container p {\n\tmargin-block-start: 0;\n\tmargin-block-end: 0;\n}\n\n.editor-banner .message-actions-container {\n\tflex-grow: 1;\n\tflex-shrink: 0;\n\tline-height: 26px;\n\tmargin: 0 4px;\n}\n\n.editor-banner .message-actions-container a.monaco-button {\n\twidth: inherit;\n\tmargin: 2px 8px;\n\tpadding: 0px 12px;\n}\n\n.editor-banner .message-actions-container a {\n\tpadding: 3px;\n\tmargin-left: 12px;\n\ttext-decoration: underline;\n}\n\n.editor-banner .action-container {\n\tpadding: 0 10px 0 6px;\n}\n\n.editor-banner {\n\tbackground-color: var(--vscode-banner-background);\n}\n\n.editor-banner,\n.editor-banner .action-container .codicon,\n.editor-banner .message-actions-container .monaco-link {\n\tcolor: var(--vscode-banner-foreground);\n}\n\n.editor-banner .icon-container .codicon {\n\tcolor: var(--vscode-banner-iconForeground);\n}\n",""]),t.Z=s},18557:function(e,t,i){"use strict";var n=i(8081),o=i.n(n),r=i(23645),s=i.n(r)()(o());s.push([e.id,"/*---------------------------------------------------------------------------------------------\n * Copyright (c) Microsoft Corporation. All rights reserved.\n * Licensed under the MIT License. See License.txt in the project root for license information.\n *--------------------------------------------------------------------------------------------*/\n\n.monaco-editor .unicode-highlight {\n\tborder: 1px solid var(--vscode-editorUnicodeHighlight-border);\n\tbox-sizing: border-box;\n}\n",""]),t.Z=s},75853:function(e,t,i){"use strict";var n=i(8081),o=i.n(n),r=i(23645),s=i.n(r)()(o());s.push([e.id,"/*---------------------------------------------------------------------------------------------\n * Copyright (c) Microsoft Corporation. All rights reserved.\n * Licensed under the MIT License. See License.txt in the project root for license information.\n *--------------------------------------------------------------------------------------------*/\n.monaco-editor .zone-widget {\n\tposition: absolute;\n\tz-index: 10;\n}\n\n\n.monaco-editor .zone-widget .zone-widget-container {\n\tborder-top-style: solid;\n\tborder-bottom-style: solid;\n\tborder-top-width: 0;\n\tborder-bottom-width: 0;\n\tposition: relative;\n}\n",""]),t.Z=s},20450:function(e,t,i){"use strict";var n=i(8081),o=i.n(n),r=i(23645),s=i.n(r)()(o());s.push([e.id,"/*---------------------------------------------------------------------------------------------\n * Copyright (c) Microsoft Corporation. All rights reserved.\n * Licensed under the MIT License. See License.txt in the project root for license information.\n *--------------------------------------------------------------------------------------------*/\n\n.monaco-editor .accessibilityHelpWidget {\n\tpadding: 10px;\n\tvertical-align: middle;\n\toverflow: scroll;\n}",""]),t.Z=s},8986:function(e,t,i){"use strict";var n=i(8081),o=i.n(n),r=i(23645),s=i.n(r),a=i(61667),l=i.n(a),c=new URL(i(6161),i.b),d=new URL(i(51096),i.b),u=s()(o()),h=l()(c),g=l()(d);u.push([e.id,"/*---------------------------------------------------------------------------------------------\n * Copyright (c) Microsoft Corporation. All rights reserved.\n * Licensed under the MIT License. See License.txt in the project root for license information.\n *--------------------------------------------------------------------------------------------*/\n\n.monaco-editor .iPadShowKeyboard {\n\twidth: 58px;\n\tmin-width: 0;\n\theight: 36px;\n\tmin-height: 0;\n\tmargin: 0;\n\tpadding: 0;\n\tposition: absolute;\n\tresize: none;\n\toverflow: hidden;\n\tbackground: url("+h+") center center no-repeat;\n\tborder: 4px solid #F6F6F6;\n\tborder-radius: 4px;\n}\n\n.monaco-editor.vs-dark .iPadShowKeyboard {\n\tbackground: url("+g+") center center no-repeat;\n\tborder: 4px solid #252526;\n}",""]),t.Z=u},2885:function(e,t,i){"use strict";var n=i(8081),o=i.n(n),r=i(23645),s=i.n(r)()(o());s.push([e.id,"/*---------------------------------------------------------------------------------------------\n * Copyright (c) Microsoft Corporation. All rights reserved.\n * Licensed under the MIT License. See License.txt in the project root for license information.\n *--------------------------------------------------------------------------------------------*/\n\n.monaco-editor .tokens-inspect-widget {\n\tz-index: 50;\n\tuser-select: text;\n\t-webkit-user-select: text;\n\t-ms-user-select: text;\n\tpadding: 10px;\n}\n\n.tokens-inspect-separator {\n\theight: 1px;\n\tborder: 0;\n}\n\n.monaco-editor .tokens-inspect-widget .tm-token {\n\tfont-family: var(--monaco-monospace-font);\n}\n\n.monaco-editor .tokens-inspect-widget .tm-token-length {\n\tfont-weight: normal;\n\tfont-size: 60%;\n\tfloat: right;\n}\n\n.monaco-editor .tokens-inspect-widget .tm-metadata-table {\n\twidth: 100%;\n}\n\n.monaco-editor .tokens-inspect-widget .tm-metadata-value {\n\tfont-family: var(--monaco-monospace-font);\n\ttext-align: right;\n}\n\n.monaco-editor .tokens-inspect-widget .tm-token-type {\n\tfont-family: var(--monaco-monospace-font);\n}\n",""]),t.Z=s},98581:function(e,t,i){"use strict";var n=i(8081),o=i.n(n),r=i(23645),s=i.n(r)()(o());s.push([e.id,"/*---------------------------------------------------------------------------------------------\n * Copyright (c) Microsoft Corporation. All rights reserved.\n * Licensed under the MIT License. See License.txt in the project root for license information.\n *--------------------------------------------------------------------------------------------*/\n\n.quick-input-widget {\n\tfont-size: 13px;\n}\n\n.quick-input-widget .monaco-highlighted-label .highlight,\n.quick-input-widget .monaco-highlighted-label .highlight {\n\tcolor: #0066BF;\n}\n\n.vs .quick-input-widget .monaco-list-row.focused .monaco-highlighted-label .highlight,\n.vs .quick-input-widget .monaco-list-row.focused .monaco-highlighted-label .highlight {\n\tcolor: #9DDDFF;\n}\n\n.vs-dark .quick-input-widget .monaco-highlighted-label .highlight,\n.vs-dark .quick-input-widget .monaco-highlighted-label .highlight {\n\tcolor: #0097fb;\n}\n\n.hc-black .quick-input-widget .monaco-highlighted-label .highlight,\n.hc-black .quick-input-widget .monaco-highlighted-label .highlight {\n\tcolor: #F38518;\n}\n\n.monaco-keybinding > .monaco-keybinding-key {\n\tbackground-color: rgba(221, 221, 221, 0.4);\n\tborder: solid 1px rgba(204, 204, 204, 0.4);\n\tborder-bottom-color: rgba(187, 187, 187, 0.4);\n\tbox-shadow: inset 0 -1px 0 rgba(187, 187, 187, 0.4);\n\tcolor: #555;\n}\n\n.hc-black .monaco-keybinding > .monaco-keybinding-key {\n\tbackground-color: transparent;\n\tborder: solid 1px rgb(111, 195, 223);\n\tbox-shadow: none;\n\tcolor: #fff;\n}\n\n.vs-dark .monaco-keybinding > .monaco-keybinding-key {\n\tbackground-color: rgba(128, 128, 128, 0.17);\n\tborder: solid 1px rgba(51, 51, 51, 0.6);\n\tborder-bottom-color: rgba(68, 68, 68, 0.6);\n\tbox-shadow: inset 0 -1px 0 rgba(68, 68, 68, 0.6);\n\tcolor: #ccc;\n}\n",""]),t.Z=s},98835:function(e,t,i){"use strict";var n=i(8081),o=i.n(n),r=i(23645),s=i.n(r)()(o());s.push([e.id,'/*---------------------------------------------------------------------------------------------\n * Copyright (c) Microsoft Corporation. All rights reserved.\n * Licensed under the MIT License. See License.txt in the project root for license information.\n *--------------------------------------------------------------------------------------------*/\n\n\n/* Default standalone editor fonts */\n.monaco-editor {\n\tfont-family: -apple-system, BlinkMacSystemFont, "Segoe WPC", "Segoe UI", "HelveticaNeue-Light", system-ui, "Ubuntu", "Droid Sans", sans-serif;\n\t--monaco-monospace-font: "SF Mono", Monaco, Menlo, Consolas, "Ubuntu Mono", "Liberation Mono", "DejaVu Sans Mono", "Courier New", monospace;\n}\n\n.monaco-menu .monaco-action-bar.vertical .action-item .action-menu-item:focus .action-label {\n\tstroke-width: 1.2px;\n}\n\n.monaco-editor.vs-dark .monaco-menu .monaco-action-bar.vertical .action-menu-item:focus .action-label,\n.monaco-editor.hc-black .monaco-menu .monaco-action-bar.vertical .action-menu-item:focus .action-label {\n\tstroke-width: 1.2px;\n}\n\n.monaco-hover p {\n\tmargin: 0;\n}\n\n/* See https://github.com/microsoft/monaco-editor/issues/2168#issuecomment-780078600 */\n.monaco-aria-container {\n\tposition: absolute !important;\n\ttop: 0; /* avoid being placed underneath a sibling element */\n\theight: 1px;\n\twidth: 1px;\n\tmargin: -1px;\n\toverflow: hidden;\n\tpadding: 0;\n\tclip: rect(1px, 1px, 1px, 1px);\n\tclip-path: inset(50%);\n}\n\n/* The hc-black theme is already high contrast optimized */\n.monaco-editor.hc-black {\n\t-ms-high-contrast-adjust: none;\n}\n/* In case the browser goes into high contrast mode and the editor is not configured with the hc-black theme */\n@media screen and (-ms-high-contrast:active) {\n\n\t/* current line highlight */\n\t.monaco-editor.vs .view-overlays .current-line,\n\t.monaco-editor.vs-dark .view-overlays .current-line {\n\t\tborder-color: windowtext !important;\n\t\tborder-left: 0;\n\t\tborder-right: 0;\n\t}\n\n\t/* view cursors */\n\t.monaco-editor.vs .cursor,\n\t.monaco-editor.vs-dark .cursor {\n\t\tbackground-color: windowtext !important;\n\t}\n\t/* dnd target */\n\t.monaco-editor.vs .dnd-target,\n\t.monaco-editor.vs-dark .dnd-target {\n\t\tborder-color: windowtext !important;\n\t}\n\n\t/* selected text background */\n\t.monaco-editor.vs .selected-text,\n\t.monaco-editor.vs-dark .selected-text {\n\t\tbackground-color: highlight !important;\n\t}\n\n\t/* allow the text to have a transparent background. */\n\t.monaco-editor.vs .view-line,\n\t.monaco-editor.vs-dark .view-line {\n\t\t-ms-high-contrast-adjust: none;\n\t}\n\n\t/* text color */\n\t.monaco-editor.vs .view-line span,\n\t.monaco-editor.vs-dark .view-line span {\n\t\tcolor: windowtext !important;\n\t}\n\t/* selected text color */\n\t.monaco-editor.vs .view-line span.inline-selected-text,\n\t.monaco-editor.vs-dark .view-line span.inline-selected-text {\n\t\tcolor: highlighttext !important;\n\t}\n\n\t/* allow decorations */\n\t.monaco-editor.vs .view-overlays,\n\t.monaco-editor.vs-dark .view-overlays {\n\t\t-ms-high-contrast-adjust: none;\n\t}\n\n\t/* various decorations */\n\t.monaco-editor.vs .selectionHighlight,\n\t.monaco-editor.vs-dark .selectionHighlight,\n\t.monaco-editor.vs .wordHighlight,\n\t.monaco-editor.vs-dark .wordHighlight,\n\t.monaco-editor.vs .wordHighlightStrong,\n\t.monaco-editor.vs-dark .wordHighlightStrong,\n\t.monaco-editor.vs .reference-decoration,\n\t.monaco-editor.vs-dark .reference-decoration {\n\t\tborder: 2px dotted highlight !important;\n\t\tbackground: transparent !important;\n\t\tbox-sizing: border-box;\n\t}\n\t.monaco-editor.vs .rangeHighlight,\n\t.monaco-editor.vs-dark .rangeHighlight {\n\t\tbackground: transparent !important;\n\t\tborder: 1px dotted activeborder !important;\n\t\tbox-sizing: border-box;\n\t}\n\t.monaco-editor.vs .bracket-match,\n\t.monaco-editor.vs-dark .bracket-match {\n\t\tborder-color: windowtext !important;\n\t\tbackground: transparent !important;\n\t}\n\n\t/* find widget */\n\t.monaco-editor.vs .findMatch,\n\t.monaco-editor.vs-dark .findMatch,\n\t.monaco-editor.vs .currentFindMatch,\n\t.monaco-editor.vs-dark .currentFindMatch {\n\t\tborder: 2px dotted activeborder !important;\n\t\tbackground: transparent !important;\n\t\tbox-sizing: border-box;\n\t}\n\t.monaco-editor.vs .find-widget,\n\t.monaco-editor.vs-dark .find-widget {\n\t\tborder: 1px solid windowtext;\n\t}\n\n\t/* list - used by suggest widget */\n\t.monaco-editor.vs .monaco-list .monaco-list-row,\n\t.monaco-editor.vs-dark .monaco-list .monaco-list-row {\n\t\t-ms-high-contrast-adjust: none;\n\t\tcolor: windowtext !important;\n\t}\n\t.monaco-editor.vs .monaco-list .monaco-list-row.focused,\n\t.monaco-editor.vs-dark .monaco-list .monaco-list-row.focused {\n\t\tcolor: highlighttext !important;\n\t\tbackground-color: highlight !important;\n\t}\n\t.monaco-editor.vs .monaco-list .monaco-list-row:hover,\n\t.monaco-editor.vs-dark .monaco-list .monaco-list-row:hover {\n\t\tbackground: transparent !important;\n\t\tborder: 1px solid highlight;\n\t\tbox-sizing: border-box;\n\t}\n\n\t/* scrollbars */\n\t.monaco-editor.vs .monaco-scrollable-element > .scrollbar,\n\t.monaco-editor.vs-dark .monaco-scrollable-element > .scrollbar {\n\t\t-ms-high-contrast-adjust: none;\n\t\tbackground: background !important;\n\t\tborder: 1px solid windowtext;\n\t\tbox-sizing: border-box;\n\t}\n\t.monaco-editor.vs .monaco-scrollable-element > .scrollbar > .slider,\n\t.monaco-editor.vs-dark .monaco-scrollable-element > .scrollbar > .slider {\n\t\tbackground: windowtext !important;\n\t}\n\t.monaco-editor.vs .monaco-scrollable-element > .scrollbar > .slider:hover,\n\t.monaco-editor.vs-dark .monaco-scrollable-element > .scrollbar > .slider:hover {\n\t\tbackground: highlight !important;\n\t}\n\t.monaco-editor.vs .monaco-scrollable-element > .scrollbar > .slider.active,\n\t.monaco-editor.vs-dark .monaco-scrollable-element > .scrollbar > .slider.active {\n\t\tbackground: highlight !important;\n\t}\n\n\t/* overview ruler */\n\t.monaco-editor.vs .decorationsOverviewRuler,\n\t.monaco-editor.vs-dark .decorationsOverviewRuler {\n\t\topacity: 0;\n\t}\n\n\t/* minimap */\n\t.monaco-editor.vs .minimap,\n\t.monaco-editor.vs-dark .minimap {\n\t\tdisplay: none;\n\t}\n\n\t/* squiggles */\n\t.monaco-editor.vs .squiggly-d-error,\n\t.monaco-editor.vs-dark .squiggly-d-error {\n\t\tbackground: transparent !important;\n\t\tborder-bottom: 4px double #E47777;\n\t}\n\t.monaco-editor.vs .squiggly-c-warning,\n\t.monaco-editor.vs-dark .squiggly-c-warning {\n\t\tborder-bottom: 4px double #71B771;\n\t}\n\t.monaco-editor.vs .squiggly-b-info,\n\t.monaco-editor.vs-dark .squiggly-b-info {\n\t\tborder-bottom: 4px double #71B771;\n\t}\n\t.monaco-editor.vs .squiggly-a-hint,\n\t.monaco-editor.vs-dark .squiggly-a-hint {\n\t\tborder-bottom: 4px double #6c6c6c;\n\t}\n\n\t/* contextmenu */\n\t.monaco-editor.vs .monaco-menu .monaco-action-bar.vertical .action-menu-item:focus .action-label,\n\t.monaco-editor.vs-dark .monaco-menu .monaco-action-bar.vertical .action-menu-item:focus .action-label {\n\t\t-ms-high-contrast-adjust: none;\n\t\tcolor: highlighttext !important;\n\t\tbackground-color: highlight !important;\n\t}\n\t.monaco-editor.vs .monaco-menu .monaco-action-bar.vertical .action-menu-item:hover .action-label,\n\t.monaco-editor.vs-dark .monaco-menu .monaco-action-bar.vertical .action-menu-item:hover .action-label {\n\t\t-ms-high-contrast-adjust: none;\n\t\tbackground: transparent !important;\n\t\tborder: 1px solid highlight;\n\t\tbox-sizing: border-box;\n\t}\n\n\t/* diff editor */\n\t.monaco-diff-editor.vs .diffOverviewRuler,\n\t.monaco-diff-editor.vs-dark .diffOverviewRuler {\n\t\tdisplay: none;\n\t}\n\t.monaco-editor.vs .line-insert,\n\t.monaco-editor.vs-dark .line-insert,\n\t.monaco-editor.vs .line-delete,\n\t.monaco-editor.vs-dark .line-delete {\n\t\tbackground: transparent !important;\n\t\tborder: 1px solid highlight !important;\n\t\tbox-sizing: border-box;\n\t}\n\t.monaco-editor.vs .char-insert,\n\t.monaco-editor.vs-dark .char-insert,\n\t.monaco-editor.vs .char-delete,\n\t.monaco-editor.vs-dark .char-delete {\n\t\tbackground: transparent !important;\n\t}\n}\n\n/*.monaco-editor.vs [tabindex="0"]:focus {\n\toutline: 1px solid rgba(0, 122, 204, 0.4);\n\toutline-offset: -1px;\n\topacity: 1 !important;\n}\n\n.monaco-editor.vs-dark [tabindex="0"]:focus {\n\toutline: 1px solid rgba(14, 99, 156, 0.6);\n\toutline-offset: -1px;\n\topacity: 1 !important;\n}*/\n',""]),t.Z=s},55723:function(e,t,i){"use strict";var n=i(8081),o=i.n(n),r=i(23645),s=i.n(r)()(o());s.push([e.id,"/*---------------------------------------------------------------------------------------------\n * Copyright (c) Microsoft Corporation. All rights reserved.\n * Licensed under the MIT License. See License.txt in the project root for license information.\n *--------------------------------------------------------------------------------------------*/\n\n.monaco-action-bar .action-item.menu-entry .action-label.icon {\n\twidth: 16px;\n\theight: 16px;\n\tbackground-repeat: no-repeat;\n\tbackground-position: 50%;\n\tbackground-size: 16px;\n}\n\n.monaco-action-bar .action-item.menu-entry .action-label {\n\tbackground-image: var(--menu-entry-icon-light);\n}\n\n.vs-dark .monaco-action-bar .action-item.menu-entry .action-label,\n.hc-black .monaco-action-bar .action-item.menu-entry .action-label {\n\tbackground-image: var(--menu-entry-icon-dark);\n}\n\n\n.monaco-dropdown-with-default {\n\tdisplay: flex !important;\n\tflex-direction: row;\n\tborder-radius: 5px;\n}\n\n.monaco-dropdown-with-default > .action-container > .action-label {\n\tmargin-right: 0;\n}\n\n.monaco-dropdown-with-default > .action-container.menu-entry > .action-label.icon {\n\twidth: 16px;\n\theight: 16px;\n\tbackground-repeat: no-repeat;\n\tbackground-position: 50%;\n\tbackground-size: 16px;\n}\n\n.monaco-dropdown-with-default > .action-container.menu-entry > .action-label {\n\tbackground-image: var(--menu-entry-icon-light);\n}\n\n.vs-dark .monaco-dropdown-with-default > .action-container.menu-entry > .action-label,\n.hc-black .monaco-dropdown-with-default > .action-container.menu-entry > .action-label {\n\tbackground-image: var(--menu-entry-icon-dark);\n}\n\n.monaco-dropdown-with-default > .dropdown-action-container > .monaco-dropdown > .dropdown-label .codicon[class*='codicon-'] {\n\tfont-size: 12px;\n\tpadding-left: 0px;\n\tpadding-right: 0px;\n\tline-height: 16px;\n\tmargin-left: -3px;\n}\n\n.monaco-dropdown-with-default > .dropdown-action-container > .monaco-dropdown > .dropdown-label > .action-label {\n\tdisplay: block;\n\tbackground-size: 16px;\n\tbackground-position: center center;\n\tbackground-repeat: no-repeat;\n}\n",""]),t.Z=s},39919:function(e,t,i){"use strict";var n=i(8081),o=i.n(n),r=i(23645),s=i.n(r)()(o());s.push([e.id,"/*---------------------------------------------------------------------------------------------\n * Copyright (c) Microsoft Corporation. All rights reserved.\n * Licensed under the MIT License. See License.txt in the project root for license information.\n *--------------------------------------------------------------------------------------------*/\n\n.context-view .monaco-menu {\n\tmin-width: 130px;\n}\n\n",""]),t.Z=s},23645:function(e){"use strict";e.exports=function(e){var t=[];return t.toString=function(){return this.map((function(t){var i="",n=void 0!==t[5];return t[4]&&(i+="@supports (".concat(t[4],") {")),t[2]&&(i+="@media ".concat(t[2]," {")),n&&(i+="@layer".concat(t[5].length>0?" ".concat(t[5]):""," {")),i+=e(t),n&&(i+="}"),t[2]&&(i+="}"),t[4]&&(i+="}"),i})).join("")},t.i=function(e,i,n,o,r){"string"==typeof e&&(e=[[null,e,void 0]]);var s={};if(n)for(var a=0;a0?" ".concat(d[5]):""," {").concat(d[1],"}")),d[5]=r),i&&(d[2]?(d[1]="@media ".concat(d[2]," {").concat(d[1],"}"),d[2]=i):d[2]=i),o&&(d[4]?(d[1]="@supports (".concat(d[4],") {").concat(d[1],"}"),d[4]=o):d[4]="".concat(o)),t.push(d))}},t}},61667:function(e){"use strict";e.exports=function(e,t){return t||(t={}),e?(e=String(e.__esModule?e.default:e),/^['"].*['"]$/.test(e)&&(e=e.slice(1,-1)),t.hash&&(e+=t.hash),/["'() \t\n]|(%20)/.test(e)||t.needQuotes?'"'.concat(e.replace(/"/g,'\\"').replace(/\n/g,"\\n"),'"'):e):e}},8081:function(e){"use strict";e.exports=function(e){return e[1]}},26641:function(e,t,i){"use strict";i.r(t),i.d(t,{PixelRatio:function(){return l},getZoomFactor:function(){return c},isAndroid:function(){return _},isChrome:function(){return g},isElectron:function(){return f},isFirefox:function(){return u},isSafari:function(){return p},isStandalone:function(){return b},isWebKit:function(){return h},isWebkitWebView:function(){return m}});var n=i(46718),o=i(4004);class r{constructor(){this._zoomFactor=1}getZoomFactor(){return this._zoomFactor}}r.INSTANCE=new r;class s extends o.JT{constructor(){super(),this._onDidChange=this._register(new n.Q5),this.onDidChange=this._onDidChange.event,this._listener=()=>this._handleChange(!0),this._mediaQueryList=null,this._handleChange(!1)}_handleChange(e){this._mediaQueryList&&this._mediaQueryList.removeEventListener("change",this._listener),this._mediaQueryList=matchMedia(`(resolution: ${window.devicePixelRatio}dppx)`),this._mediaQueryList.addEventListener("change",this._listener),e&&this._onDidChange.fire()}}class a extends o.JT{constructor(){super(),this._onDidChange=this._register(new n.Q5),this.onDidChange=this._onDidChange.event,this._value=this._getPixelRatio();const e=this._register(new s);this._register(e.onDidChange((()=>{this._value=this._getPixelRatio(),this._onDidChange.fire(this._value)})))}get value(){return this._value}_getPixelRatio(){const e=document.createElement("canvas").getContext("2d");return(window.devicePixelRatio||1)/(e.webkitBackingStorePixelRatio||e.mozBackingStorePixelRatio||e.msBackingStorePixelRatio||e.oBackingStorePixelRatio||e.backingStorePixelRatio||1)}}const l=new class{constructor(){this._pixelRatioMonitor=null}_getOrCreatePixelRatioMonitor(){return this._pixelRatioMonitor||(this._pixelRatioMonitor=new a),this._pixelRatioMonitor}get value(){return this._getOrCreatePixelRatioMonitor().value}get onDidChange(){return this._getOrCreatePixelRatioMonitor().onDidChange}};function c(){return r.INSTANCE.getZoomFactor()}const d=navigator.userAgent,u=d.indexOf("Firefox")>=0,h=d.indexOf("AppleWebKit")>=0,g=d.indexOf("Chrome")>=0,p=!g&&d.indexOf("Safari")>=0,m=!g&&!p&&h,f=d.indexOf("Electron/")>=0,_=d.indexOf("Android")>=0,b=window.matchMedia&&window.matchMedia("(display-mode: standalone)").matches},85860:function(e,t,i){"use strict";i.d(t,{D:function(){return r}});var n=i(26641),o=i(6954);const r={clipboard:{writeText:o.tY||document.queryCommandSupported&&document.queryCommandSupported("copy")||!!(navigator&&navigator.clipboard&&navigator.clipboard.writeText),readText:o.tY||!!(navigator&&navigator.clipboard&&navigator.clipboard.readText)},keyboard:o.tY||n.isStandalone?0:navigator.keyboard||n.isSafari?1:2,touch:"ontouchstart"in window||navigator.maxTouchPoints>0,pointerEvents:window.PointerEvent&&("ontouchstart"in window||window.navigator.maxTouchPoints>0||navigator.maxTouchPoints>0)}},42560:function(e,t,i){"use strict";i.d(t,{P$:function(){return r},TN:function(){return o},go:function(){return n}});const n={RESOURCES:"ResourceURLs",DOWNLOAD_URL:"DownloadURL",FILES:"Files",TEXT:i(25227).v.text,TERMINALS:"Terminals"};class o{constructor(e){this.data=e}update(){}getData(){return this.data}}const r={CurrentDragAndDropData:void 0}},68695:function(e,t,i){"use strict";i.d(t,{$:function(){return me},$Z:function(){return fe},Ay:function(){return Z},Ce:function(){return de},Cp:function(){return _e},D6:function(){return R},DI:function(){return W},Dx:function(){return A},FK:function(){return H},Fx:function(){return j},GQ:function(){return v},H$:function(){return be},IC:function(){return x},If:function(){return z},OO:function(){return G},PO:function(){return g},R3:function(){return ce},RE:function(){return S},Re:function(){return ie},Ro:function(){return O},Uh:function(){return ve},Uw:function(){return p},V3:function(){return Ce},Y_:function(){return T},_0:function(){return se},_h:function(){return Se},_q:function(){return xe},dS:function(){return Q},dp:function(){return F},fk:function(){return ee},go:function(){return le},i:function(){return B},jL:function(){return L},j_:function(){return y},jg:function(){return U},jt:function(){return we},lI:function(){return k},mc:function(){return ue},mu:function(){return b},nm:function(){return f},q6:function(){return w},tw:function(){return ne},u0:function(){return C},uB:function(){return ke},uN:function(){return te},uU:function(){return K},vL:function(){return re},vY:function(){return Y},w:function(){return V},wY:function(){return ye},wn:function(){return $},xQ:function(){return P},zB:function(){return oe}});var n=i(26641),o=i(85860),r=i(33200),s=i(80428),a=i(40027),l=i(16182),c=i(46718),d=i(4004),u=i(9734),h=i(6954);function g(e){for(;e.firstChild;)e.firstChild.remove()}function p(e){var t;return null!==(t=null==e?void 0:e.isConnected)&&void 0!==t&&t}class m{constructor(e,t,i,n){this._node=e,this._type=t,this._handler=i,this._options=n||!1,this._node.addEventListener(this._type,this._handler,this._options)}dispose(){this._handler&&(this._node.removeEventListener(this._type,this._handler,this._options),this._node=null,this._handler=null)}}function f(e,t,i,n){return new m(e,t,i,n)}function _(e){return function(t){return e(new s.n(t))}}let b=function(e,t,i,n){let o=i;return"click"===t||"mousedown"===t?o=_(i):"keydown"!==t&&"keypress"!==t&&"keyup"!==t||(o=function(e){return function(t){return e(new r.y(t))}}(i)),f(e,t,o,n)},v=function(e,t,i){return C(e,_(t),i)};function C(e,t,i){return f(e,h.gn&&o.D.pointerEvents?ne.POINTER_DOWN:ne.MOUSE_DOWN,t,i)}function w(e,t,i){return f(e,h.gn&&o.D.pointerEvents?ne.POINTER_UP:ne.MOUSE_UP,t,i)}function y(e,t){return f(e,"mouseout",(i=>{let n=i.relatedTarget;for(;n&&n!==e;)n=n.parentNode;n!==e&&t(i)}))}function S(e,t){return f(e,"pointerout",(i=>{let n=i.relatedTarget;for(;n&&n!==e;)n=n.parentNode;n!==e&&t(i)}))}function x(e,t,i){let n=null;const o=e=>r.fire(e),r=new c.Q5({onFirstListenerAdd:()=>{n||(n=new m(e,t,o,i))},onLastListenerRemove:()=>{n&&(n.dispose(),n=null)}});return r}let k,L,E=null;class N{constructor(e,t=0){this._runner=e,this.priority=t,this._canceled=!1}dispose(){this._canceled=!0}execute(){if(!this._canceled)try{this._runner()}catch(e){(0,l.dL)(e)}}static sort(e,t){return t.priority-e.priority}}!function(){let e=[],t=null,i=!1,n=!1,o=()=>{for(i=!1,t=e,e=[],n=!0;t.length>0;)t.sort(N.sort),t.shift().execute();n=!1};L=(t,n=0)=>{let r=new N(t,n);return e.push(r),i||(i=!0,function(e){if(!E){const e=e=>setTimeout((()=>e((new Date).getTime())),0);E=self.requestAnimationFrame||self.msRequestAnimationFrame||self.webkitRequestAnimationFrame||self.mozRequestAnimationFrame||self.oRequestAnimationFrame||e}E.call(self,e)}(o)),r},k=(e,i)=>{if(n){let n=new N(e,i);return t.push(n),n}return L(e,i)}}();const D=function(e,t){return t};class I extends d.JT{constructor(e,t,i,n=D,o=8){super();let r=null,s=0,l=this._register(new a._F),c=()=>{s=(new Date).getTime(),i(r),r=null};this._register(f(e,t,(e=>{r=n(r,e);let t=(new Date).getTime()-s;t>=o?(l.cancel(),c()):l.setIfNotSet(c,o-t)})))}}function T(e,t,i,n,o){return new I(e,t,i,n,o)}function A(e){return document.defaultView.getComputedStyle(e,null)}function R(e){if(e!==document.body)return new O(e.clientWidth,e.clientHeight);if(h.gn&&window.visualViewport)return new O(window.visualViewport.width,window.visualViewport.height);if(window.innerWidth&&window.innerHeight)return new O(window.innerWidth,window.innerHeight);if(document.body&&document.body.clientWidth&&document.body.clientHeight)return new O(document.body.clientWidth,document.body.clientHeight);if(document.documentElement&&document.documentElement.clientWidth&&document.documentElement.clientHeight)return new O(document.documentElement.clientWidth,document.documentElement.clientHeight);throw new Error("Unable to figure out browser width and height")}class M{static convertToPixels(e,t){return parseFloat(t)||0}static getDimension(e,t,i){let n=A(e),o="0";return n&&(o=n.getPropertyValue?n.getPropertyValue(t):n.getAttribute(i)),M.convertToPixels(e,o)}static getBorderLeftWidth(e){return M.getDimension(e,"border-left-width","borderLeftWidth")}static getBorderRightWidth(e){return M.getDimension(e,"border-right-width","borderRightWidth")}static getBorderTopWidth(e){return M.getDimension(e,"border-top-width","borderTopWidth")}static getBorderBottomWidth(e){return M.getDimension(e,"border-bottom-width","borderBottomWidth")}static getPaddingLeft(e){return M.getDimension(e,"padding-left","paddingLeft")}static getPaddingRight(e){return M.getDimension(e,"padding-right","paddingRight")}static getPaddingTop(e){return M.getDimension(e,"padding-top","paddingTop")}static getPaddingBottom(e){return M.getDimension(e,"padding-bottom","paddingBottom")}static getMarginLeft(e){return M.getDimension(e,"margin-left","marginLeft")}static getMarginTop(e){return M.getDimension(e,"margin-top","marginTop")}static getMarginRight(e){return M.getDimension(e,"margin-right","marginRight")}static getMarginBottom(e){return M.getDimension(e,"margin-bottom","marginBottom")}}class O{constructor(e,t){this.width=e,this.height=t}with(e=this.width,t=this.height){return e!==this.width||t!==this.height?new O(e,t):this}static is(e){return"object"==typeof e&&"number"==typeof e.height&&"number"==typeof e.width}static lift(e){return e instanceof O?e:new O(e.width,e.height)}static equals(e,t){return e===t||!(!e||!t)&&e.width===t.width&&e.height===t.height}}function P(e){let t=e.offsetParent,i=e.offsetTop,n=e.offsetLeft;for(;null!==(e=e.parentNode)&&e!==document.body&&e!==document.documentElement;){i-=e.scrollTop;const o=q(e)?null:A(e);o&&(n-="rtl"!==o.direction?e.scrollLeft:-e.scrollLeft),e===t&&(n+=M.getBorderLeftWidth(e),i+=M.getBorderTopWidth(e),i+=e.offsetTop,n+=e.offsetLeft,t=e.offsetParent)}return{left:n,top:i}}function F(e,t,i){"number"==typeof t&&(e.style.width=`${t}px`),"number"==typeof i&&(e.style.height=`${i}px`)}function B(e){let t=e.getBoundingClientRect();return{left:t.left+W.scrollX,top:t.top+W.scrollY,width:t.width,height:t.height}}O.None=new O(0,0);const W=new class{get scrollX(){return"number"==typeof window.scrollX?window.scrollX:document.body.scrollLeft+document.documentElement.scrollLeft}get scrollY(){return"number"==typeof window.scrollY?window.scrollY:document.body.scrollTop+document.documentElement.scrollTop}};function V(e){let t=M.getMarginLeft(e)+M.getMarginRight(e);return e.offsetWidth+t}function H(e){let t=M.getBorderLeftWidth(e)+M.getBorderRightWidth(e),i=M.getPaddingLeft(e)+M.getPaddingRight(e);return e.offsetWidth-t-i}function z(e){let t=M.getBorderTopWidth(e)+M.getBorderBottomWidth(e),i=M.getPaddingTop(e)+M.getPaddingBottom(e);return e.offsetHeight-t-i}function $(e){let t=M.getMarginTop(e)+M.getMarginBottom(e);return e.offsetHeight+t}function U(e,t){for(;e;){if(e===t)return!0;e=e.parentNode}return!1}function j(e,t,i){for(;e&&e.nodeType===e.ELEMENT_NODE;){if(e.classList.contains(t))return e;if(i)if("string"==typeof i){if(e.classList.contains(i))return null}else if(e===i)return null;e=e.parentNode}return null}function K(e,t,i){return!!j(e,t,i)}function q(e){return e&&!!e.host&&!!e.mode}function G(e){return!!Z(e)}function Z(e){for(;e.parentNode;){if(e===document.body)return null;e=e.parentNode}return q(e)?e:null}function Y(){let e=document.activeElement;for(;null==e?void 0:e.shadowRoot;)e=e.shadowRoot.activeElement;return e}function Q(e=document.getElementsByTagName("head")[0]){let t=document.createElement("style");return t.type="text/css",t.media="screen",e.appendChild(t),t}let X=null;function J(){return X||(X=Q()),X}function ee(e,t,i=J()){i&&t&&i.sheet.insertRule(e+"{"+t+"}",0)}function te(e,t=J()){if(!t)return;let i=function(e){var t,i;return(null===(t=null==e?void 0:e.sheet)||void 0===t?void 0:t.rules)?e.sheet.rules:(null===(i=null==e?void 0:e.sheet)||void 0===i?void 0:i.cssRules)?e.sheet.cssRules:[]}(t),n=[];for(let t=0;t=0;e--)t.sheet.deleteRule(n[e])}function ie(e){return"object"==typeof HTMLElement?e instanceof HTMLElement:e&&"object"==typeof e&&1===e.nodeType&&"string"==typeof e.nodeName}const ne={CLICK:"click",AUXCLICK:"auxclick",DBLCLICK:"dblclick",MOUSE_UP:"mouseup",MOUSE_DOWN:"mousedown",MOUSE_OVER:"mouseover",MOUSE_MOVE:"mousemove",MOUSE_OUT:"mouseout",MOUSE_ENTER:"mouseenter",MOUSE_LEAVE:"mouseleave",MOUSE_WHEEL:"wheel",POINTER_UP:"pointerup",POINTER_DOWN:"pointerdown",POINTER_MOVE:"pointermove",CONTEXT_MENU:"contextmenu",WHEEL:"wheel",KEY_DOWN:"keydown",KEY_PRESS:"keypress",KEY_UP:"keyup",LOAD:"load",BEFORE_UNLOAD:"beforeunload",UNLOAD:"unload",PAGE_SHOW:"pageshow",PAGE_HIDE:"pagehide",ABORT:"abort",ERROR:"error",RESIZE:"resize",SCROLL:"scroll",FULLSCREEN_CHANGE:"fullscreenchange",WK_FULLSCREEN_CHANGE:"webkitfullscreenchange",SELECT:"select",CHANGE:"change",SUBMIT:"submit",RESET:"reset",FOCUS:"focus",FOCUS_IN:"focusin",FOCUS_OUT:"focusout",BLUR:"blur",INPUT:"input",STORAGE:"storage",DRAG_START:"dragstart",DRAG:"drag",DRAG_ENTER:"dragenter",DRAG_LEAVE:"dragleave",DRAG_OVER:"dragover",DROP:"drop",DRAG_END:"dragend",ANIMATION_START:n.isWebKit?"webkitAnimationStart":"animationstart",ANIMATION_END:n.isWebKit?"webkitAnimationEnd":"animationend",ANIMATION_ITERATION:n.isWebKit?"webkitAnimationIteration":"animationiteration"},oe={stop:function(e,t){e.preventDefault?e.preventDefault():e.returnValue=!1,t&&(e.stopPropagation?e.stopPropagation():e.cancelBubble=!0)}};function re(e){let t=[];for(let i=0;e&&e.nodeType===e.ELEMENT_NODE;i++)t[i]=e.scrollTop,e=e.parentNode;return t}function se(e,t){for(let i=0;e&&e.nodeType===e.ELEMENT_NODE;i++)e.scrollTop!==t[i]&&(e.scrollTop=t[i]),e=e.parentNode}class ae extends d.JT{constructor(e){super(),this._onDidFocus=this._register(new c.Q5),this.onDidFocus=this._onDidFocus.event,this._onDidBlur=this._register(new c.Q5),this.onDidBlur=this._onDidBlur.event;let t=ae.hasFocusWithin(e),i=!1;const n=()=>{i=!1,t||(t=!0,this._onDidFocus.fire())},o=()=>{t&&(i=!0,window.setTimeout((()=>{i&&(i=!1,t=!1,this._onDidBlur.fire())}),0))};this._refreshStateHandler=()=>{ae.hasFocusWithin(e)!==t&&(t?o():n())},this._register(f(e,ne.FOCUS,n,!0)),this._register(f(e,ne.BLUR,o,!0)),this._register(f(e,ne.FOCUS_IN,(()=>this._refreshStateHandler()))),this._register(f(e,ne.FOCUS_OUT,(()=>this._refreshStateHandler())))}static hasFocusWithin(e){const t=Z(e);return U(t?t.activeElement:document.activeElement,e)}}function le(e){return new ae(e)}function ce(e,...t){if(e.append(...t),1===t.length&&"string"!=typeof t[0])return t[0]}function de(e,t){return e.insertBefore(t,e.firstChild),t}function ue(e,...t){e.innerText="",ce(e,...t)}const he=/([\w\-]+)?(#([\w\-]+))?((\.([\w\-]+))*)/;var ge;function pe(e,t,i,...n){let o=he.exec(t);if(!o)throw new Error("Bad use of emmet");i=Object.assign({},i||{});let r,s=o[1]||"div";return r=e!==ge.HTML?document.createElementNS(e,s):document.createElement(s),o[3]&&(r.id=o[3]),o[4]&&(r.className=o[4].replace(/\./g," ").trim()),Object.keys(i).forEach((e=>{const t=i[e];void 0!==t&&(/^on\w+$/.test(e)?r[e]=t:"selected"===e?t&&r.setAttribute(e,"true"):r.setAttribute(e,t))})),r.append(...n),r}function me(e,t,...i){return pe(ge.HTML,e,t,...i)}function fe(...e){for(let t of e)t.style.display="",t.removeAttribute("aria-hidden")}function _e(...e){for(let t of e)t.style.display="none",t.setAttribute("aria-hidden","true")}function be(e){return Array.prototype.slice.call(document.getElementsByTagName(e),0)}function ve(e){const t=window.devicePixelRatio*e;return Math.max(1,Math.floor(t))/window.devicePixelRatio}function Ce(e){window.open(e,"_blank","noopener")}function we(e){const t=()=>{e(),i=L(t)};let i=L(t);return(0,d.OF)((()=>i.dispose()))}function ye(e){return e?`url('${u.Gi.asBrowserUri(e).toString(!0).replace(/'/g,"%27")}')`:"url('')"}function Se(e){return`'${e.replace(/'/g,"%27")}'`}!function(e){e.HTML="http://www.w3.org/1999/xhtml",e.SVG="http://www.w3.org/2000/svg"}(ge||(ge={})),me.SVG=function(e,t,...i){return pe(ge.SVG,e,t,...i)},u.WX.setPreferredWebSchema(/^https:/.test(window.location.href)?"https":"http");class xe extends c.Q5{constructor(){super(),this._subscriptions=new d.SL,this._keyStatus={altKey:!1,shiftKey:!1,ctrlKey:!1,metaKey:!1},this._subscriptions.add(f(window,"keydown",(e=>{if(e.defaultPrevented)return;const t=new r.y(e);if(6!==t.keyCode||!e.repeat){if(e.altKey&&!this._keyStatus.altKey)this._keyStatus.lastKeyPressed="alt";else if(e.ctrlKey&&!this._keyStatus.ctrlKey)this._keyStatus.lastKeyPressed="ctrl";else if(e.metaKey&&!this._keyStatus.metaKey)this._keyStatus.lastKeyPressed="meta";else if(e.shiftKey&&!this._keyStatus.shiftKey)this._keyStatus.lastKeyPressed="shift";else{if(6===t.keyCode)return;this._keyStatus.lastKeyPressed=void 0}this._keyStatus.altKey=e.altKey,this._keyStatus.ctrlKey=e.ctrlKey,this._keyStatus.metaKey=e.metaKey,this._keyStatus.shiftKey=e.shiftKey,this._keyStatus.lastKeyPressed&&(this._keyStatus.event=e,this.fire(this._keyStatus))}}),!0)),this._subscriptions.add(f(window,"keyup",(e=>{e.defaultPrevented||(!e.altKey&&this._keyStatus.altKey?this._keyStatus.lastKeyReleased="alt":!e.ctrlKey&&this._keyStatus.ctrlKey?this._keyStatus.lastKeyReleased="ctrl":!e.metaKey&&this._keyStatus.metaKey?this._keyStatus.lastKeyReleased="meta":!e.shiftKey&&this._keyStatus.shiftKey?this._keyStatus.lastKeyReleased="shift":this._keyStatus.lastKeyReleased=void 0,this._keyStatus.lastKeyPressed!==this._keyStatus.lastKeyReleased&&(this._keyStatus.lastKeyPressed=void 0),this._keyStatus.altKey=e.altKey,this._keyStatus.ctrlKey=e.ctrlKey,this._keyStatus.metaKey=e.metaKey,this._keyStatus.shiftKey=e.shiftKey,this._keyStatus.lastKeyReleased&&(this._keyStatus.event=e,this.fire(this._keyStatus)))}),!0)),this._subscriptions.add(f(document.body,"mousedown",(()=>{this._keyStatus.lastKeyPressed=void 0}),!0)),this._subscriptions.add(f(document.body,"mouseup",(()=>{this._keyStatus.lastKeyPressed=void 0}),!0)),this._subscriptions.add(f(document.body,"mousemove",(e=>{e.buttons&&(this._keyStatus.lastKeyPressed=void 0)}),!0)),this._subscriptions.add(f(window,"blur",(()=>{this.resetKeyStatus()})))}get keyStatus(){return this._keyStatus}resetKeyStatus(){this.doResetKeyStatus(),this.fire(this._keyStatus)}doResetKeyStatus(){this._keyStatus={altKey:!1,shiftKey:!1,ctrlKey:!1,metaKey:!1}}static getInstance(){return xe.instance||(xe.instance=new xe),xe.instance}dispose(){super.dispose(),this._subscriptions.dispose()}}function ke(e,t){window.matchMedia(e).addEventListener("change",t)}},27163:function(e,t,i){"use strict";i.d(t,{Y:function(){return o},p:function(){return r}});var n=i(46718);class o{constructor(e,t,i){const o=e=>this.emitter.fire(e);this.emitter=new n.Q5({onFirstListenerAdd:()=>e.addEventListener(t,o,i),onLastListenerRemove:()=>e.removeEventListener(t,o,i)})}get event(){return this.emitter.event}dispose(){this.emitter.dispose()}}function r(e){return e.preventDefault(),e.stopPropagation(),e}},17762:function(e,t,i){"use strict";i.d(t,{X:function(){return o},Z:function(){return n}});class n{constructor(e){this.domNode=e,this._maxWidth=-1,this._width=-1,this._height=-1,this._top=-1,this._left=-1,this._bottom=-1,this._right=-1,this._fontFamily="",this._fontWeight="",this._fontSize=-1,this._fontStyle="",this._fontFeatureSettings="",this._textDecoration="",this._lineHeight=-1,this._letterSpacing=-100,this._className="",this._display="",this._position="",this._visibility="",this._color="",this._backgroundColor="",this._layerHint=!1,this._contain="none",this._boxShadow=""}setMaxWidth(e){this._maxWidth!==e&&(this._maxWidth=e,this.domNode.style.maxWidth=this._maxWidth+"px")}setWidth(e){this._width!==e&&(this._width=e,this.domNode.style.width=this._width+"px")}setHeight(e){this._height!==e&&(this._height=e,this.domNode.style.height=this._height+"px")}setTop(e){this._top!==e&&(this._top=e,this.domNode.style.top=this._top+"px")}unsetTop(){-1!==this._top&&(this._top=-1,this.domNode.style.top="")}setLeft(e){this._left!==e&&(this._left=e,this.domNode.style.left=this._left+"px")}setBottom(e){this._bottom!==e&&(this._bottom=e,this.domNode.style.bottom=this._bottom+"px")}setRight(e){this._right!==e&&(this._right=e,this.domNode.style.right=this._right+"px")}setFontFamily(e){this._fontFamily!==e&&(this._fontFamily=e,this.domNode.style.fontFamily=this._fontFamily)}setFontWeight(e){this._fontWeight!==e&&(this._fontWeight=e,this.domNode.style.fontWeight=this._fontWeight)}setFontSize(e){this._fontSize!==e&&(this._fontSize=e,this.domNode.style.fontSize=this._fontSize+"px")}setFontStyle(e){this._fontStyle!==e&&(this._fontStyle=e,this.domNode.style.fontStyle=this._fontStyle)}setFontFeatureSettings(e){this._fontFeatureSettings!==e&&(this._fontFeatureSettings=e,this.domNode.style.fontFeatureSettings=this._fontFeatureSettings)}setTextDecoration(e){this._textDecoration!==e&&(this._textDecoration=e,this.domNode.style.textDecoration=this._textDecoration)}setLineHeight(e){this._lineHeight!==e&&(this._lineHeight=e,this.domNode.style.lineHeight=this._lineHeight+"px")}setLetterSpacing(e){this._letterSpacing!==e&&(this._letterSpacing=e,this.domNode.style.letterSpacing=this._letterSpacing+"px")}setClassName(e){this._className!==e&&(this._className=e,this.domNode.className=this._className)}toggleClassName(e,t){this.domNode.classList.toggle(e,t),this._className=this.domNode.className}setDisplay(e){this._display!==e&&(this._display=e,this.domNode.style.display=this._display)}setPosition(e){this._position!==e&&(this._position=e,this.domNode.style.position=this._position)}setVisibility(e){this._visibility!==e&&(this._visibility=e,this.domNode.style.visibility=this._visibility)}setColor(e){this._color!==e&&(this._color=e,this.domNode.style.color=this._color)}setBackgroundColor(e){this._backgroundColor!==e&&(this._backgroundColor=e,this.domNode.style.backgroundColor=this._backgroundColor)}setLayerHinting(e){this._layerHint!==e&&(this._layerHint=e,this.domNode.style.transform=this._layerHint?"translate3d(0px, 0px, 0px)":"")}setBoxShadow(e){this._boxShadow!==e&&(this._boxShadow=e,this.domNode.style.boxShadow=e)}setContain(e){this._contain!==e&&(this._contain=e,this.domNode.style.contain=this._contain)}setAttribute(e,t){this.domNode.setAttribute(e,t)}removeAttribute(e){this.domNode.removeAttribute(e)}appendChild(e){this.domNode.appendChild(e.domNode)}removeChild(e){this.domNode.removeChild(e.domNode)}}function o(e){return new n(e)}},61604:function(e,t,i){"use strict";i.d(t,{BO:function(){return r},IY:function(){return o},az:function(){return s}});var n=i(68695);function o(e,t={}){const i=s(t);return i.textContent=e,i}function r(e,t={}){const i=s(t);return l(i,function(e,t){const i={type:1,children:[]};let n=0,o=i;const r=[],s=new a(e);for(;!s.eos();){let e=s.next();const i="\\"===e&&0!==c(s.peek(),t);if(i&&(e=s.next()),i||0===c(e,t)||e!==s.peek())if("\n"===e)2===o.type&&(o=r.pop()),o.children.push({type:8});else if(2!==o.type){const t={type:2,content:e};o.children.push(t),r.push(o),o=t}else o.content+=e;else{s.advance(),2===o.type&&(o=r.pop());const i=c(e,t);if(o.type===i||5===o.type&&6===i)o=r.pop();else{const e={type:i,children:[]};5===i&&(e.index=n,n++),o.children.push(e),r.push(o),o=e}}}return 2===o.type&&(o=r.pop()),r.length,i}(e,!!t.renderCodeSegments),t.actionHandler,t.renderCodeSegments),i}function s(e){const t=e.inline?"span":"div",i=document.createElement(t);return e.className&&(i.className=e.className),i}class a{constructor(e){this.source=e,this.index=0}eos(){return this.index>=this.source.length}next(){const e=this.peek();return this.advance(),e}peek(){return this.source[this.index]}advance(){this.index++}}function l(e,t,i,o){let r;if(2===t.type)r=document.createTextNode(t.content||"");else if(3===t.type)r=document.createElement("b");else if(4===t.type)r=document.createElement("i");else if(7===t.type&&o)r=document.createElement("code");else if(5===t.type&&i){const e=document.createElement("a");i.disposables.add(n.mu(e,"click",(e=>{i.callback(String(t.index),e)}))),r=e}else 8===t.type?r=document.createElement("br"):1===t.type&&(r=e);r&&e!==r&&e.appendChild(r),r&&Array.isArray(t.children)&&t.children.forEach((e=>{l(r,e,i,o)}))}function c(e,t){switch(e){case"*":return 3;case"_":return 4;case"[":return 5;case"]":return 6;case"`":return t?7:0;default:return 0}}},9630:function(e,t,i){"use strict";i.d(t,{Z:function(){return c},e:function(){return l}});var n=i(68695),o=i(61769),r=i(80428),s=i(4004),a=i(6954);function l(e,t){let i=new r.n(t);return i.preventDefault(),{leftButton:i.leftButton,buttons:i.buttons,posx:i.posx,posy:i.posy}}class c{constructor(){this._hooks=new s.SL,this._mouseMoveEventMerger=null,this._mouseMoveCallback=null,this._onStopCallback=null}dispose(){this.stopMonitoring(!1),this._hooks.dispose()}stopMonitoring(e,t){if(!this.isMonitoring())return;this._hooks.clear(),this._mouseMoveEventMerger=null,this._mouseMoveCallback=null;const i=this._onStopCallback;this._onStopCallback=null,e&&i&&i(t)}isMonitoring(){return!!this._mouseMoveEventMerger}startMonitoring(e,t,i,s,l){if(this.isMonitoring())return;this._mouseMoveEventMerger=i,this._mouseMoveCallback=s,this._onStopCallback=l;const c=o.E.getSameOriginWindowChain(),d=a.gn?"pointermove":"mousemove",u=c.map((e=>e.window.document)),h=n.Ay(e);h&&u.unshift(h);for(const e of u)this._hooks.add(n.Y_(e,d,(e=>{e.buttons===t?this._mouseMoveCallback(e):this.stopMonitoring(!0)}),((e,t)=>this._mouseMoveEventMerger(e,t)))),this._hooks.add(n.nm(e,"mouseup",(e=>this.stopMonitoring(!0))));if(o.E.hasDifferentOriginAncestor()){let e=c[c.length-1];this._hooks.add(n.nm(e.window.document,"mouseout",(e=>{"html"===new r.n(e).target.tagName.toLowerCase()&&this.stopMonitoring(!0)}))),this._hooks.add(n.nm(e.window.document,"mouseover",(e=>{"html"===new r.n(e).target.tagName.toLowerCase()&&this.stopMonitoring(!0)}))),this._hooks.add(n.nm(e.window.document.body,"mouseleave",(e=>{this.stopMonitoring(!0)})))}}}},61769:function(e,t,i){"use strict";i.d(t,{E:function(){return s}});let n=!1,o=null;function r(e){if(!e.parent||e.parent===e)return null;try{let t=e.location,i=e.parent.location;if("null"!==t.origin&&"null"!==i.origin&&t.origin!==i.origin)return n=!0,null}catch(e){return n=!0,null}return e.parent}class s{static getSameOriginWindowChain(){if(!o){o=[];let e,t=window;do{e=r(t),e?o.push({window:t,iframeElement:t.frameElement||null}):o.push({window:t,iframeElement:null}),t=e}while(t)}return o.slice(0)}static hasDifferentOriginAncestor(){return o||this.getSameOriginWindowChain(),n}static getPositionOfChildWindowRelativeToAncestorWindow(e,t){if(!t||e===t)return{top:0,left:0};let i=0,n=0,o=this.getSameOriginWindowChain();for(const e of o){if(i+=e.window.scrollY,n+=e.window.scrollX,e.window===t)break;if(!e.iframeElement)break;let o=e.iframeElement.getBoundingClientRect();i+=o.top,n+=o.left}return{top:i,left:n}}}},33200:function(e,t,i){"use strict";i.d(t,{y:function(){return c}});var n=i(26641),o=i(37808),r=i(99410),s=i(6954);const a=s.dz?256:2048,l=s.dz?2048:256;class c{constructor(e){this._standardKeyboardEventBrand=!0;let t=e;this.browserEvent=t,this.target=t.target,this.ctrlKey=t.ctrlKey,this.shiftKey=t.shiftKey,this.altKey=t.altKey,this.metaKey=t.metaKey,this.keyCode=function(e){if(e.charCode){let t=String.fromCharCode(e.charCode).toUpperCase();return o.kL.fromString(t)}const t=e.keyCode;if(3===t)return 7;if(n.isFirefox){if(59===t)return 80;if(107===t)return 81;if(109===t)return 83;if(s.dz&&224===t)return 57}else if(n.isWebKit){if(91===t)return 57;if(s.dz&&93===t)return 57;if(!s.dz&&92===t)return 57}return o.H_[t]||0}(t),this.code=t.code,this.ctrlKey=this.ctrlKey||5===this.keyCode,this.altKey=this.altKey||6===this.keyCode,this.shiftKey=this.shiftKey||4===this.keyCode,this.metaKey=this.metaKey||57===this.keyCode,this._asKeybinding=this._computeKeybinding(),this._asRuntimeKeybinding=this._computeRuntimeKeybinding()}preventDefault(){this.browserEvent&&this.browserEvent.preventDefault&&this.browserEvent.preventDefault()}stopPropagation(){this.browserEvent&&this.browserEvent.stopPropagation&&this.browserEvent.stopPropagation()}toKeybinding(){return this._asRuntimeKeybinding}equals(e){return this._asKeybinding===e}_computeKeybinding(){let e=0;5!==this.keyCode&&4!==this.keyCode&&6!==this.keyCode&&57!==this.keyCode&&(e=this.keyCode);let t=0;return this.ctrlKey&&(t|=a),this.altKey&&(t|=512),this.shiftKey&&(t|=1024),this.metaKey&&(t|=l),t|=e,t}_computeRuntimeKeybinding(){let e=0;return 5!==this.keyCode&&4!==this.keyCode&&6!==this.keyCode&&57!==this.keyCode&&(e=this.keyCode),new r.QC(this.ctrlKey,this.shiftKey,this.altKey,this.metaKey,e)}}},80428:function(e,t,i){"use strict";i.d(t,{n:function(){return s},q:function(){return a}});var n=i(26641),o=i(61769),r=i(6954);class s{constructor(e){this.timestamp=Date.now(),this.browserEvent=e,this.leftButton=0===e.button,this.middleButton=1===e.button,this.rightButton=2===e.button,this.buttons=e.buttons,this.target=e.target,this.detail=e.detail||1,"dblclick"===e.type&&(this.detail=2),this.ctrlKey=e.ctrlKey,this.shiftKey=e.shiftKey,this.altKey=e.altKey,this.metaKey=e.metaKey,"number"==typeof e.pageX?(this.posx=e.pageX,this.posy=e.pageY):(this.posx=e.clientX+document.body.scrollLeft+document.documentElement.scrollLeft,this.posy=e.clientY+document.body.scrollTop+document.documentElement.scrollTop);let t=o.E.getPositionOfChildWindowRelativeToAncestorWindow(self,e.view);this.posx-=t.left,this.posy-=t.top}preventDefault(){this.browserEvent.preventDefault()}stopPropagation(){this.browserEvent.stopPropagation()}}class a{constructor(e,t=0,i=0){if(this.browserEvent=e||null,this.target=e?e.target||e.targetNode||e.srcElement:null,this.deltaY=i,this.deltaX=t,e){let t=e,i=e;if(void 0!==t.wheelDeltaY)this.deltaY=t.wheelDeltaY/120;else if(void 0!==i.VERTICAL_AXIS&&i.axis===i.VERTICAL_AXIS)this.deltaY=-i.detail/3;else if("wheel"===e.type){const t=e;t.deltaMode===t.DOM_DELTA_LINE?n.isFirefox&&!r.dz?this.deltaY=-e.deltaY/3:this.deltaY=-e.deltaY:this.deltaY=-e.deltaY/40}if(void 0!==t.wheelDeltaX)n.isSafari&&r.ED?this.deltaX=-t.wheelDeltaX/120:this.deltaX=t.wheelDeltaX/120;else if(void 0!==i.HORIZONTAL_AXIS&&i.axis===i.HORIZONTAL_AXIS)this.deltaX=-e.detail/3;else if("wheel"===e.type){const t=e;t.deltaMode===t.DOM_DELTA_LINE?n.isFirefox&&!r.dz?this.deltaX=-e.deltaX/3:this.deltaX=-e.deltaX:this.deltaX=-e.deltaX/40}0===this.deltaY&&0===this.deltaX&&e.wheelDelta&&(this.deltaY=e.wheelDelta/120)}}preventDefault(){this.browserEvent&&this.browserEvent.preventDefault()}stopPropagation(){this.browserEvent&&this.browserEvent.stopPropagation()}}},83055:function(e,t,i){"use strict";i.d(t,{o:function(){return l},t:function(){return n}});var n,o=i(68695),r=i(57800),s=i(79945),a=i(4004);!function(e){e.Tap="-monaco-gesturetap",e.Change="-monaco-gesturechange",e.Start="-monaco-gesturestart",e.End="-monaco-gesturesend",e.Contextmenu="-monaco-gesturecontextmenu"}(n||(n={}));class l extends a.JT{constructor(){super(),this.dispatched=!1,this.activeTouches={},this.handle=null,this.targets=[],this.ignoreTargets=[],this._lastSetTapCountTime=0,this._register(o.nm(document,"touchstart",(e=>this.onTouchStart(e)),{passive:!1})),this._register(o.nm(document,"touchend",(e=>this.onTouchEnd(e)))),this._register(o.nm(document,"touchmove",(e=>this.onTouchMove(e)),{passive:!1}))}static addTarget(e){return l.isTouchDevice()?(l.INSTANCE||(l.INSTANCE=new l),l.INSTANCE.targets.push(e),{dispose:()=>{l.INSTANCE.targets=l.INSTANCE.targets.filter((t=>t!==e))}}):a.JT.None}static ignoreTarget(e){return l.isTouchDevice()?(l.INSTANCE||(l.INSTANCE=new l),l.INSTANCE.ignoreTargets.push(e),{dispose:()=>{l.INSTANCE.ignoreTargets=l.INSTANCE.ignoreTargets.filter((t=>t!==e))}}):a.JT.None}static isTouchDevice(){return"ontouchstart"in window||navigator.maxTouchPoints>0}dispose(){this.handle&&(this.handle.dispose(),this.handle=null),super.dispose()}onTouchStart(e){let t=Date.now();this.handle&&(this.handle.dispose(),this.handle=null);for(let i=0,o=e.targetTouches.length;i=l.HOLD_DELAY&&Math.abs(a.initialPageX-r.Gb(a.rollingPageX))<30&&Math.abs(a.initialPageY-r.Gb(a.rollingPageY))<30){let e=this.newGestureEvent(n.Contextmenu,a.initialTarget);e.pageX=r.Gb(a.rollingPageX),e.pageY=r.Gb(a.rollingPageY),this.dispatchEvent(e)}else if(1===i){let e=r.Gb(a.rollingPageX),i=r.Gb(a.rollingPageY),n=r.Gb(a.rollingTimestamps)-a.rollingTimestamps[0],o=e-a.rollingPageX[0],s=i-a.rollingPageY[0];const l=this.targets.filter((e=>a.initialTarget instanceof Node&&e.contains(a.initialTarget)));this.inertia(l,t,Math.abs(o)/n,o>0?1:-1,e,Math.abs(s)/n,s>0?1:-1,i)}this.dispatchEvent(this.newGestureEvent(n.End,a.initialTarget)),delete this.activeTouches[s.identifier]}this.dispatched&&(e.preventDefault(),e.stopPropagation(),this.dispatched=!1)}newGestureEvent(e,t){let i=document.createEvent("CustomEvent");return i.initEvent(e,!1,!0),i.initialTarget=t,i.tapCount=0,i}dispatchEvent(e){if(e.type===n.Tap){const t=(new Date).getTime();let i=0;i=t-this._lastSetTapCountTime>l.CLEAR_TAP_COUNT_TIME?1:2,this._lastSetTapCountTime=t,e.tapCount=i}else e.type!==n.Change&&e.type!==n.Contextmenu||(this._lastSetTapCountTime=0);for(let t=0;t{e.initialTarget instanceof Node&&t.contains(e.initialTarget)&&(t.dispatchEvent(e),this.dispatched=!0)}))}inertia(e,t,i,r,s,a,c,d){this.handle=o.jL((()=>{let o=Date.now(),u=o-t,h=0,g=0,p=!0;i+=l.SCROLL_FRICTION*u,a+=l.SCROLL_FRICTION*u,i>0&&(p=!1,h=r*i*u),a>0&&(p=!1,g=c*a*u);let m=this.newGestureEvent(n.Change);m.translationX=h,m.translationY=g,e.forEach((e=>e.dispatchEvent(m))),p||this.inertia(e,o,i,r,s+h,a,c,d+g)}))}onTouchMove(e){let t=Date.now();for(let i=0,o=e.changedTouches.length;i3&&(s.rollingPageX.shift(),s.rollingPageY.shift(),s.rollingTimestamps.shift()),s.rollingPageX.push(o.pageX),s.rollingPageY.push(o.pageY),s.rollingTimestamps.push(t)}this.dispatched&&(e.preventDefault(),e.stopPropagation(),this.dispatched=!1)}}l.SCROLL_FRICTION=-.005,l.HOLD_DELAY=700,l.CLEAR_TAP_COUNT_TIME=400,function(e,t,i,n){var o,r=arguments.length,s=r<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,i):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(e,t,i,n);else for(var a=e.length-1;a>=0;a--)(o=e[a])&&(s=(r<3?o(s):r>3?o(t,i,s):o(t,i))||s);r>3&&s&&Object.defineProperty(t,i,s)}([s.H],l,"isTouchDevice",null)},99512:function(e,t,i){"use strict";i.d(t,{Y:function(){return h},g:function(){return g}});var n=i(26641),o=i(42560),r=i(68695),s=i(83055),a=i(11007),l=i(4004),c=i(6954),d=i(28295),u=(i(63050),i(89982));class h extends l.JT{constructor(e,t,i={}){super(),this.options=i,this._context=e||this,this._action=t,t instanceof a.aU&&this._register(t.onDidChange((e=>{this.element&&this.handleActionChangeEvent(e)})))}handleActionChangeEvent(e){void 0!==e.enabled&&this.updateEnabled(),void 0!==e.checked&&this.updateChecked(),void 0!==e.class&&this.updateClass(),void 0!==e.label&&(this.updateLabel(),this.updateTooltip()),void 0!==e.tooltip&&this.updateTooltip()}get actionRunner(){return this._actionRunner||(this._actionRunner=this._register(new a.Wi)),this._actionRunner}set actionRunner(e){this._actionRunner=e}getAction(){return this._action}isEnabled(){return this._action.enabled}setActionContext(e){this._context=e}render(e){const t=this.element=e;this._register(s.o.addTarget(e));const i=this.options&&this.options.draggable;i&&(e.draggable=!0,n.isFirefox&&this._register((0,r.nm)(e,r.tw.DRAG_START,(e=>{var t;return null===(t=e.dataTransfer)||void 0===t?void 0:t.setData(o.go.TEXT,this._action.label)})))),this._register((0,r.nm)(t,s.t.Tap,(e=>this.onClick(e,!0)))),this._register((0,r.nm)(t,r.tw.MOUSE_DOWN,(e=>{i||r.zB.stop(e,!0),this._action.enabled&&0===e.button&&t.classList.add("active")}))),c.dz&&this._register((0,r.nm)(t,r.tw.CONTEXT_MENU,(e=>{0===e.button&&!0===e.ctrlKey&&this.onClick(e)}))),this._register((0,r.nm)(t,r.tw.CLICK,(e=>{r.zB.stop(e,!0),this.options&&this.options.isMenu||this.onClick(e)}))),this._register((0,r.nm)(t,r.tw.DBLCLICK,(e=>{r.zB.stop(e,!0)}))),[r.tw.MOUSE_UP,r.tw.MOUSE_OUT].forEach((e=>{this._register((0,r.nm)(t,e,(e=>{r.zB.stop(e),t.classList.remove("active")})))}))}onClick(e,t=!1){var i;r.zB.stop(e,!0);const n=d.Jp(this._context)?(null===(i=this.options)||void 0===i?void 0:i.useEventAsContext)?e:{preserveFocus:t}:this._context;this.actionRunner.run(this._action,n)}focus(){this.element&&(this.element.tabIndex=0,this.element.focus(),this.element.classList.add("focused"))}blur(){this.element&&(this.element.blur(),this.element.tabIndex=-1,this.element.classList.remove("focused"))}setFocusable(e){this.element&&(this.element.tabIndex=e?0:-1)}get trapsArrowNavigation(){return!1}updateEnabled(){}updateLabel(){}updateTooltip(){}updateClass(){}updateChecked(){}dispose(){this.element&&(this.element.remove(),this.element=void 0),super.dispose()}}class g extends h{constructor(e,t,i={}){super(e,t,i),this.options=i,this.options.icon=void 0!==i.icon&&i.icon,this.options.label=void 0===i.label||i.label,this.cssClass=""}render(e){super.render(e),this.element&&(this.label=(0,r.R3)(this.element,(0,r.$)("a.action-label"))),this.label&&(this._action.id===a.Z0.ID?this.label.setAttribute("role","presentation"):this.options.isMenu?this.label.setAttribute("role","menuitem"):this.label.setAttribute("role","button")),this.options.label&&this.options.keybinding&&this.element&&((0,r.R3)(this.element,(0,r.$)("span.keybinding")).textContent=this.options.keybinding),this.updateClass(),this.updateLabel(),this.updateTooltip(),this.updateEnabled(),this.updateChecked()}focus(){this.label&&(this.label.tabIndex=0,this.label.focus())}blur(){this.label&&(this.label.tabIndex=-1)}setFocusable(e){this.label&&(this.label.tabIndex=e?0:-1)}updateLabel(){this.options.label&&this.label&&(this.label.textContent=this.getAction().label)}updateTooltip(){let e=null;this.getAction().tooltip?e=this.getAction().tooltip:!this.options.label&&this.getAction().label&&this.options.icon&&(e=this.getAction().label,this.options.keybinding&&(e=u.NC("vs/base/browser/ui/actionbar/actionViewItems",{key:"titleLabel",comment:["action title","action keybinding"]},"{0} ({1})",e,this.options.keybinding))),e&&this.label&&(this.label.title=e)}updateClass(){this.cssClass&&this.label&&this.label.classList.remove(...this.cssClass.split(" ")),this.options.icon?(this.cssClass=this.getAction().class,this.label&&(this.label.classList.add("codicon"),this.cssClass&&this.label.classList.add(...this.cssClass.split(" "))),this.updateEnabled()):this.label&&this.label.classList.remove("codicon")}updateEnabled(){this.getAction().enabled?(this.label&&(this.label.removeAttribute("aria-disabled"),this.label.classList.remove("disabled")),this.element&&this.element.classList.remove("disabled")):(this.label&&(this.label.setAttribute("aria-disabled","true"),this.label.classList.add("disabled")),this.element&&this.element.classList.add("disabled"))}updateChecked(){this.label&&(this.getAction().checked?this.label.classList.add("checked"):this.label.classList.remove("checked"))}}},47995:function(e,t,i){"use strict";i.d(t,{o:function(){return u}});var n=i(68695),o=i(33200),r=i(99512),s=i(11007),a=i(46718),l=i(4004),c=i(28295),d=(i(63050),function(e,t,i,n){return new(i||(i=Promise))((function(o,r){function s(e){try{l(n.next(e))}catch(e){r(e)}}function a(e){try{l(n.throw(e))}catch(e){r(e)}}function l(e){var t;e.done?o(e.value):(t=e.value,t instanceof i?t:new i((function(e){e(t)}))).then(s,a)}l((n=n.apply(e,t||[])).next())}))});class u extends l.JT{constructor(e,t={}){var i,l,c,d,u,h;let g,p;switch(super(),this.triggerKeyDown=!1,this.focusable=!0,this._onDidBlur=this._register(new a.Q5),this.onDidBlur=this._onDidBlur.event,this._onDidCancel=this._register(new a.Q5({onFirstListenerAdd:()=>this.cancelHasListener=!0})),this.onDidCancel=this._onDidCancel.event,this.cancelHasListener=!1,this._onDidRun=this._register(new a.Q5),this.onDidRun=this._onDidRun.event,this._onBeforeRun=this._register(new a.Q5),this.onBeforeRun=this._onBeforeRun.event,this.options=t,this._context=null!==(i=t.context)&&void 0!==i?i:null,this._orientation=null!==(l=this.options.orientation)&&void 0!==l?l:0,this._triggerKeys={keyDown:null!==(d=null===(c=this.options.triggerKeys)||void 0===c?void 0:c.keyDown)&&void 0!==d&&d,keys:null!==(h=null===(u=this.options.triggerKeys)||void 0===u?void 0:u.keys)&&void 0!==h?h:[3,10]},this.options.actionRunner?this._actionRunner=this.options.actionRunner:(this._actionRunner=new s.Wi,this._register(this._actionRunner)),this._register(this._actionRunner.onDidRun((e=>this._onDidRun.fire(e)))),this._register(this._actionRunner.onBeforeRun((e=>this._onBeforeRun.fire(e)))),this._actionIds=[],this.viewItems=[],this.focusedItem=void 0,this.domNode=document.createElement("div"),this.domNode.className="monaco-action-bar",!1!==t.animated&&this.domNode.classList.add("animated"),this._orientation){case 0:g=[15],p=[17];break;case 1:g=[16],p=[18],this.domNode.className+=" vertical"}this._register(n.nm(this.domNode,n.tw.KEY_DOWN,(e=>{const t=new o.y(e);let i=!0;const n="number"==typeof this.focusedItem?this.viewItems[this.focusedItem]:void 0;g&&(t.equals(g[0])||t.equals(g[1]))?i=this.focusPrevious():p&&(t.equals(p[0])||t.equals(p[1]))?i=this.focusNext():t.equals(9)&&this.cancelHasListener?this._onDidCancel.fire():t.equals(14)?i=this.focusFirst():t.equals(13)?i=this.focusLast():t.equals(2)&&n instanceof r.Y&&n.trapsArrowNavigation?i=this.focusNext():this.isTriggerKeyEvent(t)?this._triggerKeys.keyDown?this.doTrigger(t):this.triggerKeyDown=!0:i=!1,i&&(t.preventDefault(),t.stopPropagation())}))),this._register(n.nm(this.domNode,n.tw.KEY_UP,(e=>{const t=new o.y(e);this.isTriggerKeyEvent(t)?(!this._triggerKeys.keyDown&&this.triggerKeyDown&&(this.triggerKeyDown=!1,this.doTrigger(t)),t.preventDefault(),t.stopPropagation()):(t.equals(2)||t.equals(1026))&&this.updateFocusedItem()}))),this.focusTracker=this._register(n.go(this.domNode)),this._register(this.focusTracker.onDidBlur((()=>{n.vY()!==this.domNode&&n.jg(n.vY(),this.domNode)||(this._onDidBlur.fire(),this.focusedItem=void 0,this.previouslyFocusedItem=void 0,this.triggerKeyDown=!1)}))),this._register(this.focusTracker.onDidFocus((()=>this.updateFocusedItem()))),this.actionsList=document.createElement("ul"),this.actionsList.className="actions-container",this.actionsList.setAttribute("role","toolbar"),this.options.ariaLabel&&this.actionsList.setAttribute("aria-label",this.options.ariaLabel),this.domNode.appendChild(this.actionsList),e.appendChild(this.domNode)}refreshRole(){this.length()>=2?this.actionsList.setAttribute("role","toolbar"):this.actionsList.setAttribute("role","presentation")}setFocusable(e){if(this.focusable=e,this.focusable){const e=this.viewItems.find((e=>e instanceof r.Y&&e.isEnabled()));e instanceof r.Y&&e.setFocusable(!0)}else this.viewItems.forEach((e=>{e instanceof r.Y&&e.setFocusable(!1)}))}isTriggerKeyEvent(e){let t=!1;return this._triggerKeys.keys.forEach((i=>{t=t||e.equals(i)})),t}updateFocusedItem(){for(let e=0;et.setActionContext(e)))}get actionRunner(){return this._actionRunner}set actionRunner(e){e&&(this._actionRunner=e,this.viewItems.forEach((t=>t.actionRunner=e)))}getContainer(){return this.domNode}push(e,t={}){const i=Array.isArray(e)?e:[e];let o=c.hj(t.index)?t.index:null;i.forEach((e=>{const i=document.createElement("li");let s;i.className="action-item",i.setAttribute("role","presentation"),this.options.allowContextMenu||this._register(n.nm(i,n.tw.CONTEXT_MENU,(e=>{n.zB.stop(e,!0)}))),this.options.actionViewItemProvider&&(s=this.options.actionViewItemProvider(e)),s||(s=new r.g(this.context,e,t)),s.actionRunner=this._actionRunner,s.setActionContext(this.context),s.render(i),this.focusable&&s instanceof r.Y&&0===this.viewItems.length&&s.setFocusable(!0),null===o||o<0||o>=this.actionsList.children.length?(this.actionsList.appendChild(i),this.viewItems.push(s),this._actionIds.push(e.id)):(this.actionsList.insertBefore(i,this.actionsList.children[o]),this.viewItems.splice(o,0,s),this._actionIds.splice(o,0,e.id),o++)})),"number"==typeof this.focusedItem&&this.focus(this.focusedItem),this.refreshRole()}clear(){(0,l.B9)(this.viewItems),this.viewItems=[],this._actionIds=[],n.PO(this.actionsList),this.refreshRole()}length(){return this.viewItems.length}focus(e){let t,i=!1;if(void 0===e?i=!0:"number"==typeof e?t=e:"boolean"==typeof e&&(i=e),i&&void 0===this.focusedItem){const e=this.viewItems.findIndex((e=>e.isEnabled()));this.focusedItem=-1===e?void 0:e,this.updateFocus(void 0,void 0,!0)}else void 0!==t&&(this.focusedItem=t),this.updateFocus(void 0,void 0,!0)}focusFirst(){return this.focusedItem=this.length()-1,this.focusNext(!0)}focusLast(){return this.focusedItem=0,this.focusPrevious(!0)}focusNext(e){if(void 0===this.focusedItem)this.focusedItem=this.viewItems.length-1;else if(this.viewItems.length<=1)return!1;const t=this.focusedItem;let i;do{if(!e&&this.options.preventLoopNavigation&&this.focusedItem+1>=this.viewItems.length)return this.focusedItem=t,!1;this.focusedItem=(this.focusedItem+1)%this.viewItems.length,i=this.viewItems[this.focusedItem]}while(this.focusedItem!==t&&this.options.focusOnlyEnabledItems&&!i.isEnabled());return this.updateFocus(),!0}focusPrevious(e){if(void 0===this.focusedItem)this.focusedItem=0;else if(this.viewItems.length<=1)return!1;const t=this.focusedItem;let i;do{if(this.focusedItem=this.focusedItem-1,this.focusedItem<0){if(!e&&this.options.preventLoopNavigation)return this.focusedItem=t,!1;this.focusedItem=this.viewItems.length-1}i=this.viewItems[this.focusedItem]}while(this.focusedItem!==t&&this.options.focusOnlyEnabledItems&&!i.isEnabled());return this.updateFocus(!0),!0}updateFocus(e,t,i=!1){var n;void 0===this.focusedItem&&this.actionsList.focus({preventScroll:t}),void 0!==this.previouslyFocusedItem&&this.previouslyFocusedItem!==this.focusedItem&&(null===(n=this.viewItems[this.previouslyFocusedItem])||void 0===n||n.blur());const o=void 0!==this.focusedItem&&this.viewItems[this.focusedItem];if(o){let n=!0;c.mf(o.focus)||(n=!1),this.options.focusOnlyEnabledItems&&c.mf(o.isEnabled)&&!o.isEnabled()&&(n=!1),n?(i||this.previouslyFocusedItem!==this.focusedItem)&&(o.focus(e),this.previouslyFocusedItem=this.focusedItem):(this.actionsList.focus({preventScroll:t}),this.previouslyFocusedItem=void 0)}}doTrigger(e){if(void 0===this.focusedItem)return;const t=this.viewItems[this.focusedItem];if(t instanceof r.Y){const i=null===t._context||void 0===t._context?e:t._context;this.run(t._action,i)}}run(e,t){return d(this,void 0,void 0,(function*(){yield this._actionRunner.run(e,t)}))}dispose(){(0,l.B9)(this.viewItems),this.viewItems=[],this._actionIds=[],this.getContainer().remove(),super.dispose()}}},77339:function(e,t,i){"use strict";i.d(t,{Z9:function(){return k},wW:function(){return x},i7:function(){return L}});var n=i(68695),o=i(6954),r=i(93379),s=i.n(r),a=i(7795),l=i.n(a),c=i(90569),d=i.n(c),u=i(3565),h=i.n(u),g=i(19216),p=i.n(g),m=i(44589),f=i.n(m),_=i(15479),b={};let v,C,w,y,S;function x(e){v=document.createElement("div"),v.className="monaco-aria-container";const t=()=>{const e=document.createElement("div");return e.className="monaco-alert",e.setAttribute("role","alert"),e.setAttribute("aria-atomic","true"),v.appendChild(e),e};C=t(),w=t();const i=()=>{const e=document.createElement("div");return e.className="monaco-status",e.setAttribute("role","complementary"),e.setAttribute("aria-live","polite"),e.setAttribute("aria-atomic","true"),v.appendChild(e),e};y=i(),S=i(),e.appendChild(v)}function k(e){v&&(C.textContent!==e?(n.PO(w),E(C,e)):(n.PO(C),E(w,e)))}function L(e){v&&(o.dz?k(e):y.textContent!==e?(n.PO(S),E(y,e)):(n.PO(y),E(S,e)))}function E(e,t){n.PO(e),t.length>2e4&&(t=t.substr(0,2e4)),e.textContent=t,e.style.visibility="hidden",e.style.visibility="visible"}b.styleTagTransform=f(),b.setAttributes=h(),b.insert=d().bind(null,"head"),b.domAPI=l(),b.insertStyleElement=p(),s()(_.Z,b),_.Z&&_.Z.locals&&_.Z.locals},98973:function(e,t,i){"use strict";i.d(t,{X:function(){return y}});var n=i(43479),o=i(4821),r=i(18689),s=i(46718),a=i(93379),l=i.n(a),c=i(7795),d=i.n(c),u=i(90569),h=i.n(u),g=i(3565),p=i.n(g),m=i(19216),f=i.n(m),_=i(44589),b=i.n(_),v=i(25222),C={};C.styleTagTransform=b(),C.setAttributes=p(),C.insert=h().bind(null,"head"),C.domAPI=d(),C.insertStyleElement=f(),l()(v.Z,C),v.Z&&v.Z.locals&&v.Z.locals;const w={inputActiveOptionBorder:r.Il.fromHex("#007ACC00"),inputActiveOptionForeground:r.Il.fromHex("#FFFFFF"),inputActiveOptionBackground:r.Il.fromHex("#0E639C50")};class y extends n.${constructor(e){super(),this._onChange=this._register(new s.Q5),this.onChange=this._onChange.event,this._onKeyDown=this._register(new s.Q5),this.onKeyDown=this._onKeyDown.event,this._opts=Object.assign(Object.assign({},w),e),this._checked=this._opts.isChecked;const t=["monaco-custom-checkbox"];this._opts.icon&&t.push(...o.dT.asClassNameArray(this._opts.icon)),this._opts.actionClassName&&t.push(...this._opts.actionClassName.split(" ")),this._checked&&t.push("checked"),this.domNode=document.createElement("div"),this.domNode.title=this._opts.title,this.domNode.classList.add(...t),this._opts.notFocusable||(this.domNode.tabIndex=0),this.domNode.setAttribute("role","checkbox"),this.domNode.setAttribute("aria-checked",String(this._checked)),this.domNode.setAttribute("aria-label",this._opts.title),this.applyStyles(),this.onclick(this.domNode,(e=>{this.enabled&&(this.checked=!this._checked,this._onChange.fire(!1),e.preventDefault())})),this.ignoreGesture(this.domNode),this.onkeydown(this.domNode,(e=>{if(10===e.keyCode||3===e.keyCode)return this.checked=!this._checked,this._onChange.fire(!0),void e.preventDefault();this._onKeyDown.fire(e)}))}get enabled(){return"true"!==this.domNode.getAttribute("aria-disabled")}focus(){this.domNode.focus()}get checked(){return this._checked}set checked(e){this._checked=e,this.domNode.setAttribute("aria-checked",String(this._checked)),this.domNode.classList.toggle("checked",this._checked),this.applyStyles()}width(){return 22}style(e){e.inputActiveOptionBorder&&(this._opts.inputActiveOptionBorder=e.inputActiveOptionBorder),e.inputActiveOptionForeground&&(this._opts.inputActiveOptionForeground=e.inputActiveOptionForeground),e.inputActiveOptionBackground&&(this._opts.inputActiveOptionBackground=e.inputActiveOptionBackground),this.applyStyles()}applyStyles(){this.domNode&&(this.domNode.style.borderColor=this._checked&&this._opts.inputActiveOptionBorder?this._opts.inputActiveOptionBorder.toString():"",this.domNode.style.color=this._checked&&this._opts.inputActiveOptionForeground?this._opts.inputActiveOptionForeground.toString():"inherit",this.domNode.style.backgroundColor=this._checked&&this._opts.inputActiveOptionBackground?this._opts.inputActiveOptionBackground.toString():"")}enable(){this.domNode.setAttribute("aria-disabled",String(!1))}disable(){this.domNode.setAttribute("aria-disabled",String(!0))}}},6622:function(e,t,i){"use strict";i.d(t,{a:function(){return C}});var n=i(4821),o=i(93379),r=i.n(o),s=i(7795),a=i.n(s),l=i(90569),c=i.n(l),d=i(3565),u=i.n(d),h=i(19216),g=i.n(h),p=i(44589),m=i.n(p),f=i(65077),_={};_.styleTagTransform=m(),_.setAttributes=u(),_.insert=c().bind(null,"head"),_.domAPI=a(),_.insertStyleElement=g(),r()(f.Z,_),f.Z&&f.Z.locals&&f.Z.locals;var b=i(38533),v={};function C(e){let t=e.definition;for(;t instanceof n.lA;)t=t.definition;return`.codicon-${e.id}:before { content: '${t.fontCharacter}'; }`}v.styleTagTransform=m(),v.setAttributes=u(),v.insert=c().bind(null,"head"),v.domAPI=a(),v.insertStyleElement=g(),r()(b.Z,v),b.Z&&b.Z.locals&&b.Z.locals},38408:function(e,t,i){"use strict";i.d(t,{Z:function(){return y}});var n=i(68695),o=i(18689),r=i(90584),s=i(18039),a=i(93379),l=i.n(a),c=i(7795),d=i.n(c),u=i(90569),h=i.n(u),g=i(3565),p=i.n(g),m=i(19216),f=i.n(m),_=i(44589),b=i.n(_),v=i(76558),C={};C.styleTagTransform=b(),C.setAttributes=p(),C.insert=h().bind(null,"head"),C.domAPI=d(),C.insertStyleElement=f(),l()(v.Z,C),v.Z&&v.Z.locals&&v.Z.locals;const w={badgeBackground:o.Il.fromHex("#4D4D4D"),badgeForeground:o.Il.fromHex("#FFFFFF")};class y{constructor(e,t){this.count=0,this.options=t||Object.create(null),(0,r.jB)(this.options,w,!1),this.badgeBackground=this.options.badgeBackground,this.badgeForeground=this.options.badgeForeground,this.badgeBorder=this.options.badgeBorder,this.element=(0,n.R3)(e,(0,n.$)(".monaco-count-badge")),this.countFormat=this.options.countFormat||"{0}",this.titleFormat=this.options.titleFormat||"",this.setCount(this.options.count||0)}setCount(e){this.count=e,this.render()}setTitleFormat(e){this.titleFormat=e,this.render()}render(){this.element.textContent=(0,s.WU)(this.countFormat,this.count),this.element.title=(0,s.WU)(this.titleFormat,this.count),this.applyStyles()}style(e){this.badgeBackground=e.badgeBackground,this.badgeForeground=e.badgeForeground,this.badgeBorder=e.badgeBorder,this.applyStyles()}applyStyles(){if(this.element){const e=this.badgeBackground?this.badgeBackground.toString():"",t=this.badgeForeground?this.badgeForeground.toString():"",i=this.badgeBorder?this.badgeBorder.toString():"";this.element.style.backgroundColor=e,this.element.style.color=t,this.element.style.borderWidth=i?"1px":"",this.element.style.borderStyle=i?"solid":"",this.element.style.borderColor=i}}}},41174:function(e,t,i){"use strict";i.d(t,{am:function(){return u},n3:function(){return d},vk:function(){return c}});var n=i(98973),o=i(4821),r=i(89982);const s=r.NC("vs/base/browser/ui/findinput/findInputCheckboxes","caseDescription","Match Case"),a=r.NC("vs/base/browser/ui/findinput/findInputCheckboxes","wordsDescription","Match Whole Word"),l=r.NC("vs/base/browser/ui/findinput/findInputCheckboxes","regexDescription","Use Regular Expression");class c extends n.X{constructor(e){super({icon:o.lA.caseSensitive,title:s+e.appendTitle,isChecked:e.isChecked,inputActiveOptionBorder:e.inputActiveOptionBorder,inputActiveOptionForeground:e.inputActiveOptionForeground,inputActiveOptionBackground:e.inputActiveOptionBackground})}}class d extends n.X{constructor(e){super({icon:o.lA.wholeWord,title:a+e.appendTitle,isChecked:e.isChecked,inputActiveOptionBorder:e.inputActiveOptionBorder,inputActiveOptionForeground:e.inputActiveOptionForeground,inputActiveOptionBackground:e.inputActiveOptionBackground})}}class u extends n.X{constructor(e){super({icon:o.lA.regex,title:l+e.appendTitle,isChecked:e.isChecked,inputActiveOptionBorder:e.inputActiveOptionBorder,inputActiveOptionForeground:e.inputActiveOptionForeground,inputActiveOptionBackground:e.inputActiveOptionBackground})}}},35090:function(e,t,i){"use strict";i.d(t,{q:function(){return s}});var n=i(68695),o=i(80563),r=i(90584);class s{constructor(e,t){var i;this.text="",this.title="",this.highlights=[],this.didEverRender=!1,this.supportIcons=null!==(i=null==t?void 0:t.supportIcons)&&void 0!==i&&i,this.domNode=n.R3(e,n.$("span.monaco-highlighted-label"))}get element(){return this.domNode}set(e,t=[],i="",n){e||(e=""),n&&(e=s.escapeNewLines(e,t)),this.didEverRender&&this.text===e&&this.title===i&&r.fS(this.highlights,t)||(this.text=e,this.title=i,this.highlights=t,this.render())}render(){const e=[];let t=0;for(const i of this.highlights){if(i.end===i.start)continue;if(t{n="\r\n"===e?-1:0,o+=i;for(const e of t)e.end<=o||(e.start>=o&&(e.start+=n),e.end>=o&&(e.end+=n));return i+=n,"⏎"}))}}},77982:function(e,t,i){"use strict";i.d(t,{g:function(){return T}});var n=i(68695),o=i(35090),r=i(40027),s=i(60677),a=i(66978),l=i(14329),c=i(4004),d=i(28295),u=i(89982),h=function(e,t,i,n){return new(i||(i=Promise))((function(o,r){function s(e){try{l(n.next(e))}catch(e){r(e)}}function a(e){try{l(n.throw(e))}catch(e){r(e)}}function l(e){var t;e.done?o(e.value):(t=e.value,t instanceof i?t:new i((function(e){e(t)}))).then(s,a)}l((n=n.apply(e,t||[])).next())}))};class g{constructor(e,t,i){this.hoverDelegate=e,this.target=t,this.fadeInAnimation=i}update(e,t){var i;return h(this,void 0,void 0,(function*(){if(this._cancellationTokenSource&&(this._cancellationTokenSource.dispose(!0),this._cancellationTokenSource=void 0),this.isDisposed)return;let n;if(void 0===e||(0,d.HD)(e)||e instanceof HTMLElement)n=e;else if((0,d.mf)(e.markdown)){this._hoverWidget||this.show((0,u.NC)("vs/base/browser/ui/iconLabel/iconLabelHover","iconLabel.loading","Loading..."),t),this._cancellationTokenSource=new s.A;const i=this._cancellationTokenSource.token;if(n=yield e.markdown(i),void 0===n&&(n=e.markdownNotSupportedFallback),this.isDisposed||i.isCancellationRequested)return}else n=null!==(i=e.markdown)&&void 0!==i?i:e.markdownNotSupportedFallback;this.show(n,t)}))}show(e,t){const i=this._hoverWidget;if(this.hasContent(e)){const n={content:e,target:this.target,showPointer:"element"===this.hoverDelegate.placement,hoverPosition:2,skipFadeInAnimation:!this.fadeInAnimation||!!i};this._hoverWidget=this.hoverDelegate.showHover(n,t)}null==i||i.dispose()}hasContent(e){return!(!e||(0,a.Fr)(e)&&!e.value)}get isDisposed(){var e;return null===(e=this._hoverWidget)||void 0===e?void 0:e.isDisposed}dispose(){var e,t;null===(e=this._hoverWidget)||void 0===e||e.dispose(),null===(t=this._cancellationTokenSource)||void 0===t||t.dispose(!0),this._cancellationTokenSource=void 0}}var p=i(90584),m=i(14747),f=i(93379),_=i.n(f),b=i(7795),v=i.n(b),C=i(90569),w=i.n(C),y=i(3565),S=i.n(y),x=i(19216),k=i.n(x),L=i(44589),E=i.n(L),N=i(78963),D={};D.styleTagTransform=E(),D.setAttributes=S(),D.insert=w().bind(null,"head"),D.domAPI=v(),D.insertStyleElement=k(),_()(N.Z,D),N.Z&&N.Z.locals&&N.Z.locals;class I{constructor(e){this._element=e}get element(){return this._element}set textContent(e){this.disposed||e===this._textContent||(this._textContent=e,this._element.textContent=e)}set className(e){this.disposed||e===this._className||(this._className=e,this._element.className=e)}set empty(e){this.disposed||e===this._empty||(this._empty=e,this._element.style.marginLeft=e?"0":"")}dispose(){this.disposed=!0}}class T extends c.JT{constructor(e,t){super(),this.customHovers=new Map,this.domNode=this._register(new I(n.R3(e,n.$(".monaco-icon-label")))),this.labelContainer=n.R3(this.domNode.element,n.$(".monaco-icon-label-container"));const i=n.R3(this.labelContainer,n.$("span.monaco-icon-name-container"));this.descriptionContainer=this._register(new I(n.R3(this.labelContainer,n.$("span.monaco-icon-description-container")))),(null==t?void 0:t.supportHighlights)||(null==t?void 0:t.supportIcons)?this.nameNode=new R(i,!!t.supportIcons):this.nameNode=new A(i),(null==t?void 0:t.supportDescriptionHighlights)?this.descriptionNodeFactory=()=>new o.q(n.R3(this.descriptionContainer.element,n.$("span.label-description")),{supportIcons:!!t.supportIcons}):this.descriptionNodeFactory=()=>this._register(new I(n.R3(this.descriptionContainer.element,n.$("span.label-description")))),this.hoverDelegate=null==t?void 0:t.hoverDelegate}get element(){return this.domNode.element}setLabel(e,t,i){const n=["monaco-icon-label"];i&&(i.extraClasses&&n.push(...i.extraClasses),i.italic&&n.push("italic"),i.strikethrough&&n.push("strikethrough")),this.domNode.className=n.join(" "),this.setupHover((null==i?void 0:i.descriptionTitle)?this.labelContainer:this.element,null==i?void 0:i.title),this.nameNode.setLabel(e,i),(t||this.descriptionNode)&&(this.descriptionNode||(this.descriptionNode=this.descriptionNodeFactory()),this.descriptionNode instanceof o.q?(this.descriptionNode.set(t||"",i?i.descriptionMatches:void 0),this.setupHover(this.descriptionNode.element,null==i?void 0:i.descriptionTitle)):(this.descriptionNode.textContent=t||"",this.setupHover(this.descriptionNode.element,(null==i?void 0:i.descriptionTitle)||""),this.descriptionNode.empty=!t))}setupHover(e,t){const i=this.customHovers.get(e);if(i&&(i.dispose(),this.customHovers.delete(e)),t)if(this.hoverDelegate){const i=function(e,t,i){let o,s;const a=(t,i)=>{var n;t&&(null==s||s.dispose(),s=void 0),i&&(null==o||o.dispose(),o=void 0),null===(n=e.onDidHideHover)||void 0===n||n.call(e)},l=(n,o,a)=>new r._F((()=>h(this,void 0,void 0,(function*(){s&&!s.isDisposed||(s=new g(e,a||t,n>0),yield s.update(i,o))}))),n),d=n.nm(t,n.tw.MOUSE_OVER,(()=>{if(o)return;const i=new c.SL;i.add(n.nm(t,n.tw.MOUSE_LEAVE,(e=>a(!1,e.fromElement===t)),!0)),i.add(n.nm(t,n.tw.MOUSE_DOWN,(()=>a(!0,!0)),!0));const r={targetElements:[t],dispose:()=>{}};if(void 0===e.placement||"mouse"===e.placement){const e=e=>r.x=e.x+10;i.add(n.nm(t,n.tw.MOUSE_MOVE,e,!0))}i.add(l(e.delay,!1,r)),o=i}),!0);return{show:e=>{a(!1,!0),l(0,e)},hide:()=>{a(!0,!0)},update:e=>h(this,void 0,void 0,(function*(){i=e,yield null==s?void 0:s.update(i)})),dispose:()=>{d.dispose(),a(!0,!0)}}}(this.hoverDelegate,e,t);i&&this.customHovers.set(e,i)}else!function(e,t){(0,d.HD)(t)?e.title=(0,l.x$)(t):(null==t?void 0:t.markdownNotSupportedFallback)?e.title=t.markdownNotSupportedFallback:e.removeAttribute("title")}(e,t);else e.removeAttribute("title")}dispose(){super.dispose();for(const e of this.customHovers.values())e.dispose();this.customHovers.clear()}}class A{constructor(e){this.container=e,this.label=void 0,this.singleLabel=void 0}setLabel(e,t){if(this.label!==e||!(0,p.fS)(this.options,t))if(this.label=e,this.options=t,"string"==typeof e)this.singleLabel||(this.container.innerText="",this.container.classList.remove("multiple"),this.singleLabel=n.R3(this.container,n.$("a.label-name",{id:null==t?void 0:t.domId}))),this.singleLabel.textContent=e;else{this.container.innerText="",this.container.classList.add("multiple"),this.singleLabel=void 0;for(let i=0;i{const o={start:n,end:n+e.length},r=i.map((e=>m.e.intersect(o,e))).filter((e=>!m.e.isEmpty(e))).map((({start:e,end:t})=>({start:e-n,end:t-n})));return n=o.end+t.length,r}))}(e,i,null==t?void 0:t.matches);for(let s=0;sthis._limit&&this._initialize(e.slice(e.length-this._limit))}_currentPosition(){const e=this._navigator.current();return e?this._elements.indexOf(e):-1}_initialize(e){this._history=new Set;for(const t of e)this._history.add(t)}get _elements(){const e=[];return this._history.forEach((t=>e.push(t))),e}}var p=i(90584),m=i(93379),f=i.n(m),_=i(7795),b=i.n(_),v=i(90569),C=i.n(v),w=i(3565),y=i.n(w),S=i(19216),x=i.n(S),k=i(44589),L=i.n(k),E=i(7121),N={};N.styleTagTransform=L(),N.setAttributes=y(),N.insert=C().bind(null,"head"),N.domAPI=b(),N.insertStyleElement=x(),f()(E.Z,N),E.Z&&E.Z.locals&&E.Z.locals;var D=i(89982);const I=n.$,T={inputBackground:d.Il.fromHex("#3C3C3C"),inputForeground:d.Il.fromHex("#CCCCCC"),inputValidationInfoBorder:d.Il.fromHex("#55AAFF"),inputValidationInfoBackground:d.Il.fromHex("#063B49"),inputValidationWarningBorder:d.Il.fromHex("#B89500"),inputValidationWarningBackground:d.Il.fromHex("#352A05"),inputValidationErrorBorder:d.Il.fromHex("#BE1100"),inputValidationErrorBackground:d.Il.fromHex("#5A1D1D")};class A extends c.${constructor(e,t,i){var r;super(),this.state="idle",this.maxHeight=Number.POSITIVE_INFINITY,this._onDidChange=this._register(new u.Q5),this.onDidChange=this._onDidChange.event,this._onDidHeightChange=this._register(new u.Q5),this.onDidHeightChange=this._onDidHeightChange.event,this.contextViewProvider=t,this.options=i||Object.create(null),(0,p.jB)(this.options,T,!1),this.message=null,this.placeholder=this.options.placeholder||"",this.tooltip=null!==(r=this.options.tooltip)&&void 0!==r?r:this.placeholder||"",this.ariaLabel=this.options.ariaLabel||"",this.inputBackground=this.options.inputBackground,this.inputForeground=this.options.inputForeground,this.inputBorder=this.options.inputBorder,this.inputValidationInfoBorder=this.options.inputValidationInfoBorder,this.inputValidationInfoBackground=this.options.inputValidationInfoBackground,this.inputValidationInfoForeground=this.options.inputValidationInfoForeground,this.inputValidationWarningBorder=this.options.inputValidationWarningBorder,this.inputValidationWarningBackground=this.options.inputValidationWarningBackground,this.inputValidationWarningForeground=this.options.inputValidationWarningForeground,this.inputValidationErrorBorder=this.options.inputValidationErrorBorder,this.inputValidationErrorBackground=this.options.inputValidationErrorBackground,this.inputValidationErrorForeground=this.options.inputValidationErrorForeground,this.options.validationOptions&&(this.validation=this.options.validationOptions.validation),this.element=n.R3(e,I(".monaco-inputbox.idle"));let a=this.options.flexibleHeight?"textarea":"input",c=n.R3(this.element,I(".ibwrapper"));if(this.input=n.R3(c,I(a+".input.empty")),this.input.setAttribute("autocorrect","off"),this.input.setAttribute("autocapitalize","off"),this.input.setAttribute("spellcheck","false"),this.onfocus(this.input,(()=>this.element.classList.add("synthetic-focus"))),this.onblur(this.input,(()=>this.element.classList.remove("synthetic-focus"))),this.options.flexibleHeight){this.maxHeight="number"==typeof this.options.flexibleMaxHeight?this.options.flexibleMaxHeight:Number.POSITIVE_INFINITY,this.mirror=n.R3(c,I("div.mirror")),this.mirror.innerText=" ",this.scrollableElement=new l.NB(this.element,{vertical:1}),this.options.flexibleWidth&&(this.input.setAttribute("wrap","off"),this.mirror.style.whiteSpace="pre",this.mirror.style.wordWrap="initial"),n.R3(e,this.scrollableElement.getDomNode()),this._register(this.scrollableElement),this._register(this.scrollableElement.onScroll((e=>this.input.scrollTop=e.scrollTop)));const t=this._register(new o.Y(document,"selectionchange")),i=u.ju.filter(t.event,(()=>{const e=document.getSelection();return(null==e?void 0:e.anchorNode)===c}));this._register(i(this.updateScrollDimensions,this)),this._register(this.onDidHeightChange(this.updateScrollDimensions,this))}else this.input.type=this.options.type||"text",this.input.setAttribute("wrap","off");this.ariaLabel&&this.input.setAttribute("aria-label",this.ariaLabel),this.placeholder&&!this.options.showPlaceholderOnFocus&&this.setPlaceHolder(this.placeholder),this.tooltip&&this.setTooltip(this.tooltip),this.oninput(this.input,(()=>this.onValueChange())),this.onblur(this.input,(()=>this.onBlur())),this.onfocus(this.input,(()=>this.onFocus())),this.ignoreGesture(this.input),setTimeout((()=>this.updateMirror()),0),this.options.actions&&(this.actionbar=this._register(new s.o(this.element)),this.actionbar.push(this.options.actions,{icon:!0,label:!1})),this.applyStyles()}onBlur(){this._hideMessage(),this.options.showPlaceholderOnFocus&&this.input.setAttribute("placeholder","")}onFocus(){this._showMessage(),this.options.showPlaceholderOnFocus&&this.input.setAttribute("placeholder",this.placeholder||"")}setPlaceHolder(e){this.placeholder=e,this.input.setAttribute("placeholder",e)}setTooltip(e){this.tooltip=e,this.input.title=e}setAriaLabel(e){this.ariaLabel=e,e?this.input.setAttribute("aria-label",this.ariaLabel):this.input.removeAttribute("aria-label")}getAriaLabel(){return this.ariaLabel}get inputElement(){return this.input}get value(){return this.input.value}set value(e){this.input.value!==e&&(this.input.value=e,this.onValueChange())}get height(){return"number"==typeof this.cachedHeight?this.cachedHeight:n.wn(this.element)}focus(){this.input.focus()}blur(){this.input.blur()}hasFocus(){return document.activeElement===this.input}select(e=null){this.input.select(),e&&(this.input.setSelectionRange(e.start,e.end),e.end===this.input.value.length&&(this.input.scrollLeft=this.input.scrollWidth))}isSelectionAtEnd(){return this.input.selectionEnd===this.input.value.length&&this.input.selectionStart===this.input.selectionEnd}enable(){this.input.removeAttribute("disabled")}disable(){this.blur(),this.input.disabled=!0,this._hideMessage()}get width(){return n.w(this.input)}set width(e){if(this.options.flexibleHeight&&this.options.flexibleWidth){let t=0;this.mirror&&(t=(parseFloat(this.mirror.style.paddingLeft||"")||0)+(parseFloat(this.mirror.style.paddingRight||"")||0)),this.input.style.width=e-t+"px"}else this.input.style.width=e+"px";this.mirror&&(this.mirror.style.width=e+"px")}set paddingRight(e){this.input.style.width=`calc(100% - ${e}px)`,this.mirror&&(this.mirror.style.paddingRight=e+"px")}updateScrollDimensions(){if("number"!=typeof this.cachedContentHeight||"number"!=typeof this.cachedHeight||!this.scrollableElement)return;const e=this.cachedContentHeight,t=this.cachedHeight,i=this.input.scrollTop;this.scrollableElement.setScrollDimensions({scrollHeight:e,height:t}),this.scrollableElement.setScrollPosition({scrollTop:i})}showMessage(e,t){this.message=e,this.element.classList.remove("idle"),this.element.classList.remove("info"),this.element.classList.remove("warning"),this.element.classList.remove("error"),this.element.classList.add(this.classForType(e.type));const i=this.stylesForType(this.message.type);this.element.style.border=i.border?`1px solid ${i.border}`:"",(this.hasFocus()||t)&&this._showMessage()}hideMessage(){this.message=null,this.element.classList.remove("info"),this.element.classList.remove("warning"),this.element.classList.remove("error"),this.element.classList.add("idle"),this._hideMessage(),this.applyStyles()}validate(){let e=null;return this.validation&&(e=this.validation(this.value),e?(this.inputElement.setAttribute("aria-invalid","true"),this.showMessage(e)):this.inputElement.hasAttribute("aria-invalid")&&(this.inputElement.removeAttribute("aria-invalid"),this.hideMessage())),null==e?void 0:e.type}stylesForType(e){switch(e){case 1:return{border:this.inputValidationInfoBorder,background:this.inputValidationInfoBackground,foreground:this.inputValidationInfoForeground};case 2:return{border:this.inputValidationWarningBorder,background:this.inputValidationWarningBackground,foreground:this.inputValidationWarningForeground};default:return{border:this.inputValidationErrorBorder,background:this.inputValidationErrorBackground,foreground:this.inputValidationErrorForeground}}}classForType(e){switch(e){case 1:return"info";case 2:return"warning";default:return"error"}}_showMessage(){if(!this.contextViewProvider||!this.message)return;let e,t,i=()=>e.style.width=n.w(this.element)+"px";this.contextViewProvider.showContextView({getAnchor:()=>this.element,anchorAlignment:1,render:t=>{if(!this.message)return null;e=n.R3(t,I(".monaco-inputbox-container")),i();const o={inline:!0,className:"monaco-inputbox-message"},s=this.message.formatContent?(0,r.BO)(this.message.content,o):(0,r.IY)(this.message.content,o);s.classList.add(this.classForType(this.message.type));const a=this.stylesForType(this.message.type);return s.style.backgroundColor=a.background?a.background.toString():"",s.style.color=a.foreground?a.foreground.toString():"",s.style.border=a.border?`1px solid ${a.border}`:"",n.R3(e,s),null},onHide:()=>{this.state="closed"},layout:i}),t=3===this.message.type?D.NC("vs/base/browser/ui/inputbox/inputBox","alertErrorMessage","Error: {0}",this.message.content):2===this.message.type?D.NC("vs/base/browser/ui/inputbox/inputBox","alertWarningMessage","Warning: {0}",this.message.content):D.NC("vs/base/browser/ui/inputbox/inputBox","alertInfoMessage","Info: {0}",this.message.content),a.Z9(t),this.state="open"}_hideMessage(){this.contextViewProvider&&("open"===this.state&&this.contextViewProvider.hideContextView(),this.state="idle")}onValueChange(){this._onDidChange.fire(this.value),this.validate(),this.updateMirror(),this.input.classList.toggle("empty",!this.value),"open"===this.state&&this.contextViewProvider&&this.contextViewProvider.layout()}updateMirror(){if(!this.mirror)return;const e=this.value,t=10===e.charCodeAt(e.length-1)?" ":"";(e+t).replace(/\u000c/g,"")?this.mirror.textContent=e+t:this.mirror.innerText=" ",this.layout()}style(e){this.inputBackground=e.inputBackground,this.inputForeground=e.inputForeground,this.inputBorder=e.inputBorder,this.inputValidationInfoBackground=e.inputValidationInfoBackground,this.inputValidationInfoForeground=e.inputValidationInfoForeground,this.inputValidationInfoBorder=e.inputValidationInfoBorder,this.inputValidationWarningBackground=e.inputValidationWarningBackground,this.inputValidationWarningForeground=e.inputValidationWarningForeground,this.inputValidationWarningBorder=e.inputValidationWarningBorder,this.inputValidationErrorBackground=e.inputValidationErrorBackground,this.inputValidationErrorForeground=e.inputValidationErrorForeground,this.inputValidationErrorBorder=e.inputValidationErrorBorder,this.applyStyles()}applyStyles(){const e=this.inputBackground?this.inputBackground.toString():"",t=this.inputForeground?this.inputForeground.toString():"",i=this.inputBorder?this.inputBorder.toString():"";this.element.style.backgroundColor=e,this.element.style.color=t,this.input.style.backgroundColor="inherit",this.input.style.color=t,this.element.style.borderWidth=i?"1px":"",this.element.style.borderStyle=i?"solid":"",this.element.style.borderColor=i}layout(){if(!this.mirror)return;const e=this.cachedContentHeight;this.cachedContentHeight=n.wn(this.mirror),e!==this.cachedContentHeight&&(this.cachedHeight=Math.min(this.cachedContentHeight,this.maxHeight),this.input.style.height=this.cachedHeight+"px",this._onDidHeightChange.fire(this.cachedContentHeight))}insertAtCursor(e){const t=this.inputElement,i=t.selectionStart,n=t.selectionEnd,o=t.value;null!==i&&null!==n&&(this.value=o.substr(0,i)+e+o.substr(n),t.setSelectionRange(i+1,i+1),this.layout())}dispose(){this._hideMessage(),this.message=null,this.actionbar&&this.actionbar.dispose(),super.dispose()}}class R extends A{constructor(e,t,i){const n=D.NC("vs/base/browser/ui/inputbox/inputBox",{key:"history.inputbox.hint",comment:["Text will be prefixed with ⇅ plus a single space, then used as a hint where input field keeps history"]},"for history"),o=` or ⇅ ${n}`,r=` (⇅ ${n})`;super(e,t,i),this.history=new g(i.history,100);const s=()=>{if(i.showHistoryHint&&i.showHistoryHint()&&!this.placeholder.endsWith(o)&&!this.placeholder.endsWith(r)&&this.history.getHistory().length){const e=this.placeholder.endsWith(")")?o:r,t=this.placeholder+e;i.showPlaceholderOnFocus&&document.activeElement!==this.input?this.placeholder=t:this.setPlaceHolder(t)}};this.observer=new MutationObserver(((e,t)=>{e.forEach((e=>{e.target.textContent||s()}))})),this.observer.observe(this.input,{attributeFilter:["class"]}),this.onfocus(this.input,(()=>s())),this.onblur(this.input,(()=>{const e=e=>{if(this.placeholder.endsWith(e)){const t=this.placeholder.slice(0,this.placeholder.length-e.length);return i.showPlaceholderOnFocus?this.placeholder=t:this.setPlaceHolder(t),!0}return!1};e(r)||e(o)}))}dispose(){super.dispose(),this.observer&&(this.observer.disconnect(),this.observer=void 0)}addToHistory(){this.value&&this.value!==this.getCurrentValue()&&this.history.add(this.value)}showNextValue(){this.history.has(this.value)||this.addToHistory();let e=this.getNextValue();e&&(e=e===this.value?this.getNextValue():e),e&&(this.value=e,a.i7(this.value))}showPreviousValue(){this.history.has(this.value)||this.addToHistory();let e=this.getPreviousValue();e&&(e=e===this.value?this.getPreviousValue():e),e&&(this.value=e,a.i7(this.value))}getCurrentValue(){let e=this.history.current();return e||(e=this.history.last(),this.history.next()),e}getPreviousValue(){return this.history.previous()||this.history.first()}getNextValue(){return this.history.next()||this.history.last()}}},20768:function(e,t,i){"use strict";i.d(t,{kX:function(){return S},Bv:function(){return E}});var n=i(26641),o=i(42560),r=i(68695),s=i(27163),a=i(83055),l=i(98677),c=i(57800),d=i(40027),u=i(79945),h=i(46718),g=i(4004),p=i(90584),m=i(14747),f=i(98729);function _(e,t){const i=[];for(let n of t){if(e.start>=n.range.end)continue;if(e.end({range:b(e.range,n),size:e.size}))),s=i.map(((t,i)=>({range:{start:e+i,end:e+i+1},size:t.size})));this.groups=function(...e){return function(e){const t=[];let i=null;for(let n of e){const e=n.range.start,o=n.range.end,r=n.size;i&&r===i.size?i.range.end=o:(i={range:{start:e,end:o},size:r},t.push(i))}return t}(e.reduce(((e,t)=>e.concat(t)),[]))}(o,s,r),this._size=this.groups.reduce(((e,t)=>e+t.size*(t.range.end-t.range.start)),0)}get count(){const e=this.groups.length;return e?this.groups[e-1].range.end:0}get size(){return this._size}indexAt(e){if(e<0)return-1;let t=0,i=0;for(let n of this.groups){const o=n.range.end-n.range.start,r=i+o*n.size;if(e{for(const i of e)this.getRenderer(t).disposeTemplate(i.templateData),i.templateData=null})),this.cache.clear()}getRenderer(e){const t=this.renderers.get(e);if(!t)throw new Error(`No renderer found for ${e}`);return t}}var w=function(e,t,i,n){var o,r=arguments.length,s=r<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,i):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(e,t,i,n);else for(var a=e.length-1;a>=0;a--)(o=e[a])&&(s=(r<3?o(s):r>3?o(t,i,s):o(t,i))||s);return r>3&&s&&Object.defineProperty(t,i,s),s};const y={useShadows:!0,verticalScrollMode:1,setRowLineHeight:!0,setRowHeight:!0,supportDynamicHeights:!1,dnd:{getDragElements:e=>[e],getDragURI:()=>null,onDragStart(){},onDragOver:()=>!1,drop(){}},horizontalScrolling:!1,transformOptimization:!0,alwaysConsumeMouseWheel:!0};class S{constructor(e){this.elements=e}update(){}getData(){return this.elements}}class x{constructor(e){this.elements=e}update(){}getData(){return this.elements}}class k{constructor(){this.types=[],this.files=[]}update(e){if(e.types&&this.types.splice(0,this.types.length,...e.types),e.files){this.files.splice(0,this.files.length);for(let t=0;ti,(null==e?void 0:e.getPosInSet)?this.getPosInSet=e.getPosInSet.bind(e):this.getPosInSet=(e,t)=>t+1,(null==e?void 0:e.getRole)?this.getRole=e.getRole.bind(e):this.getRole=e=>"listitem",(null==e?void 0:e.isChecked)?this.isChecked=e.isChecked.bind(e):this.isChecked=e=>{}}}class E{constructor(e,t,i,n=y){if(this.virtualDelegate=t,this.domId="list_id_"+ ++E.InstanceCount,this.renderers=new Map,this.renderWidth=0,this._scrollHeight=0,this.scrollableElementUpdateDisposable=null,this.scrollableElementWidthDelayer=new d.vp(50),this.splicing=!1,this.dragOverAnimationStopDisposable=g.JT.None,this.dragOverMouseY=0,this.canDrop=!1,this.currentDragFeedbackDisposable=g.JT.None,this.onDragLeaveTimeout=g.JT.None,this.disposables=new g.SL,this._onDidChangeContentHeight=new h.Q5,this._horizontalScrolling=!1,n.horizontalScrolling&&n.supportDynamicHeights)throw new Error("Horizontal scrolling and dynamic heights not supported simultaneously");this.items=[],this.itemId=0,this.rangeMap=new v;for(const e of i)this.renderers.set(e.templateId,e);this.cache=this.disposables.add(new C(this.renderers)),this.lastRenderTop=0,this.lastRenderHeight=0,this.domNode=document.createElement("div"),this.domNode.className="monaco-list",this.domNode.classList.add(this.domId),this.domNode.tabIndex=0,this.domNode.classList.toggle("mouse-support","boolean"!=typeof n.mouseSupport||n.mouseSupport),this._horizontalScrolling=(0,p.CJ)(n,(e=>e.horizontalScrolling),y.horizontalScrolling),this.domNode.classList.toggle("horizontal-scrolling",this._horizontalScrolling),this.additionalScrollHeight=void 0===n.additionalScrollHeight?0:n.additionalScrollHeight,this.accessibilityProvider=new L(n.accessibilityProvider),this.rowsContainer=document.createElement("div"),this.rowsContainer.className="monaco-list-rows",(0,p.CJ)(n,(e=>e.transformOptimization),y.transformOptimization)&&(this.rowsContainer.style.transform="translate3d(0px, 0px, 0px)"),this.disposables.add(a.o.addTarget(this.rowsContainer)),this.scrollable=new f.Rm({forceIntegerValues:!0,smoothScrollDuration:(0,p.CJ)(n,(e=>e.smoothScrolling),!1)?125:0,scheduleAtNextAnimationFrame:e=>(0,r.jL)(e)}),this.scrollableElement=this.disposables.add(new l.$Z(this.rowsContainer,{alwaysConsumeMouseWheel:(0,p.CJ)(n,(e=>e.alwaysConsumeMouseWheel),y.alwaysConsumeMouseWheel),horizontal:1,vertical:(0,p.CJ)(n,(e=>e.verticalScrollMode),y.verticalScrollMode),useShadows:(0,p.CJ)(n,(e=>e.useShadows),y.useShadows),mouseWheelScrollSensitivity:n.mouseWheelScrollSensitivity,fastScrollSensitivity:n.fastScrollSensitivity},this.scrollable)),this.domNode.appendChild(this.scrollableElement.getDomNode()),e.appendChild(this.domNode),this.scrollableElement.onScroll(this.onScroll,this,this.disposables),this.disposables.add((0,r.nm)(this.rowsContainer,a.t.Change,(e=>this.onTouchChange(e)))),this.disposables.add((0,r.nm)(this.scrollableElement.getDomNode(),"scroll",(e=>e.target.scrollTop=0))),this.disposables.add((0,r.nm)(this.domNode,"dragover",(e=>this.onDragOver(this.toDragEvent(e))))),this.disposables.add((0,r.nm)(this.domNode,"drop",(e=>this.onDrop(this.toDragEvent(e))))),this.disposables.add((0,r.nm)(this.domNode,"dragleave",(e=>this.onDragLeave(this.toDragEvent(e))))),this.disposables.add((0,r.nm)(this.domNode,"dragend",(e=>this.onDragEnd(e)))),this.setRowLineHeight=(0,p.CJ)(n,(e=>e.setRowLineHeight),y.setRowLineHeight),this.setRowHeight=(0,p.CJ)(n,(e=>e.setRowHeight),y.setRowHeight),this.supportDynamicHeights=(0,p.CJ)(n,(e=>e.supportDynamicHeights),y.supportDynamicHeights),this.dnd=(0,p.CJ)(n,(e=>e.dnd),y.dnd),this.layout()}get contentHeight(){return this.rangeMap.size}get horizontalScrolling(){return this._horizontalScrolling}set horizontalScrolling(e){if(e!==this._horizontalScrolling){if(e&&this.supportDynamicHeights)throw new Error("Horizontal scrolling and dynamic heights not supported simultaneously");if(this._horizontalScrolling=e,this.domNode.classList.toggle("horizontal-scrolling",this._horizontalScrolling),this._horizontalScrolling){for(const e of this.items)this.measureItemWidth(e);this.updateScrollWidth(),this.scrollableElement.setScrollDimensions({width:(0,r.FK)(this.domNode)}),this.rowsContainer.style.width=`${Math.max(this.scrollWidth||0,this.renderWidth)}px`}else this.scrollableElementWidthDelayer.cancel(),this.scrollableElement.setScrollDimensions({width:this.renderWidth,scrollWidth:this.renderWidth}),this.rowsContainer.style.width=""}}updateOptions(e){void 0!==e.additionalScrollHeight&&(this.additionalScrollHeight=e.additionalScrollHeight,this.scrollableElement.setScrollDimensions({scrollHeight:this.scrollHeight})),void 0!==e.smoothScrolling&&this.scrollable.setSmoothScrollDuration(e.smoothScrolling?125:0),void 0!==e.horizontalScrolling&&(this.horizontalScrolling=e.horizontalScrolling),void 0!==e.mouseWheelScrollSensitivity&&this.scrollableElement.updateOptions({mouseWheelScrollSensitivity:e.mouseWheelScrollSensitivity}),void 0!==e.fastScrollSensitivity&&this.scrollableElement.updateOptions({fastScrollSensitivity:e.fastScrollSensitivity})}splice(e,t,i=[]){if(this.splicing)throw new Error("Can't run recursive splices.");this.splicing=!0;try{return this._splice(e,t,i)}finally{this.splicing=!1,this._onDidChangeContentHeight.fire(this.contentHeight)}}_splice(e,t,i=[]){const n=this.getRenderRange(this.lastRenderTop,this.lastRenderHeight),o={start:e,end:e+t},r=m.e.intersect(n,o),s=new Map;for(let e=r.end-1;e>=r.start;e--){const t=this.items[e];if(t.dragStartDisposable.dispose(),t.row){let i=s.get(t.templateId);i||(i=[],s.set(t.templateId,i));const n=this.renderers.get(t.templateId);n&&n.disposeElement&&n.disposeElement(t.element,e,t.row.templateData,t.size),i.push(t.row)}t.row=null}const a={start:e+t,end:this.items.length},l=m.e.intersect(a,n),c=m.e.relativeComplement(a,n),d=i.map((e=>({id:String(this.itemId++),element:e,templateId:this.virtualDelegate.getTemplateId(e),size:this.virtualDelegate.getHeight(e),width:void 0,hasDynamicHeight:!!this.virtualDelegate.hasDynamicHeight&&this.virtualDelegate.hasDynamicHeight(e),lastDynamicHeightWidth:void 0,row:null,uri:void 0,dropTarget:!1,dragStartDisposable:g.JT.None,checkedDisposable:g.JT.None})));let u;0===e&&t>=this.items.length?(this.rangeMap=new v,this.rangeMap.splice(0,0,d),u=this.items,this.items=d):(this.rangeMap.splice(e,t,d),u=this.items.splice(e,t,...d));const h=i.length-t,p=this.getRenderRange(this.lastRenderTop,this.lastRenderHeight),f=b(l,h),_=m.e.intersect(p,f);for(let e=_.start;e<_.end;e++)this.updateItemInDOM(this.items[e],e);const C=m.e.relativeComplement(f,p);for(const e of C)for(let t=e.start;tb(e,h))),y=[{start:e,end:e+i.length},...w].map((e=>m.e.intersect(p,e))),S=this.getNextToLastElement(y);for(const e of y)for(let t=e.start;te.element))}eventuallyUpdateScrollDimensions(){this._scrollHeight=this.contentHeight,this.rowsContainer.style.height=`${this._scrollHeight}px`,this.scrollableElementUpdateDisposable||(this.scrollableElementUpdateDisposable=(0,r.jL)((()=>{this.scrollableElement.setScrollDimensions({scrollHeight:this.scrollHeight}),this.updateScrollWidth(),this.scrollableElementUpdateDisposable=null})))}eventuallyUpdateScrollWidth(){this.horizontalScrolling?this.scrollableElementWidthDelayer.trigger((()=>this.updateScrollWidth())):this.scrollableElementWidthDelayer.cancel()}updateScrollWidth(){if(!this.horizontalScrolling)return;let e=0;for(const t of this.items)void 0!==t.width&&(e=Math.max(e,t.width));this.scrollWidth=e,this.scrollableElement.setScrollDimensions({scrollWidth:0===e?0:e+10})}rerender(){if(this.supportDynamicHeights){for(const e of this.items)e.lastDynamicHeightWidth=void 0;this._rerender(this.lastRenderTop,this.lastRenderHeight)}}get length(){return this.items.length}get renderHeight(){return this.scrollableElement.getScrollDimensions().height}element(e){return this.items[e].element}domElement(e){const t=this.items[e].row;return t&&t.domNode}elementHeight(e){return this.items[e].size}elementTop(e){return this.rangeMap.positionAt(e)}indexAt(e){return this.rangeMap.indexAt(e)}indexAfter(e){return this.rangeMap.indexAfter(e)}layout(e,t){let i={height:"number"==typeof e?e:(0,r.If)(this.domNode)};this.scrollableElementUpdateDisposable&&(this.scrollableElementUpdateDisposable.dispose(),this.scrollableElementUpdateDisposable=null,i.scrollHeight=this.scrollHeight),this.scrollableElement.setScrollDimensions(i),void 0!==t&&(this.renderWidth=t,this.supportDynamicHeights&&this._rerender(this.scrollTop,this.renderHeight)),this.horizontalScrolling&&this.scrollableElement.setScrollDimensions({width:"number"==typeof t?t:(0,r.FK)(this.domNode)})}render(e,t,i,n,o,r=!1){const s=this.getRenderRange(t,i),a=m.e.relativeComplement(s,e),l=m.e.relativeComplement(e,s),c=this.getNextToLastElement(a);if(r){const t=m.e.intersect(e,s);for(let e=t.start;en.row.domNode.setAttribute("aria-checked",String(!!e));e(s.value),n.checkedDisposable=s.onDidChange(e)}n.row.domNode.parentElement||(t?this.rowsContainer.insertBefore(n.row.domNode,t):this.rowsContainer.appendChild(n.row.domNode)),this.updateItemInDOM(n,e);const a=this.renderers.get(n.templateId);if(!a)throw new Error(`No renderer found for template id ${n.templateId}`);a&&a.renderElement(n.element,e,n.row.templateData,n.size);const l=this.dnd.getDragURI(n.element);n.dragStartDisposable.dispose(),n.row.domNode.draggable=!!l,l&&(n.dragStartDisposable=(0,r.nm)(n.row.domNode,"dragstart",(e=>this.onDragStart(n.element,l,e)))),this.horizontalScrolling&&(this.measureItemWidth(n),this.eventuallyUpdateScrollWidth())}measureItemWidth(e){if(!e.row||!e.row.domNode)return;e.row.domNode.style.width=n.isFirefox?"-moz-fit-content":"fit-content",e.width=(0,r.FK)(e.row.domNode);const t=window.getComputedStyle(e.row.domNode);t.paddingLeft&&(e.width+=parseFloat(t.paddingLeft)),t.paddingRight&&(e.width+=parseFloat(t.paddingRight)),e.row.domNode.style.width=""}updateItemInDOM(e,t){e.row.domNode.style.top=`${this.elementTop(t)}px`,this.setRowHeight&&(e.row.domNode.style.height=`${e.size}px`),this.setRowLineHeight&&(e.row.domNode.style.lineHeight=`${e.size}px`),e.row.domNode.setAttribute("data-index",`${t}`),e.row.domNode.setAttribute("data-last-element",t===this.length-1?"true":"false"),e.row.domNode.setAttribute("data-parity",t%2==0?"even":"odd"),e.row.domNode.setAttribute("aria-setsize",String(this.accessibilityProvider.getSetSize(e.element,t,this.length))),e.row.domNode.setAttribute("aria-posinset",String(this.accessibilityProvider.getPosInSet(e.element,t))),e.row.domNode.setAttribute("id",this.getElementDomId(t)),e.row.domNode.classList.toggle("drop-target",e.dropTarget)}removeItemFromDOM(e){const t=this.items[e];if(t.dragStartDisposable.dispose(),t.checkedDisposable.dispose(),t.row){const i=this.renderers.get(t.templateId);i&&i.disposeElement&&i.disposeElement(t.element,e,t.row.templateData,t.size),this.cache.release(t.row),t.row=null}this.horizontalScrolling&&this.eventuallyUpdateScrollWidth()}getScrollTop(){return this.scrollableElement.getScrollPosition().scrollTop}setScrollTop(e,t){this.scrollableElementUpdateDisposable&&(this.scrollableElementUpdateDisposable.dispose(),this.scrollableElementUpdateDisposable=null,this.scrollableElement.setScrollDimensions({scrollHeight:this.scrollHeight})),this.scrollableElement.setScrollPosition({scrollTop:e,reuseAnimation:t})}get scrollTop(){return this.getScrollTop()}set scrollTop(e){this.setScrollTop(e)}get scrollHeight(){return this._scrollHeight+(this.horizontalScrolling?10:0)+this.additionalScrollHeight}get onMouseClick(){return h.ju.map(this.disposables.add(new s.Y(this.domNode,"click")).event,(e=>this.toMouseEvent(e)))}get onMouseDblClick(){return h.ju.map(this.disposables.add(new s.Y(this.domNode,"dblclick")).event,(e=>this.toMouseEvent(e)))}get onMouseMiddleClick(){return h.ju.filter(h.ju.map(this.disposables.add(new s.Y(this.domNode,"auxclick")).event,(e=>this.toMouseEvent(e))),(e=>1===e.browserEvent.button))}get onMouseDown(){return h.ju.map(this.disposables.add(new s.Y(this.domNode,"mousedown")).event,(e=>this.toMouseEvent(e)))}get onContextMenu(){return h.ju.any(h.ju.map(this.disposables.add(new s.Y(this.domNode,"contextmenu")).event,(e=>this.toMouseEvent(e))),h.ju.map(this.disposables.add(new s.Y(this.domNode,a.t.Contextmenu)).event,(e=>this.toGestureEvent(e))))}get onTouchStart(){return h.ju.map(this.disposables.add(new s.Y(this.domNode,"touchstart")).event,(e=>this.toTouchEvent(e)))}get onTap(){return h.ju.map(this.disposables.add(new s.Y(this.rowsContainer,a.t.Tap)).event,(e=>this.toGestureEvent(e)))}toMouseEvent(e){const t=this.getItemIndexFromEventTarget(e.target||null),i=void 0===t?void 0:this.items[t];return{browserEvent:e,index:t,element:i&&i.element}}toTouchEvent(e){const t=this.getItemIndexFromEventTarget(e.target||null),i=void 0===t?void 0:this.items[t];return{browserEvent:e,index:t,element:i&&i.element}}toGestureEvent(e){const t=this.getItemIndexFromEventTarget(e.initialTarget||null),i=void 0===t?void 0:this.items[t];return{browserEvent:e,index:t,element:i&&i.element}}toDragEvent(e){const t=this.getItemIndexFromEventTarget(e.target||null),i=void 0===t?void 0:this.items[t];return{browserEvent:e,index:t,element:i&&i.element}}onScroll(e){try{const t=this.getRenderRange(this.lastRenderTop,this.lastRenderHeight);this.render(t,e.scrollTop,e.height,e.scrollLeft,e.scrollWidth),this.supportDynamicHeights&&this._rerender(e.scrollTop,e.height,e.inSmoothScrolling)}catch(t){throw console.error("Got bad scroll event:",e),t}}onTouchChange(e){e.preventDefault(),e.stopPropagation(),this.scrollTop-=e.translationY}onDragStart(e,t,i){if(!i.dataTransfer)return;const n=this.dnd.getDragElements(e);if(i.dataTransfer.effectAllowed="copyMove",i.dataTransfer.setData(o.go.TEXT,t),i.dataTransfer.setDragImage){let e;this.dnd.getDragLabel&&(e=this.dnd.getDragLabel(n,i)),void 0===e&&(e=String(n.length));const t=(0,r.$)(".monaco-drag-image");t.textContent=e,document.body.appendChild(t),i.dataTransfer.setDragImage(t,-10,-10),setTimeout((()=>document.body.removeChild(t)),0)}this.currentDragData=new S(n),o.P$.CurrentDragAndDropData=new x(n),this.dnd.onDragStart&&this.dnd.onDragStart(this.currentDragData,i)}onDragOver(e){if(e.browserEvent.preventDefault(),this.onDragLeaveTimeout.dispose(),o.P$.CurrentDragAndDropData&&"vscode-ui"===o.P$.CurrentDragAndDropData.getData())return!1;if(this.setupDragAndDropScrollTopAnimation(e.browserEvent),!e.browserEvent.dataTransfer)return!1;if(!this.currentDragData)if(o.P$.CurrentDragAndDropData)this.currentDragData=o.P$.CurrentDragAndDropData;else{if(!e.browserEvent.dataTransfer.types)return!1;this.currentDragData=new k}const t=this.dnd.onDragOver(this.currentDragData,e.element,e.index,e.browserEvent);if(this.canDrop="boolean"==typeof t?t:t.accept,!this.canDrop)return this.currentDragFeedback=void 0,this.currentDragFeedbackDisposable.dispose(),!1;let i;if(e.browserEvent.dataTransfer.dropEffect="boolean"!=typeof t&&0===t.effect?"copy":"move",i="boolean"!=typeof t&&t.feedback?t.feedback:void 0===e.index?[-1]:[e.index],i=(0,c.EB)(i).filter((e=>e>=-1&&ee-t)),i=-1===i[0]?[-1]:i,n=this.currentDragFeedback,r=i,Array.isArray(n)&&Array.isArray(r)?(0,c.fS)(n,r):n===r)return!0;var n,r;if(this.currentDragFeedback=i,this.currentDragFeedbackDisposable.dispose(),-1===i[0])this.domNode.classList.add("drop-target"),this.rowsContainer.classList.add("drop-target"),this.currentDragFeedbackDisposable=(0,g.OF)((()=>{this.domNode.classList.remove("drop-target"),this.rowsContainer.classList.remove("drop-target")}));else{for(const e of i){const t=this.items[e];t.dropTarget=!0,t.row&&t.row.domNode.classList.add("drop-target")}this.currentDragFeedbackDisposable=(0,g.OF)((()=>{for(const e of i){const t=this.items[e];t.dropTarget=!1,t.row&&t.row.domNode.classList.remove("drop-target")}}))}return!0}onDragLeave(e){var t,i;this.onDragLeaveTimeout.dispose(),this.onDragLeaveTimeout=(0,d.Vg)((()=>this.clearDragOverFeedback()),100),this.currentDragData&&(null===(i=(t=this.dnd).onDragLeave)||void 0===i||i.call(t,this.currentDragData,e.element,e.index,e.browserEvent))}onDrop(e){if(!this.canDrop)return;const t=this.currentDragData;this.teardownDragAndDropScrollTopAnimation(),this.clearDragOverFeedback(),this.currentDragData=void 0,o.P$.CurrentDragAndDropData=void 0,t&&e.browserEvent.dataTransfer&&(e.browserEvent.preventDefault(),t.update(e.browserEvent.dataTransfer),this.dnd.drop(t,e.element,e.index,e.browserEvent))}onDragEnd(e){this.canDrop=!1,this.teardownDragAndDropScrollTopAnimation(),this.clearDragOverFeedback(),this.currentDragData=void 0,o.P$.CurrentDragAndDropData=void 0,this.dnd.onDragEnd&&this.dnd.onDragEnd(e)}clearDragOverFeedback(){this.currentDragFeedback=void 0,this.currentDragFeedbackDisposable.dispose(),this.currentDragFeedbackDisposable=g.JT.None}setupDragAndDropScrollTopAnimation(e){if(!this.dragOverAnimationDisposable){const e=(0,r.xQ)(this.domNode).top;this.dragOverAnimationDisposable=(0,r.jt)(this.animateDragAndDropScrollTop.bind(this,e))}this.dragOverAnimationStopDisposable.dispose(),this.dragOverAnimationStopDisposable=(0,d.Vg)((()=>{this.dragOverAnimationDisposable&&(this.dragOverAnimationDisposable.dispose(),this.dragOverAnimationDisposable=void 0)}),1e3),this.dragOverMouseY=e.pageY}animateDragAndDropScrollTop(e){if(void 0===this.dragOverMouseY)return;const t=this.dragOverMouseY-e,i=this.renderHeight-35;t<35?this.scrollTop+=Math.max(-14,Math.floor(.3*(t-35))):t>i&&(this.scrollTop+=Math.min(14,Math.floor(.3*(t-i))))}teardownDragAndDropScrollTopAnimation(){this.dragOverAnimationStopDisposable.dispose(),this.dragOverAnimationDisposable&&(this.dragOverAnimationDisposable.dispose(),this.dragOverAnimationDisposable=void 0)}getItemIndexFromEventTarget(e){const t=this.scrollableElement.getDomNode();let i=e;for(;i instanceof HTMLElement&&i!==this.rowsContainer&&t.contains(i);){const e=i.getAttribute("data-index");if(e){const t=Number(e);if(!isNaN(t))return t}i=i.parentElement}}getRenderRange(e,t){return{start:this.rangeMap.indexAt(e),end:this.rangeMap.indexAfter(e+t-1)}}_rerender(e,t,i){const n=this.getRenderRange(e,t);let o,r;e===this.elementTop(n.start)?(o=n.start,r=0):n.end-n.start>1&&(o=n.start+1,r=this.elementTop(o)-e);let s=0;for(;;){const a=this.getRenderRange(e,t);let l=!1;for(let e=a.start;en.splice(e,t,i)))}}var c=i(57800),d=i(40027),u=i(18689),h=i(79945),g=i(46718),p=i(34604),m=i(4004),f=i(1478),_=i(90584),b=i(6954),v=i(28295);i(99704);class C extends Error{constructor(e,t){super(`ListError [${e}] ${t}`)}}var w,y=i(20768),S=function(e,t,i,n){var o,r=arguments.length,s=r<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,i):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(e,t,i,n);else for(var a=e.length-1;a>=0;a--)(o=e[a])&&(s=(r<3?o(s):r>3?o(t,i,s):o(t,i))||s);return r>3&&s&&Object.defineProperty(t,i,s),s},x=function(e,t,i,n){return new(i||(i=Promise))((function(o,r){function s(e){try{l(n.next(e))}catch(e){r(e)}}function a(e){try{l(n.throw(e))}catch(e){r(e)}}function l(e){var t;e.done?o(e.value):(t=e.value,t instanceof i?t:new i((function(e){e(t)}))).then(s,a)}l((n=n.apply(e,t||[])).next())}))};class k{constructor(e){this.trait=e,this.renderedElements=[]}get templateId(){return`template:${this.trait.name}`}renderTemplate(e){return e}renderElement(e,t,i){const n=this.renderedElements.findIndex((e=>e.templateData===i));if(n>=0){const e=this.renderedElements[n];this.trait.unrender(i),e.index=t}else{const e={index:t,templateData:i};this.renderedElements.push(e)}this.trait.renderIndex(t,i)}splice(e,t,i){const n=[];for(const o of this.renderedElements)o.index=e+t&&n.push({index:o.index+i-t,templateData:o.templateData});this.renderedElements=n}renderIndexes(e){for(const{index:t,templateData:i}of this.renderedElements)e.indexOf(t)>-1&&this.trait.renderIndex(t,i)}disposeTemplate(e){const t=this.renderedElements.findIndex((t=>t.templateData===e));t<0||this.renderedElements.splice(t,1)}}class L{constructor(e){this._trait=e,this.length=0,this.indexes=[],this.sortedIndexes=[],this._onChange=new g.Q5,this.onChange=this._onChange.event}get name(){return this._trait}get renderer(){return new k(this)}splice(e,t,i){var n;t=Math.max(0,Math.min(t,this.length-e));const o=i.length-t,r=e+t,s=[...this.sortedIndexes.filter((t=>tt?i+e:-1)).filter((e=>-1!==e)),...this.sortedIndexes.filter((e=>e>=r)).map((e=>e+o))],a=this.length+o;if(this.sortedIndexes.length>0&&0===s.length&&a>0){const t=null!==(n=this.sortedIndexes.find((t=>t>=e)))&&void 0!==n?n:a-1;s.push(Math.min(t,a-1))}this.renderer.splice(e,t,i.length),this._set(s,s),this.length=a}renderIndex(e,t){t.classList.toggle(this._trait,this.contains(e))}unrender(e){e.classList.remove(this._trait)}set(e,t){return this._set(e,[...e].sort($),t)}_set(e,t,i){const n=this.indexes,o=this.sortedIndexes;this.indexes=e,this.sortedIndexes=t;const r=z(o,e);return this.renderer.renderIndexes(r),this._onChange.fire({indexes:e,browserEvent:i}),n}get(){return this.indexes}contains(e){return(0,c.ry)(this.sortedIndexes,e,$)>=0}dispose(){(0,m.B9)(this._onChange)}}S([h.H],L.prototype,"renderer",null);class E extends L{constructor(e){super("selected"),this.setAriaSelected=e}renderIndex(e,t){super.renderIndex(e,t),this.setAriaSelected&&(this.contains(e)?t.setAttribute("aria-selected","true"):t.setAttribute("aria-selected","false"))}}class N{constructor(e,t,i){this.trait=e,this.view=t,this.identityProvider=i}splice(e,t,i){if(!this.identityProvider)return this.trait.splice(e,t,i.map((()=>!1)));const n=this.trait.get().map((e=>this.identityProvider.getId(this.view.element(e)).toString())),o=i.map((e=>n.indexOf(this.identityProvider.getId(e).toString())>-1));this.trait.splice(e,t,o)}}function D(e){return"INPUT"===e.tagName||"TEXTAREA"===e.tagName}function I(e){return!!e.classList.contains("monaco-editor")||!e.classList.contains("monaco-list")&&!!e.parentElement&&I(e.parentElement)}class T{constructor(e,t,i){this.list=e,this.view=t,this.disposables=new m.SL,this.multipleSelectionDisposables=new m.SL,this.onKeyDown.filter((e=>3===e.keyCode)).on(this.onEnter,this,this.disposables),this.onKeyDown.filter((e=>16===e.keyCode)).on(this.onUpArrow,this,this.disposables),this.onKeyDown.filter((e=>18===e.keyCode)).on(this.onDownArrow,this,this.disposables),this.onKeyDown.filter((e=>11===e.keyCode)).on(this.onPageUpArrow,this,this.disposables),this.onKeyDown.filter((e=>12===e.keyCode)).on(this.onPageDownArrow,this,this.disposables),this.onKeyDown.filter((e=>9===e.keyCode)).on(this.onEscape,this,this.disposables),!1!==i.multipleSelectionSupport&&this.onKeyDown.filter((e=>(b.dz?e.metaKey:e.ctrlKey)&&31===e.keyCode)).on(this.onCtrlA,this,this.multipleSelectionDisposables)}get onKeyDown(){return g.ju.chain(this.disposables.add(new o.Y(this.view.domNode,"keydown")).event).filter((e=>!D(e.target))).map((e=>new r.y(e)))}updateOptions(e){void 0!==e.multipleSelectionSupport&&(this.multipleSelectionDisposables.clear(),e.multipleSelectionSupport&&this.onKeyDown.filter((e=>(b.dz?e.metaKey:e.ctrlKey)&&31===e.keyCode)).on(this.onCtrlA,this,this.multipleSelectionDisposables))}onEnter(e){e.preventDefault(),e.stopPropagation(),this.list.setSelection(this.list.getFocus(),e.browserEvent)}onUpArrow(e){e.preventDefault(),e.stopPropagation(),this.list.focusPrevious(1,!1,e.browserEvent);const t=this.list.getFocus()[0];this.list.setAnchor(t),this.list.reveal(t),this.view.domNode.focus()}onDownArrow(e){e.preventDefault(),e.stopPropagation(),this.list.focusNext(1,!1,e.browserEvent);const t=this.list.getFocus()[0];this.list.setAnchor(t),this.list.reveal(t),this.view.domNode.focus()}onPageUpArrow(e){e.preventDefault(),e.stopPropagation(),this.list.focusPreviousPage(e.browserEvent);const t=this.list.getFocus()[0];this.list.setAnchor(t),this.list.reveal(t),this.view.domNode.focus()}onPageDownArrow(e){e.preventDefault(),e.stopPropagation(),this.list.focusNextPage(e.browserEvent);const t=this.list.getFocus()[0];this.list.setAnchor(t),this.list.reveal(t),this.view.domNode.focus()}onCtrlA(e){e.preventDefault(),e.stopPropagation(),this.list.setSelection((0,c.w6)(this.list.length),e.browserEvent),this.list.setAnchor(void 0),this.view.domNode.focus()}onEscape(e){this.list.getSelection().length&&(e.preventDefault(),e.stopPropagation(),this.list.setSelection([],e.browserEvent),this.list.setAnchor(void 0),this.view.domNode.focus())}dispose(){this.disposables.dispose(),this.multipleSelectionDisposables.dispose()}}S([h.H],T.prototype,"onKeyDown",null),function(e){e[e.Idle=0]="Idle",e[e.Typing=1]="Typing"}(w||(w={}));const A=new class{mightProducePrintableCharacter(e){return!(e.ctrlKey||e.metaKey||e.altKey)&&(e.keyCode>=31&&e.keyCode<=56||e.keyCode>=21&&e.keyCode<=30||e.keyCode>=93&&e.keyCode<=102||e.keyCode>=80&&e.keyCode<=90)}};class R{constructor(e,t,i,n){this.list=e,this.view=t,this.keyboardNavigationLabelProvider=i,this.delegate=n,this.enabled=!1,this.state=w.Idle,this.automaticKeyboardNavigation=!0,this.triggered=!1,this.previouslyFocused=-1,this.enabledDisposables=new m.SL,this.disposables=new m.SL,this.updateOptions(e.options)}updateOptions(e){void 0===e.enableKeyboardNavigation||e.enableKeyboardNavigation?this.enable():this.disable(),void 0!==e.automaticKeyboardNavigation&&(this.automaticKeyboardNavigation=e.automaticKeyboardNavigation)}enable(){if(this.enabled)return;const e=g.ju.chain(this.enabledDisposables.add(new o.Y(this.view.domNode,"keydown")).event).filter((e=>!D(e.target))).filter((()=>this.automaticKeyboardNavigation||this.triggered)).map((e=>new r.y(e))).filter((e=>this.delegate.mightProducePrintableCharacter(e))).forEach((e=>e.preventDefault())).map((e=>e.browserEvent.key)).event,t=g.ju.debounce(e,(()=>null),800);g.ju.reduce(g.ju.any(e,t),((e,t)=>null===t?null:(e||"")+t))(this.onInput,this,this.enabledDisposables),t(this.onClear,this,this.enabledDisposables),this.enabled=!0,this.triggered=!1}disable(){this.enabled&&(this.enabledDisposables.clear(),this.enabled=!1,this.triggered=!1)}onClear(){var e;const t=this.list.getFocus();if(t.length>0&&t[0]===this.previouslyFocused){const i=null===(e=this.list.options.accessibilityProvider)||void 0===e?void 0:e.getAriaLabel(this.list.element(t[0]));i&&(0,a.Z9)(i)}this.previouslyFocused=-1}onInput(e){if(!e)return this.state=w.Idle,void(this.triggered=!1);const t=this.list.getFocus(),i=t.length>0?t[0]:0,n=this.state===w.Idle?1:0;this.state=w.Typing;for(let t=0;t!D(e.target))).map((e=>new r.y(e))).filter((e=>!(2!==e.keyCode||e.ctrlKey||e.metaKey||e.shiftKey||e.altKey))).on(this.onTab,this,this.disposables)}onTab(e){if(e.target!==this.view.domNode)return;const t=this.list.getFocus();if(0===t.length)return;const i=this.view.domElement(t[0]);if(!i)return;const n=i.querySelector("[tabIndex]");if(!(n&&n instanceof HTMLElement&&-1!==n.tabIndex))return;const o=window.getComputedStyle(n);"hidden"!==o.visibility&&"none"!==o.display&&(e.preventDefault(),e.stopPropagation(),n.focus())}dispose(){this.disposables.dispose()}}function O(e){return b.dz?e.browserEvent.metaKey:e.browserEvent.ctrlKey}function P(e){return e.browserEvent.shiftKey}const F={isSelectionSingleChangeEvent:O,isSelectionRangeChangeEvent:P};class B{constructor(e){this.list=e,this.disposables=new m.SL,this._onPointer=new g.Q5,this.onPointer=this._onPointer.event,!1!==e.options.multipleSelectionSupport&&(this.multipleSelectionController=this.list.options.multipleSelectionController||F),this.mouseSupport=void 0===e.options.mouseSupport||!!e.options.mouseSupport,this.mouseSupport&&(e.onMouseDown(this.onMouseDown,this,this.disposables),e.onContextMenu(this.onContextMenu,this,this.disposables),e.onMouseDblClick(this.onDoubleClick,this,this.disposables),e.onTouchStart(this.onMouseDown,this,this.disposables),this.disposables.add(s.o.addTarget(e.getHTMLElement()))),g.ju.any(e.onMouseClick,e.onMouseMiddleClick,e.onTap)(this.onViewPointer,this,this.disposables)}updateOptions(e){void 0!==e.multipleSelectionSupport&&(this.multipleSelectionController=void 0,e.multipleSelectionSupport&&(this.multipleSelectionController=this.list.options.multipleSelectionController||F))}isSelectionSingleChangeEvent(e){return!!this.multipleSelectionController&&this.multipleSelectionController.isSelectionSingleChangeEvent(e)}isSelectionRangeChangeEvent(e){return!!this.multipleSelectionController&&this.multipleSelectionController.isSelectionRangeChangeEvent(e)}isSelectionChangeEvent(e){return this.isSelectionSingleChangeEvent(e)||this.isSelectionRangeChangeEvent(e)}onMouseDown(e){I(e.browserEvent.target)||document.activeElement!==e.browserEvent.target&&this.list.domFocus()}onContextMenu(e){if(I(e.browserEvent.target))return;const t=void 0===e.index?[]:[e.index];this.list.setFocus(t,e.browserEvent)}onViewPointer(e){if(!this.mouseSupport)return;if(D(e.browserEvent.target)||I(e.browserEvent.target))return;const t=e.index;return void 0===t?(this.list.setFocus([],e.browserEvent),this.list.setSelection([],e.browserEvent),void this.list.setAnchor(void 0)):this.isSelectionRangeChangeEvent(e)||this.isSelectionChangeEvent(e)?this.changeSelection(e):(this.list.setFocus([t],e.browserEvent),this.list.setAnchor(t),(i=e.browserEvent)instanceof MouseEvent&&2===i.button||this.list.setSelection([t],e.browserEvent),void this._onPointer.fire(e));var i}onDoubleClick(e){if(D(e.browserEvent.target)||I(e.browserEvent.target))return;if(this.isSelectionChangeEvent(e))return;const t=this.list.getFocus();this.list.setSelection(t,e.browserEvent)}changeSelection(e){const t=e.index;let i=this.list.getAnchor();if(this.isSelectionRangeChangeEvent(e)){if(void 0===i){const e=this.list.getFocus()[0];i=null!=e?e:t,this.list.setAnchor(i)}const n=Math.min(i,t),o=Math.max(i,t),r=(0,c.w6)(n,o+1),s=this.list.getSelection(),a=function(e,t){const i=e.indexOf(t);if(-1===i)return[];const n=[];let o=i-1;for(;o>=0&&e[o]===t-(i-o);)n.push(e[o--]);for(n.reverse(),o=i;o=e.length)i.push(t[o++]);else if(o>=t.length)i.push(e[n++]);else{if(e[n]===t[o]){n++,o++;continue}e[n]e!==t));this.list.setFocus([t]),this.list.setAnchor(t),i.length===n.length?this.list.setSelection([...n,t],e.browserEvent):this.list.setSelection(n,e.browserEvent)}}dispose(){this.disposables.dispose()}}class W{constructor(e,t){this.styleElement=e,this.selectorSuffix=t}style(e){const t=this.selectorSuffix&&`.${this.selectorSuffix}`,i=[];e.listBackground&&(e.listBackground.isOpaque()?i.push(`.monaco-list${t} .monaco-list-rows { background: ${e.listBackground}; }`):b.dz||console.warn(`List with id '${this.selectorSuffix}' was styled with a non-opaque background color. This will break sub-pixel antialiasing.`)),e.listFocusBackground&&(i.push(`.monaco-list${t}:focus .monaco-list-row.focused { background-color: ${e.listFocusBackground}; }`),i.push(`.monaco-list${t}:focus .monaco-list-row.focused:hover { background-color: ${e.listFocusBackground}; }`)),e.listFocusForeground&&i.push(`.monaco-list${t}:focus .monaco-list-row.focused { color: ${e.listFocusForeground}; }`),e.listActiveSelectionBackground&&(i.push(`.monaco-list${t}:focus .monaco-list-row.selected { background-color: ${e.listActiveSelectionBackground}; }`),i.push(`.monaco-list${t}:focus .monaco-list-row.selected:hover { background-color: ${e.listActiveSelectionBackground}; }`)),e.listActiveSelectionForeground&&i.push(`.monaco-list${t}:focus .monaco-list-row.selected { color: ${e.listActiveSelectionForeground}; }`),e.listActiveSelectionIconForeground&&i.push(`.monaco-list${t}:focus .monaco-list-row.selected .codicon { color: ${e.listActiveSelectionIconForeground}; }`),e.listFocusAndSelectionBackground&&i.push(`\n\t\t\t\t.monaco-drag-image,\n\t\t\t\t.monaco-list${t}:focus .monaco-list-row.selected.focused { background-color: ${e.listFocusAndSelectionBackground}; }\n\t\t\t`),e.listFocusAndSelectionForeground&&i.push(`\n\t\t\t\t.monaco-drag-image,\n\t\t\t\t.monaco-list${t}:focus .monaco-list-row.selected.focused { color: ${e.listFocusAndSelectionForeground}; }\n\t\t\t`),e.listInactiveFocusForeground&&(i.push(`.monaco-list${t} .monaco-list-row.focused { color: ${e.listInactiveFocusForeground}; }`),i.push(`.monaco-list${t} .monaco-list-row.focused:hover { color: ${e.listInactiveFocusForeground}; }`)),e.listInactiveSelectionIconForeground&&i.push(`.monaco-list${t} .monaco-list-row.focused .codicon { color: ${e.listInactiveSelectionIconForeground}; }`),e.listInactiveFocusBackground&&(i.push(`.monaco-list${t} .monaco-list-row.focused { background-color: ${e.listInactiveFocusBackground}; }`),i.push(`.monaco-list${t} .monaco-list-row.focused:hover { background-color: ${e.listInactiveFocusBackground}; }`)),e.listInactiveSelectionBackground&&(i.push(`.monaco-list${t} .monaco-list-row.selected { background-color: ${e.listInactiveSelectionBackground}; }`),i.push(`.monaco-list${t} .monaco-list-row.selected:hover { background-color: ${e.listInactiveSelectionBackground}; }`)),e.listInactiveSelectionForeground&&i.push(`.monaco-list${t} .monaco-list-row.selected { color: ${e.listInactiveSelectionForeground}; }`),e.listHoverBackground&&i.push(`.monaco-list${t}:not(.drop-target) .monaco-list-row:hover:not(.selected):not(.focused) { background-color: ${e.listHoverBackground}; }`),e.listHoverForeground&&i.push(`.monaco-list${t} .monaco-list-row:hover:not(.selected):not(.focused) { color: ${e.listHoverForeground}; }`),e.listSelectionOutline&&i.push(`.monaco-list${t} .monaco-list-row.selected { outline: 1px dotted ${e.listSelectionOutline}; outline-offset: -1px; }`),e.listFocusOutline&&i.push(`\n\t\t\t\t.monaco-drag-image,\n\t\t\t\t.monaco-list${t}:focus .monaco-list-row.focused { outline: 1px solid ${e.listFocusOutline}; outline-offset: -1px; }\n\t\t\t\t.monaco-workbench.context-menu-visible .monaco-list${t}.last-focused .monaco-list-row.focused { outline: 1px solid ${e.listFocusOutline}; outline-offset: -1px; }\n\t\t\t`),e.listInactiveFocusOutline&&i.push(`.monaco-list${t} .monaco-list-row.focused { outline: 1px dotted ${e.listInactiveFocusOutline}; outline-offset: -1px; }`),e.listHoverOutline&&i.push(`.monaco-list${t} .monaco-list-row:hover { outline: 1px dashed ${e.listHoverOutline}; outline-offset: -1px; }`),e.listDropBackground&&i.push(`\n\t\t\t\t.monaco-list${t}.drop-target,\n\t\t\t\t.monaco-list${t} .monaco-list-rows.drop-target,\n\t\t\t\t.monaco-list${t} .monaco-list-row.drop-target { background-color: ${e.listDropBackground} !important; color: inherit !important; }\n\t\t\t`),e.listFilterWidgetBackground&&i.push(`.monaco-list-type-filter { background-color: ${e.listFilterWidgetBackground} }`),e.listFilterWidgetOutline&&i.push(`.monaco-list-type-filter { border: 1px solid ${e.listFilterWidgetOutline}; }`),e.listFilterWidgetNoMatchesOutline&&i.push(`.monaco-list-type-filter.no-matches { border: 1px solid ${e.listFilterWidgetNoMatchesOutline}; }`),e.listMatchesShadow&&i.push(`.monaco-list-type-filter { box-shadow: 1px 1px 1px ${e.listMatchesShadow}; }`),e.tableColumnsBorder&&i.push(`\n\t\t\t\t.monaco-table:hover > .monaco-split-view2,\n\t\t\t\t.monaco-table:hover > .monaco-split-view2 .monaco-sash.vertical::before {\n\t\t\t\t\tborder-color: ${e.tableColumnsBorder};\n\t\t\t}`),e.tableOddRowsBackgroundColor&&i.push(`\n\t\t\t\t.monaco-table .monaco-list-row[data-parity=odd]:not(.focused):not(.selected):not(:hover) .monaco-table-tr,\n\t\t\t\t.monaco-table .monaco-list:not(:focus) .monaco-list-row[data-parity=odd].focused:not(.selected):not(:hover) .monaco-table-tr,\n\t\t\t\t.monaco-table .monaco-list:not(.focused) .monaco-list-row[data-parity=odd].focused:not(.selected):not(:hover) .monaco-table-tr {\n\t\t\t\t\tbackground-color: ${e.tableOddRowsBackgroundColor};\n\t\t\t\t}\n\t\t\t`),this.styleElement.textContent=i.join("\n")}}const V={listFocusBackground:u.Il.fromHex("#7FB0D0"),listActiveSelectionBackground:u.Il.fromHex("#0E639C"),listActiveSelectionForeground:u.Il.fromHex("#FFFFFF"),listActiveSelectionIconForeground:u.Il.fromHex("#FFFFFF"),listFocusAndSelectionBackground:u.Il.fromHex("#094771"),listFocusAndSelectionForeground:u.Il.fromHex("#FFFFFF"),listInactiveSelectionBackground:u.Il.fromHex("#3F3F46"),listInactiveSelectionIconForeground:u.Il.fromHex("#FFFFFF"),listHoverBackground:u.Il.fromHex("#2A2D2E"),listDropBackground:u.Il.fromHex("#383B3D"),treeIndentGuidesStroke:u.Il.fromHex("#a9a9a9"),tableColumnsBorder:u.Il.fromHex("#cccccc").transparent(.2),tableOddRowsBackgroundColor:u.Il.fromHex("#cccccc").transparent(.04)},H={keyboardSupport:!0,mouseSupport:!0,multipleSelectionSupport:!0,dnd:{getDragURI:()=>null,onDragStart(){},onDragOver:()=>!1,drop(){}}};function z(e,t){const i=[];let n=0,o=0;for(;n=e.length)i.push(t[o++]);else if(o>=t.length)i.push(e[n++]);else{if(e[n]===t[o]){i.push(e[n]),n++,o++;continue}e[n]e-t;class U{constructor(e,t){this._templateId=e,this.renderers=t}get templateId(){return this._templateId}renderTemplate(e){return this.renderers.map((t=>t.renderTemplate(e)))}renderElement(e,t,i,n){let o=0;for(const r of this.renderers)r.renderElement(e,t,i[o++],n)}disposeElement(e,t,i,n){let o=0;for(const r of this.renderers)r.disposeElement&&r.disposeElement(e,t,i[o],n),o+=1}disposeTemplate(e){let t=0;for(const i of this.renderers)i.disposeTemplate(e[t++])}}class j{constructor(e){this.accessibilityProvider=e,this.templateId="a18n"}renderTemplate(e){return e}renderElement(e,t,i){const n=this.accessibilityProvider.getAriaLabel(e);n?i.setAttribute("aria-label",n):i.removeAttribute("aria-label");const o=this.accessibilityProvider.getAriaLevel&&this.accessibilityProvider.getAriaLevel(e);"number"==typeof o?i.setAttribute("aria-level",`${o}`):i.removeAttribute("aria-level")}disposeTemplate(e){}}class K{constructor(e,t){this.list=e,this.dnd=t}getDragElements(e){const t=this.list.getSelectedElements();return t.indexOf(e)>-1?t:[e]}getDragURI(e){return this.dnd.getDragURI(e)}getDragLabel(e,t){if(this.dnd.getDragLabel)return this.dnd.getDragLabel(e,t)}onDragStart(e,t){this.dnd.onDragStart&&this.dnd.onDragStart(e,t)}onDragOver(e,t,i,n){return this.dnd.onDragOver(e,t,i,n)}onDragLeave(e,t,i,n){var o,r;null===(r=(o=this.dnd).onDragLeave)||void 0===r||r.call(o,e,t,i,n)}onDragEnd(e){this.dnd.onDragEnd&&this.dnd.onDragEnd(e)}drop(e,t,i,n){this.dnd.drop(e,t,i,n)}}class q{constructor(e,t,i,o,r=H){var s;this.user=e,this._options=r,this.focus=new L("focused"),this.anchor=new L("anchor"),this.eventBufferer=new g.E7,this._ariaLabel="",this.disposables=new m.SL,this._onDidDispose=new g.Q5,this.onDidDispose=this._onDidDispose.event;const a=this._options.accessibilityProvider&&this._options.accessibilityProvider.getWidgetRole?null===(s=this._options.accessibilityProvider)||void 0===s?void 0:s.getWidgetRole():"list";this.selection=new E("listbox"!==a),(0,_.jB)(r,V,!1);const c=[this.focus.renderer,this.selection.renderer];this.accessibilityProvider=r.accessibilityProvider,this.accessibilityProvider&&(c.push(new j(this.accessibilityProvider)),this.accessibilityProvider.onDidChangeActiveDescendant&&this.accessibilityProvider.onDidChangeActiveDescendant(this.onDidChangeActiveDescendant,this,this.disposables)),o=o.map((e=>new U(e.templateId,[...c,e])));const d=Object.assign(Object.assign({},r),{dnd:r.dnd&&new K(this,r.dnd)});if(this.view=new y.Bv(t,i,o,d),this.view.domNode.setAttribute("role",a),r.styleController)this.styleController=r.styleController(this.view.domId);else{const e=(0,n.dS)(this.view.domNode);this.styleController=new W(e,this.view.domId)}if(this.spliceable=new l([new N(this.focus,this.view,r.identityProvider),new N(this.selection,this.view,r.identityProvider),new N(this.anchor,this.view,r.identityProvider),this.view]),this.disposables.add(this.focus),this.disposables.add(this.selection),this.disposables.add(this.anchor),this.disposables.add(this.view),this.disposables.add(this._onDidDispose),this.disposables.add(new M(this,this.view)),("boolean"!=typeof r.keyboardSupport||r.keyboardSupport)&&(this.keyboardController=new T(this,this.view,r),this.disposables.add(this.keyboardController)),r.keyboardNavigationLabelProvider){const e=r.keyboardNavigationDelegate||A;this.typeLabelController=new R(this,this.view,r.keyboardNavigationLabelProvider,e),this.disposables.add(this.typeLabelController)}this.mouseController=this.createMouseController(r),this.disposables.add(this.mouseController),this.onDidChangeFocus(this._onFocusChange,this,this.disposables),this.onDidChangeSelection(this._onSelectionChange,this,this.disposables),this.accessibilityProvider&&(this.ariaLabel=this.accessibilityProvider.getWidgetAriaLabel()),!1!==this._options.multipleSelectionSupport&&this.view.domNode.setAttribute("aria-multiselectable","true")}get onDidChangeFocus(){return g.ju.map(this.eventBufferer.wrapEvent(this.focus.onChange),(e=>this.toListEvent(e)))}get onDidChangeSelection(){return g.ju.map(this.eventBufferer.wrapEvent(this.selection.onChange),(e=>this.toListEvent(e)))}get domId(){return this.view.domId}get onMouseClick(){return this.view.onMouseClick}get onMouseDblClick(){return this.view.onMouseDblClick}get onMouseMiddleClick(){return this.view.onMouseMiddleClick}get onPointer(){return this.mouseController.onPointer}get onMouseDown(){return this.view.onMouseDown}get onTouchStart(){return this.view.onTouchStart}get onTap(){return this.view.onTap}get onContextMenu(){let e=!1;const t=g.ju.chain(this.disposables.add(new o.Y(this.view.domNode,"keydown")).event).map((e=>new r.y(e))).filter((t=>e=58===t.keyCode||t.shiftKey&&68===t.keyCode)).map(o.p).filter((()=>!1)).event,i=g.ju.chain(this.disposables.add(new o.Y(this.view.domNode,"keyup")).event).forEach((()=>e=!1)).map((e=>new r.y(e))).filter((e=>58===e.keyCode||e.shiftKey&&68===e.keyCode)).map(o.p).map((({browserEvent:e})=>{const t=this.getFocus(),i=t.length?t[0]:void 0;return{index:i,element:void 0!==i?this.view.element(i):void 0,anchor:void 0!==i?this.view.domElement(i):this.view.domNode,browserEvent:e}})).event,n=g.ju.chain(this.view.onContextMenu).filter((t=>!e)).map((({element:e,index:t,browserEvent:i})=>({element:e,index:t,anchor:{x:i.pageX+1,y:i.pageY},browserEvent:i}))).event;return g.ju.any(t,i,n)}get onKeyDown(){return this.disposables.add(new o.Y(this.view.domNode,"keydown")).event}get onDidFocus(){return g.ju.signal(this.disposables.add(new o.Y(this.view.domNode,"focus",!0)).event)}createMouseController(e){return new B(this)}updateOptions(e={}){var t;this._options=Object.assign(Object.assign({},this._options),e),this.typeLabelController&&this.typeLabelController.updateOptions(this._options),void 0!==this._options.multipleSelectionController&&(this._options.multipleSelectionSupport?this.view.domNode.setAttribute("aria-multiselectable","true"):this.view.domNode.removeAttribute("aria-multiselectable")),this.mouseController.updateOptions(e),null===(t=this.keyboardController)||void 0===t||t.updateOptions(e),this.view.updateOptions(e)}get options(){return this._options}splice(e,t,i=[]){if(e<0||e>this.view.length)throw new C(this.user,`Invalid start index: ${e}`);if(t<0)throw new C(this.user,`Invalid delete count: ${t}`);0===t&&0===i.length||this.eventBufferer.bufferEvents((()=>this.spliceable.splice(e,t,i)))}rerender(){this.view.rerender()}element(e){return this.view.element(e)}get length(){return this.view.length}get contentHeight(){return this.view.contentHeight}get scrollTop(){return this.view.getScrollTop()}set scrollTop(e){this.view.setScrollTop(e)}get ariaLabel(){return this._ariaLabel}set ariaLabel(e){this._ariaLabel=e,this.view.domNode.setAttribute("aria-label",e)}domFocus(){this.view.domNode.focus({preventScroll:!0})}layout(e,t){this.view.layout(e,t)}setSelection(e,t){for(const t of e)if(t<0||t>=this.length)throw new C(this.user,`Invalid index ${t}`);this.selection.set(e,t)}getSelection(){return this.selection.get()}getSelectedElements(){return this.getSelection().map((e=>this.view.element(e)))}setAnchor(e){if(void 0!==e){if(e<0||e>=this.length)throw new C(this.user,`Invalid index ${e}`);this.anchor.set([e])}else this.anchor.set([])}getAnchor(){return(0,c.Xh)(this.anchor.get(),void 0)}getAnchorElement(){const e=this.getAnchor();return void 0===e?void 0:this.element(e)}setFocus(e,t){for(const t of e)if(t<0||t>=this.length)throw new C(this.user,`Invalid index ${t}`);this.focus.set(e,t)}focusNext(e=1,t=!1,i,n){if(0===this.length)return;const o=this.focus.get(),r=this.findNextIndex(o.length>0?o[0]+e:0,t,n);r>-1&&this.setFocus([r],i)}focusPrevious(e=1,t=!1,i,n){if(0===this.length)return;const o=this.focus.get(),r=this.findPreviousIndex(o.length>0?o[0]-e:0,t,n);r>-1&&this.setFocus([r],i)}focusNextPage(e,t){return x(this,void 0,void 0,(function*(){let i=this.view.indexAt(this.view.getScrollTop()+this.view.renderHeight);i=0===i?0:i-1;const n=this.view.element(i),o=this.getFocusedElements()[0];if(o!==n){const n=this.findPreviousIndex(i,!1,t);n>-1&&o!==this.view.element(n)?this.setFocus([n],e):this.setFocus([i],e)}else{const n=this.view.getScrollTop();this.view.setScrollTop(n+this.view.renderHeight-this.view.elementHeight(i)),this.view.getScrollTop()!==n&&(this.setFocus([]),yield(0,d.Vs)(0),yield this.focusNextPage(e,t))}}))}focusPreviousPage(e,t){return x(this,void 0,void 0,(function*(){let i;const n=this.view.getScrollTop();i=0===n?this.view.indexAt(n):this.view.indexAfter(n-1);const o=this.view.element(i),r=this.getFocusedElements()[0];if(r!==o){const n=this.findNextIndex(i,!1,t);n>-1&&r!==this.view.element(n)?this.setFocus([n],e):this.setFocus([i],e)}else{const i=n;this.view.setScrollTop(n-this.view.renderHeight),this.view.getScrollTop()!==i&&(this.setFocus([]),yield(0,d.Vs)(0),yield this.focusPreviousPage(e,t))}}))}focusLast(e,t){if(0===this.length)return;const i=this.findPreviousIndex(this.length-1,!1,t);i>-1&&this.setFocus([i],e)}focusFirst(e,t){this.focusNth(0,e,t)}focusNth(e,t,i){if(0===this.length)return;const n=this.findNextIndex(e,!1,i);n>-1&&this.setFocus([n],t)}findNextIndex(e,t=!1,i){for(let n=0;n=this.length&&!t)return-1;if(e%=this.length,!i||i(this.element(e)))return e;e++}return-1}findPreviousIndex(e,t=!1,i){for(let n=0;nthis.view.element(e)))}reveal(e,t){if(e<0||e>=this.length)throw new C(this.user,`Invalid index ${e}`);const i=this.view.getScrollTop(),n=this.view.elementTop(e),o=this.view.elementHeight(e);if((0,v.hj)(t)){const e=o-this.view.renderHeight;this.view.setScrollTop(e*(0,f.uZ)(t,0,1)+n)}else{const e=n+o,t=i+this.view.renderHeight;n=t||(n=t&&o>=this.view.renderHeight?this.view.setScrollTop(n):e>=t&&this.view.setScrollTop(e-this.view.renderHeight))}}getRelativeTop(e){if(e<0||e>=this.length)throw new C(this.user,`Invalid index ${e}`);const t=this.view.getScrollTop(),i=this.view.elementTop(e),n=this.view.elementHeight(e);if(it+this.view.renderHeight)return null;const o=n-this.view.renderHeight;return Math.abs((t-i)/o)}getHTMLElement(){return this.view.domNode}style(e){this.styleController.style(e)}toListEvent({indexes:e,browserEvent:t}){return{indexes:e,elements:e.map((e=>this.view.element(e))),browserEvent:t}}_onFocusChange(){const e=this.focus.get();this.view.domNode.classList.toggle("element-focused",e.length>0),this.onDidChangeActiveDescendant()}onDidChangeActiveDescendant(){var e;const t=this.focus.get();if(t.length>0){let i;(null===(e=this.accessibilityProvider)||void 0===e?void 0:e.getActiveDescendantId)&&(i=this.accessibilityProvider.getActiveDescendantId(this.view.element(t[0]))),this.view.domNode.setAttribute("aria-activedescendant",i||this.view.getElementDomId(t[0]))}else this.view.domNode.removeAttribute("aria-activedescendant")}_onSelectionChange(){const e=this.selection.get();this.view.domNode.classList.toggle("selection-none",0===e.length),this.view.domNode.classList.toggle("selection-single",1===e.length),this.view.domNode.classList.toggle("selection-multiple",e.length>1)}dispose(){this._onDidDispose.fire(),this.disposables.dispose(),this._onDidDispose.dispose()}}S([h.H],q.prototype,"onDidChangeFocus",null),S([h.H],q.prototype,"onDidChangeSelection",null),S([h.H],q.prototype,"onContextMenu",null),S([h.H],q.prototype,"onKeyDown",null),S([h.H],q.prototype,"onDidFocus",null)},32082:function(e,t,i){"use strict";i.d(t,{S:function(){return _}});var n=i(93379),o=i.n(n),r=i(7795),s=i.n(r),a=i(90569),l=i.n(a),c=i(3565),d=i.n(c),u=i(19216),h=i.n(u),g=i(44589),p=i.n(g),m=i(12422),f={};f.styleTagTransform=p(),f.setAttributes=d(),f.insert=l().bind(null,"head"),f.domAPI=s(),f.insertStyleElement=h(),o()(m.Z,f),m.Z&&m.Z.locals&&m.Z.locals;const _="monaco-mouse-cursor-text"},71036:function(e,t,i){"use strict";i.d(t,{l:function(){return k},g:function(){return R}});var n=i(68695),o=i(27163),r=i(83055),s=i(40027),a=i(79945),l=i(46718),c=i(4004),d=i(6954),u=i(93379),h=i.n(u),g=i(7795),p=i.n(g),m=i(90569),f=i.n(m),_=i(3565),b=i.n(_),v=i(19216),C=i.n(v),w=i(44589),y=i.n(w),S=i(68126),x={};x.styleTagTransform=y(),x.setAttributes=b(),x.insert=f().bind(null,"head"),x.domAPI=p(),x.insertStyleElement=C(),h()(S.Z,x),S.Z&&S.Z.locals&&S.Z.locals;var k,L=function(e,t,i,n){var o,r=arguments.length,s=r<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,i):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(e,t,i,n);else for(var a=e.length-1;a>=0;a--)(o=e[a])&&(s=(r<3?o(s):r>3?o(t,i,s):o(t,i))||s);return r>3&&s&&Object.defineProperty(t,i,s),s};!function(e){e.North="north",e.South="south",e.East="east",e.West="west"}(k||(k={}));const E=new l.Q5,N=new l.Q5;class D{constructor(){this.disposables=new c.SL}get onPointerMove(){return this.disposables.add(new o.Y(window,"mousemove")).event}get onPointerUp(){return this.disposables.add(new o.Y(window,"mouseup")).event}dispose(){this.disposables.dispose()}}L([a.H],D.prototype,"onPointerMove",null),L([a.H],D.prototype,"onPointerUp",null);class I{constructor(e){this.el=e,this.disposables=new c.SL}get onPointerMove(){return this.disposables.add(new o.Y(this.el,r.t.Change)).event}get onPointerUp(){return this.disposables.add(new o.Y(this.el,r.t.End)).event}dispose(){this.disposables.dispose()}}L([a.H],I.prototype,"onPointerMove",null),L([a.H],I.prototype,"onPointerUp",null);class T{constructor(e){this.factory=e}get onPointerMove(){return this.factory.onPointerMove}get onPointerUp(){return this.factory.onPointerUp}dispose(){}}L([a.H],T.prototype,"onPointerMove",null),L([a.H],T.prototype,"onPointerUp",null);const A="pointer-events-disabled";class R extends c.JT{constructor(e,t,i){super(),this.hoverDelay=300,this.hoverDelayer=this._register(new s.vp(this.hoverDelay)),this._state=3,this.onDidEnablementChange=this._register(new l.Q5),this._onDidStart=this._register(new l.Q5),this._onDidChange=this._register(new l.Q5),this._onDidReset=this._register(new l.Q5),this._onDidEnd=this._register(new l.Q5),this.orthogonalStartSashDisposables=this._register(new c.SL),this.orthogonalStartDragHandleDisposables=this._register(new c.SL),this.orthogonalEndSashDisposables=this._register(new c.SL),this.orthogonalEndDragHandleDisposables=this._register(new c.SL),this.onDidStart=this._onDidStart.event,this.onDidChange=this._onDidChange.event,this.onDidReset=this._onDidReset.event,this.onDidEnd=this._onDidEnd.event,this.linkedSash=void 0,this.el=(0,n.R3)(e,(0,n.$)(".monaco-sash")),i.orthogonalEdge&&this.el.classList.add(`orthogonal-edge-${i.orthogonalEdge}`),d.dz&&this.el.classList.add("mac");const a=this._register(new o.Y(this.el,"mousedown")).event;this._register(a((e=>this.onPointerStart(e,new D)),this));const u=this._register(new o.Y(this.el,"dblclick")).event;this._register(u(this.onPointerDoublePress,this));const h=this._register(new o.Y(this.el,"mouseenter")).event;this._register(h((()=>R.onMouseEnter(this))));const g=this._register(new o.Y(this.el,"mouseleave")).event;this._register(g((()=>R.onMouseLeave(this)))),this._register(r.o.addTarget(this.el));const p=l.ju.map(this._register(new o.Y(this.el,r.t.Start)).event,(e=>{var t;return Object.assign(Object.assign({},e),{target:null!==(t=e.initialTarget)&&void 0!==t?t:null})}));this._register(p((e=>this.onPointerStart(e,new I(this.el))),this));const m=this._register(new o.Y(this.el,r.t.Tap)).event,f=l.ju.map(l.ju.filter(l.ju.debounce(m,((e,t)=>{var i;return{event:t,count:(null!==(i=null==e?void 0:e.count)&&void 0!==i?i:0)+1}}),250),(({count:e})=>2===e)),(({event:e})=>{var t;return Object.assign(Object.assign({},e),{target:null!==(t=e.initialTarget)&&void 0!==t?t:null})}));this._register(f(this.onPointerDoublePress,this)),"number"==typeof i.size?(this.size=i.size,0===i.orientation?this.el.style.width=`${this.size}px`:this.el.style.height=`${this.size}px`):(this.size=4,this._register(E.event((e=>{this.size=e,this.layout()})))),this._register(N.event((e=>this.hoverDelay=e))),this.layoutProvider=t,this.orthogonalStartSash=i.orthogonalStartSash,this.orthogonalEndSash=i.orthogonalEndSash,this.orientation=i.orientation||0,1===this.orientation?(this.el.classList.add("horizontal"),this.el.classList.remove("vertical")):(this.el.classList.remove("horizontal"),this.el.classList.add("vertical")),this.el.classList.toggle("debug",!1),this.layout()}get state(){return this._state}get orthogonalStartSash(){return this._orthogonalStartSash}get orthogonalEndSash(){return this._orthogonalEndSash}set state(e){this._state!==e&&(this.el.classList.toggle("disabled",0===e),this.el.classList.toggle("minimum",1===e),this.el.classList.toggle("maximum",2===e),this._state=e,this.onDidEnablementChange.fire(e))}set orthogonalStartSash(e){if(this.orthogonalStartDragHandleDisposables.clear(),this.orthogonalStartSashDisposables.clear(),e){const t=t=>{this.orthogonalStartDragHandleDisposables.clear(),0!==t&&(this._orthogonalStartDragHandle=(0,n.R3)(this.el,(0,n.$)(".orthogonal-drag-handle.start")),this.orthogonalStartDragHandleDisposables.add((0,c.OF)((()=>this._orthogonalStartDragHandle.remove()))),this.orthogonalStartDragHandleDisposables.add(new o.Y(this._orthogonalStartDragHandle,"mouseenter")).event((()=>R.onMouseEnter(e)),void 0,this.orthogonalStartDragHandleDisposables),this.orthogonalStartDragHandleDisposables.add(new o.Y(this._orthogonalStartDragHandle,"mouseleave")).event((()=>R.onMouseLeave(e)),void 0,this.orthogonalStartDragHandleDisposables))};this.orthogonalStartSashDisposables.add(e.onDidEnablementChange.event(t,this)),t(e.state)}this._orthogonalStartSash=e}set orthogonalEndSash(e){if(this.orthogonalEndDragHandleDisposables.clear(),this.orthogonalEndSashDisposables.clear(),e){const t=t=>{this.orthogonalEndDragHandleDisposables.clear(),0!==t&&(this._orthogonalEndDragHandle=(0,n.R3)(this.el,(0,n.$)(".orthogonal-drag-handle.end")),this.orthogonalEndDragHandleDisposables.add((0,c.OF)((()=>this._orthogonalEndDragHandle.remove()))),this.orthogonalEndDragHandleDisposables.add(new o.Y(this._orthogonalEndDragHandle,"mouseenter")).event((()=>R.onMouseEnter(e)),void 0,this.orthogonalEndDragHandleDisposables),this.orthogonalEndDragHandleDisposables.add(new o.Y(this._orthogonalEndDragHandle,"mouseleave")).event((()=>R.onMouseLeave(e)),void 0,this.orthogonalEndDragHandleDisposables))};this.orthogonalEndSashDisposables.add(e.onDidEnablementChange.event(t,this)),t(e.state)}this._orthogonalEndSash=e}onPointerStart(e,t){n.zB.stop(e);let i=!1;if(!e.__orthogonalSashEvent){const n=this.getOrthogonalSash(e);n&&(i=!0,e.__orthogonalSashEvent=!0,n.onPointerStart(e,new T(t)))}if(this.linkedSash&&!e.__linkedSashEvent&&(e.__linkedSashEvent=!0,this.linkedSash.onPointerStart(e,new T(t))),!this.state)return;const o=(0,n.H$)("iframe");for(const e of o)e.classList.add(A);const r=e.pageX,s=e.pageY,a=e.altKey,l={startX:r,currentX:r,startY:s,currentY:s,altKey:a};this.el.classList.add("active"),this._onDidStart.fire(l);const u=(0,n.dS)(this.el),h=()=>{let e="";e=i?"all-scroll":1===this.orientation?1===this.state?"s-resize":2===this.state?"n-resize":d.dz?"row-resize":"ns-resize":1===this.state?"e-resize":2===this.state?"w-resize":d.dz?"col-resize":"ew-resize",u.textContent=`* { cursor: ${e} !important; }`},g=new c.SL;h(),i||this.onDidEnablementChange.event(h,null,g),t.onPointerMove((e=>{n.zB.stop(e,!1);const t={startX:r,currentX:e.pageX,startY:s,currentY:e.pageY,altKey:a};this._onDidChange.fire(t)}),null,g),t.onPointerUp((e=>{n.zB.stop(e,!1),this.el.removeChild(u),this.el.classList.remove("active"),this._onDidEnd.fire(),g.dispose();for(const e of o)e.classList.remove(A)}),null,g),g.add(t)}onPointerDoublePress(e){const t=this.getOrthogonalSash(e);t&&t._onDidReset.fire(),this.linkedSash&&this.linkedSash._onDidReset.fire(),this._onDidReset.fire()}static onMouseEnter(e,t=!1){e.el.classList.contains("active")?(e.hoverDelayer.cancel(),e.el.classList.add("hover")):e.hoverDelayer.trigger((()=>e.el.classList.add("hover")),e.hoverDelay).then(void 0,(()=>{})),!t&&e.linkedSash&&R.onMouseEnter(e.linkedSash,!0)}static onMouseLeave(e,t=!1){e.hoverDelayer.cancel(),e.el.classList.remove("hover"),!t&&e.linkedSash&&R.onMouseLeave(e.linkedSash,!0)}clearSashHoverState(){R.onMouseLeave(this)}layout(){if(0===this.orientation){const e=this.layoutProvider;this.el.style.left=e.getVerticalSashLeft(this)-this.size/2+"px",e.getVerticalSashTop&&(this.el.style.top=e.getVerticalSashTop(this)+"px"),e.getVerticalSashHeight&&(this.el.style.height=e.getVerticalSashHeight(this)+"px")}else{const e=this.layoutProvider;this.el.style.top=e.getHorizontalSashTop(this)-this.size/2+"px",e.getHorizontalSashLeft&&(this.el.style.left=e.getHorizontalSashLeft(this)+"px"),e.getHorizontalSashWidth&&(this.el.style.width=e.getHorizontalSashWidth(this)+"px")}}getOrthogonalSash(e){if(e.target&&e.target instanceof HTMLElement)return e.target.classList.contains("orthogonal-drag-handle")?e.target.classList.contains("start")?this.orthogonalStartSash:this.orthogonalEndSash:void 0}dispose(){super.dispose(),this.el.remove()}}},98677:function(e,t,i){"use strict";i.d(t,{s$:function(){return V},NB:function(){return B},$Z:function(){return W}});var n=i(26641),o=i(68695),r=i(17762),s=i(80428),a=i(9630),l=i(43479),c=i(40027);class d extends l.${constructor(e){super(),this._onActivate=e.onActivate,this.bgDomNode=document.createElement("div"),this.bgDomNode.className="arrow-background",this.bgDomNode.style.position="absolute",this.bgDomNode.style.width=e.bgWidth+"px",this.bgDomNode.style.height=e.bgHeight+"px",void 0!==e.top&&(this.bgDomNode.style.top="0px"),void 0!==e.left&&(this.bgDomNode.style.left="0px"),void 0!==e.bottom&&(this.bgDomNode.style.bottom="0px"),void 0!==e.right&&(this.bgDomNode.style.right="0px"),this.domNode=document.createElement("div"),this.domNode.className=e.className,this.domNode.classList.add(...e.icon.classNamesArray),this.domNode.style.position="absolute",this.domNode.style.width="11px",this.domNode.style.height="11px",void 0!==e.top&&(this.domNode.style.top=e.top+"px"),void 0!==e.left&&(this.domNode.style.left=e.left+"px"),void 0!==e.bottom&&(this.domNode.style.bottom=e.bottom+"px"),void 0!==e.right&&(this.domNode.style.right=e.right+"px"),this._mouseMoveMonitor=this._register(new a.Z),this.onmousedown(this.bgDomNode,(e=>this._arrowMouseDown(e))),this.onmousedown(this.domNode,(e=>this._arrowMouseDown(e))),this._mousedownRepeatTimer=this._register(new c.zh),this._mousedownScheduleRepeatTimer=this._register(new c._F)}_arrowMouseDown(e){this._onActivate(),this._mousedownRepeatTimer.cancel(),this._mousedownScheduleRepeatTimer.cancelAndSet((()=>{this._mousedownRepeatTimer.cancelAndSet((()=>this._onActivate()),1e3/24)}),200),this._mouseMoveMonitor.startMonitoring(e.target,e.buttons,a.e,(e=>{}),(()=>{this._mousedownRepeatTimer.cancel(),this._mousedownScheduleRepeatTimer.cancel()})),e.preventDefault()}}var u=i(4004);class h extends u.JT{constructor(e,t,i){super(),this._visibility=e,this._visibleClassName=t,this._invisibleClassName=i,this._domNode=null,this._isVisible=!1,this._isNeeded=!1,this._rawShouldBeVisible=!1,this._shouldBeVisible=!1,this._revealTimer=this._register(new c._F)}setVisibility(e){this._visibility!==e&&(this._visibility=e,this._updateShouldBeVisible())}setShouldBeVisible(e){this._rawShouldBeVisible=e,this._updateShouldBeVisible()}_applyVisibilitySetting(){return 2!==this._visibility&&(3===this._visibility||this._rawShouldBeVisible)}_updateShouldBeVisible(){const e=this._applyVisibilitySetting();this._shouldBeVisible!==e&&(this._shouldBeVisible=e,this.ensureVisibility())}setIsNeeded(e){this._isNeeded!==e&&(this._isNeeded=e,this.ensureVisibility())}setDomNode(e){this._domNode=e,this._domNode.setClassName(this._invisibleClassName),this.setShouldBeVisible(!1)}ensureVisibility(){this._isNeeded?this._shouldBeVisible?this._reveal():this._hide(!0):this._hide(!1)}_reveal(){this._isVisible||(this._isVisible=!0,this._revealTimer.setIfNotSet((()=>{this._domNode&&this._domNode.setClassName(this._visibleClassName)}),0))}_hide(e){this._revealTimer.cancel(),this._isVisible&&(this._isVisible=!1,this._domNode&&this._domNode.setClassName(this._invisibleClassName+(e?" fade":"")))}}var g=i(6954);class p extends l.${constructor(e){super(),this._lazyRender=e.lazyRender,this._host=e.host,this._scrollable=e.scrollable,this._scrollByPage=e.scrollByPage,this._scrollbarState=e.scrollbarState,this._visibilityController=this._register(new h(e.visibility,"visible scrollbar "+e.extraScrollbarClassName,"invisible scrollbar "+e.extraScrollbarClassName)),this._visibilityController.setIsNeeded(this._scrollbarState.isNeeded()),this._mouseMoveMonitor=this._register(new a.Z),this._shouldRender=!0,this.domNode=(0,r.X)(document.createElement("div")),this.domNode.setAttribute("role","presentation"),this.domNode.setAttribute("aria-hidden","true"),this._visibilityController.setDomNode(this.domNode),this.domNode.setPosition("absolute"),this.onmousedown(this.domNode.domNode,(e=>this._domNodeMouseDown(e)))}_createArrow(e){const t=this._register(new d(e));this.domNode.domNode.appendChild(t.bgDomNode),this.domNode.domNode.appendChild(t.domNode)}_createSlider(e,t,i,n){this.slider=(0,r.X)(document.createElement("div")),this.slider.setClassName("slider"),this.slider.setPosition("absolute"),this.slider.setTop(e),this.slider.setLeft(t),"number"==typeof i&&this.slider.setWidth(i),"number"==typeof n&&this.slider.setHeight(n),this.slider.setLayerHinting(!0),this.slider.setContain("strict"),this.domNode.domNode.appendChild(this.slider.domNode),this.onmousedown(this.slider.domNode,(e=>{e.leftButton&&(e.preventDefault(),this._sliderMouseDown(e,(()=>{})))})),this.onclick(this.slider.domNode,(e=>{e.leftButton&&e.stopPropagation()}))}_onElementSize(e){return this._scrollbarState.setVisibleSize(e)&&(this._visibilityController.setIsNeeded(this._scrollbarState.isNeeded()),this._shouldRender=!0,this._lazyRender||this.render()),this._shouldRender}_onElementScrollSize(e){return this._scrollbarState.setScrollSize(e)&&(this._visibilityController.setIsNeeded(this._scrollbarState.isNeeded()),this._shouldRender=!0,this._lazyRender||this.render()),this._shouldRender}_onElementScrollPosition(e){return this._scrollbarState.setScrollPosition(e)&&(this._visibilityController.setIsNeeded(this._scrollbarState.isNeeded()),this._shouldRender=!0,this._lazyRender||this.render()),this._shouldRender}beginReveal(){this._visibilityController.setShouldBeVisible(!0)}beginHide(){this._visibilityController.setShouldBeVisible(!1)}render(){this._shouldRender&&(this._shouldRender=!1,this._renderDomNode(this._scrollbarState.getRectangleLargeSize(),this._scrollbarState.getRectangleSmallSize()),this._updateSlider(this._scrollbarState.getSliderSize(),this._scrollbarState.getArrowSize()+this._scrollbarState.getSliderPosition()))}_domNodeMouseDown(e){e.target===this.domNode.domNode&&this._onMouseDown(e)}delegateMouseDown(e){const t=this.domNode.domNode.getClientRects()[0].top,i=t+this._scrollbarState.getSliderPosition(),n=t+this._scrollbarState.getSliderPosition()+this._scrollbarState.getSliderSize(),o=this._sliderMousePosition(e);i<=o&&o<=n?e.leftButton&&(e.preventDefault(),this._sliderMouseDown(e,(()=>{}))):this._onMouseDown(e)}_onMouseDown(e){let t,i;if(e.target===this.domNode.domNode&&"number"==typeof e.browserEvent.offsetX&&"number"==typeof e.browserEvent.offsetY)t=e.browserEvent.offsetX,i=e.browserEvent.offsetY;else{const n=o.i(this.domNode.domNode);t=e.posx-n.left,i=e.posy-n.top}const n=this._mouseDownRelativePosition(t,i);this._setDesiredScrollPositionNow(this._scrollByPage?this._scrollbarState.getDesiredScrollPositionFromOffsetPaged(n):this._scrollbarState.getDesiredScrollPositionFromOffset(n)),e.leftButton&&(e.preventDefault(),this._sliderMouseDown(e,(()=>{})))}_sliderMouseDown(e,t){const i=this._sliderMousePosition(e),n=this._sliderOrthogonalMousePosition(e),o=this._scrollbarState.clone();this.slider.toggleClassName("active",!0),this._mouseMoveMonitor.startMonitoring(e.target,e.buttons,a.e,(e=>{const t=this._sliderOrthogonalMousePosition(e),r=Math.abs(t-n);if(g.ED&&r>140)return void this._setDesiredScrollPositionNow(o.getScrollPosition());const s=this._sliderMousePosition(e)-i;this._setDesiredScrollPositionNow(o.getDesiredScrollPositionFromDelta(s))}),(()=>{this.slider.toggleClassName("active",!1),this._host.onDragEnd(),t()})),this._host.onDragStart()}_setDesiredScrollPositionNow(e){const t={};this.writeScrollPosition(t,e),this._scrollable.setScrollPositionNow(t)}updateScrollbarSize(e){this._updateScrollbarSize(e),this._scrollbarState.setScrollbarSize(e),this._shouldRender=!0,this._lazyRender||this.render()}isNeeded(){return this._scrollbarState.isNeeded()}}class m{constructor(e,t,i,n,o,r){this._scrollbarSize=Math.round(t),this._oppositeScrollbarSize=Math.round(i),this._arrowSize=Math.round(e),this._visibleSize=n,this._scrollSize=o,this._scrollPosition=r,this._computedAvailableSize=0,this._computedIsNeeded=!1,this._computedSliderSize=0,this._computedSliderRatio=0,this._computedSliderPosition=0,this._refreshComputedValues()}clone(){return new m(this._arrowSize,this._scrollbarSize,this._oppositeScrollbarSize,this._visibleSize,this._scrollSize,this._scrollPosition)}setVisibleSize(e){const t=Math.round(e);return this._visibleSize!==t&&(this._visibleSize=t,this._refreshComputedValues(),!0)}setScrollSize(e){const t=Math.round(e);return this._scrollSize!==t&&(this._scrollSize=t,this._refreshComputedValues(),!0)}setScrollPosition(e){const t=Math.round(e);return this._scrollPosition!==t&&(this._scrollPosition=t,this._refreshComputedValues(),!0)}setScrollbarSize(e){this._scrollbarSize=Math.round(e)}setOppositeScrollbarSize(e){this._oppositeScrollbarSize=Math.round(e)}static _computeValues(e,t,i,n,o){const r=Math.max(0,i-e),s=Math.max(0,r-2*t),a=n>0&&n>i;if(!a)return{computedAvailableSize:Math.round(r),computedIsNeeded:a,computedSliderSize:Math.round(s),computedSliderRatio:0,computedSliderPosition:0};const l=Math.round(Math.max(20,Math.floor(i*s/n))),c=(s-l)/(n-i),d=o*c;return{computedAvailableSize:Math.round(r),computedIsNeeded:a,computedSliderSize:Math.round(l),computedSliderRatio:c,computedSliderPosition:Math.round(d)}}_refreshComputedValues(){const e=m._computeValues(this._oppositeScrollbarSize,this._arrowSize,this._visibleSize,this._scrollSize,this._scrollPosition);this._computedAvailableSize=e.computedAvailableSize,this._computedIsNeeded=e.computedIsNeeded,this._computedSliderSize=e.computedSliderSize,this._computedSliderRatio=e.computedSliderRatio,this._computedSliderPosition=e.computedSliderPosition}getArrowSize(){return this._arrowSize}getScrollPosition(){return this._scrollPosition}getRectangleLargeSize(){return this._computedAvailableSize}getRectangleSmallSize(){return this._scrollbarSize}isNeeded(){return this._computedIsNeeded}getSliderSize(){return this._computedSliderSize}getSliderPosition(){return this._computedSliderPosition}getDesiredScrollPositionFromOffset(e){if(!this._computedIsNeeded)return 0;const t=e-this._arrowSize-this._computedSliderSize/2;return Math.round(t/this._computedSliderRatio)}getDesiredScrollPositionFromOffsetPaged(e){if(!this._computedIsNeeded)return 0;const t=e-this._arrowSize;let i=this._scrollPosition;return tthis._host.onMouseWheel(new s.q(null,1,0))}),this._createArrow({className:"scra",icon:f.lA.scrollbarButtonRight,top:i,left:void 0,bottom:void 0,right:e,bgWidth:t.arrowSize,bgHeight:t.horizontalScrollbarSize,onActivate:()=>this._host.onMouseWheel(new s.q(null,-1,0))})}this._createSlider(Math.floor((t.horizontalScrollbarSize-t.horizontalSliderSize)/2),0,void 0,t.horizontalSliderSize)}_updateSlider(e,t){this.slider.setWidth(e),this.slider.setLeft(t)}_renderDomNode(e,t){this.domNode.setWidth(e),this.domNode.setHeight(t),this.domNode.setLeft(0),this.domNode.setBottom(0)}onDidScroll(e){return this._shouldRender=this._onElementScrollSize(e.scrollWidth)||this._shouldRender,this._shouldRender=this._onElementScrollPosition(e.scrollLeft)||this._shouldRender,this._shouldRender=this._onElementSize(e.width)||this._shouldRender,this._shouldRender}_mouseDownRelativePosition(e,t){return e}_sliderMousePosition(e){return e.posx}_sliderOrthogonalMousePosition(e){return e.posy}_updateScrollbarSize(e){this.slider.setHeight(e)}writeScrollPosition(e,t){e.scrollLeft=t}updateOptions(e){this.updateScrollbarSize(2===e.horizontal?0:e.horizontalScrollbarSize),this._scrollbarState.setOppositeScrollbarSize(2===e.vertical?0:e.verticalScrollbarSize),this._visibilityController.setVisibility(e.horizontal),this._scrollByPage=e.scrollByPage}}class b extends p{constructor(e,t,i){const n=e.getScrollDimensions(),o=e.getCurrentScrollPosition();if(super({lazyRender:t.lazyRender,host:i,scrollbarState:new m(t.verticalHasArrows?t.arrowSize:0,2===t.vertical?0:t.verticalScrollbarSize,0,n.height,n.scrollHeight,o.scrollTop),visibility:t.vertical,extraScrollbarClassName:"vertical",scrollable:e,scrollByPage:t.scrollByPage}),t.verticalHasArrows){const e=(t.arrowSize-11)/2,i=(t.verticalScrollbarSize-11)/2;this._createArrow({className:"scra",icon:f.lA.scrollbarButtonUp,top:e,left:i,bottom:void 0,right:void 0,bgWidth:t.verticalScrollbarSize,bgHeight:t.arrowSize,onActivate:()=>this._host.onMouseWheel(new s.q(null,0,1))}),this._createArrow({className:"scra",icon:f.lA.scrollbarButtonDown,top:void 0,left:i,bottom:e,right:void 0,bgWidth:t.verticalScrollbarSize,bgHeight:t.arrowSize,onActivate:()=>this._host.onMouseWheel(new s.q(null,0,-1))})}this._createSlider(0,Math.floor((t.verticalScrollbarSize-t.verticalSliderSize)/2),t.verticalSliderSize,void 0)}_updateSlider(e,t){this.slider.setHeight(e),this.slider.setTop(t)}_renderDomNode(e,t){this.domNode.setWidth(t),this.domNode.setHeight(e),this.domNode.setRight(0),this.domNode.setTop(0)}onDidScroll(e){return this._shouldRender=this._onElementScrollSize(e.scrollHeight)||this._shouldRender,this._shouldRender=this._onElementScrollPosition(e.scrollTop)||this._shouldRender,this._shouldRender=this._onElementSize(e.height)||this._shouldRender,this._shouldRender}_mouseDownRelativePosition(e,t){return t}_sliderMousePosition(e){return e.posy}_sliderOrthogonalMousePosition(e){return e.posx}_updateScrollbarSize(e){this.slider.setWidth(e)}writeScrollPosition(e,t){e.scrollTop=t}updateOptions(e){this.updateScrollbarSize(2===e.vertical?0:e.verticalScrollbarSize),this._scrollbarState.setOppositeScrollbarSize(0),this._visibilityController.setVisibility(e.vertical),this._scrollByPage=e.scrollByPage}}var v=i(46718),C=i(98729),w=i(93379),y=i.n(w),S=i(7795),x=i.n(S),k=i(90569),L=i.n(k),E=i(3565),N=i.n(E),D=i(19216),I=i.n(D),T=i(44589),A=i.n(T),R=i(33304),M={};M.styleTagTransform=A(),M.setAttributes=N(),M.insert=L().bind(null,"head"),M.domAPI=x(),M.insertStyleElement=I(),y()(R.Z,M),R.Z&&R.Z.locals&&R.Z.locals;class O{constructor(e,t,i){this.timestamp=e,this.deltaX=t,this.deltaY=i,this.score=0}}class P{constructor(){this._capacity=5,this._memory=[],this._front=-1,this._rear=-1}isPhysicalMouseWheel(){if(-1===this._front&&-1===this._rear)return!1;let e=1,t=0,i=1,n=this._rear;for(;;){const o=n===this._front?e:Math.pow(2,-i);if(e-=o,t+=this._memory[n].score*o,n===this._front)break;n=(this._capacity+n-1)%this._capacity,i++}return t<=.5}accept(e,t,i){const n=new O(e,t,i);n.score=this._computeScore(n),-1===this._front&&-1===this._rear?(this._memory[0]=n,this._front=0,this._rear=0):(this._rear=(this._rear+1)%this._capacity,this._rear===this._front&&(this._front=(this._front+1)%this._capacity),this._memory[this._rear]=n)}_computeScore(e){if(Math.abs(e.deltaX)>0&&Math.abs(e.deltaY)>0)return 1;let t=.5;return-1===this._front&&-1===this._rear||this._memory[this._rear],this._isAlmostInt(e.deltaX)&&this._isAlmostInt(e.deltaY)||(t+=.25),Math.min(Math.max(t,0),1)}_isAlmostInt(e){return Math.abs(Math.round(e)-e)<.01}}P.INSTANCE=new P;class F extends l.${constructor(e,t,i){super(),this._onScroll=this._register(new v.Q5),this.onScroll=this._onScroll.event,this._onWillScroll=this._register(new v.Q5),e.style.overflow="hidden",this._options=function(e){const t={lazyRender:void 0!==e.lazyRender&&e.lazyRender,className:void 0!==e.className?e.className:"",useShadows:void 0===e.useShadows||e.useShadows,handleMouseWheel:void 0===e.handleMouseWheel||e.handleMouseWheel,flipAxes:void 0!==e.flipAxes&&e.flipAxes,consumeMouseWheelIfScrollbarIsNeeded:void 0!==e.consumeMouseWheelIfScrollbarIsNeeded&&e.consumeMouseWheelIfScrollbarIsNeeded,alwaysConsumeMouseWheel:void 0!==e.alwaysConsumeMouseWheel&&e.alwaysConsumeMouseWheel,scrollYToX:void 0!==e.scrollYToX&&e.scrollYToX,mouseWheelScrollSensitivity:void 0!==e.mouseWheelScrollSensitivity?e.mouseWheelScrollSensitivity:1,fastScrollSensitivity:void 0!==e.fastScrollSensitivity?e.fastScrollSensitivity:5,scrollPredominantAxis:void 0===e.scrollPredominantAxis||e.scrollPredominantAxis,mouseWheelSmoothScroll:void 0===e.mouseWheelSmoothScroll||e.mouseWheelSmoothScroll,arrowSize:void 0!==e.arrowSize?e.arrowSize:11,listenOnDomNode:void 0!==e.listenOnDomNode?e.listenOnDomNode:null,horizontal:void 0!==e.horizontal?e.horizontal:1,horizontalScrollbarSize:void 0!==e.horizontalScrollbarSize?e.horizontalScrollbarSize:10,horizontalSliderSize:void 0!==e.horizontalSliderSize?e.horizontalSliderSize:0,horizontalHasArrows:void 0!==e.horizontalHasArrows&&e.horizontalHasArrows,vertical:void 0!==e.vertical?e.vertical:1,verticalScrollbarSize:void 0!==e.verticalScrollbarSize?e.verticalScrollbarSize:10,verticalHasArrows:void 0!==e.verticalHasArrows&&e.verticalHasArrows,verticalSliderSize:void 0!==e.verticalSliderSize?e.verticalSliderSize:0,scrollByPage:void 0!==e.scrollByPage&&e.scrollByPage};return t.horizontalSliderSize=void 0!==e.horizontalSliderSize?e.horizontalSliderSize:t.horizontalScrollbarSize,t.verticalSliderSize=void 0!==e.verticalSliderSize?e.verticalSliderSize:t.verticalScrollbarSize,g.dz&&(t.className+=" mac"),t}(t),this._scrollable=i,this._register(this._scrollable.onScroll((e=>{this._onWillScroll.fire(e),this._onDidScroll(e),this._onScroll.fire(e)})));const n={onMouseWheel:e=>this._onMouseWheel(e),onDragStart:()=>this._onDragStart(),onDragEnd:()=>this._onDragEnd()};this._verticalScrollbar=this._register(new b(this._scrollable,this._options,n)),this._horizontalScrollbar=this._register(new _(this._scrollable,this._options,n)),this._domNode=document.createElement("div"),this._domNode.className="monaco-scrollable-element "+this._options.className,this._domNode.setAttribute("role","presentation"),this._domNode.style.position="relative",this._domNode.style.overflow="hidden",this._domNode.appendChild(e),this._domNode.appendChild(this._horizontalScrollbar.domNode.domNode),this._domNode.appendChild(this._verticalScrollbar.domNode.domNode),this._options.useShadows?(this._leftShadowDomNode=(0,r.X)(document.createElement("div")),this._leftShadowDomNode.setClassName("shadow"),this._domNode.appendChild(this._leftShadowDomNode.domNode),this._topShadowDomNode=(0,r.X)(document.createElement("div")),this._topShadowDomNode.setClassName("shadow"),this._domNode.appendChild(this._topShadowDomNode.domNode),this._topLeftShadowDomNode=(0,r.X)(document.createElement("div")),this._topLeftShadowDomNode.setClassName("shadow"),this._domNode.appendChild(this._topLeftShadowDomNode.domNode)):(this._leftShadowDomNode=null,this._topShadowDomNode=null,this._topLeftShadowDomNode=null),this._listenOnDomNode=this._options.listenOnDomNode||this._domNode,this._mouseWheelToDispose=[],this._setListeningToMouseWheel(this._options.handleMouseWheel),this.onmouseover(this._listenOnDomNode,(e=>this._onMouseOver(e))),this.onnonbubblingmouseout(this._listenOnDomNode,(e=>this._onMouseOut(e))),this._hideTimeout=this._register(new c._F),this._isDragging=!1,this._mouseIsOver=!1,this._shouldRender=!0,this._revealOnScroll=!0}get options(){return this._options}dispose(){this._mouseWheelToDispose=(0,u.B9)(this._mouseWheelToDispose),super.dispose()}getDomNode(){return this._domNode}getOverviewRulerLayoutInfo(){return{parent:this._domNode,insertBefore:this._verticalScrollbar.domNode.domNode}}delegateVerticalScrollbarMouseDown(e){this._verticalScrollbar.delegateMouseDown(e)}getScrollDimensions(){return this._scrollable.getScrollDimensions()}setScrollDimensions(e){this._scrollable.setScrollDimensions(e,!1)}updateClassName(e){this._options.className=e,g.dz&&(this._options.className+=" mac"),this._domNode.className="monaco-scrollable-element "+this._options.className}updateOptions(e){void 0!==e.handleMouseWheel&&(this._options.handleMouseWheel=e.handleMouseWheel,this._setListeningToMouseWheel(this._options.handleMouseWheel)),void 0!==e.mouseWheelScrollSensitivity&&(this._options.mouseWheelScrollSensitivity=e.mouseWheelScrollSensitivity),void 0!==e.fastScrollSensitivity&&(this._options.fastScrollSensitivity=e.fastScrollSensitivity),void 0!==e.scrollPredominantAxis&&(this._options.scrollPredominantAxis=e.scrollPredominantAxis),void 0!==e.horizontal&&(this._options.horizontal=e.horizontal),void 0!==e.vertical&&(this._options.vertical=e.vertical),void 0!==e.horizontalScrollbarSize&&(this._options.horizontalScrollbarSize=e.horizontalScrollbarSize),void 0!==e.verticalScrollbarSize&&(this._options.verticalScrollbarSize=e.verticalScrollbarSize),void 0!==e.scrollByPage&&(this._options.scrollByPage=e.scrollByPage),this._horizontalScrollbar.updateOptions(this._options),this._verticalScrollbar.updateOptions(this._options),this._options.lazyRender||this._render()}_setListeningToMouseWheel(e){if(this._mouseWheelToDispose.length>0!==e&&(this._mouseWheelToDispose=(0,u.B9)(this._mouseWheelToDispose),e)){const e=e=>{this._onMouseWheel(new s.q(e))};this._mouseWheelToDispose.push(o.nm(this._listenOnDomNode,o.tw.MOUSE_WHEEL,e,{passive:!1}))}}_onMouseWheel(e){const t=P.INSTANCE;{const i=window.devicePixelRatio/(0,n.getZoomFactor)();g.ED||g.IJ?t.accept(Date.now(),e.deltaX/i,e.deltaY/i):t.accept(Date.now(),e.deltaX,e.deltaY)}let i=!1;if(e.deltaY||e.deltaX){let n=e.deltaY*this._options.mouseWheelScrollSensitivity,o=e.deltaX*this._options.mouseWheelScrollSensitivity;this._options.scrollPredominantAxis&&(Math.abs(n)>=Math.abs(o)?o=0:n=0),this._options.flipAxes&&([n,o]=[o,n]);const r=!g.dz&&e.browserEvent&&e.browserEvent.shiftKey;!this._options.scrollYToX&&!r||o||(o=n,n=0),e.browserEvent&&e.browserEvent.altKey&&(o*=this._options.fastScrollSensitivity,n*=this._options.fastScrollSensitivity);const s=this._scrollable.getFutureScrollPosition();let a={};if(n){const e=50*n,t=s.scrollTop-(e<0?Math.floor(e):Math.ceil(e));this._verticalScrollbar.writeScrollPosition(a,t)}if(o){const e=50*o,t=s.scrollLeft-(e<0?Math.floor(e):Math.ceil(e));this._horizontalScrollbar.writeScrollPosition(a,t)}a=this._scrollable.validateScrollPosition(a),(s.scrollLeft!==a.scrollLeft||s.scrollTop!==a.scrollTop)&&(this._options.mouseWheelSmoothScroll&&t.isPhysicalMouseWheel()?this._scrollable.setScrollPositionSmooth(a):this._scrollable.setScrollPositionNow(a),i=!0)}let o=i;!o&&this._options.alwaysConsumeMouseWheel&&(o=!0),!o&&this._options.consumeMouseWheelIfScrollbarIsNeeded&&(this._verticalScrollbar.isNeeded()||this._horizontalScrollbar.isNeeded())&&(o=!0),o&&(e.preventDefault(),e.stopPropagation())}_onDidScroll(e){this._shouldRender=this._horizontalScrollbar.onDidScroll(e)||this._shouldRender,this._shouldRender=this._verticalScrollbar.onDidScroll(e)||this._shouldRender,this._options.useShadows&&(this._shouldRender=!0),this._revealOnScroll&&this._reveal(),this._options.lazyRender||this._render()}renderNow(){if(!this._options.lazyRender)throw new Error("Please use `lazyRender` together with `renderNow`!");this._render()}_render(){if(this._shouldRender&&(this._shouldRender=!1,this._horizontalScrollbar.render(),this._verticalScrollbar.render(),this._options.useShadows)){const e=this._scrollable.getCurrentScrollPosition(),t=e.scrollTop>0,i=e.scrollLeft>0,n=i?" left":"",o=t?" top":"",r=i||t?" top-left-corner":"";this._leftShadowDomNode.setClassName(`shadow${n}`),this._topShadowDomNode.setClassName(`shadow${o}`),this._topLeftShadowDomNode.setClassName(`shadow${r}${o}${n}`)}}_onDragStart(){this._isDragging=!0,this._reveal()}_onDragEnd(){this._isDragging=!1,this._hide()}_onMouseOut(e){this._mouseIsOver=!1,this._hide()}_onMouseOver(e){this._mouseIsOver=!0,this._reveal()}_reveal(){this._verticalScrollbar.beginReveal(),this._horizontalScrollbar.beginReveal(),this._scheduleHide()}_hide(){this._mouseIsOver||this._isDragging||(this._verticalScrollbar.beginHide(),this._horizontalScrollbar.beginHide())}_scheduleHide(){this._mouseIsOver||this._isDragging||this._hideTimeout.cancelAndSet((()=>this._hide()),500)}}class B extends F{constructor(e,t){(t=t||{}).mouseWheelSmoothScroll=!1;const i=new C.Rm({forceIntegerValues:!0,smoothScrollDuration:0,scheduleAtNextAnimationFrame:e=>o.jL(e)});super(e,t,i),this._register(i)}setScrollPosition(e){this._scrollable.setScrollPositionNow(e)}}class W extends F{constructor(e,t,i){super(e,t,i)}setScrollPosition(e){e.reuseAnimation?this._scrollable.setScrollPositionSmooth(e,e.reuseAnimation):this._scrollable.setScrollPositionNow(e)}getScrollPosition(){return this._scrollable.getCurrentScrollPosition()}}class V extends F{constructor(e,t){(t=t||{}).mouseWheelSmoothScroll=!1;const i=new C.Rm({forceIntegerValues:!1,smoothScrollDuration:0,scheduleAtNextAnimationFrame:e=>o.jL(e)});super(e,t,i),this._register(i),this._element=e,this.onScroll((e=>{e.scrollTopChanged&&(this._element.scrollTop=e.scrollTop),e.scrollLeftChanged&&(this._element.scrollLeft=e.scrollLeft)})),this.scanDomNode()}setScrollPosition(e){this._scrollable.setScrollPositionNow(e)}getScrollPosition(){return this._scrollable.getCurrentScrollPosition()}scanDomNode(){this.setScrollDimensions({width:this._element.clientWidth,scrollWidth:this._element.scrollWidth,height:this._element.clientHeight,scrollHeight:this._element.scrollHeight}),this.setScrollPosition({scrollLeft:this._element.scrollLeft,scrollTop:this._element.scrollTop})}}},92987:function(e,t,i){"use strict";i.d(t,{M:function(){return A},z:function(){return R}});var n=i(68695),o=i(71036),r=i(98677),s=i(57800),a=i(18689),l=i(46718),c=i(4004),d=i(1478),u=i(98729),h=i(28295),g=i(93379),p=i.n(g),m=i(7795),f=i.n(m),_=i(90569),b=i.n(_),v=i(3565),C=i.n(v),w=i(19216),y=i.n(w),S=i(44589),x=i.n(S),k=i(42254),L={};L.styleTagTransform=x(),L.setAttributes=C(),L.insert=b().bind(null,"head"),L.domAPI=f(),L.insertStyleElement=y(),p()(k.Z,L),k.Z&&k.Z.locals&&k.Z.locals;const E={separatorBorder:a.Il.transparent};class N{constructor(e,t,i,n){this.container=e,this.view=t,this.disposable=n,this._cachedVisibleSize=void 0,"number"==typeof i?(this._size=i,this._cachedVisibleSize=void 0,e.classList.add("visible")):(this._size=0,this._cachedVisibleSize=i.cachedVisibleSize)}set size(e){this._size=e}get size(){return this._size}get visible(){return void 0===this._cachedVisibleSize}setVisible(e,t){e!==this.visible&&(e?(this.size=(0,d.uZ)(this._cachedVisibleSize,this.viewMinimumSize,this.viewMaximumSize),this._cachedVisibleSize=void 0):(this._cachedVisibleSize="number"==typeof t?t:this.size,this.size=0),this.container.classList.toggle("visible",e),this.view.setVisible&&this.view.setVisible(e))}get minimumSize(){return this.visible?this.view.minimumSize:0}get viewMinimumSize(){return this.view.minimumSize}get maximumSize(){return this.visible?this.view.maximumSize:0}get viewMaximumSize(){return this.view.maximumSize}get priority(){return this.view.priority}get snap(){return!!this.view.snap}set enabled(e){this.container.style.pointerEvents=e?"":"none"}layout(e,t){this.layoutContainer(e),this.view.layout(this.size,e,t)}dispose(){return this.disposable.dispose(),this.view}}class D extends N{layoutContainer(e){this.container.style.top=`${e}px`,this.container.style.height=`${this.size}px`}}class I extends N{layoutContainer(e){this.container.style.left=`${e}px`,this.container.style.width=`${this.size}px`}}var T,A;!function(e){e[e.Idle=0]="Idle",e[e.Busy=1]="Busy"}(T||(T={})),function(e){e.Distribute={type:"distribute"},e.Split=function(e){return{type:"split",index:e}},e.Invisible=function(e){return{type:"invisible",cachedVisibleSize:e}}}(A||(A={}));class R extends c.JT{constructor(e,t={}){var i,o,s,a,c;super(),this.size=0,this.contentSize=0,this.proportions=void 0,this.viewItems=[],this.sashItems=[],this.state=T.Idle,this._onDidSashChange=this._register(new l.Q5),this._onDidSashReset=this._register(new l.Q5),this._startSnappingEnabled=!0,this._endSnappingEnabled=!0,this.onDidSashChange=this._onDidSashChange.event,this.onDidSashReset=this._onDidSashReset.event,this.orientation=null!==(i=t.orientation)&&void 0!==i?i:0,this.inverseAltBehavior=null!==(o=t.inverseAltBehavior)&&void 0!==o&&o,this.proportionalLayout=null===(s=t.proportionalLayout)||void 0===s||s,this.getSashOrthogonalSize=t.getSashOrthogonalSize,this.el=document.createElement("div"),this.el.classList.add("monaco-split-view2"),this.el.classList.add(0===this.orientation?"vertical":"horizontal"),e.appendChild(this.el),this.sashContainer=(0,n.R3)(this.el,(0,n.$)(".sash-container")),this.viewContainer=(0,n.$)(".split-view-container"),this.scrollable=new u.Rm({forceIntegerValues:!0,smoothScrollDuration:125,scheduleAtNextAnimationFrame:n.jL}),this.scrollableElement=this._register(new r.$Z(this.viewContainer,{vertical:0===this.orientation?null!==(a=t.scrollbarVisibility)&&void 0!==a?a:1:2,horizontal:1===this.orientation?null!==(c=t.scrollbarVisibility)&&void 0!==c?c:1:2},this.scrollable)),this.onDidScroll=this.scrollableElement.onScroll,this._register(this.onDidScroll((e=>{this.viewContainer.scrollTop=e.scrollTop,this.viewContainer.scrollLeft=e.scrollLeft}))),(0,n.R3)(this.el,this.scrollableElement.getDomNode()),this.style(t.styles||E),t.descriptor&&(this.size=t.descriptor.size,t.descriptor.views.forEach(((e,t)=>{const i=h.o8(e.visible)||e.visible?e.size:{type:"invisible",cachedVisibleSize:e.size},n=e.view;this.doAddView(n,i,t,!0)})),this.contentSize=this.viewItems.reduce(((e,t)=>e+t.size),0),this.saveProportions())}get orthogonalStartSash(){return this._orthogonalStartSash}get orthogonalEndSash(){return this._orthogonalEndSash}get startSnappingEnabled(){return this._startSnappingEnabled}get endSnappingEnabled(){return this._endSnappingEnabled}set orthogonalStartSash(e){for(const t of this.sashItems)t.sash.orthogonalStartSash=e;this._orthogonalStartSash=e}set orthogonalEndSash(e){for(const t of this.sashItems)t.sash.orthogonalEndSash=e;this._orthogonalEndSash=e}set startSnappingEnabled(e){this._startSnappingEnabled!==e&&(this._startSnappingEnabled=e,this.updateSashEnablement())}set endSnappingEnabled(e){this._endSnappingEnabled!==e&&(this._endSnappingEnabled=e,this.updateSashEnablement())}style(e){e.separatorBorder.isTransparent()?(this.el.classList.remove("separator-border"),this.el.style.removeProperty("--separator-border")):(this.el.classList.add("separator-border"),this.el.style.setProperty("--separator-border",e.separatorBorder.toString()))}addView(e,t,i=this.viewItems.length,n){this.doAddView(e,t,i,n)}layout(e,t){const i=Math.max(this.size,this.contentSize);if(this.size=e,this.layoutContext=t,this.proportions)for(let t=0;t1===this.viewItems[e].priority)),o=t.filter((e=>2===this.viewItems[e].priority));this.resize(this.viewItems.length-1,e-i,void 0,n,o)}this.distributeEmptySpace(),this.layoutViews()}saveProportions(){this.proportionalLayout&&this.contentSize>0&&(this.proportions=this.viewItems.map((e=>e.size/this.contentSize)))}onSashStart({sash:e,start:t,alt:i}){for(const e of this.viewItems)e.enabled=!1;const o=this.sashItems.findIndex((t=>t.sash===e)),r=(0,c.F8)((0,n.nm)(document.body,"keydown",(e=>a(this.sashDragState.current,e.altKey))),(0,n.nm)(document.body,"keyup",(()=>a(this.sashDragState.current,!1)))),a=(e,t)=>{const i=this.viewItems.map((e=>e.size));let n,a,l=Number.NEGATIVE_INFINITY,c=Number.POSITIVE_INFINITY;if(this.inverseAltBehavior&&(t=!t),t)if(o===this.sashItems.length-1){const e=this.viewItems[o];l=(e.minimumSize-e.size)/2,c=(e.maximumSize-e.size)/2}else{const e=this.viewItems[o+1];l=(e.size-e.maximumSize)/2,c=(e.size-e.minimumSize)/2}if(!t){const e=(0,s.w6)(o,-1),t=(0,s.w6)(o+1,this.viewItems.length),r=e.reduce(((e,t)=>e+(this.viewItems[t].minimumSize-i[t])),0),l=e.reduce(((e,t)=>e+(this.viewItems[t].viewMaximumSize-i[t])),0),c=0===t.length?Number.POSITIVE_INFINITY:t.reduce(((e,t)=>e+(i[t]-this.viewItems[t].minimumSize)),0),d=0===t.length?Number.NEGATIVE_INFINITY:t.reduce(((e,t)=>e+(i[t]-this.viewItems[t].viewMaximumSize)),0),u=Math.max(r,d),h=Math.min(c,l),g=this.findFirstSnapIndex(e),p=this.findFirstSnapIndex(t);if("number"==typeof g){const e=this.viewItems[g],t=Math.floor(e.viewMinimumSize/2);n={index:g,limitDelta:e.visible?u-t:u+t,size:e.size}}if("number"==typeof p){const e=this.viewItems[p],t=Math.floor(e.viewMinimumSize/2);a={index:p,limitDelta:e.visible?h+t:h-t,size:e.size}}}this.sashDragState={start:e,current:e,index:o,sizes:i,minDelta:l,maxDelta:c,alt:t,snapBefore:n,snapAfter:a,disposable:r}};a(t,i)}onSashChange({current:e}){const{index:t,start:i,sizes:n,alt:o,minDelta:r,maxDelta:s,snapBefore:a,snapAfter:l}=this.sashDragState;this.sashDragState.current=e;const c=e-i,d=this.resize(t,c,n,void 0,void 0,r,s,a,l);if(o){const e=t===this.sashItems.length-1,i=this.viewItems.map((e=>e.size)),n=e?t:t+1,o=this.viewItems[n],r=o.size-o.maximumSize,s=o.size-o.minimumSize,a=e?t-1:t+1;this.resize(a,-d,i,void 0,void 0,r,s)}this.distributeEmptySpace(),this.layoutViews()}onSashEnd(e){this._onDidSashChange.fire(e),this.sashDragState.disposable.dispose(),this.saveProportions();for(const e of this.viewItems)e.enabled=!0}onViewChange(e,t){const i=this.viewItems.indexOf(e);i<0||i>=this.viewItems.length||(t="number"==typeof t?t:e.size,t=(0,d.uZ)(t,e.minimumSize,e.maximumSize),this.inverseAltBehavior&&i>0?(this.resize(i-1,Math.floor((e.size-t)/2)),this.distributeEmptySpace(),this.layoutViews()):(e.size=t,this.relayout([i],void 0)))}resizeView(e,t){if(this.state!==T.Idle)throw new Error("Cant modify splitview");if(this.state=T.Busy,e<0||e>=this.viewItems.length)return;const i=(0,s.w6)(this.viewItems.length).filter((t=>t!==e)),n=[...i.filter((e=>1===this.viewItems[e].priority)),e],o=i.filter((e=>2===this.viewItems[e].priority)),r=this.viewItems[e];t=Math.round(t),t=(0,d.uZ)(t,r.minimumSize,Math.min(r.maximumSize,this.size)),r.size=t,this.relayout(n,o),this.state=T.Idle}distributeViewSizes(){const e=[];let t=0;for(const i of this.viewItems)i.maximumSize-i.minimumSize>0&&(e.push(i),t+=i.size);const i=Math.floor(t/e.length);for(const t of e)t.size=(0,d.uZ)(i,t.minimumSize,t.maximumSize);const n=(0,s.w6)(this.viewItems.length),o=n.filter((e=>1===this.viewItems[e].priority)),r=n.filter((e=>2===this.viewItems[e].priority));this.relayout(o,r)}getViewSize(e){return e<0||e>=this.viewItems.length?-1:this.viewItems[e].size}doAddView(e,t,i=this.viewItems.length,r){if(this.state!==T.Idle)throw new Error("Cant modify splitview");this.state=T.Busy;const a=(0,n.$)(".split-view-view");i===this.viewItems.length?this.viewContainer.appendChild(a):this.viewContainer.insertBefore(a,this.viewContainer.children.item(i));const d=e.onDidChange((e=>this.onViewChange(p,e))),u=(0,c.OF)((()=>this.viewContainer.removeChild(a))),h=(0,c.F8)(d,u);let g;g="number"==typeof t?t:"split"===t.type?this.getViewSize(t.index)/2:"invisible"===t.type?{cachedVisibleSize:t.cachedVisibleSize}:e.minimumSize;const p=0===this.orientation?new D(a,e,g,h):new I(a,e,g,h);if(this.viewItems.splice(i,0,p),this.viewItems.length>1){let e={orthogonalStartSash:this.orthogonalStartSash,orthogonalEndSash:this.orthogonalEndSash};const t=0===this.orientation?new o.g(this.sashContainer,{getHorizontalSashTop:e=>this.getSashPosition(e),getHorizontalSashWidth:this.getSashOrthogonalSize},Object.assign(Object.assign({},e),{orientation:1})):new o.g(this.sashContainer,{getVerticalSashLeft:e=>this.getSashPosition(e),getVerticalSashHeight:this.getSashOrthogonalSize},Object.assign(Object.assign({},e),{orientation:0})),n=0===this.orientation?e=>({sash:t,start:e.startY,current:e.currentY,alt:e.altKey}):e=>({sash:t,start:e.startX,current:e.currentX,alt:e.altKey}),r=l.ju.map(t.onDidStart,n)(this.onSashStart,this),a=l.ju.map(t.onDidChange,n)(this.onSashChange,this),d=l.ju.map(t.onDidEnd,(()=>this.sashItems.findIndex((e=>e.sash===t)))),u=d(this.onSashEnd,this),h=t.onDidReset((()=>{const e=this.sashItems.findIndex((e=>e.sash===t)),i=(0,s.w6)(e,-1),n=(0,s.w6)(e+1,this.viewItems.length),o=this.findFirstSnapIndex(i),r=this.findFirstSnapIndex(n);("number"!=typeof o||this.viewItems[o].visible)&&("number"!=typeof r||this.viewItems[r].visible)&&this._onDidSashReset.fire(e)})),g=(0,c.F8)(r,a,u,h,t),p={sash:t,disposable:g};this.sashItems.splice(i-1,0,p)}let m;a.appendChild(e.element),"number"!=typeof t&&"split"===t.type&&(m=[t.index]),r||this.relayout([i],m),this.state=T.Idle,r||"number"==typeof t||"distribute"!==t.type||this.distributeViewSizes()}relayout(e,t){const i=this.viewItems.reduce(((e,t)=>e+t.size),0);this.resize(this.viewItems.length-1,this.size-i,void 0,e,t),this.distributeEmptySpace(),this.layoutViews(),this.saveProportions()}resize(e,t,i=this.viewItems.map((e=>e.size)),n,o,r=Number.NEGATIVE_INFINITY,a=Number.POSITIVE_INFINITY,l,c){if(e<0||e>=this.viewItems.length)return 0;const u=(0,s.w6)(e,-1),h=(0,s.w6)(e+1,this.viewItems.length);if(o)for(const e of o)(0,s.zI)(u,e),(0,s.zI)(h,e);if(n)for(const e of n)(0,s.al)(u,e),(0,s.al)(h,e);const g=u.map((e=>this.viewItems[e])),p=u.map((e=>i[e])),m=h.map((e=>this.viewItems[e])),f=h.map((e=>i[e])),_=u.reduce(((e,t)=>e+(this.viewItems[t].minimumSize-i[t])),0),b=u.reduce(((e,t)=>e+(this.viewItems[t].maximumSize-i[t])),0),v=0===h.length?Number.POSITIVE_INFINITY:h.reduce(((e,t)=>e+(i[t]-this.viewItems[t].minimumSize)),0),C=0===h.length?Number.NEGATIVE_INFINITY:h.reduce(((e,t)=>e+(i[t]-this.viewItems[t].maximumSize)),0),w=Math.max(_,C,r),y=Math.min(v,b,a);let S=!1;if(l){const e=this.viewItems[l.index],i=t>=l.limitDelta;S=i!==e.visible,e.setVisible(i,l.size)}if(!S&&c){const e=this.viewItems[c.index],i=te+t.size),0);let i=this.size-t;const n=(0,s.w6)(this.viewItems.length-1,-1),o=n.filter((e=>1===this.viewItems[e].priority)),r=n.filter((e=>2===this.viewItems[e].priority));for(const e of r)(0,s.zI)(n,e);for(const e of o)(0,s.al)(n,e);"number"==typeof e&&(0,s.al)(n,e);for(let e=0;0!==i&&ee+t.size),0);let e=0;for(const t of this.viewItems)t.layout(e,this.layoutContext),e+=t.size;this.sashItems.forEach((e=>e.sash.layout())),this.updateSashEnablement(),this.updateScrollableElement()}updateScrollableElement(){0===this.orientation?this.scrollableElement.setScrollDimensions({height:this.size,scrollHeight:this.contentSize}):this.scrollableElement.setScrollDimensions({width:this.size,scrollWidth:this.contentSize})}updateSashEnablement(){let e=!1;const t=this.viewItems.map((t=>e=t.size-t.minimumSize>0||e));e=!1;const i=this.viewItems.map((t=>e=t.maximumSize-t.size>0||e)),n=[...this.viewItems].reverse();e=!1;const o=n.map((t=>e=t.size-t.minimumSize>0||e)).reverse();e=!1;const r=n.map((t=>e=t.maximumSize-t.size>0||e)).reverse();let a=0;for(let e=0;e0||this.startSnappingEnabled)?n.state=1:u&&t[e]&&(a0)return;if(!e.visible&&e.snap)return t}}dispose(){super.dispose(),(0,c.B9)(this.viewItems),this.viewItems=[],this.sashItems.forEach((e=>e.disposable.dispose())),this.sashItems=[]}}},43479:function(e,t,i){"use strict";i.d(t,{$:function(){return l}});var n=i(68695),o=i(33200),r=i(80428),s=i(83055),a=i(4004);class l extends a.JT{onclick(e,t){this._register(n.nm(e,n.tw.CLICK,(e=>t(new r.n(e)))))}onmousedown(e,t){this._register(n.nm(e,n.tw.MOUSE_DOWN,(e=>t(new r.n(e)))))}onmouseover(e,t){this._register(n.nm(e,n.tw.MOUSE_OVER,(e=>t(new r.n(e)))))}onnonbubblingmouseout(e,t){this._register(n.j_(e,(e=>t(new r.n(e)))))}onkeydown(e,t){this._register(n.nm(e,n.tw.KEY_DOWN,(e=>t(new o.y(e)))))}onkeyup(e,t){this._register(n.nm(e,n.tw.KEY_UP,(e=>t(new o.y(e)))))}oninput(e,t){this._register(n.nm(e,n.tw.INPUT,t))}onblur(e,t){this._register(n.nm(e,n.tw.BLUR,t))}onfocus(e,t){this._register(n.nm(e,n.tw.FOCUS,t))}ignoreGesture(e){s.o.ignoreTarget(e)}}},11007:function(e,t,i){"use strict";i.d(t,{Wi:function(){return l},Z0:function(){return c},aU:function(){return a},eZ:function(){return u},wY:function(){return d}});var n=i(46718),o=i(4004),r=i(89982),s=function(e,t,i,n){return new(i||(i=Promise))((function(o,r){function s(e){try{l(n.next(e))}catch(e){r(e)}}function a(e){try{l(n.throw(e))}catch(e){r(e)}}function l(e){var t;e.done?o(e.value):(t=e.value,t instanceof i?t:new i((function(e){e(t)}))).then(s,a)}l((n=n.apply(e,t||[])).next())}))};class a extends o.JT{constructor(e,t="",i="",o=!0,r){super(),this._onDidChange=this._register(new n.Q5),this.onDidChange=this._onDidChange.event,this._enabled=!0,this._id=e,this._label=t,this._cssClass=i,this._enabled=o,this._actionCallback=r}get id(){return this._id}get label(){return this._label}set label(e){this._setLabel(e)}_setLabel(e){this._label!==e&&(this._label=e,this._onDidChange.fire({label:e}))}get tooltip(){return this._tooltip||""}set tooltip(e){this._setTooltip(e)}_setTooltip(e){this._tooltip!==e&&(this._tooltip=e,this._onDidChange.fire({tooltip:e}))}get class(){return this._cssClass}set class(e){this._setClass(e)}_setClass(e){this._cssClass!==e&&(this._cssClass=e,this._onDidChange.fire({class:e}))}get enabled(){return this._enabled}set enabled(e){this._setEnabled(e)}_setEnabled(e){this._enabled!==e&&(this._enabled=e,this._onDidChange.fire({enabled:e}))}get checked(){return this._checked}set checked(e){this._setChecked(e)}_setChecked(e){this._checked!==e&&(this._checked=e,this._onDidChange.fire({checked:e}))}run(e,t){return s(this,void 0,void 0,(function*(){this._actionCallback&&(yield this._actionCallback(e))}))}}class l extends o.JT{constructor(){super(...arguments),this._onBeforeRun=this._register(new n.Q5),this.onBeforeRun=this._onBeforeRun.event,this._onDidRun=this._register(new n.Q5),this.onDidRun=this._onDidRun.event}run(e,t){return s(this,void 0,void 0,(function*(){if(!e.enabled)return;let i;this._onBeforeRun.fire({action:e});try{yield this.runAction(e,t)}catch(e){i=e}this._onDidRun.fire({action:e,error:i})}))}runAction(e,t){return s(this,void 0,void 0,(function*(){yield e.run(t)}))}}class c extends a{constructor(e){super(c.ID,e,e?"separator text":"separator"),this.checked=!1,this.enabled=!1}}c.ID="vs.actions.separator";class d{constructor(e,t,i,n){this.tooltip="",this.enabled=!0,this.checked=void 0,this.id=e,this.label=t,this.class=n,this._actions=i}get actions(){return this._actions}dispose(){}run(){return s(this,void 0,void 0,(function*(){}))}}class u extends a{constructor(){super(u.ID,r.NC("vs/base/common/actions","submenu.empty","(empty)"),void 0,!1)}}u.ID="vs.actions.empty"},57800:function(e,t,i){"use strict";function n(e,t=0){return e[e.length-(1+t)]}function o(e){if(0===e.length)throw new Error("Invalid tail call");return[e.slice(0,e.length-1),e[e.length-1]]}function r(e,t,i=((e,t)=>e===t)){if(e===t)return!0;if(!e||!t)return!1;if(e.length!==t.length)return!1;for(let n=0,o=e.length;n0))return r;o=r-1}}return-(n+1)}function a(e,t){let i=0,n=e.length;if(0===n)return 0;for(;i=t.length)throw new TypeError("invalid index");let n=t[Math.floor(t.length*Math.random())],o=[],r=[],s=[];for(let e of t){const t=i(e,n);t<0?o.push(e):t>0?r.push(e):s.push(e)}return e!!e))}function u(e){return!Array.isArray(e)||0===e.length}function h(e){return Array.isArray(e)&&e.length>0}function g(e,t=(e=>e)){const i=new Set;return e.filter((e=>{const n=t(e);return!i.has(n)&&(i.add(n),!0)}))}function p(e,t){const i=function(e,t){for(let i=e.length-1;i>=0;i--)if(t(e[i]))return i;return-1}(e,t);if(-1!==i)return e[i]}function m(e,t){return e.length>0?e[0]:t}function f(e){return[].concat(...e)}function _(e,t){let i="number"==typeof t?e:0;"number"==typeof t?i=e:(i=0,t=e);const n=[];if(i<=t)for(let e=i;et;e--)n.push(e);return n}function b(e,t,i){const n=e.slice(0,t),o=e.slice(t);return n.concat(i,o)}function v(e,t){const i=e.indexOf(t);i>-1&&(e.splice(i,1),e.unshift(t))}function C(e,t){const i=e.indexOf(t);i>-1&&(e.splice(i,1),e.push(t))}function w(e){return Array.isArray(e)?e:[e]}function y(e,t,i,n){const o=S(e,t),r=e.splice(o,i);return function(e,t,i){const n=S(e,t),o=e.length,r=i.length;e.length=o+r;for(let t=o-1;t>=n;t--)e[t+r]=e[t];for(let t=0;tt(e(i),e(n))}i.d(t,{Dc:function(){return L},EB:function(){return g},Gb:function(){return n},H9:function(){return D},HW:function(){return l},JH:function(){return o},Of:function(){return h},VJ:function(){return N},XY:function(){return u},Xh:function(){return m},Zv:function(){return b},_2:function(){return w},al:function(){return C},dF:function(){return p},db:function(){return y},fS:function(){return r},fv:function(){return k},jV:function(){return E},kX:function(){return d},lG:function(){return a},ry:function(){return s},tT:function(){return x},vM:function(){return c},w6:function(){return _},xH:function(){return f},zI:function(){return v}});const k=(e,t)=>e-t;function L(e,t){if(0===e.length)return;let i=e[0];for(let n=1;n0&&(i=o)}return i}function E(e,t){if(0===e.length)return;let i=e[0];for(let n=1;n=0&&(i=o)}return i}function N(e,t){return L(e,((e,i)=>-t(e,i)))}class D{constructor(e){this.items=e,this.firstIdx=0,this.lastIdx=this.items.length-1}takeWhile(e){let t=this.firstIdx;for(;t=0&&e(this.items[t]);)t--;const i=t===this.lastIdx?null:this.items.slice(t+1,this.lastIdx+1);return this.lastIdx=t,i}peek(){return this.items[this.firstIdx]}dequeue(){const e=this.items[this.firstIdx];return this.firstIdx++,e}takeCount(e){const t=this.items.slice(this.firstIdx,this.firstIdx+e);return this.firstIdx+=e,t}}},69974:function(e,t,i){"use strict";function n(e,t){if(!e)throw new Error(t?`Assertion failed (${t})`:"Assertion Failed")}i.d(t,{ok:function(){return n}})},40027:function(e,t,i){"use strict";i.d(t,{Aq:function(){return E},CR:function(){return k},J8:function(){return d},PG:function(){return u},Ps:function(){return v},To:function(){return S},Ue:function(){return x},Vg:function(){return b},Vs:function(){return _},_F:function(){return C},eP:function(){return h},jT:function(){return L},ne:function(){return p},pY:function(){return y},rH:function(){return f},vp:function(){return m},zS:function(){return D},zh:function(){return w}});var n=i(60677),o=i(16182),r=i(46718),s=i(4004),a=i(6954),l=function(e,t,i,n){return new(i||(i=Promise))((function(o,r){function s(e){try{l(n.next(e))}catch(e){r(e)}}function a(e){try{l(n.throw(e))}catch(e){r(e)}}function l(e){var t;e.done?o(e.value):(t=e.value,t instanceof i?t:new i((function(e){e(t)}))).then(s,a)}l((n=n.apply(e,t||[])).next())}))},c=function(e){if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var t,i=e[Symbol.asyncIterator];return i?i.call(e):(e="function"==typeof __values?__values(e):e[Symbol.iterator](),t={},n("next"),n("throw"),n("return"),t[Symbol.asyncIterator]=function(){return this},t);function n(i){t[i]=e[i]&&function(t){return new Promise((function(n,o){!function(e,t,i,n){Promise.resolve(n).then((function(t){e({value:t,done:i})}),t)}(n,o,(t=e[i](t)).done,t.value)}))}}};function d(e){return!!e&&"function"==typeof e.then}function u(e){const t=new n.A,i=e(t.token),r=new Promise(((e,n)=>{const r=t.token.onCancellationRequested((()=>{r.dispose(),t.dispose(),n(new o.FU)}));Promise.resolve(i).then((i=>{r.dispose(),t.dispose(),e(i)}),(e=>{r.dispose(),t.dispose(),n(e)}))}));return new class{cancel(){t.cancel()}then(e,t){return r.then(e,t)}catch(e){return this.then(void 0,e)}finally(e){return r.finally(e)}}}function h(e,t,i){return new Promise(((n,o)=>{const r=t.onCancellationRequested((()=>{r.dispose(),n(i)}));e.then(n,o).finally((()=>r.dispose()))}))}class g{constructor(){this.activePromise=null,this.queuedPromise=null,this.queuedPromiseFactory=null}queue(e){if(this.activePromise){if(this.queuedPromiseFactory=e,!this.queuedPromise){const e=()=>{this.queuedPromise=null;const e=this.queue(this.queuedPromiseFactory);return this.queuedPromiseFactory=null,e};this.queuedPromise=new Promise((t=>{this.activePromise.then(e,e).then(t)}))}return new Promise(((e,t)=>{this.queuedPromise.then(e,t)}))}return this.activePromise=e(),new Promise(((e,t)=>{this.activePromise.then((t=>{this.activePromise=null,e(t)}),(e=>{this.activePromise=null,t(e)}))}))}}const p=Symbol("MicrotaskDelay");class m{constructor(e){this.defaultDelay=e,this.deferred=null,this.completionPromise=null,this.doResolve=null,this.doReject=null,this.task=null}trigger(e,t=this.defaultDelay){this.task=e,this.cancelTimeout(),this.completionPromise||(this.completionPromise=new Promise(((e,t)=>{this.doResolve=e,this.doReject=t})).then((()=>{if(this.completionPromise=null,this.doResolve=null,this.task){const e=this.task;return this.task=null,e()}})));const i=()=>{var e;this.deferred=null,null===(e=this.doResolve)||void 0===e||e.call(this,null)};return this.deferred=t===p?(e=>{let t=!0;return queueMicrotask((()=>{t&&(t=!1,e())})),{isTriggered:()=>t,dispose:()=>{t=!1}}})(i):((e,t)=>{let i=!0;const n=setTimeout((()=>{i=!1,t()}),e);return{isTriggered:()=>i,dispose:()=>{clearTimeout(n),i=!1}}})(t,i),this.completionPromise}isTriggered(){var e;return!!(null===(e=this.deferred)||void 0===e?void 0:e.isTriggered())}cancel(){this.cancelTimeout(),this.completionPromise&&(this.doReject&&this.doReject(new o.FU),this.completionPromise=null)}cancelTimeout(){var e;null===(e=this.deferred)||void 0===e||e.dispose(),this.deferred=null}dispose(){this.cancel()}}class f{constructor(e){this.delayer=new m(e),this.throttler=new g}trigger(e,t){return this.delayer.trigger((()=>this.throttler.queue(e)),t)}dispose(){this.delayer.dispose()}}function _(e,t){return t?new Promise(((i,n)=>{const r=setTimeout((()=>{s.dispose(),i()}),e),s=t.onCancellationRequested((()=>{clearTimeout(r),s.dispose(),n(new o.FU)}))})):u((t=>_(e,t)))}function b(e,t=0){const i=setTimeout(e,t);return(0,s.OF)((()=>clearTimeout(i)))}function v(e,t=(e=>!!e),i=null){let n=0;const o=e.length,r=()=>{if(n>=o)return Promise.resolve(i);const s=e[n++];return Promise.resolve(s()).then((e=>t(e)?Promise.resolve(e):r()))};return r()}class C{constructor(e,t){this._token=-1,"function"==typeof e&&"number"==typeof t&&this.setIfNotSet(e,t)}dispose(){this.cancel()}cancel(){-1!==this._token&&(clearTimeout(this._token),this._token=-1)}cancelAndSet(e,t){this.cancel(),this._token=setTimeout((()=>{this._token=-1,e()}),t)}setIfNotSet(e,t){-1===this._token&&(this._token=setTimeout((()=>{this._token=-1,e()}),t))}}class w{constructor(){this._token=-1}dispose(){this.cancel()}cancel(){-1!==this._token&&(clearInterval(this._token),this._token=-1)}cancelAndSet(e,t){this.cancel(),this._token=setInterval((()=>{e()}),t)}}class y{constructor(e,t){this.timeoutToken=-1,this.runner=e,this.timeout=t,this.timeoutHandler=this.onTimeout.bind(this)}dispose(){this.cancel(),this.runner=null}cancel(){this.isScheduled()&&(clearTimeout(this.timeoutToken),this.timeoutToken=-1)}schedule(e=this.timeout){this.cancel(),this.timeoutToken=setTimeout(this.timeoutHandler,e)}get delay(){return this.timeout}set delay(e){this.timeout=e}isScheduled(){return-1!==this.timeoutToken}onTimeout(){this.timeoutToken=-1,this.runner&&this.doRun()}doRun(){this.runner&&this.runner()}}let S;S="function"!=typeof requestIdleCallback||"function"!=typeof cancelIdleCallback?e=>{(0,a.fn)((()=>{if(t)return;const i=Date.now()+15;e(Object.freeze({didTimeout:!0,timeRemaining:()=>Math.max(0,i-Date.now())}))}));let t=!1;return{dispose(){t||(t=!0)}}}:(e,t)=>{const i=requestIdleCallback(e,"number"==typeof t?{timeout:t}:void 0);let n=!1;return{dispose(){n||(n=!0,cancelIdleCallback(i))}}};class x{constructor(e){this._didRun=!1,this._executor=()=>{try{this._value=e()}catch(e){this._error=e}finally{this._didRun=!0}},this._handle=S((()=>this._executor()))}dispose(){this._handle.dispose()}get value(){if(this._didRun||(this._handle.dispose(),this._executor()),this._error)throw this._error;return this._value}get isInitialized(){return this._didRun}}class k{constructor(){this.rejected=!1,this.resolved=!1,this.p=new Promise(((e,t)=>{this.completeCallback=e,this.errorCallback=t}))}get isRejected(){return this.rejected}get isSettled(){return this.rejected||this.resolved}complete(e){return new Promise((t=>{this.completeCallback(e),this.resolved=!0,t()}))}cancel(){new Promise((e=>{this.errorCallback(new o.FU),this.rejected=!0,e()}))}}var L;!function(e){e.settled=function(e){return l(this,void 0,void 0,(function*(){let t;const i=yield Promise.all(e.map((e=>e.then((e=>e),(e=>{t||(t=e)})))));if(void 0!==t)throw t;return i}))},e.withAsyncBody=function(e){return new Promise(((t,i)=>l(this,void 0,void 0,(function*(){try{yield e(t,i)}catch(e){i(e)}}))))}}(L||(L={}));class E{constructor(e){this._state=0,this._results=[],this._error=null,this._onStateChanged=new r.Q5,queueMicrotask((()=>l(this,void 0,void 0,(function*(){const t={emitOne:e=>this.emitOne(e),emitMany:e=>this.emitMany(e),reject:e=>this.reject(e)};try{yield Promise.resolve(e(t)),this.resolve()}catch(e){this.reject(e)}finally{t.emitOne=void 0,t.emitMany=void 0,t.reject=void 0}}))))}static fromArray(e){return new E((t=>{t.emitMany(e)}))}static fromPromise(e){return new E((t=>l(this,void 0,void 0,(function*(){t.emitMany(yield e)}))))}static fromPromises(e){return new E((t=>l(this,void 0,void 0,(function*(){yield Promise.all(e.map((e=>l(this,void 0,void 0,(function*(){return t.emitOne(yield e)})))))}))))}static merge(e){return new E((t=>l(this,void 0,void 0,(function*(){yield Promise.all(e.map((e=>{var i,n;return l(this,void 0,void 0,(function*(){var o,r;try{for(i=c(e);!(n=yield i.next()).done;){const e=n.value;t.emitOne(e)}}catch(e){o={error:e}}finally{try{n&&!n.done&&(r=i.return)&&(yield r.call(i))}finally{if(o)throw o.error}}}))})))}))))}[Symbol.asyncIterator](){let e=0;return{next:()=>l(this,void 0,void 0,(function*(){for(;;){if(2===this._state)throw this._error;if(el(this,void 0,void 0,(function*(){var n,o;try{for(var r,s=c(e);!(r=yield s.next()).done;){const e=r.value;i.emitOne(t(e))}}catch(e){n={error:e}}finally{try{r&&!r.done&&(o=s.return)&&(yield o.call(s))}finally{if(n)throw n.error}}}))))}map(e){return E.map(this,e)}static filter(e,t){return new E((i=>l(this,void 0,void 0,(function*(){var n,o;try{for(var r,s=c(e);!(r=yield s.next()).done;){const e=r.value;t(e)&&i.emitOne(e)}}catch(e){n={error:e}}finally{try{r&&!r.done&&(o=s.return)&&(yield o.call(s))}finally{if(n)throw n.error}}}))))}filter(e){return E.filter(this,e)}static coalesce(e){return E.filter(e,(e=>!!e))}coalesce(){return E.coalesce(this)}static toPromise(e){var t,i,n,o;return l(this,void 0,void 0,(function*(){const r=[];try{for(t=c(e);!(i=yield t.next()).done;){const e=i.value;r.push(e)}}catch(e){n={error:e}}finally{try{i&&!i.done&&(o=t.return)&&(yield o.call(t))}finally{if(n)throw n.error}}return r}))}toPromise(){return E.toPromise(this)}emitOne(e){0===this._state&&(this._results.push(e),this._onStateChanged.fire())}emitMany(e){0===this._state&&(this._results=this._results.concat(e),this._onStateChanged.fire())}resolve(){0===this._state&&(this._state=1,this._onStateChanged.fire())}reject(e){0===this._state&&(this._state=2,this._error=e,this._onStateChanged.fire())}}E.EMPTY=E.fromArray([]);class N extends E{constructor(e,t){super(t),this._source=e}cancel(){this._source.cancel()}}function D(e){const t=new n.A,i=e(t.token);return new N(t,(e=>l(this,void 0,void 0,(function*(){var n,r;const s=t.token.onCancellationRequested((()=>{s.dispose(),t.dispose(),e.reject(new o.FU)}));try{try{for(var a,l=c(i);!(a=yield l.next()).done;){const i=a.value;if(t.token.isCancellationRequested)return;e.emitOne(i)}}catch(e){n={error:e}}finally{try{a&&!a.done&&(r=l.return)&&(yield r.call(l))}finally{if(n)throw n.error}}s.dispose(),t.dispose()}catch(i){s.dispose(),t.dispose(),e.reject(i)}}))))}},75527:function(e,t,i){"use strict";i.d(t,{Ag:function(){return l},Cg:function(){return u},KN:function(){return r},Q$:function(){return d},T4:function(){return c},mP:function(){return s},oq:function(){return a}});const n="undefined"!=typeof Buffer;let o;class r{constructor(e){this.buffer=e,this.byteLength=this.buffer.byteLength}static wrap(e){return n&&!Buffer.isBuffer(e)&&(e=Buffer.from(e.buffer,e.byteOffset,e.byteLength)),new r(e)}toString(){return n?this.buffer.toString():(o||(o=new TextDecoder),o.decode(this.buffer))}}function s(e,t){return e[t+0]<<0>>>0|e[t+1]<<8>>>0}function a(e,t,i){e[i+0]=255&t,t>>>=8,e[i+1]=255&t}function l(e,t){return e[t]*Math.pow(2,24)+e[t+1]*Math.pow(2,16)+e[t+2]*Math.pow(2,8)+e[t+3]}function c(e,t,i){e[i+3]=t,t>>>=8,e[i+2]=t,t>>>=8,e[i+1]=t,t>>>=8,e[i]=t}function d(e,t){return e[t]}function u(e,t,i){e[i]=t}},60677:function(e,t,i){"use strict";i.d(t,{A:function(){return a},T:function(){return r}});var n=i(46718);const o=Object.freeze((function(e,t){const i=setTimeout(e.bind(t),0);return{dispose(){clearTimeout(i)}}}));var r;!function(e){e.isCancellationToken=function(t){return t===e.None||t===e.Cancelled||t instanceof s||!(!t||"object"!=typeof t)&&"boolean"==typeof t.isCancellationRequested&&"function"==typeof t.onCancellationRequested},e.None=Object.freeze({isCancellationRequested:!1,onCancellationRequested:n.ju.None}),e.Cancelled=Object.freeze({isCancellationRequested:!0,onCancellationRequested:o})}(r||(r={}));class s{constructor(){this._isCancelled=!1,this._emitter=null}cancel(){this._isCancelled||(this._isCancelled=!0,this._emitter&&(this._emitter.fire(void 0),this.dispose()))}get isCancellationRequested(){return this._isCancelled}get onCancellationRequested(){return this._isCancelled?o:(this._emitter||(this._emitter=new n.Q5),this._emitter.event)}dispose(){this._emitter&&(this._emitter.dispose(),this._emitter=null)}}class a{constructor(e){this._token=void 0,this._parentListener=void 0,this._parentListener=e&&e.onCancellationRequested(this.cancel,this)}get token(){return this._token||(this._token=new s),this._token}cancel(){this._token?this._token instanceof s&&this._token.cancel():this._token=r.Cancelled}dispose(e=!1){e&&this.cancel(),this._parentListener&&this._parentListener.dispose(),this._token?this._token instanceof s&&this._token.dispose():this._token=r.None}}},4821:function(e,t,i){"use strict";function n(e){return e?e.replace(/\$\((.*?)\)/g,((e,t)=>` ${t} `)).trim():""}i.d(t,{JL:function(){return n},dT:function(){return r},lA:function(){return o}});class o{constructor(e,t,i){this.id=e,this.definition=t,this.description=i,o._allCodicons.push(this)}get classNames(){return"codicon codicon-"+this.id}get classNamesArray(){return["codicon","codicon-"+this.id]}get cssSelector(){return".codicon.codicon-"+this.id}static getAll(){return o._allCodicons}}var r;o._allCodicons=[],o.add=new o("add",{fontCharacter:"\\ea60"}),o.plus=new o("plus",o.add.definition),o.gistNew=new o("gist-new",o.add.definition),o.repoCreate=new o("repo-create",o.add.definition),o.lightbulb=new o("lightbulb",{fontCharacter:"\\ea61"}),o.lightBulb=new o("light-bulb",{fontCharacter:"\\ea61"}),o.repo=new o("repo",{fontCharacter:"\\ea62"}),o.repoDelete=new o("repo-delete",{fontCharacter:"\\ea62"}),o.gistFork=new o("gist-fork",{fontCharacter:"\\ea63"}),o.repoForked=new o("repo-forked",{fontCharacter:"\\ea63"}),o.gitPullRequest=new o("git-pull-request",{fontCharacter:"\\ea64"}),o.gitPullRequestAbandoned=new o("git-pull-request-abandoned",{fontCharacter:"\\ea64"}),o.recordKeys=new o("record-keys",{fontCharacter:"\\ea65"}),o.keyboard=new o("keyboard",{fontCharacter:"\\ea65"}),o.tag=new o("tag",{fontCharacter:"\\ea66"}),o.tagAdd=new o("tag-add",{fontCharacter:"\\ea66"}),o.tagRemove=new o("tag-remove",{fontCharacter:"\\ea66"}),o.person=new o("person",{fontCharacter:"\\ea67"}),o.personFollow=new o("person-follow",{fontCharacter:"\\ea67"}),o.personOutline=new o("person-outline",{fontCharacter:"\\ea67"}),o.personFilled=new o("person-filled",{fontCharacter:"\\ea67"}),o.gitBranch=new o("git-branch",{fontCharacter:"\\ea68"}),o.gitBranchCreate=new o("git-branch-create",{fontCharacter:"\\ea68"}),o.gitBranchDelete=new o("git-branch-delete",{fontCharacter:"\\ea68"}),o.sourceControl=new o("source-control",{fontCharacter:"\\ea68"}),o.mirror=new o("mirror",{fontCharacter:"\\ea69"}),o.mirrorPublic=new o("mirror-public",{fontCharacter:"\\ea69"}),o.star=new o("star",{fontCharacter:"\\ea6a"}),o.starAdd=new o("star-add",{fontCharacter:"\\ea6a"}),o.starDelete=new o("star-delete",{fontCharacter:"\\ea6a"}),o.starEmpty=new o("star-empty",{fontCharacter:"\\ea6a"}),o.comment=new o("comment",{fontCharacter:"\\ea6b"}),o.commentAdd=new o("comment-add",{fontCharacter:"\\ea6b"}),o.alert=new o("alert",{fontCharacter:"\\ea6c"}),o.warning=new o("warning",{fontCharacter:"\\ea6c"}),o.search=new o("search",{fontCharacter:"\\ea6d"}),o.searchSave=new o("search-save",{fontCharacter:"\\ea6d"}),o.logOut=new o("log-out",{fontCharacter:"\\ea6e"}),o.signOut=new o("sign-out",{fontCharacter:"\\ea6e"}),o.logIn=new o("log-in",{fontCharacter:"\\ea6f"}),o.signIn=new o("sign-in",{fontCharacter:"\\ea6f"}),o.eye=new o("eye",{fontCharacter:"\\ea70"}),o.eyeUnwatch=new o("eye-unwatch",{fontCharacter:"\\ea70"}),o.eyeWatch=new o("eye-watch",{fontCharacter:"\\ea70"}),o.circleFilled=new o("circle-filled",{fontCharacter:"\\ea71"}),o.primitiveDot=new o("primitive-dot",{fontCharacter:"\\ea71"}),o.closeDirty=new o("close-dirty",{fontCharacter:"\\ea71"}),o.debugBreakpoint=new o("debug-breakpoint",{fontCharacter:"\\ea71"}),o.debugBreakpointDisabled=new o("debug-breakpoint-disabled",{fontCharacter:"\\ea71"}),o.debugHint=new o("debug-hint",{fontCharacter:"\\ea71"}),o.primitiveSquare=new o("primitive-square",{fontCharacter:"\\ea72"}),o.edit=new o("edit",{fontCharacter:"\\ea73"}),o.pencil=new o("pencil",{fontCharacter:"\\ea73"}),o.info=new o("info",{fontCharacter:"\\ea74"}),o.issueOpened=new o("issue-opened",{fontCharacter:"\\ea74"}),o.gistPrivate=new o("gist-private",{fontCharacter:"\\ea75"}),o.gitForkPrivate=new o("git-fork-private",{fontCharacter:"\\ea75"}),o.lock=new o("lock",{fontCharacter:"\\ea75"}),o.mirrorPrivate=new o("mirror-private",{fontCharacter:"\\ea75"}),o.close=new o("close",{fontCharacter:"\\ea76"}),o.removeClose=new o("remove-close",{fontCharacter:"\\ea76"}),o.x=new o("x",{fontCharacter:"\\ea76"}),o.repoSync=new o("repo-sync",{fontCharacter:"\\ea77"}),o.sync=new o("sync",{fontCharacter:"\\ea77"}),o.clone=new o("clone",{fontCharacter:"\\ea78"}),o.desktopDownload=new o("desktop-download",{fontCharacter:"\\ea78"}),o.beaker=new o("beaker",{fontCharacter:"\\ea79"}),o.microscope=new o("microscope",{fontCharacter:"\\ea79"}),o.vm=new o("vm",{fontCharacter:"\\ea7a"}),o.deviceDesktop=new o("device-desktop",{fontCharacter:"\\ea7a"}),o.file=new o("file",{fontCharacter:"\\ea7b"}),o.fileText=new o("file-text",{fontCharacter:"\\ea7b"}),o.more=new o("more",{fontCharacter:"\\ea7c"}),o.ellipsis=new o("ellipsis",{fontCharacter:"\\ea7c"}),o.kebabHorizontal=new o("kebab-horizontal",{fontCharacter:"\\ea7c"}),o.mailReply=new o("mail-reply",{fontCharacter:"\\ea7d"}),o.reply=new o("reply",{fontCharacter:"\\ea7d"}),o.organization=new o("organization",{fontCharacter:"\\ea7e"}),o.organizationFilled=new o("organization-filled",{fontCharacter:"\\ea7e"}),o.organizationOutline=new o("organization-outline",{fontCharacter:"\\ea7e"}),o.newFile=new o("new-file",{fontCharacter:"\\ea7f"}),o.fileAdd=new o("file-add",{fontCharacter:"\\ea7f"}),o.newFolder=new o("new-folder",{fontCharacter:"\\ea80"}),o.fileDirectoryCreate=new o("file-directory-create",{fontCharacter:"\\ea80"}),o.trash=new o("trash",{fontCharacter:"\\ea81"}),o.trashcan=new o("trashcan",{fontCharacter:"\\ea81"}),o.history=new o("history",{fontCharacter:"\\ea82"}),o.clock=new o("clock",{fontCharacter:"\\ea82"}),o.folder=new o("folder",{fontCharacter:"\\ea83"}),o.fileDirectory=new o("file-directory",{fontCharacter:"\\ea83"}),o.symbolFolder=new o("symbol-folder",{fontCharacter:"\\ea83"}),o.logoGithub=new o("logo-github",{fontCharacter:"\\ea84"}),o.markGithub=new o("mark-github",{fontCharacter:"\\ea84"}),o.github=new o("github",{fontCharacter:"\\ea84"}),o.terminal=new o("terminal",{fontCharacter:"\\ea85"}),o.console=new o("console",{fontCharacter:"\\ea85"}),o.repl=new o("repl",{fontCharacter:"\\ea85"}),o.zap=new o("zap",{fontCharacter:"\\ea86"}),o.symbolEvent=new o("symbol-event",{fontCharacter:"\\ea86"}),o.error=new o("error",{fontCharacter:"\\ea87"}),o.stop=new o("stop",{fontCharacter:"\\ea87"}),o.variable=new o("variable",{fontCharacter:"\\ea88"}),o.symbolVariable=new o("symbol-variable",{fontCharacter:"\\ea88"}),o.array=new o("array",{fontCharacter:"\\ea8a"}),o.symbolArray=new o("symbol-array",{fontCharacter:"\\ea8a"}),o.symbolModule=new o("symbol-module",{fontCharacter:"\\ea8b"}),o.symbolPackage=new o("symbol-package",{fontCharacter:"\\ea8b"}),o.symbolNamespace=new o("symbol-namespace",{fontCharacter:"\\ea8b"}),o.symbolObject=new o("symbol-object",{fontCharacter:"\\ea8b"}),o.symbolMethod=new o("symbol-method",{fontCharacter:"\\ea8c"}),o.symbolFunction=new o("symbol-function",{fontCharacter:"\\ea8c"}),o.symbolConstructor=new o("symbol-constructor",{fontCharacter:"\\ea8c"}),o.symbolBoolean=new o("symbol-boolean",{fontCharacter:"\\ea8f"}),o.symbolNull=new o("symbol-null",{fontCharacter:"\\ea8f"}),o.symbolNumeric=new o("symbol-numeric",{fontCharacter:"\\ea90"}),o.symbolNumber=new o("symbol-number",{fontCharacter:"\\ea90"}),o.symbolStructure=new o("symbol-structure",{fontCharacter:"\\ea91"}),o.symbolStruct=new o("symbol-struct",{fontCharacter:"\\ea91"}),o.symbolParameter=new o("symbol-parameter",{fontCharacter:"\\ea92"}),o.symbolTypeParameter=new o("symbol-type-parameter",{fontCharacter:"\\ea92"}),o.symbolKey=new o("symbol-key",{fontCharacter:"\\ea93"}),o.symbolText=new o("symbol-text",{fontCharacter:"\\ea93"}),o.symbolReference=new o("symbol-reference",{fontCharacter:"\\ea94"}),o.goToFile=new o("go-to-file",{fontCharacter:"\\ea94"}),o.symbolEnum=new o("symbol-enum",{fontCharacter:"\\ea95"}),o.symbolValue=new o("symbol-value",{fontCharacter:"\\ea95"}),o.symbolRuler=new o("symbol-ruler",{fontCharacter:"\\ea96"}),o.symbolUnit=new o("symbol-unit",{fontCharacter:"\\ea96"}),o.activateBreakpoints=new o("activate-breakpoints",{fontCharacter:"\\ea97"}),o.archive=new o("archive",{fontCharacter:"\\ea98"}),o.arrowBoth=new o("arrow-both",{fontCharacter:"\\ea99"}),o.arrowDown=new o("arrow-down",{fontCharacter:"\\ea9a"}),o.arrowLeft=new o("arrow-left",{fontCharacter:"\\ea9b"}),o.arrowRight=new o("arrow-right",{fontCharacter:"\\ea9c"}),o.arrowSmallDown=new o("arrow-small-down",{fontCharacter:"\\ea9d"}),o.arrowSmallLeft=new o("arrow-small-left",{fontCharacter:"\\ea9e"}),o.arrowSmallRight=new o("arrow-small-right",{fontCharacter:"\\ea9f"}),o.arrowSmallUp=new o("arrow-small-up",{fontCharacter:"\\eaa0"}),o.arrowUp=new o("arrow-up",{fontCharacter:"\\eaa1"}),o.bell=new o("bell",{fontCharacter:"\\eaa2"}),o.bold=new o("bold",{fontCharacter:"\\eaa3"}),o.book=new o("book",{fontCharacter:"\\eaa4"}),o.bookmark=new o("bookmark",{fontCharacter:"\\eaa5"}),o.debugBreakpointConditionalUnverified=new o("debug-breakpoint-conditional-unverified",{fontCharacter:"\\eaa6"}),o.debugBreakpointConditional=new o("debug-breakpoint-conditional",{fontCharacter:"\\eaa7"}),o.debugBreakpointConditionalDisabled=new o("debug-breakpoint-conditional-disabled",{fontCharacter:"\\eaa7"}),o.debugBreakpointDataUnverified=new o("debug-breakpoint-data-unverified",{fontCharacter:"\\eaa8"}),o.debugBreakpointData=new o("debug-breakpoint-data",{fontCharacter:"\\eaa9"}),o.debugBreakpointDataDisabled=new o("debug-breakpoint-data-disabled",{fontCharacter:"\\eaa9"}),o.debugBreakpointLogUnverified=new o("debug-breakpoint-log-unverified",{fontCharacter:"\\eaaa"}),o.debugBreakpointLog=new o("debug-breakpoint-log",{fontCharacter:"\\eaab"}),o.debugBreakpointLogDisabled=new o("debug-breakpoint-log-disabled",{fontCharacter:"\\eaab"}),o.briefcase=new o("briefcase",{fontCharacter:"\\eaac"}),o.broadcast=new o("broadcast",{fontCharacter:"\\eaad"}),o.browser=new o("browser",{fontCharacter:"\\eaae"}),o.bug=new o("bug",{fontCharacter:"\\eaaf"}),o.calendar=new o("calendar",{fontCharacter:"\\eab0"}),o.caseSensitive=new o("case-sensitive",{fontCharacter:"\\eab1"}),o.check=new o("check",{fontCharacter:"\\eab2"}),o.checklist=new o("checklist",{fontCharacter:"\\eab3"}),o.chevronDown=new o("chevron-down",{fontCharacter:"\\eab4"}),o.dropDownButton=new o("drop-down-button",o.chevronDown.definition),o.chevronLeft=new o("chevron-left",{fontCharacter:"\\eab5"}),o.chevronRight=new o("chevron-right",{fontCharacter:"\\eab6"}),o.chevronUp=new o("chevron-up",{fontCharacter:"\\eab7"}),o.chromeClose=new o("chrome-close",{fontCharacter:"\\eab8"}),o.chromeMaximize=new o("chrome-maximize",{fontCharacter:"\\eab9"}),o.chromeMinimize=new o("chrome-minimize",{fontCharacter:"\\eaba"}),o.chromeRestore=new o("chrome-restore",{fontCharacter:"\\eabb"}),o.circleOutline=new o("circle-outline",{fontCharacter:"\\eabc"}),o.debugBreakpointUnverified=new o("debug-breakpoint-unverified",{fontCharacter:"\\eabc"}),o.circleSlash=new o("circle-slash",{fontCharacter:"\\eabd"}),o.circuitBoard=new o("circuit-board",{fontCharacter:"\\eabe"}),o.clearAll=new o("clear-all",{fontCharacter:"\\eabf"}),o.clippy=new o("clippy",{fontCharacter:"\\eac0"}),o.closeAll=new o("close-all",{fontCharacter:"\\eac1"}),o.cloudDownload=new o("cloud-download",{fontCharacter:"\\eac2"}),o.cloudUpload=new o("cloud-upload",{fontCharacter:"\\eac3"}),o.code=new o("code",{fontCharacter:"\\eac4"}),o.collapseAll=new o("collapse-all",{fontCharacter:"\\eac5"}),o.colorMode=new o("color-mode",{fontCharacter:"\\eac6"}),o.commentDiscussion=new o("comment-discussion",{fontCharacter:"\\eac7"}),o.compareChanges=new o("compare-changes",{fontCharacter:"\\eafd"}),o.creditCard=new o("credit-card",{fontCharacter:"\\eac9"}),o.dash=new o("dash",{fontCharacter:"\\eacc"}),o.dashboard=new o("dashboard",{fontCharacter:"\\eacd"}),o.database=new o("database",{fontCharacter:"\\eace"}),o.debugContinue=new o("debug-continue",{fontCharacter:"\\eacf"}),o.debugDisconnect=new o("debug-disconnect",{fontCharacter:"\\ead0"}),o.debugPause=new o("debug-pause",{fontCharacter:"\\ead1"}),o.debugRestart=new o("debug-restart",{fontCharacter:"\\ead2"}),o.debugStart=new o("debug-start",{fontCharacter:"\\ead3"}),o.debugStepInto=new o("debug-step-into",{fontCharacter:"\\ead4"}),o.debugStepOut=new o("debug-step-out",{fontCharacter:"\\ead5"}),o.debugStepOver=new o("debug-step-over",{fontCharacter:"\\ead6"}),o.debugStop=new o("debug-stop",{fontCharacter:"\\ead7"}),o.debug=new o("debug",{fontCharacter:"\\ead8"}),o.deviceCameraVideo=new o("device-camera-video",{fontCharacter:"\\ead9"}),o.deviceCamera=new o("device-camera",{fontCharacter:"\\eada"}),o.deviceMobile=new o("device-mobile",{fontCharacter:"\\eadb"}),o.diffAdded=new o("diff-added",{fontCharacter:"\\eadc"}),o.diffIgnored=new o("diff-ignored",{fontCharacter:"\\eadd"}),o.diffModified=new o("diff-modified",{fontCharacter:"\\eade"}),o.diffRemoved=new o("diff-removed",{fontCharacter:"\\eadf"}),o.diffRenamed=new o("diff-renamed",{fontCharacter:"\\eae0"}),o.diff=new o("diff",{fontCharacter:"\\eae1"}),o.discard=new o("discard",{fontCharacter:"\\eae2"}),o.editorLayout=new o("editor-layout",{fontCharacter:"\\eae3"}),o.emptyWindow=new o("empty-window",{fontCharacter:"\\eae4"}),o.exclude=new o("exclude",{fontCharacter:"\\eae5"}),o.extensions=new o("extensions",{fontCharacter:"\\eae6"}),o.eyeClosed=new o("eye-closed",{fontCharacter:"\\eae7"}),o.fileBinary=new o("file-binary",{fontCharacter:"\\eae8"}),o.fileCode=new o("file-code",{fontCharacter:"\\eae9"}),o.fileMedia=new o("file-media",{fontCharacter:"\\eaea"}),o.filePdf=new o("file-pdf",{fontCharacter:"\\eaeb"}),o.fileSubmodule=new o("file-submodule",{fontCharacter:"\\eaec"}),o.fileSymlinkDirectory=new o("file-symlink-directory",{fontCharacter:"\\eaed"}),o.fileSymlinkFile=new o("file-symlink-file",{fontCharacter:"\\eaee"}),o.fileZip=new o("file-zip",{fontCharacter:"\\eaef"}),o.files=new o("files",{fontCharacter:"\\eaf0"}),o.filter=new o("filter",{fontCharacter:"\\eaf1"}),o.flame=new o("flame",{fontCharacter:"\\eaf2"}),o.foldDown=new o("fold-down",{fontCharacter:"\\eaf3"}),o.foldUp=new o("fold-up",{fontCharacter:"\\eaf4"}),o.fold=new o("fold",{fontCharacter:"\\eaf5"}),o.folderActive=new o("folder-active",{fontCharacter:"\\eaf6"}),o.folderOpened=new o("folder-opened",{fontCharacter:"\\eaf7"}),o.gear=new o("gear",{fontCharacter:"\\eaf8"}),o.gift=new o("gift",{fontCharacter:"\\eaf9"}),o.gistSecret=new o("gist-secret",{fontCharacter:"\\eafa"}),o.gist=new o("gist",{fontCharacter:"\\eafb"}),o.gitCommit=new o("git-commit",{fontCharacter:"\\eafc"}),o.gitCompare=new o("git-compare",{fontCharacter:"\\eafd"}),o.gitMerge=new o("git-merge",{fontCharacter:"\\eafe"}),o.githubAction=new o("github-action",{fontCharacter:"\\eaff"}),o.githubAlt=new o("github-alt",{fontCharacter:"\\eb00"}),o.globe=new o("globe",{fontCharacter:"\\eb01"}),o.grabber=new o("grabber",{fontCharacter:"\\eb02"}),o.graph=new o("graph",{fontCharacter:"\\eb03"}),o.gripper=new o("gripper",{fontCharacter:"\\eb04"}),o.heart=new o("heart",{fontCharacter:"\\eb05"}),o.home=new o("home",{fontCharacter:"\\eb06"}),o.horizontalRule=new o("horizontal-rule",{fontCharacter:"\\eb07"}),o.hubot=new o("hubot",{fontCharacter:"\\eb08"}),o.inbox=new o("inbox",{fontCharacter:"\\eb09"}),o.issueClosed=new o("issue-closed",{fontCharacter:"\\eba4"}),o.issueReopened=new o("issue-reopened",{fontCharacter:"\\eb0b"}),o.issues=new o("issues",{fontCharacter:"\\eb0c"}),o.italic=new o("italic",{fontCharacter:"\\eb0d"}),o.jersey=new o("jersey",{fontCharacter:"\\eb0e"}),o.json=new o("json",{fontCharacter:"\\eb0f"}),o.kebabVertical=new o("kebab-vertical",{fontCharacter:"\\eb10"}),o.key=new o("key",{fontCharacter:"\\eb11"}),o.law=new o("law",{fontCharacter:"\\eb12"}),o.lightbulbAutofix=new o("lightbulb-autofix",{fontCharacter:"\\eb13"}),o.linkExternal=new o("link-external",{fontCharacter:"\\eb14"}),o.link=new o("link",{fontCharacter:"\\eb15"}),o.listOrdered=new o("list-ordered",{fontCharacter:"\\eb16"}),o.listUnordered=new o("list-unordered",{fontCharacter:"\\eb17"}),o.liveShare=new o("live-share",{fontCharacter:"\\eb18"}),o.loading=new o("loading",{fontCharacter:"\\eb19"}),o.location=new o("location",{fontCharacter:"\\eb1a"}),o.mailRead=new o("mail-read",{fontCharacter:"\\eb1b"}),o.mail=new o("mail",{fontCharacter:"\\eb1c"}),o.markdown=new o("markdown",{fontCharacter:"\\eb1d"}),o.megaphone=new o("megaphone",{fontCharacter:"\\eb1e"}),o.mention=new o("mention",{fontCharacter:"\\eb1f"}),o.milestone=new o("milestone",{fontCharacter:"\\eb20"}),o.mortarBoard=new o("mortar-board",{fontCharacter:"\\eb21"}),o.move=new o("move",{fontCharacter:"\\eb22"}),o.multipleWindows=new o("multiple-windows",{fontCharacter:"\\eb23"}),o.mute=new o("mute",{fontCharacter:"\\eb24"}),o.noNewline=new o("no-newline",{fontCharacter:"\\eb25"}),o.note=new o("note",{fontCharacter:"\\eb26"}),o.octoface=new o("octoface",{fontCharacter:"\\eb27"}),o.openPreview=new o("open-preview",{fontCharacter:"\\eb28"}),o.package_=new o("package",{fontCharacter:"\\eb29"}),o.paintcan=new o("paintcan",{fontCharacter:"\\eb2a"}),o.pin=new o("pin",{fontCharacter:"\\eb2b"}),o.play=new o("play",{fontCharacter:"\\eb2c"}),o.run=new o("run",{fontCharacter:"\\eb2c"}),o.plug=new o("plug",{fontCharacter:"\\eb2d"}),o.preserveCase=new o("preserve-case",{fontCharacter:"\\eb2e"}),o.preview=new o("preview",{fontCharacter:"\\eb2f"}),o.project=new o("project",{fontCharacter:"\\eb30"}),o.pulse=new o("pulse",{fontCharacter:"\\eb31"}),o.question=new o("question",{fontCharacter:"\\eb32"}),o.quote=new o("quote",{fontCharacter:"\\eb33"}),o.radioTower=new o("radio-tower",{fontCharacter:"\\eb34"}),o.reactions=new o("reactions",{fontCharacter:"\\eb35"}),o.references=new o("references",{fontCharacter:"\\eb36"}),o.refresh=new o("refresh",{fontCharacter:"\\eb37"}),o.regex=new o("regex",{fontCharacter:"\\eb38"}),o.remoteExplorer=new o("remote-explorer",{fontCharacter:"\\eb39"}),o.remote=new o("remote",{fontCharacter:"\\eb3a"}),o.remove=new o("remove",{fontCharacter:"\\eb3b"}),o.replaceAll=new o("replace-all",{fontCharacter:"\\eb3c"}),o.replace=new o("replace",{fontCharacter:"\\eb3d"}),o.repoClone=new o("repo-clone",{fontCharacter:"\\eb3e"}),o.repoForcePush=new o("repo-force-push",{fontCharacter:"\\eb3f"}),o.repoPull=new o("repo-pull",{fontCharacter:"\\eb40"}),o.repoPush=new o("repo-push",{fontCharacter:"\\eb41"}),o.report=new o("report",{fontCharacter:"\\eb42"}),o.requestChanges=new o("request-changes",{fontCharacter:"\\eb43"}),o.rocket=new o("rocket",{fontCharacter:"\\eb44"}),o.rootFolderOpened=new o("root-folder-opened",{fontCharacter:"\\eb45"}),o.rootFolder=new o("root-folder",{fontCharacter:"\\eb46"}),o.rss=new o("rss",{fontCharacter:"\\eb47"}),o.ruby=new o("ruby",{fontCharacter:"\\eb48"}),o.saveAll=new o("save-all",{fontCharacter:"\\eb49"}),o.saveAs=new o("save-as",{fontCharacter:"\\eb4a"}),o.save=new o("save",{fontCharacter:"\\eb4b"}),o.screenFull=new o("screen-full",{fontCharacter:"\\eb4c"}),o.screenNormal=new o("screen-normal",{fontCharacter:"\\eb4d"}),o.searchStop=new o("search-stop",{fontCharacter:"\\eb4e"}),o.server=new o("server",{fontCharacter:"\\eb50"}),o.settingsGear=new o("settings-gear",{fontCharacter:"\\eb51"}),o.settings=new o("settings",{fontCharacter:"\\eb52"}),o.shield=new o("shield",{fontCharacter:"\\eb53"}),o.smiley=new o("smiley",{fontCharacter:"\\eb54"}),o.sortPrecedence=new o("sort-precedence",{fontCharacter:"\\eb55"}),o.splitHorizontal=new o("split-horizontal",{fontCharacter:"\\eb56"}),o.splitVertical=new o("split-vertical",{fontCharacter:"\\eb57"}),o.squirrel=new o("squirrel",{fontCharacter:"\\eb58"}),o.starFull=new o("star-full",{fontCharacter:"\\eb59"}),o.starHalf=new o("star-half",{fontCharacter:"\\eb5a"}),o.symbolClass=new o("symbol-class",{fontCharacter:"\\eb5b"}),o.symbolColor=new o("symbol-color",{fontCharacter:"\\eb5c"}),o.symbolCustomColor=new o("symbol-customcolor",{fontCharacter:"\\eb5c"}),o.symbolConstant=new o("symbol-constant",{fontCharacter:"\\eb5d"}),o.symbolEnumMember=new o("symbol-enum-member",{fontCharacter:"\\eb5e"}),o.symbolField=new o("symbol-field",{fontCharacter:"\\eb5f"}),o.symbolFile=new o("symbol-file",{fontCharacter:"\\eb60"}),o.symbolInterface=new o("symbol-interface",{fontCharacter:"\\eb61"}),o.symbolKeyword=new o("symbol-keyword",{fontCharacter:"\\eb62"}),o.symbolMisc=new o("symbol-misc",{fontCharacter:"\\eb63"}),o.symbolOperator=new o("symbol-operator",{fontCharacter:"\\eb64"}),o.symbolProperty=new o("symbol-property",{fontCharacter:"\\eb65"}),o.wrench=new o("wrench",{fontCharacter:"\\eb65"}),o.wrenchSubaction=new o("wrench-subaction",{fontCharacter:"\\eb65"}),o.symbolSnippet=new o("symbol-snippet",{fontCharacter:"\\eb66"}),o.tasklist=new o("tasklist",{fontCharacter:"\\eb67"}),o.telescope=new o("telescope",{fontCharacter:"\\eb68"}),o.textSize=new o("text-size",{fontCharacter:"\\eb69"}),o.threeBars=new o("three-bars",{fontCharacter:"\\eb6a"}),o.thumbsdown=new o("thumbsdown",{fontCharacter:"\\eb6b"}),o.thumbsup=new o("thumbsup",{fontCharacter:"\\eb6c"}),o.tools=new o("tools",{fontCharacter:"\\eb6d"}),o.triangleDown=new o("triangle-down",{fontCharacter:"\\eb6e"}),o.triangleLeft=new o("triangle-left",{fontCharacter:"\\eb6f"}),o.triangleRight=new o("triangle-right",{fontCharacter:"\\eb70"}),o.triangleUp=new o("triangle-up",{fontCharacter:"\\eb71"}),o.twitter=new o("twitter",{fontCharacter:"\\eb72"}),o.unfold=new o("unfold",{fontCharacter:"\\eb73"}),o.unlock=new o("unlock",{fontCharacter:"\\eb74"}),o.unmute=new o("unmute",{fontCharacter:"\\eb75"}),o.unverified=new o("unverified",{fontCharacter:"\\eb76"}),o.verified=new o("verified",{fontCharacter:"\\eb77"}),o.versions=new o("versions",{fontCharacter:"\\eb78"}),o.vmActive=new o("vm-active",{fontCharacter:"\\eb79"}),o.vmOutline=new o("vm-outline",{fontCharacter:"\\eb7a"}),o.vmRunning=new o("vm-running",{fontCharacter:"\\eb7b"}),o.watch=new o("watch",{fontCharacter:"\\eb7c"}),o.whitespace=new o("whitespace",{fontCharacter:"\\eb7d"}),o.wholeWord=new o("whole-word",{fontCharacter:"\\eb7e"}),o.window=new o("window",{fontCharacter:"\\eb7f"}),o.wordWrap=new o("word-wrap",{fontCharacter:"\\eb80"}),o.zoomIn=new o("zoom-in",{fontCharacter:"\\eb81"}),o.zoomOut=new o("zoom-out",{fontCharacter:"\\eb82"}),o.listFilter=new o("list-filter",{fontCharacter:"\\eb83"}),o.listFlat=new o("list-flat",{fontCharacter:"\\eb84"}),o.listSelection=new o("list-selection",{fontCharacter:"\\eb85"}),o.selection=new o("selection",{fontCharacter:"\\eb85"}),o.listTree=new o("list-tree",{fontCharacter:"\\eb86"}),o.debugBreakpointFunctionUnverified=new o("debug-breakpoint-function-unverified",{fontCharacter:"\\eb87"}),o.debugBreakpointFunction=new o("debug-breakpoint-function",{fontCharacter:"\\eb88"}),o.debugBreakpointFunctionDisabled=new o("debug-breakpoint-function-disabled",{fontCharacter:"\\eb88"}),o.debugStackframeActive=new o("debug-stackframe-active",{fontCharacter:"\\eb89"}),o.debugStackframeDot=new o("debug-stackframe-dot",{fontCharacter:"\\eb8a"}),o.debugStackframe=new o("debug-stackframe",{fontCharacter:"\\eb8b"}),o.debugStackframeFocused=new o("debug-stackframe-focused",{fontCharacter:"\\eb8b"}),o.debugBreakpointUnsupported=new o("debug-breakpoint-unsupported",{fontCharacter:"\\eb8c"}),o.symbolString=new o("symbol-string",{fontCharacter:"\\eb8d"}),o.debugReverseContinue=new o("debug-reverse-continue",{fontCharacter:"\\eb8e"}),o.debugStepBack=new o("debug-step-back",{fontCharacter:"\\eb8f"}),o.debugRestartFrame=new o("debug-restart-frame",{fontCharacter:"\\eb90"}),o.callIncoming=new o("call-incoming",{fontCharacter:"\\eb92"}),o.callOutgoing=new o("call-outgoing",{fontCharacter:"\\eb93"}),o.menu=new o("menu",{fontCharacter:"\\eb94"}),o.expandAll=new o("expand-all",{fontCharacter:"\\eb95"}),o.feedback=new o("feedback",{fontCharacter:"\\eb96"}),o.groupByRefType=new o("group-by-ref-type",{fontCharacter:"\\eb97"}),o.ungroupByRefType=new o("ungroup-by-ref-type",{fontCharacter:"\\eb98"}),o.account=new o("account",{fontCharacter:"\\eb99"}),o.bellDot=new o("bell-dot",{fontCharacter:"\\eb9a"}),o.debugConsole=new o("debug-console",{fontCharacter:"\\eb9b"}),o.library=new o("library",{fontCharacter:"\\eb9c"}),o.output=new o("output",{fontCharacter:"\\eb9d"}),o.runAll=new o("run-all",{fontCharacter:"\\eb9e"}),o.syncIgnored=new o("sync-ignored",{fontCharacter:"\\eb9f"}),o.pinned=new o("pinned",{fontCharacter:"\\eba0"}),o.githubInverted=new o("github-inverted",{fontCharacter:"\\eba1"}),o.debugAlt=new o("debug-alt",{fontCharacter:"\\eb91"}),o.serverProcess=new o("server-process",{fontCharacter:"\\eba2"}),o.serverEnvironment=new o("server-environment",{fontCharacter:"\\eba3"}),o.pass=new o("pass",{fontCharacter:"\\eba4"}),o.stopCircle=new o("stop-circle",{fontCharacter:"\\eba5"}),o.playCircle=new o("play-circle",{fontCharacter:"\\eba6"}),o.record=new o("record",{fontCharacter:"\\eba7"}),o.debugAltSmall=new o("debug-alt-small",{fontCharacter:"\\eba8"}),o.vmConnect=new o("vm-connect",{fontCharacter:"\\eba9"}),o.cloud=new o("cloud",{fontCharacter:"\\ebaa"}),o.merge=new o("merge",{fontCharacter:"\\ebab"}),o.exportIcon=new o("export",{fontCharacter:"\\ebac"}),o.graphLeft=new o("graph-left",{fontCharacter:"\\ebad"}),o.magnet=new o("magnet",{fontCharacter:"\\ebae"}),o.notebook=new o("notebook",{fontCharacter:"\\ebaf"}),o.redo=new o("redo",{fontCharacter:"\\ebb0"}),o.checkAll=new o("check-all",{fontCharacter:"\\ebb1"}),o.pinnedDirty=new o("pinned-dirty",{fontCharacter:"\\ebb2"}),o.passFilled=new o("pass-filled",{fontCharacter:"\\ebb3"}),o.circleLargeFilled=new o("circle-large-filled",{fontCharacter:"\\ebb4"}),o.circleLargeOutline=new o("circle-large-outline",{fontCharacter:"\\ebb5"}),o.combine=new o("combine",{fontCharacter:"\\ebb6"}),o.gather=new o("gather",{fontCharacter:"\\ebb6"}),o.table=new o("table",{fontCharacter:"\\ebb7"}),o.variableGroup=new o("variable-group",{fontCharacter:"\\ebb8"}),o.typeHierarchy=new o("type-hierarchy",{fontCharacter:"\\ebb9"}),o.typeHierarchySub=new o("type-hierarchy-sub",{fontCharacter:"\\ebba"}),o.typeHierarchySuper=new o("type-hierarchy-super",{fontCharacter:"\\ebbb"}),o.gitPullRequestCreate=new o("git-pull-request-create",{fontCharacter:"\\ebbc"}),o.runAbove=new o("run-above",{fontCharacter:"\\ebbd"}),o.runBelow=new o("run-below",{fontCharacter:"\\ebbe"}),o.notebookTemplate=new o("notebook-template",{fontCharacter:"\\ebbf"}),o.debugRerun=new o("debug-rerun",{fontCharacter:"\\ebc0"}),o.workspaceTrusted=new o("workspace-trusted",{fontCharacter:"\\ebc1"}),o.workspaceUntrusted=new o("workspace-untrusted",{fontCharacter:"\\ebc2"}),o.workspaceUnspecified=new o("workspace-unspecified",{fontCharacter:"\\ebc3"}),o.terminalCmd=new o("terminal-cmd",{fontCharacter:"\\ebc4"}),o.terminalDebian=new o("terminal-debian",{fontCharacter:"\\ebc5"}),o.terminalLinux=new o("terminal-linux",{fontCharacter:"\\ebc6"}),o.terminalPowershell=new o("terminal-powershell",{fontCharacter:"\\ebc7"}),o.terminalTmux=new o("terminal-tmux",{fontCharacter:"\\ebc8"}),o.terminalUbuntu=new o("terminal-ubuntu",{fontCharacter:"\\ebc9"}),o.terminalBash=new o("terminal-bash",{fontCharacter:"\\ebca"}),o.arrowSwap=new o("arrow-swap",{fontCharacter:"\\ebcb"}),o.copy=new o("copy",{fontCharacter:"\\ebcc"}),o.personAdd=new o("person-add",{fontCharacter:"\\ebcd"}),o.filterFilled=new o("filter-filled",{fontCharacter:"\\ebce"}),o.wand=new o("wand",{fontCharacter:"\\ebcf"}),o.debugLineByLine=new o("debug-line-by-line",{fontCharacter:"\\ebd0"}),o.inspect=new o("inspect",{fontCharacter:"\\ebd1"}),o.layers=new o("layers",{fontCharacter:"\\ebd2"}),o.layersDot=new o("layers-dot",{fontCharacter:"\\ebd3"}),o.layersActive=new o("layers-active",{fontCharacter:"\\ebd4"}),o.compass=new o("compass",{fontCharacter:"\\ebd5"}),o.compassDot=new o("compass-dot",{fontCharacter:"\\ebd6"}),o.compassActive=new o("compass-active",{fontCharacter:"\\ebd7"}),o.azure=new o("azure",{fontCharacter:"\\ebd8"}),o.issueDraft=new o("issue-draft",{fontCharacter:"\\ebd9"}),o.gitPullRequestClosed=new o("git-pull-request-closed",{fontCharacter:"\\ebda"}),o.gitPullRequestDraft=new o("git-pull-request-draft",{fontCharacter:"\\ebdb"}),o.debugAll=new o("debug-all",{fontCharacter:"\\ebdc"}),o.debugCoverage=new o("debug-coverage",{fontCharacter:"\\ebdd"}),o.runErrors=new o("run-errors",{fontCharacter:"\\ebde"}),o.folderLibrary=new o("folder-library",{fontCharacter:"\\ebdf"}),o.debugContinueSmall=new o("debug-continue-small",{fontCharacter:"\\ebe0"}),o.beakerStop=new o("beaker-stop",{fontCharacter:"\\ebe1"}),o.graphLine=new o("graph-line",{fontCharacter:"\\ebe2"}),o.graphScatter=new o("graph-scatter",{fontCharacter:"\\ebe3"}),o.pieChart=new o("pie-chart",{fontCharacter:"\\ebe4"}),o.bracket=new o("bracket",o.json.definition),o.bracketDot=new o("bracket-dot",{fontCharacter:"\\ebe5"}),o.bracketError=new o("bracket-error",{fontCharacter:"\\ebe6"}),o.lockSmall=new o("lock-small",{fontCharacter:"\\ebe7"}),o.azureDevops=new o("azure-devops",{fontCharacter:"\\ebe8"}),o.verifiedFilled=new o("verified-filled",{fontCharacter:"\\ebe9"}),o.newLine=new o("newline",{fontCharacter:"\\ebea"}),o.layout=new o("layout",{fontCharacter:"\\ebeb"}),o.layoutActivitybarLeft=new o("layout-activitybar-left",{fontCharacter:"\\ebec"}),o.layoutActivitybarRight=new o("layout-activitybar-right",{fontCharacter:"\\ebed"}),o.layoutPanelLeft=new o("layout-panel-left",{fontCharacter:"\\ebee"}),o.layoutPanelCenter=new o("layout-panel-center",{fontCharacter:"\\ebef"}),o.layoutPanelJustify=new o("layout-panel-justify",{fontCharacter:"\\ebf0"}),o.layoutPanelRight=new o("layout-panel-right",{fontCharacter:"\\ebf1"}),o.layoutPanel=new o("layout-panel",{fontCharacter:"\\ebf2"}),o.layoutSidebarLeft=new o("layout-sidebar-left",{fontCharacter:"\\ebf3"}),o.layoutSidebarRight=new o("layout-sidebar-right",{fontCharacter:"\\ebf4"}),o.layoutStatusbar=new o("layout-statusbar",{fontCharacter:"\\ebf5"}),o.layoutMenubar=new o("layout-menubar",{fontCharacter:"\\ebf6"}),o.layoutCentered=new o("layout-centered",{fontCharacter:"\\ebf7"}),o.target=new o("target",{fontCharacter:"\\ebf8"}),o.indent=new o("indent",{fontCharacter:"\\ebf9"}),o.recordSmall=new o("record-small",{fontCharacter:"\\ebfa"}),o.errorSmall=new o("error-small",{fontCharacter:"\\ebfb"}),o.arrowCircleDown=new o("arrow-circle-down",{fontCharacter:"\\ebfc"}),o.arrowCircleLeft=new o("arrow-circle-left",{fontCharacter:"\\ebfd"}),o.arrowCircleRight=new o("arrow-circle-right",{fontCharacter:"\\ebfe"}),o.arrowCircleUp=new o("arrow-circle-up",{fontCharacter:"\\ebff"}),o.dialogError=new o("dialog-error",o.error.definition),o.dialogWarning=new o("dialog-warning",o.warning.definition),o.dialogInfo=new o("dialog-info",o.info.definition),o.dialogClose=new o("dialog-close",o.close.definition),o.treeItemExpanded=new o("tree-item-expanded",o.chevronDown.definition),o.treeFilterOnTypeOn=new o("tree-filter-on-type-on",o.listFilter.definition),o.treeFilterOnTypeOff=new o("tree-filter-on-type-off",o.listSelection.definition),o.treeFilterClear=new o("tree-filter-clear",o.close.definition),o.treeItemLoading=new o("tree-item-loading",o.loading.definition),o.menuSelection=new o("menu-selection",o.check.definition),o.menuSubmenu=new o("menu-submenu",o.chevronRight.definition),o.menuBarMore=new o("menubar-more",o.more.definition),o.scrollbarButtonLeft=new o("scrollbar-button-left",o.triangleLeft.definition),o.scrollbarButtonRight=new o("scrollbar-button-right",o.triangleRight.definition),o.scrollbarButtonUp=new o("scrollbar-button-up",o.triangleUp.definition),o.scrollbarButtonDown=new o("scrollbar-button-down",o.triangleDown.definition),o.toolBarMore=new o("toolbar-more",o.more.definition),o.quickInputBack=new o("quick-input-back",o.arrowLeft.definition),function(e){e.iconNameSegment="[A-Za-z0-9]+",e.iconNameExpression="[A-Za-z0-9-]+",e.iconModifierExpression="~[A-Za-z]+",e.iconNameCharacter="[A-Za-z0-9~-]";const t=new RegExp(`^(${e.iconNameExpression})(${e.iconModifierExpression})?$`);function i(e){if(e instanceof o)return["codicon","codicon-"+e.id];const n=t.exec(e.id);if(!n)return i(o.error);let[,r,s]=n;const a=["codicon","codicon-"+r];return s&&a.push("codicon-modifier-"+s.substr(1)),a}e.asClassNameArray=i,e.asClassName=function(e){return i(e).join(" ")},e.asCSSSelector=function(e){return"."+i(e).join(".")}}(r||(r={}))},64870:function(e,t,i){"use strict";i.d(t,{E:function(){return o},r:function(){return r}});const n=Object.prototype.hasOwnProperty;function o(e,t){for(let i in e)if(n.call(e,i)&&!1===t({key:i,value:e[i]},(function(){delete e[i]})))return}class r{constructor(){this.map=new Map}add(e,t){let i=this.map.get(e);i||(i=new Set,this.map.set(e,i)),i.add(t)}delete(e,t){const i=this.map.get(e);i&&(i.delete(t),0===i.size&&this.map.delete(e))}forEach(e,t){const i=this.map.get(e);i&&i.forEach(t)}}},18689:function(e,t,i){"use strict";function n(e,t){const i=Math.pow(10,t);return Math.round(e*i)/i}i.d(t,{Il:function(){return a},VS:function(){return o},tx:function(){return s}});class o{constructor(e,t,i,o=1){this._rgbaBrand=void 0,this.r=0|Math.min(255,Math.max(0,e)),this.g=0|Math.min(255,Math.max(0,t)),this.b=0|Math.min(255,Math.max(0,i)),this.a=n(Math.max(Math.min(1,o),0),3)}static equals(e,t){return e.r===t.r&&e.g===t.g&&e.b===t.b&&e.a===t.a}}class r{constructor(e,t,i,o){this._hslaBrand=void 0,this.h=0|Math.max(Math.min(360,e),0),this.s=n(Math.max(Math.min(1,t),0),3),this.l=n(Math.max(Math.min(1,i),0),3),this.a=n(Math.max(Math.min(1,o),0),3)}static equals(e,t){return e.h===t.h&&e.s===t.s&&e.l===t.l&&e.a===t.a}static fromRGBA(e){const t=e.r/255,i=e.g/255,n=e.b/255,o=e.a,s=Math.max(t,i,n),a=Math.min(t,i,n);let l=0,c=0;const d=(a+s)/2,u=s-a;if(u>0){switch(c=Math.min(d<=.5?u/(2*d):u/(2-2*d),1),s){case t:l=(i-n)/u+(i1&&(i-=1),i<1/6?e+6*(t-e)*i:i<.5?t:i<2/3?e+(t-e)*(2/3-i)*6:e}static toRGBA(e){const t=e.h/360,{s:i,l:n,a:s}=e;let a,l,c;if(0===i)a=l=c=n;else{const e=n<.5?n*(1+i):n+i-n*i,o=2*n-e;a=r._hue2rgb(o,e,t+1/3),l=r._hue2rgb(o,e,t),c=r._hue2rgb(o,e,t-1/3)}return new o(Math.round(255*a),Math.round(255*l),Math.round(255*c),s)}}class s{constructor(e,t,i,o){this._hsvaBrand=void 0,this.h=0|Math.max(Math.min(360,e),0),this.s=n(Math.max(Math.min(1,t),0),3),this.v=n(Math.max(Math.min(1,i),0),3),this.a=n(Math.max(Math.min(1,o),0),3)}static equals(e,t){return e.h===t.h&&e.s===t.s&&e.v===t.v&&e.a===t.a}static fromRGBA(e){const t=e.r/255,i=e.g/255,n=e.b/255,o=Math.max(t,i,n),r=o-Math.min(t,i,n),a=0===o?0:r/o;let l;return l=0===r?0:o===t?((i-n)/r%6+6)%6:o===i?(n-t)/r+2:(t-i)/r+4,new s(Math.round(60*l),a,o,e.a)}static toRGBA(e){const{h:t,s:i,v:n,a:r}=e,s=n*i,a=s*(1-Math.abs(t/60%2-1)),l=n-s;let[c,d,u]=[0,0,0];return t<60?(c=s,d=a):t<120?(c=a,d=s):t<180?(d=s,u=a):t<240?(d=a,u=s):t<300?(c=a,u=s):t<=360&&(c=s,u=a),c=Math.round(255*(c+l)),d=Math.round(255*(d+l)),u=Math.round(255*(u+l)),new o(c,d,u,r)}}class a{constructor(e){if(!e)throw new Error("Color needs a value");if(e instanceof o)this.rgba=e;else if(e instanceof r)this._hsla=e,this.rgba=r.toRGBA(e);else{if(!(e instanceof s))throw new Error("Invalid color ctor argument");this._hsva=e,this.rgba=s.toRGBA(e)}}static fromHex(e){return a.Format.CSS.parseHex(e)||a.red}get hsla(){return this._hsla?this._hsla:r.fromRGBA(this.rgba)}get hsva(){return this._hsva?this._hsva:s.fromRGBA(this.rgba)}equals(e){return!!e&&o.equals(this.rgba,e.rgba)&&r.equals(this.hsla,e.hsla)&&s.equals(this.hsva,e.hsva)}getRelativeLuminance(){return n(.2126*a._relativeLuminanceForComponent(this.rgba.r)+.7152*a._relativeLuminanceForComponent(this.rgba.g)+.0722*a._relativeLuminanceForComponent(this.rgba.b),4)}static _relativeLuminanceForComponent(e){const t=e/255;return t<=.03928?t/12.92:Math.pow((t+.055)/1.055,2.4)}isLighter(){return(299*this.rgba.r+587*this.rgba.g+114*this.rgba.b)/1e3>=128}isLighterThan(e){return this.getRelativeLuminance()>e.getRelativeLuminance()}isDarkerThan(e){return this.getRelativeLuminance()0||this.m_modifiedCount>0)&&this.m_changes.push(new n(this.m_originalStart,this.m_originalCount,this.m_modifiedStart,this.m_modifiedCount)),this.m_originalCount=0,this.m_modifiedCount=0,this.m_originalStart=1073741824,this.m_modifiedStart=1073741824}AddOriginalElement(e,t){this.m_originalStart=Math.min(this.m_originalStart,e),this.m_modifiedStart=Math.min(this.m_modifiedStart,t),this.m_originalCount++}AddModifiedElement(e,t){this.m_originalStart=Math.min(this.m_originalStart,e),this.m_modifiedStart=Math.min(this.m_modifiedStart,t),this.m_modifiedCount++}getChanges(){return(this.m_originalCount>0||this.m_modifiedCount>0)&&this.MarkNextChange(),this.m_changes}getReverseChanges(){return(this.m_originalCount>0||this.m_modifiedCount>0)&&this.MarkNextChange(),this.m_changes.reverse(),this.m_changes}}class d{constructor(e,t,i=null){this.ContinueProcessingPredicate=i,this._originalSequence=e,this._modifiedSequence=t;const[n,o,r]=d._getElements(e),[s,a,l]=d._getElements(t);this._hasStrings=r&&l,this._originalStringElements=n,this._originalElementsOrHash=o,this._modifiedStringElements=s,this._modifiedElementsOrHash=a,this.m_forwardHistory=[],this.m_reverseHistory=[]}static _isStringArray(e){return e.length>0&&"string"==typeof e[0]}static _getElements(e){const t=e.getElements();if(d._isStringArray(t)){const e=new Int32Array(t.length);for(let i=0,n=t.length;i=e&&o>=i&&this.ElementsAreEqual(t,o);)t--,o--;if(e>t||i>o){let r;return i<=o?(a.Assert(e===t+1,"originalStart should only be one more than originalEnd"),r=[new n(e,0,i,o-i+1)]):e<=t?(a.Assert(i===o+1,"modifiedStart should only be one more than modifiedEnd"),r=[new n(e,t-e+1,i,0)]):(a.Assert(e===t+1,"originalStart should only be one more than originalEnd"),a.Assert(i===o+1,"modifiedStart should only be one more than modifiedEnd"),r=[]),r}const s=[0],l=[0],c=this.ComputeRecursionPoint(e,t,i,o,s,l,r),d=s[0],u=l[0];if(null!==c)return c;if(!r[0]){const s=this.ComputeDiffRecursive(e,d,i,u,r);let a=[];return a=r[0]?[new n(d+1,t-(d+1)+1,u+1,o-(u+1)+1)]:this.ComputeDiffRecursive(d+1,t,u+1,o,r),this.ConcatenateChanges(s,a)}return[new n(e,t-e+1,i,o-i+1)]}WALKTRACE(e,t,i,o,r,s,a,l,d,u,h,g,p,m,f,_,b,v){let C=null,w=null,y=new c,S=t,x=i,k=p[0]-_[0]-o,L=-1073741824,E=this.m_forwardHistory.length-1;do{const t=k+e;t===S||t=0&&(e=(d=this.m_forwardHistory[E])[0],S=1,x=d.length-1)}while(--E>=-1);if(C=y.getReverseChanges(),v[0]){let e=p[0]+1,t=_[0]+1;if(null!==C&&C.length>0){const i=C[C.length-1];e=Math.max(e,i.getOriginalEnd()),t=Math.max(t,i.getModifiedEnd())}w=[new n(e,g-e+1,t,f-t+1)]}else{y=new c,S=s,x=a,k=p[0]-_[0]-l,L=1073741824,E=b?this.m_reverseHistory.length-1:this.m_reverseHistory.length-2;do{const e=k+r;e===S||e=u[e+1]?(m=(h=u[e+1]-1)-k-l,h>L&&y.MarkNextChange(),L=h+1,y.AddOriginalElement(h+1,m+1),k=e+1-r):(m=(h=u[e-1])-k-l,h>L&&y.MarkNextChange(),L=h,y.AddModifiedElement(h+1,m+1),k=e-1-r),E>=0&&(r=(u=this.m_reverseHistory[E])[0],S=1,x=u.length-1)}while(--E>=-1);w=y.getChanges()}return this.ConcatenateChanges(C,w)}ComputeRecursionPoint(e,t,i,o,r,s,a){let c=0,d=0,u=0,h=0,g=0,p=0;e--,i--,r[0]=0,s[0]=0,this.m_forwardHistory=[],this.m_reverseHistory=[];const m=t-e+(o-i),f=m+1,_=new Int32Array(f),b=new Int32Array(f),v=o-i,C=t-e,w=e-i,y=t-o,S=(C-v)%2==0;_[v]=e,b[C]=t,a[0]=!1;for(let x=1;x<=m/2+1;x++){let m=0,k=0;u=this.ClipDiagonalBound(v-x,x,v,f),h=this.ClipDiagonalBound(v+x,x,v,f);for(let e=u;e<=h;e+=2){c=e===u||em+k&&(m=c,k=d),!S&&Math.abs(e-C)<=x-1&&c>=b[e])return r[0]=c,s[0]=d,i<=b[e]&&x<=1448?this.WALKTRACE(v,u,h,w,C,g,p,y,_,b,c,t,r,d,o,s,S,a):null}const L=(m-e+(k-i)-x)/2;if(null!==this.ContinueProcessingPredicate&&!this.ContinueProcessingPredicate(m,L))return a[0]=!0,r[0]=m,s[0]=k,L>0&&x<=1448?this.WALKTRACE(v,u,h,w,C,g,p,y,_,b,c,t,r,d,o,s,S,a):(e++,i++,[new n(e,t-e+1,i,o-i+1)]);g=this.ClipDiagonalBound(C-x,x,C,f),p=this.ClipDiagonalBound(C+x,x,C,f);for(let n=g;n<=p;n+=2){c=n===g||n=b[n+1]?b[n+1]-1:b[n-1],d=c-(n-C)-y;const l=c;for(;c>e&&d>i&&this.ElementsAreEqual(c,d);)c--,d--;if(b[n]=c,S&&Math.abs(n-v)<=x&&c<=_[n])return r[0]=c,s[0]=d,l>=_[n]&&x<=1448?this.WALKTRACE(v,u,h,w,C,g,p,y,_,b,c,t,r,d,o,s,S,a):null}if(x<=1447){let e=new Int32Array(h-u+2);e[0]=v-u+1,l.Copy2(_,u,e,1,h-u+1),this.m_forwardHistory.push(e),e=new Int32Array(p-g+2),e[0]=C-g+1,l.Copy2(b,g,e,1,p-g+1),this.m_reverseHistory.push(e)}}return this.WALKTRACE(v,u,h,w,C,g,p,y,_,b,c,t,r,d,o,s,S,a)}PrettifyChanges(e){for(let t=0;t0,s=i.modifiedLength>0;for(;i.originalStart+i.originalLength=0;t--){const i=e[t];let n=0,o=0;if(t>0){const i=e[t-1];n=i.originalStart+i.originalLength,o=i.modifiedStart+i.modifiedLength}const r=i.originalLength>0,s=i.modifiedLength>0;let a=0,l=this._boundaryScore(i.originalStart,i.originalLength,i.modifiedStart,i.modifiedLength);for(let e=1;;e++){const t=i.originalStart-e,c=i.modifiedStart-e;if(tl&&(l=d,a=e)}i.originalStart-=a,i.modifiedStart-=a;const c=[null];t>0&&this.ChangesOverlap(e[t-1],e[t],c)&&(e[t-1]=c[0],e.splice(t,1),t++)}if(this._hasStrings)for(let t=1,i=e.length;t0&&i>a&&(a=i,l=t,c=e)}return a>0?[l,c]:null}_contiguousSequenceScore(e,t,i){let n=0;for(let o=0;o=this._originalElementsOrHash.length-1||this._hasStrings&&/^\s*$/.test(this._originalStringElements[e])}_OriginalRegionIsBoundary(e,t){if(this._OriginalIsBoundary(e)||this._OriginalIsBoundary(e-1))return!0;if(t>0){const i=e+t;if(this._OriginalIsBoundary(i-1)||this._OriginalIsBoundary(i))return!0}return!1}_ModifiedIsBoundary(e){return e<=0||e>=this._modifiedElementsOrHash.length-1||this._hasStrings&&/^\s*$/.test(this._modifiedStringElements[e])}_ModifiedRegionIsBoundary(e,t){if(this._ModifiedIsBoundary(e)||this._ModifiedIsBoundary(e-1))return!0;if(t>0){const i=e+t;if(this._ModifiedIsBoundary(i-1)||this._ModifiedIsBoundary(i))return!0}return!1}_boundaryScore(e,t,i,n){return(this._OriginalRegionIsBoundary(e,t)?1:0)+(this._ModifiedRegionIsBoundary(i,n)?1:0)}ConcatenateChanges(e,t){let i=[];if(0===e.length||0===t.length)return t.length>0?t:e;if(this.ChangesOverlap(e[e.length-1],t[0],i)){const n=new Array(e.length+t.length-1);return l.Copy(e,0,n,0,e.length-1),n[e.length-1]=i[0],l.Copy(t,1,n,e.length,t.length-1),n}{const i=new Array(e.length+t.length);return l.Copy(e,0,i,0,e.length),l.Copy(t,0,i,e.length,t.length),i}}ChangesOverlap(e,t,i){if(a.Assert(e.originalStart<=t.originalStart,"Left change is not less than or equal to right change"),a.Assert(e.modifiedStart<=t.modifiedStart,"Left change is not less than or equal to right change"),e.originalStart+e.originalLength>=t.originalStart||e.modifiedStart+e.modifiedLength>=t.modifiedStart){const o=e.originalStart;let r=e.originalLength;const s=e.modifiedStart;let a=e.modifiedLength;return e.originalStart+e.originalLength>=t.originalStart&&(r=t.originalStart+t.originalLength-e.originalStart),e.modifiedStart+e.modifiedLength>=t.modifiedStart&&(a=t.modifiedStart+t.modifiedLength-e.modifiedStart),i[0]=new n(o,r,s,a),!0}return i[0]=null,!1}ClipDiagonalBound(e,t,i,n){if(e>=0&&e{if(e.stack)throw new Error(e.message+"\n\n"+e.stack);throw e}),0)}}emit(e){this.listeners.forEach((t=>{t(e)}))}onUnexpectedError(e){this.unexpectedErrorHandler(e),this.emit(e)}onUnexpectedExternalError(e){this.unexpectedErrorHandler(e)}};function o(e){l(e)||n.onUnexpectedError(e)}function r(e){l(e)||n.onUnexpectedExternalError(e)}function s(e){if(e instanceof Error){let{name:t,message:i}=e;return{$isError:!0,name:t,message:i,stack:e.stacktrace||e.stack}}return e}const a="Canceled";function l(e){return e instanceof c||e instanceof Error&&e.name===a&&e.message===a}class c extends Error{constructor(){super(a),this.name=this.message}}function d(){const e=new Error(a);return e.name=e.message,e}function u(e){return e?new Error(`Illegal argument: ${e}`):new Error("Illegal argument")}function h(e){return e?new Error(`Illegal state: ${e}`):new Error("Illegal state")}class g extends Error{constructor(e){super("NotSupported"),e&&(this.message=e)}}},46718:function(e,t,i){"use strict";i.d(t,{D0:function(){return g},E7:function(){return p},K3:function(){return h},Q5:function(){return u},ZD:function(){return m},ju:function(){return n}});var n,o=i(16182),r=i(4004),s=i(57512),a=i(52150);!function(e){function t(e){return(t,i=null,n)=>{let o,r=!1;return o=e((e=>{if(!r)return o?o.dispose():r=!0,t.call(i,e)}),null,n),r&&o.dispose(),o}}function i(e,t,i){return a(((i,n=null,o)=>e((e=>i.call(n,t(e))),null,o)),i)}function n(e,t,i){return a(((i,n=null,o)=>e((e=>{t(e),i.call(n,e)}),null,o)),i)}function o(e,t,i){return a(((i,n=null,o)=>e((e=>t(e)&&i.call(n,e)),null,o)),i)}function s(e,t,n,o){let r=n;return i(e,(e=>(r=t(r,e),r)),o)}function a(e,t){let i;const n=new u({onFirstListenerAdd(){i=e(n.fire,n)},onLastListenerRemove(){i.dispose()}});return t&&t.add(n),n.event}function l(e,t,i=100,n=!1,o,r){let s,a,l,c=0;const d=new u({leakWarningThreshold:o,onFirstListenerAdd(){s=e((e=>{c++,a=t(a,e),n&&!l&&(d.fire(a),a=void 0),clearTimeout(l),l=setTimeout((()=>{const e=a;a=void 0,l=void 0,(!n||c>1)&&d.fire(e),c=0}),i)}))},onLastListenerRemove(){s.dispose()}});return r&&r.add(d),d.event}function c(e,t=((e,t)=>e===t),i){let n,r=!0;return o(e,(e=>{const i=r||!t(e,n);return r=!1,n=e,i}),i)}e.None=()=>r.JT.None,e.once=t,e.map=i,e.forEach=n,e.filter=o,e.signal=function(e){return e},e.any=function(...e){return(t,i=null,n)=>(0,r.F8)(...e.map((e=>e((e=>t.call(i,e)),null,n))))},e.reduce=s,e.debounce=l,e.latch=c,e.split=function(t,i,n){return[e.filter(t,i,n),e.filter(t,(e=>!i(e)),n)]},e.buffer=function(e,t=!1,i=[]){let n=i.slice(),o=e((e=>{n?n.push(e):s.fire(e)}));const r=()=>{n&&n.forEach((e=>s.fire(e))),n=null},s=new u({onFirstListenerAdd(){o||(o=e((e=>s.fire(e))))},onFirstListenerDidAdd(){n&&(t?setTimeout(r):r())},onLastListenerRemove(){o&&o.dispose(),o=null}});return s.event};class d{constructor(e){this.event=e}map(e){return new d(i(this.event,e))}forEach(e){return new d(n(this.event,e))}filter(e){return new d(o(this.event,e))}reduce(e,t){return new d(s(this.event,e,t))}latch(){return new d(c(this.event))}debounce(e,t=100,i=!1,n){return new d(l(this.event,e,t,i,n))}on(e,t,i){return this.event(e,t,i)}once(e,i,n){return t(this.event)(e,i,n)}}e.chain=function(e){return new d(e)},e.fromNodeEventEmitter=function(e,t,i=(e=>e)){const n=(...e)=>o.fire(i(...e)),o=new u({onFirstListenerAdd:()=>e.on(t,n),onLastListenerRemove:()=>e.removeListener(t,n)});return o.event},e.fromDOMEventEmitter=function(e,t,i=(e=>e)){const n=(...e)=>o.fire(i(...e)),o=new u({onFirstListenerAdd:()=>e.addEventListener(t,n),onLastListenerRemove:()=>e.removeEventListener(t,n)});return o.event},e.toPromise=function(e){return new Promise((i=>t(e)(i)))},e.runAndSubscribe=function(e,t){return t(void 0),e((e=>t(e)))},e.runAndSubscribeWithStore=function(e,t){let i=null;function n(e){null==i||i.dispose(),i=new r.SL,t(e,i)}n(void 0);const o=e((e=>n(e)));return(0,r.OF)((()=>{o.dispose(),null==i||i.dispose()}))}}(n||(n={}));class l{constructor(e){this._listenerCount=0,this._invocationCount=0,this._elapsedOverall=0,this._name=`${e}_${l._idPool++}`}start(e){this._stopWatch=new a.G(!0),this._listenerCount=e}stop(){if(this._stopWatch){const e=this._stopWatch.elapsed();this._elapsedOverall+=e,this._invocationCount+=1,console.info(`did FIRE ${this._name}: elapsed_ms: ${e.toFixed(5)}, listener: ${this._listenerCount} (elapsed_overall: ${this._elapsedOverall.toFixed(2)}, invocations: ${this._invocationCount})`),this._stopWatch=void 0}}}l._idPool=0;class c{constructor(e){this.value=e}static create(){var e;return new c(null!==(e=(new Error).stack)&&void 0!==e?e:"")}print(){console.warn(this.value.split("\n").slice(2).join("\n"))}}class d{constructor(e,t,i){this.callback=e,this.callbackThis=t,this.stack=i,this.subscription=new r.dt}invoke(e){this.callback.call(this.callbackThis,e)}}class u{constructor(e){var t;this._disposed=!1,this._options=e,this._leakageMon=void 0,this._perfMon=(null===(t=this._options)||void 0===t?void 0:t._profName)?new l(this._options._profName):void 0}dispose(){var e,t,i,n;this._disposed||(this._disposed=!0,this._listeners&&this._listeners.clear(),null===(e=this._deliveryQueue)||void 0===e||e.clear(),null===(i=null===(t=this._options)||void 0===t?void 0:t.onLastListenerRemove)||void 0===i||i.call(t),null===(n=this._leakageMon)||void 0===n||n.dispose())}get event(){return this._event||(this._event=(e,t,i)=>{var n,o,a;this._listeners||(this._listeners=new s.S);const l=this._listeners.isEmpty();let u,h;l&&(null===(n=this._options)||void 0===n?void 0:n.onFirstListenerAdd)&&this._options.onFirstListenerAdd(this),this._leakageMon&&this._listeners.size>=30&&(h=c.create(),u=this._leakageMon.check(h,this._listeners.size+1));const g=new d(e,t,h),p=this._listeners.push(g);l&&(null===(o=this._options)||void 0===o?void 0:o.onFirstListenerDidAdd)&&this._options.onFirstListenerDidAdd(this),(null===(a=this._options)||void 0===a?void 0:a.onListenerDidAdd)&&this._options.onListenerDidAdd(this,e,t);const m=g.subscription.set((()=>{u&&u(),!this._disposed&&(p(),this._options&&this._options.onLastListenerRemove)&&(this._listeners&&!this._listeners.isEmpty()||this._options.onLastListenerRemove(this))}));return i instanceof r.SL?i.add(m):Array.isArray(i)&&i.push(m),m}),this._event}fire(e){var t,i;if(this._listeners){this._deliveryQueue||(this._deliveryQueue=new s.S);for(let t of this._listeners)this._deliveryQueue.push([t,e]);for(null===(t=this._perfMon)||void 0===t||t.start(this._deliveryQueue.size);this._deliveryQueue.size>0;){const[e,t]=this._deliveryQueue.shift();try{e.invoke(t)}catch(e){(0,o.dL)(e)}}null===(i=this._perfMon)||void 0===i||i.stop()}}}class h extends u{constructor(e){super(e),this._isPaused=0,this._eventQueue=new s.S,this._mergeFn=null==e?void 0:e.merge}pause(){this._isPaused++}resume(){if(0!==this._isPaused&&0==--this._isPaused)if(this._mergeFn){const e=Array.from(this._eventQueue);this._eventQueue.clear(),super.fire(this._mergeFn(e))}else for(;!this._isPaused&&0!==this._eventQueue.size;)super.fire(this._eventQueue.shift())}fire(e){this._listeners&&(0!==this._isPaused?this._eventQueue.push(e):super.fire(e))}}class g extends h{constructor(e){var t;super(e),this._delay=null!==(t=e.delay)&&void 0!==t?t:100}fire(e){this._handle||(this.pause(),this._handle=setTimeout((()=>{this._handle=void 0,this.resume()}),this._delay)),super.fire(e)}}class p{constructor(){this.buffers=[]}wrapEvent(e){return(t,i,n)=>e((e=>{const n=this.buffers[this.buffers.length-1];n?n.push((()=>t.call(i,e))):t.call(i,e)}),void 0,n)}bufferEvents(e){const t=[];this.buffers.push(t);const i=e();return this.buffers.pop(),t.forEach((e=>e())),i}}class m{constructor(){this.listening=!1,this.inputEvent=n.None,this.inputEventListener=r.JT.None,this.emitter=new u({onFirstListenerDidAdd:()=>{this.listening=!0,this.inputEventListener=this.inputEvent(this.emitter.fire,this.emitter)},onLastListenerRemove:()=>{this.listening=!1,this.inputEventListener.dispose()}}),this.event=this.emitter.event}set input(e){this.inputEvent=e,this.listening&&(this.inputEventListener.dispose(),this.inputEventListener=e(this.emitter.fire,this.emitter))}dispose(){this.inputEventListener.dispose(),this.emitter.dispose()}}},56855:function(e,t,i){"use strict";i.d(t,{KM:function(){return d},ej:function(){return a},fn:function(){return l},oP:function(){return g},vY:function(){return h},yj:function(){return c}});var n=i(14477),o=i(6954),r=i(18039);function s(e){return 47===e||92===e}function a(e){return e.replace(/[\\/]/g,n.KR.sep)}function l(e){return-1===e.indexOf("/")&&(e=a(e)),/^[a-zA-Z]:(\/|$)/.test(e)&&(e="/"+e),e}function c(e,t=n.KR.sep){if(!e)return"";const i=e.length,o=e.charCodeAt(0);if(s(o)){if(s(e.charCodeAt(1))&&!s(e.charCodeAt(2))){let n=3;const o=n;for(;ne.length)return!1;if(i){if(!(0,r.ok)(e,t))return!1;if(t.length===e.length)return!0;let i=t.length;return t.charAt(t.length-1)===o&&i--,e.charAt(i)===o}return t.charAt(t.length-1)!==o&&(t+=o),0===e.indexOf(t)}function u(e){return e>=65&&e<=90||e>=97&&e<=122}function h(e){const t=(0,n.Fv)(e);return o.ED?!(e.length>3)&&g(t)&&(2===e.length||92===t.charCodeAt(2)):t===n.KR.sep}function g(e,t){return!!(void 0!==t?t:o.ED)&&u(e.charCodeAt(0))&&58===e.charCodeAt(1)}},34604:function(e,t,i){"use strict";i.d(t,{CL:function(){return H},EW:function(){return z},Ji:function(){return s},KZ:function(){return w},Oh:function(){return E},ir:function(){return l},jB:function(){return N},l7:function(){return U},mB:function(){return D},or:function(){return r}});var n=i(38455),o=i(18039);function r(...e){return function(t,i){for(let n=0,o=e.length;n0?[{start:0,end:t.length}]:[]:null}function l(e,t){const i=t.toLowerCase().indexOf(e.toLowerCase());return-1===i?null:[{start:i,end:i+e.length}]}function c(e,t,i,n){if(i===e.length)return[];if(n===t.length)return null;if(e[i]===t[n]){let o=null;return(o=c(e,t,i+1,n+1))?_({start:n,end:n+1},o):null}return c(e,t,i,n+1)}function d(e){return 97<=e&&e<=122}function u(e){return 65<=e&&e<=90}function h(e){return 48<=e&&e<=57}function g(e){return 32===e||9===e||10===e||13===e}const p=new Set;function m(e){return g(e)||p.has(e)}function f(e){return d(e)||u(e)||h(e)}function _(e,t){return 0===t.length?t=[e]:e.end===t[0].start?t[0].start=e.start:t.unshift(e),t}function b(e,t){for(let i=t;i0&&!f(e.charCodeAt(i-1)))return i}return e.length}function v(e,t,i,n){if(i===e.length)return[];if(n===t.length)return null;if(e[i]!==t[n].toLowerCase())return null;{let o=null,r=n+1;for(o=v(e,t,i+1,n+1);!o&&(r=b(t,r))60)return null;const i=function(e){let t=0,i=0,n=0,o=0,r=0;for(let s=0;s.2&&t<.8&&n>.6&&o<.2}(i)){if(!function(e){const{upperPercent:t,lowerPercent:i}=e;return 0===i&&t>.6}(i))return null;t=t.toLowerCase()}let n=null,o=0;for(e=e.toLowerCase();o0&&m(e.charCodeAt(i-1)))return i;return e.length}"()[]{}<>`'\"-/;:,.?!".split("").forEach((e=>p.add(e.charCodeAt(0))));const x=r(s,C,l),k=r(s,C,(function(e,t){return c(e.toLowerCase(),t.toLowerCase(),0,0)})),L=new n.z6(1e4);function E(e,t,i=!1){if("string"!=typeof e||"string"!=typeof t)return null;let n=L.get(e);n||(n=new RegExp(o.un(e),"i"),L.set(e,n));const r=n.exec(t);return r?[{start:r.index,end:r.index+r[0].length}]:i?k(e,t):x(e,t)}function N(e,t,i,n,o,r){const s=Math.min(13,e.length);for(;i1;n--){const o=e[n]+i,r=t[t.length-1];r&&r.end===o?r.end=o+1:t.push({start:o,end:o+1})}return t}const I=128;function T(){const e=[],t=[];for(let e=0;e<=I;e++)t[e]=0;for(let i=0;i<=I;i++)e.push(t.slice(0));return e}function A(e){const t=[];for(let i=0;i<=e;i++)t[i]=0;return t}const R=A(256),M=A(256),O=T(),P=T(),F=T();function B(e,t){if(t<0||t>=e.length)return!1;const i=e.codePointAt(t);switch(i){case 95:case 45:case 46:case 32:case 47:case 92:case 39:case 34:case 58:case 36:case 60:case 40:case 91:return!0;case void 0:return!1;default:return!!o.C8(i)}}function W(e,t){if(t<0||t>=e.length)return!1;switch(e.charCodeAt(t)){case 32:case 9:return!0;default:return!1}}function V(e,t,i){return t[e]!==i[e]}var H;function z(e,t,i,n,o,r,s){const a=e.length>I?I:e.length,l=n.length>I?I:n.length;if(i>=a||r>=l||a-i>l-r)return;if(!function(e,t,i,n,o,r,s=!1){for(;t=i&&a>=n;)o[s]===r[a]&&(M[s]=a,s--),a--}(a,l,i,r,t,o);let c=1,d=1,u=i,h=r;const g=[!1];for(c=1,u=i;us,b=_?P[c][d-1]+(O[c][d-1]>0?-5:0):0,v=h>s+1&&O[c][d-1]>0,C=v?P[c][d-2]+(O[c][d-2]>0?-5:0):0;if(v&&(!_||C>=b)&&(!m||C>=f))P[c][d]=C,F[c][d]=3,O[c][d]=0;else if(_&&(!m||b>=f))P[c][d]=b,F[c][d]=2,O[c][d]=0;else{if(!m)throw new Error("not possible");P[c][d]=f,F[c][d]=1,O[c][d]=O[c-1][d-1]+1}}}if(!g[0]&&!s)return;c--,d--;const p=[P[c][d],r];let m=0,f=0;for(;c>=1;){let e=d;do{const t=F[c][e];if(3===t)e-=2;else{if(2!==t)break;e-=1}}while(e>=1);m>1&&t[i+c-1]===o[r+d-1]&&!V(e+r-1,n,o)&&m+1>O[c][e]&&(e=d),e===d?m++:m=1,f||(f=e),c--,d=e-1,p.push(d)}l===a&&(p[0]+=2);const _=f-a;return p[0]-=_,p}function $(e,t,i,n,o,r,s,a,l,c,d){if(t[i]!==r[s])return Number.MIN_SAFE_INTEGER;let u=1,h=!1;return s===i-n?u=e[i]===o[s]?7:5:!V(s,o,r)||0!==s&&V(s-1,o,r)?!B(r,s)||0!==s&&B(r,s-1)?(B(r,s-1)||W(r,s-1))&&(u=5,h=!0):u=5:(u=e[i]===o[s]?7:5,h=!0),u>1&&i===n&&(d[0]=!0),h||(h=V(s,o,r)||B(r,s-1)||W(r,s-1)),i===n?s>l&&(u-=h?3:5):u+=c?h?2:0:h?0:1,s+1===a&&(u-=h?3:5),u}function U(e,t,i,n,o,r,s){return function(e,t,i,n,o,r,s,a){let l=z(e,t,i,n,o,r,a);if(e.length>=3){const t=Math.min(7,e.length-1);for(let s=i+1;sl[0])&&(l=e))}}}return l}(e,t,i,n,o,r,0,s)}function j(e,t){if(t+1>=e.length)return;const i=e[t],n=e[t+1];return i!==n?e.slice(0,t)+n+i+e.slice(t+2):void 0}!function(e){e.Default=[-100,0],e.isDefault=function(e){return!e||2===e.length&&-100===e[0]&&0===e[1]}}(H||(H={}))},58143:function(e,t,i){"use strict";function n(e){const t=this;let i,n=!1;return function(){return n||(n=!0,i=e.apply(t,arguments)),i}}i.d(t,{I:function(){return n}})},25672:function(e,t,i){"use strict";i.d(t,{Cv:function(){return a},SP:function(){return r},vp:function(){return o},yP:function(){return u}});var n=i(18039);function o(e){return r(e,0)}function r(e,t){switch(typeof e){case"object":return null===e?s(349,t):Array.isArray(e)?(i=e,n=s(104579,n=t),i.reduce(((e,t)=>r(t,e)),n)):function(e,t){return t=s(181387,t),Object.keys(e).sort().reduce(((t,i)=>(t=a(i,t),r(e[i],t))),t)}(e,t);case"string":return a(e,t);case"boolean":return function(e,t){return s(e?433:863,t)}(e,t);case"number":return s(e,t);case"undefined":return s(937,t);default:return s(617,t)}var i,n}function s(e,t){return(t<<5)-t+e|0}function a(e,t){t=s(149417,t);for(let i=0,n=e.length;i>>n)>>>0}function c(e,t=0,i=e.byteLength,n=0){for(let o=0;oe.toString(16).padStart(2,"0"))).join(""):function(e,t,i="0"){for(;e.length>>0).toString(16),t/4)}class u{constructor(){this._h0=1732584193,this._h1=4023233417,this._h2=2562383102,this._h3=271733878,this._h4=3285377520,this._buff=new Uint8Array(67),this._buffDV=new DataView(this._buff.buffer),this._buffLen=0,this._totalLen=0,this._leftoverHighSurrogate=0,this._finished=!1}update(e){const t=e.length;if(0===t)return;const i=this._buff;let o,r,s=this._buffLen,a=this._leftoverHighSurrogate;for(0!==a?(o=a,r=-1,a=0):(o=e.charCodeAt(0),r=0);;){let l=o;if(n.ZG(o)){if(!(r+1>>6,e[t++]=128|(63&i)>>>0):i<65536?(e[t++]=224|(61440&i)>>>12,e[t++]=128|(4032&i)>>>6,e[t++]=128|(63&i)>>>0):(e[t++]=240|(1835008&i)>>>18,e[t++]=128|(258048&i)>>>12,e[t++]=128|(4032&i)>>>6,e[t++]=128|(63&i)>>>0),t>=64&&(this._step(),t-=64,this._totalLen+=64,e[0]=e[64],e[1]=e[65],e[2]=e[66]),t}digest(){return this._finished||(this._finished=!0,this._leftoverHighSurrogate&&(this._leftoverHighSurrogate=0,this._buffLen=this._push(this._buff,this._buffLen,65533)),this._totalLen+=this._buffLen,this._wrapUp()),d(this._h0)+d(this._h1)+d(this._h2)+d(this._h3)+d(this._h4)}_wrapUp(){this._buff[this._buffLen++]=128,c(this._buff,this._buffLen),this._buffLen>56&&(this._step(),c(this._buff));const e=8*this._totalLen;this._buffDV.setUint32(56,Math.floor(e/4294967296),!1),this._buffDV.setUint32(60,e%4294967296,!1),this._step()}_step(){const e=u._bigBlock32,t=this._buffDV;for(let i=0;i<64;i+=4)e.setUint32(i,t.getUint32(i,!1),!1);for(let t=64;t<320;t+=4)e.setUint32(t,l(e.getUint32(t-12,!1)^e.getUint32(t-32,!1)^e.getUint32(t-56,!1)^e.getUint32(t-64,!1),1),!1);let i,n,o,r=this._h0,s=this._h1,a=this._h2,c=this._h3,d=this._h4;for(let t=0;t<80;t++)t<20?(i=s&a|~s&c,n=1518500249):t<40?(i=s^a^c,n=1859775393):t<60?(i=s&a|s&c|a&c,n=2400959708):(i=s^a^c,n=3395469782),o=l(r,5)+i+d+n+e.getUint32(4*t,!1)&4294967295,d=c,c=a,a=l(s,30),s=r,r=o;this._h0=this._h0+r&4294967295,this._h1=this._h1+s&4294967295,this._h2=this._h2+a&4294967295,this._h3=this._h3+c&4294967295,this._h4=this._h4+d&4294967295}}u._bigBlock32=new DataView(new ArrayBuffer(320))},66978:function(e,t,i){"use strict";i.d(t,{CP:function(){return s},Fr:function(){return a},W5:function(){return r},oR:function(){return l},v1:function(){return c}});var n=i(16182),o=i(14329);class r{constructor(e="",t=!1){var i,o,r;if(this.value=e,"string"!=typeof this.value)throw(0,n.b1)("value");"boolean"==typeof t?(this.isTrusted=t,this.supportThemeIcons=!1,this.supportHtml=!1):(this.isTrusted=null!==(i=t.isTrusted)&&void 0!==i?i:void 0,this.supportThemeIcons=null!==(o=t.supportThemeIcons)&&void 0!==o&&o,this.supportHtml=null!==(r=t.supportHtml)&&void 0!==r&&r)}appendText(e,t=0){var i;return this.value+=(i=this.supportThemeIcons?(0,o.Qo)(e):e,i.replace(/[\\`*_{}[\]()#+\-!]/g,"\\$&")).replace(/([ \t]+)/g,((e,t)=>" ".repeat(t.length))).replace(/\>/gm,"\\>").replace(/\n/g,1===t?"\\\n":"\n\n"),this}appendMarkdown(e){return this.value+=e,this}appendCodeblock(e,t){return this.value+="\n```",this.value+=e,this.value+="\n",this.value+=t,this.value+="\n```\n",this}}function s(e){return a(e)?!e.value:!Array.isArray(e)||e.every(s)}function a(e){return e instanceof r||!(!e||"object"!=typeof e)&&!("string"!=typeof e.value||"boolean"!=typeof e.isTrusted&&void 0!==e.isTrusted||"boolean"!=typeof e.supportThemeIcons&&void 0!==e.supportThemeIcons)}function l(e){return e?e.replace(/\\([\\`*_{}[\]()#+\-.!])/g,"$1"):e}function c(e){const t=[],i=e.split("|").map((e=>e.trim()));e=i[0];const n=i[1];if(n){const e=/height=(\d+)/.exec(n),i=/width=(\d+)/.exec(n),o=e?e[1]:"",r=i?i[1]:"",s=isFinite(parseInt(r)),a=isFinite(parseInt(o));s&&t.push(`width="${r}"`),a&&t.push(`height="${o}"`)}return{href:e,dimensions:t}}},14329:function(e,t,i){"use strict";i.d(t,{Gt:function(){return f},Ho:function(){return m},Qo:function(){return d},f$:function(){return h},x$:function(){return p}});var n=i(4821),o=i(34604),r=i(18039);const s="$(",a=new RegExp(`\\$\\(${n.dT.iconNameExpression}(?:${n.dT.iconModifierExpression})?\\)`,"g"),l=new RegExp(n.dT.iconNameCharacter),c=new RegExp(`(\\\\)?${a.source}`,"g");function d(e){return e.replace(c,((e,t)=>t?e:`\\${e}`))}const u=new RegExp(`\\\\${a.source}`,"g");function h(e){return e.replace(u,(e=>`\\${e}`))}const g=new RegExp(`(\\s)?(\\\\)?${a.source}(\\s)?`,"g");function p(e){return-1===(e=e||"").indexOf(s)?e:e.replace(g,((e,t,i,n)=>i?e:t||n||""))}function m(e){const t=e.indexOf(s);return-1===t?{text:e}:function(e,t){const i=[];let n="";function o(e){if(e){n+=e;for(const t of e)i.push(u)}}let r,a,c=-1,d="",u=0,h=t;const g=e.length;for(o(e.substr(0,t));he.length&&(i=e.length);to}]},e.equals=function(e,t,i=((e,t)=>e===t)){const n=e[Symbol.iterator](),o=t[Symbol.iterator]();for(;;){const e=n.next(),t=o.next();if(e.done!==t.done)return!1;if(e.done)return!0;if(!i(e.value,t.value))return!1}}}(n||(n={}))},37808:function(e,t,i){"use strict";i.d(t,{H_:function(){return a},Vd:function(){return h},gx:function(){return m},kL:function(){return p}});class n{constructor(){this._keyCodeToStr=[],this._strToKeyCode=Object.create(null)}define(e,t){this._keyCodeToStr[e]=t,this._strToKeyCode[t.toLowerCase()]=e}keyCodeToStr(e){return this._keyCodeToStr[e]}strToKeyCode(e){return this._strToKeyCode[e.toLowerCase()]||0}}const o=new n,r=new n,s=new n,a=new Array(230),l={},c=[],d=Object.create(null),u=Object.create(null),h=[],g=[];for(let e=0;e<=193;e++)h[e]=-1;for(let e=0;e<=127;e++)g[e]=-1;var p;function m(e,t){return(e|(65535&t)<<16>>>0)>>>0}!function(){const e="",t=[[0,1,0,"None",0,"unknown",0,"VK_UNKNOWN",e,e],[0,1,1,"Hyper",0,e,0,e,e,e],[0,1,2,"Super",0,e,0,e,e,e],[0,1,3,"Fn",0,e,0,e,e,e],[0,1,4,"FnLock",0,e,0,e,e,e],[0,1,5,"Suspend",0,e,0,e,e,e],[0,1,6,"Resume",0,e,0,e,e,e],[0,1,7,"Turbo",0,e,0,e,e,e],[0,1,8,"Sleep",0,e,0,"VK_SLEEP",e,e],[0,1,9,"WakeUp",0,e,0,e,e,e],[31,0,10,"KeyA",31,"A",65,"VK_A",e,e],[32,0,11,"KeyB",32,"B",66,"VK_B",e,e],[33,0,12,"KeyC",33,"C",67,"VK_C",e,e],[34,0,13,"KeyD",34,"D",68,"VK_D",e,e],[35,0,14,"KeyE",35,"E",69,"VK_E",e,e],[36,0,15,"KeyF",36,"F",70,"VK_F",e,e],[37,0,16,"KeyG",37,"G",71,"VK_G",e,e],[38,0,17,"KeyH",38,"H",72,"VK_H",e,e],[39,0,18,"KeyI",39,"I",73,"VK_I",e,e],[40,0,19,"KeyJ",40,"J",74,"VK_J",e,e],[41,0,20,"KeyK",41,"K",75,"VK_K",e,e],[42,0,21,"KeyL",42,"L",76,"VK_L",e,e],[43,0,22,"KeyM",43,"M",77,"VK_M",e,e],[44,0,23,"KeyN",44,"N",78,"VK_N",e,e],[45,0,24,"KeyO",45,"O",79,"VK_O",e,e],[46,0,25,"KeyP",46,"P",80,"VK_P",e,e],[47,0,26,"KeyQ",47,"Q",81,"VK_Q",e,e],[48,0,27,"KeyR",48,"R",82,"VK_R",e,e],[49,0,28,"KeyS",49,"S",83,"VK_S",e,e],[50,0,29,"KeyT",50,"T",84,"VK_T",e,e],[51,0,30,"KeyU",51,"U",85,"VK_U",e,e],[52,0,31,"KeyV",52,"V",86,"VK_V",e,e],[53,0,32,"KeyW",53,"W",87,"VK_W",e,e],[54,0,33,"KeyX",54,"X",88,"VK_X",e,e],[55,0,34,"KeyY",55,"Y",89,"VK_Y",e,e],[56,0,35,"KeyZ",56,"Z",90,"VK_Z",e,e],[22,0,36,"Digit1",22,"1",49,"VK_1",e,e],[23,0,37,"Digit2",23,"2",50,"VK_2",e,e],[24,0,38,"Digit3",24,"3",51,"VK_3",e,e],[25,0,39,"Digit4",25,"4",52,"VK_4",e,e],[26,0,40,"Digit5",26,"5",53,"VK_5",e,e],[27,0,41,"Digit6",27,"6",54,"VK_6",e,e],[28,0,42,"Digit7",28,"7",55,"VK_7",e,e],[29,0,43,"Digit8",29,"8",56,"VK_8",e,e],[30,0,44,"Digit9",30,"9",57,"VK_9",e,e],[21,0,45,"Digit0",21,"0",48,"VK_0",e,e],[3,1,46,"Enter",3,"Enter",13,"VK_RETURN",e,e],[9,1,47,"Escape",9,"Escape",27,"VK_ESCAPE",e,e],[1,1,48,"Backspace",1,"Backspace",8,"VK_BACK",e,e],[2,1,49,"Tab",2,"Tab",9,"VK_TAB",e,e],[10,1,50,"Space",10,"Space",32,"VK_SPACE",e,e],[83,0,51,"Minus",83,"-",189,"VK_OEM_MINUS","-","OEM_MINUS"],[81,0,52,"Equal",81,"=",187,"VK_OEM_PLUS","=","OEM_PLUS"],[87,0,53,"BracketLeft",87,"[",219,"VK_OEM_4","[","OEM_4"],[89,0,54,"BracketRight",89,"]",221,"VK_OEM_6","]","OEM_6"],[88,0,55,"Backslash",88,"\\",220,"VK_OEM_5","\\","OEM_5"],[0,0,56,"IntlHash",0,e,0,e,e,e],[80,0,57,"Semicolon",80,";",186,"VK_OEM_1",";","OEM_1"],[90,0,58,"Quote",90,"'",222,"VK_OEM_7","'","OEM_7"],[86,0,59,"Backquote",86,"`",192,"VK_OEM_3","`","OEM_3"],[82,0,60,"Comma",82,",",188,"VK_OEM_COMMA",",","OEM_COMMA"],[84,0,61,"Period",84,".",190,"VK_OEM_PERIOD",".","OEM_PERIOD"],[85,0,62,"Slash",85,"/",191,"VK_OEM_2","/","OEM_2"],[8,1,63,"CapsLock",8,"CapsLock",20,"VK_CAPITAL",e,e],[59,1,64,"F1",59,"F1",112,"VK_F1",e,e],[60,1,65,"F2",60,"F2",113,"VK_F2",e,e],[61,1,66,"F3",61,"F3",114,"VK_F3",e,e],[62,1,67,"F4",62,"F4",115,"VK_F4",e,e],[63,1,68,"F5",63,"F5",116,"VK_F5",e,e],[64,1,69,"F6",64,"F6",117,"VK_F6",e,e],[65,1,70,"F7",65,"F7",118,"VK_F7",e,e],[66,1,71,"F8",66,"F8",119,"VK_F8",e,e],[67,1,72,"F9",67,"F9",120,"VK_F9",e,e],[68,1,73,"F10",68,"F10",121,"VK_F10",e,e],[69,1,74,"F11",69,"F11",122,"VK_F11",e,e],[70,1,75,"F12",70,"F12",123,"VK_F12",e,e],[0,1,76,"PrintScreen",0,e,0,e,e,e],[79,1,77,"ScrollLock",79,"ScrollLock",145,"VK_SCROLL",e,e],[7,1,78,"Pause",7,"PauseBreak",19,"VK_PAUSE",e,e],[19,1,79,"Insert",19,"Insert",45,"VK_INSERT",e,e],[14,1,80,"Home",14,"Home",36,"VK_HOME",e,e],[11,1,81,"PageUp",11,"PageUp",33,"VK_PRIOR",e,e],[20,1,82,"Delete",20,"Delete",46,"VK_DELETE",e,e],[13,1,83,"End",13,"End",35,"VK_END",e,e],[12,1,84,"PageDown",12,"PageDown",34,"VK_NEXT",e,e],[17,1,85,"ArrowRight",17,"RightArrow",39,"VK_RIGHT","Right",e],[15,1,86,"ArrowLeft",15,"LeftArrow",37,"VK_LEFT","Left",e],[18,1,87,"ArrowDown",18,"DownArrow",40,"VK_DOWN","Down",e],[16,1,88,"ArrowUp",16,"UpArrow",38,"VK_UP","Up",e],[78,1,89,"NumLock",78,"NumLock",144,"VK_NUMLOCK",e,e],[108,1,90,"NumpadDivide",108,"NumPad_Divide",111,"VK_DIVIDE",e,e],[103,1,91,"NumpadMultiply",103,"NumPad_Multiply",106,"VK_MULTIPLY",e,e],[106,1,92,"NumpadSubtract",106,"NumPad_Subtract",109,"VK_SUBTRACT",e,e],[104,1,93,"NumpadAdd",104,"NumPad_Add",107,"VK_ADD",e,e],[3,1,94,"NumpadEnter",3,e,0,e,e,e],[94,1,95,"Numpad1",94,"NumPad1",97,"VK_NUMPAD1",e,e],[95,1,96,"Numpad2",95,"NumPad2",98,"VK_NUMPAD2",e,e],[96,1,97,"Numpad3",96,"NumPad3",99,"VK_NUMPAD3",e,e],[97,1,98,"Numpad4",97,"NumPad4",100,"VK_NUMPAD4",e,e],[98,1,99,"Numpad5",98,"NumPad5",101,"VK_NUMPAD5",e,e],[99,1,100,"Numpad6",99,"NumPad6",102,"VK_NUMPAD6",e,e],[100,1,101,"Numpad7",100,"NumPad7",103,"VK_NUMPAD7",e,e],[101,1,102,"Numpad8",101,"NumPad8",104,"VK_NUMPAD8",e,e],[102,1,103,"Numpad9",102,"NumPad9",105,"VK_NUMPAD9",e,e],[93,1,104,"Numpad0",93,"NumPad0",96,"VK_NUMPAD0",e,e],[107,1,105,"NumpadDecimal",107,"NumPad_Decimal",110,"VK_DECIMAL",e,e],[92,0,106,"IntlBackslash",92,"OEM_102",226,"VK_OEM_102",e,e],[58,1,107,"ContextMenu",58,"ContextMenu",93,e,e,e],[0,1,108,"Power",0,e,0,e,e,e],[0,1,109,"NumpadEqual",0,e,0,e,e,e],[71,1,110,"F13",71,"F13",124,"VK_F13",e,e],[72,1,111,"F14",72,"F14",125,"VK_F14",e,e],[73,1,112,"F15",73,"F15",126,"VK_F15",e,e],[74,1,113,"F16",74,"F16",127,"VK_F16",e,e],[75,1,114,"F17",75,"F17",128,"VK_F17",e,e],[76,1,115,"F18",76,"F18",129,"VK_F18",e,e],[77,1,116,"F19",77,"F19",130,"VK_F19",e,e],[0,1,117,"F20",0,e,0,"VK_F20",e,e],[0,1,118,"F21",0,e,0,"VK_F21",e,e],[0,1,119,"F22",0,e,0,"VK_F22",e,e],[0,1,120,"F23",0,e,0,"VK_F23",e,e],[0,1,121,"F24",0,e,0,"VK_F24",e,e],[0,1,122,"Open",0,e,0,e,e,e],[0,1,123,"Help",0,e,0,e,e,e],[0,1,124,"Select",0,e,0,e,e,e],[0,1,125,"Again",0,e,0,e,e,e],[0,1,126,"Undo",0,e,0,e,e,e],[0,1,127,"Cut",0,e,0,e,e,e],[0,1,128,"Copy",0,e,0,e,e,e],[0,1,129,"Paste",0,e,0,e,e,e],[0,1,130,"Find",0,e,0,e,e,e],[0,1,131,"AudioVolumeMute",112,"AudioVolumeMute",173,"VK_VOLUME_MUTE",e,e],[0,1,132,"AudioVolumeUp",113,"AudioVolumeUp",175,"VK_VOLUME_UP",e,e],[0,1,133,"AudioVolumeDown",114,"AudioVolumeDown",174,"VK_VOLUME_DOWN",e,e],[105,1,134,"NumpadComma",105,"NumPad_Separator",108,"VK_SEPARATOR",e,e],[110,0,135,"IntlRo",110,"ABNT_C1",193,"VK_ABNT_C1",e,e],[0,1,136,"KanaMode",0,e,0,e,e,e],[0,0,137,"IntlYen",0,e,0,e,e,e],[0,1,138,"Convert",0,e,0,e,e,e],[0,1,139,"NonConvert",0,e,0,e,e,e],[0,1,140,"Lang1",0,e,0,e,e,e],[0,1,141,"Lang2",0,e,0,e,e,e],[0,1,142,"Lang3",0,e,0,e,e,e],[0,1,143,"Lang4",0,e,0,e,e,e],[0,1,144,"Lang5",0,e,0,e,e,e],[0,1,145,"Abort",0,e,0,e,e,e],[0,1,146,"Props",0,e,0,e,e,e],[0,1,147,"NumpadParenLeft",0,e,0,e,e,e],[0,1,148,"NumpadParenRight",0,e,0,e,e,e],[0,1,149,"NumpadBackspace",0,e,0,e,e,e],[0,1,150,"NumpadMemoryStore",0,e,0,e,e,e],[0,1,151,"NumpadMemoryRecall",0,e,0,e,e,e],[0,1,152,"NumpadMemoryClear",0,e,0,e,e,e],[0,1,153,"NumpadMemoryAdd",0,e,0,e,e,e],[0,1,154,"NumpadMemorySubtract",0,e,0,e,e,e],[0,1,155,"NumpadClear",126,"Clear",12,"VK_CLEAR",e,e],[0,1,156,"NumpadClearEntry",0,e,0,e,e,e],[5,1,0,e,5,"Ctrl",17,"VK_CONTROL",e,e],[4,1,0,e,4,"Shift",16,"VK_SHIFT",e,e],[6,1,0,e,6,"Alt",18,"VK_MENU",e,e],[57,1,0,e,57,"Meta",0,"VK_COMMAND",e,e],[5,1,157,"ControlLeft",5,e,0,"VK_LCONTROL",e,e],[4,1,158,"ShiftLeft",4,e,0,"VK_LSHIFT",e,e],[6,1,159,"AltLeft",6,e,0,"VK_LMENU",e,e],[57,1,160,"MetaLeft",57,e,0,"VK_LWIN",e,e],[5,1,161,"ControlRight",5,e,0,"VK_RCONTROL",e,e],[4,1,162,"ShiftRight",4,e,0,"VK_RSHIFT",e,e],[6,1,163,"AltRight",6,e,0,"VK_RMENU",e,e],[57,1,164,"MetaRight",57,e,0,"VK_RWIN",e,e],[0,1,165,"BrightnessUp",0,e,0,e,e,e],[0,1,166,"BrightnessDown",0,e,0,e,e,e],[0,1,167,"MediaPlay",0,e,0,e,e,e],[0,1,168,"MediaRecord",0,e,0,e,e,e],[0,1,169,"MediaFastForward",0,e,0,e,e,e],[0,1,170,"MediaRewind",0,e,0,e,e,e],[114,1,171,"MediaTrackNext",119,"MediaTrackNext",176,"VK_MEDIA_NEXT_TRACK",e,e],[115,1,172,"MediaTrackPrevious",120,"MediaTrackPrevious",177,"VK_MEDIA_PREV_TRACK",e,e],[116,1,173,"MediaStop",121,"MediaStop",178,"VK_MEDIA_STOP",e,e],[0,1,174,"Eject",0,e,0,e,e,e],[117,1,175,"MediaPlayPause",122,"MediaPlayPause",179,"VK_MEDIA_PLAY_PAUSE",e,e],[0,1,176,"MediaSelect",123,"LaunchMediaPlayer",181,"VK_MEDIA_LAUNCH_MEDIA_SELECT",e,e],[0,1,177,"LaunchMail",124,"LaunchMail",180,"VK_MEDIA_LAUNCH_MAIL",e,e],[0,1,178,"LaunchApp2",125,"LaunchApp2",183,"VK_MEDIA_LAUNCH_APP2",e,e],[0,1,179,"LaunchApp1",0,e,0,"VK_MEDIA_LAUNCH_APP1",e,e],[0,1,180,"SelectTask",0,e,0,e,e,e],[0,1,181,"LaunchScreenSaver",0,e,0,e,e,e],[0,1,182,"BrowserSearch",115,"BrowserSearch",170,"VK_BROWSER_SEARCH",e,e],[0,1,183,"BrowserHome",116,"BrowserHome",172,"VK_BROWSER_HOME",e,e],[112,1,184,"BrowserBack",117,"BrowserBack",166,"VK_BROWSER_BACK",e,e],[113,1,185,"BrowserForward",118,"BrowserForward",167,"VK_BROWSER_FORWARD",e,e],[0,1,186,"BrowserStop",0,e,0,"VK_BROWSER_STOP",e,e],[0,1,187,"BrowserRefresh",0,e,0,"VK_BROWSER_REFRESH",e,e],[0,1,188,"BrowserFavorites",0,e,0,"VK_BROWSER_FAVORITES",e,e],[0,1,189,"ZoomToggle",0,e,0,e,e,e],[0,1,190,"MailReply",0,e,0,e,e,e],[0,1,191,"MailForward",0,e,0,e,e,e],[0,1,192,"MailSend",0,e,0,e,e,e],[109,1,0,e,109,"KeyInComposition",229,e,e,e],[111,1,0,e,111,"ABNT_C2",194,"VK_ABNT_C2",e,e],[91,1,0,e,91,"OEM_8",223,"VK_OEM_8",e,e],[0,1,0,e,0,e,0,"VK_KANA",e,e],[0,1,0,e,0,e,0,"VK_HANGUL",e,e],[0,1,0,e,0,e,0,"VK_JUNJA",e,e],[0,1,0,e,0,e,0,"VK_FINAL",e,e],[0,1,0,e,0,e,0,"VK_HANJA",e,e],[0,1,0,e,0,e,0,"VK_KANJI",e,e],[0,1,0,e,0,e,0,"VK_CONVERT",e,e],[0,1,0,e,0,e,0,"VK_NONCONVERT",e,e],[0,1,0,e,0,e,0,"VK_ACCEPT",e,e],[0,1,0,e,0,e,0,"VK_MODECHANGE",e,e],[0,1,0,e,0,e,0,"VK_SELECT",e,e],[0,1,0,e,0,e,0,"VK_PRINT",e,e],[0,1,0,e,0,e,0,"VK_EXECUTE",e,e],[0,1,0,e,0,e,0,"VK_SNAPSHOT",e,e],[0,1,0,e,0,e,0,"VK_HELP",e,e],[0,1,0,e,0,e,0,"VK_APPS",e,e],[0,1,0,e,0,e,0,"VK_PROCESSKEY",e,e],[0,1,0,e,0,e,0,"VK_PACKET",e,e],[0,1,0,e,0,e,0,"VK_DBE_SBCSCHAR",e,e],[0,1,0,e,0,e,0,"VK_DBE_DBCSCHAR",e,e],[0,1,0,e,0,e,0,"VK_ATTN",e,e],[0,1,0,e,0,e,0,"VK_CRSEL",e,e],[0,1,0,e,0,e,0,"VK_EXSEL",e,e],[0,1,0,e,0,e,0,"VK_EREOF",e,e],[0,1,0,e,0,e,0,"VK_PLAY",e,e],[0,1,0,e,0,e,0,"VK_ZOOM",e,e],[0,1,0,e,0,e,0,"VK_NONAME",e,e],[0,1,0,e,0,e,0,"VK_PA1",e,e],[0,1,0,e,0,e,0,"VK_OEM_CLEAR",e,e]];let i=[],n=[];for(const e of t){const[t,p,m,f,_,b,v,C,w,y]=e;if(n[m]||(n[m]=!0,c[m]=f,d[f]=m,u[f.toLowerCase()]=m,p&&(h[m]=_,0!==_&&3!==_&&5!==_&&4!==_&&6!==_&&57!==_&&(g[_]=m))),!i[_]){if(i[_]=!0,!b)throw new Error(`String representation missing for key code ${_} around scan code ${f}`);o.define(_,b),r.define(_,w||b),s.define(_,y||w||b)}v&&(a[v]=_),C&&(l[C]=_)}g[3]=46}(),function(e){e.toString=function(e){return o.keyCodeToStr(e)},e.fromString=function(e){return o.strToKeyCode(e)},e.toUserSettingsUS=function(e){return r.keyCodeToStr(e)},e.toUserSettingsGeneral=function(e){return s.keyCodeToStr(e)},e.fromUserSettings=function(e){return r.strToKeyCode(e)||s.strToKeyCode(e)},e.toElectronAccelerator=function(e){if(e>=93&&e<=108)return null;switch(e){case 16:return"Up";case 18:return"Down";case 15:return"Left";case 17:return"Right"}return o.keyCodeToStr(e)}}(p||(p={}))},34670:function(e,t,i){"use strict";i.d(t,{X4:function(){return s},jC:function(){return a},xo:function(){return r}});var n=i(89982);class o{constructor(e,t,i=t){this.modifierLabels=[null],this.modifierLabels[2]=e,this.modifierLabels[1]=t,this.modifierLabels[3]=i}toLabel(e,t,i){if(0===t.length)return null;const n=[];for(let o=0,r=t.length;o>>0,n=(4294901760&e)>>>16;return new a(0!==n?[r(i,t),r(n,t)]:[r(i,t)])}function r(e,t){const i=!!(2048&e),n=!!(256&e);return new s(2===t?n:i,!!(1024&e),!!(512&e),2===t?i:n,255&e)}class s{constructor(e,t,i,n,o){this.ctrlKey=e,this.shiftKey=t,this.altKey=i,this.metaKey=n,this.keyCode=o}equals(e){return this.ctrlKey===e.ctrlKey&&this.shiftKey===e.shiftKey&&this.altKey===e.altKey&&this.metaKey===e.metaKey&&this.keyCode===e.keyCode}isModifierKey(){return 0===this.keyCode||5===this.keyCode||57===this.keyCode||6===this.keyCode||4===this.keyCode}toChord(){return new a([this])}isDuplicateModifierCase(){return this.ctrlKey&&5===this.keyCode||this.shiftKey&&4===this.keyCode||this.altKey&&6===this.keyCode||this.metaKey&&57===this.keyCode}}class a{constructor(e){if(0===e.length)throw(0,n.b1)("parts");this.parts=e}}class l{constructor(e,t,i,n,o,r){this.ctrlKey=e,this.shiftKey=t,this.altKey=i,this.metaKey=n,this.keyLabel=o,this.keyAriaLabel=r}}class c{}},70722:function(e,t,i){"use strict";i.d(t,{D:function(){return c},p:function(){return l}});var n=i(56855),o=i(9734),r=i(6954),s=i(10804),a=i(39675);function l(e){if(!e)return;"string"==typeof e&&(e=a.o.file(e));const t=(0,s.EZ)(e)||(e.scheme===o.lg.file?e.fsPath:e.path);return r.ED&&(0,n.vY)(t)?c(t):t}function c(e,t){return(0,n.oP)(e,t)?e.charAt(0).toUpperCase()+e.slice(1):e}Object.create(null)},84305:function(e,t,i){"use strict";i.d(t,{o:function(){return n}});class n{constructor(e){this.executor=e,this._didRun=!1}getValue(){if(!this._didRun)try{this._value=this.executor()}catch(e){this._error=e}finally{this._didRun=!0}if(this._error)throw this._error;return this._value}get rawValue(){return this._value}}},4004:function(e,t,i){"use strict";i.d(t,{B9:function(){return l},F8:function(){return c},JT:function(){return h},Jz:function(){return m},OF:function(){return d},SL:function(){return u},Wf:function(){return a},XK:function(){return g},dk:function(){return r},dt:function(){return p}});var n=i(58143),o=i(44780);function r(e){return e}class s extends Error{constructor(e){super(`Encountered errors while disposing of store. Errors: [${e.join(", ")}]`),this.errors=e}}function a(e){return"function"==typeof e.dispose&&0===e.dispose.length}function l(e){if(o.$.is(e)){let t=[];for(const i of e)if(i)try{i.dispose()}catch(e){t.push(e)}if(1===t.length)throw t[0];if(t.length>1)throw new s(t);return Array.isArray(e)?[]:e}if(e)return e.dispose(),e}function c(...e){const t=d((()=>l(e)));return t}function d(e){const t={dispose:(0,n.I)((()=>{e()}))};return t}class u{constructor(){this._toDispose=new Set,this._isDisposed=!1}dispose(){this._isDisposed||(this._isDisposed=!0,this.clear())}get isDisposed(){return this._isDisposed}clear(){try{l(this._toDispose.values())}finally{this._toDispose.clear()}}add(e){if(!e)return e;if(e===this)throw new Error("Cannot register a disposable on itself!");return this._isDisposed?u.DISABLE_DISPOSED_WARNING||console.warn(new Error("Trying to add a disposable to a DisposableStore that has already been disposed of. The added object will be leaked!").stack):this._toDispose.add(e),e}}u.DISABLE_DISPOSED_WARNING=!1;class h{constructor(){this._store=new u,this._store}dispose(){this._store.dispose()}_register(e){if(e===this)throw new Error("Cannot register a disposable on itself!");return this._store.add(e)}}h.None=Object.freeze({dispose(){}});class g{constructor(){this._isDisposed=!1}get value(){return this._isDisposed?void 0:this._value}set value(e){var t;this._isDisposed||e===this._value||(null===(t=this._value)||void 0===t||t.dispose(),this._value=e)}clear(){this.value=void 0}dispose(){var e;this._isDisposed=!0,null===(e=this._value)||void 0===e||e.dispose(),this._value=void 0}clearAndLeak(){const e=this._value;return this._value=void 0,e}}class p{constructor(){this.dispose=()=>{},this.unset=()=>{},this.isset=()=>!1}set(e){let t=e;return this.unset=()=>t=void 0,this.isset=()=>void 0!==t,this.dispose=()=>{t&&(t(),t=void 0)},this}}class m{constructor(e){this.object=e}dispose(){}}},57512:function(e,t,i){"use strict";i.d(t,{S:function(){return o}});class n{constructor(e){this.element=e,this.next=n.Undefined,this.prev=n.Undefined}}n.Undefined=new n(void 0);class o{constructor(){this._first=n.Undefined,this._last=n.Undefined,this._size=0}get size(){return this._size}isEmpty(){return this._first===n.Undefined}clear(){let e=this._first;for(;e!==n.Undefined;){const t=e.next;e.prev=n.Undefined,e.next=n.Undefined,e=t}this._first=n.Undefined,this._last=n.Undefined,this._size=0}unshift(e){return this._insert(e,!1)}push(e){return this._insert(e,!0)}_insert(e,t){const i=new n(e);if(this._first===n.Undefined)this._first=i,this._last=i;else if(t){const e=this._last;this._last=i,i.prev=e,e.next=i}else{const e=this._first;this._first=i,i.next=e,e.prev=i}this._size+=1;let o=!1;return()=>{o||(o=!0,this._remove(i))}}shift(){if(this._first!==n.Undefined){const e=this._first.element;return this._remove(this._first),e}}pop(){if(this._last!==n.Undefined){const e=this._last.element;return this._remove(this._last),e}}_remove(e){if(e.prev!==n.Undefined&&e.next!==n.Undefined){const t=e.prev;t.next=e.next,e.next.prev=t}else e.prev===n.Undefined&&e.next===n.Undefined?(this._first=n.Undefined,this._last=n.Undefined):e.next===n.Undefined?(this._last=this._last.prev,this._last.next=n.Undefined):e.prev===n.Undefined&&(this._first=this._first.next,this._first.prev=n.Undefined);this._size-=1}*[Symbol.iterator](){let e=this._first;for(;e!==n.Undefined;)yield e.element,e=e.next}}},38455:function(e,t,i){"use strict";i.d(t,{Id:function(){return u},Y9:function(){return g},z6:function(){return m}});var n,o,r=i(18039);class s{constructor(){this._value="",this._pos=0}reset(e){return this._value=e,this._pos=0,this}next(){return this._pos+=1,this}hasNext(){return this._pos=0;t--,this._valueLen--){const e=this._value.charCodeAt(t);if(!(47===e||this._splitOnBackslash&&92===e))break}return this.next()}hasNext(){return this._to!1)){return new u(new c(e))}static forStrings(){return new u(new s)}static forConfigKeys(){return new u(new a)}clear(){this._root=void 0}set(e,t){const i=this._iter.reset(e);let n;this._root||(this._root=new d,this._root.segment=i.value());const o=[];for(n=this._root;;){const e=i.cmp(n.segment);if(e>0)n.left||(n.left=new d,n.left.segment=i.value()),o.push([-1,n]),n=n.left;else if(e<0)n.right||(n.right=new d,n.right.segment=i.value()),o.push([1,n]),n=n.right;else{if(!i.hasNext())break;i.next(),n.mid||(n.mid=new d,n.mid.segment=i.value()),o.push([0,n]),n=n.mid}}const r=n.value;n.value=t,n.key=e;for(let e=o.length-1;e>=0;e--){const t=o[e][1];t.updateHeight();const i=t.balanceFactor();if(i<-1||i>1){const i=o[e][0],n=o[e+1][0];if(1===i&&1===n)o[e][1]=t.rotateLeft();else if(-1===i&&-1===n)o[e][1]=t.rotateRight();else if(1===i&&-1===n)t.right=o[e+1][1]=o[e+1][1].rotateRight(),o[e][1]=t.rotateLeft();else{if(-1!==i||1!==n)throw new Error;t.left=o[e+1][1]=o[e+1][1].rotateLeft(),o[e][1]=t.rotateRight()}if(e>0)switch(o[e-1][0]){case-1:o[e-1][1].left=o[e][1];break;case 1:o[e-1][1].right=o[e][1];break;case 0:o[e-1][1].mid=o[e][1]}else this._root=o[0][1]}}return r}get(e){var t;return null===(t=this._getNode(e))||void 0===t?void 0:t.value}_getNode(e){const t=this._iter.reset(e);let i=this._root;for(;i;){const e=t.cmp(i.segment);if(e>0)i=i.left;else if(e<0)i=i.right;else{if(!t.hasNext())break;t.next(),i=i.mid}}return i}has(e){const t=this._getNode(e);return!(void 0===(null==t?void 0:t.value)&&void 0===(null==t?void 0:t.mid))}delete(e){return this._delete(e,!1)}deleteSuperstr(e){return this._delete(e,!0)}_delete(e,t){var i;const n=this._iter.reset(e),o=[];let r=this._root;for(;r;){const e=n.cmp(r.segment);if(e>0)o.push([-1,r]),r=r.left;else if(e<0)o.push([1,r]),r=r.right;else{if(!n.hasNext())break;n.next(),o.push([0,r]),r=r.mid}}if(r){if(t?(r.left=void 0,r.mid=void 0,r.right=void 0,r.height=1):(r.key=void 0,r.value=void 0),!r.mid&&!r.value)if(r.left&&r.right){const e=this._min(r.right),{key:t,value:i,segment:n}=e;this._delete(e.key,!1),r.key=t,r.value=i,r.segment=n}else{const e=null!==(i=r.left)&&void 0!==i?i:r.right;if(o.length>0){const[t,i]=o[o.length-1];switch(t){case-1:i.left=e;break;case 0:i.mid=e;break;case 1:i.right=e}}else this._root=e}for(let e=o.length-1;e>=0;e--){const t=o[e][1];t.updateHeight();const i=t.balanceFactor();if(i>1?(t.right.balanceFactor()>=0||(t.right=t.right.rotateRight()),o[e][1]=t.rotateLeft()):i<-1&&(t.left.balanceFactor()<=0||(t.left=t.left.rotateLeft()),o[e][1]=t.rotateRight()),e>0)switch(o[e-1][0]){case-1:o[e-1][1].left=o[e][1];break;case 1:o[e-1][1].right=o[e][1];break;case 0:o[e-1][1].mid=o[e][1]}else this._root=o[0][1]}}}_min(e){for(;e.left;)e=e.left;return e}findSubstr(e){const t=this._iter.reset(e);let i,n=this._root;for(;n;){const e=t.cmp(n.segment);if(e>0)n=n.left;else if(e<0)n=n.right;else{if(!t.hasNext())break;t.next(),i=n.value||i,n=n.mid}}return n&&n.value||i}findSuperstr(e){const t=this._iter.reset(e);let i=this._root;for(;i;){const e=t.cmp(i.segment);if(e>0)i=i.left;else if(e<0)i=i.right;else{if(!t.hasNext())return i.mid?this._entries(i.mid):void 0;t.next(),i=i.mid}}}forEach(e){for(const[t,i]of this)e(i,t)}*[Symbol.iterator](){yield*this._entries(this._root)}*_entries(e){e&&(e.left&&(yield*this._entries(e.left)),e.value&&(yield[e.key,e.value]),e.mid&&(yield*this._entries(e.mid)),e.right&&(yield*this._entries(e.right)))}}class h{constructor(e,t){this.uri=e,this.value=t}}class g{constructor(e,t){this[n]="ResourceMap",e instanceof g?(this.map=new Map(e.map),this.toKey=null!=t?t:g.defaultToKey):(this.map=new Map,this.toKey=null!=e?e:g.defaultToKey)}set(e,t){return this.map.set(this.toKey(e),new h(e,t)),this}get(e){var t;return null===(t=this.map.get(this.toKey(e)))||void 0===t?void 0:t.value}has(e){return this.map.has(this.toKey(e))}get size(){return this.map.size}clear(){this.map.clear()}delete(e){return this.map.delete(this.toKey(e))}forEach(e,t){void 0!==t&&(e=e.bind(t));for(let[t,i]of this.map)e(i.value,i.uri,this)}*values(){for(let e of this.map.values())yield e.value}*keys(){for(let e of this.map.values())yield e.uri}*entries(){for(let e of this.map.values())yield[e.uri,e.value]}*[(n=Symbol.toStringTag,Symbol.iterator)](){for(let[,e]of this.map)yield[e.uri,e.value]}}g.defaultToKey=e=>e.toString();class p{constructor(){this[o]="LinkedMap",this._map=new Map,this._head=void 0,this._tail=void 0,this._size=0,this._state=0}clear(){this._map.clear(),this._head=void 0,this._tail=void 0,this._size=0,this._state++}isEmpty(){return!this._head&&!this._tail}get size(){return this._size}get first(){var e;return null===(e=this._head)||void 0===e?void 0:e.value}get last(){var e;return null===(e=this._tail)||void 0===e?void 0:e.value}has(e){return this._map.has(e)}get(e,t=0){const i=this._map.get(e);if(i)return 0!==t&&this.touch(i,t),i.value}set(e,t,i=0){let n=this._map.get(e);if(n)n.value=t,0!==i&&this.touch(n,i);else{switch(n={key:e,value:t,next:void 0,previous:void 0},i){case 0:case 2:default:this.addItemLast(n);break;case 1:this.addItemFirst(n)}this._map.set(e,n),this._size++}return this}delete(e){return!!this.remove(e)}remove(e){const t=this._map.get(e);if(t)return this._map.delete(e),this.removeItem(t),this._size--,t.value}shift(){if(!this._head&&!this._tail)return;if(!this._head||!this._tail)throw new Error("Invalid list");const e=this._head;return this._map.delete(e.key),this.removeItem(e),this._size--,e.value}forEach(e,t){const i=this._state;let n=this._head;for(;n;){if(t?e.bind(t)(n.value,n.key,this):e(n.value,n.key,this),this._state!==i)throw new Error("LinkedMap got modified during iteration.");n=n.next}}keys(){const e=this,t=this._state;let i=this._head;const n={[Symbol.iterator]:()=>n,next(){if(e._state!==t)throw new Error("LinkedMap got modified during iteration.");if(i){const e={value:i.key,done:!1};return i=i.next,e}return{value:void 0,done:!0}}};return n}values(){const e=this,t=this._state;let i=this._head;const n={[Symbol.iterator]:()=>n,next(){if(e._state!==t)throw new Error("LinkedMap got modified during iteration.");if(i){const e={value:i.value,done:!1};return i=i.next,e}return{value:void 0,done:!0}}};return n}entries(){const e=this,t=this._state;let i=this._head;const n={[Symbol.iterator]:()=>n,next(){if(e._state!==t)throw new Error("LinkedMap got modified during iteration.");if(i){const e={value:[i.key,i.value],done:!1};return i=i.next,e}return{value:void 0,done:!0}}};return n}[(o=Symbol.toStringTag,Symbol.iterator)](){return this.entries()}trimOld(e){if(e>=this.size)return;if(0===e)return void this.clear();let t=this._head,i=this.size;for(;t&&i>e;)this._map.delete(t.key),t=t.next,i--;this._head=t,this._size=i,t&&(t.previous=void 0),this._state++}addItemFirst(e){if(this._head||this._tail){if(!this._head)throw new Error("Invalid list");e.next=this._head,this._head.previous=e}else this._tail=e;this._head=e,this._state++}addItemLast(e){if(this._head||this._tail){if(!this._tail)throw new Error("Invalid list");e.previous=this._tail,this._tail.next=e}else this._head=e;this._tail=e,this._state++}removeItem(e){if(e===this._head&&e===this._tail)this._head=void 0,this._tail=void 0;else if(e===this._head){if(!e.next)throw new Error("Invalid list");e.next.previous=void 0,this._head=e.next}else if(e===this._tail){if(!e.previous)throw new Error("Invalid list");e.previous.next=void 0,this._tail=e.previous}else{const t=e.next,i=e.previous;if(!t||!i)throw new Error("Invalid list");t.previous=i,i.next=t}e.next=void 0,e.previous=void 0,this._state++}touch(e,t){if(!this._head||!this._tail)throw new Error("Invalid list");if(1===t||2===t)if(1===t){if(e===this._head)return;const t=e.next,i=e.previous;e===this._tail?(i.next=void 0,this._tail=i):(t.previous=i,i.next=t),e.previous=void 0,e.next=this._head,this._head.previous=e,this._head=e,this._state++}else if(2===t){if(e===this._tail)return;const t=e.next,i=e.previous;e===this._head?(t.previous=void 0,this._head=t):(t.previous=i,i.next=t),e.next=void 0,e.previous=this._tail,this._tail.next=e,this._tail=e,this._state++}}toJSON(){const e=[];return this.forEach(((t,i)=>{e.push([i,t])})),e}fromJSON(e){this.clear();for(const[t,i]of e)this.set(t,i)}}class m extends p{constructor(e,t=1){super(),this._limit=e,this._ratio=Math.min(Math.max(0,t),1)}get limit(){return this._limit}set limit(e){this._limit=e,this.checkTrim()}get(e,t=2){return super.get(e,t)}peek(e){return super.get(e,0)}set(e,t){return super.set(e,t,2),this.checkTrim(),this}checkTrim(){this.size>this._limit&&this.trimOld(Math.round(this._limit*this._ratio))}}},60491:function(e,t,i){"use strict";i.d(t,{Q:function(){return r}});var n=i(75527),o=i(39675);function r(e){let t=JSON.parse(e);return t=s(t),t}function s(e,t=0){if(!e||t>200)return e;if("object"==typeof e){switch(e.$mid){case 1:return o.o.revive(e);case 2:return new RegExp(e.source,e.flags);case 14:return new Date(e.source)}if(e instanceof n.KN||e instanceof Uint8Array)return e;if(Array.isArray(e))for(let i=0;i{e[i]&&"object"==typeof e[i]?t[i]=o(e[i]):t[i]=e[i]})),t}function r(e){if(!e||"object"!=typeof e)return e;const t=[e];for(;t.length>0;){const e=t.shift();Object.freeze(e);for(const i in e)if(s.call(e,i)){const n=e[i];"object"!=typeof n||Object.isFrozen(n)||t.push(n)}}return e}const s=Object.prototype.hasOwnProperty;function a(e,t){return l(e,t,new Set)}function l(e,t,i){if((0,n.Jp)(e))return e;const o=t(e);if(void 0!==o)return o;if((0,n.kJ)(e)){const n=[];for(const o of e)n.push(l(o,t,i));return n}if((0,n.Kn)(e)){if(i.has(e))throw new Error("Cannot clone recursive data-structure");i.add(e);const n={};for(let o in e)s.call(e,o)&&(n[o]=l(e[o],t,i));return i.delete(e),n}return e}function c(e,t,i=!0){return(0,n.Kn)(e)?((0,n.Kn)(t)&&Object.keys(t).forEach((o=>{o in e?i&&((0,n.Kn)(e[o])&&(0,n.Kn)(t[o])?c(e[o],t[o],i):e[o]=t[o]):e[o]=t[o]})),e):t}function d(e,t){if(e===t)return!0;if(null==e||null==t)return!1;if(typeof e!=typeof t)return!1;if("object"!=typeof e)return!1;if(Array.isArray(e)!==Array.isArray(t))return!1;let i,n;if(Array.isArray(e)){if(e.length!==t.length)return!1;for(i=0;ie.cwd()}}else o="undefined"!=typeof process?{get platform(){return process.platform},get arch(){return process.arch},get env(){return process.env},cwd:()=>process.env.VSCODE_CWD||process.cwd()}:{get platform(){return n.ED?"win32":n.dz?"darwin":"linux"},get arch(){},get env(){return{}},cwd:()=>"/"};const r=o.cwd,s=o.env,a=o.platform,l=46,c=47,d=92,u=58;class h extends Error{constructor(e,t,i){let n;"string"==typeof t&&0===t.indexOf("not ")?(n="must not be",t=t.replace(/^not /,"")):n="must be";const o=-1!==e.indexOf(".")?"property":"argument";let r=`The "${e}" ${o} ${n} of type ${t}`;r+=". Received type "+typeof i,super(r),this.code="ERR_INVALID_ARG_TYPE"}}function g(e,t){if("string"!=typeof e)throw new h(t,"string",e)}function p(e){return e===c||e===d}function m(e){return e===c}function f(e){return e>=65&&e<=90||e>=97&&e<=122}function _(e,t,i,n){let o="",r=0,s=-1,a=0,d=0;for(let u=0;u<=e.length;++u){if(u2){const e=o.lastIndexOf(i);-1===e?(o="",r=0):(o=o.slice(0,e),r=o.length-1-o.lastIndexOf(i)),s=u,a=0;continue}if(0!==o.length){o="",r=0,s=u,a=0;continue}}t&&(o+=o.length>0?`${i}..`:"..",r=2)}else o.length>0?o+=`${i}${e.slice(s+1,u)}`:o=e.slice(s+1,u),r=u-s-1;s=u,a=0}else d===l&&-1!==a?++a:a=-1}return o}function b(e,t){if(null===t||"object"!=typeof t)throw new h("pathObject","Object",t);const i=t.dir||t.root,n=t.base||`${t.name||""}${t.ext||""}`;return i?i===t.root?`${i}${n}`:`${i}${e}${n}`:n}const v={resolve(...e){let t="",i="",n=!1;for(let o=e.length-1;o>=-1;o--){let a;if(o>=0){if(a=e[o],g(a,"path"),0===a.length)continue}else 0===t.length?a=r():(a=s[`=${t}`]||r(),(void 0===a||a.slice(0,2).toLowerCase()!==t.toLowerCase()&&a.charCodeAt(2)===d)&&(a=`${t}\\`));const l=a.length;let c=0,h="",m=!1;const _=a.charCodeAt(0);if(1===l)p(_)&&(c=1,m=!0);else if(p(_))if(m=!0,p(a.charCodeAt(1))){let e=2,t=e;for(;e2&&p(a.charCodeAt(2))&&(m=!0,c=3));if(h.length>0)if(t.length>0){if(h.toLowerCase()!==t.toLowerCase())continue}else t=h;if(n){if(t.length>0)break}else if(i=`${a.slice(c)}\\${i}`,n=m,m&&t.length>0)break}return i=_(i,!n,"\\",p),n?`${t}\\${i}`:`${t}${i}`||"."},normalize(e){g(e,"path");const t=e.length;if(0===t)return".";let i,n=0,o=!1;const r=e.charCodeAt(0);if(1===t)return m(r)?"\\":e;if(p(r))if(o=!0,p(e.charCodeAt(1))){let o=2,r=o;for(;o2&&p(e.charCodeAt(2))&&(o=!0,n=3));let s=n0&&p(e.charCodeAt(t-1))&&(s+="\\"),void 0===i?o?`\\${s}`:s:o?`${i}\\${s}`:`${i}${s}`},isAbsolute(e){g(e,"path");const t=e.length;if(0===t)return!1;const i=e.charCodeAt(0);return p(i)||t>2&&f(i)&&e.charCodeAt(1)===u&&p(e.charCodeAt(2))},join(...e){if(0===e.length)return".";let t,i;for(let n=0;n0&&(void 0===t?t=i=o:t+=`\\${o}`)}if(void 0===t)return".";let n=!0,o=0;if("string"==typeof i&&p(i.charCodeAt(0))){++o;const e=i.length;e>1&&p(i.charCodeAt(1))&&(++o,e>2&&(p(i.charCodeAt(2))?++o:n=!1))}if(n){for(;o=2&&(t=`\\${t.slice(o)}`)}return v.normalize(t)},relative(e,t){if(g(e,"from"),g(t,"to"),e===t)return"";const i=v.resolve(e),n=v.resolve(t);if(i===n)return"";if((e=i.toLowerCase())===(t=n.toLowerCase()))return"";let o=0;for(;oo&&e.charCodeAt(r-1)===d;)r--;const s=r-o;let a=0;for(;aa&&t.charCodeAt(l-1)===d;)l--;const c=l-a,u=su){if(t.charCodeAt(a+p)===d)return n.slice(a+p+1);if(2===p)return n.slice(a+p)}s>u&&(e.charCodeAt(o+p)===d?h=p:2===p&&(h=3)),-1===h&&(h=0)}let m="";for(p=o+h+1;p<=r;++p)p!==r&&e.charCodeAt(p)!==d||(m+=0===m.length?"..":"\\..");return a+=h,m.length>0?`${m}${n.slice(a,l)}`:(n.charCodeAt(a)===d&&++a,n.slice(a,l))},toNamespacedPath(e){if("string"!=typeof e)return e;if(0===e.length)return"";const t=v.resolve(e);if(t.length<=2)return e;if(t.charCodeAt(0)===d){if(t.charCodeAt(1)===d){const e=t.charCodeAt(2);if(63!==e&&e!==l)return`\\\\?\\UNC\\${t.slice(2)}`}}else if(f(t.charCodeAt(0))&&t.charCodeAt(1)===u&&t.charCodeAt(2)===d)return`\\\\?\\${t}`;return e},dirname(e){g(e,"path");const t=e.length;if(0===t)return".";let i=-1,n=0;const o=e.charCodeAt(0);if(1===t)return p(o)?e:".";if(p(o)){if(i=n=1,p(e.charCodeAt(1))){let o=2,r=o;for(;o2&&p(e.charCodeAt(2))?3:2,n=i);let r=-1,s=!0;for(let i=t-1;i>=n;--i)if(p(e.charCodeAt(i))){if(!s){r=i;break}}else s=!1;if(-1===r){if(-1===i)return".";r=i}return e.slice(0,r)},basename(e,t){void 0!==t&&g(t,"ext"),g(e,"path");let i,n=0,o=-1,r=!0;if(e.length>=2&&f(e.charCodeAt(0))&&e.charCodeAt(1)===u&&(n=2),void 0!==t&&t.length>0&&t.length<=e.length){if(t===e)return"";let s=t.length-1,a=-1;for(i=e.length-1;i>=n;--i){const l=e.charCodeAt(i);if(p(l)){if(!r){n=i+1;break}}else-1===a&&(r=!1,a=i+1),s>=0&&(l===t.charCodeAt(s)?-1==--s&&(o=i):(s=-1,o=a))}return n===o?o=a:-1===o&&(o=e.length),e.slice(n,o)}for(i=e.length-1;i>=n;--i)if(p(e.charCodeAt(i))){if(!r){n=i+1;break}}else-1===o&&(r=!1,o=i+1);return-1===o?"":e.slice(n,o)},extname(e){g(e,"path");let t=0,i=-1,n=0,o=-1,r=!0,s=0;e.length>=2&&e.charCodeAt(1)===u&&f(e.charCodeAt(0))&&(t=n=2);for(let a=e.length-1;a>=t;--a){const t=e.charCodeAt(a);if(p(t)){if(!r){n=a+1;break}}else-1===o&&(r=!1,o=a+1),t===l?-1===i?i=a:1!==s&&(s=1):-1!==i&&(s=-1)}return-1===i||-1===o||0===s||1===s&&i===o-1&&i===n+1?"":e.slice(i,o)},format:b.bind(null,"\\"),parse(e){g(e,"path");const t={root:"",dir:"",base:"",ext:"",name:""};if(0===e.length)return t;const i=e.length;let n=0,o=e.charCodeAt(0);if(1===i)return p(o)?(t.root=t.dir=e,t):(t.base=t.name=e,t);if(p(o)){if(n=1,p(e.charCodeAt(1))){let t=2,o=t;for(;t0&&(t.root=e.slice(0,n));let r=-1,s=n,a=-1,c=!0,d=e.length-1,h=0;for(;d>=n;--d)if(o=e.charCodeAt(d),p(o)){if(!c){s=d+1;break}}else-1===a&&(c=!1,a=d+1),o===l?-1===r?r=d:1!==h&&(h=1):-1!==r&&(h=-1);return-1!==a&&(-1===r||0===h||1===h&&r===a-1&&r===s+1?t.base=t.name=e.slice(s,a):(t.name=e.slice(s,r),t.base=e.slice(s,a),t.ext=e.slice(r,a))),t.dir=s>0&&s!==n?e.slice(0,s-1):t.root,t},sep:"\\",delimiter:";",win32:null,posix:null},C={resolve(...e){let t="",i=!1;for(let n=e.length-1;n>=-1&&!i;n--){const o=n>=0?e[n]:r();g(o,"path"),0!==o.length&&(t=`${o}/${t}`,i=o.charCodeAt(0)===c)}return t=_(t,!i,"/",m),i?`/${t}`:t.length>0?t:"."},normalize(e){if(g(e,"path"),0===e.length)return".";const t=e.charCodeAt(0)===c,i=e.charCodeAt(e.length-1)===c;return 0===(e=_(e,!t,"/",m)).length?t?"/":i?"./":".":(i&&(e+="/"),t?`/${e}`:e)},isAbsolute:e=>(g(e,"path"),e.length>0&&e.charCodeAt(0)===c),join(...e){if(0===e.length)return".";let t;for(let i=0;i0&&(void 0===t?t=n:t+=`/${n}`)}return void 0===t?".":C.normalize(t)},relative(e,t){if(g(e,"from"),g(t,"to"),e===t)return"";if((e=C.resolve(e))===(t=C.resolve(t)))return"";const i=e.length,n=i-1,o=t.length-1,r=nr){if(t.charCodeAt(1+a)===c)return t.slice(1+a+1);if(0===a)return t.slice(1+a)}else n>r&&(e.charCodeAt(1+a)===c?s=a:0===a&&(s=0));let l="";for(a=1+s+1;a<=i;++a)a!==i&&e.charCodeAt(a)!==c||(l+=0===l.length?"..":"/..");return`${l}${t.slice(1+s)}`},toNamespacedPath:e=>e,dirname(e){if(g(e,"path"),0===e.length)return".";const t=e.charCodeAt(0)===c;let i=-1,n=!0;for(let t=e.length-1;t>=1;--t)if(e.charCodeAt(t)===c){if(!n){i=t;break}}else n=!1;return-1===i?t?"/":".":t&&1===i?"//":e.slice(0,i)},basename(e,t){void 0!==t&&g(t,"ext"),g(e,"path");let i,n=0,o=-1,r=!0;if(void 0!==t&&t.length>0&&t.length<=e.length){if(t===e)return"";let s=t.length-1,a=-1;for(i=e.length-1;i>=0;--i){const l=e.charCodeAt(i);if(l===c){if(!r){n=i+1;break}}else-1===a&&(r=!1,a=i+1),s>=0&&(l===t.charCodeAt(s)?-1==--s&&(o=i):(s=-1,o=a))}return n===o?o=a:-1===o&&(o=e.length),e.slice(n,o)}for(i=e.length-1;i>=0;--i)if(e.charCodeAt(i)===c){if(!r){n=i+1;break}}else-1===o&&(r=!1,o=i+1);return-1===o?"":e.slice(n,o)},extname(e){g(e,"path");let t=-1,i=0,n=-1,o=!0,r=0;for(let s=e.length-1;s>=0;--s){const a=e.charCodeAt(s);if(a!==c)-1===n&&(o=!1,n=s+1),a===l?-1===t?t=s:1!==r&&(r=1):-1!==t&&(r=-1);else if(!o){i=s+1;break}}return-1===t||-1===n||0===r||1===r&&t===n-1&&t===i+1?"":e.slice(t,n)},format:b.bind(null,"/"),parse(e){g(e,"path");const t={root:"",dir:"",base:"",ext:"",name:""};if(0===e.length)return t;const i=e.charCodeAt(0)===c;let n;i?(t.root="/",n=1):n=0;let o=-1,r=0,s=-1,a=!0,d=e.length-1,u=0;for(;d>=n;--d){const t=e.charCodeAt(d);if(t!==c)-1===s&&(a=!1,s=d+1),t===l?-1===o?o=d:1!==u&&(u=1):-1!==o&&(u=-1);else if(!a){r=d+1;break}}if(-1!==s){const n=0===r&&i?1:r;-1===o||0===u||1===u&&o===s-1&&o===r+1?t.base=t.name=e.slice(n,s):(t.name=e.slice(n,o),t.base=e.slice(n,s),t.ext=e.slice(o,s))}return r>0?t.dir=e.slice(0,r-1):i&&(t.dir="/"),t},sep:"/",delimiter:":",win32:null,posix:null};C.win32=v.win32=v,C.posix=v.posix=C;const w="win32"===a?v.normalize:C.normalize,y="win32"===a?v.resolve:C.resolve,S="win32"===a?v.relative:C.relative,x="win32"===a?v.dirname:C.dirname,k="win32"===a?v.basename:C.basename,L="win32"===a?v.extname:C.extname,E="win32"===a?v.sep:C.sep},6954:function(e,t,i){"use strict";var n;i.d(t,{$L:function(){return E},ED:function(){return S},G6:function(){return W},IJ:function(){return k},OS:function(){return R},dK:function(){return T},dz:function(){return x},fn:function(){return A},gn:function(){return D},i7:function(){return F},li:function(){return b},n2:function(){return N},r:function(){return P},tY:function(){return L},un:function(){return V},vU:function(){return B}});const o="en";let r,s,a=!1,l=!1,c=!1,d=!1,u=!1,h=!1,g=!1,p=!1,m=!1,f=o,_=null;const b="object"==typeof self?self:"object"==typeof i.g?i.g:{};let v;void 0!==b.vscode&&void 0!==b.vscode.process?v=b.vscode.process:"undefined"!=typeof process&&(v=process);const C="string"==typeof(null===(n=null==v?void 0:v.versions)||void 0===n?void 0:n.electron),w=C&&"renderer"===(null==v?void 0:v.type);if("object"!=typeof navigator||w)if("object"==typeof v){a="win32"===v.platform,l="darwin"===v.platform,c="linux"===v.platform,d=c&&!!v.env.SNAP&&!!v.env.SNAP_REVISION,g=C,m=!!v.env.CI||!!v.env.BUILD_ARTIFACTSTAGINGDIRECTORY,r=o,f=o;const e=v.env.VSCODE_NLS_CONFIG;if(e)try{const t=JSON.parse(e),i=t.availableLanguages["*"];r=t.locale,f=i||o,_=t._translationsConfigFile}catch(e){}u=!0}else console.error("Unable to resolve platform.");else s=navigator.userAgent,a=s.indexOf("Windows")>=0,l=s.indexOf("Macintosh")>=0,p=(s.indexOf("Macintosh")>=0||s.indexOf("iPad")>=0||s.indexOf("iPhone")>=0)&&!!navigator.maxTouchPoints&&navigator.maxTouchPoints>0,c=s.indexOf("Linux")>=0,h=!0,r=navigator.language,f=r;let y=0;l?y=1:a?y=3:c&&(y=2);const S=a,x=l,k=c,L=u,E=h,N=h&&"function"==typeof b.importScripts,D=p,I=s,T=f,A=(()=>{if("function"==typeof b.postMessage&&!b.importScripts){let e=[];b.addEventListener("message",(t=>{if(t.data&&t.data.vscodeScheduleAsyncWork)for(let i=0,n=e.length;i{const n=++t;e.push({id:n,callback:i}),b.postMessage({vscodeScheduleAsyncWork:n},"*")}}return e=>setTimeout(e)})(),R=l||p?2:a?1:3;let M=!0,O=!1;function P(){if(!O){O=!0;const e=new Uint8Array(2);e[0]=1,e[1]=2;const t=new Uint16Array(e.buffer);M=513===t[0]}return M}const F=!!(I&&I.indexOf("Chrome")>=0),B=!!(I&&I.indexOf("Firefox")>=0),W=!!(!F&&I&&I.indexOf("Safari")>=0),V=!!(I&&I.indexOf("Edg/")>=0);I&&I.indexOf("Android")},14747:function(e,t,i){"use strict";var n;i.d(t,{e:function(){return n}}),function(e){function t(e,t){if(e.start>=t.end||t.start>=e.end)return{start:0,end:0};const i=Math.max(e.start,t.start),n=Math.min(e.end,t.end);return n-i<=0?{start:0,end:0}:{start:i,end:n}}function i(e){return e.end-e.start<=0}e.intersect=t,e.isEmpty=i,e.intersects=function(e,n){return!i(t(e,n))},e.relativeComplement=function(e,t){const n=[],o={start:e.start,end:Math.min(t.start,e.end)},r={start:Math.max(t.end,e.start),end:e.end};return i(o)||n.push(o),i(r)||n.push(r),n}}(n||(n={}))},10804:function(e,t,i){"use strict";i.d(t,{AH:function(){return b},DZ:function(){return m},EZ:function(){return p},Hx:function(){return g},SF:function(){return u},Vb:function(){return y},Vo:function(){return _},XX:function(){return f},Xy:function(){return h},i3:function(){return v},z_:function(){return c}});var n=i(56855),o=i(9734),r=i(14477),s=i(6954),a=i(18039),l=i(39675);function c(e){return(0,l.q)(e,!0)}class d{constructor(e){this._ignorePathCasing=e}compare(e,t,i=!1){return e===t?0:(0,a.qu)(this.getComparisonKey(e,i),this.getComparisonKey(t,i))}isEqual(e,t,i=!1){return e===t||!(!e||!t)&&this.getComparisonKey(e,i)===this.getComparisonKey(t,i)}getComparisonKey(e,t=!1){return e.with({path:this._ignorePathCasing(e)?e.path.toLowerCase():void 0,fragment:t?null:void 0}).toString()}isEqualOrParent(e,t,i=!1){if(e.scheme===t.scheme){if(e.scheme===o.lg.file)return n.KM(c(e),c(t),this._ignorePathCasing(e))&&e.query===t.query&&(i||e.fragment===t.fragment);if(C(e.authority,t.authority))return n.KM(e.path,t.path,this._ignorePathCasing(e),"/")&&e.query===t.query&&(i||e.fragment===t.fragment)}return!1}joinPath(e,...t){return l.o.joinPath(e,...t)}basenameOrAuthority(e){return p(e)||e.authority}basename(e){return r.KR.basename(e.path)}extname(e){return r.KR.extname(e.path)}dirname(e){if(0===e.path.length)return e;let t;return e.scheme===o.lg.file?t=l.o.file(r.XX(c(e))).path:(t=r.KR.dirname(e.path),e.authority&&t.length&&47!==t.charCodeAt(0)&&(console.error(`dirname("${e.toString})) resulted in a relative path`),t="/")),e.with({path:t})}normalizePath(e){if(!e.path.length)return e;let t;return t=e.scheme===o.lg.file?l.o.file(r.Fv(c(e))).path:r.KR.normalize(e.path),e.with({path:t})}relativePath(e,t){if(e.scheme!==t.scheme||!C(e.authority,t.authority))return;if(e.scheme===o.lg.file){const i=r.Gf(c(e),c(t));return s.ED?n.ej(i):i}let i=e.path||"/",a=t.path||"/";if(this._ignorePathCasing(e)){let e=0;for(const t=Math.min(i.length,a.length);en.yj(i).length&&i[i.length-1]===t}{const t=e.path;return t.length>1&&47===t.charCodeAt(t.length-1)&&!/^[a-zA-Z]:(\/$|\\$)/.test(e.fsPath)}}removeTrailingPathSeparator(e,t=r.ir){return w(e,t)?e.with({path:e.path.substr(0,e.path.length-1)}):e}addTrailingPathSeparator(e,t=r.ir){let i=!1;if(e.scheme===o.lg.file){const o=c(e);i=void 0!==o&&o.length===n.yj(o).length&&o[o.length-1]===t}else{t="/";const n=e.path;i=1===n.length&&47===n.charCodeAt(n.length-1)}return i||w(e,t)?e:e.with({path:e.path+"/"})}}const u=new d((()=>!1)),h=(new d((e=>e.scheme!==o.lg.file||!s.IJ)),new d((e=>!0)),u.isEqual.bind(u)),g=(u.isEqualOrParent.bind(u),u.getComparisonKey.bind(u),u.basenameOrAuthority.bind(u)),p=u.basename.bind(u),m=u.extname.bind(u),f=u.dirname.bind(u),_=u.joinPath.bind(u),b=u.normalizePath.bind(u),v=(u.relativePath.bind(u),u.resolvePath.bind(u)),C=(u.isAbsolutePath.bind(u),u.isEqualAuthority.bind(u)),w=u.hasTrailingPathSeparator.bind(u);var y;u.removeTrailingPathSeparator.bind(u),u.addTrailingPathSeparator.bind(u),function(e){e.META_DATA_LABEL="label",e.META_DATA_DESCRIPTION="description",e.META_DATA_SIZE="size",e.META_DATA_MIME="mime",e.parseMetaData=function(t){const i=new Map;t.path.substring(t.path.indexOf(";")+1,t.path.lastIndexOf(";")).split(";").forEach((e=>{const[t,n]=e.split(":");t&&n&&i.set(t,n)}));const n=t.path.substring(0,t.path.indexOf(";"));return n&&i.set(e.META_DATA_MIME,n),i}}(y||(y={}))},98729:function(e,t,i){"use strict";i.d(t,{Rm:function(){return s}});var n=i(46718),o=i(4004);class r{constructor(e,t,i,n,o,r,s){this._forceIntegerValues=e,this._scrollStateBrand=void 0,this._forceIntegerValues&&(t|=0,i|=0,n|=0,o|=0,r|=0,s|=0),this.rawScrollLeft=n,this.rawScrollTop=s,t<0&&(t=0),n+t>i&&(n=i-t),n<0&&(n=0),o<0&&(o=0),s+o>r&&(s=r-o),s<0&&(s=0),this.width=t,this.scrollWidth=i,this.scrollLeft=n,this.height=o,this.scrollHeight=r,this.scrollTop=s}equals(e){return this.rawScrollLeft===e.rawScrollLeft&&this.rawScrollTop===e.rawScrollTop&&this.width===e.width&&this.scrollWidth===e.scrollWidth&&this.scrollLeft===e.scrollLeft&&this.height===e.height&&this.scrollHeight===e.scrollHeight&&this.scrollTop===e.scrollTop}withScrollDimensions(e,t){return new r(this._forceIntegerValues,void 0!==e.width?e.width:this.width,void 0!==e.scrollWidth?e.scrollWidth:this.scrollWidth,t?this.rawScrollLeft:this.scrollLeft,void 0!==e.height?e.height:this.height,void 0!==e.scrollHeight?e.scrollHeight:this.scrollHeight,t?this.rawScrollTop:this.scrollTop)}withScrollPosition(e){return new r(this._forceIntegerValues,this.width,this.scrollWidth,void 0!==e.scrollLeft?e.scrollLeft:this.rawScrollLeft,this.height,this.scrollHeight,void 0!==e.scrollTop?e.scrollTop:this.rawScrollTop)}createScrollEvent(e,t){const i=this.width!==e.width,n=this.scrollWidth!==e.scrollWidth,o=this.scrollLeft!==e.scrollLeft,r=this.height!==e.height,s=this.scrollHeight!==e.scrollHeight,a=this.scrollTop!==e.scrollTop;return{inSmoothScrolling:t,oldWidth:e.width,oldScrollWidth:e.scrollWidth,oldScrollLeft:e.scrollLeft,width:this.width,scrollWidth:this.scrollWidth,scrollLeft:this.scrollLeft,oldHeight:e.height,oldScrollHeight:e.scrollHeight,oldScrollTop:e.scrollTop,height:this.height,scrollHeight:this.scrollHeight,scrollTop:this.scrollTop,widthChanged:i,scrollWidthChanged:n,scrollLeftChanged:o,heightChanged:r,scrollHeightChanged:s,scrollTopChanged:a}}}class s extends o.JT{constructor(e){super(),this._scrollableBrand=void 0,this._onScroll=this._register(new n.Q5),this.onScroll=this._onScroll.event,this._smoothScrollDuration=e.smoothScrollDuration,this._scheduleAtNextAnimationFrame=e.scheduleAtNextAnimationFrame,this._state=new r(e.forceIntegerValues,0,0,0,0,0,0),this._smoothScrolling=null}dispose(){this._smoothScrolling&&(this._smoothScrolling.dispose(),this._smoothScrolling=null),super.dispose()}setSmoothScrollDuration(e){this._smoothScrollDuration=e}validateScrollPosition(e){return this._state.withScrollPosition(e)}getScrollDimensions(){return this._state}setScrollDimensions(e,t){const i=this._state.withScrollDimensions(e,t);this._setState(i,Boolean(this._smoothScrolling)),this._smoothScrolling&&this._smoothScrolling.acceptScrollDimensions(this._state)}getFutureScrollPosition(){return this._smoothScrolling?this._smoothScrolling.to:this._state}getCurrentScrollPosition(){return this._state}setScrollPositionNow(e){const t=this._state.withScrollPosition(e);this._smoothScrolling&&(this._smoothScrolling.dispose(),this._smoothScrolling=null),this._setState(t,!1)}setScrollPositionSmooth(e,t){if(0===this._smoothScrollDuration)return this.setScrollPositionNow(e);if(this._smoothScrolling){e={scrollLeft:void 0===e.scrollLeft?this._smoothScrolling.to.scrollLeft:e.scrollLeft,scrollTop:void 0===e.scrollTop?this._smoothScrolling.to.scrollTop:e.scrollTop};const i=this._state.withScrollPosition(e);if(this._smoothScrolling.to.scrollLeft===i.scrollLeft&&this._smoothScrolling.to.scrollTop===i.scrollTop)return;let n;n=t?new c(this._smoothScrolling.from,i,this._smoothScrolling.startTime,this._smoothScrolling.duration):this._smoothScrolling.combine(this._state,i,this._smoothScrollDuration),this._smoothScrolling.dispose(),this._smoothScrolling=n}else{const t=this._state.withScrollPosition(e);this._smoothScrolling=c.start(this._state,t,this._smoothScrollDuration)}this._smoothScrolling.animationFrameDisposable=this._scheduleAtNextAnimationFrame((()=>{this._smoothScrolling&&(this._smoothScrolling.animationFrameDisposable=null,this._performSmoothScrolling())}))}_performSmoothScrolling(){if(!this._smoothScrolling)return;const e=this._smoothScrolling.tick(),t=this._state.withScrollPosition(e);return this._setState(t,!0),this._smoothScrolling?e.isDone?(this._smoothScrolling.dispose(),void(this._smoothScrolling=null)):void(this._smoothScrolling.animationFrameDisposable=this._scheduleAtNextAnimationFrame((()=>{this._smoothScrolling&&(this._smoothScrolling.animationFrameDisposable=null,this._performSmoothScrolling())}))):void 0}_setState(e,t){const i=this._state;i.equals(e)||(this._state=e,this._onScroll.fire(this._state.createScrollEvent(i,t)))}}class a{constructor(e,t,i){this.scrollLeft=e,this.scrollTop=t,this.isDone=i}}function l(e,t){const i=t-e;return function(t){return e+i*(1-(n=1-t,Math.pow(n,3)));var n}}class c{constructor(e,t,i,n){this.from=e,this.to=t,this.duration=n,this.startTime=i,this.animationFrameDisposable=null,this._initAnimations()}_initAnimations(){this.scrollLeft=this._initAnimation(this.from.scrollLeft,this.to.scrollLeft,this.to.width),this.scrollTop=this._initAnimation(this.from.scrollTop,this.to.scrollTop,this.to.height)}_initAnimation(e,t,i){if(Math.abs(e-t)>2.5*i){let s,a;return e=t.length?e:t[n]}))}function l(e){return e.replace(/[<>&]/g,(function(e){switch(e){case"<":return"<";case">":return">";case"&":return"&";default:return e}}))}function c(e){return e.replace(/[\\\{\}\*\+\?\|\^\$\.\[\]\(\)]/g,"\\$&")}function d(e,t=" "){return h(u(e,t),t)}function u(e,t){if(!e||!t)return e;const i=t.length;if(0===i||0===e.length)return e;let n=0;for(;e.indexOf(t,n)===n;)n+=i;return e.substring(n)}function h(e,t){if(!e||!t)return e;const i=t.length,n=e.length;if(0===i||0===n)return e;let o=n,r=-1;for(;r=e.lastIndexOf(t,o-1),-1!==r&&r+i===o;){if(0===r)return"";o=r}return e.substring(0,o)}function g(e){return e.replace(/[\-\\\{\}\+\?\|\^\$\.\,\[\]\(\)\#\s]/g,"\\$&").replace(/[\*]/g,".*")}function p(e){return e.replace(/\*/g,"")}function m(e,t,i={}){if(!e)throw new Error("Cannot create regex from empty string");t||(e=c(e)),i.wholeWord&&(/\B/.test(e.charAt(0))||(e="\\b"+e),/\B/.test(e.charAt(e.length-1))||(e+="\\b"));let n="";return i.global&&(n+="g"),i.matchCase||(n+="i"),i.multiline&&(n+="m"),i.unicode&&(n+="u"),new RegExp(e,n)}function f(e){return"^"!==e.source&&"^$"!==e.source&&"$"!==e.source&&"^\\s*$"!==e.source&&!(!e.exec("")||0!==e.lastIndex)}function _(e){return(e.global?"g":"")+(e.ignoreCase?"i":"")+(e.multiline?"m":"")+(e.unicode?"u":"")}function b(e){return e.split(/\r\n|\r|\n/)}function v(e){for(let t=0,i=e.length;t=0;i--){const t=e.charCodeAt(i);if(32!==t&&9!==t)return i}return-1}function y(e,t){return et?1:0}function S(e,t,i=0,n=e.length,o=0,r=t.length){for(;ir)return 1}const s=n-i,a=r-o;return sa?1:0}function x(e,t){return k(e,t,0,e.length,0,t.length)}function k(e,t,i=0,n=e.length,o=0,r=t.length){for(;i=128||a>=128)return S(e.toLowerCase(),t.toLowerCase(),i,n,o,r);L(s)&&(s-=32),L(a)&&(a-=32);const l=s-a;if(0!==l)return l}const s=n-i,a=r-o;return sa?1:0}function L(e){return e>=97&&e<=122}function E(e){return e>=65&&e<=90}function N(e,t){return e.length===t.length&&0===k(e,t)}function D(e,t){const i=t.length;return!(t.length>e.length)&&0===k(e,t,0,i)}function I(e,t){let i,n=Math.min(e.length,t.length);for(i=0;i1){const n=e.charCodeAt(t-2);if(A(n))return M(n,i)}return i}(this._str,this._offset);return this._offset-=e>=65536?2:1,e}nextCodePoint(){const e=O(this._str,this._len,this._offset);return this._offset+=e>=65536?2:1,e}eol(){return this._offset>=this._len}}class F{constructor(e,t=0){this._iterator=new P(e,t)}get offset(){return this._iterator.offset}nextGraphemeLength(){const e=ee.getInstance(),t=this._iterator,i=t.offset;let n=e.getGraphemeBreakType(t.nextCodePoint());for(;!t.eol();){const i=t.offset,o=e.getGraphemeBreakType(t.nextCodePoint());if(J(n,o)){t.setOffset(i);break}n=o}return t.offset-i}prevGraphemeLength(){const e=ee.getInstance(),t=this._iterator,i=t.offset;let n=e.getGraphemeBreakType(t.prevCodePoint());for(;t.offset>0;){const i=t.offset,o=e.getGraphemeBreakType(t.prevCodePoint());if(J(o,n)){t.setOffset(i);break}n=o}return i-t.offset}eol(){return this._iterator.eol()}}function B(e,t){return new F(e,t).nextGraphemeLength()}function W(e,t){return new F(e,t).prevGraphemeLength()}function V(e,t){t>0&&R(e.charCodeAt(t))&&t--;const i=t+B(e,t);return[i-W(e,i),i]}const H=/(?:[\u05BE\u05C0\u05C3\u05C6\u05D0-\u05F4\u0608\u060B\u060D\u061B-\u064A\u066D-\u066F\u0671-\u06D5\u06E5\u06E6\u06EE\u06EF\u06FA-\u0710\u0712-\u072F\u074D-\u07A5\u07B1-\u07EA\u07F4\u07F5\u07FA\u07FE-\u0815\u081A\u0824\u0828\u0830-\u0858\u085E-\u088E\u08A0-\u08C9\u200F\uFB1D\uFB1F-\uFB28\uFB2A-\uFD3D\uFD50-\uFDC7\uFDF0-\uFDFC\uFE70-\uFEFC]|\uD802[\uDC00-\uDD1B\uDD20-\uDE00\uDE10-\uDE35\uDE40-\uDEE4\uDEEB-\uDF35\uDF40-\uDFFF]|\uD803[\uDC00-\uDD23\uDE80-\uDEA9\uDEAD-\uDF45\uDF51-\uDF81\uDF86-\uDFF6]|\uD83A[\uDC00-\uDCCF\uDD00-\uDD43\uDD4B-\uDFFF]|\uD83B[\uDC00-\uDEBB])/;function z(e){return H.test(e)}const $=/^[\t\n\r\x20-\x7E]*$/;function U(e){return $.test(e)}const j=/[\u2028\u2029]/;function K(e){return j.test(e)}function q(e){return e>=11904&&e<=55215||e>=63744&&e<=64255||e>=65281&&e<=65374}function G(e){return e>=127462&&e<=127487||8986===e||8987===e||9200===e||9203===e||e>=9728&&e<=10175||11088===e||11093===e||e>=127744&&e<=128591||e>=128640&&e<=128764||e>=128992&&e<=129008||e>=129280&&e<=129535||e>=129648&&e<=129782}const Z=String.fromCharCode(65279);function Y(e){return!!(e&&e.length>0&&65279===e.charCodeAt(0))}function Q(e,t=!1){return!!e&&(t&&(e=e.replace(/\\./g,"")),e.toLowerCase()!==e)}function X(e){return(e%=52)<26?String.fromCharCode(97+e):String.fromCharCode(65+e-26)}function J(e,t){return 0===e?5!==t&&7!==t:!(2===e&&3===t||4!==e&&2!==e&&3!==e&&4!==t&&2!==t&&3!==t&&(8===e&&(8===t||9===t||11===t||12===t)||!(11!==e&&9!==e||9!==t&&10!==t)||(12===e||10===e)&&10===t||5===t||13===t||7===t||1===e||13===e&&14===t||6===e&&6===t))}class ee{constructor(){this._data=JSON.parse("[0,0,0,51229,51255,12,44061,44087,12,127462,127487,6,7083,7085,5,47645,47671,12,54813,54839,12,128678,128678,14,3270,3270,5,9919,9923,14,45853,45879,12,49437,49463,12,53021,53047,12,71216,71218,7,128398,128399,14,129360,129374,14,2519,2519,5,4448,4519,9,9742,9742,14,12336,12336,14,44957,44983,12,46749,46775,12,48541,48567,12,50333,50359,12,52125,52151,12,53917,53943,12,69888,69890,5,73018,73018,5,127990,127990,14,128558,128559,14,128759,128760,14,129653,129655,14,2027,2035,5,2891,2892,7,3761,3761,5,6683,6683,5,8293,8293,4,9825,9826,14,9999,9999,14,43452,43453,5,44509,44535,12,45405,45431,12,46301,46327,12,47197,47223,12,48093,48119,12,48989,49015,12,49885,49911,12,50781,50807,12,51677,51703,12,52573,52599,12,53469,53495,12,54365,54391,12,65279,65279,4,70471,70472,7,72145,72147,7,119173,119179,5,127799,127818,14,128240,128244,14,128512,128512,14,128652,128652,14,128721,128722,14,129292,129292,14,129445,129450,14,129734,129743,14,1476,1477,5,2366,2368,7,2750,2752,7,3076,3076,5,3415,3415,5,4141,4144,5,6109,6109,5,6964,6964,5,7394,7400,5,9197,9198,14,9770,9770,14,9877,9877,14,9968,9969,14,10084,10084,14,43052,43052,5,43713,43713,5,44285,44311,12,44733,44759,12,45181,45207,12,45629,45655,12,46077,46103,12,46525,46551,12,46973,46999,12,47421,47447,12,47869,47895,12,48317,48343,12,48765,48791,12,49213,49239,12,49661,49687,12,50109,50135,12,50557,50583,12,51005,51031,12,51453,51479,12,51901,51927,12,52349,52375,12,52797,52823,12,53245,53271,12,53693,53719,12,54141,54167,12,54589,54615,12,55037,55063,12,69506,69509,5,70191,70193,5,70841,70841,7,71463,71467,5,72330,72342,5,94031,94031,5,123628,123631,5,127763,127765,14,127941,127941,14,128043,128062,14,128302,128317,14,128465,128467,14,128539,128539,14,128640,128640,14,128662,128662,14,128703,128703,14,128745,128745,14,129004,129007,14,129329,129330,14,129402,129402,14,129483,129483,14,129686,129704,14,130048,131069,14,173,173,4,1757,1757,1,2200,2207,5,2434,2435,7,2631,2632,5,2817,2817,5,3008,3008,5,3201,3201,5,3387,3388,5,3542,3542,5,3902,3903,7,4190,4192,5,6002,6003,5,6439,6440,5,6765,6770,7,7019,7027,5,7154,7155,7,8205,8205,13,8505,8505,14,9654,9654,14,9757,9757,14,9792,9792,14,9852,9853,14,9890,9894,14,9937,9937,14,9981,9981,14,10035,10036,14,11035,11036,14,42654,42655,5,43346,43347,7,43587,43587,5,44006,44007,7,44173,44199,12,44397,44423,12,44621,44647,12,44845,44871,12,45069,45095,12,45293,45319,12,45517,45543,12,45741,45767,12,45965,45991,12,46189,46215,12,46413,46439,12,46637,46663,12,46861,46887,12,47085,47111,12,47309,47335,12,47533,47559,12,47757,47783,12,47981,48007,12,48205,48231,12,48429,48455,12,48653,48679,12,48877,48903,12,49101,49127,12,49325,49351,12,49549,49575,12,49773,49799,12,49997,50023,12,50221,50247,12,50445,50471,12,50669,50695,12,50893,50919,12,51117,51143,12,51341,51367,12,51565,51591,12,51789,51815,12,52013,52039,12,52237,52263,12,52461,52487,12,52685,52711,12,52909,52935,12,53133,53159,12,53357,53383,12,53581,53607,12,53805,53831,12,54029,54055,12,54253,54279,12,54477,54503,12,54701,54727,12,54925,54951,12,55149,55175,12,68101,68102,5,69762,69762,7,70067,70069,7,70371,70378,5,70720,70721,7,71087,71087,5,71341,71341,5,71995,71996,5,72249,72249,7,72850,72871,5,73109,73109,5,118576,118598,5,121505,121519,5,127245,127247,14,127568,127569,14,127777,127777,14,127872,127891,14,127956,127967,14,128015,128016,14,128110,128172,14,128259,128259,14,128367,128368,14,128424,128424,14,128488,128488,14,128530,128532,14,128550,128551,14,128566,128566,14,128647,128647,14,128656,128656,14,128667,128673,14,128691,128693,14,128715,128715,14,128728,128732,14,128752,128752,14,128765,128767,14,129096,129103,14,129311,129311,14,129344,129349,14,129394,129394,14,129413,129425,14,129466,129471,14,129511,129535,14,129664,129666,14,129719,129722,14,129760,129767,14,917536,917631,5,13,13,2,1160,1161,5,1564,1564,4,1807,1807,1,2085,2087,5,2307,2307,7,2382,2383,7,2497,2500,5,2563,2563,7,2677,2677,5,2763,2764,7,2879,2879,5,2914,2915,5,3021,3021,5,3142,3144,5,3263,3263,5,3285,3286,5,3398,3400,7,3530,3530,5,3633,3633,5,3864,3865,5,3974,3975,5,4155,4156,7,4229,4230,5,5909,5909,7,6078,6085,7,6277,6278,5,6451,6456,7,6744,6750,5,6846,6846,5,6972,6972,5,7074,7077,5,7146,7148,7,7222,7223,5,7416,7417,5,8234,8238,4,8417,8417,5,9000,9000,14,9203,9203,14,9730,9731,14,9748,9749,14,9762,9763,14,9776,9783,14,9800,9811,14,9831,9831,14,9872,9873,14,9882,9882,14,9900,9903,14,9929,9933,14,9941,9960,14,9974,9974,14,9989,9989,14,10006,10006,14,10062,10062,14,10160,10160,14,11647,11647,5,12953,12953,14,43019,43019,5,43232,43249,5,43443,43443,5,43567,43568,7,43696,43696,5,43765,43765,7,44013,44013,5,44117,44143,12,44229,44255,12,44341,44367,12,44453,44479,12,44565,44591,12,44677,44703,12,44789,44815,12,44901,44927,12,45013,45039,12,45125,45151,12,45237,45263,12,45349,45375,12,45461,45487,12,45573,45599,12,45685,45711,12,45797,45823,12,45909,45935,12,46021,46047,12,46133,46159,12,46245,46271,12,46357,46383,12,46469,46495,12,46581,46607,12,46693,46719,12,46805,46831,12,46917,46943,12,47029,47055,12,47141,47167,12,47253,47279,12,47365,47391,12,47477,47503,12,47589,47615,12,47701,47727,12,47813,47839,12,47925,47951,12,48037,48063,12,48149,48175,12,48261,48287,12,48373,48399,12,48485,48511,12,48597,48623,12,48709,48735,12,48821,48847,12,48933,48959,12,49045,49071,12,49157,49183,12,49269,49295,12,49381,49407,12,49493,49519,12,49605,49631,12,49717,49743,12,49829,49855,12,49941,49967,12,50053,50079,12,50165,50191,12,50277,50303,12,50389,50415,12,50501,50527,12,50613,50639,12,50725,50751,12,50837,50863,12,50949,50975,12,51061,51087,12,51173,51199,12,51285,51311,12,51397,51423,12,51509,51535,12,51621,51647,12,51733,51759,12,51845,51871,12,51957,51983,12,52069,52095,12,52181,52207,12,52293,52319,12,52405,52431,12,52517,52543,12,52629,52655,12,52741,52767,12,52853,52879,12,52965,52991,12,53077,53103,12,53189,53215,12,53301,53327,12,53413,53439,12,53525,53551,12,53637,53663,12,53749,53775,12,53861,53887,12,53973,53999,12,54085,54111,12,54197,54223,12,54309,54335,12,54421,54447,12,54533,54559,12,54645,54671,12,54757,54783,12,54869,54895,12,54981,55007,12,55093,55119,12,55243,55291,10,66045,66045,5,68325,68326,5,69688,69702,5,69817,69818,5,69957,69958,7,70089,70092,5,70198,70199,5,70462,70462,5,70502,70508,5,70750,70750,5,70846,70846,7,71100,71101,5,71230,71230,7,71351,71351,5,71737,71738,5,72000,72000,7,72160,72160,5,72273,72278,5,72752,72758,5,72882,72883,5,73031,73031,5,73461,73462,7,94192,94193,7,119149,119149,7,121403,121452,5,122915,122916,5,126980,126980,14,127358,127359,14,127535,127535,14,127759,127759,14,127771,127771,14,127792,127793,14,127825,127867,14,127897,127899,14,127945,127945,14,127985,127986,14,128000,128007,14,128021,128021,14,128066,128100,14,128184,128235,14,128249,128252,14,128266,128276,14,128335,128335,14,128379,128390,14,128407,128419,14,128444,128444,14,128481,128481,14,128499,128499,14,128526,128526,14,128536,128536,14,128543,128543,14,128556,128556,14,128564,128564,14,128577,128580,14,128643,128645,14,128649,128649,14,128654,128654,14,128660,128660,14,128664,128664,14,128675,128675,14,128686,128689,14,128695,128696,14,128705,128709,14,128717,128719,14,128725,128725,14,128736,128741,14,128747,128748,14,128755,128755,14,128762,128762,14,128981,128991,14,129009,129023,14,129160,129167,14,129296,129304,14,129320,129327,14,129340,129342,14,129356,129356,14,129388,129392,14,129399,129400,14,129404,129407,14,129432,129442,14,129454,129455,14,129473,129474,14,129485,129487,14,129648,129651,14,129659,129660,14,129671,129679,14,129709,129711,14,129728,129730,14,129751,129753,14,129776,129782,14,917505,917505,4,917760,917999,5,10,10,3,127,159,4,768,879,5,1471,1471,5,1536,1541,1,1648,1648,5,1767,1768,5,1840,1866,5,2070,2073,5,2137,2139,5,2274,2274,1,2363,2363,7,2377,2380,7,2402,2403,5,2494,2494,5,2507,2508,7,2558,2558,5,2622,2624,7,2641,2641,5,2691,2691,7,2759,2760,5,2786,2787,5,2876,2876,5,2881,2884,5,2901,2902,5,3006,3006,5,3014,3016,7,3072,3072,5,3134,3136,5,3157,3158,5,3260,3260,5,3266,3266,5,3274,3275,7,3328,3329,5,3391,3392,7,3405,3405,5,3457,3457,5,3536,3537,7,3551,3551,5,3636,3642,5,3764,3772,5,3895,3895,5,3967,3967,7,3993,4028,5,4146,4151,5,4182,4183,7,4226,4226,5,4253,4253,5,4957,4959,5,5940,5940,7,6070,6070,7,6087,6088,7,6158,6158,4,6432,6434,5,6448,6449,7,6679,6680,5,6742,6742,5,6754,6754,5,6783,6783,5,6912,6915,5,6966,6970,5,6978,6978,5,7042,7042,7,7080,7081,5,7143,7143,7,7150,7150,7,7212,7219,5,7380,7392,5,7412,7412,5,8203,8203,4,8232,8232,4,8265,8265,14,8400,8412,5,8421,8432,5,8617,8618,14,9167,9167,14,9200,9200,14,9410,9410,14,9723,9726,14,9733,9733,14,9745,9745,14,9752,9752,14,9760,9760,14,9766,9766,14,9774,9774,14,9786,9786,14,9794,9794,14,9823,9823,14,9828,9828,14,9833,9850,14,9855,9855,14,9875,9875,14,9880,9880,14,9885,9887,14,9896,9897,14,9906,9916,14,9926,9927,14,9935,9935,14,9939,9939,14,9962,9962,14,9972,9972,14,9978,9978,14,9986,9986,14,9997,9997,14,10002,10002,14,10017,10017,14,10055,10055,14,10071,10071,14,10133,10135,14,10548,10549,14,11093,11093,14,12330,12333,5,12441,12442,5,42608,42610,5,43010,43010,5,43045,43046,5,43188,43203,7,43302,43309,5,43392,43394,5,43446,43449,5,43493,43493,5,43571,43572,7,43597,43597,7,43703,43704,5,43756,43757,5,44003,44004,7,44009,44010,7,44033,44059,12,44089,44115,12,44145,44171,12,44201,44227,12,44257,44283,12,44313,44339,12,44369,44395,12,44425,44451,12,44481,44507,12,44537,44563,12,44593,44619,12,44649,44675,12,44705,44731,12,44761,44787,12,44817,44843,12,44873,44899,12,44929,44955,12,44985,45011,12,45041,45067,12,45097,45123,12,45153,45179,12,45209,45235,12,45265,45291,12,45321,45347,12,45377,45403,12,45433,45459,12,45489,45515,12,45545,45571,12,45601,45627,12,45657,45683,12,45713,45739,12,45769,45795,12,45825,45851,12,45881,45907,12,45937,45963,12,45993,46019,12,46049,46075,12,46105,46131,12,46161,46187,12,46217,46243,12,46273,46299,12,46329,46355,12,46385,46411,12,46441,46467,12,46497,46523,12,46553,46579,12,46609,46635,12,46665,46691,12,46721,46747,12,46777,46803,12,46833,46859,12,46889,46915,12,46945,46971,12,47001,47027,12,47057,47083,12,47113,47139,12,47169,47195,12,47225,47251,12,47281,47307,12,47337,47363,12,47393,47419,12,47449,47475,12,47505,47531,12,47561,47587,12,47617,47643,12,47673,47699,12,47729,47755,12,47785,47811,12,47841,47867,12,47897,47923,12,47953,47979,12,48009,48035,12,48065,48091,12,48121,48147,12,48177,48203,12,48233,48259,12,48289,48315,12,48345,48371,12,48401,48427,12,48457,48483,12,48513,48539,12,48569,48595,12,48625,48651,12,48681,48707,12,48737,48763,12,48793,48819,12,48849,48875,12,48905,48931,12,48961,48987,12,49017,49043,12,49073,49099,12,49129,49155,12,49185,49211,12,49241,49267,12,49297,49323,12,49353,49379,12,49409,49435,12,49465,49491,12,49521,49547,12,49577,49603,12,49633,49659,12,49689,49715,12,49745,49771,12,49801,49827,12,49857,49883,12,49913,49939,12,49969,49995,12,50025,50051,12,50081,50107,12,50137,50163,12,50193,50219,12,50249,50275,12,50305,50331,12,50361,50387,12,50417,50443,12,50473,50499,12,50529,50555,12,50585,50611,12,50641,50667,12,50697,50723,12,50753,50779,12,50809,50835,12,50865,50891,12,50921,50947,12,50977,51003,12,51033,51059,12,51089,51115,12,51145,51171,12,51201,51227,12,51257,51283,12,51313,51339,12,51369,51395,12,51425,51451,12,51481,51507,12,51537,51563,12,51593,51619,12,51649,51675,12,51705,51731,12,51761,51787,12,51817,51843,12,51873,51899,12,51929,51955,12,51985,52011,12,52041,52067,12,52097,52123,12,52153,52179,12,52209,52235,12,52265,52291,12,52321,52347,12,52377,52403,12,52433,52459,12,52489,52515,12,52545,52571,12,52601,52627,12,52657,52683,12,52713,52739,12,52769,52795,12,52825,52851,12,52881,52907,12,52937,52963,12,52993,53019,12,53049,53075,12,53105,53131,12,53161,53187,12,53217,53243,12,53273,53299,12,53329,53355,12,53385,53411,12,53441,53467,12,53497,53523,12,53553,53579,12,53609,53635,12,53665,53691,12,53721,53747,12,53777,53803,12,53833,53859,12,53889,53915,12,53945,53971,12,54001,54027,12,54057,54083,12,54113,54139,12,54169,54195,12,54225,54251,12,54281,54307,12,54337,54363,12,54393,54419,12,54449,54475,12,54505,54531,12,54561,54587,12,54617,54643,12,54673,54699,12,54729,54755,12,54785,54811,12,54841,54867,12,54897,54923,12,54953,54979,12,55009,55035,12,55065,55091,12,55121,55147,12,55177,55203,12,65024,65039,5,65520,65528,4,66422,66426,5,68152,68154,5,69291,69292,5,69633,69633,5,69747,69748,5,69811,69814,5,69826,69826,5,69932,69932,7,70016,70017,5,70079,70080,7,70095,70095,5,70196,70196,5,70367,70367,5,70402,70403,7,70464,70464,5,70487,70487,5,70709,70711,7,70725,70725,7,70833,70834,7,70843,70844,7,70849,70849,7,71090,71093,5,71103,71104,5,71227,71228,7,71339,71339,5,71344,71349,5,71458,71461,5,71727,71735,5,71985,71989,7,71998,71998,5,72002,72002,7,72154,72155,5,72193,72202,5,72251,72254,5,72281,72283,5,72344,72345,5,72766,72766,7,72874,72880,5,72885,72886,5,73023,73029,5,73104,73105,5,73111,73111,5,92912,92916,5,94095,94098,5,113824,113827,4,119142,119142,7,119155,119162,4,119362,119364,5,121476,121476,5,122888,122904,5,123184,123190,5,125252,125258,5,127183,127183,14,127340,127343,14,127377,127386,14,127491,127503,14,127548,127551,14,127744,127756,14,127761,127761,14,127769,127769,14,127773,127774,14,127780,127788,14,127796,127797,14,127820,127823,14,127869,127869,14,127894,127895,14,127902,127903,14,127943,127943,14,127947,127950,14,127972,127972,14,127988,127988,14,127992,127994,14,128009,128011,14,128019,128019,14,128023,128041,14,128064,128064,14,128102,128107,14,128174,128181,14,128238,128238,14,128246,128247,14,128254,128254,14,128264,128264,14,128278,128299,14,128329,128330,14,128348,128359,14,128371,128377,14,128392,128393,14,128401,128404,14,128421,128421,14,128433,128434,14,128450,128452,14,128476,128478,14,128483,128483,14,128495,128495,14,128506,128506,14,128519,128520,14,128528,128528,14,128534,128534,14,128538,128538,14,128540,128542,14,128544,128549,14,128552,128555,14,128557,128557,14,128560,128563,14,128565,128565,14,128567,128576,14,128581,128591,14,128641,128642,14,128646,128646,14,128648,128648,14,128650,128651,14,128653,128653,14,128655,128655,14,128657,128659,14,128661,128661,14,128663,128663,14,128665,128666,14,128674,128674,14,128676,128677,14,128679,128685,14,128690,128690,14,128694,128694,14,128697,128702,14,128704,128704,14,128710,128714,14,128716,128716,14,128720,128720,14,128723,128724,14,128726,128727,14,128733,128735,14,128742,128744,14,128746,128746,14,128749,128751,14,128753,128754,14,128756,128758,14,128761,128761,14,128763,128764,14,128884,128895,14,128992,129003,14,129008,129008,14,129036,129039,14,129114,129119,14,129198,129279,14,129293,129295,14,129305,129310,14,129312,129319,14,129328,129328,14,129331,129338,14,129343,129343,14,129351,129355,14,129357,129359,14,129375,129387,14,129393,129393,14,129395,129398,14,129401,129401,14,129403,129403,14,129408,129412,14,129426,129431,14,129443,129444,14,129451,129453,14,129456,129465,14,129472,129472,14,129475,129482,14,129484,129484,14,129488,129510,14,129536,129647,14,129652,129652,14,129656,129658,14,129661,129663,14,129667,129670,14,129680,129685,14,129705,129708,14,129712,129718,14,129723,129727,14,129731,129733,14,129744,129750,14,129754,129759,14,129768,129775,14,129783,129791,14,917504,917504,4,917506,917535,4,917632,917759,4,918000,921599,4,0,9,4,11,12,4,14,31,4,169,169,14,174,174,14,1155,1159,5,1425,1469,5,1473,1474,5,1479,1479,5,1552,1562,5,1611,1631,5,1750,1756,5,1759,1764,5,1770,1773,5,1809,1809,5,1958,1968,5,2045,2045,5,2075,2083,5,2089,2093,5,2192,2193,1,2250,2273,5,2275,2306,5,2362,2362,5,2364,2364,5,2369,2376,5,2381,2381,5,2385,2391,5,2433,2433,5,2492,2492,5,2495,2496,7,2503,2504,7,2509,2509,5,2530,2531,5,2561,2562,5,2620,2620,5,2625,2626,5,2635,2637,5,2672,2673,5,2689,2690,5,2748,2748,5,2753,2757,5,2761,2761,7,2765,2765,5,2810,2815,5,2818,2819,7,2878,2878,5,2880,2880,7,2887,2888,7,2893,2893,5,2903,2903,5,2946,2946,5,3007,3007,7,3009,3010,7,3018,3020,7,3031,3031,5,3073,3075,7,3132,3132,5,3137,3140,7,3146,3149,5,3170,3171,5,3202,3203,7,3262,3262,7,3264,3265,7,3267,3268,7,3271,3272,7,3276,3277,5,3298,3299,5,3330,3331,7,3390,3390,5,3393,3396,5,3402,3404,7,3406,3406,1,3426,3427,5,3458,3459,7,3535,3535,5,3538,3540,5,3544,3550,7,3570,3571,7,3635,3635,7,3655,3662,5,3763,3763,7,3784,3789,5,3893,3893,5,3897,3897,5,3953,3966,5,3968,3972,5,3981,3991,5,4038,4038,5,4145,4145,7,4153,4154,5,4157,4158,5,4184,4185,5,4209,4212,5,4228,4228,7,4237,4237,5,4352,4447,8,4520,4607,10,5906,5908,5,5938,5939,5,5970,5971,5,6068,6069,5,6071,6077,5,6086,6086,5,6089,6099,5,6155,6157,5,6159,6159,5,6313,6313,5,6435,6438,7,6441,6443,7,6450,6450,5,6457,6459,5,6681,6682,7,6741,6741,7,6743,6743,7,6752,6752,5,6757,6764,5,6771,6780,5,6832,6845,5,6847,6862,5,6916,6916,7,6965,6965,5,6971,6971,7,6973,6977,7,6979,6980,7,7040,7041,5,7073,7073,7,7078,7079,7,7082,7082,7,7142,7142,5,7144,7145,5,7149,7149,5,7151,7153,5,7204,7211,7,7220,7221,7,7376,7378,5,7393,7393,7,7405,7405,5,7415,7415,7,7616,7679,5,8204,8204,5,8206,8207,4,8233,8233,4,8252,8252,14,8288,8292,4,8294,8303,4,8413,8416,5,8418,8420,5,8482,8482,14,8596,8601,14,8986,8987,14,9096,9096,14,9193,9196,14,9199,9199,14,9201,9202,14,9208,9210,14,9642,9643,14,9664,9664,14,9728,9729,14,9732,9732,14,9735,9741,14,9743,9744,14,9746,9746,14,9750,9751,14,9753,9756,14,9758,9759,14,9761,9761,14,9764,9765,14,9767,9769,14,9771,9773,14,9775,9775,14,9784,9785,14,9787,9791,14,9793,9793,14,9795,9799,14,9812,9822,14,9824,9824,14,9827,9827,14,9829,9830,14,9832,9832,14,9851,9851,14,9854,9854,14,9856,9861,14,9874,9874,14,9876,9876,14,9878,9879,14,9881,9881,14,9883,9884,14,9888,9889,14,9895,9895,14,9898,9899,14,9904,9905,14,9917,9918,14,9924,9925,14,9928,9928,14,9934,9934,14,9936,9936,14,9938,9938,14,9940,9940,14,9961,9961,14,9963,9967,14,9970,9971,14,9973,9973,14,9975,9977,14,9979,9980,14,9982,9985,14,9987,9988,14,9992,9996,14,9998,9998,14,10000,10001,14,10004,10004,14,10013,10013,14,10024,10024,14,10052,10052,14,10060,10060,14,10067,10069,14,10083,10083,14,10085,10087,14,10145,10145,14,10175,10175,14,11013,11015,14,11088,11088,14,11503,11505,5,11744,11775,5,12334,12335,5,12349,12349,14,12951,12951,14,42607,42607,5,42612,42621,5,42736,42737,5,43014,43014,5,43043,43044,7,43047,43047,7,43136,43137,7,43204,43205,5,43263,43263,5,43335,43345,5,43360,43388,8,43395,43395,7,43444,43445,7,43450,43451,7,43454,43456,7,43561,43566,5,43569,43570,5,43573,43574,5,43596,43596,5,43644,43644,5,43698,43700,5,43710,43711,5,43755,43755,7,43758,43759,7,43766,43766,5,44005,44005,5,44008,44008,5,44012,44012,7,44032,44032,11,44060,44060,11,44088,44088,11,44116,44116,11,44144,44144,11,44172,44172,11,44200,44200,11,44228,44228,11,44256,44256,11,44284,44284,11,44312,44312,11,44340,44340,11,44368,44368,11,44396,44396,11,44424,44424,11,44452,44452,11,44480,44480,11,44508,44508,11,44536,44536,11,44564,44564,11,44592,44592,11,44620,44620,11,44648,44648,11,44676,44676,11,44704,44704,11,44732,44732,11,44760,44760,11,44788,44788,11,44816,44816,11,44844,44844,11,44872,44872,11,44900,44900,11,44928,44928,11,44956,44956,11,44984,44984,11,45012,45012,11,45040,45040,11,45068,45068,11,45096,45096,11,45124,45124,11,45152,45152,11,45180,45180,11,45208,45208,11,45236,45236,11,45264,45264,11,45292,45292,11,45320,45320,11,45348,45348,11,45376,45376,11,45404,45404,11,45432,45432,11,45460,45460,11,45488,45488,11,45516,45516,11,45544,45544,11,45572,45572,11,45600,45600,11,45628,45628,11,45656,45656,11,45684,45684,11,45712,45712,11,45740,45740,11,45768,45768,11,45796,45796,11,45824,45824,11,45852,45852,11,45880,45880,11,45908,45908,11,45936,45936,11,45964,45964,11,45992,45992,11,46020,46020,11,46048,46048,11,46076,46076,11,46104,46104,11,46132,46132,11,46160,46160,11,46188,46188,11,46216,46216,11,46244,46244,11,46272,46272,11,46300,46300,11,46328,46328,11,46356,46356,11,46384,46384,11,46412,46412,11,46440,46440,11,46468,46468,11,46496,46496,11,46524,46524,11,46552,46552,11,46580,46580,11,46608,46608,11,46636,46636,11,46664,46664,11,46692,46692,11,46720,46720,11,46748,46748,11,46776,46776,11,46804,46804,11,46832,46832,11,46860,46860,11,46888,46888,11,46916,46916,11,46944,46944,11,46972,46972,11,47000,47000,11,47028,47028,11,47056,47056,11,47084,47084,11,47112,47112,11,47140,47140,11,47168,47168,11,47196,47196,11,47224,47224,11,47252,47252,11,47280,47280,11,47308,47308,11,47336,47336,11,47364,47364,11,47392,47392,11,47420,47420,11,47448,47448,11,47476,47476,11,47504,47504,11,47532,47532,11,47560,47560,11,47588,47588,11,47616,47616,11,47644,47644,11,47672,47672,11,47700,47700,11,47728,47728,11,47756,47756,11,47784,47784,11,47812,47812,11,47840,47840,11,47868,47868,11,47896,47896,11,47924,47924,11,47952,47952,11,47980,47980,11,48008,48008,11,48036,48036,11,48064,48064,11,48092,48092,11,48120,48120,11,48148,48148,11,48176,48176,11,48204,48204,11,48232,48232,11,48260,48260,11,48288,48288,11,48316,48316,11,48344,48344,11,48372,48372,11,48400,48400,11,48428,48428,11,48456,48456,11,48484,48484,11,48512,48512,11,48540,48540,11,48568,48568,11,48596,48596,11,48624,48624,11,48652,48652,11,48680,48680,11,48708,48708,11,48736,48736,11,48764,48764,11,48792,48792,11,48820,48820,11,48848,48848,11,48876,48876,11,48904,48904,11,48932,48932,11,48960,48960,11,48988,48988,11,49016,49016,11,49044,49044,11,49072,49072,11,49100,49100,11,49128,49128,11,49156,49156,11,49184,49184,11,49212,49212,11,49240,49240,11,49268,49268,11,49296,49296,11,49324,49324,11,49352,49352,11,49380,49380,11,49408,49408,11,49436,49436,11,49464,49464,11,49492,49492,11,49520,49520,11,49548,49548,11,49576,49576,11,49604,49604,11,49632,49632,11,49660,49660,11,49688,49688,11,49716,49716,11,49744,49744,11,49772,49772,11,49800,49800,11,49828,49828,11,49856,49856,11,49884,49884,11,49912,49912,11,49940,49940,11,49968,49968,11,49996,49996,11,50024,50024,11,50052,50052,11,50080,50080,11,50108,50108,11,50136,50136,11,50164,50164,11,50192,50192,11,50220,50220,11,50248,50248,11,50276,50276,11,50304,50304,11,50332,50332,11,50360,50360,11,50388,50388,11,50416,50416,11,50444,50444,11,50472,50472,11,50500,50500,11,50528,50528,11,50556,50556,11,50584,50584,11,50612,50612,11,50640,50640,11,50668,50668,11,50696,50696,11,50724,50724,11,50752,50752,11,50780,50780,11,50808,50808,11,50836,50836,11,50864,50864,11,50892,50892,11,50920,50920,11,50948,50948,11,50976,50976,11,51004,51004,11,51032,51032,11,51060,51060,11,51088,51088,11,51116,51116,11,51144,51144,11,51172,51172,11,51200,51200,11,51228,51228,11,51256,51256,11,51284,51284,11,51312,51312,11,51340,51340,11,51368,51368,11,51396,51396,11,51424,51424,11,51452,51452,11,51480,51480,11,51508,51508,11,51536,51536,11,51564,51564,11,51592,51592,11,51620,51620,11,51648,51648,11,51676,51676,11,51704,51704,11,51732,51732,11,51760,51760,11,51788,51788,11,51816,51816,11,51844,51844,11,51872,51872,11,51900,51900,11,51928,51928,11,51956,51956,11,51984,51984,11,52012,52012,11,52040,52040,11,52068,52068,11,52096,52096,11,52124,52124,11,52152,52152,11,52180,52180,11,52208,52208,11,52236,52236,11,52264,52264,11,52292,52292,11,52320,52320,11,52348,52348,11,52376,52376,11,52404,52404,11,52432,52432,11,52460,52460,11,52488,52488,11,52516,52516,11,52544,52544,11,52572,52572,11,52600,52600,11,52628,52628,11,52656,52656,11,52684,52684,11,52712,52712,11,52740,52740,11,52768,52768,11,52796,52796,11,52824,52824,11,52852,52852,11,52880,52880,11,52908,52908,11,52936,52936,11,52964,52964,11,52992,52992,11,53020,53020,11,53048,53048,11,53076,53076,11,53104,53104,11,53132,53132,11,53160,53160,11,53188,53188,11,53216,53216,11,53244,53244,11,53272,53272,11,53300,53300,11,53328,53328,11,53356,53356,11,53384,53384,11,53412,53412,11,53440,53440,11,53468,53468,11,53496,53496,11,53524,53524,11,53552,53552,11,53580,53580,11,53608,53608,11,53636,53636,11,53664,53664,11,53692,53692,11,53720,53720,11,53748,53748,11,53776,53776,11,53804,53804,11,53832,53832,11,53860,53860,11,53888,53888,11,53916,53916,11,53944,53944,11,53972,53972,11,54000,54000,11,54028,54028,11,54056,54056,11,54084,54084,11,54112,54112,11,54140,54140,11,54168,54168,11,54196,54196,11,54224,54224,11,54252,54252,11,54280,54280,11,54308,54308,11,54336,54336,11,54364,54364,11,54392,54392,11,54420,54420,11,54448,54448,11,54476,54476,11,54504,54504,11,54532,54532,11,54560,54560,11,54588,54588,11,54616,54616,11,54644,54644,11,54672,54672,11,54700,54700,11,54728,54728,11,54756,54756,11,54784,54784,11,54812,54812,11,54840,54840,11,54868,54868,11,54896,54896,11,54924,54924,11,54952,54952,11,54980,54980,11,55008,55008,11,55036,55036,11,55064,55064,11,55092,55092,11,55120,55120,11,55148,55148,11,55176,55176,11,55216,55238,9,64286,64286,5,65056,65071,5,65438,65439,5,65529,65531,4,66272,66272,5,68097,68099,5,68108,68111,5,68159,68159,5,68900,68903,5,69446,69456,5,69632,69632,7,69634,69634,7,69744,69744,5,69759,69761,5,69808,69810,7,69815,69816,7,69821,69821,1,69837,69837,1,69927,69931,5,69933,69940,5,70003,70003,5,70018,70018,7,70070,70078,5,70082,70083,1,70094,70094,7,70188,70190,7,70194,70195,7,70197,70197,7,70206,70206,5,70368,70370,7,70400,70401,5,70459,70460,5,70463,70463,7,70465,70468,7,70475,70477,7,70498,70499,7,70512,70516,5,70712,70719,5,70722,70724,5,70726,70726,5,70832,70832,5,70835,70840,5,70842,70842,5,70845,70845,5,70847,70848,5,70850,70851,5,71088,71089,7,71096,71099,7,71102,71102,7,71132,71133,5,71219,71226,5,71229,71229,5,71231,71232,5,71340,71340,7,71342,71343,7,71350,71350,7,71453,71455,5,71462,71462,7,71724,71726,7,71736,71736,7,71984,71984,5,71991,71992,7,71997,71997,7,71999,71999,1,72001,72001,1,72003,72003,5,72148,72151,5,72156,72159,7,72164,72164,7,72243,72248,5,72250,72250,1,72263,72263,5,72279,72280,7,72324,72329,1,72343,72343,7,72751,72751,7,72760,72765,5,72767,72767,5,72873,72873,7,72881,72881,7,72884,72884,7,73009,73014,5,73020,73021,5,73030,73030,1,73098,73102,7,73107,73108,7,73110,73110,7,73459,73460,5,78896,78904,4,92976,92982,5,94033,94087,7,94180,94180,5,113821,113822,5,118528,118573,5,119141,119141,5,119143,119145,5,119150,119154,5,119163,119170,5,119210,119213,5,121344,121398,5,121461,121461,5,121499,121503,5,122880,122886,5,122907,122913,5,122918,122922,5,123566,123566,5,125136,125142,5,126976,126979,14,126981,127182,14,127184,127231,14,127279,127279,14,127344,127345,14,127374,127374,14,127405,127461,14,127489,127490,14,127514,127514,14,127538,127546,14,127561,127567,14,127570,127743,14,127757,127758,14,127760,127760,14,127762,127762,14,127766,127768,14,127770,127770,14,127772,127772,14,127775,127776,14,127778,127779,14,127789,127791,14,127794,127795,14,127798,127798,14,127819,127819,14,127824,127824,14,127868,127868,14,127870,127871,14,127892,127893,14,127896,127896,14,127900,127901,14,127904,127940,14,127942,127942,14,127944,127944,14,127946,127946,14,127951,127955,14,127968,127971,14,127973,127984,14,127987,127987,14,127989,127989,14,127991,127991,14,127995,127999,5,128008,128008,14,128012,128014,14,128017,128018,14,128020,128020,14,128022,128022,14,128042,128042,14,128063,128063,14,128065,128065,14,128101,128101,14,128108,128109,14,128173,128173,14,128182,128183,14,128236,128237,14,128239,128239,14,128245,128245,14,128248,128248,14,128253,128253,14,128255,128258,14,128260,128263,14,128265,128265,14,128277,128277,14,128300,128301,14,128326,128328,14,128331,128334,14,128336,128347,14,128360,128366,14,128369,128370,14,128378,128378,14,128391,128391,14,128394,128397,14,128400,128400,14,128405,128406,14,128420,128420,14,128422,128423,14,128425,128432,14,128435,128443,14,128445,128449,14,128453,128464,14,128468,128475,14,128479,128480,14,128482,128482,14,128484,128487,14,128489,128494,14,128496,128498,14,128500,128505,14,128507,128511,14,128513,128518,14,128521,128525,14,128527,128527,14,128529,128529,14,128533,128533,14,128535,128535,14,128537,128537,14]")}static getInstance(){return ee._INSTANCE||(ee._INSTANCE=new ee),ee._INSTANCE}getGraphemeBreakType(e){if(e<32)return 10===e?3:13===e?2:4;if(e<127)return 0;const t=this._data,i=t.length/3;let n=1;for(;n<=i;)if(et[3*n+1]))return t[3*n+2];n=2*n+1}return 0}}function te(e,t){if(0===e)return 0;const i=function(e,t){const i=new P(t,e);let n=i.prevCodePoint();for(;ie(n)||65039===n||8419===n;){if(0===i.offset)return;n=i.prevCodePoint()}if(!G(n))return;let o=i.offset;return o>0&&8205===i.prevCodePoint()&&(o=i.offset),o}(e,t);if(void 0!==i)return i;const n=new P(t,e);return n.prevCodePoint(),n.offset}function ie(e){return 127995<=e&&e<=127999}ee._INSTANCE=null;const ne=" ";class oe{constructor(e){this.confusableDictionary=e}static getInstance(e){return oe.cache.get(Array.from(e))}static getLocales(){return oe._locales.getValue()}isAmbiguous(e){return this.confusableDictionary.has(e)}getPrimaryConfusable(e){return this.confusableDictionary.get(e)}getConfusableCodePoints(){return new Set(this.confusableDictionary.keys())}}n=oe,oe.ambiguousCharacterData=new o.o((()=>JSON.parse('{"_common":[8232,32,8233,32,5760,32,8192,32,8193,32,8194,32,8195,32,8196,32,8197,32,8198,32,8200,32,8201,32,8202,32,8287,32,8199,32,8239,32,2042,95,65101,95,65102,95,65103,95,8208,45,8209,45,8210,45,65112,45,1748,45,8259,45,727,45,8722,45,10134,45,11450,45,1549,44,1643,44,8218,44,184,44,42233,44,894,59,2307,58,2691,58,1417,58,1795,58,1796,58,5868,58,65072,58,6147,58,6153,58,8282,58,1475,58,760,58,42889,58,8758,58,720,58,42237,58,451,33,11601,33,660,63,577,63,2429,63,5038,63,42731,63,119149,46,8228,46,1793,46,1794,46,42510,46,68176,46,1632,46,1776,46,42232,46,1373,96,65287,96,8219,96,8242,96,1370,96,1523,96,8175,96,65344,96,900,96,8189,96,8125,96,8127,96,8190,96,697,96,884,96,712,96,714,96,715,96,756,96,699,96,701,96,700,96,702,96,42892,96,1497,96,2036,96,2037,96,5194,96,5836,96,94033,96,94034,96,65339,91,10088,40,10098,40,12308,40,64830,40,65341,93,10089,41,10099,41,12309,41,64831,41,10100,123,119060,123,10101,125,65342,94,8270,42,1645,42,8727,42,66335,42,5941,47,8257,47,8725,47,8260,47,9585,47,10187,47,10744,47,119354,47,12755,47,12339,47,11462,47,20031,47,12035,47,65340,92,65128,92,8726,92,10189,92,10741,92,10745,92,119311,92,119355,92,12756,92,20022,92,12034,92,42872,38,708,94,710,94,5869,43,10133,43,66203,43,8249,60,10094,60,706,60,119350,60,5176,60,5810,60,5120,61,11840,61,12448,61,42239,61,8250,62,10095,62,707,62,119351,62,5171,62,94015,62,8275,126,732,126,8128,126,8764,126,65372,124,65293,45,120784,50,120794,50,120804,50,120814,50,120824,50,130034,50,42842,50,423,50,1000,50,42564,50,5311,50,42735,50,119302,51,120785,51,120795,51,120805,51,120815,51,120825,51,130035,51,42923,51,540,51,439,51,42858,51,11468,51,1248,51,94011,51,71882,51,120786,52,120796,52,120806,52,120816,52,120826,52,130036,52,5070,52,71855,52,120787,53,120797,53,120807,53,120817,53,120827,53,130037,53,444,53,71867,53,120788,54,120798,54,120808,54,120818,54,120828,54,130038,54,11474,54,5102,54,71893,54,119314,55,120789,55,120799,55,120809,55,120819,55,120829,55,130039,55,66770,55,71878,55,2819,56,2538,56,2666,56,125131,56,120790,56,120800,56,120810,56,120820,56,120830,56,130040,56,547,56,546,56,66330,56,2663,57,2920,57,2541,57,3437,57,120791,57,120801,57,120811,57,120821,57,120831,57,130041,57,42862,57,11466,57,71884,57,71852,57,71894,57,9082,97,65345,97,119834,97,119886,97,119938,97,119990,97,120042,97,120094,97,120146,97,120198,97,120250,97,120302,97,120354,97,120406,97,120458,97,593,97,945,97,120514,97,120572,97,120630,97,120688,97,120746,97,65313,65,119808,65,119860,65,119912,65,119964,65,120016,65,120068,65,120120,65,120172,65,120224,65,120276,65,120328,65,120380,65,120432,65,913,65,120488,65,120546,65,120604,65,120662,65,120720,65,5034,65,5573,65,42222,65,94016,65,66208,65,119835,98,119887,98,119939,98,119991,98,120043,98,120095,98,120147,98,120199,98,120251,98,120303,98,120355,98,120407,98,120459,98,388,98,5071,98,5234,98,5551,98,65314,66,8492,66,119809,66,119861,66,119913,66,120017,66,120069,66,120121,66,120173,66,120225,66,120277,66,120329,66,120381,66,120433,66,42932,66,914,66,120489,66,120547,66,120605,66,120663,66,120721,66,5108,66,5623,66,42192,66,66178,66,66209,66,66305,66,65347,99,8573,99,119836,99,119888,99,119940,99,119992,99,120044,99,120096,99,120148,99,120200,99,120252,99,120304,99,120356,99,120408,99,120460,99,7428,99,1010,99,11429,99,43951,99,66621,99,128844,67,71922,67,71913,67,65315,67,8557,67,8450,67,8493,67,119810,67,119862,67,119914,67,119966,67,120018,67,120174,67,120226,67,120278,67,120330,67,120382,67,120434,67,1017,67,11428,67,5087,67,42202,67,66210,67,66306,67,66581,67,66844,67,8574,100,8518,100,119837,100,119889,100,119941,100,119993,100,120045,100,120097,100,120149,100,120201,100,120253,100,120305,100,120357,100,120409,100,120461,100,1281,100,5095,100,5231,100,42194,100,8558,68,8517,68,119811,68,119863,68,119915,68,119967,68,120019,68,120071,68,120123,68,120175,68,120227,68,120279,68,120331,68,120383,68,120435,68,5024,68,5598,68,5610,68,42195,68,8494,101,65349,101,8495,101,8519,101,119838,101,119890,101,119942,101,120046,101,120098,101,120150,101,120202,101,120254,101,120306,101,120358,101,120410,101,120462,101,43826,101,1213,101,8959,69,65317,69,8496,69,119812,69,119864,69,119916,69,120020,69,120072,69,120124,69,120176,69,120228,69,120280,69,120332,69,120384,69,120436,69,917,69,120492,69,120550,69,120608,69,120666,69,120724,69,11577,69,5036,69,42224,69,71846,69,71854,69,66182,69,119839,102,119891,102,119943,102,119995,102,120047,102,120099,102,120151,102,120203,102,120255,102,120307,102,120359,102,120411,102,120463,102,43829,102,42905,102,383,102,7837,102,1412,102,119315,70,8497,70,119813,70,119865,70,119917,70,120021,70,120073,70,120125,70,120177,70,120229,70,120281,70,120333,70,120385,70,120437,70,42904,70,988,70,120778,70,5556,70,42205,70,71874,70,71842,70,66183,70,66213,70,66853,70,65351,103,8458,103,119840,103,119892,103,119944,103,120048,103,120100,103,120152,103,120204,103,120256,103,120308,103,120360,103,120412,103,120464,103,609,103,7555,103,397,103,1409,103,119814,71,119866,71,119918,71,119970,71,120022,71,120074,71,120126,71,120178,71,120230,71,120282,71,120334,71,120386,71,120438,71,1292,71,5056,71,5107,71,42198,71,65352,104,8462,104,119841,104,119945,104,119997,104,120049,104,120101,104,120153,104,120205,104,120257,104,120309,104,120361,104,120413,104,120465,104,1211,104,1392,104,5058,104,65320,72,8459,72,8460,72,8461,72,119815,72,119867,72,119919,72,120023,72,120179,72,120231,72,120283,72,120335,72,120387,72,120439,72,919,72,120494,72,120552,72,120610,72,120668,72,120726,72,11406,72,5051,72,5500,72,42215,72,66255,72,731,105,9075,105,65353,105,8560,105,8505,105,8520,105,119842,105,119894,105,119946,105,119998,105,120050,105,120102,105,120154,105,120206,105,120258,105,120310,105,120362,105,120414,105,120466,105,120484,105,618,105,617,105,953,105,8126,105,890,105,120522,105,120580,105,120638,105,120696,105,120754,105,1110,105,42567,105,1231,105,43893,105,5029,105,71875,105,65354,106,8521,106,119843,106,119895,106,119947,106,119999,106,120051,106,120103,106,120155,106,120207,106,120259,106,120311,106,120363,106,120415,106,120467,106,1011,106,1112,106,65322,74,119817,74,119869,74,119921,74,119973,74,120025,74,120077,74,120129,74,120181,74,120233,74,120285,74,120337,74,120389,74,120441,74,42930,74,895,74,1032,74,5035,74,5261,74,42201,74,119844,107,119896,107,119948,107,120000,107,120052,107,120104,107,120156,107,120208,107,120260,107,120312,107,120364,107,120416,107,120468,107,8490,75,65323,75,119818,75,119870,75,119922,75,119974,75,120026,75,120078,75,120130,75,120182,75,120234,75,120286,75,120338,75,120390,75,120442,75,922,75,120497,75,120555,75,120613,75,120671,75,120729,75,11412,75,5094,75,5845,75,42199,75,66840,75,1472,108,8739,73,9213,73,65512,73,1633,108,1777,73,66336,108,125127,108,120783,73,120793,73,120803,73,120813,73,120823,73,130033,73,65321,73,8544,73,8464,73,8465,73,119816,73,119868,73,119920,73,120024,73,120128,73,120180,73,120232,73,120284,73,120336,73,120388,73,120440,73,65356,108,8572,73,8467,108,119845,108,119897,108,119949,108,120001,108,120053,108,120105,73,120157,73,120209,73,120261,73,120313,73,120365,73,120417,73,120469,73,448,73,120496,73,120554,73,120612,73,120670,73,120728,73,11410,73,1030,73,1216,73,1493,108,1503,108,1575,108,126464,108,126592,108,65166,108,65165,108,1994,108,11599,73,5825,73,42226,73,93992,73,66186,124,66313,124,119338,76,8556,76,8466,76,119819,76,119871,76,119923,76,120027,76,120079,76,120131,76,120183,76,120235,76,120287,76,120339,76,120391,76,120443,76,11472,76,5086,76,5290,76,42209,76,93974,76,71843,76,71858,76,66587,76,66854,76,65325,77,8559,77,8499,77,119820,77,119872,77,119924,77,120028,77,120080,77,120132,77,120184,77,120236,77,120288,77,120340,77,120392,77,120444,77,924,77,120499,77,120557,77,120615,77,120673,77,120731,77,1018,77,11416,77,5047,77,5616,77,5846,77,42207,77,66224,77,66321,77,119847,110,119899,110,119951,110,120003,110,120055,110,120107,110,120159,110,120211,110,120263,110,120315,110,120367,110,120419,110,120471,110,1400,110,1404,110,65326,78,8469,78,119821,78,119873,78,119925,78,119977,78,120029,78,120081,78,120185,78,120237,78,120289,78,120341,78,120393,78,120445,78,925,78,120500,78,120558,78,120616,78,120674,78,120732,78,11418,78,42208,78,66835,78,3074,111,3202,111,3330,111,3458,111,2406,111,2662,111,2790,111,3046,111,3174,111,3302,111,3430,111,3664,111,3792,111,4160,111,1637,111,1781,111,65359,111,8500,111,119848,111,119900,111,119952,111,120056,111,120108,111,120160,111,120212,111,120264,111,120316,111,120368,111,120420,111,120472,111,7439,111,7441,111,43837,111,959,111,120528,111,120586,111,120644,111,120702,111,120760,111,963,111,120532,111,120590,111,120648,111,120706,111,120764,111,11423,111,4351,111,1413,111,1505,111,1607,111,126500,111,126564,111,126596,111,65259,111,65260,111,65258,111,65257,111,1726,111,64428,111,64429,111,64427,111,64426,111,1729,111,64424,111,64425,111,64423,111,64422,111,1749,111,3360,111,4125,111,66794,111,71880,111,71895,111,66604,111,1984,79,2534,79,2918,79,12295,79,70864,79,71904,79,120782,79,120792,79,120802,79,120812,79,120822,79,130032,79,65327,79,119822,79,119874,79,119926,79,119978,79,120030,79,120082,79,120134,79,120186,79,120238,79,120290,79,120342,79,120394,79,120446,79,927,79,120502,79,120560,79,120618,79,120676,79,120734,79,11422,79,1365,79,11604,79,4816,79,2848,79,66754,79,42227,79,71861,79,66194,79,66219,79,66564,79,66838,79,9076,112,65360,112,119849,112,119901,112,119953,112,120005,112,120057,112,120109,112,120161,112,120213,112,120265,112,120317,112,120369,112,120421,112,120473,112,961,112,120530,112,120544,112,120588,112,120602,112,120646,112,120660,112,120704,112,120718,112,120762,112,120776,112,11427,112,65328,80,8473,80,119823,80,119875,80,119927,80,119979,80,120031,80,120083,80,120187,80,120239,80,120291,80,120343,80,120395,80,120447,80,929,80,120504,80,120562,80,120620,80,120678,80,120736,80,11426,80,5090,80,5229,80,42193,80,66197,80,119850,113,119902,113,119954,113,120006,113,120058,113,120110,113,120162,113,120214,113,120266,113,120318,113,120370,113,120422,113,120474,113,1307,113,1379,113,1382,113,8474,81,119824,81,119876,81,119928,81,119980,81,120032,81,120084,81,120188,81,120240,81,120292,81,120344,81,120396,81,120448,81,11605,81,119851,114,119903,114,119955,114,120007,114,120059,114,120111,114,120163,114,120215,114,120267,114,120319,114,120371,114,120423,114,120475,114,43847,114,43848,114,7462,114,11397,114,43905,114,119318,82,8475,82,8476,82,8477,82,119825,82,119877,82,119929,82,120033,82,120189,82,120241,82,120293,82,120345,82,120397,82,120449,82,422,82,5025,82,5074,82,66740,82,5511,82,42211,82,94005,82,65363,115,119852,115,119904,115,119956,115,120008,115,120060,115,120112,115,120164,115,120216,115,120268,115,120320,115,120372,115,120424,115,120476,115,42801,115,445,115,1109,115,43946,115,71873,115,66632,115,65331,83,119826,83,119878,83,119930,83,119982,83,120034,83,120086,83,120138,83,120190,83,120242,83,120294,83,120346,83,120398,83,120450,83,1029,83,1359,83,5077,83,5082,83,42210,83,94010,83,66198,83,66592,83,119853,116,119905,116,119957,116,120009,116,120061,116,120113,116,120165,116,120217,116,120269,116,120321,116,120373,116,120425,116,120477,116,8868,84,10201,84,128872,84,65332,84,119827,84,119879,84,119931,84,119983,84,120035,84,120087,84,120139,84,120191,84,120243,84,120295,84,120347,84,120399,84,120451,84,932,84,120507,84,120565,84,120623,84,120681,84,120739,84,11430,84,5026,84,42196,84,93962,84,71868,84,66199,84,66225,84,66325,84,119854,117,119906,117,119958,117,120010,117,120062,117,120114,117,120166,117,120218,117,120270,117,120322,117,120374,117,120426,117,120478,117,42911,117,7452,117,43854,117,43858,117,651,117,965,117,120534,117,120592,117,120650,117,120708,117,120766,117,1405,117,66806,117,71896,117,8746,85,8899,85,119828,85,119880,85,119932,85,119984,85,120036,85,120088,85,120140,85,120192,85,120244,85,120296,85,120348,85,120400,85,120452,85,1357,85,4608,85,66766,85,5196,85,42228,85,94018,85,71864,85,8744,118,8897,118,65366,118,8564,118,119855,118,119907,118,119959,118,120011,118,120063,118,120115,118,120167,118,120219,118,120271,118,120323,118,120375,118,120427,118,120479,118,7456,118,957,118,120526,118,120584,118,120642,118,120700,118,120758,118,1141,118,1496,118,71430,118,43945,118,71872,118,119309,86,1639,86,1783,86,8548,86,119829,86,119881,86,119933,86,119985,86,120037,86,120089,86,120141,86,120193,86,120245,86,120297,86,120349,86,120401,86,120453,86,1140,86,11576,86,5081,86,5167,86,42719,86,42214,86,93960,86,71840,86,66845,86,623,119,119856,119,119908,119,119960,119,120012,119,120064,119,120116,119,120168,119,120220,119,120272,119,120324,119,120376,119,120428,119,120480,119,7457,119,1121,119,1309,119,1377,119,71434,119,71438,119,71439,119,43907,119,71919,87,71910,87,119830,87,119882,87,119934,87,119986,87,120038,87,120090,87,120142,87,120194,87,120246,87,120298,87,120350,87,120402,87,120454,87,1308,87,5043,87,5076,87,42218,87,5742,120,10539,120,10540,120,10799,120,65368,120,8569,120,119857,120,119909,120,119961,120,120013,120,120065,120,120117,120,120169,120,120221,120,120273,120,120325,120,120377,120,120429,120,120481,120,5441,120,5501,120,5741,88,9587,88,66338,88,71916,88,65336,88,8553,88,119831,88,119883,88,119935,88,119987,88,120039,88,120091,88,120143,88,120195,88,120247,88,120299,88,120351,88,120403,88,120455,88,42931,88,935,88,120510,88,120568,88,120626,88,120684,88,120742,88,11436,88,11613,88,5815,88,42219,88,66192,88,66228,88,66327,88,66855,88,611,121,7564,121,65369,121,119858,121,119910,121,119962,121,120014,121,120066,121,120118,121,120170,121,120222,121,120274,121,120326,121,120378,121,120430,121,120482,121,655,121,7935,121,43866,121,947,121,8509,121,120516,121,120574,121,120632,121,120690,121,120748,121,1199,121,4327,121,71900,121,65337,89,119832,89,119884,89,119936,89,119988,89,120040,89,120092,89,120144,89,120196,89,120248,89,120300,89,120352,89,120404,89,120456,89,933,89,978,89,120508,89,120566,89,120624,89,120682,89,120740,89,11432,89,1198,89,5033,89,5053,89,42220,89,94019,89,71844,89,66226,89,119859,122,119911,122,119963,122,120015,122,120067,122,120119,122,120171,122,120223,122,120275,122,120327,122,120379,122,120431,122,120483,122,7458,122,43923,122,71876,122,66293,90,71909,90,65338,90,8484,90,8488,90,119833,90,119885,90,119937,90,119989,90,120041,90,120197,90,120249,90,120301,90,120353,90,120405,90,120457,90,918,90,120493,90,120551,90,120609,90,120667,90,120725,90,5059,90,42204,90,71849,90,65282,34,65284,36,65285,37,65286,38,65290,42,65291,43,65294,46,65295,47,65296,48,65297,49,65298,50,65299,51,65300,52,65301,53,65302,54,65303,55,65304,56,65305,57,65308,60,65309,61,65310,62,65312,64,65316,68,65318,70,65319,71,65324,76,65329,81,65330,82,65333,85,65334,86,65335,87,65343,95,65346,98,65348,100,65350,102,65355,107,65357,109,65358,110,65361,113,65362,114,65364,116,65365,117,65367,119,65370,122,65371,123,65373,125],"_default":[160,32,8211,45,65374,126,65306,58,65281,33,8216,96,8217,96,8245,96,180,96,12494,47,1047,51,1073,54,1072,97,1040,65,1068,98,1042,66,1089,99,1057,67,1077,101,1045,69,1053,72,305,105,1050,75,921,73,1052,77,1086,111,1054,79,1009,112,1088,112,1056,80,1075,114,1058,84,215,120,1093,120,1061,88,1091,121,1059,89,65283,35,65288,40,65289,41,65292,44,65307,59,65311,63],"cs":[65374,126,65306,58,65281,33,8216,96,8217,96,8245,96,180,96,12494,47,1047,51,1073,54,1072,97,1040,65,1068,98,1042,66,1089,99,1057,67,1077,101,1045,69,1053,72,305,105,1050,75,921,73,1052,77,1086,111,1054,79,1009,112,1088,112,1056,80,1075,114,1058,84,1093,120,1061,88,1091,121,1059,89,65283,35,65288,40,65289,41,65292,44,65307,59,65311,63],"de":[65374,126,65306,58,65281,33,8216,96,8217,96,8245,96,180,96,12494,47,1047,51,1073,54,1072,97,1040,65,1068,98,1042,66,1089,99,1057,67,1077,101,1045,69,1053,72,305,105,1050,75,921,73,1052,77,1086,111,1054,79,1009,112,1088,112,1056,80,1075,114,1058,84,1093,120,1061,88,1091,121,1059,89,65283,35,65288,40,65289,41,65292,44,65307,59,65311,63],"es":[8211,45,65374,126,65306,58,65281,33,8245,96,180,96,12494,47,1047,51,1073,54,1072,97,1040,65,1068,98,1042,66,1089,99,1057,67,1077,101,1045,69,1053,72,305,105,1050,75,1052,77,1086,111,1054,79,1009,112,1088,112,1056,80,1075,114,1058,84,215,120,1093,120,1061,88,1091,121,1059,89,65283,35,65288,40,65289,41,65292,44,65307,59,65311,63],"fr":[65374,126,65306,58,65281,33,8216,96,8245,96,12494,47,1047,51,1073,54,1072,97,1040,65,1068,98,1042,66,1089,99,1057,67,1077,101,1045,69,1053,72,305,105,1050,75,921,73,1052,77,1086,111,1054,79,1009,112,1088,112,1056,80,1075,114,1058,84,215,120,1093,120,1061,88,1091,121,1059,89,65283,35,65288,40,65289,41,65292,44,65307,59,65311,63],"it":[160,32,8211,45,65374,126,65306,58,65281,33,8216,96,8245,96,180,96,12494,47,1047,51,1073,54,1072,97,1040,65,1068,98,1042,66,1089,99,1057,67,1077,101,1045,69,1053,72,305,105,1050,75,921,73,1052,77,1086,111,1054,79,1009,112,1088,112,1056,80,1075,114,1058,84,215,120,1093,120,1061,88,1091,121,1059,89,65283,35,65288,40,65289,41,65292,44,65307,59,65311,63],"ja":[8211,45,65306,58,65281,33,8216,96,8217,96,8245,96,180,96,1047,51,1073,54,1072,97,1040,65,1068,98,1042,66,1089,99,1057,67,1077,101,1045,69,1053,72,305,105,1050,75,921,73,1052,77,1086,111,1054,79,1009,112,1088,112,1056,80,1075,114,1058,84,215,120,1093,120,1061,88,1091,121,1059,89,65283,35,65292,44,65307,59],"ko":[8211,45,65374,126,65306,58,65281,33,8245,96,180,96,12494,47,1047,51,1073,54,1072,97,1040,65,1068,98,1042,66,1089,99,1057,67,1077,101,1045,69,1053,72,305,105,1050,75,921,73,1052,77,1086,111,1054,79,1009,112,1088,112,1056,80,1075,114,1058,84,215,120,1093,120,1061,88,1091,121,1059,89,65283,35,65288,40,65289,41,65292,44,65307,59,65311,63],"pl":[65374,126,65306,58,65281,33,8216,96,8217,96,8245,96,180,96,12494,47,1047,51,1073,54,1072,97,1040,65,1068,98,1042,66,1089,99,1057,67,1077,101,1045,69,1053,72,305,105,1050,75,921,73,1052,77,1086,111,1054,79,1009,112,1088,112,1056,80,1075,114,1058,84,215,120,1093,120,1061,88,1091,121,1059,89,65283,35,65288,40,65289,41,65292,44,65307,59,65311,63],"pt-BR":[65374,126,65306,58,65281,33,8216,96,8217,96,8245,96,180,96,12494,47,1047,51,1073,54,1072,97,1040,65,1068,98,1042,66,1089,99,1057,67,1077,101,1045,69,1053,72,305,105,1050,75,921,73,1052,77,1086,111,1054,79,1009,112,1088,112,1056,80,1075,114,1058,84,215,120,1093,120,1061,88,1091,121,1059,89,65283,35,65288,40,65289,41,65292,44,65307,59,65311,63],"qps-ploc":[160,32,8211,45,65374,126,65306,58,65281,33,8216,96,8217,96,8245,96,180,96,12494,47,1047,51,1073,54,1072,97,1040,65,1068,98,1042,66,1089,99,1057,67,1077,101,1045,69,1053,72,305,105,1050,75,921,73,1052,77,1086,111,1054,79,1088,112,1056,80,1075,114,1058,84,215,120,1093,120,1061,88,1091,121,1059,89,65283,35,65288,40,65289,41,65292,44,65307,59,65311,63],"ru":[65374,126,65306,58,65281,33,8216,96,8217,96,8245,96,180,96,12494,47,305,105,921,73,1009,112,215,120,65283,35,65288,40,65289,41,65292,44,65307,59,65311,63],"tr":[160,32,8211,45,65374,126,65306,58,65281,33,8245,96,180,96,12494,47,1047,51,1073,54,1072,97,1040,65,1068,98,1042,66,1089,99,1057,67,1077,101,1045,69,1053,72,1050,75,921,73,1052,77,1086,111,1054,79,1009,112,1088,112,1056,80,1075,114,1058,84,215,120,1093,120,1061,88,1091,121,1059,89,65283,35,65288,40,65289,41,65292,44,65307,59,65311,63],"zh-hans":[65374,126,65306,58,65281,33,8245,96,180,96,12494,47,1047,51,1073,54,1072,97,1040,65,1068,98,1042,66,1089,99,1057,67,1077,101,1045,69,1053,72,305,105,1050,75,921,73,1052,77,1086,111,1054,79,1009,112,1088,112,1056,80,1075,114,1058,84,215,120,1093,120,1061,88,1091,121,1059,89,65288,40,65289,41],"zh-hant":[8211,45,65374,126,180,96,12494,47,1047,51,1073,54,1072,97,1040,65,1068,98,1042,66,1089,99,1057,67,1077,101,1045,69,1053,72,305,105,1050,75,921,73,1052,77,1086,111,1054,79,1009,112,1088,112,1056,80,1075,114,1058,84,215,120,1093,120,1061,88,1091,121,1059,89,65283,35,65307,59]}'))),oe.cache=new class{constructor(e){this.computeFn=e,this.lastCache=void 0,this.lastArgKey=void 0}get(e){const t=JSON.stringify(e);return this.lastArgKey!==t&&(this.lastArgKey=t,this.lastCache=this.computeFn(e)),this.lastCache}}((e=>{function t(e){const t=new Map;for(let i=0;i!e.startsWith("_")&&e in o));0===s.length&&(s=["_default"]);for(const e of s)r=i(r,t(o[e]));const a=function(e,t){const i=new Map(e);for(const[e,n]of t)i.set(e,n);return i}(t(o._common),r);return new oe(a)})),oe._locales=new o.o((()=>Object.keys(oe.ambiguousCharacterData.getValue()).filter((e=>!e.startsWith("_")))));class re{static getRawData(){return JSON.parse("[9,10,11,12,13,32,127,160,173,847,1564,4447,4448,6068,6069,6155,6156,6157,6158,7355,7356,8192,8193,8194,8195,8196,8197,8198,8199,8200,8201,8202,8203,8204,8205,8206,8207,8234,8235,8236,8237,8238,8239,8287,8288,8289,8290,8291,8292,8293,8294,8295,8296,8297,8298,8299,8300,8301,8302,8303,10240,12288,12644,65024,65025,65026,65027,65028,65029,65030,65031,65032,65033,65034,65035,65036,65037,65038,65039,65279,65440,65520,65521,65522,65523,65524,65525,65526,65527,65528,65532,78844,119155,119156,119157,119158,119159,119160,119161,119162,917504,917505,917506,917507,917508,917509,917510,917511,917512,917513,917514,917515,917516,917517,917518,917519,917520,917521,917522,917523,917524,917525,917526,917527,917528,917529,917530,917531,917532,917533,917534,917535,917536,917537,917538,917539,917540,917541,917542,917543,917544,917545,917546,917547,917548,917549,917550,917551,917552,917553,917554,917555,917556,917557,917558,917559,917560,917561,917562,917563,917564,917565,917566,917567,917568,917569,917570,917571,917572,917573,917574,917575,917576,917577,917578,917579,917580,917581,917582,917583,917584,917585,917586,917587,917588,917589,917590,917591,917592,917593,917594,917595,917596,917597,917598,917599,917600,917601,917602,917603,917604,917605,917606,917607,917608,917609,917610,917611,917612,917613,917614,917615,917616,917617,917618,917619,917620,917621,917622,917623,917624,917625,917626,917627,917628,917629,917630,917631,917760,917761,917762,917763,917764,917765,917766,917767,917768,917769,917770,917771,917772,917773,917774,917775,917776,917777,917778,917779,917780,917781,917782,917783,917784,917785,917786,917787,917788,917789,917790,917791,917792,917793,917794,917795,917796,917797,917798,917799,917800,917801,917802,917803,917804,917805,917806,917807,917808,917809,917810,917811,917812,917813,917814,917815,917816,917817,917818,917819,917820,917821,917822,917823,917824,917825,917826,917827,917828,917829,917830,917831,917832,917833,917834,917835,917836,917837,917838,917839,917840,917841,917842,917843,917844,917845,917846,917847,917848,917849,917850,917851,917852,917853,917854,917855,917856,917857,917858,917859,917860,917861,917862,917863,917864,917865,917866,917867,917868,917869,917870,917871,917872,917873,917874,917875,917876,917877,917878,917879,917880,917881,917882,917883,917884,917885,917886,917887,917888,917889,917890,917891,917892,917893,917894,917895,917896,917897,917898,917899,917900,917901,917902,917903,917904,917905,917906,917907,917908,917909,917910,917911,917912,917913,917914,917915,917916,917917,917918,917919,917920,917921,917922,917923,917924,917925,917926,917927,917928,917929,917930,917931,917932,917933,917934,917935,917936,917937,917938,917939,917940,917941,917942,917943,917944,917945,917946,917947,917948,917949,917950,917951,917952,917953,917954,917955,917956,917957,917958,917959,917960,917961,917962,917963,917964,917965,917966,917967,917968,917969,917970,917971,917972,917973,917974,917975,917976,917977,917978,917979,917980,917981,917982,917983,917984,917985,917986,917987,917988,917989,917990,917991,917992,917993,917994,917995,917996,917997,917998,917999]")}static getData(){return this._data||(this._data=new Set(re.getRawData())),this._data}static isInvisibleCharacter(e){return re.getData().has(e)}static get codePoints(){return re.getData()}}re._data=void 0},28295:function(e,t,i){"use strict";function n(e){return Array.isArray(e)}function o(e){return"string"==typeof e}function r(e){return!("object"!=typeof e||null===e||Array.isArray(e)||e instanceof RegExp||e instanceof Date)}function s(e){return"number"==typeof e&&!isNaN(e)}function a(e){return!!e&&"function"==typeof e[Symbol.iterator]}function l(e){return!0===e||!1===e}function c(e){return void 0===e}function d(e){return!u(e)}function u(e){return c(e)||null===e}function h(e,t){if(!e)throw new Error(t?`Unexpected type, expected '${t}'`:"Unexpected type")}function g(e){if(u(e))throw new Error("Assertion Failed: argument is undefined or null");return e}function p(e){return"function"==typeof e}function m(e,t){const i=Math.min(e.length,t.length);for(let n=0;nfunction(){const i=Array.prototype.slice.call(arguments,0);return t(e,i)};let n={};for(const t of e)n[t]=i(t);return n}function v(e){return null===e?void 0:e}function C(e,t="Unreachable"){throw new Error(t)}i.d(t,{$E:function(){return _},$K:function(){return d},D8:function(){return m},HD:function(){return o},IU:function(){return b},Jp:function(){return u},Kn:function(){return r},TW:function(){return a},cW:function(){return g},f6:function(){return v},hj:function(){return s},jn:function(){return l},kJ:function(){return n},mf:function(){return p},o8:function(){return c},p_:function(){return h},vE:function(){return C}})},16987:function(e,t,i){"use strict";function n(e){return e<0?0:e>255?255:0|e}function o(e){return e<0?0:e>4294967295?4294967295:0|e}i.d(t,{A:function(){return o},K:function(){return n}})},39675:function(e,t,i){"use strict";i.d(t,{o:function(){return h},q:function(){return b}});var n=i(14477),o=i(6954);const r=/^\w[\w\d+.-]*$/,s=/^\//,a=/^\/\//;function l(e,t){if(!e.scheme&&t)throw new Error(`[UriError]: Scheme is missing: {scheme: "", authority: "${e.authority}", path: "${e.path}", query: "${e.query}", fragment: "${e.fragment}"}`);if(e.scheme&&!r.test(e.scheme))throw new Error("[UriError]: Scheme contains illegal characters.");if(e.path)if(e.authority){if(!s.test(e.path))throw new Error('[UriError]: If a URI contains an authority component, then the path component must either be empty or begin with a slash ("/") character')}else if(a.test(e.path))throw new Error('[UriError]: If a URI does not contain an authority component, then the path cannot begin with two slash characters ("//")')}const c="",d="/",u=/^(([^:/?#]+?):)?(\/\/([^/?#]*))?([^?#]*)(\?([^#]*))?(#(.*))?/;class h{constructor(e,t,i,n,o,r=!1){"object"==typeof e?(this.scheme=e.scheme||c,this.authority=e.authority||c,this.path=e.path||c,this.query=e.query||c,this.fragment=e.fragment||c):(this.scheme=function(e,t){return e||t?e:"file"}(e,r),this.authority=t||c,this.path=function(e,t){switch(e){case"https":case"http":case"file":t?t[0]!==d&&(t=d+t):t=d}return t}(this.scheme,i||c),this.query=n||c,this.fragment=o||c,l(this,r))}static isUri(e){return e instanceof h||!!e&&"string"==typeof e.authority&&"string"==typeof e.fragment&&"string"==typeof e.path&&"string"==typeof e.query&&"string"==typeof e.scheme&&"string"==typeof e.fsPath&&"function"==typeof e.with&&"function"==typeof e.toString}get fsPath(){return b(this,!1)}with(e){if(!e)return this;let{scheme:t,authority:i,path:n,query:o,fragment:r}=e;return void 0===t?t=this.scheme:null===t&&(t=c),void 0===i?i=this.authority:null===i&&(i=c),void 0===n?n=this.path:null===n&&(n=c),void 0===o?o=this.query:null===o&&(o=c),void 0===r?r=this.fragment:null===r&&(r=c),t===this.scheme&&i===this.authority&&n===this.path&&o===this.query&&r===this.fragment?this:new p(t,i,n,o,r)}static parse(e,t=!1){const i=u.exec(e);return i?new p(i[2]||c,y(i[4]||c),y(i[5]||c),y(i[7]||c),y(i[9]||c),t):new p(c,c,c,c,c)}static file(e){let t=c;if(o.ED&&(e=e.replace(/\\/g,d)),e[0]===d&&e[1]===d){const i=e.indexOf(d,2);-1===i?(t=e.substring(2),e=d):(t=e.substring(2,i),e=e.substring(i)||d)}return new p("file",t,e,c,c)}static from(e){const t=new p(e.scheme,e.authority,e.path,e.query,e.fragment);return l(t,!0),t}static joinPath(e,...t){if(!e.path)throw new Error("[UriError]: cannot call joinPath on URI without path");let i;return i=o.ED&&"file"===e.scheme?h.file(n.Ku.join(b(e,!0),...t)).path:n.KR.join(e.path,...t),e.with({path:i})}toString(e=!1){return v(this,e)}toJSON(){return this}static revive(e){if(e){if(e instanceof h)return e;{const t=new p(e);return t._formatted=e.external,t._fsPath=e._sep===g?e.fsPath:null,t}}return e}}const g=o.ED?1:void 0;class p extends h{constructor(){super(...arguments),this._formatted=null,this._fsPath=null}get fsPath(){return this._fsPath||(this._fsPath=b(this,!1)),this._fsPath}toString(e=!1){return e?v(this,!0):(this._formatted||(this._formatted=v(this,!1)),this._formatted)}toJSON(){const e={$mid:1};return this._fsPath&&(e.fsPath=this._fsPath,e._sep=g),this._formatted&&(e.external=this._formatted),this.path&&(e.path=this.path),this.scheme&&(e.scheme=this.scheme),this.authority&&(e.authority=this.authority),this.query&&(e.query=this.query),this.fragment&&(e.fragment=this.fragment),e}}const m={58:"%3A",47:"%2F",63:"%3F",35:"%23",91:"%5B",93:"%5D",64:"%40",33:"%21",36:"%24",38:"%26",39:"%27",40:"%28",41:"%29",42:"%2A",43:"%2B",44:"%2C",59:"%3B",61:"%3D",32:"%20"};function f(e,t){let i,n=-1;for(let o=0;o=97&&r<=122||r>=65&&r<=90||r>=48&&r<=57||45===r||46===r||95===r||126===r||t&&47===r)-1!==n&&(i+=encodeURIComponent(e.substring(n,o)),n=-1),void 0!==i&&(i+=e.charAt(o));else{void 0===i&&(i=e.substr(0,o));const t=m[r];void 0!==t?(-1!==n&&(i+=encodeURIComponent(e.substring(n,o)),n=-1),i+=t):-1===n&&(n=o)}}return-1!==n&&(i+=encodeURIComponent(e.substring(n))),void 0!==i?i:e}function _(e){let t;for(let i=0;i1&&"file"===e.scheme?`//${e.authority}${e.path}`:47===e.path.charCodeAt(0)&&(e.path.charCodeAt(1)>=65&&e.path.charCodeAt(1)<=90||e.path.charCodeAt(1)>=97&&e.path.charCodeAt(1)<=122)&&58===e.path.charCodeAt(2)?t?e.path.substr(1):e.path[1].toLowerCase()+e.path.substr(2):e.path,o.ED&&(i=i.replace(/\//g,"\\")),i}function v(e,t){const i=t?_:f;let n="",{scheme:o,authority:r,path:s,query:a,fragment:l}=e;if(o&&(n+=o,n+=":"),(r||"file"===o)&&(n+=d,n+=d),r){let e=r.indexOf("@");if(-1!==e){const t=r.substr(0,e);r=r.substr(e+1),e=t.indexOf(":"),-1===e?n+=i(t,!1):(n+=i(t.substr(0,e),!1),n+=":",n+=i(t.substr(e+1),!1)),n+="@"}r=r.toLowerCase(),e=r.indexOf(":"),-1===e?n+=i(r,!1):(n+=i(r.substr(0,e),!1),n+=r.substr(e))}if(s){if(s.length>=3&&47===s.charCodeAt(0)&&58===s.charCodeAt(2)){const e=s.charCodeAt(1);e>=65&&e<=90&&(s=`/${String.fromCharCode(e+32)}:${s.substr(3)}`)}else if(s.length>=2&&58===s.charCodeAt(1)){const e=s.charCodeAt(0);e>=65&&e<=90&&(s=`${String.fromCharCode(e+32)}:${s.substr(2)}`)}n+=i(s,!0)}return a&&(n+="?",n+=i(a,!1)),l&&(n+="#",n+=t?l:f(l,!1)),n}function C(e){try{return decodeURIComponent(e)}catch(t){return e.length>3?e.substr(0,3)+C(e.substr(3)):e}}const w=/(%[0-9A-Za-z][0-9A-Za-z])+/g;function y(e){return e.match(w)?e.replace(w,(e=>C(e))):e}},55470:function(e,t,i){"use strict";i.d(t,{Jq:function(){return o},X5:function(){return n},jG:function(){return r}});const n={ctrlCmd:!1,alt:!1};var o,r;!function(e){e[e.Blur=1]="Blur",e[e.Gesture=2]="Gesture",e[e.Other=3]="Other"}(o||(o={})),function(e){e[e.NONE=0]="NONE",e[e.FIRST=1]="FIRST",e[e.SECOND=2]="SECOND",e[e.LAST=3]="LAST"}(r||(r={})),new class{constructor(e){this.options=e}}},70266:function(e,t,i){"use strict";i.d(t,{H:function(){return h}});var n=i(54918),o=Object.defineProperty,r=Object.getOwnPropertyDescriptor,s=Object.getOwnPropertyNames,a=Object.prototype.hasOwnProperty,l={};((e,t,i,n)=>{if(t&&"object"==typeof t||"function"==typeof t)for(let i of s(t))a.call(e,i)||"default"===i||o(e,i,{get:()=>t[i],enumerable:!(n=r(t,i))||n.enumerable})})(l,n);var c={},d={},u=class{static getOrCreate(e){return d[e]||(d[e]=new u(e)),d[e]}_languageId;_loadingTriggered;_lazyLoadPromise;_lazyLoadPromiseResolve;_lazyLoadPromiseReject;constructor(e){this._languageId=e,this._loadingTriggered=!1,this._lazyLoadPromise=new Promise(((e,t)=>{this._lazyLoadPromiseResolve=e,this._lazyLoadPromiseReject=t}))}load(){return this._loadingTriggered||(this._loadingTriggered=!0,c[this._languageId].loader().then((e=>this._lazyLoadPromiseResolve(e)),(e=>this._lazyLoadPromiseReject(e)))),this._lazyLoadPromise}};function h(e){const t=e.id;c[t]=e,l.languages.register(e);const i=u.getOrCreate(t);l.languages.registerTokensProviderFactory(t,{create:async()=>(await i.load()).language}),l.languages.onLanguage(t,(async()=>{const e=await i.load();l.languages.setLanguageConfiguration(t,e.conf)}))}},47729:function(e,t,i){"use strict";i.r(t),(0,i(70266).H)({id:"abap",extensions:[".abap"],aliases:["abap","ABAP"],loader:()=>Promise.resolve().then(i.bind(i,47408))})},47408:function(e,t,i){"use strict";i.r(t),i.d(t,{conf:function(){return n},language:function(){return o}});var n={comments:{lineComment:"*"},brackets:[["[","]"],["(",")"]]},o={defaultToken:"invalid",ignoreCase:!0,tokenPostfix:".abap",keywords:["abap-source","abbreviated","abstract","accept","accepting","according","activation","actual","add","add-corresponding","adjacent","after","alias","aliases","align","all","allocate","alpha","analysis","analyzer","and","append","appendage","appending","application","archive","area","arithmetic","as","ascending","aspect","assert","assign","assigned","assigning","association","asynchronous","at","attributes","authority","authority-check","avg","back","background","backup","backward","badi","base","before","begin","between","big","binary","bintohex","bit","black","blank","blanks","blob","block","blocks","blue","bound","boundaries","bounds","boxed","break-point","buffer","by","bypassing","byte","byte-order","call","calling","case","cast","casting","catch","center","centered","chain","chain-input","chain-request","change","changing","channels","character","char-to-hex","check","checkbox","ci_","circular","class","class-coding","class-data","class-events","class-methods","class-pool","cleanup","clear","client","clob","clock","close","coalesce","code","coding","col_background","col_group","col_heading","col_key","col_negative","col_normal","col_positive","col_total","collect","color","column","columns","comment","comments","commit","common","communication","comparing","component","components","compression","compute","concat","concat_with_space","concatenate","cond","condense","condition","connect","connection","constants","context","contexts","continue","control","controls","conv","conversion","convert","copies","copy","corresponding","country","cover","cpi","create","creating","critical","currency","currency_conversion","current","cursor","cursor-selection","customer","customer-function","dangerous","data","database","datainfo","dataset","date","dats_add_days","dats_add_months","dats_days_between","dats_is_valid","daylight","dd/mm/yy","dd/mm/yyyy","ddmmyy","deallocate","decimal_shift","decimals","declarations","deep","default","deferred","define","defining","definition","delete","deleting","demand","department","descending","describe","destination","detail","dialog","directory","disconnect","display","display-mode","distinct","divide","divide-corresponding","division","do","dummy","duplicate","duplicates","duration","during","dynamic","dynpro","edit","editor-call","else","elseif","empty","enabled","enabling","encoding","end","endat","endcase","endcatch","endchain","endclass","enddo","endenhancement","end-enhancement-section","endexec","endform","endfunction","endian","endif","ending","endinterface","end-lines","endloop","endmethod","endmodule","end-of-definition","end-of-editing","end-of-file","end-of-page","end-of-selection","endon","endprovide","endselect","end-test-injection","end-test-seam","endtry","endwhile","endwith","engineering","enhancement","enhancement-point","enhancements","enhancement-section","entries","entry","enum","environment","equiv","errormessage","errors","escaping","event","events","exact","except","exception","exceptions","exception-table","exclude","excluding","exec","execute","exists","exit","exit-command","expand","expanding","expiration","explicit","exponent","export","exporting","extend","extended","extension","extract","fail","fetch","field","field-groups","fields","field-symbol","field-symbols","file","filter","filters","filter-table","final","find","first","first-line","fixed-point","fkeq","fkge","flush","font","for","form","format","forward","found","frame","frames","free","friends","from","function","functionality","function-pool","further","gaps","generate","get","giving","gkeq","gkge","global","grant","green","group","groups","handle","handler","harmless","hashed","having","hdb","header","headers","heading","head-lines","help-id","help-request","hextobin","hide","high","hint","hold","hotspot","icon","id","identification","identifier","ids","if","ignore","ignoring","immediately","implementation","implementations","implemented","implicit","import","importing","in","inactive","incl","include","includes","including","increment","index","index-line","infotypes","inheriting","init","initial","initialization","inner","inout","input","insert","instance","instances","instr","intensified","interface","interface-pool","interfaces","internal","intervals","into","inverse","inverted-date","is","iso","job","join","keep","keeping","kernel","key","keys","keywords","kind","language","last","late","layout","leading","leave","left","left-justified","leftplus","leftspace","legacy","length","let","level","levels","like","line","lines","line-count","linefeed","line-selection","line-size","list","listbox","list-processing","little","llang","load","load-of-program","lob","local","locale","locator","logfile","logical","log-point","long","loop","low","lower","lpad","lpi","ltrim","mail","main","major-id","mapping","margin","mark","mask","match","matchcode","max","maximum","medium","members","memory","mesh","message","message-id","messages","messaging","method","methods","min","minimum","minor-id","mm/dd/yy","mm/dd/yyyy","mmddyy","mode","modif","modifier","modify","module","move","move-corresponding","multiply","multiply-corresponding","name","nametab","native","nested","nesting","new","new-line","new-page","new-section","next","no","no-display","no-extension","no-gap","no-gaps","no-grouping","no-heading","no-scrolling","no-sign","no-title","no-topofpage","no-zero","node","nodes","non-unicode","non-unique","not","null","number","object","objects","obligatory","occurrence","occurrences","occurs","of","off","offset","ole","on","only","open","option","optional","options","or","order","other","others","out","outer","output","output-length","overflow","overlay","pack","package","pad","padding","page","pages","parameter","parameters","parameter-table","part","partially","pattern","percentage","perform","performing","person","pf1","pf10","pf11","pf12","pf13","pf14","pf15","pf2","pf3","pf4","pf5","pf6","pf7","pf8","pf9","pf-status","pink","places","pool","pos_high","pos_low","position","pragmas","precompiled","preferred","preserving","primary","print","print-control","priority","private","procedure","process","program","property","protected","provide","public","push","pushbutton","put","queue-only","quickinfo","radiobutton","raise","raising","range","ranges","read","reader","read-only","receive","received","receiver","receiving","red","redefinition","reduce","reduced","ref","reference","refresh","regex","reject","remote","renaming","replace","replacement","replacing","report","request","requested","reserve","reset","resolution","respecting","responsible","result","results","resumable","resume","retry","return","returncode","returning","returns","right","right-justified","rightplus","rightspace","risk","rmc_communication_failure","rmc_invalid_status","rmc_system_failure","role","rollback","rows","rpad","rtrim","run","sap","sap-spool","saving","scale_preserving","scale_preserving_scientific","scan","scientific","scientific_with_leading_zero","scroll","scroll-boundary","scrolling","search","secondary","seconds","section","select","selection","selections","selection-screen","selection-set","selection-sets","selection-table","select-options","send","separate","separated","set","shared","shift","short","shortdump-id","sign_as_postfix","single","size","skip","skipping","smart","some","sort","sortable","sorted","source","specified","split","spool","spots","sql","sqlscript","stable","stamp","standard","starting","start-of-editing","start-of-selection","state","statement","statements","static","statics","statusinfo","step-loop","stop","structure","structures","style","subkey","submatches","submit","subroutine","subscreen","subtract","subtract-corresponding","suffix","sum","summary","summing","supplied","supply","suppress","switch","switchstates","symbol","syncpoints","syntax","syntax-check","syntax-trace","system-call","system-exceptions","system-exit","tab","tabbed","table","tables","tableview","tabstrip","target","task","tasks","test","testing","test-injection","test-seam","text","textpool","then","throw","time","times","timestamp","timezone","tims_is_valid","title","titlebar","title-lines","to","tokenization","tokens","top-lines","top-of-page","trace-file","trace-table","trailing","transaction","transfer","transformation","translate","transporting","trmac","truncate","truncation","try","tstmp_add_seconds","tstmp_current_utctimestamp","tstmp_is_valid","tstmp_seconds_between","type","type-pool","type-pools","types","uline","unassign","under","unicode","union","unique","unit_conversion","unix","unpack","until","unwind","up","update","upper","user","user-command","using","utf-8","valid","value","value-request","values","vary","varying","verification-message","version","via","view","visible","wait","warning","when","whenever","where","while","width","window","windows","with","with-heading","without","with-title","word","work","write","writer","xml","xsd","yellow","yes","yymmdd","zero","zone","abap_system_timezone","abap_user_timezone","access","action","adabas","adjust_numbers","allow_precision_loss","allowed","amdp","applicationuser","as_geo_json","as400","associations","balance","behavior","breakup","bulk","cds","cds_client","check_before_save","child","clients","corr","corr_spearman","cross","cycles","datn_add_days","datn_add_months","datn_days_between","dats_from_datn","dats_tims_to_tstmp","dats_to_datn","db2","db6","ddl","dense_rank","depth","deterministic","discarding","entities","entity","error","failed","finalize","first_value","fltp_to_dec","following","fractional","full","graph","grouping","hierarchy","hierarchy_ancestors","hierarchy_ancestors_aggregate","hierarchy_descendants","hierarchy_descendants_aggregate","hierarchy_siblings","incremental","indicators","lag","last_value","lead","leaves","like_regexpr","link","locale_sap","lock","locks","many","mapped","matched","measures","median","mssqlnt","multiple","nodetype","ntile","nulls","occurrences_regexpr","one","operations","oracle","orphans","over","parent","parents","partition","pcre","period","pfcg_mapping","preceding","privileged","product","projection","rank","redirected","replace_regexpr","reported","response","responses","root","row","row_number","sap_system_date","save","schema","session","sets","shortdump","siblings","spantree","start","stddev","string_agg","subtotal","sybase","tims_from_timn","tims_to_timn","to_blob","to_clob","total","trace-entry","tstmp_to_dats","tstmp_to_dst","tstmp_to_tims","tstmpl_from_utcl","tstmpl_to_utcl","unbounded","utcl_add_seconds","utcl_current","utcl_seconds_between","uuid","var","verbatim"],builtinFunctions:["abs","acos","asin","atan","bit-set","boolc","boolx","ceil","char_off","charlen","cmax","cmin","concat_lines_of","contains","contains_any_not_of","contains_any_of","cos","cosh","count","count_any_not_of","count_any_of","dbmaxlen","distance","escape","exp","find_any_not_of","find_any_of","find_end","floor","frac","from_mixed","ipow","line_exists","line_index","log","log10","matches","nmax","nmin","numofchar","repeat","rescale","reverse","round","segment","shift_left","shift_right","sign","sin","sinh","sqrt","strlen","substring","substring_after","substring_before","substring_from","substring_to","tan","tanh","to_lower","to_mixed","to_upper","trunc","utclong_add","utclong_current","utclong_diff","xsdbool","xstrlen"],typeKeywords:["b","c","d","decfloat16","decfloat34","f","i","int8","n","p","s","string","t","utclong","x","xstring","any","clike","csequence","decfloat","numeric","simple","xsequence","accp","char","clnt","cuky","curr","datn","dats","d16d","d16n","d16r","d34d","d34n","d34r","dec","df16_dec","df16_raw","df34_dec","df34_raw","fltp","geom_ewkb","int1","int2","int4","lang","lchr","lraw","numc","quan","raw","rawstring","sstring","timn","tims","unit","utcl","df16_scl","df34_scl","prec","varc","abap_bool","abap_false","abap_true","abap_undefined","me","screen","space","super","sy","syst","table_line","*sys*"],builtinMethods:["class_constructor","constructor"],derivedTypes:["%CID","%CID_REF","%CONTROL","%DATA","%ELEMENT","%FAIL","%KEY","%MSG","%PARAM","%PID","%PID_ASSOC","%PID_PARENT","%_HINTS"],cdsLanguage:["@AbapAnnotation","@AbapCatalog","@AccessControl","@API","@ClientDependent","@ClientHandling","@CompatibilityContract","@DataAging","@EndUserText","@Environment","@LanguageDependency","@MappingRole","@Metadata","@MetadataExtension","@ObjectModel","@Scope","@Semantics","$EXTENSION","$SELF"],selectors:["->","->*","=>","~","~*"],operators:[" +"," -","/","*","**","div","mod","=","#","@","+=","-=","*=","/=","**=","&&=","?=","&","&&","bit-and","bit-not","bit-or","bit-xor","m","o","z","<"," >","<=",">=","<>","><","=<","=>","bt","byte-ca","byte-cn","byte-co","byte-cs","byte-na","byte-ns","ca","cn","co","cp","cs","eq","ge","gt","le","lt","na","nb","ne","np","ns","*/","*:","--","/*","//"],symbols:/[=>))*/,{cases:{"@typeKeywords":"type","@keywords":"keyword","@cdsLanguage":"annotation","@derivedTypes":"type","@builtinFunctions":"type","@builtinMethods":"type","@operators":"key","@default":"identifier"}}],[/<[\w]+>/,"identifier"],[/##[\w|_]+/,"comment"],{include:"@whitespace"},[/[:,.]/,"delimiter"],[/[{}()\[\]]/,"@brackets"],[/@symbols/,{cases:{"@selectors":"tag","@operators":"key","@default":""}}],[/'/,{token:"string",bracket:"@open",next:"@stringquote"}],[/`/,{token:"string",bracket:"@open",next:"@stringping"}],[/\|/,{token:"string",bracket:"@open",next:"@stringtemplate"}],[/\d+/,"number"]],stringtemplate:[[/[^\\\|]+/,"string"],[/\\\|/,"string"],[/\|/,{token:"string",bracket:"@close",next:"@pop"}]],stringping:[[/[^\\`]+/,"string"],[/`/,{token:"string",bracket:"@close",next:"@pop"}]],stringquote:[[/[^\\']+/,"string"],[/'/,{token:"string",bracket:"@close",next:"@pop"}]],whitespace:[[/[ \t\r\n]+/,""],[/^\*.*$/,"comment"],[/\".*$/,"comment"]]}}},24900:function(e,t,i){"use strict";i.r(t),(0,i(70266).H)({id:"apex",extensions:[".cls"],aliases:["Apex","apex"],mimetypes:["text/x-apex-source","text/x-apex"],loader:()=>Promise.resolve().then(i.bind(i,13820))})},13820:function(e,t,i){"use strict";i.r(t),i.d(t,{conf:function(){return n},language:function(){return r}});var n={wordPattern:/(-?\d*\.\d\w*)|([^\`\~\!\#\%\^\&\*\(\)\-\=\+\[\{\]\}\\\|\;\:\'\"\,\.\<\>\/\?\s]+)/g,comments:{lineComment:"//",blockComment:["/*","*/"]},brackets:[["{","}"],["[","]"],["(",")"]],autoClosingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:'"',close:'"'},{open:"'",close:"'"}],surroundingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:'"',close:'"'},{open:"'",close:"'"},{open:"<",close:">"}],folding:{markers:{start:new RegExp("^\\s*//\\s*(?:(?:#?region\\b)|(?:))")}}},o=[];["abstract","activate","and","any","array","as","asc","assert","autonomous","begin","bigdecimal","blob","boolean","break","bulk","by","case","cast","catch","char","class","collect","commit","const","continue","convertcurrency","decimal","default","delete","desc","do","double","else","end","enum","exception","exit","export","extends","false","final","finally","float","for","from","future","get","global","goto","group","having","hint","if","implements","import","in","inner","insert","instanceof","int","interface","into","join","last_90_days","last_month","last_n_days","last_week","like","limit","list","long","loop","map","merge","native","new","next_90_days","next_month","next_n_days","next_week","not","null","nulls","number","object","of","on","or","outer","override","package","parallel","pragma","private","protected","public","retrieve","return","returning","rollback","savepoint","search","select","set","short","sort","stat","static","strictfp","super","switch","synchronized","system","testmethod","then","this","this_month","this_week","throw","throws","today","tolabel","tomorrow","transaction","transient","trigger","true","try","type","undelete","update","upsert","using","virtual","void","volatile","webservice","when","where","while","yesterday"].forEach((e=>{o.push(e),o.push(e.toUpperCase()),o.push((e=>e.charAt(0).toUpperCase()+e.substr(1))(e))}));var r={defaultToken:"",tokenPostfix:".apex",keywords:o,operators:["=",">","<","!","~","?",":","==","<=",">=","!=","&&","||","++","--","+","-","*","/","&","|","^","%","<<",">>",">>>","+=","-=","*=","/=","&=","|=","^=","%=","<<=",">>=",">>>="],symbols:/[=>](?!@symbols)/,"@brackets"],[/@symbols/,{cases:{"@operators":"delimiter","@default":""}}],[/@\s*[a-zA-Z_\$][\w\$]*/,"annotation"],[/(@digits)[eE]([\-+]?(@digits))?[fFdD]?/,"number.float"],[/(@digits)\.(@digits)([eE][\-+]?(@digits))?[fFdD]?/,"number.float"],[/(@digits)[fFdD]/,"number.float"],[/(@digits)[lL]?/,"number"],[/[;,.]/,"delimiter"],[/"([^"\\]|\\.)*$/,"string.invalid"],[/'([^'\\]|\\.)*$/,"string.invalid"],[/"/,"string",'@string."'],[/'/,"string","@string.'"],[/'[^\\']'/,"string"],[/(')(@escapes)(')/,["string","string.escape","string"]],[/'/,"string.invalid"]],whitespace:[[/[ \t\r\n]+/,""],[/\/\*\*(?!\/)/,"comment.doc","@apexdoc"],[/\/\*/,"comment","@comment"],[/\/\/.*$/,"comment"]],comment:[[/[^\/*]+/,"comment"],[/\*\//,"comment","@pop"],[/[\/*]/,"comment"]],apexdoc:[[/[^\/*]+/,"comment.doc"],[/\*\//,"comment.doc","@pop"],[/[\/*]/,"comment.doc"]],string:[[/[^\\"']+/,"string"],[/@escapes/,"string.escape"],[/\\./,"string.escape.invalid"],[/["']/,{cases:{"$#==$S2":{token:"string",next:"@pop"},"@default":"string"}}]]}}},23434:function(e,t,i){"use strict";i.r(t),(0,i(70266).H)({id:"azcli",extensions:[".azcli"],aliases:["Azure CLI","azcli"],loader:()=>Promise.resolve().then(i.bind(i,64523))})},64523:function(e,t,i){"use strict";i.r(t),i.d(t,{conf:function(){return n},language:function(){return o}});var n={comments:{lineComment:"#"}},o={defaultToken:"keyword",ignoreCase:!0,tokenPostfix:".azcli",str:/[^#\s]/,tokenizer:{root:[{include:"@comment"},[/\s-+@str*\s*/,{cases:{"@eos":{token:"key.identifier",next:"@popall"},"@default":{token:"key.identifier",next:"@type"}}}],[/^-+@str*\s*/,{cases:{"@eos":{token:"key.identifier",next:"@popall"},"@default":{token:"key.identifier",next:"@type"}}}]],type:[{include:"@comment"},[/-+@str*\s*/,{cases:{"@eos":{token:"key.identifier",next:"@popall"},"@default":"key.identifier"}}],[/@str+\s*/,{cases:{"@eos":{token:"string",next:"@popall"},"@default":"string"}}]],comment:[[/#.*$/,{cases:{"@eos":{token:"comment",next:"@popall"}}}]]}}},63631:function(e,t,i){"use strict";i.r(t),(0,i(70266).H)({id:"bat",extensions:[".bat",".cmd"],aliases:["Batch","bat"],loader:()=>Promise.resolve().then(i.bind(i,41557))})},41557:function(e,t,i){"use strict";i.r(t),i.d(t,{conf:function(){return n},language:function(){return o}});var n={comments:{lineComment:"REM"},brackets:[["{","}"],["[","]"],["(",")"]],autoClosingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:'"',close:'"'}],surroundingPairs:[{open:"[",close:"]"},{open:"(",close:")"},{open:'"',close:'"'}],folding:{markers:{start:new RegExp("^\\s*(::\\s*|REM\\s+)#region"),end:new RegExp("^\\s*(::\\s*|REM\\s+)#endregion")}}},o={defaultToken:"",ignoreCase:!0,tokenPostfix:".bat",brackets:[{token:"delimiter.bracket",open:"{",close:"}"},{token:"delimiter.parenthesis",open:"(",close:")"},{token:"delimiter.square",open:"[",close:"]"}],keywords:/call|defined|echo|errorlevel|exist|for|goto|if|pause|set|shift|start|title|not|pushd|popd/,symbols:/[=>Promise.resolve().then(i.bind(i,20862))})},20862:function(e,t,i){"use strict";i.r(t),i.d(t,{conf:function(){return n},language:function(){return o}});var n={comments:{lineComment:"//",blockComment:["/*","*/"]},brackets:[["{","}"],["[","]"],["(",")"]],surroundingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:"'",close:"'"},{open:"'''",close:"'''"}],autoClosingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:"'",close:"'",notIn:["string","comment"]},{open:"'''",close:"'''",notIn:["string","comment"]}],autoCloseBefore:":.,=}])' \n\t",indentationRules:{increaseIndentPattern:new RegExp("^((?!\\/\\/).)*(\\{[^}\"'`]*|\\([^)\"'`]*|\\[[^\\]\"'`]*)$"),decreaseIndentPattern:new RegExp("^((?!.*?\\/\\*).*\\*/)?\\s*[\\}\\]].*$")}},o={defaultToken:"",tokenPostfix:".bicep",brackets:[{open:"{",close:"}",token:"delimiter.curly"},{open:"[",close:"]",token:"delimiter.square"},{open:"(",close:")",token:"delimiter.parenthesis"}],symbols:/[=>Promise.resolve().then(i.bind(i,71718))})},71718:function(e,t,i){"use strict";i.r(t),i.d(t,{conf:function(){return n},language:function(){return o}});var n={comments:{lineComment:"//",blockComment:["(*","*)"]},brackets:[["{","}"],["[","]"],["(",")"],["<",">"]],autoClosingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:"<",close:">"},{open:"'",close:"'"},{open:'"',close:'"'},{open:"(*",close:"*)"}],surroundingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:"<",close:">"},{open:"'",close:"'"},{open:'"',close:'"'},{open:"(*",close:"*)"}]},o={defaultToken:"",tokenPostfix:".cameligo",ignoreCase:!0,brackets:[{open:"{",close:"}",token:"delimiter.curly"},{open:"[",close:"]",token:"delimiter.square"},{open:"(",close:")",token:"delimiter.parenthesis"},{open:"<",close:">",token:"delimiter.angle"}],keywords:["abs","assert","block","Bytes","case","Crypto","Current","else","failwith","false","for","fun","if","in","let","let%entry","let%init","List","list","Map","map","match","match%nat","mod","not","operation","Operation","of","record","Set","set","sender","skip","source","String","then","to","true","type","with"],typeKeywords:["int","unit","string","tz","nat","bool"],operators:["=",">","<","<=",">=","<>",":",":=","and","mod","or","+","-","*","/","@","&","^","%","->","<-","&&","||"],symbols:/[=><:@\^&|+\-*\/\^%]+/,tokenizer:{root:[[/[a-zA-Z_][\w]*/,{cases:{"@keywords":{token:"keyword.$0"},"@default":"identifier"}}],{include:"@whitespace"},[/[{}()\[\]]/,"@brackets"],[/[<>](?!@symbols)/,"@brackets"],[/@symbols/,{cases:{"@operators":"delimiter","@default":""}}],[/\d*\.\d+([eE][\-+]?\d+)?/,"number.float"],[/\$[0-9a-fA-F]{1,16}/,"number.hex"],[/\d+/,"number"],[/[;,.]/,"delimiter"],[/'([^'\\]|\\.)*$/,"string.invalid"],[/'/,"string","@string"],[/'[^\\']'/,"string"],[/'/,"string.invalid"],[/\#\d+/,"string"]],comment:[[/[^\(\*]+/,"comment"],[/\*\)/,"comment","@pop"],[/\(\*/,"comment"]],string:[[/[^\\']+/,"string"],[/\\./,"string.escape.invalid"],[/'/,{token:"string.quote",bracket:"@close",next:"@pop"}]],whitespace:[[/[ \t\r\n]+/,"white"],[/\(\*/,"comment","@comment"],[/\/\/.*$/,"comment"]]}}},98184:function(e,t,i){"use strict";i.r(t),(0,i(70266).H)({id:"clojure",extensions:[".clj",".cljs",".cljc",".edn"],aliases:["clojure","Clojure"],loader:()=>Promise.resolve().then(i.bind(i,37942))})},37942:function(e,t,i){"use strict";i.r(t),i.d(t,{conf:function(){return n},language:function(){return o}});var n={comments:{lineComment:";;"},brackets:[["[","]"],["(",")"],["{","}"]],autoClosingPairs:[{open:"[",close:"]"},{open:'"',close:'"'},{open:"(",close:")"},{open:"{",close:"}"}],surroundingPairs:[{open:"[",close:"]"},{open:'"',close:'"'},{open:"(",close:")"},{open:"{",close:"}"}]},o={defaultToken:"",ignoreCase:!0,tokenPostfix:".clj",brackets:[{open:"[",close:"]",token:"delimiter.square"},{open:"(",close:")",token:"delimiter.parenthesis"},{open:"{",close:"}",token:"delimiter.curly"}],constants:["true","false","nil"],numbers:/^(?:[+\-]?\d+(?:(?:N|(?:[eE][+\-]?\d+))|(?:\.?\d*(?:M|(?:[eE][+\-]?\d+))?)|\/\d+|[xX][0-9a-fA-F]+|r[0-9a-zA-Z]+)?(?=[\\\[\]\s"#'(),;@^`{}~]|$))/,characters:/^(?:\\(?:backspace|formfeed|newline|return|space|tab|o[0-7]{3}|u[0-9A-Fa-f]{4}|x[0-9A-Fa-f]{4}|.)?(?=[\\\[\]\s"(),;@^`{}~]|$))/,escapes:/^\\(?:["'\\bfnrt]|x[0-9A-Fa-f]{1,4}|u[0-9A-Fa-f]{4}|U[0-9A-Fa-f]{8})/,qualifiedSymbols:/^(?:(?:[^\\\/\[\]\d\s"#'(),;@^`{}~][^\\\[\]\s"(),;@^`{}~]*(?:\.[^\\\/\[\]\d\s"#'(),;@^`{}~][^\\\[\]\s"(),;@^`{}~]*)*\/)?(?:\/|[^\\\/\[\]\d\s"#'(),;@^`{}~][^\\\[\]\s"(),;@^`{}~]*)*(?=[\\\[\]\s"(),;@^`{}~]|$))/,specialForms:[".","catch","def","do","if","monitor-enter","monitor-exit","new","quote","recur","set!","throw","try","var"],coreSymbols:["*","*'","*1","*2","*3","*agent*","*allow-unresolved-vars*","*assert*","*clojure-version*","*command-line-args*","*compile-files*","*compile-path*","*compiler-options*","*data-readers*","*default-data-reader-fn*","*e","*err*","*file*","*flush-on-newline*","*fn-loader*","*in*","*math-context*","*ns*","*out*","*print-dup*","*print-length*","*print-level*","*print-meta*","*print-namespace-maps*","*print-readably*","*read-eval*","*reader-resolver*","*source-path*","*suppress-read*","*unchecked-math*","*use-context-classloader*","*verbose-defrecords*","*warn-on-reflection*","+","+'","-","-'","->","->>","->ArrayChunk","->Eduction","->Vec","->VecNode","->VecSeq","-cache-protocol-fn","-reset-methods","..","/","<","<=","=","==",">",">=","EMPTY-NODE","Inst","StackTraceElement->vec","Throwable->map","accessor","aclone","add-classpath","add-watch","agent","agent-error","agent-errors","aget","alength","alias","all-ns","alter","alter-meta!","alter-var-root","amap","ancestors","and","any?","apply","areduce","array-map","as->","aset","aset-boolean","aset-byte","aset-char","aset-double","aset-float","aset-int","aset-long","aset-short","assert","assoc","assoc!","assoc-in","associative?","atom","await","await-for","await1","bases","bean","bigdec","bigint","biginteger","binding","bit-and","bit-and-not","bit-clear","bit-flip","bit-not","bit-or","bit-set","bit-shift-left","bit-shift-right","bit-test","bit-xor","boolean","boolean-array","boolean?","booleans","bound-fn","bound-fn*","bound?","bounded-count","butlast","byte","byte-array","bytes","bytes?","case","cast","cat","char","char-array","char-escape-string","char-name-string","char?","chars","chunk","chunk-append","chunk-buffer","chunk-cons","chunk-first","chunk-next","chunk-rest","chunked-seq?","class","class?","clear-agent-errors","clojure-version","coll?","comment","commute","comp","comparator","compare","compare-and-set!","compile","complement","completing","concat","cond","cond->","cond->>","condp","conj","conj!","cons","constantly","construct-proxy","contains?","count","counted?","create-ns","create-struct","cycle","dec","dec'","decimal?","declare","dedupe","default-data-readers","definline","definterface","defmacro","defmethod","defmulti","defn","defn-","defonce","defprotocol","defrecord","defstruct","deftype","delay","delay?","deliver","denominator","deref","derive","descendants","destructure","disj","disj!","dissoc","dissoc!","distinct","distinct?","doall","dorun","doseq","dosync","dotimes","doto","double","double-array","double?","doubles","drop","drop-last","drop-while","eduction","empty","empty?","ensure","ensure-reduced","enumeration-seq","error-handler","error-mode","eval","even?","every-pred","every?","ex-data","ex-info","extend","extend-protocol","extend-type","extenders","extends?","false?","ffirst","file-seq","filter","filterv","find","find-keyword","find-ns","find-protocol-impl","find-protocol-method","find-var","first","flatten","float","float-array","float?","floats","flush","fn","fn?","fnext","fnil","for","force","format","frequencies","future","future-call","future-cancel","future-cancelled?","future-done?","future?","gen-class","gen-interface","gensym","get","get-in","get-method","get-proxy-class","get-thread-bindings","get-validator","group-by","halt-when","hash","hash-combine","hash-map","hash-ordered-coll","hash-set","hash-unordered-coll","ident?","identical?","identity","if-let","if-not","if-some","ifn?","import","in-ns","inc","inc'","indexed?","init-proxy","inst-ms","inst-ms*","inst?","instance?","int","int-array","int?","integer?","interleave","intern","interpose","into","into-array","ints","io!","isa?","iterate","iterator-seq","juxt","keep","keep-indexed","key","keys","keyword","keyword?","last","lazy-cat","lazy-seq","let","letfn","line-seq","list","list*","list?","load","load-file","load-reader","load-string","loaded-libs","locking","long","long-array","longs","loop","macroexpand","macroexpand-1","make-array","make-hierarchy","map","map-entry?","map-indexed","map?","mapcat","mapv","max","max-key","memfn","memoize","merge","merge-with","meta","method-sig","methods","min","min-key","mix-collection-hash","mod","munge","name","namespace","namespace-munge","nat-int?","neg-int?","neg?","newline","next","nfirst","nil?","nnext","not","not-any?","not-empty","not-every?","not=","ns","ns-aliases","ns-imports","ns-interns","ns-map","ns-name","ns-publics","ns-refers","ns-resolve","ns-unalias","ns-unmap","nth","nthnext","nthrest","num","number?","numerator","object-array","odd?","or","parents","partial","partition","partition-all","partition-by","pcalls","peek","persistent!","pmap","pop","pop!","pop-thread-bindings","pos-int?","pos?","pr","pr-str","prefer-method","prefers","primitives-classnames","print","print-ctor","print-dup","print-method","print-simple","print-str","printf","println","println-str","prn","prn-str","promise","proxy","proxy-call-with-super","proxy-mappings","proxy-name","proxy-super","push-thread-bindings","pvalues","qualified-ident?","qualified-keyword?","qualified-symbol?","quot","rand","rand-int","rand-nth","random-sample","range","ratio?","rational?","rationalize","re-find","re-groups","re-matcher","re-matches","re-pattern","re-seq","read","read-line","read-string","reader-conditional","reader-conditional?","realized?","record?","reduce","reduce-kv","reduced","reduced?","reductions","ref","ref-history-count","ref-max-history","ref-min-history","ref-set","refer","refer-clojure","reify","release-pending-sends","rem","remove","remove-all-methods","remove-method","remove-ns","remove-watch","repeat","repeatedly","replace","replicate","require","reset!","reset-meta!","reset-vals!","resolve","rest","restart-agent","resultset-seq","reverse","reversible?","rseq","rsubseq","run!","satisfies?","second","select-keys","send","send-off","send-via","seq","seq?","seqable?","seque","sequence","sequential?","set","set-agent-send-executor!","set-agent-send-off-executor!","set-error-handler!","set-error-mode!","set-validator!","set?","short","short-array","shorts","shuffle","shutdown-agents","simple-ident?","simple-keyword?","simple-symbol?","slurp","some","some->","some->>","some-fn","some?","sort","sort-by","sorted-map","sorted-map-by","sorted-set","sorted-set-by","sorted?","special-symbol?","spit","split-at","split-with","str","string?","struct","struct-map","subs","subseq","subvec","supers","swap!","swap-vals!","symbol","symbol?","sync","tagged-literal","tagged-literal?","take","take-last","take-nth","take-while","test","the-ns","thread-bound?","time","to-array","to-array-2d","trampoline","transduce","transient","tree-seq","true?","type","unchecked-add","unchecked-add-int","unchecked-byte","unchecked-char","unchecked-dec","unchecked-dec-int","unchecked-divide-int","unchecked-double","unchecked-float","unchecked-inc","unchecked-inc-int","unchecked-int","unchecked-long","unchecked-multiply","unchecked-multiply-int","unchecked-negate","unchecked-negate-int","unchecked-remainder-int","unchecked-short","unchecked-subtract","unchecked-subtract-int","underive","unquote","unquote-splicing","unreduced","unsigned-bit-shift-right","update","update-in","update-proxy","uri?","use","uuid?","val","vals","var-get","var-set","var?","vary-meta","vec","vector","vector-of","vector?","volatile!","volatile?","vreset!","vswap!","when","when-first","when-let","when-not","when-some","while","with-bindings","with-bindings*","with-in-str","with-loading-context","with-local-vars","with-meta","with-open","with-out-str","with-precision","with-redefs","with-redefs-fn","xml-seq","zero?","zipmap"],tokenizer:{root:[{include:"@whitespace"},[/@numbers/,"number"],[/@characters/,"string"],{include:"@string"},[/[()\[\]{}]/,"@brackets"],[/\/#"(?:\.|(?:")|[^"\n])*"\/g/,"regexp"],[/[#'@^`~]/,"meta"],[/@qualifiedSymbols/,{cases:{"^:.+$":"constant","@specialForms":"keyword","@coreSymbols":"keyword","@constants":"constant","@default":"identifier"}}]],whitespace:[[/[\s,]+/,"white"],[/;.*$/,"comment"],[/\(comment\b/,"comment","@comment"]],comment:[[/\(/,"comment","@push"],[/\)/,"comment","@pop"],[/[^()]/,"comment"]],string:[[/"/,"string","@multiLineString"]],multiLineString:[[/"/,"string","@popall"],[/@escapes/,"string.escape"],[/./,"string"]]}}},3186:function(e,t,i){"use strict";i.r(t),(0,i(70266).H)({id:"coffeescript",extensions:[".coffee"],aliases:["CoffeeScript","coffeescript","coffee"],mimetypes:["text/x-coffeescript","text/coffeescript"],loader:()=>Promise.resolve().then(i.bind(i,90072))})},90072:function(e,t,i){"use strict";i.r(t),i.d(t,{conf:function(){return n},language:function(){return o}});var n={wordPattern:/(-?\d*\.\d\w*)|([^\`\~\!\@\#%\^\&\*\(\)\=\$\-\+\[\{\]\}\\\|\;\:\'\"\,\.\<\>\/\?\s]+)/g,comments:{blockComment:["###","###"],lineComment:"#"},brackets:[["{","}"],["[","]"],["(",")"]],autoClosingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:'"',close:'"'},{open:"'",close:"'"}],surroundingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:'"',close:'"'},{open:"'",close:"'"}],folding:{markers:{start:new RegExp("^\\s*#region\\b"),end:new RegExp("^\\s*#endregion\\b")}}},o={defaultToken:"",ignoreCase:!0,tokenPostfix:".coffee",brackets:[{open:"{",close:"}",token:"delimiter.curly"},{open:"[",close:"]",token:"delimiter.square"},{open:"(",close:")",token:"delimiter.parenthesis"}],regEx:/\/(?!\/\/)(?:[^\/\\]|\\.)*\/[igm]*/,keywords:["and","or","is","isnt","not","on","yes","@","no","off","true","false","null","this","new","delete","typeof","in","instanceof","return","throw","break","continue","debugger","if","else","switch","for","while","do","try","catch","finally","class","extends","super","undefined","then","unless","until","loop","of","by","when"],symbols:/[=>Promise.resolve().then(i.bind(i,97193))}),(0,n.H)({id:"cpp",extensions:[".cpp",".cc",".cxx",".hpp",".hh",".hxx"],aliases:["C++","Cpp","cpp"],loader:()=>Promise.resolve().then(i.bind(i,97193))})},97193:function(e,t,i){"use strict";i.r(t),i.d(t,{conf:function(){return n},language:function(){return o}});var n={comments:{lineComment:"//",blockComment:["/*","*/"]},brackets:[["{","}"],["[","]"],["(",")"]],autoClosingPairs:[{open:"[",close:"]"},{open:"{",close:"}"},{open:"(",close:")"},{open:"'",close:"'",notIn:["string","comment"]},{open:'"',close:'"',notIn:["string"]}],surroundingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:'"',close:'"'},{open:"'",close:"'"}],folding:{markers:{start:new RegExp("^\\s*#pragma\\s+region\\b"),end:new RegExp("^\\s*#pragma\\s+endregion\\b")}}},o={defaultToken:"",tokenPostfix:".cpp",brackets:[{token:"delimiter.curly",open:"{",close:"}"},{token:"delimiter.parenthesis",open:"(",close:")"},{token:"delimiter.square",open:"[",close:"]"},{token:"delimiter.angle",open:"<",close:">"}],keywords:["abstract","amp","array","auto","bool","break","case","catch","char","class","const","constexpr","const_cast","continue","cpu","decltype","default","delegate","delete","do","double","dynamic_cast","each","else","enum","event","explicit","export","extern","false","final","finally","float","for","friend","gcnew","generic","goto","if","in","initonly","inline","int","interface","interior_ptr","internal","literal","long","mutable","namespace","new","noexcept","nullptr","__nullptr","operator","override","partial","pascal","pin_ptr","private","property","protected","public","ref","register","reinterpret_cast","restrict","return","safe_cast","sealed","short","signed","sizeof","static","static_assert","static_cast","struct","switch","template","this","thread_local","throw","tile_static","true","try","typedef","typeid","typename","union","unsigned","using","virtual","void","volatile","wchar_t","where","while","_asm","_based","_cdecl","_declspec","_fastcall","_if_exists","_if_not_exists","_inline","_multiple_inheritance","_pascal","_single_inheritance","_stdcall","_virtual_inheritance","_w64","__abstract","__alignof","__asm","__assume","__based","__box","__builtin_alignof","__cdecl","__clrcall","__declspec","__delegate","__event","__except","__fastcall","__finally","__forceinline","__gc","__hook","__identifier","__if_exists","__if_not_exists","__inline","__int128","__int16","__int32","__int64","__int8","__interface","__leave","__m128","__m128d","__m128i","__m256","__m256d","__m256i","__m64","__multiple_inheritance","__newslot","__nogc","__noop","__nounwind","__novtordisp","__pascal","__pin","__pragma","__property","__ptr32","__ptr64","__raise","__restrict","__resume","__sealed","__single_inheritance","__stdcall","__super","__thiscall","__try","__try_cast","__typeof","__unaligned","__unhook","__uuidof","__value","__virtual_inheritance","__w64","__wchar_t"],operators:["=",">","<","!","~","?",":","==","<=",">=","!=","&&","||","++","--","+","-","*","/","&","|","^","%","<<",">>",">>>","+=","-=","*=","/=","&=","|=","^=","%=","<<=",">>=",">>>="],symbols:/[=>](?!@symbols)/,"@brackets"],[/@symbols/,{cases:{"@operators":"delimiter","@default":""}}],[/\d*\d+[eE]([\-+]?\d+)?(@floatsuffix)/,"number.float"],[/\d*\.\d+([eE][\-+]?\d+)?(@floatsuffix)/,"number.float"],[/0[xX][0-9a-fA-F']*[0-9a-fA-F](@integersuffix)/,"number.hex"],[/0[0-7']*[0-7](@integersuffix)/,"number.octal"],[/0[bB][0-1']*[0-1](@integersuffix)/,"number.binary"],[/\d[\d']*\d(@integersuffix)/,"number"],[/\d(@integersuffix)/,"number"],[/[;,.]/,"delimiter"],[/"([^"\\]|\\.)*$/,"string.invalid"],[/"/,"string","@string"],[/'[^\\']'/,"string"],[/(')(@escapes)(')/,["string","string.escape","string"]],[/'/,"string.invalid"]],whitespace:[[/[ \t\r\n]+/,""],[/\/\*\*(?!\/)/,"comment.doc","@doccomment"],[/\/\*/,"comment","@comment"],[/\/\/.*\\$/,"comment","@linecomment"],[/\/\/.*$/,"comment"]],comment:[[/[^\/*]+/,"comment"],[/\*\//,"comment","@pop"],[/[\/*]/,"comment"]],linecomment:[[/.*[^\\]$/,"comment","@pop"],[/[^]+/,"comment"]],doccomment:[[/[^\/*]+/,"comment.doc"],[/\*\//,"comment.doc","@pop"],[/[\/*]/,"comment.doc"]],string:[[/[^\\"]+/,"string"],[/@escapes/,"string.escape"],[/\\./,"string.escape.invalid"],[/"/,"string","@pop"]],raw:[[/(.*)(\))(?:([^ ()\\\t"]*))(\")/,{cases:{"$3==$S2":["string.raw","string.raw.end","string.raw.end",{token:"string.raw.end",next:"@pop"}],"@default":["string.raw","string.raw","string.raw","string.raw"]}}],[/.*/,"string.raw"]],annotation:[{include:"@whitespace"},[/using|alignas/,"keyword"],[/[a-zA-Z0-9_]+/,"annotation"],[/[,:]/,"delimiter"],[/[()]/,"@brackets"],[/\]\s*\]/,{token:"annotation",next:"@pop"}]],include:[[/(\s*)(<)([^<>]*)(>)/,["","keyword.directive.include.begin","string.include.identifier",{token:"keyword.directive.include.end",next:"@pop"}]],[/(\s*)(")([^"]*)(")/,["","keyword.directive.include.begin","string.include.identifier",{token:"keyword.directive.include.end",next:"@pop"}]]]}}},34669:function(e,t,i){"use strict";i.r(t),(0,i(70266).H)({id:"csharp",extensions:[".cs",".csx",".cake"],aliases:["C#","csharp"],loader:()=>Promise.resolve().then(i.bind(i,90165))})},90165:function(e,t,i){"use strict";i.r(t),i.d(t,{conf:function(){return n},language:function(){return o}});var n={wordPattern:/(-?\d*\.\d\w*)|([^\`\~\!\#\$\%\^\&\*\(\)\-\=\+\[\{\]\}\\\|\;\:\'\"\,\.\<\>\/\?\s]+)/g,comments:{lineComment:"//",blockComment:["/*","*/"]},brackets:[["{","}"],["[","]"],["(",")"]],autoClosingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:"'",close:"'",notIn:["string","comment"]},{open:'"',close:'"',notIn:["string","comment"]}],surroundingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:"<",close:">"},{open:"'",close:"'"},{open:'"',close:'"'}],folding:{markers:{start:new RegExp("^\\s*#region\\b"),end:new RegExp("^\\s*#endregion\\b")}}},o={defaultToken:"",tokenPostfix:".cs",brackets:[{open:"{",close:"}",token:"delimiter.curly"},{open:"[",close:"]",token:"delimiter.square"},{open:"(",close:")",token:"delimiter.parenthesis"},{open:"<",close:">",token:"delimiter.angle"}],keywords:["extern","alias","using","bool","decimal","sbyte","byte","short","ushort","int","uint","long","ulong","char","float","double","object","dynamic","string","assembly","is","as","ref","out","this","base","new","typeof","void","checked","unchecked","default","delegate","var","const","if","else","switch","case","while","do","for","foreach","in","break","continue","goto","return","throw","try","catch","finally","lock","yield","from","let","where","join","on","equals","into","orderby","ascending","descending","select","group","by","namespace","partial","class","field","event","method","param","public","protected","internal","private","abstract","sealed","static","struct","readonly","volatile","virtual","override","params","get","set","add","remove","operator","true","false","implicit","explicit","interface","enum","null","async","await","fixed","sizeof","stackalloc","unsafe","nameof","when"],namespaceFollows:["namespace","using"],parenFollows:["if","for","while","switch","foreach","using","catch","when"],operators:["=","??","||","&&","|","^","&","==","!=","<=",">=","<<","+","-","*","/","%","!","~","++","--","+=","-=","*=","/=","%=","&=","|=","^=","<<=",">>=",">>","=>"],symbols:/[=>](?!@symbols)/,"@brackets"],[/@symbols/,{cases:{"@operators":"delimiter","@default":""}}],[/[0-9_]*\.[0-9_]+([eE][\-+]?\d+)?[fFdD]?/,"number.float"],[/0[xX][0-9a-fA-F_]+/,"number.hex"],[/0[bB][01_]+/,"number.hex"],[/[0-9_]+/,"number"],[/[;,.]/,"delimiter"],[/"([^"\\]|\\.)*$/,"string.invalid"],[/"/,{token:"string.quote",next:"@string"}],[/\$\@"/,{token:"string.quote",next:"@litinterpstring"}],[/\@"/,{token:"string.quote",next:"@litstring"}],[/\$"/,{token:"string.quote",next:"@interpolatedstring"}],[/'[^\\']'/,"string"],[/(')(@escapes)(')/,["string","string.escape","string"]],[/'/,"string.invalid"]],qualified:[[/[a-zA-Z_][\w]*/,{cases:{"@keywords":{token:"keyword.$0"},"@default":"identifier"}}],[/\./,"delimiter"],["","","@pop"]],namespace:[{include:"@whitespace"},[/[A-Z]\w*/,"namespace"],[/[\.=]/,"delimiter"],["","","@pop"]],comment:[[/[^\/*]+/,"comment"],["\\*/","comment","@pop"],[/[\/*]/,"comment"]],string:[[/[^\\"]+/,"string"],[/@escapes/,"string.escape"],[/\\./,"string.escape.invalid"],[/"/,{token:"string.quote",next:"@pop"}]],litstring:[[/[^"]+/,"string"],[/""/,"string.escape"],[/"/,{token:"string.quote",next:"@pop"}]],litinterpstring:[[/[^"{]+/,"string"],[/""/,"string.escape"],[/{{/,"string.escape"],[/}}/,"string.escape"],[/{/,{token:"string.quote",next:"root.litinterpstring"}],[/"/,{token:"string.quote",next:"@pop"}]],interpolatedstring:[[/[^\\"{]+/,"string"],[/@escapes/,"string.escape"],[/\\./,"string.escape.invalid"],[/{{/,"string.escape"],[/}}/,"string.escape"],[/{/,{token:"string.quote",next:"root.interpolatedstring"}],[/"/,{token:"string.quote",next:"@pop"}]],whitespace:[[/^[ \t\v\f]*#((r)|(load))(?=\s)/,"directive.csx"],[/^[ \t\v\f]*#\w.*$/,"namespace.cpp"],[/[ \t\v\f\r\n]+/,""],[/\/\*/,"comment","@comment"],[/\/\/.*$/,"comment"]]}}},3654:function(e,t,i){"use strict";i.r(t),(0,i(70266).H)({id:"csp",extensions:[],aliases:["CSP","csp"],loader:()=>Promise.resolve().then(i.bind(i,49713))})},49713:function(e,t,i){"use strict";i.r(t),i.d(t,{conf:function(){return n},language:function(){return o}});var n={brackets:[],autoClosingPairs:[],surroundingPairs:[]},o={keywords:[],typeKeywords:[],tokenPostfix:".csp",operators:[],symbols:/[=>Promise.resolve().then(i.bind(i,33845))})},33845:function(e,t,i){"use strict";i.r(t),i.d(t,{conf:function(){return n},language:function(){return o}});var n={wordPattern:/(#?-?\d*\.\d\w*%?)|((::|[@#.!:])?[\w-?]+%?)|::|[@#.!:]/g,comments:{blockComment:["/*","*/"]},brackets:[["{","}"],["[","]"],["(",")"]],autoClosingPairs:[{open:"{",close:"}",notIn:["string","comment"]},{open:"[",close:"]",notIn:["string","comment"]},{open:"(",close:")",notIn:["string","comment"]},{open:'"',close:'"',notIn:["string","comment"]},{open:"'",close:"'",notIn:["string","comment"]}],surroundingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:'"',close:'"'},{open:"'",close:"'"}],folding:{markers:{start:new RegExp("^\\s*\\/\\*\\s*#region\\b\\s*(.*?)\\s*\\*\\/"),end:new RegExp("^\\s*\\/\\*\\s*#endregion\\b.*\\*\\/")}}},o={defaultToken:"",tokenPostfix:".css",ws:"[ \t\n\r\f]*",identifier:"-?-?([a-zA-Z]|(\\\\(([0-9a-fA-F]{1,6}\\s?)|[^[0-9a-fA-F])))([\\w\\-]|(\\\\(([0-9a-fA-F]{1,6}\\s?)|[^[0-9a-fA-F])))*",brackets:[{open:"{",close:"}",token:"delimiter.bracket"},{open:"[",close:"]",token:"delimiter.bracket"},{open:"(",close:")",token:"delimiter.parenthesis"},{open:"<",close:">",token:"delimiter.angle"}],tokenizer:{root:[{include:"@selector"}],selector:[{include:"@comments"},{include:"@import"},{include:"@strings"},["[@](keyframes|-webkit-keyframes|-moz-keyframes|-o-keyframes)",{token:"keyword",next:"@keyframedeclaration"}],["[@](page|content|font-face|-moz-document)",{token:"keyword"}],["[@](charset|namespace)",{token:"keyword",next:"@declarationbody"}],["(url-prefix)(\\()",["attribute.value",{token:"delimiter.parenthesis",next:"@urldeclaration"}]],["(url)(\\()",["attribute.value",{token:"delimiter.parenthesis",next:"@urldeclaration"}]],{include:"@selectorname"},["[\\*]","tag"],["[>\\+,]","delimiter"],["\\[",{token:"delimiter.bracket",next:"@selectorattribute"}],["{",{token:"delimiter.bracket",next:"@selectorbody"}]],selectorbody:[{include:"@comments"},["[*_]?@identifier@ws:(?=(\\s|\\d|[^{;}]*[;}]))","attribute.name","@rulevalue"],["}",{token:"delimiter.bracket",next:"@pop"}]],selectorname:[["(\\.|#(?=[^{])|%|(@identifier)|:)+","tag"]],selectorattribute:[{include:"@term"},["]",{token:"delimiter.bracket",next:"@pop"}]],term:[{include:"@comments"},["(url-prefix)(\\()",["attribute.value",{token:"delimiter.parenthesis",next:"@urldeclaration"}]],["(url)(\\()",["attribute.value",{token:"delimiter.parenthesis",next:"@urldeclaration"}]],{include:"@functioninvocation"},{include:"@numbers"},{include:"@name"},{include:"@strings"},["([<>=\\+\\-\\*\\/\\^\\|\\~,])","delimiter"],[",","delimiter"]],rulevalue:[{include:"@comments"},{include:"@strings"},{include:"@term"},["!important","keyword"],[";","delimiter","@pop"],["(?=})",{token:"",next:"@pop"}]],warndebug:[["[@](warn|debug)",{token:"keyword",next:"@declarationbody"}]],import:[["[@](import)",{token:"keyword",next:"@declarationbody"}]],urldeclaration:[{include:"@strings"},["[^)\r\n]+","string"],["\\)",{token:"delimiter.parenthesis",next:"@pop"}]],parenthizedterm:[{include:"@term"},["\\)",{token:"delimiter.parenthesis",next:"@pop"}]],declarationbody:[{include:"@term"},[";","delimiter","@pop"],["(?=})",{token:"",next:"@pop"}]],comments:[["\\/\\*","comment","@comment"],["\\/\\/+.*","comment"]],comment:[["\\*\\/","comment","@pop"],[/[^*/]+/,"comment"],[/./,"comment"]],name:[["@identifier","attribute.value"]],numbers:[["-?(\\d*\\.)?\\d+([eE][\\-+]?\\d+)?",{token:"attribute.value.number",next:"@units"}],["#[0-9a-fA-F_]+(?!\\w)","attribute.value.hex"]],units:[["(em|ex|ch|rem|vmin|vmax|vw|vh|vm|cm|mm|in|px|pt|pc|deg|grad|rad|turn|s|ms|Hz|kHz|%)?","attribute.value.unit","@pop"]],keyframedeclaration:[["@identifier","attribute.value"],["{",{token:"delimiter.bracket",switchTo:"@keyframebody"}]],keyframebody:[{include:"@term"},["{",{token:"delimiter.bracket",next:"@selectorbody"}],["}",{token:"delimiter.bracket",next:"@pop"}]],functioninvocation:[["@identifier\\(",{token:"attribute.value",next:"@functionarguments"}]],functionarguments:[["\\$@identifier@ws:","attribute.name"],["[,]","delimiter"],{include:"@term"},["\\)",{token:"attribute.value",next:"@pop"}]],strings:[['~?"',{token:"string",next:"@stringenddoublequote"}],["~?'",{token:"string",next:"@stringendquote"}]],stringenddoublequote:[["\\\\.","string"],['"',{token:"string",next:"@pop"}],[/[^\\"]+/,"string"],[".","string"]],stringendquote:[["\\\\.","string"],["'",{token:"string",next:"@pop"}],[/[^\\']+/,"string"],[".","string"]]}}},73151:function(e,t,i){"use strict";i.r(t),(0,i(70266).H)({id:"dart",extensions:[".dart"],aliases:["Dart","dart"],mimetypes:["text/x-dart-source","text/x-dart"],loader:()=>Promise.resolve().then(i.bind(i,83453))})},83453:function(e,t,i){"use strict";i.r(t),i.d(t,{conf:function(){return n},language:function(){return o}});var n={comments:{lineComment:"//",blockComment:["/*","*/"]},brackets:[["{","}"],["[","]"],["(",")"]],autoClosingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:"'",close:"'",notIn:["string","comment"]},{open:'"',close:'"',notIn:["string"]},{open:"`",close:"`",notIn:["string","comment"]},{open:"/**",close:" */",notIn:["string"]}],surroundingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:"<",close:">"},{open:"'",close:"'"},{open:"(",close:")"},{open:'"',close:'"'},{open:"`",close:"`"}],folding:{markers:{start:/^\s*\s*#?region\b/,end:/^\s*\s*#?endregion\b/}}},o={defaultToken:"invalid",tokenPostfix:".dart",keywords:["abstract","dynamic","implements","show","as","else","import","static","assert","enum","in","super","async","export","interface","switch","await","extends","is","sync","break","external","library","this","case","factory","mixin","throw","catch","false","new","true","class","final","null","try","const","finally","on","typedef","continue","for","operator","var","covariant","Function","part","void","default","get","rethrow","while","deferred","hide","return","with","do","if","set","yield"],typeKeywords:["int","double","String","bool"],operators:["+","-","*","/","~/","%","++","--","==","!=",">","<",">=","<=","=","-=","/=","%=",">>=","^=","+=","*=","~/=","<<=","&=","!=","||","&&","&","|","^","~","<<",">>","!",">>>","??","?",":","|="],symbols:/[=>](?!@symbols)/,"@brackets"],[/!(?=([^=]|$))/,"delimiter"],[/@symbols/,{cases:{"@operators":"delimiter","@default":""}}],[/(@digits)[eE]([\-+]?(@digits))?/,"number.float"],[/(@digits)\.(@digits)([eE][\-+]?(@digits))?/,"number.float"],[/0[xX](@hexdigits)n?/,"number.hex"],[/0[oO]?(@octaldigits)n?/,"number.octal"],[/0[bB](@binarydigits)n?/,"number.binary"],[/(@digits)n?/,"number"],[/[;,.]/,"delimiter"],[/"([^"\\]|\\.)*$/,"string.invalid"],[/'([^'\\]|\\.)*$/,"string.invalid"],[/"/,"string","@string_double"],[/'/,"string","@string_single"]],whitespace:[[/[ \t\r\n]+/,""],[/\/\*\*(?!\/)/,"comment.doc","@jsdoc"],[/\/\*/,"comment","@comment"],[/\/\/\/.*$/,"comment.doc"],[/\/\/.*$/,"comment"]],comment:[[/[^\/*]+/,"comment"],[/\*\//,"comment","@pop"],[/[\/*]/,"comment"]],jsdoc:[[/[^\/*]+/,"comment.doc"],[/\*\//,"comment.doc","@pop"],[/[\/*]/,"comment.doc"]],regexp:[[/(\{)(\d+(?:,\d*)?)(\})/,["regexp.escape.control","regexp.escape.control","regexp.escape.control"]],[/(\[)(\^?)(?=(?:[^\]\\\/]|\\.)+)/,["regexp.escape.control",{token:"regexp.escape.control",next:"@regexrange"}]],[/(\()(\?:|\?=|\?!)/,["regexp.escape.control","regexp.escape.control"]],[/[()]/,"regexp.escape.control"],[/@regexpctl/,"regexp.escape.control"],[/[^\\\/]/,"regexp"],[/@regexpesc/,"regexp.escape"],[/\\\./,"regexp.invalid"],[/(\/)([gimsuy]*)/,[{token:"regexp",bracket:"@close",next:"@pop"},"keyword.other"]]],regexrange:[[/-/,"regexp.escape.control"],[/\^/,"regexp.invalid"],[/@regexpesc/,"regexp.escape"],[/[^\]]/,"regexp"],[/\]/,{token:"regexp.escape.control",next:"@pop",bracket:"@close"}]],string_double:[[/[^\\"\$]+/,"string"],[/[^\\"]+/,"string"],[/@escapes/,"string.escape"],[/\\./,"string.escape.invalid"],[/"/,"string","@pop"],[/\$\w+/,"identifier"]],string_single:[[/[^\\'\$]+/,"string"],[/@escapes/,"string.escape"],[/\\./,"string.escape.invalid"],[/'/,"string","@pop"],[/\$\w+/,"identifier"]]}}},80631:function(e,t,i){"use strict";i.r(t),(0,i(70266).H)({id:"dockerfile",extensions:[".dockerfile"],filenames:["Dockerfile"],aliases:["Dockerfile"],loader:()=>Promise.resolve().then(i.bind(i,56265))})},56265:function(e,t,i){"use strict";i.r(t),i.d(t,{conf:function(){return n},language:function(){return o}});var n={brackets:[["{","}"],["[","]"],["(",")"]],autoClosingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:'"',close:'"'},{open:"'",close:"'"}],surroundingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:'"',close:'"'},{open:"'",close:"'"}]},o={defaultToken:"",tokenPostfix:".dockerfile",variable:/\${?[\w]+}?/,tokenizer:{root:[{include:"@whitespace"},{include:"@comment"},[/(ONBUILD)(\s+)/,["keyword",""]],[/(ENV)(\s+)([\w]+)/,["keyword","",{token:"variable",next:"@arguments"}]],[/(FROM|MAINTAINER|RUN|EXPOSE|ENV|ADD|ARG|VOLUME|LABEL|USER|WORKDIR|COPY|CMD|STOPSIGNAL|SHELL|HEALTHCHECK|ENTRYPOINT)/,{token:"keyword",next:"@arguments"}]],arguments:[{include:"@whitespace"},{include:"@strings"},[/(@variable)/,{cases:{"@eos":{token:"variable",next:"@popall"},"@default":"variable"}}],[/\\/,{cases:{"@eos":"","@default":""}}],[/./,{cases:{"@eos":{token:"",next:"@popall"},"@default":""}}]],whitespace:[[/\s+/,{cases:{"@eos":{token:"",next:"@popall"},"@default":""}}]],comment:[[/(^#.*$)/,"comment","@popall"]],strings:[[/\\'$/,"","@popall"],[/\\'/,""],[/'$/,"string","@popall"],[/'/,"string","@stringBody"],[/"$/,"string","@popall"],[/"/,"string","@dblStringBody"]],stringBody:[[/[^\\\$']/,{cases:{"@eos":{token:"string",next:"@popall"},"@default":"string"}}],[/\\./,"string.escape"],[/'$/,"string","@popall"],[/'/,"string","@pop"],[/(@variable)/,"variable"],[/\\$/,"string"],[/$/,"string","@popall"]],dblStringBody:[[/[^\\\$"]/,{cases:{"@eos":{token:"string",next:"@popall"},"@default":"string"}}],[/\\./,"string.escape"],[/"$/,"string","@popall"],[/"/,"string","@pop"],[/(@variable)/,"variable"],[/\\$/,"string"],[/$/,"string","@popall"]]}}},10944:function(e,t,i){"use strict";i.r(t),(0,i(70266).H)({id:"ecl",extensions:[".ecl"],aliases:["ECL","Ecl","ecl"],loader:()=>Promise.resolve().then(i.bind(i,82542))})},82542:function(e,t,i){"use strict";i.r(t),i.d(t,{conf:function(){return n},language:function(){return o}});var n={comments:{lineComment:"//",blockComment:["/*","*/"]},brackets:[["{","}"],["[","]"],["(",")"]],autoClosingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:"'",close:"'",notIn:["string","comment"]},{open:'"',close:'"',notIn:["string","comment"]}],surroundingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:"<",close:">"},{open:"'",close:"'"},{open:'"',close:'"'}]},o={defaultToken:"",tokenPostfix:".ecl",ignoreCase:!0,brackets:[{open:"{",close:"}",token:"delimiter.curly"},{open:"[",close:"]",token:"delimiter.square"},{open:"(",close:")",token:"delimiter.parenthesis"},{open:"<",close:">",token:"delimiter.angle"}],pounds:["append","break","declare","demangle","end","for","getdatatype","if","inmodule","loop","mangle","onwarning","option","set","stored","uniquename"].join("|"),keywords:["__compressed__","after","all","and","any","as","atmost","before","beginc","best","between","case","cluster","compressed","compression","const","counter","csv","default","descend","embed","encoding","encrypt","end","endc","endembed","endmacro","enum","escape","except","exclusive","expire","export","extend","fail","few","fileposition","first","flat","forward","from","full","function","functionmacro","group","grouped","heading","hole","ifblock","import","in","inner","interface","internal","joined","keep","keyed","last","left","limit","linkcounted","literal","little_endian","load","local","locale","lookup","lzw","macro","many","maxcount","maxlength","min skew","module","mofn","multiple","named","namespace","nocase","noroot","noscan","nosort","not","noxpath","of","onfail","only","opt","or","outer","overwrite","packed","partition","penalty","physicallength","pipe","prefetch","quote","record","repeat","retry","return","right","right1","right2","rows","rowset","scan","scope","self","separator","service","shared","skew","skip","smart","soapaction","sql","stable","store","terminator","thor","threshold","timelimit","timeout","token","transform","trim","type","unicodeorder","unordered","unsorted","unstable","update","use","validate","virtual","whole","width","wild","within","wnotrim","xml","xpath"],functions:["abs","acos","aggregate","allnodes","apply","ascii","asin","assert","asstring","atan","atan2","ave","build","buildindex","case","catch","choose","choosen","choosesets","clustersize","combine","correlation","cos","cosh","count","covariance","cron","dataset","dedup","define","denormalize","dictionary","distribute","distributed","distribution","ebcdic","enth","error","evaluate","event","eventextra","eventname","exists","exp","fail","failcode","failmessage","fetch","fromunicode","fromxml","getenv","getisvalid","global","graph","group","hash","hash32","hash64","hashcrc","hashmd5","having","httpcall","httpheader","if","iff","index","intformat","isvalid","iterate","join","keydiff","keypatch","keyunicode","length","library","limit","ln","loadxml","local","log","loop","map","matched","matchlength","matchposition","matchtext","matchunicode","max","merge","mergejoin","min","nofold","nolocal","nonempty","normalize","nothor","notify","output","parallel","parse","pipe","power","preload","process","project","pull","random","range","rank","ranked","realformat","recordof","regexfind","regexreplace","regroup","rejected","rollup","round","roundup","row","rowdiff","sample","sequential","set","sin","sinh","sizeof","soapcall","sort","sorted","sqrt","stepped","stored","sum","table","tan","tanh","thisnode","topn","tounicode","toxml","transfer","transform","trim","truncate","typeof","ungroup","unicodeorder","variance","wait","which","workunit","xmldecode","xmlencode","xmltext","xmlunicode"],typesint:["integer","unsigned"].join("|"),typesnum:["data","qstring","string","unicode","utf8","varstring","varunicode"],typesone:["ascii","big_endian","boolean","data","decimal","ebcdic","grouped","integer","linkcounted","pattern","qstring","real","record","rule","set of","streamed","string","token","udecimal","unicode","unsigned","utf8","varstring","varunicode"].join("|"),operators:["+","-","/",":=","<","<>","=",">","\\","and","in","not","or"],symbols:/[=>](?!@symbols)/,"@brackets"],[/@symbols/,{cases:{"@operators":"delimiter","@default":""}}],[/[0-9_]*\.[0-9_]+([eE][\-+]?\d+)?/,"number.float"],[/0[xX][0-9a-fA-F_]+/,"number.hex"],[/0[bB][01]+/,"number.hex"],[/[0-9_]+/,"number"],[/[;,.]/,"delimiter"],[/"([^"\\]|\\.)*$/,"string.invalid"],[/"/,"string","@string"],[/'[^\\']'/,"string"],[/(')(@escapes)(')/,["string","string.escape","string"]],[/'/,"string.invalid"]],whitespace:[[/[ \t\v\f\r\n]+/,""],[/\/\*/,"comment","@comment"],[/\/\/.*$/,"comment"]],comment:[[/[^\/*]+/,"comment"],[/\*\//,"comment","@pop"],[/[\/*]/,"comment"]],string:[[/[^\\']+/,"string"],[/@escapes/,"string.escape"],[/\\./,"string.escape.invalid"],[/'/,"string","@pop"]]}}},25456:function(e,t,i){"use strict";i.r(t),(0,i(70266).H)({id:"elixir",extensions:[".ex",".exs"],aliases:["Elixir","elixir","ex"],loader:()=>Promise.resolve().then(i.bind(i,37125))})},37125:function(e,t,i){"use strict";i.r(t),i.d(t,{conf:function(){return n},language:function(){return o}});var n={comments:{lineComment:"#"},brackets:[["{","}"],["[","]"],["(",")"]],surroundingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:"'",close:"'"},{open:'"',close:'"'}],autoClosingPairs:[{open:"'",close:"'",notIn:["string","comment"]},{open:'"',close:'"',notIn:["comment"]},{open:'"""',close:'"""'},{open:"`",close:"`",notIn:["string","comment"]},{open:"(",close:")"},{open:"{",close:"}"},{open:"[",close:"]"},{open:"<<",close:">>"}],indentationRules:{increaseIndentPattern:/^\s*(after|else|catch|rescue|fn|[^#]*(do|<\-|\->|\{|\[|\=))\s*$/,decreaseIndentPattern:/^\s*((\}|\])\s*$|(after|else|catch|rescue|end)\b)/}},o={defaultToken:"source",tokenPostfix:".elixir",brackets:[{open:"[",close:"]",token:"delimiter.square"},{open:"(",close:")",token:"delimiter.parenthesis"},{open:"{",close:"}",token:"delimiter.curly"},{open:"<<",close:">>",token:"delimiter.angle.special"}],declarationKeywords:["def","defp","defn","defnp","defguard","defguardp","defmacro","defmacrop","defdelegate","defcallback","defmacrocallback","defmodule","defprotocol","defexception","defimpl","defstruct"],operatorKeywords:["and","in","not","or","when"],namespaceKeywords:["alias","import","require","use"],otherKeywords:["after","case","catch","cond","do","else","end","fn","for","if","quote","raise","receive","rescue","super","throw","try","unless","unquote_splicing","unquote","with"],constants:["true","false","nil"],nameBuiltin:["__MODULE__","__DIR__","__ENV__","__CALLER__","__STACKTRACE__"],operator:/-[->]?|!={0,2}|\*{1,2}|\/|\\\\|&{1,3}|\.\.?|\^(?:\^\^)?|\+\+?|<(?:-|<<|=|>|\|>|~>?)?|=~|={1,3}|>(?:=|>>)?|\|~>|\|>|\|{1,3}|~>>?|~~~|::/,variableName:/[a-z_][a-zA-Z0-9_]*[?!]?/,atomName:/[a-zA-Z_][a-zA-Z0-9_@]*[?!]?|@specialAtomName|@operator/,specialAtomName:/\.\.\.|<<>>|%\{\}|%|\{\}/,aliasPart:/[A-Z][a-zA-Z0-9_]*/,moduleName:/@aliasPart(?:\.@aliasPart)*/,sigilSymmetricDelimiter:/"""|'''|"|'|\/|\|/,sigilStartDelimiter:/@sigilSymmetricDelimiter|<|\{|\[|\(/,sigilEndDelimiter:/@sigilSymmetricDelimiter|>|\}|\]|\)/,sigilModifiers:/[a-zA-Z0-9]*/,decimal:/\d(?:_?\d)*/,hex:/[0-9a-fA-F](_?[0-9a-fA-F])*/,octal:/[0-7](_?[0-7])*/,binary:/[01](_?[01])*/,escape:/\\u[0-9a-fA-F]{4}|\\x[0-9a-fA-F]{2}|\\./,tokenizer:{root:[{include:"@whitespace"},{include:"@comments"},{include:"@keywordsShorthand"},{include:"@numbers"},{include:"@identifiers"},{include:"@strings"},{include:"@atoms"},{include:"@sigils"},{include:"@attributes"},{include:"@symbols"}],whitespace:[[/\s+/,"white"]],comments:[[/(#)(.*)/,["comment.punctuation","comment"]]],keywordsShorthand:[[/(@atomName)(:)/,["constant","constant.punctuation"]],[/"(?=([^"]|#\{.*?\}|\\")*":)/,{token:"constant.delimiter",next:"@doubleQuotedStringKeyword"}],[/'(?=([^']|#\{.*?\}|\\')*':)/,{token:"constant.delimiter",next:"@singleQuotedStringKeyword"}]],doubleQuotedStringKeyword:[[/":/,{token:"constant.delimiter",next:"@pop"}],{include:"@stringConstantContentInterpol"}],singleQuotedStringKeyword:[[/':/,{token:"constant.delimiter",next:"@pop"}],{include:"@stringConstantContentInterpol"}],numbers:[[/0b@binary/,"number.binary"],[/0o@octal/,"number.octal"],[/0x@hex/,"number.hex"],[/@decimal\.@decimal([eE]-?@decimal)?/,"number.float"],[/@decimal/,"number"]],identifiers:[[/\b(defp?|defnp?|defmacrop?|defguardp?|defdelegate)(\s+)(@variableName)(?!\s+@operator)/,["keyword.declaration","white",{cases:{unquote:"keyword","@default":"function"}}]],[/(@variableName)(?=\s*\.?\s*\()/,{cases:{"@declarationKeywords":"keyword.declaration","@namespaceKeywords":"keyword","@otherKeywords":"keyword","@default":"function.call"}}],[/(@moduleName)(\s*)(\.)(\s*)(@variableName)/,["type.identifier","white","operator","white","function.call"]],[/(:)(@atomName)(\s*)(\.)(\s*)(@variableName)/,["constant.punctuation","constant","white","operator","white","function.call"]],[/(\|>)(\s*)(@variableName)/,["operator","white",{cases:{"@otherKeywords":"keyword","@default":"function.call"}}]],[/(&)(\s*)(@variableName)/,["operator","white","function.call"]],[/@variableName/,{cases:{"@declarationKeywords":"keyword.declaration","@operatorKeywords":"keyword.operator","@namespaceKeywords":"keyword","@otherKeywords":"keyword","@constants":"constant.language","@nameBuiltin":"variable.language","_.*":"comment.unused","@default":"identifier"}}],[/@moduleName/,"type.identifier"]],strings:[[/"""/,{token:"string.delimiter",next:"@doubleQuotedHeredoc"}],[/'''/,{token:"string.delimiter",next:"@singleQuotedHeredoc"}],[/"/,{token:"string.delimiter",next:"@doubleQuotedString"}],[/'/,{token:"string.delimiter",next:"@singleQuotedString"}]],doubleQuotedHeredoc:[[/"""/,{token:"string.delimiter",next:"@pop"}],{include:"@stringContentInterpol"}],singleQuotedHeredoc:[[/'''/,{token:"string.delimiter",next:"@pop"}],{include:"@stringContentInterpol"}],doubleQuotedString:[[/"/,{token:"string.delimiter",next:"@pop"}],{include:"@stringContentInterpol"}],singleQuotedString:[[/'/,{token:"string.delimiter",next:"@pop"}],{include:"@stringContentInterpol"}],atoms:[[/(:)(@atomName)/,["constant.punctuation","constant"]],[/:"/,{token:"constant.delimiter",next:"@doubleQuotedStringAtom"}],[/:'/,{token:"constant.delimiter",next:"@singleQuotedStringAtom"}]],doubleQuotedStringAtom:[[/"/,{token:"constant.delimiter",next:"@pop"}],{include:"@stringConstantContentInterpol"}],singleQuotedStringAtom:[[/'/,{token:"constant.delimiter",next:"@pop"}],{include:"@stringConstantContentInterpol"}],sigils:[[/~[a-z]@sigilStartDelimiter/,{token:"@rematch",next:"@sigil.interpol"}],[/~[A-Z]@sigilStartDelimiter/,{token:"@rematch",next:"@sigil.noInterpol"}]],sigil:[[/~([a-zA-Z])\{/,{token:"@rematch",switchTo:"@sigilStart.$S2.$1.{.}"}],[/~([a-zA-Z])\[/,{token:"@rematch",switchTo:"@sigilStart.$S2.$1.[.]"}],[/~([a-zA-Z])\(/,{token:"@rematch",switchTo:"@sigilStart.$S2.$1.(.)"}],[/~([a-zA-Z])\"}],[/~([a-zA-Z])(@sigilSymmetricDelimiter)/,{token:"@rematch",switchTo:"@sigilStart.$S2.$1.$2.$2"}]],"sigilStart.interpol.s":[[/~s@sigilStartDelimiter/,{token:"string.delimiter",switchTo:"@sigilContinue.$S2.$S3.$S4.$S5"}]],"sigilContinue.interpol.s":[[/(@sigilEndDelimiter)@sigilModifiers/,{cases:{"$1==$S5":{token:"string.delimiter",next:"@pop"},"@default":"string"}}],{include:"@stringContentInterpol"}],"sigilStart.noInterpol.S":[[/~S@sigilStartDelimiter/,{token:"string.delimiter",switchTo:"@sigilContinue.$S2.$S3.$S4.$S5"}]],"sigilContinue.noInterpol.S":[[/(^|[^\\])\\@sigilEndDelimiter/,"string"],[/(@sigilEndDelimiter)@sigilModifiers/,{cases:{"$1==$S5":{token:"string.delimiter",next:"@pop"},"@default":"string"}}],{include:"@stringContent"}],"sigilStart.interpol.r":[[/~r@sigilStartDelimiter/,{token:"regexp.delimiter",switchTo:"@sigilContinue.$S2.$S3.$S4.$S5"}]],"sigilContinue.interpol.r":[[/(@sigilEndDelimiter)@sigilModifiers/,{cases:{"$1==$S5":{token:"regexp.delimiter",next:"@pop"},"@default":"regexp"}}],{include:"@regexpContentInterpol"}],"sigilStart.noInterpol.R":[[/~R@sigilStartDelimiter/,{token:"regexp.delimiter",switchTo:"@sigilContinue.$S2.$S3.$S4.$S5"}]],"sigilContinue.noInterpol.R":[[/(^|[^\\])\\@sigilEndDelimiter/,"regexp"],[/(@sigilEndDelimiter)@sigilModifiers/,{cases:{"$1==$S5":{token:"regexp.delimiter",next:"@pop"},"@default":"regexp"}}],{include:"@regexpContent"}],"sigilStart.interpol":[[/~([a-zA-Z])@sigilStartDelimiter/,{token:"sigil.delimiter",switchTo:"@sigilContinue.$S2.$S3.$S4.$S5"}]],"sigilContinue.interpol":[[/(@sigilEndDelimiter)@sigilModifiers/,{cases:{"$1==$S5":{token:"sigil.delimiter",next:"@pop"},"@default":"sigil"}}],{include:"@sigilContentInterpol"}],"sigilStart.noInterpol":[[/~([a-zA-Z])@sigilStartDelimiter/,{token:"sigil.delimiter",switchTo:"@sigilContinue.$S2.$S3.$S4.$S5"}]],"sigilContinue.noInterpol":[[/(^|[^\\])\\@sigilEndDelimiter/,"sigil"],[/(@sigilEndDelimiter)@sigilModifiers/,{cases:{"$1==$S5":{token:"sigil.delimiter",next:"@pop"},"@default":"sigil"}}],{include:"@sigilContent"}],attributes:[[/\@(module|type)?doc (~[sS])?"""/,{token:"comment.block.documentation",next:"@doubleQuotedHeredocDocstring"}],[/\@(module|type)?doc (~[sS])?"/,{token:"comment.block.documentation",next:"@doubleQuotedStringDocstring"}],[/\@(module|type)?doc false/,"comment.block.documentation"],[/\@(@variableName)/,"variable"]],doubleQuotedHeredocDocstring:[[/"""/,{token:"comment.block.documentation",next:"@pop"}],{include:"@docstringContent"}],doubleQuotedStringDocstring:[[/"/,{token:"comment.block.documentation",next:"@pop"}],{include:"@docstringContent"}],symbols:[[/\?(\\.|[^\\\s])/,"number.constant"],[/&\d+/,"operator"],[/<<<|>>>/,"operator"],[/[()\[\]\{\}]|<<|>>/,"@brackets"],[/\.\.\./,"identifier"],[/=>/,"punctuation"],[/@operator/,"operator"],[/[:;,.%]/,"punctuation"]],stringContentInterpol:[{include:"@interpolation"},{include:"@escapeChar"},{include:"@stringContent"}],stringContent:[[/./,"string"]],stringConstantContentInterpol:[{include:"@interpolation"},{include:"@escapeChar"},{include:"@stringConstantContent"}],stringConstantContent:[[/./,"constant"]],regexpContentInterpol:[{include:"@interpolation"},{include:"@escapeChar"},{include:"@regexpContent"}],regexpContent:[[/(\s)(#)(\s.*)$/,["white","comment.punctuation","comment"]],[/./,"regexp"]],sigilContentInterpol:[{include:"@interpolation"},{include:"@escapeChar"},{include:"@sigilContent"}],sigilContent:[[/./,"sigil"]],docstringContent:[[/./,"comment.block.documentation"]],escapeChar:[[/@escape/,"constant.character.escape"]],interpolation:[[/#{/,{token:"delimiter.bracket.embed",next:"@interpolationContinue"}]],interpolationContinue:[[/}/,{token:"delimiter.bracket.embed",next:"@pop"}],{include:"@root"}]}}},2395:function(e,t,i){"use strict";i.r(t),(0,i(70266).H)({id:"flow9",extensions:[".flow"],aliases:["Flow9","Flow","flow9","flow"],loader:()=>Promise.resolve().then(i.bind(i,91898))})},91898:function(e,t,i){"use strict";i.r(t),i.d(t,{conf:function(){return n},language:function(){return o}});var n={comments:{blockComment:["/*","*/"],lineComment:"//"},brackets:[["{","}"],["[","]"],["(",")"]],autoClosingPairs:[{open:"{",close:"}",notIn:["string"]},{open:"[",close:"]",notIn:["string"]},{open:"(",close:")",notIn:["string"]},{open:'"',close:'"',notIn:["string"]},{open:"'",close:"'",notIn:["string"]}],surroundingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:'"',close:'"'},{open:"'",close:"'"},{open:"<",close:">"}]},o={defaultToken:"",tokenPostfix:".flow",keywords:["import","require","export","forbid","native","if","else","cast","unsafe","switch","default"],types:["io","mutable","bool","int","double","string","flow","void","ref","true","false","with"],operators:["=",">","<","<=",">=","==","!","!=",":=","::=","&&","||","+","-","*","/","@","&","%",":","->","\\","$","??","^"],symbols:/[@$=>](?!@symbols)/,"delimiter"],[/@symbols/,{cases:{"@operators":"delimiter","@default":""}}],[/((0(x|X)[0-9a-fA-F]*)|(([0-9]+\.?[0-9]*)|(\.[0-9]+))((e|E)(\+|-)?[0-9]+)?)/,"number"],[/[;,.]/,"delimiter"],[/"([^"\\]|\\.)*$/,"string.invalid"],[/"/,"string","@string"]],whitespace:[[/[ \t\r\n]+/,""],[/\/\*/,"comment","@comment"],[/\/\/.*$/,"comment"]],comment:[[/[^\/*]+/,"comment"],[/\*\//,"comment","@pop"],[/[\/*]/,"comment"]],string:[[/[^\\"]+/,"string"],[/@escapes/,"string.escape"],[/\\./,"string.escape.invalid"],[/"/,"string","@pop"]]}}},630:function(e,t,i){"use strict";i.r(t);var n=i(70266);(0,n.H)({id:"freemarker2",extensions:[".ftl",".ftlh",".ftlx"],aliases:["FreeMarker2","Apache FreeMarker2"],loader:()=>Promise.resolve().then(i.bind(i,18993)).then((e=>e.TagAutoInterpolationDollar))}),(0,n.H)({id:"freemarker2.tag-angle.interpolation-dollar",aliases:["FreeMarker2 (Angle/Dollar)","Apache FreeMarker2 (Angle/Dollar)"],loader:()=>Promise.resolve().then(i.bind(i,18993)).then((e=>e.TagAngleInterpolationDollar))}),(0,n.H)({id:"freemarker2.tag-bracket.interpolation-dollar",aliases:["FreeMarker2 (Bracket/Dollar)","Apache FreeMarker2 (Bracket/Dollar)"],loader:()=>Promise.resolve().then(i.bind(i,18993)).then((e=>e.TagBracketInterpolationDollar))}),(0,n.H)({id:"freemarker2.tag-angle.interpolation-bracket",aliases:["FreeMarker2 (Angle/Bracket)","Apache FreeMarker2 (Angle/Bracket)"],loader:()=>Promise.resolve().then(i.bind(i,18993)).then((e=>e.TagAngleInterpolationBracket))}),(0,n.H)({id:"freemarker2.tag-bracket.interpolation-bracket",aliases:["FreeMarker2 (Bracket/Bracket)","Apache FreeMarker2 (Bracket/Bracket)"],loader:()=>Promise.resolve().then(i.bind(i,18993)).then((e=>e.TagBracketInterpolationBracket))}),(0,n.H)({id:"freemarker2.tag-auto.interpolation-dollar",aliases:["FreeMarker2 (Auto/Dollar)","Apache FreeMarker2 (Auto/Dollar)"],loader:()=>Promise.resolve().then(i.bind(i,18993)).then((e=>e.TagAutoInterpolationDollar))}),(0,n.H)({id:"freemarker2.tag-auto.interpolation-bracket",aliases:["FreeMarker2 (Auto/Bracket)","Apache FreeMarker2 (Auto/Bracket)"],loader:()=>Promise.resolve().then(i.bind(i,18993)).then((e=>e.TagAutoInterpolationBracket))})},18993:function(e,t,i){"use strict";i.r(t),i.d(t,{TagAngleInterpolationBracket:function(){return y},TagAngleInterpolationDollar:function(){return C},TagAutoInterpolationBracket:function(){return k},TagAutoInterpolationDollar:function(){return x},TagBracketInterpolationBracket:function(){return S},TagBracketInterpolationDollar:function(){return w}});var n=i(54918),o=Object.defineProperty,r=Object.getOwnPropertyDescriptor,s=Object.getOwnPropertyNames,a=Object.prototype.hasOwnProperty,l={};((e,t,i,n)=>{if(t&&"object"==typeof t||"function"==typeof t)for(let i of s(t))a.call(e,i)||"default"===i||o(e,i,{get:()=>t[i],enumerable:!(n=r(t,i))||n.enumerable})})(l,n);var c=["assign","flush","ftl","return","global","import","include","break","continue","local","nested","nt","setting","stop","t","lt","rt","fallback"],d=["attempt","autoesc","autoEsc","compress","comment","escape","noescape","function","if","list","items","sep","macro","noparse","noParse","noautoesc","noAutoEsc","outputformat","switch","visit","recurse"],u={close:">",id:"angle",open:"<"},h={close:"\\]",id:"bracket",open:"\\["},g={close:"[>\\]]",id:"auto",open:"[<\\[]"},p={close:"\\}",id:"dollar",open1:"\\$",open2:"\\{"},m={close:"\\]",id:"bracket",open1:"\\[",open2:"="};function f(e){return{brackets:[["<",">"],["[","]"],["(",")"],["{","}"]],comments:{blockComment:[`${e.open}--`,`--${e.close}`]},autoCloseBefore:"\n\r\t }]),.:;=",autoClosingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:'"',close:'"',notIn:["string"]},{open:"'",close:"'",notIn:["string"]}],surroundingPairs:[{open:'"',close:'"'},{open:"'",close:"'"},{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:"<",close:">"}],folding:{markers:{start:new RegExp(`${e.open}#(?:${d.join("|")})([^/${e.close}]*(?!/)${e.close})[^${e.open}]*$`),end:new RegExp(`${e.open}/#(?:${d.join("|")})[\\r\\n\\t ]*>`)}},onEnterRules:[{beforeText:new RegExp(`${e.open}#(?!(?:${c.join("|")}))([a-zA-Z_]+)([^/${e.close}]*(?!/)${e.close})[^${e.open}]*$`),afterText:new RegExp(`^${e.open}/#([a-zA-Z_]+)[\\r\\n\\t ]*${e.close}$`),action:{indentAction:l.languages.IndentAction.IndentOutdent}},{beforeText:new RegExp(`${e.open}#(?!(?:${c.join("|")}))([a-zA-Z_]+)([^/${e.close}]*(?!/)${e.close})[^${e.open}]*$`),action:{indentAction:l.languages.IndentAction.Indent}}]}}function _(){return{brackets:[["<",">"],["[","]"],["(",")"],["{","}"]],autoCloseBefore:"\n\r\t }]),.:;=",autoClosingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:'"',close:'"',notIn:["string"]},{open:"'",close:"'",notIn:["string"]}],surroundingPairs:[{open:'"',close:'"'},{open:"'",close:"'"},{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:"<",close:">"}],folding:{markers:{start:new RegExp(`[<\\[]#(?:${d.join("|")})([^/>\\]]*(?!/)[>\\]])[^<\\[]*$`),end:new RegExp(`[<\\[]/#(?:${d.join("|")})[\\r\\n\\t ]*>`)}},onEnterRules:[{beforeText:new RegExp(`[<\\[]#(?!(?:${c.join("|")}))([a-zA-Z_]+)([^/>\\]]*(?!/)[>\\]])[^[<\\[]]*$`),afterText:new RegExp("^[<\\[]/#([a-zA-Z_]+)[\\r\\n\\t ]*[>\\]]$"),action:{indentAction:l.languages.IndentAction.IndentOutdent}},{beforeText:new RegExp(`[<\\[]#(?!(?:${c.join("|")}))([a-zA-Z_]+)([^/>\\]]*(?!/)[>\\]])[^[<\\[]]*$`),action:{indentAction:l.languages.IndentAction.Indent}}]}}function b(e,t){const i=`_${e.id}_${t.id}`,n=e=>e.replace(/__id__/g,i),o=e=>{const t=e.source.replace(/__id__/g,i);return new RegExp(t,e.flags)};return{unicode:!0,includeLF:!1,start:n("default__id__"),ignoreCase:!1,defaultToken:"invalid",tokenPostfix:".freemarker2",brackets:[{open:"{",close:"}",token:"delimiter.curly"},{open:"[",close:"]",token:"delimiter.square"},{open:"(",close:")",token:"delimiter.parenthesis"},{open:"<",close:">",token:"delimiter.angle"}],[n("open__id__")]:new RegExp(e.open),[n("close__id__")]:new RegExp(e.close),[n("iOpen1__id__")]:new RegExp(t.open1),[n("iOpen2__id__")]:new RegExp(t.open2),[n("iClose__id__")]:new RegExp(t.close),[n("startTag__id__")]:o(/(@open__id__)(#)/),[n("endTag__id__")]:o(/(@open__id__)(\/#)/),[n("startOrEndTag__id__")]:o(/(@open__id__)(\/?#)/),[n("closeTag1__id__")]:o(/((?:@blank)*)(@close__id__)/),[n("closeTag2__id__")]:o(/((?:@blank)*\/?)(@close__id__)/),blank:/[ \t\n\r]/,keywords:["false","true","in","as","using"],directiveStartCloseTag1:/attempt|recover|sep|auto[eE]sc|no(?:autoe|AutoE)sc|compress|default|no[eE]scape|comment|no[pP]arse/,directiveStartCloseTag2:/else|break|continue|return|stop|flush|t|lt|rt|nt|nested|recurse|fallback|ftl/,directiveStartBlank:/if|else[iI]f|list|for[eE]ach|switch|case|assign|global|local|include|import|function|macro|transform|visit|stop|return|call|setting|output[fF]ormat|nested|recurse|escape|ftl|items/,directiveEndCloseTag1:/if|list|items|sep|recover|attempt|for[eE]ach|local|global|assign|function|macro|output[fF]ormat|auto[eE]sc|no(?:autoe|AutoE)sc|compress|transform|switch|escape|no[eE]scape/,escapedChar:/\\(?:[ntrfbgla\\'"\{=]|(?:x[0-9A-Fa-f]{1,4}))/,asciiDigit:/[0-9]/,integer:/[0-9]+/,nonEscapedIdStartChar:/[\$@-Z_a-z\u00AA\u00B5\u00BA\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u1FFF\u2071\u207F\u2090-\u209C\u2102\u2107\u210A-\u2113\u2115\u2119-\u211D\u2124\u2126\u2128\u212A-\u212D\u212F-\u2139\u213C-\u213F\u2145-\u2149\u214E\u2183-\u2184\u2C00-\u2C2E\u2C30-\u2C5E\u2C60-\u2CE4\u2CEB-\u2CEE\u2CF2-\u2CF3\u2D00-\u2D25\u2D27\u2D2D\u2D30-\u2D67\u2D6F\u2D80-\u2D96\u2DA0-\u2DA6\u2DA8-\u2DAE\u2DB0-\u2DB6\u2DB8-\u2DBE\u2DC0-\u2DC6\u2DC8-\u2DCE\u2DD0-\u2DD6\u2DD8-\u2DDE\u2E2F\u3005-\u3006\u3031-\u3035\u303B-\u303C\u3040-\u318F\u31A0-\u31BA\u31F0-\u31FF\u3300-\u337F\u3400-\u4DB5\u4E00-\uA48C\uA4D0-\uA4FD\uA500-\uA60C\uA610-\uA62B\uA640-\uA66E\uA67F-\uA697\uA6A0-\uA6E5\uA717-\uA71F\uA722-\uA788\uA78B-\uA78E\uA790-\uA793\uA7A0-\uA7AA\uA7F8-\uA801\uA803-\uA805\uA807-\uA80A\uA80C-\uA822\uA840-\uA873\uA882-\uA8B3\uA8D0-\uA8D9\uA8F2-\uA8F7\uA8FB\uA900-\uA925\uA930-\uA946\uA960-\uA97C\uA984-\uA9B2\uA9CF-\uA9D9\uAA00-\uAA28\uAA40-\uAA42\uAA44-\uAA4B\uAA50-\uAA59\uAA60-\uAA76\uAA7A\uAA80-\uAAAF\uAAB1\uAAB5-\uAAB6\uAAB9-\uAABD\uAAC0\uAAC2\uAADB-\uAADD\uAAE0-\uAAEA\uAAF2-\uAAF4\uAB01-\uAB06\uAB09-\uAB0E\uAB11-\uAB16\uAB20-\uAB26\uAB28-\uAB2E\uABC0-\uABE2\uABF0-\uABF9\uAC00-\uD7A3\uD7B0-\uD7C6\uD7CB-\uD7FB\uF900-\uFB06\uFB13-\uFB17\uFB1D\uFB1F-\uFB28\uFB2A-\uFB36\uFB38-\uFB3C\uFB3E\uFB40-\uFB41\uFB43-\uFB44\uFB46-\uFBB1\uFBD3-\uFD3D\uFD50-\uFD8F\uFD92-\uFDC7\uFDF0-\uFDFB\uFE70-\uFE74\uFE76-\uFEFC\uFF10-\uFF19\uFF21-\uFF3A\uFF41-\uFF5A\uFF66-\uFFBE\uFFC2-\uFFC7\uFFCA-\uFFCF\uFFD2-\uFFD7\uFFDA-\uFFDC]/,escapedIdChar:/\\[\-\.:#]/,idStartChar:/(?:@nonEscapedIdStartChar)|(?:@escapedIdChar)/,id:/(?:@idStartChar)(?:(?:@idStartChar)|(?:@asciiDigit))*/,specialHashKeys:/\*\*|\*|false|true|in|as|using/,namedSymbols:/<=|>=|\\lte|\\lt|<|\\gte|\\gt|>|&&|\\and|->|->|==|!=|\+=|-=|\*=|\/=|%=|\+\+|--|<=|&&|\|\||:|\.\.\.|\.\.\*|\.\.<|\.\.!|\?\?|=|<|\+|-|\*|\/|%|\||\.\.|\?|!|&|\.|,|;/,arrows:["->","->"],delimiters:[";",":",",","."],stringOperators:["lte","lt","gte","gt"],noParseTags:["noparse","noParse","comment"],tokenizer:{[n("default__id__")]:[{include:n("@directive_token__id__")},{include:n("@interpolation_and_text_token__id__")}],[n("fmExpression__id__.directive")]:[{include:n("@blank_and_expression_comment_token__id__")},{include:n("@directive_end_token__id__")},{include:n("@expression_token__id__")}],[n("fmExpression__id__.interpolation")]:[{include:n("@blank_and_expression_comment_token__id__")},{include:n("@expression_token__id__")},{include:n("@greater_operators_token__id__")}],[n("inParen__id__.plain")]:[{include:n("@blank_and_expression_comment_token__id__")},{include:n("@directive_end_token__id__")},{include:n("@expression_token__id__")}],[n("inParen__id__.gt")]:[{include:n("@blank_and_expression_comment_token__id__")},{include:n("@expression_token__id__")},{include:n("@greater_operators_token__id__")}],[n("noSpaceExpression__id__")]:[{include:n("@no_space_expression_end_token__id__")},{include:n("@directive_end_token__id__")},{include:n("@expression_token__id__")}],[n("unifiedCall__id__")]:[{include:n("@unified_call_token__id__")}],[n("singleString__id__")]:[{include:n("@string_single_token__id__")}],[n("doubleString__id__")]:[{include:n("@string_double_token__id__")}],[n("rawSingleString__id__")]:[{include:n("@string_single_raw_token__id__")}],[n("rawDoubleString__id__")]:[{include:n("@string_double_raw_token__id__")}],[n("expressionComment__id__")]:[{include:n("@expression_comment_token__id__")}],[n("noParse__id__")]:[{include:n("@no_parse_token__id__")}],[n("terseComment__id__")]:[{include:n("@terse_comment_token__id__")}],[n("directive_token__id__")]:[[o(/(?:@startTag__id__)(@directiveStartCloseTag1)(?:@closeTag1__id__)/),"auto"===e.id?{cases:{"$1==<":{token:"@rematch",switchTo:`@default_angle_${t.id}`},"$1==[":{token:"@rematch",switchTo:`@default_bracket_${t.id}`}}}:[{token:"@brackets.directive"},{token:"delimiter.directive"},{cases:{"@noParseTags":{token:"tag",next:n("@noParse__id__.$3")},"@default":{token:"tag"}}},{token:"delimiter.directive"},{token:"@brackets.directive"}]],[o(/(?:@startTag__id__)(@directiveStartCloseTag2)(?:@closeTag2__id__)/),"auto"===e.id?{cases:{"$1==<":{token:"@rematch",switchTo:`@default_angle_${t.id}`},"$1==[":{token:"@rematch",switchTo:`@default_bracket_${t.id}`}}}:[{token:"@brackets.directive"},{token:"delimiter.directive"},{token:"tag"},{token:"delimiter.directive"},{token:"@brackets.directive"}]],[o(/(?:@startTag__id__)(@directiveStartBlank)(@blank)/),"auto"===e.id?{cases:{"$1==<":{token:"@rematch",switchTo:`@default_angle_${t.id}`},"$1==[":{token:"@rematch",switchTo:`@default_bracket_${t.id}`}}}:[{token:"@brackets.directive"},{token:"delimiter.directive"},{token:"tag"},{token:"",next:n("@fmExpression__id__.directive")}]],[o(/(?:@endTag__id__)(@directiveEndCloseTag1)(?:@closeTag1__id__)/),"auto"===e.id?{cases:{"$1==<":{token:"@rematch",switchTo:`@default_angle_${t.id}`},"$1==[":{token:"@rematch",switchTo:`@default_bracket_${t.id}`}}}:[{token:"@brackets.directive"},{token:"delimiter.directive"},{token:"tag"},{token:"delimiter.directive"},{token:"@brackets.directive"}]],[o(/(@open__id__)(@)/),"auto"===e.id?{cases:{"$1==<":{token:"@rematch",switchTo:`@default_angle_${t.id}`},"$1==[":{token:"@rematch",switchTo:`@default_bracket_${t.id}`}}}:[{token:"@brackets.directive"},{token:"delimiter.directive",next:n("@unifiedCall__id__")}]],[o(/(@open__id__)(\/@)((?:(?:@id)(?:\.(?:@id))*)?)(?:@closeTag1__id__)/),[{token:"@brackets.directive"},{token:"delimiter.directive"},{token:"tag"},{token:"delimiter.directive"},{token:"@brackets.directive"}]],[o(/(@open__id__)#--/),"auto"===e.id?{cases:{"$1==<":{token:"@rematch",switchTo:`@default_angle_${t.id}`},"$1==[":{token:"@rematch",switchTo:`@default_bracket_${t.id}`}}}:{token:"comment",next:n("@terseComment__id__")}],[o(/(?:@startOrEndTag__id__)([a-zA-Z_]+)/),"auto"===e.id?{cases:{"$1==<":{token:"@rematch",switchTo:`@default_angle_${t.id}`},"$1==[":{token:"@rematch",switchTo:`@default_bracket_${t.id}`}}}:[{token:"@brackets.directive"},{token:"delimiter.directive"},{token:"tag.invalid",next:n("@fmExpression__id__.directive")}]]],[n("interpolation_and_text_token__id__")]:[[o(/(@iOpen1__id__)(@iOpen2__id__)/),[{token:"bracket"===t.id?"@brackets.interpolation":"delimiter.interpolation"},{token:"bracket"===t.id?"delimiter.interpolation":"@brackets.interpolation",next:n("@fmExpression__id__.interpolation")}]],[/[\$#<\[\{]|(?:@blank)+|[^\$<#\[\{\n\r\t ]+/,{token:"source"}]],[n("string_single_token__id__")]:[[/[^'\\]/,{token:"string"}],[/@escapedChar/,{token:"string.escape"}],[/'/,{token:"string",next:"@pop"}]],[n("string_double_token__id__")]:[[/[^"\\]/,{token:"string"}],[/@escapedChar/,{token:"string.escape"}],[/"/,{token:"string",next:"@pop"}]],[n("string_single_raw_token__id__")]:[[/[^']+/,{token:"string.raw"}],[/'/,{token:"string.raw",next:"@pop"}]],[n("string_double_raw_token__id__")]:[[/[^"]+/,{token:"string.raw"}],[/"/,{token:"string.raw",next:"@pop"}]],[n("expression_token__id__")]:[[/(r?)(['"])/,{cases:{"r'":[{token:"keyword"},{token:"string.raw",next:n("@rawSingleString__id__")}],'r"':[{token:"keyword"},{token:"string.raw",next:n("@rawDoubleString__id__")}],"'":[{token:"source"},{token:"string",next:n("@singleString__id__")}],'"':[{token:"source"},{token:"string",next:n("@doubleString__id__")}]}}],[/(?:@integer)(?:\.(?:@integer))?/,{cases:{"(?:@integer)":{token:"number"},"@default":{token:"number.float"}}}],[/(\.)(@blank*)(@specialHashKeys)/,[{token:"delimiter"},{token:""},{token:"identifier"}]],[/(?:@namedSymbols)/,{cases:{"@arrows":{token:"meta.arrow"},"@delimiters":{token:"delimiter"},"@default":{token:"operators"}}}],[/@id/,{cases:{"@keywords":{token:"keyword.$0"},"@stringOperators":{token:"operators"},"@default":{token:"identifier"}}}],[/[\[\]\(\)\{\}]/,{cases:{"\\[":{cases:{"$S2==gt":{token:"@brackets",next:n("@inParen__id__.gt")},"@default":{token:"@brackets",next:n("@inParen__id__.plain")}}},"\\]":{cases:{..."bracket"===t.id?{"$S2==interpolation":{token:"@brackets.interpolation",next:"@popall"}}:{},..."bracket"===e.id?{"$S2==directive":{token:"@brackets.directive",next:"@popall"}}:{},[n("$S1==inParen__id__")]:{token:"@brackets",next:"@pop"},"@default":{token:"@brackets"}}},"\\(":{token:"@brackets",next:n("@inParen__id__.gt")},"\\)":{cases:{[n("$S1==inParen__id__")]:{token:"@brackets",next:"@pop"},"@default":{token:"@brackets"}}},"\\{":{cases:{"$S2==gt":{token:"@brackets",next:n("@inParen__id__.gt")},"@default":{token:"@brackets",next:n("@inParen__id__.plain")}}},"\\}":{cases:{..."bracket"===t.id?{}:{"$S2==interpolation":{token:"@brackets.interpolation",next:"@popall"}},[n("$S1==inParen__id__")]:{token:"@brackets",next:"@pop"},"@default":{token:"@brackets"}}}}}],[/\$\{/,{token:"delimiter.invalid"}]],[n("blank_and_expression_comment_token__id__")]:[[/(?:@blank)+/,{token:""}],[/[<\[][#!]--/,{token:"comment",next:n("@expressionComment__id__")}]],[n("directive_end_token__id__")]:[[/>/,"bracket"===e.id?{token:"operators"}:{token:"@brackets.directive",next:"@popall"}],[o(/(\/)(@close__id__)/),[{token:"delimiter.directive"},{token:"@brackets.directive",next:"@popall"}]]],[n("greater_operators_token__id__")]:[[/>/,{token:"operators"}],[/>=/,{token:"operators"}]],[n("no_space_expression_end_token__id__")]:[[/(?:@blank)+/,{token:"",switchTo:n("@fmExpression__id__.directive")}]],[n("unified_call_token__id__")]:[[/(@id)((?:@blank)+)/,[{token:"tag"},{token:"",next:n("@fmExpression__id__.directive")}]],[o(/(@id)(\/?)(@close__id__)/),[{token:"tag"},{token:"delimiter.directive"},{token:"@brackets.directive",next:"@popall"}]],[/./,{token:"@rematch",next:n("@noSpaceExpression__id__")}]],[n("no_parse_token__id__")]:[[o(/(@open__id__)(\/#?)([a-zA-Z]+)((?:@blank)*)(@close__id__)/),{cases:{"$S2==$3":[{token:"@brackets.directive"},{token:"delimiter.directive"},{token:"tag"},{token:""},{token:"@brackets.directive",next:"@popall"}],"$S2==comment":[{token:"comment"},{token:"comment"},{token:"comment"},{token:"comment"},{token:"comment"}],"@default":[{token:"source"},{token:"source"},{token:"source"},{token:"source"},{token:"source"}]}}],[/[^<\[\-]+|[<\[\-]/,{cases:{"$S2==comment":{token:"comment"},"@default":{token:"source"}}}]],[n("expression_comment_token__id__")]:[[/--[>\]]/,{token:"comment",next:"@pop"}],[/[^\->\]]+|[>\]\-]/,{token:"comment"}]],[n("terse_comment_token__id__")]:[[o(/--(?:@close__id__)/),{token:"comment",next:"@popall"}],[/[^<\[\-]+|[<\[\-]/,{token:"comment"}]]}}}function v(e){const t=b(u,e),i=b(h,e),n=b(g,e);return{...t,...i,...n,unicode:!0,includeLF:!1,start:`default_auto_${e.id}`,ignoreCase:!1,defaultToken:"invalid",tokenPostfix:".freemarker2",brackets:[{open:"{",close:"}",token:"delimiter.curly"},{open:"[",close:"]",token:"delimiter.square"},{open:"(",close:")",token:"delimiter.parenthesis"},{open:"<",close:">",token:"delimiter.angle"}],tokenizer:{...t.tokenizer,...i.tokenizer,...n.tokenizer}}}var C={conf:f(u),language:b(u,p)},w={conf:f(h),language:b(h,p)},y={conf:f(u),language:b(u,m)},S={conf:f(h),language:b(h,m)},x={conf:_(),language:v(p)},k={conf:_(),language:v(m)}},4275:function(e,t,i){"use strict";i.r(t),(0,i(70266).H)({id:"fsharp",extensions:[".fs",".fsi",".ml",".mli",".fsx",".fsscript"],aliases:["F#","FSharp","fsharp"],loader:()=>Promise.resolve().then(i.bind(i,74950))})},74950:function(e,t,i){"use strict";i.r(t),i.d(t,{conf:function(){return n},language:function(){return o}});var n={comments:{lineComment:"//",blockComment:["(*","*)"]},brackets:[["{","}"],["[","]"],["(",")"]],autoClosingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:'"',close:'"'}],surroundingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:'"',close:'"'},{open:"'",close:"'"}],folding:{markers:{start:new RegExp("^\\s*//\\s*#region\\b|^\\s*\\(\\*\\s*#region(.*)\\*\\)"),end:new RegExp("^\\s*//\\s*#endregion\\b|^\\s*\\(\\*\\s*#endregion\\s*\\*\\)")}}},o={defaultToken:"",tokenPostfix:".fs",keywords:["abstract","and","atomic","as","assert","asr","base","begin","break","checked","component","const","constraint","constructor","continue","class","default","delegate","do","done","downcast","downto","elif","else","end","exception","eager","event","external","extern","false","finally","for","fun","function","fixed","functor","global","if","in","include","inherit","inline","interface","internal","land","lor","lsl","lsr","lxor","lazy","let","match","member","mod","module","mutable","namespace","method","mixin","new","not","null","of","open","or","object","override","private","parallel","process","protected","pure","public","rec","return","static","sealed","struct","sig","then","to","true","tailcall","trait","try","type","upcast","use","val","void","virtual","volatile","when","while","with","yield"],symbols:/[=>\]/,"annotation"],[/^#(if|else|endif)/,"keyword"],[/[{}()\[\]]/,"@brackets"],[/[<>](?!@symbols)/,"@brackets"],[/@symbols/,"delimiter"],[/\d*\d+[eE]([\-+]?\d+)?(@floatsuffix)/,"number.float"],[/\d*\.\d+([eE][\-+]?\d+)?(@floatsuffix)/,"number.float"],[/0x[0-9a-fA-F]+LF/,"number.float"],[/0x[0-9a-fA-F]+(@integersuffix)/,"number.hex"],[/0b[0-1]+(@integersuffix)/,"number.bin"],[/\d+(@integersuffix)/,"number"],[/[;,.]/,"delimiter"],[/"([^"\\]|\\.)*$/,"string.invalid"],[/"""/,"string",'@string."""'],[/"/,"string",'@string."'],[/\@"/,{token:"string.quote",next:"@litstring"}],[/'[^\\']'B?/,"string"],[/(')(@escapes)(')/,["string","string.escape","string"]],[/'/,"string.invalid"]],whitespace:[[/[ \t\r\n]+/,""],[/\(\*(?!\))/,"comment","@comment"],[/\/\/.*$/,"comment"]],comment:[[/[^*(]+/,"comment"],[/\*\)/,"comment","@pop"],[/\*/,"comment"],[/\(\*\)/,"comment"],[/\(/,"comment"]],string:[[/[^\\"]+/,"string"],[/@escapes/,"string.escape"],[/\\./,"string.escape.invalid"],[/("""|"B?)/,{cases:{"$#==$S2":{token:"string",next:"@pop"},"@default":"string"}}]],litstring:[[/[^"]+/,"string"],[/""/,"string.escape"],[/"/,{token:"string.quote",next:"@pop"}]]}}},61089:function(e,t,i){"use strict";i.r(t),(0,i(70266).H)({id:"go",extensions:[".go"],aliases:["Go"],loader:()=>Promise.resolve().then(i.bind(i,13238))})},13238:function(e,t,i){"use strict";i.r(t),i.d(t,{conf:function(){return n},language:function(){return o}});var n={comments:{lineComment:"//",blockComment:["/*","*/"]},brackets:[["{","}"],["[","]"],["(",")"]],autoClosingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:"`",close:"`",notIn:["string"]},{open:'"',close:'"',notIn:["string"]},{open:"'",close:"'",notIn:["string","comment"]}],surroundingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:"`",close:"`"},{open:'"',close:'"'},{open:"'",close:"'"}]},o={defaultToken:"",tokenPostfix:".go",keywords:["break","case","chan","const","continue","default","defer","else","fallthrough","for","func","go","goto","if","import","interface","map","package","range","return","select","struct","switch","type","var","bool","true","false","uint8","uint16","uint32","uint64","int8","int16","int32","int64","float32","float64","complex64","complex128","byte","rune","uint","int","uintptr","string","nil"],operators:["+","-","*","/","%","&","|","^","<<",">>","&^","+=","-=","*=","/=","%=","&=","|=","^=","<<=",">>=","&^=","&&","||","<-","++","--","==","<",">","=","!","!=","<=",">=",":=","...","(",")","","]","{","}",",",";",".",":"],symbols:/[=>](?!@symbols)/,"@brackets"],[/@symbols/,{cases:{"@operators":"delimiter","@default":""}}],[/\d*\d+[eE]([\-+]?\d+)?/,"number.float"],[/\d*\.\d+([eE][\-+]?\d+)?/,"number.float"],[/0[xX][0-9a-fA-F']*[0-9a-fA-F]/,"number.hex"],[/0[0-7']*[0-7]/,"number.octal"],[/0[bB][0-1']*[0-1]/,"number.binary"],[/\d[\d']*/,"number"],[/\d/,"number"],[/[;,.]/,"delimiter"],[/"([^"\\]|\\.)*$/,"string.invalid"],[/"/,"string","@string"],[/`/,"string","@rawstring"],[/'[^\\']'/,"string"],[/(')(@escapes)(')/,["string","string.escape","string"]],[/'/,"string.invalid"]],whitespace:[[/[ \t\r\n]+/,""],[/\/\*\*(?!\/)/,"comment.doc","@doccomment"],[/\/\*/,"comment","@comment"],[/\/\/.*$/,"comment"]],comment:[[/[^\/*]+/,"comment"],[/\*\//,"comment","@pop"],[/[\/*]/,"comment"]],doccomment:[[/[^\/*]+/,"comment.doc"],[/\/\*/,"comment.doc.invalid"],[/\*\//,"comment.doc","@pop"],[/[\/*]/,"comment.doc"]],string:[[/[^\\"]+/,"string"],[/@escapes/,"string.escape"],[/\\./,"string.escape.invalid"],[/"/,"string","@pop"]],rawstring:[[/[^\`]/,"string"],[/`/,"string","@pop"]]}}},80527:function(e,t,i){"use strict";i.r(t),(0,i(70266).H)({id:"graphql",extensions:[".graphql",".gql"],aliases:["GraphQL","graphql","gql"],mimetypes:["application/graphql"],loader:()=>Promise.resolve().then(i.bind(i,43634))})},43634:function(e,t,i){"use strict";i.r(t),i.d(t,{conf:function(){return n},language:function(){return o}});var n={comments:{lineComment:"#"},brackets:[["{","}"],["[","]"],["(",")"]],autoClosingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:'"""',close:'"""',notIn:["string","comment"]},{open:'"',close:'"',notIn:["string","comment"]}],surroundingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:'"""',close:'"""'},{open:'"',close:'"'}],folding:{offSide:!0}},o={defaultToken:"invalid",tokenPostfix:".gql",keywords:["null","true","false","query","mutation","subscription","extend","schema","directive","scalar","type","interface","union","enum","input","implements","fragment","on"],typeKeywords:["Int","Float","String","Boolean","ID"],directiveLocations:["SCHEMA","SCALAR","OBJECT","FIELD_DEFINITION","ARGUMENT_DEFINITION","INTERFACE","UNION","ENUM","ENUM_VALUE","INPUT_OBJECT","INPUT_FIELD_DEFINITION","QUERY","MUTATION","SUBSCRIPTION","FIELD","FRAGMENT_DEFINITION","FRAGMENT_SPREAD","INLINE_FRAGMENT","VARIABLE_DEFINITION"],operators:["=","!","?",":","&","|"],symbols:/[=!?:&|]+/,escapes:/\\(?:["\\\/bfnrt]|u[0-9A-Fa-f]{4})/,tokenizer:{root:[[/[a-z_][\w$]*/,{cases:{"@keywords":"keyword","@default":"key.identifier"}}],[/[$][\w$]*/,{cases:{"@keywords":"keyword","@default":"argument.identifier"}}],[/[A-Z][\w\$]*/,{cases:{"@typeKeywords":"keyword","@default":"type.identifier"}}],{include:"@whitespace"},[/[{}()\[\]]/,"@brackets"],[/@symbols/,{cases:{"@operators":"operator","@default":""}}],[/@\s*[a-zA-Z_\$][\w\$]*/,{token:"annotation",log:"annotation token: $0"}],[/\d*\.\d+([eE][\-+]?\d+)?/,"number.float"],[/0[xX][0-9a-fA-F]+/,"number.hex"],[/\d+/,"number"],[/[;,.]/,"delimiter"],[/"""/,{token:"string",next:"@mlstring",nextEmbedded:"markdown"}],[/"([^"\\]|\\.)*$/,"string.invalid"],[/"/,{token:"string.quote",bracket:"@open",next:"@string"}]],mlstring:[[/[^"]+/,"string"],['"""',{token:"string",next:"@pop",nextEmbedded:"@pop"}]],string:[[/[^\\"]+/,"string"],[/@escapes/,"string.escape"],[/\\./,"string.escape.invalid"],[/"/,{token:"string.quote",bracket:"@close",next:"@pop"}]],whitespace:[[/[ \t\r\n]+/,""],[/#.*$/,"comment"]]}}},9243:function(e,t,i){"use strict";i.r(t),(0,i(70266).H)({id:"handlebars",extensions:[".handlebars",".hbs"],aliases:["Handlebars","handlebars","hbs"],mimetypes:["text/x-handlebars-template"],loader:()=>Promise.resolve().then(i.bind(i,41750))})},41750:function(e,t,i){"use strict";i.r(t),i.d(t,{conf:function(){return d},language:function(){return u}});var n=i(54918),o=Object.defineProperty,r=Object.getOwnPropertyDescriptor,s=Object.getOwnPropertyNames,a=Object.prototype.hasOwnProperty,l={};((e,t,i,n)=>{if(t&&"object"==typeof t||"function"==typeof t)for(let i of s(t))a.call(e,i)||"default"===i||o(e,i,{get:()=>t[i],enumerable:!(n=r(t,i))||n.enumerable})})(l,n);var c=["area","base","br","col","embed","hr","img","input","keygen","link","menuitem","meta","param","source","track","wbr"],d={wordPattern:/(-?\d*\.\d\w*)|([^\`\~\!\@\$\^\&\*\(\)\=\+\[\{\]\}\\\|\;\:\'\"\,\.\<\>\/\s]+)/g,comments:{blockComment:["{{!--","--}}"]},brackets:[["\x3c!--","--\x3e"],["<",">"],["{{","}}"],["{","}"],["(",")"]],autoClosingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:'"',close:'"'},{open:"'",close:"'"}],surroundingPairs:[{open:"<",close:">"},{open:'"',close:'"'},{open:"'",close:"'"}],onEnterRules:[{beforeText:new RegExp(`<(?!(?:${c.join("|")}))(\\w[\\w\\d]*)([^/>]*(?!/)>)[^<]*$`,"i"),afterText:/^<\/(\w[\w\d]*)\s*>$/i,action:{indentAction:l.languages.IndentAction.IndentOutdent}},{beforeText:new RegExp(`<(?!(?:${c.join("|")}))(\\w[\\w\\d]*)([^/>]*(?!/)>)[^<]*$`,"i"),action:{indentAction:l.languages.IndentAction.Indent}}]},u={defaultToken:"",tokenPostfix:"",tokenizer:{root:[[/\{\{!--/,"comment.block.start.handlebars","@commentBlock"],[/\{\{!/,"comment.start.handlebars","@comment"],[/\{\{/,{token:"@rematch",switchTo:"@handlebarsInSimpleState.root"}],[/)/,["delimiter.html","tag.html","delimiter.html"]],[/(<)(script)/,["delimiter.html",{token:"tag.html",next:"@script"}]],[/(<)(style)/,["delimiter.html",{token:"tag.html",next:"@style"}]],[/(<)([:\w]+)/,["delimiter.html",{token:"tag.html",next:"@otherTag"}]],[/(<\/)(\w+)/,["delimiter.html",{token:"tag.html",next:"@otherTag"}]],[/]+/,"metatag.content.html"],[/>/,"metatag.html","@pop"]],comment:[[/\}\}/,"comment.end.handlebars","@pop"],[/./,"comment.content.handlebars"]],commentBlock:[[/--\}\}/,"comment.block.end.handlebars","@pop"],[/./,"comment.content.handlebars"]],commentHtml:[[/\{\{/,{token:"@rematch",switchTo:"@handlebarsInSimpleState.comment"}],[/-->/,"comment.html","@pop"],[/[^-]+/,"comment.content.html"],[/./,"comment.content.html"]],otherTag:[[/\{\{/,{token:"@rematch",switchTo:"@handlebarsInSimpleState.otherTag"}],[/\/?>/,"delimiter.html","@pop"],[/"([^"]*)"/,"attribute.value"],[/'([^']*)'/,"attribute.value"],[/[\w\-]+/,"attribute.name"],[/=/,"delimiter"],[/[ \t\r\n]+/]],script:[[/\{\{/,{token:"@rematch",switchTo:"@handlebarsInSimpleState.script"}],[/type/,"attribute.name","@scriptAfterType"],[/"([^"]*)"/,"attribute.value"],[/'([^']*)'/,"attribute.value"],[/[\w\-]+/,"attribute.name"],[/=/,"delimiter"],[/>/,{token:"delimiter.html",next:"@scriptEmbedded.text/javascript",nextEmbedded:"text/javascript"}],[/[ \t\r\n]+/],[/(<\/)(script\s*)(>)/,["delimiter.html","tag.html",{token:"delimiter.html",next:"@pop"}]]],scriptAfterType:[[/\{\{/,{token:"@rematch",switchTo:"@handlebarsInSimpleState.scriptAfterType"}],[/=/,"delimiter","@scriptAfterTypeEquals"],[/>/,{token:"delimiter.html",next:"@scriptEmbedded.text/javascript",nextEmbedded:"text/javascript"}],[/[ \t\r\n]+/],[/<\/script\s*>/,{token:"@rematch",next:"@pop"}]],scriptAfterTypeEquals:[[/\{\{/,{token:"@rematch",switchTo:"@handlebarsInSimpleState.scriptAfterTypeEquals"}],[/"([^"]*)"/,{token:"attribute.value",switchTo:"@scriptWithCustomType.$1"}],[/'([^']*)'/,{token:"attribute.value",switchTo:"@scriptWithCustomType.$1"}],[/>/,{token:"delimiter.html",next:"@scriptEmbedded.text/javascript",nextEmbedded:"text/javascript"}],[/[ \t\r\n]+/],[/<\/script\s*>/,{token:"@rematch",next:"@pop"}]],scriptWithCustomType:[[/\{\{/,{token:"@rematch",switchTo:"@handlebarsInSimpleState.scriptWithCustomType.$S2"}],[/>/,{token:"delimiter.html",next:"@scriptEmbedded.$S2",nextEmbedded:"$S2"}],[/"([^"]*)"/,"attribute.value"],[/'([^']*)'/,"attribute.value"],[/[\w\-]+/,"attribute.name"],[/=/,"delimiter"],[/[ \t\r\n]+/],[/<\/script\s*>/,{token:"@rematch",next:"@pop"}]],scriptEmbedded:[[/\{\{/,{token:"@rematch",switchTo:"@handlebarsInEmbeddedState.scriptEmbedded.$S2",nextEmbedded:"@pop"}],[/<\/script/,{token:"@rematch",next:"@pop",nextEmbedded:"@pop"}]],style:[[/\{\{/,{token:"@rematch",switchTo:"@handlebarsInSimpleState.style"}],[/type/,"attribute.name","@styleAfterType"],[/"([^"]*)"/,"attribute.value"],[/'([^']*)'/,"attribute.value"],[/[\w\-]+/,"attribute.name"],[/=/,"delimiter"],[/>/,{token:"delimiter.html",next:"@styleEmbedded.text/css",nextEmbedded:"text/css"}],[/[ \t\r\n]+/],[/(<\/)(style\s*)(>)/,["delimiter.html","tag.html",{token:"delimiter.html",next:"@pop"}]]],styleAfterType:[[/\{\{/,{token:"@rematch",switchTo:"@handlebarsInSimpleState.styleAfterType"}],[/=/,"delimiter","@styleAfterTypeEquals"],[/>/,{token:"delimiter.html",next:"@styleEmbedded.text/css",nextEmbedded:"text/css"}],[/[ \t\r\n]+/],[/<\/style\s*>/,{token:"@rematch",next:"@pop"}]],styleAfterTypeEquals:[[/\{\{/,{token:"@rematch",switchTo:"@handlebarsInSimpleState.styleAfterTypeEquals"}],[/"([^"]*)"/,{token:"attribute.value",switchTo:"@styleWithCustomType.$1"}],[/'([^']*)'/,{token:"attribute.value",switchTo:"@styleWithCustomType.$1"}],[/>/,{token:"delimiter.html",next:"@styleEmbedded.text/css",nextEmbedded:"text/css"}],[/[ \t\r\n]+/],[/<\/style\s*>/,{token:"@rematch",next:"@pop"}]],styleWithCustomType:[[/\{\{/,{token:"@rematch",switchTo:"@handlebarsInSimpleState.styleWithCustomType.$S2"}],[/>/,{token:"delimiter.html",next:"@styleEmbedded.$S2",nextEmbedded:"$S2"}],[/"([^"]*)"/,"attribute.value"],[/'([^']*)'/,"attribute.value"],[/[\w\-]+/,"attribute.name"],[/=/,"delimiter"],[/[ \t\r\n]+/],[/<\/style\s*>/,{token:"@rematch",next:"@pop"}]],styleEmbedded:[[/\{\{/,{token:"@rematch",switchTo:"@handlebarsInEmbeddedState.styleEmbedded.$S2",nextEmbedded:"@pop"}],[/<\/style/,{token:"@rematch",next:"@pop",nextEmbedded:"@pop"}]],handlebarsInSimpleState:[[/\{\{\{?/,"delimiter.handlebars"],[/\}\}\}?/,{token:"delimiter.handlebars",switchTo:"@$S2.$S3"}],{include:"handlebarsRoot"}],handlebarsInEmbeddedState:[[/\{\{\{?/,"delimiter.handlebars"],[/\}\}\}?/,{token:"delimiter.handlebars",switchTo:"@$S2.$S3",nextEmbedded:"$S3"}],{include:"handlebarsRoot"}],handlebarsRoot:[[/"[^"]*"/,"string.handlebars"],[/[#/][^\s}]+/,"keyword.helper.handlebars"],[/else\b/,"keyword.helper.handlebars"],[/[\s]+/],[/[^}]/,"variable.parameter.handlebars"]]}}},64825:function(e,t,i){"use strict";i.r(t),(0,i(70266).H)({id:"hcl",extensions:[".tf",".tfvars",".hcl"],aliases:["Terraform","tf","HCL","hcl"],loader:()=>Promise.resolve().then(i.bind(i,17042))})},17042:function(e,t,i){"use strict";i.r(t),i.d(t,{conf:function(){return n},language:function(){return o}});var n={comments:{lineComment:"#",blockComment:["/*","*/"]},brackets:[["{","}"],["[","]"],["(",")"]],autoClosingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:'"',close:'"',notIn:["string"]}],surroundingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:'"',close:'"'}]},o={defaultToken:"",tokenPostfix:".hcl",keywords:["var","local","path","for_each","any","string","number","bool","true","false","null","if ","else ","endif ","for ","in","endfor"],operators:["=",">=","<=","==","!=","+","-","*","/","%","&&","||","!","<",">","?","...",":"],symbols:/[=>](?!@symbols)/,"@brackets"],[/@symbols/,{cases:{"@operators":"operator","@default":""}}],[/\d*\d+[eE]([\-+]?\d+)?/,"number.float"],[/\d*\.\d+([eE][\-+]?\d+)?/,"number.float"],[/\d[\d']*/,"number"],[/\d/,"number"],[/[;,.]/,"delimiter"],[/"/,"string","@string"],[/'/,"invalid"]],heredoc:[[/<<[-]*\s*["]?([\w\-]+)["]?/,{token:"string.heredoc.delimiter",next:"@heredocBody.$1"}]],heredocBody:[[/([\w\-]+)$/,{cases:{"$1==$S2":[{token:"string.heredoc.delimiter",next:"@popall"}],"@default":"string.heredoc"}}],[/./,"string.heredoc"]],whitespace:[[/[ \t\r\n]+/,""],[/\/\*/,"comment","@comment"],[/\/\/.*$/,"comment"],[/#.*$/,"comment"]],comment:[[/[^\/*]+/,"comment"],[/\*\//,"comment","@pop"],[/[\/*]/,"comment"]],string:[[/\$\{/,{token:"delimiter",next:"@stringExpression"}],[/[^\\"\$]+/,"string"],[/@escapes/,"string.escape"],[/\\./,"string.escape.invalid"],[/"/,"string","@popall"]],stringInsideExpression:[[/[^\\"]+/,"string"],[/@escapes/,"string.escape"],[/\\./,"string.escape.invalid"],[/"/,"string","@pop"]],stringExpression:[[/\}/,{token:"delimiter",next:"@pop"}],[/"/,"string","@stringInsideExpression"],{include:"@terraform"}]}}},77322:function(e,t,i){"use strict";i.r(t),(0,i(70266).H)({id:"html",extensions:[".html",".htm",".shtml",".xhtml",".mdoc",".jsp",".asp",".aspx",".jshtm"],aliases:["HTML","htm","html","xhtml"],mimetypes:["text/html","text/x-jshtm","text/template","text/ng-template"],loader:()=>Promise.resolve().then(i.bind(i,25231))})},25231:function(e,t,i){"use strict";i.r(t),i.d(t,{conf:function(){return d},language:function(){return u}});var n=i(54918),o=Object.defineProperty,r=Object.getOwnPropertyDescriptor,s=Object.getOwnPropertyNames,a=Object.prototype.hasOwnProperty,l={};((e,t,i,n)=>{if(t&&"object"==typeof t||"function"==typeof t)for(let i of s(t))a.call(e,i)||"default"===i||o(e,i,{get:()=>t[i],enumerable:!(n=r(t,i))||n.enumerable})})(l,n);var c=["area","base","br","col","embed","hr","img","input","keygen","link","menuitem","meta","param","source","track","wbr"],d={wordPattern:/(-?\d*\.\d\w*)|([^\`\~\!\@\$\^\&\*\(\)\=\+\[\{\]\}\\\|\;\:\'\"\,\.\<\>\/\s]+)/g,comments:{blockComment:["\x3c!--","--\x3e"]},brackets:[["\x3c!--","--\x3e"],["<",">"],["{","}"],["(",")"]],autoClosingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:'"',close:'"'},{open:"'",close:"'"}],surroundingPairs:[{open:'"',close:'"'},{open:"'",close:"'"},{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:"<",close:">"}],onEnterRules:[{beforeText:new RegExp(`<(?!(?:${c.join("|")}))([_:\\w][_:\\w-.\\d]*)([^/>]*(?!/)>)[^<]*$`,"i"),afterText:/^<\/([_:\w][_:\w-.\d]*)\s*>$/i,action:{indentAction:l.languages.IndentAction.IndentOutdent}},{beforeText:new RegExp(`<(?!(?:${c.join("|")}))(\\w[\\w\\d]*)([^/>]*(?!/)>)[^<]*$`,"i"),action:{indentAction:l.languages.IndentAction.Indent}}],folding:{markers:{start:new RegExp("^\\s*\x3c!--\\s*#region\\b.*--\x3e"),end:new RegExp("^\\s*\x3c!--\\s*#endregion\\b.*--\x3e")}}},u={defaultToken:"",tokenPostfix:".html",ignoreCase:!0,tokenizer:{root:[[/)/,["delimiter","tag","","delimiter"]],[/(<)(script)/,["delimiter",{token:"tag",next:"@script"}]],[/(<)(style)/,["delimiter",{token:"tag",next:"@style"}]],[/(<)((?:[\w\-]+:)?[\w\-]+)/,["delimiter",{token:"tag",next:"@otherTag"}]],[/(<\/)((?:[\w\-]+:)?[\w\-]+)/,["delimiter",{token:"tag",next:"@otherTag"}]],[/]+/,"metatag.content"],[/>/,"metatag","@pop"]],comment:[[/-->/,"comment","@pop"],[/[^-]+/,"comment.content"],[/./,"comment.content"]],otherTag:[[/\/?>/,"delimiter","@pop"],[/"([^"]*)"/,"attribute.value"],[/'([^']*)'/,"attribute.value"],[/[\w\-]+/,"attribute.name"],[/=/,"delimiter"],[/[ \t\r\n]+/]],script:[[/type/,"attribute.name","@scriptAfterType"],[/"([^"]*)"/,"attribute.value"],[/'([^']*)'/,"attribute.value"],[/[\w\-]+/,"attribute.name"],[/=/,"delimiter"],[/>/,{token:"delimiter",next:"@scriptEmbedded",nextEmbedded:"text/javascript"}],[/[ \t\r\n]+/],[/(<\/)(script\s*)(>)/,["delimiter","tag",{token:"delimiter",next:"@pop"}]]],scriptAfterType:[[/=/,"delimiter","@scriptAfterTypeEquals"],[/>/,{token:"delimiter",next:"@scriptEmbedded",nextEmbedded:"text/javascript"}],[/[ \t\r\n]+/],[/<\/script\s*>/,{token:"@rematch",next:"@pop"}]],scriptAfterTypeEquals:[[/"([^"]*)"/,{token:"attribute.value",switchTo:"@scriptWithCustomType.$1"}],[/'([^']*)'/,{token:"attribute.value",switchTo:"@scriptWithCustomType.$1"}],[/>/,{token:"delimiter",next:"@scriptEmbedded",nextEmbedded:"text/javascript"}],[/[ \t\r\n]+/],[/<\/script\s*>/,{token:"@rematch",next:"@pop"}]],scriptWithCustomType:[[/>/,{token:"delimiter",next:"@scriptEmbedded.$S2",nextEmbedded:"$S2"}],[/"([^"]*)"/,"attribute.value"],[/'([^']*)'/,"attribute.value"],[/[\w\-]+/,"attribute.name"],[/=/,"delimiter"],[/[ \t\r\n]+/],[/<\/script\s*>/,{token:"@rematch",next:"@pop"}]],scriptEmbedded:[[/<\/script/,{token:"@rematch",next:"@pop",nextEmbedded:"@pop"}],[/[^<]+/,""]],style:[[/type/,"attribute.name","@styleAfterType"],[/"([^"]*)"/,"attribute.value"],[/'([^']*)'/,"attribute.value"],[/[\w\-]+/,"attribute.name"],[/=/,"delimiter"],[/>/,{token:"delimiter",next:"@styleEmbedded",nextEmbedded:"text/css"}],[/[ \t\r\n]+/],[/(<\/)(style\s*)(>)/,["delimiter","tag",{token:"delimiter",next:"@pop"}]]],styleAfterType:[[/=/,"delimiter","@styleAfterTypeEquals"],[/>/,{token:"delimiter",next:"@styleEmbedded",nextEmbedded:"text/css"}],[/[ \t\r\n]+/],[/<\/style\s*>/,{token:"@rematch",next:"@pop"}]],styleAfterTypeEquals:[[/"([^"]*)"/,{token:"attribute.value",switchTo:"@styleWithCustomType.$1"}],[/'([^']*)'/,{token:"attribute.value",switchTo:"@styleWithCustomType.$1"}],[/>/,{token:"delimiter",next:"@styleEmbedded",nextEmbedded:"text/css"}],[/[ \t\r\n]+/],[/<\/style\s*>/,{token:"@rematch",next:"@pop"}]],styleWithCustomType:[[/>/,{token:"delimiter",next:"@styleEmbedded.$S2",nextEmbedded:"$S2"}],[/"([^"]*)"/,"attribute.value"],[/'([^']*)'/,"attribute.value"],[/[\w\-]+/,"attribute.name"],[/=/,"delimiter"],[/[ \t\r\n]+/],[/<\/style\s*>/,{token:"@rematch",next:"@pop"}]],styleEmbedded:[[/<\/style/,{token:"@rematch",next:"@pop",nextEmbedded:"@pop"}],[/[^<]+/,""]]}}},62965:function(e,t,i){"use strict";i.r(t),(0,i(70266).H)({id:"ini",extensions:[".ini",".properties",".gitconfig"],filenames:["config",".gitattributes",".gitconfig",".editorconfig"],aliases:["Ini","ini"],loader:()=>Promise.resolve().then(i.bind(i,9178))})},9178:function(e,t,i){"use strict";i.r(t),i.d(t,{conf:function(){return n},language:function(){return o}});var n={comments:{lineComment:"#"},brackets:[["{","}"],["[","]"],["(",")"]],autoClosingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:'"',close:'"'},{open:"'",close:"'"}],surroundingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:'"',close:'"'},{open:"'",close:"'"}]},o={defaultToken:"",tokenPostfix:".ini",escapes:/\\(?:[abfnrtv\\"']|x[0-9A-Fa-f]{1,4}|u[0-9A-Fa-f]{4}|U[0-9A-Fa-f]{8})/,tokenizer:{root:[[/^\[[^\]]*\]/,"metatag"],[/(^\w+)(\s*)(\=)/,["key","","delimiter"]],{include:"@whitespace"},[/\d+/,"number"],[/"([^"\\]|\\.)*$/,"string.invalid"],[/'([^'\\]|\\.)*$/,"string.invalid"],[/"/,"string",'@string."'],[/'/,"string","@string.'"]],whitespace:[[/[ \t\r\n]+/,""],[/^\s*[#;].*$/,"comment"]],string:[[/[^\\"']+/,"string"],[/@escapes/,"string.escape"],[/\\./,"string.escape.invalid"],[/["']/,{cases:{"$#==$S2":{token:"string",next:"@pop"},"@default":"string"}}]]}}},80571:function(e,t,i){"use strict";i.r(t),(0,i(70266).H)({id:"java",extensions:[".java",".jav"],aliases:["Java","java"],mimetypes:["text/x-java-source","text/x-java"],loader:()=>Promise.resolve().then(i.bind(i,65311))})},65311:function(e,t,i){"use strict";i.r(t),i.d(t,{conf:function(){return n},language:function(){return o}});var n={wordPattern:/(-?\d*\.\d\w*)|([^\`\~\!\#\%\^\&\*\(\)\-\=\+\[\{\]\}\\\|\;\:\'\"\,\.\<\>\/\?\s]+)/g,comments:{lineComment:"//",blockComment:["/*","*/"]},brackets:[["{","}"],["[","]"],["(",")"]],autoClosingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:'"',close:'"'},{open:"'",close:"'"}],surroundingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:'"',close:'"'},{open:"'",close:"'"},{open:"<",close:">"}],folding:{markers:{start:new RegExp("^\\s*//\\s*(?:(?:#?region\\b)|(?:))")}}},o={defaultToken:"",tokenPostfix:".java",keywords:["abstract","continue","for","new","switch","assert","default","goto","package","synchronized","boolean","do","if","private","this","break","double","implements","protected","throw","byte","else","import","public","throws","case","enum","instanceof","return","transient","catch","extends","int","short","try","char","final","interface","static","void","class","finally","long","strictfp","volatile","const","float","native","super","while","true","false","yield","record","sealed","non-sealed","permits"],operators:["=",">","<","!","~","?",":","==","<=",">=","!=","&&","||","++","--","+","-","*","/","&","|","^","%","<<",">>",">>>","+=","-=","*=","/=","&=","|=","^=","%=","<<=",">>=",">>>="],symbols:/[=>](?!@symbols)/,"@brackets"],[/@symbols/,{cases:{"@operators":"delimiter","@default":""}}],[/@\s*[a-zA-Z_\$][\w\$]*/,"annotation"],[/(@digits)[eE]([\-+]?(@digits))?[fFdD]?/,"number.float"],[/(@digits)\.(@digits)([eE][\-+]?(@digits))?[fFdD]?/,"number.float"],[/0[xX](@hexdigits)[Ll]?/,"number.hex"],[/0(@octaldigits)[Ll]?/,"number.octal"],[/0[bB](@binarydigits)[Ll]?/,"number.binary"],[/(@digits)[fFdD]/,"number.float"],[/(@digits)[lL]?/,"number"],[/[;,.]/,"delimiter"],[/"([^"\\]|\\.)*$/,"string.invalid"],[/"""/,"string","@multistring"],[/"/,"string","@string"],[/'[^\\']'/,"string"],[/(')(@escapes)(')/,["string","string.escape","string"]],[/'/,"string.invalid"]],whitespace:[[/[ \t\r\n]+/,""],[/\/\*\*(?!\/)/,"comment.doc","@javadoc"],[/\/\*/,"comment","@comment"],[/\/\/.*$/,"comment"]],comment:[[/[^\/*]+/,"comment"],[/\*\//,"comment","@pop"],[/[\/*]/,"comment"]],javadoc:[[/[^\/*]+/,"comment.doc"],[/\/\*/,"comment.doc.invalid"],[/\*\//,"comment.doc","@pop"],[/[\/*]/,"comment.doc"]],string:[[/[^\\"]+/,"string"],[/@escapes/,"string.escape"],[/\\./,"string.escape.invalid"],[/"/,"string","@pop"]],multistring:[[/[^\\"]+/,"string"],[/@escapes/,"string.escape"],[/\\./,"string.escape.invalid"],[/"""/,"string","@pop"],[/./,"string"]]}}},89852:function(e,t,i){"use strict";i.r(t),(0,i(70266).H)({id:"javascript",extensions:[".js",".es6",".jsx",".mjs",".cjs"],firstLine:"^#!.*\\bnode",filenames:["jakefile"],aliases:["JavaScript","javascript","js"],mimetypes:["text/javascript"],loader:()=>Promise.resolve().then(i.bind(i,79785))})},79785:function(e,t,i){"use strict";i.r(t),i.d(t,{conf:function(){return o},language:function(){return r}});var n=i(18815),o=n.conf,r={defaultToken:"invalid",tokenPostfix:".js",keywords:["break","case","catch","class","continue","const","constructor","debugger","default","delete","do","else","export","extends","false","finally","for","from","function","get","if","import","in","instanceof","let","new","null","return","set","super","switch","symbol","this","throw","true","try","typeof","undefined","var","void","while","with","yield","async","await","of"],typeKeywords:[],operators:n.language.operators,symbols:n.language.symbols,escapes:n.language.escapes,digits:n.language.digits,octaldigits:n.language.octaldigits,binarydigits:n.language.binarydigits,hexdigits:n.language.hexdigits,regexpctl:n.language.regexpctl,regexpesc:n.language.regexpesc,tokenizer:n.language.tokenizer}},66424:function(e,t,i){"use strict";i.r(t),(0,i(70266).H)({id:"julia",extensions:[".jl"],aliases:["julia","Julia"],loader:()=>Promise.resolve().then(i.bind(i,80594))})},80594:function(e,t,i){"use strict";i.r(t),i.d(t,{conf:function(){return n},language:function(){return o}});var n={brackets:[["{","}"],["[","]"],["(",")"]],autoClosingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:'"',close:'"'},{open:"'",close:"'"}],surroundingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:'"',close:'"'},{open:"'",close:"'"}]},o={tokenPostfix:".julia",keywords:["begin","while","if","for","try","return","break","continue","function","macro","quote","let","local","global","const","do","struct","module","baremodule","using","import","export","end","else","elseif","catch","finally","mutable","primitive","abstract","type","in","isa","where","new"],types:["LinRange","LineNumberNode","LinearIndices","LoadError","MIME","Matrix","Method","MethodError","Missing","MissingException","Module","NTuple","NamedTuple","Nothing","Number","OrdinalRange","OutOfMemoryError","OverflowError","Pair","PartialQuickSort","PermutedDimsArray","Pipe","Ptr","QuoteNode","Rational","RawFD","ReadOnlyMemoryError","Real","ReentrantLock","Ref","Regex","RegexMatch","RoundingMode","SegmentationFault","Set","Signed","Some","StackOverflowError","StepRange","StepRangeLen","StridedArray","StridedMatrix","StridedVecOrMat","StridedVector","String","StringIndexError","SubArray","SubString","SubstitutionString","Symbol","SystemError","Task","Text","TextDisplay","Timer","Tuple","Type","TypeError","TypeVar","UInt","UInt128","UInt16","UInt32","UInt64","UInt8","UndefInitializer","AbstractArray","UndefKeywordError","AbstractChannel","UndefRefError","AbstractChar","UndefVarError","AbstractDict","Union","AbstractDisplay","UnionAll","AbstractFloat","UnitRange","AbstractIrrational","Unsigned","AbstractMatrix","AbstractRange","Val","AbstractSet","Vararg","AbstractString","VecElement","AbstractUnitRange","VecOrMat","AbstractVecOrMat","Vector","AbstractVector","VersionNumber","Any","WeakKeyDict","ArgumentError","WeakRef","Array","AssertionError","BigFloat","BigInt","BitArray","BitMatrix","BitSet","BitVector","Bool","BoundsError","CapturedException","CartesianIndex","CartesianIndices","Cchar","Cdouble","Cfloat","Channel","Char","Cint","Cintmax_t","Clong","Clonglong","Cmd","Colon","Complex","ComplexF16","ComplexF32","ComplexF64","CompositeException","Condition","Cptrdiff_t","Cshort","Csize_t","Cssize_t","Cstring","Cuchar","Cuint","Cuintmax_t","Culong","Culonglong","Cushort","Cvoid","Cwchar_t","Cwstring","DataType","DenseArray","DenseMatrix","DenseVecOrMat","DenseVector","Dict","DimensionMismatch","Dims","DivideError","DomainError","EOFError","Enum","ErrorException","Exception","ExponentialBackOff","Expr","Float16","Float32","Float64","Function","GlobalRef","HTML","IO","IOBuffer","IOContext","IOStream","IdDict","IndexCartesian","IndexLinear","IndexStyle","InexactError","InitError","Int","Int128","Int16","Int32","Int64","Int8","Integer","InterruptException","InvalidStateException","Irrational","KeyError"],keywordops:["<:",">:",":","=>","...",".","->","?"],allops:/[^\w\d\s()\[\]{}"'#]+/,constants:["true","false","nothing","missing","undef","Inf","pi","NaN","π","ℯ","ans","PROGRAM_FILE","ARGS","C_NULL","VERSION","DEPOT_PATH","LOAD_PATH"],operators:["!","!=","!==","%","&","*","+","-","/","//","<","<<","<=","==","===","=>",">",">=",">>",">>>","\\","^","|","|>","~","÷","∈","∉","∋","∌","∘","√","∛","∩","∪","≈","≉","≠","≡","≢","≤","≥","⊆","⊇","⊈","⊉","⊊","⊋","⊻"],brackets:[{open:"(",close:")",token:"delimiter.parenthesis"},{open:"{",close:"}",token:"delimiter.curly"},{open:"[",close:"]",token:"delimiter.square"}],ident:/π|ℯ|\b(?!\d)\w+\b/,escape:/(?:[abefnrstv\\"'\n\r]|[0-7]{1,3}|x[0-9A-Fa-f]{1,2}|u[0-9A-Fa-f]{4})/,escapes:/\\(?:C\-(@escape|.)|c(@escape|.)|@escape)/,tokenizer:{root:[[/(::)\s*|\b(isa)\s+/,"keyword","@typeanno"],[/\b(isa)(\s*\(@ident\s*,\s*)/,["keyword",{token:"",next:"@typeanno"}]],[/\b(type|struct)[ \t]+/,"keyword","@typeanno"],[/^\s*:@ident[!?]?/,"metatag"],[/(return)(\s*:@ident[!?]?)/,["keyword","metatag"]],[/(\(|\[|\{|@allops)(\s*:@ident[!?]?)/,["","metatag"]],[/:\(/,"metatag","@quote"],[/r"""/,"regexp.delim","@tregexp"],[/r"/,"regexp.delim","@sregexp"],[/raw"""/,"string.delim","@rtstring"],[/[bv]?"""/,"string.delim","@dtstring"],[/raw"/,"string.delim","@rsstring"],[/[bv]?"/,"string.delim","@dsstring"],[/(@ident)\{/,{cases:{"$1@types":{token:"type",next:"@gen"},"@default":{token:"type",next:"@gen"}}}],[/@ident[!?'']?(?=\.?\()/,{cases:{"@types":"type","@keywords":"keyword","@constants":"variable","@default":"keyword.flow"}}],[/@ident[!?']?/,{cases:{"@types":"type","@keywords":"keyword","@constants":"variable","@default":"identifier"}}],[/\$\w+/,"key"],[/\$\(/,"key","@paste"],[/@@@ident/,"annotation"],{include:"@whitespace"},[/'(?:@escapes|.)'/,"string.character"],[/[()\[\]{}]/,"@brackets"],[/@allops/,{cases:{"@keywordops":"keyword","@operators":"operator"}}],[/[;,]/,"delimiter"],[/0[xX][0-9a-fA-F](_?[0-9a-fA-F])*/,"number.hex"],[/0[_oO][0-7](_?[0-7])*/,"number.octal"],[/0[bB][01](_?[01])*/,"number.binary"],[/[+\-]?\d+(\.\d+)?(im?|[eE][+\-]?\d+(\.\d+)?)?/,"number"]],typeanno:[[/[a-zA-Z_]\w*(?:\.[a-zA-Z_]\w*)*\{/,"type","@gen"],[/([a-zA-Z_]\w*(?:\.[a-zA-Z_]\w*)*)(\s*<:\s*)/,["type","keyword"]],[/[a-zA-Z_]\w*(?:\.[a-zA-Z_]\w*)*/,"type","@pop"],["","","@pop"]],gen:[[/[a-zA-Z_]\w*(?:\.[a-zA-Z_]\w*)*\{/,"type","@push"],[/[a-zA-Z_]\w*(?:\.[a-zA-Z_]\w*)*/,"type"],[/<:/,"keyword"],[/(\})(\s*<:\s*)/,["type",{token:"keyword",next:"@pop"}]],[/\}/,"type","@pop"],{include:"@root"}],quote:[[/\$\(/,"key","@paste"],[/\(/,"@brackets","@paren"],[/\)/,"metatag","@pop"],{include:"@root"}],paste:[[/:\(/,"metatag","@quote"],[/\(/,"@brackets","@paren"],[/\)/,"key","@pop"],{include:"@root"}],paren:[[/\$\(/,"key","@paste"],[/:\(/,"metatag","@quote"],[/\(/,"@brackets","@push"],[/\)/,"@brackets","@pop"],{include:"@root"}],sregexp:[[/^.*/,"invalid"],[/[^\\"()\[\]{}]/,"regexp"],[/[()\[\]{}]/,"@brackets"],[/\\./,"operator.scss"],[/"[imsx]*/,"regexp.delim","@pop"]],tregexp:[[/[^\\"()\[\]{}]/,"regexp"],[/[()\[\]{}]/,"@brackets"],[/\\./,"operator.scss"],[/"(?!"")/,"string"],[/"""[imsx]*/,"regexp.delim","@pop"]],rsstring:[[/^.*/,"invalid"],[/[^\\"]/,"string"],[/\\./,"string.escape"],[/"/,"string.delim","@pop"]],rtstring:[[/[^\\"]/,"string"],[/\\./,"string.escape"],[/"(?!"")/,"string"],[/"""/,"string.delim","@pop"]],dsstring:[[/^.*/,"invalid"],[/[^\\"\$]/,"string"],[/\$/,"","@interpolated"],[/@escapes/,"string.escape"],[/\\./,"string.escape.invalid"],[/"/,"string.delim","@pop"]],dtstring:[[/[^\\"\$]/,"string"],[/\$/,"","@interpolated"],[/@escapes/,"string.escape"],[/\\./,"string.escape.invalid"],[/"(?!"")/,"string"],[/"""/,"string.delim","@pop"]],interpolated:[[/\(/,{token:"",switchTo:"@interpolated_compound"}],[/[a-zA-Z_]\w*/,"identifier"],["","","@pop"]],interpolated_compound:[[/\)/,"","@pop"],{include:"@root"}],whitespace:[[/[ \t\r\n]+/,""],[/#=/,"comment","@multi_comment"],[/#.*$/,"comment"]],multi_comment:[[/#=/,"comment","@push"],[/=#/,"comment","@pop"],[/=(?!#)|#(?!=)/,"comment"],[/[^#=]+/,"comment"]]}}},93741:function(e,t,i){"use strict";i.r(t),(0,i(70266).H)({id:"kotlin",extensions:[".kt"],aliases:["Kotlin","kotlin"],mimetypes:["text/x-kotlin-source","text/x-kotlin"],loader:()=>Promise.resolve().then(i.bind(i,78933))})},78933:function(e,t,i){"use strict";i.r(t),i.d(t,{conf:function(){return n},language:function(){return o}});var n={wordPattern:/(-?\d*\.\d\w*)|([^\`\~\!\#\%\^\&\*\(\)\-\=\+\[\{\]\}\\\|\;\:\'\"\,\.\<\>\/\?\s]+)/g,comments:{lineComment:"//",blockComment:["/*","*/"]},brackets:[["{","}"],["[","]"],["(",")"]],autoClosingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:'"',close:'"'},{open:"'",close:"'"}],surroundingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:'"',close:'"'},{open:"'",close:"'"},{open:"<",close:">"}],folding:{markers:{start:new RegExp("^\\s*//\\s*(?:(?:#?region\\b)|(?:))")}}},o={defaultToken:"",tokenPostfix:".kt",keywords:["as","as?","break","class","continue","do","else","false","for","fun","if","in","!in","interface","is","!is","null","object","package","return","super","this","throw","true","try","typealias","val","var","when","while","by","catch","constructor","delegate","dynamic","field","file","finally","get","import","init","param","property","receiver","set","setparam","where","actual","abstract","annotation","companion","const","crossinline","data","enum","expect","external","final","infix","inline","inner","internal","lateinit","noinline","open","operator","out","override","private","protected","public","reified","sealed","suspend","tailrec","vararg","field","it"],operators:["+","-","*","/","%","=","+=","-=","*=","/=","%=","++","--","&&","||","!","==","!=","===","!==",">","<","<=",">=","[","]","!!","?.","?:","::","..",":","?","->","@",";","$","_"],symbols:/[=>](?!@symbols)/,"@brackets"],[/@symbols/,{cases:{"@operators":"delimiter","@default":""}}],[/@\s*[a-zA-Z_\$][\w\$]*/,"annotation"],[/(@digits)[eE]([\-+]?(@digits))?[fFdD]?/,"number.float"],[/(@digits)\.(@digits)([eE][\-+]?(@digits))?[fFdD]?/,"number.float"],[/0[xX](@hexdigits)[Ll]?/,"number.hex"],[/0(@octaldigits)[Ll]?/,"number.octal"],[/0[bB](@binarydigits)[Ll]?/,"number.binary"],[/(@digits)[fFdD]/,"number.float"],[/(@digits)[lL]?/,"number"],[/[;,.]/,"delimiter"],[/"([^"\\]|\\.)*$/,"string.invalid"],[/"""/,"string","@multistring"],[/"/,"string","@string"],[/'[^\\']'/,"string"],[/(')(@escapes)(')/,["string","string.escape","string"]],[/'/,"string.invalid"]],whitespace:[[/[ \t\r\n]+/,""],[/\/\*\*(?!\/)/,"comment.doc","@javadoc"],[/\/\*/,"comment","@comment"],[/\/\/.*$/,"comment"]],comment:[[/[^\/*]+/,"comment"],[/\/\*/,"comment","@comment"],[/\*\//,"comment","@pop"],[/[\/*]/,"comment"]],javadoc:[[/[^\/*]+/,"comment.doc"],[/\/\*/,"comment.doc","@push"],[/\/\*/,"comment.doc.invalid"],[/\*\//,"comment.doc","@pop"],[/[\/*]/,"comment.doc"]],string:[[/[^\\"]+/,"string"],[/@escapes/,"string.escape"],[/\\./,"string.escape.invalid"],[/"/,"string","@pop"]],multistring:[[/[^\\"]+/,"string"],[/@escapes/,"string.escape"],[/\\./,"string.escape.invalid"],[/"""/,"string","@pop"],[/./,"string"]]}}},27174:function(e,t,i){"use strict";i.r(t),(0,i(70266).H)({id:"less",extensions:[".less"],aliases:["Less","less"],mimetypes:["text/x-less","text/less"],loader:()=>Promise.resolve().then(i.bind(i,1474))})},1474:function(e,t,i){"use strict";i.r(t),i.d(t,{conf:function(){return n},language:function(){return o}});var n={wordPattern:/(#?-?\d*\.\d\w*%?)|([@#!.:]?[\w-?]+%?)|[@#!.]/g,comments:{blockComment:["/*","*/"],lineComment:"//"},brackets:[["{","}"],["[","]"],["(",")"]],autoClosingPairs:[{open:"{",close:"}",notIn:["string","comment"]},{open:"[",close:"]",notIn:["string","comment"]},{open:"(",close:")",notIn:["string","comment"]},{open:'"',close:'"',notIn:["string","comment"]},{open:"'",close:"'",notIn:["string","comment"]}],surroundingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:'"',close:'"'},{open:"'",close:"'"}],folding:{markers:{start:new RegExp("^\\s*\\/\\*\\s*#region\\b\\s*(.*?)\\s*\\*\\/"),end:new RegExp("^\\s*\\/\\*\\s*#endregion\\b.*\\*\\/")}}},o={defaultToken:"",tokenPostfix:".less",identifier:"-?-?([a-zA-Z]|(\\\\(([0-9a-fA-F]{1,6}\\s?)|[^[0-9a-fA-F])))([\\w\\-]|(\\\\(([0-9a-fA-F]{1,6}\\s?)|[^[0-9a-fA-F])))*",identifierPlus:"-?-?([a-zA-Z:.]|(\\\\(([0-9a-fA-F]{1,6}\\s?)|[^[0-9a-fA-F])))([\\w\\-:.]|(\\\\(([0-9a-fA-F]{1,6}\\s?)|[^[0-9a-fA-F])))*",brackets:[{open:"{",close:"}",token:"delimiter.curly"},{open:"[",close:"]",token:"delimiter.bracket"},{open:"(",close:")",token:"delimiter.parenthesis"},{open:"<",close:">",token:"delimiter.angle"}],tokenizer:{root:[{include:"@nestedJSBegin"},["[ \\t\\r\\n]+",""],{include:"@comments"},{include:"@keyword"},{include:"@strings"},{include:"@numbers"},["[*_]?[a-zA-Z\\-\\s]+(?=:.*(;|(\\\\$)))","attribute.name","@attribute"],["url(\\-prefix)?\\(",{token:"tag",next:"@urldeclaration"}],["[{}()\\[\\]]","@brackets"],["[,:;]","delimiter"],["#@identifierPlus","tag.id"],["&","tag"],["\\.@identifierPlus(?=\\()","tag.class","@attribute"],["\\.@identifierPlus","tag.class"],["@identifierPlus","tag"],{include:"@operators"},["@(@identifier(?=[:,\\)]))","variable","@attribute"],["@(@identifier)","variable"],["@","key","@atRules"]],nestedJSBegin:[["``","delimiter.backtick"],["`",{token:"delimiter.backtick",next:"@nestedJSEnd",nextEmbedded:"text/javascript"}]],nestedJSEnd:[["`",{token:"delimiter.backtick",next:"@pop",nextEmbedded:"@pop"}]],operators:[["[<>=\\+\\-\\*\\/\\^\\|\\~]","operator"]],keyword:[["(@[\\s]*import|![\\s]*important|true|false|when|iscolor|isnumber|isstring|iskeyword|isurl|ispixel|ispercentage|isem|hue|saturation|lightness|alpha|lighten|darken|saturate|desaturate|fadein|fadeout|fade|spin|mix|round|ceil|floor|percentage)\\b","keyword"]],urldeclaration:[{include:"@strings"},["[^)\r\n]+","string"],["\\)",{token:"tag",next:"@pop"}]],attribute:[{include:"@nestedJSBegin"},{include:"@comments"},{include:"@strings"},{include:"@numbers"},{include:"@keyword"},["[a-zA-Z\\-]+(?=\\()","attribute.value","@attribute"],[">","operator","@pop"],["@identifier","attribute.value"],{include:"@operators"},["@(@identifier)","variable"],["[)\\}]","@brackets","@pop"],["[{}()\\[\\]>]","@brackets"],["[;]","delimiter","@pop"],["[,=:]","delimiter"],["\\s",""],[".","attribute.value"]],comments:[["\\/\\*","comment","@comment"],["\\/\\/+.*","comment"]],comment:[["\\*\\/","comment","@pop"],[".","comment"]],numbers:[["(\\d*\\.)?\\d+([eE][\\-+]?\\d+)?",{token:"attribute.value.number",next:"@units"}],["#[0-9a-fA-F_]+(?!\\w)","attribute.value.hex"]],units:[["(em|ex|ch|rem|vmin|vmax|vw|vh|vm|cm|mm|in|px|pt|pc|deg|grad|rad|turn|s|ms|Hz|kHz|%)?","attribute.value.unit","@pop"]],strings:[['~?"',{token:"string.delimiter",next:"@stringsEndDoubleQuote"}],["~?'",{token:"string.delimiter",next:"@stringsEndQuote"}]],stringsEndDoubleQuote:[['\\\\"',"string"],['"',{token:"string.delimiter",next:"@popall"}],[".","string"]],stringsEndQuote:[["\\\\'","string"],["'",{token:"string.delimiter",next:"@popall"}],[".","string"]],atRules:[{include:"@comments"},{include:"@strings"},["[()]","delimiter"],["[\\{;]","delimiter","@pop"],[".","key"]]}}},68971:function(e,t,i){"use strict";i.r(t),(0,i(70266).H)({id:"lexon",extensions:[".lex"],aliases:["Lexon"],loader:()=>Promise.resolve().then(i.bind(i,95897))})},95897:function(e,t,i){"use strict";i.r(t),i.d(t,{conf:function(){return n},language:function(){return o}});var n={comments:{lineComment:"COMMENT"},brackets:[["(",")"]],autoClosingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:'"',close:'"'},{open:":",close:"."}],surroundingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:"`",close:"`"},{open:'"',close:'"'},{open:"'",close:"'"},{open:":",close:"."}],folding:{markers:{start:new RegExp("^\\s*(::\\s*|COMMENT\\s+)#region"),end:new RegExp("^\\s*(::\\s*|COMMENT\\s+)#endregion")}}},o={tokenPostfix:".lexon",ignoreCase:!0,keywords:["lexon","lex","clause","terms","contracts","may","pay","pays","appoints","into","to"],typeKeywords:["amount","person","key","time","date","asset","text"],operators:["less","greater","equal","le","gt","or","and","add","added","subtract","subtracted","multiply","multiplied","times","divide","divided","is","be","certified"],symbols:/[=>](?!@symbols)/,"@brackets"],[/@symbols/,"delimiter"],[/\d*\.\d*\.\d*/,"number.semver"],[/\d*\.\d+([eE][\-+]?\d+)?/,"number.float"],[/0[xX][0-9a-fA-F]+/,"number.hex"],[/\d+/,"number"],[/[;,.]/,"delimiter"]],quoted_identifier:[[/[^\\"]+/,"identifier"],[/"/,{token:"identifier.quote",bracket:"@close",next:"@pop"}]],space_identifier_until_period:[[":","delimiter"],[" ",{token:"white",next:"@identifier_rest"}]],identifier_until_period:[{include:"@whitespace"},[":",{token:"delimiter",next:"@identifier_rest"}],[/[^\\.]+/,"identifier"],[/\./,{token:"delimiter",bracket:"@close",next:"@pop"}]],identifier_rest:[[/[^\\.]+/,"identifier"],[/\./,{token:"delimiter",bracket:"@close",next:"@pop"}]],semver:[{include:"@whitespace"},[":","delimiter"],[/\d*\.\d*\.\d*/,{token:"number.semver",bracket:"@close",next:"@pop"}]],whitespace:[[/[ \t\r\n]+/,"white"]]}}},21401:function(e,t,i){"use strict";i.r(t),(0,i(70266).H)({id:"liquid",extensions:[".liquid",".html.liquid"],aliases:["Liquid","liquid"],mimetypes:["application/liquid"],loader:()=>Promise.resolve().then(i.bind(i,77801))})},77801:function(e,t,i){"use strict";i.r(t),i.d(t,{conf:function(){return d},language:function(){return u}});var n=i(54918),o=Object.defineProperty,r=Object.getOwnPropertyDescriptor,s=Object.getOwnPropertyNames,a=Object.prototype.hasOwnProperty,l={};((e,t,i,n)=>{if(t&&"object"==typeof t||"function"==typeof t)for(let i of s(t))a.call(e,i)||"default"===i||o(e,i,{get:()=>t[i],enumerable:!(n=r(t,i))||n.enumerable})})(l,n);var c=["area","base","br","col","embed","hr","img","input","keygen","link","menuitem","meta","param","source","track","wbr"],d={wordPattern:/(-?\d*\.\d\w*)|([^\`\~\!\@\$\^\&\*\(\)\=\+\[\{\]\}\\\|\;\:\'\"\,\.\<\>\/\s]+)/g,brackets:[["\x3c!--","--\x3e"],["<",">"],["{{","}}"],["{%","%}"],["{","}"],["(",")"]],autoClosingPairs:[{open:"{",close:"}"},{open:"%",close:"%"},{open:"[",close:"]"},{open:"(",close:")"},{open:'"',close:'"'},{open:"'",close:"'"}],surroundingPairs:[{open:"<",close:">"},{open:'"',close:'"'},{open:"'",close:"'"}],onEnterRules:[{beforeText:new RegExp(`<(?!(?:${c.join("|")}))(\\w[\\w\\d]*)([^/>]*(?!/)>)[^<]*$`,"i"),afterText:/^<\/(\w[\w\d]*)\s*>$/i,action:{indentAction:l.languages.IndentAction.IndentOutdent}},{beforeText:new RegExp(`<(?!(?:${c.join("|")}))(\\w[\\w\\d]*)([^/>]*(?!/)>)[^<]*$`,"i"),action:{indentAction:l.languages.IndentAction.Indent}}]},u={defaultToken:"",tokenPostfix:"",builtinTags:["if","else","elseif","endif","render","assign","capture","endcapture","case","endcase","comment","endcomment","cycle","decrement","for","endfor","include","increment","layout","raw","endraw","render","tablerow","endtablerow","unless","endunless"],builtinFilters:["abs","append","at_least","at_most","capitalize","ceil","compact","date","default","divided_by","downcase","escape","escape_once","first","floor","join","json","last","lstrip","map","minus","modulo","newline_to_br","plus","prepend","remove","remove_first","replace","replace_first","reverse","round","rstrip","size","slice","sort","sort_natural","split","strip","strip_html","strip_newlines","times","truncate","truncatewords","uniq","upcase","url_decode","url_encode","where"],constants:["true","false"],operators:["==","!=",">","<",">=","<="],symbol:/[=>)/,["delimiter.html","tag.html","delimiter.html"]],[/(<)([:\w]+)/,["delimiter.html",{token:"tag.html",next:"@otherTag"}]],[/(<\/)([\w\-]+)/,["delimiter.html",{token:"tag.html",next:"@otherTag"}]],[//,"delimiter.html","@pop"],[/"([^"]*)"/,"attribute.value"],[/'([^']*)'/,"attribute.value"],[/[\w\-]+/,"attribute.name"],[/=/,"delimiter"],[/[ \t\r\n]+/]],liquidState:[[/\{\{/,"delimiter.output.liquid"],[/\}\}/,{token:"delimiter.output.liquid",switchTo:"@$S2.$S3"}],[/\{\%/,"delimiter.tag.liquid"],[/raw\s*\%\}/,"delimiter.tag.liquid","@liquidRaw"],[/\%\}/,{token:"delimiter.tag.liquid",switchTo:"@$S2.$S3"}],{include:"liquidRoot"}],liquidRaw:[[/^(?!\{\%\s*endraw\s*\%\}).+/],[/\{\%/,"delimiter.tag.liquid"],[/@identifier/],[/\%\}/,{token:"delimiter.tag.liquid",next:"@root"}]],liquidRoot:[[/\d+(\.\d+)?/,"number.liquid"],[/"[^"]*"/,"string.liquid"],[/'[^']*'/,"string.liquid"],[/\s+/],[/@symbol/,{cases:{"@operators":"operator.liquid","@default":""}}],[/\./],[/@identifier/,{cases:{"@constants":"keyword.liquid","@builtinFilters":"predefined.liquid","@builtinTags":"predefined.liquid","@default":"variable.liquid"}}],[/[^}|%]/,"variable.liquid"]]}}},50612:function(e,t,i){"use strict";i.r(t),(0,i(70266).H)({id:"lua",extensions:[".lua"],aliases:["Lua","lua"],loader:()=>Promise.resolve().then(i.bind(i,21428))})},21428:function(e,t,i){"use strict";i.r(t),i.d(t,{conf:function(){return n},language:function(){return o}});var n={comments:{lineComment:"--",blockComment:["--[[","]]"]},brackets:[["{","}"],["[","]"],["(",")"]],autoClosingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:'"',close:'"'},{open:"'",close:"'"}],surroundingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:'"',close:'"'},{open:"'",close:"'"}]},o={defaultToken:"",tokenPostfix:".lua",keywords:["and","break","do","else","elseif","end","false","for","function","goto","if","in","local","nil","not","or","repeat","return","then","true","until","while"],brackets:[{token:"delimiter.bracket",open:"{",close:"}"},{token:"delimiter.array",open:"[",close:"]"},{token:"delimiter.parenthesis",open:"(",close:")"}],operators:["+","-","*","/","%","^","#","==","~=","<=",">=","<",">","=",";",":",",",".","..","..."],symbols:/[=>Promise.resolve().then(i.bind(i,76540))})},76540:function(e,t,i){"use strict";i.r(t),i.d(t,{conf:function(){return n},language:function(){return o}});var n={comments:{blockComment:["(*","*)"]},brackets:[["{","}"],["[","]"],["(",")"]],autoClosingPairs:[{open:"[",close:"]"},{open:"{",close:"}"},{open:"(",close:")"},{open:"(*",close:"*)"},{open:"<*",close:"*>"},{open:"'",close:"'",notIn:["string","comment"]},{open:'"',close:'"',notIn:["string","comment"]}]},o={defaultToken:"",tokenPostfix:".m3",brackets:[{token:"delimiter.curly",open:"{",close:"}"},{token:"delimiter.parenthesis",open:"(",close:")"},{token:"delimiter.square",open:"[",close:"]"}],keywords:["AND","ANY","ARRAY","AS","BEGIN","BITS","BRANDED","BY","CASE","CONST","DIV","DO","ELSE","ELSIF","END","EVAL","EXCEPT","EXCEPTION","EXIT","EXPORTS","FINALLY","FOR","FROM","GENERIC","IF","IMPORT","IN","INTERFACE","LOCK","LOOP","METHODS","MOD","MODULE","NOT","OBJECT","OF","OR","OVERRIDES","PROCEDURE","RAISE","RAISES","READONLY","RECORD","REF","REPEAT","RETURN","REVEAL","SET","THEN","TO","TRY","TYPE","TYPECASE","UNSAFE","UNTIL","UNTRACED","VALUE","VAR","WHILE","WITH"],reservedConstNames:["ABS","ADR","ADRSIZE","BITSIZE","BYTESIZE","CEILING","DEC","DISPOSE","FALSE","FIRST","FLOAT","FLOOR","INC","ISTYPE","LAST","LOOPHOLE","MAX","MIN","NARROW","NEW","NIL","NUMBER","ORD","ROUND","SUBARRAY","TRUE","TRUNC","TYPECODE","VAL"],reservedTypeNames:["ADDRESS","ANY","BOOLEAN","CARDINAL","CHAR","EXTENDED","INTEGER","LONGCARD","LONGINT","LONGREAL","MUTEX","NULL","REAL","REFANY","ROOT","TEXT"],operators:["+","-","*","/","&","^","."],relations:["=","#","<","<=",">",">=","<:",":"],delimiters:["|","..","=>",",",";",":="],symbols:/[>=<#.,:;+\-*/&^]+/,escapes:/\\(?:[\\fnrt"']|[0-7]{3})/,tokenizer:{root:[[/_\w*/,"invalid"],[/[a-zA-Z][a-zA-Z0-9_]*/,{cases:{"@keywords":{token:"keyword.$0"},"@reservedConstNames":{token:"constant.reserved.$0"},"@reservedTypeNames":{token:"type.reserved.$0"},"@default":"identifier"}}],{include:"@whitespace"},[/[{}()\[\]]/,"@brackets"],[/[0-9]+\.[0-9]+(?:[DdEeXx][\+\-]?[0-9]+)?/,"number.float"],[/[0-9]+(?:\_[0-9a-fA-F]+)?L?/,"number"],[/@symbols/,{cases:{"@operators":"operators","@relations":"operators","@delimiters":"delimiter","@default":"invalid"}}],[/'[^\\']'/,"string.char"],[/(')(@escapes)(')/,["string.char","string.escape","string.char"]],[/'/,"invalid"],[/"([^"\\]|\\.)*$/,"invalid"],[/"/,"string.text","@text"]],text:[[/[^\\"]+/,"string.text"],[/@escapes/,"string.escape"],[/\\./,"invalid"],[/"/,"string.text","@pop"]],comment:[[/\(\*/,"comment","@push"],[/\*\)/,"comment","@pop"],[/./,"comment"]],pragma:[[/<\*/,"keyword.pragma","@push"],[/\*>/,"keyword.pragma","@pop"],[/./,"keyword.pragma"]],whitespace:[[/[ \t\r\n]+/,"white"],[/\(\*/,"comment","@comment"],[/<\*/,"keyword.pragma","@pragma"]]}}},20366:function(e,t,i){"use strict";i.r(t),(0,i(70266).H)({id:"markdown",extensions:[".md",".markdown",".mdown",".mkdn",".mkd",".mdwn",".mdtxt",".mdtext"],aliases:["Markdown","markdown"],loader:()=>Promise.resolve().then(i.bind(i,21261))})},21261:function(e,t,i){"use strict";i.r(t),i.d(t,{conf:function(){return n},language:function(){return o}});var n={comments:{blockComment:["\x3c!--","--\x3e"]},brackets:[["{","}"],["[","]"],["(",")"]],autoClosingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:"<",close:">",notIn:["string"]}],surroundingPairs:[{open:"(",close:")"},{open:"[",close:"]"},{open:"`",close:"`"}],folding:{markers:{start:new RegExp("^\\s*\x3c!--\\s*#?region\\b.*--\x3e"),end:new RegExp("^\\s*\x3c!--\\s*#?endregion\\b.*--\x3e")}}},o={defaultToken:"",tokenPostfix:".md",control:/[\\`*_\[\]{}()#+\-\.!]/,noncontrol:/[^\\`*_\[\]{}()#+\-\.!]/,escapes:/\\(?:@control)/,jsescapes:/\\(?:[btnfr\\"']|[0-7][0-7]?|[0-3][0-7]{2})/,empty:["area","base","basefont","br","col","frame","hr","img","input","isindex","link","meta","param"],tokenizer:{root:[[/^\s*\|/,"@rematch","@table_header"],[/^(\s{0,3})(#+)((?:[^\\#]|@escapes)+)((?:#+)?)/,["white","keyword","keyword","keyword"]],[/^\s*(=+|\-+)\s*$/,"keyword"],[/^\s*((\*[ ]?)+)\s*$/,"meta.separator"],[/^\s*>+/,"comment"],[/^\s*([\*\-+:]|\d+\.)\s/,"keyword"],[/^(\t|[ ]{4})[^ ].*$/,"string"],[/^\s*~~~\s*((?:\w|[\/\-#])+)?\s*$/,{token:"string",next:"@codeblock"}],[/^\s*```\s*((?:\w|[\/\-#])+).*$/,{token:"string",next:"@codeblockgh",nextEmbedded:"$1"}],[/^\s*```\s*$/,{token:"string",next:"@codeblock"}],{include:"@linecontent"}],table_header:[{include:"@table_common"},[/[^\|]+/,"keyword.table.header"]],table_body:[{include:"@table_common"},{include:"@linecontent"}],table_common:[[/\s*[\-:]+\s*/,{token:"keyword",switchTo:"table_body"}],[/^\s*\|/,"keyword.table.left"],[/^\s*[^\|]/,"@rematch","@pop"],[/^\s*$/,"@rematch","@pop"],[/\|/,{cases:{"@eos":"keyword.table.right","@default":"keyword.table.middle"}}]],codeblock:[[/^\s*~~~\s*$/,{token:"string",next:"@pop"}],[/^\s*```\s*$/,{token:"string",next:"@pop"}],[/.*$/,"variable.source"]],codeblockgh:[[/```\s*$/,{token:"string",next:"@pop",nextEmbedded:"@pop"}],[/[^`]+/,"variable.source"]],linecontent:[[/&\w+;/,"string.escape"],[/@escapes/,"escape"],[/\b__([^\\_]|@escapes|_(?!_))+__\b/,"strong"],[/\*\*([^\\*]|@escapes|\*(?!\*))+\*\*/,"strong"],[/\b_[^_]+_\b/,"emphasis"],[/\*([^\\*]|@escapes)+\*/,"emphasis"],[/`([^\\`]|@escapes)+`/,"variable"],[/\{+[^}]+\}+/,"string.target"],[/(!?\[)((?:[^\]\\]|@escapes)*)(\]\([^\)]+\))/,["string.link","","string.link"]],[/(!?\[)((?:[^\]\\]|@escapes)*)(\])/,"string.link"],{include:"html"}],html:[[/<(\w+)\/>/,"tag"],[/<(\w+)(\-|\w)*/,{cases:{"@empty":{token:"tag",next:"@tag.$1"},"@default":{token:"tag",next:"@tag.$1"}}}],[/<\/(\w+)(\-|\w)*\s*>/,{token:"tag"}],[//,"comment","@pop"],[//,"comment.html","@pop"],[/[^-]+/,"comment.content.html"],[/./,"comment.content.html"]],otherTag:[[/<\?((php)|=)?/,{token:"@rematch",switchTo:"@phpInSimpleState.otherTag"}],[/\/?>/,"delimiter.html","@pop"],[/"([^"]*)"/,"attribute.value"],[/'([^']*)'/,"attribute.value"],[/[\w\-]+/,"attribute.name"],[/=/,"delimiter"],[/[ \t\r\n]+/]],script:[[/<\?((php)|=)?/,{token:"@rematch",switchTo:"@phpInSimpleState.script"}],[/type/,"attribute.name","@scriptAfterType"],[/"([^"]*)"/,"attribute.value"],[/'([^']*)'/,"attribute.value"],[/[\w\-]+/,"attribute.name"],[/=/,"delimiter"],[/>/,{token:"delimiter.html",next:"@scriptEmbedded.text/javascript",nextEmbedded:"text/javascript"}],[/[ \t\r\n]+/],[/(<\/)(script\s*)(>)/,["delimiter.html","tag.html",{token:"delimiter.html",next:"@pop"}]]],scriptAfterType:[[/<\?((php)|=)?/,{token:"@rematch",switchTo:"@phpInSimpleState.scriptAfterType"}],[/=/,"delimiter","@scriptAfterTypeEquals"],[/>/,{token:"delimiter.html",next:"@scriptEmbedded.text/javascript",nextEmbedded:"text/javascript"}],[/[ \t\r\n]+/],[/<\/script\s*>/,{token:"@rematch",next:"@pop"}]],scriptAfterTypeEquals:[[/<\?((php)|=)?/,{token:"@rematch",switchTo:"@phpInSimpleState.scriptAfterTypeEquals"}],[/"([^"]*)"/,{token:"attribute.value",switchTo:"@scriptWithCustomType.$1"}],[/'([^']*)'/,{token:"attribute.value",switchTo:"@scriptWithCustomType.$1"}],[/>/,{token:"delimiter.html",next:"@scriptEmbedded.text/javascript",nextEmbedded:"text/javascript"}],[/[ \t\r\n]+/],[/<\/script\s*>/,{token:"@rematch",next:"@pop"}]],scriptWithCustomType:[[/<\?((php)|=)?/,{token:"@rematch",switchTo:"@phpInSimpleState.scriptWithCustomType.$S2"}],[/>/,{token:"delimiter.html",next:"@scriptEmbedded.$S2",nextEmbedded:"$S2"}],[/"([^"]*)"/,"attribute.value"],[/'([^']*)'/,"attribute.value"],[/[\w\-]+/,"attribute.name"],[/=/,"delimiter"],[/[ \t\r\n]+/],[/<\/script\s*>/,{token:"@rematch",next:"@pop"}]],scriptEmbedded:[[/<\?((php)|=)?/,{token:"@rematch",switchTo:"@phpInEmbeddedState.scriptEmbedded.$S2",nextEmbedded:"@pop"}],[/<\/script/,{token:"@rematch",next:"@pop",nextEmbedded:"@pop"}]],style:[[/<\?((php)|=)?/,{token:"@rematch",switchTo:"@phpInSimpleState.style"}],[/type/,"attribute.name","@styleAfterType"],[/"([^"]*)"/,"attribute.value"],[/'([^']*)'/,"attribute.value"],[/[\w\-]+/,"attribute.name"],[/=/,"delimiter"],[/>/,{token:"delimiter.html",next:"@styleEmbedded.text/css",nextEmbedded:"text/css"}],[/[ \t\r\n]+/],[/(<\/)(style\s*)(>)/,["delimiter.html","tag.html",{token:"delimiter.html",next:"@pop"}]]],styleAfterType:[[/<\?((php)|=)?/,{token:"@rematch",switchTo:"@phpInSimpleState.styleAfterType"}],[/=/,"delimiter","@styleAfterTypeEquals"],[/>/,{token:"delimiter.html",next:"@styleEmbedded.text/css",nextEmbedded:"text/css"}],[/[ \t\r\n]+/],[/<\/style\s*>/,{token:"@rematch",next:"@pop"}]],styleAfterTypeEquals:[[/<\?((php)|=)?/,{token:"@rematch",switchTo:"@phpInSimpleState.styleAfterTypeEquals"}],[/"([^"]*)"/,{token:"attribute.value",switchTo:"@styleWithCustomType.$1"}],[/'([^']*)'/,{token:"attribute.value",switchTo:"@styleWithCustomType.$1"}],[/>/,{token:"delimiter.html",next:"@styleEmbedded.text/css",nextEmbedded:"text/css"}],[/[ \t\r\n]+/],[/<\/style\s*>/,{token:"@rematch",next:"@pop"}]],styleWithCustomType:[[/<\?((php)|=)?/,{token:"@rematch",switchTo:"@phpInSimpleState.styleWithCustomType.$S2"}],[/>/,{token:"delimiter.html",next:"@styleEmbedded.$S2",nextEmbedded:"$S2"}],[/"([^"]*)"/,"attribute.value"],[/'([^']*)'/,"attribute.value"],[/[\w\-]+/,"attribute.name"],[/=/,"delimiter"],[/[ \t\r\n]+/],[/<\/style\s*>/,{token:"@rematch",next:"@pop"}]],styleEmbedded:[[/<\?((php)|=)?/,{token:"@rematch",switchTo:"@phpInEmbeddedState.styleEmbedded.$S2",nextEmbedded:"@pop"}],[/<\/style/,{token:"@rematch",next:"@pop",nextEmbedded:"@pop"}]],phpInSimpleState:[[/<\?((php)|=)?/,"metatag.php"],[/\?>/,{token:"metatag.php",switchTo:"@$S2.$S3"}],{include:"phpRoot"}],phpInEmbeddedState:[[/<\?((php)|=)?/,"metatag.php"],[/\?>/,{token:"metatag.php",switchTo:"@$S2.$S3",nextEmbedded:"$S3"}],{include:"phpRoot"}],phpRoot:[[/[a-zA-Z_]\w*/,{cases:{"@phpKeywords":{token:"keyword.php"},"@phpCompileTimeConstants":{token:"constant.php"},"@default":"identifier.php"}}],[/[$a-zA-Z_]\w*/,{cases:{"@phpPreDefinedVariables":{token:"variable.predefined.php"},"@default":"variable.php"}}],[/[{}]/,"delimiter.bracket.php"],[/[\[\]]/,"delimiter.array.php"],[/[()]/,"delimiter.parenthesis.php"],[/[ \t\r\n]+/],[/(#|\/\/)$/,"comment.php"],[/(#|\/\/)/,"comment.php","@phpLineComment"],[/\/\*/,"comment.php","@phpComment"],[/"/,"string.php","@phpDoubleQuoteString"],[/'/,"string.php","@phpSingleQuoteString"],[/[\+\-\*\%\&\|\^\~\!\=\<\>\/\?\;\:\.\,\@]/,"delimiter.php"],[/\d*\d+[eE]([\-+]?\d+)?/,"number.float.php"],[/\d*\.\d+([eE][\-+]?\d+)?/,"number.float.php"],[/0[xX][0-9a-fA-F']*[0-9a-fA-F]/,"number.hex.php"],[/0[0-7']*[0-7]/,"number.octal.php"],[/0[bB][0-1']*[0-1]/,"number.binary.php"],[/\d[\d']*/,"number.php"],[/\d/,"number.php"]],phpComment:[[/\*\//,"comment.php","@pop"],[/[^*]+/,"comment.php"],[/./,"comment.php"]],phpLineComment:[[/\?>/,{token:"@rematch",next:"@pop"}],[/.$/,"comment.php","@pop"],[/[^?]+$/,"comment.php","@pop"],[/[^?]+/,"comment.php"],[/./,"comment.php"]],phpDoubleQuoteString:[[/[^\\"]+/,"string.php"],[/@escapes/,"string.escape.php"],[/\\./,"string.escape.invalid.php"],[/"/,"string.php","@pop"]],phpSingleQuoteString:[[/[^\\']+/,"string.php"],[/@escapes/,"string.escape.php"],[/\\./,"string.escape.invalid.php"],[/'/,"string.php","@pop"]]},phpKeywords:["abstract","and","array","as","break","callable","case","catch","cfunction","class","clone","const","continue","declare","default","do","else","elseif","enddeclare","endfor","endforeach","endif","endswitch","endwhile","extends","false","final","for","foreach","function","global","goto","if","implements","interface","instanceof","insteadof","namespace","new","null","object","old_function","or","private","protected","public","resource","static","switch","throw","trait","try","true","use","var","while","xor","die","echo","empty","exit","eval","include","include_once","isset","list","require","require_once","return","print","unset","yield","__construct"],phpCompileTimeConstants:["__CLASS__","__DIR__","__FILE__","__LINE__","__NAMESPACE__","__METHOD__","__FUNCTION__","__TRAIT__"],phpPreDefinedVariables:["$GLOBALS","$_SERVER","$_GET","$_POST","$_FILES","$_REQUEST","$_SESSION","$_ENV","$_COOKIE","$php_errormsg","$HTTP_RAW_POST_DATA","$http_response_header","$argc","$argv"],escapes:/\\(?:[abfnrtv\\"']|x[0-9A-Fa-f]{1,4}|u[0-9A-Fa-f]{4}|U[0-9A-Fa-f]{8})/}},79931:function(e,t,i){"use strict";i.r(t),(0,i(70266).H)({id:"pla",extensions:[".pla"],loader:()=>Promise.resolve().then(i.bind(i,16638))})},16638:function(e,t,i){"use strict";i.r(t),i.d(t,{conf:function(){return n},language:function(){return o}});var n={comments:{lineComment:"#"},brackets:[["[","]"],["<",">"],["(",")"]],autoClosingPairs:[{open:"[",close:"]"},{open:"<",close:">"},{open:"(",close:")"}],surroundingPairs:[{open:"[",close:"]"},{open:"<",close:">"},{open:"(",close:")"}]},o={defaultToken:"",tokenPostfix:".pla",brackets:[{open:"[",close:"]",token:"delimiter.square"},{open:"<",close:">",token:"delimiter.angle"},{open:"(",close:")",token:"delimiter.parenthesis"}],keywords:[".i",".o",".mv",".ilb",".ob",".label",".type",".phase",".pair",".symbolic",".symbolic-output",".kiss",".p",".e",".end"],comment:/#.*$/,identifier:/[a-zA-Z]+[a-zA-Z0-9_\-]*/,plaContent:/[01\-~\|]+/,tokenizer:{root:[{include:"@whitespace"},[/@comment/,"comment"],[/\.([a-zA-Z_\-]+)/,{cases:{"@eos":{token:"keyword.$1"},"@keywords":{cases:{".type":{token:"keyword.$1",next:"@type"},"@default":{token:"keyword.$1",next:"@keywordArg"}}},"@default":{token:"keyword.$1"}}}],[/@identifier/,"identifier"],[/@plaContent/,"string"]],whitespace:[[/[ \t\r\n]+/,""]],type:[{include:"@whitespace"},[/\w+/,{token:"type",next:"@pop"}]],keywordArg:[[/[ \t\r\n]+/,{cases:{"@eos":{token:"",next:"@pop"},"@default":""}}],[/@comment/,"comment","@pop"],[/[<>()\[\]]/,{cases:{"@eos":{token:"@brackets",next:"@pop"},"@default":"@brackets"}}],[/\-?\d+/,{cases:{"@eos":{token:"number",next:"@pop"},"@default":"number"}}],[/@identifier/,{cases:{"@eos":{token:"identifier",next:"@pop"},"@default":"identifier"}}],[/[;=]/,{cases:{"@eos":{token:"delimiter",next:"@pop"},"@default":"delimiter"}}]]}}},53828:function(e,t,i){"use strict";i.r(t),(0,i(70266).H)({id:"postiats",extensions:[".dats",".sats",".hats"],aliases:["ATS","ATS/Postiats"],loader:()=>Promise.resolve().then(i.bind(i,86958))})},86958:function(e,t,i){"use strict";i.r(t),i.d(t,{conf:function(){return n},language:function(){return o}});var n={comments:{lineComment:"//",blockComment:["(*","*)"]},brackets:[["{","}"],["[","]"],["(",")"],["<",">"]],autoClosingPairs:[{open:'"',close:'"',notIn:["string","comment"]},{open:"{",close:"}",notIn:["string","comment"]},{open:"[",close:"]",notIn:["string","comment"]},{open:"(",close:")",notIn:["string","comment"]}]},o={tokenPostfix:".pats",defaultToken:"invalid",keywords:["abstype","abst0ype","absprop","absview","absvtype","absviewtype","absvt0ype","absviewt0ype","as","and","assume","begin","classdec","datasort","datatype","dataprop","dataview","datavtype","dataviewtype","do","end","extern","extype","extvar","exception","fn","fnx","fun","prfn","prfun","praxi","castfn","if","then","else","ifcase","in","infix","infixl","infixr","prefix","postfix","implmnt","implement","primplmnt","primplement","import","let","local","macdef","macrodef","nonfix","symelim","symintr","overload","of","op","rec","sif","scase","sortdef","sta","stacst","stadef","static","staload","dynload","try","tkindef","typedef","propdef","viewdef","vtypedef","viewtypedef","prval","var","prvar","when","where","with","withtype","withprop","withview","withvtype","withviewtype"],keywords_dlr:["$delay","$ldelay","$arrpsz","$arrptrsize","$d2ctype","$effmask","$effmask_ntm","$effmask_exn","$effmask_ref","$effmask_wrt","$effmask_all","$extern","$extkind","$extype","$extype_struct","$extval","$extfcall","$extmcall","$literal","$myfilename","$mylocation","$myfunction","$lst","$lst_t","$lst_vt","$list","$list_t","$list_vt","$rec","$rec_t","$rec_vt","$record","$record_t","$record_vt","$tup","$tup_t","$tup_vt","$tuple","$tuple_t","$tuple_vt","$break","$continue","$raise","$showtype","$vcopyenv_v","$vcopyenv_vt","$tempenver","$solver_assert","$solver_verify"],keywords_srp:["#if","#ifdef","#ifndef","#then","#elif","#elifdef","#elifndef","#else","#endif","#error","#prerr","#print","#assert","#undef","#define","#include","#require","#pragma","#codegen2","#codegen3"],irregular_keyword_list:["val+","val-","val","case+","case-","case","addr@","addr","fold@","free@","fix@","fix","lam@","lam","llam@","llam","viewt@ype+","viewt@ype-","viewt@ype","viewtype+","viewtype-","viewtype","view+","view-","view@","view","type+","type-","type","vtype+","vtype-","vtype","vt@ype+","vt@ype-","vt@ype","viewt@ype+","viewt@ype-","viewt@ype","viewtype+","viewtype-","viewtype","prop+","prop-","prop","type+","type-","type","t@ype","t@ype+","t@ype-","abst@ype","abstype","absviewt@ype","absvt@ype","for*","for","while*","while"],keywords_types:["bool","double","byte","int","short","char","void","unit","long","float","string","strptr"],keywords_effects:["0","fun","clo","prf","funclo","cloptr","cloref","ref","ntm","1"],operators:["@","!","|","`",":","$",".","=","#","~","..","...","=>","=<>","=/=>","=>>","=/=>>","<",">","><",".<",">.",".<>.","->","-<>"],brackets:[{open:",(",close:")",token:"delimiter.parenthesis"},{open:"`(",close:")",token:"delimiter.parenthesis"},{open:"%(",close:")",token:"delimiter.parenthesis"},{open:"'(",close:")",token:"delimiter.parenthesis"},{open:"'{",close:"}",token:"delimiter.parenthesis"},{open:"@(",close:")",token:"delimiter.parenthesis"},{open:"@{",close:"}",token:"delimiter.brace"},{open:"@[",close:"]",token:"delimiter.square"},{open:"#[",close:"]",token:"delimiter.square"},{open:"{",close:"}",token:"delimiter.curly"},{open:"[",close:"]",token:"delimiter.square"},{open:"(",close:")",token:"delimiter.parenthesis"},{open:"<",close:">",token:"delimiter.angle"}],symbols:/[=>]/,digit:/[0-9]/,digitseq0:/@digit*/,xdigit:/[0-9A-Za-z]/,xdigitseq0:/@xdigit*/,INTSP:/[lLuU]/,FLOATSP:/[fFlL]/,fexponent:/[eE][+-]?[0-9]+/,fexponent_bin:/[pP][+-]?[0-9]+/,deciexp:/\.[0-9]*@fexponent?/,hexiexp:/\.[0-9a-zA-Z]*@fexponent_bin?/,irregular_keywords:/val[+-]?|case[+-]?|addr\@?|fold\@|free\@|fix\@?|lam\@?|llam\@?|prop[+-]?|type[+-]?|view[+-@]?|viewt@?ype[+-]?|t@?ype[+-]?|v(iew)?t@?ype[+-]?|abst@?ype|absv(iew)?t@?ype|for\*?|while\*?/,ESCHAR:/[ntvbrfa\\\?'"\(\[\{]/,start:"root",tokenizer:{root:[{regex:/[ \t\r\n]+/,action:{token:""}},{regex:/\(\*\)/,action:{token:"invalid"}},{regex:/\(\*/,action:{token:"comment",next:"lexing_COMMENT_block_ml"}},{regex:/\(/,action:"@brackets"},{regex:/\)/,action:"@brackets"},{regex:/\[/,action:"@brackets"},{regex:/\]/,action:"@brackets"},{regex:/\{/,action:"@brackets"},{regex:/\}/,action:"@brackets"},{regex:/,\(/,action:"@brackets"},{regex:/,/,action:{token:"delimiter.comma"}},{regex:/;/,action:{token:"delimiter.semicolon"}},{regex:/@\(/,action:"@brackets"},{regex:/@\[/,action:"@brackets"},{regex:/@\{/,action:"@brackets"},{regex:/:/,action:{token:"@rematch",next:"@pop"}}],lexing_EXTCODE:[{regex:/^%}/,action:{token:"@rematch",next:"@pop",nextEmbedded:"@pop"}},{regex:/[^%]+/,action:""}],lexing_DQUOTE:[{regex:/"/,action:{token:"string.quote",next:"@pop"}},{regex:/(\{\$)(@IDENTFST@IDENTRST*)(\})/,action:[{token:"string.escape"},{token:"identifier"},{token:"string.escape"}]},{regex:/\\$/,action:{token:"string.escape"}},{regex:/\\(@ESCHAR|[xX]@xdigit+|@digit+)/,action:{token:"string.escape"}},{regex:/[^\\"]+/,action:{token:"string"}}]}}},7406:function(e,t,i){"use strict";i.r(t),(0,i(70266).H)({id:"powerquery",extensions:[".pq",".pqm"],aliases:["PQ","M","Power Query","Power Query M"],loader:()=>Promise.resolve().then(i.bind(i,74947))})},74947:function(e,t,i){"use strict";i.r(t),i.d(t,{conf:function(){return n},language:function(){return o}});var n={comments:{lineComment:"//",blockComment:["/*","*/"]},brackets:[["[","]"],["(",")"],["{","}"]],autoClosingPairs:[{open:'"',close:'"',notIn:["string","comment","identifier"]},{open:"[",close:"]",notIn:["string","comment","identifier"]},{open:"(",close:")",notIn:["string","comment","identifier"]},{open:"{",close:"}",notIn:["string","comment","identifier"]}]},o={defaultToken:"",tokenPostfix:".pq",ignoreCase:!1,brackets:[{open:"[",close:"]",token:"delimiter.square"},{open:"{",close:"}",token:"delimiter.brackets"},{open:"(",close:")",token:"delimiter.parenthesis"}],operatorKeywords:["and","not","or"],keywords:["as","each","else","error","false","if","in","is","let","meta","otherwise","section","shared","then","true","try","type"],constructors:["#binary","#date","#datetime","#datetimezone","#duration","#table","#time"],constants:["#infinity","#nan","#sections","#shared"],typeKeywords:["action","any","anynonnull","none","null","logical","number","time","date","datetime","datetimezone","duration","text","binary","list","record","table","function"],builtinFunctions:["Access.Database","Action.Return","Action.Sequence","Action.Try","ActiveDirectory.Domains","AdoDotNet.DataSource","AdoDotNet.Query","AdobeAnalytics.Cubes","AnalysisServices.Database","AnalysisServices.Databases","AzureStorage.BlobContents","AzureStorage.Blobs","AzureStorage.Tables","Binary.Buffer","Binary.Combine","Binary.Compress","Binary.Decompress","Binary.End","Binary.From","Binary.FromList","Binary.FromText","Binary.InferContentType","Binary.Length","Binary.ToList","Binary.ToText","BinaryFormat.7BitEncodedSignedInteger","BinaryFormat.7BitEncodedUnsignedInteger","BinaryFormat.Binary","BinaryFormat.Byte","BinaryFormat.ByteOrder","BinaryFormat.Choice","BinaryFormat.Decimal","BinaryFormat.Double","BinaryFormat.Group","BinaryFormat.Length","BinaryFormat.List","BinaryFormat.Null","BinaryFormat.Record","BinaryFormat.SignedInteger16","BinaryFormat.SignedInteger32","BinaryFormat.SignedInteger64","BinaryFormat.Single","BinaryFormat.Text","BinaryFormat.Transform","BinaryFormat.UnsignedInteger16","BinaryFormat.UnsignedInteger32","BinaryFormat.UnsignedInteger64","Byte.From","Character.FromNumber","Character.ToNumber","Combiner.CombineTextByDelimiter","Combiner.CombineTextByEachDelimiter","Combiner.CombineTextByLengths","Combiner.CombineTextByPositions","Combiner.CombineTextByRanges","Comparer.Equals","Comparer.FromCulture","Comparer.Ordinal","Comparer.OrdinalIgnoreCase","Csv.Document","Cube.AddAndExpandDimensionColumn","Cube.AddMeasureColumn","Cube.ApplyParameter","Cube.AttributeMemberId","Cube.AttributeMemberProperty","Cube.CollapseAndRemoveColumns","Cube.Dimensions","Cube.DisplayFolders","Cube.Measures","Cube.Parameters","Cube.Properties","Cube.PropertyKey","Cube.ReplaceDimensions","Cube.Transform","Currency.From","DB2.Database","Date.AddDays","Date.AddMonths","Date.AddQuarters","Date.AddWeeks","Date.AddYears","Date.Day","Date.DayOfWeek","Date.DayOfWeekName","Date.DayOfYear","Date.DaysInMonth","Date.EndOfDay","Date.EndOfMonth","Date.EndOfQuarter","Date.EndOfWeek","Date.EndOfYear","Date.From","Date.FromText","Date.IsInCurrentDay","Date.IsInCurrentMonth","Date.IsInCurrentQuarter","Date.IsInCurrentWeek","Date.IsInCurrentYear","Date.IsInNextDay","Date.IsInNextMonth","Date.IsInNextNDays","Date.IsInNextNMonths","Date.IsInNextNQuarters","Date.IsInNextNWeeks","Date.IsInNextNYears","Date.IsInNextQuarter","Date.IsInNextWeek","Date.IsInNextYear","Date.IsInPreviousDay","Date.IsInPreviousMonth","Date.IsInPreviousNDays","Date.IsInPreviousNMonths","Date.IsInPreviousNQuarters","Date.IsInPreviousNWeeks","Date.IsInPreviousNYears","Date.IsInPreviousQuarter","Date.IsInPreviousWeek","Date.IsInPreviousYear","Date.IsInYearToDate","Date.IsLeapYear","Date.Month","Date.MonthName","Date.QuarterOfYear","Date.StartOfDay","Date.StartOfMonth","Date.StartOfQuarter","Date.StartOfWeek","Date.StartOfYear","Date.ToRecord","Date.ToText","Date.WeekOfMonth","Date.WeekOfYear","Date.Year","DateTime.AddZone","DateTime.Date","DateTime.FixedLocalNow","DateTime.From","DateTime.FromFileTime","DateTime.FromText","DateTime.IsInCurrentHour","DateTime.IsInCurrentMinute","DateTime.IsInCurrentSecond","DateTime.IsInNextHour","DateTime.IsInNextMinute","DateTime.IsInNextNHours","DateTime.IsInNextNMinutes","DateTime.IsInNextNSeconds","DateTime.IsInNextSecond","DateTime.IsInPreviousHour","DateTime.IsInPreviousMinute","DateTime.IsInPreviousNHours","DateTime.IsInPreviousNMinutes","DateTime.IsInPreviousNSeconds","DateTime.IsInPreviousSecond","DateTime.LocalNow","DateTime.Time","DateTime.ToRecord","DateTime.ToText","DateTimeZone.FixedLocalNow","DateTimeZone.FixedUtcNow","DateTimeZone.From","DateTimeZone.FromFileTime","DateTimeZone.FromText","DateTimeZone.LocalNow","DateTimeZone.RemoveZone","DateTimeZone.SwitchZone","DateTimeZone.ToLocal","DateTimeZone.ToRecord","DateTimeZone.ToText","DateTimeZone.ToUtc","DateTimeZone.UtcNow","DateTimeZone.ZoneHours","DateTimeZone.ZoneMinutes","Decimal.From","Diagnostics.ActivityId","Diagnostics.Trace","DirectQueryCapabilities.From","Double.From","Duration.Days","Duration.From","Duration.FromText","Duration.Hours","Duration.Minutes","Duration.Seconds","Duration.ToRecord","Duration.ToText","Duration.TotalDays","Duration.TotalHours","Duration.TotalMinutes","Duration.TotalSeconds","Embedded.Value","Error.Record","Excel.CurrentWorkbook","Excel.Workbook","Exchange.Contents","Expression.Constant","Expression.Evaluate","Expression.Identifier","Facebook.Graph","File.Contents","Folder.Contents","Folder.Files","Function.From","Function.Invoke","Function.InvokeAfter","Function.IsDataSource","GoogleAnalytics.Accounts","Guid.From","HdInsight.Containers","HdInsight.Contents","HdInsight.Files","Hdfs.Contents","Hdfs.Files","Informix.Database","Int16.From","Int32.From","Int64.From","Int8.From","ItemExpression.From","Json.Document","Json.FromValue","Lines.FromBinary","Lines.FromText","Lines.ToBinary","Lines.ToText","List.Accumulate","List.AllTrue","List.Alternate","List.AnyTrue","List.Average","List.Buffer","List.Combine","List.Contains","List.ContainsAll","List.ContainsAny","List.Count","List.Covariance","List.DateTimeZones","List.DateTimes","List.Dates","List.Difference","List.Distinct","List.Durations","List.FindText","List.First","List.FirstN","List.Generate","List.InsertRange","List.Intersect","List.IsDistinct","List.IsEmpty","List.Last","List.LastN","List.MatchesAll","List.MatchesAny","List.Max","List.MaxN","List.Median","List.Min","List.MinN","List.Mode","List.Modes","List.NonNullCount","List.Numbers","List.PositionOf","List.PositionOfAny","List.Positions","List.Product","List.Random","List.Range","List.RemoveFirstN","List.RemoveItems","List.RemoveLastN","List.RemoveMatchingItems","List.RemoveNulls","List.RemoveRange","List.Repeat","List.ReplaceMatchingItems","List.ReplaceRange","List.ReplaceValue","List.Reverse","List.Select","List.Single","List.SingleOrDefault","List.Skip","List.Sort","List.StandardDeviation","List.Sum","List.Times","List.Transform","List.TransformMany","List.Union","List.Zip","Logical.From","Logical.FromText","Logical.ToText","MQ.Queue","MySQL.Database","Number.Abs","Number.Acos","Number.Asin","Number.Atan","Number.Atan2","Number.BitwiseAnd","Number.BitwiseNot","Number.BitwiseOr","Number.BitwiseShiftLeft","Number.BitwiseShiftRight","Number.BitwiseXor","Number.Combinations","Number.Cos","Number.Cosh","Number.Exp","Number.Factorial","Number.From","Number.FromText","Number.IntegerDivide","Number.IsEven","Number.IsNaN","Number.IsOdd","Number.Ln","Number.Log","Number.Log10","Number.Mod","Number.Permutations","Number.Power","Number.Random","Number.RandomBetween","Number.Round","Number.RoundAwayFromZero","Number.RoundDown","Number.RoundTowardZero","Number.RoundUp","Number.Sign","Number.Sin","Number.Sinh","Number.Sqrt","Number.Tan","Number.Tanh","Number.ToText","OData.Feed","Odbc.DataSource","Odbc.Query","OleDb.DataSource","OleDb.Query","Oracle.Database","Percentage.From","PostgreSQL.Database","RData.FromBinary","Record.AddField","Record.Combine","Record.Field","Record.FieldCount","Record.FieldNames","Record.FieldOrDefault","Record.FieldValues","Record.FromList","Record.FromTable","Record.HasFields","Record.RemoveFields","Record.RenameFields","Record.ReorderFields","Record.SelectFields","Record.ToList","Record.ToTable","Record.TransformFields","Replacer.ReplaceText","Replacer.ReplaceValue","RowExpression.Column","RowExpression.From","Salesforce.Data","Salesforce.Reports","SapBusinessWarehouse.Cubes","SapHana.Database","SharePoint.Contents","SharePoint.Files","SharePoint.Tables","Single.From","Soda.Feed","Splitter.SplitByNothing","Splitter.SplitTextByAnyDelimiter","Splitter.SplitTextByDelimiter","Splitter.SplitTextByEachDelimiter","Splitter.SplitTextByLengths","Splitter.SplitTextByPositions","Splitter.SplitTextByRanges","Splitter.SplitTextByRepeatedLengths","Splitter.SplitTextByWhitespace","Sql.Database","Sql.Databases","SqlExpression.SchemaFrom","SqlExpression.ToExpression","Sybase.Database","Table.AddColumn","Table.AddIndexColumn","Table.AddJoinColumn","Table.AddKey","Table.AggregateTableColumn","Table.AlternateRows","Table.Buffer","Table.Column","Table.ColumnCount","Table.ColumnNames","Table.ColumnsOfType","Table.Combine","Table.CombineColumns","Table.Contains","Table.ContainsAll","Table.ContainsAny","Table.DemoteHeaders","Table.Distinct","Table.DuplicateColumn","Table.ExpandListColumn","Table.ExpandRecordColumn","Table.ExpandTableColumn","Table.FillDown","Table.FillUp","Table.FilterWithDataTable","Table.FindText","Table.First","Table.FirstN","Table.FirstValue","Table.FromColumns","Table.FromList","Table.FromPartitions","Table.FromRecords","Table.FromRows","Table.FromValue","Table.Group","Table.HasColumns","Table.InsertRows","Table.IsDistinct","Table.IsEmpty","Table.Join","Table.Keys","Table.Last","Table.LastN","Table.MatchesAllRows","Table.MatchesAnyRows","Table.Max","Table.MaxN","Table.Min","Table.MinN","Table.NestedJoin","Table.Partition","Table.PartitionValues","Table.Pivot","Table.PositionOf","Table.PositionOfAny","Table.PrefixColumns","Table.Profile","Table.PromoteHeaders","Table.Range","Table.RemoveColumns","Table.RemoveFirstN","Table.RemoveLastN","Table.RemoveMatchingRows","Table.RemoveRows","Table.RemoveRowsWithErrors","Table.RenameColumns","Table.ReorderColumns","Table.Repeat","Table.ReplaceErrorValues","Table.ReplaceKeys","Table.ReplaceMatchingRows","Table.ReplaceRelationshipIdentity","Table.ReplaceRows","Table.ReplaceValue","Table.ReverseRows","Table.RowCount","Table.Schema","Table.SelectColumns","Table.SelectRows","Table.SelectRowsWithErrors","Table.SingleRow","Table.Skip","Table.Sort","Table.SplitColumn","Table.ToColumns","Table.ToList","Table.ToRecords","Table.ToRows","Table.TransformColumnNames","Table.TransformColumnTypes","Table.TransformColumns","Table.TransformRows","Table.Transpose","Table.Unpivot","Table.UnpivotOtherColumns","Table.View","Table.ViewFunction","TableAction.DeleteRows","TableAction.InsertRows","TableAction.UpdateRows","Tables.GetRelationships","Teradata.Database","Text.AfterDelimiter","Text.At","Text.BeforeDelimiter","Text.BetweenDelimiters","Text.Clean","Text.Combine","Text.Contains","Text.End","Text.EndsWith","Text.Format","Text.From","Text.FromBinary","Text.Insert","Text.Length","Text.Lower","Text.Middle","Text.NewGuid","Text.PadEnd","Text.PadStart","Text.PositionOf","Text.PositionOfAny","Text.Proper","Text.Range","Text.Remove","Text.RemoveRange","Text.Repeat","Text.Replace","Text.ReplaceRange","Text.Select","Text.Split","Text.SplitAny","Text.Start","Text.StartsWith","Text.ToBinary","Text.ToList","Text.Trim","Text.TrimEnd","Text.TrimStart","Text.Upper","Time.EndOfHour","Time.From","Time.FromText","Time.Hour","Time.Minute","Time.Second","Time.StartOfHour","Time.ToRecord","Time.ToText","Type.AddTableKey","Type.ClosedRecord","Type.Facets","Type.ForFunction","Type.ForRecord","Type.FunctionParameters","Type.FunctionRequiredParameters","Type.FunctionReturn","Type.Is","Type.IsNullable","Type.IsOpenRecord","Type.ListItem","Type.NonNullable","Type.OpenRecord","Type.RecordFields","Type.ReplaceFacets","Type.ReplaceTableKeys","Type.TableColumn","Type.TableKeys","Type.TableRow","Type.TableSchema","Type.Union","Uri.BuildQueryString","Uri.Combine","Uri.EscapeDataString","Uri.Parts","Value.Add","Value.As","Value.Compare","Value.Divide","Value.Equals","Value.Firewall","Value.FromText","Value.Is","Value.Metadata","Value.Multiply","Value.NativeQuery","Value.NullableEquals","Value.RemoveMetadata","Value.ReplaceMetadata","Value.ReplaceType","Value.Subtract","Value.Type","ValueAction.NativeStatement","ValueAction.Replace","Variable.Value","Web.Contents","Web.Page","WebAction.Request","Xml.Document","Xml.Tables"],builtinConstants:["BinaryEncoding.Base64","BinaryEncoding.Hex","BinaryOccurrence.Optional","BinaryOccurrence.Repeating","BinaryOccurrence.Required","ByteOrder.BigEndian","ByteOrder.LittleEndian","Compression.Deflate","Compression.GZip","CsvStyle.QuoteAfterDelimiter","CsvStyle.QuoteAlways","Culture.Current","Day.Friday","Day.Monday","Day.Saturday","Day.Sunday","Day.Thursday","Day.Tuesday","Day.Wednesday","ExtraValues.Error","ExtraValues.Ignore","ExtraValues.List","GroupKind.Global","GroupKind.Local","JoinAlgorithm.Dynamic","JoinAlgorithm.LeftHash","JoinAlgorithm.LeftIndex","JoinAlgorithm.PairwiseHash","JoinAlgorithm.RightHash","JoinAlgorithm.RightIndex","JoinAlgorithm.SortMerge","JoinKind.FullOuter","JoinKind.Inner","JoinKind.LeftAnti","JoinKind.LeftOuter","JoinKind.RightAnti","JoinKind.RightOuter","JoinSide.Left","JoinSide.Right","MissingField.Error","MissingField.Ignore","MissingField.UseNull","Number.E","Number.Epsilon","Number.NaN","Number.NegativeInfinity","Number.PI","Number.PositiveInfinity","Occurrence.All","Occurrence.First","Occurrence.Last","Occurrence.Optional","Occurrence.Repeating","Occurrence.Required","Order.Ascending","Order.Descending","Precision.Decimal","Precision.Double","QuoteStyle.Csv","QuoteStyle.None","RelativePosition.FromEnd","RelativePosition.FromStart","RoundingMode.AwayFromZero","RoundingMode.Down","RoundingMode.ToEven","RoundingMode.TowardZero","RoundingMode.Up","SapHanaDistribution.All","SapHanaDistribution.Connection","SapHanaDistribution.Off","SapHanaDistribution.Statement","SapHanaRangeOperator.Equals","SapHanaRangeOperator.GreaterThan","SapHanaRangeOperator.GreaterThanOrEquals","SapHanaRangeOperator.LessThan","SapHanaRangeOperator.LessThanOrEquals","SapHanaRangeOperator.NotEquals","TextEncoding.Ascii","TextEncoding.BigEndianUnicode","TextEncoding.Unicode","TextEncoding.Utf16","TextEncoding.Utf8","TextEncoding.Windows","TraceLevel.Critical","TraceLevel.Error","TraceLevel.Information","TraceLevel.Verbose","TraceLevel.Warning","WebMethod.Delete","WebMethod.Get","WebMethod.Head","WebMethod.Patch","WebMethod.Post","WebMethod.Put"],builtinTypes:["Action.Type","Any.Type","Binary.Type","BinaryEncoding.Type","BinaryOccurrence.Type","Byte.Type","ByteOrder.Type","Character.Type","Compression.Type","CsvStyle.Type","Currency.Type","Date.Type","DateTime.Type","DateTimeZone.Type","Day.Type","Decimal.Type","Double.Type","Duration.Type","ExtraValues.Type","Function.Type","GroupKind.Type","Guid.Type","Int16.Type","Int32.Type","Int64.Type","Int8.Type","JoinAlgorithm.Type","JoinKind.Type","JoinSide.Type","List.Type","Logical.Type","MissingField.Type","None.Type","Null.Type","Number.Type","Occurrence.Type","Order.Type","Password.Type","Percentage.Type","Precision.Type","QuoteStyle.Type","Record.Type","RelativePosition.Type","RoundingMode.Type","SapHanaDistribution.Type","SapHanaRangeOperator.Type","Single.Type","Table.Type","Text.Type","TextEncoding.Type","Time.Type","TraceLevel.Type","Type.Type","Uri.Type","WebMethod.Type"],tokenizer:{root:[[/#"[\w \.]+"/,"identifier.quote"],[/\d*\.\d+([eE][\-+]?\d+)?/,"number.float"],[/0[xX][0-9a-fA-F]+/,"number.hex"],[/\d+([eE][\-+]?\d+)?/,"number"],[/(#?[a-z]+)\b/,{cases:{"@typeKeywords":"type","@keywords":"keyword","@constants":"constant","@constructors":"constructor","@operatorKeywords":"operators","@default":"identifier"}}],[/\b([A-Z][a-zA-Z0-9]+\.Type)\b/,{cases:{"@builtinTypes":"type","@default":"identifier"}}],[/\b([A-Z][a-zA-Z0-9]+\.[A-Z][a-zA-Z0-9]+)\b/,{cases:{"@builtinFunctions":"keyword.function","@builtinConstants":"constant","@default":"identifier"}}],[/\b([a-zA-Z_][\w\.]*)\b/,"identifier"],{include:"@whitespace"},{include:"@comments"},{include:"@strings"},[/[{}()\[\]]/,"@brackets"],[/([=\+<>\-\*&@\?\/!])|([<>]=)|(<>)|(=>)|(\.\.\.)|(\.\.)/,"operators"],[/[,;]/,"delimiter"]],whitespace:[[/\s+/,"white"]],comments:[["\\/\\*","comment","@comment"],["\\/\\/+.*","comment"]],comment:[["\\*\\/","comment","@pop"],[".","comment"]],strings:[['"',"string","@string"]],string:[['""',"string.escape"],['"',"string","@pop"],[".","string"]]}}},64026:function(e,t,i){"use strict";i.r(t),(0,i(70266).H)({id:"powershell",extensions:[".ps1",".psm1",".psd1"],aliases:["PowerShell","powershell","ps","ps1"],loader:()=>Promise.resolve().then(i.bind(i,8397))})},8397:function(e,t,i){"use strict";i.r(t),i.d(t,{conf:function(){return n},language:function(){return o}});var n={wordPattern:/(-?\d*\.\d\w*)|([^\`\~\!\@\#%\^\&\*\(\)\=\+\[\{\]\}\\\|\;\:\'\"\,\.\<\>\/\?\s]+)/g,comments:{lineComment:"#",blockComment:["<#","#>"]},brackets:[["{","}"],["[","]"],["(",")"]],autoClosingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:'"',close:'"',notIn:["string"]},{open:"'",close:"'",notIn:["string","comment"]}],surroundingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:'"',close:'"'},{open:"'",close:"'"}],folding:{markers:{start:new RegExp("^\\s*#region\\b"),end:new RegExp("^\\s*#endregion\\b")}}},o={defaultToken:"",ignoreCase:!0,tokenPostfix:".ps1",brackets:[{token:"delimiter.curly",open:"{",close:"}"},{token:"delimiter.square",open:"[",close:"]"},{token:"delimiter.parenthesis",open:"(",close:")"}],keywords:["begin","break","catch","class","continue","data","define","do","dynamicparam","else","elseif","end","exit","filter","finally","for","foreach","from","function","if","in","param","process","return","switch","throw","trap","try","until","using","var","while","workflow","parallel","sequence","inlinescript","configuration"],helpKeywords:/SYNOPSIS|DESCRIPTION|PARAMETER|EXAMPLE|INPUTS|OUTPUTS|NOTES|LINK|COMPONENT|ROLE|FUNCTIONALITY|FORWARDHELPTARGETNAME|FORWARDHELPCATEGORY|REMOTEHELPRUNSPACE|EXTERNALHELP/,symbols:/[=>/,"comment","@pop"],[/(\.)(@helpKeywords)(?!\w)/,{token:"comment.keyword.$2"}],[/[\.#]/,"comment"]]}}},33173:function(e,t,i){"use strict";i.r(t),(0,i(70266).H)({id:"proto",extensions:[".proto"],aliases:["protobuf","Protocol Buffers"],loader:()=>Promise.resolve().then(i.bind(i,66460))})},66460:function(e,t,i){"use strict";i.r(t),i.d(t,{conf:function(){return n},language:function(){return o}});var n={comments:{lineComment:"//",blockComment:["/*","*/"]},brackets:[["{","}"],["[","]"],["(",")"],["<",">"]],surroundingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:"<",close:">"},{open:'"',close:'"'},{open:"'",close:"'"}],autoClosingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:"<",close:">"},{open:'"',close:'"',notIn:["string"]},{open:"'",close:"'",notIn:["string"]}],autoCloseBefore:".,=}])>' \n\t",indentationRules:{increaseIndentPattern:new RegExp("^((?!\\/\\/).)*(\\{[^}\"'`]*|\\([^)\"'`]*|\\[[^\\]\"'`]*)$"),decreaseIndentPattern:new RegExp("^((?!.*?\\/\\*).*\\*/)?\\s*[\\}\\]].*$")}},o={defaultToken:"",tokenPostfix:".proto",brackets:[{open:"{",close:"}",token:"delimiter.curly"},{open:"[",close:"]",token:"delimiter.square"},{open:"(",close:")",token:"delimiter.parenthesis"},{open:"<",close:">",token:"delimiter.angle"}],symbols:/[=>/,{token:"@brackets",bracket:"@close",switchTo:"identifier"}]],field:[{include:"@whitespace"},["group",{cases:{"$S2==proto2":{token:"keyword",switchTo:"@groupDecl.$S2"}}}],[/(@identifier)(\s*)(=)/,["identifier","white",{token:"delimiter",next:"@pop"}]],[/@fullIdentifier|\./,{cases:{"@builtinTypes":"keyword","@default":"type.identifier"}}]],groupDecl:[{include:"@whitespace"},[/@identifier/,"identifier"],["=","operator"],[/{/,{token:"@brackets",bracket:"@open",switchTo:"@messageBody.$S2"}],{include:"@constant"}],type:[{include:"@whitespace"},[/@identifier/,"type.identifier","@pop"],[/./,"delimiter"]],identifier:[{include:"@whitespace"},[/@identifier/,"identifier","@pop"]],serviceDecl:[{include:"@whitespace"},[/@identifier/,"identifier"],[/{/,{token:"@brackets",bracket:"@open",switchTo:"@serviceBody.$S2"}]],serviceBody:[{include:"@whitespace"},{include:"@constant"},[/;/,"delimiter"],[/option\b/,"keyword","@option.$S2"],[/rpc\b/,"keyword","@rpc.$S2"],[/\[/,{token:"@brackets",bracket:"@open",next:"@options.$S2"}],[/}/,{token:"@brackets",bracket:"@close",next:"@pop"}]],rpc:[{include:"@whitespace"},[/@identifier/,"identifier"],[/\(/,{token:"@brackets",bracket:"@open",switchTo:"@request.$S2"}],[/{/,{token:"@brackets",bracket:"@open",next:"@methodOptions.$S2"}],[/;/,"delimiter","@pop"]],request:[{include:"@whitespace"},[/@messageType/,{cases:{stream:{token:"keyword",next:"@type.$S2"},"@default":"type.identifier"}}],[/\)/,{token:"@brackets",bracket:"@close",switchTo:"@returns.$S2"}]],returns:[{include:"@whitespace"},[/returns\b/,"keyword"],[/\(/,{token:"@brackets",bracket:"@open",switchTo:"@response.$S2"}]],response:[{include:"@whitespace"},[/@messageType/,{cases:{stream:{token:"keyword",next:"@type.$S2"},"@default":"type.identifier"}}],[/\)/,{token:"@brackets",bracket:"@close",switchTo:"@rpc.$S2"}]],methodOptions:[{include:"@whitespace"},{include:"@constant"},[/;/,"delimiter"],["option","keyword"],[/@optionName/,"annotation"],[/[()]/,"annotation.brackets"],[/=/,"operator"],[/}/,{token:"@brackets",bracket:"@close",next:"@pop"}]],comment:[[/[^\/*]+/,"comment"],[/\/\*/,"comment","@push"],["\\*/","comment","@pop"],[/[\/*]/,"comment"]],string:[[/[^\\"]+/,"string"],[/@escapes/,"string.escape"],[/\\./,"string.escape.invalid"],[/"/,{token:"string.quote",bracket:"@close",next:"@pop"}]],stringSingle:[[/[^\\']+/,"string"],[/@escapes/,"string.escape"],[/\\./,"string.escape.invalid"],[/'/,{token:"string.quote",bracket:"@close",next:"@pop"}]],constant:[["@boolLit","keyword.constant"],["@hexLit","number.hex"],["@octalLit","number.octal"],["@decimalLit","number"],["@floatLit","number.float"],[/("([^"\\]|\\.)*|'([^'\\]|\\.)*)$/,"string.invalid"],[/"/,{token:"string.quote",bracket:"@open",next:"@string"}],[/'/,{token:"string.quote",bracket:"@open",next:"@stringSingle"}],[/{/,{token:"@brackets",bracket:"@open",next:"@prototext"}],[/identifier/,"identifier"]],whitespace:[[/[ \t\r\n]+/,"white"],[/\/\*/,"comment","@comment"],[/\/\/.*$/,"comment"]],prototext:[{include:"@whitespace"},{include:"@constant"},[/@identifier/,"identifier"],[/[:;]/,"delimiter"],[/}/,{token:"@brackets",bracket:"@close",next:"@pop"}]]}}},11138:function(e,t,i){"use strict";i.r(t),(0,i(70266).H)({id:"pug",extensions:[".jade",".pug"],aliases:["Pug","Jade","jade"],loader:()=>Promise.resolve().then(i.bind(i,46378))})},46378:function(e,t,i){"use strict";i.r(t),i.d(t,{conf:function(){return n},language:function(){return o}});var n={comments:{lineComment:"//"},brackets:[["{","}"],["[","]"],["(",")"]],autoClosingPairs:[{open:'"',close:'"',notIn:["string","comment"]},{open:"'",close:"'",notIn:["string","comment"]},{open:"{",close:"}",notIn:["string","comment"]},{open:"[",close:"]",notIn:["string","comment"]},{open:"(",close:")",notIn:["string","comment"]}],folding:{offSide:!0}},o={defaultToken:"",tokenPostfix:".pug",ignoreCase:!0,brackets:[{token:"delimiter.curly",open:"{",close:"}"},{token:"delimiter.array",open:"[",close:"]"},{token:"delimiter.parenthesis",open:"(",close:")"}],keywords:["append","block","case","default","doctype","each","else","extends","for","if","in","include","mixin","typeof","unless","var","when"],tags:["a","abbr","acronym","address","area","article","aside","audio","b","base","basefont","bdi","bdo","blockquote","body","br","button","canvas","caption","center","cite","code","col","colgroup","command","datalist","dd","del","details","dfn","div","dl","dt","em","embed","fieldset","figcaption","figure","font","footer","form","frame","frameset","h1","h2","h3","h4","h5","h6","head","header","hgroup","hr","html","i","iframe","img","input","ins","keygen","kbd","label","li","link","map","mark","menu","meta","meter","nav","noframes","noscript","object","ol","optgroup","option","output","p","param","pre","progress","q","rp","rt","ruby","s","samp","script","section","select","small","source","span","strike","strong","style","sub","summary","sup","table","tbody","td","textarea","tfoot","th","thead","time","title","tr","tracks","tt","u","ul","video","wbr"],symbols:/[\+\-\*\%\&\|\!\=\/\.\,\:]+/,escapes:/\\(?:[abfnrtv\\"']|x[0-9A-Fa-f]{1,4}|u[0-9A-Fa-f]{4}|U[0-9A-Fa-f]{8})/,tokenizer:{root:[[/^(\s*)([a-zA-Z_-][\w-]*)/,{cases:{"$2@tags":{cases:{"@eos":["","tag"],"@default":["",{token:"tag",next:"@tag.$1"}]}},"$2@keywords":["",{token:"keyword.$2"}],"@default":["",""]}}],[/^(\s*)(#[a-zA-Z_-][\w-]*)/,{cases:{"@eos":["","tag.id"],"@default":["",{token:"tag.id",next:"@tag.$1"}]}}],[/^(\s*)(\.[a-zA-Z_-][\w-]*)/,{cases:{"@eos":["","tag.class"],"@default":["",{token:"tag.class",next:"@tag.$1"}]}}],[/^(\s*)(\|.*)$/,""],{include:"@whitespace"},[/[a-zA-Z_$][\w$]*/,{cases:{"@keywords":{token:"keyword.$0"},"@default":""}}],[/[{}()\[\]]/,"@brackets"],[/@symbols/,"delimiter"],[/\d+\.\d+([eE][\-+]?\d+)?/,"number.float"],[/\d+/,"number"],[/"/,"string",'@string."'],[/'/,"string","@string.'"]],tag:[[/(\.)(\s*$)/,[{token:"delimiter",next:"@blockText.$S2."},""]],[/\s+/,{token:"",next:"@simpleText"}],[/#[a-zA-Z_-][\w-]*/,{cases:{"@eos":{token:"tag.id",next:"@pop"},"@default":"tag.id"}}],[/\.[a-zA-Z_-][\w-]*/,{cases:{"@eos":{token:"tag.class",next:"@pop"},"@default":"tag.class"}}],[/\(/,{token:"delimiter.parenthesis",next:"@attributeList"}]],simpleText:[[/[^#]+$/,{token:"",next:"@popall"}],[/[^#]+/,{token:""}],[/(#{)([^}]*)(})/,{cases:{"@eos":["interpolation.delimiter","interpolation",{token:"interpolation.delimiter",next:"@popall"}],"@default":["interpolation.delimiter","interpolation","interpolation.delimiter"]}}],[/#$/,{token:"",next:"@popall"}],[/#/,""]],attributeList:[[/\s+/,""],[/(\w+)(\s*=\s*)("|')/,["attribute.name","delimiter",{token:"attribute.value",next:"@value.$3"}]],[/\w+/,"attribute.name"],[/,/,{cases:{"@eos":{token:"attribute.delimiter",next:"@popall"},"@default":"attribute.delimiter"}}],[/\)$/,{token:"delimiter.parenthesis",next:"@popall"}],[/\)/,{token:"delimiter.parenthesis",next:"@pop"}]],whitespace:[[/^(\s*)(\/\/.*)$/,{token:"comment",next:"@blockText.$1.comment"}],[/[ \t\r\n]+/,""],[//,{token:"comment",next:"@pop"}],[//,"comment.html","@pop"],[/[^-]+/,"comment.content.html"],[/./,"comment.content.html"]],otherTag:[[/@[^@]/,{token:"@rematch",switchTo:"@razorInSimpleState.otherTag"}],[/\/?>/,"delimiter.html","@pop"],[/"([^"]*)"/,"attribute.value"],[/'([^']*)'/,"attribute.value"],[/[\w\-]+/,"attribute.name"],[/=/,"delimiter"],[/[ \t\r\n]+/]],script:[[/@[^@]/,{token:"@rematch",switchTo:"@razorInSimpleState.script"}],[/type/,"attribute.name","@scriptAfterType"],[/"([^"]*)"/,"attribute.value"],[/'([^']*)'/,"attribute.value"],[/[\w\-]+/,"attribute.name"],[/=/,"delimiter"],[/>/,{token:"delimiter.html",next:"@scriptEmbedded.text/javascript",nextEmbedded:"text/javascript"}],[/[ \t\r\n]+/],[/(<\/)(script\s*)(>)/,["delimiter.html","tag.html",{token:"delimiter.html",next:"@pop"}]]],scriptAfterType:[[/@[^@]/,{token:"@rematch",switchTo:"@razorInSimpleState.scriptAfterType"}],[/=/,"delimiter","@scriptAfterTypeEquals"],[/>/,{token:"delimiter.html",next:"@scriptEmbedded.text/javascript",nextEmbedded:"text/javascript"}],[/[ \t\r\n]+/],[/<\/script\s*>/,{token:"@rematch",next:"@pop"}]],scriptAfterTypeEquals:[[/@[^@]/,{token:"@rematch",switchTo:"@razorInSimpleState.scriptAfterTypeEquals"}],[/"([^"]*)"/,{token:"attribute.value",switchTo:"@scriptWithCustomType.$1"}],[/'([^']*)'/,{token:"attribute.value",switchTo:"@scriptWithCustomType.$1"}],[/>/,{token:"delimiter.html",next:"@scriptEmbedded.text/javascript",nextEmbedded:"text/javascript"}],[/[ \t\r\n]+/],[/<\/script\s*>/,{token:"@rematch",next:"@pop"}]],scriptWithCustomType:[[/@[^@]/,{token:"@rematch",switchTo:"@razorInSimpleState.scriptWithCustomType.$S2"}],[/>/,{token:"delimiter.html",next:"@scriptEmbedded.$S2",nextEmbedded:"$S2"}],[/"([^"]*)"/,"attribute.value"],[/'([^']*)'/,"attribute.value"],[/[\w\-]+/,"attribute.name"],[/=/,"delimiter"],[/[ \t\r\n]+/],[/<\/script\s*>/,{token:"@rematch",next:"@pop"}]],scriptEmbedded:[[/@[^@]/,{token:"@rematch",switchTo:"@razorInEmbeddedState.scriptEmbedded.$S2",nextEmbedded:"@pop"}],[/<\/script/,{token:"@rematch",next:"@pop",nextEmbedded:"@pop"}]],style:[[/@[^@]/,{token:"@rematch",switchTo:"@razorInSimpleState.style"}],[/type/,"attribute.name","@styleAfterType"],[/"([^"]*)"/,"attribute.value"],[/'([^']*)'/,"attribute.value"],[/[\w\-]+/,"attribute.name"],[/=/,"delimiter"],[/>/,{token:"delimiter.html",next:"@styleEmbedded.text/css",nextEmbedded:"text/css"}],[/[ \t\r\n]+/],[/(<\/)(style\s*)(>)/,["delimiter.html","tag.html",{token:"delimiter.html",next:"@pop"}]]],styleAfterType:[[/@[^@]/,{token:"@rematch",switchTo:"@razorInSimpleState.styleAfterType"}],[/=/,"delimiter","@styleAfterTypeEquals"],[/>/,{token:"delimiter.html",next:"@styleEmbedded.text/css",nextEmbedded:"text/css"}],[/[ \t\r\n]+/],[/<\/style\s*>/,{token:"@rematch",next:"@pop"}]],styleAfterTypeEquals:[[/@[^@]/,{token:"@rematch",switchTo:"@razorInSimpleState.styleAfterTypeEquals"}],[/"([^"]*)"/,{token:"attribute.value",switchTo:"@styleWithCustomType.$1"}],[/'([^']*)'/,{token:"attribute.value",switchTo:"@styleWithCustomType.$1"}],[/>/,{token:"delimiter.html",next:"@styleEmbedded.text/css",nextEmbedded:"text/css"}],[/[ \t\r\n]+/],[/<\/style\s*>/,{token:"@rematch",next:"@pop"}]],styleWithCustomType:[[/@[^@]/,{token:"@rematch",switchTo:"@razorInSimpleState.styleWithCustomType.$S2"}],[/>/,{token:"delimiter.html",next:"@styleEmbedded.$S2",nextEmbedded:"$S2"}],[/"([^"]*)"/,"attribute.value"],[/'([^']*)'/,"attribute.value"],[/[\w\-]+/,"attribute.name"],[/=/,"delimiter"],[/[ \t\r\n]+/],[/<\/style\s*>/,{token:"@rematch",next:"@pop"}]],styleEmbedded:[[/@[^@]/,{token:"@rematch",switchTo:"@razorInEmbeddedState.styleEmbedded.$S2",nextEmbedded:"@pop"}],[/<\/style/,{token:"@rematch",next:"@pop",nextEmbedded:"@pop"}]],razorInSimpleState:[[/@\*/,"comment.cs","@razorBlockCommentTopLevel"],[/@[{(]/,"metatag.cs","@razorRootTopLevel"],[/(@)(\s*[\w]+)/,["metatag.cs",{token:"identifier.cs",switchTo:"@$S2.$S3"}]],[/[})]/,{token:"metatag.cs",switchTo:"@$S2.$S3"}],[/\*@/,{token:"comment.cs",switchTo:"@$S2.$S3"}]],razorInEmbeddedState:[[/@\*/,"comment.cs","@razorBlockCommentTopLevel"],[/@[{(]/,"metatag.cs","@razorRootTopLevel"],[/(@)(\s*[\w]+)/,["metatag.cs",{token:"identifier.cs",switchTo:"@$S2.$S3",nextEmbedded:"$S3"}]],[/[})]/,{token:"metatag.cs",switchTo:"@$S2.$S3",nextEmbedded:"$S3"}],[/\*@/,{token:"comment.cs",switchTo:"@$S2.$S3",nextEmbedded:"$S3"}]],razorBlockCommentTopLevel:[[/\*@/,"@rematch","@pop"],[/[^*]+/,"comment.cs"],[/./,"comment.cs"]],razorBlockComment:[[/\*@/,"comment.cs","@pop"],[/[^*]+/,"comment.cs"],[/./,"comment.cs"]],razorRootTopLevel:[[/\{/,"delimiter.bracket.cs","@razorRoot"],[/\(/,"delimiter.parenthesis.cs","@razorRoot"],[/[})]/,"@rematch","@pop"],{include:"razorCommon"}],razorRoot:[[/\{/,"delimiter.bracket.cs","@razorRoot"],[/\(/,"delimiter.parenthesis.cs","@razorRoot"],[/\}/,"delimiter.bracket.cs","@pop"],[/\)/,"delimiter.parenthesis.cs","@pop"],{include:"razorCommon"}],razorCommon:[[/[a-zA-Z_]\w*/,{cases:{"@razorKeywords":{token:"keyword.cs"},"@default":"identifier.cs"}}],[/[\[\]]/,"delimiter.array.cs"],[/[ \t\r\n]+/],[/\/\/.*$/,"comment.cs"],[/@\*/,"comment.cs","@razorBlockComment"],[/"([^"]*)"/,"string.cs"],[/'([^']*)'/,"string.cs"],[/(<)([\w\-]+)(\/>)/,["delimiter.html","tag.html","delimiter.html"]],[/(<)([\w\-]+)(>)/,["delimiter.html","tag.html","delimiter.html"]],[/(<\/)([\w\-]+)(>)/,["delimiter.html","tag.html","delimiter.html"]],[/[\+\-\*\%\&\|\^\~\!\=\<\>\/\?\;\:\.\,]/,"delimiter.cs"],[/\d*\d+[eE]([\-+]?\d+)?/,"number.float.cs"],[/\d*\.\d+([eE][\-+]?\d+)?/,"number.float.cs"],[/0[xX][0-9a-fA-F']*[0-9a-fA-F]/,"number.hex.cs"],[/0[0-7']*[0-7]/,"number.octal.cs"],[/0[bB][0-1']*[0-1]/,"number.binary.cs"],[/\d[\d']*/,"number.cs"],[/\d/,"number.cs"]]},razorKeywords:["abstract","as","async","await","base","bool","break","by","byte","case","catch","char","checked","class","const","continue","decimal","default","delegate","do","double","descending","explicit","event","extern","else","enum","false","finally","fixed","float","for","foreach","from","goto","group","if","implicit","in","int","interface","internal","into","is","lock","long","nameof","new","null","namespace","object","operator","out","override","orderby","params","private","protected","public","readonly","ref","return","switch","struct","sbyte","sealed","short","sizeof","stackalloc","static","string","select","this","throw","true","try","typeof","uint","ulong","unchecked","unsafe","ushort","using","var","virtual","volatile","void","when","while","where","yield","model","inject"],escapes:/\\(?:[abfnrtv\\"']|x[0-9A-Fa-f]{1,4}|u[0-9A-Fa-f]{4}|U[0-9A-Fa-f]{8})/}},99032:function(e,t,i){"use strict";i.r(t),(0,i(70266).H)({id:"redis",extensions:[".redis"],aliases:["redis"],loader:()=>Promise.resolve().then(i.bind(i,36709))})},36709:function(e,t,i){"use strict";i.r(t),i.d(t,{conf:function(){return n},language:function(){return o}});var n={brackets:[["{","}"],["[","]"],["(",")"]],autoClosingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:'"',close:'"'},{open:"'",close:"'"}],surroundingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:'"',close:'"'},{open:"'",close:"'"}]},o={defaultToken:"",tokenPostfix:".redis",ignoreCase:!0,brackets:[{open:"[",close:"]",token:"delimiter.square"},{open:"(",close:")",token:"delimiter.parenthesis"}],keywords:["APPEND","AUTH","BGREWRITEAOF","BGSAVE","BITCOUNT","BITFIELD","BITOP","BITPOS","BLPOP","BRPOP","BRPOPLPUSH","CLIENT","KILL","LIST","GETNAME","PAUSE","REPLY","SETNAME","CLUSTER","ADDSLOTS","COUNT-FAILURE-REPORTS","COUNTKEYSINSLOT","DELSLOTS","FAILOVER","FORGET","GETKEYSINSLOT","INFO","KEYSLOT","MEET","NODES","REPLICATE","RESET","SAVECONFIG","SET-CONFIG-EPOCH","SETSLOT","SLAVES","SLOTS","COMMAND","COUNT","GETKEYS","CONFIG","GET","REWRITE","SET","RESETSTAT","DBSIZE","DEBUG","OBJECT","SEGFAULT","DECR","DECRBY","DEL","DISCARD","DUMP","ECHO","EVAL","EVALSHA","EXEC","EXISTS","EXPIRE","EXPIREAT","FLUSHALL","FLUSHDB","GEOADD","GEOHASH","GEOPOS","GEODIST","GEORADIUS","GEORADIUSBYMEMBER","GETBIT","GETRANGE","GETSET","HDEL","HEXISTS","HGET","HGETALL","HINCRBY","HINCRBYFLOAT","HKEYS","HLEN","HMGET","HMSET","HSET","HSETNX","HSTRLEN","HVALS","INCR","INCRBY","INCRBYFLOAT","KEYS","LASTSAVE","LINDEX","LINSERT","LLEN","LPOP","LPUSH","LPUSHX","LRANGE","LREM","LSET","LTRIM","MGET","MIGRATE","MONITOR","MOVE","MSET","MSETNX","MULTI","PERSIST","PEXPIRE","PEXPIREAT","PFADD","PFCOUNT","PFMERGE","PING","PSETEX","PSUBSCRIBE","PUBSUB","PTTL","PUBLISH","PUNSUBSCRIBE","QUIT","RANDOMKEY","READONLY","READWRITE","RENAME","RENAMENX","RESTORE","ROLE","RPOP","RPOPLPUSH","RPUSH","RPUSHX","SADD","SAVE","SCARD","SCRIPT","FLUSH","LOAD","SDIFF","SDIFFSTORE","SELECT","SETBIT","SETEX","SETNX","SETRANGE","SHUTDOWN","SINTER","SINTERSTORE","SISMEMBER","SLAVEOF","SLOWLOG","SMEMBERS","SMOVE","SORT","SPOP","SRANDMEMBER","SREM","STRLEN","SUBSCRIBE","SUNION","SUNIONSTORE","SWAPDB","SYNC","TIME","TOUCH","TTL","TYPE","UNSUBSCRIBE","UNLINK","UNWATCH","WAIT","WATCH","ZADD","ZCARD","ZCOUNT","ZINCRBY","ZINTERSTORE","ZLEXCOUNT","ZRANGE","ZRANGEBYLEX","ZREVRANGEBYLEX","ZRANGEBYSCORE","ZRANK","ZREM","ZREMRANGEBYLEX","ZREMRANGEBYRANK","ZREMRANGEBYSCORE","ZREVRANGE","ZREVRANGEBYSCORE","ZREVRANK","ZSCORE","ZUNIONSTORE","SCAN","SSCAN","HSCAN","ZSCAN"],operators:[],builtinFunctions:[],builtinVariables:[],pseudoColumns:[],tokenizer:{root:[{include:"@whitespace"},{include:"@pseudoColumns"},{include:"@numbers"},{include:"@strings"},{include:"@scopes"},[/[;,.]/,"delimiter"],[/[()]/,"@brackets"],[/[\w@#$]+/,{cases:{"@keywords":"keyword","@operators":"operator","@builtinVariables":"predefined","@builtinFunctions":"predefined","@default":"identifier"}}],[/[<>=!%&+\-*/|~^]/,"operator"]],whitespace:[[/\s+/,"white"]],pseudoColumns:[[/[$][A-Za-z_][\w@#$]*/,{cases:{"@pseudoColumns":"predefined","@default":"identifier"}}]],numbers:[[/0[xX][0-9a-fA-F]*/,"number"],[/[$][+-]*\d*(\.\d*)?/,"number"],[/((\d+(\.\d*)?)|(\.\d+))([eE][\-+]?\d+)?/,"number"]],strings:[[/'/,{token:"string",next:"@string"}],[/"/,{token:"string.double",next:"@stringDouble"}]],string:[[/[^']+/,"string"],[/''/,"string"],[/'/,{token:"string",next:"@pop"}]],stringDouble:[[/[^"]+/,"string.double"],[/""/,"string.double"],[/"/,{token:"string.double",next:"@pop"}]],scopes:[]}}},28897:function(e,t,i){"use strict";i.r(t),(0,i(70266).H)({id:"redshift",extensions:[],aliases:["Redshift","redshift"],loader:()=>Promise.resolve().then(i.bind(i,35777))})},35777:function(e,t,i){"use strict";i.r(t),i.d(t,{conf:function(){return n},language:function(){return o}});var n={comments:{lineComment:"--",blockComment:["/*","*/"]},brackets:[["{","}"],["[","]"],["(",")"]],autoClosingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:'"',close:'"'},{open:"'",close:"'"}],surroundingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:'"',close:'"'},{open:"'",close:"'"}]},o={defaultToken:"",tokenPostfix:".sql",ignoreCase:!0,brackets:[{open:"[",close:"]",token:"delimiter.square"},{open:"(",close:")",token:"delimiter.parenthesis"}],keywords:["AES128","AES256","ALL","ALLOWOVERWRITE","ANALYSE","ANALYZE","AND","ANY","ARRAY","AS","ASC","AUTHORIZATION","AZ64","BACKUP","BETWEEN","BINARY","BLANKSASNULL","BOTH","BYTEDICT","BZIP2","CASE","CAST","CHECK","COLLATE","COLUMN","CONSTRAINT","CREATE","CREDENTIALS","CROSS","CURRENT_DATE","CURRENT_TIME","CURRENT_TIMESTAMP","CURRENT_USER","CURRENT_USER_ID","DEFAULT","DEFERRABLE","DEFLATE","DEFRAG","DELTA","DELTA32K","DESC","DISABLE","DISTINCT","DO","ELSE","EMPTYASNULL","ENABLE","ENCODE","ENCRYPT","ENCRYPTION","END","EXCEPT","EXPLICIT","FALSE","FOR","FOREIGN","FREEZE","FROM","FULL","GLOBALDICT256","GLOBALDICT64K","GRANT","GROUP","GZIP","HAVING","IDENTITY","IGNORE","ILIKE","IN","INITIALLY","INNER","INTERSECT","INTO","IS","ISNULL","JOIN","LANGUAGE","LEADING","LEFT","LIKE","LIMIT","LOCALTIME","LOCALTIMESTAMP","LUN","LUNS","LZO","LZOP","MINUS","MOSTLY16","MOSTLY32","MOSTLY8","NATURAL","NEW","NOT","NOTNULL","NULL","NULLS","OFF","OFFLINE","OFFSET","OID","OLD","ON","ONLY","OPEN","OR","ORDER","OUTER","OVERLAPS","PARALLEL","PARTITION","PERCENT","PERMISSIONS","PLACING","PRIMARY","RAW","READRATIO","RECOVER","REFERENCES","RESPECT","REJECTLOG","RESORT","RESTORE","RIGHT","SELECT","SESSION_USER","SIMILAR","SNAPSHOT","SOME","SYSDATE","SYSTEM","TABLE","TAG","TDES","TEXT255","TEXT32K","THEN","TIMESTAMP","TO","TOP","TRAILING","TRUE","TRUNCATECOLUMNS","UNION","UNIQUE","USER","USING","VERBOSE","WALLET","WHEN","WHERE","WITH","WITHOUT"],operators:["AND","BETWEEN","IN","LIKE","NOT","OR","IS","NULL","INTERSECT","UNION","INNER","JOIN","LEFT","OUTER","RIGHT"],builtinFunctions:["current_schema","current_schemas","has_database_privilege","has_schema_privilege","has_table_privilege","age","current_time","current_timestamp","localtime","isfinite","now","ascii","get_bit","get_byte","set_bit","set_byte","to_ascii","approximate percentile_disc","avg","count","listagg","max","median","min","percentile_cont","stddev_samp","stddev_pop","sum","var_samp","var_pop","bit_and","bit_or","bool_and","bool_or","cume_dist","first_value","lag","last_value","lead","nth_value","ratio_to_report","dense_rank","ntile","percent_rank","rank","row_number","case","coalesce","decode","greatest","least","nvl","nvl2","nullif","add_months","at time zone","convert_timezone","current_date","date_cmp","date_cmp_timestamp","date_cmp_timestamptz","date_part_year","dateadd","datediff","date_part","date_trunc","extract","getdate","interval_cmp","last_day","months_between","next_day","sysdate","timeofday","timestamp_cmp","timestamp_cmp_date","timestamp_cmp_timestamptz","timestamptz_cmp","timestamptz_cmp_date","timestamptz_cmp_timestamp","timezone","to_timestamp","trunc","abs","acos","asin","atan","atan2","cbrt","ceil","ceiling","checksum","cos","cot","degrees","dexp","dlog1","dlog10","exp","floor","ln","log","mod","pi","power","radians","random","round","sin","sign","sqrt","tan","to_hex","bpcharcmp","btrim","bttext_pattern_cmp","char_length","character_length","charindex","chr","concat","crc32","func_sha1","initcap","left and rights","len","length","lower","lpad and rpads","ltrim","md5","octet_length","position","quote_ident","quote_literal","regexp_count","regexp_instr","regexp_replace","regexp_substr","repeat","replace","replicate","reverse","rtrim","split_part","strpos","strtol","substring","textlen","translate","trim","upper","cast","convert","to_char","to_date","to_number","json_array_length","json_extract_array_element_text","json_extract_path_text","current_setting","pg_cancel_backend","pg_terminate_backend","set_config","current_database","current_user","current_user_id","pg_backend_pid","pg_last_copy_count","pg_last_copy_id","pg_last_query_id","pg_last_unload_count","session_user","slice_num","user","version","abbrev","acosd","any","area","array_agg","array_append","array_cat","array_dims","array_fill","array_length","array_lower","array_ndims","array_position","array_positions","array_prepend","array_remove","array_replace","array_to_json","array_to_string","array_to_tsvector","array_upper","asind","atan2d","atand","bit","bit_length","bound_box","box","brin_summarize_new_values","broadcast","cardinality","center","circle","clock_timestamp","col_description","concat_ws","convert_from","convert_to","corr","cosd","cotd","covar_pop","covar_samp","current_catalog","current_query","current_role","currval","cursor_to_xml","diameter","div","encode","enum_first","enum_last","enum_range","every","family","format","format_type","generate_series","generate_subscripts","get_current_ts_config","gin_clean_pending_list","grouping","has_any_column_privilege","has_column_privilege","has_foreign_data_wrapper_privilege","has_function_privilege","has_language_privilege","has_sequence_privilege","has_server_privilege","has_tablespace_privilege","has_type_privilege","height","host","hostmask","inet_client_addr","inet_client_port","inet_merge","inet_same_family","inet_server_addr","inet_server_port","isclosed","isempty","isopen","json_agg","json_object","json_object_agg","json_populate_record","json_populate_recordset","json_to_record","json_to_recordset","jsonb_agg","jsonb_object_agg","justify_days","justify_hours","justify_interval","lastval","left","line","localtimestamp","lower_inc","lower_inf","lpad","lseg","make_date","make_interval","make_time","make_timestamp","make_timestamptz","masklen","mode","netmask","network","nextval","npoints","num_nonnulls","num_nulls","numnode","obj_description","overlay","parse_ident","path","pclose","percentile_disc","pg_advisory_lock","pg_advisory_lock_shared","pg_advisory_unlock","pg_advisory_unlock_all","pg_advisory_unlock_shared","pg_advisory_xact_lock","pg_advisory_xact_lock_shared","pg_backup_start_time","pg_blocking_pids","pg_client_encoding","pg_collation_is_visible","pg_column_size","pg_conf_load_time","pg_control_checkpoint","pg_control_init","pg_control_recovery","pg_control_system","pg_conversion_is_visible","pg_create_logical_replication_slot","pg_create_physical_replication_slot","pg_create_restore_point","pg_current_xlog_flush_location","pg_current_xlog_insert_location","pg_current_xlog_location","pg_database_size","pg_describe_object","pg_drop_replication_slot","pg_export_snapshot","pg_filenode_relation","pg_function_is_visible","pg_get_constraintdef","pg_get_expr","pg_get_function_arguments","pg_get_function_identity_arguments","pg_get_function_result","pg_get_functiondef","pg_get_indexdef","pg_get_keywords","pg_get_object_address","pg_get_owned_sequence","pg_get_ruledef","pg_get_serial_sequence","pg_get_triggerdef","pg_get_userbyid","pg_get_viewdef","pg_has_role","pg_identify_object","pg_identify_object_as_address","pg_index_column_has_property","pg_index_has_property","pg_indexam_has_property","pg_indexes_size","pg_is_in_backup","pg_is_in_recovery","pg_is_other_temp_schema","pg_is_xlog_replay_paused","pg_last_committed_xact","pg_last_xact_replay_timestamp","pg_last_xlog_receive_location","pg_last_xlog_replay_location","pg_listening_channels","pg_logical_emit_message","pg_logical_slot_get_binary_changes","pg_logical_slot_get_changes","pg_logical_slot_peek_binary_changes","pg_logical_slot_peek_changes","pg_ls_dir","pg_my_temp_schema","pg_notification_queue_usage","pg_opclass_is_visible","pg_operator_is_visible","pg_opfamily_is_visible","pg_options_to_table","pg_postmaster_start_time","pg_read_binary_file","pg_read_file","pg_relation_filenode","pg_relation_filepath","pg_relation_size","pg_reload_conf","pg_replication_origin_create","pg_replication_origin_drop","pg_replication_origin_oid","pg_replication_origin_progress","pg_replication_origin_session_is_setup","pg_replication_origin_session_progress","pg_replication_origin_session_reset","pg_replication_origin_session_setup","pg_replication_origin_xact_reset","pg_replication_origin_xact_setup","pg_rotate_logfile","pg_size_bytes","pg_size_pretty","pg_sleep","pg_sleep_for","pg_sleep_until","pg_start_backup","pg_stat_file","pg_stop_backup","pg_switch_xlog","pg_table_is_visible","pg_table_size","pg_tablespace_databases","pg_tablespace_location","pg_tablespace_size","pg_total_relation_size","pg_trigger_depth","pg_try_advisory_lock","pg_try_advisory_lock_shared","pg_try_advisory_xact_lock","pg_try_advisory_xact_lock_shared","pg_ts_config_is_visible","pg_ts_dict_is_visible","pg_ts_parser_is_visible","pg_ts_template_is_visible","pg_type_is_visible","pg_typeof","pg_xact_commit_timestamp","pg_xlog_location_diff","pg_xlog_replay_pause","pg_xlog_replay_resume","pg_xlogfile_name","pg_xlogfile_name_offset","phraseto_tsquery","plainto_tsquery","point","polygon","popen","pqserverversion","query_to_xml","querytree","quote_nullable","radius","range_merge","regexp_matches","regexp_split_to_array","regexp_split_to_table","regr_avgx","regr_avgy","regr_count","regr_intercept","regr_r2","regr_slope","regr_sxx","regr_sxy","regr_syy","right","row_security_active","row_to_json","rpad","scale","set_masklen","setseed","setval","setweight","shobj_description","sind","sprintf","statement_timestamp","stddev","string_agg","string_to_array","strip","substr","table_to_xml","table_to_xml_and_xmlschema","tand","text","to_json","to_regclass","to_regnamespace","to_regoper","to_regoperator","to_regproc","to_regprocedure","to_regrole","to_regtype","to_tsquery","to_tsvector","transaction_timestamp","ts_debug","ts_delete","ts_filter","ts_headline","ts_lexize","ts_parse","ts_rank","ts_rank_cd","ts_rewrite","ts_stat","ts_token_type","tsquery_phrase","tsvector_to_array","tsvector_update_trigger","tsvector_update_trigger_column","txid_current","txid_current_snapshot","txid_snapshot_xip","txid_snapshot_xmax","txid_snapshot_xmin","txid_visible_in_snapshot","unnest","upper_inc","upper_inf","variance","width","width_bucket","xml_is_well_formed","xml_is_well_formed_content","xml_is_well_formed_document","xmlagg","xmlcomment","xmlconcat","xmlelement","xmlexists","xmlforest","xmlparse","xmlpi","xmlroot","xmlserialize","xpath","xpath_exists"],builtinVariables:[],pseudoColumns:[],tokenizer:{root:[{include:"@comments"},{include:"@whitespace"},{include:"@pseudoColumns"},{include:"@numbers"},{include:"@strings"},{include:"@complexIdentifiers"},{include:"@scopes"},[/[;,.]/,"delimiter"],[/[()]/,"@brackets"],[/[\w@#$]+/,{cases:{"@keywords":"keyword","@operators":"operator","@builtinVariables":"predefined","@builtinFunctions":"predefined","@default":"identifier"}}],[/[<>=!%&+\-*/|~^]/,"operator"]],whitespace:[[/\s+/,"white"]],comments:[[/--+.*/,"comment"],[/\/\*/,{token:"comment.quote",next:"@comment"}]],comment:[[/[^*/]+/,"comment"],[/\*\//,{token:"comment.quote",next:"@pop"}],[/./,"comment"]],pseudoColumns:[[/[$][A-Za-z_][\w@#$]*/,{cases:{"@pseudoColumns":"predefined","@default":"identifier"}}]],numbers:[[/0[xX][0-9a-fA-F]*/,"number"],[/[$][+-]*\d*(\.\d*)?/,"number"],[/((\d+(\.\d*)?)|(\.\d+))([eE][\-+]?\d+)?/,"number"]],strings:[[/'/,{token:"string",next:"@string"}]],string:[[/[^']+/,"string"],[/''/,"string"],[/'/,{token:"string",next:"@pop"}]],complexIdentifiers:[[/"/,{token:"identifier.quote",next:"@quotedIdentifier"}]],quotedIdentifier:[[/[^"]+/,"identifier"],[/""/,"identifier"],[/"/,{token:"identifier.quote",next:"@pop"}]],scopes:[]}}},45439:function(e,t,i){"use strict";i.r(t),(0,i(70266).H)({id:"restructuredtext",extensions:[".rst"],aliases:["reStructuredText","restructuredtext"],loader:()=>Promise.resolve().then(i.bind(i,56876))})},56876:function(e,t,i){"use strict";i.r(t),i.d(t,{conf:function(){return n},language:function(){return o}});var n={brackets:[["{","}"],["[","]"],["(",")"]],autoClosingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:"<",close:">",notIn:["string"]}],surroundingPairs:[{open:"(",close:")"},{open:"[",close:"]"},{open:"`",close:"`"}],folding:{markers:{start:new RegExp("^\\s*\x3c!--\\s*#?region\\b.*--\x3e"),end:new RegExp("^\\s*\x3c!--\\s*#?endregion\\b.*--\x3e")}}},o={defaultToken:"",tokenPostfix:".rst",control:/[\\`*_\[\]{}()#+\-\.!]/,escapes:/\\(?:@control)/,empty:["area","base","basefont","br","col","frame","hr","img","input","isindex","link","meta","param"],alphanumerics:/[A-Za-z0-9]/,simpleRefNameWithoutBq:/(?:@alphanumerics[-_+:.]*@alphanumerics)+|(?:@alphanumerics+)/,simpleRefName:/(?:`@phrase`|@simpleRefNameWithoutBq)/,phrase:/@simpleRefNameWithoutBq(?:\s@simpleRefNameWithoutBq)*/,citationName:/[A-Za-z][A-Za-z0-9-_.]*/,blockLiteralStart:/(?:[!"#$%&'()*+,-./:;<=>?@\[\]^_`{|}~]|[\s])/,precedingChars:/(?:[ -:/'"<([{])/,followingChars:/(?:[ -.,:;!?/'")\]}>]|$)/,punctuation:/(=|-|~|`|#|"|\^|\+|\*|:|\.|'|_|\+)/,tokenizer:{root:[[/^(@punctuation{3,}$){1,1}?/,"keyword"],[/^\s*([\*\-+‣•]|[a-zA-Z0-9]+\.|\([a-zA-Z0-9]+\)|[a-zA-Z0-9]+\))\s/,"keyword"],[/([ ]::)\s*$/,"keyword","@blankLineOfLiteralBlocks"],[/(::)\s*$/,"keyword","@blankLineOfLiteralBlocks"],{include:"@tables"},{include:"@explicitMarkupBlocks"},{include:"@inlineMarkup"}],explicitMarkupBlocks:[{include:"@citations"},{include:"@footnotes"},[/^(\.\.\s)(@simpleRefName)(::\s)(.*)$/,[{token:"",next:"subsequentLines"},"keyword","",""]],[/^(\.\.)(\s+)(_)(@simpleRefName)(:)(\s+)(.*)/,[{token:"",next:"hyperlinks"},"","","string.link","","","string.link"]],[/^((?:(?:\.\.)(?:\s+))?)(__)(:)(\s+)(.*)/,[{token:"",next:"subsequentLines"},"","","","string.link"]],[/^(__\s+)(.+)/,["","string.link"]],[/^(\.\.)( \|)([^| ]+[^|]*[^| ]*)(\| )(@simpleRefName)(:: .*)/,[{token:"",next:"subsequentLines"},"","string.link","","keyword",""],"@rawBlocks"],[/(\|)([^| ]+[^|]*[^| ]*)(\|_{0,2})/,["","string.link",""]],[/^(\.\.)([ ].*)$/,[{token:"",next:"@comments"},"comment"]]],inlineMarkup:[{include:"@citationsReference"},{include:"@footnotesReference"},[/(@simpleRefName)(_{1,2})/,["string.link",""]],[/(`)([^<`]+\s+)(<)(.*)(>)(`)(_)/,["","string.link","","string.link","","",""]],[/\*\*([^\\*]|\*(?!\*))+\*\*/,"strong"],[/\*[^*]+\*/,"emphasis"],[/(``)((?:[^`]|\`(?!`))+)(``)/,["","keyword",""]],[/(__\s+)(.+)/,["","keyword"]],[/(:)((?:@simpleRefNameWithoutBq)?)(:`)([^`]+)(`)/,["","keyword","","",""]],[/(`)([^`]+)(`:)((?:@simpleRefNameWithoutBq)?)(:)/,["","","","keyword",""]],[/(`)([^`]+)(`)/,""],[/(_`)(@phrase)(`)/,["","string.link",""]]],citations:[[/^(\.\.\s+\[)((?:@citationName))(\]\s+)(.*)/,[{token:"",next:"@subsequentLines"},"string.link","",""]]],citationsReference:[[/(\[)(@citationName)(\]_)/,["","string.link",""]]],footnotes:[[/^(\.\.\s+\[)((?:[0-9]+))(\]\s+.*)/,[{token:"",next:"@subsequentLines"},"string.link",""]],[/^(\.\.\s+\[)((?:#@simpleRefName?))(\]\s+)(.*)/,[{token:"",next:"@subsequentLines"},"string.link","",""]],[/^(\.\.\s+\[)((?:\*))(\]\s+)(.*)/,[{token:"",next:"@subsequentLines"},"string.link","",""]]],footnotesReference:[[/(\[)([0-9]+)(\])(_)/,["","string.link","",""]],[/(\[)(#@simpleRefName?)(\])(_)/,["","string.link","",""]],[/(\[)(\*)(\])(_)/,["","string.link","",""]]],blankLineOfLiteralBlocks:[[/^$/,"","@subsequentLinesOfLiteralBlocks"],[/^.*$/,"","@pop"]],subsequentLinesOfLiteralBlocks:[[/(@blockLiteralStart+)(.*)/,["keyword",""]],[/^(?!blockLiteralStart)/,"","@popall"]],subsequentLines:[[/^[\s]+.*/,""],[/^(?!\s)/,"","@pop"]],hyperlinks:[[/^[\s]+.*/,"string.link"],[/^(?!\s)/,"","@pop"]],comments:[[/^[\s]+.*/,"comment"],[/^(?!\s)/,"","@pop"]],tables:[[/\+-[+-]+/,"keyword"],[/\+=[+=]+/,"keyword"]]}}},94184:function(e,t,i){"use strict";i.r(t),(0,i(70266).H)({id:"ruby",extensions:[".rb",".rbx",".rjs",".gemspec",".pp"],filenames:["rakefile","Gemfile"],aliases:["Ruby","rb"],loader:()=>Promise.resolve().then(i.bind(i,1636))})},1636:function(e,t,i){"use strict";i.r(t),i.d(t,{conf:function(){return n},language:function(){return o}});var n={comments:{lineComment:"#",blockComment:["=begin","=end"]},brackets:[["(",")"],["{","}"],["[","]"]],autoClosingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:'"',close:'"'},{open:"'",close:"'"}],surroundingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:'"',close:'"'},{open:"'",close:"'"}],indentationRules:{increaseIndentPattern:new RegExp("^\\s*((begin|class|(private|protected)\\s+def|def|else|elsif|ensure|for|if|module|rescue|unless|until|when|while|case)|([^#]*\\sdo\\b)|([^#]*=\\s*(case|if|unless)))\\b([^#\\{;]|(\"|'|/).*\\4)*(#.*)?$"),decreaseIndentPattern:new RegExp("^\\s*([}\\]]([,)]?\\s*(#|$)|\\.[a-zA-Z_]\\w*\\b)|(end|rescue|ensure|else|elsif|when)\\b)")}},o={tokenPostfix:".ruby",keywords:["__LINE__","__ENCODING__","__FILE__","BEGIN","END","alias","and","begin","break","case","class","def","defined?","do","else","elsif","end","ensure","for","false","if","in","module","next","nil","not","or","redo","rescue","retry","return","self","super","then","true","undef","unless","until","when","while","yield"],keywordops:["::","..","...","?",":","=>"],builtins:["require","public","private","include","extend","attr_reader","protected","private_class_method","protected_class_method","new"],declarations:["module","class","def","case","do","begin","for","if","while","until","unless"],linedecls:["def","case","do","begin","for","if","while","until","unless"],operators:["^","&","|","<=>","==","===","!~","=~",">",">=","<","<=","<<",">>","+","-","*","/","%","**","~","+@","-@","[]","[]=","`","+=","-=","*=","**=","/=","^=","%=","<<=",">>=","&=","&&=","||=","|="],brackets:[{open:"(",close:")",token:"delimiter.parenthesis"},{open:"{",close:"}",token:"delimiter.curly"},{open:"[",close:"]",token:"delimiter.square"}],symbols:/[=>"}],[/%([qws])(@delim)/,{token:"string.$1.delim",switchTo:"@qstring.$1.$2.$2"}],[/%r\(/,{token:"regexp.delim",switchTo:"@pregexp.(.)"}],[/%r\[/,{token:"regexp.delim",switchTo:"@pregexp.[.]"}],[/%r\{/,{token:"regexp.delim",switchTo:"@pregexp.{.}"}],[/%r"}],[/%r(@delim)/,{token:"regexp.delim",switchTo:"@pregexp.$1.$1"}],[/%(x|W|Q?)\(/,{token:"string.$1.delim",switchTo:"@qqstring.$1.(.)"}],[/%(x|W|Q?)\[/,{token:"string.$1.delim",switchTo:"@qqstring.$1.[.]"}],[/%(x|W|Q?)\{/,{token:"string.$1.delim",switchTo:"@qqstring.$1.{.}"}],[/%(x|W|Q?)"}],[/%(x|W|Q?)(@delim)/,{token:"string.$1.delim",switchTo:"@qqstring.$1.$2.$2"}],[/%([rqwsxW]|Q?)./,{token:"invalid",next:"@pop"}],[/./,{token:"invalid",next:"@pop"}]],qstring:[[/\\$/,"string.$S2.escape"],[/\\./,"string.$S2.escape"],[/./,{cases:{"$#==$S4":{token:"string.$S2.delim",next:"@pop"},"$#==$S3":{token:"string.$S2.delim",next:"@push"},"@default":"string.$S2"}}]],qqstring:[[/#/,"string.$S2.escape","@interpolated"],{include:"@qstring"}],whitespace:[[/[ \t\r\n]+/,""],[/^\s*=begin\b/,"comment","@comment"],[/#.*$/,"comment"]],comment:[[/[^=]+/,"comment"],[/^\s*=begin\b/,"comment.invalid"],[/^\s*=end\b.*/,"comment","@pop"],[/[=]/,"comment"]]}}},48367:function(e,t,i){"use strict";i.r(t),(0,i(70266).H)({id:"rust",extensions:[".rs",".rlib"],aliases:["Rust","rust"],loader:()=>Promise.resolve().then(i.bind(i,35056))})},35056:function(e,t,i){"use strict";i.r(t),i.d(t,{conf:function(){return n},language:function(){return o}});var n={comments:{lineComment:"//",blockComment:["/*","*/"]},brackets:[["{","}"],["[","]"],["(",")"]],autoClosingPairs:[{open:"[",close:"]"},{open:"{",close:"}"},{open:"(",close:")"},{open:'"',close:'"',notIn:["string"]}],surroundingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:'"',close:'"'},{open:"'",close:"'"}],folding:{markers:{start:new RegExp("^\\s*#pragma\\s+region\\b"),end:new RegExp("^\\s*#pragma\\s+endregion\\b")}}},o={tokenPostfix:".rust",defaultToken:"invalid",keywords:["as","async","await","box","break","const","continue","crate","dyn","else","enum","extern","false","fn","for","if","impl","in","let","loop","match","mod","move","mut","pub","ref","return","self","static","struct","super","trait","true","try","type","unsafe","use","where","while","catch","default","union","static","abstract","alignof","become","do","final","macro","offsetof","override","priv","proc","pure","sizeof","typeof","unsized","virtual","yield"],typeKeywords:["Self","m32","m64","m128","f80","f16","f128","int","uint","float","char","bool","u8","u16","u32","u64","f32","f64","i8","i16","i32","i64","str","Option","Either","c_float","c_double","c_void","FILE","fpos_t","DIR","dirent","c_char","c_schar","c_uchar","c_short","c_ushort","c_int","c_uint","c_long","c_ulong","size_t","ptrdiff_t","clock_t","time_t","c_longlong","c_ulonglong","intptr_t","uintptr_t","off_t","dev_t","ino_t","pid_t","mode_t","ssize_t"],constants:["true","false","Some","None","Left","Right","Ok","Err"],supportConstants:["EXIT_FAILURE","EXIT_SUCCESS","RAND_MAX","EOF","SEEK_SET","SEEK_CUR","SEEK_END","_IOFBF","_IONBF","_IOLBF","BUFSIZ","FOPEN_MAX","FILENAME_MAX","L_tmpnam","TMP_MAX","O_RDONLY","O_WRONLY","O_RDWR","O_APPEND","O_CREAT","O_EXCL","O_TRUNC","S_IFIFO","S_IFCHR","S_IFBLK","S_IFDIR","S_IFREG","S_IFMT","S_IEXEC","S_IWRITE","S_IREAD","S_IRWXU","S_IXUSR","S_IWUSR","S_IRUSR","F_OK","R_OK","W_OK","X_OK","STDIN_FILENO","STDOUT_FILENO","STDERR_FILENO"],supportMacros:["format!","print!","println!","panic!","format_args!","unreachable!","write!","writeln!"],operators:["!","!=","%","%=","&","&=","&&","*","*=","+","+=","-","-=","->",".","..","...","/","/=",":",";","<<","<<=","<","<=","=","==","=>",">",">=",">>",">>=","@","^","^=","|","|=","||","_","?","#"],escapes:/\\([nrt0\"''\\]|x\h{2}|u\{\h{1,6}\})/,delimiters:/[,]/,symbols:/[\#\!\%\&\*\+\-\.\/\:\;\<\=\>\@\^\|_\?]+/,intSuffixes:/[iu](8|16|32|64|128|size)/,floatSuffixes:/f(32|64)/,tokenizer:{root:[[/r(#*)"/,{token:"string.quote",bracket:"@open",next:"@stringraw.$1"}],[/[a-zA-Z][a-zA-Z0-9_]*!?|_[a-zA-Z0-9_]+/,{cases:{"@typeKeywords":"keyword.type","@keywords":"keyword","@supportConstants":"keyword","@supportMacros":"keyword","@constants":"keyword","@default":"identifier"}}],[/\$/,"identifier"],[/'[a-zA-Z_][a-zA-Z0-9_]*(?=[^\'])/,"identifier"],[/'(\S|@escapes)'/,"string.byteliteral"],[/"/,{token:"string.quote",bracket:"@open",next:"@string"}],{include:"@numbers"},{include:"@whitespace"},[/@delimiters/,{cases:{"@keywords":"keyword","@default":"delimiter"}}],[/[{}()\[\]<>]/,"@brackets"],[/@symbols/,{cases:{"@operators":"operator","@default":""}}]],whitespace:[[/[ \t\r\n]+/,"white"],[/\/\*/,"comment","@comment"],[/\/\/.*$/,"comment"]],comment:[[/[^\/*]+/,"comment"],[/\/\*/,"comment","@push"],["\\*/","comment","@pop"],[/[\/*]/,"comment"]],string:[[/[^\\"]+/,"string"],[/@escapes/,"string.escape"],[/\\./,"string.escape.invalid"],[/"/,{token:"string.quote",bracket:"@close",next:"@pop"}]],stringraw:[[/[^"#]+/,{token:"string"}],[/"(#*)/,{cases:{"$1==$S2":{token:"string.quote",bracket:"@close",next:"@pop"},"@default":{token:"string"}}}],[/["#]/,{token:"string"}]],numbers:[[/(0o[0-7_]+)(@intSuffixes)?/,{token:"number"}],[/(0b[0-1_]+)(@intSuffixes)?/,{token:"number"}],[/[\d][\d_]*(\.[\d][\d_]*)?[eE][+-][\d_]+(@floatSuffixes)?/,{token:"number"}],[/\b(\d\.?[\d_]*)(@floatSuffixes)?\b/,{token:"number"}],[/(0x[\da-fA-F]+)_?(@intSuffixes)?/,{token:"number"}],[/[\d][\d_]*(@intSuffixes?)?/,{token:"number"}]]}}},33464:function(e,t,i){"use strict";i.r(t),(0,i(70266).H)({id:"sb",extensions:[".sb"],aliases:["Small Basic","sb"],loader:()=>Promise.resolve().then(i.bind(i,77673))})},77673:function(e,t,i){"use strict";i.r(t),i.d(t,{conf:function(){return n},language:function(){return o}});var n={comments:{lineComment:"'"},brackets:[["(",")"],["[","]"],["If","EndIf"],["While","EndWhile"],["For","EndFor"],["Sub","EndSub"]],autoClosingPairs:[{open:'"',close:'"',notIn:["string","comment"]},{open:"(",close:")",notIn:["string","comment"]},{open:"[",close:"]",notIn:["string","comment"]}]},o={defaultToken:"",tokenPostfix:".sb",ignoreCase:!0,brackets:[{token:"delimiter.array",open:"[",close:"]"},{token:"delimiter.parenthesis",open:"(",close:")"},{token:"keyword.tag-if",open:"If",close:"EndIf"},{token:"keyword.tag-while",open:"While",close:"EndWhile"},{token:"keyword.tag-for",open:"For",close:"EndFor"},{token:"keyword.tag-sub",open:"Sub",close:"EndSub"}],keywords:["Else","ElseIf","EndFor","EndIf","EndSub","EndWhile","For","Goto","If","Step","Sub","Then","To","While"],tagwords:["If","Sub","While","For"],operators:[">","<","<>","<=",">=","And","Or","+","-","*","/","="],identifier:/[a-zA-Z_][\w]*/,symbols:/[=><:+\-*\/%\.,]+/,escapes:/\\(?:[abfnrtv\\"']|x[0-9A-Fa-f]{1,4}|u[0-9A-Fa-f]{4}|U[0-9A-Fa-f]{8})/,tokenizer:{root:[{include:"@whitespace"},[/(@identifier)(?=[.])/,"type"],[/@identifier/,{cases:{"@keywords":{token:"keyword.$0"},"@operators":"operator","@default":"variable.name"}}],[/([.])(@identifier)/,{cases:{$2:["delimiter","type.member"],"@default":""}}],[/\d*\.\d+/,"number.float"],[/\d+/,"number"],[/[()\[\]]/,"@brackets"],[/@symbols/,{cases:{"@operators":"operator","@default":"delimiter"}}],[/"([^"\\]|\\.)*$/,"string.invalid"],[/"/,"string","@string"]],whitespace:[[/[ \t\r\n]+/,""],[/(\').*$/,"comment"]],string:[[/[^\\"]+/,"string"],[/@escapes/,"string.escape"],[/\\./,"string.escape.invalid"],[/"C?/,"string","@pop"]]}}},4595:function(e,t,i){"use strict";i.r(t),(0,i(70266).H)({id:"scala",extensions:[".scala",".sc",".sbt"],aliases:["Scala","scala","SBT","Sbt","sbt","Dotty","dotty"],mimetypes:["text/x-scala-source","text/x-scala","text/x-sbt","text/x-dotty"],loader:()=>Promise.resolve().then(i.bind(i,14892))})},14892:function(e,t,i){"use strict";i.r(t),i.d(t,{conf:function(){return n},language:function(){return o}});var n={wordPattern:/(unary_[@~!#%^&*()\-=+\\|:<>\/?]+)|([a-zA-Z_$][\w$]*?_=)|(`[^`]+`)|([a-zA-Z_$][\w$]*)/g,comments:{lineComment:"//",blockComment:["/*","*/"]},brackets:[["{","}"],["[","]"],["(",")"]],autoClosingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:'"',close:'"'},{open:"'",close:"'"}],surroundingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:'"',close:'"'},{open:"'",close:"'"}],folding:{markers:{start:new RegExp("^\\s*//\\s*(?:(?:#?region\\b)|(?:))")}}},o={tokenPostfix:".scala",keywords:["asInstanceOf","catch","class","classOf","def","do","else","extends","finally","for","foreach","forSome","if","import","isInstanceOf","macro","match","new","object","package","return","throw","trait","try","type","until","val","var","while","with","yield","given","enum","then"],softKeywords:["as","export","extension","end","derives","on"],constants:["true","false","null","this","super"],modifiers:["abstract","final","implicit","lazy","override","private","protected","sealed"],softModifiers:["inline","opaque","open","transparent","using"],name:/(?:[a-z_$][\w$]*|`[^`]+`)/,type:/(?:[A-Z][\w$]*)/,symbols:/[=>))/,["@brackets","white","variable"]],[/@name/,{cases:{"@keywords":"keyword","@softKeywords":"keyword","@modifiers":"keyword.modifier","@softModifiers":"keyword.modifier","@constants":{token:"constant",next:"@allowMethod"},"@default":{token:"identifier",next:"@allowMethod"}}}],[/@type/,"type","@allowMethod"],{include:"@whitespace"},[/@[a-zA-Z_$][\w$]*(?:\.[a-zA-Z_$][\w$]*)*/,"annotation"],[/[{(]/,"@brackets"],[/[})]/,"@brackets","@allowMethod"],[/\[/,"operator.square"],[/](?!\s*(?:va[rl]|def|type)\b)/,"operator.square","@allowMethod"],[/]/,"operator.square"],[/([=-]>|<-|>:|<:|:>|<%)(?=[\s\w()[\]{},\."'`])/,"keyword"],[/@symbols/,"operator"],[/[;,\.]/,"delimiter"],[/'[a-zA-Z$][\w$]*(?!')/,"attribute.name"],[/'[^\\']'/,"string","@allowMethod"],[/(')(@escapes)(')/,["string","string.escape",{token:"string",next:"@allowMethod"}]],[/'/,"string.invalid"]],import:[[/;/,"delimiter","@pop"],[/^|$/,"","@pop"],[/[ \t]+/,"white"],[/[\n\r]+/,"white","@pop"],[/\/\*/,"comment","@comment"],[/@name|@type/,"type"],[/[(){}]/,"@brackets"],[/[[\]]/,"operator.square"],[/[\.,]/,"delimiter"]],allowMethod:[[/^|$/,"","@pop"],[/[ \t]+/,"white"],[/[\n\r]+/,"white","@pop"],[/\/\*/,"comment","@comment"],[/(?==>[\s\w([{])/,"keyword","@pop"],[/(@name|@symbols)(?=[ \t]*[[({"'`]|[ \t]+(?:[+-]?\.?\d|\w))/,{cases:{"@keywords":{token:"keyword",next:"@pop"},"->|<-|>:|<:|<%":{token:"keyword",next:"@pop"},"@default":{token:"@rematch",next:"@pop"}}}],["","","@pop"]],comment:[[/[^\/*]+/,"comment"],[/\/\*/,"comment","@push"],[/\*\//,"comment","@pop"],[/[\/*]/,"comment"]],case:[[/\b_\*/,"key"],[/\b(_|true|false|null|this|super)\b/,"keyword","@allowMethod"],[/\bif\b|=>/,"keyword","@pop"],[/`[^`]+`/,"identifier","@allowMethod"],[/@name/,"variable","@allowMethod"],[/:::?|\||@(?![a-z_$])/,"keyword"],{include:"@root"}],vardef:[[/\b_\*/,"key"],[/\b(_|true|false|null|this|super)\b/,"keyword"],[/@name/,"variable"],[/:::?|\||@(?![a-z_$])/,"keyword"],[/=|:(?!:)/,"operator","@pop"],[/$/,"white","@pop"],{include:"@root"}],string:[[/[^\\"\n\r]+/,"string"],[/@escapes/,"string.escape"],[/\\./,"string.escape.invalid"],[/"/,{token:"string.quote",bracket:"@close",switchTo:"@allowMethod"}]],stringt:[[/[^\\"\n\r]+/,"string"],[/@escapes/,"string.escape"],[/\\./,"string.escape.invalid"],[/"(?=""")/,"string"],[/"""/,{token:"string.quote",bracket:"@close",switchTo:"@allowMethod"}],[/"/,"string"]],fstring:[[/@escapes/,"string.escape"],[/"/,{token:"string.quote",bracket:"@close",switchTo:"@allowMethod"}],[/\$\$/,"string"],[/(\$)([a-z_]\w*)/,["operator","identifier"]],[/\$\{/,"operator","@interp"],[/%%/,"string"],[/(%)([\-#+ 0,(])(\d+|\.\d+|\d+\.\d+)(@fstring_conv)/,["metatag","keyword.modifier","number","metatag"]],[/(%)(\d+|\.\d+|\d+\.\d+)(@fstring_conv)/,["metatag","number","metatag"]],[/(%)([\-#+ 0,(])(@fstring_conv)/,["metatag","keyword.modifier","metatag"]],[/(%)(@fstring_conv)/,["metatag","metatag"]],[/./,"string"]],fstringt:[[/@escapes/,"string.escape"],[/"(?=""")/,"string"],[/"""/,{token:"string.quote",bracket:"@close",switchTo:"@allowMethod"}],[/\$\$/,"string"],[/(\$)([a-z_]\w*)/,["operator","identifier"]],[/\$\{/,"operator","@interp"],[/%%/,"string"],[/(%)([\-#+ 0,(])(\d+|\.\d+|\d+\.\d+)(@fstring_conv)/,["metatag","keyword.modifier","number","metatag"]],[/(%)(\d+|\.\d+|\d+\.\d+)(@fstring_conv)/,["metatag","number","metatag"]],[/(%)([\-#+ 0,(])(@fstring_conv)/,["metatag","keyword.modifier","metatag"]],[/(%)(@fstring_conv)/,["metatag","metatag"]],[/./,"string"]],sstring:[[/@escapes/,"string.escape"],[/"/,{token:"string.quote",bracket:"@close",switchTo:"@allowMethod"}],[/\$\$/,"string"],[/(\$)([a-z_]\w*)/,["operator","identifier"]],[/\$\{/,"operator","@interp"],[/./,"string"]],sstringt:[[/@escapes/,"string.escape"],[/"(?=""")/,"string"],[/"""/,{token:"string.quote",bracket:"@close",switchTo:"@allowMethod"}],[/\$\$/,"string"],[/(\$)([a-z_]\w*)/,["operator","identifier"]],[/\$\{/,"operator","@interp"],[/./,"string"]],interp:[[/{/,"operator","@push"],[/}/,"operator","@pop"],{include:"@root"}],rawstring:[[/[^"]/,"string"],[/"/,{token:"string.quote",bracket:"@close",switchTo:"@allowMethod"}]],rawstringt:[[/[^"]/,"string"],[/"(?=""")/,"string"],[/"""/,{token:"string.quote",bracket:"@close",switchTo:"@allowMethod"}],[/"/,"string"]],whitespace:[[/[ \t\r\n]+/,"white"],[/\/\*/,"comment","@comment"],[/\/\/.*$/,"comment"]]}}},8592:function(e,t,i){"use strict";i.r(t),(0,i(70266).H)({id:"scheme",extensions:[".scm",".ss",".sch",".rkt"],aliases:["scheme","Scheme"],loader:()=>Promise.resolve().then(i.bind(i,33616))})},33616:function(e,t,i){"use strict";i.r(t),i.d(t,{conf:function(){return n},language:function(){return o}});var n={comments:{lineComment:";",blockComment:["#|","|#"]},brackets:[["(",")"],["{","}"],["[","]"]],autoClosingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:'"',close:'"'}],surroundingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:'"',close:'"'}]},o={defaultToken:"",ignoreCase:!0,tokenPostfix:".scheme",brackets:[{open:"(",close:")",token:"delimiter.parenthesis"},{open:"{",close:"}",token:"delimiter.curly"},{open:"[",close:"]",token:"delimiter.square"}],keywords:["case","do","let","loop","if","else","when","cons","car","cdr","cond","lambda","lambda*","syntax-rules","format","set!","quote","eval","append","list","list?","member?","load"],constants:["#t","#f"],operators:["eq?","eqv?","equal?","and","or","not","null?"],tokenizer:{root:[[/#[xXoObB][0-9a-fA-F]+/,"number.hex"],[/[+-]?\d+(?:(?:\.\d*)?(?:[eE][+-]?\d+)?)?/,"number.float"],[/(?:\b(?:(define|define-syntax|define-macro))\b)(\s+)((?:\w|\-|\!|\?)*)/,["keyword","white","variable"]],{include:"@whitespace"},{include:"@strings"},[/[a-zA-Z_#][a-zA-Z0-9_\-\?\!\*]*/,{cases:{"@keywords":"keyword","@constants":"constant","@operators":"operators","@default":"identifier"}}]],comment:[[/[^\|#]+/,"comment"],[/#\|/,"comment","@push"],[/\|#/,"comment","@pop"],[/[\|#]/,"comment"]],whitespace:[[/[ \t\r\n]+/,"white"],[/#\|/,"comment","@comment"],[/;.*$/,"comment"]],strings:[[/"$/,"string","@popall"],[/"(?=.)/,"string","@multiLineString"]],multiLineString:[[/[^\\"]+$/,"string","@popall"],[/[^\\"]+/,"string"],[/\\./,"string.escape"],[/"/,"string","@popall"],[/\\$/,"string"]]}}},49607:function(e,t,i){"use strict";i.r(t),(0,i(70266).H)({id:"scss",extensions:[".scss"],aliases:["Sass","sass","scss"],mimetypes:["text/x-scss","text/scss"],loader:()=>Promise.resolve().then(i.bind(i,58933))})},58933:function(e,t,i){"use strict";i.r(t),i.d(t,{conf:function(){return n},language:function(){return o}});var n={wordPattern:/(#?-?\d*\.\d\w*%?)|([@$#!.:]?[\w-?]+%?)|[@#!.]/g,comments:{blockComment:["/*","*/"],lineComment:"//"},brackets:[["{","}"],["[","]"],["(",")"]],autoClosingPairs:[{open:"{",close:"}",notIn:["string","comment"]},{open:"[",close:"]",notIn:["string","comment"]},{open:"(",close:")",notIn:["string","comment"]},{open:'"',close:'"',notIn:["string","comment"]},{open:"'",close:"'",notIn:["string","comment"]}],surroundingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:'"',close:'"'},{open:"'",close:"'"}],folding:{markers:{start:new RegExp("^\\s*\\/\\*\\s*#region\\b\\s*(.*?)\\s*\\*\\/"),end:new RegExp("^\\s*\\/\\*\\s*#endregion\\b.*\\*\\/")}}},o={defaultToken:"",tokenPostfix:".scss",ws:"[ \t\n\r\f]*",identifier:"-?-?([a-zA-Z]|(\\\\(([0-9a-fA-F]{1,6}\\s?)|[^[0-9a-fA-F])))([\\w\\-]|(\\\\(([0-9a-fA-F]{1,6}\\s?)|[^[0-9a-fA-F])))*",brackets:[{open:"{",close:"}",token:"delimiter.curly"},{open:"[",close:"]",token:"delimiter.bracket"},{open:"(",close:")",token:"delimiter.parenthesis"},{open:"<",close:">",token:"delimiter.angle"}],tokenizer:{root:[{include:"@selector"}],selector:[{include:"@comments"},{include:"@import"},{include:"@variabledeclaration"},{include:"@warndebug"},["[@](include)",{token:"keyword",next:"@includedeclaration"}],["[@](keyframes|-webkit-keyframes|-moz-keyframes|-o-keyframes)",{token:"keyword",next:"@keyframedeclaration"}],["[@](page|content|font-face|-moz-document)",{token:"keyword"}],["[@](charset|namespace)",{token:"keyword",next:"@declarationbody"}],["[@](function)",{token:"keyword",next:"@functiondeclaration"}],["[@](mixin)",{token:"keyword",next:"@mixindeclaration"}],["url(\\-prefix)?\\(",{token:"meta",next:"@urldeclaration"}],{include:"@controlstatement"},{include:"@selectorname"},["[&\\*]","tag"],["[>\\+,]","delimiter"],["\\[",{token:"delimiter.bracket",next:"@selectorattribute"}],["{",{token:"delimiter.curly",next:"@selectorbody"}]],selectorbody:[["[*_]?@identifier@ws:(?=(\\s|\\d|[^{;}]*[;}]))","attribute.name","@rulevalue"],{include:"@selector"},["[@](extend)",{token:"keyword",next:"@extendbody"}],["[@](return)",{token:"keyword",next:"@declarationbody"}],["}",{token:"delimiter.curly",next:"@pop"}]],selectorname:[["#{",{token:"meta",next:"@variableinterpolation"}],["(\\.|#(?=[^{])|%|(@identifier)|:)+","tag"]],selectorattribute:[{include:"@term"},["]",{token:"delimiter.bracket",next:"@pop"}]],term:[{include:"@comments"},["url(\\-prefix)?\\(",{token:"meta",next:"@urldeclaration"}],{include:"@functioninvocation"},{include:"@numbers"},{include:"@strings"},{include:"@variablereference"},["(and\\b|or\\b|not\\b)","operator"],{include:"@name"},["([<>=\\+\\-\\*\\/\\^\\|\\~,])","operator"],[",","delimiter"],["!default","literal"],["\\(",{token:"delimiter.parenthesis",next:"@parenthizedterm"}]],rulevalue:[{include:"@term"},["!important","literal"],[";","delimiter","@pop"],["{",{token:"delimiter.curly",switchTo:"@nestedproperty"}],["(?=})",{token:"",next:"@pop"}]],nestedproperty:[["[*_]?@identifier@ws:","attribute.name","@rulevalue"],{include:"@comments"},["}",{token:"delimiter.curly",next:"@pop"}]],warndebug:[["[@](warn|debug)",{token:"keyword",next:"@declarationbody"}]],import:[["[@](import)",{token:"keyword",next:"@declarationbody"}]],variabledeclaration:[["\\$@identifier@ws:","variable.decl","@declarationbody"]],urldeclaration:[{include:"@strings"},["[^)\r\n]+","string"],["\\)",{token:"meta",next:"@pop"}]],parenthizedterm:[{include:"@term"},["\\)",{token:"delimiter.parenthesis",next:"@pop"}]],declarationbody:[{include:"@term"},[";","delimiter","@pop"],["(?=})",{token:"",next:"@pop"}]],extendbody:[{include:"@selectorname"},["!optional","literal"],[";","delimiter","@pop"],["(?=})",{token:"",next:"@pop"}]],variablereference:[["\\$@identifier","variable.ref"],["\\.\\.\\.","operator"],["#{",{token:"meta",next:"@variableinterpolation"}]],variableinterpolation:[{include:"@variablereference"},["}",{token:"meta",next:"@pop"}]],comments:[["\\/\\*","comment","@comment"],["\\/\\/+.*","comment"]],comment:[["\\*\\/","comment","@pop"],[".","comment"]],name:[["@identifier","attribute.value"]],numbers:[["(\\d*\\.)?\\d+([eE][\\-+]?\\d+)?",{token:"number",next:"@units"}],["#[0-9a-fA-F_]+(?!\\w)","number.hex"]],units:[["(em|ex|ch|rem|vmin|vmax|vw|vh|vm|cm|mm|in|px|pt|pc|deg|grad|rad|turn|s|ms|Hz|kHz|%)?","number","@pop"]],functiondeclaration:[["@identifier@ws\\(",{token:"meta",next:"@parameterdeclaration"}],["{",{token:"delimiter.curly",switchTo:"@functionbody"}]],mixindeclaration:[["@identifier@ws\\(",{token:"meta",next:"@parameterdeclaration"}],["@identifier","meta"],["{",{token:"delimiter.curly",switchTo:"@selectorbody"}]],parameterdeclaration:[["\\$@identifier@ws:","variable.decl"],["\\.\\.\\.","operator"],[",","delimiter"],{include:"@term"},["\\)",{token:"meta",next:"@pop"}]],includedeclaration:[{include:"@functioninvocation"},["@identifier","meta"],[";","delimiter","@pop"],["(?=})",{token:"",next:"@pop"}],["{",{token:"delimiter.curly",switchTo:"@selectorbody"}]],keyframedeclaration:[["@identifier","meta"],["{",{token:"delimiter.curly",switchTo:"@keyframebody"}]],keyframebody:[{include:"@term"},["{",{token:"delimiter.curly",next:"@selectorbody"}],["}",{token:"delimiter.curly",next:"@pop"}]],controlstatement:[["[@](if|else|for|while|each|media)",{token:"keyword.flow",next:"@controlstatementdeclaration"}]],controlstatementdeclaration:[["(in|from|through|if|to)\\b",{token:"keyword.flow"}],{include:"@term"},["{",{token:"delimiter.curly",switchTo:"@selectorbody"}]],functionbody:[["[@](return)",{token:"keyword"}],{include:"@variabledeclaration"},{include:"@term"},{include:"@controlstatement"},[";","delimiter"],["}",{token:"delimiter.curly",next:"@pop"}]],functioninvocation:[["@identifier\\(",{token:"meta",next:"@functionarguments"}]],functionarguments:[["\\$@identifier@ws:","attribute.name"],["[,]","delimiter"],{include:"@term"},["\\)",{token:"meta",next:"@pop"}]],strings:[['~?"',{token:"string.delimiter",next:"@stringenddoublequote"}],["~?'",{token:"string.delimiter",next:"@stringendquote"}]],stringenddoublequote:[["\\\\.","string"],['"',{token:"string.delimiter",next:"@pop"}],[".","string"]],stringendquote:[["\\\\.","string"],["'",{token:"string.delimiter",next:"@pop"}],[".","string"]]}}},78027:function(e,t,i){"use strict";i.r(t),(0,i(70266).H)({id:"shell",extensions:[".sh",".bash"],aliases:["Shell","sh"],loader:()=>Promise.resolve().then(i.bind(i,70718))})},70718:function(e,t,i){"use strict";i.r(t),i.d(t,{conf:function(){return n},language:function(){return o}});var n={comments:{lineComment:"#"},brackets:[["{","}"],["[","]"],["(",")"]],autoClosingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:'"',close:'"'},{open:"'",close:"'"},{open:"`",close:"`"}],surroundingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:'"',close:'"'},{open:"'",close:"'"},{open:"`",close:"`"}]},o={defaultToken:"",ignoreCase:!0,tokenPostfix:".shell",brackets:[{token:"delimiter.bracket",open:"{",close:"}"},{token:"delimiter.parenthesis",open:"(",close:")"},{token:"delimiter.square",open:"[",close:"]"}],keywords:["if","then","do","else","elif","while","until","for","in","esac","fi","fin","fil","done","exit","set","unset","export","function"],builtins:["ab","awk","bash","beep","cat","cc","cd","chown","chmod","chroot","clear","cp","curl","cut","diff","echo","find","gawk","gcc","get","git","grep","hg","kill","killall","ln","ls","make","mkdir","openssl","mv","nc","node","npm","ping","ps","restart","rm","rmdir","sed","service","sh","shopt","shred","source","sort","sleep","ssh","start","stop","su","sudo","svn","tee","telnet","top","touch","vi","vim","wall","wc","wget","who","write","yes","zsh"],startingWithDash:/\-+\w+/,identifiersWithDashes:/[a-zA-Z]\w+(?:@startingWithDash)+/,symbols:/[=>Promise.resolve().then(i.bind(i,94393))})},94393:function(e,t,i){"use strict";i.r(t),i.d(t,{conf:function(){return n},language:function(){return o}});var n={comments:{lineComment:"//",blockComment:["/*","*/"]},brackets:[["{","}"],["[","]"],["(",")"],["<",">"]],autoClosingPairs:[{open:'"',close:'"',notIn:["string","comment"]},{open:"{",close:"}",notIn:["string","comment"]},{open:"[",close:"]",notIn:["string","comment"]},{open:"(",close:")",notIn:["string","comment"]}]},o={defaultToken:"",tokenPostfix:".sol",brackets:[{token:"delimiter.curly",open:"{",close:"}"},{token:"delimiter.parenthesis",open:"(",close:")"},{token:"delimiter.square",open:"[",close:"]"},{token:"delimiter.angle",open:"<",close:">"}],keywords:["pragma","solidity","contract","library","using","struct","function","modifier","constructor","address","string","bool","Int","Uint","Byte","Fixed","Ufixed","int","int8","int16","int24","int32","int40","int48","int56","int64","int72","int80","int88","int96","int104","int112","int120","int128","int136","int144","int152","int160","int168","int176","int184","int192","int200","int208","int216","int224","int232","int240","int248","int256","uint","uint8","uint16","uint24","uint32","uint40","uint48","uint56","uint64","uint72","uint80","uint88","uint96","uint104","uint112","uint120","uint128","uint136","uint144","uint152","uint160","uint168","uint176","uint184","uint192","uint200","uint208","uint216","uint224","uint232","uint240","uint248","uint256","byte","bytes","bytes1","bytes2","bytes3","bytes4","bytes5","bytes6","bytes7","bytes8","bytes9","bytes10","bytes11","bytes12","bytes13","bytes14","bytes15","bytes16","bytes17","bytes18","bytes19","bytes20","bytes21","bytes22","bytes23","bytes24","bytes25","bytes26","bytes27","bytes28","bytes29","bytes30","bytes31","bytes32","fixed","fixed0x8","fixed0x16","fixed0x24","fixed0x32","fixed0x40","fixed0x48","fixed0x56","fixed0x64","fixed0x72","fixed0x80","fixed0x88","fixed0x96","fixed0x104","fixed0x112","fixed0x120","fixed0x128","fixed0x136","fixed0x144","fixed0x152","fixed0x160","fixed0x168","fixed0x176","fixed0x184","fixed0x192","fixed0x200","fixed0x208","fixed0x216","fixed0x224","fixed0x232","fixed0x240","fixed0x248","fixed0x256","fixed8x8","fixed8x16","fixed8x24","fixed8x32","fixed8x40","fixed8x48","fixed8x56","fixed8x64","fixed8x72","fixed8x80","fixed8x88","fixed8x96","fixed8x104","fixed8x112","fixed8x120","fixed8x128","fixed8x136","fixed8x144","fixed8x152","fixed8x160","fixed8x168","fixed8x176","fixed8x184","fixed8x192","fixed8x200","fixed8x208","fixed8x216","fixed8x224","fixed8x232","fixed8x240","fixed8x248","fixed16x8","fixed16x16","fixed16x24","fixed16x32","fixed16x40","fixed16x48","fixed16x56","fixed16x64","fixed16x72","fixed16x80","fixed16x88","fixed16x96","fixed16x104","fixed16x112","fixed16x120","fixed16x128","fixed16x136","fixed16x144","fixed16x152","fixed16x160","fixed16x168","fixed16x176","fixed16x184","fixed16x192","fixed16x200","fixed16x208","fixed16x216","fixed16x224","fixed16x232","fixed16x240","fixed24x8","fixed24x16","fixed24x24","fixed24x32","fixed24x40","fixed24x48","fixed24x56","fixed24x64","fixed24x72","fixed24x80","fixed24x88","fixed24x96","fixed24x104","fixed24x112","fixed24x120","fixed24x128","fixed24x136","fixed24x144","fixed24x152","fixed24x160","fixed24x168","fixed24x176","fixed24x184","fixed24x192","fixed24x200","fixed24x208","fixed24x216","fixed24x224","fixed24x232","fixed32x8","fixed32x16","fixed32x24","fixed32x32","fixed32x40","fixed32x48","fixed32x56","fixed32x64","fixed32x72","fixed32x80","fixed32x88","fixed32x96","fixed32x104","fixed32x112","fixed32x120","fixed32x128","fixed32x136","fixed32x144","fixed32x152","fixed32x160","fixed32x168","fixed32x176","fixed32x184","fixed32x192","fixed32x200","fixed32x208","fixed32x216","fixed32x224","fixed40x8","fixed40x16","fixed40x24","fixed40x32","fixed40x40","fixed40x48","fixed40x56","fixed40x64","fixed40x72","fixed40x80","fixed40x88","fixed40x96","fixed40x104","fixed40x112","fixed40x120","fixed40x128","fixed40x136","fixed40x144","fixed40x152","fixed40x160","fixed40x168","fixed40x176","fixed40x184","fixed40x192","fixed40x200","fixed40x208","fixed40x216","fixed48x8","fixed48x16","fixed48x24","fixed48x32","fixed48x40","fixed48x48","fixed48x56","fixed48x64","fixed48x72","fixed48x80","fixed48x88","fixed48x96","fixed48x104","fixed48x112","fixed48x120","fixed48x128","fixed48x136","fixed48x144","fixed48x152","fixed48x160","fixed48x168","fixed48x176","fixed48x184","fixed48x192","fixed48x200","fixed48x208","fixed56x8","fixed56x16","fixed56x24","fixed56x32","fixed56x40","fixed56x48","fixed56x56","fixed56x64","fixed56x72","fixed56x80","fixed56x88","fixed56x96","fixed56x104","fixed56x112","fixed56x120","fixed56x128","fixed56x136","fixed56x144","fixed56x152","fixed56x160","fixed56x168","fixed56x176","fixed56x184","fixed56x192","fixed56x200","fixed64x8","fixed64x16","fixed64x24","fixed64x32","fixed64x40","fixed64x48","fixed64x56","fixed64x64","fixed64x72","fixed64x80","fixed64x88","fixed64x96","fixed64x104","fixed64x112","fixed64x120","fixed64x128","fixed64x136","fixed64x144","fixed64x152","fixed64x160","fixed64x168","fixed64x176","fixed64x184","fixed64x192","fixed72x8","fixed72x16","fixed72x24","fixed72x32","fixed72x40","fixed72x48","fixed72x56","fixed72x64","fixed72x72","fixed72x80","fixed72x88","fixed72x96","fixed72x104","fixed72x112","fixed72x120","fixed72x128","fixed72x136","fixed72x144","fixed72x152","fixed72x160","fixed72x168","fixed72x176","fixed72x184","fixed80x8","fixed80x16","fixed80x24","fixed80x32","fixed80x40","fixed80x48","fixed80x56","fixed80x64","fixed80x72","fixed80x80","fixed80x88","fixed80x96","fixed80x104","fixed80x112","fixed80x120","fixed80x128","fixed80x136","fixed80x144","fixed80x152","fixed80x160","fixed80x168","fixed80x176","fixed88x8","fixed88x16","fixed88x24","fixed88x32","fixed88x40","fixed88x48","fixed88x56","fixed88x64","fixed88x72","fixed88x80","fixed88x88","fixed88x96","fixed88x104","fixed88x112","fixed88x120","fixed88x128","fixed88x136","fixed88x144","fixed88x152","fixed88x160","fixed88x168","fixed96x8","fixed96x16","fixed96x24","fixed96x32","fixed96x40","fixed96x48","fixed96x56","fixed96x64","fixed96x72","fixed96x80","fixed96x88","fixed96x96","fixed96x104","fixed96x112","fixed96x120","fixed96x128","fixed96x136","fixed96x144","fixed96x152","fixed96x160","fixed104x8","fixed104x16","fixed104x24","fixed104x32","fixed104x40","fixed104x48","fixed104x56","fixed104x64","fixed104x72","fixed104x80","fixed104x88","fixed104x96","fixed104x104","fixed104x112","fixed104x120","fixed104x128","fixed104x136","fixed104x144","fixed104x152","fixed112x8","fixed112x16","fixed112x24","fixed112x32","fixed112x40","fixed112x48","fixed112x56","fixed112x64","fixed112x72","fixed112x80","fixed112x88","fixed112x96","fixed112x104","fixed112x112","fixed112x120","fixed112x128","fixed112x136","fixed112x144","fixed120x8","fixed120x16","fixed120x24","fixed120x32","fixed120x40","fixed120x48","fixed120x56","fixed120x64","fixed120x72","fixed120x80","fixed120x88","fixed120x96","fixed120x104","fixed120x112","fixed120x120","fixed120x128","fixed120x136","fixed128x8","fixed128x16","fixed128x24","fixed128x32","fixed128x40","fixed128x48","fixed128x56","fixed128x64","fixed128x72","fixed128x80","fixed128x88","fixed128x96","fixed128x104","fixed128x112","fixed128x120","fixed128x128","fixed136x8","fixed136x16","fixed136x24","fixed136x32","fixed136x40","fixed136x48","fixed136x56","fixed136x64","fixed136x72","fixed136x80","fixed136x88","fixed136x96","fixed136x104","fixed136x112","fixed136x120","fixed144x8","fixed144x16","fixed144x24","fixed144x32","fixed144x40","fixed144x48","fixed144x56","fixed144x64","fixed144x72","fixed144x80","fixed144x88","fixed144x96","fixed144x104","fixed144x112","fixed152x8","fixed152x16","fixed152x24","fixed152x32","fixed152x40","fixed152x48","fixed152x56","fixed152x64","fixed152x72","fixed152x80","fixed152x88","fixed152x96","fixed152x104","fixed160x8","fixed160x16","fixed160x24","fixed160x32","fixed160x40","fixed160x48","fixed160x56","fixed160x64","fixed160x72","fixed160x80","fixed160x88","fixed160x96","fixed168x8","fixed168x16","fixed168x24","fixed168x32","fixed168x40","fixed168x48","fixed168x56","fixed168x64","fixed168x72","fixed168x80","fixed168x88","fixed176x8","fixed176x16","fixed176x24","fixed176x32","fixed176x40","fixed176x48","fixed176x56","fixed176x64","fixed176x72","fixed176x80","fixed184x8","fixed184x16","fixed184x24","fixed184x32","fixed184x40","fixed184x48","fixed184x56","fixed184x64","fixed184x72","fixed192x8","fixed192x16","fixed192x24","fixed192x32","fixed192x40","fixed192x48","fixed192x56","fixed192x64","fixed200x8","fixed200x16","fixed200x24","fixed200x32","fixed200x40","fixed200x48","fixed200x56","fixed208x8","fixed208x16","fixed208x24","fixed208x32","fixed208x40","fixed208x48","fixed216x8","fixed216x16","fixed216x24","fixed216x32","fixed216x40","fixed224x8","fixed224x16","fixed224x24","fixed224x32","fixed232x8","fixed232x16","fixed232x24","fixed240x8","fixed240x16","fixed248x8","ufixed","ufixed0x8","ufixed0x16","ufixed0x24","ufixed0x32","ufixed0x40","ufixed0x48","ufixed0x56","ufixed0x64","ufixed0x72","ufixed0x80","ufixed0x88","ufixed0x96","ufixed0x104","ufixed0x112","ufixed0x120","ufixed0x128","ufixed0x136","ufixed0x144","ufixed0x152","ufixed0x160","ufixed0x168","ufixed0x176","ufixed0x184","ufixed0x192","ufixed0x200","ufixed0x208","ufixed0x216","ufixed0x224","ufixed0x232","ufixed0x240","ufixed0x248","ufixed0x256","ufixed8x8","ufixed8x16","ufixed8x24","ufixed8x32","ufixed8x40","ufixed8x48","ufixed8x56","ufixed8x64","ufixed8x72","ufixed8x80","ufixed8x88","ufixed8x96","ufixed8x104","ufixed8x112","ufixed8x120","ufixed8x128","ufixed8x136","ufixed8x144","ufixed8x152","ufixed8x160","ufixed8x168","ufixed8x176","ufixed8x184","ufixed8x192","ufixed8x200","ufixed8x208","ufixed8x216","ufixed8x224","ufixed8x232","ufixed8x240","ufixed8x248","ufixed16x8","ufixed16x16","ufixed16x24","ufixed16x32","ufixed16x40","ufixed16x48","ufixed16x56","ufixed16x64","ufixed16x72","ufixed16x80","ufixed16x88","ufixed16x96","ufixed16x104","ufixed16x112","ufixed16x120","ufixed16x128","ufixed16x136","ufixed16x144","ufixed16x152","ufixed16x160","ufixed16x168","ufixed16x176","ufixed16x184","ufixed16x192","ufixed16x200","ufixed16x208","ufixed16x216","ufixed16x224","ufixed16x232","ufixed16x240","ufixed24x8","ufixed24x16","ufixed24x24","ufixed24x32","ufixed24x40","ufixed24x48","ufixed24x56","ufixed24x64","ufixed24x72","ufixed24x80","ufixed24x88","ufixed24x96","ufixed24x104","ufixed24x112","ufixed24x120","ufixed24x128","ufixed24x136","ufixed24x144","ufixed24x152","ufixed24x160","ufixed24x168","ufixed24x176","ufixed24x184","ufixed24x192","ufixed24x200","ufixed24x208","ufixed24x216","ufixed24x224","ufixed24x232","ufixed32x8","ufixed32x16","ufixed32x24","ufixed32x32","ufixed32x40","ufixed32x48","ufixed32x56","ufixed32x64","ufixed32x72","ufixed32x80","ufixed32x88","ufixed32x96","ufixed32x104","ufixed32x112","ufixed32x120","ufixed32x128","ufixed32x136","ufixed32x144","ufixed32x152","ufixed32x160","ufixed32x168","ufixed32x176","ufixed32x184","ufixed32x192","ufixed32x200","ufixed32x208","ufixed32x216","ufixed32x224","ufixed40x8","ufixed40x16","ufixed40x24","ufixed40x32","ufixed40x40","ufixed40x48","ufixed40x56","ufixed40x64","ufixed40x72","ufixed40x80","ufixed40x88","ufixed40x96","ufixed40x104","ufixed40x112","ufixed40x120","ufixed40x128","ufixed40x136","ufixed40x144","ufixed40x152","ufixed40x160","ufixed40x168","ufixed40x176","ufixed40x184","ufixed40x192","ufixed40x200","ufixed40x208","ufixed40x216","ufixed48x8","ufixed48x16","ufixed48x24","ufixed48x32","ufixed48x40","ufixed48x48","ufixed48x56","ufixed48x64","ufixed48x72","ufixed48x80","ufixed48x88","ufixed48x96","ufixed48x104","ufixed48x112","ufixed48x120","ufixed48x128","ufixed48x136","ufixed48x144","ufixed48x152","ufixed48x160","ufixed48x168","ufixed48x176","ufixed48x184","ufixed48x192","ufixed48x200","ufixed48x208","ufixed56x8","ufixed56x16","ufixed56x24","ufixed56x32","ufixed56x40","ufixed56x48","ufixed56x56","ufixed56x64","ufixed56x72","ufixed56x80","ufixed56x88","ufixed56x96","ufixed56x104","ufixed56x112","ufixed56x120","ufixed56x128","ufixed56x136","ufixed56x144","ufixed56x152","ufixed56x160","ufixed56x168","ufixed56x176","ufixed56x184","ufixed56x192","ufixed56x200","ufixed64x8","ufixed64x16","ufixed64x24","ufixed64x32","ufixed64x40","ufixed64x48","ufixed64x56","ufixed64x64","ufixed64x72","ufixed64x80","ufixed64x88","ufixed64x96","ufixed64x104","ufixed64x112","ufixed64x120","ufixed64x128","ufixed64x136","ufixed64x144","ufixed64x152","ufixed64x160","ufixed64x168","ufixed64x176","ufixed64x184","ufixed64x192","ufixed72x8","ufixed72x16","ufixed72x24","ufixed72x32","ufixed72x40","ufixed72x48","ufixed72x56","ufixed72x64","ufixed72x72","ufixed72x80","ufixed72x88","ufixed72x96","ufixed72x104","ufixed72x112","ufixed72x120","ufixed72x128","ufixed72x136","ufixed72x144","ufixed72x152","ufixed72x160","ufixed72x168","ufixed72x176","ufixed72x184","ufixed80x8","ufixed80x16","ufixed80x24","ufixed80x32","ufixed80x40","ufixed80x48","ufixed80x56","ufixed80x64","ufixed80x72","ufixed80x80","ufixed80x88","ufixed80x96","ufixed80x104","ufixed80x112","ufixed80x120","ufixed80x128","ufixed80x136","ufixed80x144","ufixed80x152","ufixed80x160","ufixed80x168","ufixed80x176","ufixed88x8","ufixed88x16","ufixed88x24","ufixed88x32","ufixed88x40","ufixed88x48","ufixed88x56","ufixed88x64","ufixed88x72","ufixed88x80","ufixed88x88","ufixed88x96","ufixed88x104","ufixed88x112","ufixed88x120","ufixed88x128","ufixed88x136","ufixed88x144","ufixed88x152","ufixed88x160","ufixed88x168","ufixed96x8","ufixed96x16","ufixed96x24","ufixed96x32","ufixed96x40","ufixed96x48","ufixed96x56","ufixed96x64","ufixed96x72","ufixed96x80","ufixed96x88","ufixed96x96","ufixed96x104","ufixed96x112","ufixed96x120","ufixed96x128","ufixed96x136","ufixed96x144","ufixed96x152","ufixed96x160","ufixed104x8","ufixed104x16","ufixed104x24","ufixed104x32","ufixed104x40","ufixed104x48","ufixed104x56","ufixed104x64","ufixed104x72","ufixed104x80","ufixed104x88","ufixed104x96","ufixed104x104","ufixed104x112","ufixed104x120","ufixed104x128","ufixed104x136","ufixed104x144","ufixed104x152","ufixed112x8","ufixed112x16","ufixed112x24","ufixed112x32","ufixed112x40","ufixed112x48","ufixed112x56","ufixed112x64","ufixed112x72","ufixed112x80","ufixed112x88","ufixed112x96","ufixed112x104","ufixed112x112","ufixed112x120","ufixed112x128","ufixed112x136","ufixed112x144","ufixed120x8","ufixed120x16","ufixed120x24","ufixed120x32","ufixed120x40","ufixed120x48","ufixed120x56","ufixed120x64","ufixed120x72","ufixed120x80","ufixed120x88","ufixed120x96","ufixed120x104","ufixed120x112","ufixed120x120","ufixed120x128","ufixed120x136","ufixed128x8","ufixed128x16","ufixed128x24","ufixed128x32","ufixed128x40","ufixed128x48","ufixed128x56","ufixed128x64","ufixed128x72","ufixed128x80","ufixed128x88","ufixed128x96","ufixed128x104","ufixed128x112","ufixed128x120","ufixed128x128","ufixed136x8","ufixed136x16","ufixed136x24","ufixed136x32","ufixed136x40","ufixed136x48","ufixed136x56","ufixed136x64","ufixed136x72","ufixed136x80","ufixed136x88","ufixed136x96","ufixed136x104","ufixed136x112","ufixed136x120","ufixed144x8","ufixed144x16","ufixed144x24","ufixed144x32","ufixed144x40","ufixed144x48","ufixed144x56","ufixed144x64","ufixed144x72","ufixed144x80","ufixed144x88","ufixed144x96","ufixed144x104","ufixed144x112","ufixed152x8","ufixed152x16","ufixed152x24","ufixed152x32","ufixed152x40","ufixed152x48","ufixed152x56","ufixed152x64","ufixed152x72","ufixed152x80","ufixed152x88","ufixed152x96","ufixed152x104","ufixed160x8","ufixed160x16","ufixed160x24","ufixed160x32","ufixed160x40","ufixed160x48","ufixed160x56","ufixed160x64","ufixed160x72","ufixed160x80","ufixed160x88","ufixed160x96","ufixed168x8","ufixed168x16","ufixed168x24","ufixed168x32","ufixed168x40","ufixed168x48","ufixed168x56","ufixed168x64","ufixed168x72","ufixed168x80","ufixed168x88","ufixed176x8","ufixed176x16","ufixed176x24","ufixed176x32","ufixed176x40","ufixed176x48","ufixed176x56","ufixed176x64","ufixed176x72","ufixed176x80","ufixed184x8","ufixed184x16","ufixed184x24","ufixed184x32","ufixed184x40","ufixed184x48","ufixed184x56","ufixed184x64","ufixed184x72","ufixed192x8","ufixed192x16","ufixed192x24","ufixed192x32","ufixed192x40","ufixed192x48","ufixed192x56","ufixed192x64","ufixed200x8","ufixed200x16","ufixed200x24","ufixed200x32","ufixed200x40","ufixed200x48","ufixed200x56","ufixed208x8","ufixed208x16","ufixed208x24","ufixed208x32","ufixed208x40","ufixed208x48","ufixed216x8","ufixed216x16","ufixed216x24","ufixed216x32","ufixed216x40","ufixed224x8","ufixed224x16","ufixed224x24","ufixed224x32","ufixed232x8","ufixed232x16","ufixed232x24","ufixed240x8","ufixed240x16","ufixed248x8","event","enum","let","mapping","private","public","external","inherited","payable","true","false","var","import","constant","if","else","for","else","for","while","do","break","continue","throw","returns","return","suicide","new","is","this","super"],operators:["=",">","<","!","~","?",":","==","<=",">=","!=","&&","||","++","--","+","-","*","/","&","|","^","%","<<",">>",">>>","+=","-=","*=","/=","&=","|=","^=","%=","<<=",">>=",">>>="],symbols:/[=>](?!@symbols)/,"@brackets"],[/@symbols/,{cases:{"@operators":"delimiter","@default":""}}],[/\d*\d+[eE]([\-+]?\d+)?(@floatsuffix)/,"number.float"],[/\d*\.\d+([eE][\-+]?\d+)?(@floatsuffix)/,"number.float"],[/0[xX][0-9a-fA-F']*[0-9a-fA-F](@integersuffix)/,"number.hex"],[/0[0-7']*[0-7](@integersuffix)/,"number.octal"],[/0[bB][0-1']*[0-1](@integersuffix)/,"number.binary"],[/\d[\d']*\d(@integersuffix)/,"number"],[/\d(@integersuffix)/,"number"],[/[;,.]/,"delimiter"],[/"([^"\\]|\\.)*$/,"string.invalid"],[/"/,"string","@string"],[/'[^\\']'/,"string"],[/(')(@escapes)(')/,["string","string.escape","string"]],[/'/,"string.invalid"]],whitespace:[[/[ \t\r\n]+/,""],[/\/\*\*(?!\/)/,"comment.doc","@doccomment"],[/\/\*/,"comment","@comment"],[/\/\/.*$/,"comment"]],comment:[[/[^\/*]+/,"comment"],[/\*\//,"comment","@pop"],[/[\/*]/,"comment"]],doccomment:[[/[^\/*]+/,"comment.doc"],[/\*\//,"comment.doc","@pop"],[/[\/*]/,"comment.doc"]],string:[[/[^\\"]+/,"string"],[/@escapes/,"string.escape"],[/\\./,"string.escape.invalid"],[/"/,"string","@pop"]]}}},22900:function(e,t,i){"use strict";i.r(t),(0,i(70266).H)({id:"aes",extensions:[".aes"],aliases:["aes","sophia","Sophia"],loader:()=>Promise.resolve().then(i.bind(i,23412))})},23412:function(e,t,i){"use strict";i.r(t),i.d(t,{conf:function(){return n},language:function(){return o}});var n={comments:{lineComment:"//",blockComment:["/*","*/"]},brackets:[["{","}"],["[","]"],["(",")"],["<",">"]],autoClosingPairs:[{open:'"',close:'"',notIn:["string","comment"]},{open:"{",close:"}",notIn:["string","comment"]},{open:"[",close:"]",notIn:["string","comment"]},{open:"(",close:")",notIn:["string","comment"]}]},o={defaultToken:"",tokenPostfix:".aes",brackets:[{token:"delimiter.curly",open:"{",close:"}"},{token:"delimiter.parenthesis",open:"(",close:")"},{token:"delimiter.square",open:"[",close:"]"},{token:"delimiter.angle",open:"<",close:">"}],keywords:["contract","library","entrypoint","function","stateful","state","hash","signature","tuple","list","address","string","bool","int","record","datatype","type","option","oracle","oracle_query","Call","Bits","Bytes","Oracle","String","Crypto","Address","Auth","Chain","None","Some","bits","bytes","event","let","map","private","public","true","false","var","if","else","throw"],operators:["=",">","<","!","~","?","::",":","==","<=",">=","!=","&&","||","++","--","+","-","*","/","&","|","^","%","<<",">>",">>>","+=","-=","*=","/=","&=","|=","^=","%=","<<=",">>=",">>>="],symbols:/[=>](?!@symbols)/,"@brackets"],[/@symbols/,{cases:{"@operators":"delimiter","@default":""}}],[/\d*\d+[eE]([\-+]?\d+)?(@floatsuffix)/,"number.float"],[/\d*\.\d+([eE][\-+]?\d+)?(@floatsuffix)/,"number.float"],[/0[xX][0-9a-fA-F']*[0-9a-fA-F](@integersuffix)/,"number.hex"],[/0[0-7']*[0-7](@integersuffix)/,"number.octal"],[/0[bB][0-1']*[0-1](@integersuffix)/,"number.binary"],[/\d[\d']*\d(@integersuffix)/,"number"],[/\d(@integersuffix)/,"number"],[/[;,.]/,"delimiter"],[/"([^"\\]|\\.)*$/,"string.invalid"],[/"/,"string","@string"],[/'[^\\']'/,"string"],[/(')(@escapes)(')/,["string","string.escape","string"]],[/'/,"string.invalid"]],whitespace:[[/[ \t\r\n]+/,""],[/\/\*\*(?!\/)/,"comment.doc","@doccomment"],[/\/\*/,"comment","@comment"],[/\/\/.*$/,"comment"]],comment:[[/[^\/*]+/,"comment"],[/\*\//,"comment","@pop"],[/[\/*]/,"comment"]],doccomment:[[/[^\/*]+/,"comment.doc"],[/\*\//,"comment.doc","@pop"],[/[\/*]/,"comment.doc"]],string:[[/[^\\"]+/,"string"],[/@escapes/,"string.escape"],[/\\./,"string.escape.invalid"],[/"/,"string","@pop"]]}}},6714:function(e,t,i){"use strict";i.r(t),(0,i(70266).H)({id:"sparql",extensions:[".rq"],aliases:["sparql","SPARQL"],loader:()=>Promise.resolve().then(i.bind(i,40632))})},40632:function(e,t,i){"use strict";i.r(t),i.d(t,{conf:function(){return n},language:function(){return o}});var n={comments:{lineComment:"#"},brackets:[["{","}"],["[","]"],["(",")"]],autoClosingPairs:[{open:"'",close:"'",notIn:["string"]},{open:'"',close:'"',notIn:["string"]},{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"}]},o={defaultToken:"",tokenPostfix:".rq",brackets:[{token:"delimiter.curly",open:"{",close:"}"},{token:"delimiter.parenthesis",open:"(",close:")"},{token:"delimiter.square",open:"[",close:"]"},{token:"delimiter.angle",open:"<",close:">"}],keywords:["add","as","asc","ask","base","by","clear","construct","copy","create","data","delete","desc","describe","distinct","drop","false","filter","from","graph","group","having","in","insert","limit","load","minus","move","named","not","offset","optional","order","prefix","reduced","select","service","silent","to","true","undef","union","using","values","where","with"],builtinFunctions:["a","abs","avg","bind","bnode","bound","ceil","coalesce","concat","contains","count","datatype","day","encode_for_uri","exists","floor","group_concat","hours","if","iri","isblank","isiri","isliteral","isnumeric","isuri","lang","langmatches","lcase","max","md5","min","minutes","month","now","rand","regex","replace","round","sameterm","sample","seconds","sha1","sha256","sha384","sha512","str","strafter","strbefore","strdt","strends","strlang","strlen","strstarts","struuid","substr","sum","timezone","tz","ucase","uri","uuid","year"],ignoreCase:!0,tokenizer:{root:[[/<[^\s\u00a0>]*>?/,"tag"],{include:"@strings"},[/#.*/,"comment"],[/[{}()\[\]]/,"@brackets"],[/[;,.]/,"delimiter"],[/[_\w\d]+:(\.(?=[\w_\-\\%])|[:\w_-]|\\[-\\_~.!$&'()*+,;=/?#@%]|%[a-f\d][a-f\d])*/,"tag"],[/:(\.(?=[\w_\-\\%])|[:\w_-]|\\[-\\_~.!$&'()*+,;=/?#@%]|%[a-f\d][a-f\d])+/,"tag"],[/[$?]?[_\w\d]+/,{cases:{"@keywords":{token:"keyword"},"@builtinFunctions":{token:"predefined.sql"},"@default":"identifier"}}],[/\^\^/,"operator.sql"],[/\^[*+\-<>=&|^\/!?]*/,"operator.sql"],[/[*+\-<>=&|\/!?]/,"operator.sql"],[/@[a-z\d\-]*/,"metatag.html"],[/\s+/,"white"]],strings:[[/'([^'\\]|\\.)*$/,"string.invalid"],[/'$/,"string.sql","@pop"],[/'/,"string.sql","@stringBody"],[/"([^"\\]|\\.)*$/,"string.invalid"],[/"$/,"string.sql","@pop"],[/"/,"string.sql","@dblStringBody"]],stringBody:[[/[^\\']+/,"string.sql"],[/\\./,"string.escape"],[/'/,"string.sql","@pop"]],dblStringBody:[[/[^\\"]+/,"string.sql"],[/\\./,"string.escape"],[/"/,"string.sql","@pop"]]}}},59305:function(e,t,i){"use strict";i.r(t),(0,i(70266).H)({id:"sql",extensions:[".sql"],aliases:["SQL"],loader:()=>Promise.resolve().then(i.bind(i,17013))})},17013:function(e,t,i){"use strict";i.r(t),i.d(t,{conf:function(){return n},language:function(){return o}});var n={comments:{lineComment:"--",blockComment:["/*","*/"]},brackets:[["{","}"],["[","]"],["(",")"]],autoClosingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:'"',close:'"'},{open:"'",close:"'"}],surroundingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:'"',close:'"'},{open:"'",close:"'"}]},o={defaultToken:"",tokenPostfix:".sql",ignoreCase:!0,brackets:[{open:"[",close:"]",token:"delimiter.square"},{open:"(",close:")",token:"delimiter.parenthesis"}],keywords:["ABORT","ABSOLUTE","ACTION","ADA","ADD","AFTER","ALL","ALLOCATE","ALTER","ALWAYS","ANALYZE","AND","ANY","ARE","AS","ASC","ASSERTION","AT","ATTACH","AUTHORIZATION","AUTOINCREMENT","AVG","BACKUP","BEFORE","BEGIN","BETWEEN","BIT","BIT_LENGTH","BOTH","BREAK","BROWSE","BULK","BY","CASCADE","CASCADED","CASE","CAST","CATALOG","CHAR","CHARACTER","CHARACTER_LENGTH","CHAR_LENGTH","CHECK","CHECKPOINT","CLOSE","CLUSTERED","COALESCE","COLLATE","COLLATION","COLUMN","COMMIT","COMPUTE","CONFLICT","CONNECT","CONNECTION","CONSTRAINT","CONSTRAINTS","CONTAINS","CONTAINSTABLE","CONTINUE","CONVERT","CORRESPONDING","COUNT","CREATE","CROSS","CURRENT","CURRENT_DATE","CURRENT_TIME","CURRENT_TIMESTAMP","CURRENT_USER","CURSOR","DATABASE","DATE","DAY","DBCC","DEALLOCATE","DEC","DECIMAL","DECLARE","DEFAULT","DEFERRABLE","DEFERRED","DELETE","DENY","DESC","DESCRIBE","DESCRIPTOR","DETACH","DIAGNOSTICS","DISCONNECT","DISK","DISTINCT","DISTRIBUTED","DO","DOMAIN","DOUBLE","DROP","DUMP","EACH","ELSE","END","END-EXEC","ERRLVL","ESCAPE","EXCEPT","EXCEPTION","EXCLUDE","EXCLUSIVE","EXEC","EXECUTE","EXISTS","EXIT","EXPLAIN","EXTERNAL","EXTRACT","FAIL","FALSE","FETCH","FILE","FILLFACTOR","FILTER","FIRST","FLOAT","FOLLOWING","FOR","FOREIGN","FORTRAN","FOUND","FREETEXT","FREETEXTTABLE","FROM","FULL","FUNCTION","GENERATED","GET","GLOB","GLOBAL","GO","GOTO","GRANT","GROUP","GROUPS","HAVING","HOLDLOCK","HOUR","IDENTITY","IDENTITYCOL","IDENTITY_INSERT","IF","IGNORE","IMMEDIATE","IN","INCLUDE","INDEX","INDEXED","INDICATOR","INITIALLY","INNER","INPUT","INSENSITIVE","INSERT","INSTEAD","INT","INTEGER","INTERSECT","INTERVAL","INTO","IS","ISNULL","ISOLATION","JOIN","KEY","KILL","LANGUAGE","LAST","LEADING","LEFT","LEVEL","LIKE","LIMIT","LINENO","LOAD","LOCAL","LOWER","MATCH","MATERIALIZED","MAX","MERGE","MIN","MINUTE","MODULE","MONTH","NAMES","NATIONAL","NATURAL","NCHAR","NEXT","NO","NOCHECK","NONCLUSTERED","NONE","NOT","NOTHING","NOTNULL","NULL","NULLIF","NULLS","NUMERIC","OCTET_LENGTH","OF","OFF","OFFSET","OFFSETS","ON","ONLY","OPEN","OPENDATASOURCE","OPENQUERY","OPENROWSET","OPENXML","OPTION","OR","ORDER","OTHERS","OUTER","OUTPUT","OVER","OVERLAPS","PAD","PARTIAL","PARTITION","PASCAL","PERCENT","PIVOT","PLAN","POSITION","PRAGMA","PRECEDING","PRECISION","PREPARE","PRESERVE","PRIMARY","PRINT","PRIOR","PRIVILEGES","PROC","PROCEDURE","PUBLIC","QUERY","RAISE","RAISERROR","RANGE","READ","READTEXT","REAL","RECONFIGURE","RECURSIVE","REFERENCES","REGEXP","REINDEX","RELATIVE","RELEASE","RENAME","REPLACE","REPLICATION","RESTORE","RESTRICT","RETURN","RETURNING","REVERT","REVOKE","RIGHT","ROLLBACK","ROW","ROWCOUNT","ROWGUIDCOL","ROWS","RULE","SAVE","SAVEPOINT","SCHEMA","SCROLL","SECOND","SECTION","SECURITYAUDIT","SELECT","SEMANTICKEYPHRASETABLE","SEMANTICSIMILARITYDETAILSTABLE","SEMANTICSIMILARITYTABLE","SESSION","SESSION_USER","SET","SETUSER","SHUTDOWN","SIZE","SMALLINT","SOME","SPACE","SQL","SQLCA","SQLCODE","SQLERROR","SQLSTATE","SQLWARNING","STATISTICS","SUBSTRING","SUM","SYSTEM_USER","TABLE","TABLESAMPLE","TEMP","TEMPORARY","TEXTSIZE","THEN","TIES","TIME","TIMESTAMP","TIMEZONE_HOUR","TIMEZONE_MINUTE","TO","TOP","TRAILING","TRAN","TRANSACTION","TRANSLATE","TRANSLATION","TRIGGER","TRIM","TRUE","TRUNCATE","TRY_CONVERT","TSEQUAL","UNBOUNDED","UNION","UNIQUE","UNKNOWN","UNPIVOT","UPDATE","UPDATETEXT","UPPER","USAGE","USE","USER","USING","VACUUM","VALUE","VALUES","VARCHAR","VARYING","VIEW","VIRTUAL","WAITFOR","WHEN","WHENEVER","WHERE","WHILE","WINDOW","WITH","WITHIN GROUP","WITHOUT","WORK","WRITE","WRITETEXT","YEAR","ZONE"],operators:["ALL","AND","ANY","BETWEEN","EXISTS","IN","LIKE","NOT","OR","SOME","EXCEPT","INTERSECT","UNION","APPLY","CROSS","FULL","INNER","JOIN","LEFT","OUTER","RIGHT","CONTAINS","FREETEXT","IS","NULL","PIVOT","UNPIVOT","MATCHED"],builtinFunctions:["AVG","CHECKSUM_AGG","COUNT","COUNT_BIG","GROUPING","GROUPING_ID","MAX","MIN","SUM","STDEV","STDEVP","VAR","VARP","CUME_DIST","FIRST_VALUE","LAG","LAST_VALUE","LEAD","PERCENTILE_CONT","PERCENTILE_DISC","PERCENT_RANK","COLLATE","COLLATIONPROPERTY","TERTIARY_WEIGHTS","FEDERATION_FILTERING_VALUE","CAST","CONVERT","PARSE","TRY_CAST","TRY_CONVERT","TRY_PARSE","ASYMKEY_ID","ASYMKEYPROPERTY","CERTPROPERTY","CERT_ID","CRYPT_GEN_RANDOM","DECRYPTBYASYMKEY","DECRYPTBYCERT","DECRYPTBYKEY","DECRYPTBYKEYAUTOASYMKEY","DECRYPTBYKEYAUTOCERT","DECRYPTBYPASSPHRASE","ENCRYPTBYASYMKEY","ENCRYPTBYCERT","ENCRYPTBYKEY","ENCRYPTBYPASSPHRASE","HASHBYTES","IS_OBJECTSIGNED","KEY_GUID","KEY_ID","KEY_NAME","SIGNBYASYMKEY","SIGNBYCERT","SYMKEYPROPERTY","VERIFYSIGNEDBYCERT","VERIFYSIGNEDBYASYMKEY","CURSOR_STATUS","DATALENGTH","IDENT_CURRENT","IDENT_INCR","IDENT_SEED","IDENTITY","SQL_VARIANT_PROPERTY","CURRENT_TIMESTAMP","DATEADD","DATEDIFF","DATEFROMPARTS","DATENAME","DATEPART","DATETIME2FROMPARTS","DATETIMEFROMPARTS","DATETIMEOFFSETFROMPARTS","DAY","EOMONTH","GETDATE","GETUTCDATE","ISDATE","MONTH","SMALLDATETIMEFROMPARTS","SWITCHOFFSET","SYSDATETIME","SYSDATETIMEOFFSET","SYSUTCDATETIME","TIMEFROMPARTS","TODATETIMEOFFSET","YEAR","CHOOSE","COALESCE","IIF","NULLIF","ABS","ACOS","ASIN","ATAN","ATN2","CEILING","COS","COT","DEGREES","EXP","FLOOR","LOG","LOG10","PI","POWER","RADIANS","RAND","ROUND","SIGN","SIN","SQRT","SQUARE","TAN","APP_NAME","APPLOCK_MODE","APPLOCK_TEST","ASSEMBLYPROPERTY","COL_LENGTH","COL_NAME","COLUMNPROPERTY","DATABASE_PRINCIPAL_ID","DATABASEPROPERTYEX","DB_ID","DB_NAME","FILE_ID","FILE_IDEX","FILE_NAME","FILEGROUP_ID","FILEGROUP_NAME","FILEGROUPPROPERTY","FILEPROPERTY","FULLTEXTCATALOGPROPERTY","FULLTEXTSERVICEPROPERTY","INDEX_COL","INDEXKEY_PROPERTY","INDEXPROPERTY","OBJECT_DEFINITION","OBJECT_ID","OBJECT_NAME","OBJECT_SCHEMA_NAME","OBJECTPROPERTY","OBJECTPROPERTYEX","ORIGINAL_DB_NAME","PARSENAME","SCHEMA_ID","SCHEMA_NAME","SCOPE_IDENTITY","SERVERPROPERTY","STATS_DATE","TYPE_ID","TYPE_NAME","TYPEPROPERTY","DENSE_RANK","NTILE","RANK","ROW_NUMBER","PUBLISHINGSERVERNAME","OPENDATASOURCE","OPENQUERY","OPENROWSET","OPENXML","CERTENCODED","CERTPRIVATEKEY","CURRENT_USER","HAS_DBACCESS","HAS_PERMS_BY_NAME","IS_MEMBER","IS_ROLEMEMBER","IS_SRVROLEMEMBER","LOGINPROPERTY","ORIGINAL_LOGIN","PERMISSIONS","PWDENCRYPT","PWDCOMPARE","SESSION_USER","SESSIONPROPERTY","SUSER_ID","SUSER_NAME","SUSER_SID","SUSER_SNAME","SYSTEM_USER","USER","USER_ID","USER_NAME","ASCII","CHAR","CHARINDEX","CONCAT","DIFFERENCE","FORMAT","LEFT","LEN","LOWER","LTRIM","NCHAR","PATINDEX","QUOTENAME","REPLACE","REPLICATE","REVERSE","RIGHT","RTRIM","SOUNDEX","SPACE","STR","STUFF","SUBSTRING","UNICODE","UPPER","BINARY_CHECKSUM","CHECKSUM","CONNECTIONPROPERTY","CONTEXT_INFO","CURRENT_REQUEST_ID","ERROR_LINE","ERROR_NUMBER","ERROR_MESSAGE","ERROR_PROCEDURE","ERROR_SEVERITY","ERROR_STATE","FORMATMESSAGE","GETANSINULL","GET_FILESTREAM_TRANSACTION_CONTEXT","HOST_ID","HOST_NAME","ISNULL","ISNUMERIC","MIN_ACTIVE_ROWVERSION","NEWID","NEWSEQUENTIALID","ROWCOUNT_BIG","XACT_STATE","TEXTPTR","TEXTVALID","COLUMNS_UPDATED","EVENTDATA","TRIGGER_NESTLEVEL","UPDATE","CHANGETABLE","CHANGE_TRACKING_CONTEXT","CHANGE_TRACKING_CURRENT_VERSION","CHANGE_TRACKING_IS_COLUMN_IN_MASK","CHANGE_TRACKING_MIN_VALID_VERSION","CONTAINSTABLE","FREETEXTTABLE","SEMANTICKEYPHRASETABLE","SEMANTICSIMILARITYDETAILSTABLE","SEMANTICSIMILARITYTABLE","FILETABLEROOTPATH","GETFILENAMESPACEPATH","GETPATHLOCATOR","PATHNAME","GET_TRANSMISSION_STATUS"],builtinVariables:["@@DATEFIRST","@@DBTS","@@LANGID","@@LANGUAGE","@@LOCK_TIMEOUT","@@MAX_CONNECTIONS","@@MAX_PRECISION","@@NESTLEVEL","@@OPTIONS","@@REMSERVER","@@SERVERNAME","@@SERVICENAME","@@SPID","@@TEXTSIZE","@@VERSION","@@CURSOR_ROWS","@@FETCH_STATUS","@@DATEFIRST","@@PROCID","@@ERROR","@@IDENTITY","@@ROWCOUNT","@@TRANCOUNT","@@CONNECTIONS","@@CPU_BUSY","@@IDLE","@@IO_BUSY","@@PACKET_ERRORS","@@PACK_RECEIVED","@@PACK_SENT","@@TIMETICKS","@@TOTAL_ERRORS","@@TOTAL_READ","@@TOTAL_WRITE"],pseudoColumns:["$ACTION","$IDENTITY","$ROWGUID","$PARTITION"],tokenizer:{root:[{include:"@comments"},{include:"@whitespace"},{include:"@pseudoColumns"},{include:"@numbers"},{include:"@strings"},{include:"@complexIdentifiers"},{include:"@scopes"},[/[;,.]/,"delimiter"],[/[()]/,"@brackets"],[/[\w@#$]+/,{cases:{"@operators":"operator","@builtinVariables":"predefined","@builtinFunctions":"predefined","@keywords":"keyword","@default":"identifier"}}],[/[<>=!%&+\-*/|~^]/,"operator"]],whitespace:[[/\s+/,"white"]],comments:[[/--+.*/,"comment"],[/\/\*/,{token:"comment.quote",next:"@comment"}]],comment:[[/[^*/]+/,"comment"],[/\*\//,{token:"comment.quote",next:"@pop"}],[/./,"comment"]],pseudoColumns:[[/[$][A-Za-z_][\w@#$]*/,{cases:{"@pseudoColumns":"predefined","@default":"identifier"}}]],numbers:[[/0[xX][0-9a-fA-F]*/,"number"],[/[$][+-]*\d*(\.\d*)?/,"number"],[/((\d+(\.\d*)?)|(\.\d+))([eE][\-+]?\d+)?/,"number"]],strings:[[/N'/,{token:"string",next:"@string"}],[/'/,{token:"string",next:"@string"}]],string:[[/[^']+/,"string"],[/''/,"string"],[/'/,{token:"string",next:"@pop"}]],complexIdentifiers:[[/\[/,{token:"identifier.quote",next:"@bracketedIdentifier"}],[/"/,{token:"identifier.quote",next:"@quotedIdentifier"}]],bracketedIdentifier:[[/[^\]]+/,"identifier"],[/]]/,"identifier"],[/]/,{token:"identifier.quote",next:"@pop"}]],quotedIdentifier:[[/[^"]+/,"identifier"],[/""/,"identifier"],[/"/,{token:"identifier.quote",next:"@pop"}]],scopes:[[/BEGIN\s+(DISTRIBUTED\s+)?TRAN(SACTION)?\b/i,"keyword"],[/BEGIN\s+TRY\b/i,{token:"keyword.try"}],[/END\s+TRY\b/i,{token:"keyword.try"}],[/BEGIN\s+CATCH\b/i,{token:"keyword.catch"}],[/END\s+CATCH\b/i,{token:"keyword.catch"}],[/(BEGIN|CASE)\b/i,{token:"keyword.block"}],[/END\b/i,{token:"keyword.block"}],[/WHEN\b/i,{token:"keyword.choice"}],[/THEN\b/i,{token:"keyword.choice"}]]}}},51345:function(e,t,i){"use strict";i.r(t),(0,i(70266).H)({id:"st",extensions:[".st",".iecst",".iecplc",".lc3lib"],aliases:["StructuredText","scl","stl"],loader:()=>Promise.resolve().then(i.bind(i,192))})},192:function(e,t,i){"use strict";i.r(t),i.d(t,{conf:function(){return n},language:function(){return o}});var n={comments:{lineComment:"//",blockComment:["(*","*)"]},brackets:[["{","}"],["[","]"],["(",")"],["var","end_var"],["var_input","end_var"],["var_output","end_var"],["var_in_out","end_var"],["var_temp","end_var"],["var_global","end_var"],["var_access","end_var"],["var_external","end_var"],["type","end_type"],["struct","end_struct"],["program","end_program"],["function","end_function"],["function_block","end_function_block"],["action","end_action"],["step","end_step"],["initial_step","end_step"],["transaction","end_transaction"],["configuration","end_configuration"],["tcp","end_tcp"],["recource","end_recource"],["channel","end_channel"],["library","end_library"],["folder","end_folder"],["binaries","end_binaries"],["includes","end_includes"],["sources","end_sources"]],autoClosingPairs:[{open:"[",close:"]"},{open:"{",close:"}"},{open:"(",close:")"},{open:"/*",close:"*/"},{open:"'",close:"'",notIn:["string_sq"]},{open:'"',close:'"',notIn:["string_dq"]},{open:"var_input",close:"end_var"},{open:"var_output",close:"end_var"},{open:"var_in_out",close:"end_var"},{open:"var_temp",close:"end_var"},{open:"var_global",close:"end_var"},{open:"var_access",close:"end_var"},{open:"var_external",close:"end_var"},{open:"type",close:"end_type"},{open:"struct",close:"end_struct"},{open:"program",close:"end_program"},{open:"function",close:"end_function"},{open:"function_block",close:"end_function_block"},{open:"action",close:"end_action"},{open:"step",close:"end_step"},{open:"initial_step",close:"end_step"},{open:"transaction",close:"end_transaction"},{open:"configuration",close:"end_configuration"},{open:"tcp",close:"end_tcp"},{open:"recource",close:"end_recource"},{open:"channel",close:"end_channel"},{open:"library",close:"end_library"},{open:"folder",close:"end_folder"},{open:"binaries",close:"end_binaries"},{open:"includes",close:"end_includes"},{open:"sources",close:"end_sources"}],surroundingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:'"',close:'"'},{open:"'",close:"'"},{open:"var",close:"end_var"},{open:"var_input",close:"end_var"},{open:"var_output",close:"end_var"},{open:"var_in_out",close:"end_var"},{open:"var_temp",close:"end_var"},{open:"var_global",close:"end_var"},{open:"var_access",close:"end_var"},{open:"var_external",close:"end_var"},{open:"type",close:"end_type"},{open:"struct",close:"end_struct"},{open:"program",close:"end_program"},{open:"function",close:"end_function"},{open:"function_block",close:"end_function_block"},{open:"action",close:"end_action"},{open:"step",close:"end_step"},{open:"initial_step",close:"end_step"},{open:"transaction",close:"end_transaction"},{open:"configuration",close:"end_configuration"},{open:"tcp",close:"end_tcp"},{open:"recource",close:"end_recource"},{open:"channel",close:"end_channel"},{open:"library",close:"end_library"},{open:"folder",close:"end_folder"},{open:"binaries",close:"end_binaries"},{open:"includes",close:"end_includes"},{open:"sources",close:"end_sources"}],folding:{markers:{start:new RegExp("^\\s*#pragma\\s+region\\b"),end:new RegExp("^\\s*#pragma\\s+endregion\\b")}}},o={defaultToken:"",tokenPostfix:".st",ignoreCase:!0,brackets:[{token:"delimiter.curly",open:"{",close:"}"},{token:"delimiter.parenthesis",open:"(",close:")"},{token:"delimiter.square",open:"[",close:"]"}],keywords:["if","end_if","elsif","else","case","of","to","__try","__catch","__finally","do","with","by","while","repeat","end_while","end_repeat","end_case","for","end_for","task","retain","non_retain","constant","with","at","exit","return","interval","priority","address","port","on_channel","then","iec","file","uses","version","packagetype","displayname","copyright","summary","vendor","common_source","from","extends"],constant:["false","true","null"],defineKeywords:["var","var_input","var_output","var_in_out","var_temp","var_global","var_access","var_external","end_var","type","end_type","struct","end_struct","program","end_program","function","end_function","function_block","end_function_block","interface","end_interface","method","end_method","property","end_property","namespace","end_namespace","configuration","end_configuration","tcp","end_tcp","resource","end_resource","channel","end_channel","library","end_library","folder","end_folder","binaries","end_binaries","includes","end_includes","sources","end_sources","action","end_action","step","initial_step","end_step","transaction","end_transaction"],typeKeywords:["int","sint","dint","lint","usint","uint","udint","ulint","real","lreal","time","date","time_of_day","date_and_time","string","bool","byte","word","dword","array","pointer","lword"],operators:["=",">","<",":",":=","<=",">=","<>","&","+","-","*","**","MOD","^","or","and","not","xor","abs","acos","asin","atan","cos","exp","expt","ln","log","sin","sqrt","tan","sel","max","min","limit","mux","shl","shr","rol","ror","indexof","sizeof","adr","adrinst","bitadr","is_valid","ref","ref_to"],builtinVariables:[],builtinFunctions:["sr","rs","tp","ton","tof","eq","ge","le","lt","ne","round","trunc","ctd","сtu","ctud","r_trig","f_trig","move","concat","delete","find","insert","left","len","replace","right","rtc"],symbols:/[=>Promise.resolve().then(i.bind(i,58834))})},58834:function(e,t,i){"use strict";i.r(t),i.d(t,{conf:function(){return n},language:function(){return o}});var n={comments:{lineComment:"//",blockComment:["/*","*/"]},brackets:[["{","}"],["[","]"],["(",")"]],autoClosingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:'"',close:'"'},{open:"'",close:"'"},{open:"`",close:"`"}],surroundingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:'"',close:'"'},{open:"'",close:"'"},{open:"`",close:"`"}]},o={defaultToken:"",tokenPostfix:".swift",identifier:/[a-zA-Z_][\w$]*/,attributes:["@GKInspectable","@IBAction","@IBDesignable","@IBInspectable","@IBOutlet","@IBSegueAction","@NSApplicationMain","@NSCopying","@NSManaged","@Sendable","@UIApplicationMain","@autoclosure","@actorIndependent","@asyncHandler","@available","@convention","@derivative","@differentiable","@discardableResult","@dynamicCallable","@dynamicMemberLookup","@escaping","@frozen","@globalActor","@inlinable","@inline","@main","@noDerivative","@nonobjc","@noreturn","@objc","@objcMembers","@preconcurrency","@propertyWrapper","@requires_stored_property_inits","@resultBuilder","@testable","@unchecked","@unknown","@usableFromInline","@warn_unqualified_access"],accessmodifiers:["open","public","internal","fileprivate","private"],keywords:["#available","#colorLiteral","#column","#dsohandle","#else","#elseif","#endif","#error","#file","#fileID","#fileLiteral","#filePath","#function","#if","#imageLiteral","#keyPath","#line","#selector","#sourceLocation","#warning","Any","Protocol","Self","Type","actor","as","assignment","associatedtype","associativity","async","await","break","case","catch","class","continue","convenience","default","defer","deinit","didSet","do","dynamic","dynamicType","else","enum","extension","fallthrough","false","fileprivate","final","for","func","get","guard","higherThan","if","import","in","indirect","infix","init","inout","internal","is","isolated","lazy","left","let","lowerThan","mutating","nil","none","nonisolated","nonmutating","open","operator","optional","override","postfix","precedence","precedencegroup","prefix","private","protocol","public","repeat","required","rethrows","return","right","safe","self","set","some","static","struct","subscript","super","switch","throw","throws","true","try","typealias","unowned","unsafe","var","weak","where","while","willSet","__consuming","__owned"],symbols:/[=(){}\[\].,:;@#\_&\-<>`?!+*\\\/]/,operatorstart:/[\/=\-+!*%<>&|^~?\u00A1-\u00A7\u00A9\u00AB\u00AC\u00AE\u00B0-\u00B1\u00B6\u00BB\u00BF\u00D7\u00F7\u2016-\u2017\u2020-\u2027\u2030-\u203E\u2041-\u2053\u2055-\u205E\u2190-\u23FF\u2500-\u2775\u2794-\u2BFF\u2E00-\u2E7F\u3001-\u3003\u3008-\u3030]/,operatorend:/[\u0300-\u036F\u1DC0-\u1DFF\u20D0-\u20FF\uFE00-\uFE0F\uFE20-\uFE2F\uE0100-\uE01EF]/,operators:/(@operatorstart)((@operatorstart)|(@operatorend))*/,escapes:/\\(?:[abfnrtv\\"']|x[0-9A-Fa-f]{1,4}|u[0-9A-Fa-f]{4}|U[0-9A-Fa-f]{8})/,tokenizer:{root:[{include:"@whitespace"},{include:"@comment"},{include:"@attribute"},{include:"@literal"},{include:"@keyword"},{include:"@invokedmethod"},{include:"@symbol"}],whitespace:[[/\s+/,"white"],[/"""/,"string.quote","@endDblDocString"]],endDblDocString:[[/[^"]+/,"string"],[/\\"/,"string"],[/"""/,"string.quote","@popall"],[/"/,"string"]],symbol:[[/[{}()\[\]]/,"@brackets"],[/[<>](?!@symbols)/,"@brackets"],[/[.]/,"delimiter"],[/@operators/,"operator"],[/@symbols/,"operator"]],comment:[[/\/\/\/.*$/,"comment.doc"],[/\/\*\*/,"comment.doc","@commentdocbody"],[/\/\/.*$/,"comment"],[/\/\*/,"comment","@commentbody"]],commentdocbody:[[/\/\*/,"comment","@commentbody"],[/\*\//,"comment.doc","@pop"],[/\:[a-zA-Z]+\:/,"comment.doc.param"],[/./,"comment.doc"]],commentbody:[[/\/\*/,"comment","@commentbody"],[/\*\//,"comment","@pop"],[/./,"comment"]],attribute:[[/@@@identifier/,{cases:{"@attributes":"keyword.control","@default":""}}]],literal:[[/"/,{token:"string.quote",next:"@stringlit"}],[/0[b]([01]_?)+/,"number.binary"],[/0[o]([0-7]_?)+/,"number.octal"],[/0[x]([0-9a-fA-F]_?)+([pP][\-+](\d_?)+)?/,"number.hex"],[/(\d_?)*\.(\d_?)+([eE][\-+]?(\d_?)+)?/,"number.float"],[/(\d_?)+/,"number"]],stringlit:[[/\\\(/,{token:"operator",next:"@interpolatedexpression"}],[/@escapes/,"string"],[/\\./,"string.escape.invalid"],[/"/,{token:"string.quote",next:"@pop"}],[/./,"string"]],interpolatedexpression:[[/\(/,{token:"operator",next:"@interpolatedexpression"}],[/\)/,{token:"operator",next:"@pop"}],{include:"@literal"},{include:"@keyword"},{include:"@symbol"}],keyword:[[/`/,{token:"operator",next:"@escapedkeyword"}],[/@identifier/,{cases:{"@keywords":"keyword","[A-Z][a-zA-Z0-9$]*":"type.identifier","@default":"identifier"}}]],escapedkeyword:[[/`/,{token:"operator",next:"@pop"}],[/./,"identifier"]],invokedmethod:[[/([.])(@identifier)/,{cases:{$2:["delimeter","type.identifier"],"@default":""}}]]}}},86:function(e,t,i){"use strict";i.r(t);var n=i(70266);(0,n.H)({id:"systemverilog",extensions:[".sv",".svh"],aliases:["SV","sv","SystemVerilog","systemverilog"],loader:()=>Promise.resolve().then(i.bind(i,21112))}),(0,n.H)({id:"verilog",extensions:[".v",".vh"],aliases:["V","v","Verilog","verilog"],loader:()=>Promise.resolve().then(i.bind(i,21112))})},21112:function(e,t,i){"use strict";i.r(t),i.d(t,{conf:function(){return n},language:function(){return o}});var n={comments:{lineComment:"//",blockComment:["/*","*/"]},brackets:[["{","}"],["[","]"],["(",")"],["begin","end"],["case","endcase"],["casex","endcase"],["casez","endcase"],["checker","endchecker"],["class","endclass"],["clocking","endclocking"],["config","endconfig"],["function","endfunction"],["generate","endgenerate"],["group","endgroup"],["interface","endinterface"],["module","endmodule"],["package","endpackage"],["primitive","endprimitive"],["program","endprogram"],["property","endproperty"],["specify","endspecify"],["sequence","endsequence"],["table","endtable"],["task","endtask"]],autoClosingPairs:[{open:"[",close:"]"},{open:"{",close:"}"},{open:"(",close:")"},{open:"'",close:"'",notIn:["string","comment"]},{open:'"',close:'"',notIn:["string"]}],surroundingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:'"',close:'"'},{open:"'",close:"'"}],folding:{offSide:!1,markers:{start:new RegExp("^(?:\\s*|.*(?!\\/[\\/\\*])[^\\w])(?:begin|case(x|z)?|class|clocking|config|covergroup|function|generate|interface|module|package|primitive|property|program|sequence|specify|table|task)\\b"),end:new RegExp("^(?:\\s*|.*(?!\\/[\\/\\*])[^\\w])(?:end|endcase|endclass|endclocking|endconfig|endgroup|endfunction|endgenerate|endinterface|endmodule|endpackage|endprimitive|endproperty|endprogram|endsequence|endspecify|endtable|endtask)\\b")}}},o={defaultToken:"",tokenPostfix:".sv",brackets:[{token:"delimiter.curly",open:"{",close:"}"},{token:"delimiter.parenthesis",open:"(",close:")"},{token:"delimiter.square",open:"[",close:"]"},{token:"delimiter.angle",open:"<",close:">"}],keywords:["accept_on","alias","always","always_comb","always_ff","always_latch","and","assert","assign","assume","automatic","before","begin","bind","bins","binsof","bit","break","buf","bufif0","bufif1","byte","case","casex","casez","cell","chandle","checker","class","clocking","cmos","config","const","constraint","context","continue","cover","covergroup","coverpoint","cross","deassign","default","defparam","design","disable","dist","do","edge","else","end","endcase","endchecker","endclass","endclocking","endconfig","endfunction","endgenerate","endgroup","endinterface","endmodule","endpackage","endprimitive","endprogram","endproperty","endspecify","endsequence","endtable","endtask","enum","event","eventually","expect","export","extends","extern","final","first_match","for","force","foreach","forever","fork","forkjoin","function","generate","genvar","global","highz0","highz1","if","iff","ifnone","ignore_bins","illegal_bins","implements","implies","import","incdir","include","initial","inout","input","inside","instance","int","integer","interconnect","interface","intersect","join","join_any","join_none","large","let","liblist","library","local","localparam","logic","longint","macromodule","matches","medium","modport","module","nand","negedge","nettype","new","nexttime","nmos","nor","noshowcancelled","not","notif0","notif1","null","or","output","package","packed","parameter","pmos","posedge","primitive","priority","program","property","protected","pull0","pull1","pulldown","pullup","pulsestyle_ondetect","pulsestyle_onevent","pure","rand","randc","randcase","randsequence","rcmos","real","realtime","ref","reg","reject_on","release","repeat","restrict","return","rnmos","rpmos","rtran","rtranif0","rtranif1","s_always","s_eventually","s_nexttime","s_until","s_until_with","scalared","sequence","shortint","shortreal","showcancelled","signed","small","soft","solve","specify","specparam","static","string","strong","strong0","strong1","struct","super","supply0","supply1","sync_accept_on","sync_reject_on","table","tagged","task","this","throughout","time","timeprecision","timeunit","tran","tranif0","tranif1","tri","tri0","tri1","triand","trior","trireg","type","typedef","union","unique","unique0","unsigned","until","until_with","untyped","use","uwire","var","vectored","virtual","void","wait","wait_order","wand","weak","weak0","weak1","while","wildcard","wire","with","within","wor","xnor","xor"],builtin_gates:["and","nand","nor","or","xor","xnor","buf","not","bufif0","bufif1","notif1","notif0","cmos","nmos","pmos","rcmos","rnmos","rpmos","tran","tranif1","tranif0","rtran","rtranif1","rtranif0"],operators:["=","+=","-=","*=","/=","%=","&=","|=","^=","<<=",">>+","<<<=",">>>=","?",":","+","-","!","~","&","~&","|","~|","^","~^","^~","+","-","*","/","%","==","!=","===","!==","==?","!=?","&&","||","**","<","<=",">",">=","&","|","^",">>","<<",">>>","<<<","++","--","->","<->","inside","dist","::","+:","-:","*>","&&&","|->","|=>","#=#"],symbols:/[=>](?!@symbols)/,"@brackets"],[/@symbols/,{cases:{"@operators":"delimiter","@default":""}}],{include:"@numbers"},[/[;,.]/,"delimiter"],{include:"@strings"}],identifier_or_keyword:[[/@identifier/,{cases:{"@keywords":{token:"keyword.$0"},"@default":"identifier"}}]],numbers:[[/\d+?[\d_]*(?:\.[\d_]+)?[eE][\-+]?\d+/,"number.float"],[/\d+?[\d_]*\.[\d_]+(?:\s*@timeunits)?/,"number.float"],[/(?:\d+?[\d_]*\s*)?'[sS]?[dD]\s*[0-9xXzZ?]+?[0-9xXzZ?_]*/,"number"],[/(?:\d+?[\d_]*\s*)?'[sS]?[bB]\s*[0-1xXzZ?]+?[0-1xXzZ?_]*/,"number.binary"],[/(?:\d+?[\d_]*\s*)?'[sS]?[oO]\s*[0-7xXzZ?]+?[0-7xXzZ?_]*/,"number.octal"],[/(?:\d+?[\d_]*\s*)?'[sS]?[hH]\s*[0-9a-fA-FxXzZ?]+?[0-9a-fA-FxXzZ?_]*/,"number.hex"],[/1step/,"number"],[/[\dxXzZ]+?[\dxXzZ_]*(?:\s*@timeunits)?/,"number"],[/'[01xXzZ]+/,"number"]],module_instance:[{include:"@whitespace"},[/(#?)(\()/,["",{token:"@brackets",next:"@port_connection"}]],[/@identifier\s*[;={}\[\],]/,{token:"@rematch",next:"@pop"}],[/@symbols|[;={}\[\],]/,{token:"@rematch",next:"@pop"}],[/@identifier/,"type"],[/;/,"delimiter","@pop"]],port_connection:[{include:"@identifier_or_keyword"},{include:"@whitespace"},[/@systemcall/,"variable.predefined"],{include:"@numbers"},{include:"@strings"},[/[,]/,"delimiter"],[/\(/,"@brackets","@port_connection"],[/\)/,"@brackets","@pop"]],whitespace:[[/[ \t\r\n]+/,""],[/\/\*/,"comment","@comment"],[/\/\/.*$/,"comment"]],comment:[[/[^\/*]+/,"comment"],[/\*\//,"comment","@pop"],[/[\/*]/,"comment"]],strings:[[/"([^"\\]|\\.)*$/,"string.invalid"],[/"/,"string","@string"]],string:[[/[^\\"]+/,"string"],[/@escapes/,"string.escape"],[/\\./,"string.escape.invalid"],[/"/,"string","@pop"]],include:[[/(\s*)(")([\w*\/*]*)(.\w*)(")/,["","string.include.identifier","string.include.identifier","string.include.identifier",{token:"string.include.identifier",next:"@pop"}]],[/(\s*)(<)([\w*\/*]*)(.\w*)(>)/,["","string.include.identifier","string.include.identifier","string.include.identifier",{token:"string.include.identifier",next:"@pop"}]]],table:[{include:"@whitespace"},[/[()]/,"@brackets"],[/[:;]/,"delimiter"],[/[01\-*?xXbBrRfFpPnN]/,"variable.predefined"],["endtable","keyword.endtable","@pop"]]}}},35184:function(e,t,i){"use strict";i.r(t),(0,i(70266).H)({id:"tcl",extensions:[".tcl"],aliases:["tcl","Tcl","tcltk","TclTk","tcl/tk","Tcl/Tk"],loader:()=>Promise.resolve().then(i.bind(i,96040))})},96040:function(e,t,i){"use strict";i.r(t),i.d(t,{conf:function(){return n},language:function(){return o}});var n={brackets:[["{","}"],["[","]"],["(",")"]],autoClosingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:'"',close:'"'},{open:"'",close:"'"}],surroundingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:'"',close:'"'},{open:"'",close:"'"}]},o={tokenPostfix:".tcl",specialFunctions:["set","unset","rename","variable","proc","coroutine","foreach","incr","append","lappend","linsert","lreplace"],mainFunctions:["if","then","elseif","else","case","switch","while","for","break","continue","return","package","namespace","catch","exit","eval","expr","uplevel","upvar"],builtinFunctions:["file","info","concat","join","lindex","list","llength","lrange","lsearch","lsort","split","array","parray","binary","format","regexp","regsub","scan","string","subst","dict","cd","clock","exec","glob","pid","pwd","close","eof","fblocked","fconfigure","fcopy","fileevent","flush","gets","open","puts","read","seek","socket","tell","interp","after","auto_execok","auto_load","auto_mkindex","auto_reset","bgerror","error","global","history","load","source","time","trace","unknown","unset","update","vwait","winfo","wm","bind","event","pack","place","grid","font","bell","clipboard","destroy","focus","grab","lower","option","raise","selection","send","tk","tkwait","tk_bisque","tk_focusNext","tk_focusPrev","tk_focusFollowsMouse","tk_popup","tk_setPalette"],symbols:/[=>Promise.resolve().then(i.bind(i,3679))})},3679:function(e,t,i){"use strict";i.r(t),i.d(t,{conf:function(){return n},language:function(){return o}});var n={wordPattern:/(-?\d*\.\d\w*)|([^\`\~\!\@\$\^\&\*\(\)\=\+\[\{\]\}\\\|\;\:\'\"\,\.\<\>\/\s]+)/g,comments:{blockComment:["{#","#}"]},brackets:[["{#","#}"],["{%","%}"],["{{","}}"],["(",")"],["[","]"],["\x3c!--","--\x3e"],["<",">"]],autoClosingPairs:[{open:"{# ",close:" #}"},{open:"{% ",close:" %}"},{open:"{{ ",close:" }}"},{open:"[",close:"]"},{open:"(",close:")"},{open:'"',close:'"'},{open:"'",close:"'"}],surroundingPairs:[{open:'"',close:'"'},{open:"'",close:"'"},{open:"<",close:">"}]},o={defaultToken:"",tokenPostfix:"",ignoreCase:!0,keywords:["apply","autoescape","block","deprecated","do","embed","extends","flush","for","from","if","import","include","macro","sandbox","set","use","verbatim","with","endapply","endautoescape","endblock","endembed","endfor","endif","endmacro","endsandbox","endset","endwith","true","false"],tokenizer:{root:[[/\s+/],[/{#/,"comment.twig","@commentState"],[/{%[-~]?/,"delimiter.twig","@blockState"],[/{{[-~]?/,"delimiter.twig","@variableState"],[/)/,["delimiter.html","tag.html","","delimiter.html"]],[/(<)(script)/,["delimiter.html",{token:"tag.html",next:"@script"}]],[/(<)(style)/,["delimiter.html",{token:"tag.html",next:"@style"}]],[/(<)((?:[\w\-]+:)?[\w\-]+)/,["delimiter.html",{token:"tag.html",next:"@otherTag"}]],[/(<\/)((?:[\w\-]+:)?[\w\-]+)/,["delimiter.html",{token:"tag.html",next:"@otherTag"}]],[/|>=|<=/,"operators.twig"],[/(starts with|ends with|matches)(\s+)/,["operators.twig",""]],[/(in)(\s+)/,["operators.twig",""]],[/(is)(\s+)/,["operators.twig",""]],[/\||~|:|\.{1,2}|\?{1,2}/,"operators.twig"],[/[^\W\d][\w]*/,{cases:{"@keywords":"keyword.twig","@default":"variable.twig"}}],[/\d+(\.\d+)?/,"number.twig"],[/\(|\)|\[|\]|{|}|,/,"delimiter.twig"],[/"([^#"\\]*(?:\\.[^#"\\]*)*)"|\'([^\'\\]*(?:\\.[^\'\\]*)*)\'/,"string.twig"],[/"/,"string.twig","@stringState"],[/=>/,"operators.twig"],[/=/,"operators.twig"]],doctype:[[/[^>]+/,"metatag.content.html"],[/>/,"metatag.html","@pop"]],comment:[[/-->/,"comment.html","@pop"],[/[^-]+/,"comment.content.html"],[/./,"comment.content.html"]],otherTag:[[/\/?>/,"delimiter.html","@pop"],[/"([^"]*)"/,"attribute.value.html"],[/'([^']*)'/,"attribute.value.html"],[/[\w\-]+/,"attribute.name.html"],[/=/,"delimiter.html"],[/[ \t\r\n]+/]],script:[[/type/,"attribute.name.html","@scriptAfterType"],[/"([^"]*)"/,"attribute.value.html"],[/'([^']*)'/,"attribute.value.html"],[/[\w\-]+/,"attribute.name.html"],[/=/,"delimiter.html"],[/>/,{token:"delimiter.html",next:"@scriptEmbedded",nextEmbedded:"text/javascript"}],[/[ \t\r\n]+/],[/(<\/)(script\s*)(>)/,["delimiter.html","tag.html",{token:"delimiter.html",next:"@pop"}]]],scriptAfterType:[[/=/,"delimiter.html","@scriptAfterTypeEquals"],[/>/,{token:"delimiter.html",next:"@scriptEmbedded",nextEmbedded:"text/javascript"}],[/[ \t\r\n]+/],[/<\/script\s*>/,{token:"@rematch",next:"@pop"}]],scriptAfterTypeEquals:[[/"([^"]*)"/,{token:"attribute.value.html",switchTo:"@scriptWithCustomType.$1"}],[/'([^']*)'/,{token:"attribute.value.html",switchTo:"@scriptWithCustomType.$1"}],[/>/,{token:"delimiter.html",next:"@scriptEmbedded",nextEmbedded:"text/javascript"}],[/[ \t\r\n]+/],[/<\/script\s*>/,{token:"@rematch",next:"@pop"}]],scriptWithCustomType:[[/>/,{token:"delimiter.html",next:"@scriptEmbedded.$S2",nextEmbedded:"$S2"}],[/"([^"]*)"/,"attribute.value.html"],[/'([^']*)'/,"attribute.value.html"],[/[\w\-]+/,"attribute.name.html"],[/=/,"delimiter.html"],[/[ \t\r\n]+/],[/<\/script\s*>/,{token:"@rematch",next:"@pop"}]],scriptEmbedded:[[/<\/script/,{token:"@rematch",next:"@pop",nextEmbedded:"@pop"}],[/[^<]+/,""]],style:[[/type/,"attribute.name.html","@styleAfterType"],[/"([^"]*)"/,"attribute.value.html"],[/'([^']*)'/,"attribute.value.html"],[/[\w\-]+/,"attribute.name.html"],[/=/,"delimiter.html"],[/>/,{token:"delimiter.html",next:"@styleEmbedded",nextEmbedded:"text/css"}],[/[ \t\r\n]+/],[/(<\/)(style\s*)(>)/,["delimiter.html","tag.html",{token:"delimiter.html",next:"@pop"}]]],styleAfterType:[[/=/,"delimiter.html","@styleAfterTypeEquals"],[/>/,{token:"delimiter.html",next:"@styleEmbedded",nextEmbedded:"text/css"}],[/[ \t\r\n]+/],[/<\/style\s*>/,{token:"@rematch",next:"@pop"}]],styleAfterTypeEquals:[[/"([^"]*)"/,{token:"attribute.value.html",switchTo:"@styleWithCustomType.$1"}],[/'([^']*)'/,{token:"attribute.value.html",switchTo:"@styleWithCustomType.$1"}],[/>/,{token:"delimiter.html",next:"@styleEmbedded",nextEmbedded:"text/css"}],[/[ \t\r\n]+/],[/<\/style\s*>/,{token:"@rematch",next:"@pop"}]],styleWithCustomType:[[/>/,{token:"delimiter.html",next:"@styleEmbedded.$S2",nextEmbedded:"$S2"}],[/"([^"]*)"/,"attribute.value.html"],[/'([^']*)'/,"attribute.value.html"],[/[\w\-]+/,"attribute.name.html"],[/=/,"delimiter.html"],[/[ \t\r\n]+/],[/<\/style\s*>/,{token:"@rematch",next:"@pop"}]],styleEmbedded:[[/<\/style/,{token:"@rematch",next:"@pop",nextEmbedded:"@pop"}],[/[^<]+/,""]]}}},59114:function(e,t,i){"use strict";i.r(t),(0,i(70266).H)({id:"typescript",extensions:[".ts",".tsx"],aliases:["TypeScript","ts","typescript"],mimetypes:["text/typescript"],loader:()=>Promise.resolve().then(i.bind(i,18815))})},18815:function(e,t,i){"use strict";i.r(t),i.d(t,{conf:function(){return c},language:function(){return d}});var n=i(54918),o=Object.defineProperty,r=Object.getOwnPropertyDescriptor,s=Object.getOwnPropertyNames,a=Object.prototype.hasOwnProperty,l={};((e,t,i,n)=>{if(t&&"object"==typeof t||"function"==typeof t)for(let i of s(t))a.call(e,i)||"default"===i||o(e,i,{get:()=>t[i],enumerable:!(n=r(t,i))||n.enumerable})})(l,n);var c={wordPattern:/(-?\d*\.\d\w*)|([^\`\~\!\@\#\%\^\&\*\(\)\-\=\+\[\{\]\}\\\|\;\:\'\"\,\.\<\>\/\?\s]+)/g,comments:{lineComment:"//",blockComment:["/*","*/"]},brackets:[["{","}"],["[","]"],["(",")"]],onEnterRules:[{beforeText:/^\s*\/\*\*(?!\/)([^\*]|\*(?!\/))*$/,afterText:/^\s*\*\/$/,action:{indentAction:l.languages.IndentAction.IndentOutdent,appendText:" * "}},{beforeText:/^\s*\/\*\*(?!\/)([^\*]|\*(?!\/))*$/,action:{indentAction:l.languages.IndentAction.None,appendText:" * "}},{beforeText:/^(\t|(\ \ ))*\ \*(\ ([^\*]|\*(?!\/))*)?$/,action:{indentAction:l.languages.IndentAction.None,appendText:"* "}},{beforeText:/^(\t|(\ \ ))*\ \*\/\s*$/,action:{indentAction:l.languages.IndentAction.None,removeText:1}}],autoClosingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:'"',close:'"',notIn:["string"]},{open:"'",close:"'",notIn:["string","comment"]},{open:"`",close:"`",notIn:["string","comment"]},{open:"/**",close:" */",notIn:["string"]}],folding:{markers:{start:new RegExp("^\\s*//\\s*#?region\\b"),end:new RegExp("^\\s*//\\s*#?endregion\\b")}}},d={defaultToken:"invalid",tokenPostfix:".ts",keywords:["abstract","any","as","asserts","bigint","boolean","break","case","catch","class","continue","const","constructor","debugger","declare","default","delete","do","else","enum","export","extends","false","finally","for","from","function","get","if","implements","import","in","infer","instanceof","interface","is","keyof","let","module","namespace","never","new","null","number","object","package","private","protected","public","override","readonly","require","global","return","set","static","string","super","switch","symbol","this","throw","true","try","type","typeof","undefined","unique","unknown","var","void","while","with","yield","async","await","of"],operators:["<=",">=","==","!=","===","!==","=>","+","-","**","*","/","%","++","--","<<",">",">>>","&","|","^","!","~","&&","||","??","?",":","=","+=","-=","*=","**=","/=","%=","<<=",">>=",">>>=","&=","|=","^=","@"],symbols:/[=>](?!@symbols)/,"@brackets"],[/!(?=([^=]|$))/,"delimiter"],[/@symbols/,{cases:{"@operators":"delimiter","@default":""}}],[/(@digits)[eE]([\-+]?(@digits))?/,"number.float"],[/(@digits)\.(@digits)([eE][\-+]?(@digits))?/,"number.float"],[/0[xX](@hexdigits)n?/,"number.hex"],[/0[oO]?(@octaldigits)n?/,"number.octal"],[/0[bB](@binarydigits)n?/,"number.binary"],[/(@digits)n?/,"number"],[/[;,.]/,"delimiter"],[/"([^"\\]|\\.)*$/,"string.invalid"],[/'([^'\\]|\\.)*$/,"string.invalid"],[/"/,"string","@string_double"],[/'/,"string","@string_single"],[/`/,"string","@string_backtick"]],whitespace:[[/[ \t\r\n]+/,""],[/\/\*\*(?!\/)/,"comment.doc","@jsdoc"],[/\/\*/,"comment","@comment"],[/\/\/.*$/,"comment"]],comment:[[/[^\/*]+/,"comment"],[/\*\//,"comment","@pop"],[/[\/*]/,"comment"]],jsdoc:[[/[^\/*]+/,"comment.doc"],[/\*\//,"comment.doc","@pop"],[/[\/*]/,"comment.doc"]],regexp:[[/(\{)(\d+(?:,\d*)?)(\})/,["regexp.escape.control","regexp.escape.control","regexp.escape.control"]],[/(\[)(\^?)(?=(?:[^\]\\\/]|\\.)+)/,["regexp.escape.control",{token:"regexp.escape.control",next:"@regexrange"}]],[/(\()(\?:|\?=|\?!)/,["regexp.escape.control","regexp.escape.control"]],[/[()]/,"regexp.escape.control"],[/@regexpctl/,"regexp.escape.control"],[/[^\\\/]/,"regexp"],[/@regexpesc/,"regexp.escape"],[/\\\./,"regexp.invalid"],[/(\/)([dgimsuy]*)/,[{token:"regexp",bracket:"@close",next:"@pop"},"keyword.other"]]],regexrange:[[/-/,"regexp.escape.control"],[/\^/,"regexp.invalid"],[/@regexpesc/,"regexp.escape"],[/[^\]]/,"regexp"],[/\]/,{token:"regexp.escape.control",next:"@pop",bracket:"@close"}]],string_double:[[/[^\\"]+/,"string"],[/@escapes/,"string.escape"],[/\\./,"string.escape.invalid"],[/"/,"string","@pop"]],string_single:[[/[^\\']+/,"string"],[/@escapes/,"string.escape"],[/\\./,"string.escape.invalid"],[/'/,"string","@pop"]],string_backtick:[[/\$\{/,{token:"delimiter.bracket",next:"@bracketCounting"}],[/[^\\`$]+/,"string"],[/@escapes/,"string.escape"],[/\\./,"string.escape.invalid"],[/`/,"string","@pop"]],bracketCounting:[[/\{/,"delimiter.bracket","@bracketCounting"],[/\}/,"delimiter.bracket","@pop"],{include:"common"}]}}},19396:function(e,t,i){"use strict";i.r(t),(0,i(70266).H)({id:"vb",extensions:[".vb"],aliases:["Visual Basic","vb"],loader:()=>Promise.resolve().then(i.bind(i,96047))})},96047:function(e,t,i){"use strict";i.r(t),i.d(t,{conf:function(){return n},language:function(){return o}});var n={comments:{lineComment:"'",blockComment:["/*","*/"]},brackets:[["{","}"],["[","]"],["(",")"],["<",">"],["addhandler","end addhandler"],["class","end class"],["enum","end enum"],["event","end event"],["function","end function"],["get","end get"],["if","end if"],["interface","end interface"],["module","end module"],["namespace","end namespace"],["operator","end operator"],["property","end property"],["raiseevent","end raiseevent"],["removehandler","end removehandler"],["select","end select"],["set","end set"],["structure","end structure"],["sub","end sub"],["synclock","end synclock"],["try","end try"],["while","end while"],["with","end with"],["using","end using"],["do","loop"],["for","next"]],autoClosingPairs:[{open:"{",close:"}",notIn:["string","comment"]},{open:"[",close:"]",notIn:["string","comment"]},{open:"(",close:")",notIn:["string","comment"]},{open:'"',close:'"',notIn:["string","comment"]},{open:"<",close:">",notIn:["string","comment"]}],folding:{markers:{start:new RegExp("^\\s*#Region\\b"),end:new RegExp("^\\s*#End Region\\b")}}},o={defaultToken:"",tokenPostfix:".vb",ignoreCase:!0,brackets:[{token:"delimiter.bracket",open:"{",close:"}"},{token:"delimiter.array",open:"[",close:"]"},{token:"delimiter.parenthesis",open:"(",close:")"},{token:"delimiter.angle",open:"<",close:">"},{token:"keyword.tag-addhandler",open:"addhandler",close:"end addhandler"},{token:"keyword.tag-class",open:"class",close:"end class"},{token:"keyword.tag-enum",open:"enum",close:"end enum"},{token:"keyword.tag-event",open:"event",close:"end event"},{token:"keyword.tag-function",open:"function",close:"end function"},{token:"keyword.tag-get",open:"get",close:"end get"},{token:"keyword.tag-if",open:"if",close:"end if"},{token:"keyword.tag-interface",open:"interface",close:"end interface"},{token:"keyword.tag-module",open:"module",close:"end module"},{token:"keyword.tag-namespace",open:"namespace",close:"end namespace"},{token:"keyword.tag-operator",open:"operator",close:"end operator"},{token:"keyword.tag-property",open:"property",close:"end property"},{token:"keyword.tag-raiseevent",open:"raiseevent",close:"end raiseevent"},{token:"keyword.tag-removehandler",open:"removehandler",close:"end removehandler"},{token:"keyword.tag-select",open:"select",close:"end select"},{token:"keyword.tag-set",open:"set",close:"end set"},{token:"keyword.tag-structure",open:"structure",close:"end structure"},{token:"keyword.tag-sub",open:"sub",close:"end sub"},{token:"keyword.tag-synclock",open:"synclock",close:"end synclock"},{token:"keyword.tag-try",open:"try",close:"end try"},{token:"keyword.tag-while",open:"while",close:"end while"},{token:"keyword.tag-with",open:"with",close:"end with"},{token:"keyword.tag-using",open:"using",close:"end using"},{token:"keyword.tag-do",open:"do",close:"loop"},{token:"keyword.tag-for",open:"for",close:"next"}],keywords:["AddHandler","AddressOf","Alias","And","AndAlso","As","Async","Boolean","ByRef","Byte","ByVal","Call","Case","Catch","CBool","CByte","CChar","CDate","CDbl","CDec","Char","CInt","Class","CLng","CObj","Const","Continue","CSByte","CShort","CSng","CStr","CType","CUInt","CULng","CUShort","Date","Decimal","Declare","Default","Delegate","Dim","DirectCast","Do","Double","Each","Else","ElseIf","End","EndIf","Enum","Erase","Error","Event","Exit","False","Finally","For","Friend","Function","Get","GetType","GetXMLNamespace","Global","GoSub","GoTo","Handles","If","Implements","Imports","In","Inherits","Integer","Interface","Is","IsNot","Let","Lib","Like","Long","Loop","Me","Mod","Module","MustInherit","MustOverride","MyBase","MyClass","NameOf","Namespace","Narrowing","New","Next","Not","Nothing","NotInheritable","NotOverridable","Object","Of","On","Operator","Option","Optional","Or","OrElse","Out","Overloads","Overridable","Overrides","ParamArray","Partial","Private","Property","Protected","Public","RaiseEvent","ReadOnly","ReDim","RemoveHandler","Resume","Return","SByte","Select","Set","Shadows","Shared","Short","Single","Static","Step","Stop","String","Structure","Sub","SyncLock","Then","Throw","To","True","Try","TryCast","TypeOf","UInteger","ULong","UShort","Using","Variant","Wend","When","While","Widening","With","WithEvents","WriteOnly","Xor"],tagwords:["If","Sub","Select","Try","Class","Enum","Function","Get","Interface","Module","Namespace","Operator","Set","Structure","Using","While","With","Do","Loop","For","Next","Property","Continue","AddHandler","RemoveHandler","Event","RaiseEvent","SyncLock"],symbols:/[=>Promise.resolve().then(i.bind(i,13674))})},13674:function(e,t,i){"use strict";i.r(t),i.d(t,{conf:function(){return c},language:function(){return d}});var n=i(54918),o=Object.defineProperty,r=Object.getOwnPropertyDescriptor,s=Object.getOwnPropertyNames,a=Object.prototype.hasOwnProperty,l={};((e,t,i,n)=>{if(t&&"object"==typeof t||"function"==typeof t)for(let i of s(t))a.call(e,i)||"default"===i||o(e,i,{get:()=>t[i],enumerable:!(n=r(t,i))||n.enumerable})})(l,n);var c={comments:{blockComment:["\x3c!--","--\x3e"]},brackets:[["<",">"]],autoClosingPairs:[{open:"<",close:">"},{open:"'",close:"'"},{open:'"',close:'"'}],surroundingPairs:[{open:"<",close:">"},{open:"'",close:"'"},{open:'"',close:'"'}],onEnterRules:[{beforeText:new RegExp("<([_:\\w][_:\\w-.\\d]*)([^/>]*(?!/)>)[^<]*$","i"),afterText:/^<\/([_:\w][_:\w-.\d]*)\s*>$/i,action:{indentAction:l.languages.IndentAction.IndentOutdent}},{beforeText:new RegExp("<(\\w[\\w\\d]*)([^/>]*(?!/)>)[^<]*$","i"),action:{indentAction:l.languages.IndentAction.Indent}}]},d={defaultToken:"",tokenPostfix:".xml",ignoreCase:!0,qualifiedName:/(?:[\w\.\-]+:)?[\w\.\-]+/,tokenizer:{root:[[/[^<&]+/,""],{include:"@whitespace"},[/(<)(@qualifiedName)/,[{token:"delimiter"},{token:"tag",next:"@tag"}]],[/(<\/)(@qualifiedName)(\s*)(>)/,[{token:"delimiter"},{token:"tag"},"",{token:"delimiter"}]],[/(<\?)(@qualifiedName)/,[{token:"delimiter"},{token:"metatag",next:"@tag"}]],[/(<\!)(@qualifiedName)/,[{token:"delimiter"},{token:"metatag",next:"@tag"}]],[/<\!\[CDATA\[/,{token:"delimiter.cdata",next:"@cdata"}],[/&\w+;/,"string.escape"]],cdata:[[/[^\]]+/,""],[/\]\]>/,{token:"delimiter.cdata",next:"@pop"}],[/\]/,""]],tag:[[/[ \t\r\n]+/,""],[/(@qualifiedName)(\s*=\s*)("[^"]*"|'[^']*')/,["attribute.name","","attribute.value"]],[/(@qualifiedName)(\s*=\s*)("[^">?\/]*|'[^'>?\/]*)(?=[\?\/]\>)/,["attribute.name","","attribute.value"]],[/(@qualifiedName)(\s*=\s*)("[^">]*|'[^'>]*)/,["attribute.name","","attribute.value"]],[/@qualifiedName/,"attribute.name"],[/\?>/,{token:"delimiter",next:"@pop"}],[/(\/)(>)/,[{token:"tag"},{token:"delimiter",next:"@pop"}]],[/>/,{token:"delimiter",next:"@pop"}]],whitespace:[[/[ \t\r\n]+/,""],[//,{token:"comment",next:"@pop"}],[/|$)/,T.html=m(T.html,"i").replace("comment",T._comment).replace("tag",T._tag).replace("attribute",/ +[a-zA-Z:_][\w.:-]*(?: *= *"[^"\n]*"| *= *'[^'\n]*'| *= *[^\s"'=<>`]+)?/).getRegex(),T.paragraph=m(T._paragraph).replace("hr",T.hr).replace("heading"," {0,3}#{1,6} ").replace("|lheading","").replace("|table","").replace("blockquote"," {0,3}>").replace("fences"," {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list"," {0,3}(?:[*+-]|1[.)]) ").replace("html",")|<(?:script|pre|style|textarea|!--)").replace("tag",T._tag).getRegex(),T.blockquote=m(T.blockquote).replace("paragraph",T.paragraph).getRegex(),T.normal=x({},T),T.gfm=x({},T.normal,{table:"^ *([^\\n ].*\\|.*)\\n {0,3}(?:\\| *)?(:?-+:? *(?:\\| *:?-+:? *)*)(?:\\| *)?(?:\\n((?:(?! *\\n|hr|heading|blockquote|code|fences|list|html).*(?:\\n|$))*)\\n*|$)"}),T.gfm.table=m(T.gfm.table).replace("hr",T.hr).replace("heading"," {0,3}#{1,6} ").replace("blockquote"," {0,3}>").replace("code"," {4}[^\\n]").replace("fences"," {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list"," {0,3}(?:[*+-]|1[.)]) ").replace("html",")|<(?:script|pre|style|textarea|!--)").replace("tag",T._tag).getRegex(),T.gfm.paragraph=m(T._paragraph).replace("hr",T.hr).replace("heading"," {0,3}#{1,6} ").replace("|lheading","").replace("table",T.gfm.table).replace("blockquote"," {0,3}>").replace("fences"," {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list"," {0,3}(?:[*+-]|1[.)]) ").replace("html",")|<(?:script|pre|style|textarea|!--)").replace("tag",T._tag).getRegex(),T.pedantic=x({},T.normal,{html:m("^ *(?:comment *(?:\\n|\\s*$)|<(tag)[\\s\\S]+? *(?:\\n{2,}|\\s*$)|\\s]*)*?/?> *(?:\\n{2,}|\\s*$))").replace("comment",T._comment).replace(/tag/g,"(?!(?:a|em|strong|small|s|cite|q|dfn|abbr|data|time|code|var|samp|kbd|sub|sup|i|b|u|mark|ruby|rt|rp|bdi|bdo|span|br|wbr|ins|del|img)\\b)\\w+(?!:|[^\\w\\s@]*@)\\b").getRegex(),def:/^ *\[([^\]]+)\]: *]+)>?(?: +(["(][^\n]+[")]))? *(?:\n+|$)/,heading:/^(#{1,6})(.*)(?:\n+|$)/,fences:S,paragraph:m(T.normal._paragraph).replace("hr",T.hr).replace("heading"," *#{1,6} *[^\n]").replace("lheading",T.lheading).replace("blockquote"," {0,3}>").replace("|fences","").replace("|list","").replace("|html","").getRegex()});var A={escape:/^\\([!"#$%&'()*+,\-./:;<=>?@\[\]\\^_`{|}~])/,autolink:/^<(scheme:[^\s\x00-\x1f<>]*|email)>/,url:S,tag:"^comment|^|^<[a-zA-Z][\\w-]*(?:attribute)*?\\s*/?>|^<\\?[\\s\\S]*?\\?>|^|^",link:/^!?\[(label)\]\(\s*(href)(?:\s+(title))?\s*\)/,reflink:/^!?\[(label)\]\[(ref)\]/,nolink:/^!?\[(ref)\](?:\[\])?/,reflinkSearch:"reflink|nolink(?!\\()",emStrong:{lDelim:/^(?:\*+(?:([punct_])|[^\s*]))|^_+(?:([punct*])|([^\s_]))/,rDelimAst:/^[^_*]*?\_\_[^_*]*?\*[^_*]*?(?=\_\_)|[punct_](\*+)(?=[\s]|$)|[^punct*_\s](\*+)(?=[punct_\s]|$)|[punct_\s](\*+)(?=[^punct*_\s])|[\s](\*+)(?=[punct_])|[punct_](\*+)(?=[punct_])|[^punct*_\s](\*+)(?=[^punct*_\s])/,rDelimUnd:/^[^_*]*?\*\*[^_*]*?\_[^_*]*?(?=\*\*)|[punct*](\_+)(?=[\s]|$)|[^punct*_\s](\_+)(?=[punct*\s]|$)|[punct*\s](\_+)(?=[^punct*_\s])|[\s](\_+)(?=[punct*])|[punct*](\_+)(?=[punct*])/},code:/^(`+)([^`]|[^`][\s\S]*?[^`])\1(?!`)/,br:/^( {2,}|\\)\n(?!\s*$)/,del:S,text:/^(`+|[^`])(?:(?= {2,}\n)|[\s\S]*?(?:(?=[\\.5&&(i="x"+i.toString(16)),n+="&#"+i+";";return n}A._punctuation="!\"#$%&'()+\\-.,/:;<=>?@\\[\\]`^{|}~",A.punctuation=m(A.punctuation).replace(/punctuation/g,A._punctuation).getRegex(),A.blockSkip=/\[[^\]]*?\]\([^\)]*?\)|`[^`]*?`|<[^>]*?>/g,A.escapedEmSt=/\\\*|\\_/g,A._comment=m(T._comment).replace("(?:--\x3e|$)","--\x3e").getRegex(),A.emStrong.lDelim=m(A.emStrong.lDelim).replace(/punct/g,A._punctuation).getRegex(),A.emStrong.rDelimAst=m(A.emStrong.rDelimAst,"g").replace(/punct/g,A._punctuation).getRegex(),A.emStrong.rDelimUnd=m(A.emStrong.rDelimUnd,"g").replace(/punct/g,A._punctuation).getRegex(),A._escapes=/\\([!"#$%&'()*+,\-./:;<=>?@\[\]\\^_`{|}~])/g,A._scheme=/[a-zA-Z][a-zA-Z0-9+.-]{1,31}/,A._email=/[a-zA-Z0-9.!#$%&'*+/=?^_`{|}~-]+(@)[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?(?:\.[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?)+(?![-_])/,A.autolink=m(A.autolink).replace("scheme",A._scheme).replace("email",A._email).getRegex(),A._attribute=/\s+[a-zA-Z:_][\w.:-]*(?:\s*=\s*"[^"]*"|\s*=\s*'[^']*'|\s*=\s*[^\s"'=<>`]+)?/,A.tag=m(A.tag).replace("comment",A._comment).replace("attribute",A._attribute).getRegex(),A._label=/(?:\[(?:\\.|[^\[\]\\])*\]|\\.|`[^`]*`|[^\[\]\\`])*?/,A._href=/<(?:\\.|[^\n<>\\])+>|[^\s\x00-\x1f]*/,A._title=/"(?:\\"?|[^"\\])*"|'(?:\\'?|[^'\\])*'|\((?:\\\)?|[^)\\])*\)/,A.link=m(A.link).replace("label",A._label).replace("href",A._href).replace("title",A._title).getRegex(),A.reflink=m(A.reflink).replace("label",A._label).replace("ref",T._label).getRegex(),A.nolink=m(A.nolink).replace("ref",T._label).getRegex(),A.reflinkSearch=m(A.reflinkSearch,"g").replace("reflink",A.reflink).replace("nolink",A.nolink).getRegex(),A.normal=x({},A),A.pedantic=x({},A.normal,{strong:{start:/^__|\*\*/,middle:/^__(?=\S)([\s\S]*?\S)__(?!_)|^\*\*(?=\S)([\s\S]*?\S)\*\*(?!\*)/,endAst:/\*\*(?!\*)/g,endUnd:/__(?!_)/g},em:{start:/^_|\*/,middle:/^()\*(?=\S)([\s\S]*?\S)\*(?!\*)|^_(?=\S)([\s\S]*?\S)_(?!_)/,endAst:/\*(?!\*)/g,endUnd:/_(?!_)/g},link:m(/^!?\[(label)\]\((.*?)\)/).replace("label",A._label).getRegex(),reflink:m(/^!?\[(label)\]\s*\[([^\]]*)\]/).replace("label",A._label).getRegex()}),A.gfm=x({},A.normal,{escape:m(A.escape).replace("])","~|])").getRegex(),_extended_email:/[A-Za-z0-9._+-]+(@)[a-zA-Z0-9-_]+(?:\.[a-zA-Z0-9-_]*[a-zA-Z0-9])+(?![-_])/,url:/^((?:ftp|https?):\/\/|www\.)(?:[a-zA-Z0-9\-]+\.?)+[^\s<]*|^email/,_backpedal:/(?:[^?!.,:;*_~()&]+|\([^)]*\)|&(?![a-zA-Z0-9]+;$)|[?!.,:;*_~)]+(?!$))+/,del:/^(~~?)(?=[^\s~])([\s\S]*?[^\s~])\1(?=[^~]|$)/,text:/^([`~]+|[^`~])(?:(?= {2,}\n)|(?=[a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-]+@)|[\s\S]*?(?:(?=[\\0?t[t.length-1].raw+="\n":t.push(i);else if(i=this.tokenizer.code(e))e=e.substring(i.raw.length),!(n=t[t.length-1])||"paragraph"!==n.type&&"text"!==n.type?t.push(i):(n.raw+="\n"+i.raw,n.text+="\n"+i.text,this.inlineQueue[this.inlineQueue.length-1].src=n.text);else if(i=this.tokenizer.fences(e))e=e.substring(i.raw.length),t.push(i);else if(i=this.tokenizer.heading(e))e=e.substring(i.raw.length),t.push(i);else if(i=this.tokenizer.hr(e))e=e.substring(i.raw.length),t.push(i);else if(i=this.tokenizer.blockquote(e))e=e.substring(i.raw.length),t.push(i);else if(i=this.tokenizer.list(e))e=e.substring(i.raw.length),t.push(i);else if(i=this.tokenizer.html(e))e=e.substring(i.raw.length),t.push(i);else if(i=this.tokenizer.def(e))e=e.substring(i.raw.length),!(n=t[t.length-1])||"paragraph"!==n.type&&"text"!==n.type?this.tokens.links[i.tag]||(this.tokens.links[i.tag]={href:i.href,title:i.title}):(n.raw+="\n"+i.raw,n.text+="\n"+i.raw,this.inlineQueue[this.inlineQueue.length-1].src=n.text);else if(i=this.tokenizer.table(e))e=e.substring(i.raw.length),t.push(i);else if(i=this.tokenizer.lheading(e))e=e.substring(i.raw.length),t.push(i);else if(o=e,this.options.extensions&&this.options.extensions.startBlock&&function(){var t=1/0,i=e.slice(1),n=void 0;s.options.extensions.startBlock.forEach((function(e){"number"==typeof(n=e.call({lexer:this},i))&&n>=0&&(t=Math.min(t,n))})),t<1/0&&t>=0&&(o=e.substring(0,t+1))}(),this.state.top&&(i=this.tokenizer.paragraph(o)))n=t[t.length-1],r&&"paragraph"===n.type?(n.raw+="\n"+i.raw,n.text+="\n"+i.text,this.inlineQueue.pop(),this.inlineQueue[this.inlineQueue.length-1].src=n.text):t.push(i),r=o.length!==e.length,e=e.substring(i.raw.length);else if(i=this.tokenizer.text(e))e=e.substring(i.raw.length),(n=t[t.length-1])&&"text"===n.type?(n.raw+="\n"+i.raw,n.text+="\n"+i.text,this.inlineQueue.pop(),this.inlineQueue[this.inlineQueue.length-1].src=n.text):t.push(i);else if(e){var a="Infinite loop on byte: "+e.charCodeAt(0);if(this.options.silent){console.error(a);break}throw new Error(a)}return this.state.top=!0,t},r.inline=function(e,t){this.inlineQueue.push({src:e,tokens:t})},r.inlineTokens=function(e,t){var i,n,o,r=this;void 0===t&&(t=[]);var s,a,l,c=e;if(this.tokens.links){var d=Object.keys(this.tokens.links);if(d.length>0)for(;null!=(s=this.tokenizer.rules.inline.reflinkSearch.exec(c));)d.includes(s[0].slice(s[0].lastIndexOf("[")+1,-1))&&(c=c.slice(0,s.index)+"["+N("a",s[0].length-2)+"]"+c.slice(this.tokenizer.rules.inline.reflinkSearch.lastIndex))}for(;null!=(s=this.tokenizer.rules.inline.blockSkip.exec(c));)c=c.slice(0,s.index)+"["+N("a",s[0].length-2)+"]"+c.slice(this.tokenizer.rules.inline.blockSkip.lastIndex);for(;null!=(s=this.tokenizer.rules.inline.escapedEmSt.exec(c));)c=c.slice(0,s.index)+"++"+c.slice(this.tokenizer.rules.inline.escapedEmSt.lastIndex);for(;e;)if(a||(l=""),a=!1,!(this.options.extensions&&this.options.extensions.inline&&this.options.extensions.inline.some((function(n){return!!(i=n.call({lexer:r},e,t))&&(e=e.substring(i.raw.length),t.push(i),!0)}))))if(i=this.tokenizer.escape(e))e=e.substring(i.raw.length),t.push(i);else if(i=this.tokenizer.tag(e))e=e.substring(i.raw.length),(n=t[t.length-1])&&"text"===i.type&&"text"===n.type?(n.raw+=i.raw,n.text+=i.text):t.push(i);else if(i=this.tokenizer.link(e))e=e.substring(i.raw.length),t.push(i);else if(i=this.tokenizer.reflink(e,this.tokens.links))e=e.substring(i.raw.length),(n=t[t.length-1])&&"text"===i.type&&"text"===n.type?(n.raw+=i.raw,n.text+=i.text):t.push(i);else if(i=this.tokenizer.emStrong(e,c,l))e=e.substring(i.raw.length),t.push(i);else if(i=this.tokenizer.codespan(e))e=e.substring(i.raw.length),t.push(i);else if(i=this.tokenizer.br(e))e=e.substring(i.raw.length),t.push(i);else if(i=this.tokenizer.del(e))e=e.substring(i.raw.length),t.push(i);else if(i=this.tokenizer.autolink(e,M))e=e.substring(i.raw.length),t.push(i);else if(this.state.inLink||!(i=this.tokenizer.url(e,M))){if(o=e,this.options.extensions&&this.options.extensions.startInline&&function(){var t=1/0,i=e.slice(1),n=void 0;r.options.extensions.startInline.forEach((function(e){"number"==typeof(n=e.call({lexer:this},i))&&n>=0&&(t=Math.min(t,n))})),t<1/0&&t>=0&&(o=e.substring(0,t+1))}(),i=this.tokenizer.inlineText(o,R))e=e.substring(i.raw.length),"_"!==i.raw.slice(-1)&&(l=i.raw.slice(-1)),a=!0,(n=t[t.length-1])&&"text"===n.type?(n.raw+=i.raw,n.text+=i.text):t.push(i);else if(e){var u="Infinite loop on byte: "+e.charCodeAt(0);if(this.options.silent){console.error(u);break}throw new Error(u)}}else e=e.substring(i.raw.length),t.push(i);return t},n=i,o=[{key:"rules",get:function(){return{block:T,inline:A}}}],null&&t(n.prototype,null),o&&t(n,o),Object.defineProperty(n,"prototype",{writable:!1}),i}(),P=function(){function t(t){this.options=t||e.defaults}var i=t.prototype;return i.code=function(e,t,i){var n=(t||"").match(/\S*/)[0];if(this.options.highlight){var o=this.options.highlight(e,n);null!=o&&o!==e&&(i=!0,e=o)}return e=e.replace(/\n$/,"")+"\n",n?'
          '+(i?e:u(e,!0))+"
          \n":"
          "+(i?e:u(e,!0))+"
          \n"},i.blockquote=function(e){return"
          \n"+e+"
          \n"},i.html=function(e){return e},i.heading=function(e,t,i,n){return this.options.headerIds?"'+e+"\n":""+e+"\n"},i.hr=function(){return this.options.xhtml?"
          \n":"
          \n"},i.list=function(e,t,i){var n=t?"ol":"ul";return"<"+n+(t&&1!==i?' start="'+i+'"':"")+">\n"+e+"\n"},i.listitem=function(e){return"
        1. "+e+"
        2. \n"},i.checkbox=function(e){return" "},i.paragraph=function(e){return"

          "+e+"

          \n"},i.table=function(e,t){return t&&(t=""+t+""),"\n\n"+e+"\n"+t+"
          \n"},i.tablerow=function(e){return"\n"+e+"\n"},i.tablecell=function(e,t){var i=t.header?"th":"td";return(t.align?"<"+i+' align="'+t.align+'">':"<"+i+">")+e+"\n"},i.strong=function(e){return""+e+""},i.em=function(e){return""+e+""},i.codespan=function(e){return""+e+""},i.br=function(){return this.options.xhtml?"
          ":"
          "},i.del=function(e){return""+e+""},i.link=function(e,t,i){if(null===(e=b(this.options.sanitize,this.options.baseUrl,e)))return i;var n='
          "+i+""},i.image=function(e,t,i){if(null===(e=b(this.options.sanitize,this.options.baseUrl,e)))return i;var n=''+i+'":">")},i.text=function(e){return e},t}(),F=function(){function e(){}var t=e.prototype;return t.strong=function(e){return e},t.em=function(e){return e},t.codespan=function(e){return e},t.del=function(e){return e},t.html=function(e){return e},t.text=function(e){return e},t.link=function(e,t,i){return""+i},t.image=function(e,t,i){return""+i},t.br=function(){return""},e}(),B=function(){function e(){this.seen={}}var t=e.prototype;return t.serialize=function(e){return e.toLowerCase().trim().replace(/<[!\/a-z].*?>/gi,"").replace(/[\u2000-\u206F\u2E00-\u2E7F\\'!"#$%&()*+,./:;<=>?@[\]^`{|}~]/g,"").replace(/\s/g,"-")},t.getNextSafeSlug=function(e,t){var i=e,n=0;if(this.seen.hasOwnProperty(i)){n=this.seen[e];do{i=e+"-"+ ++n}while(this.seen.hasOwnProperty(i))}return t||(this.seen[e]=n,this.seen[i]=0),i},t.slug=function(e,t){void 0===t&&(t={});var i=this.serialize(e);return this.getNextSafeSlug(i,t.dryrun)},e}(),W=function(){function t(t){this.options=t||e.defaults,this.options.renderer=this.options.renderer||new P,this.renderer=this.options.renderer,this.renderer.options=this.options,this.textRenderer=new F,this.slugger=new B}t.parse=function(e,i){return new t(i).parse(e)},t.parseInline=function(e,i){return new t(i).parseInline(e)};var i=t.prototype;return i.parse=function(e,t){void 0===t&&(t=!0);var i,n,o,r,s,a,l,c,d,u,h,p,m,f,_,b,v,C,w,y="",S=e.length;for(i=0;i0&&"paragraph"===_.tokens[0].type?(_.tokens[0].text=C+" "+_.tokens[0].text,_.tokens[0].tokens&&_.tokens[0].tokens.length>0&&"text"===_.tokens[0].tokens[0].type&&(_.tokens[0].tokens[0].text=C+" "+_.tokens[0].tokens[0].text)):_.tokens.unshift({type:"text",text:C}):f+=C),f+=this.parse(_.tokens,m),d+=this.renderer.listitem(f,v,b);y+=this.renderer.list(d,h,p);continue;case"html":y+=this.renderer.html(u.text);continue;case"paragraph":y+=this.renderer.paragraph(this.parseInline(u.tokens));continue;case"text":for(d=u.tokens?this.parseInline(u.tokens):u.text;i+1An error occurred:

          "+u(e.message+"",!0)+"
          ";throw e}}V.options=V.setOptions=function(t){var i;return x(V.defaults,t),i=V.defaults,e.defaults=i,V},V.getDefaults=o,V.defaults=e.defaults,V.use=function(){for(var e=arguments.length,t=new Array(e),i=0;iAn error occurred:

          "+u(e.message+"",!0)+"
          ";throw e}},V.Parser=W,V.parser=W.parse,V.Renderer=P,V.TextRenderer=F,V.Lexer=O,V.lexer=O.lex,V.Tokenizer=I,V.Slugger=B,V.parse=V;var H=V.options,z=V.setOptions,$=V.use,U=V.walkTokens,j=V.parseInline,K=V,q=W.parse,G=O.lex;e.Lexer=O,e.Parser=W,e.Renderer=P,e.Slugger=B,e.TextRenderer=F,e.Tokenizer=I,e.getDefaults=o,e.lexer=G,e.marked=V,e.options=H,e.parse=K,e.parseInline=j,e.parser=q,e.setOptions=z,e.use=$,e.walkTokens=U,Object.defineProperty(e,"__esModule",{value:!0})},"object"==typeof exports?i(exports):e.amd?e(0,i):i((t="undefined"!=typeof globalThis?globalThis:t||self).marked={})}();var me=pe||exports,fe=i(60491),_e=i(9734),be=i(90584),ve=i(10804),Ce=i(18039),we=i(39675);function ye(e,t){return/^\w[\w\d+.-]*:/.test(t)?t:e.path.endsWith("/")?(0,ve.i3)(e,t).toString():(0,ve.i3)((0,ve.XX)(e),t).toString()}function Se(e,t){const{config:i,allowedSchemes:n}=function(e){const t=[_e.lg.http,_e.lg.https,_e.lg.mailto,_e.lg.data,_e.lg.file,_e.lg.vscodeFileResource,_e.lg.vscodeRemote,_e.lg.vscodeRemoteResource];return e.isTrusted&&t.push(_e.lg.command),{config:{ALLOWED_TAGS:["ul","li","p","b","i","code","blockquote","ol","h1","h2","h3","h4","h5","h6","hr","em","pre","table","thead","tbody","tr","th","td","div","del","a","strong","br","img","span"],ALLOWED_ATTR:["href","data-href","target","title","src","alt","class","style","data-code","width","height","align"],ALLOW_UNKNOWN_PROTOCOLS:!0},allowedSchemes:t}}(e);ee("uponSanitizeAttribute",((e,t)=>{if("style"!==t.attrName&&"class"!==t.attrName);else{if("SPAN"===e.tagName){if("style"===t.attrName)return void(t.keepAttr=/^(color\:#[0-9a-fA-F]+;)?(background-color\:#[0-9a-fA-F]+;)?$/.test(t.attrValue));if("class"===t.attrName)return void(t.keepAttr=/^codicon codicon-[a-z\-]+( codicon-modifier-[a-z\-]+)?$/.test(t.attrValue))}t.keepAttr=!1}}));const o=document.createElement("a");ee("afterSanitizeAttributes",(e=>{for(const t of["href","src"])e.hasAttribute(t)&&(o.href=e.getAttribute(t),n.includes(o.protocol.replace(/:$/,""))||e.removeAttribute(t))}));try{return J(t,Object.assign(Object.assign({},i),{RETURN_TRUSTED_TYPE:!0}))}finally{te("uponSanitizeAttribute"),te("afterSanitizeAttributes")}}var xe,ke=i(82523),Le=i(10940),Ee=i(54571),Ne=i(18226),De=i(11233),Ie=function(e,t){return function(i,n){t(i,n,e)}};let Te=class e{constructor(e,t,i){this._options=e,this._languageService=t,this._openerService=i,this._onDidRenderAsync=new ce.Q5,this.onDidRenderAsync=this._onDidRenderAsync.event}dispose(){this._onDidRenderAsync.dispose()}render(e,t,i){if(!e)return{element:document.createElement("span"),dispose:()=>{}};const o=new ge.SL,r=o.add(function(e,t={},i={}){var o;const r=new ge.SL;let s=!1;const a=r.add(new ae.A),l=(0,ne.az)(t),c=function(t){let i;try{i=(0,fe.Q)(decodeURIComponent(t))}catch(e){}return i?(i=(0,be.rs)(i,(t=>e.uris&&e.uris[t]?we.o.revive(e.uris[t]):void 0)),encodeURIComponent(JSON.stringify(i))):t},d=function(t,i){const n=e.uris&&e.uris[t];let o=we.o.revive(n);return i?t.startsWith(_e.lg.data+":")?t:(o||(o=we.o.parse(t)),_e.Gi.asBrowserUri(o).toString(!0)):o?we.o.parse(t).toString()===o.toString()?t:(o.query&&(o=o.with({query:c(o.query)})),o.toString()):t};let u;const h=new Promise((e=>u=e)),g=new me.Renderer;if(g.image=(e,t,i)=>{let n=[],o=[];return e&&(({href:e,dimensions:n}=(0,de.v1)(e)),o.push(`src="${e}"`)),i&&o.push(`alt="${i}"`),t&&o.push(`title="${t}"`),n.length&&(o=o.concat(n)),""},g.link=(t,i,n)=>"string"!=typeof t?"":(t===n&&(n=(0,de.oR)(n)),t=d(t,!1),e.baseUri&&(t=ye(we.o.from(e.baseUri),t)),i="string"==typeof i?(0,de.oR)(i):"",!(t=(0,de.oR)(t))||/^data:|javascript:/i.test(t)||/^command:/i.test(t)&&!e.isTrusted||/^command:(\/\/\/)?_workbench\.downloadResource/i.test(t)?n:`/g,">").replace(/"/g,""").replace(/'/g,"'")}" title="${i||t}">${n}`),g.paragraph=e=>`

          ${e}

          `,t.codeBlockRenderer&&(g.code=(e,i)=>{const o=t.codeBlockRenderer(null!=i?i:"",e),r=he.a.nextId();return(0,se.eP)(Promise.all([o,h]),a.token).then((e=>{var i;if(!s&&e){const o=l.querySelector(`div[data-code="${r}"]`);o&&n.mc(o,e[0]),null===(i=t.asyncRenderCallback)||void 0===i||i.call(t)}})).catch((()=>{})),`
          ${(0,Ce.YU)(e)}
          `}),t.actionHandler){const i=t.actionHandler.disposables.add(new ie.Y(l,"click")),n=t.actionHandler.disposables.add(new ie.Y(l,"auxclick"));t.actionHandler.disposables.add(ce.ju.any(i.event,n.event)((i=>{const n=new oe.n(i);if(!n.leftButton&&!n.middleButton)return;let o=n.target;if("A"===o.tagName||(o=o.parentElement,o&&"A"===o.tagName))try{let i=o.dataset.href;i&&(e.baseUri&&(i=ye(we.o.from(e.baseUri),i)),t.actionHandler.callback(i,n))}catch(e){(0,le.dL)(e)}finally{n.preventDefault()}})))}e.supportHtml||(i.sanitizer=t=>(e.isTrusted?t.match(/^(]+>)|(<\/\s*span>)$/):void 0)?t:"",i.sanitize=!0,i.silent=!0),i.renderer=g;let p=null!==(o=e.value)&&void 0!==o?o:"";p.length>1e5&&(p=`${p.substr(0,1e5)}…`),e.supportThemeIcons&&(p=(0,ue.f$)(p));let m=me.parse(p,i);e.supportThemeIcons&&(m=(0,re.T)(m).map((e=>"string"==typeof e?e:e.outerHTML)).join(""));const f=(new DOMParser).parseFromString(Se(e,m),"text/html");if(f.body.querySelectorAll("img").forEach((t=>{const i=t.getAttribute("src");if(i){let n=i;try{e.baseUri&&(n=ye(we.o.from(e.baseUri),n))}catch(e){}t.src=d(n,!0)}})),l.innerHTML=Se(e,f.body.innerHTML),u(),t.asyncRenderCallback)for(const e of l.getElementsByTagName("img")){const i=r.add(n.nm(e,"load",(()=>{i.dispose(),t.asyncRenderCallback()})))}return{element:l,dispose:()=>{s=!0,a.cancel(),r.dispose()}}}(e,Object.assign(Object.assign({},this._getRenderOptions(e,o)),t),i));return{element:r.element,dispose:()=>o.dispose()}}_getRenderOptions(t,i){return{codeBlockRenderer:(t,i)=>{return n=this,o=void 0,s=function*(){var n,o,r;let s;t?s=this._languageService.getLanguageIdByLanguageName(t):this._options.editor&&(s=null===(n=this._options.editor.getModel())||void 0===n?void 0:n.getLanguageId()),s||(s=De.bd);const a=yield(0,Ee.C2)(this._languageService,i,s),l=document.createElement("span");if(l.innerHTML=null!==(r=null===(o=e._ttpTokenizer)||void 0===o?void 0:o.createHTML(a))&&void 0!==r?r:a,this._options.editor){const e=this._options.editor.getOption(44);(0,Ne.N)(l,e)}else this._options.codeBlockFontFamily&&(l.style.fontFamily=this._options.codeBlockFontFamily);return l},new((r=void 0)||(r=Promise))((function(e,t){function i(e){try{l(s.next(e))}catch(e){t(e)}}function a(e){try{l(s.throw(e))}catch(e){t(e)}}function l(t){var n;t.done?e(t.value):(n=t.value,n instanceof r?n:new r((function(e){e(n)}))).then(i,a)}l((s=s.apply(n,o||[])).next())}));var n,o,r,s},asyncRenderCallback:()=>this._onDidRenderAsync.fire(),actionHandler:{callback:e=>this._openerService.open(e,{fromUserGesture:!0,allowContributedOpeners:!0,allowCommands:t.isTrusted}).catch(le.dL),disposables:i}}}};Te._ttpTokenizer=null===(xe=window.trustedTypes)||void 0===xe?void 0:xe.createPolicy("tokenizeToString",{createHTML:e=>e}),Te=function(e,t,i,n){var o,r=arguments.length,s=r<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,i):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(e,t,i,n);else for(var a=e.length-1;a>=0;a--)(o=e[a])&&(s=(r<3?o(s):r>3?o(t,i,s):o(t,i))||s);return r>3&&s&&Object.defineProperty(t,i,s),s}([Ie(1,Le.O),Ie(2,ke.v4)],Te)},52974:function(e,t,i){"use strict";i.d(t,{O:function(){return x}});var n=i(77339),o=i(40027),r=i(4004),s=i(93379),a=i.n(s),l=i(7795),c=i.n(l),d=i(90569),u=i.n(d),h=i(3565),g=i.n(h),p=i(19216),m=i.n(p),f=i(44589),_=i.n(f),b=i(89009),v={};v.styleTagTransform=_(),v.setAttributes=g(),v.insert=u().bind(null,"head"),v.domAPI=c(),v.insertStyleElement=m(),a()(b.Z,v),b.Z&&b.Z.locals&&b.Z.locals;var C=i(4189),w=i(11465),y=i(89982),S=i(60393);let x=class e{constructor(t,i){this._messageWidget=new r.XK,this._messageListeners=new r.SL,this._editor=t,this._visible=e.MESSAGE_VISIBLE.bindTo(i),this._editorListener=this._editor.onDidAttemptReadOnlyEdit((()=>this._onDidAttemptReadOnlyEdit()))}static get(t){return t.getContribution(e.ID)}dispose(){this._editorListener.dispose(),this._messageListeners.dispose(),this._messageWidget.dispose(),this._visible.reset()}showMessage(e,t){let i;(0,n.Z9)(e),this._visible.set(!0),this._messageWidget.clear(),this._messageListeners.clear(),this._messageWidget.value=new N(this._editor,t,e),this._messageListeners.add(this._editor.onDidBlurEditorText((()=>this.closeMessage()))),this._messageListeners.add(this._editor.onDidChangeCursorPosition((()=>this.closeMessage()))),this._messageListeners.add(this._editor.onDidDispose((()=>this.closeMessage()))),this._messageListeners.add(this._editor.onDidChangeModel((()=>this.closeMessage()))),this._messageListeners.add(new o._F((()=>this.closeMessage()),3e3)),this._messageListeners.add(this._editor.onMouseMove((e=>{e.target.position&&(i?i.containsPosition(e.target.position)||this.closeMessage():i=new w.e(t.lineNumber-3,1,e.target.position.lineNumber+3,1))})))}closeMessage(){this._visible.reset(),this._messageListeners.clear(),this._messageWidget.value&&this._messageListeners.add(N.fadeOut(this._messageWidget.value))}_onDidAttemptReadOnlyEdit(){this._editor.hasModel()&&this.showMessage(y.NC("vs/editor/contrib/message/browser/messageController","editor.readonly","Cannot edit in read-only editor"),this._editor.getPosition())}};var k,L;x.ID="editor.contrib.messageController",x.MESSAGE_VISIBLE=new S.uy("messageVisible",!1,y.NC("vs/editor/contrib/message/browser/messageController","messageVisible","Whether the editor is currently showing an inline message")),x=function(e,t,i,n){var o,r=arguments.length,s=r<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,i):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(e,t,i,n);else for(var a=e.length-1;a>=0;a--)(o=e[a])&&(s=(r<3?o(s):r>3?o(t,i,s):o(t,i))||s);return r>3&&s&&Object.defineProperty(t,i,s),s}([(k=1,L=S.i6,function(e,t){L(e,t,k)})],x);const E=C._l.bindToContribution(x.get);(0,C.fK)(new E({id:"leaveEditorMessage",precondition:x.MESSAGE_VISIBLE,handler:e=>e.closeMessage(),kbOpts:{weight:130,primary:9}}));class N{constructor(e,{lineNumber:t,column:i},n){this.allowEditorOverflow=!0,this.suppressMouseDown=!1,this._editor=e,this._editor.revealLinesInCenterIfOutsideViewport(t,t,0),this._position={lineNumber:t,column:i-1},this._domNode=document.createElement("div"),this._domNode.classList.add("monaco-editor-overlaymessage");const o=document.createElement("div");o.classList.add("anchor","top"),this._domNode.appendChild(o);const r=document.createElement("div");r.classList.add("message"),r.textContent=n,this._domNode.appendChild(r);const s=document.createElement("div");s.classList.add("anchor","below"),this._domNode.appendChild(s),this._editor.addContentWidget(this),this._domNode.classList.add("fadeIn")}static fadeOut(e){let t;const i=()=>{e.dispose(),clearTimeout(t),e.getDomNode().removeEventListener("animationend",i)};return t=setTimeout(i,110),e.getDomNode().addEventListener("animationend",i),e.getDomNode().classList.add("fadeOut"),{dispose:i}}dispose(){this._editor.removeContentWidget(this)}getId(){return"messageoverlay"}getDomNode(){return this._domNode}getPosition(){return{position:this._position,preference:[1,2]}}afterRender(e){this._domNode.classList.toggle("below",2===e)}}(0,C._K)(x.ID,x)},78053:function(e,t,i){"use strict";i.r(t),i.d(t,{AddSelectionToNextFindMatchAction:function(){return T},AddSelectionToPreviousFindMatchAction:function(){return A},CompatChangeAll:function(){return P},InsertCursorAbove:function(){return y},InsertCursorBelow:function(){return S},MoveSelectionToNextFindMatchAction:function(){return R},MoveSelectionToPreviousFindMatchAction:function(){return M},MultiCursorSelectionController:function(){return D},MultiCursorSelectionControllerAction:function(){return I},MultiCursorSession:function(){return N},MultiCursorSessionResult:function(){return E},SelectHighlightsAction:function(){return O},SelectionHighlighter:function(){return B}});var n=i(77339),o=i(40027),r=i(37808),s=i(4004),a=i(4189),l=i(64649),c=i(11465),d=i(59744),u=i(38673),h=i(77324),g=i(25732),p=i(90251),m=i(89982),f=i(3337),_=i(60393),b=i(45164),v=i(81585),C=i(66988);function w(e,t){const i=t.filter((t=>!e.find((e=>e.equals(t)))));if(i.length>=1){const e=i.map((e=>`line ${e.viewState.position.lineNumber} column ${e.viewState.position.column}`)).join(", "),t=1===i.length?m.NC("vs/editor/contrib/multicursor/browser/multicursor","cursorAdded","Cursor added: {0}",e):m.NC("vs/editor/contrib/multicursor/browser/multicursor","cursorsAdded","Cursors added: {0}",e);(0,n.i7)(t)}}class y extends a.R6{constructor(){super({id:"editor.action.insertCursorAbove",label:m.NC("vs/editor/contrib/multicursor/browser/multicursor","mutlicursor.insertAbove","Add Cursor Above"),alias:"Add Cursor Above",precondition:void 0,kbOpts:{kbExpr:u.u.editorTextFocus,primary:2576,linux:{primary:1552,secondary:[3088]},weight:100},menuOpts:{menuId:f.eH.MenubarSelectionMenu,group:"3_multi",title:m.NC("vs/editor/contrib/multicursor/browser/multicursor",{key:"miInsertCursorAbove",comment:["&& denotes a mnemonic"]},"&&Add Cursor Above"),order:2}})}run(e,t,i){if(!t.hasModel())return;let n=!0;i&&!1===i.logicalLine&&(n=!1);const o=t._getViewModel();if(o.cursorConfig.readOnly)return;o.model.pushStackElement();const r=o.getCursorStates();o.setCursorStates(i.source,3,l.P.addCursorUp(o,r,n)),o.revealTopMostCursor(i.source),w(r,o.getCursorStates())}}class S extends a.R6{constructor(){super({id:"editor.action.insertCursorBelow",label:m.NC("vs/editor/contrib/multicursor/browser/multicursor","mutlicursor.insertBelow","Add Cursor Below"),alias:"Add Cursor Below",precondition:void 0,kbOpts:{kbExpr:u.u.editorTextFocus,primary:2578,linux:{primary:1554,secondary:[3090]},weight:100},menuOpts:{menuId:f.eH.MenubarSelectionMenu,group:"3_multi",title:m.NC("vs/editor/contrib/multicursor/browser/multicursor",{key:"miInsertCursorBelow",comment:["&& denotes a mnemonic"]},"A&&dd Cursor Below"),order:3}})}run(e,t,i){if(!t.hasModel())return;let n=!0;i&&!1===i.logicalLine&&(n=!1);const o=t._getViewModel();if(o.cursorConfig.readOnly)return;o.model.pushStackElement();const r=o.getCursorStates();o.setCursorStates(i.source,3,l.P.addCursorDown(o,r,n)),o.revealBottomMostCursor(i.source),w(r,o.getCursorStates())}}class x extends a.R6{constructor(){super({id:"editor.action.insertCursorAtEndOfEachLineSelected",label:m.NC("vs/editor/contrib/multicursor/browser/multicursor","mutlicursor.insertAtEndOfEachLineSelected","Add Cursors to Line Ends"),alias:"Add Cursors to Line Ends",precondition:void 0,kbOpts:{kbExpr:u.u.editorTextFocus,primary:1575,weight:100},menuOpts:{menuId:f.eH.MenubarSelectionMenu,group:"3_multi",title:m.NC("vs/editor/contrib/multicursor/browser/multicursor",{key:"miInsertCursorAtEndOfEachLineSelected",comment:["&& denotes a mnemonic"]},"Add C&&ursors to Line Ends"),order:4}})}getCursorsForSelection(e,t,i){if(!e.isEmpty()){for(let n=e.startLineNumber;n1&&i.push(new d.Y(e.endLineNumber,e.endColumn,e.endLineNumber,e.endColumn))}}run(e,t){if(!t.hasModel())return;const i=t.getModel(),n=t.getSelections(),o=t._getViewModel(),r=o.getCursorStates();let s=[];n.forEach((e=>this.getCursorsForSelection(e,i,s))),s.length>0&&t.setSelections(s),w(r,o.getCursorStates())}}class k extends a.R6{constructor(){super({id:"editor.action.addCursorsToBottom",label:m.NC("vs/editor/contrib/multicursor/browser/multicursor","mutlicursor.addCursorsToBottom","Add Cursors To Bottom"),alias:"Add Cursors To Bottom",precondition:void 0})}run(e,t){if(!t.hasModel())return;const i=t.getSelections(),n=t.getModel().getLineCount();let o=[];for(let e=i[0].startLineNumber;e<=n;e++)o.push(new d.Y(e,i[0].startColumn,e,i[0].endColumn));const r=t._getViewModel(),s=r.getCursorStates();o.length>0&&t.setSelections(o),w(s,r.getCursorStates())}}class L extends a.R6{constructor(){super({id:"editor.action.addCursorsToTop",label:m.NC("vs/editor/contrib/multicursor/browser/multicursor","mutlicursor.addCursorsToTop","Add Cursors To Top"),alias:"Add Cursors To Top",precondition:void 0})}run(e,t){if(!t.hasModel())return;const i=t.getSelections();let n=[];for(let e=i[0].startLineNumber;e>=1;e--)n.push(new d.Y(e,i[0].startColumn,e,i[0].endColumn));const o=t._getViewModel(),r=o.getCursorStates();n.length>0&&t.setSelections(n),w(r,o.getCursorStates())}}class E{constructor(e,t,i){this.selections=e,this.revealRange=t,this.revealScrollType=i}}class N{constructor(e,t,i,n,o,r,s){this._editor=e,this.findController=t,this.isDisconnectedFromFindController=i,this.searchText=n,this.wholeWord=o,this.matchCase=r,this.currentMatch=s}static create(e,t){if(!e.hasModel())return null;const i=t.getState();if(!e.hasTextFocus()&&i.isRevealed&&i.searchString.length>0)return new N(e,t,!1,i.searchString,i.wholeWord,i.matchCase,null);let n,o,r=!1;const s=e.getSelections();1===s.length&&s[0].isEmpty()?(r=!0,n=!0,o=!0):(n=i.wholeWord,o=i.matchCase);const a=e.getSelection();let l,c=null;if(a.isEmpty()){const t=e.getConfiguredWordAtPosition(a.getStartPosition());if(!t)return null;l=t.word,c=new d.Y(a.startLineNumber,t.startColumn,a.startLineNumber,t.endColumn)}else l=e.getModel().getValueInRange(a).replace(/\r\n/g,"\n");return new N(e,t,r,l,n,o,c)}addSelectionToNextFindMatch(){if(!this._editor.hasModel())return null;const e=this._getNextMatch();if(!e)return null;const t=this._editor.getSelections();return new E(t.concat(e),e,0)}moveSelectionToNextFindMatch(){if(!this._editor.hasModel())return null;const e=this._getNextMatch();if(!e)return null;const t=this._editor.getSelections();return new E(t.slice(0,t.length-1).concat(e),e,0)}_getNextMatch(){if(!this._editor.hasModel())return null;if(this.currentMatch){const e=this.currentMatch;return this.currentMatch=null,e}this.findController.highlightFindOptions();const e=this._editor.getSelections(),t=e[e.length-1],i=this._editor.getModel().findNextMatch(this.searchText,t.getEndPosition(),!1,this.matchCase,this.wholeWord?this._editor.getOption(117):null,!1);return i?new d.Y(i.range.startLineNumber,i.range.startColumn,i.range.endLineNumber,i.range.endColumn):null}addSelectionToPreviousFindMatch(){if(!this._editor.hasModel())return null;const e=this._getPreviousMatch();if(!e)return null;const t=this._editor.getSelections();return new E(t.concat(e),e,0)}moveSelectionToPreviousFindMatch(){if(!this._editor.hasModel())return null;const e=this._getPreviousMatch();if(!e)return null;const t=this._editor.getSelections();return new E(t.slice(0,t.length-1).concat(e),e,0)}_getPreviousMatch(){if(!this._editor.hasModel())return null;if(this.currentMatch){const e=this.currentMatch;return this.currentMatch=null,e}this.findController.highlightFindOptions();const e=this._editor.getSelections(),t=e[e.length-1],i=this._editor.getModel().findPreviousMatch(this.searchText,t.getStartPosition(),!1,this.matchCase,this.wholeWord?this._editor.getOption(117):null,!1);return i?new d.Y(i.range.startLineNumber,i.range.startColumn,i.range.endLineNumber,i.range.endColumn):null}selectAll(){return this._editor.hasModel()?(this.findController.highlightFindOptions(),this._editor.getModel().findMatches(this.searchText,!0,!1,this.matchCase,this.wholeWord?this._editor.getOption(117):null,!1,1073741824)):[]}}class D extends s.JT{constructor(e){super(),this._sessionDispose=this._register(new s.SL),this._editor=e,this._ignoreSelectionChange=!1,this._session=null}static get(e){return e.getContribution(D.ID)}dispose(){this._endSession(),super.dispose()}_beginSessionIfNeeded(e){if(!this._session){const t=N.create(this._editor,e);if(!t)return;this._session=t;const i={searchString:this._session.searchText};this._session.isDisconnectedFromFindController&&(i.wholeWordOverride=1,i.matchCaseOverride=1,i.isRegexOverride=2),e.getState().change(i,!1),this._sessionDispose.add(this._editor.onDidChangeCursorSelection((e=>{this._ignoreSelectionChange||this._endSession()}))),this._sessionDispose.add(this._editor.onDidBlurEditorText((()=>{this._endSession()}))),this._sessionDispose.add(e.getState().onFindReplaceStateChange((e=>{(e.matchCase||e.wholeWord)&&this._endSession()})))}}_endSession(){if(this._sessionDispose.clear(),this._session&&this._session.isDisconnectedFromFindController){const e={wholeWordOverride:0,matchCaseOverride:0,isRegexOverride:0};this._session.findController.getState().change(e,!1)}this._session=null}_setSelections(e){this._ignoreSelectionChange=!0,this._editor.setSelections(e),this._ignoreSelectionChange=!1}_expandEmptyToWord(e,t){if(!t.isEmpty())return t;const i=this._editor.getConfiguredWordAtPosition(t.getStartPosition());return i?new d.Y(t.startLineNumber,i.startColumn,t.startLineNumber,i.endColumn):t}_applySessionResult(e){e&&(this._setSelections(e.selections),e.revealRange&&this._editor.revealRangeInCenterIfOutsideViewport(e.revealRange,e.revealScrollType))}getSession(e){return this._session}addSelectionToNextFindMatch(e){if(this._editor.hasModel()){if(!this._session){const t=this._editor.getSelections();if(t.length>1){const i=e.getState().matchCase;if(!W(this._editor.getModel(),t,i)){const e=this._editor.getModel();let i=[];for(let n=0,o=t.length;n0&&i.isRegex)t=this._editor.getModel().findMatches(i.searchString,!0,i.isRegex,i.matchCase,i.wholeWord?this._editor.getOption(117):null,!1,1073741824);else{if(this._beginSessionIfNeeded(e),!this._session)return;t=this._session.selectAll()}if(i.searchScope){const e=i.searchScope;let n=[];t.forEach((t=>{e.forEach((e=>{t.range.endLineNumber<=e.endLineNumber&&t.range.startLineNumber>=e.startLineNumber&&n.push(t)}))})),t=n}if(t.length>0){const e=this._editor.getSelection();for(let i=0,n=t.length;inew d.Y(e.range.startLineNumber,e.range.startColumn,e.range.endLineNumber,e.range.endColumn))))}}}D.ID="editor.contrib.multiCursorController";class I extends a.R6{run(e,t){const i=D.get(t);if(!i)return;const n=p.CommonFindController.get(t);if(!n)return;const o=t._getViewModel();if(o){const e=o.getCursorStates();this._run(i,n),w(e,o.getCursorStates())}}}class T extends I{constructor(){super({id:"editor.action.addSelectionToNextFindMatch",label:m.NC("vs/editor/contrib/multicursor/browser/multicursor","addSelectionToNextFindMatch","Add Selection To Next Find Match"),alias:"Add Selection To Next Find Match",precondition:void 0,kbOpts:{kbExpr:u.u.focus,primary:2082,weight:100},menuOpts:{menuId:f.eH.MenubarSelectionMenu,group:"3_multi",title:m.NC("vs/editor/contrib/multicursor/browser/multicursor",{key:"miAddSelectionToNextFindMatch",comment:["&& denotes a mnemonic"]},"Add &&Next Occurrence"),order:5}})}_run(e,t){e.addSelectionToNextFindMatch(t)}}class A extends I{constructor(){super({id:"editor.action.addSelectionToPreviousFindMatch",label:m.NC("vs/editor/contrib/multicursor/browser/multicursor","addSelectionToPreviousFindMatch","Add Selection To Previous Find Match"),alias:"Add Selection To Previous Find Match",precondition:void 0,menuOpts:{menuId:f.eH.MenubarSelectionMenu,group:"3_multi",title:m.NC("vs/editor/contrib/multicursor/browser/multicursor",{key:"miAddSelectionToPreviousFindMatch",comment:["&& denotes a mnemonic"]},"Add P&&revious Occurrence"),order:6}})}_run(e,t){e.addSelectionToPreviousFindMatch(t)}}class R extends I{constructor(){super({id:"editor.action.moveSelectionToNextFindMatch",label:m.NC("vs/editor/contrib/multicursor/browser/multicursor","moveSelectionToNextFindMatch","Move Last Selection To Next Find Match"),alias:"Move Last Selection To Next Find Match",precondition:void 0,kbOpts:{kbExpr:u.u.focus,primary:(0,r.gx)(2089,2082),weight:100}})}_run(e,t){e.moveSelectionToNextFindMatch(t)}}class M extends I{constructor(){super({id:"editor.action.moveSelectionToPreviousFindMatch",label:m.NC("vs/editor/contrib/multicursor/browser/multicursor","moveSelectionToPreviousFindMatch","Move Last Selection To Previous Find Match"),alias:"Move Last Selection To Previous Find Match",precondition:void 0})}_run(e,t){e.moveSelectionToPreviousFindMatch(t)}}class O extends I{constructor(){super({id:"editor.action.selectHighlights",label:m.NC("vs/editor/contrib/multicursor/browser/multicursor","selectAllOccurrencesOfFindMatch","Select All Occurrences of Find Match"),alias:"Select All Occurrences of Find Match",precondition:void 0,kbOpts:{kbExpr:u.u.focus,primary:3114,weight:100},menuOpts:{menuId:f.eH.MenubarSelectionMenu,group:"3_multi",title:m.NC("vs/editor/contrib/multicursor/browser/multicursor",{key:"miSelectHighlights",comment:["&& denotes a mnemonic"]},"Select All &&Occurrences"),order:7}})}_run(e,t){e.selectAll(t)}}class P extends I{constructor(){super({id:"editor.action.changeAll",label:m.NC("vs/editor/contrib/multicursor/browser/multicursor","changeAll.label","Change All Occurrences"),alias:"Change All Occurrences",precondition:_.Ao.and(u.u.writable,u.u.editorTextFocus),kbOpts:{kbExpr:u.u.editorTextFocus,primary:2108,weight:100},contextMenuOpts:{group:"1_modification",order:1.2}})}_run(e,t){e.selectAll(t)}}class F{constructor(e,t,i,n,o){this._model=e,this._searchText=t,this._matchCase=i,this._wordSeparators=n,this._modelVersionId=this._model.getVersionId(),this._cachedFindMatches=null,o&&this._model===o._model&&this._searchText===o._searchText&&this._matchCase===o._matchCase&&this._wordSeparators===o._wordSeparators&&this._modelVersionId===o._modelVersionId&&(this._cachedFindMatches=o._cachedFindMatches)}findMatches(){return null===this._cachedFindMatches&&(this._cachedFindMatches=this._model.findMatches(this._searchText,!0,!1,this._matchCase,this._wordSeparators,!1).map((e=>e.range)),this._cachedFindMatches.sort(c.e.compareRangesUsingStarts)),this._cachedFindMatches}}let B=class e extends s.JT{constructor(e,t){super(),this._languageFeaturesService=t,this.editor=e,this._isEnabled=e.getOption(97),this.decorations=[],this.updateSoon=this._register(new o.pY((()=>this._update()),300)),this.state=null,this._register(e.onDidChangeConfiguration((t=>{this._isEnabled=e.getOption(97)}))),this._register(e.onDidChangeCursorSelection((e=>{this._isEnabled&&(e.selection.isEmpty()?3===e.reason?(this.state&&this._setState(null),this.updateSoon.schedule()):this._setState(null):this._update())}))),this._register(e.onDidChangeModel((e=>{this._setState(null)}))),this._register(e.onDidChangeModelContent((e=>{this._isEnabled&&this.updateSoon.schedule()})));const i=p.CommonFindController.get(e);i&&this._register(i.getState().onFindReplaceStateChange((e=>{this._update()})))}_update(){this._setState(e._createState(this.state,this._isEnabled,this.editor))}static _createState(e,t,i){if(!t)return null;if(!i.hasModel())return null;const n=i.getSelection();if(n.startLineNumber!==n.endLineNumber)return null;const o=D.get(i);if(!o)return null;const r=p.CommonFindController.get(i);if(!r)return null;let s=o.getSession(r);if(!s){const e=i.getSelections();if(e.length>1){const t=r.getState().matchCase;if(!W(i.getModel(),e,t))return null}s=N.create(i,r)}if(!s)return null;if(s.currentMatch)return null;if(/^[ \t]+$/.test(s.searchText))return null;if(s.searchText.length>200)return null;const a=r.getState(),l=a.matchCase;if(a.isRevealed){let e=a.searchString;l||(e=e.toLowerCase());let t=s.searchText;if(l||(t=t.toLowerCase()),e===t&&s.matchCase===a.matchCase&&s.wholeWord===a.wholeWord&&!a.isRegex)return null}return new F(i.getModel(),s.searchText,s.matchCase,s.wholeWord?i.getOption(117):null,e)}_setState(t){if(this.state=t,!this.state)return void(this.decorations=this.editor.deltaDecorations(this.decorations,[]));if(!this.editor.hasModel())return;const i=this.editor.getModel();if(i.isTooLargeForTokenization())return;const n=this.state.findMatches(),o=this.editor.getSelections();o.sort(c.e.compareRangesUsingStarts);const r=[];for(let e=0,t=0,i=n.length,s=o.length;e=s)r.push(i),e++;else{const n=c.e.compareRangesUsingStarts(i,o[t]);n<0?(!o[t].isEmpty()&&c.e.areIntersecting(i,o[t])||r.push(i),e++):(n>0||e++,t++)}}const s=this._languageFeaturesService.documentHighlightProvider.has(i)&&this.editor.getOption(72),a=r.map((t=>({range:t,options:s?e._SELECTION_HIGHLIGHT:e._SELECTION_HIGHLIGHT_OVERVIEW})));this.decorations=this.editor.deltaDecorations(this.decorations,a)}dispose(){this._setState(null),super.dispose()}};function W(e,t,i){const n=V(e,t[0],!i);for(let o=1,r=t.length;o=0;a--)(o=e[a])&&(s=(r<3?o(s):r>3?o(t,i,s):o(t,i))||s);return r>3&&s&&Object.defineProperty(t,i,s),s}([(H=1,z=C.p,function(e,t){z(e,t,H)})],B),(0,a._K)(D.ID,D),(0,a._K)(B.ID,B),(0,a.Qr)(y),(0,a.Qr)(S),(0,a.Qr)(x),(0,a.Qr)(T),(0,a.Qr)(A),(0,a.Qr)(R),(0,a.Qr)(M),(0,a.Qr)(O),(0,a.Qr)(P),(0,a.Qr)(k),(0,a.Qr)(L)},99966:function(e,t,i){"use strict";i.r(t),i.d(t,{TriggerParameterHintsAction:function(){return le}});var n=i(4004),o=i(4189),r=i(38673),s=i(74893),a=i(60677),l=i(16182),c=i(28295),d=i(39675),u=i(72248),h=i(20010),g=i(14756),p=i(60393),m=i(66988),f=function(e,t,i,n){return new(i||(i=Promise))((function(o,r){function s(e){try{l(n.next(e))}catch(e){r(e)}}function a(e){try{l(n.throw(e))}catch(e){r(e)}}function l(e){var t;e.done?o(e.value):(t=e.value,t instanceof i?t:new i((function(e){e(t)}))).then(s,a)}l((n=n.apply(e,t||[])).next())}))};const _={Visible:new p.uy("parameterHintsVisible",!1),MultipleSignatures:new p.uy("parameterHintsMultipleSignatures",!1)};function b(e,t,i,n,o){return f(this,void 0,void 0,(function*(){const r=e.ordered(t);for(const e of r)try{const r=yield e.provideSignatureHelp(t,i,o,n);if(r)return r}catch(e){(0,l.Cp)(e)}}))}g.P0.registerCommand("_executeSignatureHelpProvider",((e,...t)=>f(void 0,void 0,void 0,(function*(){const[i,n,o]=t;(0,c.p_)(d.o.isUri(i)),(0,c.p_)(u.L.isIPosition(n)),(0,c.p_)("string"==typeof o||!o);const r=e.get(m.p),l=yield e.get(h.S).createModelReference(i);try{const e=yield b(r.signatureHelpProvider,l.object.textEditorModel,u.L.lift(n),{triggerKind:s.WW.Invoke,isRetrigger:!1,triggerCharacter:o},a.T.None);if(!e)return;return setTimeout((()=>e.dispose()),0),e.value}finally{l.dispose()}}))));var v=i(89982),C=i(12260),w=i(68695),y=i(77339),S=i(98677),x=i(4821),k=i(46718),L=i(18039),E=i(93379),N=i.n(E),D=i(7795),I=i.n(D),T=i(90569),A=i.n(T),R=i(3565),M=i.n(R),O=i(19216),P=i.n(O),F=i(44589),B=i.n(F),W=i(88846),V={};V.styleTagTransform=B(),V.setAttributes=M(),V.insert=A().bind(null,"head"),V.domAPI=I(),V.insertStyleElement=P(),N()(W.Z,V),W.Z&&W.Z.locals&&W.Z.locals;var H,z=i(72956),$=i(10940),U=i(40027),j=i(93423);!function(e){e.Default={type:0},e.Pending=class{constructor(e,t){this.request=e,this.previouslyActiveHints=t,this.type=2}},e.Active=class{constructor(e){this.hints=e,this.type=1}}}(H||(H={}));class K extends n.JT{constructor(e,t,i=K.DEFAULT_DELAY){super(),this._onChangedHints=this._register(new k.Q5),this.onChangedHints=this._onChangedHints.event,this.triggerOnType=!1,this._state=H.Default,this._pendingTriggers=[],this._lastSignatureHelpResult=this._register(new n.XK),this.triggerChars=new j.q,this.retriggerChars=new j.q,this.triggerId=0,this.editor=e,this.providers=t,this.throttledDelayer=new U.vp(i),this._register(this.editor.onDidBlurEditorWidget((()=>this.cancel()))),this._register(this.editor.onDidChangeConfiguration((()=>this.onEditorConfigurationChange()))),this._register(this.editor.onDidChangeModel((e=>this.onModelChanged()))),this._register(this.editor.onDidChangeModelLanguage((e=>this.onModelChanged()))),this._register(this.editor.onDidChangeCursorSelection((e=>this.onCursorChange(e)))),this._register(this.editor.onDidChangeModelContent((e=>this.onModelContentChange()))),this._register(this.providers.onDidChange(this.onModelChanged,this)),this._register(this.editor.onDidType((e=>this.onDidType(e)))),this.onEditorConfigurationChange(),this.onModelChanged()}get state(){return this._state}set state(e){2===this._state.type&&this._state.request.cancel(),this._state=e}cancel(e=!1){this.state=H.Default,this.throttledDelayer.cancel(),e||this._onChangedHints.fire(void 0)}trigger(e,t){const i=this.editor.getModel();if(!i||!this.providers.has(i))return;const n=++this.triggerId;this._pendingTriggers.push(e),this.throttledDelayer.trigger((()=>this.doTrigger(n)),t).catch(l.dL)}next(){if(1!==this.state.type)return;const e=this.state.hints.signatures.length,t=this.state.hints.activeSignature,i=t%e==e-1,n=this.editor.getOption(76).cycle;!(e<2||i)||n?this.updateActiveSignature(i&&n?0:t+1):this.cancel()}previous(){if(1!==this.state.type)return;const e=this.state.hints.signatures.length,t=this.state.hints.activeSignature,i=0===t,n=this.editor.getOption(76).cycle;!(e<2||i)||n?this.updateActiveSignature(i&&n?e-1:t-1):this.cancel()}updateActiveSignature(e){1===this.state.type&&(this.state=new H.Active(Object.assign(Object.assign({},this.state.hints),{activeSignature:e})),this._onChangedHints.fire(this.state.hints))}doTrigger(e){return t=this,i=void 0,o=function*(){const t=1===this.state.type||2===this.state.type,i=this.getLastActiveHints();if(this.cancel(!0),0===this._pendingTriggers.length)return!1;const n=this._pendingTriggers.reduce(q);this._pendingTriggers=[];const o={triggerKind:n.triggerKind,triggerCharacter:n.triggerCharacter,isRetrigger:t,activeSignatureHelp:i};if(!this.editor.hasModel())return!1;const r=this.editor.getModel(),s=this.editor.getPosition();this.state=new H.Pending((0,U.PG)((e=>b(this.providers,r,s,o,e))),i);try{const t=yield this.state.request;return e!==this.triggerId?(null==t||t.dispose(),!1):t&&t.value.signatures&&0!==t.value.signatures.length?(this.state=new H.Active(t.value),this._lastSignatureHelpResult.value=t,this._onChangedHints.fire(this.state.hints),!0):(null==t||t.dispose(),this._lastSignatureHelpResult.clear(),this.cancel(),!1)}catch(t){return e===this.triggerId&&(this.state=H.Default),(0,l.dL)(t),!1}},new((n=void 0)||(n=Promise))((function(e,r){function s(e){try{l(o.next(e))}catch(e){r(e)}}function a(e){try{l(o.throw(e))}catch(e){r(e)}}function l(t){var i;t.done?e(t.value):(i=t.value,i instanceof n?i:new n((function(e){e(i)}))).then(s,a)}l((o=o.apply(t,i||[])).next())}));var t,i,n,o}getLastActiveHints(){switch(this.state.type){case 1:return this.state.hints;case 2:return this.state.previouslyActiveHints;default:return}}get isTriggered(){return 1===this.state.type||2===this.state.type||this.throttledDelayer.isTriggered()}onModelChanged(){this.cancel(),this.triggerChars=new j.q,this.retriggerChars=new j.q;const e=this.editor.getModel();if(e)for(const t of this.providers.ordered(e)){for(const e of t.signatureHelpTriggerCharacters||[])this.triggerChars.add(e.charCodeAt(0)),this.retriggerChars.add(e.charCodeAt(0));for(const e of t.signatureHelpRetriggerCharacters||[])this.retriggerChars.add(e.charCodeAt(0))}}onDidType(e){if(!this.triggerOnType)return;const t=e.length-1,i=e.charCodeAt(t);(this.triggerChars.has(i)||this.isTriggered&&this.retriggerChars.has(i))&&this.trigger({triggerKind:s.WW.TriggerCharacter,triggerCharacter:e.charAt(t)})}onCursorChange(e){"mouse"===e.source?this.cancel():this.isTriggered&&this.trigger({triggerKind:s.WW.ContentChange})}onModelContentChange(){this.isTriggered&&this.trigger({triggerKind:s.WW.ContentChange})}onEditorConfigurationChange(){this.triggerOnType=this.editor.getOption(76).enabled,this.triggerOnType||this.cancel()}dispose(){this.cancel(!0),super.dispose()}}function q(e,t){switch(t.triggerKind){case s.WW.Invoke:return t;case s.WW.ContentChange:return e;case s.WW.TriggerCharacter:default:return t}}K.DEFAULT_DELAY=120;var G=i(82523),Z=i(45164),Y=i(26181),Q=i(14540),X=i(81585),J=function(e,t){return function(i,n){t(i,n,e)}};const ee=w.$,te=(0,Y.q5)("parameter-hints-next",x.lA.chevronDown,v.NC("vs/editor/contrib/parameterHints/browser/parameterHintsWidget","parameterHintsNextIcon","Icon for show next parameter hint.")),ie=(0,Y.q5)("parameter-hints-previous",x.lA.chevronUp,v.NC("vs/editor/contrib/parameterHints/browser/parameterHintsWidget","parameterHintsPreviousIcon","Icon for show previous parameter hint."));let ne=class e extends n.JT{constructor(e,t,i,o,r){super(),this.editor=e,this.renderDisposeables=this._register(new n.SL),this.visible=!1,this.announcedLabel=null,this.allowEditorOverflow=!0,this.markdownRenderer=this._register(new z.$({editor:e},o,i)),this.model=this._register(new K(e,r.signatureHelpProvider)),this.keyVisible=_.Visible.bindTo(t),this.keyMultipleSignatures=_.MultipleSignatures.bindTo(t),this._register(this.model.onChangedHints((e=>{e?(this.show(),this.render(e)):this.hide()})))}createParameterHintDOMNodes(){const e=ee(".editor-widget.parameter-hints-widget"),t=w.R3(e,ee(".phwrapper"));t.tabIndex=-1;const i=w.R3(t,ee(".controls")),n=w.R3(i,ee(".button"+X.kS.asCSSSelector(ie))),o=w.R3(i,ee(".overloads")),r=w.R3(i,ee(".button"+X.kS.asCSSSelector(te)));this._register(w.nm(n,"click",(e=>{w.zB.stop(e),this.previous()}))),this._register(w.nm(r,"click",(e=>{w.zB.stop(e),this.next()})));const s=ee(".body"),a=new S.s$(s,{});this._register(a),t.appendChild(a.getDomNode());const l=w.R3(s,ee(".signature")),c=w.R3(s,ee(".docs"));e.style.userSelect="text",this.domNodes={element:e,signature:l,overloads:o,docs:c,scrollbar:a},this.editor.addContentWidget(this),this.hide(),this._register(this.editor.onDidChangeCursorSelection((e=>{this.visible&&this.editor.layoutContentWidget(this)})));const d=()=>{if(!this.domNodes)return;const e=this.editor.getOption(44);this.domNodes.element.style.fontSize=`${e.fontSize}px`,this.domNodes.element.style.lineHeight=""+e.lineHeight/e.fontSize};d(),this._register(k.ju.chain(this.editor.onDidChangeConfiguration.bind(this.editor)).filter((e=>e.hasChanged(44))).on(d,null)),this._register(this.editor.onDidLayoutChange((e=>this.updateMaxHeight()))),this.updateMaxHeight()}show(){this.visible||(this.domNodes||this.createParameterHintDOMNodes(),this.keyVisible.set(!0),this.visible=!0,setTimeout((()=>{this.domNodes&&this.domNodes.element.classList.add("visible")}),100),this.editor.layoutContentWidget(this))}hide(){this.renderDisposeables.clear(),this.visible&&(this.keyVisible.reset(),this.visible=!1,this.announcedLabel=null,this.domNodes&&this.domNodes.element.classList.remove("visible"),this.editor.layoutContentWidget(this))}getPosition(){return this.visible?{position:this.editor.getPosition(),preference:[1,2]}:null}render(e){var t;if(this.renderDisposeables.clear(),!this.domNodes)return;const i=e.signatures.length>1;this.domNodes.element.classList.toggle("multiple",i),this.keyMultipleSignatures.set(i),this.domNodes.signature.innerText="",this.domNodes.docs.innerText="";const n=e.signatures[e.activeSignature];if(!n)return;const o=w.R3(this.domNodes.signature,ee(".code")),r=this.editor.getOption(44);o.style.fontSize=`${r.fontSize}px`,o.style.fontFamily=r.fontFamily;const s=n.parameters.length>0,a=null!==(t=n.activeParameter)&&void 0!==t?t:e.activeParameter;s?this.renderParameters(o,n,a):w.R3(o,ee("span")).textContent=n.label;const l=n.parameters[a];if(null==l?void 0:l.documentation){const e=ee("span.documentation");if("string"==typeof l.documentation)e.textContent=l.documentation;else{const t=this.renderMarkdownDocs(l.documentation);e.appendChild(t.element)}w.R3(this.domNodes.docs,ee("p",{},e))}if(void 0===n.documentation);else if("string"==typeof n.documentation)w.R3(this.domNodes.docs,ee("p",{},n.documentation));else{const e=this.renderMarkdownDocs(n.documentation);w.R3(this.domNodes.docs,e.element)}const c=this.hasDocs(n,l);if(this.domNodes.signature.classList.toggle("has-docs",c),this.domNodes.docs.classList.toggle("empty",!c),this.domNodes.overloads.textContent=String(e.activeSignature+1).padStart(e.signatures.length.toString().length,"0")+"/"+e.signatures.length,l){let e="";const t=n.parameters[a];e=Array.isArray(t.label)?n.label.substring(t.label[0],t.label[1]):t.label,t.documentation&&(e+="string"==typeof t.documentation?`, ${t.documentation}`:`, ${t.documentation.value}`),n.documentation&&(e+="string"==typeof n.documentation?`, ${n.documentation}`:`, ${n.documentation.value}`),this.announcedLabel!==e&&(y.Z9(v.NC("vs/editor/contrib/parameterHints/browser/parameterHintsWidget","hint","{0}, hint",e)),this.announcedLabel=e)}this.editor.layoutContentWidget(this),this.domNodes.scrollbar.scanDomNode()}renderMarkdownDocs(e){const t=this.renderDisposeables.add(this.markdownRenderer.render(e,{asyncRenderCallback:()=>{var e;null===(e=this.domNodes)||void 0===e||e.scrollbar.scanDomNode()}}));return t.element.classList.add("markdown-docs"),t}hasDocs(e,t){return!!(t&&"string"==typeof t.documentation&&(0,c.cW)(t.documentation).length>0||t&&"object"==typeof t.documentation&&(0,c.cW)(t.documentation).value.length>0||e.documentation&&"string"==typeof e.documentation&&(0,c.cW)(e.documentation).length>0||e.documentation&&"object"==typeof e.documentation&&(0,c.cW)(e.documentation.value).length>0)}renderParameters(e,t,i){const[n,o]=this.getParameterLabelOffsets(t,i),r=document.createElement("span");r.textContent=t.label.substring(0,n);const s=document.createElement("span");s.textContent=t.label.substring(n,o),s.className="parameter active";const a=document.createElement("span");a.textContent=t.label.substring(o),w.R3(e,r,s,a)}getParameterLabelOffsets(e,t){const i=e.parameters[t];if(i){if(Array.isArray(i.label))return i.label;if(i.label.length){const t=new RegExp(`(\\W|^)${(0,L.ec)(i.label)}(?=\\W|$)`,"g");t.test(e.label);const n=t.lastIndex-i.label.length;return n>=0?[n,t.lastIndex]:[0,0]}return[0,0]}return[0,0]}next(){this.editor.focus(),this.model.next()}previous(){this.editor.focus(),this.model.previous()}cancel(){this.model.cancel()}getDomNode(){return this.domNodes||this.createParameterHintDOMNodes(),this.domNodes.element}getId(){return e.ID}trigger(e){this.model.trigger(e,0)}updateMaxHeight(){if(!this.domNodes)return;const e=`${Math.max(this.editor.getLayoutInfo().height/4,250)}px`;this.domNodes.element.style.maxHeight=e;const t=this.domNodes.element.getElementsByClassName("phwrapper");t.length&&(t[0].style.maxHeight=e)}};ne.ID="editor.widget.parameterHintsWidget",ne=function(e,t,i,n){var o,r=arguments.length,s=r<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,i):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(e,t,i,n);else for(var a=e.length-1;a>=0;a--)(o=e[a])&&(s=(r<3?o(s):r>3?o(t,i,s):o(t,i))||s);return r>3&&s&&Object.defineProperty(t,i,s),s}([J(1,p.i6),J(2,G.v4),J(3,$.O),J(4,m.p)],ne);const oe=(0,Z.P6G)("editorHoverWidget.highlightForeground",{dark:Z.Gwp,light:Z.Gwp,hc:Z.Gwp},v.NC("vs/editor/contrib/parameterHints/browser/parameterHintsWidget","editorHoverWidgetHighlightForeground","Foreground color of the active item in the parameter hint."));(0,X.Ic)(((e,t)=>{const i=e.getColor(Z.CNo);if(i){const n=e.type===Q.e.HIGH_CONTRAST?2:1;t.addRule(`.monaco-editor .parameter-hints-widget { border: ${n}px solid ${i}; }`),t.addRule(`.monaco-editor .parameter-hints-widget.multiple .body { border-left: 1px solid ${i.transparent(.5)}; }`),t.addRule(`.monaco-editor .parameter-hints-widget .signature.has-docs { border-bottom: 1px solid ${i.transparent(.5)}; }`)}const n=e.getColor(Z.yJx);n&&t.addRule(`.monaco-editor .parameter-hints-widget { background-color: ${n}; }`);const o=e.getColor(Z.url);o&&t.addRule(`.monaco-editor .parameter-hints-widget a { color: ${o}; }`);const r=e.getColor(Z.sgC);r&&t.addRule(`.monaco-editor .parameter-hints-widget a:hover { color: ${r}; }`);const s=e.getColor(Z.Sbf);s&&t.addRule(`.monaco-editor .parameter-hints-widget { color: ${s}; }`);const a=e.getColor(Z.SwI);a&&t.addRule(`.monaco-editor .parameter-hints-widget code { background-color: ${a}; }`);const l=e.getColor(oe);l&&t.addRule(`.monaco-editor .parameter-hints-widget .parameter.active { color: ${l}}`)}));let re=class e extends n.JT{constructor(e,t){super(),this.editor=e,this.widget=this._register(t.createInstance(ne,this.editor))}static get(t){return t.getContribution(e.ID)}cancel(){this.widget.cancel()}previous(){this.widget.previous()}next(){this.widget.next()}trigger(e){this.widget.trigger(e)}};var se,ae;re.ID="editor.controller.parameterHints",re=function(e,t,i,n){var o,r=arguments.length,s=r<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,i):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(e,t,i,n);else for(var a=e.length-1;a>=0;a--)(o=e[a])&&(s=(r<3?o(s):r>3?o(t,i,s):o(t,i))||s);return r>3&&s&&Object.defineProperty(t,i,s),s}([(se=1,ae=C.TG,function(e,t){ae(e,t,se)})],re);class le extends o.R6{constructor(){super({id:"editor.action.triggerParameterHints",label:v.NC("vs/editor/contrib/parameterHints/browser/parameterHints","parameterHints.trigger.label","Trigger Parameter Hints"),alias:"Trigger Parameter Hints",precondition:r.u.hasSignatureHelpProvider,kbOpts:{kbExpr:r.u.editorTextFocus,primary:3082,weight:100}})}run(e,t){const i=re.get(t);i&&i.trigger({triggerKind:s.WW.Invoke})}}(0,o._K)(re.ID,re),(0,o.Qr)(le);const ce=o._l.bindToContribution(re.get);(0,o.fK)(new ce({id:"closeParameterHints",precondition:_.Visible,handler:e=>e.cancel(),kbOpts:{weight:175,kbExpr:r.u.focus,primary:9,secondary:[1033]}})),(0,o.fK)(new ce({id:"showPrevParameterHint",precondition:p.Ao.and(_.Visible,_.MultipleSignatures),handler:e=>e.previous(),kbOpts:{weight:175,kbExpr:r.u.focus,primary:16,secondary:[528],mac:{primary:16,secondary:[528,302]}}})),(0,o.fK)(new ce({id:"showNextParameterHint",precondition:p.Ao.and(_.Visible,_.MultipleSignatures),handler:e=>e.next(),kbOpts:{weight:175,kbExpr:r.u.focus,primary:18,secondary:[530],mac:{primary:18,secondary:[530,300]}}}))},13919:function(e,t,i){"use strict";i.d(t,{Fw:function(){return q},Jy:function(){return G},vk:function(){return X},rc:function(){return Y},SC:function(){return ie},M8:function(){return ne},KY:function(){return J},IH:function(){return ee},R7:function(){return te}});var n=i(68695),o=i(47995),r=i(11007),s=i(4821),a=i(18689),l=i(46718),c=i(90584),d=i(93379),u=i.n(d),h=i(7795),g=i.n(h),p=i(90569),m=i.n(p),f=i(3565),_=i.n(f),b=i(19216),v=i.n(b),C=i(44589),w=i.n(C),y=i(66458),S={};S.styleTagTransform=w(),S.setAttributes=_(),S.insert=m().bind(null,"head"),S.domAPI=g(),S.insertStyleElement=v(),u()(y.Z,S),y.Z&&y.Z.locals&&y.Z.locals;var x=i(4189),k=i(3622),L=i(9709),E=i(71036),N=i(68332),D=i(4004),I=i(75853),T={};T.styleTagTransform=w(),T.setAttributes=_(),T.insert=m().bind(null,"head"),T.domAPI=g(),T.insertStyleElement=v(),u()(I.Z,T),I.Z&&I.Z.locals&&I.Z.locals;var A=i(11465),R=i(25732);const M=new a.Il(new a.VS(0,122,204)),O={showArrow:!0,showFrame:!0,className:"",frameColor:M,arrowColor:M,keepEditorSelection:!1};class P{constructor(e,t,i,n,o,r){this.id="",this.domNode=e,this.afterLineNumber=t,this.afterColumn=i,this.heightInLines=n,this._onDomNodeTop=o,this._onComputedHeight=r}onDomNodeTop(e){this._onDomNodeTop(e)}onComputedHeight(e){this._onComputedHeight(e)}}class F{constructor(e,t){this._id=e,this._domNode=t}getId(){return this._id}getDomNode(){return this._domNode}getPosition(){return null}}class B{constructor(e){this._editor=e,this._ruleName=B._IdGenerator.nextId(),this._decorations=[],this._color=null,this._height=-1}dispose(){this.hide(),n.uN(this._ruleName)}set color(e){this._color!==e&&(this._color=e,this._updateStyle())}set height(e){this._height!==e&&(this._height=e,this._updateStyle())}_updateStyle(){n.uN(this._ruleName),n.fk(`.monaco-editor ${this._ruleName}`,`border-style: solid; border-color: transparent; border-bottom-color: ${this._color}; border-width: ${this._height}px; bottom: -${this._height}px; margin-left: -${this._height}px; `)}show(e){1===e.column&&(e={lineNumber:e.lineNumber,column:2}),this._decorations=this._editor.deltaDecorations(this._decorations,[{range:A.e.fromPositions(e),options:{description:"zone-widget-arrow",className:this._ruleName,stickiness:1}}])}hide(){this._editor.deltaDecorations(this._decorations,[])}}B._IdGenerator=new N.R(".arrow-decoration-");var W=i(89982),V=i(83390),H=i(60393),z=i(14472),$=i(12260),U=i(45164),j=function(e,t,i,n){var o,r=arguments.length,s=r<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,i):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(e,t,i,n);else for(var a=e.length-1;a>=0;a--)(o=e[a])&&(s=(r<3?o(s):r>3?o(t,i,s):o(t,i))||s);return r>3&&s&&Object.defineProperty(t,i,s),s},K=function(e,t){return function(i,n){t(i,n,e)}};const q=(0,$.yh)("IPeekViewService");var G;(0,z.z)(q,class{constructor(){this._widgets=new Map}addExclusiveWidget(e,t){const i=this._widgets.get(e);i&&(i.listener.dispose(),i.widget.dispose()),this._widgets.set(e,{widget:t,listener:t.onDidClose((()=>{const i=this._widgets.get(e);i&&i.widget===t&&(i.listener.dispose(),this._widgets.delete(e))}))})}}),function(e){e.inPeekEditor=new H.uy("inReferenceSearchEditor",!0,W.NC("vs/editor/contrib/peekView/browser/peekView","inReferenceSearchEditor","Whether the current code editor is embedded inside peek")),e.notInPeekEditor=e.inPeekEditor.toNegated()}(G||(G={}));let Z=class{constructor(e,t){e instanceof L.H&&G.inPeekEditor.bindTo(t)}dispose(){}};function Y(e){let t=e.get(k.$).getFocusedCodeEditor();return t instanceof L.H?t.getParentEditor():t}Z.ID="editor.contrib.referenceController",Z=j([K(1,H.i6)],Z),(0,x._K)(Z.ID,Z);const Q={headerBackgroundColor:a.Il.white,primaryHeadingColor:a.Il.fromHex("#333333"),secondaryHeadingColor:a.Il.fromHex("#6c6c6cb3")};let X=class extends class{constructor(e,t={}){this._arrow=null,this._overlayWidget=null,this._resizeSash=null,this._positionMarkerId=[],this._viewZone=null,this._disposables=new D.SL,this.container=null,this._isShowing=!1,this.editor=e,this.options=c.I8(t),c.jB(this.options,O,!1),this.domNode=document.createElement("div"),this.options.isAccessible||(this.domNode.setAttribute("aria-hidden","true"),this.domNode.setAttribute("role","presentation")),this._disposables.add(this.editor.onDidLayoutChange((e=>{const t=this._getWidth(e);this.domNode.style.width=t+"px",this.domNode.style.left=this._getLeft(e)+"px",this._onWidth(t)})))}dispose(){this._overlayWidget&&(this.editor.removeOverlayWidget(this._overlayWidget),this._overlayWidget=null),this._viewZone&&this.editor.changeViewZones((e=>{this._viewZone&&e.removeZone(this._viewZone.id),this._viewZone=null})),this.editor.deltaDecorations(this._positionMarkerId,[]),this._positionMarkerId=[],this._disposables.dispose()}create(){this.domNode.classList.add("zone-widget"),this.options.className&&this.domNode.classList.add(this.options.className),this.container=document.createElement("div"),this.container.classList.add("zone-widget-container"),this.domNode.appendChild(this.container),this.options.showArrow&&(this._arrow=new B(this.editor),this._disposables.add(this._arrow)),this._fillContainer(this.container),this._initSash(),this._applyStyles()}style(e){e.frameColor&&(this.options.frameColor=e.frameColor),e.arrowColor&&(this.options.arrowColor=e.arrowColor),this._applyStyles()}_applyStyles(){if(this.container&&this.options.frameColor){let e=this.options.frameColor.toString();this.container.style.borderTopColor=e,this.container.style.borderBottomColor=e}if(this._arrow&&this.options.arrowColor){let e=this.options.arrowColor.toString();this._arrow.color=e}}_getWidth(e){return e.width-e.minimap.minimapWidth-e.verticalScrollbarWidth}_getLeft(e){return e.minimap.minimapWidth>0&&0===e.minimap.minimapLeft?e.minimap.minimapWidth:0}_onViewZoneTop(e){this.domNode.style.top=e+"px"}_onViewZoneHeight(e){if(this.domNode.style.height=`${e}px`,this.container){let t=e-this._decoratingElementsHeight();this.container.style.height=`${t}px`;const i=this.editor.getLayoutInfo();this._doLayout(t,this._getWidth(i))}this._resizeSash&&this._resizeSash.layout()}get position(){const[e]=this._positionMarkerId;if(!e)return;const t=this.editor.getModel();if(!t)return;const i=t.getDecorationRange(e);return i?i.getStartPosition():void 0}show(e,t){const i=A.e.isIRange(e)?A.e.lift(e):A.e.fromPositions(e);this._isShowing=!0,this._showImpl(i,t),this._isShowing=!1,this._positionMarkerId=this.editor.deltaDecorations(this._positionMarkerId,[{range:i,options:R.qx.EMPTY}])}hide(){this._viewZone&&(this.editor.changeViewZones((e=>{this._viewZone&&e.removeZone(this._viewZone.id)})),this._viewZone=null),this._overlayWidget&&(this.editor.removeOverlayWidget(this._overlayWidget),this._overlayWidget=null),this._arrow&&this._arrow.hide()}_decoratingElementsHeight(){let e=this.editor.getOption(59),t=0;return this.options.showArrow&&(t+=2*Math.round(e/3)),this.options.showFrame&&(t+=2*Math.round(e/9)),t}_showImpl(e,t){const i=e.getStartPosition(),n=this.editor.getLayoutInfo(),o=this._getWidth(n);this.domNode.style.width=`${o}px`,this.domNode.style.left=this._getLeft(n)+"px";const r=document.createElement("div");r.style.overflow="hidden";const s=this.editor.getOption(59),a=Math.max(12,this.editor.getLayoutInfo().height/s*.8);t=Math.min(t,a);let l=0,c=0;if(this._arrow&&this.options.showArrow&&(l=Math.round(s/3),this._arrow.height=l,this._arrow.show(i)),this.options.showFrame&&(c=Math.round(s/9)),this.editor.changeViewZones((e=>{this._viewZone&&e.removeZone(this._viewZone.id),this._overlayWidget&&(this.editor.removeOverlayWidget(this._overlayWidget),this._overlayWidget=null),this.domNode.style.top="-1000px",this._viewZone=new P(r,i.lineNumber,i.column,t,(e=>this._onViewZoneTop(e)),(e=>this._onViewZoneHeight(e))),this._viewZone.id=e.addZone(this._viewZone),this._overlayWidget=new F("vs.editor.contrib.zoneWidget"+this._viewZone.id,this.domNode),this.editor.addOverlayWidget(this._overlayWidget)})),this.container&&this.options.showFrame){const e=this.options.frameWidth?this.options.frameWidth:c;this.container.style.borderTopWidth=e+"px",this.container.style.borderBottomWidth=e+"px"}let d=t*s-this._decoratingElementsHeight();this.container&&(this.container.style.top=l+"px",this.container.style.height=d+"px",this.container.style.overflow="hidden"),this._doLayout(d,o),this.options.keepEditorSelection||this.editor.setSelection(e);const u=this.editor.getModel();if(u){const t=e.endLineNumber+1;t<=u.getLineCount()?this.revealLine(t,!1):this.revealLine(u.getLineCount(),!0)}}revealLine(e,t){t?this.editor.revealLineInCenter(e,0):this.editor.revealLine(e,0)}setCssClass(e,t){this.container&&(t&&this.container.classList.remove(t),this.container.classList.add(e))}_onWidth(e){}_doLayout(e,t){}_relayout(e){this._viewZone&&this._viewZone.heightInLines!==e&&this.editor.changeViewZones((t=>{this._viewZone&&(this._viewZone.heightInLines=e,t.layoutZone(this._viewZone.id))}))}_initSash(){if(this._resizeSash)return;let e;this._resizeSash=this._disposables.add(new E.g(this.domNode,this,{orientation:1})),this.options.isResizeable||(this._resizeSash.state=0),this._disposables.add(this._resizeSash.onDidStart((t=>{this._viewZone&&(e={startY:t.startY,heightInLines:this._viewZone.heightInLines})}))),this._disposables.add(this._resizeSash.onDidEnd((()=>{e=void 0}))),this._disposables.add(this._resizeSash.onDidChange((t=>{if(e){let i=(t.currentY-e.startY)/this.editor.getOption(59),n=i<0?Math.ceil(i):Math.floor(i),o=e.heightInLines+n;o>5&&o<35&&this._relayout(o)}})))}getHorizontalSashLeft(){return 0}getHorizontalSashTop(){return(null===this.domNode.style.height?0:parseInt(this.domNode.style.height))-this._decoratingElementsHeight()/2}getHorizontalSashWidth(){const e=this.editor.getLayoutInfo();return e.width-e.minimap.minimapWidth}}{constructor(e,t,i){super(e,t),this.instantiationService=i,this._onDidClose=new l.Q5,this.onDidClose=this._onDidClose.event,c.jB(this.options,Q,!1)}dispose(){this.disposed||(this.disposed=!0,super.dispose(),this._onDidClose.fire(this))}style(e){let t=this.options;e.headerBackgroundColor&&(t.headerBackgroundColor=e.headerBackgroundColor),e.primaryHeadingColor&&(t.primaryHeadingColor=e.primaryHeadingColor),e.secondaryHeadingColor&&(t.secondaryHeadingColor=e.secondaryHeadingColor),super.style(e)}_applyStyles(){super._applyStyles();let e=this.options;this._headElement&&e.headerBackgroundColor&&(this._headElement.style.backgroundColor=e.headerBackgroundColor.toString()),this._primaryHeading&&e.primaryHeadingColor&&(this._primaryHeading.style.color=e.primaryHeadingColor.toString()),this._secondaryHeading&&e.secondaryHeadingColor&&(this._secondaryHeading.style.color=e.secondaryHeadingColor.toString()),this._bodyElement&&e.frameColor&&(this._bodyElement.style.borderColor=e.frameColor.toString())}_fillContainer(e){this.setCssClass("peekview-widget"),this._headElement=n.$(".head"),this._bodyElement=n.$(".body"),this._fillHead(this._headElement),this._fillBody(this._bodyElement),e.appendChild(this._headElement),e.appendChild(this._bodyElement)}_fillHead(e,t){const i=n.$(".peekview-title");this.options.supportOnTitleClick&&(i.classList.add("clickable"),n.mu(i,"click",(e=>this._onTitleClick(e)))),n.R3(this._headElement,i),this._fillTitleIcon(i),this._primaryHeading=n.$("span.filename"),this._secondaryHeading=n.$("span.dirname"),this._metaHeading=n.$("span.meta"),n.R3(i,this._primaryHeading,this._secondaryHeading,this._metaHeading);const a=n.$(".peekview-actions");n.R3(this._headElement,a);const l=this._getActionBarOptions();this._actionbarWidget=new o.o(a,l),this._disposables.add(this._actionbarWidget),t||this._actionbarWidget.push(new r.aU("peekview.close",W.NC("vs/editor/contrib/peekView/browser/peekView","label.close","Close"),s.lA.close.classNames,!0,(()=>(this.dispose(),Promise.resolve()))),{label:!1,icon:!0})}_fillTitleIcon(e){}_getActionBarOptions(){return{actionViewItemProvider:V.Id.bind(void 0,this.instantiationService),orientation:0}}_onTitleClick(e){}setTitle(e,t){this._primaryHeading&&this._secondaryHeading&&(this._primaryHeading.innerText=e,this._primaryHeading.setAttribute("title",e),t?this._secondaryHeading.innerText=t:n.PO(this._secondaryHeading))}setMetaTitle(e){this._metaHeading&&(e?(this._metaHeading.innerText=e,n.$Z(this._metaHeading)):n.Cp(this._metaHeading))}_doLayout(e,t){if(!this._isShowing&&e<0)return void this.dispose();const i=Math.ceil(1.2*this.editor.getOption(59)),n=Math.round(e-(i+2));this._doLayoutHead(i,t),this._doLayoutBody(n,t)}_doLayoutHead(e,t){this._headElement&&(this._headElement.style.height=`${e}px`,this._headElement.style.lineHeight=this._headElement.style.height)}_doLayoutBody(e,t){this._bodyElement&&(this._bodyElement.style.height=`${e}px`)}};X=j([K(2,$.TG)],X);const J=(0,U.P6G)("peekViewTitle.background",{dark:(0,U.ZnX)(U.c63,.1),light:(0,U.ZnX)(U.c63,.1),hc:null},W.NC("vs/editor/contrib/peekView/browser/peekView","peekViewTitleBackground","Background color of the peek view title area.")),ee=(0,U.P6G)("peekViewTitleLabel.foreground",{dark:a.Il.white,light:a.Il.black,hc:a.Il.white},W.NC("vs/editor/contrib/peekView/browser/peekView","peekViewTitleForeground","Color of the peek view title.")),te=(0,U.P6G)("peekViewTitleDescription.foreground",{dark:"#ccccccb3",light:"#616161",hc:"#FFFFFF99"},W.NC("vs/editor/contrib/peekView/browser/peekView","peekViewTitleInfoForeground","Color of the peek view title info.")),ie=(0,U.P6G)("peekView.border",{dark:U.c63,light:U.c63,hc:U.lRK},W.NC("vs/editor/contrib/peekView/browser/peekView","peekViewBorder","Color of the peek view borders and arrow.")),ne=(0,U.P6G)("peekViewResult.background",{dark:"#252526",light:"#F3F3F3",hc:a.Il.black},W.NC("vs/editor/contrib/peekView/browser/peekView","peekViewResultsBackground","Background color of the peek view result list.")),oe=((0,U.P6G)("peekViewResult.lineForeground",{dark:"#bbbbbb",light:"#646465",hc:a.Il.white},W.NC("vs/editor/contrib/peekView/browser/peekView","peekViewResultsMatchForeground","Foreground color for line nodes in the peek view result list.")),(0,U.P6G)("peekViewResult.fileForeground",{dark:a.Il.white,light:"#1E1E1E",hc:a.Il.white},W.NC("vs/editor/contrib/peekView/browser/peekView","peekViewResultsFileForeground","Foreground color for file nodes in the peek view result list.")),(0,U.P6G)("peekViewResult.selectionBackground",{dark:"#3399ff33",light:"#3399ff33",hc:null},W.NC("vs/editor/contrib/peekView/browser/peekView","peekViewResultsSelectionBackground","Background color of the selected entry in the peek view result list.")),(0,U.P6G)("peekViewResult.selectionForeground",{dark:a.Il.white,light:"#6C6C6C",hc:a.Il.white},W.NC("vs/editor/contrib/peekView/browser/peekView","peekViewResultsSelectionForeground","Foreground color of the selected entry in the peek view result list.")),(0,U.P6G)("peekViewEditor.background",{dark:"#001F33",light:"#F2F8FC",hc:a.Il.black},W.NC("vs/editor/contrib/peekView/browser/peekView","peekViewEditorBackground","Background color of the peek view editor.")));(0,U.P6G)("peekViewEditorGutter.background",{dark:oe,light:oe,hc:oe},W.NC("vs/editor/contrib/peekView/browser/peekView","peekViewEditorGutterBackground","Background color of the gutter in the peek view editor.")),(0,U.P6G)("peekViewResult.matchHighlightBackground",{dark:"#ea5c004d",light:"#ea5c004d",hc:null},W.NC("vs/editor/contrib/peekView/browser/peekView","peekViewResultsMatchHighlight","Match highlight color in the peek view result list.")),(0,U.P6G)("peekViewEditor.matchHighlightBackground",{dark:"#ff8f0099",light:"#f5d802de",hc:null},W.NC("vs/editor/contrib/peekView/browser/peekView","peekViewEditorMatchHighlight","Match highlight color in the peek view editor.")),(0,U.P6G)("peekViewEditor.matchHighlightBorder",{dark:null,light:null,hc:U.xL1},W.NC("vs/editor/contrib/peekView/browser/peekView","peekViewEditorMatchHighlightBorder","Match highlight border in the peek view editor."))},10600:function(e,t,i){"use strict";i.d(t,{X:function(){return d}});var n=i(58143),o=i(4004),r=i(28295),s=i(28281),a=i(77324),l=i(4773),c=i(81585);class d{constructor(e){this.options=e,this.rangeHighlightDecorationId=void 0}provide(e,t){var i;const n=new o.SL;e.canAcceptInBackground=!!(null===(i=this.options)||void 0===i?void 0:i.canAcceptInBackground),e.matchOnLabel=e.matchOnDescription=e.matchOnDetail=e.sortByLabel=!1;const r=n.add(new o.XK);return r.value=this.doProvide(e,t),n.add(this.onDidActiveTextEditorControlChange((()=>{r.value=void 0,r.value=this.doProvide(e,t)}))),n}doProvide(e,t){const i=new o.SL,a=this.activeTextEditorControl;if(a&&this.canProvideWithTextEditor(a)){const l={editor:a},c=(0,s.Pi)(a);if(c){let e=(0,r.f6)(a.saveViewState());i.add(c.onDidChangeCursorPosition((()=>{e=(0,r.f6)(a.saveViewState())}))),l.restoreViewState=()=>{e&&a===this.activeTextEditorControl&&a.restoreViewState(e)},i.add((0,n.I)(t.onCancellationRequested)((()=>{var e;return null===(e=l.restoreViewState)||void 0===e?void 0:e.call(l)})))}i.add((0,o.OF)((()=>this.clearDecorations(a)))),i.add(this.provideWithTextEditor(l,e,t))}else i.add(this.provideWithoutTextEditor(e,t));return i}canProvideWithTextEditor(e){return!0}gotoLocation({editor:e},t){e.setSelection(t.range),e.revealRangeInCenter(t.range,0),t.preserveFocus||e.focus()}getModel(e){var t;return(0,s.QI)(e)?null===(t=e.getModel())||void 0===t?void 0:t.modified:e.getModel()}addDecorations(e,t){e.changeDecorations((e=>{const i=[];this.rangeHighlightDecorationId&&(i.push(this.rangeHighlightDecorationId.overviewRulerDecorationId),i.push(this.rangeHighlightDecorationId.rangeHighlightId),this.rangeHighlightDecorationId=void 0);const n=[{range:t,options:{description:"quick-access-range-highlight",className:"rangeHighlight",isWholeLine:!0}},{range:t,options:{description:"quick-access-range-highlight-overview",overviewRuler:{color:(0,c.EN)(l.m9),position:a.sh.Full}}}],[o,r]=e.deltaDecorations(i,n);this.rangeHighlightDecorationId={rangeHighlightId:o,overviewRulerDecorationId:r}}))}clearDecorations(e){const t=this.rangeHighlightDecorationId;t&&(e.changeDecorations((e=>{e.deltaDecorations([t.overviewRulerDecorationId,t.rangeHighlightId],[])})),this.rangeHighlightDecorationId=void 0)}}},98483:function(e,t,i){"use strict";i.r(t),i.d(t,{RenameAction:function(){return J},rename:function(){return Q}});var n=i(77339),o=i(40027),r=i(60677),s=i(16182),a=i(4004),l=i(28295),c=i(39675),d=i(78507),u=i(4189),h=i(86789),g=i(3622),p=i(72248),m=i(11465),f=i(38673),_=i(72837),b=i(52974),v=i(89982),C=i(97618),w=i(60393),y=i(12260),S=i(16592),x=i(66877),k=i(35073),L=i(73403),E=i(93379),N=i.n(E),D=i(7795),I=i.n(D),T=i(90569),A=i.n(T),R=i(3565),M=i.n(R),O=i(19216),P=i.n(O),F=i(44589),B=i.n(F),W=i(68747),V={};V.styleTagTransform=B(),V.setAttributes=M(),V.insert=A().bind(null,"head"),V.domAPI=I(),V.insertStyleElement=P(),N()(W.Z,V),W.Z&&W.Z.locals&&W.Z.locals;var H=i(67517),z=i(45164),$=i(81585),U=function(e,t){return function(i,n){t(i,n,e)}};const j=new w.uy("renameInputVisible",!1,(0,v.NC)("vs/editor/contrib/rename/browser/renameInputField","renameInputVisible","Whether the rename input widget is visible"));let K=class{constructor(e,t,i,n,o){this._editor=e,this._acceptKeybindings=t,this._themeService=i,this._keybindingService=n,this._disposables=new a.SL,this.allowEditorOverflow=!0,this._visibleContextKey=j.bindTo(o),this._editor.addContentWidget(this),this._disposables.add(this._editor.onDidChangeConfiguration((e=>{e.hasChanged(44)&&this._updateFont()}))),this._disposables.add(i.onDidColorThemeChange(this._updateStyles,this))}dispose(){this._disposables.dispose(),this._editor.removeContentWidget(this)}getId(){return"__renameInputWidget"}getDomNode(){if(!this._domNode){this._domNode=document.createElement("div"),this._domNode.className="monaco-editor rename-box",this._input=document.createElement("input"),this._input.className="rename-input",this._input.type="text",this._input.setAttribute("aria-label",(0,v.NC)("vs/editor/contrib/rename/browser/renameInputField","renameAriaLabel","Rename input. Type new name and press Enter to commit.")),this._domNode.appendChild(this._input),this._label=document.createElement("div"),this._label.className="rename-label",this._domNode.appendChild(this._label);const e=()=>{var e,t;const[i,n]=this._acceptKeybindings;this._keybindingService.lookupKeybinding(i),this._label.innerText=(0,v.NC)("vs/editor/contrib/rename/browser/renameInputField",{key:"label",comment:['placeholders are keybindings, e.g "F2 to Rename, Shift+F2 to Preview"']},"{0} to Rename, {1} to Preview",null===(e=this._keybindingService.lookupKeybinding(i))||void 0===e?void 0:e.getLabel(),null===(t=this._keybindingService.lookupKeybinding(n))||void 0===t?void 0:t.getLabel())};e(),this._disposables.add(this._keybindingService.onDidUpdateKeybindings(e)),this._updateFont(),this._updateStyles(this._themeService.getColorTheme())}return this._domNode}_updateStyles(e){var t,i,n,o;if(!this._input||!this._domNode)return;const r=e.getColor(z.rh);this._domNode.style.backgroundColor=String(null!==(t=e.getColor(z.D0T))&&void 0!==t?t:""),this._domNode.style.boxShadow=r?` 0 0 8px 2px ${r}`:"",this._domNode.style.color=String(null!==(i=e.getColor(z.zJb))&&void 0!==i?i:""),this._input.style.backgroundColor=String(null!==(n=e.getColor(z.sEe))&&void 0!==n?n:"");const s=e.getColor(z.dt_);this._input.style.borderWidth=s?"1px":"0px",this._input.style.borderStyle=s?"solid":"none",this._input.style.borderColor=null!==(o=null==s?void 0:s.toString())&&void 0!==o?o:"none"}_updateFont(){if(!this._input||!this._label)return;const e=this._editor.getOption(44);this._input.style.fontFamily=e.fontFamily,this._input.style.fontWeight=e.fontWeight,this._input.style.fontSize=`${e.fontSize}px`,this._label.style.fontSize=.8*e.fontSize+"px"}getPosition(){return this._visible?{position:this._position,preference:[2,1]}:null}afterRender(e){e||this.cancelInput(!0)}acceptInput(e){this._currentAcceptInput&&this._currentAcceptInput(e)}cancelInput(e){this._currentCancelInput&&this._currentCancelInput(e)}getInput(e,t,i,n,o,r){this._domNode.classList.toggle("preview",o),this._position=new p.L(e.startLineNumber,e.startColumn),this._input.value=t,this._input.setAttribute("selectionStart",i.toString()),this._input.setAttribute("selectionEnd",n.toString()),this._input.size=Math.max(1.1*(e.endColumn-e.startColumn),20);const s=new a.SL;return new Promise((e=>{this._currentCancelInput=t=>(this._currentAcceptInput=void 0,this._currentCancelInput=void 0,e(t),!0),this._currentAcceptInput=i=>{0!==this._input.value.trim().length&&this._input.value!==t?(this._currentAcceptInput=void 0,this._currentCancelInput=void 0,e({newName:this._input.value,wantsPreview:o&&i})):this.cancelInput(!0)},s.add(r.onCancellationRequested((()=>this.cancelInput(!0)))),s.add(this._editor.onDidBlurEditorWidget((()=>this.cancelInput(!1)))),this._show()})).finally((()=>{s.dispose(),this._hide()}))}_show(){this._editor.revealLineInCenterIfOutsideViewport(this._position.lineNumber,0),this._visible=!0,this._visibleContextKey.set(!0),this._editor.layoutContentWidget(this),setTimeout((()=>{this._input.focus(),this._input.setSelectionRange(parseInt(this._input.getAttribute("selectionStart")),parseInt(this._input.getAttribute("selectionEnd")))}),100)}_hide(){this._visible=!1,this._visibleContextKey.reset(),this._editor.layoutContentWidget(this)}};K=function(e,t,i,n){var o,r=arguments.length,s=r<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,i):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(e,t,i,n);else for(var a=e.length-1;a>=0;a--)(o=e[a])&&(s=(r<3?o(s):r>3?o(t,i,s):o(t,i))||s);return r>3&&s&&Object.defineProperty(t,i,s),s}([U(2,$.XE),U(3,H.d),U(4,w.i6)],K);var q=i(66988),G=function(e,t){return function(i,n){t(i,n,e)}},Z=function(e,t,i,n){return new(i||(i=Promise))((function(o,r){function s(e){try{l(n.next(e))}catch(e){r(e)}}function a(e){try{l(n.throw(e))}catch(e){r(e)}}function l(e){var t;e.done?o(e.value):(t=e.value,t instanceof i?t:new i((function(e){e(t)}))).then(s,a)}l((n=n.apply(e,t||[])).next())}))};class Y{constructor(e,t,i){this.model=e,this.position=t,this._providerRenameIdx=0,this._providers=i.ordered(e)}hasProvider(){return this._providers.length>0}resolveRenameLocation(e){return Z(this,void 0,void 0,(function*(){const t=[];for(this._providerRenameIdx=0;this._providerRenameIdx0?t.join("\n"):void 0}:{range:m.e.fromPositions(this.position),text:"",rejectReason:t.length>0?t.join("\n"):void 0}}))}provideRenameEdits(e,t){return Z(this,void 0,void 0,(function*(){return this._provideRenameEdits(e,this._providerRenameIdx,[],t)}))}_provideRenameEdits(e,t,i,n){return Z(this,void 0,void 0,(function*(){const o=this._providers[t];if(!o)return{edits:[],rejectReason:i.join("\n")};const r=yield o.provideRenameEdits(this.model,this.position,e,n);return r?r.rejectReason?this._provideRenameEdits(e,t+1,i.concat(r.rejectReason),n):r:this._provideRenameEdits(e,t+1,i.concat(v.NC("vs/editor/contrib/rename/browser/rename","no result","No result.")),n)}))}}function Q(e,t,i,n){return Z(this,void 0,void 0,(function*(){const o=new Y(t,i,e),s=yield o.resolveRenameLocation(r.T.None);return(null==s?void 0:s.rejectReason)?{edits:[],rejectReason:s.rejectReason}:o.provideRenameEdits(n,r.T.None)}))}let X=class e{constructor(e,t,i,n,s,l,c,d){this.editor=e,this._instaService=t,this._notificationService=i,this._bulkEditService=n,this._progressService=s,this._logService=l,this._configService=c,this._languageFeaturesService=d,this._dispoableStore=new a.SL,this._cts=new r.A,this._renameInputField=this._dispoableStore.add(new o.Ue((()=>this._dispoableStore.add(this._instaService.createInstance(K,this.editor,["acceptRenameInput","acceptRenameInputWithPreview"])))))}static get(t){return t.getContribution(e.ID)}dispose(){this._dispoableStore.dispose(),this._cts.dispose(!0)}run(){var e,t;return Z(this,void 0,void 0,(function*(){if(this._cts.dispose(!0),!this.editor.hasModel())return;const i=this.editor.getPosition(),r=new Y(this.editor.getModel(),i,this._languageFeaturesService.renameProvider);if(!r.hasProvider())return;let s;this._cts=new d.Dl(this.editor,5);try{const e=r.resolveRenameLocation(this._cts.token);this._progressService.showWhile(e,250),s=yield e}catch(t){return void(null===(e=b.O.get(this.editor))||void 0===e||e.showMessage(t||v.NC("vs/editor/contrib/rename/browser/rename","resolveRenameLocationFailed","An unknown error occurred while resolving rename location"),i))}if(!s)return;if(s.rejectReason)return void(null===(t=b.O.get(this.editor))||void 0===t||t.showMessage(s.rejectReason,i));if(this._cts.token.isCancellationRequested)return;this._cts.dispose(),this._cts=new d.Dl(this.editor,5,s.range);let a=this.editor.getSelection(),l=0,c=s.text.length;m.e.isEmpty(a)||m.e.spansMultipleLines(a)||!m.e.containsRange(s.range,a)||(l=Math.max(0,a.startColumn-s.range.startColumn),c=Math.min(s.range.endColumn,a.endColumn)-s.range.startColumn);const u=this._bulkEditService.hasPreviewHandler()&&this._configService.getValue(this.editor.getModel().uri,"editor.rename.enablePreview"),g=yield this._renameInputField.value.getInput(s.range,s.text,l,c,u,this._cts.token);if("boolean"==typeof g)return void(g&&this.editor.focus());this.editor.focus();const p=(0,o.eP)(r.provideRenameEdits(g.newName,this._cts.token),this._cts.token).then((e=>Z(this,void 0,void 0,(function*(){e&&this.editor.hasModel()&&(e.rejectReason?this._notificationService.info(e.rejectReason):(this.editor.setSelection(m.e.fromPositions(this.editor.getSelection().getPosition())),this._bulkEditService.apply(h.fo.convert(e),{editor:this.editor,showPreview:g.wantsPreview,label:v.NC("vs/editor/contrib/rename/browser/rename","label","Renaming '{0}'",null==s?void 0:s.text),quotableLabel:v.NC("vs/editor/contrib/rename/browser/rename","quotableLabel","Renaming {0}",null==s?void 0:s.text)}).then((e=>{e.ariaSummary&&(0,n.Z9)(v.NC("vs/editor/contrib/rename/browser/rename","aria","Successfully renamed '{0}' to '{1}'. Summary: {2}",s.text,g.newName,e.ariaSummary))})).catch((e=>{this._notificationService.error(v.NC("vs/editor/contrib/rename/browser/rename","rename.failedApply","Rename failed to apply edits")),this._logService.error(e)}))))}))),(e=>{this._notificationService.error(v.NC("vs/editor/contrib/rename/browser/rename","rename.failed","Rename failed to compute edits")),this._logService.error(e)}));return this._progressService.showWhile(p,250),p}))}acceptRenameInput(e){this._renameInputField.value.acceptInput(e)}cancelRenameInput(){this._renameInputField.value.cancelInput(!0)}};X.ID="editor.contrib.renameController",X=function(e,t,i,n){var o,r=arguments.length,s=r<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,i):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(e,t,i,n);else for(var a=e.length-1;a>=0;a--)(o=e[a])&&(s=(r<3?o(s):r>3?o(t,i,s):o(t,i))||s);return r>3&&s&&Object.defineProperty(t,i,s),s}([G(1,y.TG),G(2,x.lT),G(3,h.vu),G(4,k.ek),G(5,S.VZ),G(6,_.V),G(7,q.p)],X);class J extends u.R6{constructor(){super({id:"editor.action.rename",label:v.NC("vs/editor/contrib/rename/browser/rename","rename.label","Rename Symbol"),alias:"Rename Symbol",precondition:w.Ao.and(f.u.writable,f.u.hasRenameProvider),kbOpts:{kbExpr:f.u.editorTextFocus,primary:60,weight:100},contextMenuOpts:{group:"1_modification",order:1.1}})}runCommand(e,t){const i=e.get(g.$),[n,o]=Array.isArray(t)&&t||[void 0,void 0];return c.o.isUri(n)&&p.L.isIPosition(o)?i.openCodeEditor({resource:n},i.getActiveCodeEditor()).then((e=>{e&&(e.setPosition(o),e.invokeWithinContext((t=>(this.reportTelemetry(t,e),this.run(t,e)))))}),s.dL):super.runCommand(e,t)}run(e,t){const i=X.get(t);return i?i.run():Promise.resolve()}}(0,u._K)(X.ID,X),(0,u.Qr)(J);const ee=u._l.bindToContribution(X.get);(0,u.fK)(new ee({id:"acceptRenameInput",precondition:j,handler:e=>e.acceptRenameInput(!1),kbOpts:{weight:199,kbExpr:f.u.focus,primary:3}})),(0,u.fK)(new ee({id:"acceptRenameInputWithPreview",precondition:w.Ao.and(j,w.Ao.has("config.editor.rename.enablePreview")),handler:e=>e.acceptRenameInput(!0),kbOpts:{weight:199,kbExpr:f.u.focus,primary:1027}})),(0,u.fK)(new ee({id:"cancelRenameInput",precondition:j,handler:e=>e.cancelRenameInput(),kbOpts:{weight:199,kbExpr:f.u.focus,primary:9,secondary:[1033]}})),(0,u.sb)("_executeDocumentRenameProvider",(function(e,t,i,...n){const[o]=n;(0,l.p_)("string"==typeof o);const{renameProvider:r}=e.get(q.p);return Q(r,t,i,o)})),(0,u.sb)("_executePrepareRename",(function(e,t,i){return Z(this,void 0,void 0,(function*(){const{renameProvider:n}=e.get(q.p),o=new Y(t,i,n),s=yield o.resolveRenameLocation(r.T.None);if(null==s?void 0:s.rejectReason)throw new Error(s.rejectReason);return s}))})),L.B.as(C.IP.Configuration).registerConfiguration({id:"editor",properties:{"editor.rename.enablePreview":{scope:5,description:v.NC("vs/editor/contrib/rename/browser/rename","enablePreview","Enable/disable the ability to preview changes before renaming"),default:!0,type:"boolean"}}})},75058:function(e,t,i){"use strict";i.d(t,{x:function(){return s}});var n=i(57512),o=i(72248),r=i(11465);class s{provideSelectionRanges(e,t){return i=this,n=void 0,r=function*(){const i=[];for(const n of t){const t=[];i.push(t);const o=new Map;yield new Promise((t=>s._bracketsRightYield(t,0,e,n,o))),yield new Promise((i=>s._bracketsLeftYield(i,0,e,n,o,t)))}return i},new((o=void 0)||(o=Promise))((function(e,t){function s(e){try{l(r.next(e))}catch(e){t(e)}}function a(e){try{l(r.throw(e))}catch(e){t(e)}}function l(t){var i;t.done?e(t.value):(i=t.value,i instanceof o?i:new o((function(e){e(i)}))).then(s,a)}l((r=r.apply(i,n||[])).next())}));var i,n,o,r}static _bracketsRightYield(e,t,i,o,r){const a=new Map,l=Date.now();for(;;){if(t>=s._maxRounds){e();break}if(!o){e();break}let c=i.bracketPairs.findNextBracket(o);if(!c){e();break}if(Date.now()-l>s._maxDuration){setTimeout((()=>s._bracketsRightYield(e,t+1,i,o,r)));break}const d=c.close[0];if(c.isOpen){let e=a.has(d)?a.get(d):0;a.set(d,e+1)}else{let e=a.has(d)?a.get(d):0;if(e-=1,a.set(d,Math.max(0,e)),e<0){let e=r.get(d);e||(e=new n.S,r.set(d,e)),e.push(c.range)}}o=c.range.getEndPosition()}}static _bracketsLeftYield(e,t,i,n,o,a){const l=new Map,c=Date.now();for(;;){if(t>=s._maxRounds&&0===o.size){e();break}if(!n){e();break}let d=i.bracketPairs.findPrevBracket(n);if(!d){e();break}if(Date.now()-c>s._maxDuration){setTimeout((()=>s._bracketsLeftYield(e,t+1,i,n,o,a)));break}const u=d.close[0];if(d.isOpen){let e=l.has(u)?l.get(u):0;if(e-=1,l.set(u,Math.max(0,e)),e<0){let e=o.get(u);if(e){let t=e.shift();0===e.size&&o.delete(u);const n=r.e.fromPositions(d.range.getEndPosition(),t.getStartPosition()),l=r.e.fromPositions(d.range.getStartPosition(),t.getEndPosition());a.push({range:n}),a.push({range:l}),s._addBracketLeading(i,l,a)}}}else{let e=l.has(u)?l.get(u):0;l.set(u,e+1)}n=d.range.getStartPosition()}}static _addBracketLeading(e,t,i){if(t.startLineNumber===t.endLineNumber)return;const n=t.startLineNumber,s=e.getLineFirstNonWhitespaceColumn(n);0!==s&&s!==t.startColumn&&(i.push({range:r.e.fromPositions(new o.L(n,s),t.getEndPosition())}),i.push({range:r.e.fromPositions(new o.L(n,1),t.getEndPosition())}));const a=n-1;if(a>0){const n=e.getLineFirstNonWhitespaceColumn(a);n===t.startColumn&&n!==e.getLineLastNonWhitespaceColumn(a)&&(i.push({range:r.e.fromPositions(new o.L(a,n),t.getEndPosition())}),i.push({range:r.e.fromPositions(new o.L(a,1),t.getEndPosition())}))}}}s._maxDuration=30,s._maxRounds=2},32072:function(e,t,i){"use strict";i.r(t),i.d(t,{provideSelectionRanges:function(){return E}});var n=i(57800),o=i(60677),r=i(16182),s=i(4189),a=i(72248),l=i(11465),c=i(59744),d=i(38673),u=i(75058),h=i(18039);class g{provideSelectionRanges(e,t){const i=[];for(const n of t){const t=[];i.push(t),this._addInWordRanges(t,e,n),this._addWordRanges(t,e,n),this._addWhitespaceLine(t,e,n),t.push({range:e.getFullModelRange()})}return i}_addInWordRanges(e,t,i){const n=t.getWordAtPosition(i);if(!n)return;let{word:o,startColumn:r}=n,s=i.column-r,a=s,c=s,d=0;for(;a>=0;a--){let e=o.charCodeAt(a);if(a!==s&&(95===e||45===e))break;if((0,h.mK)(e)&&(0,h.df)(d))break;d=e}for(a+=1;c0&&0===t.getLineFirstNonWhitespaceColumn(i.lineNumber)&&0===t.getLineLastNonWhitespaceColumn(i.lineNumber)&&e.push({range:new l.e(i.lineNumber,1,i.lineNumber,t.getLineMaxColumn(i.lineNumber))})}}var p=i(89982),m=i(3337),f=i(14756),_=i(66988),b=i(20010),v=i(28295),C=i(39675),w=function(e,t,i,n){return new(i||(i=Promise))((function(o,r){function s(e){try{l(n.next(e))}catch(e){r(e)}}function a(e){try{l(n.throw(e))}catch(e){r(e)}}function l(e){var t;e.done?o(e.value):(t=e.value,t instanceof i?t:new i((function(e){e(t)}))).then(s,a)}l((n=n.apply(e,t||[])).next())}))};class y{constructor(e,t){this.index=e,this.ranges=t}mov(e){let t=this.index+(e?1:-1);if(t<0||t>=this.ranges.length)return this;const i=new y(t,this.ranges);return i.ranges[t].equalsRange(this.ranges[this.index])?i.mov(e):i}}let S=class e{constructor(e,t){this._editor=e,this._languageFeaturesService=t,this._ignoreSelection=!1}static get(t){return t.getContribution(e.ID)}dispose(){var e;null===(e=this._selectionListener)||void 0===e||e.dispose()}run(e){return w(this,void 0,void 0,(function*(){if(!this._editor.hasModel())return;const t=this._editor.getSelections(),i=this._editor.getModel();if(this._state||(yield E(this._languageFeaturesService.selectionRangeProvider,i,t.map((e=>e.getPosition())),this._editor.getOption(102),o.T.None).then((e=>{var i;if(n.Of(e)&&e.length===t.length&&this._editor.hasModel()&&n.fS(this._editor.getSelections(),t,((e,t)=>e.equalsSelection(t)))){for(let i=0;ie.containsPosition(t[i].getStartPosition())&&e.containsPosition(t[i].getEndPosition()))),e[i].unshift(t[i]);this._state=e.map((e=>new y(0,e))),null===(i=this._selectionListener)||void 0===i||i.dispose(),this._selectionListener=this._editor.onDidChangeCursorPosition((()=>{var e;this._ignoreSelection||(null===(e=this._selectionListener)||void 0===e||e.dispose(),this._state=void 0)}))}}))),!this._state)return;this._state=this._state.map((t=>t.mov(e)));const r=this._state.map((e=>c.Y.fromPositions(e.ranges[e.index].getStartPosition(),e.ranges[e.index].getEndPosition())));this._ignoreSelection=!0;try{this._editor.setSelections(r)}finally{this._ignoreSelection=!1}}))}};var x,k;S.ID="editor.contrib.smartSelectController",S=function(e,t,i,n){var o,r=arguments.length,s=r<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,i):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(e,t,i,n);else for(var a=e.length-1;a>=0;a--)(o=e[a])&&(s=(r<3?o(s):r>3?o(t,i,s):o(t,i))||s);return r>3&&s&&Object.defineProperty(t,i,s),s}([(x=1,k=_.p,function(e,t){k(e,t,x)})],S);class L extends s.R6{constructor(e,t){super(t),this._forward=e}run(e,t){return w(this,void 0,void 0,(function*(){let e=S.get(t);e&&(yield e.run(this._forward))}))}}function E(e,t,i,o,s){return w(this,void 0,void 0,(function*(){const c=e.all(t).concat(new g);1===c.length&&c.unshift(new u.x);let d=[],h=[];for(const e of c)d.push(Promise.resolve(e.provideSelectionRanges(t,i,s)).then((e=>{if(n.Of(e)&&e.length===i.length)for(let t=0;t{if(0===e.length)return[];e.sort(((e,t)=>a.L.isBefore(e.getStartPosition(),t.getStartPosition())?1:a.L.isBefore(t.getStartPosition(),e.getStartPosition())||a.L.isBefore(e.getEndPosition(),t.getEndPosition())?-1:a.L.isBefore(t.getEndPosition(),e.getEndPosition())?1:0));let i,n=[];for(const t of e)(!i||l.e.containsRange(t,i)&&!l.e.equalsRange(t,i))&&(n.push(t),i=t);if(!o.selectLeadingAndTrailingWhitespace)return n;let r=[n[0]];for(let e=1;e")}}_doInsert(e,t){this._editor.hasModel()&&(this._snippetListener.clear(),t.undoStopBefore&&this._editor.getModel().pushStackElement(),this._session?this._session.merge(e,t):(this._modelVersionId=this._editor.getModel().getAlternativeVersionId(),this._session=new g.l(this._editor,e,t),this._session.insert()),t.undoStopAfter&&this._editor.getModel().pushStackElement(),this._updateState(),this._snippetListener.add(this._editor.onDidChangeModelContent((e=>e.isFlush&&this.cancel()))),this._snippetListener.add(this._editor.onDidChangeModel((()=>this.cancel()))),this._snippetListener.add(this._editor.onDidChangeCursorSelection((()=>this._updateState()))))}_updateState(){if(this._session&&this._editor.hasModel()){if(this._modelVersionId===this._editor.getModel().getAlternativeVersionId())return this.cancel();if(!this._session.hasPlaceholder)return this.cancel();if(this._session.isAtLastPlaceholder||!this._session.isSelectionWithinPlaceholders())return this._editor.getModel().pushStackElement(),this.cancel();this._inSnippet.set(!0),this._hasPrevTabstop.set(!this._session.isAtFirstPlaceholder),this._hasNextTabstop.set(!this._session.isAtLastPlaceholder),this._handleChoice()}}_handleChoice(){if(!this._session||!this._editor.hasModel())return void(this._currentChoice=void 0);const{choice:e}=this._session;if(e){if(this._currentChoice!==e){this._currentChoice=e,this._editor.setSelections(this._editor.getSelections().map((e=>s.Y.fromPositions(e.getStartPosition()))));const[t]=e.options;this._instantiationService.invokeFunction(l.i5,this._editor,e.options.map(((e,i)=>({kind:13,label:e.value,insertText:e.value,sortText:"a".repeat(i+1),range:r.e.fromPositions(this._editor.getPosition(),this._editor.getPosition().delta(0,t.value.length))}))))}}else this._currentChoice=void 0}finish(){for(;this._inSnippet.get();)this.next()}cancel(e=!1){var t;this._inSnippet.reset(),this._hasPrevTabstop.reset(),this._hasNextTabstop.reset(),this._snippetListener.clear(),null===(t=this._session)||void 0===t||t.dispose(),this._session=void 0,this._modelVersionId=-1,e&&this._editor.setSelections([this._editor.getSelection()])}prev(){this._session&&this._session.prev(),this._updateState()}next(){this._session&&this._session.next(),this._updateState()}isInSnippet(){return Boolean(this._inSnippet.get())}};f.ID="snippetController2",f.InSnippetMode=new d.uy("inSnippetMode",!1,(0,c.NC)("vs/editor/contrib/snippet/browser/snippetController2","inSnippetMode","Whether the editor in current in snippet mode")),f.HasNextTabstop=new d.uy("hasNextTabstop",!1,(0,c.NC)("vs/editor/contrib/snippet/browser/snippetController2","hasNextTabstop","Whether there is a next tab stop when in snippet mode")),f.HasPrevTabstop=new d.uy("hasPrevTabstop",!1,(0,c.NC)("vs/editor/contrib/snippet/browser/snippetController2","hasPrevTabstop","Whether there is a previous tab stop when in snippet mode")),f=function(e,t,i,n){var o,r=arguments.length,s=r<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,i):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(e,t,i,n);else for(var a=e.length-1;a>=0;a--)(o=e[a])&&(s=(r<3?o(s):r>3?o(t,i,s):o(t,i))||s);return r>3&&s&&Object.defineProperty(t,i,s),s}([p(1,u.TG),p(2,h.VZ),p(3,d.i6)],f),(0,o._K)(f.ID,f);const _=o._l.bindToContribution(f.get);(0,o.fK)(new _({id:"jumpToNextSnippetPlaceholder",precondition:d.Ao.and(f.InSnippetMode,f.HasNextTabstop),handler:e=>e.next(),kbOpts:{weight:130,kbExpr:a.u.editorTextFocus,primary:2}})),(0,o.fK)(new _({id:"jumpToPrevSnippetPlaceholder",precondition:d.Ao.and(f.InSnippetMode,f.HasPrevTabstop),handler:e=>e.prev(),kbOpts:{weight:130,kbExpr:a.u.editorTextFocus,primary:1026}})),(0,o.fK)(new _({id:"leaveSnippet",precondition:f.InSnippetMode,handler:e=>e.cancel(!0),kbOpts:{weight:130,kbExpr:a.u.editorTextFocus,primary:9,secondary:[1033]}})),(0,o.fK)(new _({id:"acceptSnippet",precondition:f.InSnippetMode,handler:e=>e.finish()}))},57693:function(e,t,i){"use strict";i.d(t,{Lv:function(){return l},Vm:function(){return a},Yj:function(){return p},xv:function(){return r}});class n{constructor(){this.value="",this.pos=0}static isDigitCharacter(e){return e>=48&&e<=57}static isVariableCharacter(e){return 95===e||e>=97&&e<=122||e>=65&&e<=90}text(e){this.value=e,this.pos=0}tokenText(e){return this.value.substr(e.pos,e.len)}next(){if(this.pos>=this.value.length)return{type:14,pos:this.pos,len:0};let e,t=this.pos,i=0,o=this.value.charCodeAt(t);if(e=n._table[o],"number"==typeof e)return this.pos+=1,{type:e,pos:t,len:1};if(n.isDigitCharacter(o)){e=8;do{i+=1,o=this.value.charCodeAt(t+i)}while(n.isDigitCharacter(o));return this.pos+=i,{type:e,pos:t,len:i}}if(n.isVariableCharacter(o)){e=9;do{o=this.value.charCodeAt(t+ ++i)}while(n.isVariableCharacter(o)||n.isDigitCharacter(o));return this.pos+=i,{type:e,pos:t,len:i}}e=10;do{i+=1,o=this.value.charCodeAt(t+i)}while(!isNaN(o)&&void 0===n._table[o]&&!n.isDigitCharacter(o)&&!n.isVariableCharacter(o));return this.pos+=i,{type:e,pos:t,len:i}}}n._table={36:0,58:1,44:2,123:3,125:4,92:5,47:6,124:7,43:11,45:12,63:13};class o{constructor(){this._children=[]}appendChild(e){return e instanceof r&&this._children[this._children.length-1]instanceof r?this._children[this._children.length-1].value+=e.value:(e.parent=this,this._children.push(e)),this}replace(e,t){const{parent:i}=e,n=i.children.indexOf(e),o=i.children.slice(0);o.splice(n,1,...t),i._children=o,function e(t,i){for(const n of t)n.parent=i,e(n.children,n)}(t,i)}get children(){return this._children}get snippet(){let e=this;for(;;){if(!e)return;if(e instanceof g)return e;e=e.parent}}toString(){return this.children.reduce(((e,t)=>e+t.toString()),"")}len(){return 0}}class r extends o{constructor(e){super(),this.value=e}toString(){return this.value}len(){return this.value.length}clone(){return new r(this.value)}}class s extends o{}class a extends s{constructor(e){super(),this.index=e}static compareByIndex(e,t){return e.index===t.index?0:e.isFinalTabstop?1:t.isFinalTabstop||e.indext.index?1:0}get isFinalTabstop(){return 0===this.index}get choice(){return 1===this._children.length&&this._children[0]instanceof l?this._children[0]:void 0}clone(){let e=new a(this.index);return this.transform&&(e.transform=this.transform.clone()),e._children=this.children.map((e=>e.clone())),e}}class l extends o{constructor(){super(...arguments),this.options=[]}appendChild(e){return e instanceof r&&(e.parent=this,this.options.push(e)),this}toString(){return this.options[0].value}len(){return this.options[0].len()}clone(){let e=new l;return this.options.forEach(e.appendChild,e),e}}class c extends o{constructor(){super(...arguments),this.regexp=new RegExp("")}resolve(e){const t=this;let i=!1,n=e.replace(this.regexp,(function(){return i=!0,t._replace(Array.prototype.slice.call(arguments,0,-2))}));return!i&&this._children.some((e=>e instanceof d&&Boolean(e.elseValue)))&&(n=this._replace([])),n}_replace(e){let t="";for(const i of this._children)if(i instanceof d){let n=e[i.index]||"";n=i.resolve(n),t+=n}else t+=i.toString();return t}toString(){return""}clone(){let e=new c;return e.regexp=new RegExp(this.regexp.source,(this.regexp.ignoreCase?"i":"")+(this.regexp.global?"g":"")),e._children=this.children.map((e=>e.clone())),e}}class d extends o{constructor(e,t,i,n){super(),this.index=e,this.shorthandName=t,this.ifValue=i,this.elseValue=n}resolve(e){return"upcase"===this.shorthandName?e?e.toLocaleUpperCase():"":"downcase"===this.shorthandName?e?e.toLocaleLowerCase():"":"capitalize"===this.shorthandName?e?e[0].toLocaleUpperCase()+e.substr(1):"":"pascalcase"===this.shorthandName?e?this._toPascalCase(e):"":"camelcase"===this.shorthandName?e?this._toCamelCase(e):"":Boolean(e)&&"string"==typeof this.ifValue?this.ifValue:Boolean(e)||"string"!=typeof this.elseValue?e||"":this.elseValue}_toPascalCase(e){const t=e.match(/[a-z0-9]+/gi);return t?t.map((e=>e.charAt(0).toUpperCase()+e.substr(1).toLowerCase())).join(""):e}_toCamelCase(e){const t=e.match(/[a-z0-9]+/gi);return t?t.map(((e,t)=>0===t?e.toLowerCase():e.charAt(0).toUpperCase()+e.substr(1).toLowerCase())).join(""):e}clone(){return new d(this.index,this.shorthandName,this.ifValue,this.elseValue)}}class u extends s{constructor(e){super(),this.name=e}resolve(e){let t=e.resolve(this);return this.transform&&(t=this.transform.resolve(t||"")),void 0!==t&&(this._children=[new r(t)],!0)}clone(){const e=new u(this.name);return this.transform&&(e.transform=this.transform.clone()),e._children=this.children.map((e=>e.clone())),e}}function h(e,t){const i=[...e];for(;i.length>0;){const e=i.shift();if(!t(e))break;i.unshift(...e.children)}}class g extends o{get placeholderInfo(){if(!this._placeholders){let e,t=[];this.walk((function(i){return i instanceof a&&(t.push(i),e=!e||e.indexn===e?(i=!0,!1):(t+=n.len(),!0))),i?t:-1}fullLen(e){let t=0;return h([e],(e=>(t+=e.len(),!0))),t}enclosingPlaceholders(e){let t=[],{parent:i}=e;for(;i;)i instanceof a&&t.push(i),i=i.parent;return t}resolveVariables(e){return this.walk((t=>(t instanceof u&&t.resolve(e)&&(this._placeholders=void 0),!0))),this}appendChild(e){return this._placeholders=void 0,super.appendChild(e)}replace(e,t){return this._placeholders=void 0,super.replace(e,t)}clone(){let e=new g;return this._children=this.children.map((e=>e.clone())),e}walk(e){h(this.children,e)}}class p{constructor(){this._scanner=new n,this._token={type:14,pos:0,len:0}}static escape(e){return e.replace(/\$|}|\\/g,"\\$&")}static guessNeedsClipboard(e){return/\${?CLIPBOARD/.test(e)}parse(e,t,i){this._scanner.text(e),this._token=this._scanner.next();const n=new g;for(;this._parse(n););const o=new Map,r=[];let s=0;n.walk((e=>(e instanceof a&&(s+=1,e.isFinalTabstop?o.set(0,void 0):!o.has(e.index)&&e.children.length>0?o.set(e.index,e.children):r.push(e)),!0)));for(const e of r){const t=o.get(e.index);if(t){const i=new a(e.index);i.transform=e.transform;for(const e of t)i.appendChild(e.clone());n.replace(e,[i])}}return i||(i=s>0&&t),!o.has(0)&&i&&n.appendChild(new a(0)),n}_accept(e,t){if(void 0===e||this._token.type===e){let e=!t||this._scanner.tokenText(this._token);return this._token=this._scanner.next(),e}return!1}_backTo(e){return this._scanner.pos=e.pos+e.len,this._token=e,!1}_until(e){const t=this._token;for(;this._token.type!==e;){if(14===this._token.type)return!1;if(5===this._token.type){const e=this._scanner.next();if(0!==e.type&&4!==e.type&&5!==e.type)return!1}this._token=this._scanner.next()}const i=this._scanner.value.substring(t.pos,this._token.pos).replace(/\\(\$|}|\\)/g,"$1");return this._token=this._scanner.next(),i}_parse(e){return this._parseEscaped(e)||this._parseTabstopOrVariableName(e)||this._parseComplexPlaceholder(e)||this._parseComplexVariable(e)||this._parseAnything(e)}_parseEscaped(e){let t;return!!(t=this._accept(5,!0))&&(t=this._accept(0,!0)||this._accept(4,!0)||this._accept(5,!0)||t,e.appendChild(new r(t)),!0)}_parseTabstopOrVariableName(e){let t;const i=this._token;return this._accept(0)&&(t=this._accept(9,!0)||this._accept(8,!0))?(e.appendChild(/^\d+$/.test(t)?new a(Number(t)):new u(t)),!0):this._backTo(i)}_parseComplexPlaceholder(e){let t;const i=this._token;if(!(this._accept(0)&&this._accept(3)&&(t=this._accept(8,!0))))return this._backTo(i);const n=new a(Number(t));if(this._accept(1))for(;;){if(this._accept(4))return e.appendChild(n),!0;if(!this._parse(n))return e.appendChild(new r("${"+t+":")),n.children.forEach(e.appendChild,e),!0}else{if(!(n.index>0&&this._accept(7)))return this._accept(6)?this._parseTransform(n)?(e.appendChild(n),!0):(this._backTo(i),!1):this._accept(4)?(e.appendChild(n),!0):this._backTo(i);{const t=new l;for(;;){if(this._parseChoiceElement(t)){if(this._accept(2))continue;if(this._accept(7)&&(n.appendChild(t),this._accept(4)))return e.appendChild(n),!0}return this._backTo(i),!1}}}}_parseChoiceElement(e){const t=this._token,i=[];for(;2!==this._token.type&&7!==this._token.type;){let e;if(e=(e=this._accept(5,!0))?this._accept(2,!0)||this._accept(7,!0)||this._accept(5,!0)||e:this._accept(void 0,!0),!e)return this._backTo(t),!1;i.push(e)}return 0===i.length?(this._backTo(t),!1):(e.appendChild(new r(i.join(""))),!0)}_parseComplexVariable(e){let t;const i=this._token;if(!(this._accept(0)&&this._accept(3)&&(t=this._accept(9,!0))))return this._backTo(i);const n=new u(t);if(!this._accept(1))return this._accept(6)?this._parseTransform(n)?(e.appendChild(n),!0):(this._backTo(i),!1):this._accept(4)?(e.appendChild(n),!0):this._backTo(i);for(;;){if(this._accept(4))return e.appendChild(n),!0;if(!this._parse(n))return e.appendChild(new r("${"+t+":")),n.children.forEach(e.appendChild,e),!0}}_parseTransform(e){let t=new c,i="",n="";for(;!this._accept(6);){let e;if(e=this._accept(5,!0))e=this._accept(6,!0)||e,i+=e;else{if(14===this._token.type)return!1;i+=this._accept(void 0,!0)}}for(;!this._accept(6);){let e;if(e=this._accept(5,!0))e=this._accept(5,!0)||this._accept(6,!0)||e,t.appendChild(new r(e));else if(!this._parseFormatString(t)&&!this._parseAnything(t))return!1}for(;!this._accept(4);){if(14===this._token.type)return!1;n+=this._accept(void 0,!0)}try{t.regexp=new RegExp(i,n)}catch(e){return!1}return e.transform=t,!0}_parseFormatString(e){const t=this._token;if(!this._accept(0))return!1;let i=!1;this._accept(3)&&(i=!0);let n=this._accept(8,!0);if(!n)return this._backTo(t),!1;if(!i)return e.appendChild(new d(Number(n))),!0;if(this._accept(4))return e.appendChild(new d(Number(n))),!0;if(!this._accept(1))return this._backTo(t),!1;if(this._accept(6)){let i=this._accept(9,!0);return i&&this._accept(4)?(e.appendChild(new d(Number(n),i)),!0):(this._backTo(t),!1)}if(this._accept(11)){let t=this._until(4);if(t)return e.appendChild(new d(Number(n),void 0,t,void 0)),!0}else if(this._accept(12)){let t=this._until(4);if(t)return e.appendChild(new d(Number(n),void 0,void 0,t)),!0}else if(this._accept(13)){let t=this._until(1);if(t){let i=this._until(4);if(i)return e.appendChild(new d(Number(n),void 0,t,i)),!0}}else{let t=this._until(4);if(t)return e.appendChild(new d(Number(n),void 0,void 0,t)),!0}return this._backTo(t),!1}_parseAnything(e){return 14!==this._token.type&&(e.appendChild(new r(this._scanner.tokenText(this._token))),this._accept(void 0),!0)}}},12618:function(e,t,i){"use strict";i.d(t,{l:function(){return j}});var n=i(57800),o=i(4004),r=i(18039),s=i(93379),a=i.n(s),l=i(7795),c=i.n(l),d=i(90569),u=i.n(d),h=i(3565),g=i.n(h),p=i(19216),m=i.n(p),f=i(44589),_=i.n(f),b=i(842),v={};v.styleTagTransform=_(),v.setAttributes=g(),v.insert=u().bind(null,"head"),v.domAPI=c(),v.insertStyleElement=m(),a()(b.Z,v),b.Z&&b.Z.locals&&b.Z.locals;var C=i(92382),w=i(11465),y=i(59744),S=i(25732),x=i(99125),k=i(38630),L=i(57693),E=i(70722),N=i(14477),D=i(10804);const I=new Uint8Array(16),T=[];for(let e=0;e<256;e++)T.push(e.toString(16).padStart(2,"0"));let A;A="object"==typeof crypto&&"function"==typeof crypto.getRandomValues?crypto.getRandomValues.bind(crypto):function(e){for(let t=0;tt!==e&&(t instanceof L.xv&&(o=(0,r.V8)((0,r.uq)(t.value).pop())),!0)));const s=(0,r.Mh)(o,n);t=t.replace(/(\r\n|\r|\n)(.*)/g,((e,t,i)=>`${t}${o.substr(s)}${i}`))}return t}if("TM_CURRENT_LINE"===t)return this._model.getLineContent(this._selection.positionLineNumber);if("TM_CURRENT_WORD"===t){const e=this._model.getWordAtPosition({lineNumber:this._selection.positionLineNumber,column:this._selection.positionColumn});return e&&e.word||void 0}return"TM_LINE_INDEX"===t?String(this._selection.positionLineNumber-1):"TM_LINE_NUMBER"===t?String(this._selection.positionLineNumber):void 0}}class F{constructor(e,t){this._labelService=e,this._model=t}resolve(e){const{name:t}=e;if("TM_FILENAME"===t)return N.EZ(this._model.uri.fsPath);if("TM_FILENAME_BASE"===t){const e=N.EZ(this._model.uri.fsPath),t=e.lastIndexOf(".");return t<=0?e:e.slice(0,t)}return"TM_DIRECTORY"===t?"."===N.XX(this._model.uri.fsPath)?"":this._labelService.getUriLabel((0,D.XX)(this._model.uri)):"TM_FILEPATH"===t?this._labelService.getUriLabel(this._model.uri):"RELATIVE_FILEPATH"===t?this._labelService.getUriLabel(this._model.uri,{relative:!0,noPrefix:!0}):void 0}}class B{constructor(e,t,i,n){this._readClipboardText=e,this._selectionIdx=t,this._selectionCount=i,this._spread=n}resolve(e){if("CLIPBOARD"!==e.name)return;const t=this._readClipboardText();if(t){if(this._spread){const e=t.split(/\r\n|\n|\r/).filter((e=>!(0,r.m5)(e)));if(e.length===this._selectionCount)return e[this._selectionIdx]}return t}}}class W{constructor(e,t){this._model=e,this._selection=t}resolve(e){const{name:t}=e,i=this._model.getLanguageIdAtPosition(this._selection.selectionStartLineNumber,this._selection.selectionStartColumn),n=R.zu.getComments(i);if(n)return"LINE_COMMENT"===t?n.lineCommentToken||void 0:"BLOCK_COMMENT_START"===t?n.blockCommentStartToken||void 0:"BLOCK_COMMENT_END"===t&&n.blockCommentEndToken||void 0}}class V{constructor(){this._date=new Date}resolve(e){const{name:t}=e;return"CURRENT_YEAR"===t?String(this._date.getFullYear()):"CURRENT_YEAR_SHORT"===t?String(this._date.getFullYear()).slice(-2):"CURRENT_MONTH"===t?String(this._date.getMonth().valueOf()+1).padStart(2,"0"):"CURRENT_DATE"===t?String(this._date.getDate().valueOf()).padStart(2,"0"):"CURRENT_HOUR"===t?String(this._date.getHours().valueOf()).padStart(2,"0"):"CURRENT_MINUTE"===t?String(this._date.getMinutes().valueOf()).padStart(2,"0"):"CURRENT_SECOND"===t?String(this._date.getSeconds().valueOf()).padStart(2,"0"):"CURRENT_DAY_NAME"===t?V.dayNames[this._date.getDay()]:"CURRENT_DAY_NAME_SHORT"===t?V.dayNamesShort[this._date.getDay()]:"CURRENT_MONTH_NAME"===t?V.monthNames[this._date.getMonth()]:"CURRENT_MONTH_NAME_SHORT"===t?V.monthNamesShort[this._date.getMonth()]:"CURRENT_SECONDS_UNIX"===t?String(Math.floor(this._date.getTime()/1e3)):void 0}}V.dayNames=[M.NC("vs/editor/contrib/snippet/browser/snippetVariables","Sunday","Sunday"),M.NC("vs/editor/contrib/snippet/browser/snippetVariables","Monday","Monday"),M.NC("vs/editor/contrib/snippet/browser/snippetVariables","Tuesday","Tuesday"),M.NC("vs/editor/contrib/snippet/browser/snippetVariables","Wednesday","Wednesday"),M.NC("vs/editor/contrib/snippet/browser/snippetVariables","Thursday","Thursday"),M.NC("vs/editor/contrib/snippet/browser/snippetVariables","Friday","Friday"),M.NC("vs/editor/contrib/snippet/browser/snippetVariables","Saturday","Saturday")],V.dayNamesShort=[M.NC("vs/editor/contrib/snippet/browser/snippetVariables","SundayShort","Sun"),M.NC("vs/editor/contrib/snippet/browser/snippetVariables","MondayShort","Mon"),M.NC("vs/editor/contrib/snippet/browser/snippetVariables","TuesdayShort","Tue"),M.NC("vs/editor/contrib/snippet/browser/snippetVariables","WednesdayShort","Wed"),M.NC("vs/editor/contrib/snippet/browser/snippetVariables","ThursdayShort","Thu"),M.NC("vs/editor/contrib/snippet/browser/snippetVariables","FridayShort","Fri"),M.NC("vs/editor/contrib/snippet/browser/snippetVariables","SaturdayShort","Sat")],V.monthNames=[M.NC("vs/editor/contrib/snippet/browser/snippetVariables","January","January"),M.NC("vs/editor/contrib/snippet/browser/snippetVariables","February","February"),M.NC("vs/editor/contrib/snippet/browser/snippetVariables","March","March"),M.NC("vs/editor/contrib/snippet/browser/snippetVariables","April","April"),M.NC("vs/editor/contrib/snippet/browser/snippetVariables","May","May"),M.NC("vs/editor/contrib/snippet/browser/snippetVariables","June","June"),M.NC("vs/editor/contrib/snippet/browser/snippetVariables","July","July"),M.NC("vs/editor/contrib/snippet/browser/snippetVariables","August","August"),M.NC("vs/editor/contrib/snippet/browser/snippetVariables","September","September"),M.NC("vs/editor/contrib/snippet/browser/snippetVariables","October","October"),M.NC("vs/editor/contrib/snippet/browser/snippetVariables","November","November"),M.NC("vs/editor/contrib/snippet/browser/snippetVariables","December","December")],V.monthNamesShort=[M.NC("vs/editor/contrib/snippet/browser/snippetVariables","JanuaryShort","Jan"),M.NC("vs/editor/contrib/snippet/browser/snippetVariables","FebruaryShort","Feb"),M.NC("vs/editor/contrib/snippet/browser/snippetVariables","MarchShort","Mar"),M.NC("vs/editor/contrib/snippet/browser/snippetVariables","AprilShort","Apr"),M.NC("vs/editor/contrib/snippet/browser/snippetVariables","MayShort","May"),M.NC("vs/editor/contrib/snippet/browser/snippetVariables","JuneShort","Jun"),M.NC("vs/editor/contrib/snippet/browser/snippetVariables","JulyShort","Jul"),M.NC("vs/editor/contrib/snippet/browser/snippetVariables","AugustShort","Aug"),M.NC("vs/editor/contrib/snippet/browser/snippetVariables","SeptemberShort","Sep"),M.NC("vs/editor/contrib/snippet/browser/snippetVariables","OctoberShort","Oct"),M.NC("vs/editor/contrib/snippet/browser/snippetVariables","NovemberShort","Nov"),M.NC("vs/editor/contrib/snippet/browser/snippetVariables","DecemberShort","Dec")];class H{constructor(e){this._workspaceService=e}resolve(e){if(!this._workspaceService)return;const t=(0,k.uT)(this._workspaceService.getWorkspace());return t?"WORKSPACE_NAME"===e.name?this._resolveWorkspaceName(t):"WORKSPACE_FOLDER"===e.name?this._resoveWorkspacePath(t):void 0:void 0}_resolveWorkspaceName(e){if((0,k.eb)(e))return N.EZ(e.uri.path);let t=N.EZ(e.configPath.path);return t.endsWith(k.A6)&&(t=t.substr(0,t.length-k.A6.length-1)),t}_resoveWorkspacePath(e){if((0,k.eb)(e))return(0,E.D)(e.uri.fsPath);let t=N.EZ(e.configPath.path),i=e.configPath.fsPath;return i.endsWith(t)&&(i=i.substr(0,i.length-t.length-1)),i?(0,E.D)(i):"/"}}class z{resolve(e){const{name:t}=e;return"RANDOM"===t?Math.random().toString().slice(-6):"RANDOM_HEX"===t?Math.random().toString(16).slice(-6):"UUID"===t?function(){A(I),I[6]=15&I[6]|64,I[8]=63&I[8]|128;let e=0,t="";return t+=T[I[e++]],t+=T[I[e++]],t+=T[I[e++]],t+=T[I[e++]],t+="-",t+=T[I[e++]],t+=T[I[e++]],t+="-",t+=T[I[e++]],t+=T[I[e++]],t+="-",t+=T[I[e++]],t+=T[I[e++]],t+="-",t+=T[I[e++]],t+=T[I[e++]],t+=T[I[e++]],t+=T[I[e++]],t+=T[I[e++]],t+=T[I[e++]],t}():void 0}}class ${constructor(e,t,i,o){this._editor=e,this._snippet=t,this._offset=i,this._snippetLineLeadingWhitespace=o,this._nestingLevel=1,this._placeholderGroups=(0,n.vM)(t.placeholders,L.Vm.compareByIndex),this._placeholderGroupsIdx=-1}dispose(){this._placeholderDecorations&&this._editor.deltaDecorations([...this._placeholderDecorations.values()],[]),this._placeholderGroups.length=0}_initDecorations(){if(this._placeholderDecorations)return;this._placeholderDecorations=new Map;const e=this._editor.getModel();this._editor.changeDecorations((t=>{for(const i of this._snippet.placeholders){const n=this._snippet.offset(i),o=this._snippet.fullLen(i),r=w.e.fromPositions(e.getPositionAt(this._offset+n),e.getPositionAt(this._offset+n+o)),s=i.isFinalTabstop?$._decor.inactiveFinal:$._decor.inactive,a=t.addDecoration(r,s);this._placeholderDecorations.set(i,a)}}))}move(e){if(!this._editor.hasModel())return[];if(this._initDecorations(),this._placeholderGroupsIdx>=0){let e=[];for(const t of this._placeholderGroups[this._placeholderGroupsIdx])if(t.transform){const i=this._placeholderDecorations.get(t),n=this._editor.getModel().getDecorationRange(i),o=this._editor.getModel().getValueInRange(n),r=t.transform.resolve(o).split(/\r\n|\r|\n/);for(let e=1;e0&&this._editor.executeEdits("snippet.placeholderTransform",e)}let t=!1;!0===e&&this._placeholderGroupsIdx0&&(this._placeholderGroupsIdx-=1,t=!0);const i=this._editor.getModel().changeDecorations((e=>{const i=new Set,n=[];for(const o of this._placeholderGroups[this._placeholderGroupsIdx]){const r=this._placeholderDecorations.get(o),s=this._editor.getModel().getDecorationRange(r);n.push(new y.Y(s.startLineNumber,s.startColumn,s.endLineNumber,s.endColumn)),t=t&&this._hasPlaceholderBeenCollapsed(o),e.changeDecorationOptions(r,o.isFinalTabstop?$._decor.activeFinal:$._decor.active),i.add(o);for(const t of this._snippet.enclosingPlaceholders(o)){const n=this._placeholderDecorations.get(t);e.changeDecorationOptions(n,t.isFinalTabstop?$._decor.activeFinal:$._decor.active),i.add(t)}}for(const[t,n]of this._placeholderDecorations)i.has(t)||e.changeDecorationOptions(n,t.isFinalTabstop?$._decor.inactiveFinal:$._decor.inactive);return n}));return t?this.move(e):null!=i?i:[]}_hasPlaceholderBeenCollapsed(e){let t=e;for(;t;){if(t instanceof L.Vm){const e=this._placeholderDecorations.get(t);if(this._editor.getModel().getDecorationRange(e).isEmpty()&&t.toString().length>0)return!0}t=t.parent}return!1}get isAtFirstPlaceholder(){return this._placeholderGroupsIdx<=0||0===this._placeholderGroups.length}get isAtLastPlaceholder(){return this._placeholderGroupsIdx===this._placeholderGroups.length-1}get hasPlaceholder(){return this._snippet.placeholders.length>0}computePossibleSelections(){const e=new Map;for(const t of this._placeholderGroups){let i;for(const n of t){if(n.isFinalTabstop)break;i||(i=[],e.set(n.index,i));const t=this._placeholderDecorations.get(n),o=this._editor.getModel().getDecorationRange(t);if(!o){e.delete(n.index);break}i.push(o)}}return e}get choice(){return this._placeholderGroups[this._placeholderGroupsIdx][0].choice}merge(e){const t=this._editor.getModel();this._nestingLevel*=10,this._editor.changeDecorations((i=>{for(const n of this._placeholderGroups[this._placeholderGroupsIdx]){const o=e.shift();console.assert(!o._placeholderDecorations);const r=o._snippet.placeholderInfo.last.index;for(const e of o._snippet.placeholderInfo.all)e.isFinalTabstop?e.index=n.index+(r+1)/this._nestingLevel:e.index=n.index+e.index/this._nestingLevel;this._snippet.replace(n,o._snippet.children);const s=this._placeholderDecorations.get(n);i.removeDecoration(s),this._placeholderDecorations.delete(n);for(const e of o._snippet.placeholders){const n=o._snippet.offset(e),r=o._snippet.fullLen(e),s=w.e.fromPositions(t.getPositionAt(o._offset+n),t.getPositionAt(o._offset+n+r)),a=i.addDecoration(s,$._decor.inactive);this._placeholderDecorations.set(e,a)}}this._placeholderGroups=(0,n.vM)(this._snippet.placeholders,L.Vm.compareByIndex)}))}}$._decor={active:S.qx.register({description:"snippet-placeholder-1",stickiness:0,className:"snippet-placeholder"}),inactive:S.qx.register({description:"snippet-placeholder-2",stickiness:1,className:"snippet-placeholder"}),activeFinal:S.qx.register({description:"snippet-placeholder-3",stickiness:1,className:"finish-snippet-placeholder"}),inactiveFinal:S.qx.register({description:"snippet-placeholder-4",stickiness:1,className:"finish-snippet-placeholder"})};const U={overwriteBefore:0,overwriteAfter:0,adjustWhitespace:!0,clipboardText:void 0,overtypingCapturer:void 0};class j{constructor(e,t,i=U){this._templateMerges=[],this._snippets=[],this._editor=e,this._template=t,this._options=i}static adjustWhitespace(e,t,i,n,o){const s=e.getLineContent(t.lineNumber),a=(0,r.V8)(s,0,t.column-1);let l;return i.walk((t=>{if(!(t instanceof L.xv)||t.parent instanceof L.Lv)return!0;const o=t.value.split(/\r\n|\r|\n/);if(n){const n=i.offset(t);if(0===n)o[0]=e.normalizeIndentation(o[0]);else{l=null!=l?l:i.toString();let t=l.charCodeAt(n-1);10!==t&&13!==t||(o[0]=e.normalizeIndentation(a+o[0]))}for(let t=1;te.get(k.ec))),h=e.invokeWithinContext((e=>new F(e.get(x.e),d))),g=()=>s;let p=0,m=d.getValueInRange(j.adjustSelection(d,e.getSelection(),i,0)),f=d.getValueInRange(j.adjustSelection(d,e.getSelection(),0,n)),_=d.getLineFirstNonWhitespaceColumn(e.getSelection().positionLineNumber);const b=e.getSelections().map(((e,t)=>({selection:e,idx:t}))).sort(((e,t)=>w.e.compareRangesUsingStarts(e.selection,t.selection)));for(const{selection:s,idx:v}of b){let w=j.adjustSelection(d,s,i,0),y=j.adjustSelection(d,s,0,n);m!==d.getValueInRange(w)&&(w=s),f!==d.getValueInRange(y)&&(y=s);const S=s.setStartPosition(w.startLineNumber,w.startColumn).setEndPosition(y.endLineNumber,y.endColumn),x=(new L.Yj).parse(t,!0,o),k=S.getStartPosition(),E=j.adjustWhitespace(d,k,x,r||v>0&&_!==d.getLineFirstNonWhitespaceColumn(s.positionLineNumber),!0);x.resolveVariables(new O([h,new B(g,v,b.length,"spread"===e.getOption(71)),new P(d,s,v,a),new W(d,s),new V,new H(u),new z]));const N=d.getOffsetAt(k)+p;p+=x.toString().length-d.getValueLengthInRange(S),l[v]=C.h.replace(S,x.toString()),l[v].identifier={major:v,minor:0},c[v]=new $(e,x,N,E)}return{edits:l,snippets:c}}dispose(){(0,o.B9)(this._snippets)}_logInfo(){return`template="${this._template}", merged_templates="${this._templateMerges.join(" -> ")}"`}insert(){if(!this._editor.hasModel())return;const{edits:e,snippets:t}=j.createEditsAndSnippets(this._editor,this._template,this._options.overwriteBefore,this._options.overwriteAfter,!1,this._options.adjustWhitespace,this._options.clipboardText,this._options.overtypingCapturer);this._snippets=t,this._editor.executeEdits("snippet",e,(e=>this._snippets[0].hasPlaceholder?this._move(!0):e.filter((e=>!!e.identifier)).map((e=>y.Y.fromPositions(e.range.getEndPosition()))))),this._editor.revealRange(this._editor.getSelections()[0])}merge(e,t=U){if(!this._editor.hasModel())return;this._templateMerges.push([this._snippets[0]._nestingLevel,this._snippets[0]._placeholderGroupsIdx,e]);const{edits:i,snippets:n}=j.createEditsAndSnippets(this._editor,e,t.overwriteBefore,t.overwriteAfter,!0,t.adjustWhitespace,t.clipboardText,t.overtypingCapturer);this._editor.executeEdits("snippet",i,(e=>{for(const e of this._snippets)e.merge(n);return console.assert(0===n.length),this._snippets[0].hasPlaceholder?this._move(void 0):e.filter((e=>!!e.identifier)).map((e=>y.Y.fromPositions(e.range.getEndPosition())))}))}next(){const e=this._move(!0);this._editor.setSelections(e),this._editor.revealPositionInCenterIfOutsideViewport(e[0].getPosition())}prev(){const e=this._move(!1);this._editor.setSelections(e),this._editor.revealPositionInCenterIfOutsideViewport(e[0].getPosition())}_move(e){const t=[];for(const i of this._snippets){const n=i.move(e);t.push(...n)}return t}get isAtFirstPlaceholder(){return this._snippets[0].isAtFirstPlaceholder}get isAtLastPlaceholder(){return this._snippets[0].isAtLastPlaceholder}get hasPlaceholder(){return this._snippets[0].hasPlaceholder}get choice(){return this._snippets[0].choice}isSelectionWithinPlaceholders(){if(!this.hasPlaceholder)return!1;const e=this._editor.getSelections();if(e.length{e.push(...n.get(t))}))}e.sort(w.e.compareRangesUsingStarts);for(let[i,n]of t)if(n.length===e.length){n.sort(w.e.compareRangesUsingStarts);for(let o=0;o0}}},64795:function(e,t,i){"use strict";i.d(t,{A9:function(){return x},GI:function(){return y},ZJ:function(){return k},_y:function(){return w},i5:function(){return R},kL:function(){return E},wg:function(){return I}});var n=i(60677),o=i(16182),r=i(34604),s=i(4004),a=i(52150),l=i(28295),c=i(39675),d=i(72248),u=i(11465),h=i(20010),g=i(57693),p=i(89982),m=i(3337),f=i(14756),_=i(60393),b=i(66988),v=i(84701),C=function(e,t,i,n){return new(i||(i=Promise))((function(o,r){function s(e){try{l(n.next(e))}catch(e){r(e)}}function a(e){try{l(n.throw(e))}catch(e){r(e)}}function l(e){var t;e.done?o(e.value):(t=e.value,t instanceof i?t:new i((function(e){e(t)}))).then(s,a)}l((n=n.apply(e,t||[])).next())}))};const w={Visible:v.iX,DetailsVisible:new _.uy("suggestWidgetDetailsVisible",!1,(0,p.NC)("vs/editor/contrib/suggest/browser/suggest","suggestWidgetDetailsVisible","Whether suggestion details are visible")),MultipleSuggestions:new _.uy("suggestWidgetMultipleSuggestions",!1,(0,p.NC)("vs/editor/contrib/suggest/browser/suggest","suggestWidgetMultipleSuggestions","Whether there are multiple suggestions to pick from")),MakesTextEdit:new _.uy("suggestionMakesTextEdit",!0,(0,p.NC)("vs/editor/contrib/suggest/browser/suggest","suggestionMakesTextEdit","Whether inserting the current suggestion yields in a change or has everything already been typed")),AcceptSuggestionsOnEnter:new _.uy("acceptSuggestionOnEnter",!0,(0,p.NC)("vs/editor/contrib/suggest/browser/suggest","acceptSuggestionOnEnter","Whether suggestions are inserted when pressing Enter")),HasInsertAndReplaceRange:new _.uy("suggestionHasInsertAndReplaceRange",!1,(0,p.NC)("vs/editor/contrib/suggest/browser/suggest","suggestionHasInsertAndReplaceRange","Whether the current suggestion has insert and replace behaviour")),InsertMode:new _.uy("suggestionInsertMode",void 0,{type:"string",description:(0,p.NC)("vs/editor/contrib/suggest/browser/suggest","suggestionInsertMode","Whether the default behaviour is to insert or replace")}),CanResolve:new _.uy("suggestionCanResolve",!1,(0,p.NC)("vs/editor/contrib/suggest/browser/suggest","suggestionCanResolve","Whether the current suggestion supports to resolve further details"))},y=new m.eH("suggestWidgetStatusBar");class S{constructor(e,t,i,n){this.position=e,this.completion=t,this.container=i,this.provider=n,this.isInvalid=!1,this.score=r.CL.Default,this.distance=0,this.textLabel="string"==typeof t.label?t.label:t.label.label,this.labelLow=this.textLabel.toLowerCase(),this.isInvalid=!this.textLabel,this.sortTextLow=t.sortText&&t.sortText.toLowerCase(),this.filterTextLow=t.filterText&&t.filterText.toLowerCase(),u.e.isIRange(t.range)?(this.editStart=new d.L(t.range.startLineNumber,t.range.startColumn),this.editInsertEnd=new d.L(t.range.endLineNumber,t.range.endColumn),this.editReplaceEnd=new d.L(t.range.endLineNumber,t.range.endColumn),this.isInvalid=this.isInvalid||u.e.spansMultipleLines(t.range)||t.range.startLineNumber!==e.lineNumber):(this.editStart=new d.L(t.range.insert.startLineNumber,t.range.insert.startColumn),this.editInsertEnd=new d.L(t.range.insert.endLineNumber,t.range.insert.endColumn),this.editReplaceEnd=new d.L(t.range.replace.endLineNumber,t.range.replace.endColumn),this.isInvalid=this.isInvalid||u.e.spansMultipleLines(t.range.insert)||u.e.spansMultipleLines(t.range.replace)||t.range.insert.startLineNumber!==e.lineNumber||t.range.replace.startLineNumber!==e.lineNumber||t.range.insert.startColumn!==t.range.replace.startColumn),"function"!=typeof n.resolveCompletionItem&&(this._resolveCache=Promise.resolve(),this._isResolved=!0)}get isResolved(){return!!this._isResolved}resolve(e){return C(this,void 0,void 0,(function*(){if(!this._resolveCache){const t=e.onCancellationRequested((()=>{this._resolveCache=void 0,this._isResolved=!1}));this._resolveCache=Promise.resolve(this.provider.resolveCompletionItem(this.completion,e)).then((e=>{Object.assign(this.completion,e),this._isResolved=!0,t.dispose()}),(e=>{(0,o.n2)(e)&&(this._resolveCache=void 0,this._isResolved=!1)}))}return this._resolveCache}))}}class x{constructor(e=2,t=new Set,i=new Set,n=!0){this.snippetSortOrder=e,this.kindFilter=t,this.providerFilter=i,this.showDeprecated=n}}function k(){}x.default=new x;class L{constructor(e,t,i,n){this.items=e,this.needsClipboard=t,this.durations=i,this.disposable=n}}function E(e,t,i,r=x.default,l={triggerKind:0},c=n.T.None){return C(this,void 0,void 0,(function*(){const n=new a.G(!0);i=i.clone();const d=t.getWordAtPosition(i),h=d?new u.e(i.lineNumber,d.startColumn,i.lineNumber,d.endColumn):u.e.fromPositions(i),p={replace:h,insert:h.setEndPosition(i.lineNumber,i.column)},m=[],f=new s.SL,_=[];let b=!1;const v=(e,t,n)=>{var o,a,l;let c=!1;if(!t)return c;for(let n of t.suggestions)if(!r.kindFilter.has(n.kind)){if(!r.showDeprecated&&(null===(o=null==n?void 0:n.tags)||void 0===o?void 0:o.includes(1)))continue;n.range||(n.range=p),n.sortText||(n.sortText="string"==typeof n.label?n.label:n.label.label),!b&&n.insertTextRules&&4&n.insertTextRules&&(b=g.Yj.guessNeedsClipboard(n.insertText)),m.push(new S(i,n,t,e)),c=!0}return(0,s.Wf)(t)&&f.add(t),_.push({providerName:null!==(a=e._debugDisplayName)&&void 0!==a?a:"unknown_provider",elapsedProvider:null!==(l=t.duration)&&void 0!==l?l:-1,elapsedOverall:n.elapsed()}),c},w=(()=>C(this,void 0,void 0,(function*(){})))();for(let n of e.orderedGroups(t)){let e=!1;if(yield Promise.all(n.map((n=>C(this,void 0,void 0,(function*(){if(!(r.providerFilter.size>0)||r.providerFilter.has(n))try{const o=new a.G(!0),r=yield n.provideCompletionItems(t,i,l,c);e=v(n,r,o)||e}catch(e){(0,o.Cp)(e)}}))))),e||c.isCancellationRequested)break}return yield w,c.isCancellationRequested?(f.dispose(),Promise.reject((0,o.F0)())):new L(m.sort(I(r.snippetSortOrder)),b,{entries:_,elapsed:n.elapsed()},f)}))}function N(e,t){if(e.sortTextLow&&t.sortTextLow){if(e.sortTextLowt.sortTextLow)return 1}return e.completion.labelt.completion.label?1:e.completion.kind-t.completion.kind}const D=new Map;function I(e){return D.get(e)}let T;D.set(0,(function(e,t){if(e.completion.kind!==t.completion.kind){if(27===e.completion.kind)return-1;if(27===t.completion.kind)return 1}return N(e,t)})),D.set(2,(function(e,t){if(e.completion.kind!==t.completion.kind){if(27===e.completion.kind)return 1;if(27===t.completion.kind)return-1}return N(e,t)})),D.set(1,N),f.P0.registerCommand("_executeCompletionItemProvider",((e,...t)=>C(void 0,void 0,void 0,(function*(){const[i,o,r,s]=t;(0,l.p_)(c.o.isUri(i)),(0,l.p_)(d.L.isIPosition(o)),(0,l.p_)("string"==typeof r||!r),(0,l.p_)("number"==typeof s||!s);const{completionProvider:a}=e.get(b.p),u=yield e.get(h.S).createModelReference(i);try{const e={incomplete:!1,suggestions:[]},t=[],i=yield E(a,u.object.textEditorModel,d.L.lift(o),void 0,{triggerCharacter:r,triggerKind:r?1:0});for(const o of i.items)t.length<(null!=s?s:0)&&t.push(o.resolve(n.T.None)),e.incomplete=e.incomplete||o.container.incomplete,e.suggestions.push(o.completion);try{return yield Promise.all(t),e}finally{setTimeout((()=>i.disposable.dispose()),100)}}finally{u.dispose()}}))));let A=[];function R(e,t,i){const{completionProvider:n}=e.get(b.p);T||(T=new class{provideCompletionItems(){let e={suggestions:A.slice(0)};return A.length=0,e}},n.register("*",T)),setTimeout((()=>{var e;A.push(...i),null===(e=t.getContribution("editor.contrib.suggestController"))||void 0===e||e.triggerSuggest((new Set).add(T))}),0)}},1266:function(e,t,i){"use strict";i.r(t),i.d(t,{SuggestController:function(){return ft},TriggerSuggestAction:function(){return bt}});var n=i(77339),o=i(57800),r=i(40027),s=i(60677),a=i(16182),l=i(46718),c=i(99410),d=i(4004),u=i(6954),h=i(52150),g=i(28295),p=i(87107),m=i(4189),f=i(92382),_=i(72248),b=i(11465),v=i(38673),C=i(29820),w=i(57693),y=i(38455),S=i(74893),x=i(40539),k=i(14472),L=i(12260),E=i(86303),N=function(e,t){return function(i,n){t(i,n,e)}};class D{constructor(e){this.name=e}select(e,t,i){if(0===i.length)return 0;let n=i[0].score[0];for(let e=0;ethis._saveState()),500),this._disposables.add(e.onWillSaveState((e=>{e.reason===E.fk.SHUTDOWN&&this._saveState()})))}dispose(){this._disposables.dispose(),this._persistSoon.dispose()}memorize(e,t,i){this._withStrategy(e,t).memorize(e,t,i),this._persistSoon.schedule()}select(e,t,i){return this._withStrategy(e,t).select(e,t,i)}_withStrategy(t,i){var n;const o=this._configService.getValue("editor.suggestSelection",{overrideIdentifier:t.getLanguageIdAtPosition(i.lineNumber,i.column),resource:t.uri});if((null===(n=this._strategy)||void 0===n?void 0:n.name)!==o){this._saveState();const t=e._strategyCtors.get(o)||I;this._strategy=new t;try{const t=this._configService.getValue("editor.suggest.shareSuggestSelections")?0:1,i=this._storageService.get(`${e._storagePrefix}/${o}`,t);i&&this._strategy.fromJSON(JSON.parse(i))}catch(e){}}return this._strategy}_saveState(){if(this._strategy){const t=this._configService.getValue("editor.suggest.shareSuggestSelections")?0:1,i=JSON.stringify(this._strategy);this._storageService.store(`${e._storagePrefix}/${this._strategy.name}`,i,t,1)}}};T._strategyCtors=new Map([["recentlyUsedByPrefix",class extends D{constructor(){super("recentlyUsedByPrefix"),this._trie=y.Id.forStrings(),this._seq=0}memorize(e,t,i){const{word:n}=e.getWordUntilPosition(t),o=`${e.getLanguageId()}/${n}`;this._trie.set(o,{type:i.completion.kind,insertText:i.completion.insertText,touch:this._seq++})}select(e,t,i){let{word:n}=e.getWordUntilPosition(t);if(!n)return super.select(e,t,i);let o=`${e.getLanguageId()}/${n}`,r=this._trie.get(o);if(r||(r=this._trie.findSubstr(o)),r)for(let e=0;ee.push([i,t]))),e.sort(((e,t)=>-(e[1].touch-t[1].touch))).forEach(((e,t)=>e[1].touch=t)),e.slice(0,200)}fromJSON(e){if(this._trie.clear(),e.length>0){this._seq=e[0][1].touch+1;for(const[t,i]of e)i.type="number"==typeof i.type?i.type:S.gX.fromString(i.type),this._trie.set(t,i)}}}],["recentlyUsed",class extends D{constructor(){super("recentlyUsed"),this._cache=new y.z6(300,.66),this._seq=0}memorize(e,t,i){const n=`${e.getLanguageId()}/${i.textLabel}`;this._cache.set(n,{touch:this._seq++,type:i.completion.kind,insertText:i.completion.insertText})}select(e,t,i){if(0===i.length)return 0;const n=e.getLineContent(t.lineNumber).substr(t.column-10,t.column-1);if(/\s$/.test(n))return super.select(e,t,i);let o=i[0].score[0],r=-1,s=-1;for(let t=0;ts&&o.type===i[t].completion.kind&&o.insertText===i[t].completion.insertText&&(s=o.touch,r=t),i[t].completion.preselect)return t}return-1!==r?r:0}toJSON(){return this._cache.toJSON()}fromJSON(e){this._cache.clear();for(const[t,i]of e)i.touch=0,i.type="number"==typeof i.type?i.type:S.gX.fromString(i.type),this._cache.set(t,i);this._seq=this._cache.size}}],["first",I]]),T._storagePrefix="suggest/memories",T=function(e,t,i,n){var o,r=arguments.length,s=r<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,i):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(e,t,i,n);else for(var a=e.length-1;a>=0;a--)(o=e[a])&&(s=(r<3?o(s):r>3?o(t,i,s):o(t,i))||s);return r>3&&s&&Object.defineProperty(t,i,s),s}([N(0,E.Uy),N(1,x.Ui)],T);const A=(0,L.yh)("ISuggestMemories");(0,k.z)(A,T,!0);var R=i(60393);let M=class e{constructor(t,i){this._editor=t,this._enabled=!1,this._ckAtEnd=e.AtEnd.bindTo(i),this._configListener=this._editor.onDidChangeConfiguration((e=>e.hasChanged(111)&&this._update())),this._update()}dispose(){var e;this._configListener.dispose(),null===(e=this._selectionListener)||void 0===e||e.dispose(),this._ckAtEnd.reset()}_update(){const e="on"===this._editor.getOption(111);if(this._enabled!==e)if(this._enabled=e,this._enabled){const e=()=>{if(!this._editor.hasModel())return void this._ckAtEnd.set(!1);const e=this._editor.getModel(),t=this._editor.getSelection(),i=e.getWordAtPosition(t.getStartPosition());i?this._ckAtEnd.set(i.endColumn===t.getStartPosition().column):this._ckAtEnd.set(!1)};this._selectionListener=this._editor.onDidChangeCursorSelection(e),e()}else this._selectionListener&&(this._ckAtEnd.reset(),this._selectionListener.dispose(),this._selectionListener=void 0)}};var O,P;M.AtEnd=new R.uy("atEndOfWord",!1),M=function(e,t,i,n){var o,r=arguments.length,s=r<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,i):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(e,t,i,n);else for(var a=e.length-1;a>=0;a--)(o=e[a])&&(s=(r<3?o(s):r>3?o(t,i,s):o(t,i))||s);return r>3&&s&&Object.defineProperty(t,i,s),s}([(O=1,P=R.i6,function(e,t){P(e,t,O)})],M);var F=i(89982),B=i(3337),W=i(14756),V=i(77101),H=i(16592),z=i(64795);let $=class e{constructor(t,i){this._editor=t,this._index=0,this._ckOtherSuggestions=e.OtherSuggestions.bindTo(i)}dispose(){this.reset()}reset(){var e;this._ckOtherSuggestions.reset(),null===(e=this._listener)||void 0===e||e.dispose(),this._model=void 0,this._acceptNext=void 0,this._ignore=!1}set({model:t,index:i},n){0!==t.items.length&&e._moveIndex(!0,t,i)!==i?(this._acceptNext=n,this._model=t,this._index=i,this._listener=this._editor.onDidChangeCursorPosition((()=>{this._ignore||this.reset()})),this._ckOtherSuggestions.set(!0)):this.reset()}static _moveIndex(e,t,i){let n=i;for(;n=(n+t.items.length+(e?1:-1))%t.items.length,n!==i&&t.items[n].completion.additionalTextEdits;);return n}next(){this._move(!0)}prev(){this._move(!1)}_move(t){if(this._model)try{this._ignore=!0,this._index=e._moveIndex(t,this._model,this._index),this._acceptNext({index:this._index,item:this._model.items[this._index],model:this._model})}finally{this._ignore=!1}}};$.OtherSuggestions=new R.uy("hasOtherSuggestions",!1),$=function(e,t,i,n){var o,r=arguments.length,s=r<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,i):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(e,t,i,n);else for(var a=e.length-1;a>=0;a--)(o=e[a])&&(s=(r<3?o(s):r>3?o(t,i,s):o(t,i))||s);return r>3&&s&&Object.defineProperty(t,i,s),s}([function(e,t){return function(i,n){t(i,n,e)}}(1,R.i6)],$);var U=i(93423);class j{constructor(e,t,i){this._disposables=new d.SL,this._disposables.add(t.onDidShow((()=>this._onItem(t.getFocusedItem())))),this._disposables.add(t.onDidFocus(this._onItem,this)),this._disposables.add(t.onDidHide(this.reset,this)),this._disposables.add(e.onWillType((n=>{if(this._active&&!t.isFrozen()){const t=n.charCodeAt(n.length-1);this._active.acceptCharacters.has(t)&&e.getOption(0)&&i(this._active.item)}})))}_onItem(e){if(!e||!(0,o.Of)(e.item.completion.commitCharacters))return void this.reset();if(this._active&&this._active.item.item===e.item)return;const t=new U.q;for(const i of e.item.completion.commitCharacters)i.length>0&&t.add(i.charCodeAt(0));this._active={acceptCharacters:t,item:e}}reset(){this._active=void 0}dispose(){this._disposables.dispose()}}var K=i(18039),q=i(59744),G=i(22157),Z=i(75058);class Y{static create(e,t){return i=this,n=void 0,s=function*(){if(!t.getOption(106).localityBonus)return Y.None;if(!t.hasModel())return Y.None;const i=t.getModel(),n=t.getPosition();if(!e.canComputeWordRanges(i.uri))return Y.None;const[r]=yield(new Z.x).provideSelectionRanges(i,[n]);if(0===r.length)return Y.None;const s=yield e.computeWordRanges(i.uri,r[0].range);if(!s)return Y.None;const a=i.getWordUntilPosition(n);return delete s[a.word],new class extends Y{distance(e,i){if(!n.equals(t.getPosition()))return 0;if(17===i.kind)return 2<<20;let a="string"==typeof i.label?i.label:i.label.label,l=s[a];if((0,o.XY)(l))return 2<<20;let c=(0,o.ry)(l,b.e.fromPositions(e),b.e.compareRangesUsingStarts),d=c>=0?l[c]:l[Math.max(0,~c-1)],u=r.length;for(const e of r){if(!b.e.containsRange(e.range,d))break;u-=1}return u}}},new((r=void 0)||(r=Promise))((function(e,t){function o(e){try{l(s.next(e))}catch(e){t(e)}}function a(e){try{l(s.throw(e))}catch(e){t(e)}}function l(t){var i;t.done?e(t.value):(i=t.value,i instanceof r?i:new r((function(e){e(i)}))).then(o,a)}l((s=s.apply(i,n||[])).next())}));var i,n,r,s}}Y.None=new class extends Y{distance(){return 0}};var Q=i(22837),X=i(56080),J=i(34604);class ee{constructor(e,t,i,n,o,r,s){this.clipboardText=s,this._snippetCompareFn=ee._compareCompletionItems,this._items=e,this._column=t,this._wordDistance=n,this._options=o,this._refilterKind=1,this._lineContext=i,"top"===r?this._snippetCompareFn=ee._compareCompletionItemsSnippetsUp:"bottom"===r&&(this._snippetCompareFn=ee._compareCompletionItemsSnippetsDown)}get lineContext(){return this._lineContext}set lineContext(e){this._lineContext.leadingLineContent===e.leadingLineContent&&this._lineContext.characterCountDelta===e.characterCountDelta||(this._refilterKind=this._lineContext.characterCountDelta2e3?J.EW:J.l7;for(let o=0;o=u)c.score=J.CL.Default;else if("string"==typeof c.completion.filterText){let t=l(n,r,e,c.completion.filterText,c.filterTextLow,0,!1);if(!t)continue;0===(0,K.zY)(c.completion.filterText,c.textLabel)?c.score=t:(c.score=(0,J.jB)(n,r,e,c.textLabel,c.labelLow,0),c.score[0]=t[0])}else{let t=l(n,r,e,c.textLabel,c.labelLow,0,!1);if(!t)continue;c.score=t}}c.idx=o,c.distance=this._wordDistance.distance(c.position,c.completion),a.push(c),e.push(c.textLabel.length)}this._filteredItems=a.sort(this._snippetCompareFn),this._refilterKind=0,this._stats={pLabelLen:e.length?(0,o.HW)(e.length-.85,e,((e,t)=>e-t)):0}}static _compareCompletionItems(e,t){return e.score[0]>t.score[0]?-1:e.score[0]t.distance?1:e.idxt.idx?1:0}static _compareCompletionItemsSnippetsDown(e,t){if(e.completion.kind!==t.completion.kind){if(27===e.completion.kind)return 1;if(27===t.completion.kind)return-1}return ee._compareCompletionItems(e,t)}static _compareCompletionItemsSnippetsUp(e,t){if(e.completion.kind!==t.completion.kind){if(27===e.completion.kind)return-1;if(27===t.completion.kind)return 1}return ee._compareCompletionItems(e,t)}}var te=i(66988),ie=function(e,t){return function(i,n){t(i,n,e)}};class ne{constructor(e,t,i,n){this.leadingLineContent=e.getLineContent(t.lineNumber).substr(0,t.column-1),this.leadingWord=e.getWordUntilPosition(t),this.lineNumber=t.lineNumber,this.column=t.column,this.auto=i,this.shy=n}static shouldAutoTrigger(e){if(!e.hasModel())return!1;const t=e.getModel(),i=e.getPosition();t.tokenizeIfCheap(i.lineNumber);const n=t.getWordAtPosition(i);return!!n&&n.endColumn===i.column&&!!isNaN(Number(n.word))}}let oe=class e{constructor(e,t,i,n,o,s,a,c){this._editor=e,this._editorWorkerService=t,this._clipboardService=i,this._telemetryService=n,this._logService=o,this._contextKeyService=s,this._configurationService=a,this._languageFeaturesService=c,this._toDispose=new d.SL,this._quickSuggestDelay=10,this._triggerCharacterListener=new d.SL,this._triggerQuickSuggest=new r._F,this._state=0,this._completionDisposables=new d.SL,this._onDidCancel=new l.Q5,this._onDidTrigger=new l.Q5,this._onDidSuggest=new l.Q5,this.onDidCancel=this._onDidCancel.event,this.onDidTrigger=this._onDidTrigger.event,this.onDidSuggest=this._onDidSuggest.event,this._telemetryGate=0,this._currentSelection=this._editor.getSelection()||new q.Y(1,1,1,1),this._toDispose.add(this._editor.onDidChangeModel((()=>{this._updateTriggerCharacters(),this.cancel()}))),this._toDispose.add(this._editor.onDidChangeModelLanguage((()=>{this._updateTriggerCharacters(),this.cancel()}))),this._toDispose.add(this._editor.onDidChangeConfiguration((()=>{this._updateTriggerCharacters(),this._updateQuickSuggest()}))),this._toDispose.add(this._languageFeaturesService.completionProvider.onDidChange((()=>{this._updateTriggerCharacters(),this._updateActiveSuggestSession()})));let u=!1;this._toDispose.add(this._editor.onDidCompositionStart((()=>{u=!0}))),this._toDispose.add(this._editor.onDidCompositionEnd((()=>{u=!1,this._onCompositionEnd()}))),this._toDispose.add(this._editor.onDidChangeCursorSelection((e=>{u||this._onCursorChange(e)}))),this._toDispose.add(this._editor.onDidChangeModelContent((()=>{u||this._refilterCompletionItems()}))),this._updateTriggerCharacters(),this._updateQuickSuggest()}dispose(){(0,d.B9)(this._triggerCharacterListener),(0,d.B9)([this._onDidCancel,this._onDidSuggest,this._onDidTrigger,this._triggerQuickSuggest]),this._toDispose.dispose(),this._completionDisposables.dispose(),this.cancel()}_updateQuickSuggest(){this._quickSuggestDelay=this._editor.getOption(80),(isNaN(this._quickSuggestDelay)||!this._quickSuggestDelay&&0!==this._quickSuggestDelay||this._quickSuggestDelay<0)&&(this._quickSuggestDelay=10)}_updateTriggerCharacters(){if(this._triggerCharacterListener.clear(),this._editor.getOption(81)||!this._editor.hasModel()||!this._editor.getOption(109))return;const e=new Map;for(const t of this._languageFeaturesService.completionProvider.all(this._editor.getModel()))for(const i of t.triggerCharacters||[]){let n=e.get(i);n||(n=new Set,n.add((0,z.ZJ)()),e.set(i,n)),n.add(t)}const t=t=>{if(!function(e,t,i){if(!Boolean(t.getContextKeyValue("inlineSuggestionVisible")))return!0;const n=i.getValue("editor.inlineSuggest.allowSuggestOnTriggerCharacters");return void 0!==n&&Boolean(n)}(this._editor,this._contextKeyService,this._configurationService))return;if(ne.shouldAutoTrigger(this._editor))return;if(!t){const e=this._editor.getPosition();t=this._editor.getModel().getLineContent(e.lineNumber).substr(0,e.column-1)}let i="";(0,K.YK)(t.charCodeAt(t.length-1))?(0,K.ZG)(t.charCodeAt(t.length-2))&&(i=t.substr(t.length-2)):i=t.charAt(t.length-1);const n=e.get(i);if(n){const e=this._completionModel?{items:this._completionModel.adopt(n),clipboardText:this._completionModel.clipboardText}:void 0;this.trigger({auto:!0,shy:!1,triggerCharacter:i},Boolean(this._completionModel),n,e)}};this._triggerCharacterListener.add(this._editor.onDidType(t)),this._triggerCharacterListener.add(this._editor.onDidCompositionEnd((()=>t())))}get state(){return this._state}cancel(e=!1){var t;0!==this._state&&(this._triggerQuickSuggest.cancel(),null===(t=this._requestToken)||void 0===t||t.cancel(),this._requestToken=void 0,this._state=0,this._completionModel=void 0,this._context=void 0,this._onDidCancel.fire({retrigger:e}))}clear(){this._completionDisposables.clear()}_updateActiveSuggestSession(){0!==this._state&&(this._editor.hasModel()&&this._languageFeaturesService.completionProvider.has(this._editor.getModel())?this.trigger({auto:2===this._state,shy:!1},!0):this.cancel())}_onCursorChange(e){if(!this._editor.hasModel())return;const t=this._currentSelection;this._currentSelection=this._editor.getSelection(),!e.selection.isEmpty()||0!==e.reason&&3!==e.reason||"keyboard"!==e.source&&"deleteLeft"!==e.source?this.cancel():0===this._state&&0===e.reason?(t.containsRange(this._currentSelection)||t.getEndPosition().isBeforeOrEqual(this._currentSelection.getPosition()))&&this._doTriggerQuickSuggest():0!==this._state&&3===e.reason&&this._refilterCompletionItems()}_onCompositionEnd(){0===this._state?this._doTriggerQuickSuggest():this._refilterCompletionItems()}_doTriggerQuickSuggest(){var e;!1!==this._editor.getOption(79)&&(this._editor.getOption(106).snippetsPreventQuickSuggestions&&(null===(e=C.SnippetController2.get(this._editor))||void 0===e?void 0:e.isInSnippet())||(this.cancel(),this._triggerQuickSuggest.cancelAndSet((()=>{if(0!==this._state)return;if(!ne.shouldAutoTrigger(this._editor))return;if(!this._editor.hasModel())return;const e=this._editor.getModel(),t=this._editor.getPosition(),i=this._editor.getOption(79);if(!1!==i){if(!0===i);else{e.tokenizeIfCheap(t.lineNumber);const n=e.getLineTokens(t.lineNumber),o=n.getStandardTokenType(n.findTokenIndexAtOffset(Math.max(t.column-1-1,0)));if(!(i.other&&0===o||i.comments&&1===o||i.strings&&2===o))return}(function(e,t,i){if(!Boolean(t.getContextKeyValue("inlineSuggestionVisible")))return!0;const n=i.getValue("editor.inlineSuggest.allowQuickSuggestions");return void 0!==n&&Boolean(n)})(this._editor,this._contextKeyService,this._configurationService)&&this._languageFeaturesService.completionProvider.has(e)&&this.trigger({auto:!0,shy:!1})}}),this._quickSuggestDelay)))}_refilterCompletionItems(){Promise.resolve().then((()=>{if(0===this._state)return;if(!this._editor.hasModel())return;const e=this._editor.getModel(),t=this._editor.getPosition(),i=new ne(e,t,2===this._state,!1);this._onNewContext(i)}))}trigger(t,i=!1,n,o){var r;if(!this._editor.hasModel())return;const l=this._editor.getModel(),c=t.auto,d=new ne(l,this._editor.getPosition(),c,t.shy);this.cancel(i),this._state=c?2:1,this._onDidTrigger.fire({auto:c,shy:t.shy,position:this._editor.getPosition()}),this._context=d;let u={triggerKind:null!==(r=t.triggerKind)&&void 0!==r?r:0};t.triggerCharacter&&(u={triggerKind:1,triggerCharacter:t.triggerCharacter}),this._requestToken=new s.A;const h=this._editor.getOption(101);let g=1;switch(h){case"top":g=0;break;case"bottom":g=2}const{itemKind:p,showDeprecated:m}=e._createSuggestFilter(this._editor),f=Y.create(this._editorWorkerService,this._editor),_=(0,z.kL)(this._languageFeaturesService.completionProvider,l,this._editor.getPosition(),new z.A9(g,p,n,m),u,this._requestToken.token);Promise.all([_,f]).then((([e,i])=>{return n=this,r=void 0,a=function*(){var n;if(null===(n=this._requestToken)||void 0===n||n.dispose(),!this._editor.hasModel())return;let r=null==o?void 0:o.clipboardText;if(!r&&e.needsClipboard&&(r=yield this._clipboardService.readText()),0===this._state)return;const s=this._editor.getModel();let a=e.items;if(o){const e=(0,z.wg)(g);a=a.concat(o.items).sort(e)}const l=new ne(s,this._editor.getPosition(),c,t.shy);this._completionModel=new ee(a,this._context.column,{leadingLineContent:l.leadingLineContent,characterCountDelta:l.column-this._context.column},i,this._editor.getOption(106),this._editor.getOption(101),r),this._completionDisposables.add(e.disposable),this._onNewContext(l),this._reportDurationsTelemetry(e.durations)},new((s=void 0)||(s=Promise))((function(e,t){function i(e){try{l(a.next(e))}catch(e){t(e)}}function o(e){try{l(a.throw(e))}catch(e){t(e)}}function l(t){var n;t.done?e(t.value):(n=t.value,n instanceof s?n:new s((function(e){e(n)}))).then(i,o)}l((a=a.apply(n,r||[])).next())}));var n,r,s,a})).catch(a.dL)}_reportDurationsTelemetry(e){this._telemetryGate++%230==0&&setTimeout((()=>{this._telemetryService.publicLog2("suggest.durations.json",{data:JSON.stringify(e)}),this._logService.debug("suggest.durations.json",e)}))}static _createSuggestFilter(e){const t=new Set;"none"===e.getOption(101)&&t.add(27);const i=e.getOption(106);return i.showMethods||t.add(0),i.showFunctions||t.add(1),i.showConstructors||t.add(2),i.showFields||t.add(3),i.showVariables||t.add(4),i.showClasses||t.add(5),i.showStructs||t.add(6),i.showInterfaces||t.add(7),i.showModules||t.add(8),i.showProperties||t.add(9),i.showEvents||t.add(10),i.showOperators||t.add(11),i.showUnits||t.add(12),i.showValues||t.add(13),i.showConstants||t.add(14),i.showEnums||t.add(15),i.showEnumMembers||t.add(16),i.showKeywords||t.add(17),i.showWords||t.add(18),i.showColors||t.add(19),i.showFiles||t.add(20),i.showReferences||t.add(21),i.showColors||t.add(22),i.showFolders||t.add(23),i.showTypeParameters||t.add(24),i.showSnippets||t.add(27),i.showUsers||t.add(25),i.showIssues||t.add(26),{itemKind:t,showDeprecated:i.showDeprecated}}_onNewContext(e){if(this._context)if(e.lineNumber===this._context.lineNumber)if((0,K.V8)(e.leadingLineContent)===(0,K.V8)(this._context.leadingLineContent)){if(e.columnthis._context.leadingWord.startColumn){const e=new Set(this._languageFeaturesService.completionProvider.all(this._editor.getModel()));for(let t of this._completionModel.allProvider)e.delete(t);const t=this._completionModel.adopt(new Set);this.trigger({auto:this._context.auto,shy:!1},!0,e,{items:t,clipboardText:this._completionModel.clipboardText})}else if(e.column>this._context.column&&this._completionModel.incomplete.size>0&&0!==e.leadingWord.word.length){const{incomplete:e}=this._completionModel,t=this._completionModel.adopt(e);this.trigger({auto:2===this._state,shy:!1,triggerKind:2},!0,e,{items:t,clipboardText:this._completionModel.clipboardText})}else{let t=this._completionModel.lineContext,i=!1;if(this._completionModel.lineContext={leadingLineContent:e.leadingLineContent,characterCountDelta:e.column-this._context.column},0===this._completionModel.items.length){if(ne.shouldAutoTrigger(this._editor)&&this._context.leadingWord.endColumn0,i&&0===e.leadingWord.word.length)return void this.cancel()}this._onDidSuggest.fire({completionModel:this._completionModel,auto:this._context.auto,shy:this._context.shy,isFrozen:i})}}else this.cancel();else this.cancel()}};oe=function(e,t,i,n){var o,r=arguments.length,s=r<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,i):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(e,t,i,n);else for(var a=e.length-1;a>=0;a--)(o=e[a])&&(s=(r<3?o(s):r>3?o(t,i,s):o(t,i))||s);return r>3&&s&&Object.defineProperty(t,i,s),s}([ie(1,G.p),ie(2,Q.p),ie(3,X.b),ie(4,H.VZ),ie(5,R.i6),ie(6,x.Ui),ie(7,te.p)],oe);class re{constructor(e,t){this._disposables=new d.SL,this._lastOvertyped=[],this._empty=!0,this._disposables.add(e.onWillType((()=>{if(!this._empty)return;if(!e.hasModel())return;const t=e.getSelections(),i=t.length;let n=!1;for(let e=0;ere._maxSelectionLength)return;this._lastOvertyped[e]={value:o.getValueInRange(i),multiline:i.startLineNumber!==i.endLineNumber}}this._empty=!1}))),this._disposables.add(t.onDidCancel((e=>{this._empty||e.retrigger||(this._empty=!0)})))}getLastOvertypedInfo(e){if(!this._empty&&e>=0&&ee instanceof B.U8?t.createInstance(Ee,e,void 0):void 0;this._leftActions=new xe.o(this.element,{actionViewItemProvider:o}),this._rightActions=new xe.o(this.element,{actionViewItemProvider:o}),this._leftActions.domNode.classList.add("left"),this._rightActions.domNode.classList.add("right")}dispose(){this._menuDisposables.dispose(),this.element.remove()}show(){const e=this._menuService.createMenu(z.GI,this._contextKeyService),t=()=>{const t=[],i=[];for(let[n,o]of e.getActions())"left"===n?t.push(...o):i.push(...o);this._leftActions.clear(),this._leftActions.push(t),this._rightActions.clear(),this._rightActions.push(i)};this._menuDisposables.add(e.onDidChange((()=>t()))),this._menuDisposables.add(e)}hide(){this._menuDisposables.clear()}};Ne=function(e,t,i,n){var o,r=arguments.length,s=r<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,i):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(e,t,i,n);else for(var a=e.length-1;a>=0;a--)(o=e[a])&&(s=(r<3?o(s):r>3?o(t,i,s):o(t,i))||s);return r>3&&s&&Object.defineProperty(t,i,s),s}([Le(1,L.TG),Le(2,B.co),Le(3,R.i6)],Ne),i(31300);var De=i(45164),Ie=i(64348),Te=i(81585),Ae=i(71036);class Re{constructor(){let e;this._onDidWillResize=new l.Q5,this.onDidWillResize=this._onDidWillResize.event,this._onDidResize=new l.Q5,this.onDidResize=this._onDidResize.event,this._sashListener=new d.SL,this._size=new se.Ro(0,0),this._minSize=new se.Ro(0,0),this._maxSize=new se.Ro(Number.MAX_SAFE_INTEGER,Number.MAX_SAFE_INTEGER),this.domNode=document.createElement("div"),this._eastSash=new Ae.g(this.domNode,{getVerticalSashLeft:()=>this._size.width},{orientation:0}),this._westSash=new Ae.g(this.domNode,{getVerticalSashLeft:()=>0},{orientation:0}),this._northSash=new Ae.g(this.domNode,{getHorizontalSashTop:()=>0},{orientation:1,orthogonalEdge:Ae.l.North}),this._southSash=new Ae.g(this.domNode,{getHorizontalSashTop:()=>this._size.height},{orientation:1,orthogonalEdge:Ae.l.South}),this._northSash.orthogonalStartSash=this._westSash,this._northSash.orthogonalEndSash=this._eastSash,this._southSash.orthogonalStartSash=this._westSash,this._southSash.orthogonalEndSash=this._eastSash;let t=0,i=0;this._sashListener.add(l.ju.any(this._northSash.onDidStart,this._eastSash.onDidStart,this._southSash.onDidStart,this._westSash.onDidStart)((()=>{void 0===e&&(this._onDidWillResize.fire(),e=this._size,t=0,i=0)}))),this._sashListener.add(l.ju.any(this._northSash.onDidEnd,this._eastSash.onDidEnd,this._southSash.onDidEnd,this._westSash.onDidEnd)((()=>{void 0!==e&&(e=void 0,t=0,i=0,this._onDidResize.fire({dimension:this._size,done:!0}))}))),this._sashListener.add(this._eastSash.onDidChange((n=>{e&&(i=n.currentX-n.startX,this.layout(e.height+t,e.width+i),this._onDidResize.fire({dimension:this._size,done:!1,east:!0}))}))),this._sashListener.add(this._westSash.onDidChange((n=>{e&&(i=-(n.currentX-n.startX),this.layout(e.height+t,e.width+i),this._onDidResize.fire({dimension:this._size,done:!1,west:!0}))}))),this._sashListener.add(this._northSash.onDidChange((n=>{e&&(t=-(n.currentY-n.startY),this.layout(e.height+t,e.width+i),this._onDidResize.fire({dimension:this._size,done:!1,north:!0}))}))),this._sashListener.add(this._southSash.onDidChange((n=>{e&&(t=n.currentY-n.startY,this.layout(e.height+t,e.width+i),this._onDidResize.fire({dimension:this._size,done:!1,south:!0}))}))),this._sashListener.add(l.ju.any(this._eastSash.onDidReset,this._westSash.onDidReset)((e=>{this._preferredSize&&(this.layout(this._size.height,this._preferredSize.width),this._onDidResize.fire({dimension:this._size,done:!0}))}))),this._sashListener.add(l.ju.any(this._northSash.onDidReset,this._southSash.onDidReset)((e=>{this._preferredSize&&(this.layout(this._preferredSize.height,this._size.width),this._onDidResize.fire({dimension:this._size,done:!0}))})))}dispose(){this._northSash.dispose(),this._southSash.dispose(),this._eastSash.dispose(),this._westSash.dispose(),this._sashListener.dispose(),this._onDidResize.dispose(),this._onDidWillResize.dispose(),this.domNode.remove()}enableSashes(e,t,i,n){this._northSash.state=e?3:0,this._eastSash.state=t?3:0,this._southSash.state=i?3:0,this._westSash.state=n?3:0}layout(e=this.size.height,t=this.size.width){const{height:i,width:n}=this._minSize,{height:o,width:r}=this._maxSize;e=Math.max(i,Math.min(o,e)),t=Math.max(n,Math.min(r,t));const s=new se.Ro(t,e);se.Ro.equals(s,this._size)||(this.domNode.style.height=e+"px",this.domNode.style.width=t+"px",this._size=s,this._northSash.layout(),this._eastSash.layout(),this._southSash.layout(),this._westSash.layout())}clearSashHoverState(){this._eastSash.clearSashHoverState(),this._westSash.clearSashHoverState(),this._northSash.clearSashHoverState(),this._southSash.clearSashHoverState()}get size(){return this._size}set maxSize(e){this._maxSize=e}get maxSize(){return this._maxSize}set minSize(e){this._minSize=e}get minSize(){return this._minSize}set preferredSize(e){this._preferredSize=e}get preferredSize(){return this._preferredSize}}var Me=i(26641),Oe=i(98677),Pe=i(4821),Fe=i(66978),Be=i(72956),We=i(18966);function Ve(e){return!!e&&Boolean(e.completion.documentation||e.completion.detail&&e.completion.detail!==e.completion.label)}let He=class{constructor(e,t){this._editor=e,this._onDidClose=new l.Q5,this.onDidClose=this._onDidClose.event,this._onDidChangeContents=new l.Q5,this.onDidChangeContents=this._onDidChangeContents.event,this._disposables=new d.SL,this._renderDisposeable=new d.SL,this._borderWidth=1,this._size=new se.Ro(330,0),this.domNode=se.$(".suggest-details"),this.domNode.classList.add("no-docs"),this._markdownRenderer=t.createInstance(Be.$,{editor:e}),this._body=se.$(".body"),this._scrollbar=new Oe.s$(this._body,{}),se.R3(this.domNode,this._scrollbar.getDomNode()),this._disposables.add(this._scrollbar),this._header=se.R3(this._body,se.$(".header")),this._close=se.R3(this._header,se.$("span"+Pe.lA.close.cssSelector)),this._close.title=F.NC("vs/editor/contrib/suggest/browser/suggestWidgetDetails","details.close","Close"),this._type=se.R3(this._header,se.$("p.type")),this._docs=se.R3(this._body,se.$("p.docs")),this._configureFont(),this._disposables.add(this._editor.onDidChangeConfiguration((e=>{e.hasChanged(44)&&this._configureFont()})))}dispose(){this._disposables.dispose(),this._renderDisposeable.dispose()}_configureFont(){const e=this._editor.getOptions(),t=e.get(44),i=t.getMassagedFontFamily(Me.isSafari?We.hL.fontFamily:null),n=e.get(107)||t.fontSize,o=e.get(108)||t.lineHeight,r=t.fontWeight,s=`${n}px`,a=`${o}px`;this.domNode.style.fontSize=s,this.domNode.style.lineHeight=""+o/n,this.domNode.style.fontWeight=r,this.domNode.style.fontFeatureSettings=t.fontFeatureSettings,this._type.style.fontFamily=i,this._close.style.height=a,this._close.style.width=a}getLayoutInfo(){const e=this._editor.getOption(108)||this._editor.getOption(44).lineHeight,t=this._borderWidth;return{lineHeight:e,borderWidth:t,borderHeight:2*t,verticalPadding:22,horizontalPadding:14}}renderLoading(){this._type.textContent=F.NC("vs/editor/contrib/suggest/browser/suggestWidgetDetails","loading","Loading..."),this._docs.textContent="",this.domNode.classList.remove("no-docs","no-type"),this.layout(this.size.width,2*this.getLayoutInfo().lineHeight),this._onDidChangeContents.fire(this)}renderItem(e,t){var i,n;this._renderDisposeable.clear();let{detail:o,documentation:r}=e.completion;if(t){let t="";t+=`score: ${e.score[0]}\n`,t+=`prefix: ${null!==(i=e.word)&&void 0!==i?i:"(no prefix)"}\n`,t+=`word: ${e.completion.filterText?e.completion.filterText+" (filterText)":e.textLabel}\n`,t+=`distance: ${e.distance} (localityBonus-setting)\n`,t+=`index: ${e.idx}, based on ${e.completion.sortText&&`sortText: "${e.completion.sortText}"`||"label"}\n`,t+=`commit_chars: ${null===(n=e.completion.commitCharacters)||void 0===n?void 0:n.join("")}\n`,r=(new Fe.W5).appendCodeblock("empty",t),o=`Provider: ${e.provider._debugDisplayName}`}if(t||Ve(e)){if(this.domNode.classList.remove("no-docs","no-type"),o){const e=o.length>1e5?`${o.substr(0,1e5)}…`:o;this._type.textContent=e,this._type.title=e,se.$Z(this._type),this._type.classList.toggle("auto-wrap",!/\r?\n^\s+/gim.test(e))}else se.PO(this._type),this._type.title="",se.Cp(this._type),this.domNode.classList.add("no-type");if(se.PO(this._docs),"string"==typeof r)this._docs.classList.remove("markdown-docs"),this._docs.textContent=r;else if(r){this._docs.classList.add("markdown-docs"),se.PO(this._docs);const e=this._markdownRenderer.render(r);this._docs.appendChild(e.element),this._renderDisposeable.add(e),this._renderDisposeable.add(this._markdownRenderer.onDidRenderAsync((()=>{this.layout(this._size.width,this._type.clientHeight+this._docs.clientHeight),this._onDidChangeContents.fire(this)})))}this.domNode.style.userSelect="text",this.domNode.tabIndex=-1,this._close.onmousedown=e=>{e.preventDefault(),e.stopPropagation()},this._close.onclick=e=>{e.preventDefault(),e.stopPropagation(),this._onDidClose.fire()},this._body.scrollTop=0,this.layout(this._size.width,this._type.clientHeight+this._docs.clientHeight),this._onDidChangeContents.fire(this)}else this.clearContents()}clearContents(){this.domNode.classList.add("no-docs"),this._type.textContent="",this._docs.textContent=""}get size(){return this._size}layout(e,t){const i=new se.Ro(e,t);se.Ro.equals(i,this._size)||(this._size=i,se.dp(this.domNode,e,t)),this._scrollbar.scanDomNode()}scrollDown(e=8){this._body.scrollTop+=e}scrollUp(e=8){this._body.scrollTop-=e}scrollTop(){this._body.scrollTop=0}scrollBottom(){this._body.scrollTop=this._body.scrollHeight}pageDown(){this.scrollDown(80)}pageUp(){this.scrollUp(80)}set borderWidth(e){this._borderWidth=e}get borderWidth(){return this._borderWidth}};He=function(e,t,i,n){var o,r=arguments.length,s=r<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,i):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(e,t,i,n);else for(var a=e.length-1;a>=0;a--)(o=e[a])&&(s=(r<3?o(s):r>3?o(t,i,s):o(t,i))||s);return r>3&&s&&Object.defineProperty(t,i,s),s}([function(e,t){return function(i,n){t(i,n,e)}}(1,L.TG)],He);class ze{constructor(e,t){let i,n;this.widget=e,this._editor=t,this._disposables=new d.SL,this._added=!1,this._preferAlignAtTop=!0,this._resizable=new Re,this._resizable.domNode.classList.add("suggest-details-container"),this._resizable.domNode.appendChild(e.domNode),this._resizable.enableSashes(!1,!0,!0,!1);let o=0,r=0;this._disposables.add(this._resizable.onDidWillResize((()=>{i=this._topLeft,n=this._resizable.size}))),this._disposables.add(this._resizable.onDidResize((e=>{if(i&&n){this.widget.layout(e.dimension.width,e.dimension.height);let t=!1;e.west&&(r=n.width-e.dimension.width,t=!0),e.north&&(o=n.height-e.dimension.height,t=!0),t&&this._applyTopLeft({top:i.top+o,left:i.left+r})}e.done&&(i=void 0,n=void 0,o=0,r=0,this._userSize=e.dimension)}))),this._disposables.add(this.widget.onDidChangeContents((()=>{var e;this._anchorBox&&this._placeAtAnchor(this._anchorBox,null!==(e=this._userSize)&&void 0!==e?e:this.widget.size,this._preferAlignAtTop)})))}dispose(){this._resizable.dispose(),this._disposables.dispose(),this.hide()}getId(){return"suggest.details"}getDomNode(){return this._resizable.domNode}getPosition(){return null}show(){this._added||(this._editor.addOverlayWidget(this),this.getDomNode().style.position="fixed",this._added=!0)}hide(e=!1){this._resizable.clearSashHoverState(),this._added&&(this._editor.removeOverlayWidget(this),this._added=!1,this._anchorBox=void 0,this._topLeft=void 0),e&&(this._userSize=void 0,this.widget.clearContents())}placeAtAnchor(e,t){var i;const n=e.getBoundingClientRect();this._anchorBox=n,this._preferAlignAtTop=t,this._placeAtAnchor(this._anchorBox,null!==(i=this._userSize)&&void 0!==i?i:this.widget.size,t)}_placeAtAnchor(e,t,i){var n;const o=se.D6(document.body),r=this.widget.getLayoutInfo(),s=new se.Ro(220,2*r.lineHeight),a=e.top,l=function(){const i=o.width-(e.left+e.width+r.borderWidth+r.horizontalPadding),n=-r.borderWidth+e.left+e.width,l=new se.Ro(i,o.height-e.top-r.borderHeight-r.verticalPadding),c=l.with(void 0,e.top+e.height-r.borderHeight-r.verticalPadding);return{top:a,left:n,fit:i-t.width,maxSizeTop:l,maxSizeBottom:c,minSize:s.with(Math.min(i,s.width))}}(),c=[l,function(){const i=e.left-r.borderWidth-r.horizontalPadding,n=Math.max(r.horizontalPadding,e.left-t.width-r.borderWidth),l=new se.Ro(i,o.height-e.top-r.borderHeight-r.verticalPadding),c=l.with(void 0,e.top+e.height-r.borderHeight-r.verticalPadding);return{top:a,left:n,fit:i-t.width,maxSizeTop:l,maxSizeBottom:c,minSize:s.with(Math.min(i,s.width))}}(),function(){const i=e.left,n=-r.borderWidth+e.top+e.height,a=new se.Ro(e.width-r.borderHeight,o.height-e.top-e.height-r.verticalPadding);return{top:n,left:i,fit:a.height-t.height,maxSizeBottom:a,maxSizeTop:a,minSize:s.with(a.width)}}()],d=null!==(n=c.find((e=>e.fit>=0)))&&void 0!==n?n:c.sort(((e,t)=>t.fit-e.fit))[0],u=e.top+e.height-r.borderHeight;let h,g=t.height;const p=Math.max(d.maxSizeTop.height,d.maxSizeBottom.height);let m;g>p&&(g=p),i?g<=d.maxSizeTop.height?(h=!0,m=d.maxSizeTop):(h=!1,m=d.maxSizeBottom):g<=d.maxSizeBottom.height?(h=!1,m=d.maxSizeBottom):(h=!0,m=d.maxSizeTop),this._applyTopLeft({left:d.left,top:h?d.top:u-g}),this.getDomNode().style.position="fixed",this._resizable.enableSashes(!h,d===l,h,d!==l),this._resizable.minSize=d.minSize,this._resizable.maxSize=m,this._resizable.layout(g,Math.min(m.width,t.width)),this.widget.layout(this._resizable.size.width,this._resizable.size.height)}_applyTopLeft(e){this._topLeft=e,this.getDomNode().style.left=`${this._topLeft.left}px`,this.getDomNode().style.top=`${this._topLeft.top}px`}}var $e,Ue=i(77982),je=i(39675),Ke=i(9734),qe=i(10804),Ge=i(11233);!function(e){e[e.FILE=0]="FILE",e[e.FOLDER=1]="FOLDER",e[e.ROOT_FOLDER=2]="ROOT_FOLDER"}($e||($e={}));const Ze=/(?:\/|^)(?:([^\/]+)\/)?([^\/]+)$/;function Ye(e,t,i,n){const o=n===$e.ROOT_FOLDER?["rootfolder-icon"]:n===$e.FOLDER?["folder-icon"]:["file-icon"];if(i){let r;if(i.scheme===Ke.lg.data)r=qe.Vb.parseMetaData(i).get(qe.Vb.META_DATA_LABEL);else{const e=i.path.match(Ze);e?(r=Qe(e[2].toLowerCase()),e[1]&&o.push(`${Qe(e[1].toLowerCase())}-name-dir-icon`)):r=Qe(i.authority.toLowerCase())}if(n===$e.FOLDER)o.push(`${r}-name-folder-icon`);else{if(r){if(o.push(`${r}-name-file-icon`),o.push("name-file-icon"),r.length<=255){const e=r.split(".");for(let t=1;t{const e=this._editor.getOptions(),i=e.get(44),o=i.getMassagedFontFamily(Me.isSafari?We.hL.fontFamily:null),r=i.fontFeatureSettings,s=e.get(107)||i.fontSize,a=e.get(108)||i.lineHeight,l=i.fontWeight,c=`${s}px`,d=`${a}px`;t.root.style.fontSize=c,t.root.style.fontWeight=l,n.style.fontFamily=o,n.style.fontFeatureSettings=r,n.style.lineHeight=d,t.icon.style.height=d,t.icon.style.width=d,t.readMore.style.height=d,t.readMore.style.width=d};return o(),t.disposables.add(this._editor.onDidChangeConfiguration((e=>{(e.hasChanged(44)||e.hasChanged(107)||e.hasChanged(108))&&o()}))),t}renderElement(e,t,i){const{completion:n}=e;i.root.id=it(t),i.colorspan.style.backgroundColor="";const r={labelEscapeNewLines:!0,matches:(0,J.mB)(e.score)};let s=[];if(19===n.kind&&ot.extract(e,s))i.icon.className="icon customcolor",i.iconContainer.className="icon hide",i.colorspan.style.backgroundColor=s[0];else if(20===n.kind&&this._themeService.getFileIconTheme().hasFileIcons){i.icon.className="icon hide",i.iconContainer.className="icon hide";const t=Ye(this._modelService,this._languageService,je.o.from({scheme:"fake",path:e.textLabel}),$e.FILE),o=Ye(this._modelService,this._languageService,je.o.from({scheme:"fake",path:n.detail}),$e.FILE);r.extraClasses=t.length>o.length?t:o}else 23===n.kind&&this._themeService.getFileIconTheme().hasFolderIcons?(i.icon.className="icon hide",i.iconContainer.className="icon hide",r.extraClasses=(0,o.xH)([Ye(this._modelService,this._languageService,je.o.from({scheme:"fake",path:e.textLabel}),$e.FOLDER),Ye(this._modelService,this._languageService,je.o.from({scheme:"fake",path:n.detail}),$e.FOLDER)])):(i.icon.className="icon hide",i.iconContainer.className="",i.iconContainer.classList.add("suggest-icon",...Pe.dT.asClassNameArray(S.gX.toIcon(n.kind))));n.tags&&n.tags.indexOf(1)>=0&&(r.extraClasses=(r.extraClasses||[]).concat(["deprecated"]),r.matches=[]),i.iconLabel.setLabel(e.textLabel,void 0,r),"string"==typeof n.label?(i.parametersLabel.textContent="",i.detailsLabel.textContent=st(n.detail||""),i.root.classList.add("string-label")):(i.parametersLabel.textContent=st(n.label.detail||""),i.detailsLabel.textContent=st(n.label.description||""),i.root.classList.remove("string-label")),this._editor.getOption(106).showInlineDetails?(0,se.$Z)(i.detailsLabel):(0,se.Cp)(i.detailsLabel),Ve(e)?(i.right.classList.add("can-expand-details"),(0,se.$Z)(i.readMore),i.readMore.onmousedown=e=>{e.stopPropagation(),e.preventDefault()},i.readMore.onclick=e=>{e.stopPropagation(),e.preventDefault(),this._onDidToggleDetails.fire()}):(i.right.classList.remove("can-expand-details"),(0,se.Cp)(i.readMore),i.readMore.onmousedown=null,i.readMore.onclick=null)}disposeTemplate(e){e.disposables.dispose()}};function st(e){return e.replace(/\r\n|\r|\n/g,"")}rt=function(e,t,i,n){var o,r=arguments.length,s=r<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,i):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(e,t,i,n);else for(var a=e.length-1;a>=0;a--)(o=e[a])&&(s=(r<3?o(s):r>3?o(t,i,s):o(t,i))||s);return r>3&&s&&Object.defineProperty(t,i,s),s}([tt(1,Je.q),tt(2,et.O),tt(3,Te.XE)],rt);var at=function(e,t){return function(i,n){t(i,n,e)}};(0,De.P6G)("editorSuggestWidget.background",{dark:De.D0T,light:De.D0T,hc:De.D0T},F.NC("vs/editor/contrib/suggest/browser/suggestWidget","editorSuggestWidgetBackground","Background color of the suggest widget.")),(0,De.P6G)("editorSuggestWidget.border",{dark:De.D1_,light:De.D1_,hc:De.D1_},F.NC("vs/editor/contrib/suggest/browser/suggestWidget","editorSuggestWidgetBorder","Border color of the suggest widget."));const lt=(0,De.P6G)("editorSuggestWidget.foreground",{dark:De.NOs,light:De.NOs,hc:De.NOs},F.NC("vs/editor/contrib/suggest/browser/suggestWidget","editorSuggestWidgetForeground","Foreground color of the suggest widget.")),ct=((0,De.P6G)("editorSuggestWidget.selectedForeground",{dark:De.NPS,light:De.NPS,hc:De.NPS},F.NC("vs/editor/contrib/suggest/browser/suggestWidget","editorSuggestWidgetSelectedForeground","Foreground color of the selected entry in the suggest widget.")),(0,De.P6G)("editorSuggestWidget.selectedIconForeground",{dark:De.cbQ,light:De.cbQ,hc:De.cbQ},F.NC("vs/editor/contrib/suggest/browser/suggestWidget","editorSuggestWidgetSelectedIconForeground","Icon foreground color of the selected entry in the suggest widget.")),(0,De.P6G)("editorSuggestWidget.selectedBackground",{dark:De.Vqd,light:De.Vqd,hc:De.Vqd},F.NC("vs/editor/contrib/suggest/browser/suggestWidget","editorSuggestWidgetSelectedBackground","Background color of the selected entry in the suggest widget.")));(0,De.P6G)("editorSuggestWidget.highlightForeground",{dark:De.Gwp,light:De.Gwp,hc:De.Gwp},F.NC("vs/editor/contrib/suggest/browser/suggestWidget","editorSuggestWidgetHighlightForeground","Color of the match highlights in the suggest widget.")),(0,De.P6G)("editorSuggestWidget.focusHighlightForeground",{dark:De.PX0,light:De.PX0,hc:De.PX0},F.NC("vs/editor/contrib/suggest/browser/suggestWidget","editorSuggestWidgetFocusHighlightForeground","Color of the match highlights in the suggest widget when an item is focused.")),(0,De.P6G)("editorSuggestWidgetStatus.foreground",{dark:(0,De.ZnX)(lt,.5),light:(0,De.ZnX)(lt,.5),hc:(0,De.ZnX)(lt,.5)},F.NC("vs/editor/contrib/suggest/browser/suggestWidget","editorSuggestWidgetStatusForeground","Foreground color of the suggest widget status."));class dt{constructor(e,t){this._service=e,this._key=`suggestWidget.size/${t.getEditorType()}/${t instanceof Se.H}`}restore(){var e;const t=null!==(e=this._service.get(this._key,0))&&void 0!==e?e:"";try{const e=JSON.parse(t);if(se.Ro.is(e))return se.Ro.lift(e)}catch(e){}}store(e){this._service.store(this._key,JSON.stringify(e),0,1)}reset(){this._service.remove(this._key,0)}}let ut=class e{constructor(e,t,i,n,o){this.editor=e,this._storageService=t,this._state=0,this._isAuto=!1,this._ignoreFocusEvents=!1,this._forceRenderingAbove=!1,this._explainMode=!1,this._showTimeout=new r._F,this._disposables=new d.SL,this._onDidSelect=new l.Q5,this._onDidFocus=new l.Q5,this._onDidHide=new l.Q5,this._onDidShow=new l.Q5,this.onDidSelect=this._onDidSelect.event,this.onDidFocus=this._onDidFocus.event,this.onDidHide=this._onDidHide.event,this.onDidShow=this._onDidShow.event,this._onDetailsKeydown=new l.Q5,this.onDetailsKeyDown=this._onDetailsKeydown.event,this.element=new Re,this.element.domNode.classList.add("editor-widget","suggest-widget"),this._contentWidget=new ht(this,e),this._persistedSize=new dt(t,e);class s{constructor(e,t,i=!1,n=!1){this.persistedSize=e,this.currentSize=t,this.persistHeight=i,this.persistWidth=n}}let a;this._disposables.add(this.element.onDidWillResize((()=>{this._contentWidget.lockPreference(),a=new s(this._persistedSize.restore(),this.element.size)}))),this._disposables.add(this.element.onDidResize((e=>{var t,i,n,o;if(this._resize(e.dimension.width,e.dimension.height),a&&(a.persistHeight=a.persistHeight||!!e.north||!!e.south,a.persistWidth=a.persistWidth||!!e.east||!!e.west),e.done){if(a){const{itemHeight:e,defaultSize:r}=this.getLayoutInfo(),s=Math.round(e/2);let{width:l,height:c}=this.element.size;(!a.persistHeight||Math.abs(a.currentSize.height-c)<=s)&&(c=null!==(i=null===(t=a.persistedSize)||void 0===t?void 0:t.height)&&void 0!==i?i:r.height),(!a.persistWidth||Math.abs(a.currentSize.width-l)<=s)&&(l=null!==(o=null===(n=a.persistedSize)||void 0===n?void 0:n.width)&&void 0!==o?o:r.width),this._persistedSize.store(new se.Ro(l,c))}this._contentWidget.unlockPreference(),a=void 0}}))),this._messageElement=se.R3(this.element.domNode,se.$(".message")),this._listElement=se.R3(this.element.domNode,se.$(".tree"));const c=o.createInstance(He,this.editor);c.onDidClose(this.toggleDetails,this,this._disposables),this._details=new ze(c,this.editor);const u=()=>this.element.domNode.classList.toggle("no-icons",!this.editor.getOption(106).showIcons);u();const h=o.createInstance(rt,this.editor);this._disposables.add(h),this._disposables.add(h.onDidToggleDetails((()=>this.toggleDetails()))),this._list=new ae.aV("SuggestWidget",this._listElement,{getHeight:e=>this.getLayoutInfo().itemHeight,getTemplateId:e=>"suggestion"},[h],{alwaysConsumeMouseWheel:!0,useShadows:!1,mouseSupport:!1,accessibilityProvider:{getRole:()=>"option",getWidgetAriaLabel:()=>F.NC("vs/editor/contrib/suggest/browser/suggestWidget","suggest","Suggest"),getWidgetRole:()=>"listbox",getAriaLabel:e=>{let t=e.textLabel;if("string"!=typeof e.completion.label){const{detail:i,description:n}=e.completion.label;i&&n?t=F.NC("vs/editor/contrib/suggest/browser/suggestWidget","label.full","{0}{1}, {2}",t,i,n):i?t=F.NC("vs/editor/contrib/suggest/browser/suggestWidget","label.detail","{0}{1}",t,i):n&&(t=F.NC("vs/editor/contrib/suggest/browser/suggestWidget","label.desc","{0}, {1}",t,n))}if(!e.isResolved||!this._isDetailsVisible())return t;const{documentation:i,detail:n}=e.completion,o=K.WU("{0}{1}",n||"",i?"string"==typeof i?i:i.value:"");return F.NC("vs/editor/contrib/suggest/browser/suggestWidget","ariaCurrenttSuggestionReadDetails","{0}, docs: {1}",t,o)}}}),this._status=o.createInstance(Ne,this.element.domNode);const g=()=>this.element.domNode.classList.toggle("with-status-bar",this.editor.getOption(106).showStatusBar);g(),this._disposables.add((0,Ie.Jl)(this._list,n,{listInactiveFocusBackground:ct,listInactiveFocusOutline:De.xL1})),this._disposables.add(n.onDidColorThemeChange((e=>this._onThemeChange(e)))),this._onThemeChange(n.getColorTheme()),this._disposables.add(this._list.onMouseDown((e=>this._onListMouseDownOrTap(e)))),this._disposables.add(this._list.onTap((e=>this._onListMouseDownOrTap(e)))),this._disposables.add(this._list.onDidChangeSelection((e=>this._onListSelection(e)))),this._disposables.add(this._list.onDidChangeFocus((e=>this._onListFocus(e)))),this._disposables.add(this.editor.onDidChangeCursorSelection((()=>this._onCursorSelectionChanged()))),this._disposables.add(this.editor.onDidChangeConfiguration((e=>{e.hasChanged(106)&&(g(),u())}))),this._ctxSuggestWidgetVisible=z._y.Visible.bindTo(i),this._ctxSuggestWidgetDetailsVisible=z._y.DetailsVisible.bindTo(i),this._ctxSuggestWidgetMultipleSuggestions=z._y.MultipleSuggestions.bindTo(i),this._disposables.add(se.mu(this._details.widget.domNode,"keydown",(e=>{this._onDetailsKeydown.fire(e)}))),this._disposables.add(this.editor.onMouseDown((e=>this._onEditorMouseDown(e))))}dispose(){var e;this._details.widget.dispose(),this._details.dispose(),this._list.dispose(),this._status.dispose(),this._disposables.dispose(),null===(e=this._loadingTimeout)||void 0===e||e.dispose(),this._showTimeout.dispose(),this._contentWidget.dispose(),this.element.dispose()}_onEditorMouseDown(e){this._details.widget.domNode.contains(e.target.element)?this._details.widget.domNode.focus():this.element.domNode.contains(e.target.element)&&this.editor.focus()}_onCursorSelectionChanged(){0!==this._state&&this._contentWidget.layout()}_onListMouseDownOrTap(e){void 0!==e.element&&void 0!==e.index&&(e.browserEvent.preventDefault(),e.browserEvent.stopPropagation(),this._select(e.element,e.index))}_onListSelection(e){e.elements.length&&this._select(e.elements[0],e.indexes[0])}_select(e,t){const i=this._completionModel;i&&(this._onDidSelect.fire({item:e,index:t,model:i}),this.editor.focus())}_onThemeChange(e){this._details.widget.borderWidth="hc"===e.type?2:1}_onListFocus(e){var t;if(this._ignoreFocusEvents)return;if(!e.elements.length)return this._currentSuggestionDetails&&(this._currentSuggestionDetails.cancel(),this._currentSuggestionDetails=void 0,this._focusedItem=void 0),void this.editor.setAriaOptions({activeDescendant:void 0});if(!this._completionModel)return;const i=e.elements[0],n=e.indexes[0];i!==this._focusedItem&&(null===(t=this._currentSuggestionDetails)||void 0===t||t.cancel(),this._currentSuggestionDetails=void 0,this._focusedItem=i,this._list.reveal(n),this._currentSuggestionDetails=(0,r.PG)((e=>{return t=this,n=void 0,s=function*(){const t=(0,r.Vg)((()=>{this._isDetailsVisible()&&this.showDetails(!0)}),250),n=e.onCancellationRequested((()=>t.dispose())),o=yield i.resolve(e);return t.dispose(),n.dispose(),o},new((o=void 0)||(o=Promise))((function(e,i){function r(e){try{l(s.next(e))}catch(e){i(e)}}function a(e){try{l(s.throw(e))}catch(e){i(e)}}function l(t){var i;t.done?e(t.value):(i=t.value,i instanceof o?i:new o((function(e){e(i)}))).then(r,a)}l((s=s.apply(t,n||[])).next())}));var t,n,o,s})),this._currentSuggestionDetails.then((()=>{n>=this._list.length||i!==this._list.element(n)||(this._ignoreFocusEvents=!0,this._list.splice(n,1,[i]),this._list.setFocus([n]),this._ignoreFocusEvents=!1,this._isDetailsVisible()?this.showDetails(!1):this.element.domNode.classList.remove("docs-side"),this.editor.setAriaOptions({activeDescendant:it(n)}))})).catch(a.dL)),this._onDidFocus.fire({item:i,index:n,model:this._completionModel})}_setState(t){if(this._state!==t)switch(this._state=t,this.element.domNode.classList.toggle("frozen",4===t),this.element.domNode.classList.remove("message"),t){case 0:se.Cp(this._messageElement,this._listElement,this._status.element),this._details.hide(!0),this._status.hide(),this._contentWidget.hide(),this._ctxSuggestWidgetVisible.reset(),this._ctxSuggestWidgetMultipleSuggestions.reset(),this._showTimeout.cancel(),this.element.domNode.classList.remove("visible"),this._list.splice(0,this._list.length),this._focusedItem=void 0,this._cappedHeight=void 0,this._explainMode=!1;break;case 1:this.element.domNode.classList.add("message"),this._messageElement.textContent=e.LOADING_MESSAGE,se.Cp(this._listElement,this._status.element),se.$Z(this._messageElement),this._details.hide(),this._show(),this._focusedItem=void 0;break;case 2:this.element.domNode.classList.add("message"),this._messageElement.textContent=e.NO_SUGGESTIONS_MESSAGE,se.Cp(this._listElement,this._status.element),se.$Z(this._messageElement),this._details.hide(),this._show(),this._focusedItem=void 0;break;case 3:case 4:se.Cp(this._messageElement),se.$Z(this._listElement,this._status.element),this._show();break;case 5:se.Cp(this._messageElement),se.$Z(this._listElement,this._status.element),this._details.show(),this._show()}}_show(){this._status.show(),this._contentWidget.show(),this._layout(this._persistedSize.restore()),this._ctxSuggestWidgetVisible.set(!0),this._showTimeout.cancelAndSet((()=>{this.element.domNode.classList.add("visible"),this._onDidShow.fire(this)}),100)}showTriggered(e,t){0===this._state&&(this._contentWidget.setPosition(this.editor.getPosition()),this._isAuto=!!e,this._isAuto||(this._loadingTimeout=(0,r.Vg)((()=>this._setState(1)),t)))}showSuggestions(e,t,i,n){var o,r;if(this._contentWidget.setPosition(this.editor.getPosition()),null===(o=this._loadingTimeout)||void 0===o||o.dispose(),null===(r=this._currentSuggestionDetails)||void 0===r||r.cancel(),this._currentSuggestionDetails=void 0,this._completionModel!==e&&(this._completionModel=e),i&&2!==this._state&&0!==this._state)return void this._setState(4);const s=this._completionModel.items.length,a=0===s;if(this._ctxSuggestWidgetMultipleSuggestions.set(s>1),a)return this._setState(n?0:2),void(this._completionModel=void 0);this._focusedItem=void 0,this._list.splice(0,this._list.length,this._completionModel.items),this._setState(i?4:3),this._list.reveal(t,0),this._list.setFocus([t]),this._layout(this.element.size),this._details.widget.domNode.classList.remove("focused")}selectNextPage(){switch(this._state){case 0:return!1;case 5:return this._details.widget.pageDown(),!0;case 1:return!this._isAuto;default:return this._list.focusNextPage(),!0}}selectNext(){switch(this._state){case 0:return!1;case 1:return!this._isAuto;default:return this._list.focusNext(1,!0),!0}}selectLast(){switch(this._state){case 0:return!1;case 5:return this._details.widget.scrollBottom(),!0;case 1:return!this._isAuto;default:return this._list.focusLast(),!0}}selectPreviousPage(){switch(this._state){case 0:return!1;case 5:return this._details.widget.pageUp(),!0;case 1:return!this._isAuto;default:return this._list.focusPreviousPage(),!0}}selectPrevious(){switch(this._state){case 0:return!1;case 1:return!this._isAuto;default:return this._list.focusPrevious(1,!0),!1}}selectFirst(){switch(this._state){case 0:return!1;case 5:return this._details.widget.scrollTop(),!0;case 1:return!this._isAuto;default:return this._list.focusFirst(),!0}}getFocusedItem(){if(0!==this._state&&2!==this._state&&1!==this._state&&this._completionModel)return{item:this._list.getFocusedElements()[0],index:this._list.getFocus()[0],model:this._completionModel}}toggleDetailsFocus(){5===this._state?(this._setState(3),this._details.widget.domNode.classList.remove("focused")):3===this._state&&this._isDetailsVisible()&&(this._setState(5),this._details.widget.domNode.classList.add("focused"))}toggleDetails(){this._isDetailsVisible()?(this._ctxSuggestWidgetDetailsVisible.set(!1),this._setDetailsVisible(!1),this._details.hide(),this.element.domNode.classList.remove("shows-details")):!Ve(this._list.getFocusedElements()[0])&&!this._explainMode||3!==this._state&&5!==this._state&&4!==this._state||(this._ctxSuggestWidgetDetailsVisible.set(!0),this._setDetailsVisible(!0),this.showDetails(!1))}showDetails(e){this._details.show(),e?this._details.widget.renderLoading():this._details.widget.renderItem(this._list.getFocusedElements()[0],this._explainMode),this._positionDetails(),this.editor.focus(),this.element.domNode.classList.add("shows-details")}toggleExplainMode(){this._list.getFocusedElements()[0]&&(this._explainMode=!this._explainMode,this._isDetailsVisible()?this.showDetails(!1):this.toggleDetails())}resetPersistedSize(){this._persistedSize.reset()}hideWidget(){var e;null===(e=this._loadingTimeout)||void 0===e||e.dispose(),this._setState(0),this._onDidHide.fire(this),this.element.clearSashHoverState();const t=this._persistedSize.restore(),i=Math.ceil(4.3*this.getLayoutInfo().itemHeight);t&&t.heightl&&(a=l);const c=this._completionModel?this._completionModel.stats.pLabelLen*r.typicalHalfwidthCharacterWidth:a,d=r.statusBarHeight+this._list.contentHeight+r.borderHeight,u=r.itemHeight+r.statusBarHeight,h=se.i(this.editor.getDomNode()),g=this.editor.getScrolledVisiblePosition(this.editor.getPosition()),p=h.top+g.top+g.height,m=Math.min(o.height-p-r.verticalPadding,d),f=h.top+g.top-r.verticalPadding,_=Math.min(f,d);let b=Math.min(Math.max(_,m)+r.borderHeight,d);s===(null===(t=this._cappedHeight)||void 0===t?void 0:t.capped)&&(s=this._cappedHeight.wanted),sb&&(s=b);const v=150;s>m||this._forceRenderingAbove&&f>v?(this._contentWidget.setPreference(1),this.element.enableSashes(!0,!0,!1,!1),b=_):(this._contentWidget.setPreference(2),this.element.enableSashes(!1,!0,!0,!1),b=m),this.element.preferredSize=new se.Ro(c,r.defaultSize.height),this.element.maxSize=new se.Ro(l,b),this.element.minSize=new se.Ro(220,u),this._cappedHeight=s===d?{wanted:null!==(n=null===(i=this._cappedHeight)||void 0===i?void 0:i.wanted)&&void 0!==n?n:e.height,capped:s}:void 0}this._resize(a,s)}_resize(e,t){const{width:i,height:n}=this.element.maxSize;e=Math.min(i,e),t=Math.min(n,t);const{statusBarHeight:o}=this.getLayoutInfo();this._list.layout(t-o,e),this._listElement.style.height=t-o+"px",this.element.layout(t,e),this._contentWidget.layout(),this._positionDetails()}_positionDetails(){var e;this._isDetailsVisible()&&this._details.placeAtAnchor(this.element.domNode,2===(null===(e=this._contentWidget.getPosition())||void 0===e?void 0:e.preference[0]))}getLayoutInfo(){const e=this.editor.getOption(44),t=(0,le.uZ)(this.editor.getOption(108)||e.lineHeight,8,1e3),i=this.editor.getOption(106).showStatusBar&&2!==this._state&&1!==this._state?t:0,n=this._details.widget.borderWidth,o=2*n;return{itemHeight:t,statusBarHeight:i,borderWidth:n,borderHeight:o,typicalHalfwidthCharacterWidth:e.typicalHalfwidthCharacterWidth,verticalPadding:22,horizontalPadding:14,defaultSize:new se.Ro(430,i+12*t+o)}}_isDetailsVisible(){return this._storageService.getBoolean("expandSuggestionDocs",0,!1)}_setDetailsVisible(e){this._storageService.store("expandSuggestionDocs",e,0,0)}forceRenderingAbove(){this._forceRenderingAbove||(this._forceRenderingAbove=!0,this._layout(this._persistedSize.restore()))}stopForceRenderingAbove(){this._forceRenderingAbove=!1}};ut.LOADING_MESSAGE=F.NC("vs/editor/contrib/suggest/browser/suggestWidget","suggestWidget.loading","Loading..."),ut.NO_SUGGESTIONS_MESSAGE=F.NC("vs/editor/contrib/suggest/browser/suggestWidget","suggestWidget.noSuggestions","No suggestions."),ut=function(e,t,i,n){var o,r=arguments.length,s=r<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,i):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(e,t,i,n);else for(var a=e.length-1;a>=0;a--)(o=e[a])&&(s=(r<3?o(s):r>3?o(t,i,s):o(t,i))||s);return r>3&&s&&Object.defineProperty(t,i,s),s}([at(1,E.Uy),at(2,R.i6),at(3,Te.XE),at(4,L.TG)],ut);class ht{constructor(e,t){this._widget=e,this._editor=t,this.allowEditorOverflow=!0,this.suppressMouseDown=!1,this._preferenceLocked=!1,this._added=!1,this._hidden=!1}dispose(){this._added&&(this._added=!1,this._editor.removeContentWidget(this))}getId(){return"editor.widget.suggestWidget"}getDomNode(){return this._widget.element.domNode}show(){this._hidden=!1,this._added||(this._added=!0,this._editor.addContentWidget(this))}hide(){this._hidden||(this._hidden=!0,this.layout())}layout(){this._editor.layoutContentWidget(this)}getPosition(){return!this._hidden&&this._position&&this._preference?{position:this._position,preference:[this._preference]}:null}beforeRender(){const{height:e,width:t}=this._widget.element.size,{borderWidth:i,horizontalPadding:n}=this._widget.getLayoutInfo();return new se.Ro(t+2*i+n,e+2*i)}afterRender(e){this._widget._afterRender(e)}setPreference(e){this._preferenceLocked||(this._preference=e)}lockPreference(){this._preferenceLocked=!0}unlockPreference(){this._preferenceLocked=!1}setPosition(e){this._position=e}}var gt=i(25672),pt=function(e,t){return function(i,n){t(i,n,e)}};class mt{constructor(e,t){if(this._model=e,this._position=t,e.getLineMaxColumn(t.lineNumber)!==t.column){const i=e.getOffsetAt(t),n=e.getPositionAt(i+1);this._marker=e.deltaDecorations([],[{range:b.e.fromPositions(t,n),options:{description:"suggest-line-suffix",stickiness:1}}])}}dispose(){this._marker&&!this._model.isDisposed()&&this._model.deltaDecorations(this._marker,[])}delta(e){if(this._model.isDisposed()||this._position.lineNumber!==e.lineNumber)return 0;if(this._marker){const t=this._model.getDecorationRange(this._marker[0]);return this._model.getOffsetAt(t.getStartPosition())-this._model.getOffsetAt(e)}return this._model.getLineMaxColumn(e.lineNumber)-e.column}}let ft=class e{constructor(e,t,i,n,o,s,a){this._memoryService=t,this._commandService=i,this._contextKeyService=n,this._instantiationService=o,this._logService=s,this._telemetryService=a,this._lineSuffix=new d.XK,this._toDispose=new d.SL,this._selectors=new _t((e=>e.priority)),this._telemetryGate=0,this.editor=e,this.model=o.createInstance(oe,this.editor);const l=z._y.InsertMode.bindTo(n);l.set(e.getOption(106).insertMode),this.model.onDidTrigger((()=>l.set(e.getOption(106).insertMode))),this.widget=this._toDispose.add(new r.Ue((()=>{const e=this._instantiationService.createInstance(ut,this.editor);this._toDispose.add(e),this._toDispose.add(e.onDidSelect((e=>this._insertSuggestion(e,0)),this));const t=new j(this.editor,e,(e=>this._insertSuggestion(e,2)));this._toDispose.add(t),this._toDispose.add(this.model.onDidSuggest((e=>{0===e.completionModel.items.length&&t.reset()})));const i=z._y.MakesTextEdit.bindTo(this._contextKeyService),n=z._y.HasInsertAndReplaceRange.bindTo(this._contextKeyService),o=z._y.CanResolve.bindTo(this._contextKeyService);return this._toDispose.add((0,d.OF)((()=>{i.reset(),n.reset(),o.reset()}))),this._toDispose.add(e.onDidFocus((({item:e})=>{const t=this.editor.getPosition(),r=e.editStart.column,s=t.column;let a=!0;"smart"!==this.editor.getOption(1)||2!==this.model.state||e.completion.additionalTextEdits||4&e.completion.insertTextRules||s-r!==e.completion.insertText.length||(a=this.editor.getModel().getValueInRange({startLineNumber:t.lineNumber,startColumn:r,endLineNumber:t.lineNumber,endColumn:s})!==e.completion.insertText),i.set(a),n.set(!_.L.equals(e.editInsertEnd,e.editReplaceEnd)),o.set(Boolean(e.provider.resolveCompletionItem)||Boolean(e.completion.documentation)||e.completion.detail!==e.completion.label)}))),this._toDispose.add(e.onDetailsKeyDown((e=>{e.toKeybinding().equals(new c.QC(!0,!1,!1,!1,33))||u.dz&&e.toKeybinding().equals(new c.QC(!1,!1,!1,!0,33))?e.stopPropagation():e.toKeybinding().isModifierKey()||this.editor.focus()}))),e}))),this._overtypingCapturer=this._toDispose.add(new r.Ue((()=>this._toDispose.add(new re(this.editor,this.model))))),this._alternatives=this._toDispose.add(new r.Ue((()=>this._toDispose.add(new $(this.editor,this._contextKeyService))))),this._toDispose.add(o.createInstance(M,e)),this._toDispose.add(this.model.onDidTrigger((e=>{this.widget.value.showTriggered(e.auto,e.shy?250:50),this._lineSuffix.value=new mt(this.editor.getModel(),e.position)}))),this._toDispose.add(this.model.onDidSuggest((e=>{if(!e.shy){let t=-1;for(const i of this._selectors.itemsOrderedByPriorityDesc)if(t=i.select(this.editor.getModel(),this.editor.getPosition(),e.completionModel.items),-1!==t)break;-1===t&&(t=this._memoryService.select(this.editor.getModel(),this.editor.getPosition(),e.completionModel.items)),this.widget.value.showSuggestions(e.completionModel,t,e.isFrozen,e.auto)}}))),this._toDispose.add(this.model.onDidCancel((e=>{e.retrigger||this.widget.value.hideWidget()}))),this._toDispose.add(this.editor.onDidBlurEditorWidget((()=>{this.model.cancel(),this.model.clear()})));let h=z._y.AcceptSuggestionsOnEnter.bindTo(n),g=()=>{const e=this.editor.getOption(1);h.set("on"===e||"smart"===e)};this._toDispose.add(this.editor.onDidChangeConfiguration((()=>g()))),g()}static get(t){return t.getContribution(e.ID)}dispose(){this._alternatives.dispose(),this._toDispose.dispose(),this.widget.dispose(),this.model.dispose(),this._lineSuffix.dispose()}_insertSuggestion(e,t){if(!e||!e.item)return this._alternatives.value.reset(),this.model.cancel(),void this.model.clear();if(!this.editor.hasModel())return;const i=C.SnippetController2.get(this.editor);if(!i)return;const n=this.editor.getModel(),o=n.getAlternativeVersionId(),{item:r}=e,l=[],c=new s.A;1&t||this.editor.pushUndoStop();const d=this.getOverwriteInfo(r,Boolean(8&t));if(this._memoryService.memorize(n,this.editor.getPosition(),r),Array.isArray(r.completion.additionalTextEdits)){const e=p.Z.capture(this.editor);this.editor.executeEdits("suggestController.additionalTextEdits.sync",r.completion.additionalTextEdits.map((e=>f.h.replace(b.e.lift(e.range),e.text)))),e.restoreRelativeVerticalPositionOfCursor(this.editor)}else if(!r.isResolved){const e=new h.G(!0);let i;const o=n.onDidChangeContent((e=>{if(e.isFlush)return c.cancel(),void o.dispose();for(let t of e.changes){const e=b.e.getEndPosition(t.range);i&&!_.L.isBefore(e,i)||(i=e)}}));let s=t;t|=2;let a=!1,d=this.editor.onWillType((()=>{d.dispose(),a=!0,2&s||this.editor.pushUndoStop()}));l.push(r.resolve(c.token).then((()=>{if(!r.completion.additionalTextEdits||c.token.isCancellationRequested)return!1;if(i&&r.completion.additionalTextEdits.some((e=>_.L.isBefore(i,b.e.getStartPosition(e.range)))))return!1;a&&this.editor.pushUndoStop();const e=p.Z.capture(this.editor);return this.editor.executeEdits("suggestController.additionalTextEdits.async",r.completion.additionalTextEdits.map((e=>f.h.replace(b.e.lift(e.range),e.text)))),e.restoreRelativeVerticalPositionOfCursor(this.editor),!a&&2&s||this.editor.pushUndoStop(),!0})).then((t=>{this._logService.trace("[suggest] async resolving of edits DONE (ms, applied?)",e.elapsed(),t),o.dispose(),d.dispose()})))}let{insertText:u}=r.completion;4&r.completion.insertTextRules||(u=w.Yj.escape(u)),i.insert(u,{overwriteBefore:d.overwriteBefore,overwriteAfter:d.overwriteAfter,undoStopBefore:!1,undoStopAfter:!1,adjustWhitespace:!(1&r.completion.insertTextRules),clipboardText:e.model.clipboardText,overtypingCapturer:this._overtypingCapturer.value}),2&t||this.editor.pushUndoStop(),r.completion.command?r.completion.command.id===bt.id?this.model.trigger({auto:!0,shy:!1},!0):(l.push(this._commandService.executeCommand(r.completion.command.id,...r.completion.command.arguments?[...r.completion.command.arguments]:[]).catch(a.dL)),this.model.cancel()):this.model.cancel(),4&t&&this._alternatives.value.set(e,(e=>{for(c.cancel();n.canUndo();){o!==n.getAlternativeVersionId()&&n.undo(),this._insertSuggestion(e,3|(8&t?8:0));break}})),this._alertCompletionItem(r),Promise.all(l).finally((()=>{this._reportSuggestionAcceptedTelemetry(n,e),this.model.clear(),c.dispose()}))}_reportSuggestionAcceptedTelemetry(e,t){var i;if(this._telemetryGate++%100!=0)return;const n=(null!==(i=t.item.provider._debugDisplayName)&&void 0!==i?i:"unknown").split("(",1)[0].toLowerCase();this._telemetryService.publicLog2("suggest.acceptedSuggestion",{providerId:n,basenameHash:(0,gt.vp)((0,qe.EZ)(e.uri)).toString(16),languageId:e.getLanguageId(),fileExtension:(0,qe.DZ)(e.uri)})}getOverwriteInfo(e,t){(0,g.p_)(this.editor.hasModel());let i="replace"===this.editor.getOption(106).insertMode;t&&(i=!i);const n=e.position.column-e.editStart.column,o=(i?e.editReplaceEnd.column:e.editInsertEnd.column)-e.position.column;return{overwriteBefore:n+(this.editor.getPosition().column-e.position.column),overwriteAfter:o+(this._lineSuffix.value?this._lineSuffix.value.delta(this.editor.getPosition()):0)}}_alertCompletionItem(e){if((0,o.Of)(e.completion.additionalTextEdits)){let t=F.NC("vs/editor/contrib/suggest/browser/suggestController","aria.alert.snippet","Accepting '{0}' made {1} additional edits",e.textLabel,e.completion.additionalTextEdits.length);(0,n.Z9)(t)}}triggerSuggest(e,t){this.editor.hasModel()&&(this.model.trigger({auto:null!=t&&t,shy:!1},!1,e),this.editor.revealPosition(this.editor.getPosition(),0),this.editor.focus())}triggerSuggestAndAcceptBest(e){if(!this.editor.hasModel())return;const t=this.editor.getPosition(),i=()=>{t.equals(this.editor.getPosition())&&this._commandService.executeCommand(e.fallback)},n=e=>{if(4&e.completion.insertTextRules||e.completion.additionalTextEdits)return!0;const t=this.editor.getPosition(),i=e.editStart.column,n=t.column;return n-i!==e.completion.insertText.length||this.editor.getModel().getValueInRange({startLineNumber:t.lineNumber,startColumn:i,endLineNumber:t.lineNumber,endColumn:n})!==e.completion.insertText};l.ju.once(this.model.onDidTrigger)((e=>{let t=[];l.ju.any(this.model.onDidTrigger,this.model.onDidCancel)((()=>{(0,d.B9)(t),i()}),void 0,t),this.model.onDidSuggest((({completionModel:e})=>{if((0,d.B9)(t),0===e.items.length)return void i();const o=this._memoryService.select(this.editor.getModel(),this.editor.getPosition(),e.items),r=e.items[o];n(r)?(this.editor.pushUndoStop(),this._insertSuggestion({index:o,item:r,model:e},7)):i()}),void 0,t)})),this.model.trigger({auto:!1,shy:!0}),this.editor.revealPosition(t,0),this.editor.focus()}acceptSelectedSuggestion(e,t){const i=this.widget.value.getFocusedItem();let n=0;e&&(n|=4),t&&(n|=8),this._insertSuggestion(i,n)}acceptNextSuggestion(){this._alternatives.value.next()}acceptPrevSuggestion(){this._alternatives.value.prev()}cancelSuggestWidget(){this.model.cancel(),this.model.clear(),this.widget.value.hideWidget()}selectNextSuggestion(){this.widget.value.selectNext()}selectNextPageSuggestion(){this.widget.value.selectNextPage()}selectLastSuggestion(){this.widget.value.selectLast()}selectPrevSuggestion(){this.widget.value.selectPrevious()}selectPrevPageSuggestion(){this.widget.value.selectPreviousPage()}selectFirstSuggestion(){this.widget.value.selectFirst()}toggleSuggestionDetails(){this.widget.value.toggleDetails()}toggleExplainMode(){this.widget.value.toggleExplainMode()}toggleSuggestionFocus(){this.widget.value.toggleDetailsFocus()}resetWidgetSize(){this.widget.value.resetPersistedSize()}forceRenderingAbove(){this.widget.value.forceRenderingAbove()}stopForceRenderingAbove(){this.widget.isInitialized&&this.widget.value.stopForceRenderingAbove()}registerSelector(e){return this._selectors.register(e)}};ft.ID="editor.contrib.suggestController",ft=function(e,t,i,n){var o,r=arguments.length,s=r<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,i):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(e,t,i,n);else for(var a=e.length-1;a>=0;a--)(o=e[a])&&(s=(r<3?o(s):r>3?o(t,i,s):o(t,i))||s);return r>3&&s&&Object.defineProperty(t,i,s),s}([pt(1,A),pt(2,W.Hy),pt(3,R.i6),pt(4,L.TG),pt(5,H.VZ),pt(6,X.b)],ft);class _t{constructor(e){this.prioritySelector=e,this._items=new Array}register(e){if(-1!==this._items.indexOf(e))throw new Error("Value is already registered");return this._items.push(e),this._items.sort(((e,t)=>this.prioritySelector(t)-this.prioritySelector(e))),{dispose:()=>{const t=this._items.indexOf(e);t>=0&&this._items.splice(t,1)}}}get itemsOrderedByPriorityDesc(){return this._items}}class bt extends m.R6{constructor(){super({id:bt.id,label:F.NC("vs/editor/contrib/suggest/browser/suggestController","suggest.trigger.label","Trigger Suggest"),alias:"Trigger Suggest",precondition:R.Ao.and(v.u.writable,v.u.hasCompletionItemProvider),kbOpts:{kbExpr:v.u.textInputFocus,primary:2058,secondary:[2087],mac:{primary:266,secondary:[521,2087]},weight:100}})}run(e,t,i){const n=ft.get(t);if(!n)return;let o;i&&"object"==typeof i&&!0===i.auto&&(o=!0),n.triggerSuggest(void 0,o)}}bt.id="editor.action.triggerSuggest",(0,m._K)(ft.ID,ft),(0,m.Qr)(bt);const vt=190,Ct=m._l.bindToContribution(ft.get);(0,m.fK)(new Ct({id:"acceptSelectedSuggestion",precondition:z._y.Visible,handler(e){e.acceptSelectedSuggestion(!0,!1)}})),V.W.registerKeybindingRule({id:"acceptSelectedSuggestion",when:R.Ao.and(z._y.Visible,v.u.textInputFocus),primary:2,weight:vt}),V.W.registerKeybindingRule({id:"acceptSelectedSuggestion",when:R.Ao.and(z._y.Visible,v.u.textInputFocus,z._y.AcceptSuggestionsOnEnter,z._y.MakesTextEdit),primary:3,weight:vt}),B.BH.appendMenuItem(z.GI,{command:{id:"acceptSelectedSuggestion",title:F.NC("vs/editor/contrib/suggest/browser/suggestController","accept.insert","Insert")},group:"left",order:1,when:z._y.HasInsertAndReplaceRange.toNegated()}),B.BH.appendMenuItem(z.GI,{command:{id:"acceptSelectedSuggestion",title:F.NC("vs/editor/contrib/suggest/browser/suggestController","accept.insert","Insert")},group:"left",order:1,when:R.Ao.and(z._y.HasInsertAndReplaceRange,z._y.InsertMode.isEqualTo("insert"))}),B.BH.appendMenuItem(z.GI,{command:{id:"acceptSelectedSuggestion",title:F.NC("vs/editor/contrib/suggest/browser/suggestController","accept.replace","Replace")},group:"left",order:1,when:R.Ao.and(z._y.HasInsertAndReplaceRange,z._y.InsertMode.isEqualTo("replace"))}),(0,m.fK)(new Ct({id:"acceptAlternativeSelectedSuggestion",precondition:R.Ao.and(z._y.Visible,v.u.textInputFocus),kbOpts:{weight:vt,kbExpr:v.u.textInputFocus,primary:1027,secondary:[1026]},handler(e){e.acceptSelectedSuggestion(!1,!0)},menuOpts:[{menuId:z.GI,group:"left",order:2,when:R.Ao.and(z._y.HasInsertAndReplaceRange,z._y.InsertMode.isEqualTo("insert")),title:F.NC("vs/editor/contrib/suggest/browser/suggestController","accept.replace","Replace")},{menuId:z.GI,group:"left",order:2,when:R.Ao.and(z._y.HasInsertAndReplaceRange,z._y.InsertMode.isEqualTo("replace")),title:F.NC("vs/editor/contrib/suggest/browser/suggestController","accept.insert","Insert")}]})),W.P0.registerCommandAlias("acceptSelectedSuggestionOnEnter","acceptSelectedSuggestion"),(0,m.fK)(new Ct({id:"hideSuggestWidget",precondition:z._y.Visible,handler:e=>e.cancelSuggestWidget(),kbOpts:{weight:vt,kbExpr:v.u.textInputFocus,primary:9,secondary:[1033]}})),(0,m.fK)(new Ct({id:"selectNextSuggestion",precondition:R.Ao.and(z._y.Visible,z._y.MultipleSuggestions),handler:e=>e.selectNextSuggestion(),kbOpts:{weight:vt,kbExpr:v.u.textInputFocus,primary:18,secondary:[2066],mac:{primary:18,secondary:[2066,300]}}})),(0,m.fK)(new Ct({id:"selectNextPageSuggestion",precondition:R.Ao.and(z._y.Visible,z._y.MultipleSuggestions),handler:e=>e.selectNextPageSuggestion(),kbOpts:{weight:vt,kbExpr:v.u.textInputFocus,primary:12,secondary:[2060]}})),(0,m.fK)(new Ct({id:"selectLastSuggestion",precondition:R.Ao.and(z._y.Visible,z._y.MultipleSuggestions),handler:e=>e.selectLastSuggestion()})),(0,m.fK)(new Ct({id:"selectPrevSuggestion",precondition:R.Ao.and(z._y.Visible,z._y.MultipleSuggestions),handler:e=>e.selectPrevSuggestion(),kbOpts:{weight:vt,kbExpr:v.u.textInputFocus,primary:16,secondary:[2064],mac:{primary:16,secondary:[2064,302]}}})),(0,m.fK)(new Ct({id:"selectPrevPageSuggestion",precondition:R.Ao.and(z._y.Visible,z._y.MultipleSuggestions),handler:e=>e.selectPrevPageSuggestion(),kbOpts:{weight:vt,kbExpr:v.u.textInputFocus,primary:11,secondary:[2059]}})),(0,m.fK)(new Ct({id:"selectFirstSuggestion",precondition:R.Ao.and(z._y.Visible,z._y.MultipleSuggestions),handler:e=>e.selectFirstSuggestion()})),(0,m.fK)(new Ct({id:"toggleSuggestionDetails",precondition:z._y.Visible,handler:e=>e.toggleSuggestionDetails(),kbOpts:{weight:vt,kbExpr:v.u.textInputFocus,primary:2058,secondary:[2087],mac:{primary:266,secondary:[2087]}},menuOpts:[{menuId:z.GI,group:"right",order:1,when:R.Ao.and(z._y.DetailsVisible,z._y.CanResolve),title:F.NC("vs/editor/contrib/suggest/browser/suggestController","detail.more","show less")},{menuId:z.GI,group:"right",order:1,when:R.Ao.and(z._y.DetailsVisible.toNegated(),z._y.CanResolve),title:F.NC("vs/editor/contrib/suggest/browser/suggestController","detail.less","show more")}]})),(0,m.fK)(new Ct({id:"toggleExplainMode",precondition:z._y.Visible,handler:e=>e.toggleExplainMode(),kbOpts:{weight:100,primary:2133}})),(0,m.fK)(new Ct({id:"toggleSuggestionFocus",precondition:z._y.Visible,handler:e=>e.toggleSuggestionFocus(),kbOpts:{weight:vt,kbExpr:v.u.textInputFocus,primary:2570,mac:{primary:778}}})),(0,m.fK)(new Ct({id:"insertBestCompletion",precondition:R.Ao.and(v.u.textInputFocus,R.Ao.equals("config.editor.tabCompletion","on"),M.AtEnd,z._y.Visible.toNegated(),$.OtherSuggestions.toNegated(),C.SnippetController2.InSnippetMode.toNegated()),handler:(e,t)=>{e.triggerSuggestAndAcceptBest((0,g.Kn)(t)?Object.assign({fallback:"tab"},t):{fallback:"tab"})},kbOpts:{weight:vt,primary:2}})),(0,m.fK)(new Ct({id:"insertNextSuggestion",precondition:R.Ao.and(v.u.textInputFocus,R.Ao.equals("config.editor.tabCompletion","on"),$.OtherSuggestions,z._y.Visible.toNegated(),C.SnippetController2.InSnippetMode.toNegated()),handler:e=>e.acceptNextSuggestion(),kbOpts:{weight:vt,kbExpr:v.u.textInputFocus,primary:2}})),(0,m.fK)(new Ct({id:"insertPrevSuggestion",precondition:R.Ao.and(v.u.textInputFocus,R.Ao.equals("config.editor.tabCompletion","on"),$.OtherSuggestions,z._y.Visible.toNegated(),C.SnippetController2.InSnippetMode.toNegated()),handler:e=>e.acceptPrevSuggestion(),kbOpts:{weight:vt,kbExpr:v.u.textInputFocus,primary:1026}})),(0,m.Qr)(class extends m.R6{constructor(){super({id:"editor.action.resetSuggestSize",label:F.NC("vs/editor/contrib/suggest/browser/suggestController","suggest.reset.label","Reset Suggest Widget Size"),alias:"Reset Suggest Widget Size",precondition:void 0})}run(e,t){var i;null===(i=ft.get(t))||void 0===i||i.resetWidgetSize()}})},31300:function(e,t,i){"use strict";var n=i(4821),o=i(89982),r=i(45164),s=i(81585);const a=(0,r.P6G)("symbolIcon.arrayForeground",{dark:r.dRz,light:r.dRz,hc:r.dRz},(0,o.NC)("vs/editor/contrib/symbolIcons/browser/symbolIcons","symbolIcon.arrayForeground","The foreground color for array symbols. These symbols appear in the outline, breadcrumb, and suggest widget.")),l=(0,r.P6G)("symbolIcon.booleanForeground",{dark:r.dRz,light:r.dRz,hc:r.dRz},(0,o.NC)("vs/editor/contrib/symbolIcons/browser/symbolIcons","symbolIcon.booleanForeground","The foreground color for boolean symbols. These symbols appear in the outline, breadcrumb, and suggest widget.")),c=(0,r.P6G)("symbolIcon.classForeground",{dark:"#EE9D28",light:"#D67E00",hc:"#EE9D28"},(0,o.NC)("vs/editor/contrib/symbolIcons/browser/symbolIcons","symbolIcon.classForeground","The foreground color for class symbols. These symbols appear in the outline, breadcrumb, and suggest widget.")),d=(0,r.P6G)("symbolIcon.colorForeground",{dark:r.dRz,light:r.dRz,hc:r.dRz},(0,o.NC)("vs/editor/contrib/symbolIcons/browser/symbolIcons","symbolIcon.colorForeground","The foreground color for color symbols. These symbols appear in the outline, breadcrumb, and suggest widget.")),u=(0,r.P6G)("symbolIcon.constantForeground",{dark:r.dRz,light:r.dRz,hc:r.dRz},(0,o.NC)("vs/editor/contrib/symbolIcons/browser/symbolIcons","symbolIcon.constantForeground","The foreground color for constant symbols. These symbols appear in the outline, breadcrumb, and suggest widget.")),h=(0,r.P6G)("symbolIcon.constructorForeground",{dark:"#B180D7",light:"#652D90",hc:"#B180D7"},(0,o.NC)("vs/editor/contrib/symbolIcons/browser/symbolIcons","symbolIcon.constructorForeground","The foreground color for constructor symbols. These symbols appear in the outline, breadcrumb, and suggest widget.")),g=(0,r.P6G)("symbolIcon.enumeratorForeground",{dark:"#EE9D28",light:"#D67E00",hc:"#EE9D28"},(0,o.NC)("vs/editor/contrib/symbolIcons/browser/symbolIcons","symbolIcon.enumeratorForeground","The foreground color for enumerator symbols. These symbols appear in the outline, breadcrumb, and suggest widget.")),p=(0,r.P6G)("symbolIcon.enumeratorMemberForeground",{dark:"#75BEFF",light:"#007ACC",hc:"#75BEFF"},(0,o.NC)("vs/editor/contrib/symbolIcons/browser/symbolIcons","symbolIcon.enumeratorMemberForeground","The foreground color for enumerator member symbols. These symbols appear in the outline, breadcrumb, and suggest widget.")),m=(0,r.P6G)("symbolIcon.eventForeground",{dark:"#EE9D28",light:"#D67E00",hc:"#EE9D28"},(0,o.NC)("vs/editor/contrib/symbolIcons/browser/symbolIcons","symbolIcon.eventForeground","The foreground color for event symbols. These symbols appear in the outline, breadcrumb, and suggest widget.")),f=(0,r.P6G)("symbolIcon.fieldForeground",{dark:"#75BEFF",light:"#007ACC",hc:"#75BEFF"},(0,o.NC)("vs/editor/contrib/symbolIcons/browser/symbolIcons","symbolIcon.fieldForeground","The foreground color for field symbols. These symbols appear in the outline, breadcrumb, and suggest widget.")),_=(0,r.P6G)("symbolIcon.fileForeground",{dark:r.dRz,light:r.dRz,hc:r.dRz},(0,o.NC)("vs/editor/contrib/symbolIcons/browser/symbolIcons","symbolIcon.fileForeground","The foreground color for file symbols. These symbols appear in the outline, breadcrumb, and suggest widget.")),b=(0,r.P6G)("symbolIcon.folderForeground",{dark:r.dRz,light:r.dRz,hc:r.dRz},(0,o.NC)("vs/editor/contrib/symbolIcons/browser/symbolIcons","symbolIcon.folderForeground","The foreground color for folder symbols. These symbols appear in the outline, breadcrumb, and suggest widget.")),v=(0,r.P6G)("symbolIcon.functionForeground",{dark:"#B180D7",light:"#652D90",hc:"#B180D7"},(0,o.NC)("vs/editor/contrib/symbolIcons/browser/symbolIcons","symbolIcon.functionForeground","The foreground color for function symbols. These symbols appear in the outline, breadcrumb, and suggest widget.")),C=(0,r.P6G)("symbolIcon.interfaceForeground",{dark:"#75BEFF",light:"#007ACC",hc:"#75BEFF"},(0,o.NC)("vs/editor/contrib/symbolIcons/browser/symbolIcons","symbolIcon.interfaceForeground","The foreground color for interface symbols. These symbols appear in the outline, breadcrumb, and suggest widget.")),w=(0,r.P6G)("symbolIcon.keyForeground",{dark:r.dRz,light:r.dRz,hc:r.dRz},(0,o.NC)("vs/editor/contrib/symbolIcons/browser/symbolIcons","symbolIcon.keyForeground","The foreground color for key symbols. These symbols appear in the outline, breadcrumb, and suggest widget.")),y=(0,r.P6G)("symbolIcon.keywordForeground",{dark:r.dRz,light:r.dRz,hc:r.dRz},(0,o.NC)("vs/editor/contrib/symbolIcons/browser/symbolIcons","symbolIcon.keywordForeground","The foreground color for keyword symbols. These symbols appear in the outline, breadcrumb, and suggest widget.")),S=(0,r.P6G)("symbolIcon.methodForeground",{dark:"#B180D7",light:"#652D90",hc:"#B180D7"},(0,o.NC)("vs/editor/contrib/symbolIcons/browser/symbolIcons","symbolIcon.methodForeground","The foreground color for method symbols. These symbols appear in the outline, breadcrumb, and suggest widget.")),x=(0,r.P6G)("symbolIcon.moduleForeground",{dark:r.dRz,light:r.dRz,hc:r.dRz},(0,o.NC)("vs/editor/contrib/symbolIcons/browser/symbolIcons","symbolIcon.moduleForeground","The foreground color for module symbols. These symbols appear in the outline, breadcrumb, and suggest widget.")),k=(0,r.P6G)("symbolIcon.namespaceForeground",{dark:r.dRz,light:r.dRz,hc:r.dRz},(0,o.NC)("vs/editor/contrib/symbolIcons/browser/symbolIcons","symbolIcon.namespaceForeground","The foreground color for namespace symbols. These symbols appear in the outline, breadcrumb, and suggest widget.")),L=(0,r.P6G)("symbolIcon.nullForeground",{dark:r.dRz,light:r.dRz,hc:r.dRz},(0,o.NC)("vs/editor/contrib/symbolIcons/browser/symbolIcons","symbolIcon.nullForeground","The foreground color for null symbols. These symbols appear in the outline, breadcrumb, and suggest widget.")),E=(0,r.P6G)("symbolIcon.numberForeground",{dark:r.dRz,light:r.dRz,hc:r.dRz},(0,o.NC)("vs/editor/contrib/symbolIcons/browser/symbolIcons","symbolIcon.numberForeground","The foreground color for number symbols. These symbols appear in the outline, breadcrumb, and suggest widget.")),N=(0,r.P6G)("symbolIcon.objectForeground",{dark:r.dRz,light:r.dRz,hc:r.dRz},(0,o.NC)("vs/editor/contrib/symbolIcons/browser/symbolIcons","symbolIcon.objectForeground","The foreground color for object symbols. These symbols appear in the outline, breadcrumb, and suggest widget.")),D=(0,r.P6G)("symbolIcon.operatorForeground",{dark:r.dRz,light:r.dRz,hc:r.dRz},(0,o.NC)("vs/editor/contrib/symbolIcons/browser/symbolIcons","symbolIcon.operatorForeground","The foreground color for operator symbols. These symbols appear in the outline, breadcrumb, and suggest widget.")),I=(0,r.P6G)("symbolIcon.packageForeground",{dark:r.dRz,light:r.dRz,hc:r.dRz},(0,o.NC)("vs/editor/contrib/symbolIcons/browser/symbolIcons","symbolIcon.packageForeground","The foreground color for package symbols. These symbols appear in the outline, breadcrumb, and suggest widget.")),T=(0,r.P6G)("symbolIcon.propertyForeground",{dark:r.dRz,light:r.dRz,hc:r.dRz},(0,o.NC)("vs/editor/contrib/symbolIcons/browser/symbolIcons","symbolIcon.propertyForeground","The foreground color for property symbols. These symbols appear in the outline, breadcrumb, and suggest widget.")),A=(0,r.P6G)("symbolIcon.referenceForeground",{dark:r.dRz,light:r.dRz,hc:r.dRz},(0,o.NC)("vs/editor/contrib/symbolIcons/browser/symbolIcons","symbolIcon.referenceForeground","The foreground color for reference symbols. These symbols appear in the outline, breadcrumb, and suggest widget.")),R=(0,r.P6G)("symbolIcon.snippetForeground",{dark:r.dRz,light:r.dRz,hc:r.dRz},(0,o.NC)("vs/editor/contrib/symbolIcons/browser/symbolIcons","symbolIcon.snippetForeground","The foreground color for snippet symbols. These symbols appear in the outline, breadcrumb, and suggest widget.")),M=(0,r.P6G)("symbolIcon.stringForeground",{dark:r.dRz,light:r.dRz,hc:r.dRz},(0,o.NC)("vs/editor/contrib/symbolIcons/browser/symbolIcons","symbolIcon.stringForeground","The foreground color for string symbols. These symbols appear in the outline, breadcrumb, and suggest widget.")),O=(0,r.P6G)("symbolIcon.structForeground",{dark:r.dRz,light:r.dRz,hc:r.dRz},(0,o.NC)("vs/editor/contrib/symbolIcons/browser/symbolIcons","symbolIcon.structForeground","The foreground color for struct symbols. These symbols appear in the outline, breadcrumb, and suggest widget.")),P=(0,r.P6G)("symbolIcon.textForeground",{dark:r.dRz,light:r.dRz,hc:r.dRz},(0,o.NC)("vs/editor/contrib/symbolIcons/browser/symbolIcons","symbolIcon.textForeground","The foreground color for text symbols. These symbols appear in the outline, breadcrumb, and suggest widget.")),F=(0,r.P6G)("symbolIcon.typeParameterForeground",{dark:r.dRz,light:r.dRz,hc:r.dRz},(0,o.NC)("vs/editor/contrib/symbolIcons/browser/symbolIcons","symbolIcon.typeParameterForeground","The foreground color for type parameter symbols. These symbols appear in the outline, breadcrumb, and suggest widget.")),B=(0,r.P6G)("symbolIcon.unitForeground",{dark:r.dRz,light:r.dRz,hc:r.dRz},(0,o.NC)("vs/editor/contrib/symbolIcons/browser/symbolIcons","symbolIcon.unitForeground","The foreground color for unit symbols. These symbols appear in the outline, breadcrumb, and suggest widget.")),W=(0,r.P6G)("symbolIcon.variableForeground",{dark:"#75BEFF",light:"#007ACC",hc:"#75BEFF"},(0,o.NC)("vs/editor/contrib/symbolIcons/browser/symbolIcons","symbolIcon.variableForeground","The foreground color for variable symbols. These symbols appear in the outline, breadcrumb, and suggest widget."));(0,s.Ic)(((e,t)=>{const i=e.getColor(a);i&&t.addRule(`${n.lA.symbolArray.cssSelector} { color: ${i}; }`);const o=e.getColor(l);o&&t.addRule(`${n.lA.symbolBoolean.cssSelector} { color: ${o}; }`);const r=e.getColor(c);r&&t.addRule(`${n.lA.symbolClass.cssSelector} { color: ${r}; }`);const s=e.getColor(S);s&&t.addRule(`${n.lA.symbolMethod.cssSelector} { color: ${s}; }`);const V=e.getColor(d);V&&t.addRule(`${n.lA.symbolColor.cssSelector} { color: ${V}; }`);const H=e.getColor(u);H&&t.addRule(`${n.lA.symbolConstant.cssSelector} { color: ${H}; }`);const z=e.getColor(h);z&&t.addRule(`${n.lA.symbolConstructor.cssSelector} { color: ${z}; }`);const $=e.getColor(g);$&&t.addRule(`\n\t\t\t${n.lA.symbolValue.cssSelector},${n.lA.symbolEnum.cssSelector} { color: ${$}; }`);const U=e.getColor(p);U&&t.addRule(`${n.lA.symbolEnumMember.cssSelector} { color: ${U}; }`);const j=e.getColor(m);j&&t.addRule(`${n.lA.symbolEvent.cssSelector} { color: ${j}; }`);const K=e.getColor(f);K&&t.addRule(`${n.lA.symbolField.cssSelector} { color: ${K}; }`);const q=e.getColor(_);q&&t.addRule(`${n.lA.symbolFile.cssSelector} { color: ${q}; }`);const G=e.getColor(b);G&&t.addRule(`${n.lA.symbolFolder.cssSelector} { color: ${G}; }`);const Z=e.getColor(v);Z&&t.addRule(`${n.lA.symbolFunction.cssSelector} { color: ${Z}; }`);const Y=e.getColor(C);Y&&t.addRule(`${n.lA.symbolInterface.cssSelector} { color: ${Y}; }`);const Q=e.getColor(w);Q&&t.addRule(`${n.lA.symbolKey.cssSelector} { color: ${Q}; }`);const X=e.getColor(y);X&&t.addRule(`${n.lA.symbolKeyword.cssSelector} { color: ${X}; }`);const J=e.getColor(x);J&&t.addRule(`${n.lA.symbolModule.cssSelector} { color: ${J}; }`);const ee=e.getColor(k);ee&&t.addRule(`${n.lA.symbolNamespace.cssSelector} { color: ${ee}; }`);const te=e.getColor(L);te&&t.addRule(`${n.lA.symbolNull.cssSelector} { color: ${te}; }`);const ie=e.getColor(E);ie&&t.addRule(`${n.lA.symbolNumber.cssSelector} { color: ${ie}; }`);const ne=e.getColor(N);ne&&t.addRule(`${n.lA.symbolObject.cssSelector} { color: ${ne}; }`);const oe=e.getColor(D);oe&&t.addRule(`${n.lA.symbolOperator.cssSelector} { color: ${oe}; }`);const re=e.getColor(I);re&&t.addRule(`${n.lA.symbolPackage.cssSelector} { color: ${re}; }`);const se=e.getColor(T);se&&t.addRule(`${n.lA.symbolProperty.cssSelector} { color: ${se}; }`);const ae=e.getColor(A);ae&&t.addRule(`${n.lA.symbolReference.cssSelector} { color: ${ae}; }`);const le=e.getColor(R);le&&t.addRule(`${n.lA.symbolSnippet.cssSelector} { color: ${le}; }`);const ce=e.getColor(M);ce&&t.addRule(`${n.lA.symbolString.cssSelector} { color: ${ce}; }`);const de=e.getColor(O);de&&t.addRule(`${n.lA.symbolStruct.cssSelector} { color: ${de}; }`);const ue=e.getColor(P);ue&&t.addRule(`${n.lA.symbolText.cssSelector} { color: ${ue}; }`);const he=e.getColor(F);he&&t.addRule(`${n.lA.symbolTypeParameter.cssSelector} { color: ${he}; }`);const ge=e.getColor(B);ge&&t.addRule(`${n.lA.symbolUnit.cssSelector} { color: ${ge}; }`);const pe=e.getColor(W);pe&&t.addRule(`${n.lA.symbolVariable.cssSelector} { color: ${pe}; }`)}))},13876:function(e,t,i){"use strict";i.r(t),i.d(t,{ToggleTabFocusModeAction:function(){return a}});var n=i(77339),o=i(6158),r=i(4189),s=i(89982);class a extends r.R6{constructor(){super({id:a.ID,label:s.NC("vs/editor/contrib/toggleTabFocusMode/browser/toggleTabFocusMode",{key:"toggle.tabMovesFocus",comment:["Turn on/off use of tab key for moving focus around VS Code"]},"Toggle Tab Key Moves Focus"),alias:"Toggle Tab Key Moves Focus",precondition:void 0,kbOpts:{kbExpr:null,primary:2091,mac:{primary:1323},weight:100}})}run(e,t){const i=!o.n.getTabFocusMode();o.n.setTabFocusMode(i),i?(0,n.Z9)(s.NC("vs/editor/contrib/toggleTabFocusMode/browser/toggleTabFocusMode","toggle.tabMovesFocus.on","Pressing Tab will now move focus to the next focusable element")):(0,n.Z9)(s.NC("vs/editor/contrib/toggleTabFocusMode/browser/toggleTabFocusMode","toggle.tabMovesFocus.off","Pressing Tab will now insert the tab character"))}}a.ID="editor.action.toggleTabFocusMode",(0,r.Qr)(a)},27710:function(e,t,i){"use strict";i.r(t);var n=i(52150),o=i(4189),r=i(89982);class s extends o.R6{constructor(){super({id:"editor.action.forceRetokenize",label:r.NC("vs/editor/contrib/tokenization/browser/tokenization","forceRetokenize","Developer: Force Retokenize"),alias:"Developer: Force Retokenize",precondition:void 0})}run(e,t){if(!t.hasModel())return;const i=t.getModel();i.resetTokenization();const o=new n.G(!0);i.forceTokenization(i.getLineCount()),o.stop(),console.log(`tokenization took ${o.elapsed()}`)}}(0,o.Qr)(s)},88942:function(e,t,i){"use strict";i.r(t),i.d(t,{DisableHighlightingInCommentsAction:function(){return me},DisableHighlightingInStringsAction:function(){return fe},DisableHighlightingOfAmbiguousCharactersAction:function(){return _e},DisableHighlightingOfInvisibleCharactersAction:function(){return be},DisableHighlightingOfNonBasicAsciiCharactersAction:function(){return ve},ShowExcludeOptions:function(){return Ce},UnicodeHighlighter:function(){return ae},UnicodeHighlighterHoverParticipant:function(){return de},warningIcon:function(){return se}});var n=i(40027),o=i(4821),r=i(4004),s=i(6954),a=i(18039),l=i(93379),c=i.n(l),d=i(7795),u=i.n(d),h=i(90569),g=i.n(h),p=i(3565),m=i.n(p),f=i(19216),_=i.n(f),b=i(44589),v=i.n(b),C=i(18557),w={};w.styleTagTransform=v(),w.setAttributes=m(),w.insert=g().bind(null,"head"),w.domAPI=u(),w.insertStyleElement=_(),c()(C.Z,w),C.Z&&C.Z.locals&&C.Z.locals;var y=i(4189),S=i(18966),x=i(25732),k=i(5083),L=i(22157),E=i(10940),N=i(63280),D=i(66801),I=i(1093),T=i(9604),A={};A.styleTagTransform=v(),A.setAttributes=m(),A.insert=g().bind(null,"head"),A.domAPI=u(),A.insertStyleElement=_(),c()(T.Z,A),T.Z&&T.Z.locals&&T.Z.locals;var R=i(68695),M=i(47995),O=i(11007),P=i(72956),F=i(12260),B=i(27163),W=i(33200),V=i(83055),H=i(46718),z=i(82523),$=i(45164),U=i(81585);let j=class extends r.JT{constructor(e,t,i={},n){var o;super(),this._link=t,this._enabled=!0,this.el=(0,R.R3)(e,(0,R.$)("a.monaco-link",{tabIndex:null!==(o=t.tabIndex)&&void 0!==o?o:0,href:t.href,title:t.title},t.label)),this.el.setAttribute("role","button");const r=this._register(new B.Y(this.el,"click")),s=this._register(new B.Y(this.el,"keypress")),a=H.ju.chain(s.event).map((e=>new W.y(e))).filter((e=>3===e.keyCode)).event,l=this._register(new B.Y(this.el,V.t.Tap)).event;this._register(V.o.addTarget(this.el));const c=H.ju.any(r.event,a,l);this._register(c((e=>{this.enabled&&(R.zB.stop(e,!0),(null==i?void 0:i.opener)?i.opener(this._link.href):n.open(this._link.href,{allowCommands:!0}))}))),this.enabled=!0}get enabled(){return this._enabled}set enabled(e){e?(this.el.setAttribute("aria-disabled","false"),this.el.tabIndex=0,this.el.style.pointerEvents="auto",this.el.style.opacity="1",this.el.style.cursor="pointer",this._enabled=!1):(this.el.setAttribute("aria-disabled","true"),this.el.tabIndex=-1,this.el.style.pointerEvents="none",this.el.style.opacity="0.4",this.el.style.cursor="default",this._enabled=!0),this._enabled=e}};var K,q;j=function(e,t,i,n){var o,r=arguments.length,s=r<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,i):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(e,t,i,n);else for(var a=e.length-1;a>=0;a--)(o=e[a])&&(s=(r<3?o(s):r>3?o(t,i,s):o(t,i))||s);return r>3&&s&&Object.defineProperty(t,i,s),s}([(K=3,q=z.v4,function(e,t){q(e,t,K)})],j),(0,U.Ic)(((e,t)=>{const i=e.getColor($.url);i&&t.addRule(`.monaco-link { color: ${i}; }`);const n=e.getColor($.sgC);n&&t.addRule(`.monaco-link:hover { color: ${n}; }`)}));var G=i(26181),Z=function(e,t,i,n){var o,r=arguments.length,s=r<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,i):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(e,t,i,n);else for(var a=e.length-1;a>=0;a--)(o=e[a])&&(s=(r<3?o(s):r>3?o(t,i,s):o(t,i))||s);return r>3&&s&&Object.defineProperty(t,i,s),s},Y=function(e,t){return function(i,n){t(i,n,e)}};let Q=class extends r.JT{constructor(e,t){super(),this._editor=e,this.instantiationService=t,this.banner=this._register(this.instantiationService.createInstance(X))}hide(){this._editor.setBanner(null,0),this.banner.clear()}show(e){this.banner.show(Object.assign(Object.assign({},e),{onClose:()=>{this.hide(),e.onClose&&e.onClose()}})),this._editor.setBanner(this.banner.element,26)}};Q=Z([Y(1,F.TG)],Q);let X=class extends r.JT{constructor(e){super(),this.instantiationService=e,this.markdownRenderer=this.instantiationService.createInstance(P.$,{}),this.element=(0,R.$)("div.editor-banner"),this.element.tabIndex=0}getAriaLabel(e){return e.ariaLabel?e.ariaLabel:"string"==typeof e.message?e.message:void 0}getBannerMessage(e){if("string"==typeof e){const t=(0,R.$)("span");return t.innerText=e,t}return this.markdownRenderer.render(e).element}clear(){(0,R.PO)(this.element)}show(e){(0,R.PO)(this.element);const t=this.getAriaLabel(e);t&&this.element.setAttribute("aria-label",t);const i=(0,R.R3)(this.element,(0,R.$)("div.icon-container"));i.setAttribute("aria-hidden","true"),e.icon&&i.appendChild((0,R.$)(`div${U.kS.asCSSSelector(e.icon)}`));const n=(0,R.R3)(this.element,(0,R.$)("div.message-container"));if(n.setAttribute("aria-hidden","true"),n.appendChild(this.getBannerMessage(e.message)),this.messageActionsContainer=(0,R.R3)(this.element,(0,R.$)("div.message-actions-container")),e.actions)for(const t of e.actions)this._register(this.instantiationService.createInstance(j,this.messageActionsContainer,Object.assign(Object.assign({},t),{tabIndex:-1}),{}));const o=(0,R.R3)(this.element,(0,R.$)("div.action-container"));this.actionBar=this._register(new M.o(o)),this.actionBar.push(this._register(new O.aU("banner.close","Close Banner",U.kS.asClassName(G.s_),!0,(()=>{"function"==typeof e.onClose&&e.onClose()}))),{icon:!0,label:!1}),this.actionBar.setFocusable(!1)}};X=Z([Y(0,F.TG)],X);var J=i(89982),ee=i(40539),te=i(22447),ie=i(32817),ne=function(e,t,i,n){var o,r=arguments.length,s=r<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,i):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(e,t,i,n);else for(var a=e.length-1;a>=0;a--)(o=e[a])&&(s=(r<3?o(s):r>3?o(t,i,s):o(t,i))||s);return r>3&&s&&Object.defineProperty(t,i,s),s},oe=function(e,t){return function(i,n){t(i,n,e)}},re=function(e,t,i,n){return new(i||(i=Promise))((function(o,r){function s(e){try{l(n.next(e))}catch(e){r(e)}}function a(e){try{l(n.throw(e))}catch(e){r(e)}}function l(e){var t;e.done?o(e.value):(t=e.value,t instanceof i?t:new i((function(e){e(t)}))).then(s,a)}l((n=n.apply(e,t||[])).next())}))};const se=(0,G.q5)("extensions-warning-message",o.lA.warning,J.NC("vs/editor/contrib/unicodeHighlighter/browser/unicodeHighlighter","warningIcon","Icon shown with a warning message in the extensions editor."));let ae=class extends r.JT{constructor(e,t,i,n){super(),this._editor=e,this._editorWorkerService=t,this._workspaceTrustService=i,this._highlighter=null,this._bannerClosed=!1,this._updateState=e=>{if(e&&e.hasMore){if(this._bannerClosed)return;const t=Math.max(e.ambiguousCharacterCount,e.nonBasicAsciiCharacterCount,e.invisibleCharacterCount);let i;if(e.nonBasicAsciiCharacterCount>=t)i={message:J.NC("vs/editor/contrib/unicodeHighlighter/browser/unicodeHighlighter","unicodeHighlighting.thisDocumentHasManyNonBasicAsciiUnicodeCharacters","This document contains many non-basic ASCII unicode characters"),command:new ve};else if(e.ambiguousCharacterCount>=t)i={message:J.NC("vs/editor/contrib/unicodeHighlighter/browser/unicodeHighlighter","unicodeHighlighting.thisDocumentHasManyAmbiguousUnicodeCharacters","This document contains many ambiguous unicode characters"),command:new _e};else{if(!(e.invisibleCharacterCount>=t))throw new Error("Unreachable");i={message:J.NC("vs/editor/contrib/unicodeHighlighter/browser/unicodeHighlighter","unicodeHighlighting.thisDocumentHasManyInvisibleUnicodeCharacters","This document contains many invisible unicode characters"),command:new be}}this._bannerController.show({id:"unicodeHighlightBanner",message:i.message,icon:se,actions:[{label:i.command.shortLabel,href:`command:${i.command.id}`}],onClose:()=>{this._bannerClosed=!0}})}else this._bannerController.hide()},this._bannerController=this._register(n.createInstance(Q,e)),this._register(this._editor.onDidChangeModel((()=>{this._bannerClosed=!1,this._updateHighlighter()}))),this._options=e.getOption(113),this._register(i.onDidChangeTrust((e=>{this._updateHighlighter()}))),this._register(e.onDidChangeConfiguration((t=>{t.hasChanged(113)&&(this._options=e.getOption(113),this._updateHighlighter())}))),this._updateHighlighter()}dispose(){this._highlighter&&(this._highlighter.dispose(),this._highlighter=null),super.dispose()}_updateHighlighter(){if(this._updateState(null),this._highlighter&&(this._highlighter.dispose(),this._highlighter=null),!this._editor.hasModel())return;const e=function(e,t){return{nonBasicASCII:t.nonBasicASCII===S.Av?!e:t.nonBasicASCII,ambiguousCharacters:t.ambiguousCharacters,invisibleCharacters:t.invisibleCharacters,includeComments:t.includeComments===S.Av?!e:t.includeComments,includeStrings:t.includeStrings===S.Av?!e:t.includeStrings,allowedCharacters:t.allowedCharacters,allowedLocales:t.allowedLocales}}(this._workspaceTrustService.isWorkspaceTrusted(),this._options);if([e.nonBasicASCII,e.ambiguousCharacters,e.invisibleCharacters].every((e=>!1===e)))return;const t={nonBasicASCII:e.nonBasicASCII,ambiguousCharacters:e.ambiguousCharacters,invisibleCharacters:e.invisibleCharacters,includeComments:e.includeComments,includeStrings:e.includeStrings,allowedCodePoints:Object.keys(e.allowedCharacters).map((e=>e.codePointAt(0))),allowedLocales:Object.keys(e.allowedLocales).map((e=>"_os"===e?(new Intl.NumberFormat).resolvedOptions().locale:"_vscode"===e?s.dK:e))};this._editorWorkerService.canComputeUnicodeHighlights(this._editor.getModel().uri)?this._highlighter=new le(this._editor,t,this._updateState,this._editorWorkerService):this._highlighter=new ce(this._editor,t,this._updateState)}getDecorationInfo(e){return this._highlighter?this._highlighter.getDecorationInfo(e):null}};ae.ID="editor.contrib.unicodeHighlighter",ae=ne([oe(1,L.p),oe(2,ie.Y),oe(3,F.TG)],ae);let le=class extends r.JT{constructor(e,t,i,o){super(),this._editor=e,this._options=t,this._updateState=i,this._editorWorkerService=o,this._model=this._editor.getModel(),this._decorationIds=new Set,this._updateSoon=this._register(new n.pY((()=>this._update()),250)),this._register(this._editor.onDidChangeModelContent((()=>{this._updateSoon.schedule()}))),this._updateSoon.schedule()}dispose(){this._decorationIds=new Set(this._model.deltaDecorations(Array.from(this._decorationIds),[])),super.dispose()}_update(){if(this._model.isDisposed())return;if(!this._model.mightContainNonBasicASCII())return void(this._decorationIds=new Set(this._editor.deltaDecorations(Array.from(this._decorationIds),[])));const e=this._model.getVersionId();this._editorWorkerService.computedUnicodeHighlights(this._model.uri,this._options).then((t=>{if(this._model.isDisposed())return;if(this._model.getVersionId()!==e)return;this._updateState(t);const i=[];if(!t.hasMore)for(const e of t.ranges)i.push({range:e,options:pe.instance.getDecorationFromOptions(this._options)});this._decorationIds=new Set(this._editor.deltaDecorations(Array.from(this._decorationIds),i))}))}getDecorationInfo(e){if(!this._decorationIds.has(e))return null;const t=this._editor.getModel(),i=t.getDecorationRange(e),n={range:i,options:pe.instance.getDecorationFromOptions(this._options),id:e,ownerId:0};return(0,N.Fd)(t,n)?{reason:ge(t.getValueInRange(i),this._options),inComment:(0,N.$t)(t,n),inString:(0,N.zg)(t,n)}:null}};le=ne([oe(3,L.p)],le);class ce extends r.JT{constructor(e,t,i){super(),this._editor=e,this._options=t,this._updateState=i,this._model=this._editor.getModel(),this._decorationIds=new Set,this._updateSoon=this._register(new n.pY((()=>this._update()),250)),this._register(this._editor.onDidLayoutChange((()=>{this._updateSoon.schedule()}))),this._register(this._editor.onDidScrollChange((()=>{this._updateSoon.schedule()}))),this._register(this._editor.onDidChangeHiddenAreas((()=>{this._updateSoon.schedule()}))),this._register(this._editor.onDidChangeModelContent((()=>{this._updateSoon.schedule()}))),this._updateSoon.schedule()}dispose(){this._decorationIds=new Set(this._model.deltaDecorations(Array.from(this._decorationIds),[])),super.dispose()}_update(){if(this._model.isDisposed())return;if(!this._model.mightContainNonBasicASCII())return void(this._decorationIds=new Set(this._editor.deltaDecorations(Array.from(this._decorationIds),[])));const e=this._editor.getVisibleRanges(),t=[],i={ranges:[],ambiguousCharacterCount:0,invisibleCharacterCount:0,nonBasicAsciiCharacterCount:0,hasMore:!1};for(const t of e){const e=k.a.computeUnicodeHighlights(this._model,this._options,t);for(const t of e.ranges)i.ranges.push(t);i.ambiguousCharacterCount+=i.ambiguousCharacterCount,i.invisibleCharacterCount+=i.invisibleCharacterCount,i.nonBasicAsciiCharacterCount+=i.nonBasicAsciiCharacterCount,i.hasMore=i.hasMore||e.hasMore}if(!i.hasMore)for(const e of i.ranges)t.push({range:e,options:pe.instance.getDecorationFromOptions(this._options)});this._updateState(i),this._decorationIds=new Set(this._editor.deltaDecorations(Array.from(this._decorationIds),t))}getDecorationInfo(e){if(!this._decorationIds.has(e))return null;const t=this._editor.getModel(),i=t.getDecorationRange(e),n=t.getValueInRange(i),o={range:i,options:pe.instance.getDecorationFromOptions(this._options),id:e,ownerId:0};return(0,N.Fd)(t,o)?{reason:ge(n,this._options),inComment:(0,N.$t)(t,o),inString:(0,N.zg)(t,o)}:null}}let de=class{constructor(e,t,i){this._editor=e,this._languageService=t,this._openerService=i,this.hoverOrdinal=4}computeSync(e,t){if(!this._editor.hasModel()||1!==e.type)return[];const i=this._editor.getModel(),n=this._editor.getContribution(ae.ID);if(!n)return[];const o=[];let r=300;for(const e of t){const t=n.getDecorationInfo(e.id);if(!t)continue;const s=i.getValueInRange(e.range).codePointAt(0),a=he(s);let l;switch(t.reason.kind){case 0:l=J.NC("vs/editor/contrib/unicodeHighlighter/browser/unicodeHighlighter","unicodeHighlight.characterIsAmbiguous","The character {0} could be confused with the character {1}, which is more common in source code.",a,he(t.reason.confusableWith.codePointAt(0)));break;case 1:l=J.NC("vs/editor/contrib/unicodeHighlighter/browser/unicodeHighlighter","unicodeHighlight.characterIsInvisible","The character {0} is invisible.",a);break;case 2:l=J.NC("vs/editor/contrib/unicodeHighlighter/browser/unicodeHighlighter","unicodeHighlight.characterIsNonBasicAscii","The character {0} is not a basic ASCII character.",a)}const c={codePoint:s,reason:t.reason,inComment:t.inComment,inString:t.inString},d=[{value:`${l} [${J.NC("vs/editor/contrib/unicodeHighlighter/browser/unicodeHighlighter","unicodeHighlight.adjustSettings","Adjust settings")}](command:${Ce.ID}?${encodeURIComponent(JSON.stringify(c))})`,isTrusted:!0}];o.push(new I.hU(this,e.range,d,r++))}return o}renderHoverParts(e,t){return(0,I.c)(e,t,this._editor,this._languageService,this._openerService)}};function ue(e){return`U+${e.toString(16).padStart(4,"0")}`}function he(e){let t=`\`${ue(e)}\``;return a.vU.isInvisibleCharacter(e)||(t+=` "${function(e){return 96===e?"`` ` ``":"`"+String.fromCodePoint(e)+"`"}(e)}"`),t}function ge(e,t){return k.a.computeUnicodeHighlightReason(e,t)}de=ne([oe(1,E.O),oe(2,z.v4)],de);class pe{constructor(){this.map=new Map}getDecorationFromOptions(e){return this.getDecoration(!e.includeComments,!e.includeStrings)}getDecoration(e,t){const i=`${e}${t}`;let n=this.map.get(i);return n||(n=x.qx.createDynamic({description:"unicode-highlight",stickiness:1,className:"unicode-highlight",showIfCollapsed:!0,overviewRuler:null,minimap:null,hideInCommentTokens:e,hideInStringTokens:t}),this.map.set(i,n)),n}}pe.instance=new pe;class me extends y.R6{constructor(){super({id:_e.ID,label:J.NC("vs/editor/contrib/unicodeHighlighter/browser/unicodeHighlighter","action.unicodeHighlight.disableHighlightingInComments","Disable highlighting of characters in comments"),alias:"Disable highlighting of characters in comments",precondition:void 0}),this.shortLabel=J.NC("vs/editor/contrib/unicodeHighlighter/browser/unicodeHighlighter","unicodeHighlight.disableHighlightingInComments.shortLabel","Disable Highlight In Comments")}run(e,t,i){return re(this,void 0,void 0,(function*(){let t=null==e?void 0:e.get(ee.Ui);t&&this.runAction(t)}))}runAction(e){return re(this,void 0,void 0,(function*(){yield e.updateValue(S.qt.includeComments,!1,1)}))}}class fe extends y.R6{constructor(){super({id:_e.ID,label:J.NC("vs/editor/contrib/unicodeHighlighter/browser/unicodeHighlighter","action.unicodeHighlight.disableHighlightingInStrings","Disable highlighting of characters in strings"),alias:"Disable highlighting of characters in strings",precondition:void 0}),this.shortLabel=J.NC("vs/editor/contrib/unicodeHighlighter/browser/unicodeHighlighter","unicodeHighlight.disableHighlightingInStrings.shortLabel","Disable Highlight In Strings")}run(e,t,i){return re(this,void 0,void 0,(function*(){let t=null==e?void 0:e.get(ee.Ui);t&&this.runAction(t)}))}runAction(e){return re(this,void 0,void 0,(function*(){yield e.updateValue(S.qt.includeStrings,!1,1)}))}}class _e extends y.R6{constructor(){super({id:_e.ID,label:J.NC("vs/editor/contrib/unicodeHighlighter/browser/unicodeHighlighter","action.unicodeHighlight.disableHighlightingOfAmbiguousCharacters","Disable highlighting of ambiguous characters"),alias:"Disable highlighting of ambiguous characters",precondition:void 0}),this.shortLabel=J.NC("vs/editor/contrib/unicodeHighlighter/browser/unicodeHighlighter","unicodeHighlight.disableHighlightingOfAmbiguousCharacters.shortLabel","Disable Ambiguous Highlight")}run(e,t,i){return re(this,void 0,void 0,(function*(){let t=null==e?void 0:e.get(ee.Ui);t&&this.runAction(t)}))}runAction(e){return re(this,void 0,void 0,(function*(){yield e.updateValue(S.qt.ambiguousCharacters,!1,1)}))}}_e.ID="editor.action.unicodeHighlight.disableHighlightingOfAmbiguousCharacters";class be extends y.R6{constructor(){super({id:be.ID,label:J.NC("vs/editor/contrib/unicodeHighlighter/browser/unicodeHighlighter","action.unicodeHighlight.disableHighlightingOfInvisibleCharacters","Disable highlighting of invisible characters"),alias:"Disable highlighting of invisible characters",precondition:void 0}),this.shortLabel=J.NC("vs/editor/contrib/unicodeHighlighter/browser/unicodeHighlighter","unicodeHighlight.disableHighlightingOfInvisibleCharacters.shortLabel","Disable Invisible Highlight")}run(e,t,i){return re(this,void 0,void 0,(function*(){let t=null==e?void 0:e.get(ee.Ui);t&&this.runAction(t)}))}runAction(e){return re(this,void 0,void 0,(function*(){yield e.updateValue(S.qt.invisibleCharacters,!1,1)}))}}be.ID="editor.action.unicodeHighlight.disableHighlightingOfInvisibleCharacters";class ve extends y.R6{constructor(){super({id:ve.ID,label:J.NC("vs/editor/contrib/unicodeHighlighter/browser/unicodeHighlighter","action.unicodeHighlight.disableHighlightingOfNonBasicAsciiCharacters","Disable highlighting of non basic ASCII characters"),alias:"Disable highlighting of non basic ASCII characters",precondition:void 0}),this.shortLabel=J.NC("vs/editor/contrib/unicodeHighlighter/browser/unicodeHighlighter","unicodeHighlight.disableHighlightingOfNonBasicAsciiCharacters.shortLabel","Disable Non ASCII Highlight")}run(e,t,i){return re(this,void 0,void 0,(function*(){let t=null==e?void 0:e.get(ee.Ui);t&&this.runAction(t)}))}runAction(e){return re(this,void 0,void 0,(function*(){yield e.updateValue(S.qt.nonBasicASCII,!1,1)}))}}ve.ID="editor.action.unicodeHighlight.disableHighlightingOfNonBasicAsciiCharacters";class Ce extends y.R6{constructor(){super({id:Ce.ID,label:J.NC("vs/editor/contrib/unicodeHighlighter/browser/unicodeHighlighter","action.unicodeHighlight.showExcludeOptions","Show Exclude Options"),alias:"Show Exclude Options",precondition:void 0})}run(e,t,i){return re(this,void 0,void 0,(function*(){const{codePoint:t,reason:n,inString:o,inComment:r}=i,s=String.fromCodePoint(t),l=e.get(te.eJ),c=e.get(ee.Ui),d=[];if(0===n.kind)for(const e of n.notAmbiguousInLocales)d.push({label:J.NC("vs/editor/contrib/unicodeHighlighter/browser/unicodeHighlighter","unicodeHighlight.allowCommonCharactersInLanguage",'Allow unicode characters that are more common in the language "{0}".',e),run:()=>re(this,void 0,void 0,(function*(){we(c,[e])}))});if(d.push({label:function(e){return a.vU.isInvisibleCharacter(e)?J.NC("vs/editor/contrib/unicodeHighlighter/browser/unicodeHighlighter","unicodeHighlight.excludeInvisibleCharFromBeingHighlighted","Exclude {0} (invisible character) from being highlighted",ue(e)):J.NC("vs/editor/contrib/unicodeHighlighter/browser/unicodeHighlighter","unicodeHighlight.excludeCharFromBeingHighlighted","Exclude {0} from being highlighted",`${ue(e)} "${s}"`)}(t),run:()=>function(e,t){return re(this,void 0,void 0,(function*(){const i=e.getValue(S.qt.allowedCharacters);let n;n="object"==typeof i&&i?i:{};for(const e of t)n[String.fromCodePoint(e)]=!0;yield e.updateValue(S.qt.allowedCharacters,n,1)}))}(c,[t])}),r){const e=new me;d.push({label:e.label,run:()=>re(this,void 0,void 0,(function*(){return e.runAction(c)}))})}else if(o){const e=new fe;d.push({label:e.label,run:()=>re(this,void 0,void 0,(function*(){return e.runAction(c)}))})}if(0===n.kind){const e=new _e;d.push({label:e.label,run:()=>re(this,void 0,void 0,(function*(){return e.runAction(c)}))})}else if(1===n.kind){const e=new be;d.push({label:e.label,run:()=>re(this,void 0,void 0,(function*(){return e.runAction(c)}))})}else if(2===n.kind){const e=new ve;d.push({label:e.label,run:()=>re(this,void 0,void 0,(function*(){return e.runAction(c)}))})}else!function(e){throw new Error(`Unexpected value: ${e}`)}(n);const u=yield l.pick(d,{title:J.NC("vs/editor/contrib/unicodeHighlighter/browser/unicodeHighlighter","unicodeHighlight.configureUnicodeHighlightOptions","Configure Unicode Highlight Options")});u&&(yield u.run())}))}}function we(e,t){var i;return re(this,void 0,void 0,(function*(){const n=null===(i=e.inspect(S.qt.allowedLocales).user)||void 0===i?void 0:i.value;let o;o="object"==typeof n&&n?Object.assign({},n):{};for(const e of t)o[e]=!0;yield e.updateValue(S.qt.allowedLocales,o,1)}))}Ce.ID="editor.action.unicodeHighlight.showExcludeOptions",(0,y.Qr)(_e),(0,y.Qr)(be),(0,y.Qr)(ve),(0,y.Qr)(Ce),(0,y._K)(ae.ID,ae),D.Ae.register(de)},60803:function(e,t,i){"use strict";i.r(t),i.d(t,{UnusualLineTerminatorsDetector:function(){return u}});var n=i(4004),o=i(10804),r=i(4189),s=i(3622),a=i(89982),l=i(34243),c=function(e,t){return function(i,n){t(i,n,e)}};const d="ignoreUnusualLineTerminators";let u=class extends n.JT{constructor(e,t,i){super(),this._editor=e,this._dialogService=t,this._codeEditorService=i,this._config=this._editor.getOption(114),this._register(this._editor.onDidChangeConfiguration((e=>{e.hasChanged(114)&&(this._config=this._editor.getOption(114),this._checkForUnusualLineTerminators())}))),this._register(this._editor.onDidChangeModel((()=>{this._checkForUnusualLineTerminators()}))),this._register(this._editor.onDidChangeModelContent((e=>{e.isUndoing||this._checkForUnusualLineTerminators()})))}_checkForUnusualLineTerminators(){return e=this,t=void 0,n=function*(){if("off"===this._config)return;if(!this._editor.hasModel())return;const e=this._editor.getModel();if(!e.mightContainUnusualLineTerminators())return;const t=function(e,t){return e.getModelProperty(t.uri,d)}(this._codeEditorService,e);!0!==t&&(this._editor.getOption(81)||("auto"!==this._config?(yield this._dialogService.confirm({title:a.NC("vs/editor/contrib/unusualLineTerminators/browser/unusualLineTerminators","unusualLineTerminators.title","Unusual Line Terminators"),message:a.NC("vs/editor/contrib/unusualLineTerminators/browser/unusualLineTerminators","unusualLineTerminators.message","Detected unusual line terminators"),detail:a.NC("vs/editor/contrib/unusualLineTerminators/browser/unusualLineTerminators","unusualLineTerminators.detail","The file '{0}' contains one or more unusual line terminator characters, like Line Separator (LS) or Paragraph Separator (PS).\n\nIt is recommended to remove them from the file. This can be configured via `editor.unusualLineTerminators`.",(0,o.EZ)(e.uri)),primaryButton:a.NC("vs/editor/contrib/unusualLineTerminators/browser/unusualLineTerminators","unusualLineTerminators.fix","Remove Unusual Line Terminators"),secondaryButton:a.NC("vs/editor/contrib/unusualLineTerminators/browser/unusualLineTerminators","unusualLineTerminators.ignore","Ignore")})).confirmed?e.removeUnusualLineTerminators(this._editor.getSelections()):function(e,t,i){e.setModelProperty(t.uri,d,!0)}(this._codeEditorService,e):e.removeUnusualLineTerminators(this._editor.getSelections())))},new((i=void 0)||(i=Promise))((function(o,r){function s(e){try{l(n.next(e))}catch(e){r(e)}}function a(e){try{l(n.throw(e))}catch(e){r(e)}}function l(e){var t;e.done?o(e.value):(t=e.value,t instanceof i?t:new i((function(e){e(t)}))).then(s,a)}l((n=n.apply(e,t||[])).next())}));var e,t,i,n}};u.ID="editor.contrib.unusualLineTerminatorsDetector",u=function(e,t,i,n){var o,r=arguments.length,s=r<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,i):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(e,t,i,n);else for(var a=e.length-1;a>=0;a--)(o=e[a])&&(s=(r<3?o(s):r>3?o(t,i,s):o(t,i))||s);return r>3&&s&&Object.defineProperty(t,i,s),s}([c(1,l.S),c(2,s.$)],u),(0,r._K)(u.ID,u)},32547:function(e,t,i){"use strict";i.r(t);var n=i(40027),o=i(4004),r=i(4189),s=i(33234),a=i(59083),l=i(14902),c=i(71873),d=i(40539),u=i(81585),h=i(30021),g=i(52150),p=i(66988),m=function(e,t){return function(i,n){t(i,n,e)}};let f=class extends o.JT{constructor(e,t,i,o,r,s){super(),this._modelService=t,this._themeService=i,this._configurationService=o,this._editor=e,this._provider=s.documentRangeSemanticTokensProvider,this._debounceInformation=r.for(this._provider,"DocumentRangeSemanticTokens",{min:100,max:500}),this._tokenizeViewport=this._register(new n.pY((()=>this._tokenizeViewportNow()),100)),this._outstandingRequests=[];const a=()=>{this._editor.hasModel()&&this._tokenizeViewport.schedule(this._debounceInformation.get(this._editor.getModel()))};this._register(this._editor.onDidScrollChange((()=>{a()}))),this._register(this._editor.onDidChangeModel((()=>{this._cancelAll(),a()}))),this._register(this._editor.onDidChangeModelContent((e=>{this._cancelAll(),a()}))),this._register(this._provider.onDidChange((()=>{this._cancelAll(),a()}))),this._register(this._configurationService.onDidChangeConfiguration((e=>{e.affectsConfiguration(l.e3)&&(this._cancelAll(),a())}))),this._register(this._themeService.onDidColorThemeChange((()=>{this._cancelAll(),a()})))}_cancelAll(){for(const e of this._outstandingRequests)e.cancel();this._outstandingRequests=[]}_removeOutstandingRequest(e){for(let t=0,i=this._outstandingRequests.length;tthis._requestRange(e,t))))}_requestRange(e,t){const i=e.getVersionId(),o=(0,n.PG)((i=>Promise.resolve((0,s.OG)(this._provider,e,t,i)))),r=new g.G(!1);return o.then((n=>{if(this._debounceInformation.update(e,r.elapsed()),!n||!n.tokens||e.isDisposed()||e.getVersionId()!==i)return;const{provider:o,tokens:s}=n,a=this._modelService.getSemanticTokensProviderStyling(o);e.setPartialSemanticTokens(t,(0,c.h)(s,a,e.getLanguageId()))})).then((()=>this._removeOutstandingRequest(o)),(()=>this._removeOutstandingRequest(o))),o}};f.ID="editor.contrib.viewportSemanticTokens",f=function(e,t,i,n){var o,r=arguments.length,s=r<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,i):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(e,t,i,n);else for(var a=e.length-1;a>=0;a--)(o=e[a])&&(s=(r<3?o(s):r>3?o(t,i,s):o(t,i))||s);return r>3&&s&&Object.defineProperty(t,i,s),s}([m(1,a.q),m(2,u.XE),m(3,d.Ui),m(4,h.A),m(5,p.p)],f),(0,r._K)(f.ID,f)},40216:function(e,t,i){"use strict";i.r(t),i.d(t,{getOccurrencesAtPosition:function(){return N}});var n=i(77339),o=i(57800),r=i(40027),s=i(60677),a=i(16182),l=i(4004),c=i(4189),d=i(11465),u=i(38673),h=i(77324),g=i(25732),p=i(74893),m=i(89982),f=i(60393),_=i(45164),b=i(81585),v=i(66988),C=function(e,t){return function(i,n){t(i,n,e)}};const w=(0,_.P6G)("editor.wordHighlightBackground",{dark:"#575757B8",light:"#57575740",hc:null},m.NC("vs/editor/contrib/wordHighlighter/browser/wordHighlighter","wordHighlight","Background color of a symbol during read-access, like reading a variable. The color must not be opaque so as not to hide underlying decorations."),!0),y=(0,_.P6G)("editor.wordHighlightStrongBackground",{dark:"#004972B8",light:"#0e639c40",hc:null},m.NC("vs/editor/contrib/wordHighlighter/browser/wordHighlighter","wordHighlightStrong","Background color of a symbol during write-access, like writing to a variable. The color must not be opaque so as not to hide underlying decorations."),!0),S=(0,_.P6G)("editor.wordHighlightBorder",{light:null,dark:null,hc:_.xL1},m.NC("vs/editor/contrib/wordHighlighter/browser/wordHighlighter","wordHighlightBorder","Border color of a symbol during read-access, like reading a variable.")),x=(0,_.P6G)("editor.wordHighlightStrongBorder",{light:null,dark:null,hc:_.xL1},m.NC("vs/editor/contrib/wordHighlighter/browser/wordHighlighter","wordHighlightStrongBorder","Border color of a symbol during write-access, like writing to a variable.")),k=(0,_.P6G)("editorOverviewRuler.wordHighlightForeground",{dark:"#A0A0A0CC",light:"#A0A0A0CC",hc:"#A0A0A0CC"},m.NC("vs/editor/contrib/wordHighlighter/browser/wordHighlighter","overviewRulerWordHighlightForeground","Overview ruler marker color for symbol highlights. The color must not be opaque so as not to hide underlying decorations."),!0),L=(0,_.P6G)("editorOverviewRuler.wordHighlightStrongForeground",{dark:"#C0A0C0CC",light:"#C0A0C0CC",hc:"#C0A0C0CC"},m.NC("vs/editor/contrib/wordHighlighter/browser/wordHighlighter","overviewRulerWordHighlightStrongForeground","Overview ruler marker color for write-access symbol highlights. The color must not be opaque so as not to hide underlying decorations."),!0),E=new f.uy("hasWordHighlights",!1);function N(e,t,i,n){const s=e.ordered(t);return(0,r.Ps)(s.map((e=>()=>Promise.resolve(e.provideDocumentHighlights(t,i,n)).then(void 0,a.Cp))),o.Of)}class D{constructor(e,t,i){this._model=e,this._selection=t,this._wordSeparators=i,this._wordRange=this._getCurrentWordRange(e,t),this._result=null}get result(){return this._result||(this._result=(0,r.PG)((e=>this._compute(this._model,this._selection,this._wordSeparators,e)))),this._result}_getCurrentWordRange(e,t){const i=e.getWordAtPosition(t.getPosition());return i?new d.e(t.startLineNumber,i.startColumn,t.startLineNumber,i.endColumn):null}isValid(e,t,i){const n=t.startLineNumber,o=t.startColumn,r=t.endColumn,s=this._getCurrentWordRange(e,t);let a=Boolean(this._wordRange&&this._wordRange.equalsRange(s));for(let t=0,s=i.length;!a&&t=r&&(a=!0)}return a}cancel(){this.result.cancel()}}class I extends D{constructor(e,t,i,n){super(e,t,i),this._providers=n}_compute(e,t,i,n){return N(this._providers,e,t.getPosition(),n).then((e=>e||[]))}}class T extends D{constructor(e,t,i){super(e,t,i),this._selectionIsEmpty=t.isEmpty()}_compute(e,t,i,n){return(0,r.Vs)(250,n).then((()=>{if(!t.isEmpty())return[];const n=e.getWordAtPosition(t.getPosition());return!n||n.word.length>1e3?[]:e.findMatches(n.word,!0,!1,!0,i,!1).map((e=>({range:e.range,kind:p.MY.Text})))}))}isValid(e,t,i){const n=t.isEmpty();return this._selectionIsEmpty===n&&super.isValid(e,t,i)}}(0,c.sb)("_executeDocumentHighlights",((e,t,i)=>N(e.get(v.p).documentHighlightProvider,t,i,s.T.None)));class A{constructor(e,t,i){this.toUnhook=new l.SL,this.workerRequestTokenId=0,this.workerRequestCompleted=!1,this.workerRequestValue=[],this.lastCursorPositionChangeTime=0,this.renderDecorationsTimer=-1,this.editor=e,this.providers=t,this._hasWordHighlights=E.bindTo(i),this._ignorePositionChangeEvent=!1,this.occurrencesHighlight=this.editor.getOption(72),this.model=this.editor.getModel(),this.toUnhook.add(e.onDidChangeCursorPosition((e=>{this._ignorePositionChangeEvent||this.occurrencesHighlight&&this._onPositionChanged(e)}))),this.toUnhook.add(e.onDidChangeModelContent((e=>{this._stopAll()}))),this.toUnhook.add(e.onDidChangeConfiguration((e=>{let t=this.editor.getOption(72);this.occurrencesHighlight!==t&&(this.occurrencesHighlight=t,this._stopAll())}))),this._decorationIds=[],this.workerRequestTokenId=0,this.workerRequest=null,this.workerRequestCompleted=!1,this.lastCursorPositionChangeTime=0,this.renderDecorationsTimer=-1}hasDecorations(){return this._decorationIds.length>0}restore(){this.occurrencesHighlight&&this._run()}_getSortedHighlights(){return o.kX(this._decorationIds.map((e=>this.model.getDecorationRange(e))).sort(d.e.compareRangesUsingStarts))}moveNext(){let e=this._getSortedHighlights(),t=(e.findIndex((e=>e.containsPosition(this.editor.getPosition())))+1)%e.length,i=e[t];try{this._ignorePositionChangeEvent=!0,this.editor.setPosition(i.getStartPosition()),this.editor.revealRangeInCenterIfOutsideViewport(i);const o=this._getWord();if(o){const r=this.editor.getModel().getLineContent(i.startLineNumber);(0,n.Z9)(`${r}, ${t+1} of ${e.length} for '${o.word}'`)}}finally{this._ignorePositionChangeEvent=!1}}moveBack(){let e=this._getSortedHighlights(),t=(e.findIndex((e=>e.containsPosition(this.editor.getPosition())))-1+e.length)%e.length,i=e[t];try{this._ignorePositionChangeEvent=!0,this.editor.setPosition(i.getStartPosition()),this.editor.revealRangeInCenterIfOutsideViewport(i);const o=this._getWord();if(o){const r=this.editor.getModel().getLineContent(i.startLineNumber);(0,n.Z9)(`${r}, ${t+1} of ${e.length} for '${o.word}'`)}}finally{this._ignorePositionChangeEvent=!1}}_removeDecorations(){this._decorationIds.length>0&&(this._decorationIds=this.editor.deltaDecorations(this._decorationIds,[]),this._hasWordHighlights.set(!1))}_stopAll(){this._removeDecorations(),-1!==this.renderDecorationsTimer&&(clearTimeout(this.renderDecorationsTimer),this.renderDecorationsTimer=-1),null!==this.workerRequest&&(this.workerRequest.cancel(),this.workerRequest=null),this.workerRequestCompleted||(this.workerRequestTokenId++,this.workerRequestCompleted=!0)}_onPositionChanged(e){this.occurrencesHighlight&&3===e.reason?this._run():this._stopAll()}_getWord(){let e=this.editor.getSelection(),t=e.startLineNumber,i=e.startColumn;return this.model.getWordAtPosition({lineNumber:t,column:i})}_run(){let e=this.editor.getSelection();if(e.startLineNumber!==e.endLineNumber)return void this._stopAll();let t=e.startColumn,i=e.endColumn;const n=this._getWord();if(!n||n.startColumn>t||n.endColumn{e===this.workerRequestTokenId&&(this.workerRequestCompleted=!0,this.workerRequestValue=t||[],this._beginRenderDecorations())}),a.dL)}var r,s,l,c}_beginRenderDecorations(){let e=(new Date).getTime(),t=this.lastCursorPositionChangeTime+250;e>=t?(this.renderDecorationsTimer=-1,this.renderDecorations()):this.renderDecorationsTimer=setTimeout((()=>{this.renderDecorations()}),t-e)}renderDecorations(){this.renderDecorationsTimer=-1;let e=[];for(const t of this.workerRequestValue)t.range&&e.push({range:t.range,options:A._getDecorationOptions(t.kind)});this._decorationIds=this.editor.deltaDecorations(this._decorationIds,e),this._hasWordHighlights.set(this.hasDecorations())}static _getDecorationOptions(e){return e===p.MY.Write?this._WRITE_OPTIONS:e===p.MY.Text?this._TEXT_OPTIONS:this._REGULAR_OPTIONS}dispose(){this._stopAll(),this.toUnhook.dispose()}}A._WRITE_OPTIONS=g.qx.register({description:"word-highlight-strong",stickiness:1,className:"wordHighlightStrong",overviewRuler:{color:(0,b.EN)(L),position:h.sh.Center},minimap:{color:(0,b.EN)(_.IYc),position:h.F5.Inline}}),A._TEXT_OPTIONS=g.qx.register({description:"selection-highlight",stickiness:1,className:"selectionHighlight",overviewRuler:{color:(0,b.EN)(_.SPM),position:h.sh.Center},minimap:{color:(0,b.EN)(_.IYc),position:h.F5.Inline}}),A._REGULAR_OPTIONS=g.qx.register({description:"word-highlight",stickiness:1,className:"wordHighlight",overviewRuler:{color:(0,b.EN)(k),position:h.sh.Center},minimap:{color:(0,b.EN)(_.IYc),position:h.F5.Inline}});let R=class e extends l.JT{constructor(e,t,i){super(),this.wordHighlighter=null;const n=()=>{e.hasModel()&&(this.wordHighlighter=new A(e,i.documentHighlightProvider,t))};this._register(e.onDidChangeModel((e=>{this.wordHighlighter&&(this.wordHighlighter.dispose(),this.wordHighlighter=null),n()}))),n()}static get(t){return t.getContribution(e.ID)}saveViewState(){return!(!this.wordHighlighter||!this.wordHighlighter.hasDecorations())}moveNext(){this.wordHighlighter&&this.wordHighlighter.moveNext()}moveBack(){this.wordHighlighter&&this.wordHighlighter.moveBack()}restoreViewState(e){this.wordHighlighter&&e&&this.wordHighlighter.restore()}dispose(){this.wordHighlighter&&(this.wordHighlighter.dispose(),this.wordHighlighter=null),super.dispose()}};R.ID="editor.contrib.wordHighlighter",R=function(e,t,i,n){var o,r=arguments.length,s=r<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,i):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(e,t,i,n);else for(var a=e.length-1;a>=0;a--)(o=e[a])&&(s=(r<3?o(s):r>3?o(t,i,s):o(t,i))||s);return r>3&&s&&Object.defineProperty(t,i,s),s}([C(1,f.i6),C(2,v.p)],R);class M extends c.R6{constructor(e,t){super(t),this._isNext=e}run(e,t){const i=R.get(t);i&&(this._isNext?i.moveNext():i.moveBack())}}class O extends c.R6{constructor(){super({id:"editor.action.wordHighlight.trigger",label:m.NC("vs/editor/contrib/wordHighlighter/browser/wordHighlighter","wordHighlight.trigger.label","Trigger Symbol Highlight"),alias:"Trigger Symbol Highlight",precondition:E.toNegated(),kbOpts:{kbExpr:u.u.editorTextFocus,primary:0,weight:100}})}run(e,t,i){const n=R.get(t);n&&n.restoreViewState(!0)}}(0,c._K)(R.ID,R),(0,c.Qr)(class extends M{constructor(){super(!0,{id:"editor.action.wordHighlight.next",label:m.NC("vs/editor/contrib/wordHighlighter/browser/wordHighlighter","wordHighlight.next.label","Go to Next Symbol Highlight"),alias:"Go to Next Symbol Highlight",precondition:E,kbOpts:{kbExpr:u.u.editorTextFocus,primary:65,weight:100}})}}),(0,c.Qr)(class extends M{constructor(){super(!1,{id:"editor.action.wordHighlight.prev",label:m.NC("vs/editor/contrib/wordHighlighter/browser/wordHighlighter","wordHighlight.previous.label","Go to Previous Symbol Highlight"),alias:"Go to Previous Symbol Highlight",precondition:E,kbOpts:{kbExpr:u.u.editorTextFocus,primary:1089,weight:100}})}}),(0,c.Qr)(O),(0,b.Ic)(((e,t)=>{const i=e.getColor(_.Rzx);i&&(t.addRule(`.monaco-editor .focused .selectionHighlight { background-color: ${i}; }`),t.addRule(`.monaco-editor .selectionHighlight { background-color: ${i.transparent(.5)}; }`));const n=e.getColor(w);n&&t.addRule(`.monaco-editor .wordHighlight { background-color: ${n}; }`);const o=e.getColor(y);o&&t.addRule(`.monaco-editor .wordHighlightStrong { background-color: ${o}; }`);const r=e.getColor(_.g_n);r&&t.addRule(`.monaco-editor .selectionHighlight { border: 1px ${"hc"===e.type?"dotted":"solid"} ${r}; box-sizing: border-box; }`);const s=e.getColor(S);s&&t.addRule(`.monaco-editor .wordHighlight { border: 1px ${"hc"===e.type?"dashed":"solid"} ${s}; box-sizing: border-box; }`);const a=e.getColor(x);a&&t.addRule(`.monaco-editor .wordHighlightStrong { border: 1px ${"hc"===e.type?"dashed":"solid"} ${a}; box-sizing: border-box; }`)}))},37184:function(e,t,i){"use strict";i.r(t),i.d(t,{CursorWordAccessibilityLeft:function(){return E},CursorWordAccessibilityLeftSelect:function(){return N},CursorWordAccessibilityRight:function(){return O},CursorWordAccessibilityRightSelect:function(){return P},CursorWordEndLeft:function(){return y},CursorWordEndLeftSelect:function(){return k},CursorWordEndRight:function(){return I},CursorWordEndRightSelect:function(){return R},CursorWordLeft:function(){return S},CursorWordLeftSelect:function(){return L},CursorWordRight:function(){return T},CursorWordRightSelect:function(){return M},CursorWordStartLeft:function(){return w},CursorWordStartLeftSelect:function(){return x},CursorWordStartRight:function(){return D},CursorWordStartRightSelect:function(){return A},DeleteInsideWord:function(){return K},DeleteWordCommand:function(){return F},DeleteWordEndLeft:function(){return H},DeleteWordEndRight:function(){return U},DeleteWordLeft:function(){return z},DeleteWordLeftCommand:function(){return B},DeleteWordRight:function(){return j},DeleteWordRightCommand:function(){return W},DeleteWordStartLeft:function(){return V},DeleteWordStartRight:function(){return $},MoveWordCommand:function(){return b},WordLeftCommand:function(){return v},WordRightCommand:function(){return C}});var n=i(4189),o=i(22804),r=i(18966),s=i(92472),a=i(65292),l=i(67071),c=i(72248),d=i(11465),u=i(59744),h=i(38673),g=i(98340),p=i(89982),m=i(33060),f=i(60393),_=i(61263);class b extends n._l{constructor(e){super(e),this._inSelectionMode=e.inSelectionMode,this._wordNavigationType=e.wordNavigationType}runEditorCommand(e,t,i){if(!t.hasModel())return;const n=(0,l.u)(t.getOption(117)),o=t.getModel(),r=t.getSelections().map((e=>{const t=new c.L(e.positionLineNumber,e.positionColumn),i=this._move(n,o,t,this._wordNavigationType);return this._moveTo(e,i,this._inSelectionMode)}));if(o.pushStackElement(),t._getViewModel().setCursorStates("moveWordCommand",3,r.map((e=>s.Vi.fromModelSelection(e)))),1===r.length){const e=new c.L(r[0].positionLineNumber,r[0].positionColumn);t.revealPosition(e,0)}}_moveTo(e,t,i){return i?new u.Y(e.selectionStartLineNumber,e.selectionStartColumn,t.lineNumber,t.column):new u.Y(t.lineNumber,t.column,t.lineNumber,t.column)}}class v extends b{_move(e,t,i,n){return a.w.moveWordLeft(e,t,i,n)}}class C extends b{_move(e,t,i,n){return a.w.moveWordRight(e,t,i,n)}}class w extends v{constructor(){super({inSelectionMode:!1,wordNavigationType:0,id:"cursorWordStartLeft",precondition:void 0})}}class y extends v{constructor(){super({inSelectionMode:!1,wordNavigationType:2,id:"cursorWordEndLeft",precondition:void 0})}}class S extends v{constructor(){var e;super({inSelectionMode:!1,wordNavigationType:1,id:"cursorWordLeft",precondition:void 0,kbOpts:{kbExpr:f.Ao.and(h.u.textInputFocus,null===(e=f.Ao.and(m.U,_.cv))||void 0===e?void 0:e.negate()),primary:2063,mac:{primary:527},weight:100}})}}class x extends v{constructor(){super({inSelectionMode:!0,wordNavigationType:0,id:"cursorWordStartLeftSelect",precondition:void 0})}}class k extends v{constructor(){super({inSelectionMode:!0,wordNavigationType:2,id:"cursorWordEndLeftSelect",precondition:void 0})}}class L extends v{constructor(){var e;super({inSelectionMode:!0,wordNavigationType:1,id:"cursorWordLeftSelect",precondition:void 0,kbOpts:{kbExpr:f.Ao.and(h.u.textInputFocus,null===(e=f.Ao.and(m.U,_.cv))||void 0===e?void 0:e.negate()),primary:3087,mac:{primary:1551},weight:100}})}}class E extends v{constructor(){super({inSelectionMode:!1,wordNavigationType:3,id:"cursorWordAccessibilityLeft",precondition:void 0})}_move(e,t,i,n){return super._move((0,l.u)(r.BH.wordSeparators.defaultValue),t,i,n)}}class N extends v{constructor(){super({inSelectionMode:!0,wordNavigationType:3,id:"cursorWordAccessibilityLeftSelect",precondition:void 0})}_move(e,t,i,n){return super._move((0,l.u)(r.BH.wordSeparators.defaultValue),t,i,n)}}class D extends C{constructor(){super({inSelectionMode:!1,wordNavigationType:0,id:"cursorWordStartRight",precondition:void 0})}}class I extends C{constructor(){var e;super({inSelectionMode:!1,wordNavigationType:2,id:"cursorWordEndRight",precondition:void 0,kbOpts:{kbExpr:f.Ao.and(h.u.textInputFocus,null===(e=f.Ao.and(m.U,_.cv))||void 0===e?void 0:e.negate()),primary:2065,mac:{primary:529},weight:100}})}}class T extends C{constructor(){super({inSelectionMode:!1,wordNavigationType:2,id:"cursorWordRight",precondition:void 0})}}class A extends C{constructor(){super({inSelectionMode:!0,wordNavigationType:0,id:"cursorWordStartRightSelect",precondition:void 0})}}class R extends C{constructor(){var e;super({inSelectionMode:!0,wordNavigationType:2,id:"cursorWordEndRightSelect",precondition:void 0,kbOpts:{kbExpr:f.Ao.and(h.u.textInputFocus,null===(e=f.Ao.and(m.U,_.cv))||void 0===e?void 0:e.negate()),primary:3089,mac:{primary:1553},weight:100}})}}class M extends C{constructor(){super({inSelectionMode:!0,wordNavigationType:2,id:"cursorWordRightSelect",precondition:void 0})}}class O extends C{constructor(){super({inSelectionMode:!1,wordNavigationType:3,id:"cursorWordAccessibilityRight",precondition:void 0})}_move(e,t,i,n){return super._move((0,l.u)(r.BH.wordSeparators.defaultValue),t,i,n)}}class P extends C{constructor(){super({inSelectionMode:!0,wordNavigationType:3,id:"cursorWordAccessibilityRightSelect",precondition:void 0})}_move(e,t,i,n){return super._move((0,l.u)(r.BH.wordSeparators.defaultValue),t,i,n)}}class F extends n._l{constructor(e){super(e),this._whitespaceHeuristics=e.whitespaceHeuristics,this._wordNavigationType=e.wordNavigationType}runEditorCommand(e,t,i){const n=e.get(g.c_);if(!t.hasModel())return;const r=(0,l.u)(t.getOption(117)),s=t.getModel(),a=t.getSelections(),c=t.getOption(5),d=t.getOption(8),u=n.getLanguageConfiguration(s.getLanguageId()).getAutoClosingPairs(),h=t._getViewModel(),p=a.map((e=>{const i=this._delete({wordSeparators:r,model:s,selection:e,whitespaceHeuristics:this._whitespaceHeuristics,autoClosingDelete:t.getOption(6),autoClosingBrackets:c,autoClosingQuotes:d,autoClosingPairs:u,autoClosedCharacters:h.getCursorAutoClosedCharacters()},this._wordNavigationType);return new o.T4(i,"")}));t.pushUndoStop(),t.executeCommands(this.id,p),t.pushUndoStop()}}class B extends F{_delete(e,t){return a.w.deleteWordLeft(e,t)||new d.e(1,1,1,1)}}class W extends F{_delete(e,t){let i=a.w.deleteWordRight(e,t);if(i)return i;const n=e.model.getLineCount(),o=e.model.getLineMaxColumn(n);return new d.e(n,o,n,o)}}class V extends B{constructor(){super({whitespaceHeuristics:!1,wordNavigationType:0,id:"deleteWordStartLeft",precondition:h.u.writable})}}class H extends B{constructor(){super({whitespaceHeuristics:!1,wordNavigationType:2,id:"deleteWordEndLeft",precondition:h.u.writable})}}class z extends B{constructor(){super({whitespaceHeuristics:!0,wordNavigationType:0,id:"deleteWordLeft",precondition:h.u.writable,kbOpts:{kbExpr:h.u.textInputFocus,primary:2049,mac:{primary:513},weight:100}})}}class $ extends W{constructor(){super({whitespaceHeuristics:!1,wordNavigationType:0,id:"deleteWordStartRight",precondition:h.u.writable})}}class U extends W{constructor(){super({whitespaceHeuristics:!1,wordNavigationType:2,id:"deleteWordEndRight",precondition:h.u.writable})}}class j extends W{constructor(){super({whitespaceHeuristics:!0,wordNavigationType:2,id:"deleteWordRight",precondition:h.u.writable,kbOpts:{kbExpr:h.u.textInputFocus,primary:2068,mac:{primary:532},weight:100}})}}class K extends n.R6{constructor(){super({id:"deleteInsideWord",precondition:h.u.writable,label:p.NC("vs/editor/contrib/wordOperations/browser/wordOperations","deleteInsideWord","Delete Word"),alias:"Delete Word"})}run(e,t,i){if(!t.hasModel())return;const n=(0,l.u)(t.getOption(117)),r=t.getModel(),s=t.getSelections().map((e=>{const t=a.w.deleteInsideWord(n,r,e);return new o.T4(t,"")}));t.pushUndoStop(),t.executeCommands(this.id,s),t.pushUndoStop()}}(0,n.fK)(new w),(0,n.fK)(new y),(0,n.fK)(new S),(0,n.fK)(new x),(0,n.fK)(new k),(0,n.fK)(new L),(0,n.fK)(new D),(0,n.fK)(new I),(0,n.fK)(new T),(0,n.fK)(new A),(0,n.fK)(new R),(0,n.fK)(new M),(0,n.fK)(new E),(0,n.fK)(new N),(0,n.fK)(new O),(0,n.fK)(new P),(0,n.fK)(new V),(0,n.fK)(new H),(0,n.fK)(new z),(0,n.fK)(new $),(0,n.fK)(new U),(0,n.fK)(new j),(0,n.Qr)(K)},65042:function(e,t,i){"use strict";i.r(t),i.d(t,{CursorWordPartLeft:function(){return h},CursorWordPartLeftSelect:function(){return g},CursorWordPartRight:function(){return m},CursorWordPartRightSelect:function(){return f},DeleteWordPartLeft:function(){return c},DeleteWordPartRight:function(){return d},WordPartLeftCommand:function(){return u},WordPartRightCommand:function(){return p}});var n=i(4189),o=i(65292),r=i(11465),s=i(38673),a=i(37184),l=i(14756);class c extends a.DeleteWordCommand{constructor(){super({whitespaceHeuristics:!0,wordNavigationType:0,id:"deleteWordPartLeft",precondition:s.u.writable,kbOpts:{kbExpr:s.u.textInputFocus,primary:0,mac:{primary:769},weight:100}})}_delete(e,t){return o.L.deleteWordPartLeft(e)||new r.e(1,1,1,1)}}class d extends a.DeleteWordCommand{constructor(){super({whitespaceHeuristics:!0,wordNavigationType:2,id:"deleteWordPartRight",precondition:s.u.writable,kbOpts:{kbExpr:s.u.textInputFocus,primary:0,mac:{primary:788},weight:100}})}_delete(e,t){let i=o.L.deleteWordPartRight(e);if(i)return i;const n=e.model.getLineCount(),s=e.model.getLineMaxColumn(n);return new r.e(n,s,n,s)}}class u extends a.MoveWordCommand{_move(e,t,i,n){return o.L.moveWordPartLeft(e,t,i)}}class h extends u{constructor(){super({inSelectionMode:!1,wordNavigationType:0,id:"cursorWordPartLeft",precondition:void 0,kbOpts:{kbExpr:s.u.textInputFocus,primary:0,mac:{primary:783},weight:100}})}}l.P0.registerCommandAlias("cursorWordPartStartLeft","cursorWordPartLeft");class g extends u{constructor(){super({inSelectionMode:!0,wordNavigationType:0,id:"cursorWordPartLeftSelect",precondition:void 0,kbOpts:{kbExpr:s.u.textInputFocus,primary:0,mac:{primary:1807},weight:100}})}}l.P0.registerCommandAlias("cursorWordPartStartLeftSelect","cursorWordPartLeftSelect");class p extends a.MoveWordCommand{_move(e,t,i,n){return o.L.moveWordPartRight(e,t,i)}}class m extends p{constructor(){super({inSelectionMode:!1,wordNavigationType:2,id:"cursorWordPartRight",precondition:void 0,kbOpts:{kbExpr:s.u.textInputFocus,primary:0,mac:{primary:785},weight:100}})}}class f extends p{constructor(){super({inSelectionMode:!0,wordNavigationType:2,id:"cursorWordPartRightSelect",precondition:void 0,kbOpts:{kbExpr:s.u.textInputFocus,primary:0,mac:{primary:1809},weight:100}})}}(0,n.fK)(new c),(0,n.fK)(new d),(0,n.fK)(new h),(0,n.fK)(new g),(0,n.fK)(new m),(0,n.fK)(new f)},38203:function(e,t,i){"use strict";i.r(t),i.d(t,{CancellationTokenSource:function(){return pl},Emitter:function(){return ml},KeyCode:function(){return fl},KeyMod:function(){return _l},MarkerSeverity:function(){return yl},MarkerTag:function(){return Sl},Position:function(){return bl},Range:function(){return vl},Selection:function(){return Cl},SelectionDirection:function(){return wl},Token:function(){return kl},Uri:function(){return xl},editor:function(){return Ll},languages:function(){return El},version:function(){return gl}});var n,o,r,s,a,l,c,d,u,h,g,p,m,f,_,b,v,C,w,y,S,x,k,L,E,N,D,I,T,A,R,M,O,P,F,B,W,V=i(18966),H=i(60677),z=i(46718),$=i(37808),U=i(39675),j=i(72248),K=i(11465),q=i(59744),G=i(74893);!function(e){e[e.Unknown=0]="Unknown",e[e.Disabled=1]="Disabled",e[e.Enabled=2]="Enabled"}(n||(n={})),function(e){e[e.KeepWhitespace=1]="KeepWhitespace",e[e.InsertAsSnippet=4]="InsertAsSnippet"}(o||(o={})),function(e){e[e.Method=0]="Method",e[e.Function=1]="Function",e[e.Constructor=2]="Constructor",e[e.Field=3]="Field",e[e.Variable=4]="Variable",e[e.Class=5]="Class",e[e.Struct=6]="Struct",e[e.Interface=7]="Interface",e[e.Module=8]="Module",e[e.Property=9]="Property",e[e.Event=10]="Event",e[e.Operator=11]="Operator",e[e.Unit=12]="Unit",e[e.Value=13]="Value",e[e.Constant=14]="Constant",e[e.Enum=15]="Enum",e[e.EnumMember=16]="EnumMember",e[e.Keyword=17]="Keyword",e[e.Text=18]="Text",e[e.Color=19]="Color",e[e.File=20]="File",e[e.Reference=21]="Reference",e[e.Customcolor=22]="Customcolor",e[e.Folder=23]="Folder",e[e.TypeParameter=24]="TypeParameter",e[e.User=25]="User",e[e.Issue=26]="Issue",e[e.Snippet=27]="Snippet"}(r||(r={})),function(e){e[e.Deprecated=1]="Deprecated"}(s||(s={})),function(e){e[e.Invoke=0]="Invoke",e[e.TriggerCharacter=1]="TriggerCharacter",e[e.TriggerForIncompleteCompletions=2]="TriggerForIncompleteCompletions"}(a||(a={})),function(e){e[e.EXACT=0]="EXACT",e[e.ABOVE=1]="ABOVE",e[e.BELOW=2]="BELOW"}(l||(l={})),function(e){e[e.NotSet=0]="NotSet",e[e.ContentFlush=1]="ContentFlush",e[e.RecoverFromMarkers=2]="RecoverFromMarkers",e[e.Explicit=3]="Explicit",e[e.Paste=4]="Paste",e[e.Undo=5]="Undo",e[e.Redo=6]="Redo"}(c||(c={})),function(e){e[e.LF=1]="LF",e[e.CRLF=2]="CRLF"}(d||(d={})),function(e){e[e.Text=0]="Text",e[e.Read=1]="Read",e[e.Write=2]="Write"}(u||(u={})),function(e){e[e.None=0]="None",e[e.Keep=1]="Keep",e[e.Brackets=2]="Brackets",e[e.Advanced=3]="Advanced",e[e.Full=4]="Full"}(h||(h={})),function(e){e[e.acceptSuggestionOnCommitCharacter=0]="acceptSuggestionOnCommitCharacter",e[e.acceptSuggestionOnEnter=1]="acceptSuggestionOnEnter",e[e.accessibilitySupport=2]="accessibilitySupport",e[e.accessibilityPageSize=3]="accessibilityPageSize",e[e.ariaLabel=4]="ariaLabel",e[e.autoClosingBrackets=5]="autoClosingBrackets",e[e.autoClosingDelete=6]="autoClosingDelete",e[e.autoClosingOvertype=7]="autoClosingOvertype",e[e.autoClosingQuotes=8]="autoClosingQuotes",e[e.autoIndent=9]="autoIndent",e[e.automaticLayout=10]="automaticLayout",e[e.autoSurround=11]="autoSurround",e[e.bracketPairColorization=12]="bracketPairColorization",e[e.guides=13]="guides",e[e.codeLens=14]="codeLens",e[e.codeLensFontFamily=15]="codeLensFontFamily",e[e.codeLensFontSize=16]="codeLensFontSize",e[e.colorDecorators=17]="colorDecorators",e[e.columnSelection=18]="columnSelection",e[e.comments=19]="comments",e[e.contextmenu=20]="contextmenu",e[e.copyWithSyntaxHighlighting=21]="copyWithSyntaxHighlighting",e[e.cursorBlinking=22]="cursorBlinking",e[e.cursorSmoothCaretAnimation=23]="cursorSmoothCaretAnimation",e[e.cursorStyle=24]="cursorStyle",e[e.cursorSurroundingLines=25]="cursorSurroundingLines",e[e.cursorSurroundingLinesStyle=26]="cursorSurroundingLinesStyle",e[e.cursorWidth=27]="cursorWidth",e[e.disableLayerHinting=28]="disableLayerHinting",e[e.disableMonospaceOptimizations=29]="disableMonospaceOptimizations",e[e.domReadOnly=30]="domReadOnly",e[e.dragAndDrop=31]="dragAndDrop",e[e.emptySelectionClipboard=32]="emptySelectionClipboard",e[e.extraEditorClassName=33]="extraEditorClassName",e[e.fastScrollSensitivity=34]="fastScrollSensitivity",e[e.find=35]="find",e[e.fixedOverflowWidgets=36]="fixedOverflowWidgets",e[e.folding=37]="folding",e[e.foldingStrategy=38]="foldingStrategy",e[e.foldingHighlight=39]="foldingHighlight",e[e.foldingImportsByDefault=40]="foldingImportsByDefault",e[e.foldingMaximumRegions=41]="foldingMaximumRegions",e[e.unfoldOnClickAfterEndOfLine=42]="unfoldOnClickAfterEndOfLine",e[e.fontFamily=43]="fontFamily",e[e.fontInfo=44]="fontInfo",e[e.fontLigatures=45]="fontLigatures",e[e.fontSize=46]="fontSize",e[e.fontWeight=47]="fontWeight",e[e.formatOnPaste=48]="formatOnPaste",e[e.formatOnType=49]="formatOnType",e[e.glyphMargin=50]="glyphMargin",e[e.gotoLocation=51]="gotoLocation",e[e.hideCursorInOverviewRuler=52]="hideCursorInOverviewRuler",e[e.hover=53]="hover",e[e.inDiffEditor=54]="inDiffEditor",e[e.inlineSuggest=55]="inlineSuggest",e[e.letterSpacing=56]="letterSpacing",e[e.lightbulb=57]="lightbulb",e[e.lineDecorationsWidth=58]="lineDecorationsWidth",e[e.lineHeight=59]="lineHeight",e[e.lineNumbers=60]="lineNumbers",e[e.lineNumbersMinChars=61]="lineNumbersMinChars",e[e.linkedEditing=62]="linkedEditing",e[e.links=63]="links",e[e.matchBrackets=64]="matchBrackets",e[e.minimap=65]="minimap",e[e.mouseStyle=66]="mouseStyle",e[e.mouseWheelScrollSensitivity=67]="mouseWheelScrollSensitivity",e[e.mouseWheelZoom=68]="mouseWheelZoom",e[e.multiCursorMergeOverlapping=69]="multiCursorMergeOverlapping",e[e.multiCursorModifier=70]="multiCursorModifier",e[e.multiCursorPaste=71]="multiCursorPaste",e[e.occurrencesHighlight=72]="occurrencesHighlight",e[e.overviewRulerBorder=73]="overviewRulerBorder",e[e.overviewRulerLanes=74]="overviewRulerLanes",e[e.padding=75]="padding",e[e.parameterHints=76]="parameterHints",e[e.peekWidgetDefaultFocus=77]="peekWidgetDefaultFocus",e[e.definitionLinkOpensInPeek=78]="definitionLinkOpensInPeek",e[e.quickSuggestions=79]="quickSuggestions",e[e.quickSuggestionsDelay=80]="quickSuggestionsDelay",e[e.readOnly=81]="readOnly",e[e.renameOnType=82]="renameOnType",e[e.renderControlCharacters=83]="renderControlCharacters",e[e.renderFinalNewline=84]="renderFinalNewline",e[e.renderLineHighlight=85]="renderLineHighlight",e[e.renderLineHighlightOnlyWhenFocus=86]="renderLineHighlightOnlyWhenFocus",e[e.renderValidationDecorations=87]="renderValidationDecorations",e[e.renderWhitespace=88]="renderWhitespace",e[e.revealHorizontalRightPadding=89]="revealHorizontalRightPadding",e[e.roundedSelection=90]="roundedSelection",e[e.rulers=91]="rulers",e[e.scrollbar=92]="scrollbar",e[e.scrollBeyondLastColumn=93]="scrollBeyondLastColumn",e[e.scrollBeyondLastLine=94]="scrollBeyondLastLine",e[e.scrollPredominantAxis=95]="scrollPredominantAxis",e[e.selectionClipboard=96]="selectionClipboard",e[e.selectionHighlight=97]="selectionHighlight",e[e.selectOnLineNumbers=98]="selectOnLineNumbers",e[e.showFoldingControls=99]="showFoldingControls",e[e.showUnused=100]="showUnused",e[e.snippetSuggestions=101]="snippetSuggestions",e[e.smartSelect=102]="smartSelect",e[e.smoothScrolling=103]="smoothScrolling",e[e.stickyTabStops=104]="stickyTabStops",e[e.stopRenderingLineAfter=105]="stopRenderingLineAfter",e[e.suggest=106]="suggest",e[e.suggestFontSize=107]="suggestFontSize",e[e.suggestLineHeight=108]="suggestLineHeight",e[e.suggestOnTriggerCharacters=109]="suggestOnTriggerCharacters",e[e.suggestSelection=110]="suggestSelection",e[e.tabCompletion=111]="tabCompletion",e[e.tabIndex=112]="tabIndex",e[e.unicodeHighlighting=113]="unicodeHighlighting",e[e.unusualLineTerminators=114]="unusualLineTerminators",e[e.useShadowDOM=115]="useShadowDOM",e[e.useTabStops=116]="useTabStops",e[e.wordSeparators=117]="wordSeparators",e[e.wordWrap=118]="wordWrap",e[e.wordWrapBreakAfterCharacters=119]="wordWrapBreakAfterCharacters",e[e.wordWrapBreakBeforeCharacters=120]="wordWrapBreakBeforeCharacters",e[e.wordWrapColumn=121]="wordWrapColumn",e[e.wordWrapOverride1=122]="wordWrapOverride1",e[e.wordWrapOverride2=123]="wordWrapOverride2",e[e.wrappingIndent=124]="wrappingIndent",e[e.wrappingStrategy=125]="wrappingStrategy",e[e.showDeprecated=126]="showDeprecated",e[e.inlayHints=127]="inlayHints",e[e.editorClassName=128]="editorClassName",e[e.pixelRatio=129]="pixelRatio",e[e.tabFocusMode=130]="tabFocusMode",e[e.layoutInfo=131]="layoutInfo",e[e.wrappingInfo=132]="wrappingInfo"}(g||(g={})),function(e){e[e.TextDefined=0]="TextDefined",e[e.LF=1]="LF",e[e.CRLF=2]="CRLF"}(p||(p={})),function(e){e[e.LF=0]="LF",e[e.CRLF=1]="CRLF"}(m||(m={})),function(e){e[e.None=0]="None",e[e.Indent=1]="Indent",e[e.IndentOutdent=2]="IndentOutdent",e[e.Outdent=3]="Outdent"}(f||(f={})),function(e){e[e.Both=0]="Both",e[e.Right=1]="Right",e[e.Left=2]="Left",e[e.None=3]="None"}(_||(_={})),function(e){e[e.Type=1]="Type",e[e.Parameter=2]="Parameter"}(b||(b={})),function(e){e[e.Automatic=0]="Automatic",e[e.Explicit=1]="Explicit"}(v||(v={})),function(e){e[e.DependsOnKbLayout=-1]="DependsOnKbLayout",e[e.Unknown=0]="Unknown",e[e.Backspace=1]="Backspace",e[e.Tab=2]="Tab",e[e.Enter=3]="Enter",e[e.Shift=4]="Shift",e[e.Ctrl=5]="Ctrl",e[e.Alt=6]="Alt",e[e.PauseBreak=7]="PauseBreak",e[e.CapsLock=8]="CapsLock",e[e.Escape=9]="Escape",e[e.Space=10]="Space",e[e.PageUp=11]="PageUp",e[e.PageDown=12]="PageDown",e[e.End=13]="End",e[e.Home=14]="Home",e[e.LeftArrow=15]="LeftArrow",e[e.UpArrow=16]="UpArrow",e[e.RightArrow=17]="RightArrow",e[e.DownArrow=18]="DownArrow",e[e.Insert=19]="Insert",e[e.Delete=20]="Delete",e[e.Digit0=21]="Digit0",e[e.Digit1=22]="Digit1",e[e.Digit2=23]="Digit2",e[e.Digit3=24]="Digit3",e[e.Digit4=25]="Digit4",e[e.Digit5=26]="Digit5",e[e.Digit6=27]="Digit6",e[e.Digit7=28]="Digit7",e[e.Digit8=29]="Digit8",e[e.Digit9=30]="Digit9",e[e.KeyA=31]="KeyA",e[e.KeyB=32]="KeyB",e[e.KeyC=33]="KeyC",e[e.KeyD=34]="KeyD",e[e.KeyE=35]="KeyE",e[e.KeyF=36]="KeyF",e[e.KeyG=37]="KeyG",e[e.KeyH=38]="KeyH",e[e.KeyI=39]="KeyI",e[e.KeyJ=40]="KeyJ",e[e.KeyK=41]="KeyK",e[e.KeyL=42]="KeyL",e[e.KeyM=43]="KeyM",e[e.KeyN=44]="KeyN",e[e.KeyO=45]="KeyO",e[e.KeyP=46]="KeyP",e[e.KeyQ=47]="KeyQ",e[e.KeyR=48]="KeyR",e[e.KeyS=49]="KeyS",e[e.KeyT=50]="KeyT",e[e.KeyU=51]="KeyU",e[e.KeyV=52]="KeyV",e[e.KeyW=53]="KeyW",e[e.KeyX=54]="KeyX",e[e.KeyY=55]="KeyY",e[e.KeyZ=56]="KeyZ",e[e.Meta=57]="Meta",e[e.ContextMenu=58]="ContextMenu",e[e.F1=59]="F1",e[e.F2=60]="F2",e[e.F3=61]="F3",e[e.F4=62]="F4",e[e.F5=63]="F5",e[e.F6=64]="F6",e[e.F7=65]="F7",e[e.F8=66]="F8",e[e.F9=67]="F9",e[e.F10=68]="F10",e[e.F11=69]="F11",e[e.F12=70]="F12",e[e.F13=71]="F13",e[e.F14=72]="F14",e[e.F15=73]="F15",e[e.F16=74]="F16",e[e.F17=75]="F17",e[e.F18=76]="F18",e[e.F19=77]="F19",e[e.NumLock=78]="NumLock",e[e.ScrollLock=79]="ScrollLock",e[e.Semicolon=80]="Semicolon",e[e.Equal=81]="Equal",e[e.Comma=82]="Comma",e[e.Minus=83]="Minus",e[e.Period=84]="Period",e[e.Slash=85]="Slash",e[e.Backquote=86]="Backquote",e[e.BracketLeft=87]="BracketLeft",e[e.Backslash=88]="Backslash",e[e.BracketRight=89]="BracketRight",e[e.Quote=90]="Quote",e[e.OEM_8=91]="OEM_8",e[e.IntlBackslash=92]="IntlBackslash",e[e.Numpad0=93]="Numpad0",e[e.Numpad1=94]="Numpad1",e[e.Numpad2=95]="Numpad2",e[e.Numpad3=96]="Numpad3",e[e.Numpad4=97]="Numpad4",e[e.Numpad5=98]="Numpad5",e[e.Numpad6=99]="Numpad6",e[e.Numpad7=100]="Numpad7",e[e.Numpad8=101]="Numpad8",e[e.Numpad9=102]="Numpad9",e[e.NumpadMultiply=103]="NumpadMultiply",e[e.NumpadAdd=104]="NumpadAdd",e[e.NUMPAD_SEPARATOR=105]="NUMPAD_SEPARATOR",e[e.NumpadSubtract=106]="NumpadSubtract",e[e.NumpadDecimal=107]="NumpadDecimal",e[e.NumpadDivide=108]="NumpadDivide",e[e.KEY_IN_COMPOSITION=109]="KEY_IN_COMPOSITION",e[e.ABNT_C1=110]="ABNT_C1",e[e.ABNT_C2=111]="ABNT_C2",e[e.AudioVolumeMute=112]="AudioVolumeMute",e[e.AudioVolumeUp=113]="AudioVolumeUp",e[e.AudioVolumeDown=114]="AudioVolumeDown",e[e.BrowserSearch=115]="BrowserSearch",e[e.BrowserHome=116]="BrowserHome",e[e.BrowserBack=117]="BrowserBack",e[e.BrowserForward=118]="BrowserForward",e[e.MediaTrackNext=119]="MediaTrackNext",e[e.MediaTrackPrevious=120]="MediaTrackPrevious",e[e.MediaStop=121]="MediaStop",e[e.MediaPlayPause=122]="MediaPlayPause",e[e.LaunchMediaPlayer=123]="LaunchMediaPlayer",e[e.LaunchMail=124]="LaunchMail",e[e.LaunchApp2=125]="LaunchApp2",e[e.Clear=126]="Clear",e[e.MAX_VALUE=127]="MAX_VALUE"}(C||(C={})),function(e){e[e.Hint=1]="Hint",e[e.Info=2]="Info",e[e.Warning=4]="Warning",e[e.Error=8]="Error"}(w||(w={})),function(e){e[e.Unnecessary=1]="Unnecessary",e[e.Deprecated=2]="Deprecated"}(y||(y={})),function(e){e[e.Inline=1]="Inline",e[e.Gutter=2]="Gutter"}(S||(S={})),function(e){e[e.UNKNOWN=0]="UNKNOWN",e[e.TEXTAREA=1]="TEXTAREA",e[e.GUTTER_GLYPH_MARGIN=2]="GUTTER_GLYPH_MARGIN",e[e.GUTTER_LINE_NUMBERS=3]="GUTTER_LINE_NUMBERS",e[e.GUTTER_LINE_DECORATIONS=4]="GUTTER_LINE_DECORATIONS",e[e.GUTTER_VIEW_ZONE=5]="GUTTER_VIEW_ZONE",e[e.CONTENT_TEXT=6]="CONTENT_TEXT",e[e.CONTENT_EMPTY=7]="CONTENT_EMPTY",e[e.CONTENT_VIEW_ZONE=8]="CONTENT_VIEW_ZONE",e[e.CONTENT_WIDGET=9]="CONTENT_WIDGET",e[e.OVERVIEW_RULER=10]="OVERVIEW_RULER",e[e.SCROLLBAR=11]="SCROLLBAR",e[e.OVERLAY_WIDGET=12]="OVERLAY_WIDGET",e[e.OUTSIDE_EDITOR=13]="OUTSIDE_EDITOR"}(x||(x={})),function(e){e[e.TOP_RIGHT_CORNER=0]="TOP_RIGHT_CORNER",e[e.BOTTOM_RIGHT_CORNER=1]="BOTTOM_RIGHT_CORNER",e[e.TOP_CENTER=2]="TOP_CENTER"}(k||(k={})),function(e){e[e.Left=1]="Left",e[e.Center=2]="Center",e[e.Right=4]="Right",e[e.Full=7]="Full"}(L||(L={})),function(e){e[e.Left=0]="Left",e[e.Right=1]="Right",e[e.None=2]="None"}(E||(E={})),function(e){e[e.Off=0]="Off",e[e.On=1]="On",e[e.Relative=2]="Relative",e[e.Interval=3]="Interval",e[e.Custom=4]="Custom"}(N||(N={})),function(e){e[e.None=0]="None",e[e.Text=1]="Text",e[e.Blocks=2]="Blocks"}(D||(D={})),function(e){e[e.Smooth=0]="Smooth",e[e.Immediate=1]="Immediate"}(I||(I={})),function(e){e[e.Auto=1]="Auto",e[e.Hidden=2]="Hidden",e[e.Visible=3]="Visible"}(T||(T={})),function(e){e[e.LTR=0]="LTR",e[e.RTL=1]="RTL"}(A||(A={})),function(e){e[e.Invoke=1]="Invoke",e[e.TriggerCharacter=2]="TriggerCharacter",e[e.ContentChange=3]="ContentChange"}(R||(R={})),function(e){e[e.File=0]="File",e[e.Module=1]="Module",e[e.Namespace=2]="Namespace",e[e.Package=3]="Package",e[e.Class=4]="Class",e[e.Method=5]="Method",e[e.Property=6]="Property",e[e.Field=7]="Field",e[e.Constructor=8]="Constructor",e[e.Enum=9]="Enum",e[e.Interface=10]="Interface",e[e.Function=11]="Function",e[e.Variable=12]="Variable",e[e.Constant=13]="Constant",e[e.String=14]="String",e[e.Number=15]="Number",e[e.Boolean=16]="Boolean",e[e.Array=17]="Array",e[e.Object=18]="Object",e[e.Key=19]="Key",e[e.Null=20]="Null",e[e.EnumMember=21]="EnumMember",e[e.Struct=22]="Struct",e[e.Event=23]="Event",e[e.Operator=24]="Operator",e[e.TypeParameter=25]="TypeParameter"}(M||(M={})),function(e){e[e.Deprecated=1]="Deprecated"}(O||(O={})),function(e){e[e.Hidden=0]="Hidden",e[e.Blink=1]="Blink",e[e.Smooth=2]="Smooth",e[e.Phase=3]="Phase",e[e.Expand=4]="Expand",e[e.Solid=5]="Solid"}(P||(P={})),function(e){e[e.Line=1]="Line",e[e.Block=2]="Block",e[e.Underline=3]="Underline",e[e.LineThin=4]="LineThin",e[e.BlockOutline=5]="BlockOutline",e[e.UnderlineThin=6]="UnderlineThin"}(F||(F={})),function(e){e[e.AlwaysGrowsWhenTypingAtEdges=0]="AlwaysGrowsWhenTypingAtEdges",e[e.NeverGrowsWhenTypingAtEdges=1]="NeverGrowsWhenTypingAtEdges",e[e.GrowsOnlyWhenTypingBefore=2]="GrowsOnlyWhenTypingBefore",e[e.GrowsOnlyWhenTypingAfter=3]="GrowsOnlyWhenTypingAfter"}(B||(B={})),function(e){e[e.None=0]="None",e[e.Same=1]="Same",e[e.Indent=2]="Indent",e[e.DeepIndent=3]="DeepIndent"}(W||(W={}));class Z{static chord(e,t){return(0,$.gx)(e,t)}}function Y(){return{editor:void 0,languages:void 0,CancellationTokenSource:H.A,Emitter:z.Q5,KeyCode:C,KeyMod:Z,Position:j.L,Range:K.e,Selection:q.Y,SelectionDirection:A,MarkerSeverity:w,MarkerTag:y,Uri:U.o,Token:G.WU}}Z.CtrlCmd=2048,Z.Shift=1024,Z.Alt=512,Z.WinCtrl=256;var Q=i(93379),X=i.n(Q),J=i(7795),ee=i.n(J),te=i(90569),ie=i.n(te),ne=i(3565),oe=i.n(ne),re=i(19216),se=i.n(re),ae=i(44589),le=i.n(ae),ce=i(98835),de={};de.styleTagTransform=le(),de.setAttributes=oe(),de.insert=ie().bind(null,"head"),de.domAPI=ee(),de.insertStyleElement=se(),X()(ce.Z,de),ce.Z&&ce.Z.locals&&ce.Z.locals;var ue=i(18039),he=i(95602),ge=i(3622),pe=i(54552),me=i(59417),fe=i(19483),_e=i(77324),be=i(98340),ve=i(14704),Ce=i(10940),we=i(59083),ye=i(40027),Se=i(4004),xe=i(16182),ke=i(6954),Le=i(28295);let Ee=!1;function Ne(e){ke.$L&&(Ee||(Ee=!0,console.warn("Could not create web worker(s). Falling back to loading web worker code in main thread, which might cause UI freezes. Please see https://github.com/microsoft/monaco-editor#faq")),console.warn(e.message))}class De{constructor(e,t,i,n){this.vsWorker=e,this.req=t,this.method=i,this.args=n,this.type=0}}class Ie{constructor(e,t,i,n){this.vsWorker=e,this.seq=t,this.res=i,this.err=n,this.type=1}}class Te{constructor(e,t,i,n){this.vsWorker=e,this.req=t,this.eventName=i,this.arg=n,this.type=2}}class Ae{constructor(e,t,i){this.vsWorker=e,this.req=t,this.event=i,this.type=3}}class Re{constructor(e,t){this.vsWorker=e,this.req=t,this.type=4}}class Me{constructor(e){this._workerId=-1,this._handler=e,this._lastSentReq=0,this._pendingReplies=Object.create(null),this._pendingEmitters=new Map,this._pendingEvents=new Map}setWorkerId(e){this._workerId=e}sendMessage(e,t){const i=String(++this._lastSentReq);return new Promise(((n,o)=>{this._pendingReplies[i]={resolve:n,reject:o},this._send(new De(this._workerId,i,e,t))}))}listen(e,t){let i=null;const n=new z.Q5({onFirstListenerAdd:()=>{i=String(++this._lastSentReq),this._pendingEmitters.set(i,n),this._send(new Te(this._workerId,i,e,t))},onLastListenerRemove:()=>{this._pendingEmitters.delete(i),this._send(new Re(this._workerId,i)),i=null}});return n.event}handleMessage(e){e&&e.vsWorker&&(-1!==this._workerId&&e.vsWorker!==this._workerId||this._handleMessage(e))}_handleMessage(e){switch(e.type){case 1:return this._handleReplyMessage(e);case 0:return this._handleRequestMessage(e);case 2:return this._handleSubscribeEventMessage(e);case 3:return this._handleEventMessage(e);case 4:return this._handleUnsubscribeEventMessage(e)}}_handleReplyMessage(e){if(!this._pendingReplies[e.seq])return void console.warn("Got reply to unknown seq");let t=this._pendingReplies[e.seq];if(delete this._pendingReplies[e.seq],e.err){let i=e.err;return e.err.$isError&&(i=new Error,i.name=e.err.name,i.message=e.err.message,i.stack=e.err.stack),void t.reject(i)}t.resolve(e.res)}_handleRequestMessage(e){let t=e.req;this._handler.handleMessage(e.method,e.args).then((e=>{this._send(new Ie(this._workerId,t,e,void 0))}),(e=>{e.detail instanceof Error&&(e.detail=(0,xe.ri)(e.detail)),this._send(new Ie(this._workerId,t,void 0,(0,xe.ri)(e)))}))}_handleSubscribeEventMessage(e){const t=e.req,i=this._handler.handleEvent(e.eventName,e.arg)((e=>{this._send(new Ae(this._workerId,t,e))}));this._pendingEvents.set(t,i)}_handleEventMessage(e){this._pendingEmitters.has(e.req)?this._pendingEmitters.get(e.req).fire(e.event):console.warn("Got event for unknown req")}_handleUnsubscribeEventMessage(e){this._pendingEvents.has(e.req)?(this._pendingEvents.get(e.req).dispose(),this._pendingEvents.delete(e.req)):console.warn("Got unsubscribe for unknown req")}_send(e){let t=[];if(0===e.type)for(let i=0;i{this._protocol.handleMessage(e)}),(e=>{n&&n(e)}))),this._protocol=new Me({sendMessage:(e,t)=>{this._worker.postMessage(e,t)},handleMessage:(e,t)=>{if("function"!=typeof i[e])return Promise.reject(new Error("Missing method "+e+" on main thread host."));try{return Promise.resolve(i[e].apply(i,t))}catch(e){return Promise.reject(e)}},handleEvent:(e,t)=>{if(Fe(e)){const n=i[e].call(i,t);if("function"!=typeof n)throw new Error(`Missing dynamic event ${e} on main thread host.`);return n}if(Pe(e)){const t=i[e];if("function"!=typeof t)throw new Error(`Missing event ${e} on main thread host.`);return t}throw new Error(`Malformed event name ${e}`)}}),this._protocol.setWorkerId(this._worker.getId());let o=null;void 0!==ke.li.require&&"function"==typeof ke.li.require.getConfig?o=ke.li.require.getConfig():void 0!==ke.li.requirejs&&(o=ke.li.requirejs.s.contexts._.config);const r=Le.$E(i);this._onModuleLoaded=this._protocol.sendMessage("$initialize",[this._worker.getId(),JSON.parse(JSON.stringify(o)),t,r]);const s=(e,t)=>this._request(e,t),a=(e,t)=>this._protocol.listen(e,t);this._lazyProxy=new Promise(((e,i)=>{n=i,this._onModuleLoaded.then((t=>{e(function(e,t,i){const n=e=>function(){const i=Array.prototype.slice.call(arguments,0);return t(e,i)},o=e=>function(t){return i(e,t)};let r={};for(const t of e)Fe(t)?r[t]=o(t):Pe(t)?r[t]=i(t,void 0):r[t]=n(t);return r}(t,s,a))}),(e=>{i(e),this._onError("Worker failed to load "+t,e)}))}))}getProxyObject(){return this._lazyProxy}_request(e,t){return new Promise(((i,n)=>{this._onModuleLoaded.then((()=>{this._protocol.sendMessage(e,t).then(i,n)}),n)}))}_onError(e,t){console.error(e),console.info(t)}}function Pe(e){return"o"===e[0]&&"n"===e[1]&&ue.df(e.charCodeAt(2))}function Fe(e){return/^onDynamic/.test(e)&&ue.df(e.charCodeAt(9))}var Be;const We=null===(Be=window.trustedTypes)||void 0===Be?void 0:Be.createPolicy("defaultWorkerFactory",{createScriptURL:e=>e});class Ve{constructor(e,t,i,n,o){this.id=t;const r=function(e){if(ke.li.MonacoEnvironment){if("function"==typeof ke.li.MonacoEnvironment.getWorker)return ke.li.MonacoEnvironment.getWorker("workerMain.js",e);if("function"==typeof ke.li.MonacoEnvironment.getWorkerUrl){const t=ke.li.MonacoEnvironment.getWorkerUrl("workerMain.js",e);return new Worker(We?We.createScriptURL(t):t,{name:e})}}throw new Error("You must define a function MonacoEnvironment.getWorkerUrl or MonacoEnvironment.getWorker")}(i);"function"==typeof r.then?this.worker=r:this.worker=Promise.resolve(r),this.postMessage(e,[]),this.worker.then((e=>{e.onmessage=function(e){n(e.data)},e.onmessageerror=o,"function"==typeof e.addEventListener&&e.addEventListener("error",o)}))}getId(){return this.id}postMessage(e,t){this.worker&&this.worker.then((i=>i.postMessage(e,t)))}dispose(){this.worker&&this.worker.then((e=>e.terminate())),this.worker=null}}class He{constructor(e){this._label=e,this._webWorkerFailedBeforeError=!1}create(e,t,i){let n=++He.LAST_WORKER_ID;if(this._webWorkerFailedBeforeError)throw this._webWorkerFailedBeforeError;return new Ve(e,n,this._label||"anonymous"+n,t,(e=>{Ne(e),this._webWorkerFailedBeforeError=e,i(e)}))}}He.LAST_WORKER_ID=0;var ze=i(53276);function $e(e,t,i,n){return new ze.Hs(e,t,i).ComputeDiff(n)}class Ue{constructor(e){const t=[],i=[];for(let n=0,o=e.length;n0&&t.originalLength<20&&t.modifiedLength>0&&t.modifiedLength<20&&o()){const r=i.createCharSequence(e,t.originalStart,t.originalStart+t.originalLength-1),a=n.createCharSequence(e,t.modifiedStart,t.modifiedStart+t.modifiedLength-1);let l=$e(r,a,o,!0).changes;s&&(l=function(e){if(e.length<=1)return e;const t=[e[0]];let i=t[0];for(let n=1,o=e.length;n1&&s>1&&e.charCodeAt(i-2)===t.charCodeAt(s-2);)i--,s--;(i>1||s>1)&&this._pushTrimWhitespaceCharChange(n,o+1,1,i,r+1,1,s)}{let i=Ye(e,1),s=Ye(t,1);const a=e.length+1,l=t.length+1;for(;i!0;const t=Date.now();return()=>Date.now()-tt&&(t=r),o>i&&(i=o),s>i&&(i=s)}t++,i++;const n=new tt(i,t,0);for(let t=0,i=e.length;t=this._maxCharCode?0:this._states.get(e,t)}}let nt=null,ot=null;class rt{static _createLink(e,t,i,n,o){let r=o-1;do{const i=t.charCodeAt(r);if(2!==e.get(i))break;r--}while(r>n);if(n>0){const e=t.charCodeAt(n-1),i=t.charCodeAt(r);(40===e&&41===i||91===e&&93===i||123===e&&125===i)&&r--}return{range:{startLineNumber:i,startColumn:n+1,endLineNumber:i,endColumn:r+2},url:t.substring(n,r+1)}}static computeLinks(e,t=function(){return null===nt&&(nt=new it([[1,104,2],[1,72,2],[1,102,6],[1,70,6],[2,116,3],[2,84,3],[3,116,4],[3,84,4],[4,112,5],[4,80,5],[5,115,9],[5,83,9],[5,58,10],[6,105,7],[6,73,7],[7,108,8],[7,76,8],[8,101,9],[8,69,9],[9,58,10],[10,47,11],[11,47,12]])),nt}()){const i=function(){if(null===ot){ot=new et.N(0);const e=" \t<>'\"、。。、,.:;‘〈「『〔([{「」}])〕』」〉’`~…";for(let t=0;t=0?(n+=i?1:-1,n<0?n=e.length-1:n%=e.length,e[n]):null}}st.INSTANCE=new st;var at=i(52150),lt=i(5083),ct=function(e,t,i,n){return new(i||(i=Promise))((function(o,r){function s(e){try{l(n.next(e))}catch(e){r(e)}}function a(e){try{l(n.throw(e))}catch(e){r(e)}}function l(e){var t;e.done?o(e.value):(t=e.value,t instanceof i?t:new i((function(e){e(t)}))).then(s,a)}l((n=n.apply(e,t||[])).next())}))};class dt extends class{constructor(e,t,i,n){this._uri=e,this._lines=t,this._eol=i,this._versionId=n,this._lineStarts=null,this._cachedTextValue=null}dispose(){this._lines.length=0}get version(){return this._versionId}getText(){return null===this._cachedTextValue&&(this._cachedTextValue=this._lines.join(this._eol)),this._cachedTextValue}onEvents(e){e.eol&&e.eol!==this._eol&&(this._eol=e.eol,this._lineStarts=null);const t=e.changes;for(const e of t)this._acceptDeleteRange(e.range),this._acceptInsertText(new j.L(e.range.startLineNumber,e.range.startColumn),e.text);this._versionId=e.versionId,this._cachedTextValue=null}_ensureLineStarts(){if(!this._lineStarts){const e=this._eol.length,t=this._lines.length,i=new Uint32Array(t);for(let n=0;nthis._lines.length)t=this._lines.length,i=this._lines[t-1].length+1,n=!0;else{const e=this._lines[t-1].length+1;i<1?(i=1,n=!0):i>e&&(i=e,n=!0)}return n?{lineNumber:t,column:i}:e}}class ut{constructor(e,t){this._host=e,this._models=Object.create(null),this._foreignModuleFactory=t,this._foreignModule=null}dispose(){this._models=Object.create(null)}_getModel(e){return this._models[e]}_getModels(){const e=[];return Object.keys(this._models).forEach((t=>e.push(this._models[t]))),e}acceptNewModel(e){this._models[e.url]=new dt(U.o.parse(e.url),e.lines,e.EOL,e.versionId)}acceptModelChanged(e,t){this._models[e]&&this._models[e].onEvents(t)}acceptRemovedModel(e){this._models[e]&&delete this._models[e]}computeUnicodeHighlights(e,t,i){return ct(this,void 0,void 0,(function*(){const n=this._getModel(e);return n?lt.a.computeUnicodeHighlights(n,t,i):{ranges:[],hasMore:!1,ambiguousCharacterCount:0,invisibleCharacterCount:0,nonBasicAsciiCharacterCount:0}}))}computeDiff(e,t,i,n){return ct(this,void 0,void 0,(function*(){const o=this._getModel(e),r=this._getModel(t);if(!o||!r)return null;const s=o.getLinesContent(),a=r.getLinesContent(),l=new Ge(s,a,{shouldComputeCharChanges:!0,shouldPostProcessCharChanges:!0,shouldIgnoreTrimWhitespace:i,shouldMakePrettyDiff:!0,maxComputationTime:n}).computeDiff(),c=!(l.changes.length>0)&&this._modelsAreIdentical(o,r);return{quitEarly:l.quitEarly,identical:c,changes:l.changes}}))}_modelsAreIdentical(e,t){const i=e.getLineCount();if(i!==t.getLineCount())return!1;for(let n=1;n<=i;n++)if(e.getLineContent(n)!==t.getLineContent(n))return!1;return!0}computeMoreMinimalEdits(e,t){return ct(this,void 0,void 0,(function*(){const i=this._getModel(e);if(!i)return t;const n=[];let o;t=t.slice(0).sort(((e,t)=>e.range&&t.range?K.e.compareRangesUsingStarts(e.range,t.range):(e.range?0:1)-(t.range?0:1)));for(let{range:e,text:r,eol:s}of t){if("number"==typeof s&&(o=s),K.e.isEmpty(e)&&!r)continue;const t=i.getValueInRange(e);if(r=r.replace(/\r\n|\n|\r/g,i.eol),t===r)continue;if(Math.max(r.length,t.length)>ut._diffLimit){n.push({range:e,text:r});continue}const a=(0,ze.a$)(t,r,!1),l=i.offsetAt(K.e.lift(e).getStartPosition());for(const e of a){const t=i.positionAt(l+e.originalStart),o=i.positionAt(l+e.originalStart+e.originalLength),s={text:r.substr(e.modifiedStart,e.modifiedLength),range:{startLineNumber:t.lineNumber,startColumn:t.column,endLineNumber:o.lineNumber,endColumn:o.column}};i.getValueInRange(s.range)!==s.text&&n.push(s)}}return"number"==typeof o&&n.push({eol:o,text:"",range:{startLineNumber:0,startColumn:0,endLineNumber:0,endColumn:0}}),n}))}computeLinks(e){return ct(this,void 0,void 0,(function*(){const t=this._getModel(e);return t?function(e){return e&&"function"==typeof e.getLineCount&&"function"==typeof e.getLineContent?rt.computeLinks(e):[]}(t):null}))}textualSuggest(e,t,i,n){return ct(this,void 0,void 0,(function*(){const o=new at.G(!0),r=new RegExp(i,n),s=new Set;e:for(let i of e){const e=this._getModel(i);if(e)for(let i of e.words(r))if(i!==t&&isNaN(Number(i))&&(s.add(i),s.size>ut._suggestionsLimit))break e}return{words:Array.from(s),duration:o.elapsed()}}))}computeWordRanges(e,t,i,n){return ct(this,void 0,void 0,(function*(){const o=this._getModel(e);if(!o)return Object.create(null);const r=new RegExp(i,n),s=Object.create(null);for(let e=t.startLineNumber;ethis._host.fhr(e,t))),getMirrorModels:()=>this._getModels()};return this._foreignModuleFactory?(this._foreignModule=this._foreignModuleFactory(n,t),Promise.resolve(Le.$E(this._foreignModule))):Promise.reject(new Error("Unexpected usage"))}fmr(e,t){if(!this._foreignModule||"function"!=typeof this._foreignModule[e])return Promise.reject(new Error("Missing requestHandler or method: "+e));try{return Promise.resolve(this._foreignModule[e].apply(this._foreignModule,t))}catch(e){return Promise.reject(e)}}}ut._diffLimit=1e5,ut._suggestionsLimit=1e4,"function"==typeof importScripts&&(ke.li.monaco=Y());var ht=i(72837),gt=i(57800),pt=i(16592),mt=i(66988),ft=function(e,t){return function(i,n){t(i,n,e)}},_t=function(e,t,i,n){return new(i||(i=Promise))((function(o,r){function s(e){try{l(n.next(e))}catch(e){r(e)}}function a(e){try{l(n.throw(e))}catch(e){r(e)}}function l(e){var t;e.done?o(e.value):(t=e.value,t instanceof i?t:new i((function(e){e(t)}))).then(s,a)}l((n=n.apply(e,t||[])).next())}))};function bt(e,t){const i=e.getModel(t);return!!i&&!i.isTooLargeForSyncing()}let vt=class extends Se.JT{constructor(e,t,i,n,o){super(),this._modelService=e,this._workerManager=this._register(new wt(this._modelService,n)),this._logService=i,this._register(o.linkProvider.register({language:"*",hasAccessToAllModels:!0},{provideLinks:(e,t)=>bt(this._modelService,e.uri)?this._workerManager.withWorker().then((t=>t.computeLinks(e.uri))).then((e=>e&&{links:e})):Promise.resolve({links:[]})})),this._register(o.completionProvider.register("*",new Ct(this._workerManager,t,this._modelService,n)))}dispose(){super.dispose()}canComputeUnicodeHighlights(e){return bt(this._modelService,e)}computedUnicodeHighlights(e,t,i){return this._workerManager.withWorker().then((n=>n.computedUnicodeHighlights(e,t,i)))}computeDiff(e,t,i,n){return this._workerManager.withWorker().then((o=>o.computeDiff(e,t,i,n)))}computeMoreMinimalEdits(e,t){if((0,gt.Of)(t)){if(!bt(this._modelService,e))return Promise.resolve(t);const i=at.G.create(!0),n=this._workerManager.withWorker().then((i=>i.computeMoreMinimalEdits(e,t)));return n.finally((()=>this._logService.trace("FORMAT#computeMoreMinimalEdits",e.toString(!0),i.elapsed()))),Promise.race([n,(0,ye.Vs)(1e3).then((()=>t))])}return Promise.resolve(void 0)}canNavigateValueSet(e){return bt(this._modelService,e)}navigateValueSet(e,t,i){return this._workerManager.withWorker().then((n=>n.navigateValueSet(e,t,i)))}canComputeWordRanges(e){return bt(this._modelService,e)}computeWordRanges(e,t){return this._workerManager.withWorker().then((i=>i.computeWordRanges(e,t)))}};vt=function(e,t,i,n){var o,r=arguments.length,s=r<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,i):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(e,t,i,n);else for(var a=e.length-1;a>=0;a--)(o=e[a])&&(s=(r<3?o(s):r>3?o(t,i,s):o(t,i))||s);return r>3&&s&&Object.defineProperty(t,i,s),s}([ft(0,we.q),ft(1,ht.V),ft(2,pt.VZ),ft(3,be.c_),ft(4,mt.p)],vt);class Ct{constructor(e,t,i,n){this.languageConfigurationService=n,this._debugDisplayName="wordbasedCompletions",this._workerManager=e,this._configurationService=t,this._modelService=i}provideCompletionItems(e,t){return _t(this,void 0,void 0,(function*(){const i=this._configurationService.getValue(e.uri,t,"editor");if(!i.wordBasedSuggestions)return;const n=[];if("currentDocument"===i.wordBasedSuggestionsMode)bt(this._modelService,e.uri)&&n.push(e.uri);else for(const t of this._modelService.getModels())bt(this._modelService,t.uri)&&(t===e?n.unshift(t.uri):"allDocuments"!==i.wordBasedSuggestionsMode&&t.getLanguageId()!==e.getLanguageId()||n.push(t.uri));if(0===n.length)return;const o=this.languageConfigurationService.getLanguageConfiguration(e.getLanguageId()).getWordDefinition(),r=e.getWordAtPosition(t),s=r?new K.e(t.lineNumber,r.startColumn,t.lineNumber,r.endColumn):K.e.fromPositions(t),a=s.setEndPosition(t.lineNumber,t.column),l=yield this._workerManager.withWorker(),c=yield l.textualSuggest(n,null==r?void 0:r.word,o);return c?{duration:c.duration,suggestions:c.words.map((e=>({kind:18,label:e,insertText:e,range:{insert:a,replace:s}})))}:void 0}))}}class wt extends Se.JT{constructor(e,t){super(),this.languageConfigurationService=t,this._modelService=e,this._editorWorkerClient=null,this._lastWorkerUsedTime=(new Date).getTime(),this._register(new ye.zh).cancelAndSet((()=>this._checkStopIdleWorker()),Math.round(15e4)),this._register(this._modelService.onModelRemoved((e=>this._checkStopEmptyWorker())))}dispose(){this._editorWorkerClient&&(this._editorWorkerClient.dispose(),this._editorWorkerClient=null),super.dispose()}_checkStopEmptyWorker(){this._editorWorkerClient&&0===this._modelService.getModels().length&&(this._editorWorkerClient.dispose(),this._editorWorkerClient=null)}_checkStopIdleWorker(){this._editorWorkerClient&&(new Date).getTime()-this._lastWorkerUsedTime>3e5&&(this._editorWorkerClient.dispose(),this._editorWorkerClient=null)}withWorker(){return this._lastWorkerUsedTime=(new Date).getTime(),this._editorWorkerClient||(this._editorWorkerClient=new kt(this._modelService,!1,"editorWorkerService",this.languageConfigurationService)),Promise.resolve(this._editorWorkerClient)}}class yt extends Se.JT{constructor(e,t,i){if(super(),this._syncedModels=Object.create(null),this._syncedModelsLastUsedTime=Object.create(null),this._proxy=e,this._modelService=t,!i){const e=new ye.zh;e.cancelAndSet((()=>this._checkStopModelSync()),Math.round(3e4)),this._register(e)}}dispose(){for(let e in this._syncedModels)(0,Se.B9)(this._syncedModels[e]);this._syncedModels=Object.create(null),this._syncedModelsLastUsedTime=Object.create(null),super.dispose()}ensureSyncedResources(e,t){for(const i of e){const e=i.toString();this._syncedModels[e]||this._beginModelSync(i,t),this._syncedModels[e]&&(this._syncedModelsLastUsedTime[e]=(new Date).getTime())}}_checkStopModelSync(){const e=(new Date).getTime(),t=[];for(let i in this._syncedModelsLastUsedTime)e-this._syncedModelsLastUsedTime[i]>6e4&&t.push(i);for(const e of t)this._stopModelSync(e)}_beginModelSync(e,t){const i=this._modelService.getModel(e);if(!i)return;if(!t&&i.isTooLargeForSyncing())return;const n=e.toString();this._proxy.acceptNewModel({url:i.uri.toString(),lines:i.getLinesContent(),EOL:i.getEOL(),versionId:i.getVersionId()});const o=new Se.SL;o.add(i.onDidChangeContent((e=>{this._proxy.acceptModelChanged(n.toString(),e)}))),o.add(i.onWillDispose((()=>{this._stopModelSync(n)}))),o.add((0,Se.OF)((()=>{this._proxy.acceptRemovedModel(n)}))),this._syncedModels[n]=o}_stopModelSync(e){const t=this._syncedModels[e];delete this._syncedModels[e],delete this._syncedModelsLastUsedTime[e],(0,Se.B9)(t)}}class St{constructor(e){this._instance=e,this._proxyObj=Promise.resolve(this._instance)}dispose(){this._instance.dispose()}getProxyObject(){return this._proxyObj}}class xt{constructor(e){this._workerClient=e}fhr(e,t){return this._workerClient.fhr(e,t)}}class kt extends Se.JT{constructor(e,t,i,n){super(),this.languageConfigurationService=n,this._disposed=!1,this._modelService=e,this._keepIdleModels=t,this._workerFactory=new He(i),this._worker=null,this._modelManager=null}fhr(e,t){throw new Error("Not implemented!")}_getOrCreateWorker(){if(!this._worker)try{this._worker=this._register(new Oe(this._workerFactory,"vs/editor/common/services/editorSimpleWorker",new xt(this)))}catch(e){Ne(e),this._worker=new St(new ut(new xt(this),null))}return this._worker}_getProxy(){return this._getOrCreateWorker().getProxyObject().then(void 0,(e=>(Ne(e),this._worker=new St(new ut(new xt(this),null)),this._getOrCreateWorker().getProxyObject())))}_getOrCreateModelManager(e){return this._modelManager||(this._modelManager=this._register(new yt(e,this._modelService,this._keepIdleModels))),this._modelManager}_withSyncedResources(e,t=!1){return _t(this,void 0,void 0,(function*(){return this._disposed?Promise.reject((0,xe.F0)()):this._getProxy().then((i=>(this._getOrCreateModelManager(i).ensureSyncedResources(e,t),i)))}))}computedUnicodeHighlights(e,t,i){return this._withSyncedResources([e]).then((n=>n.computeUnicodeHighlights(e.toString(),t,i)))}computeDiff(e,t,i,n){return this._withSyncedResources([e,t],!0).then((o=>o.computeDiff(e.toString(),t.toString(),i,n)))}computeMoreMinimalEdits(e,t){return this._withSyncedResources([e]).then((i=>i.computeMoreMinimalEdits(e.toString(),t)))}computeLinks(e){return this._withSyncedResources([e]).then((t=>t.computeLinks(e.toString())))}textualSuggest(e,t,i){return _t(this,void 0,void 0,(function*(){const n=yield this._withSyncedResources(e),o=i.source,r=(0,ue.mr)(i);return n.textualSuggest(e.map((e=>e.toString())),t,o,r)}))}computeWordRanges(e,t){return this._withSyncedResources([e]).then((i=>{const n=this._modelService.getModel(e);if(!n)return Promise.resolve(null);const o=this.languageConfigurationService.getLanguageConfiguration(n.getLanguageId()).getWordDefinition(),r=o.source,s=(0,ue.mr)(o);return i.computeWordRanges(e.toString(),t,r,s)}))}navigateValueSet(e,t,i){return this._withSyncedResources([e]).then((n=>{const o=this._modelService.getModel(e);if(!o)return null;const r=this.languageConfigurationService.getLanguageConfiguration(o.getLanguageId()).getWordDefinition(),s=r.source,a=(0,ue.mr)(r);return n.navigateValueSet(e.toString(),t,i,s,a)}))}dispose(){super.dispose(),this._disposed=!0}}class Lt extends kt{constructor(e,t,i){super(e,i.keepIdleModels||!1,i.label,t),this._foreignModuleId=i.moduleId,this._foreignModuleCreateData=i.createData||null,this._foreignModuleHost=i.host||null,this._foreignProxy=null}fhr(e,t){if(!this._foreignModuleHost||"function"!=typeof this._foreignModuleHost[e])return Promise.reject(new Error("Missing method "+e+" or missing main thread foreign host."));try{return Promise.resolve(this._foreignModuleHost[e].apply(this._foreignModuleHost,t))}catch(e){return Promise.reject(e)}}_getForeignProxy(){return this._foreignProxy||(this._foreignProxy=this._getProxy().then((e=>{const t=this._foreignModuleHost?Le.$E(this._foreignModuleHost):[];return e.loadForeignModule(this._foreignModuleId,this._foreignModuleCreateData,t).then((t=>{this._foreignModuleCreateData=null;const i=(t,i)=>e.fmr(t,i),n=(e,t)=>function(){const i=Array.prototype.slice.call(arguments,0);return t(e,i)},o={};for(const e of t)o[e]=n(e,i);return o}))}))),this._foreignProxy}getProxy(){return this._getForeignProxy()}withSyncedResources(e){return this._withSyncedResources(e).then((e=>this.getProxy()))}}var Et=i(59193),Nt=i(2969),Dt=i(29954);function It(e){return"string"==typeof e}function Tt(e){return!It(e)}function At(e){return!e}function Rt(e,t){return e.ignoreCase&&t?t.toLowerCase():t}function Mt(e){return e.replace(/[&<>'"_]/g,"-")}function Ot(e,t){return new Error(`${e.languageId}: ${t}`)}function Pt(e,t,i,n,o){let r=null;return t.replace(/\$((\$)|(#)|(\d\d?)|[sS](\d\d?)|@(\w+))/g,(function(t,s,a,l,c,d,u,h,g){return At(a)?At(l)?!At(c)&&c0;){const t=e.tokenizer[i];if(t)return t;const n=i.lastIndexOf(".");i=n<0?null:i.substr(0,n)}return null}class Bt{constructor(e){this._maxCacheDepth=e,this._entries=Object.create(null)}static create(e,t){return this._INSTANCE.create(e,t)}create(e,t){if(null!==e&&e.depth>=this._maxCacheDepth)return new Wt(e,t);let i=Wt.getStackElementId(e);i.length>0&&(i+="|"),i+=t;let n=this._entries[i];return n||(n=new Wt(e,t),this._entries[i]=n,n)}}Bt._INSTANCE=new Bt(5);class Wt{constructor(e,t){this.parent=e,this.state=t,this.depth=(this.parent?this.parent.depth:0)+1}static getStackElementId(e){let t="";for(;null!==e;)t.length>0&&(t+="|"),t+=e.state,e=e.parent;return t}static _equals(e,t){for(;null!==e&&null!==t;){if(e===t)return!0;if(e.state!==t.state)return!1;e=e.parent,t=t.parent}return null===e&&null===t}equals(e){return Wt._equals(this,e)}push(e){return Bt.create(this,e)}pop(){return this.parent}popall(){let e=this;for(;e.parent;)e=e.parent;return e}switchTo(e){return Bt.create(this.parent,e)}}class Vt{constructor(e,t){this.languageId=e,this.state=t}equals(e){return this.languageId===e.languageId&&this.state.equals(e.state)}clone(){return this.state.clone()===this.state?this:new Vt(this.languageId,this.state)}}class Ht{constructor(e){this._maxCacheDepth=e,this._entries=Object.create(null)}static create(e,t){return this._INSTANCE.create(e,t)}create(e,t){if(null!==t)return new zt(e,t);if(null!==e&&e.depth>=this._maxCacheDepth)return new zt(e,t);const i=Wt.getStackElementId(e);let n=this._entries[i];return n||(n=new zt(e,null),this._entries[i]=n,n)}}Ht._INSTANCE=new Ht(5);class zt{constructor(e,t){this.stack=e,this.embeddedLanguageData=t}clone(){return(this.embeddedLanguageData?this.embeddedLanguageData.clone():null)===this.embeddedLanguageData?this:Ht.create(this.stack,this.embeddedLanguageData)}equals(e){return e instanceof zt&&!!this.stack.equals(e.stack)&&(null===this.embeddedLanguageData&&null===e.embeddedLanguageData||null!==this.embeddedLanguageData&&null!==e.embeddedLanguageData&&this.embeddedLanguageData.equals(e.embeddedLanguageData))}}class $t{constructor(){this._tokens=[],this._languageId=null,this._lastTokenType=null,this._lastTokenLanguage=null}enterLanguage(e){this._languageId=e}emit(e,t){this._lastTokenType===t&&this._lastTokenLanguage===this._languageId||(this._lastTokenType=t,this._lastTokenLanguage=this._languageId,this._tokens.push(new G.WU(e,t,this._languageId)))}nestedLanguageTokenize(e,t,i,n){const o=i.languageId,r=i.state,s=G.RW.get(o);if(!s)return this.enterLanguage(o),this.emit(n,""),r;const a=s.tokenize(e,t,r);if(0!==n)for(const e of a.tokens)this._tokens.push(new G.WU(e.offset+n,e.type,e.language));else this._tokens=this._tokens.concat(a.tokens);return this._lastTokenType=null,this._lastTokenLanguage=null,this._languageId=null,a.endState}finalize(e){return new G.hG(this._tokens,e)}}class Ut{constructor(e,t){this._languageService=e,this._theme=t,this._prependTokens=null,this._tokens=[],this._currentLanguageId=0,this._lastTokenMetadata=0}enterLanguage(e){this._currentLanguageId=this._languageService.languageIdCodec.encodeLanguageId(e)}emit(e,t){const i=this._theme.match(this._currentLanguageId,t);this._lastTokenMetadata!==i&&(this._lastTokenMetadata=i,this._tokens.push(e),this._tokens.push(i))}static _merge(e,t,i){const n=null!==e?e.length:0,o=t.length,r=null!==i?i.length:0;if(0===n&&0===o&&0===r)return new Uint32Array(0);if(0===n&&0===o)return i;if(0===o&&0===r)return e;const s=new Uint32Array(n+o+r);null!==e&&s.set(e);for(let e=0;e{if(o)return;let t=!1;for(let i=0,n=e.changedLanguages.length;i{}))}}getInitialState(){const e=Bt.create(null,this._lexer.start);return Ht.create(e,null)}tokenize(e,t,i){const n=new $t,o=this._tokenize(e,t,i,n);return n.finalize(o)}tokenizeEncoded(e,t,i){const n=new Ut(this._languageService,this._standaloneThemeService.getColorTheme().tokenTheme),o=this._tokenize(e,t,i,n);return n.finalize(o)}_tokenize(e,t,i,n){return i.embeddedLanguageData?this._nestedTokenize(e,t,i,0,n):this._myTokenize(e,t,i,0,n)}_findLeavingNestedLanguageOffset(e,t){let i=this._lexer.tokenizer[t.stack.state];if(!i&&(i=Ft(this._lexer,t.stack.state),!i))throw Ot(this._lexer,"tokenizer state is not defined: "+t.stack.state);let n=-1,o=!1;for(const t of i){if(!Tt(t.action)||"@pop"!==t.action.nextEmbedded)continue;o=!0;let i=t.regex;const r=t.regex.source;if("^(?:"===r.substr(0,4)&&")"===r.substr(r.length-1,1)){const e=(i.ignoreCase?"i":"")+(i.unicode?"u":"");i=new RegExp(r.substr(4,r.length-5),e)}const s=e.search(i);-1===s||0!==s&&t.matchOnlyAtLineStart||(-1===n||s0&&o.nestedLanguageTokenize(s,!1,i.embeddedLanguageData,n);const a=e.substring(r);return this._myTokenize(a,t,i,n+r,o)}_safeRuleName(e){return e?e.name:"(unknown)"}_myTokenize(e,t,i,n,o){o.enterLanguage(this._languageId);const r=e.length,s=t&&this._lexer.includeLF?e+"\n":e,a=s.length;let l=i.embeddedLanguageData,c=i.stack,d=0,u=null,h=!0;for(;h||d=a)break;h=!1;let e=this._lexer.tokenizer[_];if(!e&&(e=Ft(this._lexer,_),!e))throw Ot(this._lexer,"tokenizer state is not defined: "+_);let t=s.substr(d);for(const i of e)if((0===d||!i.matchOnlyAtLineStart)&&(b=t.match(i.regex),b)){v=b[0],C=i.action;break}}if(b||(b=[""],v=""),C||(d=this._lexer.maxStack)throw Ot(this._lexer,"maximum tokenizer stack size reached: ["+c.state+","+c.parent.state+",...]");c=c.push(_)}else if("@pop"===C.next){if(c.depth<=1)throw Ot(this._lexer,"trying to pop an empty stack in rule: "+this._safeRuleName(w));c=c.pop()}else if("@popall"===C.next)c=c.popall();else{let e=Pt(this._lexer,C.next,v,b,_);if("@"===e[0]&&(e=e.substr(1)),!Ft(this._lexer,e))throw Ot(this._lexer,"trying to set a next state '"+e+"' that is undefined in rule: "+this._safeRuleName(w));c=c.push(e)}}C.log&&"string"==typeof C.log&&(g=this._lexer,p=this._lexer.languageId+": "+Pt(this._lexer,C.log,v,b,_),console.log(`${g.languageId}: ${p}`))}if(null===S)throw Ot(this._lexer,"lexer rule has no well-defined action in rule: "+this._safeRuleName(w));const x=i=>{const r=this._languageService.getLanguageIdByLanguageName(i)||this._languageService.getLanguageIdByMimeType(i)||i,s=this._getNestedEmbeddedLanguageData(r);if(d0)throw Ot(this._lexer,"groups cannot be nested: "+this._safeRuleName(w));if(b.length!==S.length+1)throw Ot(this._lexer,"matched number of groups does not match the number of actions in rule: "+this._safeRuleName(w));let e=0;for(let t=1;te});class Zt{static colorizeElement(e,t,i,n){const o=(n=n||{}).theme||"vs",r=n.mimeType||i.getAttribute("lang")||i.getAttribute("data-lang");if(!r)return console.error("Mode not detected"),Promise.resolve();const s=t.getLanguageIdByMimeType(r)||r;e.setTheme(o);const a=i.firstChild?i.firstChild.nodeValue:"";return i.className+=" "+o,this.colorize(t,a||"",s,n).then((e=>{var t;const n=null!==(t=null==Gt?void 0:Gt.createHTML(e))&&void 0!==t?t:e;i.innerHTML=n}),(e=>console.error(e)))}static colorize(e,t,i,n){return o=this,r=void 0,a=function*(){const o=e.languageIdCodec;let r=4;n&&"number"==typeof n.tabSize&&(r=n.tabSize),ue.uS(t)&&(t=t.substr(1));const s=ue.uq(t);if(!e.isRegisteredLanguageId(i))return Yt(s,r,o);const a=yield G.RW.getOrCreate(i);return a?function(e,t,i,n){return new Promise(((o,r)=>{const s=()=>{const a=function(e,t,i,n){let o=[],r=i.getInitialState();for(let s=0,a=e.length;s"),r=l.endState}return o.join("")}(e,t,i,n);if(i instanceof jt){const e=i.getLoadStatus();if(!1===e.loaded)return void e.promise.then(s,r)}o(a)};s()}))}(s,r,a,o):Yt(s,r,o)},new((s=void 0)||(s=Promise))((function(e,t){function i(e){try{l(a.next(e))}catch(e){t(e)}}function n(e){try{l(a.throw(e))}catch(e){t(e)}}function l(t){var o;t.done?e(t.value):(o=t.value,o instanceof s?o:new s((function(e){e(o)}))).then(i,n)}l((a=a.apply(o,r||[])).next())}));var o,r,s,a}static colorizeLine(e,t,i,n,o=4){const r=Dt.wA.isBasicASCII(e,t),s=Dt.wA.containsRTL(e,r,i);return(0,Nt.tF)(new Nt.IJ(!1,!0,e,!1,r,s,0,n,[],o,0,0,0,0,-1,"none",!1,!1,null)).html}static colorizeModelLine(e,t,i=4){const n=e.getLineContent(t);e.forceTokenization(t);const o=e.getLineTokens(t).inflate();return this.colorizeLine(n,e.mightContainNonBasicASCII(),e.mightContainRTL(),o,i)}}function Yt(e,t,i){let n=[];const o=new Uint32Array(2);o[0]=0,o[1]=16793600;for(let r=0,s=e.length;r")}return n.join("")}var Qt=i(77339),Xt=i(34239),Jt=i(43061),ei=i(11559),ti=i(22157),ii=i(68695),ni=i(9734),oi=i(81585);let ri=class extends Se.JT{constructor(e){super(),this._themeService=e,this._onCodeEditorAdd=this._register(new z.Q5),this.onCodeEditorAdd=this._onCodeEditorAdd.event,this._onCodeEditorRemove=this._register(new z.Q5),this.onCodeEditorRemove=this._onCodeEditorRemove.event,this._onDiffEditorAdd=this._register(new z.Q5),this.onDiffEditorAdd=this._onDiffEditorAdd.event,this._onDiffEditorRemove=this._register(new z.Q5),this.onDiffEditorRemove=this._onDiffEditorRemove.event,this._decorationOptionProviders=new Map,this._modelProperties=new Map,this._codeEditors=Object.create(null),this._diffEditors=Object.create(null),this._globalStyleSheet=null}addCodeEditor(e){this._codeEditors[e.getId()]=e,this._onCodeEditorAdd.fire(e)}removeCodeEditor(e){delete this._codeEditors[e.getId()]&&this._onCodeEditorRemove.fire(e)}listCodeEditors(){return Object.keys(this._codeEditors).map((e=>this._codeEditors[e]))}addDiffEditor(e){this._diffEditors[e.getId()]=e,this._onDiffEditorAdd.fire(e)}removeDiffEditor(e){delete this._diffEditors[e.getId()]&&this._onDiffEditorRemove.fire(e)}listDiffEditors(){return Object.keys(this._diffEditors).map((e=>this._diffEditors[e]))}getFocusedCodeEditor(){let e=null;const t=this.listCodeEditors();for(const i of t){if(i.hasTextFocus())return i;i.hasWidgetFocus()&&(e=i)}return e}removeDecorationType(e){const t=this._decorationOptionProviders.get(e);t&&(t.refCount--,t.refCount<=0&&(this._decorationOptionProviders.delete(e),t.dispose(),this.listCodeEditors().forEach((t=>t.removeDecorations(e)))))}setModelProperty(e,t,i){const n=e.toString();let o;this._modelProperties.has(n)?o=this._modelProperties.get(n):(o=new Map,this._modelProperties.set(n,o)),o.set(t,i)}getModelProperty(e,t){const i=e.toString();if(this._modelProperties.has(i))return this._modelProperties.get(i).get(t)}};var si,ai;ri=function(e,t,i,n){var o,r=arguments.length,s=r<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,i):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(e,t,i,n);else for(var a=e.length-1;a>=0;a--)(o=e[a])&&(s=(r<3?o(s):r>3?o(t,i,s):o(t,i))||s);return r>3&&s&&Object.defineProperty(t,i,s),s}([(si=0,ai=oi.XE,function(e,t){ai(e,t,si)})],ri);var li=i(60393),ci=i(14472),di=function(e,t){return function(i,n){t(i,n,e)}};let ui=class extends ri{constructor(e,t){super(t),this.onCodeEditorAdd((()=>this._checkContextKey())),this.onCodeEditorRemove((()=>this._checkContextKey())),this._editorIsOpen=e.createKey("editorIsOpen",!1),this._activeCodeEditor=null}_checkContextKey(){let e=!1;for(const t of this.listCodeEditors())if(!t.isSimpleWidget){e=!0;break}this._editorIsOpen.set(e)}setActiveCodeEditor(e){this._activeCodeEditor=e}getActiveCodeEditor(){return this._activeCodeEditor}openCodeEditor(e,t,i){return t?Promise.resolve(this.doOpenEditor(t,e)):Promise.resolve(null)}doOpenEditor(e,t){if(!this.findModel(e,t.resource)){if(t.resource){const i=t.resource.scheme;if(i===ni.lg.http||i===ni.lg.https)return(0,ii.V3)(t.resource.toString()),e}return null}const i=t.options?t.options.selection:null;if(i)if("number"==typeof i.endLineNumber&&"number"==typeof i.endColumn)e.setSelection(i),e.revealRangeInCenter(i,1);else{const t={lineNumber:i.startLineNumber,column:i.startColumn};e.setPosition(t),e.revealPositionInCenter(t,1)}return e}findModel(e,t){const i=e.getModel();return i&&i.uri.toString()!==t.toString()?null:i}};ui=function(e,t,i,n){var o,r=arguments.length,s=r<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,i):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(e,t,i,n);else for(var a=e.length-1;a>=0;a--)(o=e[a])&&(s=(r<3?o(s):r>3?o(t,i,s):o(t,i))||s);return r>3&&s&&Object.defineProperty(t,i,s),s}([di(0,li.i6),di(1,oi.XE)],ui),(0,ci.z)(ge.$,ui);var hi=i(12260);const gi=(0,hi.yh)("layoutService");var pi=function(e,t,i,n){var o,r=arguments.length,s=r<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,i):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(e,t,i,n);else for(var a=e.length-1;a>=0;a--)(o=e[a])&&(s=(r<3?o(s):r>3?o(t,i,s):o(t,i))||s);return r>3&&s&&Object.defineProperty(t,i,s),s},mi=function(e,t){return function(i,n){t(i,n,e)}};let fi=class{constructor(e){this._codeEditorService=e,this.onDidLayout=z.ju.None}get dimension(){return this._dimension||(this._dimension=ii.D6(window.document.body)),this._dimension}get hasContainer(){return!1}get container(){throw new Error("ILayoutService.container is not available in the standalone editor!")}focus(){var e;null===(e=this._codeEditorService.getFocusedCodeEditor())||void 0===e||e.focus()}};fi=pi([mi(0,ge.$)],fi);let _i=class extends fi{constructor(e,t){super(t),this._container=e}get hasContainer(){return!1}get container(){return this._container}};_i=pi([mi(1,ge.$)],_i),(0,ci.z)(gi,fi);var bi=i(81234),vi=i(89982),Ci=i(34243),wi=i(66877),yi=i(68511),Si=function(e,t){return function(i,n){t(i,n,e)}},xi=function(e,t,i,n){return new(i||(i=Promise))((function(o,r){function s(e){try{l(n.next(e))}catch(e){r(e)}}function a(e){try{l(n.throw(e))}catch(e){r(e)}}function l(e){var t;e.done?o(e.value):(t=e.value,t instanceof i?t:new i((function(e){e(t)}))).then(s,a)}l((n=n.apply(e,t||[])).next())}))};function ki(e){return e.scheme===ni.lg.file?e.fsPath:e.path}let Li=0;class Ei{constructor(e,t,i,n,o,r,s){this.id=++Li,this.type=0,this.actual=e,this.label=e.label,this.confirmBeforeUndo=e.confirmBeforeUndo||!1,this.resourceLabel=t,this.strResource=i,this.resourceLabels=[this.resourceLabel],this.strResources=[this.strResource],this.groupId=n,this.groupOrder=o,this.sourceId=r,this.sourceOrder=s,this.isValid=!0}setValid(e){this.isValid=e}toString(){return`[id:${this.id}] [group:${this.groupId}] [${this.isValid?" VALID":"INVALID"}] ${this.actual.constructor.name} - ${this.actual}`}}class Ni{constructor(e,t){this.resourceLabel=e,this.reason=t}}class Di{constructor(){this.elements=new Map}createMessage(){const e=[],t=[];for(const[,i]of this.elements)(0===i.reason?e:t).push(i.resourceLabel);let i=[];return e.length>0&&i.push(vi.NC("vs/platform/undoRedo/common/undoRedoService",{key:"externalRemoval",comment:["{0} is a list of filenames"]},"The following files have been closed and modified on disk: {0}.",e.join(", "))),t.length>0&&i.push(vi.NC("vs/platform/undoRedo/common/undoRedoService",{key:"noParallelUniverses",comment:["{0} is a list of filenames"]},"The following files have been modified in an incompatible way: {0}.",t.join(", "))),i.join("\n")}get size(){return this.elements.size}has(e){return this.elements.has(e)}set(e,t){this.elements.set(e,t)}delete(e){return this.elements.delete(e)}}class Ii{constructor(e,t,i,n,o,r,s){this.id=++Li,this.type=1,this.actual=e,this.label=e.label,this.confirmBeforeUndo=e.confirmBeforeUndo||!1,this.resourceLabels=t,this.strResources=i,this.groupId=n,this.groupOrder=o,this.sourceId=r,this.sourceOrder=s,this.removedResources=null,this.invalidatedResources=null}canSplit(){return"function"==typeof this.actual.split}removeResource(e,t,i){this.removedResources||(this.removedResources=new Di),this.removedResources.has(t)||this.removedResources.set(t,new Ni(e,i))}setValid(e,t,i){i?this.invalidatedResources&&(this.invalidatedResources.delete(t),0===this.invalidatedResources.size&&(this.invalidatedResources=null)):(this.invalidatedResources||(this.invalidatedResources=new Di),this.invalidatedResources.has(t)||this.invalidatedResources.set(t,new Ni(e,0)))}toString(){return`[id:${this.id}] [group:${this.groupId}] [${this.invalidatedResources?"INVALID":" VALID"}] ${this.actual.constructor.name} - ${this.actual}`}}class Ti{constructor(e,t){this.resourceLabel=e,this.strResource=t,this._past=[],this._future=[],this.locked=!1,this.versionId=1}dispose(){for(const e of this._past)1===e.type&&e.removeResource(this.resourceLabel,this.strResource,0);for(const e of this._future)1===e.type&&e.removeResource(this.resourceLabel,this.strResource,0);this.versionId++}toString(){let e=[];e.push(`* ${this.strResource}:`);for(let t=0;t=0;t--)e.push(` * [REDO] ${this._future[t]}`);return e.join("\n")}flushAllElements(){this._past=[],this._future=[],this.versionId++}_setElementValidFlag(e,t){1===e.type?e.setValid(this.resourceLabel,this.strResource,t):e.setValid(t)}setElementsValidFlag(e,t){for(const i of this._past)t(i.actual)&&this._setElementValidFlag(i,e);for(const i of this._future)t(i.actual)&&this._setElementValidFlag(i,e)}pushElement(e){for(const e of this._future)1===e.type&&e.removeResource(this.resourceLabel,this.strResource,1);this._future=[],this._past.push(e),this.versionId++}createSnapshot(e){const t=[];for(let e=0,i=this._past.length;e=0;e--)t.push(this._future[e].id);return new yi.YO(e,t)}restoreSnapshot(e){const t=e.elements.length;let i=!0,n=0,o=-1;for(let r=0,s=this._past.length;r=t||s.id!==e.elements[n])&&(i=!1,o=0),i||1!==s.type||s.removeResource(this.resourceLabel,this.strResource,0)}let r=-1;for(let o=this._future.length-1;o>=0;o--,n++){const s=this._future[o];i&&(n>=t||s.id!==e.elements[n])&&(i=!1,r=o),i||1!==s.type||s.removeResource(this.resourceLabel,this.strResource,0)}-1!==o&&(this._past=this._past.slice(0,o)),-1!==r&&(this._future=this._future.slice(r+1)),this.versionId++}getElements(){const e=[],t=[];for(const t of this._past)e.push(t.actual);for(const e of this._future)t.push(e.actual);return{past:e,future:t}}getClosestPastElement(){return 0===this._past.length?null:this._past[this._past.length-1]}getSecondClosestPastElement(){return this._past.length<2?null:this._past[this._past.length-2]}getClosestFutureElement(){return 0===this._future.length?null:this._future[this._future.length-1]}hasPastElements(){return this._past.length>0}hasFutureElements(){return this._future.length>0}splitPastWorkspaceElement(e,t){for(let i=this._past.length-1;i>=0;i--)if(this._past[i]===e){t.has(this.strResource)?this._past[i]=t.get(this.strResource):this._past.splice(i,1);break}this.versionId++}splitFutureWorkspaceElement(e,t){for(let i=this._future.length-1;i>=0;i--)if(this._future[i]===e){t.has(this.strResource)?this._future[i]=t.get(this.strResource):this._future.splice(i,1);break}this.versionId++}moveBackward(e){this._past.pop(),this._future.push(e),this.versionId++}moveForward(e){this._future.pop(),this._past.push(e),this.versionId++}}class Ai{constructor(e){this.editStacks=e,this._versionIds=[];for(let e=0,t=this.editStacks.length;et.sourceOrder)&&(t=r,i=n)}return[t,i]}canUndo(e){if(e instanceof yi.gJ){const[,t]=this._findClosestUndoElementWithSource(e.id);return!!t}const t=this.getUriComparisonKey(e);return!!this._editStacks.has(t)&&this._editStacks.get(t).hasPastElements()}_onError(e,t){(0,xe.dL)(e);for(const e of t.strResources)this.removeElements(e);this._notificationService.error(e)}_acquireLocks(e){for(const t of e.editStacks)if(t.locked)throw new Error("Cannot acquire edit stack lock");for(const t of e.editStacks)t.locked=!0;return()=>{for(const t of e.editStacks)t.locked=!1}}_safeInvokeWithLocks(e,t,i,n,o){const r=this._acquireLocks(i);let s;try{s=t()}catch(t){return r(),n.dispose(),this._onError(t,e)}return s?s.then((()=>(r(),n.dispose(),o())),(t=>(r(),n.dispose(),this._onError(t,e)))):(r(),n.dispose(),o())}_invokeWorkspacePrepare(e){return xi(this,void 0,void 0,(function*(){if(void 0===e.actual.prepareUndoRedo)return Se.JT.None;const t=e.actual.prepareUndoRedo();return void 0===t?Se.JT.None:t}))}_invokeResourcePrepare(e,t){if(1!==e.actual.type||void 0===e.actual.prepareUndoRedo)return t(Se.JT.None);const i=e.actual.prepareUndoRedo();return i?(0,Se.Wf)(i)?t(i):i.then((e=>t(e))):t(Se.JT.None)}_getAffectedEditStacks(e){const t=[];for(const i of e.strResources)t.push(this._editStacks.get(i)||Ri);return new Ai(t)}_tryToSplitAndUndo(e,t,i,n){if(t.canSplit())return this._splitPastWorkspaceElement(t,i),this._notificationService.warn(n),new Oi(this._undo(e,0,!0));for(const e of t.strResources)this.removeElements(e);return this._notificationService.warn(n),new Oi}_checkWorkspaceUndo(e,t,i,n){if(t.removedResources)return this._tryToSplitAndUndo(e,t,t.removedResources,vi.NC("vs/platform/undoRedo/common/undoRedoService",{key:"cannotWorkspaceUndo",comment:["{0} is a label for an operation. {1} is another message."]},"Could not undo '{0}' across all files. {1}",t.label,t.removedResources.createMessage()));if(n&&t.invalidatedResources)return this._tryToSplitAndUndo(e,t,t.invalidatedResources,vi.NC("vs/platform/undoRedo/common/undoRedoService",{key:"cannotWorkspaceUndo",comment:["{0} is a label for an operation. {1} is another message."]},"Could not undo '{0}' across all files. {1}",t.label,t.invalidatedResources.createMessage()));const o=[];for(const e of i.editStacks)e.getClosestPastElement()!==t&&o.push(e.resourceLabel);if(o.length>0)return this._tryToSplitAndUndo(e,t,null,vi.NC("vs/platform/undoRedo/common/undoRedoService",{key:"cannotWorkspaceUndoDueToChanges",comment:["{0} is a label for an operation. {1} is a list of filenames."]},"Could not undo '{0}' across all files because changes were made to {1}",t.label,o.join(", ")));const r=[];for(const e of i.editStacks)e.locked&&r.push(e.resourceLabel);return r.length>0?this._tryToSplitAndUndo(e,t,null,vi.NC("vs/platform/undoRedo/common/undoRedoService",{key:"cannotWorkspaceUndoDueToInProgressUndoRedo",comment:["{0} is a label for an operation. {1} is a list of filenames."]},"Could not undo '{0}' across all files because there is already an undo or redo operation running on {1}",t.label,r.join(", "))):i.isValid()?null:this._tryToSplitAndUndo(e,t,null,vi.NC("vs/platform/undoRedo/common/undoRedoService",{key:"cannotWorkspaceUndoDueToInMeantimeUndoRedo",comment:["{0} is a label for an operation. {1} is a list of filenames."]},"Could not undo '{0}' across all files because an undo or redo operation occurred in the meantime",t.label))}_workspaceUndo(e,t,i){const n=this._getAffectedEditStacks(t),o=this._checkWorkspaceUndo(e,t,n,!1);return o?o.returnValue:this._confirmAndExecuteWorkspaceUndo(e,t,n,i)}_isPartOfUndoGroup(e){if(!e.groupId)return!1;for(const[,t]of this._editStacks){const i=t.getClosestPastElement();if(i){if(i===e){const i=t.getSecondClosestPastElement();if(i&&i.groupId===e.groupId)return!0}if(i.groupId===e.groupId)return!0}}return!1}_confirmAndExecuteWorkspaceUndo(e,t,i,n){return xi(this,void 0,void 0,(function*(){if(t.canSplit()&&!this._isPartOfUndoGroup(t)){const o=yield this._dialogService.show(bi.Z.Info,vi.NC("vs/platform/undoRedo/common/undoRedoService","confirmWorkspace","Would you like to undo '{0}' across all files?",t.label),[vi.NC("vs/platform/undoRedo/common/undoRedoService",{key:"ok",comment:["{0} denotes a number that is > 1"]},"Undo in {0} Files",i.editStacks.length),vi.NC("vs/platform/undoRedo/common/undoRedoService","nok","Undo this File"),vi.NC("vs/platform/undoRedo/common/undoRedoService","cancel","Cancel")],{cancelId:2});if(2===o.choice)return;if(1===o.choice)return this._splitPastWorkspaceElement(t,null),this._undo(e,0,!0);const r=this._checkWorkspaceUndo(e,t,i,!1);if(r)return r.returnValue;n=!0}let o;try{o=yield this._invokeWorkspacePrepare(t)}catch(e){return this._onError(e,t)}const r=this._checkWorkspaceUndo(e,t,i,!0);if(r)return o.dispose(),r.returnValue;for(const e of i.editStacks)e.moveBackward(t);return this._safeInvokeWithLocks(t,(()=>t.actual.undo()),i,o,(()=>this._continueUndoInGroup(t.groupId,n)))}))}_resourceUndo(e,t,i){if(t.isValid){if(!e.locked)return this._invokeResourcePrepare(t,(n=>(e.moveBackward(t),this._safeInvokeWithLocks(t,(()=>t.actual.undo()),new Ai([e]),n,(()=>this._continueUndoInGroup(t.groupId,i))))));{const e=vi.NC("vs/platform/undoRedo/common/undoRedoService",{key:"cannotResourceUndoDueToInProgressUndoRedo",comment:["{0} is a label for an operation."]},"Could not undo '{0}' because there is already an undo or redo operation running.",t.label);this._notificationService.warn(e)}}else e.flushAllElements()}_findClosestUndoElementInGroup(e){if(!e)return[null,null];let t=null,i=null;for(const[n,o]of this._editStacks){const r=o.getClosestPastElement();r&&r.groupId===e&&(!t||r.groupOrder>t.groupOrder)&&(t=r,i=n)}return[t,i]}_continueUndoInGroup(e,t){if(!e)return;const[,i]=this._findClosestUndoElementInGroup(e);return i?this._undo(i,0,t):void 0}undo(e){if(e instanceof yi.gJ){const[,t]=this._findClosestUndoElementWithSource(e.id);return t?this._undo(t,e.id,!1):void 0}return"string"==typeof e?this._undo(e,0,!1):this._undo(this.getUriComparisonKey(e),0,!1)}_undo(e,t=0,i){if(!this._editStacks.has(e))return;const n=this._editStacks.get(e),o=n.getClosestPastElement();if(o){if(o.groupId){const[e,n]=this._findClosestUndoElementInGroup(o.groupId);if(o!==e&&n)return this._undo(n,t,i)}if((o.sourceId!==t||o.confirmBeforeUndo)&&!i)return this._confirmAndContinueUndo(e,t,o);try{return 1===o.type?this._workspaceUndo(e,o,i):this._resourceUndo(n,o,i)}finally{}}}_confirmAndContinueUndo(e,t,i){return xi(this,void 0,void 0,(function*(){if(1!==(yield this._dialogService.show(bi.Z.Info,vi.NC("vs/platform/undoRedo/common/undoRedoService","confirmDifferentSource","Would you like to undo '{0}'?",i.label),[vi.NC("vs/platform/undoRedo/common/undoRedoService","confirmDifferentSource.yes","Yes"),vi.NC("vs/platform/undoRedo/common/undoRedoService","confirmDifferentSource.no","No")],{cancelId:1})).choice)return this._undo(e,t,!0)}))}_findClosestRedoElementWithSource(e){if(!e)return[null,null];let t=null,i=null;for(const[n,o]of this._editStacks){const r=o.getClosestFutureElement();r&&r.sourceId===e&&(!t||r.sourceOrder0)return this._tryToSplitAndRedo(e,t,null,vi.NC("vs/platform/undoRedo/common/undoRedoService",{key:"cannotWorkspaceRedoDueToChanges",comment:["{0} is a label for an operation. {1} is a list of filenames."]},"Could not redo '{0}' across all files because changes were made to {1}",t.label,o.join(", ")));const r=[];for(const e of i.editStacks)e.locked&&r.push(e.resourceLabel);return r.length>0?this._tryToSplitAndRedo(e,t,null,vi.NC("vs/platform/undoRedo/common/undoRedoService",{key:"cannotWorkspaceRedoDueToInProgressUndoRedo",comment:["{0} is a label for an operation. {1} is a list of filenames."]},"Could not redo '{0}' across all files because there is already an undo or redo operation running on {1}",t.label,r.join(", "))):i.isValid()?null:this._tryToSplitAndRedo(e,t,null,vi.NC("vs/platform/undoRedo/common/undoRedoService",{key:"cannotWorkspaceRedoDueToInMeantimeUndoRedo",comment:["{0} is a label for an operation. {1} is a list of filenames."]},"Could not redo '{0}' across all files because an undo or redo operation occurred in the meantime",t.label))}_workspaceRedo(e,t){const i=this._getAffectedEditStacks(t),n=this._checkWorkspaceRedo(e,t,i,!1);return n?n.returnValue:this._executeWorkspaceRedo(e,t,i)}_executeWorkspaceRedo(e,t,i){return xi(this,void 0,void 0,(function*(){let n;try{n=yield this._invokeWorkspacePrepare(t)}catch(e){return this._onError(e,t)}const o=this._checkWorkspaceRedo(e,t,i,!0);if(o)return n.dispose(),o.returnValue;for(const e of i.editStacks)e.moveForward(t);return this._safeInvokeWithLocks(t,(()=>t.actual.redo()),i,n,(()=>this._continueRedoInGroup(t.groupId)))}))}_resourceRedo(e,t){if(t.isValid){if(!e.locked)return this._invokeResourcePrepare(t,(i=>(e.moveForward(t),this._safeInvokeWithLocks(t,(()=>t.actual.redo()),new Ai([e]),i,(()=>this._continueRedoInGroup(t.groupId))))));{const e=vi.NC("vs/platform/undoRedo/common/undoRedoService",{key:"cannotResourceRedoDueToInProgressUndoRedo",comment:["{0} is a label for an operation."]},"Could not redo '{0}' because there is already an undo or redo operation running.",t.label);this._notificationService.warn(e)}}else e.flushAllElements()}_findClosestRedoElementInGroup(e){if(!e)return[null,null];let t=null,i=null;for(const[n,o]of this._editStacks){const r=o.getClosestFutureElement();r&&r.groupId===e&&(!t||r.groupOrder=0;a--)(o=e[a])&&(s=(r<3?o(s):r>3?o(t,i,s):o(t,i))||s);return r>3&&s&&Object.defineProperty(t,i,s),s}([Si(0,Ci.S),Si(1,wi.lT)],Mi);class Oi{constructor(e){this.returnValue=e}}(0,ci.z)(yi.tJ,Mi),i(30021);var Pi=i(33200),Fi=i(99410),Bi=i(86789),Wi=i(70105),Vi=i(97618),Hi=i(73403);const zi=Object.freeze({id:"editor",order:5,type:"object",title:vi.NC("vs/editor/common/config/editorConfigurationSchema","editorConfigurationTitle","Editor"),scope:5}),$i=Object.assign(Object.assign({},zi),{properties:{"editor.tabSize":{type:"number",default:Wi.D.tabSize,minimum:1,markdownDescription:vi.NC("vs/editor/common/config/editorConfigurationSchema","tabSize","The number of spaces a tab is equal to. This setting is overridden based on the file contents when `#editor.detectIndentation#` is on.")},"editor.insertSpaces":{type:"boolean",default:Wi.D.insertSpaces,markdownDescription:vi.NC("vs/editor/common/config/editorConfigurationSchema","insertSpaces","Insert spaces when pressing `Tab`. This setting is overridden based on the file contents when `#editor.detectIndentation#` is on.")},"editor.detectIndentation":{type:"boolean",default:Wi.D.detectIndentation,markdownDescription:vi.NC("vs/editor/common/config/editorConfigurationSchema","detectIndentation","Controls whether `#editor.tabSize#` and `#editor.insertSpaces#` will be automatically detected when a file is opened based on the file contents.")},"editor.trimAutoWhitespace":{type:"boolean",default:Wi.D.trimAutoWhitespace,description:vi.NC("vs/editor/common/config/editorConfigurationSchema","trimAutoWhitespace","Remove trailing auto inserted whitespace.")},"editor.largeFileOptimizations":{type:"boolean",default:Wi.D.largeFileOptimizations,description:vi.NC("vs/editor/common/config/editorConfigurationSchema","largeFileOptimizations","Special handling for large files to disable certain memory intensive features.")},"editor.wordBasedSuggestions":{type:"boolean",default:!0,description:vi.NC("vs/editor/common/config/editorConfigurationSchema","wordBasedSuggestions","Controls whether completions should be computed based on words in the document.")},"editor.wordBasedSuggestionsMode":{enum:["currentDocument","matchingDocuments","allDocuments"],default:"matchingDocuments",enumDescriptions:[vi.NC("vs/editor/common/config/editorConfigurationSchema","wordBasedSuggestionsMode.currentDocument","Only suggest words from the active document."),vi.NC("vs/editor/common/config/editorConfigurationSchema","wordBasedSuggestionsMode.matchingDocuments","Suggest words from all open documents of the same language."),vi.NC("vs/editor/common/config/editorConfigurationSchema","wordBasedSuggestionsMode.allDocuments","Suggest words from all open documents.")],description:vi.NC("vs/editor/common/config/editorConfigurationSchema","wordBasedSuggestionsMode","Controls from which documents word based completions are computed.")},"editor.semanticHighlighting.enabled":{enum:[!0,!1,"configuredByTheme"],enumDescriptions:[vi.NC("vs/editor/common/config/editorConfigurationSchema","semanticHighlighting.true","Semantic highlighting enabled for all color themes."),vi.NC("vs/editor/common/config/editorConfigurationSchema","semanticHighlighting.false","Semantic highlighting disabled for all color themes."),vi.NC("vs/editor/common/config/editorConfigurationSchema","semanticHighlighting.configuredByTheme","Semantic highlighting is configured by the current color theme's `semanticHighlighting` setting.")],default:"configuredByTheme",description:vi.NC("vs/editor/common/config/editorConfigurationSchema","semanticHighlighting.enabled","Controls whether the semanticHighlighting is shown for the languages that support it.")},"editor.stablePeek":{type:"boolean",default:!1,markdownDescription:vi.NC("vs/editor/common/config/editorConfigurationSchema","stablePeek","Keep peek editors open even when double clicking their content or when hitting `Escape`.")},"editor.maxTokenizationLineLength":{type:"integer",default:2e4,description:vi.NC("vs/editor/common/config/editorConfigurationSchema","maxTokenizationLineLength","Lines above this length will not be tokenized for performance reasons")},"editor.language.brackets":{type:"array",default:!1,description:vi.NC("vs/editor/common/config/editorConfigurationSchema","schema.brackets","Defines the bracket symbols that increase or decrease the indentation."),items:{type:"array",items:[{type:"string",description:vi.NC("vs/editor/common/config/editorConfigurationSchema","schema.openBracket","The opening bracket character or string sequence.")},{type:"string",description:vi.NC("vs/editor/common/config/editorConfigurationSchema","schema.closeBracket","The closing bracket character or string sequence.")}]}},"editor.language.colorizedBracketPairs":{type:"array",default:!1,description:vi.NC("vs/editor/common/config/editorConfigurationSchema","schema.colorizedBracketPairs","Defines the bracket pairs that are colorized by their nesting level if bracket pair colorization is enabled."),items:{type:"array",items:[{type:"string",description:vi.NC("vs/editor/common/config/editorConfigurationSchema","schema.openBracket","The opening bracket character or string sequence.")},{type:"string",description:vi.NC("vs/editor/common/config/editorConfigurationSchema","schema.closeBracket","The closing bracket character or string sequence.")}]}},"diffEditor.maxComputationTime":{type:"number",default:5e3,description:vi.NC("vs/editor/common/config/editorConfigurationSchema","maxComputationTime","Timeout in milliseconds after which diff computation is cancelled. Use 0 for no timeout.")},"diffEditor.maxFileSize":{type:"number",default:50,description:vi.NC("vs/editor/common/config/editorConfigurationSchema","maxFileSize","Maximum file size in MB for which to compute diffs. Use 0 for no limit.")},"diffEditor.renderSideBySide":{type:"boolean",default:!0,description:vi.NC("vs/editor/common/config/editorConfigurationSchema","sideBySide","Controls whether the diff editor shows the diff side by side or inline.")},"diffEditor.ignoreTrimWhitespace":{type:"boolean",default:!0,description:vi.NC("vs/editor/common/config/editorConfigurationSchema","ignoreTrimWhitespace","When enabled, the diff editor ignores changes in leading or trailing whitespace.")},"diffEditor.renderIndicators":{type:"boolean",default:!0,description:vi.NC("vs/editor/common/config/editorConfigurationSchema","renderIndicators","Controls whether the diff editor shows +/- indicators for added/removed changes.")},"diffEditor.codeLens":{type:"boolean",default:!1,description:vi.NC("vs/editor/common/config/editorConfigurationSchema","codeLens","Controls whether the editor shows CodeLens.")},"diffEditor.wordWrap":{type:"string",enum:["off","on","inherit"],default:"inherit",markdownEnumDescriptions:[vi.NC("vs/editor/common/config/editorConfigurationSchema","wordWrap.off","Lines will never wrap."),vi.NC("vs/editor/common/config/editorConfigurationSchema","wordWrap.on","Lines will wrap at the viewport width."),vi.NC("vs/editor/common/config/editorConfigurationSchema","wordWrap.inherit","Lines will wrap according to the `#editor.wordWrap#` setting.")]}}});for(const e of V.Bc){const t=e.schema;if(void 0!==t)if(void 0!==(Ui=t).type||void 0!==Ui.anyOf)$i.properties[`editor.${e.name}`]=t;else for(const e in t)Object.hasOwnProperty.call(t,e)&&($i.properties[e]=t[e])}var Ui;let ji=null;function Ki(){return null===ji&&(ji=Object.create(null),Object.keys($i.properties).forEach((e=>{ji[e]=!0}))),ji}Hi.B.as(Vi.IP.Configuration).registerConfiguration($i);var qi=i(92382),Gi=i(20010),Zi=i(14756),Yi=i(40539),Qi=i(38455),Xi=i(90584);class Ji{constructor(e={},t=[],i=[]){this._contents=e,this._keys=t,this._overrides=i,this.isFrozen=!1,this.overrideConfigurations=new Map}get contents(){return this.checkAndFreeze(this._contents)}get overrides(){return this.checkAndFreeze(this._overrides)}get keys(){return this.checkAndFreeze(this._keys)}isEmpty(){return 0===this._keys.length&&0===Object.keys(this._contents).length&&0===this._overrides.length}getValue(e){return e?(0,Yi.Mt)(this.contents,e):this.contents}getOverrideValue(e,t){const i=this.getContentsForOverrideIdentifer(t);return i?e?(0,Yi.Mt)(i,e):i:void 0}override(e){let t=this.overrideConfigurations.get(e);return t||(t=this.createOverrideConfigurationModel(e),this.overrideConfigurations.set(e,t)),t}merge(...e){const t=Xi.I8(this.contents),i=Xi.I8(this.overrides),n=[...this.keys];for(const o of e){this.mergeContents(t,o.contents);for(const e of o.overrides){const[t]=i.filter((t=>gt.fS(t.identifiers,e.identifiers)));t?(this.mergeContents(t.contents,e.contents),t.keys.push(...e.keys),t.keys=gt.EB(t.keys)):i.push(Xi.I8(e))}for(const e of o.keys)-1===n.indexOf(e)&&n.push(e)}return new Ji(t,n,i)}freeze(){return this.isFrozen=!0,this}createOverrideConfigurationModel(e){const t=this.getContentsForOverrideIdentifer(e);if(!t||"object"!=typeof t||!Object.keys(t).length)return this;let i={};for(const e of gt.EB([...Object.keys(this.contents),...Object.keys(t)])){let n=this.contents[e],o=t[e];o&&("object"==typeof n&&"object"==typeof o?(n=Xi.I8(n),this.mergeContents(n,o)):n=o),i[e]=n}return new Ji(i,this.keys,this.overrides)}mergeContents(e,t){for(const i of Object.keys(t))i in e&&Le.Kn(e[i])&&Le.Kn(t[i])?this.mergeContents(e[i],t[i]):e[i]=Xi.I8(t[i])}checkAndFreeze(e){return this.isFrozen&&!Object.isFrozen(e)?Xi._A(e):e}getContentsForOverrideIdentifer(e){let t=null,i=null;const n=e=>{e&&(i?this.mergeContents(i,e):i=Xi.I8(e))};for(const i of this.overrides)gt.fS(i.identifiers,[e])?t=i.contents:i.identifiers.includes(e)&&n(i.contents);return n(t),i}toJSON(){return{contents:this.contents,overrides:this.overrides,keys:this.keys}}setValue(e,t){this.addKey(e),(0,Yi.KV)(this.contents,e,t,(e=>{throw new Error(e)}))}removeValue(e){this.removeKey(e)&&(0,Yi.xL)(this.contents,e)}addKey(e){let t=this.keys.length;for(let i=0;iconsole.error(`Conflict in default settings: ${e}`)))}for(const e of Object.keys(n))Vi.eU.test(e)&&o.push({identifiers:(0,Vi.ny)(e),keys:Object.keys(n[e]),contents:(0,Yi.Od)(n[e],(e=>console.error(`Conflict in default settings file: ${e}`)))});super(n,i,o)}}class tn{constructor(e,t,i=new Ji,n=new Ji,o=new Qi.Y9,r=new Ji,s=new Qi.Y9,a=!0){this._defaultConfiguration=e,this._localUserConfiguration=t,this._remoteUserConfiguration=i,this._workspaceConfiguration=n,this._folderConfigurations=o,this._memoryConfiguration=r,this._memoryConfigurationByResource=s,this._freeze=a,this._workspaceConsolidatedConfiguration=null,this._foldersConsolidatedConfigurations=new Qi.Y9,this._userConfiguration=null}getValue(e,t,i){return this.getConsolidateConfigurationModel(t,i).getValue(e)}updateValue(e,t,i={}){let n;i.resource?(n=this._memoryConfigurationByResource.get(i.resource),n||(n=new Ji,this._memoryConfigurationByResource.set(i.resource,n))):n=this._memoryConfiguration,void 0===t?n.removeValue(e):n.setValue(e,t),i.resource||(this._workspaceConsolidatedConfiguration=null)}inspect(e,t,i){const n=this.getConsolidateConfigurationModel(t,i),o=this.getFolderConfigurationModelForResource(t.resource,i),r=t.resource&&this._memoryConfigurationByResource.get(t.resource)||this._memoryConfiguration,s=t.overrideIdentifier?this._defaultConfiguration.freeze().override(t.overrideIdentifier).getValue(e):this._defaultConfiguration.freeze().getValue(e),a=t.overrideIdentifier?this.userConfiguration.freeze().override(t.overrideIdentifier).getValue(e):this.userConfiguration.freeze().getValue(e),l=t.overrideIdentifier?this.localUserConfiguration.freeze().override(t.overrideIdentifier).getValue(e):this.localUserConfiguration.freeze().getValue(e),c=t.overrideIdentifier?this.remoteUserConfiguration.freeze().override(t.overrideIdentifier).getValue(e):this.remoteUserConfiguration.freeze().getValue(e),d=i?t.overrideIdentifier?this._workspaceConfiguration.freeze().override(t.overrideIdentifier).getValue(e):this._workspaceConfiguration.freeze().getValue(e):void 0,u=o?t.overrideIdentifier?o.freeze().override(t.overrideIdentifier).getValue(e):o.freeze().getValue(e):void 0,h=t.overrideIdentifier?r.override(t.overrideIdentifier).getValue(e):r.getValue(e),g=n.getValue(e),p=gt.EB(gt.xH(n.overrides.map((e=>e.identifiers)))).filter((t=>void 0!==n.getOverrideValue(e,t)));return{defaultValue:s,userValue:a,userLocalValue:l,userRemoteValue:c,workspaceValue:d,workspaceFolderValue:u,memoryValue:h,value:g,default:void 0!==s?{value:this._defaultConfiguration.freeze().getValue(e),override:t.overrideIdentifier?this._defaultConfiguration.freeze().getOverrideValue(e,t.overrideIdentifier):void 0}:void 0,user:void 0!==a?{value:this.userConfiguration.freeze().getValue(e),override:t.overrideIdentifier?this.userConfiguration.freeze().getOverrideValue(e,t.overrideIdentifier):void 0}:void 0,userLocal:void 0!==l?{value:this.localUserConfiguration.freeze().getValue(e),override:t.overrideIdentifier?this.localUserConfiguration.freeze().getOverrideValue(e,t.overrideIdentifier):void 0}:void 0,userRemote:void 0!==c?{value:this.remoteUserConfiguration.freeze().getValue(e),override:t.overrideIdentifier?this.remoteUserConfiguration.freeze().getOverrideValue(e,t.overrideIdentifier):void 0}:void 0,workspace:void 0!==d?{value:this._workspaceConfiguration.freeze().getValue(e),override:t.overrideIdentifier?this._workspaceConfiguration.freeze().getOverrideValue(e,t.overrideIdentifier):void 0}:void 0,workspaceFolder:void 0!==u?{value:null==o?void 0:o.freeze().getValue(e),override:t.overrideIdentifier?null==o?void 0:o.freeze().getOverrideValue(e,t.overrideIdentifier):void 0}:void 0,memory:void 0!==h?{value:r.getValue(e),override:t.overrideIdentifier?r.getOverrideValue(e,t.overrideIdentifier):void 0}:void 0,overrideIdentifiers:p.length?p:void 0}}get userConfiguration(){return this._userConfiguration||(this._userConfiguration=this._remoteUserConfiguration.isEmpty()?this._localUserConfiguration:this._localUserConfiguration.merge(this._remoteUserConfiguration),this._freeze&&this._userConfiguration.freeze()),this._userConfiguration}get localUserConfiguration(){return this._localUserConfiguration}get remoteUserConfiguration(){return this._remoteUserConfiguration}getConsolidateConfigurationModel(e,t){let i=this.getConsolidatedConfigurationModelForResource(e,t);return e.overrideIdentifier?i.override(e.overrideIdentifier):i}getConsolidatedConfigurationModelForResource({resource:e},t){let i=this.getWorkspaceConsolidatedConfiguration();if(t&&e){const n=t.getFolder(e);n&&(i=this.getFolderConsolidatedConfiguration(n.uri)||i);const o=this._memoryConfigurationByResource.get(e);o&&(i=i.merge(o))}return i}getWorkspaceConsolidatedConfiguration(){return this._workspaceConsolidatedConfiguration||(this._workspaceConsolidatedConfiguration=this._defaultConfiguration.merge(this.userConfiguration,this._workspaceConfiguration,this._memoryConfiguration),this._freeze&&(this._workspaceConfiguration=this._workspaceConfiguration.freeze())),this._workspaceConsolidatedConfiguration}getFolderConsolidatedConfiguration(e){let t=this._foldersConsolidatedConfigurations.get(e);if(!t){const i=this.getWorkspaceConsolidatedConfiguration(),n=this._folderConfigurations.get(e);n?(t=i.merge(n),this._freeze&&(t=t.freeze()),this._foldersConsolidatedConfigurations.set(e,t)):t=i}return t}getFolderConfigurationModelForResource(e,t){if(t&&e){const i=t.getFolder(e);if(i)return this._folderConfigurations.get(i.uri)}}toData(){return{defaults:{contents:this._defaultConfiguration.contents,overrides:this._defaultConfiguration.overrides,keys:this._defaultConfiguration.keys},user:{contents:this.userConfiguration.contents,overrides:this.userConfiguration.overrides,keys:this.userConfiguration.keys},workspace:{contents:this._workspaceConfiguration.contents,overrides:this._workspaceConfiguration.overrides,keys:this._workspaceConfiguration.keys},folders:[...this._folderConfigurations.keys()].reduce(((e,t)=>{const{contents:i,overrides:n,keys:o}=this._folderConfigurations.get(t);return e.push([t,{contents:i,overrides:n,keys:o}]),e}),[])}}static parse(e){const t=this.parseConfigurationModel(e.defaults),i=this.parseConfigurationModel(e.user),n=this.parseConfigurationModel(e.workspace),o=e.folders.reduce(((e,t)=>(e.set(U.o.revive(t[0]),this.parseConfigurationModel(t[1])),e)),new Qi.Y9);return new tn(t,i,new Ji,n,o,new Ji,new Qi.Y9,!1)}static parseConfigurationModel(e){return new Ji(e.contents,e.keys,e.overrides).freeze()}}class nn{constructor(e,t,i,n){this.change=e,this.previous=t,this.currentConfiguraiton=i,this.currentWorkspace=n,this._previousConfiguration=void 0;const o=new Set;e.keys.forEach((e=>o.add(e))),e.overrides.forEach((([,e])=>e.forEach((e=>o.add(e))))),this.affectedKeys=[...o.values()];const r=new Ji;this.affectedKeys.forEach((e=>r.setValue(e,{}))),this.affectedKeysTree=r.contents}get previousConfiguration(){return!this._previousConfiguration&&this.previous&&(this._previousConfiguration=tn.parse(this.previous.data)),this._previousConfiguration}affectsConfiguration(e,t){var i;if(this.doesAffectedKeysTreeContains(this.affectedKeysTree,e)){if(t){const n=this.previousConfiguration?this.previousConfiguration.getValue(e,t,null===(i=this.previous)||void 0===i?void 0:i.workspace):void 0,o=this.currentConfiguraiton.getValue(e,t,this.currentWorkspace);return!Xi.fS(n,o)}return!0}return!1}doesAffectedKeysTreeContains(e,t){let i,n=(0,Yi.Od)({[t]:!0},(()=>{}));for(;"object"==typeof n&&(i=Object.keys(n)[0]);){if(!(e=e[i]))return!1;n=n[i]}return!0}}const on=/^(cursor|delete)/;class rn extends Se.JT{constructor(e,t,i,n,o){super(),this._contextKeyService=e,this._commandService=t,this._telemetryService=i,this._notificationService=n,this._logService=o,this._onDidUpdateKeybindings=this._register(new z.Q5),this._currentChord=null,this._currentChordChecker=new ye.zh,this._currentChordStatusMessage=null,this._ignoreSingleModifiers=sn.EMPTY,this._currentSingleModifier=null,this._currentSingleModifierClearTimeout=new ye._F,this._logging=!1}get onDidUpdateKeybindings(){return this._onDidUpdateKeybindings?this._onDidUpdateKeybindings.event:z.ju.None}dispose(){super.dispose()}_log(e){this._logging&&this._logService.info(`[KeybindingService]: ${e}`)}getKeybindings(){return this._getResolver().getKeybindings()}lookupKeybinding(e,t){const i=this._getResolver().lookupPrimaryKeybinding(e,t||this._contextKeyService);if(i)return i.resolvedKeybinding}dispatchEvent(e,t){return this._dispatch(e,t)}softDispatch(e,t){const i=this.resolveKeyboardEvent(e);if(i.isChord())return console.warn("Unexpected keyboard event mapped to a chord"),null;const[n]=i.getDispatchParts();if(null===n)return null;const o=this._contextKeyService.getContext(t),r=this._currentChord?this._currentChord.keypress:null;return this._getResolver().resolve(o,r,n)}_enterChordMode(e,t){this._currentChord={keypress:e,label:t},this._currentChordStatusMessage=this._notificationService.status(vi.NC("vs/platform/keybinding/common/abstractKeybindingService","first.chord","({0}) was pressed. Waiting for second key of chord...",t));const i=Date.now();this._currentChordChecker.cancelAndSet((()=>{this._documentHasFocus()?Date.now()-i>5e3&&this._leaveChordMode():this._leaveChordMode()}),500)}_leaveChordMode(){this._currentChordStatusMessage&&(this._currentChordStatusMessage.dispose(),this._currentChordStatusMessage=null),this._currentChordChecker.cancel(),this._currentChord=null}_dispatch(e,t){return this._doDispatch(this.resolveKeyboardEvent(e),t,!1)}_singleModifierDispatch(e,t){const i=this.resolveKeyboardEvent(e),[n]=i.getSingleModifierDispatchParts();if(n)return this._ignoreSingleModifiers.has(n)?(this._log(`+ Ignoring single modifier ${n} due to it being pressed together with other keys.`),this._ignoreSingleModifiers=sn.EMPTY,this._currentSingleModifierClearTimeout.cancel(),this._currentSingleModifier=null,!1):(this._ignoreSingleModifiers=sn.EMPTY,null===this._currentSingleModifier?(this._log(`+ Storing single modifier for possible chord ${n}.`),this._currentSingleModifier=n,this._currentSingleModifierClearTimeout.cancelAndSet((()=>{this._log("+ Clearing single modifier due to 300ms elapsed."),this._currentSingleModifier=null}),300),!1):n===this._currentSingleModifier?(this._log(`/ Dispatching single modifier chord ${n} ${n}`),this._currentSingleModifierClearTimeout.cancel(),this._currentSingleModifier=null,this._doDispatch(i,t,!0)):(this._log(`+ Clearing single modifier due to modifier mismatch: ${this._currentSingleModifier} ${n}`),this._currentSingleModifierClearTimeout.cancel(),this._currentSingleModifier=null,!1));const[o]=i.getParts();return this._ignoreSingleModifiers=new sn(o),null!==this._currentSingleModifier&&this._log("+ Clearing single modifier due to other key up."),this._currentSingleModifierClearTimeout.cancel(),this._currentSingleModifier=null,!1}_doDispatch(e,t,i=!1){let n=!1;if(e.isChord())return console.warn("Unexpected keyboard event mapped to a chord"),!1;let o=null,r=null;if(i){const[t]=e.getSingleModifierDispatchParts();o=t,r=t}else[o]=e.getDispatchParts(),r=this._currentChord?this._currentChord.keypress:null;if(null===o)return this._log("\\ Keyboard event cannot be dispatched in keydown phase."),n;const s=this._contextKeyService.getContext(t),a=e.getLabel(),l=this._getResolver().resolve(s,r,o);return this._logService.trace("KeybindingService#dispatch",a,null==l?void 0:l.commandId),l&&l.enterChord?(n=!0,this._enterChordMode(o,a),n):(this._currentChord&&(l&&l.commandId||(this._notificationService.status(vi.NC("vs/platform/keybinding/common/abstractKeybindingService","missing.chord","The key combination ({0}, {1}) is not a command.",this._currentChord.label,a),{hideAfter:1e4}),n=!0)),this._leaveChordMode(),l&&l.commandId&&(l.bubble||(n=!0),void 0===l.commandArgs?this._commandService.executeCommand(l.commandId).then(void 0,(e=>this._notificationService.warn(e))):this._commandService.executeCommand(l.commandId,l.commandArgs).then(void 0,(e=>this._notificationService.warn(e))),on.test(l.commandId)||this._telemetryService.publicLog2("workbenchActionExecuted",{id:l.commandId,from:"keybinding"})),n)}mightProducePrintableCharacter(e){return!e.ctrlKey&&!e.metaKey&&(e.keyCode>=31&&e.keyCode<=56||e.keyCode>=21&&e.keyCode<=30)}}class sn{constructor(e){this._ctrlKey=!!e&&e.ctrlKey,this._shiftKey=!!e&&e.shiftKey,this._altKey=!!e&&e.altKey,this._metaKey=!!e&&e.metaKey}has(e){switch(e){case"ctrl":return this._ctrlKey;case"shift":return this._shiftKey;case"alt":return this._altKey;case"meta":return this._metaKey}}}sn.EMPTY=new sn(null);var an=i(67517);class ln{constructor(e,t,i){this._log=i,this._defaultKeybindings=e,this._defaultBoundCommands=new Map;for(const t of e){const e=t.command;e&&"-"!==e.charAt(0)&&this._defaultBoundCommands.set(e,!0)}this._map=new Map,this._lookupMap=new Map,this._keybindings=ln.handleRemovals([].concat(e).concat(t));for(let e=0,t=this._keybindings.length;e=0;e--){let n=i[e];if(n.command===t.command)continue;const o=n.keypressParts.length>1,r=t.keypressParts.length>1;o&&r&&n.keypressParts[1]!==t.keypressParts[1]||ln.whenIsEntirelyIncluded(n.when,t.when)&&this._removeFromLookupMap(n)}i.push(t),this._addToLookupMap(t)}_addToLookupMap(e){if(!e.command)return;let t=this._lookupMap.get(e.command);void 0===t?(t=[e],this._lookupMap.set(e.command,t)):t.push(e)}_removeFromLookupMap(e){if(!e.command)return;let t=this._lookupMap.get(e.command);if(void 0!==t)for(let i=0,n=t.length;i=0;e--){const n=i[e];if(t.contextMatchesRules(n.when))return n}return i[i.length-1]}resolve(e,t,i){this._log(`| Resolving ${i}${t?` chorded from ${t}`:""}`);let n=null;if(null!==t){const e=this._map.get(t);if(void 0===e)return this._log("\\ No keybinding entries."),null;n=[];for(let t=0,o=e.length;t1&&null!==o.keypressParts[1]?(this._log(`\\ From ${n.length} keybinding entries, matched chord, when: ${cn(o.when)}, source: ${dn(o)}.`),{enterChord:!0,leaveChord:!1,commandId:null,commandArgs:null,bubble:!1}):(this._log(`\\ From ${n.length} keybinding entries, matched ${o.command}, when: ${cn(o.when)}, source: ${dn(o)}.`),{enterChord:!1,leaveChord:o.keypressParts.length>1,commandId:o.command,commandArgs:o.commandArgs,bubble:o.bubble}):(this._log(`\\ From ${n.length} keybinding entries, no when clauses matched the context.`),null)}_findCommand(e,t){for(let i=t.length-1;i>=0;i--){let n=t[i];if(ln._contextMatchesRules(e,n.when))return n}return null}static _contextMatchesRules(e,t){return!t||t.evaluate(e)}}function cn(e){return e?`${e.serialize()}`:"no when condition"}function dn(e){return e.extensionId?e.isBuiltinExtension?`built-in extension ${e.extensionId}`:`user extension ${e.extensionId}`:e.isDefault?"built-in":"user"}var un=i(77101);class hn{constructor(e,t,i,n,o,r,s){this._resolvedKeybindingItemBrand=void 0,this.resolvedKeybinding=e,this.keypressParts=e?gn(e.getDispatchParts()):[],e&&0===this.keypressParts.length&&(this.keypressParts=gn(e.getSingleModifierDispatchParts())),this.bubble=!!t&&94===t.charCodeAt(0),this.command=this.bubble?t.substr(1):t,this.commandArgs=i,this.when=n,this.isDefault=o,this.extensionId=r,this.isBuiltinExtension=s}}function gn(e){let t=[];for(let i=0,n=e.length;ithis._getLabel(e)))}getAriaLabel(){return pn.X4.toLabel(this._os,this._parts,(e=>this._getAriaLabel(e)))}getElectronAccelerator(){return this._parts.length>1||this._parts[0].isDuplicateModifierCase()?null:pn.jC.toLabel(this._os,this._parts,(e=>this._getElectronAccelerator(e)))}isChord(){return this._parts.length>1}getParts(){return this._parts.map((e=>this._getPart(e)))}_getPart(e){return new Fi.BQ(e.ctrlKey,e.shiftKey,e.altKey,e.metaKey,this._getLabel(e),this._getAriaLabel(e))}getDispatchParts(){return this._parts.map((e=>this._getDispatchPart(e)))}getSingleModifierDispatchParts(){return this._parts.map((e=>this._getSingleModifierDispatchPart(e)))}}class fn extends mn{constructor(e,t){super(t,e.parts)}_keyCodeToUILabel(e){if(2===this._os)switch(e){case 15:return"←";case 16:return"↑";case 17:return"→";case 18:return"↓"}return $.kL.toString(e)}_getLabel(e){return e.isDuplicateModifierCase()?"":this._keyCodeToUILabel(e.keyCode)}_getAriaLabel(e){return e.isDuplicateModifierCase()?"":$.kL.toString(e.keyCode)}_getElectronAccelerator(e){return $.kL.toElectronAccelerator(e.keyCode)}_getDispatchPart(e){return fn.getDispatchStr(e)}static getDispatchStr(e){if(e.isModifierKey())return null;let t="";return e.ctrlKey&&(t+="ctrl+"),e.shiftKey&&(t+="shift+"),e.altKey&&(t+="alt+"),e.metaKey&&(t+="meta+"),t+=$.kL.toString(e.keyCode),t}_getSingleModifierDispatchPart(e){return 5!==e.keyCode||e.shiftKey||e.altKey||e.metaKey?4!==e.keyCode||e.ctrlKey||e.altKey||e.metaKey?6!==e.keyCode||e.ctrlKey||e.shiftKey||e.metaKey?57!==e.keyCode||e.ctrlKey||e.shiftKey||e.altKey?null:"meta":"alt":"shift":"ctrl"}static _scanCodeToKeyCode(e){const t=$.Vd[e];if(-1!==t)return t;switch(e){case 10:return 31;case 11:return 32;case 12:return 33;case 13:return 34;case 14:return 35;case 15:return 36;case 16:return 37;case 17:return 38;case 18:return 39;case 19:return 40;case 20:return 41;case 21:return 42;case 22:return 43;case 23:return 44;case 24:return 45;case 25:return 46;case 26:return 47;case 27:return 48;case 28:return 49;case 29:return 50;case 30:return 51;case 31:return 52;case 32:return 53;case 33:return 54;case 34:return 55;case 35:return 56;case 36:return 22;case 37:return 23;case 38:return 24;case 39:return 25;case 40:return 26;case 41:return 27;case 42:return 28;case 43:return 29;case 44:return 30;case 45:return 21;case 51:return 83;case 52:return 81;case 53:return 87;case 54:return 89;case 55:return 88;case 56:return 0;case 57:return 80;case 58:return 90;case 59:return 86;case 60:return 82;case 61:return 84;case 62:return 85;case 106:return 92}return 0}static _resolveSimpleUserBinding(e){if(!e)return null;if(e instanceof Fi.QC)return e;const t=this._scanCodeToKeyCode(e.scanCode);return 0===t?null:new Fi.QC(e.ctrlKey,e.shiftKey,e.altKey,e.metaKey,t)}static resolveUserBinding(e,t){const i=gn(e.map((e=>this._resolveSimpleUserBinding(e))));return i.length>0?[new fn(new Fi.X_(i),t)]:[]}}var _n,bn=i(99125),vn=i(35073),Cn=i(56080),wn=i(38630),yn=i(71414),Sn=i(32817),xn=i(12887),kn=i(85860),Ln=i(14747),En=i(3726),Nn={};function Dn(e,t,i){const n=i.mode===_n.ALIGN?i.offset:i.offset+i.size,o=i.mode===_n.ALIGN?i.offset+i.size:i.offset;return 0===i.position?t<=e-n?n:t<=o?o-t:Math.max(e-t,0):t<=o?o-t:t<=e-n?n:0}Nn.styleTagTransform=le(),Nn.setAttributes=oe(),Nn.insert=ie().bind(null,"head"),Nn.domAPI=ee(),Nn.insertStyleElement=se(),X()(En.Z,Nn),En.Z&&En.Z.locals&&En.Z.locals,function(e){e[e.AVOID=0]="AVOID",e[e.ALIGN=1]="ALIGN"}(_n||(_n={}));class In extends Se.JT{constructor(e,t){super(),this.container=null,this.delegate=null,this.toDisposeOnClean=Se.JT.None,this.toDisposeOnSetContainer=Se.JT.None,this.shadowRoot=null,this.shadowRootHostElement=null,this.view=ii.$(".context-view"),this.useFixedPosition=!1,this.useShadowDOM=!1,ii.Cp(this.view),this.setContainer(e,t),this._register((0,Se.OF)((()=>this.setContainer(null,1))))}setContainer(e,t){var i;if(this.container&&(this.toDisposeOnSetContainer.dispose(),this.shadowRoot?(this.shadowRoot.removeChild(this.view),this.shadowRoot=null,null===(i=this.shadowRootHostElement)||void 0===i||i.remove(),this.shadowRootHostElement=null):this.container.removeChild(this.view),this.container=null),e){if(this.container=e,this.useFixedPosition=1!==t,this.useShadowDOM=3===t,this.useShadowDOM){this.shadowRootHostElement=ii.$(".shadow-root-host"),this.container.appendChild(this.shadowRootHostElement),this.shadowRoot=this.shadowRootHostElement.attachShadow({mode:"open"});const e=document.createElement("style");e.textContent=Tn,this.shadowRoot.appendChild(e),this.shadowRoot.appendChild(this.view),this.shadowRoot.appendChild(ii.$("slot"))}else this.container.appendChild(this.view);const i=new Se.SL;In.BUBBLE_UP_EVENTS.forEach((e=>{i.add(ii.mu(this.container,e,(e=>{this.onDOMEvent(e,!1)})))})),In.BUBBLE_DOWN_EVENTS.forEach((e=>{i.add(ii.mu(this.container,e,(e=>{this.onDOMEvent(e,!0)}),!0))})),this.toDisposeOnSetContainer=i}}show(e){this.isVisible()&&this.hide(),ii.PO(this.view),this.view.className="context-view",this.view.style.top="0px",this.view.style.left="0px",this.view.style.zIndex="2500",this.view.style.position=this.useFixedPosition?"fixed":"absolute",ii.$Z(this.view),this.toDisposeOnClean=e.render(this.view)||Se.JT.None,this.delegate=e,this.doLayout(),this.delegate.focus&&this.delegate.focus()}getViewElement(){return this.view}layout(){this.isVisible()&&(!1!==this.delegate.canRelayout||ke.gn&&kn.D.pointerEvents?(this.delegate.layout&&this.delegate.layout(),this.doLayout()):this.hide())}doLayout(){if(!this.isVisible())return;let e,t=this.delegate.getAnchor();if(ii.Re(t)){let i=ii.i(t);e={top:i.top,left:i.left,width:i.width,height:i.height}}else e={top:t.y,left:t.x,width:t.width||1,height:t.height||2};const i=ii.w(this.view),n=ii.wn(this.view),o=this.delegate.anchorPosition||0,r=this.delegate.anchorAlignment||0;let s,a;if(0===(this.delegate.anchorAxisAlignment||0)){const t={offset:e.top-window.pageYOffset,size:e.height,position:0===o?0:1},l={offset:e.left,size:e.width,position:0===r?0:1,mode:_n.ALIGN};s=Dn(window.innerHeight,n,t)+window.pageYOffset,Ln.e.intersects({start:s,end:s+n},{start:t.offset,end:t.offset+t.size})&&(l.mode=_n.AVOID),a=Dn(window.innerWidth,i,l)}else{const t={offset:e.left,size:e.width,position:0===r?0:1},l={offset:e.top,size:e.height,position:0===o?0:1,mode:_n.ALIGN};a=Dn(window.innerWidth,i,t),Ln.e.intersects({start:a,end:a+i},{start:t.offset,end:t.offset+t.size})&&(l.mode=_n.AVOID),s=Dn(window.innerHeight,n,l)+window.pageYOffset}this.view.classList.remove("top","bottom","left","right"),this.view.classList.add(0===o?"bottom":"top"),this.view.classList.add(0===r?"left":"right"),this.view.classList.toggle("fixed",this.useFixedPosition);const l=ii.i(this.container);this.view.style.top=s-(this.useFixedPosition?ii.i(this.view).top:l.top)+"px",this.view.style.left=a-(this.useFixedPosition?ii.i(this.view).left:l.left)+"px",this.view.style.width="initial"}hide(e){const t=this.delegate;this.delegate=null,(null==t?void 0:t.onHide)&&t.onHide(e),this.toDisposeOnClean.dispose(),ii.Cp(this.view)}isVisible(){return!!this.delegate}onDOMEvent(e,t){this.delegate&&(this.delegate.onDOMEvent?this.delegate.onDOMEvent(e,document.activeElement):t&&!ii.jg(e.target,this.container)&&this.hide())}dispose(){this.hide(),super.dispose()}}In.BUBBLE_UP_EVENTS=["click","keydown","focus","blur"],In.BUBBLE_DOWN_EVENTS=["click"];let Tn='\n\t:host {\n\t\tall: initial; /* 1st rule so subsequent properties are reset. */\n\t}\n\n\t@font-face {\n\t\tfont-family: "codicon";\n\t\tfont-display: block;\n\t\tsrc: url("./codicon.ttf?5d4d76ab2ce5108968ad644d591a16a6") format("truetype");\n\t}\n\n\t.codicon[class*=\'codicon-\'] {\n\t\tfont: normal normal normal 16px/1 codicon;\n\t\tdisplay: inline-block;\n\t\ttext-decoration: none;\n\t\ttext-rendering: auto;\n\t\ttext-align: center;\n\t\t-webkit-font-smoothing: antialiased;\n\t\t-moz-osx-font-smoothing: grayscale;\n\t\tuser-select: none;\n\t\t-webkit-user-select: none;\n\t\t-ms-user-select: none;\n\t}\n\n\t:host {\n\t\tfont-family: -apple-system, BlinkMacSystemFont, "Segoe WPC", "Segoe UI", "HelveticaNeue-Light", system-ui, "Ubuntu", "Droid Sans", sans-serif;\n\t}\n\n\t:host-context(.mac) { font-family: -apple-system, BlinkMacSystemFont, sans-serif; }\n\t:host-context(.mac:lang(zh-Hans)) { font-family: -apple-system, BlinkMacSystemFont, "PingFang SC", "Hiragino Sans GB", sans-serif; }\n\t:host-context(.mac:lang(zh-Hant)) { font-family: -apple-system, BlinkMacSystemFont, "PingFang TC", sans-serif; }\n\t:host-context(.mac:lang(ja)) { font-family: -apple-system, BlinkMacSystemFont, "Hiragino Kaku Gothic Pro", sans-serif; }\n\t:host-context(.mac:lang(ko)) { font-family: -apple-system, BlinkMacSystemFont, "Nanum Gothic", "Apple SD Gothic Neo", "AppleGothic", sans-serif; }\n\n\t:host-context(.windows) { font-family: "Segoe WPC", "Segoe UI", sans-serif; }\n\t:host-context(.windows:lang(zh-Hans)) { font-family: "Segoe WPC", "Segoe UI", "Microsoft YaHei", sans-serif; }\n\t:host-context(.windows:lang(zh-Hant)) { font-family: "Segoe WPC", "Segoe UI", "Microsoft Jhenghei", sans-serif; }\n\t:host-context(.windows:lang(ja)) { font-family: "Segoe WPC", "Segoe UI", "Yu Gothic UI", "Meiryo UI", sans-serif; }\n\t:host-context(.windows:lang(ko)) { font-family: "Segoe WPC", "Segoe UI", "Malgun Gothic", "Dotom", sans-serif; }\n\n\t:host-context(.linux) { font-family: system-ui, "Ubuntu", "Droid Sans", sans-serif; }\n\t:host-context(.linux:lang(zh-Hans)) { font-family: system-ui, "Ubuntu", "Droid Sans", "Source Han Sans SC", "Source Han Sans CN", "Source Han Sans", sans-serif; }\n\t:host-context(.linux:lang(zh-Hant)) { font-family: system-ui, "Ubuntu", "Droid Sans", "Source Han Sans TC", "Source Han Sans TW", "Source Han Sans", sans-serif; }\n\t:host-context(.linux:lang(ja)) { font-family: system-ui, "Ubuntu", "Droid Sans", "Source Han Sans J", "Source Han Sans JP", "Source Han Sans", sans-serif; }\n\t:host-context(.linux:lang(ko)) { font-family: system-ui, "Ubuntu", "Droid Sans", "Source Han Sans K", "Source Han Sans JR", "Source Han Sans", "UnDotum", "FBaekmuk Gulim", sans-serif; }\n';let An=class extends Se.JT{constructor(e){super(),this.layoutService=e,this.currentViewDisposable=Se.JT.None,this.container=e.hasContainer?e.container:null,this.contextView=this._register(new In(this.container,1)),this.layout(),this._register(e.onDidLayout((()=>this.layout())))}setContainer(e,t){this.contextView.setContainer(e,t||1)}showContextView(e,t,i){t?t!==this.container&&(this.container=t,this.setContainer(t,i?3:2)):this.layoutService.hasContainer&&this.container!==this.layoutService.container&&(this.container=this.layoutService.container,this.setContainer(this.container,1)),this.contextView.show(e);const n=(0,Se.OF)((()=>{this.currentViewDisposable===n&&this.hideContextView()}));return this.currentViewDisposable=n,n}getContextViewElement(){return this.contextView.getViewElement()}layout(){this.contextView.layout()}hideContextView(e){this.contextView.hide(e)}};An=function(e,t,i,n){var o,r=arguments.length,s=r<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,i):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(e,t,i,n);else for(var a=e.length-1;a>=0;a--)(o=e[a])&&(s=(r<3?o(s):r>3?o(t,i,s):o(t,i))||s);return r>3&&s&&Object.defineProperty(t,i,s),s}([function(e,t){return function(i,n){t(i,n,e)}}(0,gi)],An);var Rn=i(56855),Mn=i(14477);const On="**",Pn=/\//g;function Fn(e){switch(e){case 0:return"";case 1:return"[^/\\\\]*?";default:return"(?:[/\\\\]|[^/\\\\]+[/\\\\]|[/\\\\][^/\\\\]+)*?"}}function Bn(e,t){if(!e)return[];const i=[];let n=!1,o=!1,r="";for(const s of e){switch(s){case t:if(!n&&!o){i.push(r),r="";continue}break;case"{":n=!0;break;case"}":n=!1;break;case"[":o=!0;break;case"]":o=!1}r+=s}return r&&i.push(r),i}function Wn(e){if(!e)return"";let t="";const i=Bn(e,"/");if(i.every((e=>e===On)))t=".*";else{let e=!1;i.forEach(((n,o)=>{if(n===On)return void(e||(t+=Fn(2),e=!0));let r=!1,s="",a=!1,l="";for(const e of n)if("}"!==e&&r)s+=e;else if(!a||"]"===e&&l)switch(e){case"{":r=!0;continue;case"[":a=!0;continue;case"}":{const e=`(?:${Bn(s,",").map((e=>Wn(e))).join("|")})`;t+=e,r=!1,s="";break}case"]":t+="["+l+"]",a=!1,l="";break;case"?":t+="[^/\\\\]";continue;case"*":t+=Fn(1);continue;default:t+=(0,ue.ec)(e)}else{let t;t="-"===e?e:"^"!==e&&"!"!==e||l?"/"===e?"":(0,ue.ec)(e):"^",l+=t}oZn(e,t))).filter((e=>e!==Gn)),e),n=i.length;if(!n)return Gn;if(1===n)return i[0];const o=function(t,n){for(let o=0,r=i.length;o!!e.allBasenames));r&&(o.allBasenames=r.allBasenames);const s=i.reduce(((e,t)=>t.allPaths?e.concat(t.allPaths):e),[]);return s.length&&(o.allPaths=s),o}(i,t):(o=Un.exec(Qn(i,t)))?Xn(o[1].substr(1),i,!0):(o=jn.exec(Qn(i,t)))?Xn(o[1],i,!1):function(e){try{const t=new RegExp(`^${Wn(e)}$`);return function(i){return t.lastIndex=0,"string"==typeof i&&t.test(i)?e:null}}catch(e){return Gn}}(i);return Kn.set(n,r),Yn(r,e)}function Yn(e,t){return"string"==typeof t?e:function(i,n){return(0,Rn.KM)(i,t.base,!ke.IJ)?e(i.substr(t.base.length+1),n):null}}function Qn(e,t){return t.trimForExclusions&&e.endsWith("/**")?e.substr(0,e.length-2):e}function Xn(e,t,i){const n=Mn.ir===Mn.KR.sep,o=n?e:e.replace(Pn,Mn.ir),r=Mn.ir+o,s=Mn.KR.sep+e,a=i?function(i,a){return"string"!=typeof i||i!==o&&!i.endsWith(r)&&(n||i!==e&&!i.endsWith(s))?null:t}:function(i,r){return"string"!=typeof i||i!==o&&(n||i!==e)?null:t};return a.allPaths=[(i?"*/":"./")+e],a}function Jn(e,t={}){if(!e)return qn;if("string"==typeof e||function(e){const t=e;return!!t&&("string"==typeof t.base&&"string"==typeof t.pattern)}(e)){const i=Zn(e,t);if(i===Gn)return qn;const n=function(e,t){return!!i(e,t)};return i.allBasenames&&(n.allBasenames=i.allBasenames),i.allPaths&&(n.allPaths=i.allPaths),n}return function(e,t){const i=eo(Object.getOwnPropertyNames(e).map((i=>function(e,t,i){if(!1===t)return Gn;const n=Zn(e,i);if(n===Gn)return Gn;if("boolean"==typeof t)return n;if(t){const i=t.when;if("string"==typeof i){const t=(t,o,r,s)=>{if(!s||!n(t,o))return null;const a=s(i.replace("$(basename)",r));return(0,ye.J8)(a)?a.then((t=>t?e:null)):a?e:null};return t.requiresSiblings=!0,t}}return n}(i,e[i],t))).filter((e=>e!==Gn))),n=i.length;if(!n)return Gn;if(!i.some((e=>!!e.requiresSiblings))){if(1===n)return i[0];const e=function(e,t){for(let n=0,o=i.length;n!!e.allBasenames));t&&(e.allBasenames=t.allBasenames);const o=i.reduce(((e,t)=>t.allPaths?e.concat(t.allPaths):e),[]);return o.length&&(e.allPaths=o),e}const o=function(e,t,n){let o;for(let r=0,s=i.length;r!!e.allBasenames));r&&(o.allBasenames=r.allBasenames);const s=i.reduce(((e,t)=>t.allPaths?e.concat(t.allPaths):e),[]);return s.length&&(o.allPaths=s),o}(e,t)}function eo(e,t){const i=e.filter((e=>!!e.basenames));if(i.length<2)return e;const n=i.reduce(((e,t)=>{const i=t.basenames;return i?e.concat(i):e}),[]);let o;if(t){o=[];for(let e=0,i=n.length;e{const i=t.patterns;return i?e.concat(i):e}),[]);const r=function(e,t){if("string"!=typeof e)return null;if(!t){let i;for(i=e.length;i>0;i--){const t=e.charCodeAt(i-1);if(47===t||92===t)break}t=e.substr(i)}const i=n.indexOf(t);return-1!==i?o[i]:null};r.basenames=n,r.patterns=o,r.allBasenames=n;const s=e.filter((e=>!e.basenames));return s.push(r),s}var to=i(25227),io=i(10804);let no=[],oo=[],ro=[];function so(e,t=!1){!function(e,t,i){const n=function(e,t){return{id:e.id,mime:e.mime,filename:e.filename,extension:e.extension,filepattern:e.filepattern,firstline:e.firstline,userConfigured:false,filenameLowercase:e.filename?e.filename.toLowerCase():void 0,extensionLowercase:e.extension?e.extension.toLowerCase():void 0,filepatternLowercase:e.filepattern?Jn(e.filepattern.toLowerCase()):void 0,filepatternOnPath:!!e.filepattern&&e.filepattern.indexOf(Mn.KR.sep)>=0}}(e);no.push(n),n.userConfigured?ro.push(n):oo.push(n),i&&!n.userConfigured&&no.forEach((e=>{e.mime===n.mime||e.userConfigured||(n.extension&&e.extension===n.extension&&console.warn(`Overwriting extension <<${n.extension}>> to now point to mime <<${n.mime}>>`),n.filename&&e.filename===n.filename&&console.warn(`Overwriting filename <<${n.filename}>> to now point to mime <<${n.mime}>>`),n.filepattern&&e.filepattern===n.filepattern&&console.warn(`Overwriting filepattern <<${n.filepattern}>> to now point to mime <<${n.mime}>>`),n.firstline&&e.firstline===n.firstline&&console.warn(`Overwriting firstline <<${n.firstline}>> to now point to mime <<${n.mime}>>`))}))}(e,0,t)}function ao(e,t,i){var n;let o,r,s;for(let a=i.length-1;a>=0;a--){const l=i[a];if(t===l.filenameLowercase){o=l;break}if(l.filepattern&&(!r||l.filepattern.length>r.filepattern.length)){const i=l.filepatternOnPath?e:t;(null===(n=l.filepatternLowercase)||void 0===n?void 0:n.call(l,i))&&(r=l)}l.extension&&(!s||l.extension.length>s.extension.length)&&t.endsWith(l.extensionLowercase)&&(s=l)}return o?o.mime:r?r.mime:s?s.mime:void 0}var lo=i(11233);const co=Object.prototype.hasOwnProperty,uo="vs.editor.nullLanguage";be.zu.register(uo,{});class ho{constructor(){this._languageIdToLanguage=[],this._languageToLanguageId=new Map,this._register(uo,0),this._register(lo.bd,1),this._nextLanguageId=2}_register(e,t){this._languageIdToLanguage[t]=e,this._languageToLanguageId.set(e,t)}register(e){if(this._languageToLanguageId.has(e))return;const t=this._nextLanguageId++;this._register(e,t)}encodeLanguageId(e){return this._languageToLanguageId.get(e)||0}decodeLanguageId(e){return this._languageIdToLanguage[e]||uo}}class go extends Se.JT{constructor(e=!0,t=!1){super(),this._onDidChange=this._register(new z.Q5),this.onDidChange=this._onDidChange.event,go.instanceCount++,this._warnOnOverwrite=t,this.languageIdCodec=new ho,this._dynamicLanguages=[],this._languages={},this._mimeTypesMap={},this._nameMap={},this._lowercaseNameMap={},e&&(this._initializeFromRegistry(),this._register(lo.dQ.onDidChangeLanguages((e=>{this._initializeFromRegistry()}))))}dispose(){go.instanceCount--,super.dispose()}_initializeFromRegistry(){this._languages={},this._mimeTypesMap={},this._nameMap={},this._lowercaseNameMap={},no=no.filter((e=>e.userConfigured)),oo=[];const e=[].concat(lo.dQ.getLanguages()).concat(this._dynamicLanguages);this._registerLanguages(e)}_registerLanguages(e){for(const t of e)this._registerLanguage(t);this._mimeTypesMap={},this._nameMap={},this._lowercaseNameMap={},Object.keys(this._languages).forEach((e=>{const t=this._languages[e];t.name&&(this._nameMap[t.name]=t.identifier),t.aliases.forEach((e=>{this._lowercaseNameMap[e.toLowerCase()]=t.identifier})),t.mimetypes.forEach((e=>{this._mimeTypesMap[e]=t.identifier}))})),Hi.B.as(Vi.IP.Configuration).registerOverrideIdentifiers(this.getRegisteredLanguageIds()),this._onDidChange.fire()}_registerLanguage(e){const t=e.id;let i;co.call(this._languages,t)?i=this._languages[t]:(this.languageIdCodec.register(t),i={identifier:t,name:null,mimetypes:[],aliases:[],extensions:[],filenames:[],configurationFiles:[],icons:[]},this._languages[t]=i),this._mergeLanguage(i,e)}_mergeLanguage(e,t){const i=t.id;let n=null;if(Array.isArray(t.mimetypes)&&t.mimetypes.length>0&&(e.mimetypes.push(...t.mimetypes),n=t.mimetypes[0]),n||(n=`text/x-${i}`,e.mimetypes.push(n)),Array.isArray(t.extensions)){t.configuration?e.extensions=t.extensions.concat(e.extensions):e.extensions=e.extensions.concat(t.extensions);for(let e of t.extensions)so({id:i,mime:n,extension:e},this._warnOnOverwrite)}if(Array.isArray(t.filenames))for(let o of t.filenames)so({id:i,mime:n,filename:o},this._warnOnOverwrite),e.filenames.push(o);if(Array.isArray(t.filenamePatterns))for(let e of t.filenamePatterns)so({id:i,mime:n,filepattern:e},this._warnOnOverwrite);if("string"==typeof t.firstLine&&t.firstLine.length>0){let e=t.firstLine;"^"!==e.charAt(0)&&(e="^"+e);try{const t=new RegExp(e);(0,ue.IO)(t)||so({id:i,mime:n,firstline:t},this._warnOnOverwrite)}catch(e){(0,xe.dL)(e)}}e.aliases.push(i);let o=null;if(void 0!==t.aliases&&Array.isArray(t.aliases)&&(o=0===t.aliases.length?[null]:t.aliases),null!==o)for(const t of o)t&&0!==t.length&&e.aliases.push(t);const r=null!==o&&o.length>0;if(r&&null===o[0]);else{const t=(r?o[0]:null)||i;!r&&e.name||(e.name=t)}t.configuration&&e.configurationFiles.push(t.configuration),t.icon&&e.icons.push(t.icon)}isRegisteredLanguageId(e){return!!e&&co.call(this._languages,e)}getRegisteredLanguageIds(){return Object.keys(this._languages)}getLanguageIdByLanguageName(e){const t=e.toLowerCase();return co.call(this._lowercaseNameMap,t)?this._lowercaseNameMap[t]:null}getLanguageIdByMimeType(e){return e&&co.call(this._mimeTypesMap,e)?this._mimeTypesMap[e]:null}guessLanguageIdByFilepathOrFirstLine(e,t){if(!e&&!t)return[];const i=function(e,t){let i;if(e)switch(e.scheme){case ni.lg.file:i=e.fsPath;break;case ni.lg.data:i=io.Vb.parseMetaData(e).get(io.Vb.META_DATA_LABEL);break;default:i=e.path}if(!i)return[to.v.unknown];i=i.toLowerCase();const n=(0,Mn.EZ)(i),o=ao(i,n,ro);if(o)return[o,to.v.text];const r=ao(i,n,oo);if(r)return[r,to.v.text];if(t){const e=function(e){if((0,ue.uS)(e)&&(e=e.substr(1)),e.length>0)for(let t=no.length-1;t>=0;t--){const i=no[t];if(!i.firstline)continue;const n=e.match(i.firstline);if(n&&n.length>0)return i.mime}}(t);if(e)return[e,to.v.text]}return[to.v.unknown]}(e,t);return(0,gt.kX)(i.map((e=>this.getLanguageIdByMimeType(e))))}}go.instanceCount=0;class po extends Se.JT{constructor(e=!1){super(),this._onDidEncounterLanguage=this._register(new z.Q5),this.onDidEncounterLanguage=this._onDidEncounterLanguage.event,this._onDidChange=this._register(new z.Q5({leakWarningThreshold:200})),this.onDidChange=this._onDidChange.event,po.instanceCount++,this._encounteredLanguages=new Set,this._registry=this._register(new go(!0,e)),this.languageIdCodec=this._registry.languageIdCodec,this._register(this._registry.onDidChange((()=>this._onDidChange.fire())))}dispose(){po.instanceCount--,super.dispose()}isRegisteredLanguageId(e){return this._registry.isRegisteredLanguageId(e)}getLanguageIdByLanguageName(e){return this._registry.getLanguageIdByLanguageName(e)}getLanguageIdByMimeType(e){return this._registry.getLanguageIdByMimeType(e)}guessLanguageIdByFilepathOrFirstLine(e,t){const i=this._registry.guessLanguageIdByFilepathOrFirstLine(e,t);return(0,gt.Xh)(i,null)}createById(e){return new mo(this.onDidChange,(()=>this._createAndGetLanguageIdentifier(e)))}createByFilepathOrFirstLine(e,t){return new mo(this.onDidChange,(()=>{const i=this.guessLanguageIdByFilepathOrFirstLine(e,t);return this._createAndGetLanguageIdentifier(i)}))}_createAndGetLanguageIdentifier(e){return e&&this.isRegisteredLanguageId(e)||(e=lo.bd),this._encounteredLanguages.has(e)||(this._encounteredLanguages.add(e),G.RW.getOrCreate(e),this._onDidEncounterLanguage.fire(e)),e}}po.instanceCount=0;class mo{constructor(e,t){this._onDidChangeLanguages=e,this._selector=t,this._listener=null,this._emitter=null,this.languageId=this._selector()}_dispose(){this._listener&&(this._listener.dispose(),this._listener=null),this._emitter&&(this._emitter.dispose(),this._emitter=null)}get onDidChange(){return this._listener||(this._listener=this._onDidChangeLanguages((()=>this._evaluate()))),this._emitter||(this._emitter=new z.Q5({onLastListenerRemove:()=>{this._dispose()}})),this._emitter.event}_evaluate(){const e=this._selector();e!==this.languageId&&(this.languageId=e,this._emitter&&this._emitter.fire(this.languageId))}}var fo=i(80428),_o=i(26641),bo=i(83055),vo=i(47995),Co=i(99512),wo=i(6622),yo=i(98677),So=i(11007),xo=i(4821),ko=i(14329);const Lo=/\(&([^\s&])\)|(^|[^&])&([^\s&])/,Eo=/(&)?(&)([^\s&])/g;var No;!function(e){e[e.Right=0]="Right",e[e.Left=1]="Left"}(No||(No={}));class Do extends vo.o{constructor(e,t,i={}){e.classList.add("monaco-menu-container"),e.setAttribute("role","presentation");const n=document.createElement("div");n.classList.add("monaco-menu"),n.setAttribute("role","presentation"),super(n,{orientation:1,actionViewItemProvider:e=>this.doGetActionViewItem(e,i,o),context:i.context,actionRunner:i.actionRunner,ariaLabel:i.ariaLabel,focusOnlyEnabledItems:!0,triggerKeys:{keys:[3,...ke.dz||ke.IJ?[10]:[]],keyDown:!0}}),this.menuElement=n,this.actionsList.setAttribute("role","menu"),this.actionsList.tabIndex=0,this.menuDisposables=this._register(new Se.SL),this.initializeOrUpdateStyleSheet(e,{}),this._register(bo.o.addTarget(n)),(0,ii.nm)(n,ii.tw.KEY_DOWN,(e=>{new Pi.y(e).equals(2)&&e.preventDefault()})),i.enableMnemonics&&this.menuDisposables.add((0,ii.nm)(n,ii.tw.KEY_DOWN,(e=>{const t=e.key.toLocaleLowerCase();if(this.mnemonics.has(t)){ii.zB.stop(e,!0);const i=this.mnemonics.get(t);if(1===i.length&&(i[0]instanceof To&&i[0].container&&this.focusItemByElement(i[0].container),i[0].onClick(e)),i.length>1){const e=i.shift();e&&e.container&&(this.focusItemByElement(e.container),i.push(e)),this.mnemonics.set(t,i)}}}))),ke.IJ&&this._register((0,ii.nm)(n,ii.tw.KEY_DOWN,(e=>{const t=new Pi.y(e);t.equals(14)||t.equals(11)?(this.focusedItem=this.viewItems.length-1,this.focusNext(),ii.zB.stop(e,!0)):(t.equals(13)||t.equals(12))&&(this.focusedItem=0,this.focusPrevious(),ii.zB.stop(e,!0))}))),this._register((0,ii.nm)(this.domNode,ii.tw.MOUSE_OUT,(e=>{let t=e.relatedTarget;(0,ii.jg)(t,this.domNode)||(this.focusedItem=void 0,this.updateFocus(),e.stopPropagation())}))),this._register((0,ii.nm)(this.actionsList,ii.tw.MOUSE_OVER,(e=>{let t=e.target;if(t&&(0,ii.jg)(t,this.actionsList)&&t!==this.actionsList){for(;t.parentElement!==this.actionsList&&null!==t.parentElement;)t=t.parentElement;if(t.classList.contains("action-item")){const e=this.focusedItem;this.setFocusedItem(t),e!==this.focusedItem&&this.updateFocus()}}}))),this._register(bo.o.addTarget(this.actionsList)),this._register((0,ii.nm)(this.actionsList,bo.t.Tap,(e=>{let t=e.initialTarget;if(t&&(0,ii.jg)(t,this.actionsList)&&t!==this.actionsList){for(;t.parentElement!==this.actionsList&&null!==t.parentElement;)t=t.parentElement;if(t.classList.contains("action-item")){const e=this.focusedItem;this.setFocusedItem(t),e!==this.focusedItem&&this.updateFocus()}}})));let o={parent:this};this.mnemonics=new Map,this.scrollableElement=this._register(new yo.s$(n,{alwaysConsumeMouseWheel:!0,horizontal:2,vertical:3,verticalScrollbarSize:7,handleMouseWheel:!0,useShadows:!0}));const r=this.scrollableElement.getDomNode();r.style.position="",this._register((0,ii.nm)(n,bo.t.Change,(e=>{ii.zB.stop(e,!0);const t=this.scrollableElement.getScrollPosition().scrollTop;this.scrollableElement.setScrollPosition({scrollTop:t-e.translationY})}))),this._register((0,ii.nm)(r,ii.tw.MOUSE_UP,(e=>{e.preventDefault()}))),n.style.maxHeight=`${Math.max(10,window.innerHeight-e.getBoundingClientRect().top-35)}px`,t=t.filter((e=>{var t;return!(null===(t=i.submenuIds)||void 0===t?void 0:t.has(e.id))||(console.warn(`Found submenu cycle: ${e.id}`),!1)})),this.push(t,{icon:!0,label:!0,isMenu:!0}),e.appendChild(this.scrollableElement.getDomNode()),this.scrollableElement.scanDomNode(),this.viewItems.filter((e=>!(e instanceof Ao))).forEach(((e,t,i)=>{e.updatePositionInSet(t+1,i.length)}))}initializeOrUpdateStyleSheet(e,t){this.styleSheet||((0,ii.OO)(e)?this.styleSheet=(0,ii.dS)(e):(Do.globalStyleSheet||(Do.globalStyleSheet=(0,ii.dS)()),this.styleSheet=Do.globalStyleSheet)),this.styleSheet.textContent=function(e,t){let i=`\n.monaco-menu {\n\tfont-size: 13px;\n\n}\n\n${(0,wo.a)(xo.lA.menuSelection)}\n${(0,wo.a)(xo.lA.menuSubmenu)}\n\n.monaco-menu .monaco-action-bar {\n\ttext-align: right;\n\toverflow: hidden;\n\twhite-space: nowrap;\n}\n\n.monaco-menu .monaco-action-bar .actions-container {\n\tdisplay: flex;\n\tmargin: 0 auto;\n\tpadding: 0;\n\twidth: 100%;\n\tjustify-content: flex-end;\n}\n\n.monaco-menu .monaco-action-bar.vertical .actions-container {\n\tdisplay: inline-block;\n}\n\n.monaco-menu .monaco-action-bar.reverse .actions-container {\n\tflex-direction: row-reverse;\n}\n\n.monaco-menu .monaco-action-bar .action-item {\n\tcursor: pointer;\n\tdisplay: inline-block;\n\ttransition: transform 50ms ease;\n\tposition: relative; /* DO NOT REMOVE - this is the key to preventing the ghosting icon bug in Chrome 42 */\n}\n\n.monaco-menu .monaco-action-bar .action-item.disabled {\n\tcursor: default;\n}\n\n.monaco-menu .monaco-action-bar.animated .action-item.active {\n\ttransform: scale(1.272019649, 1.272019649); /* 1.272019649 = √φ */\n}\n\n.monaco-menu .monaco-action-bar .action-item .icon,\n.monaco-menu .monaco-action-bar .action-item .codicon {\n\tdisplay: inline-block;\n}\n\n.monaco-menu .monaco-action-bar .action-item .codicon {\n\tdisplay: flex;\n\talign-items: center;\n}\n\n.monaco-menu .monaco-action-bar .action-label {\n\tfont-size: 11px;\n\tmargin-right: 4px;\n}\n\n.monaco-menu .monaco-action-bar .action-item.disabled .action-label,\n.monaco-menu .monaco-action-bar .action-item.disabled .action-label:hover {\n\topacity: 0.4;\n}\n\n/* Vertical actions */\n\n.monaco-menu .monaco-action-bar.vertical {\n\ttext-align: left;\n}\n\n.monaco-menu .monaco-action-bar.vertical .action-item {\n\tdisplay: block;\n}\n\n.monaco-menu .monaco-action-bar.vertical .action-label.separator {\n\tdisplay: block;\n\tborder-bottom: 1px solid #bbb;\n\tpadding-top: 1px;\n\tmargin-left: .8em;\n\tmargin-right: .8em;\n}\n\n.monaco-menu .secondary-actions .monaco-action-bar .action-label {\n\tmargin-left: 6px;\n}\n\n/* Action Items */\n.monaco-menu .monaco-action-bar .action-item.select-container {\n\toverflow: hidden; /* somehow the dropdown overflows its container, we prevent it here to not push */\n\tflex: 1;\n\tmax-width: 170px;\n\tmin-width: 60px;\n\tdisplay: flex;\n\talign-items: center;\n\tjustify-content: center;\n\tmargin-right: 10px;\n}\n\n.monaco-menu .monaco-action-bar.vertical {\n\tmargin-left: 0;\n\toverflow: visible;\n}\n\n.monaco-menu .monaco-action-bar.vertical .actions-container {\n\tdisplay: block;\n}\n\n.monaco-menu .monaco-action-bar.vertical .action-item {\n\tpadding: 0;\n\ttransform: none;\n\tdisplay: flex;\n}\n\n.monaco-menu .monaco-action-bar.vertical .action-item.active {\n\ttransform: none;\n}\n\n.monaco-menu .monaco-action-bar.vertical .action-menu-item {\n\tflex: 1 1 auto;\n\tdisplay: flex;\n\theight: 2em;\n\talign-items: center;\n\tposition: relative;\n}\n\n.monaco-menu .monaco-action-bar.vertical .action-label {\n\tflex: 1 1 auto;\n\ttext-decoration: none;\n\tpadding: 0 1em;\n\tbackground: none;\n\tfont-size: 12px;\n\tline-height: 1;\n}\n\n.monaco-menu .monaco-action-bar.vertical .keybinding,\n.monaco-menu .monaco-action-bar.vertical .submenu-indicator {\n\tdisplay: inline-block;\n\tflex: 2 1 auto;\n\tpadding: 0 1em;\n\ttext-align: right;\n\tfont-size: 12px;\n\tline-height: 1;\n}\n\n.monaco-menu .monaco-action-bar.vertical .submenu-indicator {\n\theight: 100%;\n}\n\n.monaco-menu .monaco-action-bar.vertical .submenu-indicator.codicon {\n\tfont-size: 16px !important;\n\tdisplay: flex;\n\talign-items: center;\n}\n\n.monaco-menu .monaco-action-bar.vertical .submenu-indicator.codicon::before {\n\tmargin-left: auto;\n\tmargin-right: -20px;\n}\n\n.monaco-menu .monaco-action-bar.vertical .action-item.disabled .keybinding,\n.monaco-menu .monaco-action-bar.vertical .action-item.disabled .submenu-indicator {\n\topacity: 0.4;\n}\n\n.monaco-menu .monaco-action-bar.vertical .action-label:not(.separator) {\n\tdisplay: inline-block;\n\tbox-sizing: border-box;\n\tmargin: 0;\n}\n\n.monaco-menu .monaco-action-bar.vertical .action-item {\n\tposition: static;\n\toverflow: visible;\n}\n\n.monaco-menu .monaco-action-bar.vertical .action-item .monaco-submenu {\n\tposition: absolute;\n}\n\n.monaco-menu .monaco-action-bar.vertical .action-label.separator {\n\tpadding: 0.5em 0 0 0;\n\tmargin-bottom: 0.5em;\n\twidth: 100%;\n\theight: 0px !important;\n\tmargin-left: .8em !important;\n\tmargin-right: .8em !important;\n}\n\n.monaco-menu .monaco-action-bar.vertical .action-label.separator.text {\n\tpadding: 0.7em 1em 0.1em 1em;\n\tfont-weight: bold;\n\topacity: 1;\n}\n\n.monaco-menu .monaco-action-bar.vertical .action-label:hover {\n\tcolor: inherit;\n}\n\n.monaco-menu .monaco-action-bar.vertical .menu-item-check {\n\tposition: absolute;\n\tvisibility: hidden;\n\twidth: 1em;\n\theight: 100%;\n}\n\n.monaco-menu .monaco-action-bar.vertical .action-menu-item.checked .menu-item-check {\n\tvisibility: visible;\n\tdisplay: flex;\n\talign-items: center;\n\tjustify-content: center;\n}\n\n/* Context Menu */\n\n.context-view.monaco-menu-container {\n\toutline: 0;\n\tborder: none;\n\tanimation: fadeIn 0.083s linear;\n\t-webkit-app-region: no-drag;\n}\n\n.context-view.monaco-menu-container :focus,\n.context-view.monaco-menu-container .monaco-action-bar.vertical:focus,\n.context-view.monaco-menu-container .monaco-action-bar.vertical :focus {\n\toutline: 0;\n}\n\n.monaco-menu .monaco-action-bar.vertical .action-item {\n\tborder: thin solid transparent; /* prevents jumping behaviour on hover or focus */\n}\n\n\n/* High Contrast Theming */\n:host-context(.hc-black) .context-view.monaco-menu-container {\n\tbox-shadow: none;\n}\n\n:host-context(.hc-black) .monaco-menu .monaco-action-bar.vertical .action-item.focused {\n\tbackground: none;\n}\n\n/* Vertical Action Bar Styles */\n\n.monaco-menu .monaco-action-bar.vertical {\n\tpadding: .5em 0;\n}\n\n.monaco-menu .monaco-action-bar.vertical .action-menu-item {\n\theight: 1.8em;\n}\n\n.monaco-menu .monaco-action-bar.vertical .action-label:not(.separator),\n.monaco-menu .monaco-action-bar.vertical .keybinding {\n\tfont-size: inherit;\n\tpadding: 0 2em;\n}\n\n.monaco-menu .monaco-action-bar.vertical .menu-item-check {\n\tfont-size: inherit;\n\twidth: 2em;\n}\n\n.monaco-menu .monaco-action-bar.vertical .action-label.separator {\n\tfont-size: inherit;\n\tpadding: 0.2em 0 0 0;\n\tmargin-bottom: 0.2em;\n}\n\n:host-context(.linux) .monaco-menu .monaco-action-bar.vertical .action-label.separator {\n\tmargin-left: 0;\n\tmargin-right: 0;\n}\n\n.monaco-menu .monaco-action-bar.vertical .submenu-indicator {\n\tfont-size: 60%;\n\tpadding: 0 1.8em;\n}\n\n:host-context(.linux) .monaco-menu .monaco-action-bar.vertical .submenu-indicator {\n\theight: 100%;\n\tmask-size: 10px 10px;\n\t-webkit-mask-size: 10px 10px;\n}\n\n.monaco-menu .action-item {\n\tcursor: default;\n}`;if(t){i+="\n\t\t\t/* Arrows */\n\t\t\t.monaco-scrollable-element > .scrollbar > .scra {\n\t\t\t\tcursor: pointer;\n\t\t\t\tfont-size: 11px !important;\n\t\t\t}\n\n\t\t\t.monaco-scrollable-element > .visible {\n\t\t\t\topacity: 1;\n\n\t\t\t\t/* Background rule added for IE9 - to allow clicks on dom node */\n\t\t\t\tbackground:rgba(0,0,0,0);\n\n\t\t\t\ttransition: opacity 100ms linear;\n\t\t\t}\n\t\t\t.monaco-scrollable-element > .invisible {\n\t\t\t\topacity: 0;\n\t\t\t\tpointer-events: none;\n\t\t\t}\n\t\t\t.monaco-scrollable-element > .invisible.fade {\n\t\t\t\ttransition: opacity 800ms linear;\n\t\t\t}\n\n\t\t\t/* Scrollable Content Inset Shadow */\n\t\t\t.monaco-scrollable-element > .shadow {\n\t\t\t\tposition: absolute;\n\t\t\t\tdisplay: none;\n\t\t\t}\n\t\t\t.monaco-scrollable-element > .shadow.top {\n\t\t\t\tdisplay: block;\n\t\t\t\ttop: 0;\n\t\t\t\tleft: 3px;\n\t\t\t\theight: 3px;\n\t\t\t\twidth: 100%;\n\t\t\t}\n\t\t\t.monaco-scrollable-element > .shadow.left {\n\t\t\t\tdisplay: block;\n\t\t\t\ttop: 3px;\n\t\t\t\tleft: 0;\n\t\t\t\theight: 100%;\n\t\t\t\twidth: 3px;\n\t\t\t}\n\t\t\t.monaco-scrollable-element > .shadow.top-left-corner {\n\t\t\t\tdisplay: block;\n\t\t\t\ttop: 0;\n\t\t\t\tleft: 0;\n\t\t\t\theight: 3px;\n\t\t\t\twidth: 3px;\n\t\t\t}\n\t\t";const t=e.scrollbarShadow;t&&(i+=`\n\t\t\t\t.monaco-scrollable-element > .shadow.top {\n\t\t\t\t\tbox-shadow: ${t} 0 6px 6px -6px inset;\n\t\t\t\t}\n\n\t\t\t\t.monaco-scrollable-element > .shadow.left {\n\t\t\t\t\tbox-shadow: ${t} 6px 0 6px -6px inset;\n\t\t\t\t}\n\n\t\t\t\t.monaco-scrollable-element > .shadow.top.left {\n\t\t\t\t\tbox-shadow: ${t} 6px 6px 6px -6px inset;\n\t\t\t\t}\n\t\t\t`);const n=e.scrollbarSliderBackground;n&&(i+=`\n\t\t\t\t.monaco-scrollable-element > .scrollbar > .slider {\n\t\t\t\t\tbackground: ${n};\n\t\t\t\t}\n\t\t\t`);const o=e.scrollbarSliderHoverBackground;o&&(i+=`\n\t\t\t\t.monaco-scrollable-element > .scrollbar > .slider:hover {\n\t\t\t\t\tbackground: ${o};\n\t\t\t\t}\n\t\t\t`);const r=e.scrollbarSliderActiveBackground;r&&(i+=`\n\t\t\t\t.monaco-scrollable-element > .scrollbar > .slider.active {\n\t\t\t\t\tbackground: ${r};\n\t\t\t\t}\n\t\t\t`)}return i}(t,(0,ii.OO)(e))}style(e){const t=this.getContainer();this.initializeOrUpdateStyleSheet(t,e);const i=e.foregroundColor?`${e.foregroundColor}`:"",n=e.backgroundColor?`${e.backgroundColor}`:"",o=e.borderColor?`1px solid ${e.borderColor}`:"",r=e.shadowColor?`0 2px 4px ${e.shadowColor}`:"";t.style.border=o,this.domNode.style.color=i,this.domNode.style.backgroundColor=n,t.style.boxShadow=r,this.viewItems&&this.viewItems.forEach((t=>{(t instanceof Io||t instanceof Ao)&&t.style(e)}))}getContainer(){return this.scrollableElement.getDomNode()}get onScroll(){return this.scrollableElement.onScroll}focusItemByElement(e){const t=this.focusedItem;this.setFocusedItem(e),t!==this.focusedItem&&this.updateFocus()}setFocusedItem(e){for(let t=0;t{this.element&&(this._register((0,ii.nm)(this.element,ii.tw.MOUSE_UP,(e=>{if(ii.zB.stop(e,!0),_o.isFirefox){if(new fo.n(e).rightButton)return;this.onClick(e)}else setTimeout((()=>{this.onClick(e)}),0)}))),this._register((0,ii.nm)(this.element,ii.tw.CONTEXT_MENU,(e=>{ii.zB.stop(e,!0)}))))}),100),this._register(this.runOnceToEnableMouseUp)}render(e){super.render(e),this.element&&(this.container=e,this.item=(0,ii.R3)(this.element,(0,ii.$)("a.action-menu-item")),this._action.id===So.Z0.ID?this.item.setAttribute("role","presentation"):(this.item.setAttribute("role","menuitem"),this.mnemonic&&this.item.setAttribute("aria-keyshortcuts",`${this.mnemonic}`)),this.check=(0,ii.R3)(this.item,(0,ii.$)("span.menu-item-check"+xo.lA.menuSelection.cssSelector)),this.check.setAttribute("role","none"),this.label=(0,ii.R3)(this.item,(0,ii.$)("span.action-label")),this.options.label&&this.options.keybinding&&((0,ii.R3)(this.item,(0,ii.$)("span.keybinding")).textContent=this.options.keybinding),this.runOnceToEnableMouseUp.schedule(),this.updateClass(),this.updateLabel(),this.updateTooltip(),this.updateEnabled(),this.updateChecked())}blur(){super.blur(),this.applyStyle()}focus(){super.focus(),this.item&&this.item.focus(),this.applyStyle()}updatePositionInSet(e,t){this.item&&(this.item.setAttribute("aria-posinset",`${e}`),this.item.setAttribute("aria-setsize",`${t}`))}updateLabel(){if(this.label&&this.options.label){(0,ii.PO)(this.label);let e=(0,ko.x$)(this.getAction().label);if(e){const t=function(e){const t=Lo,i=t.exec(e);if(!i)return e;const n=!i[1];return e.replace(t,n?"$2$3":"").trim()}(e);this.options.enableMnemonics||(e=t),this.label.setAttribute("aria-label",t.replace(/&&/g,"&"));const i=Lo.exec(e);if(i){e=ue.YU(e),Eo.lastIndex=0;let t=Eo.exec(e);for(;t&&t[1];)t=Eo.exec(e);const n=e=>e.replace(/&&/g,"&");t?this.label.append(ue.j3(n(e.substr(0,t.index))," "),(0,ii.$)("u",{"aria-hidden":"true"},t[3]),ue.oL(n(e.substr(t.index+t[0].length))," ")):this.label.innerText=n(e).trim(),this.item&&this.item.setAttribute("aria-keyshortcuts",(i[1]?i[1]:i[3]).toLocaleLowerCase())}else this.label.innerText=e.replace(/&&/g,"&").trim()}}}updateTooltip(){}updateClass(){this.cssClass&&this.item&&this.item.classList.remove(...this.cssClass.split(" ")),this.options.icon&&this.label?(this.cssClass=this.getAction().class||"",this.label.classList.add("icon"),this.cssClass&&this.label.classList.add(...this.cssClass.split(" ")),this.updateEnabled()):this.label&&this.label.classList.remove("icon")}updateEnabled(){this.getAction().enabled?(this.element&&(this.element.classList.remove("disabled"),this.element.removeAttribute("aria-disabled")),this.item&&(this.item.classList.remove("disabled"),this.item.removeAttribute("aria-disabled"),this.item.tabIndex=0)):(this.element&&(this.element.classList.add("disabled"),this.element.setAttribute("aria-disabled","true")),this.item&&(this.item.classList.add("disabled"),this.item.setAttribute("aria-disabled","true")))}updateChecked(){if(!this.item)return;const e=this.getAction().checked;this.item.classList.toggle("checked",!!e),void 0!==e?(this.item.setAttribute("role","menuitemcheckbox"),this.item.setAttribute("aria-checked",e?"true":"false")):(this.item.setAttribute("role","menuitem"),this.item.setAttribute("aria-checked",""))}getMnemonic(){return this.mnemonic}applyStyle(){if(!this.menuStyle)return;const e=this.element&&this.element.classList.contains("focused"),t=e&&this.menuStyle.selectionForegroundColor?this.menuStyle.selectionForegroundColor:this.menuStyle.foregroundColor,i=e&&this.menuStyle.selectionBackgroundColor?this.menuStyle.selectionBackgroundColor:void 0,n=e&&this.menuStyle.selectionBorderColor?`thin solid ${this.menuStyle.selectionBorderColor}`:"";this.item&&(this.item.style.color=t?t.toString():"",this.item.style.backgroundColor=i?i.toString():""),this.check&&(this.check.style.color=t?t.toString():""),this.container&&(this.container.style.border=n)}style(e){this.menuStyle=e,this.applyStyle()}}class To extends Io{constructor(e,t,i,n){super(e,e,n),this.submenuActions=t,this.parentData=i,this.submenuOptions=n,this.mysubmenu=null,this.submenuDisposables=this._register(new Se.SL),this.mouseOver=!1,this.expandDirection=n&&void 0!==n.expandDirection?n.expandDirection:No.Right,this.showScheduler=new ye.pY((()=>{this.mouseOver&&(this.cleanupExistingSubmenu(!1),this.createSubmenu(!1))}),250),this.hideScheduler=new ye.pY((()=>{this.element&&!(0,ii.jg)((0,ii.vY)(),this.element)&&this.parentData.submenu===this.mysubmenu&&(this.parentData.parent.focus(!1),this.cleanupExistingSubmenu(!0))}),750)}render(e){super.render(e),this.element&&(this.item&&(this.item.classList.add("monaco-submenu-item"),this.item.tabIndex=0,this.item.setAttribute("aria-haspopup","true"),this.updateAriaExpanded("false"),this.submenuIndicator=(0,ii.R3)(this.item,(0,ii.$)("span.submenu-indicator"+xo.lA.menuSubmenu.cssSelector)),this.submenuIndicator.setAttribute("aria-hidden","true")),this._register((0,ii.nm)(this.element,ii.tw.KEY_UP,(e=>{let t=new Pi.y(e);(t.equals(17)||t.equals(3))&&(ii.zB.stop(e,!0),this.createSubmenu(!0))}))),this._register((0,ii.nm)(this.element,ii.tw.KEY_DOWN,(e=>{let t=new Pi.y(e);(0,ii.vY)()===this.item&&(t.equals(17)||t.equals(3))&&ii.zB.stop(e,!0)}))),this._register((0,ii.nm)(this.element,ii.tw.MOUSE_OVER,(e=>{this.mouseOver||(this.mouseOver=!0,this.showScheduler.schedule())}))),this._register((0,ii.nm)(this.element,ii.tw.MOUSE_LEAVE,(e=>{this.mouseOver=!1}))),this._register((0,ii.nm)(this.element,ii.tw.FOCUS_OUT,(e=>{this.element&&!(0,ii.jg)((0,ii.vY)(),this.element)&&this.hideScheduler.schedule()}))),this._register(this.parentData.parent.onScroll((()=>{this.parentData.parent.focus(!1),this.cleanupExistingSubmenu(!1)}))))}updateEnabled(){}onClick(e){ii.zB.stop(e,!0),this.cleanupExistingSubmenu(!1),this.createSubmenu(!0)}cleanupExistingSubmenu(e){if(this.parentData.submenu&&(e||this.parentData.submenu!==this.mysubmenu)){try{this.parentData.submenu.dispose()}catch(e){}this.parentData.submenu=void 0,this.updateAriaExpanded("false"),this.submenuContainer&&(this.submenuDisposables.clear(),this.submenuContainer=void 0)}}calculateSubmenuMenuLayout(e,t,i,n){const o={top:0,left:0};return o.left=Dn(e.width,t.width,{position:n===No.Right?0:1,offset:i.left,size:i.width}),o.left>=i.left&&o.left{new Pi.y(e).equals(15)&&(ii.zB.stop(e,!0),this.parentData.parent.focus(),this.cleanupExistingSubmenu(!0))}))),this.submenuDisposables.add((0,ii.nm)(this.submenuContainer,ii.tw.KEY_DOWN,(e=>{new Pi.y(e).equals(15)&&ii.zB.stop(e,!0)}))),this.submenuDisposables.add(this.parentData.submenu.onDidCancel((()=>{this.parentData.parent.focus(),this.cleanupExistingSubmenu(!0)}))),this.parentData.submenu.focus(e),this.mysubmenu=this.parentData.submenu}}updateAriaExpanded(e){var t;this.item&&(null===(t=this.item)||void 0===t||t.setAttribute("aria-expanded",e))}applyStyle(){if(super.applyStyle(),!this.menuStyle)return;const e=this.element&&this.element.classList.contains("focused")&&this.menuStyle.selectionForegroundColor?this.menuStyle.selectionForegroundColor:this.menuStyle.foregroundColor;this.submenuIndicator&&(this.submenuIndicator.style.color=e?`${e}`:""),this.parentData.submenu&&this.parentData.submenu.style(this.menuStyle)}dispose(){super.dispose(),this.hideScheduler.dispose(),this.mysubmenu&&(this.mysubmenu.dispose(),this.mysubmenu=null),this.submenuContainer&&(this.submenuContainer=void 0)}}class Ao extends Co.g{style(e){this.label&&(this.label.style.borderBottomColor=e.separatorColor?`${e.separatorColor}`:"")}}var Ro=i(39919),Mo={};Mo.styleTagTransform=le(),Mo.setAttributes=oe(),Mo.insert=ie().bind(null,"head"),Mo.domAPI=ee(),Mo.insertStyleElement=se(),X()(Ro.Z,Mo),Ro.Z&&Ro.Z.locals&&Ro.Z.locals;var Oo=i(64348);class Po{constructor(e,t,i,n,o){this.contextViewService=e,this.telemetryService=t,this.notificationService=i,this.keybindingService=n,this.themeService=o,this.focusToReturn=null,this.block=null,this.options={blockMouse:!0}}configure(e){this.options=e}showContextMenu(e){const t=e.getActions();if(!t.length)return;let i;this.focusToReturn=document.activeElement;let n=(0,ii.Re)(e.domForShadowRoot)?e.domForShadowRoot:void 0;this.contextViewService.showContextView({getAnchor:()=>e.getAnchor(),canRelayout:!1,anchorAlignment:e.anchorAlignment,anchorAxisAlignment:e.anchorAxisAlignment,render:n=>{let o=e.getMenuClassName?e.getMenuClassName():"";o&&(n.className+=" "+o),this.options.blockMouse&&(this.block=n.appendChild((0,ii.$)(".context-view-block")),this.block.style.position="fixed",this.block.style.cursor="initial",this.block.style.left="0",this.block.style.top="0",this.block.style.width="100%",this.block.style.height="100%",this.block.style.zIndex="-1",(0,ii.nm)(this.block,ii.tw.MOUSE_DOWN,(e=>e.stopPropagation())));const r=new Se.SL,s=e.actionRunner||new So.Wi;return s.onBeforeRun(this.onActionRun,this,r),s.onDidRun(this.onDidActionRun,this,r),i=new Do(n,t,{actionViewItemProvider:e.getActionViewItem,context:e.getActionsContext?e.getActionsContext():null,actionRunner:s,getKeyBinding:e.getKeyBinding?e.getKeyBinding:e=>this.keybindingService.lookupKeybinding(e.id)}),r.add((0,Oo.tj)(i,this.themeService)),i.onDidCancel((()=>this.contextViewService.hideContextView(!0)),null,r),i.onDidBlur((()=>this.contextViewService.hideContextView(!0)),null,r),r.add((0,ii.nm)(window,ii.tw.BLUR,(()=>this.contextViewService.hideContextView(!0)))),r.add((0,ii.nm)(window,ii.tw.MOUSE_DOWN,(e=>{if(e.defaultPrevented)return;let t=new fo.n(e),i=t.target;if(!t.rightButton){for(;i;){if(i===n)return;i=i.parentElement}this.contextViewService.hideContextView(!0)}}))),(0,Se.F8)(r,i)},focus:()=>{i&&i.focus(!!e.autoSelectFirstItem)},onHide:t=>{e.onHide&&e.onHide(!!t),this.block&&(this.block.remove(),this.block=null),this.focusToReturn&&this.focusToReturn.focus()}},n,!!n)}onActionRun(e){this.telemetryService.publicLog2("workbenchActionExecuted",{id:e.action.id,from:"contextMenu"}),this.contextViewService.hideContextView(!1),this.focusToReturn&&this.focusToReturn.focus()}onDidActionRun(e){e.error&&!(0,xe.n2)(e.error)&&this.notificationService.error(e.error)}}var Fo=function(e,t){return function(i,n){t(i,n,e)}};let Bo=class extends Se.JT{constructor(e,t,i,n,o){super(),this._onDidShowContextMenu=new z.Q5,this._onDidHideContextMenu=new z.Q5,this.contextMenuHandler=new Po(i,e,t,n,o)}configure(e){this.contextMenuHandler.configure(e)}showContextMenu(e){this.contextMenuHandler.showContextMenu(Object.assign(Object.assign({},e),{onHide:t=>{e.onHide&&e.onHide(t),this._onDidHideContextMenu.fire()}})),ii._q.getInstance().resetKeyStatus(),this._onDidShowContextMenu.fire()}};Bo=function(e,t,i,n){var o,r=arguments.length,s=r<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,i):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(e,t,i,n);else for(var a=e.length-1;a>=0;a--)(o=e[a])&&(s=(r<3?o(s):r>3?o(t,i,s):o(t,i))||s);return r>3&&s&&Object.defineProperty(t,i,s),s}([Fo(0,Cn.b),Fo(1,wi.lT),Fo(2,xn.u),Fo(3,an.d),Fo(4,oi.XE)],Bo);var Wo,Vo=i(57512),Ho=i(60491);!function(e){e[e.API=0]="API",e[e.USER=1]="USER"}(Wo||(Wo={}));var zo=i(82523),$o=function(e,t,i,n){var o,r=arguments.length,s=r<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,i):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(e,t,i,n);else for(var a=e.length-1;a>=0;a--)(o=e[a])&&(s=(r<3?o(s):r>3?o(t,i,s):o(t,i))||s);return r>3&&s&&Object.defineProperty(t,i,s),s},Uo=function(e,t){return function(i,n){t(i,n,e)}},jo=function(e,t,i,n){return new(i||(i=Promise))((function(o,r){function s(e){try{l(n.next(e))}catch(e){r(e)}}function a(e){try{l(n.throw(e))}catch(e){r(e)}}function l(e){var t;e.done?o(e.value):(t=e.value,t instanceof i?t:new i((function(e){e(t)}))).then(s,a)}l((n=n.apply(e,t||[])).next())}))};let Ko=class{constructor(e){this._commandService=e}open(e,t){return jo(this,void 0,void 0,(function*(){if(!(0,zo.xn)(e,ni.lg.command))return!1;if(!(null==t?void 0:t.allowCommands))return!0;"string"==typeof e&&(e=U.o.parse(e));let i=[];try{i=(0,Ho.Q)(decodeURIComponent(e.query))}catch(t){try{i=(0,Ho.Q)(e.query)}catch(e){}}return Array.isArray(i)||(i=[i]),yield this._commandService.executeCommand(e.path,...i),!0}))}};Ko=$o([Uo(0,Zi.Hy)],Ko);let qo=class{constructor(e){this._editorService=e}open(e,t){return jo(this,void 0,void 0,(function*(){"string"==typeof e&&(e=U.o.parse(e));const{selection:i,uri:n}=(0,zo.xI)(e);return(e=n).scheme===ni.lg.file&&(e=(0,io.AH)(e)),yield this._editorService.openCodeEditor({resource:e,options:Object.assign({selection:i,source:(null==t?void 0:t.fromUserGesture)?Wo.USER:Wo.API},null==t?void 0:t.editorOptions)},this._editorService.getFocusedCodeEditor(),null==t?void 0:t.openToSide),!0}))}};qo=$o([Uo(0,ge.$)],qo);let Go=class{constructor(e,t){this._openers=new Vo.S,this._validators=new Vo.S,this._resolvers=new Vo.S,this._resolvedUriTargets=new Qi.Y9((e=>e.with({path:null,fragment:null,query:null}).toString())),this._externalOpeners=new Vo.S,this._defaultExternalOpener={openExternal:e=>jo(this,void 0,void 0,(function*(){return(0,zo.Gs)(e,ni.lg.http,ni.lg.https)?ii.V3(e):window.location.href=e,!0}))},this._openers.push({open:(e,t)=>jo(this,void 0,void 0,(function*(){return!(!(null==t?void 0:t.openExternal)&&!(0,zo.Gs)(e,ni.lg.mailto,ni.lg.http,ni.lg.https,ni.lg.vsls)||(yield this._doOpenExternal(e,t),0))}))}),this._openers.push(new Ko(t)),this._openers.push(new qo(e))}registerOpener(e){return{dispose:this._openers.unshift(e)}}registerValidator(e){return{dispose:this._validators.push(e)}}registerExternalUriResolver(e){return{dispose:this._resolvers.push(e)}}setDefaultExternalOpener(e){this._defaultExternalOpener=e}registerExternalOpener(e){return{dispose:this._externalOpeners.push(e)}}open(e,t){var i;return jo(this,void 0,void 0,(function*(){const n="string"==typeof e?U.o.parse(e):e,o=null!==(i=this._resolvedUriTargets.get(n))&&void 0!==i?i:e;for(const e of this._validators)if(!(yield e.shouldOpen(o)))return!1;for(const i of this._openers)if(yield i.open(e,t))return!0;return!1}))}resolveExternalUri(e,t){return jo(this,void 0,void 0,(function*(){for(const i of this._resolvers)try{const n=yield i.resolveExternalUri(e,t);if(n)return this._resolvedUriTargets.has(n.resolved)||this._resolvedUriTargets.set(n.resolved,e),n}catch(e){}throw new Error("Could not resolve external URI: "+e.toString())}))}_doOpenExternal(e,t){return jo(this,void 0,void 0,(function*(){const i="string"==typeof e?U.o.parse(e):e;let n,o;try{n=(yield this.resolveExternalUri(i,t)).resolved}catch(e){n=i}if(o="string"==typeof e&&i.toString()===n.toString()?e:encodeURI(n.toString(!0)),null==t?void 0:t.allowContributedOpeners){const e="string"==typeof(null==t?void 0:t.allowContributedOpeners)?null==t?void 0:t.allowContributedOpeners:void 0;for(const t of this._externalOpeners)if(yield t.openExternal(o,{sourceUri:i,preferredOpenerId:e},H.T.None))return!0}return this._defaultExternalOpener.openExternal(o,{sourceUri:i},H.T.None)}))}dispose(){this._validators.clear()}};Go=$o([Uo(0,ge.$),Uo(1,Zi.Hy)],Go);var Zo=i(27498),Yo=i(4773),Qo=i(45164),Xo=function(e,t){return function(i,n){t(i,n,e)}};class Jo extends Se.JT{constructor(e){super(),this.model=e,this._markersData=new Map,this._register((0,Se.OF)((()=>{this.model.deltaDecorations([...this._markersData.keys()],[]),this._markersData.clear()})))}update(e,t){const i=[...this._markersData.keys()];this._markersData.clear();const n=this.model.deltaDecorations(i,t);for(let t=0;tthis._onModelAdded(e))),this._register(e.onModelAdded(this._onModelAdded,this)),this._register(e.onModelRemoved(this._onModelRemoved,this)),this._register(this._markerService.onMarkerChanged(this._handleMarkerChange,this))}dispose(){super.dispose(),this._markerDecorations.forEach((e=>e.dispose())),this._markerDecorations.clear()}getMarker(e,t){const i=this._markerDecorations.get(e);return i&&i.getMarker(t)||null}_handleMarkerChange(e){e.forEach((e=>{const t=this._markerDecorations.get(e);t&&this._updateDecorations(t)}))}_onModelAdded(e){const t=new Jo(e);this._markerDecorations.set(e.uri,t),this._updateDecorations(t)}_onModelRemoved(e){const t=this._markerDecorations.get(e.uri);t&&(t.dispose(),this._markerDecorations.delete(e.uri)),e.uri.scheme!==ni.lg.inMemory&&e.uri.scheme!==ni.lg.internal&&e.uri.scheme!==ni.lg.vscode||this._markerService&&this._markerService.read({resource:e.uri}).map((e=>e.owner)).forEach((t=>this._markerService.remove(t,[e.uri])))}_updateDecorations(e){const t=this._markerService.read({resource:e.model.uri,take:500}),i=t.map((t=>({range:this._createDecorationRange(e.model,t),options:this._createDecorationOption(t)})));e.update(t,i)&&this._onDidChangeMarker.fire(e.model)}_createDecorationRange(e,t){let i=K.e.lift(t);if(t.severity!==Zo.ZL.Hint||this._hasMarkerTag(t,1)||this._hasMarkerTag(t,2)||(i=i.setEndPosition(i.startLineNumber,i.startColumn+2)),i=e.validateRange(i),i.isEmpty()){const t=e.getLineLastNonWhitespaceColumn(i.startLineNumber)||e.getLineMaxColumn(i.startLineNumber);if(1===t||i.endColumn>=t)return i;const n=e.getWordAtPosition(i.getStartPosition());n&&(i=new K.e(i.startLineNumber,n.startColumn,i.endLineNumber,n.endColumn))}else if(t.endColumn===Number.MAX_VALUE&&1===t.startColumn&&i.startLineNumber===i.endLineNumber){let n=e.getLineFirstNonWhitespaceColumn(t.startLineNumber);n=0}};er=function(e,t,i,n){var o,r=arguments.length,s=r<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,i):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(e,t,i,n);else for(var a=e.length-1;a>=0;a--)(o=e[a])&&(s=(r<3?o(s):r>3?o(t,i,s):o(t,i))||s);return r>3&&s&&Object.defineProperty(t,i,s),s}([Xo(0,we.q),Xo(1,Zo.lT)],er);var tr=i(95471),ir=i(14902),nr=i(98581),or={};or.styleTagTransform=le(),or.setAttributes=oe(),or.insert=ie().bind(null,"head"),or.domAPI=ee(),or.insertStyleElement=se(),X()(nr.Z,or),nr.Z&&nr.Z.locals&&nr.Z.locals;var rr=i(4189),sr=i(33060),ar=i(80563),lr=i(18689),cr=i(33767),dr={};dr.styleTagTransform=le(),dr.setAttributes=oe(),dr.insert=ie().bind(null,"head"),dr.domAPI=ee(),dr.insertStyleElement=se(),X()(cr.Z,dr),cr.Z&&cr.Z.locals&&cr.Z.locals;const ur={buttonBackground:lr.Il.fromHex("#0E639C"),buttonHoverBackground:lr.Il.fromHex("#006BB3"),buttonForeground:lr.Il.white};class hr extends Se.JT{constructor(e,t){super(),this._onDidClick=this._register(new z.Q5),this.options=t||Object.create(null),(0,Xi.jB)(this.options,ur,!1),this.buttonForeground=this.options.buttonForeground,this.buttonBackground=this.options.buttonBackground,this.buttonHoverBackground=this.options.buttonHoverBackground,this.buttonSecondaryForeground=this.options.buttonSecondaryForeground,this.buttonSecondaryBackground=this.options.buttonSecondaryBackground,this.buttonSecondaryHoverBackground=this.options.buttonSecondaryHoverBackground,this.buttonBorder=this.options.buttonBorder,this._element=document.createElement("a"),this._element.classList.add("monaco-button"),this._element.tabIndex=0,this._element.setAttribute("role","button"),e.appendChild(this._element),this._register(bo.o.addTarget(this._element)),[ii.tw.CLICK,bo.t.Tap].forEach((e=>{this._register((0,ii.nm)(this._element,e,(e=>{this.enabled?this._onDidClick.fire(e):ii.zB.stop(e)})))})),this._register((0,ii.nm)(this._element,ii.tw.KEY_DOWN,(e=>{const t=new Pi.y(e);let i=!1;this.enabled&&(t.equals(3)||t.equals(10))?(this._onDidClick.fire(e),i=!0):t.equals(9)&&(this._element.blur(),i=!0),i&&ii.zB.stop(t,!0)}))),this._register((0,ii.nm)(this._element,ii.tw.MOUSE_OVER,(e=>{this._element.classList.contains("disabled")||this.setHoverBackground()}))),this._register((0,ii.nm)(this._element,ii.tw.MOUSE_OUT,(e=>{this.applyStyles()}))),this.focusTracker=this._register((0,ii.go)(this._element)),this._register(this.focusTracker.onDidFocus((()=>this.setHoverBackground()))),this._register(this.focusTracker.onDidBlur((()=>this.applyStyles()))),this.applyStyles()}get onDidClick(){return this._onDidClick.event}setHoverBackground(){let e;e=this.options.secondary?this.buttonSecondaryHoverBackground?this.buttonSecondaryHoverBackground.toString():null:this.buttonHoverBackground?this.buttonHoverBackground.toString():null,e&&(this._element.style.backgroundColor=e)}style(e){this.buttonForeground=e.buttonForeground,this.buttonBackground=e.buttonBackground,this.buttonHoverBackground=e.buttonHoverBackground,this.buttonSecondaryForeground=e.buttonSecondaryForeground,this.buttonSecondaryBackground=e.buttonSecondaryBackground,this.buttonSecondaryHoverBackground=e.buttonSecondaryHoverBackground,this.buttonBorder=e.buttonBorder,this.applyStyles()}applyStyles(){if(this._element){let e,t;this.options.secondary?(t=this.buttonSecondaryForeground?this.buttonSecondaryForeground.toString():"",e=this.buttonSecondaryBackground?this.buttonSecondaryBackground.toString():""):(t=this.buttonForeground?this.buttonForeground.toString():"",e=this.buttonBackground?this.buttonBackground.toString():"");const i=this.buttonBorder?this.buttonBorder.toString():"";this._element.style.color=t,this._element.style.backgroundColor=e,this._element.style.borderWidth=i?"1px":"",this._element.style.borderStyle=i?"solid":"",this._element.style.borderColor=i}}get element(){return this._element}set label(e){this._element.classList.add("monaco-text-button"),this.options.supportIcons?(0,ii.mc)(this._element,...(0,ar.T)(e)):this._element.textContent=e,"string"==typeof this.options.title?this._element.title=this.options.title:this.options.title&&(this._element.title=e)}set enabled(e){e?(this._element.classList.remove("disabled"),this._element.setAttribute("aria-disabled",String(!1)),this._element.tabIndex=0):(this._element.classList.add("disabled"),this._element.setAttribute("aria-disabled",String(!0)))}get enabled(){return!this._element.classList.contains("disabled")}}var gr=i(38408),pr=i(451),mr={};mr.styleTagTransform=le(),mr.setAttributes=oe(),mr.insert=ie().bind(null,"head"),mr.domAPI=ee(),mr.insertStyleElement=se(),X()(pr.Z,mr),pr.Z&&pr.Z.locals&&pr.Z.locals;const fr="done",_r="active",br="infinite",vr="infinite-long-running",Cr="discrete",wr={progressBarBackground:lr.Il.fromHex("#0E70C0")};class yr extends Se.JT{constructor(e,t){super(),this.options=t||Object.create(null),(0,Xi.jB)(this.options,wr,!1),this.workedVal=0,this.progressBarBackground=this.options.progressBarBackground,this.showDelayedScheduler=this._register(new ye.pY((()=>(0,ii.$Z)(this.element)),0)),this.longRunningScheduler=this._register(new ye.pY((()=>this.infiniteLongRunning()),yr.LONG_RUNNING_INFINITE_THRESHOLD)),this.create(e)}create(e){this.element=document.createElement("div"),this.element.classList.add("monaco-progress-container"),this.element.setAttribute("role","progressbar"),this.element.setAttribute("aria-valuemin","0"),e.appendChild(this.element),this.bit=document.createElement("div"),this.bit.classList.add("progress-bit"),this.element.appendChild(this.bit),this.applyStyles()}off(){this.bit.style.width="inherit",this.bit.style.opacity="1",this.element.classList.remove(_r,br,vr,Cr),this.workedVal=0,this.totalWork=void 0,this.longRunningScheduler.cancel()}stop(){return this.doDone(!1)}doDone(e){return this.element.classList.add(fr),this.element.classList.contains(br)?(this.bit.style.opacity="0",e?setTimeout((()=>this.off()),200):this.off()):(this.bit.style.width="inherit",e?setTimeout((()=>this.off()),200):this.off()),this}infinite(){return this.bit.style.width="2%",this.bit.style.opacity="1",this.element.classList.remove(Cr,fr,vr),this.element.classList.add(_r,br),this.longRunningScheduler.schedule(),this}infiniteLongRunning(){this.element.classList.add(vr)}getContainer(){return this.element}style(e){this.progressBarBackground=e.progressBarBackground,this.applyStyles()}applyStyles(){if(this.bit){const e=this.progressBarBackground?this.progressBarBackground.toString():"";this.bit.style.backgroundColor=e}}}yr.LONG_RUNNING_INFINITE_THRESHOLD=1e4;var Sr=i(68332),xr=i(61699),kr={};kr.styleTagTransform=le(),kr.setAttributes=oe(),kr.insert=ie().bind(null,"head"),kr.domAPI=ee(),kr.insertStyleElement=se(),X()(xr.Z,kr),xr.Z&&xr.Z.locals&&xr.Z.locals;const Lr={},Er=new Sr.R("quick-input-button-icon-");function Nr(e){if(!e)return;let t;const i=e.dark.toString();return Lr[i]?t=Lr[i]:(t=Er.nextId(),ii.fk(`.${t}`,`background-image: ${ii.wY(e.light||e.dark)}`),ii.fk(`.vs-dark .${t}, .hc-black .${t}`,`background-image: ${ii.wY(e.dark)}`),Lr[i]=t),t}var Dr=i(55470),Ir=i(17172);const Tr=ii.$;class Ar extends Se.JT{constructor(e){super(),this.parent=e,this.onKeyDown=e=>ii.nm(this.inputBox.inputElement,ii.tw.KEY_DOWN,(t=>{e(new Pi.y(t))})),this.onMouseDown=e=>ii.nm(this.inputBox.inputElement,ii.tw.MOUSE_DOWN,(t=>{e(new fo.n(t))})),this.onDidChange=e=>this.inputBox.onDidChange(e),this.container=ii.R3(this.parent,Tr(".quick-input-box")),this.inputBox=this._register(new Ir.W(this.container,void 0))}get value(){return this.inputBox.value}set value(e){this.inputBox.value=e}select(e=null){this.inputBox.select(e)}isSelectionAtEnd(){return this.inputBox.isSelectionAtEnd()}get placeholder(){return this.inputBox.inputElement.getAttribute("placeholder")||""}set placeholder(e){this.inputBox.setPlaceHolder(e)}get ariaLabel(){return this.inputBox.getAriaLabel()}set ariaLabel(e){this.inputBox.setAriaLabel(e)}get password(){return"password"===this.inputBox.inputElement.type}set password(e){this.inputBox.inputElement.type=e?"password":"text"}setAttribute(e,t){this.inputBox.inputElement.setAttribute(e,t)}removeAttribute(e){this.inputBox.inputElement.removeAttribute(e)}showDecoration(e){e===bi.Z.Ignore?this.inputBox.hideMessage():this.inputBox.showMessage({type:e===bi.Z.Info?1:e===bi.Z.Warning?2:3,content:""})}stylesForType(e){return this.inputBox.stylesForType(e===bi.Z.Info?1:e===bi.Z.Warning?2:3)}setFocus(){this.inputBox.focus()}layout(){this.inputBox.layout()}style(e){this.inputBox.style(e)}}var Rr=i(77982),Mr=i(17200),Or={};Or.styleTagTransform=le(),Or.setAttributes=oe(),Or.insert=ie().bind(null,"head"),Or.domAPI=ee(),Or.insertStyleElement=se(),X()(Mr.Z,Or),Mr.Z&&Mr.Z.locals&&Mr.Z.locals;const Pr=ii.$;class Fr{constructor(e,t,i){this.os=t,this.keyElements=new Set,this.options=i||Object.create(null),this.labelBackground=this.options.keybindingLabelBackground,this.labelForeground=this.options.keybindingLabelForeground,this.labelBorder=this.options.keybindingLabelBorder,this.labelBottomBorder=this.options.keybindingLabelBottomBorder,this.labelShadow=this.options.keybindingLabelShadow,this.domNode=ii.R3(e,Pr(".monaco-keybinding")),this.didEverRender=!1,e.appendChild(this.domNode)}get element(){return this.domNode}set(e,t){this.didEverRender&&this.keybinding===e&&Fr.areSame(this.matches,t)||(this.keybinding=e,this.matches=t,this.render())}render(){if(this.clear(),this.keybinding){let[e,t]=this.keybinding.getParts();e&&this.renderPart(this.domNode,e,this.matches?this.matches.firstPart:null),t&&(ii.R3(this.domNode,Pr("span.monaco-keybinding-key-chord-separator",void 0," ")),this.renderPart(this.domNode,t,this.matches?this.matches.chordPart:null)),this.domNode.title=this.keybinding.getAriaLabel()||""}else this.options&&this.options.renderUnboundKeybindings&&this.renderUnbound(this.domNode);this.applyStyles(),this.didEverRender=!0}clear(){ii.PO(this.domNode),this.keyElements.clear()}renderPart(e,t,i){const n=pn.xo.modifierLabels[this.os];t.ctrlKey&&this.renderKey(e,n.ctrlKey,Boolean(null==i?void 0:i.ctrlKey),n.separator),t.shiftKey&&this.renderKey(e,n.shiftKey,Boolean(null==i?void 0:i.shiftKey),n.separator),t.altKey&&this.renderKey(e,n.altKey,Boolean(null==i?void 0:i.altKey),n.separator),t.metaKey&&this.renderKey(e,n.metaKey,Boolean(null==i?void 0:i.metaKey),n.separator);const o=t.keyLabel;o&&this.renderKey(e,o,Boolean(null==i?void 0:i.keyCode),"")}renderKey(e,t,i,n){ii.R3(e,this.createKeyElement(t,i?".highlight":"")),n&&ii.R3(e,Pr("span.monaco-keybinding-key-separator",void 0,n))}renderUnbound(e){ii.R3(e,this.createKeyElement((0,vi.NC)("vs/base/browser/ui/keybindingLabel/keybindingLabel","unbound","Unbound")))}createKeyElement(e,t=""){const i=Pr("span.monaco-keybinding-key"+t,void 0,e);return this.keyElements.add(i),i}style(e){this.labelBackground=e.keybindingLabelBackground,this.labelForeground=e.keybindingLabelForeground,this.labelBorder=e.keybindingLabelBorder,this.labelBottomBorder=e.keybindingLabelBottomBorder,this.labelShadow=e.keybindingLabelShadow,this.applyStyles()}applyStyles(){var e;if(this.element){for(const t of this.keyElements)this.labelBackground&&(t.style.backgroundColor=null===(e=this.labelBackground)||void 0===e?void 0:e.toString()),this.labelBorder&&(t.style.borderColor=this.labelBorder.toString()),this.labelBottomBorder&&(t.style.borderBottomColor=this.labelBottomBorder.toString()),this.labelShadow&&(t.style.boxShadow=`inset 0 -1px 0 ${this.labelShadow}`);this.labelForeground&&(this.element.style.color=this.labelForeground.toString())}}static areSame(e,t){return e===t||!e&&!t||!!e&&!!t&&(0,Xi.fS)(e.firstPart,t.firstPart)&&(0,Xi.fS)(e.chordPart,t.chordPart)}}const Br=new ye.Ue((()=>{const e=new Intl.Collator(void 0,{numeric:!0,sensitivity:"base"});return{collator:e,collatorIsNumeric:e.resolvedOptions().numeric}}));new ye.Ue((()=>({collator:new Intl.Collator(void 0,{numeric:!0})}))),new ye.Ue((()=>({collator:new Intl.Collator(void 0,{numeric:!0,sensitivity:"accent"})})));var Wr=i(79945),Vr=function(e,t,i,n){var o,r=arguments.length,s=r<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,i):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(e,t,i,n);else for(var a=e.length-1;a>=0;a--)(o=e[a])&&(s=(r<3?o(s):r>3?o(t,i,s):o(t,i))||s);return r>3&&s&&Object.defineProperty(t,i,s),s};const Hr=ii.$;class zr{constructor(e){this.hidden=!1,this._onChecked=new z.Q5,this.onChecked=this._onChecked.event,Object.assign(this,e)}get checked(){return!!this._checked}set checked(e){e!==this._checked&&(this._checked=e,this._onChecked.fire(e))}dispose(){this._onChecked.dispose()}}class $r{get templateId(){return $r.ID}renderTemplate(e){const t=Object.create(null);t.toDisposeElement=[],t.toDisposeTemplate=[],t.entry=ii.R3(e,Hr(".quick-input-list-entry"));const i=ii.R3(t.entry,Hr("label.quick-input-list-label"));t.toDisposeTemplate.push(ii.mu(i,ii.tw.CLICK,(e=>{t.checkbox.offsetParent||e.preventDefault()}))),t.checkbox=ii.R3(i,Hr("input.quick-input-list-checkbox")),t.checkbox.type="checkbox",t.toDisposeTemplate.push(ii.mu(t.checkbox,ii.tw.CHANGE,(e=>{t.element.checked=t.checkbox.checked})));const n=ii.R3(i,Hr(".quick-input-list-rows")),o=ii.R3(n,Hr(".quick-input-list-row")),r=ii.R3(n,Hr(".quick-input-list-row"));t.label=new Rr.g(o,{supportHighlights:!0,supportDescriptionHighlights:!0,supportIcons:!0});const s=ii.R3(o,Hr(".quick-input-list-entry-keybinding"));t.keybinding=new Fr(s,ke.OS);const a=ii.R3(r,Hr(".quick-input-list-label-meta"));return t.detail=new Rr.g(a,{supportHighlights:!0,supportIcons:!0}),t.separator=ii.R3(t.entry,Hr(".quick-input-list-separator")),t.actionBar=new vo.o(t.entry),t.actionBar.domNode.classList.add("quick-input-list-entry-action-bar"),t.toDisposeTemplate.push(t.actionBar),t}renderElement(e,t,i){i.toDisposeElement=(0,Se.B9)(i.toDisposeElement),i.element=e,i.checkbox.checked=e.checked,i.toDisposeElement.push(e.onChecked((e=>i.checkbox.checked=e)));const{labelHighlights:n,descriptionHighlights:o,detailHighlights:r}=e,s=Object.create(null);s.matches=n||[],s.descriptionTitle=e.saneDescription,s.descriptionMatches=o||[],s.extraClasses=e.item.iconClasses,s.italic=e.item.italic,s.strikethrough=e.item.strikethrough,i.label.setLabel(e.saneLabel,e.saneDescription,s),i.keybinding.set(e.item.keybinding),e.saneDetail&&i.detail.setLabel(e.saneDetail,void 0,{matches:r,title:e.saneDetail}),e.separator&&e.separator.label?(i.separator.textContent=e.separator.label,i.separator.style.display=""):i.separator.style.display="none",i.entry.classList.toggle("quick-input-list-separator-border",!!e.separator),i.actionBar.clear();const a=e.item.buttons;a&&a.length?(i.actionBar.push(a.map(((t,i)=>{let n=t.iconClass||(t.iconPath?Nr(t.iconPath):void 0);t.alwaysVisible&&(n=n?`${n} always-visible`:"always-visible");const o=new So.aU(`id-${i}`,"",n,!0,(()=>{return i=this,n=void 0,r=function*(){e.fireButtonTriggered({button:t,item:e.item})},new((o=void 0)||(o=Promise))((function(e,t){function s(e){try{l(r.next(e))}catch(e){t(e)}}function a(e){try{l(r.throw(e))}catch(e){t(e)}}function l(t){var i;t.done?e(t.value):(i=t.value,i instanceof o?i:new o((function(e){e(i)}))).then(s,a)}l((r=r.apply(i,n||[])).next())}));var i,n,o,r}));return o.tooltip=t.tooltip||"",o})),{icon:!0,label:!1}),i.entry.classList.add("has-actions")):i.entry.classList.remove("has-actions")}disposeElement(e,t,i){i.toDisposeElement=(0,Se.B9)(i.toDisposeElement)}disposeTemplate(e){e.toDisposeElement=(0,Se.B9)(e.toDisposeElement),e.toDisposeTemplate=(0,Se.B9)(e.toDisposeTemplate)}}$r.ID="listelement";class Ur{getHeight(e){return e.saneDetail?44:22}getTemplateId(e){return $r.ID}}var jr;!function(e){e[e.First=1]="First",e[e.Second=2]="Second",e[e.Last=3]="Last",e[e.Next=4]="Next",e[e.Previous=5]="Previous",e[e.NextPage=6]="NextPage",e[e.PreviousPage=7]="PreviousPage"}(jr||(jr={}));class Kr{constructor(e,t,i){this.parent=e,this.inputElements=[],this.elements=[],this.elementsToIndexes=new Map,this.matchOnDescription=!1,this.matchOnDetail=!1,this.matchOnLabel=!0,this.matchOnMeta=!0,this.sortByLabel=!0,this._onChangedAllVisibleChecked=new z.Q5,this.onChangedAllVisibleChecked=this._onChangedAllVisibleChecked.event,this._onChangedCheckedCount=new z.Q5,this.onChangedCheckedCount=this._onChangedCheckedCount.event,this._onChangedVisibleCount=new z.Q5,this.onChangedVisibleCount=this._onChangedVisibleCount.event,this._onChangedCheckedElements=new z.Q5,this.onChangedCheckedElements=this._onChangedCheckedElements.event,this._onButtonTriggered=new z.Q5,this.onButtonTriggered=this._onButtonTriggered.event,this._onKeyDown=new z.Q5,this.onKeyDown=this._onKeyDown.event,this._onLeave=new z.Q5,this.onLeave=this._onLeave.event,this._fireCheckedEvents=!0,this.elementDisposables=[],this.disposables=[],this.id=t,this.container=ii.R3(this.parent,Hr(".quick-input-list"));const n=new Ur,o=new qr;this.list=i.createList("QuickInput",this.container,n,[new $r],{identityProvider:{getId:e=>e.saneLabel},setRowLineHeight:!1,multipleSelectionSupport:!1,horizontalScrolling:!1,accessibilityProvider:o}),this.list.getHTMLElement().id=t,this.disposables.push(this.list),this.disposables.push(this.list.onKeyDown((e=>{const t=new Pi.y(e);switch(t.keyCode){case 10:this.toggleCheckbox();break;case 31:(ke.dz?e.metaKey:e.ctrlKey)&&this.list.setFocus((0,gt.w6)(this.list.length));break;case 16:{const e=this.list.getFocus();1===e.length&&0===e[0]&&this._onLeave.fire();break}case 18:{const e=this.list.getFocus();1===e.length&&e[0]===this.list.length-1&&this._onLeave.fire();break}}this._onKeyDown.fire(t)}))),this.disposables.push(this.list.onMouseDown((e=>{2!==e.browserEvent.button&&e.browserEvent.preventDefault()}))),this.disposables.push(ii.nm(this.container,ii.tw.CLICK,(e=>{(e.x||e.y)&&this._onLeave.fire()}))),this.disposables.push(this.list.onMouseMiddleClick((e=>{this._onLeave.fire()}))),this.disposables.push(this.list.onContextMenu((e=>{"number"==typeof e.index&&(e.browserEvent.preventDefault(),this.list.setSelection([e.index]))}))),this.disposables.push(this._onChangedAllVisibleChecked,this._onChangedCheckedCount,this._onChangedVisibleCount,this._onChangedCheckedElements,this._onButtonTriggered,this._onLeave,this._onKeyDown)}get onDidChangeFocus(){return z.ju.map(this.list.onDidChangeFocus,(e=>e.elements.map((e=>e.item))))}get onDidChangeSelection(){return z.ju.map(this.list.onDidChangeSelection,(e=>({items:e.elements.map((e=>e.item)),event:e.browserEvent})))}get scrollTop(){return this.list.scrollTop}set scrollTop(e){this.list.scrollTop=e}getAllVisibleChecked(){return this.allVisibleChecked(this.elements,!1)}allVisibleChecked(e,t=!0){for(let i=0,n=e.length;i{t.hidden||(t.checked=e)}))}finally{this._fireCheckedEvents=!0,this.fireCheckedEvents()}}setElements(e){this.elementDisposables=(0,Se.B9)(this.elementDisposables);const t=e=>this.fireButtonTriggered(e);this.inputElements=e,this.elements=e.reduce(((i,n,o)=>{var r,s,a;if("separator"!==n.type){const l=o&&e[o-1],c=n.label&&n.label.replace(/\r?\n/g," "),d=n.meta&&n.meta.replace(/\r?\n/g," "),u=n.description&&n.description.replace(/\r?\n/g," "),h=n.detail&&n.detail.replace(/\r?\n/g," "),g=n.ariaLabel||[c,u,h].map((e=>(0,xo.JL)(e))).filter((e=>!!e)).join(", "),p=this.parent.classList.contains("show-checkboxes");i.push(new zr({hasCheckbox:p,index:o,item:n,saneLabel:c,saneMeta:d,saneAriaLabel:g,saneDescription:u,saneDetail:h,labelHighlights:null===(r=n.highlights)||void 0===r?void 0:r.label,descriptionHighlights:null===(s=n.highlights)||void 0===s?void 0:s.description,detailHighlights:null===(a=n.highlights)||void 0===a?void 0:a.detail,checked:!1,separator:l&&"separator"===l.type?l:void 0,fireButtonTriggered:t}))}return i}),[]),this.elementDisposables.push(...this.elements),this.elementDisposables.push(...this.elements.map((e=>e.onChecked((()=>this.fireCheckedEvents()))))),this.elementsToIndexes=this.elements.reduce(((e,t,i)=>(e.set(t.item,i),e)),new Map),this.list.splice(0,this.list.length),this.list.splice(0,this.list.length,this.elements),this._onChangedVisibleCount.fire(this.elements.length)}getFocusedElements(){return this.list.getFocusedElements().map((e=>e.item))}setFocusedElements(e){if(this.list.setFocus(e.filter((e=>this.elementsToIndexes.has(e))).map((e=>this.elementsToIndexes.get(e)))),e.length>0){const e=this.list.getFocus()[0];"number"==typeof e&&this.list.reveal(e)}}getActiveDescendant(){return this.list.getHTMLElement().getAttribute("aria-activedescendant")}setSelectedElements(e){this.list.setSelection(e.filter((e=>this.elementsToIndexes.has(e))).map((e=>this.elementsToIndexes.get(e))))}getCheckedElements(){return this.elements.filter((e=>e.checked)).map((e=>e.item))}setCheckedElements(e){try{this._fireCheckedEvents=!1;const t=new Set;for(const i of e)t.add(i);for(const e of this.elements)e.checked=t.has(e.item)}finally{this._fireCheckedEvents=!0,this.fireCheckedEvents()}}set enabled(e){this.list.getHTMLElement().style.pointerEvents=e?"":"none"}focus(e){if(!this.list.length)return;switch(e===jr.Next&&this.list.getFocus()[0]===this.list.length-1&&(e=jr.First),e===jr.Previous&&0===this.list.getFocus()[0]&&(e=jr.Last),e===jr.Second&&this.list.length<2&&(e=jr.First),e){case jr.First:this.list.focusFirst();break;case jr.Second:this.list.focusNth(1);break;case jr.Last:this.list.focusLast();break;case jr.Next:this.list.focusNext();break;case jr.Previous:this.list.focusPrevious();break;case jr.NextPage:this.list.focusNextPage();break;case jr.PreviousPage:this.list.focusPreviousPage()}const t=this.list.getFocus()[0];"number"==typeof t&&this.list.reveal(t)}clearFocus(){this.list.setFocus([])}domFocus(){this.list.domFocus()}layout(e){this.list.getHTMLElement().style.maxHeight=e?`calc(${44*Math.floor(e/44)}px)`:"",this.list.layout()}filter(e){if(!(this.sortByLabel||this.matchOnLabel||this.matchOnDescription||this.matchOnDetail))return this.list.layout(),!1;if((e=e.trim())&&(this.matchOnLabel||this.matchOnDescription||this.matchOnDetail)){let t;this.elements.forEach((i=>{const n=this.matchOnLabel?(0,Le.f6)((0,ko.Gt)(e,(0,ko.Ho)(i.saneLabel))):void 0,o=this.matchOnDescription?(0,Le.f6)((0,ko.Gt)(e,(0,ko.Ho)(i.saneDescription||""))):void 0,r=this.matchOnDetail?(0,Le.f6)((0,ko.Gt)(e,(0,ko.Ho)(i.saneDetail||""))):void 0,s=this.matchOnMeta?(0,Le.f6)((0,ko.Gt)(e,(0,ko.Ho)(i.saneMeta||""))):void 0;if(n||o||r||s?(i.labelHighlights=n,i.descriptionHighlights=o,i.detailHighlights=r,i.hidden=!1):(i.labelHighlights=void 0,i.descriptionHighlights=void 0,i.detailHighlights=void 0,i.hidden=!i.item.alwaysShow),i.separator=void 0,!this.sortByLabel){const e=i.index&&this.inputElements[i.index-1];t=e&&"separator"===e.type?e:t,t&&!i.hidden&&(i.separator=t,t=void 0)}}))}else this.elements.forEach((e=>{e.labelHighlights=void 0,e.descriptionHighlights=void 0,e.detailHighlights=void 0,e.hidden=!1;const t=e.index&&this.inputElements[e.index-1];e.separator=t&&"separator"===t.type?t:void 0}));const t=this.elements.filter((e=>!e.hidden));if(this.sortByLabel&&e){const i=e.toLowerCase();t.sort(((e,t)=>function(e,t,i){const n=e.labelHighlights||[],o=t.labelHighlights||[];return n.length&&!o.length?-1:!n.length&&o.length?1:0===n.length&&0===o.length?0:function(e,t,i){const n=e.toLowerCase(),o=t.toLowerCase(),r=function(e,t,i){const n=e.toLowerCase(),o=t.toLowerCase(),r=n.startsWith(i),s=o.startsWith(i);if(r!==s)return r?-1:1;if(r&&s){if(n.lengtho.length)return 1}return 0}(e,t,i);if(r)return r;const s=n.endsWith(i);if(s!==o.endsWith(i))return s?-1:1;const a=function(e,t,i=!1){const n=e||"",o=t||"",r=Br.value.collator.compare(n,o);return Br.value.collatorIsNumeric&&0===r&&n!==o?n(e.set(t.item,i),e)),new Map),this.list.splice(0,this.list.length,t),this.list.setFocus([]),this.list.layout(),this._onChangedAllVisibleChecked.fire(this.getAllVisibleChecked()),this._onChangedVisibleCount.fire(t.length),!0}toggleCheckbox(){try{this._fireCheckedEvents=!1;const e=this.list.getFocusedElements(),t=this.allVisibleChecked(e);for(const i of e)i.checked=!t}finally{this._fireCheckedEvents=!0,this.fireCheckedEvents()}}display(e){this.container.style.display=e?"":"none"}isDisplayed(){return"none"!==this.container.style.display}dispose(){this.elementDisposables=(0,Se.B9)(this.elementDisposables),this.disposables=(0,Se.B9)(this.disposables)}fireCheckedEvents(){this._fireCheckedEvents&&(this._onChangedAllVisibleChecked.fire(this.getAllVisibleChecked()),this._onChangedCheckedCount.fire(this.getCheckedCount()),this._onChangedCheckedElements.fire(this.getCheckedElements()))}fireButtonTriggered(e){this._onButtonTriggered.fire(e)}style(e){this.list.style(e)}}Vr([Wr.H],Kr.prototype,"onDidChangeFocus",null),Vr([Wr.H],Kr.prototype,"onDidChangeSelection",null);class qr{getWidgetAriaLabel(){return(0,vi.NC)("vs/base/parts/quickinput/browser/quickInputList","quickInput","Quick Input")}getAriaLabel(e){return e.saneAriaLabel}getWidgetRole(){return"listbox"}getRole(e){return e.hasCheckbox?"checkbox":"option"}isChecked(e){if(e.hasCheckbox)return{value:e.checked,onDidChange:e.onChecked}}}var Gr=function(e,t,i,n){return new(i||(i=Promise))((function(o,r){function s(e){try{l(n.next(e))}catch(e){r(e)}}function a(e){try{l(n.throw(e))}catch(e){r(e)}}function l(e){var t;e.done?o(e.value):(t=e.value,t instanceof i?t:new i((function(e){e(t)}))).then(s,a)}l((n=n.apply(e,t||[])).next())}))};const Zr=ii.$,Yr={iconClass:xo.lA.quickInputBack.classNames,tooltip:(0,vi.NC)("vs/base/parts/quickinput/browser/quickInput","quickInput.back","Back"),handle:-1};class Qr extends Se.JT{constructor(e){super(),this.ui=e,this.visible=!1,this._enabled=!0,this._busy=!1,this._ignoreFocusOut=!1,this._buttons=[],this.noValidationMessage=Qr.noPromptMessage,this._severity=bi.Z.Ignore,this.buttonsUpdated=!1,this.onDidTriggerButtonEmitter=this._register(new z.Q5),this.onDidHideEmitter=this._register(new z.Q5),this.onDisposeEmitter=this._register(new z.Q5),this.visibleDisposables=this._register(new Se.SL),this.onDidHide=this.onDidHideEmitter.event}get title(){return this._title}set title(e){this._title=e,this.update()}get description(){return this._description}set description(e){this._description=e,this.update()}get step(){return this._steps}set step(e){this._steps=e,this.update()}get totalSteps(){return this._totalSteps}set totalSteps(e){this._totalSteps=e,this.update()}get enabled(){return this._enabled}set enabled(e){this._enabled=e,this.update()}get contextKey(){return this._contextKey}set contextKey(e){this._contextKey=e,this.update()}get busy(){return this._busy}set busy(e){this._busy=e,this.update()}get ignoreFocusOut(){return this._ignoreFocusOut}set ignoreFocusOut(e){const t=this._ignoreFocusOut!==e&&!ke.gn;this._ignoreFocusOut=e&&!ke.gn,t&&this.update()}get buttons(){return this._buttons}set buttons(e){this._buttons=e,this.buttonsUpdated=!0,this.update()}get validationMessage(){return this._validationMessage}set validationMessage(e){this._validationMessage=e,this.update()}get severity(){return this._severity}set severity(e){this._severity=e,this.update()}show(){this.visible||(this.visibleDisposables.add(this.ui.onDidTriggerButton((e=>{-1!==this.buttons.indexOf(e)&&this.onDidTriggerButtonEmitter.fire(e)}))),this.ui.show(this),this.visible=!0,this._lastValidationMessage=void 0,this._lastSeverity=void 0,this.buttons.length&&(this.buttonsUpdated=!0),this.update())}hide(){this.visible&&this.ui.hide()}didHide(e=Dr.Jq.Other){this.visible=!1,this.visibleDisposables.clear(),this.onDidHideEmitter.fire({reason:e})}update(){if(!this.visible)return;const e=this.getTitle();e&&this.ui.title.textContent!==e?this.ui.title.textContent=e:e||" "===this.ui.title.innerHTML||(this.ui.title.innerText=" ");const t=this.getDescription();if(this.ui.description1.textContent!==t&&(this.ui.description1.textContent=t),this.ui.description2.textContent!==t&&(this.ui.description2.textContent=t),this.busy&&!this.busyDelay&&(this.busyDelay=new ye._F,this.busyDelay.setIfNotSet((()=>{this.visible&&this.ui.progressBar.infinite()}),800)),!this.busy&&this.busyDelay&&(this.ui.progressBar.stop(),this.busyDelay.cancel(),this.busyDelay=void 0),this.buttonsUpdated){this.buttonsUpdated=!1,this.ui.leftActionBar.clear();const e=this.buttons.filter((e=>e===Yr));this.ui.leftActionBar.push(e.map(((e,t)=>{const i=new So.aU(`id-${t}`,"",e.iconClass||Nr(e.iconPath),!0,(()=>Gr(this,void 0,void 0,(function*(){this.onDidTriggerButtonEmitter.fire(e)}))));return i.tooltip=e.tooltip||"",i})),{icon:!0,label:!1}),this.ui.rightActionBar.clear();const t=this.buttons.filter((e=>e!==Yr));this.ui.rightActionBar.push(t.map(((e,t)=>{const i=new So.aU(`id-${t}`,"",e.iconClass||Nr(e.iconPath),!0,(()=>Gr(this,void 0,void 0,(function*(){this.onDidTriggerButtonEmitter.fire(e)}))));return i.tooltip=e.tooltip||"",i})),{icon:!0,label:!1})}this.ui.ignoreFocusOut=this.ignoreFocusOut,this.ui.setEnabled(this.enabled),this.ui.setContextKey(this.contextKey);const i=this.validationMessage||this.noValidationMessage;this._lastValidationMessage!==i&&(this._lastValidationMessage=i,ii.mc(this.ui.message,...(0,ar.T)(i))),this._lastSeverity!==this.severity&&(this._lastSeverity=this.severity,this.showMessageDecoration(this.severity))}getTitle(){return this.title&&this.step?`${this.title} (${this.getSteps()})`:this.title?this.title:this.step?this.getSteps():""}getDescription(){return this.description||""}getSteps(){return this.step&&this.totalSteps?(0,vi.NC)("vs/base/parts/quickinput/browser/quickInput","quickInput.steps","{0}/{1}",this.step,this.totalSteps):this.step?String(this.step):""}showMessageDecoration(e){if(this.ui.inputBox.showDecoration(e),e!==bi.Z.Ignore){const t=this.ui.inputBox.stylesForType(e);this.ui.message.style.color=t.foreground?`${t.foreground}`:"",this.ui.message.style.backgroundColor=t.background?`${t.background}`:"",this.ui.message.style.border=t.border?`1px solid ${t.border}`:"",this.ui.message.style.marginBottom="-2px"}else this.ui.message.style.color="",this.ui.message.style.backgroundColor="",this.ui.message.style.border="",this.ui.message.style.marginBottom=""}dispose(){this.hide(),this.onDisposeEmitter.fire(),super.dispose()}}Qr.noPromptMessage=(0,vi.NC)("vs/base/parts/quickinput/browser/quickInput","inputModeEntry","Press 'Enter' to confirm your input or 'Escape' to cancel");class Xr extends Qr{constructor(){super(...arguments),this._value="",this.onDidChangeValueEmitter=this._register(new z.Q5),this.onWillAcceptEmitter=this._register(new z.Q5),this.onDidAcceptEmitter=this._register(new z.Q5),this.onDidCustomEmitter=this._register(new z.Q5),this._items=[],this.itemsUpdated=!1,this._canSelectMany=!1,this._canAcceptInBackground=!1,this._matchOnDescription=!1,this._matchOnDetail=!1,this._matchOnLabel=!0,this._sortByLabel=!0,this._autoFocusOnList=!0,this._keepScrollPosition=!1,this._itemActivation=this.ui.isScreenReaderOptimized()?Dr.jG.NONE:Dr.jG.FIRST,this._activeItems=[],this.activeItemsUpdated=!1,this.activeItemsToConfirm=[],this.onDidChangeActiveEmitter=this._register(new z.Q5),this._selectedItems=[],this.selectedItemsUpdated=!1,this.selectedItemsToConfirm=[],this.onDidChangeSelectionEmitter=this._register(new z.Q5),this.onDidTriggerItemButtonEmitter=this._register(new z.Q5),this.valueSelectionUpdated=!0,this._ok="default",this._customButton=!1,this.filterValue=e=>e,this.onDidChangeValue=this.onDidChangeValueEmitter.event,this.onWillAccept=this.onWillAcceptEmitter.event,this.onDidAccept=this.onDidAcceptEmitter.event,this.onDidChangeActive=this.onDidChangeActiveEmitter.event,this.onDidChangeSelection=this.onDidChangeSelectionEmitter.event,this.onDidTriggerItemButton=this.onDidTriggerItemButtonEmitter.event}get quickNavigate(){return this._quickNavigate}set quickNavigate(e){this._quickNavigate=e,this.update()}get value(){return this._value}set value(e){this.doSetValue(e)}doSetValue(e,t){this._value!==e&&(this._value=e,t||this.update(),this.visible&&this.ui.list.filter(this.filterValue(this._value))&&this.trySelectFirst(),this.onDidChangeValueEmitter.fire(this._value))}set ariaLabel(e){this._ariaLabel=e,this.update()}get ariaLabel(){return this._ariaLabel}get placeholder(){return this._placeholder}set placeholder(e){this._placeholder=e,this.update()}get items(){return this._items}get scrollTop(){return this.ui.list.scrollTop}set scrollTop(e){this.ui.list.scrollTop=e}set items(e){this._items=e,this.itemsUpdated=!0,this.update()}get canSelectMany(){return this._canSelectMany}set canSelectMany(e){this._canSelectMany=e,this.update()}get canAcceptInBackground(){return this._canAcceptInBackground}set canAcceptInBackground(e){this._canAcceptInBackground=e}get matchOnDescription(){return this._matchOnDescription}set matchOnDescription(e){this._matchOnDescription=e,this.update()}get matchOnDetail(){return this._matchOnDetail}set matchOnDetail(e){this._matchOnDetail=e,this.update()}get matchOnLabel(){return this._matchOnLabel}set matchOnLabel(e){this._matchOnLabel=e,this.update()}get sortByLabel(){return this._sortByLabel}set sortByLabel(e){this._sortByLabel=e,this.update()}get autoFocusOnList(){return this._autoFocusOnList}set autoFocusOnList(e){this._autoFocusOnList=e,this.update()}get keepScrollPosition(){return this._keepScrollPosition}set keepScrollPosition(e){this._keepScrollPosition=e}get itemActivation(){return this._itemActivation}set itemActivation(e){this._itemActivation=e}get activeItems(){return this._activeItems}set activeItems(e){this._activeItems=e,this.activeItemsUpdated=!0,this.update()}get selectedItems(){return this._selectedItems}set selectedItems(e){this._selectedItems=e,this.selectedItemsUpdated=!0,this.update()}get keyMods(){return this._quickNavigate?Dr.X5:this.ui.keyMods}set valueSelection(e){this._valueSelection=e,this.valueSelectionUpdated=!0,this.update()}get customButton(){return this._customButton}set customButton(e){this._customButton=e,this.update()}get customLabel(){return this._customButtonLabel}set customLabel(e){this._customButtonLabel=e,this.update()}get customHover(){return this._customButtonHover}set customHover(e){this._customButtonHover=e,this.update()}get ok(){return this._ok}set ok(e){this._ok=e,this.update()}get hideInput(){return!!this._hideInput}set hideInput(e){this._hideInput=e,this.update()}trySelectFirst(){this.autoFocusOnList&&(this.canSelectMany||this.ui.list.focus(jr.First))}show(){this.visible||(this.visibleDisposables.add(this.ui.inputBox.onDidChange((e=>{this.doSetValue(e,!0)}))),this.visibleDisposables.add(this.ui.inputBox.onMouseDown((e=>{this.autoFocusOnList||this.ui.list.clearFocus()}))),this.visibleDisposables.add((this._hideInput?this.ui.list:this.ui.inputBox).onKeyDown((e=>{switch(e.keyCode){case 18:this.ui.list.focus(jr.Next),this.canSelectMany&&this.ui.list.domFocus(),ii.zB.stop(e,!0);break;case 16:this.ui.list.getFocusedElements().length?this.ui.list.focus(jr.Previous):this.ui.list.focus(jr.Last),this.canSelectMany&&this.ui.list.domFocus(),ii.zB.stop(e,!0);break;case 12:this.ui.list.focus(jr.NextPage),this.canSelectMany&&this.ui.list.domFocus(),ii.zB.stop(e,!0);break;case 11:this.ui.list.focus(jr.PreviousPage),this.canSelectMany&&this.ui.list.domFocus(),ii.zB.stop(e,!0);break;case 17:if(!this._canAcceptInBackground)return;if(!this.ui.inputBox.isSelectionAtEnd())return;this.activeItems[0]&&(this._selectedItems=[this.activeItems[0]],this.onDidChangeSelectionEmitter.fire(this.selectedItems),this.handleAccept(!0));break;case 14:!e.ctrlKey&&!e.metaKey||e.shiftKey||e.altKey||(this.ui.list.focus(jr.First),ii.zB.stop(e,!0));break;case 13:!e.ctrlKey&&!e.metaKey||e.shiftKey||e.altKey||(this.ui.list.focus(jr.Last),ii.zB.stop(e,!0))}}))),this.visibleDisposables.add(this.ui.onDidAccept((()=>{this.canSelectMany?this.ui.list.getCheckedElements().length||(this._selectedItems=[],this.onDidChangeSelectionEmitter.fire(this.selectedItems)):this.activeItems[0]&&(this._selectedItems=[this.activeItems[0]],this.onDidChangeSelectionEmitter.fire(this.selectedItems)),this.handleAccept(!1)}))),this.visibleDisposables.add(this.ui.onDidCustom((()=>{this.onDidCustomEmitter.fire()}))),this.visibleDisposables.add(this.ui.list.onDidChangeFocus((e=>{this.activeItemsUpdated||this.activeItemsToConfirm!==this._activeItems&&(0,gt.fS)(e,this._activeItems,((e,t)=>e===t))||(this._activeItems=e,this.onDidChangeActiveEmitter.fire(e))}))),this.visibleDisposables.add(this.ui.list.onDidChangeSelection((({items:e,event:t})=>{this.canSelectMany?e.length&&this.ui.list.setSelectedElements([]):this.selectedItemsToConfirm!==this._selectedItems&&(0,gt.fS)(e,this._selectedItems,((e,t)=>e===t))||(this._selectedItems=e,this.onDidChangeSelectionEmitter.fire(e),e.length&&this.handleAccept(t instanceof MouseEvent&&1===t.button))}))),this.visibleDisposables.add(this.ui.list.onChangedCheckedElements((e=>{this.canSelectMany&&(this.selectedItemsToConfirm!==this._selectedItems&&(0,gt.fS)(e,this._selectedItems,((e,t)=>e===t))||(this._selectedItems=e,this.onDidChangeSelectionEmitter.fire(e)))}))),this.visibleDisposables.add(this.ui.list.onButtonTriggered((e=>this.onDidTriggerItemButtonEmitter.fire(e)))),this.visibleDisposables.add(this.registerQuickNavigation()),this.valueSelectionUpdated=!0),super.show()}handleAccept(e){let t=!1;this.onWillAcceptEmitter.fire({veto:()=>t=!0}),t||this.onDidAcceptEmitter.fire({inBackground:e})}registerQuickNavigation(){return ii.nm(this.ui.container,ii.tw.KEY_UP,(e=>{if(this.canSelectMany||!this._quickNavigate)return;const t=new Pi.y(e),i=t.keyCode;this._quickNavigate.keybindings.some((e=>{const[n,o]=e.getParts();return!(o||(n.shiftKey&&4===i?t.ctrlKey||t.altKey||t.metaKey:!(n.altKey&&6===i||n.ctrlKey&&5===i||n.metaKey&&57===i)))}))&&(this.activeItems[0]&&(this._selectedItems=[this.activeItems[0]],this.onDidChangeSelectionEmitter.fire(this.selectedItems),this.handleAccept(!1)),this._quickNavigate=void 0)}))}update(){if(!this.visible)return;const e=this.keepScrollPosition?this.scrollTop:0,t=!!this._hideInput&&this._items.length>0;this.ui.container.classList.toggle("hidden-input",t&&!this.description);const i={title:!!this.title||!!this.step||!!this.buttons.length,description:!!this.description,checkAll:this.canSelectMany&&!this._hideCheckAll,checkBox:this.canSelectMany,inputBox:!t,progressBar:!t,visibleCount:!0,count:this.canSelectMany,ok:"default"===this.ok?this.canSelectMany:this.ok,list:!0,message:!!this.validationMessage,customButton:this.customButton};this.ui.setVisibilities(i),super.update(),this.ui.inputBox.value!==this.value&&(this.ui.inputBox.value=this.value),this.valueSelectionUpdated&&(this.valueSelectionUpdated=!1,this.ui.inputBox.select(this._valueSelection&&{start:this._valueSelection[0],end:this._valueSelection[1]})),this.ui.inputBox.placeholder!==(this.placeholder||"")&&(this.ui.inputBox.placeholder=this.placeholder||"");const n=this.ariaLabel||this.placeholder||Xr.DEFAULT_ARIA_LABEL;if(this.ui.inputBox.ariaLabel!==n&&(this.ui.inputBox.ariaLabel=n),this.ui.list.matchOnDescription=this.matchOnDescription,this.ui.list.matchOnDetail=this.matchOnDetail,this.ui.list.matchOnLabel=this.matchOnLabel,this.ui.list.sortByLabel=this.sortByLabel,this.itemsUpdated)switch(this.itemsUpdated=!1,this.ui.list.setElements(this.items),this.ui.list.filter(this.filterValue(this.ui.inputBox.value)),this.ui.checkAll.checked=this.ui.list.getAllVisibleChecked(),this.ui.visibleCount.setCount(this.ui.list.getVisibleCount()),this.ui.count.setCount(this.ui.list.getCheckedCount()),this._itemActivation){case Dr.jG.NONE:this._itemActivation=Dr.jG.FIRST;break;case Dr.jG.SECOND:this.ui.list.focus(jr.Second),this._itemActivation=Dr.jG.FIRST;break;case Dr.jG.LAST:this.ui.list.focus(jr.Last),this._itemActivation=Dr.jG.FIRST;break;default:this.trySelectFirst()}this.ui.container.classList.contains("show-checkboxes")!==!!this.canSelectMany&&(this.canSelectMany?this.ui.list.clearFocus():this.trySelectFirst()),this.activeItemsUpdated&&(this.activeItemsUpdated=!1,this.activeItemsToConfirm=this._activeItems,this.ui.list.setFocusedElements(this.activeItems),this.activeItemsToConfirm===this._activeItems&&(this.activeItemsToConfirm=null)),this.selectedItemsUpdated&&(this.selectedItemsUpdated=!1,this.selectedItemsToConfirm=this._selectedItems,this.canSelectMany?this.ui.list.setCheckedElements(this.selectedItems):this.ui.list.setSelectedElements(this.selectedItems),this.selectedItemsToConfirm===this._selectedItems&&(this.selectedItemsToConfirm=null)),this.ui.customButton.label=this.customLabel||"",this.ui.customButton.element.title=this.customHover||"",this.ui.setComboboxAccessibility(!0),i.inputBox||(this.ui.list.domFocus(),this.canSelectMany&&this.ui.list.focus(jr.First)),this.keepScrollPosition&&(this.scrollTop=e)}}Xr.DEFAULT_ARIA_LABEL=(0,vi.NC)("vs/base/parts/quickinput/browser/quickInput","quickInputBox.ariaLabel","Type to narrow down results.");class Jr extends Se.JT{constructor(e){super(),this.options=e,this.comboboxAccessibility=!1,this.enabled=!0,this.onDidAcceptEmitter=this._register(new z.Q5),this.onDidCustomEmitter=this._register(new z.Q5),this.onDidTriggerButtonEmitter=this._register(new z.Q5),this.keyMods={ctrlCmd:!1,alt:!1},this.controller=null,this.onShowEmitter=this._register(new z.Q5),this.onShow=this.onShowEmitter.event,this.onHideEmitter=this._register(new z.Q5),this.onHide=this.onHideEmitter.event,this.idPrefix=e.idPrefix,this.parentElement=e.container,this.styles=e.styles,this.registerKeyModsListeners()}registerKeyModsListeners(){const e=e=>{this.keyMods.ctrlCmd=e.ctrlKey||e.metaKey,this.keyMods.alt=e.altKey};this._register(ii.nm(window,ii.tw.KEY_DOWN,e,!0)),this._register(ii.nm(window,ii.tw.KEY_UP,e,!0)),this._register(ii.nm(window,ii.tw.MOUSE_DOWN,e,!0))}getUI(){if(this.ui)return this.ui;const e=ii.R3(this.parentElement,Zr(".quick-input-widget.show-file-icons"));e.tabIndex=-1,e.style.display="none";const t=ii.dS(e),i=ii.R3(e,Zr(".quick-input-titlebar")),n=this._register(new vo.o(i));n.domNode.classList.add("quick-input-left-action-bar");const o=ii.R3(i,Zr(".quick-input-title")),r=this._register(new vo.o(i));r.domNode.classList.add("quick-input-right-action-bar");const s=ii.R3(e,Zr(".quick-input-description")),a=ii.R3(e,Zr(".quick-input-header")),l=ii.R3(a,Zr("input.quick-input-check-all"));l.type="checkbox",this._register(ii.mu(l,ii.tw.CHANGE,(e=>{const t=l.checked;y.setAllVisibleChecked(t)}))),this._register(ii.nm(l,ii.tw.CLICK,(e=>{(e.x||e.y)&&h.setFocus()})));const c=ii.R3(a,Zr(".quick-input-description")),d=ii.R3(a,Zr(".quick-input-and-message")),u=ii.R3(d,Zr(".quick-input-filter")),h=this._register(new Ar(u));h.setAttribute("aria-describedby",`${this.idPrefix}message`);const g=ii.R3(u,Zr(".quick-input-visible-count"));g.setAttribute("aria-live","polite"),g.setAttribute("aria-atomic","true");const p=new gr.Z(g,{countFormat:(0,vi.NC)("vs/base/parts/quickinput/browser/quickInput",{key:"quickInput.visibleCount",comment:["This tells the user how many items are shown in a list of items to select from. The items can be anything. Currently not visible, but read by screen readers."]},"{0} Results")}),m=ii.R3(u,Zr(".quick-input-count"));m.setAttribute("aria-live","polite");const f=new gr.Z(m,{countFormat:(0,vi.NC)("vs/base/parts/quickinput/browser/quickInput",{key:"quickInput.countSelected",comment:["This tells the user how many items are selected in a list of items to select from. The items can be anything."]},"{0} Selected")}),_=ii.R3(a,Zr(".quick-input-action")),b=new hr(_);b.label=(0,vi.NC)("vs/base/parts/quickinput/browser/quickInput","ok","OK"),this._register(b.onDidClick((e=>{this.onDidAcceptEmitter.fire()})));const v=ii.R3(a,Zr(".quick-input-action")),C=new hr(v);C.label=(0,vi.NC)("vs/base/parts/quickinput/browser/quickInput","custom","Custom"),this._register(C.onDidClick((e=>{this.onDidCustomEmitter.fire()})));const w=ii.R3(d,Zr(`#${this.idPrefix}message.quick-input-message`)),y=this._register(new Kr(e,this.idPrefix+"list",this.options));this._register(y.onChangedAllVisibleChecked((e=>{l.checked=e}))),this._register(y.onChangedVisibleCount((e=>{p.setCount(e)}))),this._register(y.onChangedCheckedCount((e=>{f.setCount(e)}))),this._register(y.onLeave((()=>{setTimeout((()=>{h.setFocus(),this.controller instanceof Xr&&this.controller.canSelectMany&&y.clearFocus()}),0)}))),this._register(y.onDidChangeFocus((()=>{this.comboboxAccessibility&&this.getUI().inputBox.setAttribute("aria-activedescendant",this.getUI().list.getActiveDescendant()||"")})));const S=new yr(e);S.getContainer().classList.add("quick-input-progress");const x=ii.go(e);return this._register(x),this._register(ii.nm(e,ii.tw.FOCUS,(e=>{this.previousFocusElement=e.relatedTarget instanceof HTMLElement?e.relatedTarget:void 0}),!0)),this._register(x.onDidBlur((()=>{this.getUI().ignoreFocusOut||this.options.ignoreFocusOut()||this.hide(Dr.Jq.Blur),this.previousFocusElement=void 0}))),this._register(ii.nm(e,ii.tw.FOCUS,(e=>{h.setFocus()}))),this._register(ii.nm(e,ii.tw.KEY_DOWN,(t=>{const i=new Pi.y(t);switch(i.keyCode){case 3:ii.zB.stop(t,!0),this.onDidAcceptEmitter.fire();break;case 9:ii.zB.stop(t,!0),this.hide(Dr.Jq.Gesture);break;case 2:if(!i.altKey&&!i.ctrlKey&&!i.metaKey){const n=[".action-label.codicon"];e.classList.contains("show-checkboxes")?n.push("input"):n.push("input[type=text]"),this.getUI().list.isDisplayed()&&n.push(".monaco-list");const o=e.querySelectorAll(n.join(", "));i.shiftKey&&i.target===o[0]?(ii.zB.stop(t,!0),o[o.length-1].focus()):i.shiftKey||i.target!==o[o.length-1]||(ii.zB.stop(t,!0),o[0].focus())}}}))),this.ui={container:e,styleSheet:t,leftActionBar:n,titleBar:i,title:o,description1:s,description2:c,rightActionBar:r,checkAll:l,filterContainer:u,inputBox:h,visibleCountContainer:g,visibleCount:p,countContainer:m,count:f,okContainer:_,ok:b,message:w,customButtonContainer:v,customButton:C,list:y,progressBar:S,onDidAccept:this.onDidAcceptEmitter.event,onDidCustom:this.onDidCustomEmitter.event,onDidTriggerButton:this.onDidTriggerButtonEmitter.event,ignoreFocusOut:!1,keyMods:this.keyMods,isScreenReaderOptimized:()=>this.options.isScreenReaderOptimized(),show:e=>this.show(e),hide:()=>this.hide(),setVisibilities:e=>this.setVisibilities(e),setComboboxAccessibility:e=>this.setComboboxAccessibility(e),setEnabled:e=>this.setEnabled(e),setContextKey:e=>this.options.setContextKey(e)},this.updateStyles(),this.ui}pick(e,t={},i=H.T.None){return new Promise(((n,o)=>{let r=e=>{r=n,t.onKeyMods&&t.onKeyMods(s.keyMods),n(e)};if(i.isCancellationRequested)return void r(void 0);const s=this.createQuickPick();let a;const l=[s,s.onDidAccept((()=>{if(s.canSelectMany)r(s.selectedItems.slice()),s.hide();else{const e=s.activeItems[0];e&&(r(e),s.hide())}})),s.onDidChangeActive((e=>{const i=e[0];i&&t.onDidFocus&&t.onDidFocus(i)})),s.onDidChangeSelection((e=>{if(!s.canSelectMany){const t=e[0];t&&(r(t),s.hide())}})),s.onDidTriggerItemButton((e=>t.onDidTriggerItemButton&&t.onDidTriggerItemButton(Object.assign(Object.assign({},e),{removeItem:()=>{const t=s.items.indexOf(e.item);if(-1!==t){const e=s.items.slice(),i=e.splice(t,1),n=s.activeItems.filter((e=>e!==i[0])),o=s.keepScrollPosition;s.keepScrollPosition=!0,s.items=e,n&&(s.activeItems=n),s.keepScrollPosition=o}}})))),s.onDidChangeValue((e=>{!a||e||1===s.activeItems.length&&s.activeItems[0]===a||(s.activeItems=[a])})),i.onCancellationRequested((()=>{s.hide()})),s.onDidHide((()=>{(0,Se.B9)(l),r(void 0)}))];s.title=t.title,s.canSelectMany=!!t.canPickMany,s.placeholder=t.placeHolder,s.ignoreFocusOut=!!t.ignoreFocusLost,s.matchOnDescription=!!t.matchOnDescription,s.matchOnDetail=!!t.matchOnDetail,s.matchOnLabel=void 0===t.matchOnLabel||t.matchOnLabel,s.autoFocusOnList=void 0===t.autoFocusOnList||t.autoFocusOnList,s.quickNavigate=t.quickNavigate,s.contextKey=t.contextKey,s.busy=!0,Promise.all([e,t.activeItem]).then((([e,t])=>{a=t,s.busy=!1,s.items=e,s.canSelectMany&&(s.selectedItems=e.filter((e=>"separator"!==e.type&&e.picked))),a&&(s.activeItems=[a])})),s.show(),Promise.resolve(e).then(void 0,(e=>{o(e),s.hide()}))}))}createQuickPick(){const e=this.getUI();return new Xr(e)}show(e){const t=this.getUI();this.onShowEmitter.fire();const i=this.controller;this.controller=e,i&&i.didHide(),this.setEnabled(!0),t.leftActionBar.clear(),t.title.textContent="",t.description1.textContent="",t.description2.textContent="",t.rightActionBar.clear(),t.checkAll.checked=!1,t.inputBox.placeholder="",t.inputBox.password=!1,t.inputBox.showDecoration(bi.Z.Ignore),t.visibleCount.setCount(0),t.count.setCount(0),ii.mc(t.message),t.progressBar.stop(),t.list.setElements([]),t.list.matchOnDescription=!1,t.list.matchOnDetail=!1,t.list.matchOnLabel=!0,t.list.sortByLabel=!0,t.ignoreFocusOut=!1,this.setComboboxAccessibility(!1),t.inputBox.ariaLabel="";const n=this.options.backKeybindingLabel();Yr.tooltip=n?(0,vi.NC)("vs/base/parts/quickinput/browser/quickInput","quickInput.backWithKeybinding","Back ({0})",n):(0,vi.NC)("vs/base/parts/quickinput/browser/quickInput","quickInput.back","Back"),t.container.style.display="",this.updateLayout(),t.inputBox.setFocus()}setVisibilities(e){const t=this.getUI();t.title.style.display=e.title?"":"none",t.description1.style.display=e.description&&(e.inputBox||e.checkAll)?"":"none",t.description2.style.display=!e.description||e.inputBox||e.checkAll?"none":"",t.checkAll.style.display=e.checkAll?"":"none",t.filterContainer.style.display=e.inputBox?"":"none",t.visibleCountContainer.style.display=e.visibleCount?"":"none",t.countContainer.style.display=e.count?"":"none",t.okContainer.style.display=e.ok?"":"none",t.customButtonContainer.style.display=e.customButton?"":"none",t.message.style.display=e.message?"":"none",t.progressBar.getContainer().style.display=e.progressBar?"":"none",t.list.display(!!e.list),t.container.classList[e.checkBox?"add":"remove"]("show-checkboxes"),this.updateLayout()}setComboboxAccessibility(e){if(e!==this.comboboxAccessibility){const t=this.getUI();this.comboboxAccessibility=e,this.comboboxAccessibility?(t.inputBox.setAttribute("role","combobox"),t.inputBox.setAttribute("aria-haspopup","true"),t.inputBox.setAttribute("aria-autocomplete","list"),t.inputBox.setAttribute("aria-activedescendant",t.list.getActiveDescendant()||"")):(t.inputBox.removeAttribute("role"),t.inputBox.removeAttribute("aria-haspopup"),t.inputBox.removeAttribute("aria-autocomplete"),t.inputBox.removeAttribute("aria-activedescendant"))}}setEnabled(e){if(e!==this.enabled){this.enabled=e;for(const t of this.getUI().leftActionBar.viewItems)t.getAction().enabled=e;for(const t of this.getUI().rightActionBar.viewItems)t.getAction().enabled=e;this.getUI().checkAll.disabled=!e,this.getUI().ok.enabled=e,this.getUI().list.enabled=e}}hide(e){var t;const i=this.controller;if(i){const n=!(null===(t=this.ui)||void 0===t?void 0:t.container.contains(document.activeElement));if(this.controller=null,this.onHideEmitter.fire(),this.getUI().container.style.display="none",!n){let e=this.previousFocusElement;for(;e&&!e.offsetParent;)e=(0,Le.f6)(e.parentElement);(null==e?void 0:e.offsetParent)?(e.focus(),this.previousFocusElement=void 0):this.options.returnFocus()}i.didHide(e)}}layout(e,t){this.dimension=e,this.titleBarOffset=t,this.updateLayout()}updateLayout(){if(this.ui){this.ui.container.style.top=`${this.titleBarOffset}px`;const e=this.ui.container.style,t=Math.min(.62*this.dimension.width,Jr.MAX_WIDTH);e.width=t+"px",e.marginLeft="-"+t/2+"px",this.ui.inputBox.layout(),this.ui.list.layout(this.dimension&&.4*this.dimension.height)}}applyStyles(e){this.styles=e,this.updateStyles()}updateStyles(){if(this.ui){const{quickInputTitleBackground:e,quickInputBackground:t,quickInputForeground:i,contrastBorder:n,widgetShadow:o}=this.styles.widget;this.ui.titleBar.style.backgroundColor=e?e.toString():"",this.ui.container.style.backgroundColor=t?t.toString():"",this.ui.container.style.color=i?i.toString():"",this.ui.container.style.border=n?`1px solid ${n}`:"",this.ui.container.style.boxShadow=o?`0 0 8px 2px ${o}`:"",this.ui.inputBox.style(this.styles.inputBox),this.ui.count.style(this.styles.countBadge),this.ui.ok.style(this.styles.button),this.ui.customButton.style(this.styles.button),this.ui.progressBar.style(this.styles.progressBar),this.ui.list.style(this.styles.list);const r=[];this.styles.list.pickerGroupBorder&&r.push(`.quick-input-list .quick-input-list-entry { border-top-color: ${this.styles.list.pickerGroupBorder}; }`),this.styles.list.pickerGroupForeground&&r.push(`.quick-input-list .quick-input-list-separator { color: ${this.styles.list.pickerGroupForeground}; }`),(this.styles.keybindingLabel.keybindingLabelBackground||this.styles.keybindingLabel.keybindingLabelBorder||this.styles.keybindingLabel.keybindingLabelBottomBorder||this.styles.keybindingLabel.keybindingLabelShadow||this.styles.keybindingLabel.keybindingLabelForeground)&&(r.push(".quick-input-list .monaco-keybinding > .monaco-keybinding-key {"),this.styles.keybindingLabel.keybindingLabelBackground&&r.push(`background-color: ${this.styles.keybindingLabel.keybindingLabelBackground};`),this.styles.keybindingLabel.keybindingLabelBorder&&r.push(`border-color: ${this.styles.keybindingLabel.keybindingLabelBorder};`),this.styles.keybindingLabel.keybindingLabelBottomBorder&&r.push(`border-bottom-color: ${this.styles.keybindingLabel.keybindingLabelBottomBorder};`),this.styles.keybindingLabel.keybindingLabelShadow&&r.push(`box-shadow: inset 0 -1px 0 ${this.styles.keybindingLabel.keybindingLabelShadow};`),this.styles.keybindingLabel.keybindingLabelForeground&&r.push(`color: ${this.styles.keybindingLabel.keybindingLabelForeground};`),r.push("}"));const s=r.join("\n");s!==this.ui.styleSheet.textContent&&(this.ui.styleSheet.textContent=s)}}}Jr.MAX_WIDTH=600;var es=i(69128),ts=i(58143),is=i(34073),ns=i(22447),os=function(e,t){return function(i,n){t(i,n,e)}};let rs=class extends Se.JT{constructor(e,t){super(),this.quickInputService=e,this.instantiationService=t,this.registry=Hi.B.as(is.IP.Quickaccess),this.mapProviderToDescriptor=new Map,this.lastAcceptedPickerValues=new Map,this.visibleQuickAccess=void 0}show(e="",t){this.doShowOrPick(e,!1,t)}doShowOrPick(e,t,i){var n;const[o,r]=this.getOrInstantiateProvider(e),s=this.visibleQuickAccess,a=null==s?void 0:s.descriptor;if(s&&r&&a===r)return e===r.prefix||(null==i?void 0:i.preserveValue)||(s.picker.value=e),void this.adjustValueSelection(s.picker,r,i);if(r&&!(null==i?void 0:i.preserveValue)){let t;if(s&&a&&a!==r){const e=s.value.substr(a.prefix.length);e&&(t=`${r.prefix}${e}`)}if(!t){const e=null==o?void 0:o.defaultFilterValue;e===is.Ry.LAST?t=this.lastAcceptedPickerValues.get(r):"string"==typeof e&&(t=`${r.prefix}${e}`)}"string"==typeof t&&(e=t)}const l=new Se.SL,c=l.add(this.quickInputService.createQuickPick());let d;c.value=e,this.adjustValueSelection(c,r,i),c.placeholder=null==r?void 0:r.placeholder,c.quickNavigate=null==i?void 0:i.quickNavigateConfiguration,c.hideInput=!!c.quickNavigate&&!s,("number"==typeof(null==i?void 0:i.itemActivation)||(null==i?void 0:i.quickNavigateConfiguration))&&(c.itemActivation=null!==(n=null==i?void 0:i.itemActivation)&&void 0!==n?n:ns.jG.SECOND),c.contextKey=null==r?void 0:r.contextKey,c.filterValue=e=>e.substring(r?r.prefix.length:0),(null==r?void 0:r.placeholder)&&(c.ariaLabel=null==r?void 0:r.placeholder),t&&(d=new ye.CR,l.add((0,ts.I)(c.onWillAccept)((e=>{e.veto(),c.hide()})))),l.add(this.registerPickerListeners(c,o,r,e));const u=l.add(new H.A);return o&&l.add(o.provide(c,u.token)),(0,ts.I)(c.onDidHide)((()=>{0===c.selectedItems.length&&u.cancel(),l.dispose(),null==d||d.complete(c.selectedItems.slice(0))})),c.show(),t?null==d?void 0:d.p:void 0}adjustValueSelection(e,t,i){var n;let o;o=(null==i?void 0:i.preserveValue)?[e.value.length,e.value.length]:[null!==(n=null==t?void 0:t.prefix.length)&&void 0!==n?n:0,e.value.length],e.valueSelection=o}registerPickerListeners(e,t,i,n){const o=new Se.SL,r=this.visibleQuickAccess={picker:e,descriptor:i,value:n};return o.add((0,Se.OF)((()=>{r===this.visibleQuickAccess&&(this.visibleQuickAccess=void 0)}))),o.add(e.onDidChangeValue((e=>{const[i]=this.getOrInstantiateProvider(e);i!==t?this.show(e,{preserveValue:!0}):r.value=e}))),i&&o.add(e.onDidAccept((()=>{this.lastAcceptedPickerValues.set(i,e.value)}))),o}getOrInstantiateProvider(e){const t=this.registry.getQuickAccessProvider(e);if(!t)return[void 0,void 0];let i=this.mapProviderToDescriptor.get(t);return i||(i=this.instantiationService.createInstance(t.ctor),this.mapProviderToDescriptor.set(t,i)),[i,t]}};rs=function(e,t,i,n){var o,r=arguments.length,s=r<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,i):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(e,t,i,n);else for(var a=e.length-1;a>=0;a--)(o=e[a])&&(s=(r<3?o(s):r>3?o(t,i,s):o(t,i))||s);return r>3&&s&&Object.defineProperty(t,i,s),s}([os(0,ns.eJ),os(1,hi.TG)],rs);var ss=function(e,t){return function(i,n){t(i,n,e)}};let as=class extends oi.bB{constructor(e,t,i,n,o){super(i),this.instantiationService=e,this.contextKeyService=t,this.accessibilityService=n,this.layoutService=o,this.contexts=new Map}get controller(){return this._controller||(this._controller=this._register(this.createController())),this._controller}get quickAccess(){return this._quickAccess||(this._quickAccess=this._register(this.instantiationService.createInstance(rs))),this._quickAccess}createController(e=this.layoutService,t){var i,n;const o={idPrefix:"quickInput_",container:e.container,ignoreFocusOut:()=>!1,isScreenReaderOptimized:()=>this.accessibilityService.isScreenReaderOptimized(),backKeybindingLabel:()=>{},setContextKey:e=>this.setContextKey(e),returnFocus:()=>e.focus(),createList:(e,t,i,n,o)=>this.instantiationService.createInstance(es.ev,e,t,i,n,o),styles:this.computeStyles()},r=this._register(new Jr(Object.assign(Object.assign({},o),t)));return r.layout(e.dimension,null!==(n=null===(i=e.offset)||void 0===i?void 0:i.top)&&void 0!==n?n:0),this._register(e.onDidLayout((t=>{var i,n;return r.layout(t,null!==(n=null===(i=e.offset)||void 0===i?void 0:i.top)&&void 0!==n?n:0)}))),this._register(r.onShow((()=>this.resetContextKeys()))),this._register(r.onHide((()=>this.resetContextKeys()))),r}setContextKey(e){let t;e&&(t=this.contexts.get(e),t||(t=new li.uy(e,!1).bindTo(this.contextKeyService),this.contexts.set(e,t))),t&&t.get()||(this.resetContextKeys(),t&&t.set(!0))}resetContextKeys(){this.contexts.forEach((e=>{e.get()&&e.reset()}))}pick(e,t={},i=H.T.None){return this.controller.pick(e,t,i)}createQuickPick(){return this.controller.createQuickPick()}updateStyles(){this.controller.applyStyles(this.computeStyles())}computeStyles(){return{widget:Object.assign({},(0,Oo.o)(this.theme,{quickInputBackground:Qo.zKr,quickInputForeground:Qo.tZ6,quickInputTitleBackground:Qo.loF,contrastBorder:Qo.lRK,widgetShadow:Qo.rh})),inputBox:(0,Oo.o)(this.theme,{inputForeground:Qo.zJb,inputBackground:Qo.sEe,inputBorder:Qo.dt_,inputValidationInfoBackground:Qo._lC,inputValidationInfoForeground:Qo.YI3,inputValidationInfoBorder:Qo.EPQ,inputValidationWarningBackground:Qo.RV_,inputValidationWarningForeground:Qo.SUG,inputValidationWarningBorder:Qo.C3g,inputValidationErrorBackground:Qo.paE,inputValidationErrorForeground:Qo._t9,inputValidationErrorBorder:Qo.OZR}),countBadge:(0,Oo.o)(this.theme,{badgeBackground:Qo.g8u,badgeForeground:Qo.qeD,badgeBorder:Qo.lRK}),button:(0,Oo.o)(this.theme,{buttonForeground:Qo.j5u,buttonBackground:Qo.b7$,buttonHoverBackground:Qo.GO4,buttonBorder:Qo.lRK}),progressBar:(0,Oo.o)(this.theme,{progressBarBackground:Qo.zRJ}),keybindingLabel:(0,Oo.o)(this.theme,{keybindingLabelBackground:Qo.oQ$,keybindingLabelForeground:Qo.lWp,keybindingLabelBorder:Qo.AWI,keybindingLabelBottomBorder:Qo.K19,keybindingLabelShadow:Qo.rh}),list:(0,Oo.o)(this.theme,{listBackground:Qo.zKr,listInactiveFocusForeground:Qo.NPS,listInactiveSelectionIconForeground:Qo.cbQ,listInactiveFocusBackground:Qo.Vqd,listFocusOutline:Qo.xL1,listInactiveFocusOutline:Qo.xL1,pickerGroupBorder:Qo.opG,pickerGroupForeground:Qo.kJk})}}};as=function(e,t,i,n){var o,r=arguments.length,s=r<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,i):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(e,t,i,n);else for(var a=e.length-1;a>=0;a--)(o=e[a])&&(s=(r<3?o(s):r>3?o(t,i,s):o(t,i))||s);return r>3&&s&&Object.defineProperty(t,i,s),s}([ss(0,hi.TG),ss(1,li.i6),ss(2,oi.XE),ss(3,sr.F),ss(4,gi)],as);var ls=function(e,t,i,n){var o,r=arguments.length,s=r<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,i):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(e,t,i,n);else for(var a=e.length-1;a>=0;a--)(o=e[a])&&(s=(r<3?o(s):r>3?o(t,i,s):o(t,i))||s);return r>3&&s&&Object.defineProperty(t,i,s),s},cs=function(e,t){return function(i,n){t(i,n,e)}};let ds=class extends as{constructor(e,t,i,n,o,r){super(t,i,n,o,new _i(e.getContainerDomNode(),r)),this.host=void 0;const s=hs.get(e);if(s){const t=s.widget;this.host={_serviceBrand:void 0,get hasContainer(){return!0},get container(){return t.getDomNode()},get dimension(){return e.getLayoutInfo()},get onDidLayout(){return e.onDidLayoutChange},focus:()=>e.focus()}}else this.host=void 0}createController(){return super.createController(this.host)}};ds=ls([cs(1,hi.TG),cs(2,li.i6),cs(3,oi.XE),cs(4,sr.F),cs(5,ge.$)],ds);let us=class{constructor(e,t){this.instantiationService=e,this.codeEditorService=t,this.mapEditorToService=new Map}get activeService(){const e=this.codeEditorService.getFocusedCodeEditor();if(!e)throw new Error("Quick input service needs a focused editor to work.");let t=this.mapEditorToService.get(e);if(!t){const i=t=this.instantiationService.createInstance(ds,e);this.mapEditorToService.set(e,t),(0,ts.I)(e.onDidDispose)((()=>{i.dispose(),this.mapEditorToService.delete(e)}))}return t}get quickAccess(){return this.activeService.quickAccess}pick(e,t={},i=H.T.None){return this.activeService.pick(e,t,i)}createQuickPick(){return this.activeService.createQuickPick()}};us=ls([cs(0,hi.TG),cs(1,ge.$)],us);class hs{constructor(e){this.editor=e,this.widget=new gs(this.editor)}static get(e){return e.getContribution(hs.ID)}dispose(){this.widget.dispose()}}hs.ID="editor.controller.quickInput";class gs{constructor(e){this.codeEditor=e,this.domNode=document.createElement("div"),this.codeEditor.addOverlayWidget(this)}getId(){return gs.ID}getDomNode(){return this.domNode}getPosition(){return{preference:2}}dispose(){this.codeEditor.removeOverlayWidget(this)}}gs.ID="editor.contrib.quickInputWidget",(0,rr._K)(hs.ID,hs);class ps{constructor(e,t,i,n,o){this._parsedThemeRuleBrand=void 0,this.token=e,this.index=t,this.fontStyle=i,this.foreground=n,this.background=o}}const ms=/^#?([0-9A-Fa-f]{6})([0-9A-Fa-f]{2})?$/;class fs{constructor(){this._lastColorId=0,this._id2color=[],this._color2id=new Map}getId(e){if(null===e)return 0;const t=e.match(ms);if(!t)throw new Error("Illegal value for token color: "+e);e=t[1].toUpperCase();let i=this._color2id.get(e);return i||(i=++this._lastColorId,this._color2id.set(e,i),this._id2color[i]=lr.Il.fromHex("#"+e),i)}getColorMap(){return this._id2color.slice(0)}}class _s{constructor(e,t){this._colorMap=e,this._root=t,this._cache=new Map}static createFromRawTokenTheme(e,t){return this.createFromParsedTokenTheme(function(e){if(!e||!Array.isArray(e))return[];const t=[];let i=0;for(let n=0,o=e.length;n{const i=function(e,t){return et?1:0}(e.token,t.token);return 0!==i?i:e.index-t.index}));let i=0,n="000000",o="ffffff";for(;e.length>=1&&""===e[0].token;){const t=e.shift();-1!==t.fontStyle&&(i=t.fontStyle),null!==t.foreground&&(n=t.foreground),null!==t.background&&(o=t.background)}const r=new fs;for(let e of t)r.getId(e);const s=r.getId(n),a=r.getId(o),l=new vs(i,s,a),c=new Cs(l);for(let t=0,i=e.length;t>>0,this._cache.set(t,i)}return(i|e<<0)>>>0}}const bs=/\b(comment|string|regex|regexp)\b/;class vs{constructor(e,t,i){this._themeTrieElementRuleBrand=void 0,this._fontStyle=e,this._foreground=t,this._background=i,this.metadata=(this._fontStyle<<10|this._foreground<<14|this._background<<23)>>>0}clone(){return new vs(this._fontStyle,this._foreground,this._background)}acceptOverwrite(e,t,i){-1!==e&&(this._fontStyle=e),0!==t&&(this._foreground=t),0!==i&&(this._background=i),this.metadata=(this._fontStyle<<10|this._foreground<<14|this._background<<23)>>>0}}class Cs{constructor(e){this._themeTrieElementBrand=void 0,this._mainRule=e,this._children=new Map}match(e){if(""===e)return this._mainRule;const t=e.indexOf(".");let i,n;-1===t?(i=e,n=""):(i=e.substring(0,t),n=e.substring(t+1));const o=this._children.get(i);return void 0!==o?o.match(n):this._mainRule}insert(e,t,i,n){if(""===e)return void this._mainRule.acceptOverwrite(t,i,n);const o=e.indexOf(".");let r,s;-1===o?(r=e,s=""):(r=e.substring(0,o),s=e.substring(o+1));let a=this._children.get(r);void 0===a&&(a=new Cs(this._mainRule.clone()),this._children.set(r,a)),a.insert(s,t,i,n)}}const ws={base:"vs",inherit:!1,rules:[{token:"",foreground:"000000",background:"fffffe"},{token:"invalid",foreground:"cd3131"},{token:"emphasis",fontStyle:"italic"},{token:"strong",fontStyle:"bold"},{token:"variable",foreground:"001188"},{token:"variable.predefined",foreground:"4864AA"},{token:"constant",foreground:"dd0000"},{token:"comment",foreground:"008000"},{token:"number",foreground:"098658"},{token:"number.hex",foreground:"3030c0"},{token:"regexp",foreground:"800000"},{token:"annotation",foreground:"808080"},{token:"type",foreground:"008080"},{token:"delimiter",foreground:"000000"},{token:"delimiter.html",foreground:"383838"},{token:"delimiter.xml",foreground:"0000FF"},{token:"tag",foreground:"800000"},{token:"tag.id.pug",foreground:"4F76AC"},{token:"tag.class.pug",foreground:"4F76AC"},{token:"meta.scss",foreground:"800000"},{token:"metatag",foreground:"e00000"},{token:"metatag.content.html",foreground:"FF0000"},{token:"metatag.html",foreground:"808080"},{token:"metatag.xml",foreground:"808080"},{token:"metatag.php",fontStyle:"bold"},{token:"key",foreground:"863B00"},{token:"string.key.json",foreground:"A31515"},{token:"string.value.json",foreground:"0451A5"},{token:"attribute.name",foreground:"FF0000"},{token:"attribute.value",foreground:"0451A5"},{token:"attribute.value.number",foreground:"098658"},{token:"attribute.value.unit",foreground:"098658"},{token:"attribute.value.html",foreground:"0000FF"},{token:"attribute.value.xml",foreground:"0000FF"},{token:"string",foreground:"A31515"},{token:"string.html",foreground:"0000FF"},{token:"string.sql",foreground:"FF0000"},{token:"string.yaml",foreground:"0451A5"},{token:"keyword",foreground:"0000FF"},{token:"keyword.json",foreground:"0451A5"},{token:"keyword.flow",foreground:"AF00DB"},{token:"keyword.flow.scss",foreground:"0000FF"},{token:"operator.scss",foreground:"666666"},{token:"operator.sql",foreground:"778899"},{token:"operator.swift",foreground:"666666"},{token:"predefined.sql",foreground:"C700C7"}],colors:{[Qo.cvW]:"#FFFFFE",[Qo.NOs]:"#000000",[Qo.ES4]:"#E5EBF1",[Yo.tR]:"#D3D3D3",[Yo.Ym]:"#939393",[Qo.Rzx]:"#ADD6FF4D"}},ys={base:"vs-dark",inherit:!1,rules:[{token:"",foreground:"D4D4D4",background:"1E1E1E"},{token:"invalid",foreground:"f44747"},{token:"emphasis",fontStyle:"italic"},{token:"strong",fontStyle:"bold"},{token:"variable",foreground:"74B0DF"},{token:"variable.predefined",foreground:"4864AA"},{token:"variable.parameter",foreground:"9CDCFE"},{token:"constant",foreground:"569CD6"},{token:"comment",foreground:"608B4E"},{token:"number",foreground:"B5CEA8"},{token:"number.hex",foreground:"5BB498"},{token:"regexp",foreground:"B46695"},{token:"annotation",foreground:"cc6666"},{token:"type",foreground:"3DC9B0"},{token:"delimiter",foreground:"DCDCDC"},{token:"delimiter.html",foreground:"808080"},{token:"delimiter.xml",foreground:"808080"},{token:"tag",foreground:"569CD6"},{token:"tag.id.pug",foreground:"4F76AC"},{token:"tag.class.pug",foreground:"4F76AC"},{token:"meta.scss",foreground:"A79873"},{token:"meta.tag",foreground:"CE9178"},{token:"metatag",foreground:"DD6A6F"},{token:"metatag.content.html",foreground:"9CDCFE"},{token:"metatag.html",foreground:"569CD6"},{token:"metatag.xml",foreground:"569CD6"},{token:"metatag.php",fontStyle:"bold"},{token:"key",foreground:"9CDCFE"},{token:"string.key.json",foreground:"9CDCFE"},{token:"string.value.json",foreground:"CE9178"},{token:"attribute.name",foreground:"9CDCFE"},{token:"attribute.value",foreground:"CE9178"},{token:"attribute.value.number.css",foreground:"B5CEA8"},{token:"attribute.value.unit.css",foreground:"B5CEA8"},{token:"attribute.value.hex.css",foreground:"D4D4D4"},{token:"string",foreground:"CE9178"},{token:"string.sql",foreground:"FF0000"},{token:"keyword",foreground:"569CD6"},{token:"keyword.flow",foreground:"C586C0"},{token:"keyword.json",foreground:"CE9178"},{token:"keyword.flow.scss",foreground:"569CD6"},{token:"operator.scss",foreground:"909090"},{token:"operator.sql",foreground:"778899"},{token:"operator.swift",foreground:"909090"},{token:"predefined.sql",foreground:"FF00FF"}],colors:{[Qo.cvW]:"#1E1E1E",[Qo.NOs]:"#D4D4D4",[Qo.ES4]:"#3A3D41",[Yo.tR]:"#404040",[Yo.Ym]:"#707070",[Qo.Rzx]:"#ADD6FF26"}},Ss={base:"hc-black",inherit:!1,rules:[{token:"",foreground:"FFFFFF",background:"000000"},{token:"invalid",foreground:"f44747"},{token:"emphasis",fontStyle:"italic"},{token:"strong",fontStyle:"bold"},{token:"variable",foreground:"1AEBFF"},{token:"variable.parameter",foreground:"9CDCFE"},{token:"constant",foreground:"569CD6"},{token:"comment",foreground:"608B4E"},{token:"number",foreground:"FFFFFF"},{token:"regexp",foreground:"C0C0C0"},{token:"annotation",foreground:"569CD6"},{token:"type",foreground:"3DC9B0"},{token:"delimiter",foreground:"FFFF00"},{token:"delimiter.html",foreground:"FFFF00"},{token:"tag",foreground:"569CD6"},{token:"tag.id.pug",foreground:"4F76AC"},{token:"tag.class.pug",foreground:"4F76AC"},{token:"meta",foreground:"D4D4D4"},{token:"meta.tag",foreground:"CE9178"},{token:"metatag",foreground:"569CD6"},{token:"metatag.content.html",foreground:"1AEBFF"},{token:"metatag.html",foreground:"569CD6"},{token:"metatag.xml",foreground:"569CD6"},{token:"metatag.php",fontStyle:"bold"},{token:"key",foreground:"9CDCFE"},{token:"string.key",foreground:"9CDCFE"},{token:"string.value",foreground:"CE9178"},{token:"attribute.name",foreground:"569CD6"},{token:"attribute.value",foreground:"3FF23F"},{token:"string",foreground:"CE9178"},{token:"string.sql",foreground:"FF0000"},{token:"keyword",foreground:"569CD6"},{token:"keyword.flow",foreground:"C586C0"},{token:"operator.sql",foreground:"778899"},{token:"operator.swift",foreground:"909090"},{token:"predefined.sql",foreground:"FF00FF"}],colors:{[Qo.cvW]:"#000000",[Qo.NOs]:"#FFFFFF",[Yo.tR]:"#FFFFFF",[Yo.Ym]:"#FFFFFF"}};var xs=i(14540),ks=i(26181);class Ls{getIcon(e){const t=(0,ks.Ks)();let i=e.defaults;for(;oi.kS.isThemeIcon(i);){const e=t.getIcon(i.id);if(!e)return;i=e.defaults}return i}}const Es="vs",Ns="vs-dark",Ds="hc-black",Is=Hi.B.as(Qo.IPX.ColorContribution),Ts=Hi.B.as(oi.IP.ThemingContribution);class As{constructor(e,t){this.semanticHighlighting=!1,this.themeData=t;const i=t.base;e.length>0?(Rs(e)?this.id=e:this.id=i+" "+e,this.themeName=e):(this.id=i,this.themeName=i),this.colors=null,this.defaultColors=Object.create(null),this._tokenTheme=null}get base(){return this.themeData.base}notifyBaseUpdated(){this.themeData.inherit&&(this.colors=null,this._tokenTheme=null)}getColors(){if(!this.colors){const e=new Map;for(let t in this.themeData.colors)e.set(t,lr.Il.fromHex(this.themeData.colors[t]));if(this.themeData.inherit){const t=Ms(this.themeData.base);for(let i in t.colors)e.has(i)||e.set(i,lr.Il.fromHex(t.colors[i]))}this.colors=e}return this.colors}getColor(e,t){return this.getColors().get(e)||(!1!==t?this.getDefault(e):void 0)}getDefault(e){let t=this.defaultColors[e];return t||(t=Is.resolveDefaultColor(e,this),this.defaultColors[e]=t,t)}defines(e){return Object.prototype.hasOwnProperty.call(this.getColors(),e)}get type(){switch(this.base){case Es:return xs.e.LIGHT;case Ds:return xs.e.HIGH_CONTRAST;default:return xs.e.DARK}}get tokenTheme(){if(!this._tokenTheme){let e=[],t=[];if(this.themeData.inherit){const i=Ms(this.themeData.base);e=i.rules,i.encodedTokensColors&&(t=i.encodedTokensColors)}const i=this.themeData.colors["editor.foreground"],n=this.themeData.colors["editor.background"];if(i||n){const t={token:""};i&&(t.foreground=i),n&&(t.background=n),e.push(t)}e=e.concat(this.themeData.rules),this.themeData.encodedTokensColors&&(t=this.themeData.encodedTokensColors),this._tokenTheme=_s.createFromRawTokenTheme(e,t)}return this._tokenTheme}getTokenStyleMetadata(e,t,i){const n=this.tokenTheme._match([e].concat(t).join(".")).metadata,o=G.NX.getForeground(n),r=G.NX.getFontStyle(n);return{foreground:o,italic:Boolean(1&r),bold:Boolean(2&r),underline:Boolean(4&r),strikethrough:Boolean(8&r)}}}function Rs(e){return e===Es||e===Ns||e===Ds}function Ms(e){switch(e){case Es:return ws;case Ns:return ys;case Ds:return Ss}}function Os(e){const t=Ms(e);return new As(e,t)}class Ps extends Se.JT{constructor(){super(),this._onColorThemeChange=this._register(new z.Q5),this.onDidColorThemeChange=this._onColorThemeChange.event,this._onProductIconThemeChange=this._register(new z.Q5),this.onDidProductIconThemeChange=this._onProductIconThemeChange.event,this._environment=Object.create(null),this._builtInProductIconTheme=new Ls,this._autoDetectHighContrast=!0,this._knownThemes=new Map,this._knownThemes.set(Es,Os(Es)),this._knownThemes.set(Ns,Os(Ns)),this._knownThemes.set(Ds,Os(Ds));const e=function(e){const t=new z.Q5,i=(0,ks.Ks)();return i.onDidChange((()=>t.fire())),null==e||e.onDidProductIconThemeChange((()=>t.fire())),{onDidChange:t.event,getCSS(){const t=e?e.getProductIconTheme():new Ls,n={},o=e=>{const i=t.getIcon(e);if(!i)return;const o=i.font;return o?(n[o.id]=o.definition,`.codicon-${e.id}:before { content: '${i.fontCharacter}'; font-family: ${(0,ii._h)(o.id)}; }`):`.codicon-${e.id}:before { content: '${i.fontCharacter}'; }`},r=[];for(let e of i.getIcons()){const t=o(e);t&&r.push(t)}for(let e in n){const t=n[e],i=t.weight?`font-weight: ${t.weight};`:"",o=t.style?`font-style: ${t.style};`:"",s=t.src.map((e=>`${(0,ii.wY)(e.location)} format('${e.format}')`)).join(", ");r.push(`@font-face { src: ${s}; font-family: ${(0,ii._h)(e)};${i}${o} font-display: block; }`)}return r.join("\n")}}}(this);this._codiconCSS=e.getCSS(),this._themeCSS="",this._allCSS=`${this._codiconCSS}\n${this._themeCSS}`,this._globalStyleElement=null,this._styleElements=[],this._colorMapOverride=null,this.setTheme(Es),e.onDidChange((()=>{this._codiconCSS=e.getCSS(),this._updateCSS()})),ii.uB("(forced-colors: active)",(()=>{this._updateActualTheme()}))}registerEditorContainer(e){return ii.OO(e)?this._registerShadowDomContainer(e):this._registerRegularEditorContainer()}_registerRegularEditorContainer(){return this._globalStyleElement||(this._globalStyleElement=ii.dS(),this._globalStyleElement.className="monaco-colors",this._globalStyleElement.textContent=this._allCSS,this._styleElements.push(this._globalStyleElement)),Se.JT.None}_registerShadowDomContainer(e){const t=ii.dS(e);return t.className="monaco-colors",t.textContent=this._allCSS,this._styleElements.push(t),{dispose:()=>{for(let e=0;e{t.base===e&&t.notifyBaseUpdated()})),this._theme.themeName===e&&this.setTheme(e)}getColorTheme(){return this._theme}setColorMapOverride(e){this._colorMapOverride=e,this._updateThemeOrColorMap()}setTheme(e){let t;t=this._knownThemes.has(e)?this._knownThemes.get(e):this._knownThemes.get(Es),this._desiredTheme=t,this._updateActualTheme()}_updateActualTheme(){const e=this._autoDetectHighContrast&&window.matchMedia("(forced-colors: active)").matches?this._knownThemes.get(Ds):this._desiredTheme;this._theme!==e&&(this._theme=e,this._updateThemeOrColorMap())}setAutoDetectHighContrast(e){this._autoDetectHighContrast=e,this._updateActualTheme()}_updateThemeOrColorMap(){const e=[],t={},i={addRule:i=>{t[i]||(e.push(i),t[i]=!0)}};Ts.getThemingParticipants().forEach((e=>e(this._theme,i,this._environment)));const n=[];for(const e of Is.getColors()){const t=this._theme.getColor(e.id,!0);t&&n.push(`${(0,Qo.QO2)(e.id)}: ${t.toString()};`)}i.addRule(`.monaco-editor { ${n.join("\n")} }`);const o=this._colorMapOverride||this._theme.tokenTheme.getColorMap();i.addRule(function(e){const t=[];for(let i=1,n=e.length;ie.textContent=this._allCSS))}getFileIconTheme(){return{hasFileIcons:!1,hasFolderIcons:!1,hidesExplorerArrows:!1}}getProductIconTheme(){return this._builtInProductIconTheme}}var Fs=i(52093),Bs=function(e,t){return function(i,n){t(i,n,e)}};let Ws=class extends Se.JT{constructor(e,t){super(),this._contextKeyService=e,this._configurationService=t,this._accessibilitySupport=0,this._onDidChangeScreenReaderOptimized=new z.Q5,this._accessibilityModeEnabledContext=sr.U.bindTo(this._contextKeyService);const i=()=>this._accessibilityModeEnabledContext.set(this.isScreenReaderOptimized());this._register(this._configurationService.onDidChangeConfiguration((e=>{e.affectsConfiguration("editor.accessibilitySupport")&&(i(),this._onDidChangeScreenReaderOptimized.fire())}))),i(),this.onDidChangeScreenReaderOptimized((()=>i()))}get onDidChangeScreenReaderOptimized(){return this._onDidChangeScreenReaderOptimized.event}isScreenReaderOptimized(){const e=this._configurationService.getValue("editor.accessibilitySupport");return"on"===e||"auto"===e&&2===this._accessibilitySupport}getAccessibilitySupport(){return this._accessibilitySupport}};Ws=function(e,t,i,n){var o,r=arguments.length,s=r<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,i):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(e,t,i,n);else for(var a=e.length-1;a>=0;a--)(o=e[a])&&(s=(r<3?o(s):r>3?o(t,i,s):o(t,i))||s);return r>3&&s&&Object.defineProperty(t,i,s),s}([Bs(0,li.i6),Bs(1,Yi.Ui)],Ws);var Vs=i(3337),Hs=function(e,t,i,n){var o,r=arguments.length,s=r<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,i):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(e,t,i,n);else for(var a=e.length-1;a>=0;a--)(o=e[a])&&(s=(r<3?o(s):r>3?o(t,i,s):o(t,i))||s);return r>3&&s&&Object.defineProperty(t,i,s),s},zs=function(e,t){return function(i,n){t(i,n,e)}};let $s=class{constructor(e){this._commandService=e}createMenu(e,t,i){return new Us(e,Object.assign({emitEventsForSubmenuChanges:!1,eventDebounceDelay:50},i),this._commandService,t,this)}};$s=Hs([zs(0,Zi.Hy)],$s);let Us=class e{constructor(e,t,i,n,o){this._id=e,this._options=t,this._commandService=i,this._contextKeyService=n,this._menuService=o,this._disposables=new Se.SL,this._menuGroups=[],this._contextKeys=new Set,this._build();const r=new ye.pY((()=>{this._build(),this._onDidChange.fire(this)}),t.eventDebounceDelay);this._disposables.add(r),this._disposables.add(Vs.BH.onDidChangeMenu((t=>{t.has(e)&&r.schedule()})));const s=this._disposables.add(new Se.SL);this._onDidChange=new z.Q5({onFirstListenerAdd:()=>{const e=new ye.pY((()=>this._onDidChange.fire(this)),t.eventDebounceDelay);s.add(e),s.add(n.onDidChangeContext((t=>{t.affectsSome(this._contextKeys)&&e.schedule()})))},onLastListenerRemove:s.clear.bind(s)}),this.onDidChange=this._onDidChange.event}dispose(){this._disposables.dispose(),this._onDidChange.dispose()}_build(){this._menuGroups.length=0,this._contextKeys.clear();const t=Vs.BH.getMenuItems(this._id);let i;t.sort(e._compareMenuItems);for(const e of t){const t=e.group||"";i&&i[0]===t||(i=[t,[]],this._menuGroups.push(i)),i[1].push(e),this._collectContextKeys(e)}}_collectContextKeys(t){if(e._fillInKbExprKeys(t.when,this._contextKeys),(0,Vs.vr)(t)){if(t.command.precondition&&e._fillInKbExprKeys(t.command.precondition,this._contextKeys),t.command.toggled){const i=t.command.toggled.condition||t.command.toggled;e._fillInKbExprKeys(i,this._contextKeys)}}else this._options.emitEventsForSubmenuChanges&&Vs.BH.getMenuItems(t.submenu).forEach(this._collectContextKeys,this)}getActions(e){const t=[];for(let i of this._menuGroups){const[n,o]=i,r=[];for(const t of o)if(this._contextKeyService.contextMatchesRules(t.when)){const i=(0,Vs.vr)(t)?new Vs.U8(t.command,t.alt,e,this._contextKeyService,this._commandService):new Vs.NZ(t,this._menuService,this._contextKeyService,e);r.push(i)}r.length>0&&t.push([n,r])}return t}static _fillInKbExprKeys(e,t){if(e)for(let i of e.keys())t.add(i)}static _compareMenuItems(t,i){let n=t.group,o=i.group;if(n!==o){if(!n)return 1;if(!o)return-1;if("navigation"===n)return-1;if("navigation"===o)return 1;let e=n.localeCompare(o);if(0!==e)return e}let r=t.order||0,s=i.order||0;return rs?1:e._compareTitles((0,Vs.vr)(t)?t.command.title:t.title,(0,Vs.vr)(i)?i.command.title:i.title)}static _compareTitles(e,t){const i="string"==typeof e?e:e.original,n="string"==typeof t?t:t.original;return i.localeCompare(n)}};Us=Hs([zs(2,Zi.Hy),zs(3,li.i6),zs(4,Vs.co)],Us);var js=function(e,t){return function(i,n){t(i,n,e)}},Ks=function(e,t,i,n){return new(i||(i=Promise))((function(o,r){function s(e){try{l(n.next(e))}catch(e){r(e)}}function a(e){try{l(n.throw(e))}catch(e){r(e)}}function l(e){var t;e.done?o(e.value):(t=e.value,t instanceof i?t:new i((function(e){e(t)}))).then(s,a)}l((n=n.apply(e,t||[])).next())}))};let qs=class extends Se.JT{constructor(e,t){super(),this.layoutService=e,this.logService=t,this.mapTextToType=new Map,this.findText="",(_o.isSafari||_o.isWebkitWebView)&&this.installWebKitWriteTextWorkaround()}installWebKitWriteTextWorkaround(){const e=()=>{const e=new ye.CR;this.webKitPendingClipboardWritePromise&&!this.webKitPendingClipboardWritePromise.isSettled&&this.webKitPendingClipboardWritePromise.cancel(),this.webKitPendingClipboardWritePromise=e,navigator.clipboard.write([new ClipboardItem({"text/plain":e.p})]).catch((t=>Ks(this,void 0,void 0,(function*(){t instanceof Error&&"NotAllowedError"===t.name&&e.isRejected||this.logService.error(t)}))))};this.layoutService.hasContainer&&(this._register((0,ii.nm)(this.layoutService.container,"click",e)),this._register((0,ii.nm)(this.layoutService.container,"keydown",e)))}writeText(e,t){return Ks(this,void 0,void 0,(function*(){if(t)return void this.mapTextToType.set(t,e);if(this.webKitPendingClipboardWritePromise)return this.webKitPendingClipboardWritePromise.complete(e);try{return yield navigator.clipboard.writeText(e)}catch(e){console.error(e)}const i=document.activeElement,n=document.body.appendChild((0,ii.$)("textarea",{"aria-hidden":!0}));n.style.height="1px",n.style.width="1px",n.style.position="absolute",n.value=e,n.focus(),n.select(),document.execCommand("copy"),i instanceof HTMLElement&&i.focus(),document.body.removeChild(n)}))}readText(e){return Ks(this,void 0,void 0,(function*(){if(e)return this.mapTextToType.get(e)||"";try{return yield navigator.clipboard.readText()}catch(e){return console.error(e),""}}))}readFindText(){return Ks(this,void 0,void 0,(function*(){return this.findText}))}writeFindText(e){return Ks(this,void 0,void 0,(function*(){this.findText=e}))}};qs=function(e,t,i,n){var o,r=arguments.length,s=r<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,i):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(e,t,i,n);else for(var a=e.length-1;a>=0;a--)(o=e[a])&&(s=(r<3?o(s):r>3?o(t,i,s):o(t,i))||s);return r>3&&s&&Object.defineProperty(t,i,s),s}([js(0,gi),js(1,pt.VZ)],qs);var Gs=i(22837),Zs=i(44780);const Ys="data-keybinding-context";class Qs{constructor(e,t){this._id=e,this._parent=t,this._value=Object.create(null),this._value._contextId=e}setValue(e,t){return this._value[e]!==t&&(this._value[e]=t,!0)}removeValue(e){return e in this._value&&(delete this._value[e],!0)}getValue(e){const t=this._value[e];return void 0===t&&this._parent?this._parent.getValue(e):t}}class Xs extends Qs{constructor(){super(-1,null)}setValue(e,t){return!1}removeValue(e){return!1}getValue(e){}}Xs.INSTANCE=new Xs;class Js extends Qs{constructor(e,t,i){super(e,null),this._configurationService=t,this._values=Qi.Id.forConfigKeys(),this._listener=this._configurationService.onDidChangeConfiguration((e=>{if(6===e.source){const e=Array.from(Zs.$.map(this._values,(([e])=>e)));this._values.clear(),i.fire(new ia(e))}else{const t=[];for(const i of e.affectedKeys){const e=`config.${i}`,n=this._values.findSuperstr(e);void 0!==n&&(t.push(...Zs.$.map(n,(([e])=>e))),this._values.deleteSuperstr(e)),this._values.has(e)&&(t.push(e),this._values.delete(e))}i.fire(new ia(t))}}))}dispose(){this._listener.dispose()}getValue(e){if(0!==e.indexOf(Js._keyPrefix))return super.getValue(e);if(this._values.has(e))return this._values.get(e);const t=e.substr(Js._keyPrefix.length),i=this._configurationService.getValue(t);let n;switch(typeof i){case"number":case"boolean":case"string":n=i;break;default:n=Array.isArray(i)?JSON.stringify(i):i}return this._values.set(e,n),n}setValue(e,t){return super.setValue(e,t)}removeValue(e){return super.removeValue(e)}}Js._keyPrefix="config.";class ea{constructor(e,t,i){this._service=e,this._key=t,this._defaultValue=i,this.reset()}set(e){this._service.setContext(this._key,e)}reset(){void 0===this._defaultValue?this._service.removeContext(this._key):this._service.setContext(this._key,this._defaultValue)}get(){return this._service.getContextKeyValue(this._key)}}class ta{constructor(e){this.key=e}affectsSome(e){return e.has(this.key)}}class ia{constructor(e){this.keys=e}affectsSome(e){for(const t of this.keys)if(e.has(t))return!0;return!1}}class na{constructor(e){this.events=e}affectsSome(e){for(const t of this.events)if(t.affectsSome(e))return!0;return!1}}class oa{constructor(e){this._onDidChangeContext=new z.K3({merge:e=>new na(e)}),this.onDidChangeContext=this._onDidChangeContext.event,this._isDisposed=!1,this._myContextId=e}createKey(e,t){if(this._isDisposed)throw new Error("AbstractContextKeyService has been disposed");return new ea(this,e,t)}bufferChangeEvents(e){this._onDidChangeContext.pause();try{e()}finally{this._onDidChangeContext.resume()}}createScoped(e){if(this._isDisposed)throw new Error("AbstractContextKeyService has been disposed");return new sa(this,e)}contextMatchesRules(e){if(this._isDisposed)throw new Error("AbstractContextKeyService has been disposed");const t=this.getContextValuesContainer(this._myContextId);return!e||e.evaluate(t)}getContextKeyValue(e){if(!this._isDisposed)return this.getContextValuesContainer(this._myContextId).getValue(e)}setContext(e,t){if(this._isDisposed)return;const i=this.getContextValuesContainer(this._myContextId);i&&i.setValue(e,t)&&this._onDidChangeContext.fire(new ta(e))}removeContext(e){this._isDisposed||this.getContextValuesContainer(this._myContextId).removeValue(e)&&this._onDidChangeContext.fire(new ta(e))}getContext(e){return this._isDisposed?Xs.INSTANCE:this.getContextValuesContainer(function(e){for(;e;){if(e.hasAttribute(Ys)){const t=e.getAttribute(Ys);return t?parseInt(t,10):NaN}e=e.parentElement}return 0}(e))}}let ra=class extends oa{constructor(e){super(0),this._contexts=new Map,this._toDispose=new Se.SL,this._lastContextId=0;const t=new Js(this._myContextId,e,this._onDidChangeContext);this._contexts.set(this._myContextId,t),this._toDispose.add(t)}dispose(){this._onDidChangeContext.dispose(),this._isDisposed=!0,this._toDispose.dispose()}getContextValuesContainer(e){return this._isDisposed?Xs.INSTANCE:this._contexts.get(e)||Xs.INSTANCE}createChildContext(e=this._myContextId){if(this._isDisposed)throw new Error("ContextKeyService has been disposed");let t=++this._lastContextId;return this._contexts.set(t,new Qs(t,this.getContextValuesContainer(e))),t}disposeContext(e){this._isDisposed||this._contexts.delete(e)}};ra=function(e,t,i,n){var o,r=arguments.length,s=r<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,i):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(e,t,i,n);else for(var a=e.length-1;a>=0;a--)(o=e[a])&&(s=(r<3?o(s):r>3?o(t,i,s):o(t,i))||s);return r>3&&s&&Object.defineProperty(t,i,s),s}([function(e,t){return function(i,n){t(i,n,e)}}(0,Yi.Ui)],ra);class sa extends oa{constructor(e,t){if(super(e.createChildContext()),this._parentChangeListener=new Se.XK,this._parent=e,this._updateParentChangeListener(),this._domNode=t,this._domNode.hasAttribute(Ys)){let e="";this._domNode.classList&&(e=Array.from(this._domNode.classList.values()).join(", ")),console.error("Element already has context attribute"+(e?": "+e:""))}this._domNode.setAttribute(Ys,String(this._myContextId))}_updateParentChangeListener(){this._parentChangeListener.value=this._parent.onDidChangeContext(this._onDidChangeContext.fire,this._onDidChangeContext)}dispose(){this._isDisposed||(this._onDidChangeContext.dispose(),this._parent.disposeContext(this._myContextId),this._parentChangeListener.dispose(),this._domNode.removeAttribute(Ys),this._isDisposed=!0)}getContextValuesContainer(e){return this._isDisposed?Xs.INSTANCE:this._parent.getContextValuesContainer(e)}createChildContext(e=this._myContextId){if(this._isDisposed)throw new Error("ScopedContextKeyService has been disposed");return this._parent.createChildContext(e)}disposeContext(e){this._isDisposed||this._parent.disposeContext(e)}}Zi.P0.registerCommand(li.Eq,(function(e,t,i){e.get(li.i6).createKey(String(t),i)})),Zi.P0.registerCommand({id:"getContextKeyInfo",handler:()=>[...li.uy.all()].sort(((e,t)=>e.key.localeCompare(t.key))),description:{description:(0,vi.NC)("vs/platform/contextkey/browser/contextKeyService","getContextKeyInfo","A command that returns information about context keys"),args:[]}}),Zi.P0.registerCommand("_generateContextKeyInfo",(function(){const e=[],t=new Set;for(let i of li.uy.all())t.has(i.key)||(t.add(i.key),e.push(i));e.sort(((e,t)=>e.key.localeCompare(t.key))),console.log(JSON.stringify(e,void 0,2))}));var aa=i(58778);class la{constructor(e){this.incoming=new Map,this.outgoing=new Map,this.data=e}}class ca{constructor(e){this._hashFn=e,this._nodes=new Map}roots(){const e=[];for(let t of this._nodes.values())0===t.outgoing.size&&e.push(t);return e}insertEdge(e,t){const i=this.lookupOrInsertNode(e),n=this.lookupOrInsertNode(t);i.outgoing.set(this._hashFn(t),n),n.incoming.set(this._hashFn(e),i)}removeNode(e){const t=this._hashFn(e);this._nodes.delete(t);for(let e of this._nodes.values())e.outgoing.delete(t),e.incoming.delete(t)}lookupOrInsertNode(e){const t=this._hashFn(e);let i=this._nodes.get(t);return i||(i=new la(e),this._nodes.set(t,i)),i}isEmpty(){return 0===this._nodes.size}toString(){let e=[];for(let[t,i]of this._nodes)e.push(`${t}, (incoming)[${[...i.incoming.keys()].join(", ")}], (outgoing)[${[...i.outgoing.keys()].join(",")}]`);return e.join("\n")}findCycleSlow(){for(let[e,t]of this._nodes){const i=new Set([e]),n=this._findCycle(t,i);if(n)return n}}_findCycle(e,t){for(let[i,n]of e.outgoing){if(t.has(i))return[...t,i].join(" -> ");t.add(i);const e=this._findCycle(n,t);if(e)return e;t.delete(i)}}}var da=i(97259);class ua extends Error{constructor(e){var t;super("cyclic dependency between services"),this.message=null!==(t=e.findCycleSlow())&&void 0!==t?t:`UNABLE to detect cycle, dumping graph: \n${e.toString()}`}}class ha{constructor(e=new da.y,t=!1,i){this._activeInstantiations=new Set,this._services=e,this._strict=t,this._parent=i,this._services.set(hi.TG,this)}createChild(e){return new ha(e,this._strict,this)}invokeFunction(e,...t){let i=ga.traceInvocation(e),n=!1;try{return e({get:e=>{if(n)throw(0,xe.L6)("service accessor is only valid during the invocation of its target method");const t=this._getOrCreateServiceInstance(e,i);if(!t)throw new Error(`[invokeFunction] unknown service '${e}'`);return t}},...t)}finally{n=!0,i.stop()}}createInstance(e,...t){let i,n;return e instanceof aa.M?(i=ga.traceCreation(e.ctor),n=this._createInstance(e.ctor,e.staticArguments.concat(t),i)):(i=ga.traceCreation(e),n=this._createInstance(e,t,i)),i.stop(),n}_createInstance(e,t=[],i){let n=hi.I8.getServiceDependencies(e).sort(((e,t)=>e.index-t.index)),o=[];for(const t of n){let n=this._getOrCreateServiceInstance(t.id,i);n||this._throwIfStrict(`[createInstance] ${e.name} depends on UNKNOWN service ${t.id}.`,!1),o.push(n)}let r=n.length>0?n[0].index:t.length;if(t.length!==r){console.warn(`[createInstance] First service dependency of ${e.name} at position ${r+1} conflicts with ${t.length} static arguments`);let i=r-t.length;t=i>0?t.concat(new Array(i)):t.slice(0,r)}return new e(...[...t,...o])}_setServiceInstance(e,t){if(this._services.get(e)instanceof aa.M)this._services.set(e,t);else{if(!this._parent)throw new Error("illegalState - setting UNKNOWN service instance");this._parent._setServiceInstance(e,t)}}_getServiceInstanceOrDescriptor(e){let t=this._services.get(e);return!t&&this._parent?this._parent._getServiceInstanceOrDescriptor(e):t}_getOrCreateServiceInstance(e,t){let i=this._getServiceInstanceOrDescriptor(e);return i instanceof aa.M?this._safeCreateAndCacheServiceInstance(e,i,t.branch(e,!0)):(t.branch(e,!1),i)}_safeCreateAndCacheServiceInstance(e,t,i){if(this._activeInstantiations.has(e))throw new Error(`illegal state - RECURSIVELY instantiating service '${e}'`);this._activeInstantiations.add(e);try{return this._createAndCacheServiceInstance(e,t,i)}finally{this._activeInstantiations.delete(e)}}_createAndCacheServiceInstance(e,t,i){const n=new ca((e=>e.id.toString()));let o=0;const r=[{id:e,desc:t,_trace:i}];for(;r.length;){const t=r.pop();if(n.lookupOrInsertNode(t),o++>1e3)throw new ua(n);for(let i of hi.I8.getServiceDependencies(t.desc.ctor)){let o=this._getServiceInstanceOrDescriptor(i.id);if(o||this._throwIfStrict(`[createInstance] ${e} depends on ${i.id} which is NOT registered.`,!0),o instanceof aa.M){const e={id:i.id,desc:o,_trace:t._trace.branch(i.id,!0)};n.insertEdge(t,e),r.push(e)}}}for(;;){const e=n.roots();if(0===e.length){if(!n.isEmpty())throw new ua(n);break}for(const{data:t}of e){if(this._getServiceInstanceOrDescriptor(t.id)instanceof aa.M){const e=this._createServiceInstanceWithOwner(t.id,t.desc.ctor,t.desc.staticArguments,t.desc.supportsDelayedInstantiation,t._trace);this._setServiceInstance(t.id,e)}n.removeNode(t)}}return this._getServiceInstanceOrDescriptor(e)}_createServiceInstanceWithOwner(e,t,i=[],n,o){if(this._services.get(e)instanceof aa.M)return this._createServiceInstance(t,i,n,o);if(this._parent)return this._parent._createServiceInstanceWithOwner(e,t,i,n,o);throw new Error(`illegalState - creating UNKNOWN service instance ${t.name}`)}_createServiceInstance(e,t=[],i,n){if(i){const i=new ye.Ue((()=>this._createInstance(e,t,n)));return new Proxy(Object.create(null),{get(e,t){if(t in e)return e[t];let n=i.value,o=n[t];return"function"!=typeof o||(o=o.bind(n),e[t]=o),o},set:(e,t,n)=>(i.value[t]=n,!0)})}return this._createInstance(e,t,n)}_throwIfStrict(e,t){if(t&&console.warn(t),this._strict)throw new Error(e)}}class ga{constructor(e,t){this.type=e,this.name=t,this._start=Date.now(),this._dep=[]}static traceInvocation(e){return ga._None}static traceCreation(e){return ga._None}branch(e,t){let i=new ga(2,e.toString());return this._dep.push([e,t,i]),i}stop(){let e=Date.now()-this._start;ga._totals+=e;let t=!1,i=[`${0===this.type?"CREATE":"CALL"} ${this.name}`,`${function e(i,n){let o=[],r=new Array(i+1).join("\t");for(const[s,a,l]of n._dep)if(a&&l){t=!0,o.push(`${r}CREATES -> ${s}`);let n=e(i+1,l);n&&o.push(n)}else o.push(`${r}uses -> ${s}`);return o.join("\n")}(1,this)}`,`DONE, took ${e.toFixed(2)}ms (grand total ${ga._totals.toFixed(2)}ms)`];(e>2||t)&&console.log(i.join("\n"))}}ga._None=new class extends ga{constructor(){super(-1,null)}stop(){}branch(){return this}},ga._totals=0;class pa{constructor(){this._byResource=new Qi.Y9,this._byOwner=new Map}set(e,t,i){let n=this._byResource.get(e);n||(n=new Map,this._byResource.set(e,n)),n.set(t,i);let o=this._byOwner.get(t);o||(o=new Qi.Y9,this._byOwner.set(t,o)),o.set(e,i)}get(e,t){let i=this._byResource.get(e);return null==i?void 0:i.get(t)}delete(e,t){let i=!1,n=!1,o=this._byResource.get(e);o&&(i=o.delete(t));let r=this._byOwner.get(t);if(r&&(n=r.delete(e)),i!==n)throw new Error("illegal state");return i&&n}values(e){var t,i,n,o;return"string"==typeof e?null!==(i=null===(t=this._byOwner.get(e))||void 0===t?void 0:t.values())&&void 0!==i?i:Zs.$.empty():U.o.isUri(e)?null!==(o=null===(n=this._byResource.get(e))||void 0===n?void 0:n.values())&&void 0!==o?o:Zs.$.empty():Zs.$.map(Zs.$.concat(...this._byOwner.values()),(e=>e[1]))}}class ma{constructor(e){this.errors=0,this.infos=0,this.warnings=0,this.unknowns=0,this._data=new Qi.Y9,this._service=e,this._subscription=e.onMarkerChanged(this._update,this)}dispose(){this._subscription.dispose()}_update(e){for(const t of e){const e=this._data.get(t);e&&this._substract(e);const i=this._resourceStats(t);this._add(i),this._data.set(t,i)}}_resourceStats(e){const t={errors:0,warnings:0,infos:0,unknowns:0};if(e.scheme===ni.lg.inMemory||e.scheme===ni.lg.walkThrough||e.scheme===ni.lg.walkThroughSnippet)return t;for(const{severity:i}of this._service.read({resource:e}))i===Zo.ZL.Error?t.errors+=1:i===Zo.ZL.Warning?t.warnings+=1:i===Zo.ZL.Info?t.infos+=1:t.unknowns+=1;return t}_substract(e){this.errors-=e.errors,this.warnings-=e.warnings,this.infos-=e.infos,this.unknowns-=e.unknowns}_add(e){this.errors+=e.errors,this.warnings+=e.warnings,this.infos+=e.infos,this.unknowns+=e.unknowns}}class fa{constructor(){this._onMarkerChanged=new z.D0({delay:0,merge:fa._merge}),this.onMarkerChanged=this._onMarkerChanged.event,this._data=new pa,this._stats=new ma(this)}dispose(){this._stats.dispose(),this._onMarkerChanged.dispose()}remove(e,t){for(const i of t||[])this.changeOne(e,i,[])}changeOne(e,t,i){if((0,gt.XY)(i))this._data.delete(t,e)&&this._onMarkerChanged.fire([t]);else{const n=[];for(const o of i){const i=fa._toMarker(e,t,o);i&&n.push(i)}this._data.set(t,e,n),this._onMarkerChanged.fire([t])}}static _toMarker(e,t,i){let{code:n,severity:o,message:r,source:s,startLineNumber:a,startColumn:l,endLineNumber:c,endColumn:d,relatedInformation:u,tags:h}=i;if(r)return a=a>0?a:1,l=l>0?l:1,c=c>=a?c:a,d=d>0?d:l,{resource:t,owner:e,code:n,severity:o,message:r,source:s,startLineNumber:a,startColumn:l,endLineNumber:c,endColumn:d,relatedInformation:u,tags:h}}read(e=Object.create(null)){let{owner:t,resource:i,severities:n,take:o}=e;if((!o||o<0)&&(o=-1),t&&i){const e=this._data.get(i,t);if(e){const t=[];for(const i of e)if(fa._accept(i,n)){const e=t.push(i);if(o>0&&e===o)break}return t}return[]}if(t||i){const e=this._data.values(null!=i?i:t),r=[];for(const t of e)for(const e of t)if(fa._accept(e,n)){const t=r.push(e);if(o>0&&t===o)return r}return r}{const e=[];for(let t of this._data.values())for(let i of t)if(fa._accept(i,n)){const t=e.push(i);if(o>0&&t===o)return e}return e}}static _accept(e,t){return void 0===t||(t&e.severity)===e.severity}static _merge(e){const t=new Qi.Y9;for(let i of e)for(let e of i)t.set(e,!0);return Array.from(t.keys())}}var _a=i(86303);function ba(e,t,i,n,o){if(Array.isArray(e)){let r=0;for(const s of e){const e=ba(s,t,i,n,o);if(10===e)return e;e>r&&(r=e)}return r}if("string"==typeof e)return n?"*"===e?5:e===i?10:0:0;if(e){const{language:a,pattern:l,scheme:c,hasAccessToAllModels:d,notebookType:u}=e;if(!n&&!d)return 0;let h=0;if(c)if(c===t.scheme)h=10;else{if("*"!==c)return 0;h=5}if(a)if(a===i)h=10;else{if("*"!==a)return 0;h=Math.max(h,5)}if(u)if(u===o)h=10;else{if("*"!==u)return 0;h=Math.max(h,5)}if(l){let e;if(e="string"==typeof l?l:Object.assign(Object.assign({},l),{base:(0,Mn.Fv)(l.base)}),e!==t.fsPath&&(r=e,s=t.fsPath,!r||"string"!=typeof s||!Jn(r)(s,void 0,undefined)))return 0;h=10}return h}return 0;var r,s}function va(e){return"string"!=typeof e&&(Array.isArray(e)?e.every(va):!!e.exclusive)}class Ca{constructor(e){this._notebookTypeResolver=e,this._clock=0,this._entries=[],this._onDidChange=new z.Q5,this.onDidChange=this._onDidChange.event}register(e,t){let i={selector:e,provider:t,_score:-1,_time:this._clock++};return this._entries.push(i),this._lastCandidate=void 0,this._onDidChange.fire(this._entries.length),(0,Se.OF)((()=>{if(i){const e=this._entries.indexOf(i);e>=0&&(this._entries.splice(e,1),this._lastCandidate=void 0,this._onDidChange.fire(this._entries.length),i=void 0)}}))}has(e){return this.all(e).length>0}all(e){if(!e)return[];this._updateScores(e);const t=[];for(let e of this._entries)e._score>0&&t.push(e.provider);return t}ordered(e){const t=[];return this._orderedForEach(e,(e=>t.push(e.provider))),t}orderedGroups(e){const t=[];let i,n;return this._orderedForEach(e,(e=>{i&&n===e._score?i.push(e.provider):(n=e._score,i=[e.provider],t.push(i))})),t}_orderedForEach(e,t){if(e){this._updateScores(e);for(const e of this._entries)e._score>0&&t(e)}}_updateScores(e){var t;const i=null===(t=this._notebookTypeResolver)||void 0===t?void 0:t.call(this,e.uri),n={uri:e.uri.toString(),language:e.getLanguageId(),notebookType:i};if(!this._lastCandidate||this._lastCandidate.language!==n.language||this._lastCandidate.uri!==n.uri||this._lastCandidate.notebookType!==n.notebookType){this._lastCandidate=n;for(let t of this._entries)if(t._score=ba(t.selector,e.uri,e.getLanguageId(),(0,_e.pt)(e),i),va(t.selector)&&t._score>0){for(let e of this._entries)e._score=0;t._score=1e3;break}this._entries.sort(Ca._compareByScoreAndTime)}}static _compareByScoreAndTime(e,t){return e._scoret._score?-1:e._timet._time?-1:0}}(0,ci.z)(mt.p,class{constructor(){this.referenceProvider=new Ca(this._score.bind(this)),this.renameProvider=new Ca(this._score.bind(this)),this.codeActionProvider=new Ca(this._score.bind(this)),this.definitionProvider=new Ca(this._score.bind(this)),this.typeDefinitionProvider=new Ca(this._score.bind(this)),this.declarationProvider=new Ca(this._score.bind(this)),this.implementationProvider=new Ca(this._score.bind(this)),this.documentSymbolProvider=new Ca(this._score.bind(this)),this.inlayHintsProvider=new Ca(this._score.bind(this)),this.colorProvider=new Ca(this._score.bind(this)),this.codeLensProvider=new Ca(this._score.bind(this)),this.documentFormattingEditProvider=new Ca(this._score.bind(this)),this.documentRangeFormattingEditProvider=new Ca(this._score.bind(this)),this.onTypeFormattingEditProvider=new Ca(this._score.bind(this)),this.signatureHelpProvider=new Ca(this._score.bind(this)),this.hoverProvider=new Ca(this._score.bind(this)),this.documentHighlightProvider=new Ca(this._score.bind(this)),this.selectionRangeProvider=new Ca(this._score.bind(this)),this.foldingRangeProvider=new Ca(this._score.bind(this)),this.linkProvider=new Ca(this._score.bind(this)),this.inlineCompletionsProvider=new Ca(this._score.bind(this)),this.completionProvider=new Ca(this._score.bind(this)),this.linkedEditingRangeProvider=new Ca(this._score.bind(this)),this.documentRangeSemanticTokensProvider=new Ca(this._score.bind(this)),this.documentSemanticTokensProvider=new Ca(this._score.bind(this))}_score(e){var t;return null===(t=this._notebookTypeResolver)||void 0===t?void 0:t.call(this,e)}},!0);var wa=function(e,t,i,n){var o,r=arguments.length,s=r<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,i):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(e,t,i,n);else for(var a=e.length-1;a>=0;a--)(o=e[a])&&(s=(r<3?o(s):r>3?o(t,i,s):o(t,i))||s);return r>3&&s&&Object.defineProperty(t,i,s),s},ya=function(e,t){return function(i,n){t(i,n,e)}},Sa=function(e,t,i,n){return new(i||(i=Promise))((function(o,r){function s(e){try{l(n.next(e))}catch(e){r(e)}}function a(e){try{l(n.throw(e))}catch(e){r(e)}}function l(e){var t;e.done?o(e.value):(t=e.value,t instanceof i?t:new i((function(e){e(t)}))).then(s,a)}l((n=n.apply(e,t||[])).next())}))};class xa{constructor(e){this.disposed=!1,this.model=e,this._onWillDispose=new z.Q5}get textEditorModel(){return this.model}dispose(){this.disposed=!0,this._onWillDispose.fire()}}let ka=class{constructor(e){this.modelService=e}createModelReference(e){const t=this.modelService.getModel(e);return t?Promise.resolve(new Se.Jz(new xa(t))):Promise.reject(new Error("Model not found"))}};ka=wa([ya(0,we.q)],ka);class La{show(){return La.NULL_PROGRESS_RUNNER}showWhile(e,t){return Sa(this,void 0,void 0,(function*(){yield e}))}}La.NULL_PROGRESS_RUNNER={done:()=>{},total:()=>{},worked:()=>{}};class Ea{info(e){return this.notify({severity:bi.Z.Info,message:e})}warn(e){return this.notify({severity:bi.Z.Warning,message:e})}error(e){return this.notify({severity:bi.Z.Error,message:e})}notify(e){switch(e.severity){case bi.Z.Error:console.error(e.message);break;case bi.Z.Warning:console.warn(e.message);break;default:console.log(e.message)}return Ea.NO_OP}status(e,t){return Se.JT.None}}Ea.NO_OP=new wi.EO;let Na=class{constructor(e){this._onWillExecuteCommand=new z.Q5,this._onDidExecuteCommand=new z.Q5,this.onWillExecuteCommand=this._onWillExecuteCommand.event,this.onDidExecuteCommand=this._onDidExecuteCommand.event,this._instantiationService=e}executeCommand(e,...t){const i=Zi.P0.getCommand(e);if(!i)return Promise.reject(new Error(`command '${e}' not found`));try{this._onWillExecuteCommand.fire({commandId:e,args:t});const n=this._instantiationService.invokeFunction.apply(this._instantiationService,[i.handler,...t]);return this._onDidExecuteCommand.fire({commandId:e,args:t}),Promise.resolve(n)}catch(e){return Promise.reject(e)}}};Na=wa([ya(0,hi.TG)],Na);let Da=class extends rn{constructor(e,t,i,n,o,r){super(e,t,i,n,o),this._cachedResolver=null,this._dynamicKeybindings=[],this._domNodeListeners=[];const s=e=>{const t=new Se.SL;t.add(ii.nm(e,ii.tw.KEY_DOWN,(e=>{const t=new Pi.y(e);this._dispatch(t,t.target)&&(t.preventDefault(),t.stopPropagation())}))),t.add(ii.nm(e,ii.tw.KEY_UP,(e=>{const t=new Pi.y(e);this._singleModifierDispatch(t,t.target)&&t.preventDefault()}))),this._domNodeListeners.push(new Ia(e,t))},a=e=>{for(let t=0;t{e.getOption(54)||s(e.getContainerDomNode())};this._register(r.onCodeEditorAdd(l)),this._register(r.onCodeEditorRemove((e=>{e.getOption(54)||a(e.getContainerDomNode())}))),r.listCodeEditors().forEach(l);const c=e=>{s(e.getContainerDomNode())};this._register(r.onDiffEditorAdd(c)),this._register(r.onDiffEditorRemove((e=>{a(e.getContainerDomNode())}))),r.listDiffEditors().forEach(c)}addDynamicKeybinding(e,t,i,n){const o=(0,Fi.gm)(t,ke.OS),r=new Se.SL;return o&&(this._dynamicKeybindings.push({keybinding:o.parts,command:e,when:n,weight1:1e3,weight2:0,extensionId:null,isBuiltinExtension:!1}),r.add((0,Se.OF)((()=>{for(let t=0;tthis._log(e)))}return this._cachedResolver}_documentHasFocus(){return document.hasFocus()}_toNormalizedKeybindingItems(e,t){const i=[];let n=0;for(const o of e){const e=o.when||void 0,r=o.keybinding;if(r){const s=fn.resolveUserBinding(r,ke.OS);for(const r of s)i[n++]=new hn(r,o.command,o.commandArgs,e,t,null,!1)}else i[n++]=new hn(void 0,o.command,o.commandArgs,e,t,null,!1)}return i}resolveKeyboardEvent(e){const t=new Fi.QC(e.ctrlKey,e.shiftKey,e.altKey,e.metaKey,e.keyCode).toChord();return new fn(t,ke.OS)}};Da=wa([ya(0,li.i6),ya(1,Zi.Hy),ya(2,Cn.b),ya(3,wi.lT),ya(4,pt.VZ),ya(5,ge.$)],Da);class Ia extends Se.JT{constructor(e,t){super(),this.domNode=e,this._register(t)}}function Ta(e){return e&&"object"==typeof e&&(!e.overrideIdentifier||"string"==typeof e.overrideIdentifier)&&(!e.resource||e.resource instanceof U.o)}class Aa{constructor(){this._onDidChangeConfiguration=new z.Q5,this.onDidChangeConfiguration=this._onDidChangeConfiguration.event,this._configuration=new tn(new en,new Ji)}getValue(e,t){const i="string"==typeof e?e:void 0,n=Ta(e)?e:Ta(t)?t:{};return this._configuration.getValue(i,n,void 0)}updateValues(e){const t={data:this._configuration.toData()},i=[];for(const t of e){const[e,n]=t;this.getValue(e)!==n&&(this._configuration.updateValue(e,n),i.push(e))}if(i.length>0){const e=new nn({keys:i,overrides:[]},t,this._configuration);e.source=7,e.sourceConfig=null,this._onDidChangeConfiguration.fire(e)}return Promise.resolve()}updateValue(e,t,i,n){return this.updateValues([[e,t]])}inspect(e,t={}){return this._configuration.inspect(e,t,void 0)}}let Ra=class{constructor(e){this.configurationService=e,this._onDidChangeConfiguration=new z.Q5,this.configurationService.onDidChangeConfiguration((e=>{this._onDidChangeConfiguration.fire({affectedKeys:e.affectedKeys,affectsConfiguration:(t,i)=>e.affectsConfiguration(i)})}))}getValue(e,t,i){const n=j.L.isIPosition(t)&&t?"string"==typeof i?i:void 0:"string"==typeof t?t:void 0;return void 0===n?this.configurationService.getValue():this.configurationService.getValue(n)}};Ra=wa([ya(0,Yi.Ui)],Ra);let Ma=class{constructor(e){this.configurationService=e}getEOL(e,t){const i=this.configurationService.getValue("files.eol",{overrideIdentifier:t,resource:e});return i&&"string"==typeof i&&"auto"!==i?i:ke.IJ||ke.dz?"\n":"\r\n"}};Ma=wa([ya(0,Yi.Ui)],Ma);class Oa{constructor(){const e=U.o.from({scheme:Oa.SCHEME,authority:"model",path:"/"});this.workspace={id:"4064f6ec-cb38-4ad0-af64-ee6467e63c82",folders:[new wn.md({uri:e,name:"",index:0})]}}getWorkspace(){return this.workspace}}function Pa(e,t,i){if(!t)return;if(!(e instanceof Aa))return;const n=[];Object.keys(t).forEach((e=>{(function(e){return Ki()[`editor.${e}`]||!1})(e)&&n.push([`editor.${e}`,t[e]]),i&&function(e){return Ki()[`diffEditor.${e}`]||!1}(e)&&n.push([`diffEditor.${e}`,t[e]])})),n.length>0&&e.updateValues(n)}Oa.SCHEME="inmemory";let Fa=class{constructor(e){this._modelService=e}hasPreviewHandler(){return!1}apply(e,t){return Sa(this,void 0,void 0,(function*(){const t=new Map;for(let i of e){if(!(i instanceof Bi.Gl))throw new Error("bad edit - only text edits are supported");const e=this._modelService.getModel(i.resource);if(!e)throw new Error("bad edit - model not found");if("number"==typeof i.versionId&&e.getVersionId()!==i.versionId)throw new Error("bad state - model changed in the meantime");let n=t.get(e);n||(n=[],t.set(e,n)),n.push(qi.h.replaceMove(K.e.lift(i.textEdit.range),i.textEdit.text))}let i=0,n=0;for(const[e,o]of t)e.pushStackElement(),e.pushEditOperations([],o,(()=>[])),e.pushStackElement(),n+=1,i+=o.length;return{ariaSummary:ue.WU(yn.iN.bulkEditServiceSummary,i,n)}}))}};Fa=wa([ya(0,we.q)],Fa);let Ba=class extends An{constructor(e,t){super(e),this._codeEditorService=t}showContextView(e,t,i){if(!t){const e=this._codeEditorService.getFocusedCodeEditor()||this._codeEditorService.getActiveCodeEditor();e&&(t=e.getContainerDomNode())}return super.showContextView(e,t,i)}};Ba=wa([ya(0,gi),ya(1,ge.$)],Ba);class Wa extends pt.$V{constructor(){super(new pt.kw)}}let Va=class extends Bo{constructor(e,t,i,n,o){super(e,t,i,n,o),this.configure({blockMouse:!1})}};var Ha;Va=wa([ya(0,Cn.b),ya(1,wi.lT),ya(2,xn.u),ya(3,an.d),ya(4,oi.XE)],Va),(0,ci.z)(Yi.Ui,Aa),(0,ci.z)(ht.V,Ra),(0,ci.z)(ht.y,Ma),(0,ci.z)(wn.ec,Oa),(0,ci.z)(bn.e,class{getUriLabel(e,t){return"file"===e.scheme?e.fsPath:e.path}}),(0,ci.z)(Cn.b,class{publicLog(e,t){return Promise.resolve(void 0)}publicLog2(e,t){return this.publicLog(e,t)}}),(0,ci.z)(Ci.S,class{confirm(e){return this.doConfirm(e).then((e=>({confirmed:e,checkboxChecked:!1})))}doConfirm(e){let t=e.message;return e.detail&&(t=t+"\n\n"+e.detail),Promise.resolve(window.confirm(t))}show(e,t,i,n){return Promise.resolve({choice:0})}}),(0,ci.z)(wi.lT,Ea),(0,ci.z)(Zo.lT,fa),(0,ci.z)(Ce.O,class extends po{constructor(){super()}}),(0,ci.z)(Fs.Z,Ps),(0,ci.z)(pt.VZ,Wa),(0,ci.z)(we.q,ir.b$),(0,ci.z)(tr.i,er),(0,ci.z)(li.i6,ra),(0,ci.z)(vn.ek,La),(0,ci.z)(_a.Uy,_a.vm),(0,ci.z)(ti.p,vt),(0,ci.z)(Bi.vu,Fa),(0,ci.z)(Sn.Y,class{constructor(){this._neverEmitter=new z.Q5,this.onDidChangeTrust=this._neverEmitter.event}isWorkspaceTrusted(){return!0}}),(0,ci.z)(Gi.S,ka),(0,ci.z)(sr.F,Ws),(0,ci.z)(es.Lw,es.XN),(0,ci.z)(Zi.Hy,Na),(0,ci.z)(an.d,Da),(0,ci.z)(ns.eJ,us),(0,ci.z)(xn.u,Ba),(0,ci.z)(zo.v4,Go),(0,ci.z)(Gs.p,qs),(0,ci.z)(xn.i,Va),(0,ci.z)(Vs.co,$s),function(e){const t=new da.y;for(const[e,i]of(0,ci.d)())t.set(e,i);const i=new ha(t,!0);t.set(hi.TG,i),e.get=function(e){const n=t.get(e);if(!n)throw new Error("Missing service "+e);return n instanceof aa.M?i.invokeFunction((t=>t.get(e))):n};let n=!1;e.initialize=function(e){if(n)return i;n=!0;for(const[e,i]of(0,ci.d)())t.get(e)||t.set(e,i);for(const i in e)if(e.hasOwnProperty(i)){const n=(0,hi.yh)(i);t.get(n)instanceof aa.M&&t.set(n,e[i])}return i}}(Ha||(Ha={}));var za=function(e,t,i,n){var o,r=arguments.length,s=r<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,i):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(e,t,i,n);else for(var a=e.length-1;a>=0;a--)(o=e[a])&&(s=(r<3?o(s):r>3?o(t,i,s):o(t,i))||s);return r>3&&s&&Object.defineProperty(t,i,s),s},$a=function(e,t){return function(i,n){t(i,n,e)}};let Ua=0,ja=!1,Ka=class extends Xt.Gm{constructor(e,t,i,n,o,r,s,a,l,c,d,u){const h=Object.assign({},t);h.ariaLabel=h.ariaLabel||yn.B8.editorViewAccessibleLabel,h.ariaLabel=h.ariaLabel+";"+yn.B8.accessibilityHelpMessage,super(e,h,{},i,n,o,r,a,l,c,d,u),this._standaloneKeybindingService=s instanceof Da?s:null,function(e){if(!e){if(ja)return;ja=!0}Qt.wW(e||document.body)}(h.ariaContainerElement)}addCommand(e,t,i){if(!this._standaloneKeybindingService)return console.warn("Cannot add command because the editor is configured with an unrecognized KeybindingService"),null;const n="DYNAMIC_"+ ++Ua,o=li.Ao.deserialize(i);return this._standaloneKeybindingService.addDynamicKeybinding(n,e,t,o),n}createContextKey(e,t){return this._contextKeyService.createKey(e,t)}addAction(e){if("string"!=typeof e.id||"string"!=typeof e.label||"function"!=typeof e.run)throw new Error("Invalid action descriptor, `id`, `label` and `run` are required properties!");if(!this._standaloneKeybindingService)return console.warn("Cannot add keybinding because the editor is configured with an unrecognized KeybindingService"),Se.JT.None;const t=e.id,i=e.label,n=li.Ao.and(li.Ao.equals("editorId",this.getId()),li.Ao.deserialize(e.precondition)),o=e.keybindings,r=li.Ao.and(n,li.Ao.deserialize(e.keybindingContext)),s=e.contextMenuGroupId||null,a=e.contextMenuOrder||0,l=(t,...i)=>Promise.resolve(e.run(this,...i)),c=new Se.SL,d=this.getId()+":"+t;if(c.add(Zi.P0.registerCommand(d,l)),s){const e={command:{id:d,title:i},when:n,group:s,order:a};c.add(Vs.BH.appendMenuItem(Vs.eH.EditorContext,e))}if(Array.isArray(o))for(const e of o)c.add(this._standaloneKeybindingService.addDynamicKeybinding(d,e,l,r));const u=new ei.p(d,i,i,n,l,this._contextKeyService);return this._actions[t]=u,c.add((0,Se.OF)((()=>{delete this._actions[t]}))),c}_triggerCommand(e,t){if(this._codeEditorService instanceof ui)try{this._codeEditorService.setActiveCodeEditor(this),super._triggerCommand(e,t)}finally{this._codeEditorService.setActiveCodeEditor(null)}else super._triggerCommand(e,t)}};Ka=za([$a(2,hi.TG),$a(3,ge.$),$a(4,Zi.Hy),$a(5,li.i6),$a(6,an.d),$a(7,oi.XE),$a(8,wi.lT),$a(9,sr.F),$a(10,be.c_),$a(11,mt.p)],Ka);let qa=class extends Ka{constructor(e,t,i,n,o,r,s,a,l,c,d,u,h,g,p){const m=Object.assign({},t);Pa(c,m,!1);const f=a.registerEditorContainer(e);"string"==typeof m.theme&&a.setTheme(m.theme),void 0!==m.autoDetectHighContrast&&a.setAutoDetectHighContrast(Boolean(m.autoDetectHighContrast));const _=m.model;let b;if(delete m.model,super(e,m,i,n,o,r,s,a,l,d,g,p),this._configurationService=c,this._standaloneThemeService=a,this._register(f),void 0===_){const e=h.getLanguageIdByMimeType(m.language)||m.language||lo.bd;b=Za(u,h,m.value||"",e,void 0),this._ownsModel=!0}else b=_,this._ownsModel=!1;if(this._attachModel(b),b){const e={oldModelUrl:null,newModelUrl:b.uri};this._onDidChangeModel.fire(e)}}dispose(){super.dispose()}updateOptions(e){Pa(this._configurationService,e,!1),"string"==typeof e.theme&&this._standaloneThemeService.setTheme(e.theme),void 0!==e.autoDetectHighContrast&&this._standaloneThemeService.setAutoDetectHighContrast(Boolean(e.autoDetectHighContrast)),super.updateOptions(e)}_postDetachModelCleanup(e){super._postDetachModelCleanup(e),e&&this._ownsModel&&(e.dispose(),this._ownsModel=!1)}};qa=za([$a(2,hi.TG),$a(3,ge.$),$a(4,Zi.Hy),$a(5,li.i6),$a(6,an.d),$a(7,Fs.Z),$a(8,wi.lT),$a(9,Yi.Ui),$a(10,sr.F),$a(11,we.q),$a(12,Ce.O),$a(13,be.c_),$a(14,mt.p)],qa);let Ga=class extends Jt.p{constructor(e,t,i,n,o,r,s,a,l,c,d,u){const h=Object.assign({},t);Pa(l,h,!0);const g=s.registerEditorContainer(e);"string"==typeof h.theme&&s.setTheme(h.theme),void 0!==h.autoDetectHighContrast&&s.setAutoDetectHighContrast(Boolean(h.autoDetectHighContrast)),super(e,h,{},u,o,n,i,r,s,a,c,d),this._configurationService=l,this._standaloneThemeService=s,this._register(g)}dispose(){super.dispose()}updateOptions(e){Pa(this._configurationService,e,!0),"string"==typeof e.theme&&this._standaloneThemeService.setTheme(e.theme),void 0!==e.autoDetectHighContrast&&this._standaloneThemeService.setAutoDetectHighContrast(Boolean(e.autoDetectHighContrast)),super.updateOptions(e)}_createInnerEditor(e,t,i){return e.createInstance(Ka,t,i)}getOriginalEditor(){return super.getOriginalEditor()}getModifiedEditor(){return super.getModifiedEditor()}addCommand(e,t,i){return this.getModifiedEditor().addCommand(e,t,i)}createContextKey(e,t){return this.getModifiedEditor().createContextKey(e,t)}addAction(e){return this.getModifiedEditor().addAction(e)}};function Za(e,t,i,n,o){if(i=i||"",!n){const n=i.indexOf("\n");let r=i;return-1!==n&&(r=i.substring(0,n)),Ya(e,i,t.createByFilepathOrFirstLine(o||null,r),o)}return Ya(e,i,t.createById(n),o)}function Ya(e,t,i,n){return e.createModel(t,i,n)}function Qa(e,t){return"boolean"==typeof e?e:t}function Xa(e,t){return"string"==typeof e?e:t}function Ja(e,t=!1){t&&(e=e.map((function(e){return e.toLowerCase()})));const i=function(e){const t={};for(const i of e)t[i]=!0;return t}(e);return t?function(e){return void 0!==i[e.toLowerCase()]&&i.hasOwnProperty(e.toLowerCase())}:function(e){return void 0!==i[e]&&i.hasOwnProperty(e)}}function el(e,t){t=t.replace(/@@/g,"");let i,n=0;do{i=!1,t=t.replace(/@(\w+)/g,(function(n,o){i=!0;let r="";if("string"==typeof e[o])r=e[o];else{if(!(e[o]&&e[o]instanceof RegExp))throw void 0===e[o]?Ot(e,"language definition does not contain attribute '"+o+"', used at: "+t):Ot(e,"attribute reference '"+o+"' must be a string, used at: "+t);r=e[o].source}return At(r)?"":"(?:"+r+")"})),n++}while(i&&n<5);t=t.replace(/\x01/g,"@");const o=(e.ignoreCase?"i":"")+(e.unicode?"u":"");return new RegExp(t,o)}function tl(e,t,i,n){let o=-1,r=i,s=i.match(/^\$(([sS]?)(\d\d?)|#)(.*)$/);s&&(s[3]&&(o=parseInt(s[3]),s[2]&&(o+=100)),r=s[4]);let a,l="~",c=r;if(r&&0!==r.length?/^\w*$/.test(c)?l="==":(s=r.match(/^(@|!@|~|!~|==|!=)(.*)$/),s&&(l=s[1],c=s[2])):(l="!=",c=""),"~"!==l&&"!~"!==l||!/^(\w|\|)*$/.test(c))if("@"===l||"!@"===l){const i=e[c];if(!i)throw Ot(e,"the @ match target '"+c+"' is not defined, in rule: "+t);if(!function(e,t){if(!t)return!1;if(!Array.isArray(t))return!1;for(const e of t)if("string"!=typeof e)return!1;return!0}(0,i))throw Ot(e,"the @ match target '"+c+"' must be an array of strings, in rule: "+t);const n=Ja(i,e.ignoreCase);a=function(e){return"@"===l?n(e):!n(e)}}else if("~"===l||"!~"===l)if(c.indexOf("$")<0){const t=el(e,"^"+c+"$");a=function(e){return"~"===l?t.test(e):!t.test(e)}}else a=function(t,i,n,o){return el(e,"^"+Pt(e,c,i,n,o)+"$").test(t)};else if(c.indexOf("$")<0){const t=Rt(e,c);a=function(e){return"=="===l?e===t:e!==t}}else{const t=Rt(e,c);a=function(i,n,o,r,s){const a=Pt(e,t,n,o,r);return"=="===l?i===a:i!==a}}else{const t=Ja(c.split("|"),e.ignoreCase);a=function(e){return"~"===l?t(e):!t(e)}}return-1===o?{name:i,value:n,test:function(e,t,i,n){return a(e,e,t,i,n)}}:{name:i,value:n,test:function(e,t,i,n){const r=function(e,t,i,n){if(n<0)return e;if(n=100){n-=100;const e=i.split(".");if(e.unshift(i),n=0&&(n.tokenSubst=!0),"string"==typeof i.bracket)if("@open"===i.bracket)n.bracket=1;else{if("@close"!==i.bracket)throw Ot(e,"a 'bracket' attribute must be either '@open' or '@close', in rule: "+t);n.bracket=-1}if(i.next){if("string"!=typeof i.next)throw Ot(e,"the next state must be a string value in rule: "+t);{let o=i.next;if(!/^(@pop|@push|@popall)$/.test(o)&&("@"===o[0]&&(o=o.substr(1)),o.indexOf("$")<0&&!function(e,t){let i=t;for(;i&&i.length>0;){if(e.stateNames[i])return!0;const t=i.lastIndexOf(".");i=t<0?null:i.substr(0,t)}return!1}(e,Pt(e,o,"",[],""))))throw Ot(e,"the next state '"+i.next+"' is not defined in rule: "+t);n.next=o}}return"number"==typeof i.goBack&&(n.goBack=i.goBack),"string"==typeof i.switchTo&&(n.switchTo=i.switchTo),"string"==typeof i.log&&(n.log=i.log),"string"==typeof i.nextEmbedded&&(n.nextEmbedded=i.nextEmbedded,e.usesEmbedded=!0),n}}if(Array.isArray(i)){const n=[];for(let o=0,r=i.length;o0&&"^"===i[0],this.name=this.name+": "+i,this.regex=el(e,"^(?:"+(this.matchOnlyAtLineStart?i.substr(1):i)+")")}setAction(e,t){this.action=il(e,this.name,t)}}function ol(e,t){if(!t||"object"!=typeof t)throw new Error("Monarch: expecting a language definition object");const i={};i.languageId=e,i.includeLF=Qa(t.includeLF,!1),i.noThrow=!1,i.maxStack=100,i.start="string"==typeof t.start?t.start:null,i.ignoreCase=Qa(t.ignoreCase,!1),i.unicode=Qa(t.unicode,!1),i.tokenPostfix=Xa(t.tokenPostfix,"."+i.languageId),i.defaultToken=Xa(t.defaultToken,"source"),i.usesEmbedded=!1;const n=t;function o(e,r,s){for(const a of s){let s=a.include;if(s){if("string"!=typeof s)throw Ot(i,"an 'include' attribute must be a string at: "+e);if("@"===s[0]&&(s=s.substr(1)),!t.tokenizer[s])throw Ot(i,"include target '"+s+"' is not defined at: "+e);o(e+"."+s,r,t.tokenizer[s])}else{const t=new nl(e);if(Array.isArray(a)&&a.length>=1&&a.length<=3)if(t.setRegex(n,a[0]),a.length>=3)if("string"==typeof a[1])t.setAction(n,{token:a[1],next:a[2]});else{if("object"!=typeof a[1])throw Ot(i,"a next state as the last element of a rule can only be given if the action is either an object or a string, at: "+e);{const e=a[1];e.next=a[2],t.setAction(n,e)}}else t.setAction(n,a[1]);else{if(!a.regex)throw Ot(i,"a rule must either be an array, or an object with a 'regex' or 'include' field at: "+e);a.name&&"string"==typeof a.name&&(t.name=a.name),a.matchOnlyAtStart&&(t.matchOnlyAtLineStart=Qa(a.matchOnlyAtLineStart,!1)),t.setRegex(n,a.regex),t.setAction(n,a.action)}r.push(t)}}}if(n.languageId=e,n.includeLF=i.includeLF,n.ignoreCase=i.ignoreCase,n.unicode=i.unicode,n.noThrow=i.noThrow,n.usesEmbedded=i.usesEmbedded,n.stateNames=t.tokenizer,n.defaultToken=i.defaultToken,!t.tokenizer||"object"!=typeof t.tokenizer)throw Ot(i,"a language definition must define the 'tokenizer' attribute as an object");i.tokenizer=[];for(let e in t.tokenizer)if(t.tokenizer.hasOwnProperty(e)){i.start||(i.start=e);const n=t.tokenizer[e];i.tokenizer[e]=new Array,o("tokenizer."+e,i.tokenizer[e],n)}if(i.usesEmbedded=n.usesEmbedded,t.brackets){if(!Array.isArray(t.brackets))throw Ot(i,"the 'brackets' attribute must be defined as an array")}else t.brackets=[{open:"{",close:"}",token:"delimiter.curly"},{open:"[",close:"]",token:"delimiter.square"},{open:"(",close:")",token:"delimiter.parenthesis"},{open:"<",close:">",token:"delimiter.angle"}];const r=[];for(let e of t.brackets){let t=e;if(t&&Array.isArray(t)&&3===t.length&&(t={token:t[2],open:t[0],close:t[1]}),t.open===t.close)throw Ot(i,"open and close brackets in a 'brackets' attribute must be different: "+t.open+"\n hint: use the 'bracket' attribute if matching on equal brackets is required.");if("string"!=typeof t.open||"string"!=typeof t.token||"string"!=typeof t.close)throw Ot(i,"every element in the 'brackets' array must be a '{open,close,token}' object or array");r.push({token:t.token+i.tokenPostfix,open:Rt(i,t.open),close:Rt(i,t.close)})}return i.brackets=r,i.noThrow=!0,i}class rl{constructor(e,t){this._languageId=e,this._actual=t}getInitialState(){return this._actual.getInitialState()}tokenize(e,t,i){if("function"==typeof this._actual.tokenize)return sl.adaptTokenize(this._languageId,this._actual,e,i);throw new Error("Not supported!")}tokenizeEncoded(e,t,i){const n=this._actual.tokenizeEncoded(e,i);return new G.DI(n.tokens,n.endState)}}class sl{constructor(e,t,i,n){this._languageId=e,this._actual=t,this._languageService=i,this._standaloneThemeService=n}getInitialState(){return this._actual.getInitialState()}static _toClassicTokens(e,t){const i=[];let n=0;for(let o=0,r=e.length;o0&&o[r-1]===l)continue;let c=a.startIndex;0===e?c=0:c{return i=this,n=void 0,r=function*(){const i=yield Promise.resolve(t.create());return i?"function"==typeof i.getInitialState?ll(e,i):new jt(Ha.get(Ce.O),Ha.get(Fs.Z),e,ol(e,i)):null},new((o=void 0)||(o=Promise))((function(e,t){function s(e){try{l(r.next(e))}catch(e){t(e)}}function a(e){try{l(r.throw(e))}catch(e){t(e)}}function l(t){var i;t.done?e(t.value):(i=t.value,i instanceof o?i:new o((function(e){e(i)}))).then(s,a)}l((r=r.apply(i,n||[])).next())}));var i,n,o,r}};return G.RW.registerFactory(e,i)}var dl,ul=i(29506);V.BH.wrappingIndent.defaultValue=0,V.BH.glyphMargin.defaultValue=!1,V.BH.autoIndent.defaultValue=3,V.BH.overviewRulerLanes.defaultValue=2,ul.xC.setFormatterSelector(((e,t,i)=>Promise.resolve(e[0])));const hl=Y();Object.defineProperty(hl,"version",{get:function(){return"0.33.0"}});const gl=hl.version;hl.editor={create:function(e,t,i){return Ha.initialize(i||{}).createInstance(qa,e,t)},onDidCreateEditor:function(e){return Ha.get(ge.$).onCodeEditorAdd((t=>{e(t)}))},createDiffEditor:function(e,t,i){return Ha.initialize(i||{}).createInstance(Ga,e,t)},createDiffNavigator:function(e,t){return new pe.F(e,t)},createModel:function(e,t,i){const n=Ha.get(Ce.O),o=n.getLanguageIdByMimeType(t)||t;return Za(Ha.get(we.q),n,e,o,i)},setModelLanguage:function(e,t){const i=Ha.get(Ce.O);Ha.get(we.q).setMode(e,i.createById(t))},setModelMarkers:function(e,t,i){e&&Ha.get(Zo.lT).changeOne(t,e.uri,i)},getModelMarkers:function(e){return Ha.get(Zo.lT).read(e)},onDidChangeMarkers:function(e){return Ha.get(Zo.lT).onMarkerChanged(e)},getModels:function(){return Ha.get(we.q).getModels()},getModel:function(e){return Ha.get(we.q).getModel(e)},onDidCreateModel:function(e){return Ha.get(we.q).onModelAdded(e)},onWillDisposeModel:function(e){return Ha.get(we.q).onModelRemoved(e)},onDidChangeModelLanguage:function(e){return Ha.get(we.q).onModelLanguageChanged((t=>{e({model:t.model,oldLanguage:t.oldLanguageId})}))},createWebWorker:function(e){return function(e,t,i){return new Lt(e,t,i)}(Ha.get(we.q),Ha.get(be.c_),e)},colorizeElement:function(e,t){const i=Ha.get(Ce.O),n=Ha.get(Fs.Z);return n.registerEditorContainer(e),Zt.colorizeElement(n,i,e,t)},colorize:function(e,t,i){const n=Ha.get(Ce.O);return Ha.get(Fs.Z).registerEditorContainer(document.body),Zt.colorize(n,e,t,i)},colorizeModelLine:function(e,t,i=4){return Ha.get(Fs.Z).registerEditorContainer(document.body),Zt.colorizeModelLine(e,t,i)},tokenize:function(e,t){G.RW.getOrCreate(t);const i=(n=t,G.RW.get(n)||{getInitialState:()=>ve.TJ,tokenize:(e,t,i)=>(0,ve.Ri)(n,i)});var n;const o=(0,ue.uq)(e),r=[];let s=i.getInitialState();for(let e=0,t=o.length;e{n===e&&(i.dispose(),t())}));return i},getEncodedLanguageId:function(e){return Ha.get(Ce.O).languageIdCodec.encodeLanguageId(e)},setLanguageConfiguration:function(e,t){if(!Ha.get(Ce.O).isRegisteredLanguageId(e))throw new Error(`Cannot set configuration for unknown language ${e}`);return be.zu.register(e,t,100)},setColorMap:function(e){const t=Ha.get(Fs.Z);if(e){const i=[null];for(let t=1,n=e.length;tt}):G.RW.register(e,ll(e,t))},setMonarchTokensProvider:function(e,t){return al(t)?cl(e,{create:()=>t}):G.RW.register(e,(t=>new jt(Ha.get(Ce.O),Ha.get(Fs.Z),e,ol(e,t)))(t))},registerReferenceProvider:function(e,t){return Ha.get(mt.p).referenceProvider.register(e,t)},registerRenameProvider:function(e,t){return Ha.get(mt.p).renameProvider.register(e,t)},registerCompletionItemProvider:function(e,t){return Ha.get(mt.p).completionProvider.register(e,t)},registerSignatureHelpProvider:function(e,t){return Ha.get(mt.p).signatureHelpProvider.register(e,t)},registerHoverProvider:function(e,t){return Ha.get(mt.p).hoverProvider.register(e,{provideHover:(e,i,n)=>{const o=e.getWordAtPosition(i);return Promise.resolve(t.provideHover(e,i,n)).then((e=>{if(e)return!e.range&&o&&(e.range=new K.e(i.lineNumber,o.startColumn,i.lineNumber,o.endColumn)),e.range||(e.range=new K.e(i.lineNumber,i.column,i.lineNumber,i.column)),e}))}})},registerDocumentSymbolProvider:function(e,t){return Ha.get(mt.p).documentSymbolProvider.register(e,t)},registerDocumentHighlightProvider:function(e,t){return Ha.get(mt.p).documentHighlightProvider.register(e,t)},registerLinkedEditingRangeProvider:function(e,t){return Ha.get(mt.p).linkedEditingRangeProvider.register(e,t)},registerDefinitionProvider:function(e,t){return Ha.get(mt.p).definitionProvider.register(e,t)},registerImplementationProvider:function(e,t){return Ha.get(mt.p).implementationProvider.register(e,t)},registerTypeDefinitionProvider:function(e,t){return Ha.get(mt.p).typeDefinitionProvider.register(e,t)},registerCodeLensProvider:function(e,t){return Ha.get(mt.p).codeLensProvider.register(e,t)},registerCodeActionProvider:function(e,t,i){return Ha.get(mt.p).codeActionProvider.register(e,{providedCodeActionKinds:null==i?void 0:i.providedCodeActionKinds,provideCodeActions:(e,i,n,o)=>{const r=Ha.get(Zo.lT).read({resource:e.uri}).filter((e=>K.e.areIntersectingOrTouching(e,i)));return t.provideCodeActions(e,i,{markers:r,only:n.only},o)},resolveCodeAction:t.resolveCodeAction})},registerDocumentFormattingEditProvider:function(e,t){return Ha.get(mt.p).documentFormattingEditProvider.register(e,t)},registerDocumentRangeFormattingEditProvider:function(e,t){return Ha.get(mt.p).documentRangeFormattingEditProvider.register(e,t)},registerOnTypeFormattingEditProvider:function(e,t){return Ha.get(mt.p).onTypeFormattingEditProvider.register(e,t)},registerLinkProvider:function(e,t){return Ha.get(mt.p).linkProvider.register(e,t)},registerColorProvider:function(e,t){return Ha.get(mt.p).colorProvider.register(e,t)},registerFoldingRangeProvider:function(e,t){return Ha.get(mt.p).foldingRangeProvider.register(e,t)},registerDeclarationProvider:function(e,t){return Ha.get(mt.p).declarationProvider.register(e,t)},registerSelectionRangeProvider:function(e,t){return Ha.get(mt.p).selectionRangeProvider.register(e,t)},registerDocumentSemanticTokensProvider:function(e,t){return Ha.get(mt.p).documentSemanticTokensProvider.register(e,t)},registerDocumentRangeSemanticTokensProvider:function(e,t){return Ha.get(mt.p).documentRangeSemanticTokensProvider.register(e,t)},registerInlineCompletionsProvider:function(e,t){return Ha.get(mt.p).inlineCompletionsProvider.register(e,t)},registerInlayHintsProvider:function(e,t){return Ha.get(mt.p).inlayHintsProvider.register(e,t)},DocumentHighlightKind:u,CompletionItemKind:r,CompletionItemTag:s,CompletionItemInsertTextRule:o,SymbolKind:M,SymbolTag:O,IndentAction:f,CompletionTriggerKind:a,SignatureHelpTriggerKind:R,InlayHintKind:b,InlineCompletionTriggerKind:v,FoldingRangeKind:G.AD};const pl=hl.CancellationTokenSource,ml=hl.Emitter,fl=hl.KeyCode,_l=hl.KeyMod,bl=hl.Position,vl=hl.Range,Cl=hl.Selection,wl=hl.SelectionDirection,yl=hl.MarkerSeverity,Sl=hl.MarkerTag,xl=hl.Uri,kl=hl.Token,Ll=hl.editor,El=hl.languages;((null===(dl=ke.li.MonacoEnvironment)||void 0===dl?void 0:dl.globalAPI)||"function"==typeof define&&i.amdO)&&(self.monaco=hl),void 0!==self.require&&"function"==typeof self.require.config&&self.require.config({ignoreDuplicateModules:["vscode-languageserver-types","vscode-languageserver-types/main","vscode-languageserver-textdocument","vscode-languageserver-textdocument/main","vscode-nls","vscode-nls/vscode-nls","jsonc-parser","jsonc-parser/main","vscode-uri","vscode-uri/index","vs/basic-languages/typescript/typescript"]})},49982:function(e,t,i){"use strict";i.r(t),i.d(t,{CancellationTokenSource:function(){return n.CancellationTokenSource},Emitter:function(){return n.Emitter},KeyCode:function(){return n.KeyCode},KeyMod:function(){return n.KeyMod},MarkerSeverity:function(){return n.MarkerSeverity},MarkerTag:function(){return n.MarkerTag},Position:function(){return n.Position},Range:function(){return n.Range},Selection:function(){return n.Selection},SelectionDirection:function(){return n.SelectionDirection},Token:function(){return n.Token},Uri:function(){return n.Uri},__esModule:function(){return n.__esModule},editor:function(){return n.editor},languages:function(){return n.languages},version:function(){return n.version}});var n=i(54918);i(47729),i(24900),i(23434),i(63631),i(33475),i(93048),i(98184),i(3186),i(53651),i(34669),i(3654),i(63698),i(73151),i(80631),i(10944),i(25456),i(2395),i(4275),i(630),i(61089),i(80527),i(9243),i(64825),i(77322),i(62965),i(80571),i(89852),i(66424),i(93741),i(27174),i(68971),i(50612),i(21401),i(33903),i(20366),i(60301),i(21823),i(54201),i(5895),i(60107),i(86229),i(9086),i(24972),i(83105),i(79931),i(53828),i(7406),i(64026),i(33173),i(11138),i(61116),i(31961),i(43717),i(63074),i(99032),i(28897),i(45439),i(94184),i(48367),i(33464),i(4595),i(8592),i(49607),i(78027),i(45089),i(22900),i(6714),i(59305),i(51345),i(61797),i(86),i(35184),i(36945),i(59114),i(19396),i(77897),i(24311),i(31118),i(72080),i(45580),i(75797),i(47095),i(34239),i(43061),i(54552),i(77082),i(26421),i(90089),i(42336),i(63149),i(97807),i(42201),i(13257),i(57856),i(2769),i(80015),i(96593),i(90251),i(16244),i(48693),i(27239),i(81177),i(28859),i(82879),i(6718),i(15707),i(34944),i(7859),i(37089),i(63022),i(82105),i(68620),i(16486),i(70663),i(78053),i(99966),i(98483),i(32072),i(29820),i(1266),i(27710),i(13876),i(88942),i(60803),i(32547),i(40216),i(37184),i(65042),i(71414),i(6622),i(32210),i(17026),i(21094),i(71874),i(57402),i(88640),i(50717),i(5380),i(82597)},32210:function(e,t,i){"use strict";i.r(t);var n=i(93379),o=i.n(n),r=i(7795),s=i.n(r),a=i(90569),l=i.n(a),c=i(3565),d=i.n(c),u=i(19216),h=i.n(u),g=i(44589),p=i.n(g),m=i(20450),f={};f.styleTagTransform=p(),f.setAttributes=d(),f.insert=l().bind(null,"head"),f.domAPI=s(),f.insertStyleElement=h(),o()(m.Z,f),m.Z&&m.Z.locals&&m.Z.locals;var _=i(68695),b=i(17762),v=i(61604),C=i(77339),w=i(43479),y=i(4004),S=i(6954),x=i(18039),k=i(39675),L=i(4189),E=i(38673),N=i(13876),D=i(60393),I=i(12260),T=i(67517),A=i(82523),R=i(45164),M=i(81585),O=i(71414),P=function(e,t,i,n){var o,r=arguments.length,s=r<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,i):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(e,t,i,n);else for(var a=e.length-1;a>=0;a--)(o=e[a])&&(s=(r<3?o(s):r>3?o(t,i,s):o(t,i))||s);return r>3&&s&&Object.defineProperty(t,i,s),s},F=function(e,t){return function(i,n){t(i,n,e)}};const B=new D.uy("accessibilityHelpWidgetVisible",!1);let W=class e extends y.JT{constructor(e,t){super(),this._editor=e,this._widget=this._register(t.createInstance(V,this._editor))}static get(t){return t.getContribution(e.ID)}show(){this._widget.show()}hide(){this._widget.hide()}};W.ID="editor.contrib.accessibilityHelpController",W=P([F(1,I.TG)],W);let V=class e extends w.${constructor(e,t,i,n){super(),this._contextKeyService=t,this._keybindingService=i,this._openerService=n,this._editor=e,this._isVisibleKey=B.bindTo(this._contextKeyService),this._domNode=(0,b.X)(document.createElement("div")),this._domNode.setClassName("accessibilityHelpWidget"),this._domNode.setDisplay("none"),this._domNode.setAttribute("role","dialog"),this._domNode.setAttribute("aria-hidden","true"),this._contentDomNode=(0,b.X)(document.createElement("div")),this._contentDomNode.setAttribute("role","document"),this._domNode.appendChild(this._contentDomNode),this._isVisible=!1,this._register(this._editor.onDidLayoutChange((()=>{this._isVisible&&this._layout()}))),this._register(_.mu(this._contentDomNode.domNode,"keydown",(e=>{if(this._isVisible&&(e.equals(2083)&&((0,C.Z9)(O.Oe.emergencyConfOn),this._editor.updateOptions({accessibilitySupport:"on"}),_.PO(this._contentDomNode.domNode),this._buildContent(),this._contentDomNode.domNode.focus(),e.preventDefault(),e.stopPropagation()),e.equals(2086))){(0,C.Z9)(O.Oe.openingDocs);let t=this._editor.getRawOptions().accessibilityHelpUrl;void 0===t&&(t="https://go.microsoft.com/fwlink/?linkid=852450"),this._openerService.open(k.o.parse(t)),e.preventDefault(),e.stopPropagation()}}))),this.onblur(this._contentDomNode.domNode,(()=>{this.hide()})),this._editor.addOverlayWidget(this)}dispose(){this._editor.removeOverlayWidget(this),super.dispose()}getId(){return e.ID}getDomNode(){return this._domNode.domNode}getPosition(){return{preference:null}}show(){this._isVisible||(this._isVisible=!0,this._isVisibleKey.set(!0),this._layout(),this._domNode.setDisplay("block"),this._domNode.setAttribute("aria-hidden","false"),this._contentDomNode.domNode.tabIndex=0,this._buildContent(),this._contentDomNode.domNode.focus())}_descriptionForCommand(e,t,i){const n=this._keybindingService.lookupKeybinding(e);return n?x.WU(t,n.getAriaLabel()):x.WU(i,e)}_buildContent(){const e=this._editor.getOptions(),t=this._editor.getSelections();let i=0;if(t){const e=this._editor.getModel();e&&t.forEach((t=>{i+=e.getValueLengthInRange(t)}))}let n=function(e,t){return e&&0!==e.length?1===e.length?t?x.WU(O.Oe.singleSelectionRange,e[0].positionLineNumber,e[0].positionColumn,t):x.WU(O.Oe.singleSelection,e[0].positionLineNumber,e[0].positionColumn):t?x.WU(O.Oe.multiSelectionRange,e.length,t):e.length>0?x.WU(O.Oe.multiSelection,e.length):"":O.Oe.noSelection}(t,i);e.get(54)?e.get(81)?n+=O.Oe.readonlyDiffEditor:n+=O.Oe.editableDiffEditor:e.get(81)?n+=O.Oe.readonlyEditor:n+=O.Oe.editableEditor;const o=S.dz?O.Oe.changeConfigToOnMac:O.Oe.changeConfigToOnWinLinux;switch(e.get(2)){case 0:n+="\n\n - "+o;break;case 2:n+="\n\n - "+O.Oe.auto_on;break;case 1:n+="\n\n - "+O.Oe.auto_off,n+=" "+o}e.get(130)?n+="\n\n - "+this._descriptionForCommand(N.ToggleTabFocusModeAction.ID,O.Oe.tabFocusModeOnMsg,O.Oe.tabFocusModeOnMsgNoKb):n+="\n\n - "+this._descriptionForCommand(N.ToggleTabFocusModeAction.ID,O.Oe.tabFocusModeOffMsg,O.Oe.tabFocusModeOffMsgNoKb),n+="\n\n - "+(S.dz?O.Oe.openDocMac:O.Oe.openDocWinLinux),n+="\n\n"+O.Oe.outroMsg,this._contentDomNode.domNode.appendChild((0,v.BO)(n)),this._contentDomNode.domNode.setAttribute("aria-label",n)}hide(){this._isVisible&&(this._isVisible=!1,this._isVisibleKey.reset(),this._domNode.setDisplay("none"),this._domNode.setAttribute("aria-hidden","true"),this._contentDomNode.domNode.tabIndex=-1,_.PO(this._contentDomNode.domNode),this._editor.focus())}_layout(){const t=this._editor.getLayoutInfo(),i=Math.max(5,Math.min(e.WIDTH,t.width-40)),n=Math.max(5,Math.min(e.HEIGHT,t.height-40));this._domNode.setWidth(i),this._domNode.setHeight(n);const o=Math.round((t.height-n)/2);this._domNode.setTop(o);const r=Math.round((t.width-i)/2);this._domNode.setLeft(r)}};V.ID="editor.contrib.accessibilityHelpWidget",V.WIDTH=500,V.HEIGHT=300,V=P([F(1,D.i6),F(2,T.d),F(3,A.v4)],V);class H extends L.R6{constructor(){super({id:"editor.action.showAccessibilityHelp",label:O.Oe.showAccessibilityHelpAction,alias:"Show Accessibility Help",precondition:void 0,kbOpts:{primary:571,weight:100,linux:{primary:1595,secondary:[571]}}})}run(e,t){const i=W.get(t);i&&i.show()}}(0,L._K)(W.ID,W),(0,L.Qr)(H);const z=L._l.bindToContribution(W.get);(0,L.fK)(new z({id:"closeAccessibilityHelp",precondition:B,handler:e=>e.hide(),kbOpts:{weight:200,kbExpr:E.u.focus,primary:9,secondary:[1033]}})),(0,M.Ic)(((e,t)=>{const i=e.getColor(R.D0T);i&&t.addRule(`.monaco-editor .accessibilityHelpWidget { background-color: ${i}; }`);const n=e.getColor(R.Hfx);n&&t.addRule(`.monaco-editor .accessibilityHelpWidget { color: ${n}; }`);const o=e.getColor(R.rh);o&&t.addRule(`.monaco-editor .accessibilityHelpWidget { box-shadow: 0 2px 8px ${o}; }`);const r=e.getColor(R.lRK);r&&t.addRule(`.monaco-editor .accessibilityHelpWidget { border: 2px solid ${r}; }`)}))},17026:function(e,t,i){"use strict";i.r(t),i.d(t,{IPadShowKeyboard:function(){return w}});var n=i(93379),o=i.n(n),r=i(7795),s=i.n(r),a=i(90569),l=i.n(a),c=i(3565),d=i.n(c),u=i(19216),h=i.n(u),g=i(44589),p=i.n(g),m=i(8986),f={};f.styleTagTransform=p(),f.setAttributes=d(),f.insert=l().bind(null,"head"),f.domAPI=s(),f.insertStyleElement=h(),o()(m.Z,f),m.Z&&m.Z.locals&&m.Z.locals;var _=i(68695),b=i(4004),v=i(4189),C=i(6954);class w extends b.JT{constructor(e){super(),this.editor=e,this.widget=null,C.gn&&(this._register(e.onDidChangeConfiguration((()=>this.update()))),this.update())}update(){const e=!this.editor.getOption(81);!this.widget&&e?this.widget=new y(this.editor):this.widget&&!e&&(this.widget.dispose(),this.widget=null)}dispose(){super.dispose(),this.widget&&(this.widget.dispose(),this.widget=null)}}w.ID="editor.contrib.iPadShowKeyboard";class y extends b.JT{constructor(e){super(),this.editor=e,this._domNode=document.createElement("textarea"),this._domNode.className="iPadShowKeyboard",this._register(_.nm(this._domNode,"touchstart",(e=>{this.editor.focus()}))),this._register(_.nm(this._domNode,"focus",(e=>{this.editor.focus()}))),this.editor.addOverlayWidget(this)}dispose(){this.editor.removeOverlayWidget(this),super.dispose()}getId(){return y.ID}getDomNode(){return this._domNode}getPosition(){return{preference:1}}}y.ID="editor.contrib.ShowKeyboardWidget",(0,v._K)(w.ID,w)},21094:function(e,t,i){"use strict";i.r(t);var n=i(93379),o=i.n(n),r=i(7795),s=i.n(r),a=i(90569),l=i.n(a),c=i(3565),d=i.n(c),u=i(19216),h=i.n(u),g=i(44589),p=i.n(g),m=i(2885),f={};f.styleTagTransform=p(),f.setAttributes=d(),f.insert=l().bind(null,"head"),f.domAPI=s(),f.insertStyleElement=h(),o()(m.Z,f),m.Z&&m.Z.locals&&m.Z.locals;var _=i(68695),b=i(18689),v=i(4004),C=i(4189),w=i(74893),y=i(14704),S=i(10940),x=i(52093),k=i(45164),L=i(81585),E=i(71414),N=i(14540),D=function(e,t){return function(i,n){t(i,n,e)}};let I=class e extends v.JT{constructor(e,t,i){super(),this._editor=e,this._languageService=i,this._widget=null,this._register(this._editor.onDidChangeModel((e=>this.stop()))),this._register(this._editor.onDidChangeModelLanguage((e=>this.stop()))),this._register(w.RW.onDidChange((e=>this.stop()))),this._register(this._editor.onKeyUp((e=>9===e.keyCode&&this.stop())))}static get(t){return t.getContribution(e.ID)}dispose(){this.stop(),super.dispose()}launch(){this._widget||this._editor.hasModel()&&(this._widget=new A(this._editor,this._languageService))}stop(){this._widget&&(this._widget.dispose(),this._widget=null)}};I.ID="editor.contrib.inspectTokens",I=function(e,t,i,n){var o,r=arguments.length,s=r<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,i):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(e,t,i,n);else for(var a=e.length-1;a>=0;a--)(o=e[a])&&(s=(r<3?o(s):r>3?o(t,i,s):o(t,i))||s);return r>3&&s&&Object.defineProperty(t,i,s),s}([D(1,x.Z),D(2,S.O)],I);class T extends C.R6{constructor(){super({id:"editor.action.inspectTokens",label:E.ug.inspectTokensAction,alias:"Developer: Inspect Tokens",precondition:void 0})}run(e,t){const i=I.get(t);i&&i.launch()}}class A extends v.JT{constructor(e,t){super(),this.allowEditorOverflow=!0,this._editor=e,this._languageService=t,this._model=this._editor.getModel(),this._domNode=document.createElement("div"),this._domNode.className="tokens-inspect-widget",this._tokenizationSupport=function(e,t){const i=w.RW.get(t);if(i)return i;const n=e.encodeLanguageId(t);return{getInitialState:()=>y.TJ,tokenize:(e,i,n)=>(0,y.Ri)(t,n),tokenizeEncoded:(e,t,i)=>(0,y.Dy)(n,i)}}(this._languageService.languageIdCodec,this._model.getLanguageId()),this._compute(this._editor.getPosition()),this._register(this._editor.onDidChangeCursorPosition((e=>this._compute(this._editor.getPosition())))),this._editor.addContentWidget(this)}dispose(){this._editor.removeContentWidget(this),super.dispose()}getId(){return A._ID}_compute(e){const t=this._getTokensAtLine(e.lineNumber);let i=0;for(let n=t.tokens1.length-1;n>=0;n--){const o=t.tokens1[n];if(e.column-1>=o.offset){i=n;break}}let n=0;for(let i=t.tokens2.length>>>1;i>=0;i--)if(e.column-1>=t.tokens2[i<<1]){n=i;break}const o=this._model.getLineContent(e.lineNumber);let r="";if(i{const i=e.getColor(k.CNo);if(i){const n=e.type===N.e.HIGH_CONTRAST?2:1;t.addRule(`.monaco-editor .tokens-inspect-widget { border: ${n}px solid ${i}; }`),t.addRule(`.monaco-editor .tokens-inspect-widget .tokens-inspect-separator { background-color: ${i}; }`)}const n=e.getColor(k.yJx);n&&t.addRule(`.monaco-editor .tokens-inspect-widget { background-color: ${n}; }`);const o=e.getColor(k.Sbf);o&&t.addRule(`.monaco-editor .tokens-inspect-widget { color: ${o}; }`)}))},50717:function(e,t,i){"use strict";i.r(t),i.d(t,{GotoLineAction:function(){return U},StandaloneCommandsQuickAccessProvider:function(){return $}});var n=i(73403),o=i(34073),r=i(71414),s=i(3622),a=i(14329),l=i(57800),c=i(28295),d=i(89982);function u(e,t){return t&&(e.stack||e.stacktrace)?d.NC("vs/base/common/errorMessage","stackTrace.format","{0}: {1}",g(e),h(e.stack)||h(e.stacktrace)):g(e)}function h(e){return Array.isArray(e)?e.join("\n"):e}function g(e){return"string"==typeof e.code&&"number"==typeof e.errno&&"string"==typeof e.syscall?d.NC("vs/base/common/errorMessage","nodeExceptionMessage","A system error occurred ({0})",e.message):e.message||d.NC("vs/base/common/errorMessage","error.defaultMessage","An unknown error occurred. Please consult the log for more details.")}function p(e=null,t=!1){if(!e)return d.NC("vs/base/common/errorMessage","error.defaultMessage","An unknown error occurred. Please consult the log for more details.");if(Array.isArray(e)){const i=l.kX(e),n=p(i[0],t);return i.length>1?d.NC("vs/base/common/errorMessage","error.moreErrors","{0} ({1} errors in total)",n,i.length):n}if(c.HD(e))return e;if(e.detail){const i=e.detail;if(i.error)return u(i.error,t);if(i.exception)return u(i.exception,t)}return e.stack?u(e,t):e.message?e.message:d.NC("vs/base/common/errorMessage","error.defaultMessage","An unknown error occurred. Please consult the log for more details.")}var m,f=i(16182),_=i(34604),b=i(4004),v=i(38455),C=i(81234),w=i(14756),y=i(40539),S=i(34243),x=i(12260),k=i(67517),L=i(40027),E=i(60677),N=function(e,t,i,n){return new(i||(i=Promise))((function(o,r){function s(e){try{l(n.next(e))}catch(e){r(e)}}function a(e){try{l(n.throw(e))}catch(e){r(e)}}function l(e){var t;e.done?o(e.value):(t=e.value,t instanceof i?t:new i((function(e){e(t)}))).then(s,a)}l((n=n.apply(e,t||[])).next())}))};function D(e){const t=e;return Array.isArray(t.items)}!function(e){e[e.NO_ACTION=0]="NO_ACTION",e[e.CLOSE_PICKER=1]="CLOSE_PICKER",e[e.REFRESH_PICKER=2]="REFRESH_PICKER",e[e.REMOVE_ITEM=3]="REMOVE_ITEM"}(m||(m={}));class I extends b.JT{constructor(e,t){super(),this.prefix=e,this.options=t}provide(e,t){var i;const n=new b.SL;let o;e.canAcceptInBackground=!!(null===(i=this.options)||void 0===i?void 0:i.canAcceptInBackground),e.matchOnLabel=e.matchOnDescription=e.matchOnDetail=e.sortByLabel=!1;const r=n.add(new b.XK),s=()=>N(this,void 0,void 0,(function*(){const i=r.value=new b.SL;null==o||o.dispose(!0),e.busy=!1,o=new E.A(t);const n=o.token,s=e.value.substr(this.prefix.length).trim(),a=this._getPicks(s,i,n),l=(t,i)=>{var n;let o,r;if(D(t)?(o=t.items,r=t.active):o=t,0===o.length){if(i)return!1;s.length>0&&(null===(n=this.options)||void 0===n?void 0:n.noResultsPick)&&(o=[this.options.noResultsPick])}return e.items=o,r&&(e.activeItems=[r]),!0};if(null===a);else if(function(e){const t=e;return!!t.picks&&t.additionalPicks instanceof Promise}(a)){let t=!1,i=!1;yield Promise.all([(()=>N(this,void 0,void 0,(function*(){yield(0,L.Vs)(I.FAST_PICKS_RACE_DELAY),n.isCancellationRequested||i||(t=l(a.picks,!0))})))(),(()=>N(this,void 0,void 0,(function*(){e.busy=!0;try{const o=yield a.additionalPicks;if(n.isCancellationRequested)return;let r,s,c,d;if(D(a.picks)?(r=a.picks.items,s=a.picks.active):r=a.picks,D(o)?(c=o.items,d=o.active):c=o,c.length>0||!t){let t;if(!s&&!d){const i=e.activeItems[0];i&&-1!==r.indexOf(i)&&(t=i)}l({items:[...r,...c],active:s||d||t})}}finally{n.isCancellationRequested||(e.busy=!1),i=!0}})))()])}else if(a instanceof Promise){e.busy=!0;try{const t=yield a;if(n.isCancellationRequested)return;l(t)}finally{n.isCancellationRequested||(e.busy=!1)}}else l(a)}));return n.add(e.onDidChangeValue((()=>s()))),s(),n.add(e.onDidAccept((t=>{const[i]=e.selectedItems;"function"==typeof(null==i?void 0:i.accept)&&(t.inBackground||e.hide(),i.accept(e.keyMods,t))}))),n.add(e.onDidTriggerItemButton((({button:i,item:n})=>N(this,void 0,void 0,(function*(){var o,r;if("function"==typeof n.trigger){const a=null!==(r=null===(o=n.buttons)||void 0===o?void 0:o.indexOf(i))&&void 0!==r?r:-1;if(a>=0){const i=n.trigger(a,e.keyMods),o="number"==typeof i?i:yield i;if(t.isCancellationRequested)return;switch(o){case m.NO_ACTION:break;case m.CLOSE_PICKER:e.hide();break;case m.REFRESH_PICKER:s();break;case m.REMOVE_ITEM:{const t=e.items.indexOf(n);if(-1!==t){const i=e.items.slice(),n=i.splice(t,1),o=e.activeItems.filter((e=>e!==n[0])),r=e.keepScrollPosition;e.keepScrollPosition=!0,e.items=i,o&&(e.activeItems=o),e.keepScrollPosition=r}break}}}}}))))),n}}I.FAST_PICKS_RACE_DELAY=200;var T=i(86303),A=i(56080),R=function(e,t,i,n){var o,r=arguments.length,s=r<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,i):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(e,t,i,n);else for(var a=e.length-1;a>=0;a--)(o=e[a])&&(s=(r<3?o(s):r>3?o(t,i,s):o(t,i))||s);return r>3&&s&&Object.defineProperty(t,i,s),s},M=function(e,t){return function(i,n){t(i,n,e)}},O=function(e,t,i,n){return new(i||(i=Promise))((function(o,r){function s(e){try{l(n.next(e))}catch(e){r(e)}}function a(e){try{l(n.throw(e))}catch(e){r(e)}}function l(e){var t;e.done?o(e.value):(t=e.value,t instanceof i?t:new i((function(e){e(t)}))).then(s,a)}l((n=n.apply(e,t||[])).next())}))};let P=class e extends I{constructor(t,i,n,o,r,s){super(e.PREFIX,t),this.instantiationService=i,this.keybindingService=n,this.commandService=o,this.telemetryService=r,this.dialogService=s,this.commandsHistory=this._register(this.instantiationService.createInstance(F)),this.options=t}_getPicks(t,i,n){return O(this,void 0,void 0,(function*(){const o=yield this.getCommandPicks(i,n);if(n.isCancellationRequested)return[];const r=[];for(const i of o){const n=(0,c.f6)(e.WORD_FILTER(t,i.label)),o=i.commandAlias?(0,c.f6)(e.WORD_FILTER(t,i.commandAlias)):void 0;n||o?(i.highlights={label:n,detail:this.options.showAlias?o:void 0},r.push(i)):t===i.commandId&&r.push(i)}const s=new Map;for(const e of r){const t=s.get(e.label);t?(e.description=e.commandId,t.description=t.commandId):s.set(e.label,e)}r.sort(((e,t)=>{const i=this.commandsHistory.peek(e.commandId),n=this.commandsHistory.peek(t.commandId);return i&&n?i>n?-1:1:i?-1:n?1:e.label.localeCompare(t.label)}));const a=[];let l=!1;for(let e=0;eO(this,void 0,void 0,(function*(){this.commandsHistory.push(t.commandId),this.telemetryService.publicLog2("workbenchActionExecuted",{id:t.commandId,from:"quick open"});try{yield this.commandService.executeCommand(t.commandId)}catch(e){(0,f.n2)(e)||this.dialogService.show(C.Z.Error,(0,d.NC)("vs/platform/quickinput/browser/commandsQuickAccess","canNotRun","Command '{0}' resulted in an error ({1})",t.label,p(e)))}}))}))}return a}))}};P.PREFIX=">",P.WORD_FILTER=(0,_.or)(_.Ji,_.KZ,_.ir),P=R([M(1,x.TG),M(2,k.d),M(3,w.Hy),M(4,A.b),M(5,S.S)],P);let F=class e extends b.JT{constructor(e,t){super(),this.storageService=e,this.configurationService=t,this.configuredCommandsHistoryLength=0,this.updateConfiguration(),this.load(),this.registerListeners()}registerListeners(){this._register(this.configurationService.onDidChangeConfiguration((()=>this.updateConfiguration())))}updateConfiguration(){this.configuredCommandsHistoryLength=e.getConfiguredCommandHistoryLength(this.configurationService),e.cache&&e.cache.limit!==this.configuredCommandsHistoryLength&&(e.cache.limit=this.configuredCommandsHistoryLength,e.saveState(this.storageService))}load(){const t=this.storageService.get(e.PREF_KEY_CACHE,0);let i;if(t)try{i=JSON.parse(t)}catch(e){}const n=e.cache=new v.z6(this.configuredCommandsHistoryLength,1);if(i){let e;e=i.usesLRU?i.entries:i.entries.sort(((e,t)=>e.value-t.value)),e.forEach((e=>n.set(e.key,e.value)))}e.counter=this.storageService.getNumber(e.PREF_KEY_COUNTER,0,e.counter)}push(t){e.cache&&(e.cache.set(t,e.counter++),e.saveState(this.storageService))}peek(t){var i;return null===(i=e.cache)||void 0===i?void 0:i.peek(t)}static saveState(t){if(!e.cache)return;const i={usesLRU:!0,entries:[]};e.cache.forEach(((e,t)=>i.entries.push({key:t,value:e}))),t.store(e.PREF_KEY_CACHE,JSON.stringify(i),0,0),t.store(e.PREF_KEY_COUNTER,e.counter,0,0)}static getConfiguredCommandHistoryLength(t){var i,n;const o=null===(n=null===(i=t.getValue().workbench)||void 0===i?void 0:i.commandPalette)||void 0===n?void 0:n.history;return"number"==typeof o?o:e.DEFAULT_COMMANDS_HISTORY_LENGTH}};F.DEFAULT_COMMANDS_HISTORY_LENGTH=50,F.PREF_KEY_CACHE="commandPalette.mru.cache",F.PREF_KEY_COUNTER="commandPalette.mru.counter",F.counter=1,F=R([M(0,T.Uy),M(1,y.Ui)],F);class B extends P{constructor(e,t,i,n,o,r){super(e,t,i,n,o,r)}getCodeEditorCommandPicks(){const e=this.activeTextEditorControl;if(!e)return[];const t=[];for(const i of e.getSupportedActions())t.push({commandId:i.id,commandAlias:i.alias,label:(0,a.x$)(i.label)||i.id});return t}}var W=i(4189),V=i(38673),H=i(22447),z=function(e,t){return function(i,n){t(i,n,e)}};let $=class extends B{constructor(e,t,i,n,o,r){super({showAlias:!1},e,i,n,o,r),this.codeEditorService=t}get activeTextEditorControl(){return(0,c.f6)(this.codeEditorService.getFocusedCodeEditor())}getCommandPicks(){return e=this,t=void 0,n=function*(){return this.getCodeEditorCommandPicks()},new((i=void 0)||(i=Promise))((function(o,r){function s(e){try{l(n.next(e))}catch(e){r(e)}}function a(e){try{l(n.throw(e))}catch(e){r(e)}}function l(e){var t;e.done?o(e.value):(t=e.value,t instanceof i?t:new i((function(e){e(t)}))).then(s,a)}l((n=n.apply(e,t||[])).next())}));var e,t,i,n}};$=function(e,t,i,n){var o,r=arguments.length,s=r<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,i):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(e,t,i,n);else for(var a=e.length-1;a>=0;a--)(o=e[a])&&(s=(r<3?o(s):r>3?o(t,i,s):o(t,i))||s);return r>3&&s&&Object.defineProperty(t,i,s),s}([z(0,x.TG),z(1,s.$),z(2,k.d),z(3,w.Hy),z(4,A.b),z(5,S.S)],$),n.B.as(o.IP.Quickaccess).registerQuickAccessProvider({ctor:$,prefix:$.PREFIX,helpEntries:[{description:r.UX.quickCommandHelp,needsEditor:!0}]});class U extends W.R6{constructor(){super({id:"editor.action.quickCommand",label:r.UX.quickCommandActionLabel,alias:"Command Palette",precondition:void 0,kbOpts:{kbExpr:V.u.focus,primary:59,weight:100},contextMenuOpts:{group:"z_commands",order:1}})}run(e){e.get(H.eJ).quickAccess.show($.PREFIX)}}(0,W.Qr)(U)},57402:function(e,t,i){"use strict";i.r(t),i.d(t,{GotoLineAction:function(){return C},StandaloneGotoLineQuickAccessProvider:function(){return _}});var n=i(4004),o=i(28281),r=i(10600),s=i(89982);class a extends r.X{constructor(){super({canAcceptInBackground:!0})}provideWithoutTextEditor(e){const t=(0,s.NC)("vs/editor/contrib/quickAccess/browser/gotoLineQuickAccess","cannotRunGotoLine","Open a text editor first to go to a line.");return e.items=[{label:t}],e.ariaLabel=t,n.JT.None}provideWithTextEditor(e,t,i){const r=e.editor,s=new n.SL;s.add(t.onDidAccept((i=>{const[n]=t.selectedItems;if(n){if(!this.isValidLineNumber(r,n.lineNumber))return;this.gotoLocation(e,{range:this.toRange(n.lineNumber,n.column),keyMods:t.keyMods,preserveFocus:i.inBackground}),i.inBackground||t.hide()}})));const l=()=>{const e=this.parsePosition(r,t.value.trim().substr(a.PREFIX.length)),i=this.getPickLabel(r,e.lineNumber,e.column);if(t.items=[{lineNumber:e.lineNumber,column:e.column,label:i}],t.ariaLabel=i,!this.isValidLineNumber(r,e.lineNumber))return void this.clearDecorations(r);const n=this.toRange(e.lineNumber,e.column);r.revealRangeInCenter(n,0),this.addDecorations(r,n)};l(),s.add(t.onDidChangeValue((()=>l())));const c=(0,o.Pi)(r);return c&&2===c.getOptions().get(60).renderType&&(c.updateOptions({lineNumbers:"on"}),s.add((0,n.OF)((()=>c.updateOptions({lineNumbers:"relative"}))))),s}toRange(e=1,t=1){return{startLineNumber:e,startColumn:t,endLineNumber:e,endColumn:t}}parsePosition(e,t){const i=t.split(/,|:|#/).map((e=>parseInt(e,10))).filter((e=>!isNaN(e))),n=this.lineCount(e)+1;return{lineNumber:i[0]>0?i[0]:n+i[0],column:i[1]}}getPickLabel(e,t,i){if(this.isValidLineNumber(e,t))return this.isValidColumn(e,t,i)?(0,s.NC)("vs/editor/contrib/quickAccess/browser/gotoLineQuickAccess","gotoLineColumnLabel","Go to line {0} and character {1}.",t,i):(0,s.NC)("vs/editor/contrib/quickAccess/browser/gotoLineQuickAccess","gotoLineLabel","Go to line {0}.",t);const n=e.getPosition()||{lineNumber:1,column:1},o=this.lineCount(e);return o>1?(0,s.NC)("vs/editor/contrib/quickAccess/browser/gotoLineQuickAccess","gotoLineLabelEmptyWithLimit","Current Line: {0}, Character: {1}. Type a line number between 1 and {2} to navigate to.",n.lineNumber,n.column,o):(0,s.NC)("vs/editor/contrib/quickAccess/browser/gotoLineQuickAccess","gotoLineLabelEmpty","Current Line: {0}, Character: {1}. Type a line number to navigate to.",n.lineNumber,n.column)}isValidLineNumber(e,t){return!(!t||"number"!=typeof t)&&t>0&&t<=this.lineCount(e)}isValidColumn(e,t,i){if(!i||"number"!=typeof i)return!1;const n=this.getModel(e);if(!n)return!1;const o={lineNumber:t,column:i};return n.validatePosition(o).equals(o)}lineCount(e){var t,i;return null!==(i=null===(t=this.getModel(e))||void 0===t?void 0:t.getLineCount())&&void 0!==i?i:0}}a.PREFIX=":";var l=i(73403),c=i(34073),d=i(3622),u=i(28295),h=i(71414),g=i(46718),p=i(4189),m=i(38673),f=i(22447);let _=class extends a{constructor(e){super(),this.editorService=e,this.onDidActiveTextEditorControlChange=g.ju.None}get activeTextEditorControl(){return(0,u.f6)(this.editorService.getFocusedCodeEditor())}};var b,v;_=function(e,t,i,n){var o,r=arguments.length,s=r<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,i):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(e,t,i,n);else for(var a=e.length-1;a>=0;a--)(o=e[a])&&(s=(r<3?o(s):r>3?o(t,i,s):o(t,i))||s);return r>3&&s&&Object.defineProperty(t,i,s),s}([(b=0,v=d.$,function(e,t){v(e,t,b)})],_),l.B.as(c.IP.Quickaccess).registerQuickAccessProvider({ctor:_,prefix:_.PREFIX,helpEntries:[{description:h.qq.gotoLineActionLabel,needsEditor:!0}]});class C extends p.R6{constructor(){super({id:"editor.action.gotoLine",label:h.qq.gotoLineActionLabel,alias:"Go to Line/Column...",precondition:void 0,kbOpts:{kbExpr:m.u.focus,primary:2085,mac:{primary:293},weight:100}})}run(e){e.get(f.eJ).quickAccess.show(_.PREFIX)}}(0,p.Qr)(C)},88640:function(e,t,i){"use strict";i.r(t),i.d(t,{GotoLineAction:function(){return H},StandaloneGotoSymbolQuickAccessProvider:function(){return V}}),i(6622),i(31300);var n=i(40027),o=i(60677),r=i(4821),s=i(34604),a=i(14477),l=i(6954),c=i(18039);const d=[void 0,[]];function u(e,t,i=0,n=0){const o=t;return o.values&&o.values.length>1?function(e,t,i,n){let o=0;const r=[];for(const s of t){const[t,a]=h(e,s,i,n);if("number"!=typeof t)return d;o+=t,r.push(...a)}return[o,g(r)]}(e,o.values,i,n):h(e,t,i,n)}function h(e,t,i,n){const o=(0,s.EW)(t.original,t.originalLowercase,i,e,e.toLowerCase(),n,!0);return o?[o[0],(0,s.mB)(o)]:d}function g(e){const t=e.sort(((e,t)=>e.start-t.start)),i=[];let n;for(const e of t)!n||(r=e,(o=n).end=0,s=p(e);let l;const c=e.split(" ");if(c.length>1)for(const e of c){const t=p(e),{pathNormalized:i,normalized:n,normalizedLowercase:o}=f(e);n&&(l||(l=[]),l.push({original:e,originalLowercase:e.toLowerCase(),pathNormalized:i,normalized:n,normalizedLowercase:o,expectContiguousMatch:t}))}return{original:e,originalLowercase:t,pathNormalized:i,normalized:n,normalizedLowercase:o,values:l,containsPathSeparator:r,expectContiguousMatch:s}}function f(e){let t;t=l.ED?e.replace(/\//g,a.ir):e.replace(/\\/g,a.ir);const i=(0,c.R1)(t).replace(/\s|"/g,"");return{pathNormalized:t,normalized:i,normalizedLowercase:i.toLowerCase()}}function _(e){return Array.isArray(e)?m(e.map((e=>e.original)).join(" ")):m(e.original)}Object.freeze({score:0});var b=i(4004),v=i(11465),C=i(74893),w=i(31971),y=i(10600),S=i(89982),x=i(66988),k=function(e,t){return function(i,n){t(i,n,e)}},L=function(e,t,i,n){return new(i||(i=Promise))((function(o,r){function s(e){try{l(n.next(e))}catch(e){r(e)}}function a(e){try{l(n.throw(e))}catch(e){r(e)}}function l(e){var t;e.done?o(e.value):(t=e.value,t instanceof i?t:new i((function(e){e(t)}))).then(s,a)}l((n=n.apply(e,t||[])).next())}))};let E=class e extends y.X{constructor(e,t,i=Object.create(null)){super(i),this._languageFeaturesService=e,this._outlineModelService=t,this.options=i,this.options.canAcceptInBackground=!0}provideWithoutTextEditor(e){return this.provideLabelPick(e,(0,S.NC)("vs/editor/contrib/quickAccess/browser/gotoSymbolQuickAccess","cannotRunGotoSymbolWithoutEditor","To go to a symbol, first open a text editor with symbol information.")),b.JT.None}provideWithTextEditor(e,t,i){const n=e.editor,o=this.getModel(n);return o?this._languageFeaturesService.documentSymbolProvider.has(o)?this.doProvideWithEditorSymbols(e,o,t,i):this.doProvideWithoutEditorSymbols(e,o,t,i):b.JT.None}doProvideWithoutEditorSymbols(e,t,i,n){const o=new b.SL;return this.provideLabelPick(i,(0,S.NC)("vs/editor/contrib/quickAccess/browser/gotoSymbolQuickAccess","cannotRunGotoSymbolWithoutSymbolProvider","The active text editor does not provide symbol information.")),(()=>{L(this,void 0,void 0,(function*(){(yield this.waitForLanguageSymbolRegistry(t,o))&&!n.isCancellationRequested&&o.add(this.doProvideWithEditorSymbols(e,t,i,n))}))})(),o}provideLabelPick(e,t){e.items=[{label:t,index:0,kind:14}],e.ariaLabel=t}waitForLanguageSymbolRegistry(e,t){return L(this,void 0,void 0,(function*(){if(this._languageFeaturesService.documentSymbolProvider.has(e))return!0;const i=new n.CR,o=t.add(this._languageFeaturesService.documentSymbolProvider.onDidChange((()=>{this._languageFeaturesService.documentSymbolProvider.has(e)&&(o.dispose(),i.complete(!0))})));return t.add((0,b.OF)((()=>i.complete(!1)))),i.p}))}doProvideWithEditorSymbols(t,i,n,r){const s=t.editor,a=new b.SL;a.add(n.onDidAccept((e=>{const[i]=n.selectedItems;i&&i.range&&(this.gotoLocation(t,{range:i.range.selection,keyMods:n.keyMods,preserveFocus:e.inBackground}),e.inBackground||n.hide())}))),a.add(n.onDidTriggerItemButton((({item:e})=>{e&&e.range&&(this.gotoLocation(t,{range:e.range.selection,keyMods:n.keyMods,forceSideBySide:!0}),n.hide())})));const l=this.getDocumentSymbols(i,r);let c;const d=()=>L(this,void 0,void 0,(function*(){null==c||c.dispose(!0),n.busy=!1,c=new o.A(r),n.busy=!0;try{const t=m(n.value.substr(e.PREFIX.length).trim()),i=yield this.doGetSymbolPicks(l,t,void 0,c.token);if(r.isCancellationRequested)return;i.length>0?n.items=i:t.original.length>0?this.provideLabelPick(n,(0,S.NC)("vs/editor/contrib/quickAccess/browser/gotoSymbolQuickAccess","noMatchingSymbolResults","No matching editor symbols")):this.provideLabelPick(n,(0,S.NC)("vs/editor/contrib/quickAccess/browser/gotoSymbolQuickAccess","noSymbolResults","No editor symbols"))}finally{r.isCancellationRequested||(n.busy=!1)}}));a.add(n.onDidChangeValue((()=>d()))),d();let u=!0;return a.add(n.onDidChangeActive((()=>{const[e]=n.activeItems;if(e&&e.range){if(u)return void(u=!1);s.revealRangeInCenter(e.range.selection,0),this.addDecorations(s,e.range.decoration)}}))),a}doGetSymbolPicks(t,i,n,o){return L(this,void 0,void 0,(function*(){const s=yield t;if(o.isCancellationRequested)return[];const a=0===i.original.indexOf(e.SCOPE_PREFIX),l=a?1:0;let d,h;i.values&&i.values.length>1?(d=_(i.values[0]),h=_(i.values.slice(1))):d=i;const g=[];for(let f=0;fl){let R=!1;if(d!==i&&([k,L]=u(y,Object.assign(Object.assign({},i),{values:void 0}),l,x),"number"==typeof k&&(R=!0)),"number"!=typeof k&&([k,L]=u(y,d,l,x),"number"!=typeof k))continue;if(!R&&h){if(T&&h.original.length>0&&([E,I]=u(T,h)),"number"!=typeof E)continue;"number"==typeof k&&(k+=E)}}const A=b.tags&&b.tags.indexOf(1)>=0;g.push({index:f,kind:b.kind,score:k,label:y,ariaLabel:w,description:T,highlights:A?void 0:{label:L,description:I},range:{selection:v.e.collapseToStart(b.selectionRange),decoration:b.range},strikethrough:A,buttons:(()=>{var e,t;const i=(null===(e=this.options)||void 0===e?void 0:e.openSideBySideDirection)?null===(t=this.options)||void 0===t?void 0:t.openSideBySideDirection():void 0;if(i)return[{iconClass:"right"===i?r.lA.splitHorizontal.classNames:r.lA.splitVertical.classNames,tooltip:"right"===i?(0,S.NC)("vs/editor/contrib/quickAccess/browser/gotoSymbolQuickAccess","openToSide","Open to the Side"):(0,S.NC)("vs/editor/contrib/quickAccess/browser/gotoSymbolQuickAccess","openToBottom","Open to the Bottom")}]})()})}const p=g.sort(((e,t)=>a?this.compareByKindAndScore(e,t):this.compareByScore(e,t)));let m=[];if(a){let M,O,P=0;function F(){O&&"number"==typeof M&&P>0&&(O.label=(0,c.WU)(D[M]||N,P))}for(const B of p)M!==B.kind?(F(),M=B.kind,P=1,O={type:"separator"},m.push(O)):P++,m.push(B);F()}else p.length>0&&(m=[{label:(0,S.NC)("vs/editor/contrib/quickAccess/browser/gotoSymbolQuickAccess","symbols","symbols ({0})",g.length),type:"separator"},...p]);return m}))}compareByScore(e,t){if("number"!=typeof e.score&&"number"==typeof t.score)return 1;if("number"==typeof e.score&&"number"!=typeof t.score)return-1;if("number"==typeof e.score&&"number"==typeof t.score){if(e.score>t.score)return-1;if(e.scoret.index?1:0}compareByKindAndScore(e,t){const i=D[e.kind]||N,n=D[t.kind]||N,o=i.localeCompare(n);return 0===o?this.compareByScore(e,t):o}getDocumentSymbols(e,t){return L(this,void 0,void 0,(function*(){const i=yield this._outlineModelService.getOrCreate(e,t);return t.isCancellationRequested?[]:i.asListOfDocumentSymbols()}))}};E.PREFIX="@",E.SCOPE_PREFIX=":",E.PREFIX_BY_CATEGORY=`${E.PREFIX}${E.SCOPE_PREFIX}`,E=function(e,t,i,n){var o,r=arguments.length,s=r<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,i):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(e,t,i,n);else for(var a=e.length-1;a>=0;a--)(o=e[a])&&(s=(r<3?o(s):r>3?o(t,i,s):o(t,i))||s);return r>3&&s&&Object.defineProperty(t,i,s),s}([k(0,x.p),k(1,w.Je)],E);const N=(0,S.NC)("vs/editor/contrib/quickAccess/browser/gotoSymbolQuickAccess","property","properties ({0})"),D={5:(0,S.NC)("vs/editor/contrib/quickAccess/browser/gotoSymbolQuickAccess","method","methods ({0})"),11:(0,S.NC)("vs/editor/contrib/quickAccess/browser/gotoSymbolQuickAccess","function","functions ({0})"),8:(0,S.NC)("vs/editor/contrib/quickAccess/browser/gotoSymbolQuickAccess","_constructor","constructors ({0})"),12:(0,S.NC)("vs/editor/contrib/quickAccess/browser/gotoSymbolQuickAccess","variable","variables ({0})"),4:(0,S.NC)("vs/editor/contrib/quickAccess/browser/gotoSymbolQuickAccess","class","classes ({0})"),22:(0,S.NC)("vs/editor/contrib/quickAccess/browser/gotoSymbolQuickAccess","struct","structs ({0})"),23:(0,S.NC)("vs/editor/contrib/quickAccess/browser/gotoSymbolQuickAccess","event","events ({0})"),24:(0,S.NC)("vs/editor/contrib/quickAccess/browser/gotoSymbolQuickAccess","operator","operators ({0})"),10:(0,S.NC)("vs/editor/contrib/quickAccess/browser/gotoSymbolQuickAccess","interface","interfaces ({0})"),2:(0,S.NC)("vs/editor/contrib/quickAccess/browser/gotoSymbolQuickAccess","namespace","namespaces ({0})"),3:(0,S.NC)("vs/editor/contrib/quickAccess/browser/gotoSymbolQuickAccess","package","packages ({0})"),25:(0,S.NC)("vs/editor/contrib/quickAccess/browser/gotoSymbolQuickAccess","typeParameter","type parameters ({0})"),1:(0,S.NC)("vs/editor/contrib/quickAccess/browser/gotoSymbolQuickAccess","modules","modules ({0})"),6:(0,S.NC)("vs/editor/contrib/quickAccess/browser/gotoSymbolQuickAccess","property","properties ({0})"),9:(0,S.NC)("vs/editor/contrib/quickAccess/browser/gotoSymbolQuickAccess","enum","enumerations ({0})"),21:(0,S.NC)("vs/editor/contrib/quickAccess/browser/gotoSymbolQuickAccess","enumMember","enumeration members ({0})"),14:(0,S.NC)("vs/editor/contrib/quickAccess/browser/gotoSymbolQuickAccess","string","strings ({0})"),0:(0,S.NC)("vs/editor/contrib/quickAccess/browser/gotoSymbolQuickAccess","file","files ({0})"),17:(0,S.NC)("vs/editor/contrib/quickAccess/browser/gotoSymbolQuickAccess","array","arrays ({0})"),15:(0,S.NC)("vs/editor/contrib/quickAccess/browser/gotoSymbolQuickAccess","number","numbers ({0})"),16:(0,S.NC)("vs/editor/contrib/quickAccess/browser/gotoSymbolQuickAccess","boolean","booleans ({0})"),18:(0,S.NC)("vs/editor/contrib/quickAccess/browser/gotoSymbolQuickAccess","object","objects ({0})"),19:(0,S.NC)("vs/editor/contrib/quickAccess/browser/gotoSymbolQuickAccess","key","keys ({0})"),7:(0,S.NC)("vs/editor/contrib/quickAccess/browser/gotoSymbolQuickAccess","field","fields ({0})"),13:(0,S.NC)("vs/editor/contrib/quickAccess/browser/gotoSymbolQuickAccess","constant","constants ({0})")};var I=i(73403),T=i(34073),A=i(3622),R=i(28295),M=i(71414),O=i(46718),P=i(4189),F=i(38673),B=i(22447),W=function(e,t){return function(i,n){t(i,n,e)}};let V=class extends E{constructor(e,t,i){super(t,i),this.editorService=e,this.onDidActiveTextEditorControlChange=O.ju.None}get activeTextEditorControl(){return(0,R.f6)(this.editorService.getFocusedCodeEditor())}};V=function(e,t,i,n){var o,r=arguments.length,s=r<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,i):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(e,t,i,n);else for(var a=e.length-1;a>=0;a--)(o=e[a])&&(s=(r<3?o(s):r>3?o(t,i,s):o(t,i))||s);return r>3&&s&&Object.defineProperty(t,i,s),s}([W(0,A.$),W(1,x.p),W(2,w.Je)],V),I.B.as(T.IP.Quickaccess).registerQuickAccessProvider({ctor:V,prefix:E.PREFIX,helpEntries:[{description:M.aq.quickOutlineActionLabel,prefix:E.PREFIX,needsEditor:!0},{description:M.aq.quickOutlineByCategoryActionLabel,prefix:E.PREFIX_BY_CATEGORY,needsEditor:!0}]});class H extends P.R6{constructor(){super({id:"editor.action.quickOutline",label:M.aq.quickOutlineActionLabel,alias:"Go to Symbol...",precondition:F.u.hasDocumentSymbolProvider,kbOpts:{kbExpr:F.u.focus,primary:3117,weight:100},contextMenuOpts:{group:"navigation",order:3}})}run(e){e.get(B.eJ).quickAccess.show(E.PREFIX)}}(0,P.Qr)(H)},71874:function(e,t,i){"use strict";i.r(t);var n=i(73403),o=i(34073),r=i(71414),s=i(4004),a=i(89982),l=i(22447);let c=class e{constructor(e){this.quickInputService=e,this.registry=n.B.as(o.IP.Quickaccess)}provide(t){const i=new s.SL;i.add(t.onDidAccept((()=>{const[e]=t.selectedItems;e&&this.quickInputService.quickAccess.show(e.prefix,{preserveValue:!0})}))),i.add(t.onDidChangeValue((t=>{const i=this.registry.getQuickAccessProvider(t.substr(e.PREFIX.length));i&&i.prefix&&i.prefix!==e.PREFIX&&this.quickInputService.quickAccess.show(i.prefix,{preserveValue:!0})})));const{editorProviders:n,globalProviders:o}=this.getQuickAccessProviders();return t.items=0===n.length||0===o.length?[...0===n.length?o:n]:[{label:(0,a.NC)("vs/platform/quickinput/browser/helpQuickAccess","globalCommands","global commands"),type:"separator"},...o,{label:(0,a.NC)("vs/platform/quickinput/browser/helpQuickAccess","editorCommands","editor commands"),type:"separator"},...n],i}getQuickAccessProviders(){const t=[],i=[];for(const n of this.registry.getQuickAccessProviders().sort(((e,t)=>e.prefix.localeCompare(t.prefix))))if(n.prefix!==e.PREFIX)for(const e of n.helpEntries){const o=e.prefix||n.prefix,r=o||"…";(e.needsEditor?i:t).push({prefix:o,label:r,ariaLabel:(0,a.NC)("vs/platform/quickinput/browser/helpQuickAccess","helpPickAriaLabel","{0}, {1}",r,e.description),description:e.description})}return{editorProviders:i,globalProviders:t}}};var d,u;c.PREFIX="?",c=function(e,t,i,n){var o,r=arguments.length,s=r<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,i):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(e,t,i,n);else for(var a=e.length-1;a>=0;a--)(o=e[a])&&(s=(r<3?o(s):r>3?o(t,i,s):o(t,i))||s);return r>3&&s&&Object.defineProperty(t,i,s),s}([(d=0,u=l.eJ,function(e,t){u(e,t,d)})],c),n.B.as(o.IP.Quickaccess).registerQuickAccessProvider({ctor:c,prefix:"",helpEntries:[{description:r.ld.helpQuickAccessActionLabel,needsEditor:!0}]})},5380:function(e,t,i){"use strict";i.r(t),i.d(t,{StandaloneReferencesController:function(){return h}});var n=i(4189),o=i(3622),r=i(4235),s=i(40539),a=i(60393),l=i(12260),c=i(66877),d=i(86303),u=function(e,t){return function(i,n){t(i,n,e)}};let h=class extends r.J{constructor(e,t,i,n,o,r,s){super(!0,e,t,i,n,o,r,s)}};h=function(e,t,i,n){var o,r=arguments.length,s=r<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,i):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(e,t,i,n);else for(var a=e.length-1;a>=0;a--)(o=e[a])&&(s=(r<3?o(s):r>3?o(t,i,s):o(t,i))||s);return r>3&&s&&Object.defineProperty(t,i,s),s}([u(1,a.i6),u(2,o.$),u(3,c.lT),u(4,l.TG),u(5,d.Uy),u(6,s.Ui)],h),(0,n._K)(r.J.ID,h)},82597:function(e,t,i){"use strict";i.r(t);var n=i(4189),o=i(52093),r=i(71414);class s extends n.R6{constructor(){super({id:"editor.action.toggleHighContrast",label:r.xi.toggleHighContrast,alias:"Toggle High Contrast Theme",precondition:void 0}),this._originalThemeName=null}run(e,t){const i=e.get(o.Z);this._originalThemeName?(i.setTheme(this._originalThemeName),this._originalThemeName=null):(this._originalThemeName=i.getColorTheme().themeName,i.setTheme("hc-black"))}}(0,n.Qr)(s)},52093:function(e,t,i){"use strict";i.d(t,{Z:function(){return n}});const n=(0,i(12260).yh)("themeService")},67231:function(e,t,i){"use strict";i.r(t),i.d(t,{CompletionAdapter:function(){return dt},DefinitionAdapter:function(){return wt},DiagnosticsAdapter:function(){return lt},DocumentColorAdapter:function(){return Tt},DocumentFormattingEditProvider:function(){return Nt},DocumentHighlightAdapter:function(){return vt},DocumentLinkAdapter:function(){return Et},DocumentRangeFormattingEditProvider:function(){return Dt},DocumentSymbolAdapter:function(){return kt},FoldingRangeAdapter:function(){return At},HoverAdapter:function(){return ft},ReferenceAdapter:function(){return St},RenameAdapter:function(){return xt},SelectionRangeAdapter:function(){return Rt},WorkerManager:function(){return oe},fromPosition:function(){return ut},fromRange:function(){return ht},setupMode:function(){return Mt},toRange:function(){return gt},toTextEdit:function(){return mt}});var n=i(54918),o=Object.defineProperty,r=Object.getOwnPropertyDescriptor,s=Object.getOwnPropertyNames,a=Object.prototype.hasOwnProperty,l={};((e,t,i,n)=>{if(t&&"object"==typeof t||"function"==typeof t)for(let i of s(t))a.call(e,i)||"default"===i||o(e,i,{get:()=>t[i],enumerable:!(n=r(t,i))||n.enumerable})})(l,n);var c,d,u,h,g,p,m,f,_,b,v,C,w,y,S,x,k,L,E,N,D,I,T,A,R,M,O,P,F,B,W,V,H,z,$,U,j,K,q,G,Z,Y,Q,X,J,ee,te,ie,ne,oe=class{_defaults;_idleCheckInterval;_lastUsedTime;_configChangeListener;_worker;_client;constructor(e){this._defaults=e,this._worker=null,this._client=null,this._idleCheckInterval=window.setInterval((()=>this._checkIfIdle()),3e4),this._lastUsedTime=0,this._configChangeListener=this._defaults.onDidChange((()=>this._stopWorker()))}_stopWorker(){this._worker&&(this._worker.dispose(),this._worker=null),this._client=null}dispose(){clearInterval(this._idleCheckInterval),this._configChangeListener.dispose(),this._stopWorker()}_checkIfIdle(){this._worker&&Date.now()-this._lastUsedTime>12e4&&this._stopWorker()}_getClient(){return this._lastUsedTime=Date.now(),this._client||(this._worker=l.editor.createWebWorker({moduleId:"vs/language/css/cssWorker",label:this._defaults.languageId,createData:{options:this._defaults.options,languageId:this._defaults.languageId}}),this._client=this._worker.getProxy()),this._client}getLanguageServiceWorker(...e){let t;return this._getClient().then((e=>{t=e})).then((t=>{if(this._worker)return this._worker.withSyncedResources(e)})).then((e=>t))}};(d=c||(c={})).MIN_VALUE=-2147483648,d.MAX_VALUE=2147483647,(h=u||(u={})).MIN_VALUE=0,h.MAX_VALUE=2147483647,(p=g||(g={})).create=function(e,t){return e===Number.MAX_VALUE&&(e=u.MAX_VALUE),t===Number.MAX_VALUE&&(t=u.MAX_VALUE),{line:e,character:t}},p.is=function(e){var t=e;return ot.objectLiteral(t)&&ot.uinteger(t.line)&&ot.uinteger(t.character)},(f=m||(m={})).create=function(e,t,i,n){if(ot.uinteger(e)&&ot.uinteger(t)&&ot.uinteger(i)&&ot.uinteger(n))return{start:g.create(e,t),end:g.create(i,n)};if(g.is(e)&&g.is(t))return{start:e,end:t};throw new Error("Range#create called with invalid arguments["+e+", "+t+", "+i+", "+n+"]")},f.is=function(e){var t=e;return ot.objectLiteral(t)&&g.is(t.start)&&g.is(t.end)},(b=_||(_={})).create=function(e,t){return{uri:e,range:t}},b.is=function(e){var t=e;return ot.defined(t)&&m.is(t.range)&&(ot.string(t.uri)||ot.undefined(t.uri))},(C=v||(v={})).create=function(e,t,i,n){return{targetUri:e,targetRange:t,targetSelectionRange:i,originSelectionRange:n}},C.is=function(e){var t=e;return ot.defined(t)&&m.is(t.targetRange)&&ot.string(t.targetUri)&&(m.is(t.targetSelectionRange)||ot.undefined(t.targetSelectionRange))&&(m.is(t.originSelectionRange)||ot.undefined(t.originSelectionRange))},(y=w||(w={})).create=function(e,t,i,n){return{red:e,green:t,blue:i,alpha:n}},y.is=function(e){var t=e;return ot.numberRange(t.red,0,1)&&ot.numberRange(t.green,0,1)&&ot.numberRange(t.blue,0,1)&&ot.numberRange(t.alpha,0,1)},(x=S||(S={})).create=function(e,t){return{range:e,color:t}},x.is=function(e){var t=e;return m.is(t.range)&&w.is(t.color)},(L=k||(k={})).create=function(e,t,i){return{label:e,textEdit:t,additionalTextEdits:i}},L.is=function(e){var t=e;return ot.string(t.label)&&(ot.undefined(t.textEdit)||z.is(t))&&(ot.undefined(t.additionalTextEdits)||ot.typedArray(t.additionalTextEdits,z.is))},(N=E||(E={})).Comment="comment",N.Imports="imports",N.Region="region",(I=D||(D={})).create=function(e,t,i,n,o){var r={startLine:e,endLine:t};return ot.defined(i)&&(r.startCharacter=i),ot.defined(n)&&(r.endCharacter=n),ot.defined(o)&&(r.kind=o),r},I.is=function(e){var t=e;return ot.uinteger(t.startLine)&&ot.uinteger(t.startLine)&&(ot.undefined(t.startCharacter)||ot.uinteger(t.startCharacter))&&(ot.undefined(t.endCharacter)||ot.uinteger(t.endCharacter))&&(ot.undefined(t.kind)||ot.string(t.kind))},(A=T||(T={})).create=function(e,t){return{location:e,message:t}},A.is=function(e){var t=e;return ot.defined(t)&&_.is(t.location)&&ot.string(t.message)},(M=R||(R={})).Error=1,M.Warning=2,M.Information=3,M.Hint=4,(P=O||(O={})).Unnecessary=1,P.Deprecated=2,(F||(F={})).is=function(e){var t=e;return null!=t&&ot.string(t.href)},(W=B||(B={})).create=function(e,t,i,n,o,r){var s={range:e,message:t};return ot.defined(i)&&(s.severity=i),ot.defined(n)&&(s.code=n),ot.defined(o)&&(s.source=o),ot.defined(r)&&(s.relatedInformation=r),s},W.is=function(e){var t,i=e;return ot.defined(i)&&m.is(i.range)&&ot.string(i.message)&&(ot.number(i.severity)||ot.undefined(i.severity))&&(ot.integer(i.code)||ot.string(i.code)||ot.undefined(i.code))&&(ot.undefined(i.codeDescription)||ot.string(null===(t=i.codeDescription)||void 0===t?void 0:t.href))&&(ot.string(i.source)||ot.undefined(i.source))&&(ot.undefined(i.relatedInformation)||ot.typedArray(i.relatedInformation,T.is))},(H=V||(V={})).create=function(e,t){for(var i=[],n=2;n0&&(o.arguments=i),o},H.is=function(e){var t=e;return ot.defined(t)&&ot.string(t.title)&&ot.string(t.command)},($=z||(z={})).replace=function(e,t){return{range:e,newText:t}},$.insert=function(e,t){return{range:{start:e,end:e},newText:t}},$.del=function(e){return{range:e,newText:""}},$.is=function(e){var t=e;return ot.objectLiteral(t)&&ot.string(t.newText)&&m.is(t.range)},(j=U||(U={})).create=function(e,t,i){var n={label:e};return void 0!==t&&(n.needsConfirmation=t),void 0!==i&&(n.description=i),n},j.is=function(e){var t=e;return void 0!==t&&ot.objectLiteral(t)&&ot.string(t.label)&&(ot.boolean(t.needsConfirmation)||void 0===t.needsConfirmation)&&(ot.string(t.description)||void 0===t.description)},(K||(K={})).is=function(e){return"string"==typeof e},(G=q||(q={})).replace=function(e,t,i){return{range:e,newText:t,annotationId:i}},G.insert=function(e,t,i){return{range:{start:e,end:e},newText:t,annotationId:i}},G.del=function(e,t){return{range:e,newText:"",annotationId:t}},G.is=function(e){var t=e;return z.is(t)&&(U.is(t.annotationId)||K.is(t.annotationId))},(Y=Z||(Z={})).create=function(e,t){return{textDocument:e,edits:t}},Y.is=function(e){var t=e;return ot.defined(t)&&ce.is(t.textDocument)&&Array.isArray(t.edits)},(X=Q||(Q={})).create=function(e,t,i){var n={kind:"create",uri:e};return void 0===t||void 0===t.overwrite&&void 0===t.ignoreIfExists||(n.options=t),void 0!==i&&(n.annotationId=i),n},X.is=function(e){var t=e;return t&&"create"===t.kind&&ot.string(t.uri)&&(void 0===t.options||(void 0===t.options.overwrite||ot.boolean(t.options.overwrite))&&(void 0===t.options.ignoreIfExists||ot.boolean(t.options.ignoreIfExists)))&&(void 0===t.annotationId||K.is(t.annotationId))},(ee=J||(J={})).create=function(e,t,i,n){var o={kind:"rename",oldUri:e,newUri:t};return void 0===i||void 0===i.overwrite&&void 0===i.ignoreIfExists||(o.options=i),void 0!==n&&(o.annotationId=n),o},ee.is=function(e){var t=e;return t&&"rename"===t.kind&&ot.string(t.oldUri)&&ot.string(t.newUri)&&(void 0===t.options||(void 0===t.options.overwrite||ot.boolean(t.options.overwrite))&&(void 0===t.options.ignoreIfExists||ot.boolean(t.options.ignoreIfExists)))&&(void 0===t.annotationId||K.is(t.annotationId))},(ie=te||(te={})).create=function(e,t,i){var n={kind:"delete",uri:e};return void 0===t||void 0===t.recursive&&void 0===t.ignoreIfNotExists||(n.options=t),void 0!==i&&(n.annotationId=i),n},ie.is=function(e){var t=e;return t&&"delete"===t.kind&&ot.string(t.uri)&&(void 0===t.options||(void 0===t.options.recursive||ot.boolean(t.options.recursive))&&(void 0===t.options.ignoreIfNotExists||ot.boolean(t.options.ignoreIfNotExists)))&&(void 0===t.annotationId||K.is(t.annotationId))},(ne||(ne={})).is=function(e){var t=e;return t&&(void 0!==t.changes||void 0!==t.documentChanges)&&(void 0===t.documentChanges||t.documentChanges.every((function(e){return ot.string(e.kind)?Q.is(e)||J.is(e)||te.is(e):Z.is(e)})))};var re,se,ae,le,ce,de,ue,he,ge,pe,me,fe,_e,be,ve,Ce,we,ye,Se,xe,ke,Le,Ee,Ne,De,Ie,Te,Ae,Re,Me,Oe,Pe,Fe,Be,We,Ve,He,ze,$e,Ue,je,Ke,qe,Ge,Ze,Ye,Qe,Xe,Je,et,tt,it=function(){function e(e,t){this.edits=e,this.changeAnnotations=t}return e.prototype.insert=function(e,t,i){var n,o;if(void 0===i?n=z.insert(e,t):K.is(i)?(o=i,n=q.insert(e,t,i)):(this.assertChangeAnnotations(this.changeAnnotations),o=this.changeAnnotations.manage(i),n=q.insert(e,t,o)),this.edits.push(n),void 0!==o)return o},e.prototype.replace=function(e,t,i){var n,o;if(void 0===i?n=z.replace(e,t):K.is(i)?(o=i,n=q.replace(e,t,i)):(this.assertChangeAnnotations(this.changeAnnotations),o=this.changeAnnotations.manage(i),n=q.replace(e,t,o)),this.edits.push(n),void 0!==o)return o},e.prototype.delete=function(e,t){var i,n;if(void 0===t?i=z.del(e):K.is(t)?(n=t,i=q.del(e,t)):(this.assertChangeAnnotations(this.changeAnnotations),n=this.changeAnnotations.manage(t),i=q.del(e,n)),this.edits.push(i),void 0!==n)return n},e.prototype.add=function(e){this.edits.push(e)},e.prototype.all=function(){return this.edits},e.prototype.clear=function(){this.edits.splice(0,this.edits.length)},e.prototype.assertChangeAnnotations=function(e){if(void 0===e)throw new Error("Text edit change is not configured to manage change annotations.")},e}(),nt=function(){function e(e){this._annotations=void 0===e?Object.create(null):e,this._counter=0,this._size=0}return e.prototype.all=function(){return this._annotations},Object.defineProperty(e.prototype,"size",{get:function(){return this._size},enumerable:!1,configurable:!0}),e.prototype.manage=function(e,t){var i;if(K.is(e)?i=e:(i=this.nextId(),t=e),void 0!==this._annotations[i])throw new Error("Id "+i+" is already in use.");if(void 0===t)throw new Error("No annotation provided for id "+i);return this._annotations[i]=t,this._size++,i},e.prototype.nextId=function(){return this._counter++,this._counter.toString()},e}();!function(){function e(e){var t=this;this._textEditChanges=Object.create(null),void 0!==e?(this._workspaceEdit=e,e.documentChanges?(this._changeAnnotations=new nt(e.changeAnnotations),e.changeAnnotations=this._changeAnnotations.all(),e.documentChanges.forEach((function(e){if(Z.is(e)){var i=new it(e.edits,t._changeAnnotations);t._textEditChanges[e.textDocument.uri]=i}}))):e.changes&&Object.keys(e.changes).forEach((function(i){var n=new it(e.changes[i]);t._textEditChanges[i]=n}))):this._workspaceEdit={}}Object.defineProperty(e.prototype,"edit",{get:function(){return this.initDocumentChanges(),void 0!==this._changeAnnotations&&(0===this._changeAnnotations.size?this._workspaceEdit.changeAnnotations=void 0:this._workspaceEdit.changeAnnotations=this._changeAnnotations.all()),this._workspaceEdit},enumerable:!1,configurable:!0}),e.prototype.getTextEditChange=function(e){if(ce.is(e)){if(this.initDocumentChanges(),void 0===this._workspaceEdit.documentChanges)throw new Error("Workspace edit is not configured for document changes.");var t={uri:e.uri,version:e.version};if(!(n=this._textEditChanges[t.uri])){var i={textDocument:t,edits:o=[]};this._workspaceEdit.documentChanges.push(i),n=new it(o,this._changeAnnotations),this._textEditChanges[t.uri]=n}return n}if(this.initChanges(),void 0===this._workspaceEdit.changes)throw new Error("Workspace edit is not configured for normal text edit changes.");var n;if(!(n=this._textEditChanges[e])){var o=[];this._workspaceEdit.changes[e]=o,n=new it(o),this._textEditChanges[e]=n}return n},e.prototype.initDocumentChanges=function(){void 0===this._workspaceEdit.documentChanges&&void 0===this._workspaceEdit.changes&&(this._changeAnnotations=new nt,this._workspaceEdit.documentChanges=[],this._workspaceEdit.changeAnnotations=this._changeAnnotations.all())},e.prototype.initChanges=function(){void 0===this._workspaceEdit.documentChanges&&void 0===this._workspaceEdit.changes&&(this._workspaceEdit.changes=Object.create(null))},e.prototype.createFile=function(e,t,i){if(this.initDocumentChanges(),void 0===this._workspaceEdit.documentChanges)throw new Error("Workspace edit is not configured for document changes.");var n,o,r;if(U.is(t)||K.is(t)?n=t:i=t,void 0===n?o=Q.create(e,i):(r=K.is(n)?n:this._changeAnnotations.manage(n),o=Q.create(e,i,r)),this._workspaceEdit.documentChanges.push(o),void 0!==r)return r},e.prototype.renameFile=function(e,t,i,n){if(this.initDocumentChanges(),void 0===this._workspaceEdit.documentChanges)throw new Error("Workspace edit is not configured for document changes.");var o,r,s;if(U.is(i)||K.is(i)?o=i:n=i,void 0===o?r=J.create(e,t,n):(s=K.is(o)?o:this._changeAnnotations.manage(o),r=J.create(e,t,n,s)),this._workspaceEdit.documentChanges.push(r),void 0!==s)return s},e.prototype.deleteFile=function(e,t,i){if(this.initDocumentChanges(),void 0===this._workspaceEdit.documentChanges)throw new Error("Workspace edit is not configured for document changes.");var n,o,r;if(U.is(t)||K.is(t)?n=t:i=t,void 0===n?o=te.create(e,i):(r=K.is(n)?n:this._changeAnnotations.manage(n),o=te.create(e,i,r)),this._workspaceEdit.documentChanges.push(o),void 0!==r)return r}}(),(se=re||(re={})).create=function(e){return{uri:e}},se.is=function(e){var t=e;return ot.defined(t)&&ot.string(t.uri)},(le=ae||(ae={})).create=function(e,t){return{uri:e,version:t}},le.is=function(e){var t=e;return ot.defined(t)&&ot.string(t.uri)&&ot.integer(t.version)},(de=ce||(ce={})).create=function(e,t){return{uri:e,version:t}},de.is=function(e){var t=e;return ot.defined(t)&&ot.string(t.uri)&&(null===t.version||ot.integer(t.version))},(he=ue||(ue={})).create=function(e,t,i,n){return{uri:e,languageId:t,version:i,text:n}},he.is=function(e){var t=e;return ot.defined(t)&&ot.string(t.uri)&&ot.string(t.languageId)&&ot.integer(t.version)&&ot.string(t.text)},(pe=ge||(ge={})).PlainText="plaintext",pe.Markdown="markdown",function(e){e.is=function(t){var i=t;return i===e.PlainText||i===e.Markdown}}(ge||(ge={})),(me||(me={})).is=function(e){var t=e;return ot.objectLiteral(e)&&ge.is(t.kind)&&ot.string(t.value)},(_e=fe||(fe={})).Text=1,_e.Method=2,_e.Function=3,_e.Constructor=4,_e.Field=5,_e.Variable=6,_e.Class=7,_e.Interface=8,_e.Module=9,_e.Property=10,_e.Unit=11,_e.Value=12,_e.Enum=13,_e.Keyword=14,_e.Snippet=15,_e.Color=16,_e.File=17,_e.Reference=18,_e.Folder=19,_e.EnumMember=20,_e.Constant=21,_e.Struct=22,_e.Event=23,_e.Operator=24,_e.TypeParameter=25,(ve=be||(be={})).PlainText=1,ve.Snippet=2,(Ce||(Ce={})).Deprecated=1,(ye=we||(we={})).create=function(e,t,i){return{newText:e,insert:t,replace:i}},ye.is=function(e){var t=e;return t&&ot.string(t.newText)&&m.is(t.insert)&&m.is(t.replace)},(xe=Se||(Se={})).asIs=1,xe.adjustIndentation=2,(ke||(ke={})).create=function(e){return{label:e}},(Le||(Le={})).create=function(e,t){return{items:e||[],isIncomplete:!!t}},(Ne=Ee||(Ee={})).fromPlainText=function(e){return e.replace(/[\\`*_{}[\]()#+\-.!]/g,"\\$&")},Ne.is=function(e){var t=e;return ot.string(t)||ot.objectLiteral(t)&&ot.string(t.language)&&ot.string(t.value)},(De||(De={})).is=function(e){var t=e;return!!t&&ot.objectLiteral(t)&&(me.is(t.contents)||Ee.is(t.contents)||ot.typedArray(t.contents,Ee.is))&&(void 0===e.range||m.is(e.range))},(Ie||(Ie={})).create=function(e,t){return t?{label:e,documentation:t}:{label:e}},(Te||(Te={})).create=function(e,t){for(var i=[],n=2;n=0;s--){var a=o[s],l=e.offsetAt(a.range.start),c=e.offsetAt(a.range.end);if(!(c<=r))throw new Error("Overlapping edit");n=n.substring(0,l)+a.newText+n.substring(c,n.length),r=l}return n}}(tt||(tt={}));var ot,rt,st,at=function(){function e(e,t,i,n){this._uri=e,this._languageId=t,this._version=i,this._content=n,this._lineOffsets=void 0}return Object.defineProperty(e.prototype,"uri",{get:function(){return this._uri},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"languageId",{get:function(){return this._languageId},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"version",{get:function(){return this._version},enumerable:!1,configurable:!0}),e.prototype.getText=function(e){if(e){var t=this.offsetAt(e.start),i=this.offsetAt(e.end);return this._content.substring(t,i)}return this._content},e.prototype.update=function(e,t){this._content=e.text,this._version=t,this._lineOffsets=void 0},e.prototype.getLineOffsets=function(){if(void 0===this._lineOffsets){for(var e=[],t=this._content,i=!0,n=0;n0&&e.push(t.length),this._lineOffsets=e}return this._lineOffsets},e.prototype.positionAt=function(e){e=Math.max(Math.min(e,this._content.length),0);var t=this.getLineOffsets(),i=0,n=t.length;if(0===n)return g.create(0,e);for(;ie?n=o:i=o+1}var r=i-1;return g.create(r,e-t[r])},e.prototype.offsetAt=function(e){var t=this.getLineOffsets();if(e.line>=t.length)return this._content.length;if(e.line<0)return 0;var i=t[e.line],n=e.line+1{let t,i=e.getLanguageId();i===this._languageId&&(this._listener[e.uri.toString()]=e.onDidChangeContent((()=>{window.clearTimeout(t),t=window.setTimeout((()=>this._doValidate(e.uri,i)),500)})),this._doValidate(e.uri,i))},o=e=>{l.editor.setModelMarkers(e,this._languageId,[]);let t=e.uri.toString(),i=this._listener[t];i&&(i.dispose(),delete this._listener[t])};this._disposables.push(l.editor.onDidCreateModel(n)),this._disposables.push(l.editor.onWillDisposeModel(o)),this._disposables.push(l.editor.onDidChangeModelLanguage((e=>{o(e.model),n(e.model)}))),this._disposables.push(i((e=>{l.editor.getModels().forEach((e=>{e.getLanguageId()===this._languageId&&(o(e),n(e))}))}))),this._disposables.push({dispose:()=>{l.editor.getModels().forEach(o);for(let e in this._listener)this._listener[e].dispose()}}),l.editor.getModels().forEach(n)}_disposables=[];_listener=Object.create(null);dispose(){this._disposables.forEach((e=>e&&e.dispose())),this._disposables.length=0}_doValidate(e,t){this._worker(e).then((t=>t.doValidation(e.toString()))).then((i=>{const n=i.map((e=>function(e,t){let i="number"==typeof t.code?String(t.code):t.code;return{severity:ct(t.severity),startLineNumber:t.range.start.line+1,startColumn:t.range.start.character+1,endLineNumber:t.range.end.line+1,endColumn:t.range.end.character+1,message:t.message,code:i,source:t.source}}(0,e)));let o=l.editor.getModel(e);o&&o.getLanguageId()===t&&l.editor.setModelMarkers(o,t,n)})).then(void 0,(e=>{console.error(e)}))}};function ct(e){switch(e){case R.Error:return l.MarkerSeverity.Error;case R.Warning:return l.MarkerSeverity.Warning;case R.Information:return l.MarkerSeverity.Info;case R.Hint:return l.MarkerSeverity.Hint;default:return l.MarkerSeverity.Info}}var dt=class{constructor(e,t){this._worker=e,this._triggerCharacters=t}get triggerCharacters(){return this._triggerCharacters}provideCompletionItems(e,t,i,n){const o=e.uri;return this._worker(o).then((e=>e.doComplete(o.toString(),ut(t)))).then((i=>{if(!i)return;const n=e.getWordUntilPosition(t),o=new l.Range(t.lineNumber,n.startColumn,t.lineNumber,n.endColumn),r=i.items.map((e=>{const t={label:e.label,insertText:e.insertText||e.label,sortText:e.sortText,filterText:e.filterText,documentation:e.documentation,detail:e.detail,command:(i=e.command,i&&"editor.action.triggerSuggest"===i.command?{id:i.command,title:i.title,arguments:i.arguments}:void 0),range:o,kind:pt(e.kind)};var i,n;return e.textEdit&&(void 0!==(n=e.textEdit).insert&&void 0!==n.replace?t.range={insert:gt(e.textEdit.insert),replace:gt(e.textEdit.replace)}:t.range=gt(e.textEdit.range),t.insertText=e.textEdit.newText),e.additionalTextEdits&&(t.additionalTextEdits=e.additionalTextEdits.map(mt)),e.insertTextFormat===be.Snippet&&(t.insertTextRules=l.languages.CompletionItemInsertTextRule.InsertAsSnippet),t}));return{isIncomplete:i.isIncomplete,suggestions:r}}))}};function ut(e){if(e)return{character:e.column-1,line:e.lineNumber-1}}function ht(e){if(e)return{start:{line:e.startLineNumber-1,character:e.startColumn-1},end:{line:e.endLineNumber-1,character:e.endColumn-1}}}function gt(e){if(e)return new l.Range(e.start.line+1,e.start.character+1,e.end.line+1,e.end.character+1)}function pt(e){const t=l.languages.CompletionItemKind;switch(e){case fe.Text:return t.Text;case fe.Method:return t.Method;case fe.Function:return t.Function;case fe.Constructor:return t.Constructor;case fe.Field:return t.Field;case fe.Variable:return t.Variable;case fe.Class:return t.Class;case fe.Interface:return t.Interface;case fe.Module:return t.Module;case fe.Property:return t.Property;case fe.Unit:return t.Unit;case fe.Value:return t.Value;case fe.Enum:return t.Enum;case fe.Keyword:return t.Keyword;case fe.Snippet:return t.Snippet;case fe.Color:return t.Color;case fe.File:return t.File;case fe.Reference:return t.Reference}return t.Property}function mt(e){if(e)return{range:gt(e.range),text:e.newText}}var ft=class{constructor(e){this._worker=e}provideHover(e,t,i){let n=e.uri;return this._worker(n).then((e=>e.doHover(n.toString(),ut(t)))).then((e=>{if(e)return{range:gt(e.range),contents:bt(e.contents)}}))}};function _t(e){return"string"==typeof e?{value:e}:(t=e)&&"object"==typeof t&&"string"==typeof t.kind?"plaintext"===e.kind?{value:e.value.replace(/[\\`*_{}[\]()#+\-.!]/g,"\\$&")}:{value:e.value}:{value:"```"+e.language+"\n"+e.value+"\n```\n"};var t}function bt(e){if(e)return Array.isArray(e)?e.map(_t):[_t(e)]}var vt=class{constructor(e){this._worker=e}provideDocumentHighlights(e,t,i){const n=e.uri;return this._worker(n).then((e=>e.findDocumentHighlights(n.toString(),ut(t)))).then((e=>{if(e)return e.map((e=>({range:gt(e.range),kind:Ct(e.kind)})))}))}};function Ct(e){switch(e){case Ae.Read:return l.languages.DocumentHighlightKind.Read;case Ae.Write:return l.languages.DocumentHighlightKind.Write;case Ae.Text:return l.languages.DocumentHighlightKind.Text}return l.languages.DocumentHighlightKind.Text}var wt=class{constructor(e){this._worker=e}provideDefinition(e,t,i){const n=e.uri;return this._worker(n).then((e=>e.findDefinition(n.toString(),ut(t)))).then((e=>{if(e)return[yt(e)]}))}};function yt(e){return{uri:l.Uri.parse(e.uri),range:gt(e.range)}}var St=class{constructor(e){this._worker=e}provideReferences(e,t,i,n){const o=e.uri;return this._worker(o).then((e=>e.findReferences(o.toString(),ut(t)))).then((e=>{if(e)return e.map(yt)}))}},xt=class{constructor(e){this._worker=e}provideRenameEdits(e,t,i,n){const o=e.uri;return this._worker(o).then((e=>e.doRename(o.toString(),ut(t),i))).then((e=>function(e){if(!e||!e.changes)return;let t=[];for(let i in e.changes){const n=l.Uri.parse(i);for(let o of e.changes[i])t.push({resource:n,edit:{range:gt(o.range),text:o.newText}})}return{edits:t}}(e)))}},kt=class{constructor(e){this._worker=e}provideDocumentSymbols(e,t){const i=e.uri;return this._worker(i).then((e=>e.findDocumentSymbols(i.toString()))).then((e=>{if(e)return e.map((e=>({name:e.name,detail:"",containerName:e.containerName,kind:Lt(e.kind),range:gt(e.location.range),selectionRange:gt(e.location.range),tags:[]})))}))}};function Lt(e){let t=l.languages.SymbolKind;switch(e){case Oe.File:return t.Array;case Oe.Module:return t.Module;case Oe.Namespace:return t.Namespace;case Oe.Package:return t.Package;case Oe.Class:return t.Class;case Oe.Method:return t.Method;case Oe.Property:return t.Property;case Oe.Field:return t.Field;case Oe.Constructor:return t.Constructor;case Oe.Enum:return t.Enum;case Oe.Interface:return t.Interface;case Oe.Function:return t.Function;case Oe.Variable:return t.Variable;case Oe.Constant:return t.Constant;case Oe.String:return t.String;case Oe.Number:return t.Number;case Oe.Boolean:return t.Boolean;case Oe.Array:return t.Array}return t.Function}var Et=class{constructor(e){this._worker=e}provideLinks(e,t){const i=e.uri;return this._worker(i).then((e=>e.findDocumentLinks(i.toString()))).then((e=>{if(e)return{links:e.map((e=>({range:gt(e.range),url:e.target})))}}))}},Nt=class{constructor(e){this._worker=e}provideDocumentFormattingEdits(e,t,i){const n=e.uri;return this._worker(n).then((e=>e.format(n.toString(),null,It(t)).then((e=>{if(e&&0!==e.length)return e.map(mt)}))))}},Dt=class{constructor(e){this._worker=e}provideDocumentRangeFormattingEdits(e,t,i,n){const o=e.uri;return this._worker(o).then((e=>e.format(o.toString(),ht(t),It(i)).then((e=>{if(e&&0!==e.length)return e.map(mt)}))))}};function It(e){return{tabSize:e.tabSize,insertSpaces:e.insertSpaces}}var Tt=class{constructor(e){this._worker=e}provideDocumentColors(e,t){const i=e.uri;return this._worker(i).then((e=>e.findDocumentColors(i.toString()))).then((e=>{if(e)return e.map((e=>({color:e.color,range:gt(e.range)})))}))}provideColorPresentations(e,t,i){const n=e.uri;return this._worker(n).then((e=>e.getColorPresentations(n.toString(),t.color,ht(t.range)))).then((e=>{if(e)return e.map((e=>{let t={label:e.label};return e.textEdit&&(t.textEdit=mt(e.textEdit)),e.additionalTextEdits&&(t.additionalTextEdits=e.additionalTextEdits.map(mt)),t}))}))}},At=class{constructor(e){this._worker=e}provideFoldingRanges(e,t,i){const n=e.uri;return this._worker(n).then((e=>e.getFoldingRanges(n.toString(),t))).then((e=>{if(e)return e.map((e=>{const t={start:e.startLine+1,end:e.endLine+1};return void 0!==e.kind&&(t.kind=function(e){switch(e){case E.Comment:return l.languages.FoldingRangeKind.Comment;case E.Imports:return l.languages.FoldingRangeKind.Imports;case E.Region:return l.languages.FoldingRangeKind.Region}}(e.kind)),t}))}))}},Rt=class{constructor(e){this._worker=e}provideSelectionRanges(e,t,i){const n=e.uri;return this._worker(n).then((e=>e.getSelectionRanges(n.toString(),t.map(ut)))).then((e=>{if(e)return e.map((e=>{const t=[];for(;e;)t.push({range:gt(e.range)}),e=e.parent;return t}))}))}};function Mt(e){const t=[],i=[],n=new oe(e);t.push(n);const o=(...e)=>n.getLanguageServiceWorker(...e);return function(){const{languageId:t,modeConfiguration:n}=e;Pt(i),n.completionItems&&i.push(l.languages.registerCompletionItemProvider(t,new dt(o,["/","-",":"]))),n.hovers&&i.push(l.languages.registerHoverProvider(t,new ft(o))),n.documentHighlights&&i.push(l.languages.registerDocumentHighlightProvider(t,new vt(o))),n.definitions&&i.push(l.languages.registerDefinitionProvider(t,new wt(o))),n.references&&i.push(l.languages.registerReferenceProvider(t,new St(o))),n.documentSymbols&&i.push(l.languages.registerDocumentSymbolProvider(t,new kt(o))),n.rename&&i.push(l.languages.registerRenameProvider(t,new xt(o))),n.colors&&i.push(l.languages.registerColorProvider(t,new Tt(o))),n.foldingRanges&&i.push(l.languages.registerFoldingRangeProvider(t,new At(o))),n.diagnostics&&i.push(new lt(t,o,e.onDidChange)),n.selectionRanges&&i.push(l.languages.registerSelectionRangeProvider(t,new Rt(o)))}(),t.push(Ot(i)),Ot(t)}function Ot(e){return{dispose:()=>Pt(e)}}function Pt(e){for(;e.length;)e.pop().dispose()}},31118:function(e,t,i){"use strict";i.r(t),i.d(t,{cssDefaults:function(){return h},lessDefaults:function(){return p},scssDefaults:function(){return g}});var n=i(54918),o=Object.defineProperty,r=Object.getOwnPropertyDescriptor,s=Object.getOwnPropertyNames,a=Object.prototype.hasOwnProperty,l={};((e,t,i,n)=>{if(t&&"object"==typeof t||"function"==typeof t)for(let i of s(t))a.call(e,i)||"default"===i||o(e,i,{get:()=>t[i],enumerable:!(n=r(t,i))||n.enumerable})})(l,n);var c=class{_onDidChange=new l.Emitter;_options;_modeConfiguration;_languageId;constructor(e,t,i){this._languageId=e,this.setOptions(t),this.setModeConfiguration(i)}get onDidChange(){return this._onDidChange.event}get languageId(){return this._languageId}get modeConfiguration(){return this._modeConfiguration}get diagnosticsOptions(){return this.options}get options(){return this._options}setOptions(e){this._options=e||Object.create(null),this._onDidChange.fire(this)}setDiagnosticsOptions(e){this.setOptions(e)}setModeConfiguration(e){this._modeConfiguration=e||Object.create(null),this._onDidChange.fire(this)}},d={validate:!0,lint:{compatibleVendorPrefixes:"ignore",vendorPrefix:"warning",duplicateProperties:"warning",emptyRules:"warning",importStatement:"ignore",boxModel:"ignore",universalSelector:"ignore",zeroUnits:"ignore",fontFaceProperties:"warning",hexColorLength:"error",argumentsInColorFunction:"error",unknownProperties:"warning",ieHack:"ignore",unknownVendorSpecificProperties:"ignore",propertyIgnoredDueToDisplay:"warning",important:"ignore",float:"ignore",idSelector:"ignore"},data:{useDefaultDataProvider:!0}},u={completionItems:!0,hovers:!0,documentSymbols:!0,definitions:!0,references:!0,documentHighlights:!0,rename:!0,colors:!0,foldingRanges:!0,diagnostics:!0,selectionRanges:!0},h=new c("css",d,u),g=new c("scss",d,u),p=new c("less",d,u);function m(){return Promise.resolve().then(i.bind(i,67231))}l.languages.css={cssDefaults:h,lessDefaults:p,scssDefaults:g},l.languages.onLanguage("less",(()=>{m().then((e=>e.setupMode(p)))})),l.languages.onLanguage("scss",(()=>{m().then((e=>e.setupMode(g)))})),l.languages.onLanguage("css",(()=>{m().then((e=>e.setupMode(h)))}))},36150:function(e,t,i){"use strict";i.r(t),i.d(t,{CompletionAdapter:function(){return dt},DefinitionAdapter:function(){return wt},DiagnosticsAdapter:function(){return lt},DocumentColorAdapter:function(){return Tt},DocumentFormattingEditProvider:function(){return Nt},DocumentHighlightAdapter:function(){return vt},DocumentLinkAdapter:function(){return Et},DocumentRangeFormattingEditProvider:function(){return Dt},DocumentSymbolAdapter:function(){return kt},FoldingRangeAdapter:function(){return At},HoverAdapter:function(){return ft},ReferenceAdapter:function(){return St},RenameAdapter:function(){return xt},SelectionRangeAdapter:function(){return Rt},WorkerManager:function(){return oe},fromPosition:function(){return ut},fromRange:function(){return ht},setupMode:function(){return Pt},setupMode1:function(){return Ot},toRange:function(){return gt},toTextEdit:function(){return mt}});var n=i(54918),o=Object.defineProperty,r=Object.getOwnPropertyDescriptor,s=Object.getOwnPropertyNames,a=Object.prototype.hasOwnProperty,l={};((e,t,i,n)=>{if(t&&"object"==typeof t||"function"==typeof t)for(let i of s(t))a.call(e,i)||"default"===i||o(e,i,{get:()=>t[i],enumerable:!(n=r(t,i))||n.enumerable})})(l,n);var c,d,u,h,g,p,m,f,_,b,v,C,w,y,S,x,k,L,E,N,D,I,T,A,R,M,O,P,F,B,W,V,H,z,$,U,j,K,q,G,Z,Y,Q,X,J,ee,te,ie,ne,oe=class{_defaults;_idleCheckInterval;_lastUsedTime;_configChangeListener;_worker;_client;constructor(e){this._defaults=e,this._worker=null,this._client=null,this._idleCheckInterval=window.setInterval((()=>this._checkIfIdle()),3e4),this._lastUsedTime=0,this._configChangeListener=this._defaults.onDidChange((()=>this._stopWorker()))}_stopWorker(){this._worker&&(this._worker.dispose(),this._worker=null),this._client=null}dispose(){clearInterval(this._idleCheckInterval),this._configChangeListener.dispose(),this._stopWorker()}_checkIfIdle(){this._worker&&Date.now()-this._lastUsedTime>12e4&&this._stopWorker()}_getClient(){return this._lastUsedTime=Date.now(),this._client||(this._worker=l.editor.createWebWorker({moduleId:"vs/language/html/htmlWorker",createData:{languageSettings:this._defaults.options,languageId:this._defaults.languageId},label:this._defaults.languageId}),this._client=this._worker.getProxy()),this._client}getLanguageServiceWorker(...e){let t;return this._getClient().then((e=>{t=e})).then((t=>{if(this._worker)return this._worker.withSyncedResources(e)})).then((e=>t))}};(d=c||(c={})).MIN_VALUE=-2147483648,d.MAX_VALUE=2147483647,(h=u||(u={})).MIN_VALUE=0,h.MAX_VALUE=2147483647,(p=g||(g={})).create=function(e,t){return e===Number.MAX_VALUE&&(e=u.MAX_VALUE),t===Number.MAX_VALUE&&(t=u.MAX_VALUE),{line:e,character:t}},p.is=function(e){var t=e;return ot.objectLiteral(t)&&ot.uinteger(t.line)&&ot.uinteger(t.character)},(f=m||(m={})).create=function(e,t,i,n){if(ot.uinteger(e)&&ot.uinteger(t)&&ot.uinteger(i)&&ot.uinteger(n))return{start:g.create(e,t),end:g.create(i,n)};if(g.is(e)&&g.is(t))return{start:e,end:t};throw new Error("Range#create called with invalid arguments["+e+", "+t+", "+i+", "+n+"]")},f.is=function(e){var t=e;return ot.objectLiteral(t)&&g.is(t.start)&&g.is(t.end)},(b=_||(_={})).create=function(e,t){return{uri:e,range:t}},b.is=function(e){var t=e;return ot.defined(t)&&m.is(t.range)&&(ot.string(t.uri)||ot.undefined(t.uri))},(C=v||(v={})).create=function(e,t,i,n){return{targetUri:e,targetRange:t,targetSelectionRange:i,originSelectionRange:n}},C.is=function(e){var t=e;return ot.defined(t)&&m.is(t.targetRange)&&ot.string(t.targetUri)&&(m.is(t.targetSelectionRange)||ot.undefined(t.targetSelectionRange))&&(m.is(t.originSelectionRange)||ot.undefined(t.originSelectionRange))},(y=w||(w={})).create=function(e,t,i,n){return{red:e,green:t,blue:i,alpha:n}},y.is=function(e){var t=e;return ot.numberRange(t.red,0,1)&&ot.numberRange(t.green,0,1)&&ot.numberRange(t.blue,0,1)&&ot.numberRange(t.alpha,0,1)},(x=S||(S={})).create=function(e,t){return{range:e,color:t}},x.is=function(e){var t=e;return m.is(t.range)&&w.is(t.color)},(L=k||(k={})).create=function(e,t,i){return{label:e,textEdit:t,additionalTextEdits:i}},L.is=function(e){var t=e;return ot.string(t.label)&&(ot.undefined(t.textEdit)||z.is(t))&&(ot.undefined(t.additionalTextEdits)||ot.typedArray(t.additionalTextEdits,z.is))},(N=E||(E={})).Comment="comment",N.Imports="imports",N.Region="region",(I=D||(D={})).create=function(e,t,i,n,o){var r={startLine:e,endLine:t};return ot.defined(i)&&(r.startCharacter=i),ot.defined(n)&&(r.endCharacter=n),ot.defined(o)&&(r.kind=o),r},I.is=function(e){var t=e;return ot.uinteger(t.startLine)&&ot.uinteger(t.startLine)&&(ot.undefined(t.startCharacter)||ot.uinteger(t.startCharacter))&&(ot.undefined(t.endCharacter)||ot.uinteger(t.endCharacter))&&(ot.undefined(t.kind)||ot.string(t.kind))},(A=T||(T={})).create=function(e,t){return{location:e,message:t}},A.is=function(e){var t=e;return ot.defined(t)&&_.is(t.location)&&ot.string(t.message)},(M=R||(R={})).Error=1,M.Warning=2,M.Information=3,M.Hint=4,(P=O||(O={})).Unnecessary=1,P.Deprecated=2,(F||(F={})).is=function(e){var t=e;return null!=t&&ot.string(t.href)},(W=B||(B={})).create=function(e,t,i,n,o,r){var s={range:e,message:t};return ot.defined(i)&&(s.severity=i),ot.defined(n)&&(s.code=n),ot.defined(o)&&(s.source=o),ot.defined(r)&&(s.relatedInformation=r),s},W.is=function(e){var t,i=e;return ot.defined(i)&&m.is(i.range)&&ot.string(i.message)&&(ot.number(i.severity)||ot.undefined(i.severity))&&(ot.integer(i.code)||ot.string(i.code)||ot.undefined(i.code))&&(ot.undefined(i.codeDescription)||ot.string(null===(t=i.codeDescription)||void 0===t?void 0:t.href))&&(ot.string(i.source)||ot.undefined(i.source))&&(ot.undefined(i.relatedInformation)||ot.typedArray(i.relatedInformation,T.is))},(H=V||(V={})).create=function(e,t){for(var i=[],n=2;n0&&(o.arguments=i),o},H.is=function(e){var t=e;return ot.defined(t)&&ot.string(t.title)&&ot.string(t.command)},($=z||(z={})).replace=function(e,t){return{range:e,newText:t}},$.insert=function(e,t){return{range:{start:e,end:e},newText:t}},$.del=function(e){return{range:e,newText:""}},$.is=function(e){var t=e;return ot.objectLiteral(t)&&ot.string(t.newText)&&m.is(t.range)},(j=U||(U={})).create=function(e,t,i){var n={label:e};return void 0!==t&&(n.needsConfirmation=t),void 0!==i&&(n.description=i),n},j.is=function(e){var t=e;return void 0!==t&&ot.objectLiteral(t)&&ot.string(t.label)&&(ot.boolean(t.needsConfirmation)||void 0===t.needsConfirmation)&&(ot.string(t.description)||void 0===t.description)},(K||(K={})).is=function(e){return"string"==typeof e},(G=q||(q={})).replace=function(e,t,i){return{range:e,newText:t,annotationId:i}},G.insert=function(e,t,i){return{range:{start:e,end:e},newText:t,annotationId:i}},G.del=function(e,t){return{range:e,newText:"",annotationId:t}},G.is=function(e){var t=e;return z.is(t)&&(U.is(t.annotationId)||K.is(t.annotationId))},(Y=Z||(Z={})).create=function(e,t){return{textDocument:e,edits:t}},Y.is=function(e){var t=e;return ot.defined(t)&&ce.is(t.textDocument)&&Array.isArray(t.edits)},(X=Q||(Q={})).create=function(e,t,i){var n={kind:"create",uri:e};return void 0===t||void 0===t.overwrite&&void 0===t.ignoreIfExists||(n.options=t),void 0!==i&&(n.annotationId=i),n},X.is=function(e){var t=e;return t&&"create"===t.kind&&ot.string(t.uri)&&(void 0===t.options||(void 0===t.options.overwrite||ot.boolean(t.options.overwrite))&&(void 0===t.options.ignoreIfExists||ot.boolean(t.options.ignoreIfExists)))&&(void 0===t.annotationId||K.is(t.annotationId))},(ee=J||(J={})).create=function(e,t,i,n){var o={kind:"rename",oldUri:e,newUri:t};return void 0===i||void 0===i.overwrite&&void 0===i.ignoreIfExists||(o.options=i),void 0!==n&&(o.annotationId=n),o},ee.is=function(e){var t=e;return t&&"rename"===t.kind&&ot.string(t.oldUri)&&ot.string(t.newUri)&&(void 0===t.options||(void 0===t.options.overwrite||ot.boolean(t.options.overwrite))&&(void 0===t.options.ignoreIfExists||ot.boolean(t.options.ignoreIfExists)))&&(void 0===t.annotationId||K.is(t.annotationId))},(ie=te||(te={})).create=function(e,t,i){var n={kind:"delete",uri:e};return void 0===t||void 0===t.recursive&&void 0===t.ignoreIfNotExists||(n.options=t),void 0!==i&&(n.annotationId=i),n},ie.is=function(e){var t=e;return t&&"delete"===t.kind&&ot.string(t.uri)&&(void 0===t.options||(void 0===t.options.recursive||ot.boolean(t.options.recursive))&&(void 0===t.options.ignoreIfNotExists||ot.boolean(t.options.ignoreIfNotExists)))&&(void 0===t.annotationId||K.is(t.annotationId))},(ne||(ne={})).is=function(e){var t=e;return t&&(void 0!==t.changes||void 0!==t.documentChanges)&&(void 0===t.documentChanges||t.documentChanges.every((function(e){return ot.string(e.kind)?Q.is(e)||J.is(e)||te.is(e):Z.is(e)})))};var re,se,ae,le,ce,de,ue,he,ge,pe,me,fe,_e,be,ve,Ce,we,ye,Se,xe,ke,Le,Ee,Ne,De,Ie,Te,Ae,Re,Me,Oe,Pe,Fe,Be,We,Ve,He,ze,$e,Ue,je,Ke,qe,Ge,Ze,Ye,Qe,Xe,Je,et,tt,it=function(){function e(e,t){this.edits=e,this.changeAnnotations=t}return e.prototype.insert=function(e,t,i){var n,o;if(void 0===i?n=z.insert(e,t):K.is(i)?(o=i,n=q.insert(e,t,i)):(this.assertChangeAnnotations(this.changeAnnotations),o=this.changeAnnotations.manage(i),n=q.insert(e,t,o)),this.edits.push(n),void 0!==o)return o},e.prototype.replace=function(e,t,i){var n,o;if(void 0===i?n=z.replace(e,t):K.is(i)?(o=i,n=q.replace(e,t,i)):(this.assertChangeAnnotations(this.changeAnnotations),o=this.changeAnnotations.manage(i),n=q.replace(e,t,o)),this.edits.push(n),void 0!==o)return o},e.prototype.delete=function(e,t){var i,n;if(void 0===t?i=z.del(e):K.is(t)?(n=t,i=q.del(e,t)):(this.assertChangeAnnotations(this.changeAnnotations),n=this.changeAnnotations.manage(t),i=q.del(e,n)),this.edits.push(i),void 0!==n)return n},e.prototype.add=function(e){this.edits.push(e)},e.prototype.all=function(){return this.edits},e.prototype.clear=function(){this.edits.splice(0,this.edits.length)},e.prototype.assertChangeAnnotations=function(e){if(void 0===e)throw new Error("Text edit change is not configured to manage change annotations.")},e}(),nt=function(){function e(e){this._annotations=void 0===e?Object.create(null):e,this._counter=0,this._size=0}return e.prototype.all=function(){return this._annotations},Object.defineProperty(e.prototype,"size",{get:function(){return this._size},enumerable:!1,configurable:!0}),e.prototype.manage=function(e,t){var i;if(K.is(e)?i=e:(i=this.nextId(),t=e),void 0!==this._annotations[i])throw new Error("Id "+i+" is already in use.");if(void 0===t)throw new Error("No annotation provided for id "+i);return this._annotations[i]=t,this._size++,i},e.prototype.nextId=function(){return this._counter++,this._counter.toString()},e}();!function(){function e(e){var t=this;this._textEditChanges=Object.create(null),void 0!==e?(this._workspaceEdit=e,e.documentChanges?(this._changeAnnotations=new nt(e.changeAnnotations),e.changeAnnotations=this._changeAnnotations.all(),e.documentChanges.forEach((function(e){if(Z.is(e)){var i=new it(e.edits,t._changeAnnotations);t._textEditChanges[e.textDocument.uri]=i}}))):e.changes&&Object.keys(e.changes).forEach((function(i){var n=new it(e.changes[i]);t._textEditChanges[i]=n}))):this._workspaceEdit={}}Object.defineProperty(e.prototype,"edit",{get:function(){return this.initDocumentChanges(),void 0!==this._changeAnnotations&&(0===this._changeAnnotations.size?this._workspaceEdit.changeAnnotations=void 0:this._workspaceEdit.changeAnnotations=this._changeAnnotations.all()),this._workspaceEdit},enumerable:!1,configurable:!0}),e.prototype.getTextEditChange=function(e){if(ce.is(e)){if(this.initDocumentChanges(),void 0===this._workspaceEdit.documentChanges)throw new Error("Workspace edit is not configured for document changes.");var t={uri:e.uri,version:e.version};if(!(n=this._textEditChanges[t.uri])){var i={textDocument:t,edits:o=[]};this._workspaceEdit.documentChanges.push(i),n=new it(o,this._changeAnnotations),this._textEditChanges[t.uri]=n}return n}if(this.initChanges(),void 0===this._workspaceEdit.changes)throw new Error("Workspace edit is not configured for normal text edit changes.");var n;if(!(n=this._textEditChanges[e])){var o=[];this._workspaceEdit.changes[e]=o,n=new it(o),this._textEditChanges[e]=n}return n},e.prototype.initDocumentChanges=function(){void 0===this._workspaceEdit.documentChanges&&void 0===this._workspaceEdit.changes&&(this._changeAnnotations=new nt,this._workspaceEdit.documentChanges=[],this._workspaceEdit.changeAnnotations=this._changeAnnotations.all())},e.prototype.initChanges=function(){void 0===this._workspaceEdit.documentChanges&&void 0===this._workspaceEdit.changes&&(this._workspaceEdit.changes=Object.create(null))},e.prototype.createFile=function(e,t,i){if(this.initDocumentChanges(),void 0===this._workspaceEdit.documentChanges)throw new Error("Workspace edit is not configured for document changes.");var n,o,r;if(U.is(t)||K.is(t)?n=t:i=t,void 0===n?o=Q.create(e,i):(r=K.is(n)?n:this._changeAnnotations.manage(n),o=Q.create(e,i,r)),this._workspaceEdit.documentChanges.push(o),void 0!==r)return r},e.prototype.renameFile=function(e,t,i,n){if(this.initDocumentChanges(),void 0===this._workspaceEdit.documentChanges)throw new Error("Workspace edit is not configured for document changes.");var o,r,s;if(U.is(i)||K.is(i)?o=i:n=i,void 0===o?r=J.create(e,t,n):(s=K.is(o)?o:this._changeAnnotations.manage(o),r=J.create(e,t,n,s)),this._workspaceEdit.documentChanges.push(r),void 0!==s)return s},e.prototype.deleteFile=function(e,t,i){if(this.initDocumentChanges(),void 0===this._workspaceEdit.documentChanges)throw new Error("Workspace edit is not configured for document changes.");var n,o,r;if(U.is(t)||K.is(t)?n=t:i=t,void 0===n?o=te.create(e,i):(r=K.is(n)?n:this._changeAnnotations.manage(n),o=te.create(e,i,r)),this._workspaceEdit.documentChanges.push(o),void 0!==r)return r}}(),(se=re||(re={})).create=function(e){return{uri:e}},se.is=function(e){var t=e;return ot.defined(t)&&ot.string(t.uri)},(le=ae||(ae={})).create=function(e,t){return{uri:e,version:t}},le.is=function(e){var t=e;return ot.defined(t)&&ot.string(t.uri)&&ot.integer(t.version)},(de=ce||(ce={})).create=function(e,t){return{uri:e,version:t}},de.is=function(e){var t=e;return ot.defined(t)&&ot.string(t.uri)&&(null===t.version||ot.integer(t.version))},(he=ue||(ue={})).create=function(e,t,i,n){return{uri:e,languageId:t,version:i,text:n}},he.is=function(e){var t=e;return ot.defined(t)&&ot.string(t.uri)&&ot.string(t.languageId)&&ot.integer(t.version)&&ot.string(t.text)},(pe=ge||(ge={})).PlainText="plaintext",pe.Markdown="markdown",function(e){e.is=function(t){var i=t;return i===e.PlainText||i===e.Markdown}}(ge||(ge={})),(me||(me={})).is=function(e){var t=e;return ot.objectLiteral(e)&&ge.is(t.kind)&&ot.string(t.value)},(_e=fe||(fe={})).Text=1,_e.Method=2,_e.Function=3,_e.Constructor=4,_e.Field=5,_e.Variable=6,_e.Class=7,_e.Interface=8,_e.Module=9,_e.Property=10,_e.Unit=11,_e.Value=12,_e.Enum=13,_e.Keyword=14,_e.Snippet=15,_e.Color=16,_e.File=17,_e.Reference=18,_e.Folder=19,_e.EnumMember=20,_e.Constant=21,_e.Struct=22,_e.Event=23,_e.Operator=24,_e.TypeParameter=25,(ve=be||(be={})).PlainText=1,ve.Snippet=2,(Ce||(Ce={})).Deprecated=1,(ye=we||(we={})).create=function(e,t,i){return{newText:e,insert:t,replace:i}},ye.is=function(e){var t=e;return t&&ot.string(t.newText)&&m.is(t.insert)&&m.is(t.replace)},(xe=Se||(Se={})).asIs=1,xe.adjustIndentation=2,(ke||(ke={})).create=function(e){return{label:e}},(Le||(Le={})).create=function(e,t){return{items:e||[],isIncomplete:!!t}},(Ne=Ee||(Ee={})).fromPlainText=function(e){return e.replace(/[\\`*_{}[\]()#+\-.!]/g,"\\$&")},Ne.is=function(e){var t=e;return ot.string(t)||ot.objectLiteral(t)&&ot.string(t.language)&&ot.string(t.value)},(De||(De={})).is=function(e){var t=e;return!!t&&ot.objectLiteral(t)&&(me.is(t.contents)||Ee.is(t.contents)||ot.typedArray(t.contents,Ee.is))&&(void 0===e.range||m.is(e.range))},(Ie||(Ie={})).create=function(e,t){return t?{label:e,documentation:t}:{label:e}},(Te||(Te={})).create=function(e,t){for(var i=[],n=2;n=0;s--){var a=o[s],l=e.offsetAt(a.range.start),c=e.offsetAt(a.range.end);if(!(c<=r))throw new Error("Overlapping edit");n=n.substring(0,l)+a.newText+n.substring(c,n.length),r=l}return n}}(tt||(tt={}));var ot,rt,st,at=function(){function e(e,t,i,n){this._uri=e,this._languageId=t,this._version=i,this._content=n,this._lineOffsets=void 0}return Object.defineProperty(e.prototype,"uri",{get:function(){return this._uri},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"languageId",{get:function(){return this._languageId},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"version",{get:function(){return this._version},enumerable:!1,configurable:!0}),e.prototype.getText=function(e){if(e){var t=this.offsetAt(e.start),i=this.offsetAt(e.end);return this._content.substring(t,i)}return this._content},e.prototype.update=function(e,t){this._content=e.text,this._version=t,this._lineOffsets=void 0},e.prototype.getLineOffsets=function(){if(void 0===this._lineOffsets){for(var e=[],t=this._content,i=!0,n=0;n0&&e.push(t.length),this._lineOffsets=e}return this._lineOffsets},e.prototype.positionAt=function(e){e=Math.max(Math.min(e,this._content.length),0);var t=this.getLineOffsets(),i=0,n=t.length;if(0===n)return g.create(0,e);for(;ie?n=o:i=o+1}var r=i-1;return g.create(r,e-t[r])},e.prototype.offsetAt=function(e){var t=this.getLineOffsets();if(e.line>=t.length)return this._content.length;if(e.line<0)return 0;var i=t[e.line],n=e.line+1{let t,i=e.getLanguageId();i===this._languageId&&(this._listener[e.uri.toString()]=e.onDidChangeContent((()=>{window.clearTimeout(t),t=window.setTimeout((()=>this._doValidate(e.uri,i)),500)})),this._doValidate(e.uri,i))},o=e=>{l.editor.setModelMarkers(e,this._languageId,[]);let t=e.uri.toString(),i=this._listener[t];i&&(i.dispose(),delete this._listener[t])};this._disposables.push(l.editor.onDidCreateModel(n)),this._disposables.push(l.editor.onWillDisposeModel(o)),this._disposables.push(l.editor.onDidChangeModelLanguage((e=>{o(e.model),n(e.model)}))),this._disposables.push(i((e=>{l.editor.getModels().forEach((e=>{e.getLanguageId()===this._languageId&&(o(e),n(e))}))}))),this._disposables.push({dispose:()=>{l.editor.getModels().forEach(o);for(let e in this._listener)this._listener[e].dispose()}}),l.editor.getModels().forEach(n)}_disposables=[];_listener=Object.create(null);dispose(){this._disposables.forEach((e=>e&&e.dispose())),this._disposables.length=0}_doValidate(e,t){this._worker(e).then((t=>t.doValidation(e.toString()))).then((i=>{const n=i.map((e=>function(e,t){let i="number"==typeof t.code?String(t.code):t.code;return{severity:ct(t.severity),startLineNumber:t.range.start.line+1,startColumn:t.range.start.character+1,endLineNumber:t.range.end.line+1,endColumn:t.range.end.character+1,message:t.message,code:i,source:t.source}}(0,e)));let o=l.editor.getModel(e);o&&o.getLanguageId()===t&&l.editor.setModelMarkers(o,t,n)})).then(void 0,(e=>{console.error(e)}))}};function ct(e){switch(e){case R.Error:return l.MarkerSeverity.Error;case R.Warning:return l.MarkerSeverity.Warning;case R.Information:return l.MarkerSeverity.Info;case R.Hint:return l.MarkerSeverity.Hint;default:return l.MarkerSeverity.Info}}var dt=class{constructor(e,t){this._worker=e,this._triggerCharacters=t}get triggerCharacters(){return this._triggerCharacters}provideCompletionItems(e,t,i,n){const o=e.uri;return this._worker(o).then((e=>e.doComplete(o.toString(),ut(t)))).then((i=>{if(!i)return;const n=e.getWordUntilPosition(t),o=new l.Range(t.lineNumber,n.startColumn,t.lineNumber,n.endColumn),r=i.items.map((e=>{const t={label:e.label,insertText:e.insertText||e.label,sortText:e.sortText,filterText:e.filterText,documentation:e.documentation,detail:e.detail,command:(i=e.command,i&&"editor.action.triggerSuggest"===i.command?{id:i.command,title:i.title,arguments:i.arguments}:void 0),range:o,kind:pt(e.kind)};var i,n;return e.textEdit&&(void 0!==(n=e.textEdit).insert&&void 0!==n.replace?t.range={insert:gt(e.textEdit.insert),replace:gt(e.textEdit.replace)}:t.range=gt(e.textEdit.range),t.insertText=e.textEdit.newText),e.additionalTextEdits&&(t.additionalTextEdits=e.additionalTextEdits.map(mt)),e.insertTextFormat===be.Snippet&&(t.insertTextRules=l.languages.CompletionItemInsertTextRule.InsertAsSnippet),t}));return{isIncomplete:i.isIncomplete,suggestions:r}}))}};function ut(e){if(e)return{character:e.column-1,line:e.lineNumber-1}}function ht(e){if(e)return{start:{line:e.startLineNumber-1,character:e.startColumn-1},end:{line:e.endLineNumber-1,character:e.endColumn-1}}}function gt(e){if(e)return new l.Range(e.start.line+1,e.start.character+1,e.end.line+1,e.end.character+1)}function pt(e){const t=l.languages.CompletionItemKind;switch(e){case fe.Text:return t.Text;case fe.Method:return t.Method;case fe.Function:return t.Function;case fe.Constructor:return t.Constructor;case fe.Field:return t.Field;case fe.Variable:return t.Variable;case fe.Class:return t.Class;case fe.Interface:return t.Interface;case fe.Module:return t.Module;case fe.Property:return t.Property;case fe.Unit:return t.Unit;case fe.Value:return t.Value;case fe.Enum:return t.Enum;case fe.Keyword:return t.Keyword;case fe.Snippet:return t.Snippet;case fe.Color:return t.Color;case fe.File:return t.File;case fe.Reference:return t.Reference}return t.Property}function mt(e){if(e)return{range:gt(e.range),text:e.newText}}var ft=class{constructor(e){this._worker=e}provideHover(e,t,i){let n=e.uri;return this._worker(n).then((e=>e.doHover(n.toString(),ut(t)))).then((e=>{if(e)return{range:gt(e.range),contents:bt(e.contents)}}))}};function _t(e){return"string"==typeof e?{value:e}:(t=e)&&"object"==typeof t&&"string"==typeof t.kind?"plaintext"===e.kind?{value:e.value.replace(/[\\`*_{}[\]()#+\-.!]/g,"\\$&")}:{value:e.value}:{value:"```"+e.language+"\n"+e.value+"\n```\n"};var t}function bt(e){if(e)return Array.isArray(e)?e.map(_t):[_t(e)]}var vt=class{constructor(e){this._worker=e}provideDocumentHighlights(e,t,i){const n=e.uri;return this._worker(n).then((e=>e.findDocumentHighlights(n.toString(),ut(t)))).then((e=>{if(e)return e.map((e=>({range:gt(e.range),kind:Ct(e.kind)})))}))}};function Ct(e){switch(e){case Ae.Read:return l.languages.DocumentHighlightKind.Read;case Ae.Write:return l.languages.DocumentHighlightKind.Write;case Ae.Text:return l.languages.DocumentHighlightKind.Text}return l.languages.DocumentHighlightKind.Text}var wt=class{constructor(e){this._worker=e}provideDefinition(e,t,i){const n=e.uri;return this._worker(n).then((e=>e.findDefinition(n.toString(),ut(t)))).then((e=>{if(e)return[yt(e)]}))}};function yt(e){return{uri:l.Uri.parse(e.uri),range:gt(e.range)}}var St=class{constructor(e){this._worker=e}provideReferences(e,t,i,n){const o=e.uri;return this._worker(o).then((e=>e.findReferences(o.toString(),ut(t)))).then((e=>{if(e)return e.map(yt)}))}},xt=class{constructor(e){this._worker=e}provideRenameEdits(e,t,i,n){const o=e.uri;return this._worker(o).then((e=>e.doRename(o.toString(),ut(t),i))).then((e=>function(e){if(!e||!e.changes)return;let t=[];for(let i in e.changes){const n=l.Uri.parse(i);for(let o of e.changes[i])t.push({resource:n,edit:{range:gt(o.range),text:o.newText}})}return{edits:t}}(e)))}},kt=class{constructor(e){this._worker=e}provideDocumentSymbols(e,t){const i=e.uri;return this._worker(i).then((e=>e.findDocumentSymbols(i.toString()))).then((e=>{if(e)return e.map((e=>({name:e.name,detail:"",containerName:e.containerName,kind:Lt(e.kind),range:gt(e.location.range),selectionRange:gt(e.location.range),tags:[]})))}))}};function Lt(e){let t=l.languages.SymbolKind;switch(e){case Oe.File:return t.Array;case Oe.Module:return t.Module;case Oe.Namespace:return t.Namespace;case Oe.Package:return t.Package;case Oe.Class:return t.Class;case Oe.Method:return t.Method;case Oe.Property:return t.Property;case Oe.Field:return t.Field;case Oe.Constructor:return t.Constructor;case Oe.Enum:return t.Enum;case Oe.Interface:return t.Interface;case Oe.Function:return t.Function;case Oe.Variable:return t.Variable;case Oe.Constant:return t.Constant;case Oe.String:return t.String;case Oe.Number:return t.Number;case Oe.Boolean:return t.Boolean;case Oe.Array:return t.Array}return t.Function}var Et=class{constructor(e){this._worker=e}provideLinks(e,t){const i=e.uri;return this._worker(i).then((e=>e.findDocumentLinks(i.toString()))).then((e=>{if(e)return{links:e.map((e=>({range:gt(e.range),url:e.target})))}}))}},Nt=class{constructor(e){this._worker=e}provideDocumentFormattingEdits(e,t,i){const n=e.uri;return this._worker(n).then((e=>e.format(n.toString(),null,It(t)).then((e=>{if(e&&0!==e.length)return e.map(mt)}))))}},Dt=class{constructor(e){this._worker=e}provideDocumentRangeFormattingEdits(e,t,i,n){const o=e.uri;return this._worker(o).then((e=>e.format(o.toString(),ht(t),It(i)).then((e=>{if(e&&0!==e.length)return e.map(mt)}))))}};function It(e){return{tabSize:e.tabSize,insertSpaces:e.insertSpaces}}var Tt=class{constructor(e){this._worker=e}provideDocumentColors(e,t){const i=e.uri;return this._worker(i).then((e=>e.findDocumentColors(i.toString()))).then((e=>{if(e)return e.map((e=>({color:e.color,range:gt(e.range)})))}))}provideColorPresentations(e,t,i){const n=e.uri;return this._worker(n).then((e=>e.getColorPresentations(n.toString(),t.color,ht(t.range)))).then((e=>{if(e)return e.map((e=>{let t={label:e.label};return e.textEdit&&(t.textEdit=mt(e.textEdit)),e.additionalTextEdits&&(t.additionalTextEdits=e.additionalTextEdits.map(mt)),t}))}))}},At=class{constructor(e){this._worker=e}provideFoldingRanges(e,t,i){const n=e.uri;return this._worker(n).then((e=>e.getFoldingRanges(n.toString(),t))).then((e=>{if(e)return e.map((e=>{const t={start:e.startLine+1,end:e.endLine+1};return void 0!==e.kind&&(t.kind=function(e){switch(e){case E.Comment:return l.languages.FoldingRangeKind.Comment;case E.Imports:return l.languages.FoldingRangeKind.Imports;case E.Region:return l.languages.FoldingRangeKind.Region}}(e.kind)),t}))}))}},Rt=class{constructor(e){this._worker=e}provideSelectionRanges(e,t,i){const n=e.uri;return this._worker(n).then((e=>e.getSelectionRanges(n.toString(),t.map(ut)))).then((e=>{if(e)return e.map((e=>{const t=[];for(;e;)t.push({range:gt(e.range)}),e=e.parent;return t}))}))}},Mt=class extends dt{constructor(e){super(e,[".",":","<",'"',"=","/"])}};function Ot(e){const t=new oe(e),i=(...e)=>t.getLanguageServiceWorker(...e);let n=e.languageId;l.languages.registerCompletionItemProvider(n,new Mt(i)),l.languages.registerHoverProvider(n,new ft(i)),l.languages.registerDocumentHighlightProvider(n,new vt(i)),l.languages.registerLinkProvider(n,new Et(i)),l.languages.registerFoldingRangeProvider(n,new At(i)),l.languages.registerDocumentSymbolProvider(n,new kt(i)),l.languages.registerSelectionRangeProvider(n,new Rt(i)),l.languages.registerRenameProvider(n,new xt(i)),"html"===n&&(l.languages.registerDocumentFormattingEditProvider(n,new Nt(i)),l.languages.registerDocumentRangeFormattingEditProvider(n,new Dt(i)))}function Pt(e){const t=[],i=[],n=new oe(e);t.push(n);const o=(...e)=>n.getLanguageServiceWorker(...e);return function(){const{languageId:t,modeConfiguration:n}=e;Bt(i),n.completionItems&&i.push(l.languages.registerCompletionItemProvider(t,new Mt(o))),n.hovers&&i.push(l.languages.registerHoverProvider(t,new ft(o))),n.documentHighlights&&i.push(l.languages.registerDocumentHighlightProvider(t,new vt(o))),n.links&&i.push(l.languages.registerLinkProvider(t,new Et(o))),n.documentSymbols&&i.push(l.languages.registerDocumentSymbolProvider(t,new kt(o))),n.rename&&i.push(l.languages.registerRenameProvider(t,new xt(o))),n.foldingRanges&&i.push(l.languages.registerFoldingRangeProvider(t,new At(o))),n.selectionRanges&&i.push(l.languages.registerSelectionRangeProvider(t,new Rt(o))),n.documentFormattingEdits&&i.push(l.languages.registerDocumentFormattingEditProvider(t,new Nt(o))),n.documentRangeFormattingEdits&&i.push(l.languages.registerDocumentRangeFormattingEditProvider(t,new Dt(o)))}(),t.push(Ft(i)),Ft(t)}function Ft(e){return{dispose:()=>Bt(e)}}function Bt(e){for(;e.length;)e.pop().dispose()}},72080:function(e,t,i){"use strict";i.r(t),i.d(t,{handlebarDefaults:function(){return _},handlebarLanguageService:function(){return f},htmlDefaults:function(){return m},htmlLanguageService:function(){return p},razorDefaults:function(){return v},razorLanguageService:function(){return b},registerHTMLLanguageService:function(){return C}});var n=i(54918),o=Object.defineProperty,r=Object.getOwnPropertyDescriptor,s=Object.getOwnPropertyNames,a=Object.prototype.hasOwnProperty,l={};((e,t,i,n)=>{if(t&&"object"==typeof t||"function"==typeof t)for(let i of s(t))a.call(e,i)||"default"===i||o(e,i,{get:()=>t[i],enumerable:!(n=r(t,i))||n.enumerable})})(l,n);var c={format:{tabSize:4,insertSpaces:!1,wrapLineLength:120,unformatted:'default": "a, abbr, acronym, b, bdo, big, br, button, cite, code, dfn, em, i, img, input, kbd, label, map, object, q, samp, select, small, span, strong, sub, sup, textarea, tt, var',contentUnformatted:"pre",indentInnerHtml:!1,preserveNewLines:!0,maxPreserveNewLines:void 0,indentHandlebars:!1,endWithNewline:!1,extraLiners:"head, body, /html",wrapAttributes:"auto"},suggest:{},data:{useDefaultDataProvider:!0}};function d(e){return{completionItems:!0,hovers:!0,documentSymbols:!0,links:!0,documentHighlights:!0,rename:!0,colors:!0,foldingRanges:!0,selectionRanges:!0,diagnostics:e===u,documentFormattingEdits:e===u,documentRangeFormattingEdits:e===u}}var u="html",h="handlebars",g="razor",p=C(u,c,d(u)),m=p.defaults,f=C(h,c,d(h)),_=f.defaults,b=C(g,c,d(g)),v=b.defaults;function C(e,t=c,n=d(e)){const o=new class{_onDidChange=new l.Emitter;_options;_modeConfiguration;_languageId;constructor(e,t,i){this._languageId=e,this.setOptions(t),this.setModeConfiguration(i)}get onDidChange(){return this._onDidChange.event}get languageId(){return this._languageId}get options(){return this._options}get modeConfiguration(){return this._modeConfiguration}setOptions(e){this._options=e||Object.create(null),this._onDidChange.fire(this)}setModeConfiguration(e){this._modeConfiguration=e||Object.create(null),this._onDidChange.fire(this)}}(e,t,n);let r;const s=l.languages.onLanguage(e,(async()=>{r=(await Promise.resolve().then(i.bind(i,36150))).setupMode(o)}));return{defaults:o,dispose(){s.dispose(),r?.dispose(),r=void 0}}}l.languages.html={htmlDefaults:m,razorDefaults:v,handlebarDefaults:_,htmlLanguageService:p,handlebarLanguageService:f,razorLanguageService:b,registerHTMLLanguageService:C}},50104:function(e,t,i){"use strict";i.r(t),i.d(t,{CompletionAdapter:function(){return dt},DefinitionAdapter:function(){return wt},DiagnosticsAdapter:function(){return lt},DocumentColorAdapter:function(){return At},DocumentFormattingEditProvider:function(){return Nt},DocumentHighlightAdapter:function(){return vt},DocumentLinkAdapter:function(){return Et},DocumentRangeFormattingEditProvider:function(){return Dt},DocumentSymbolAdapter:function(){return kt},FoldingRangeAdapter:function(){return Rt},HoverAdapter:function(){return ft},ReferenceAdapter:function(){return St},RenameAdapter:function(){return xt},SelectionRangeAdapter:function(){return Mt},WorkerManager:function(){return oe},fromPosition:function(){return ut},fromRange:function(){return ht},setupMode:function(){return Jt},toRange:function(){return gt},toTextEdit:function(){return mt}});var n=i(54918),o=Object.defineProperty,r=Object.getOwnPropertyDescriptor,s=Object.getOwnPropertyNames,a=Object.prototype.hasOwnProperty,l={};((e,t,i,n)=>{if(t&&"object"==typeof t||"function"==typeof t)for(let i of s(t))a.call(e,i)||"default"===i||o(e,i,{get:()=>t[i],enumerable:!(n=r(t,i))||n.enumerable})})(l,n);var c,d,u,h,g,p,m,f,_,b,v,C,w,y,S,x,k,L,E,N,D,I,T,A,R,M,O,P,F,B,W,V,H,z,$,U,j,K,q,G,Z,Y,Q,X,J,ee,te,ie,ne,oe=class{_defaults;_idleCheckInterval;_lastUsedTime;_configChangeListener;_worker;_client;constructor(e){this._defaults=e,this._worker=null,this._client=null,this._idleCheckInterval=window.setInterval((()=>this._checkIfIdle()),3e4),this._lastUsedTime=0,this._configChangeListener=this._defaults.onDidChange((()=>this._stopWorker()))}_stopWorker(){this._worker&&(this._worker.dispose(),this._worker=null),this._client=null}dispose(){clearInterval(this._idleCheckInterval),this._configChangeListener.dispose(),this._stopWorker()}_checkIfIdle(){this._worker&&Date.now()-this._lastUsedTime>12e4&&this._stopWorker()}_getClient(){return this._lastUsedTime=Date.now(),this._client||(this._worker=l.editor.createWebWorker({moduleId:"vs/language/json/jsonWorker",label:this._defaults.languageId,createData:{languageSettings:this._defaults.diagnosticsOptions,languageId:this._defaults.languageId,enableSchemaRequest:this._defaults.diagnosticsOptions.enableSchemaRequest}}),this._client=this._worker.getProxy()),this._client}getLanguageServiceWorker(...e){let t;return this._getClient().then((e=>{t=e})).then((t=>{if(this._worker)return this._worker.withSyncedResources(e)})).then((e=>t))}};(d=c||(c={})).MIN_VALUE=-2147483648,d.MAX_VALUE=2147483647,(h=u||(u={})).MIN_VALUE=0,h.MAX_VALUE=2147483647,(p=g||(g={})).create=function(e,t){return e===Number.MAX_VALUE&&(e=u.MAX_VALUE),t===Number.MAX_VALUE&&(t=u.MAX_VALUE),{line:e,character:t}},p.is=function(e){var t=e;return ot.objectLiteral(t)&&ot.uinteger(t.line)&&ot.uinteger(t.character)},(f=m||(m={})).create=function(e,t,i,n){if(ot.uinteger(e)&&ot.uinteger(t)&&ot.uinteger(i)&&ot.uinteger(n))return{start:g.create(e,t),end:g.create(i,n)};if(g.is(e)&&g.is(t))return{start:e,end:t};throw new Error("Range#create called with invalid arguments["+e+", "+t+", "+i+", "+n+"]")},f.is=function(e){var t=e;return ot.objectLiteral(t)&&g.is(t.start)&&g.is(t.end)},(b=_||(_={})).create=function(e,t){return{uri:e,range:t}},b.is=function(e){var t=e;return ot.defined(t)&&m.is(t.range)&&(ot.string(t.uri)||ot.undefined(t.uri))},(C=v||(v={})).create=function(e,t,i,n){return{targetUri:e,targetRange:t,targetSelectionRange:i,originSelectionRange:n}},C.is=function(e){var t=e;return ot.defined(t)&&m.is(t.targetRange)&&ot.string(t.targetUri)&&(m.is(t.targetSelectionRange)||ot.undefined(t.targetSelectionRange))&&(m.is(t.originSelectionRange)||ot.undefined(t.originSelectionRange))},(y=w||(w={})).create=function(e,t,i,n){return{red:e,green:t,blue:i,alpha:n}},y.is=function(e){var t=e;return ot.numberRange(t.red,0,1)&&ot.numberRange(t.green,0,1)&&ot.numberRange(t.blue,0,1)&&ot.numberRange(t.alpha,0,1)},(x=S||(S={})).create=function(e,t){return{range:e,color:t}},x.is=function(e){var t=e;return m.is(t.range)&&w.is(t.color)},(L=k||(k={})).create=function(e,t,i){return{label:e,textEdit:t,additionalTextEdits:i}},L.is=function(e){var t=e;return ot.string(t.label)&&(ot.undefined(t.textEdit)||z.is(t))&&(ot.undefined(t.additionalTextEdits)||ot.typedArray(t.additionalTextEdits,z.is))},(N=E||(E={})).Comment="comment",N.Imports="imports",N.Region="region",(I=D||(D={})).create=function(e,t,i,n,o){var r={startLine:e,endLine:t};return ot.defined(i)&&(r.startCharacter=i),ot.defined(n)&&(r.endCharacter=n),ot.defined(o)&&(r.kind=o),r},I.is=function(e){var t=e;return ot.uinteger(t.startLine)&&ot.uinteger(t.startLine)&&(ot.undefined(t.startCharacter)||ot.uinteger(t.startCharacter))&&(ot.undefined(t.endCharacter)||ot.uinteger(t.endCharacter))&&(ot.undefined(t.kind)||ot.string(t.kind))},(A=T||(T={})).create=function(e,t){return{location:e,message:t}},A.is=function(e){var t=e;return ot.defined(t)&&_.is(t.location)&&ot.string(t.message)},(M=R||(R={})).Error=1,M.Warning=2,M.Information=3,M.Hint=4,(P=O||(O={})).Unnecessary=1,P.Deprecated=2,(F||(F={})).is=function(e){var t=e;return null!=t&&ot.string(t.href)},(W=B||(B={})).create=function(e,t,i,n,o,r){var s={range:e,message:t};return ot.defined(i)&&(s.severity=i),ot.defined(n)&&(s.code=n),ot.defined(o)&&(s.source=o),ot.defined(r)&&(s.relatedInformation=r),s},W.is=function(e){var t,i=e;return ot.defined(i)&&m.is(i.range)&&ot.string(i.message)&&(ot.number(i.severity)||ot.undefined(i.severity))&&(ot.integer(i.code)||ot.string(i.code)||ot.undefined(i.code))&&(ot.undefined(i.codeDescription)||ot.string(null===(t=i.codeDescription)||void 0===t?void 0:t.href))&&(ot.string(i.source)||ot.undefined(i.source))&&(ot.undefined(i.relatedInformation)||ot.typedArray(i.relatedInformation,T.is))},(H=V||(V={})).create=function(e,t){for(var i=[],n=2;n0&&(o.arguments=i),o},H.is=function(e){var t=e;return ot.defined(t)&&ot.string(t.title)&&ot.string(t.command)},($=z||(z={})).replace=function(e,t){return{range:e,newText:t}},$.insert=function(e,t){return{range:{start:e,end:e},newText:t}},$.del=function(e){return{range:e,newText:""}},$.is=function(e){var t=e;return ot.objectLiteral(t)&&ot.string(t.newText)&&m.is(t.range)},(j=U||(U={})).create=function(e,t,i){var n={label:e};return void 0!==t&&(n.needsConfirmation=t),void 0!==i&&(n.description=i),n},j.is=function(e){var t=e;return void 0!==t&&ot.objectLiteral(t)&&ot.string(t.label)&&(ot.boolean(t.needsConfirmation)||void 0===t.needsConfirmation)&&(ot.string(t.description)||void 0===t.description)},(K||(K={})).is=function(e){return"string"==typeof e},(G=q||(q={})).replace=function(e,t,i){return{range:e,newText:t,annotationId:i}},G.insert=function(e,t,i){return{range:{start:e,end:e},newText:t,annotationId:i}},G.del=function(e,t){return{range:e,newText:"",annotationId:t}},G.is=function(e){var t=e;return z.is(t)&&(U.is(t.annotationId)||K.is(t.annotationId))},(Y=Z||(Z={})).create=function(e,t){return{textDocument:e,edits:t}},Y.is=function(e){var t=e;return ot.defined(t)&&ce.is(t.textDocument)&&Array.isArray(t.edits)},(X=Q||(Q={})).create=function(e,t,i){var n={kind:"create",uri:e};return void 0===t||void 0===t.overwrite&&void 0===t.ignoreIfExists||(n.options=t),void 0!==i&&(n.annotationId=i),n},X.is=function(e){var t=e;return t&&"create"===t.kind&&ot.string(t.uri)&&(void 0===t.options||(void 0===t.options.overwrite||ot.boolean(t.options.overwrite))&&(void 0===t.options.ignoreIfExists||ot.boolean(t.options.ignoreIfExists)))&&(void 0===t.annotationId||K.is(t.annotationId))},(ee=J||(J={})).create=function(e,t,i,n){var o={kind:"rename",oldUri:e,newUri:t};return void 0===i||void 0===i.overwrite&&void 0===i.ignoreIfExists||(o.options=i),void 0!==n&&(o.annotationId=n),o},ee.is=function(e){var t=e;return t&&"rename"===t.kind&&ot.string(t.oldUri)&&ot.string(t.newUri)&&(void 0===t.options||(void 0===t.options.overwrite||ot.boolean(t.options.overwrite))&&(void 0===t.options.ignoreIfExists||ot.boolean(t.options.ignoreIfExists)))&&(void 0===t.annotationId||K.is(t.annotationId))},(ie=te||(te={})).create=function(e,t,i){var n={kind:"delete",uri:e};return void 0===t||void 0===t.recursive&&void 0===t.ignoreIfNotExists||(n.options=t),void 0!==i&&(n.annotationId=i),n},ie.is=function(e){var t=e;return t&&"delete"===t.kind&&ot.string(t.uri)&&(void 0===t.options||(void 0===t.options.recursive||ot.boolean(t.options.recursive))&&(void 0===t.options.ignoreIfNotExists||ot.boolean(t.options.ignoreIfNotExists)))&&(void 0===t.annotationId||K.is(t.annotationId))},(ne||(ne={})).is=function(e){var t=e;return t&&(void 0!==t.changes||void 0!==t.documentChanges)&&(void 0===t.documentChanges||t.documentChanges.every((function(e){return ot.string(e.kind)?Q.is(e)||J.is(e)||te.is(e):Z.is(e)})))};var re,se,ae,le,ce,de,ue,he,ge,pe,me,fe,_e,be,ve,Ce,we,ye,Se,xe,ke,Le,Ee,Ne,De,Ie,Te,Ae,Re,Me,Oe,Pe,Fe,Be,We,Ve,He,ze,$e,Ue,je,Ke,qe,Ge,Ze,Ye,Qe,Xe,Je,et,tt,it=function(){function e(e,t){this.edits=e,this.changeAnnotations=t}return e.prototype.insert=function(e,t,i){var n,o;if(void 0===i?n=z.insert(e,t):K.is(i)?(o=i,n=q.insert(e,t,i)):(this.assertChangeAnnotations(this.changeAnnotations),o=this.changeAnnotations.manage(i),n=q.insert(e,t,o)),this.edits.push(n),void 0!==o)return o},e.prototype.replace=function(e,t,i){var n,o;if(void 0===i?n=z.replace(e,t):K.is(i)?(o=i,n=q.replace(e,t,i)):(this.assertChangeAnnotations(this.changeAnnotations),o=this.changeAnnotations.manage(i),n=q.replace(e,t,o)),this.edits.push(n),void 0!==o)return o},e.prototype.delete=function(e,t){var i,n;if(void 0===t?i=z.del(e):K.is(t)?(n=t,i=q.del(e,t)):(this.assertChangeAnnotations(this.changeAnnotations),n=this.changeAnnotations.manage(t),i=q.del(e,n)),this.edits.push(i),void 0!==n)return n},e.prototype.add=function(e){this.edits.push(e)},e.prototype.all=function(){return this.edits},e.prototype.clear=function(){this.edits.splice(0,this.edits.length)},e.prototype.assertChangeAnnotations=function(e){if(void 0===e)throw new Error("Text edit change is not configured to manage change annotations.")},e}(),nt=function(){function e(e){this._annotations=void 0===e?Object.create(null):e,this._counter=0,this._size=0}return e.prototype.all=function(){return this._annotations},Object.defineProperty(e.prototype,"size",{get:function(){return this._size},enumerable:!1,configurable:!0}),e.prototype.manage=function(e,t){var i;if(K.is(e)?i=e:(i=this.nextId(),t=e),void 0!==this._annotations[i])throw new Error("Id "+i+" is already in use.");if(void 0===t)throw new Error("No annotation provided for id "+i);return this._annotations[i]=t,this._size++,i},e.prototype.nextId=function(){return this._counter++,this._counter.toString()},e}();!function(){function e(e){var t=this;this._textEditChanges=Object.create(null),void 0!==e?(this._workspaceEdit=e,e.documentChanges?(this._changeAnnotations=new nt(e.changeAnnotations),e.changeAnnotations=this._changeAnnotations.all(),e.documentChanges.forEach((function(e){if(Z.is(e)){var i=new it(e.edits,t._changeAnnotations);t._textEditChanges[e.textDocument.uri]=i}}))):e.changes&&Object.keys(e.changes).forEach((function(i){var n=new it(e.changes[i]);t._textEditChanges[i]=n}))):this._workspaceEdit={}}Object.defineProperty(e.prototype,"edit",{get:function(){return this.initDocumentChanges(),void 0!==this._changeAnnotations&&(0===this._changeAnnotations.size?this._workspaceEdit.changeAnnotations=void 0:this._workspaceEdit.changeAnnotations=this._changeAnnotations.all()),this._workspaceEdit},enumerable:!1,configurable:!0}),e.prototype.getTextEditChange=function(e){if(ce.is(e)){if(this.initDocumentChanges(),void 0===this._workspaceEdit.documentChanges)throw new Error("Workspace edit is not configured for document changes.");var t={uri:e.uri,version:e.version};if(!(n=this._textEditChanges[t.uri])){var i={textDocument:t,edits:o=[]};this._workspaceEdit.documentChanges.push(i),n=new it(o,this._changeAnnotations),this._textEditChanges[t.uri]=n}return n}if(this.initChanges(),void 0===this._workspaceEdit.changes)throw new Error("Workspace edit is not configured for normal text edit changes.");var n;if(!(n=this._textEditChanges[e])){var o=[];this._workspaceEdit.changes[e]=o,n=new it(o),this._textEditChanges[e]=n}return n},e.prototype.initDocumentChanges=function(){void 0===this._workspaceEdit.documentChanges&&void 0===this._workspaceEdit.changes&&(this._changeAnnotations=new nt,this._workspaceEdit.documentChanges=[],this._workspaceEdit.changeAnnotations=this._changeAnnotations.all())},e.prototype.initChanges=function(){void 0===this._workspaceEdit.documentChanges&&void 0===this._workspaceEdit.changes&&(this._workspaceEdit.changes=Object.create(null))},e.prototype.createFile=function(e,t,i){if(this.initDocumentChanges(),void 0===this._workspaceEdit.documentChanges)throw new Error("Workspace edit is not configured for document changes.");var n,o,r;if(U.is(t)||K.is(t)?n=t:i=t,void 0===n?o=Q.create(e,i):(r=K.is(n)?n:this._changeAnnotations.manage(n),o=Q.create(e,i,r)),this._workspaceEdit.documentChanges.push(o),void 0!==r)return r},e.prototype.renameFile=function(e,t,i,n){if(this.initDocumentChanges(),void 0===this._workspaceEdit.documentChanges)throw new Error("Workspace edit is not configured for document changes.");var o,r,s;if(U.is(i)||K.is(i)?o=i:n=i,void 0===o?r=J.create(e,t,n):(s=K.is(o)?o:this._changeAnnotations.manage(o),r=J.create(e,t,n,s)),this._workspaceEdit.documentChanges.push(r),void 0!==s)return s},e.prototype.deleteFile=function(e,t,i){if(this.initDocumentChanges(),void 0===this._workspaceEdit.documentChanges)throw new Error("Workspace edit is not configured for document changes.");var n,o,r;if(U.is(t)||K.is(t)?n=t:i=t,void 0===n?o=te.create(e,i):(r=K.is(n)?n:this._changeAnnotations.manage(n),o=te.create(e,i,r)),this._workspaceEdit.documentChanges.push(o),void 0!==r)return r}}(),(se=re||(re={})).create=function(e){return{uri:e}},se.is=function(e){var t=e;return ot.defined(t)&&ot.string(t.uri)},(le=ae||(ae={})).create=function(e,t){return{uri:e,version:t}},le.is=function(e){var t=e;return ot.defined(t)&&ot.string(t.uri)&&ot.integer(t.version)},(de=ce||(ce={})).create=function(e,t){return{uri:e,version:t}},de.is=function(e){var t=e;return ot.defined(t)&&ot.string(t.uri)&&(null===t.version||ot.integer(t.version))},(he=ue||(ue={})).create=function(e,t,i,n){return{uri:e,languageId:t,version:i,text:n}},he.is=function(e){var t=e;return ot.defined(t)&&ot.string(t.uri)&&ot.string(t.languageId)&&ot.integer(t.version)&&ot.string(t.text)},(pe=ge||(ge={})).PlainText="plaintext",pe.Markdown="markdown",function(e){e.is=function(t){var i=t;return i===e.PlainText||i===e.Markdown}}(ge||(ge={})),(me||(me={})).is=function(e){var t=e;return ot.objectLiteral(e)&&ge.is(t.kind)&&ot.string(t.value)},(_e=fe||(fe={})).Text=1,_e.Method=2,_e.Function=3,_e.Constructor=4,_e.Field=5,_e.Variable=6,_e.Class=7,_e.Interface=8,_e.Module=9,_e.Property=10,_e.Unit=11,_e.Value=12,_e.Enum=13,_e.Keyword=14,_e.Snippet=15,_e.Color=16,_e.File=17,_e.Reference=18,_e.Folder=19,_e.EnumMember=20,_e.Constant=21,_e.Struct=22,_e.Event=23,_e.Operator=24,_e.TypeParameter=25,(ve=be||(be={})).PlainText=1,ve.Snippet=2,(Ce||(Ce={})).Deprecated=1,(ye=we||(we={})).create=function(e,t,i){return{newText:e,insert:t,replace:i}},ye.is=function(e){var t=e;return t&&ot.string(t.newText)&&m.is(t.insert)&&m.is(t.replace)},(xe=Se||(Se={})).asIs=1,xe.adjustIndentation=2,(ke||(ke={})).create=function(e){return{label:e}},(Le||(Le={})).create=function(e,t){return{items:e||[],isIncomplete:!!t}},(Ne=Ee||(Ee={})).fromPlainText=function(e){return e.replace(/[\\`*_{}[\]()#+\-.!]/g,"\\$&")},Ne.is=function(e){var t=e;return ot.string(t)||ot.objectLiteral(t)&&ot.string(t.language)&&ot.string(t.value)},(De||(De={})).is=function(e){var t=e;return!!t&&ot.objectLiteral(t)&&(me.is(t.contents)||Ee.is(t.contents)||ot.typedArray(t.contents,Ee.is))&&(void 0===e.range||m.is(e.range))},(Ie||(Ie={})).create=function(e,t){return t?{label:e,documentation:t}:{label:e}},(Te||(Te={})).create=function(e,t){for(var i=[],n=2;n=0;s--){var a=o[s],l=e.offsetAt(a.range.start),c=e.offsetAt(a.range.end);if(!(c<=r))throw new Error("Overlapping edit");n=n.substring(0,l)+a.newText+n.substring(c,n.length),r=l}return n}}(tt||(tt={}));var ot,rt,st,at=function(){function e(e,t,i,n){this._uri=e,this._languageId=t,this._version=i,this._content=n,this._lineOffsets=void 0}return Object.defineProperty(e.prototype,"uri",{get:function(){return this._uri},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"languageId",{get:function(){return this._languageId},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"version",{get:function(){return this._version},enumerable:!1,configurable:!0}),e.prototype.getText=function(e){if(e){var t=this.offsetAt(e.start),i=this.offsetAt(e.end);return this._content.substring(t,i)}return this._content},e.prototype.update=function(e,t){this._content=e.text,this._version=t,this._lineOffsets=void 0},e.prototype.getLineOffsets=function(){if(void 0===this._lineOffsets){for(var e=[],t=this._content,i=!0,n=0;n0&&e.push(t.length),this._lineOffsets=e}return this._lineOffsets},e.prototype.positionAt=function(e){e=Math.max(Math.min(e,this._content.length),0);var t=this.getLineOffsets(),i=0,n=t.length;if(0===n)return g.create(0,e);for(;ie?n=o:i=o+1}var r=i-1;return g.create(r,e-t[r])},e.prototype.offsetAt=function(e){var t=this.getLineOffsets();if(e.line>=t.length)return this._content.length;if(e.line<0)return 0;var i=t[e.line],n=e.line+1{let t,i=e.getLanguageId();i===this._languageId&&(this._listener[e.uri.toString()]=e.onDidChangeContent((()=>{window.clearTimeout(t),t=window.setTimeout((()=>this._doValidate(e.uri,i)),500)})),this._doValidate(e.uri,i))},o=e=>{l.editor.setModelMarkers(e,this._languageId,[]);let t=e.uri.toString(),i=this._listener[t];i&&(i.dispose(),delete this._listener[t])};this._disposables.push(l.editor.onDidCreateModel(n)),this._disposables.push(l.editor.onWillDisposeModel(o)),this._disposables.push(l.editor.onDidChangeModelLanguage((e=>{o(e.model),n(e.model)}))),this._disposables.push(i((e=>{l.editor.getModels().forEach((e=>{e.getLanguageId()===this._languageId&&(o(e),n(e))}))}))),this._disposables.push({dispose:()=>{l.editor.getModels().forEach(o);for(let e in this._listener)this._listener[e].dispose()}}),l.editor.getModels().forEach(n)}_disposables=[];_listener=Object.create(null);dispose(){this._disposables.forEach((e=>e&&e.dispose())),this._disposables.length=0}_doValidate(e,t){this._worker(e).then((t=>t.doValidation(e.toString()))).then((i=>{const n=i.map((e=>function(e,t){let i="number"==typeof t.code?String(t.code):t.code;return{severity:ct(t.severity),startLineNumber:t.range.start.line+1,startColumn:t.range.start.character+1,endLineNumber:t.range.end.line+1,endColumn:t.range.end.character+1,message:t.message,code:i,source:t.source}}(0,e)));let o=l.editor.getModel(e);o&&o.getLanguageId()===t&&l.editor.setModelMarkers(o,t,n)})).then(void 0,(e=>{console.error(e)}))}};function ct(e){switch(e){case R.Error:return l.MarkerSeverity.Error;case R.Warning:return l.MarkerSeverity.Warning;case R.Information:return l.MarkerSeverity.Info;case R.Hint:return l.MarkerSeverity.Hint;default:return l.MarkerSeverity.Info}}var dt=class{constructor(e,t){this._worker=e,this._triggerCharacters=t}get triggerCharacters(){return this._triggerCharacters}provideCompletionItems(e,t,i,n){const o=e.uri;return this._worker(o).then((e=>e.doComplete(o.toString(),ut(t)))).then((i=>{if(!i)return;const n=e.getWordUntilPosition(t),o=new l.Range(t.lineNumber,n.startColumn,t.lineNumber,n.endColumn),r=i.items.map((e=>{const t={label:e.label,insertText:e.insertText||e.label,sortText:e.sortText,filterText:e.filterText,documentation:e.documentation,detail:e.detail,command:(i=e.command,i&&"editor.action.triggerSuggest"===i.command?{id:i.command,title:i.title,arguments:i.arguments}:void 0),range:o,kind:pt(e.kind)};var i,n;return e.textEdit&&(void 0!==(n=e.textEdit).insert&&void 0!==n.replace?t.range={insert:gt(e.textEdit.insert),replace:gt(e.textEdit.replace)}:t.range=gt(e.textEdit.range),t.insertText=e.textEdit.newText),e.additionalTextEdits&&(t.additionalTextEdits=e.additionalTextEdits.map(mt)),e.insertTextFormat===be.Snippet&&(t.insertTextRules=l.languages.CompletionItemInsertTextRule.InsertAsSnippet),t}));return{isIncomplete:i.isIncomplete,suggestions:r}}))}};function ut(e){if(e)return{character:e.column-1,line:e.lineNumber-1}}function ht(e){if(e)return{start:{line:e.startLineNumber-1,character:e.startColumn-1},end:{line:e.endLineNumber-1,character:e.endColumn-1}}}function gt(e){if(e)return new l.Range(e.start.line+1,e.start.character+1,e.end.line+1,e.end.character+1)}function pt(e){const t=l.languages.CompletionItemKind;switch(e){case fe.Text:return t.Text;case fe.Method:return t.Method;case fe.Function:return t.Function;case fe.Constructor:return t.Constructor;case fe.Field:return t.Field;case fe.Variable:return t.Variable;case fe.Class:return t.Class;case fe.Interface:return t.Interface;case fe.Module:return t.Module;case fe.Property:return t.Property;case fe.Unit:return t.Unit;case fe.Value:return t.Value;case fe.Enum:return t.Enum;case fe.Keyword:return t.Keyword;case fe.Snippet:return t.Snippet;case fe.Color:return t.Color;case fe.File:return t.File;case fe.Reference:return t.Reference}return t.Property}function mt(e){if(e)return{range:gt(e.range),text:e.newText}}var ft=class{constructor(e){this._worker=e}provideHover(e,t,i){let n=e.uri;return this._worker(n).then((e=>e.doHover(n.toString(),ut(t)))).then((e=>{if(e)return{range:gt(e.range),contents:bt(e.contents)}}))}};function _t(e){return"string"==typeof e?{value:e}:(t=e)&&"object"==typeof t&&"string"==typeof t.kind?"plaintext"===e.kind?{value:e.value.replace(/[\\`*_{}[\]()#+\-.!]/g,"\\$&")}:{value:e.value}:{value:"```"+e.language+"\n"+e.value+"\n```\n"};var t}function bt(e){if(e)return Array.isArray(e)?e.map(_t):[_t(e)]}var vt=class{constructor(e){this._worker=e}provideDocumentHighlights(e,t,i){const n=e.uri;return this._worker(n).then((e=>e.findDocumentHighlights(n.toString(),ut(t)))).then((e=>{if(e)return e.map((e=>({range:gt(e.range),kind:Ct(e.kind)})))}))}};function Ct(e){switch(e){case Ae.Read:return l.languages.DocumentHighlightKind.Read;case Ae.Write:return l.languages.DocumentHighlightKind.Write;case Ae.Text:return l.languages.DocumentHighlightKind.Text}return l.languages.DocumentHighlightKind.Text}var wt=class{constructor(e){this._worker=e}provideDefinition(e,t,i){const n=e.uri;return this._worker(n).then((e=>e.findDefinition(n.toString(),ut(t)))).then((e=>{if(e)return[yt(e)]}))}};function yt(e){return{uri:l.Uri.parse(e.uri),range:gt(e.range)}}var St=class{constructor(e){this._worker=e}provideReferences(e,t,i,n){const o=e.uri;return this._worker(o).then((e=>e.findReferences(o.toString(),ut(t)))).then((e=>{if(e)return e.map(yt)}))}},xt=class{constructor(e){this._worker=e}provideRenameEdits(e,t,i,n){const o=e.uri;return this._worker(o).then((e=>e.doRename(o.toString(),ut(t),i))).then((e=>function(e){if(!e||!e.changes)return;let t=[];for(let i in e.changes){const n=l.Uri.parse(i);for(let o of e.changes[i])t.push({resource:n,edit:{range:gt(o.range),text:o.newText}})}return{edits:t}}(e)))}},kt=class{constructor(e){this._worker=e}provideDocumentSymbols(e,t){const i=e.uri;return this._worker(i).then((e=>e.findDocumentSymbols(i.toString()))).then((e=>{if(e)return e.map((e=>({name:e.name,detail:"",containerName:e.containerName,kind:Lt(e.kind),range:gt(e.location.range),selectionRange:gt(e.location.range),tags:[]})))}))}};function Lt(e){let t=l.languages.SymbolKind;switch(e){case Oe.File:return t.Array;case Oe.Module:return t.Module;case Oe.Namespace:return t.Namespace;case Oe.Package:return t.Package;case Oe.Class:return t.Class;case Oe.Method:return t.Method;case Oe.Property:return t.Property;case Oe.Field:return t.Field;case Oe.Constructor:return t.Constructor;case Oe.Enum:return t.Enum;case Oe.Interface:return t.Interface;case Oe.Function:return t.Function;case Oe.Variable:return t.Variable;case Oe.Constant:return t.Constant;case Oe.String:return t.String;case Oe.Number:return t.Number;case Oe.Boolean:return t.Boolean;case Oe.Array:return t.Array}return t.Function}var Et=class{constructor(e){this._worker=e}provideLinks(e,t){const i=e.uri;return this._worker(i).then((e=>e.findDocumentLinks(i.toString()))).then((e=>{if(e)return{links:e.map((e=>({range:gt(e.range),url:e.target})))}}))}},Nt=class{constructor(e){this._worker=e}provideDocumentFormattingEdits(e,t,i){const n=e.uri;return this._worker(n).then((e=>e.format(n.toString(),null,It(t)).then((e=>{if(e&&0!==e.length)return e.map(mt)}))))}},Dt=class{constructor(e){this._worker=e}provideDocumentRangeFormattingEdits(e,t,i,n){const o=e.uri;return this._worker(o).then((e=>e.format(o.toString(),ht(t),It(i)).then((e=>{if(e&&0!==e.length)return e.map(mt)}))))}};function It(e){return{tabSize:e.tabSize,insertSpaces:e.insertSpaces}}var Tt,At=class{constructor(e){this._worker=e}provideDocumentColors(e,t){const i=e.uri;return this._worker(i).then((e=>e.findDocumentColors(i.toString()))).then((e=>{if(e)return e.map((e=>({color:e.color,range:gt(e.range)})))}))}provideColorPresentations(e,t,i){const n=e.uri;return this._worker(n).then((e=>e.getColorPresentations(n.toString(),t.color,ht(t.range)))).then((e=>{if(e)return e.map((e=>{let t={label:e.label};return e.textEdit&&(t.textEdit=mt(e.textEdit)),e.additionalTextEdits&&(t.additionalTextEdits=e.additionalTextEdits.map(mt)),t}))}))}},Rt=class{constructor(e){this._worker=e}provideFoldingRanges(e,t,i){const n=e.uri;return this._worker(n).then((e=>e.getFoldingRanges(n.toString(),t))).then((e=>{if(e)return e.map((e=>{const t={start:e.startLine+1,end:e.endLine+1};return void 0!==e.kind&&(t.kind=function(e){switch(e){case E.Comment:return l.languages.FoldingRangeKind.Comment;case E.Imports:return l.languages.FoldingRangeKind.Imports;case E.Region:return l.languages.FoldingRangeKind.Region}}(e.kind)),t}))}))}},Mt=class{constructor(e){this._worker=e}provideSelectionRanges(e,t,i){const n=e.uri;return this._worker(n).then((e=>e.getSelectionRanges(n.toString(),t.map(ut)))).then((e=>{if(e)return e.map((e=>{const t=[];for(;e;)t.push({range:gt(e.range)}),e=e.parent;return t}))}))}};function Ot(e){return 32===e||9===e||11===e||12===e||160===e||5760===e||e>=8192&&e<=8203||8239===e||8287===e||12288===e||65279===e}function Pt(e){return 10===e||13===e||8232===e||8233===e}function Ft(e){return e>=48&&e<=57}(Tt||(Tt={})).DEFAULT={allowTrailingComma:!1};function Bt(e){return{getInitialState:()=>new Qt(null,null,!1,null),tokenize:(t,i)=>function(e,t,i,n=0){let o=0,r=!1;switch(i.scanError){case 2:t='"'+t,o=1;break;case 1:t="/*"+t,o=2}const s=function(e,t){void 0===t&&(t=!1);var i=e.length,n=0,o="",r=0,s=16,a=0,l=0,c=0,d=0,u=0;function h(t,i){for(var o=0,r=0;o=48&&s<=57)r=16*r+s-48;else if(s>=65&&s<=70)r=16*r+s-65+10;else{if(!(s>=97&&s<=102))break;r=16*r+s-97+10}n++,o++}return o=i)return r=i,s=17;var t=e.charCodeAt(n);if(Ot(t)){do{n++,o+=String.fromCharCode(t),t=e.charCodeAt(n)}while(Ot(t));return s=15}if(Pt(t))return n++,o+=String.fromCharCode(t),13===t&&10===e.charCodeAt(n)&&(n++,o+="\n"),a++,c=n,s=14;switch(t){case 123:return n++,s=1;case 125:return n++,s=2;case 91:return n++,s=3;case 93:return n++,s=4;case 58:return n++,s=6;case 44:return n++,s=5;case 34:return n++,o=function(){for(var t="",o=n;;){if(n>=i){t+=e.substring(o,n),u=2;break}var r=e.charCodeAt(n);if(34===r){t+=e.substring(o,n),n++;break}if(92!==r){if(r>=0&&r<=31){if(Pt(r)){t+=e.substring(o,n),u=2;break}u=6}n++}else{if(t+=e.substring(o,n),++n>=i){u=2;break}switch(e.charCodeAt(n++)){case 34:t+='"';break;case 92:t+="\\";break;case 47:t+="/";break;case 98:t+="\b";break;case 102:t+="\f";break;case 110:t+="\n";break;case 114:t+="\r";break;case 116:t+="\t";break;case 117:var s=h(4,!0);s>=0?t+=String.fromCharCode(s):u=4;break;default:u=5}o=n}}return t}(),s=10;case 47:var g=n-1;if(47===e.charCodeAt(n+1)){for(n+=2;n=12&&e<=15);return e}:g,getToken:function(){return s},getTokenValue:function(){return o},getTokenOffset:function(){return r},getTokenLength:function(){return n-r},getTokenStartLine:function(){return l},getTokenStartCharacter:function(){return r-d},getTokenError:function(){return u}}}(t);let a=i.lastWasColon,l=i.parents;const c={tokens:[],endState:i.clone()};for(;;){let d=n+s.getPosition(),u="";const h=s.scan();if(17===h)break;if(d===n+s.getPosition())throw new Error("Scanner did not advance, next 3 characters are: "+t.substr(s.getPosition(),3));switch(r&&(d-=o),r=o>0,h){case 1:l=Yt.push(l,0),u=Wt,a=!1;break;case 2:l=Yt.pop(l),u=Wt,a=!1;break;case 3:l=Yt.push(l,1),u=Vt,a=!1;break;case 4:l=Yt.pop(l),u=Vt,a=!1;break;case 6:u=Ht,a=!0;break;case 5:u=zt,a=!1;break;case 8:case 9:u=$t,a=!1;break;case 7:u=Ut,a=!1;break;case 10:const e=1===(l?l.type:0);u=a||e?jt:qt,a=!1;break;case 11:u=Kt,a=!1}if(e)switch(h){case 12:u=Zt;break;case 13:u=Gt}c.endState=new Qt(i.getStateData(),s.getTokenError(),a,l),c.tokens.push({startIndex:d,scopes:u})}return c}(e,t,i)}}var Wt="delimiter.bracket.json",Vt="delimiter.array.json",Ht="delimiter.colon.json",zt="delimiter.comma.json",$t="keyword.json",Ut="keyword.json",jt="string.value.json",Kt="number.json",qt="string.key.json",Gt="comment.block.json",Zt="comment.line.json",Yt=class{constructor(e,t){this.parent=e,this.type=t}static pop(e){return e?e.parent:null}static push(e,t){return new Yt(e,t)}static equals(e,t){if(!e&&!t)return!0;if(!e||!t)return!1;for(;e&&t;){if(e===t)return!0;if(e.type!==t.type)return!1;e=e.parent,t=t.parent}return!0}},Qt=class{_state;scanError;lastWasColon;parents;constructor(e,t,i,n){this._state=e,this.scanError=t,this.lastWasColon=i,this.parents=n}clone(){return new Qt(this._state,this.scanError,this.lastWasColon,this.parents)}equals(e){return e===this||!!(e&&e instanceof Qt)&&this.scanError===e.scanError&&this.lastWasColon===e.lastWasColon&&Yt.equals(this.parents,e.parents)}getStateData(){return this._state}setStateData(e){this._state=e}},Xt=class extends lt{constructor(e,t,i){super(e,t,i.onDidChange),this._disposables.push(l.editor.onWillDisposeModel((e=>{this._resetSchema(e.uri)}))),this._disposables.push(l.editor.onDidChangeModelLanguage((e=>{this._resetSchema(e.model.uri)})))}_resetSchema(e){this._worker().then((t=>{t.resetSchema(e.toString())}))}};function Jt(e){const t=[],i=[],n=new oe(e);t.push(n);const o=(...e)=>n.getLanguageServiceWorker(...e);function r(){const{languageId:t,modeConfiguration:n}=e;ti(i),n.documentFormattingEdits&&i.push(l.languages.registerDocumentFormattingEditProvider(t,new Nt(o))),n.documentRangeFormattingEdits&&i.push(l.languages.registerDocumentRangeFormattingEditProvider(t,new Dt(o))),n.completionItems&&i.push(l.languages.registerCompletionItemProvider(t,new dt(o,[" ",":",'"']))),n.hovers&&i.push(l.languages.registerHoverProvider(t,new ft(o))),n.documentSymbols&&i.push(l.languages.registerDocumentSymbolProvider(t,new kt(o))),n.tokens&&i.push(l.languages.setTokensProvider(t,Bt(!0))),n.colors&&i.push(l.languages.registerColorProvider(t,new At(o))),n.foldingRanges&&i.push(l.languages.registerFoldingRangeProvider(t,new Rt(o))),n.diagnostics&&i.push(new Xt(t,o,e)),n.selectionRanges&&i.push(l.languages.registerSelectionRangeProvider(t,new Mt(o)))}r(),t.push(l.languages.setLanguageConfiguration(e.languageId,ii));let s=e.modeConfiguration;return e.onDidChange((e=>{e.modeConfiguration!==s&&(s=e.modeConfiguration,r())})),t.push(ei(i)),ei(t)}function ei(e){return{dispose:()=>ti(e)}}function ti(e){for(;e.length;)e.pop().dispose()}var ii={wordPattern:/(-?\d*\.\d\w*)|([^\[\{\]\}\:\"\,\s]+)/g,comments:{lineComment:"//",blockComment:["/*","*/"]},brackets:[["{","}"],["[","]"]],autoClosingPairs:[{open:"{",close:"}",notIn:["string"]},{open:"[",close:"]",notIn:["string"]},{open:'"',close:'"',notIn:["string"]}]}},45580:function(e,t,i){"use strict";i.r(t),i.d(t,{jsonDefaults:function(){return c}});var n=i(54918),o=Object.defineProperty,r=Object.getOwnPropertyDescriptor,s=Object.getOwnPropertyNames,a=Object.prototype.hasOwnProperty,l={};((e,t,i,n)=>{if(t&&"object"==typeof t||"function"==typeof t)for(let i of s(t))a.call(e,i)||"default"===i||o(e,i,{get:()=>t[i],enumerable:!(n=r(t,i))||n.enumerable})})(l,n);var c=new class{_onDidChange=new l.Emitter;_diagnosticsOptions;_modeConfiguration;_languageId;constructor(e,t,i){this._languageId=e,this.setDiagnosticsOptions(t),this.setModeConfiguration(i)}get onDidChange(){return this._onDidChange.event}get languageId(){return this._languageId}get modeConfiguration(){return this._modeConfiguration}get diagnosticsOptions(){return this._diagnosticsOptions}setDiagnosticsOptions(e){this._diagnosticsOptions=e||Object.create(null),this._onDidChange.fire(this)}setModeConfiguration(e){this._modeConfiguration=e||Object.create(null),this._onDidChange.fire(this)}}("json",{validate:!0,allowComments:!0,schemas:[],enableSchemaRequest:!1,schemaRequest:"warning",schemaValidation:"warning",comments:"error",trailingCommas:"error"},{documentFormattingEdits:!0,documentRangeFormattingEdits:!0,completionItems:!0,hovers:!0,documentSymbols:!0,tokens:!0,colors:!0,foldingRanges:!0,diagnostics:!0,selectionRanges:!0});l.languages.json={jsonDefaults:c},l.languages.register({id:"json",extensions:[".json",".bowerrc",".jshintrc",".jscsrc",".eslintrc",".babelrc",".har"],aliases:["JSON","json"],mimetypes:["application/json"]}),l.languages.onLanguage("json",(()=>{Promise.resolve().then(i.bind(i,50104)).then((e=>e.setupMode(c)))}))},75797:function(e,t,i){"use strict";i.r(t),i.d(t,{JsxEmit:function(){return d},ModuleKind:function(){return c},ModuleResolutionKind:function(){return g},NewLineKind:function(){return u},ScriptTarget:function(){return h},getJavaScriptWorker:function(){return v},getTypeScriptWorker:function(){return b},javascriptDefaults:function(){return _},typescriptDefaults:function(){return f},typescriptVersion:function(){return m}});var n=i(54918),o=Object.defineProperty,r=Object.getOwnPropertyDescriptor,s=Object.getOwnPropertyNames,a=Object.prototype.hasOwnProperty,l={};((e,t,i,n)=>{if(t&&"object"==typeof t||"function"==typeof t)for(let i of s(t))a.call(e,i)||"default"===i||o(e,i,{get:()=>t[i],enumerable:!(n=r(t,i))||n.enumerable})})(l,n);var c=(e=>(e[e.None=0]="None",e[e.CommonJS=1]="CommonJS",e[e.AMD=2]="AMD",e[e.UMD=3]="UMD",e[e.System=4]="System",e[e.ES2015=5]="ES2015",e[e.ESNext=99]="ESNext",e))(c||{}),d=(e=>(e[e.None=0]="None",e[e.Preserve=1]="Preserve",e[e.React=2]="React",e[e.ReactNative=3]="ReactNative",e[e.ReactJSX=4]="ReactJSX",e[e.ReactJSXDev=5]="ReactJSXDev",e))(d||{}),u=(e=>(e[e.CarriageReturnLineFeed=0]="CarriageReturnLineFeed",e[e.LineFeed=1]="LineFeed",e))(u||{}),h=(e=>(e[e.ES3=0]="ES3",e[e.ES5=1]="ES5",e[e.ES2015=2]="ES2015",e[e.ES2016=3]="ES2016",e[e.ES2017=4]="ES2017",e[e.ES2018=5]="ES2018",e[e.ES2019=6]="ES2019",e[e.ES2020=7]="ES2020",e[e.ESNext=99]="ESNext",e[e.JSON=100]="JSON",e[e.Latest=99]="Latest",e))(h||{}),g=(e=>(e[e.Classic=1]="Classic",e[e.NodeJs=2]="NodeJs",e))(g||{}),p=class{_onDidChange=new l.Emitter;_onDidExtraLibsChange=new l.Emitter;_extraLibs;_removedExtraLibs;_eagerModelSync;_compilerOptions;_diagnosticsOptions;_workerOptions;_onDidExtraLibsChangeTimeout;_inlayHintsOptions;constructor(e,t,i,n){this._extraLibs=Object.create(null),this._removedExtraLibs=Object.create(null),this._eagerModelSync=!1,this.setCompilerOptions(e),this.setDiagnosticsOptions(t),this.setWorkerOptions(i),this.setInlayHintsOptions(n),this._onDidExtraLibsChangeTimeout=-1}get onDidChange(){return this._onDidChange.event}get onDidExtraLibsChange(){return this._onDidExtraLibsChange.event}get workerOptions(){return this._workerOptions}get inlayHintsOptions(){return this._inlayHintsOptions}getExtraLibs(){return this._extraLibs}addExtraLib(e,t){let i;if(i=void 0===t?`ts:extralib-${Math.random().toString(36).substring(2,15)}`:t,this._extraLibs[i]&&this._extraLibs[i].content===e)return{dispose:()=>{}};let n=1;return this._removedExtraLibs[i]&&(n=this._removedExtraLibs[i]+1),this._extraLibs[i]&&(n=this._extraLibs[i].version+1),this._extraLibs[i]={content:e,version:n},this._fireOnDidExtraLibsChangeSoon(),{dispose:()=>{let e=this._extraLibs[i];e&&e.version===n&&(delete this._extraLibs[i],this._removedExtraLibs[i]=n,this._fireOnDidExtraLibsChangeSoon())}}}setExtraLibs(e){for(const e in this._extraLibs)this._removedExtraLibs[e]=this._extraLibs[e].version;if(this._extraLibs=Object.create(null),e&&e.length>0)for(const t of e){const e=t.filePath||`ts:extralib-${Math.random().toString(36).substring(2,15)}`,i=t.content;let n=1;this._removedExtraLibs[e]&&(n=this._removedExtraLibs[e]+1),this._extraLibs[e]={content:i,version:n}}this._fireOnDidExtraLibsChangeSoon()}_fireOnDidExtraLibsChangeSoon(){-1===this._onDidExtraLibsChangeTimeout&&(this._onDidExtraLibsChangeTimeout=window.setTimeout((()=>{this._onDidExtraLibsChangeTimeout=-1,this._onDidExtraLibsChange.fire(void 0)}),0))}getCompilerOptions(){return this._compilerOptions}setCompilerOptions(e){this._compilerOptions=e||Object.create(null),this._onDidChange.fire(void 0)}getDiagnosticsOptions(){return this._diagnosticsOptions}setDiagnosticsOptions(e){this._diagnosticsOptions=e||Object.create(null),this._onDidChange.fire(void 0)}setWorkerOptions(e){this._workerOptions=e||Object.create(null),this._onDidChange.fire(void 0)}setInlayHintsOptions(e){this._inlayHintsOptions=e||Object.create(null),this._onDidChange.fire(void 0)}setMaximumWorkerIdleTime(e){}setEagerModelSync(e){this._eagerModelSync=e}getEagerModelSync(){return this._eagerModelSync}},m="4.5.5",f=new p({allowNonTsExtensions:!0,target:99},{noSemanticValidation:!1,noSyntaxValidation:!1,onlyVisible:!1},{},{}),_=new p({allowNonTsExtensions:!0,allowJs:!0,target:99},{noSemanticValidation:!0,noSyntaxValidation:!1,onlyVisible:!1},{},{}),b=()=>C().then((e=>e.getTypeScriptWorker())),v=()=>C().then((e=>e.getJavaScriptWorker()));function C(){return Promise.resolve().then(i.bind(i,1107))}l.languages.typescript={ModuleKind:c,JsxEmit:d,NewLineKind:u,ScriptTarget:h,ModuleResolutionKind:g,typescriptVersion:m,typescriptDefaults:f,javascriptDefaults:_,getTypeScriptWorker:b,getJavaScriptWorker:v},l.languages.onLanguage("typescript",(()=>C().then((e=>e.setupTypeScript(f))))),l.languages.onLanguage("javascript",(()=>C().then((e=>e.setupJavaScript(_)))))},1107:function(e,t,i){"use strict";i.r(t),i.d(t,{Adapter:function(){return m},CodeActionAdaptor:function(){return R},DefinitionAdapter:function(){return S},DiagnosticsAdapter:function(){return _},FormatAdapter:function(){return T},FormatHelper:function(){return I},FormatOnTypeAdapter:function(){return A},InlayHintsAdapter:function(){return O},Kind:function(){return L},LibFiles:function(){return f},OccurrencesAdapter:function(){return y},OutlineAdapter:function(){return k},QuickInfoAdapter:function(){return w},ReferenceAdapter:function(){return x},RenameAdapter:function(){return M},SignatureHelpAdapter:function(){return C},SuggestAdapter:function(){return b},WorkerManager:function(){return u},flattenDiagnosticMessageText:function(){return g},getJavaScriptWorker:function(){return B},getTypeScriptWorker:function(){return W},setupJavaScript:function(){return F},setupTypeScript:function(){return P}});var n=i(54918),o=i(75797),r=Object.defineProperty,s=Object.getOwnPropertyDescriptor,a=Object.getOwnPropertyNames,l=Object.prototype.hasOwnProperty,c=(e,t,i)=>(((e,t,i)=>{t in e?r(e,t,{enumerable:!0,configurable:!0,writable:!0,value:i}):e[t]=i})(e,"symbol"!=typeof t?t+"":t,i),i),d={};((e,t,i,n)=>{if(t&&"object"==typeof t||"function"==typeof t)for(let i of a(t))l.call(e,i)||"default"===i||r(e,i,{get:()=>t[i],enumerable:!(n=s(t,i))||n.enumerable})})(d,n);var u=class{_modeId;_defaults;_configChangeListener;_updateExtraLibsToken;_extraLibsChangeListener;_worker;_client;constructor(e,t){this._modeId=e,this._defaults=t,this._worker=null,this._client=null,this._configChangeListener=this._defaults.onDidChange((()=>this._stopWorker())),this._updateExtraLibsToken=0,this._extraLibsChangeListener=this._defaults.onDidExtraLibsChange((()=>this._updateExtraLibs()))}_stopWorker(){this._worker&&(this._worker.dispose(),this._worker=null),this._client=null}dispose(){this._configChangeListener.dispose(),this._extraLibsChangeListener.dispose(),this._stopWorker()}async _updateExtraLibs(){if(!this._worker)return;const e=++this._updateExtraLibsToken,t=await this._worker.getProxy();this._updateExtraLibsToken===e&&t.updateExtraLibs(this._defaults.getExtraLibs())}_getClient(){if(!this._client){this._worker=d.editor.createWebWorker({moduleId:"vs/language/typescript/tsWorker",label:this._modeId,keepIdleModels:!0,createData:{compilerOptions:this._defaults.getCompilerOptions(),extraLibs:this._defaults.getExtraLibs(),customWorkerPath:this._defaults.workerOptions.customWorkerPath,inlayHintsOptions:this._defaults.inlayHintsOptions}});let e=this._worker.getProxy();this._defaults.getEagerModelSync()&&(e=e.then((e=>this._worker?this._worker.withSyncedResources(d.editor.getModels().filter((e=>e.getLanguageId()===this._modeId)).map((e=>e.uri))):e))),this._client=e}return this._client}getLanguageServiceWorker(...e){let t;return this._getClient().then((e=>{t=e})).then((t=>{if(this._worker)return this._worker.withSyncedResources(e)})).then((e=>t))}},h={};function g(e,t,i=0){if("string"==typeof e)return e;if(void 0===e)return"";let n="";if(i){n+=t;for(let e=0;ee.text)).join(""):""}h["lib.d.ts"]=!0,h["lib.dom.d.ts"]=!0,h["lib.dom.iterable.d.ts"]=!0,h["lib.es2015.collection.d.ts"]=!0,h["lib.es2015.core.d.ts"]=!0,h["lib.es2015.d.ts"]=!0,h["lib.es2015.generator.d.ts"]=!0,h["lib.es2015.iterable.d.ts"]=!0,h["lib.es2015.promise.d.ts"]=!0,h["lib.es2015.proxy.d.ts"]=!0,h["lib.es2015.reflect.d.ts"]=!0,h["lib.es2015.symbol.d.ts"]=!0,h["lib.es2015.symbol.wellknown.d.ts"]=!0,h["lib.es2016.array.include.d.ts"]=!0,h["lib.es2016.d.ts"]=!0,h["lib.es2016.full.d.ts"]=!0,h["lib.es2017.d.ts"]=!0,h["lib.es2017.full.d.ts"]=!0,h["lib.es2017.intl.d.ts"]=!0,h["lib.es2017.object.d.ts"]=!0,h["lib.es2017.sharedmemory.d.ts"]=!0,h["lib.es2017.string.d.ts"]=!0,h["lib.es2017.typedarrays.d.ts"]=!0,h["lib.es2018.asyncgenerator.d.ts"]=!0,h["lib.es2018.asynciterable.d.ts"]=!0,h["lib.es2018.d.ts"]=!0,h["lib.es2018.full.d.ts"]=!0,h["lib.es2018.intl.d.ts"]=!0,h["lib.es2018.promise.d.ts"]=!0,h["lib.es2018.regexp.d.ts"]=!0,h["lib.es2019.array.d.ts"]=!0,h["lib.es2019.d.ts"]=!0,h["lib.es2019.full.d.ts"]=!0,h["lib.es2019.object.d.ts"]=!0,h["lib.es2019.string.d.ts"]=!0,h["lib.es2019.symbol.d.ts"]=!0,h["lib.es2020.bigint.d.ts"]=!0,h["lib.es2020.d.ts"]=!0,h["lib.es2020.full.d.ts"]=!0,h["lib.es2020.intl.d.ts"]=!0,h["lib.es2020.promise.d.ts"]=!0,h["lib.es2020.sharedmemory.d.ts"]=!0,h["lib.es2020.string.d.ts"]=!0,h["lib.es2020.symbol.wellknown.d.ts"]=!0,h["lib.es2021.d.ts"]=!0,h["lib.es2021.full.d.ts"]=!0,h["lib.es2021.intl.d.ts"]=!0,h["lib.es2021.promise.d.ts"]=!0,h["lib.es2021.string.d.ts"]=!0,h["lib.es2021.weakref.d.ts"]=!0,h["lib.es5.d.ts"]=!0,h["lib.es6.d.ts"]=!0,h["lib.esnext.d.ts"]=!0,h["lib.esnext.full.d.ts"]=!0,h["lib.esnext.intl.d.ts"]=!0,h["lib.esnext.promise.d.ts"]=!0,h["lib.esnext.string.d.ts"]=!0,h["lib.esnext.weakref.d.ts"]=!0,h["lib.scripthost.d.ts"]=!0,h["lib.webworker.d.ts"]=!0,h["lib.webworker.importscripts.d.ts"]=!0,h["lib.webworker.iterable.d.ts"]=!0;var m=class{constructor(e){this._worker=e}_textSpanToRange(e,t){let i=e.getPositionAt(t.start),n=e.getPositionAt(t.start+t.length),{lineNumber:o,column:r}=i,{lineNumber:s,column:a}=n;return{startLineNumber:o,startColumn:r,endLineNumber:s,endColumn:a}}},f=class{constructor(e){this._worker=e,this._libFiles={},this._hasFetchedLibFiles=!1,this._fetchLibFilesPromise=null}_libFiles;_hasFetchedLibFiles;_fetchLibFilesPromise;isLibFile(e){return!!e&&0===e.path.indexOf("/lib.")&&!!h[e.path.slice(1)]}getOrCreateModel(e){const t=d.Uri.parse(e),i=d.editor.getModel(t);if(i)return i;if(this.isLibFile(t)&&this._hasFetchedLibFiles)return d.editor.createModel(this._libFiles[t.path.slice(1)],"typescript",t);const n=o.typescriptDefaults.getExtraLibs()[e];return n?d.editor.createModel(n.content,"typescript",t):null}_containsLibFile(e){for(let t of e)if(this.isLibFile(t))return!0;return!1}async fetchLibFilesIfNecessary(e){this._containsLibFile(e)&&await this._fetchLibFiles()}_fetchLibFiles(){return this._fetchLibFilesPromise||(this._fetchLibFilesPromise=this._worker().then((e=>e.getLibFiles())).then((e=>{this._hasFetchedLibFiles=!0,this._libFiles=e}))),this._fetchLibFilesPromise}},_=class extends m{constructor(e,t,i,n){super(n),this._libFiles=e,this._defaults=t,this._selector=i;const o=e=>{if(e.getLanguageId()!==i)return;const t=()=>{const{onlyVisible:t}=this._defaults.getDiagnosticsOptions();t?e.isAttachedToEditor()&&this._doValidate(e):this._doValidate(e)};let n;const o=e.onDidChangeContent((()=>{clearTimeout(n),n=window.setTimeout(t,500)})),r=e.onDidChangeAttached((()=>{const{onlyVisible:i}=this._defaults.getDiagnosticsOptions();i&&(e.isAttachedToEditor()?t():d.editor.setModelMarkers(e,this._selector,[]))}));this._listener[e.uri.toString()]={dispose(){o.dispose(),r.dispose(),clearTimeout(n)}},t()},r=e=>{d.editor.setModelMarkers(e,this._selector,[]);const t=e.uri.toString();this._listener[t]&&(this._listener[t].dispose(),delete this._listener[t])};this._disposables.push(d.editor.onDidCreateModel((e=>o(e)))),this._disposables.push(d.editor.onWillDisposeModel(r)),this._disposables.push(d.editor.onDidChangeModelLanguage((e=>{r(e.model),o(e.model)}))),this._disposables.push({dispose(){for(const e of d.editor.getModels())r(e)}});const s=()=>{for(const e of d.editor.getModels())r(e),o(e)};this._disposables.push(this._defaults.onDidChange(s)),this._disposables.push(this._defaults.onDidExtraLibsChange(s)),d.editor.getModels().forEach((e=>o(e)))}_disposables=[];_listener=Object.create(null);dispose(){this._disposables.forEach((e=>e&&e.dispose())),this._disposables=[]}async _doValidate(e){const t=await this._worker(e.uri);if(e.isDisposed())return;const i=[],{noSyntaxValidation:n,noSemanticValidation:o,noSuggestionDiagnostics:r}=this._defaults.getDiagnosticsOptions();n||i.push(t.getSyntacticDiagnostics(e.uri.toString())),o||i.push(t.getSemanticDiagnostics(e.uri.toString())),r||i.push(t.getSuggestionDiagnostics(e.uri.toString()));const s=await Promise.all(i);if(!s||e.isDisposed())return;const a=s.reduce(((e,t)=>t.concat(e)),[]).filter((e=>-1===(this._defaults.getDiagnosticsOptions().diagnosticCodesToIgnore||[]).indexOf(e.code))),l=a.map((e=>e.relatedInformation||[])).reduce(((e,t)=>t.concat(e)),[]).map((e=>e.file?d.Uri.parse(e.file.fileName):null));await this._libFiles.fetchLibFilesIfNecessary(l),e.isDisposed()||d.editor.setModelMarkers(e,this._selector,a.map((t=>this._convertDiagnostics(e,t))))}_convertDiagnostics(e,t){const i=t.start||0,n=t.length||1,{lineNumber:o,column:r}=e.getPositionAt(i),{lineNumber:s,column:a}=e.getPositionAt(i+n),l=[];return t.reportsUnnecessary&&l.push(d.MarkerTag.Unnecessary),t.reportsDeprecated&&l.push(d.MarkerTag.Deprecated),{severity:this._tsDiagnosticCategoryToMarkerSeverity(t.category),startLineNumber:o,startColumn:r,endLineNumber:s,endColumn:a,message:g(t.messageText,"\n"),code:t.code.toString(),tags:l,relatedInformation:this._convertRelatedInformation(e,t.relatedInformation)}}_convertRelatedInformation(e,t){if(!t)return[];const i=[];return t.forEach((t=>{let n=e;if(t.file&&(n=this._libFiles.getOrCreateModel(t.file.fileName)),!n)return;const o=t.start||0,r=t.length||1,{lineNumber:s,column:a}=n.getPositionAt(o),{lineNumber:l,column:c}=n.getPositionAt(o+r);i.push({resource:n.uri,startLineNumber:s,startColumn:a,endLineNumber:l,endColumn:c,message:g(t.messageText,"\n")})})),i}_tsDiagnosticCategoryToMarkerSeverity(e){switch(e){case 1:return d.MarkerSeverity.Error;case 3:return d.MarkerSeverity.Info;case 0:return d.MarkerSeverity.Warning;case 2:return d.MarkerSeverity.Hint}return d.MarkerSeverity.Info}},b=class extends m{get triggerCharacters(){return["."]}async provideCompletionItems(e,t,i,n){const o=e.getWordUntilPosition(t),r=new d.Range(t.lineNumber,o.startColumn,t.lineNumber,o.endColumn),s=e.uri,a=e.getOffsetAt(t),l=await this._worker(s);if(e.isDisposed())return;const c=await l.getCompletionsAtPosition(s.toString(),a);return c&&!e.isDisposed()?{suggestions:c.entries.map((i=>{let n=r;if(i.replacementSpan){const t=e.getPositionAt(i.replacementSpan.start),o=e.getPositionAt(i.replacementSpan.start+i.replacementSpan.length);n=new d.Range(t.lineNumber,t.column,o.lineNumber,o.column)}const o=[];return-1!==i.kindModifiers?.indexOf("deprecated")&&o.push(d.languages.CompletionItemTag.Deprecated),{uri:s,position:t,offset:a,range:n,label:i.name,insertText:i.name,sortText:i.sortText,kind:b.convertKind(i.kind),tags:o}}))}:void 0}async resolveCompletionItem(e,t){const i=e,n=i.uri,o=i.position,r=i.offset,s=await this._worker(n),a=await s.getCompletionEntryDetails(n.toString(),r,i.label);return a?{uri:n,position:o,label:a.name,kind:b.convertKind(a.kind),detail:p(a.displayParts),documentation:{value:b.createDocumentationString(a)}}:i}static convertKind(e){switch(e){case L.primitiveType:case L.keyword:return d.languages.CompletionItemKind.Keyword;case L.variable:case L.localVariable:return d.languages.CompletionItemKind.Variable;case L.memberVariable:case L.memberGetAccessor:case L.memberSetAccessor:return d.languages.CompletionItemKind.Field;case L.function:case L.memberFunction:case L.constructSignature:case L.callSignature:case L.indexSignature:return d.languages.CompletionItemKind.Function;case L.enum:return d.languages.CompletionItemKind.Enum;case L.module:return d.languages.CompletionItemKind.Module;case L.class:return d.languages.CompletionItemKind.Class;case L.interface:return d.languages.CompletionItemKind.Interface;case L.warning:return d.languages.CompletionItemKind.File}return d.languages.CompletionItemKind.Property}static createDocumentationString(e){let t=p(e.documentation);if(e.tags)for(const i of e.tags)t+=`\n\n${v(i)}`;return t}};function v(e){let t=`*@${e.name}*`;if("param"===e.name&&e.text){const[i,...n]=e.text;t+=`\`${i.text}\``,n.length>0&&(t+=` — ${n.map((e=>e.text)).join(" ")}`)}else Array.isArray(e.text)?t+=` — ${e.text.map((e=>e.text)).join(" ")}`:e.text&&(t+=` — ${e.text}`);return t}var C=class extends m{signatureHelpTriggerCharacters=["(",","];static _toSignatureHelpTriggerReason(e){switch(e.triggerKind){case d.languages.SignatureHelpTriggerKind.TriggerCharacter:return e.triggerCharacter?e.isRetrigger?{kind:"retrigger",triggerCharacter:e.triggerCharacter}:{kind:"characterTyped",triggerCharacter:e.triggerCharacter}:{kind:"invoked"};case d.languages.SignatureHelpTriggerKind.ContentChange:return e.isRetrigger?{kind:"retrigger"}:{kind:"invoked"};case d.languages.SignatureHelpTriggerKind.Invoke:default:return{kind:"invoked"}}}async provideSignatureHelp(e,t,i,n){const o=e.uri,r=e.getOffsetAt(t),s=await this._worker(o);if(e.isDisposed())return;const a=await s.getSignatureHelpItems(o.toString(),r,{triggerReason:C._toSignatureHelpTriggerReason(n)});if(!a||e.isDisposed())return;const l={activeSignature:a.selectedItemIndex,activeParameter:a.argumentIndex,signatures:[]};return a.items.forEach((e=>{const t={label:"",parameters:[]};t.documentation={value:p(e.documentation)},t.label+=p(e.prefixDisplayParts),e.parameters.forEach(((i,n,o)=>{const r=p(i.displayParts),s={label:r,documentation:{value:p(i.documentation)}};t.label+=r,t.parameters.push(s),nv(e))).join(" \n\n"):"",c=p(s.displayParts);return{range:this._textSpanToRange(e,s.textSpan),contents:[{value:"```typescript\n"+c+"\n```\n"},{value:a+(l?"\n\n"+l:"")}]}}},y=class extends m{async provideDocumentHighlights(e,t,i){const n=e.uri,o=e.getOffsetAt(t),r=await this._worker(n);if(e.isDisposed())return;const s=await r.getOccurrencesAtPosition(n.toString(),o);return s&&!e.isDisposed()?s.map((t=>({range:this._textSpanToRange(e,t.textSpan),kind:t.isWriteAccess?d.languages.DocumentHighlightKind.Write:d.languages.DocumentHighlightKind.Text}))):void 0}},S=class extends m{constructor(e,t){super(t),this._libFiles=e}async provideDefinition(e,t,i){const n=e.uri,o=e.getOffsetAt(t),r=await this._worker(n);if(e.isDisposed())return;const s=await r.getDefinitionAtPosition(n.toString(),o);if(!s||e.isDisposed())return;if(await this._libFiles.fetchLibFilesIfNecessary(s.map((e=>d.Uri.parse(e.fileName)))),e.isDisposed())return;const a=[];for(let e of s){const t=this._libFiles.getOrCreateModel(e.fileName);t&&a.push({uri:t.uri,range:this._textSpanToRange(t,e.textSpan)})}return a}},x=class extends m{constructor(e,t){super(t),this._libFiles=e}async provideReferences(e,t,i,n){const o=e.uri,r=e.getOffsetAt(t),s=await this._worker(o);if(e.isDisposed())return;const a=await s.getReferencesAtPosition(o.toString(),r);if(!a||e.isDisposed())return;if(await this._libFiles.fetchLibFilesIfNecessary(a.map((e=>d.Uri.parse(e.fileName)))),e.isDisposed())return;const l=[];for(let e of a){const t=this._libFiles.getOrCreateModel(e.fileName);t&&l.push({uri:t.uri,range:this._textSpanToRange(t,e.textSpan)})}return l}},k=class extends m{async provideDocumentSymbols(e,t){const i=e.uri,n=await this._worker(i);if(e.isDisposed())return;const o=await n.getNavigationBarItems(i.toString());if(!o||e.isDisposed())return;const r=(t,i,n)=>{let o={name:i.text,detail:"",kind:E[i.kind]||d.languages.SymbolKind.Variable,range:this._textSpanToRange(e,i.spans[0]),selectionRange:this._textSpanToRange(e,i.spans[0]),tags:[]};if(n&&(o.containerName=n),i.childItems&&i.childItems.length>0)for(let e of i.childItems)r(t,e,o.name);t.push(o)};let s=[];return o.forEach((e=>r(s,e))),s}},L=class{};c(L,"unknown",""),c(L,"keyword","keyword"),c(L,"script","script"),c(L,"module","module"),c(L,"class","class"),c(L,"interface","interface"),c(L,"type","type"),c(L,"enum","enum"),c(L,"variable","var"),c(L,"localVariable","local var"),c(L,"function","function"),c(L,"localFunction","local function"),c(L,"memberFunction","method"),c(L,"memberGetAccessor","getter"),c(L,"memberSetAccessor","setter"),c(L,"memberVariable","property"),c(L,"constructorImplementation","constructor"),c(L,"callSignature","call"),c(L,"indexSignature","index"),c(L,"constructSignature","construct"),c(L,"parameter","parameter"),c(L,"typeParameter","type parameter"),c(L,"primitiveType","primitive type"),c(L,"label","label"),c(L,"alias","alias"),c(L,"const","const"),c(L,"let","let"),c(L,"warning","warning");var E=Object.create(null);E[L.module]=d.languages.SymbolKind.Module,E[L.class]=d.languages.SymbolKind.Class,E[L.enum]=d.languages.SymbolKind.Enum,E[L.interface]=d.languages.SymbolKind.Interface,E[L.memberFunction]=d.languages.SymbolKind.Method,E[L.memberVariable]=d.languages.SymbolKind.Property,E[L.memberGetAccessor]=d.languages.SymbolKind.Property,E[L.memberSetAccessor]=d.languages.SymbolKind.Property,E[L.variable]=d.languages.SymbolKind.Variable,E[L.const]=d.languages.SymbolKind.Variable,E[L.localVariable]=d.languages.SymbolKind.Variable,E[L.variable]=d.languages.SymbolKind.Variable,E[L.function]=d.languages.SymbolKind.Function,E[L.localFunction]=d.languages.SymbolKind.Function;var N,D,I=class extends m{static _convertOptions(e){return{ConvertTabsToSpaces:e.insertSpaces,TabSize:e.tabSize,IndentSize:e.tabSize,IndentStyle:2,NewLineCharacter:"\n",InsertSpaceAfterCommaDelimiter:!0,InsertSpaceAfterSemicolonInForStatements:!0,InsertSpaceBeforeAndAfterBinaryOperators:!0,InsertSpaceAfterKeywordsInControlFlowStatements:!0,InsertSpaceAfterFunctionKeywordForAnonymousFunctions:!0,InsertSpaceAfterOpeningAndBeforeClosingNonemptyParenthesis:!1,InsertSpaceAfterOpeningAndBeforeClosingNonemptyBrackets:!1,InsertSpaceAfterOpeningAndBeforeClosingTemplateStringBraces:!1,PlaceOpenBraceOnNewLineForControlBlocks:!1,PlaceOpenBraceOnNewLineForFunctions:!1}}_convertTextChanges(e,t){return{text:t.newText,range:this._textSpanToRange(e,t.span)}}},T=class extends I{async provideDocumentRangeFormattingEdits(e,t,i,n){const o=e.uri,r=e.getOffsetAt({lineNumber:t.startLineNumber,column:t.startColumn}),s=e.getOffsetAt({lineNumber:t.endLineNumber,column:t.endColumn}),a=await this._worker(o);if(e.isDisposed())return;const l=await a.getFormattingEditsForRange(o.toString(),r,s,I._convertOptions(i));return l&&!e.isDisposed()?l.map((t=>this._convertTextChanges(e,t))):void 0}},A=class extends I{get autoFormatTriggerCharacters(){return[";","}","\n"]}async provideOnTypeFormattingEdits(e,t,i,n,o){const r=e.uri,s=e.getOffsetAt(t),a=await this._worker(r);if(e.isDisposed())return;const l=await a.getFormattingEditsAfterKeystroke(r.toString(),s,i,I._convertOptions(n));return l&&!e.isDisposed()?l.map((t=>this._convertTextChanges(e,t))):void 0}},R=class extends I{async provideCodeActions(e,t,i,n){const o=e.uri,r=e.getOffsetAt({lineNumber:t.startLineNumber,column:t.startColumn}),s=e.getOffsetAt({lineNumber:t.endLineNumber,column:t.endColumn}),a=I._convertOptions(e.getOptions()),l=i.markers.filter((e=>e.code)).map((e=>e.code)).map(Number),c=await this._worker(o);if(e.isDisposed())return;const d=await c.getCodeFixesAtPosition(o.toString(),r,s,l,a);return!d||e.isDisposed()?{actions:[],dispose:()=>{}}:{actions:d.filter((e=>0===e.changes.filter((e=>e.isNewFile)).length)).map((t=>this._tsCodeFixActionToMonacoCodeAction(e,i,t))),dispose:()=>{}}}_tsCodeFixActionToMonacoCodeAction(e,t,i){const n=[];for(const t of i.changes)for(const i of t.textChanges)n.push({resource:e.uri,edit:{range:this._textSpanToRange(e,i.span),text:i.newText}});return{title:i.description,edit:{edits:n},diagnostics:t.markers,kind:"quickfix"}}},M=class extends m{constructor(e,t){super(t),this._libFiles=e}async provideRenameEdits(e,t,i,n){const o=e.uri,r=o.toString(),s=e.getOffsetAt(t),a=await this._worker(o);if(e.isDisposed())return;const l=await a.getRenameInfo(r,s,{allowRenameOfImportPath:!1});if(!1===l.canRename)return{edits:[],rejectReason:l.localizedErrorMessage};if(void 0!==l.fileToRename)throw new Error("Renaming files is not supported.");const c=await a.findRenameLocations(r,s,!1,!1,!1);if(!c||e.isDisposed())return;const d=[];for(const e of c){const t=this._libFiles.getOrCreateModel(e.fileName);if(!t)throw new Error(`Unknown file ${e.fileName}.`);d.push({resource:t.uri,edit:{range:this._textSpanToRange(t,e.textSpan),text:i}})}return{edits:d}}},O=class extends m{async provideInlayHints(e,t,i){const n=e.uri,o=n.toString(),r=e.getOffsetAt({lineNumber:t.startLineNumber,column:t.startColumn}),s=e.getOffsetAt({lineNumber:t.endLineNumber,column:t.endColumn}),a=await this._worker(n);return e.isDisposed()?null:{hints:(await a.provideInlayHints(o,r,s)).map((t=>({...t,label:t.text,position:e.getPositionAt(t.position),kind:this._convertHintKind(t.kind)}))),dispose:()=>{}}}_convertHintKind(e){return"Parameter"===e?d.languages.InlayHintKind.Parameter:d.languages.InlayHintKind.Type}};function P(e){D=V(e,"typescript")}function F(e){N=V(e,"javascript")}function B(){return new Promise(((e,t)=>{if(!N)return t("JavaScript not registered!");e(N)}))}function W(){return new Promise(((e,t)=>{if(!D)return t("TypeScript not registered!");e(D)}))}function V(e,t){const i=new u(t,e),n=(...e)=>i.getLanguageServiceWorker(...e),o=new f(n);return d.languages.registerCompletionItemProvider(t,new b(n)),d.languages.registerSignatureHelpProvider(t,new C(n)),d.languages.registerHoverProvider(t,new w(n)),d.languages.registerDocumentHighlightProvider(t,new y(n)),d.languages.registerDefinitionProvider(t,new S(o,n)),d.languages.registerReferenceProvider(t,new x(o,n)),d.languages.registerDocumentSymbolProvider(t,new k(n)),d.languages.registerDocumentRangeFormattingEditProvider(t,new T(n)),d.languages.registerOnTypeFormattingEditProvider(t,new A(n)),d.languages.registerCodeActionProvider(t,new R(n)),d.languages.registerRenameProvider(t,new M(o,n)),d.languages.registerInlayHintsProvider(t,new O(n)),new _(o,e,t,n),n}},33060:function(e,t,i){"use strict";i.d(t,{F:function(){return o},U:function(){return r}});var n=i(60393);const o=(0,i(12260).yh)("accessibilityService"),r=new n.uy("accessibilityModeEnabled",!1)},83390:function(e,t,i){"use strict";i.d(t,{Mm:function(){return U},Id:function(){return q},vr:function(){return $}});var n=i(68695),o=i(33200),r=i(99512),s=i(83055),a=i(11007),l=i(46718),c=i(93379),d=i.n(c),u=i(7795),h=i.n(u),g=i(90569),p=i.n(g),m=i(3565),f=i.n(m),_=i(19216),b=i.n(_),v=i(44589),C=i.n(v),w=i(68904),y={};y.styleTagTransform=C(),y.setAttributes=f(),y.insert=p().bind(null,"head"),y.domAPI=h(),y.insertStyleElement=b(),d()(w.Z,y),w.Z&&w.Z.locals&&w.Z.locals;class S extends a.Wi{constructor(e,t){super(),this._onDidChangeVisibility=this._register(new l.Q5),this.onDidChangeVisibility=this._onDidChangeVisibility.event,this._element=(0,n.R3)(e,(0,n.$)(".monaco-dropdown")),this._label=(0,n.R3)(this._element,(0,n.$)(".dropdown-label"));let i=t.labelRenderer;i||(i=e=>(e.textContent=t.label||"",null));for(const e of[n.tw.CLICK,n.tw.MOUSE_DOWN,s.t.Tap])this._register((0,n.nm)(this.element,e,(e=>n.zB.stop(e,!0))));for(const e of[n.tw.MOUSE_DOWN,s.t.Tap])this._register((0,n.nm)(this._label,e,(e=>{e instanceof MouseEvent&&e.detail>1||(this.visible?this.hide():this.show())})));this._register((0,n.nm)(this._label,n.tw.KEY_UP,(e=>{const t=new o.y(e);(t.equals(3)||t.equals(10))&&(n.zB.stop(e,!0),this.visible?this.hide():this.show())})));const r=i(this._label);r&&this._register(r),this._register(s.o.addTarget(this._label))}get element(){return this._element}show(){this.visible||(this.visible=!0,this._onDidChangeVisibility.fire(!0))}hide(){this.visible&&(this.visible=!1,this._onDidChangeVisibility.fire(!1))}dispose(){super.dispose(),this.hide(),this.boxContainer&&(this.boxContainer.remove(),this.boxContainer=void 0),this.contents&&(this.contents.remove(),this.contents=void 0),this._label&&(this._label.remove(),this._label=void 0)}}class x extends S{constructor(e,t){super(e,t),this._actions=[],this._contextMenuProvider=t.contextMenuProvider,this.actions=t.actions||[],this.actionProvider=t.actionProvider,this.menuClassName=t.menuClassName||"",this.menuAsChild=!!t.menuAsChild}set menuOptions(e){this._menuOptions=e}get menuOptions(){return this._menuOptions}get actions(){return this.actionProvider?this.actionProvider.getActions():this._actions}set actions(e){this._actions=e}show(){super.show(),this.element.classList.add("active"),this._contextMenuProvider.showContextMenu({getAnchor:()=>this.element,getActions:()=>this.actions,getActionsContext:()=>this.menuOptions?this.menuOptions.context:null,getActionViewItem:e=>this.menuOptions&&this.menuOptions.actionViewItemProvider?this.menuOptions.actionViewItemProvider(e):void 0,getKeyBinding:e=>this.menuOptions&&this.menuOptions.getKeyBinding?this.menuOptions.getKeyBinding(e):void 0,getMenuClassName:()=>this.menuClassName,onHide:()=>this.onHide(),actionRunner:this.menuOptions?this.menuOptions.actionRunner:void 0,anchorAlignment:this.menuOptions?this.menuOptions.anchorAlignment:0,domForShadowRoot:this.menuAsChild?this.element:void 0})}hide(){super.hide()}onHide(){this.hide(),this.element.classList.remove("active")}}class k extends r.Y{constructor(e,t,i,n=Object.create(null)){super(null,e,n),this.actionItem=null,this._onDidChangeVisibility=this._register(new l.Q5),this.menuActionsOrProvider=t,this.contextMenuProvider=i,this.options=n,this.options.actionRunner&&(this.actionRunner=this.options.actionRunner)}render(e){this.actionItem=e;const t=Array.isArray(this.menuActionsOrProvider),i={contextMenuProvider:this.contextMenuProvider,labelRenderer:e=>{this.element=(0,n.R3)(e,(0,n.$)("a.action-label"));let t=[];return"string"==typeof this.options.classNames?t=this.options.classNames.split(/\s+/g).filter((e=>!!e)):this.options.classNames&&(t=this.options.classNames),t.find((e=>"icon"===e))||t.push("codicon"),this.element.classList.add(...t),this.element.setAttribute("role","button"),this.element.setAttribute("aria-haspopup","true"),this.element.setAttribute("aria-expanded","false"),this.element.title=this._action.label||"",null},menuAsChild:this.options.menuAsChild,actions:t?this.menuActionsOrProvider:void 0,actionProvider:t?void 0:this.menuActionsOrProvider};if(this.dropdownMenu=this._register(new x(e,i)),this._register(this.dropdownMenu.onDidChangeVisibility((e=>{var t;null===(t=this.element)||void 0===t||t.setAttribute("aria-expanded",`${e}`),this._onDidChangeVisibility.fire(e)}))),this.dropdownMenu.menuOptions={actionViewItemProvider:this.options.actionViewItemProvider,actionRunner:this.actionRunner,getKeyBinding:this.options.keybindingProvider,context:this._context},this.options.anchorAlignmentProvider){const e=this;this.dropdownMenu.menuOptions=Object.assign(Object.assign({},this.dropdownMenu.menuOptions),{get anchorAlignment(){return e.options.anchorAlignmentProvider()}})}this.updateEnabled()}setActionContext(e){super.setActionContext(e),this.dropdownMenu&&(this.dropdownMenu.menuOptions?this.dropdownMenu.menuOptions.context=e:this.dropdownMenu.menuOptions={context:e})}updateEnabled(){var e,t;const i=!this.getAction().enabled;null===(e=this.actionItem)||void 0===e||e.classList.toggle("disabled",i),null===(t=this.element)||void 0===t||t.classList.toggle("disabled",i)}}var L=i(34670),E=i(4004),N=i(6954),D=i(55723),I={};I.styleTagTransform=C(),I.setAttributes=f(),I.insert=p().bind(null,"head"),I.domAPI=h(),I.insertStyleElement=b(),d()(D.Z,I),D.Z&&D.Z.locals&&D.Z.locals;var T=i(89982),A=i(3337),R=i(60393),M=i(12887),O=i(12260),P=i(67517),F=i(66877),B=i(86303),W=i(81585),V=function(e,t,i,n){var o,r=arguments.length,s=r<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,i):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(e,t,i,n);else for(var a=e.length-1;a>=0;a--)(o=e[a])&&(s=(r<3?o(s):r>3?o(t,i,s):o(t,i))||s);return r>3&&s&&Object.defineProperty(t,i,s),s},H=function(e,t){return function(i,n){t(i,n,e)}},z=function(e,t,i,n){return new(i||(i=Promise))((function(o,r){function s(e){try{l(n.next(e))}catch(e){r(e)}}function a(e){try{l(n.throw(e))}catch(e){r(e)}}function l(e){var t;e.done?o(e.value):(t=e.value,t instanceof i?t:new i((function(e){e(t)}))).then(s,a)}l((n=n.apply(e,t||[])).next())}))};function $(e,t,i,n,o,r,s){const l=e.getActions(t);return function(e,t,i,n=(e=>"navigation"===e),o=Number.MAX_SAFE_INTEGER,r=(()=>!1),s=!1){let l,c;Array.isArray(t)?(l=t,c=t):(l=t.primary,c=t.secondary);const d=new Set;for(const[t,o]of e){let e;n(t)?(e=l,e.length>0&&s&&e.push(new a.Z0)):(e=c,e.length>0&&e.push(new a.Z0));for(let n of o){i&&(n=n instanceof A.U8&&n.alt?n.alt:n);const o=e.push(n);n instanceof a.wY&&d.add({group:t,action:n,index:o-1})}}for(const{group:e,action:t,index:i}of d){const s=n(e)?l:c,a=t.actions;(a.length<=1||s.length+a.length-2<=o)&&r(t,e,s.length)&&s.splice(i,1,...a)}if(l!==c&&l.length>o){const e=l.splice(o,l.length-o);c.unshift(...e,new a.Z0)}}(l,i,!1,"string"==typeof n?e=>e===n:n,o,r,s),function(e){const t=new E.SL;for(const[,i]of e)for(const e of i)t.add(e);return t}(l)}let U=class extends r.g{constructor(e,t,i,o,r){super(void 0,e,{icon:!(!e.class&&!e.item.icon),label:!e.class&&!e.item.icon,draggable:null==t?void 0:t.draggable}),this._keybindingService=i,this._notificationService=o,this._contextKeyService=r,this._wantsAltCommand=!1,this._itemClassDispose=this._register(new E.XK),this._altKey=n._q.getInstance()}get _menuItemAction(){return this._action}get _commandAction(){return this._wantsAltCommand&&this._menuItemAction.alt||this._menuItemAction}onClick(e){return z(this,void 0,void 0,(function*(){e.preventDefault(),e.stopPropagation();try{yield this.actionRunner.run(this._commandAction,this._context)}catch(e){this._notificationService.error(e)}}))}render(e){super.render(e),e.classList.add("menu-entry"),this._updateItemClass(this._menuItemAction.item);let t=!1,i=this._altKey.keyStatus.altKey||(N.ED||N.IJ)&&this._altKey.keyStatus.shiftKey;const o=()=>{const e=t&&i;e!==this._wantsAltCommand&&(this._wantsAltCommand=e,this.updateLabel(),this.updateTooltip(),this.updateClass())};this._menuItemAction.alt&&this._register(this._altKey.event((e=>{i=e.altKey||(N.ED||N.IJ)&&e.shiftKey,o()}))),this._register((0,n.nm)(e,"mouseleave",(e=>{t=!1,o()}))),this._register((0,n.nm)(e,"mouseenter",(e=>{t=!0,o()})))}updateLabel(){this.options.label&&this.label&&(this.label.textContent=this._commandAction.label)}updateTooltip(){if(this.label){const e=this._keybindingService.lookupKeybinding(this._commandAction.id,this._contextKeyService),t=e&&e.getLabel(),i=this._commandAction.tooltip||this._commandAction.label;let n=t?(0,T.NC)("vs/platform/actions/browser/menuEntryActionViewItem","titleAndKb","{0} ({1})",i,t):i;if(!this._wantsAltCommand&&this._menuItemAction.alt){const e=this._menuItemAction.alt.tooltip||this._menuItemAction.alt.label,t=this._keybindingService.lookupKeybinding(this._menuItemAction.alt.id,this._contextKeyService),i=t&&t.getLabel(),o=i?(0,T.NC)("vs/platform/actions/browser/menuEntryActionViewItem","titleAndKb","{0} ({1})",e,i):e;n+=`\n[${L.xo.modifierLabels[N.OS].altKey}] ${o}`}this.label.title=n}}updateClass(){this.options.icon&&(this._commandAction!==this._menuItemAction?this._menuItemAction.alt&&this._updateItemClass(this._menuItemAction.alt.item):this._menuItemAction.alt&&this._updateItemClass(this._menuItemAction.item))}_updateItemClass(e){var t;this._itemClassDispose.value=void 0;const{element:i,label:o}=this;if(!i||!o)return;const r=this._commandAction.checked&&(null===(t=e.toggled)||void 0===t?void 0:t.icon)?e.toggled.icon:e.icon;if(r)if(W.kS.isThemeIcon(r)){const e=W.kS.asClassNameArray(r);o.classList.add(...e),this._itemClassDispose.value=(0,E.OF)((()=>{o.classList.remove(...e)}))}else r.light&&o.style.setProperty("--menu-entry-icon-light",(0,n.wY)(r.light)),r.dark&&o.style.setProperty("--menu-entry-icon-dark",(0,n.wY)(r.dark)),o.classList.add("icon"),this._itemClassDispose.value=(0,E.OF)((()=>{o.classList.remove("icon"),o.style.removeProperty("--menu-entry-icon-light"),o.style.removeProperty("--menu-entry-icon-dark")}))}};U=V([H(2,P.d),H(3,F.lT),H(4,R.i6)],U);let j=class extends k{constructor(e,t,i){var n,o;const r=Object.assign({},null!=t?t:Object.create(null),{menuAsChild:null!==(n=null==t?void 0:t.menuAsChild)&&void 0!==n&&n,classNames:null!==(o=null==t?void 0:t.classNames)&&void 0!==o?o:W.kS.isThemeIcon(e.item.icon)?W.kS.asClassName(e.item.icon):void 0});super(e,{getActions:()=>e.actions},i,r)}render(e){if(super.render(e),this.element){e.classList.add("menu-entry");const{icon:t}=this._action.item;t&&!W.kS.isThemeIcon(t)&&(this.element.classList.add("icon"),t.light&&this.element.style.setProperty("--menu-entry-icon-light",(0,n.wY)(t.light)),t.dark&&this.element.style.setProperty("--menu-entry-icon-dark",(0,n.wY)(t.dark)))}}};j=V([H(2,M.i)],j);let K=class extends r.Y{constructor(e,t,i,n,o,r,s,l){var c,d,u;let h;super(null,e),this._keybindingService=i,this._notificationService=n,this._contextMenuService=o,this._menuService=r,this._instaService=s,this._storageService=l,this._container=null,this._storageKey=`${e.item.submenu._debugName}_lastActionId`;let g=l.get(this._storageKey,1);g&&(h=e.actions.find((e=>g===e.id))),h||(h=e.actions[0]),this._defaultAction=this._instaService.createInstance(U,h,void 0);const p=Object.assign({},null!=t?t:Object.create(null),{menuAsChild:null===(c=null==t?void 0:t.menuAsChild)||void 0===c||c,classNames:null!==(d=null==t?void 0:t.classNames)&&void 0!==d?d:["codicon","codicon-chevron-down"],actionRunner:null!==(u=null==t?void 0:t.actionRunner)&&void 0!==u?u:new a.Wi});this._dropdown=new k(e,e.actions,this._contextMenuService,p),this._dropdown.actionRunner.onDidRun((e=>{e.action instanceof A.U8&&this.update(e.action)}))}update(e){this._storageService.store(this._storageKey,e.id,1,0),this._defaultAction.dispose(),this._defaultAction=this._instaService.createInstance(U,e,void 0),this._defaultAction.actionRunner=new class extends a.Wi{runAction(e,t){return z(this,void 0,void 0,(function*(){yield e.run(void 0)}))}},this._container&&this._defaultAction.render((0,n.Ce)(this._container,(0,n.$)(".action-container")))}setActionContext(e){super.setActionContext(e),this._defaultAction.setActionContext(e),this._dropdown.setActionContext(e)}render(e){this._container=e,super.render(this._container),this._container.classList.add("monaco-dropdown-with-default");const t=(0,n.$)(".action-container");this._defaultAction.render((0,n.R3)(this._container,t)),this._register((0,n.nm)(t,n.tw.KEY_DOWN,(e=>{const t=new o.y(e);t.equals(17)&&(this._defaultAction.element.tabIndex=-1,this._dropdown.focus(),t.stopPropagation())})));const i=(0,n.$)(".dropdown-action-container");this._dropdown.render((0,n.R3)(this._container,i)),this._register((0,n.nm)(i,n.tw.KEY_DOWN,(e=>{var t;const i=new o.y(e);i.equals(15)&&(this._defaultAction.element.tabIndex=0,this._dropdown.setFocusable(!1),null===(t=this._defaultAction.element)||void 0===t||t.focus(),i.stopPropagation())})))}focus(e){e?this._dropdown.focus():(this._defaultAction.element.tabIndex=0,this._defaultAction.element.focus())}blur(){this._defaultAction.element.tabIndex=-1,this._dropdown.blur(),this._container.blur()}setFocusable(e){e?this._defaultAction.element.tabIndex=0:(this._defaultAction.element.tabIndex=-1,this._dropdown.setFocusable(!1))}dispose(){this._defaultAction.dispose(),this._dropdown.dispose(),super.dispose()}};function q(e,t,i){return t instanceof A.U8?e.createInstance(U,t,void 0):t instanceof A.NZ?t.item.rememberDefaultAction?e.createInstance(K,t,i):e.createInstance(j,t,i):void 0}K=V([H(2,P.d),H(3,F.lT),H(4,M.i),H(5,A.co),H(6,O.TG),H(7,B.Uy)],K)},3337:function(e,t,i){"use strict";i.d(t,{BH:function(){return _},NZ:function(){return b},U8:function(){return v},co:function(){return f},eH:function(){return m},vr:function(){return p}});var n=i(11007),o=i(4821),r=i(46718),s=i(44780),a=i(4004),l=i(57512),c=i(14756),d=i(60393),u=i(12260),h=i(81585),g=function(e,t){return function(i,n){t(i,n,e)}};function p(e){return void 0!==e.command}class m{constructor(e){this.id=m._idPool++,this._debugName=e}}m._idPool=0,m.CommandPalette=new m("CommandPalette"),m.DebugBreakpointsContext=new m("DebugBreakpointsContext"),m.DebugCallStackContext=new m("DebugCallStackContext"),m.DebugConsoleContext=new m("DebugConsoleContext"),m.DebugVariablesContext=new m("DebugVariablesContext"),m.DebugWatchContext=new m("DebugWatchContext"),m.DebugToolBar=new m("DebugToolBar"),m.EditorContext=new m("EditorContext"),m.SimpleEditorContext=new m("SimpleEditorContext"),m.EditorContextCopy=new m("EditorContextCopy"),m.EditorContextPeek=new m("EditorContextPeek"),m.EditorTitle=new m("EditorTitle"),m.EditorTitleRun=new m("EditorTitleRun"),m.EditorTitleContext=new m("EditorTitleContext"),m.EmptyEditorGroup=new m("EmptyEditorGroup"),m.EmptyEditorGroupContext=new m("EmptyEditorGroupContext"),m.ExplorerContext=new m("ExplorerContext"),m.ExtensionContext=new m("ExtensionContext"),m.GlobalActivity=new m("GlobalActivity"),m.LayoutControlMenuSubmenu=new m("LayoutControlMenuSubmenu"),m.LayoutControlMenu=new m("LayoutControlMenu"),m.MenubarMainMenu=new m("MenubarMainMenu"),m.MenubarAppearanceMenu=new m("MenubarAppearanceMenu"),m.MenubarDebugMenu=new m("MenubarDebugMenu"),m.MenubarEditMenu=new m("MenubarEditMenu"),m.MenubarCopy=new m("MenubarCopy"),m.MenubarFileMenu=new m("MenubarFileMenu"),m.MenubarGoMenu=new m("MenubarGoMenu"),m.MenubarHelpMenu=new m("MenubarHelpMenu"),m.MenubarLayoutMenu=new m("MenubarLayoutMenu"),m.MenubarNewBreakpointMenu=new m("MenubarNewBreakpointMenu"),m.MenubarPanelAlignmentMenu=new m("MenubarPanelAlignmentMenu"),m.MenubarPanelPositionMenu=new m("MenubarPanelPositionMenu"),m.MenubarPreferencesMenu=new m("MenubarPreferencesMenu"),m.MenubarRecentMenu=new m("MenubarRecentMenu"),m.MenubarSelectionMenu=new m("MenubarSelectionMenu"),m.MenubarSwitchEditorMenu=new m("MenubarSwitchEditorMenu"),m.MenubarSwitchGroupMenu=new m("MenubarSwitchGroupMenu"),m.MenubarTerminalMenu=new m("MenubarTerminalMenu"),m.MenubarViewMenu=new m("MenubarViewMenu"),m.MenubarHomeMenu=new m("MenubarHomeMenu"),m.OpenEditorsContext=new m("OpenEditorsContext"),m.ProblemsPanelContext=new m("ProblemsPanelContext"),m.SCMChangeContext=new m("SCMChangeContext"),m.SCMResourceContext=new m("SCMResourceContext"),m.SCMResourceFolderContext=new m("SCMResourceFolderContext"),m.SCMResourceGroupContext=new m("SCMResourceGroupContext"),m.SCMSourceControl=new m("SCMSourceControl"),m.SCMTitle=new m("SCMTitle"),m.SearchContext=new m("SearchContext"),m.StatusBarWindowIndicatorMenu=new m("StatusBarWindowIndicatorMenu"),m.StatusBarRemoteIndicatorMenu=new m("StatusBarRemoteIndicatorMenu"),m.TestItem=new m("TestItem"),m.TestItemGutter=new m("TestItemGutter"),m.TestPeekElement=new m("TestPeekElement"),m.TestPeekTitle=new m("TestPeekTitle"),m.TouchBarContext=new m("TouchBarContext"),m.TitleBarContext=new m("TitleBarContext"),m.TunnelContext=new m("TunnelContext"),m.TunnelPrivacy=new m("TunnelPrivacy"),m.TunnelProtocol=new m("TunnelProtocol"),m.TunnelPortInline=new m("TunnelInline"),m.TunnelTitle=new m("TunnelTitle"),m.TunnelLocalAddressInline=new m("TunnelLocalAddressInline"),m.TunnelOriginInline=new m("TunnelOriginInline"),m.ViewItemContext=new m("ViewItemContext"),m.ViewContainerTitle=new m("ViewContainerTitle"),m.ViewContainerTitleContext=new m("ViewContainerTitleContext"),m.ViewTitle=new m("ViewTitle"),m.ViewTitleContext=new m("ViewTitleContext"),m.CommentThreadTitle=new m("CommentThreadTitle"),m.CommentThreadActions=new m("CommentThreadActions"),m.CommentTitle=new m("CommentTitle"),m.CommentActions=new m("CommentActions"),m.InteractiveToolbar=new m("InteractiveToolbar"),m.InteractiveCellTitle=new m("InteractiveCellTitle"),m.InteractiveCellExecute=new m("InteractiveCellExecute"),m.InteractiveInputExecute=new m("InteractiveInputExecute"),m.NotebookToolbar=new m("NotebookToolbar"),m.NotebookCellTitle=new m("NotebookCellTitle"),m.NotebookCellInsert=new m("NotebookCellInsert"),m.NotebookCellBetween=new m("NotebookCellBetween"),m.NotebookCellListTop=new m("NotebookCellTop"),m.NotebookCellExecute=new m("NotebookCellExecute"),m.NotebookCellExecutePrimary=new m("NotebookCellExecutePrimary"),m.NotebookDiffCellInputTitle=new m("NotebookDiffCellInputTitle"),m.NotebookDiffCellMetadataTitle=new m("NotebookDiffCellMetadataTitle"),m.NotebookDiffCellOutputsTitle=new m("NotebookDiffCellOutputsTitle"),m.NotebookOutputToolbar=new m("NotebookOutputToolbar"),m.NotebookEditorLayoutConfigure=new m("NotebookEditorLayoutConfigure"),m.BulkEditTitle=new m("BulkEditTitle"),m.BulkEditContext=new m("BulkEditContext"),m.TimelineItemContext=new m("TimelineItemContext"),m.TimelineTitle=new m("TimelineTitle"),m.TimelineTitleContext=new m("TimelineTitleContext"),m.AccountsContext=new m("AccountsContext"),m.PanelTitle=new m("PanelTitle"),m.AuxiliaryBarTitle=new m("AuxiliaryBarTitle"),m.TerminalInstanceContext=new m("TerminalInstanceContext"),m.TerminalEditorInstanceContext=new m("TerminalEditorInstanceContext"),m.TerminalNewDropdownContext=new m("TerminalNewDropdownContext"),m.TerminalTabContext=new m("TerminalTabContext"),m.TerminalTabEmptyAreaContext=new m("TerminalTabEmptyAreaContext"),m.TerminalInlineTabContext=new m("TerminalInlineTabContext"),m.WebviewContext=new m("WebviewContext"),m.InlineCompletionsActions=new m("InlineCompletionsActions"),m.NewFile=new m("NewFile");const f=(0,u.yh)("menuService"),_=new class{constructor(){this._commands=new Map,this._menuItems=new Map,this._onDidChangeMenu=new r.Q5,this.onDidChangeMenu=this._onDidChangeMenu.event,this._commandPaletteChangeEvent={has:e=>e===m.CommandPalette}}addCommand(e){return this.addCommands(s.$.single(e))}addCommands(e){for(const t of e)this._commands.set(t.id,t);return this._onDidChangeMenu.fire(this._commandPaletteChangeEvent),(0,a.OF)((()=>{let t=!1;for(const i of e)t=this._commands.delete(i.id)||t;t&&this._onDidChangeMenu.fire(this._commandPaletteChangeEvent)}))}getCommand(e){return this._commands.get(e)}getCommands(){const e=new Map;return this._commands.forEach(((t,i)=>e.set(i,t))),e}appendMenuItem(e,t){return this.appendMenuItems(s.$.single({id:e,item:t}))}appendMenuItems(e){const t=new Set,i=new l.S;for(const{id:n,item:o}of e){let e=this._menuItems.get(n);e||(e=new l.S,this._menuItems.set(n,e)),i.push(e.push(o)),t.add(n)}return this._onDidChangeMenu.fire(t),(0,a.OF)((()=>{if(i.size>0){for(let e of i)e();this._onDidChangeMenu.fire(t),i.clear()}}))}getMenuItems(e){let t;return t=this._menuItems.has(e)?[...this._menuItems.get(e)]:[],e===m.CommandPalette&&this._appendImplicitItems(t),t}_appendImplicitItems(e){const t=new Set;for(const i of e)p(i)&&(t.add(i.command.id),i.alt&&t.add(i.alt.id));this._commands.forEach(((i,n)=>{t.has(n)||e.push({command:i})}))}};class b extends n.wY{constructor(e,t,i,n){super(`submenuitem.${e.submenu.id}`,"string"==typeof e.title?e.title:e.title.value,[],"submenu"),this.item=e,this._menuService=t,this._contextKeyService=i,this._options=n}get actions(){const e=[],t=this._menuService.createMenu(this.item.submenu,this._contextKeyService),i=t.getActions(this._options);t.dispose();for(const[,t]of i)t.length>0&&(e.push(...t),e.push(new n.Z0));return e.length&&e.pop(),e}}let v=class e{constructor(t,i,n,r,s){var a,l;if(this._commandService=s,this.id=t.id,this.label=(null==n?void 0:n.renderShortTitle)&&t.shortTitle?"string"==typeof t.shortTitle?t.shortTitle:t.shortTitle.value:"string"==typeof t.title?t.title:t.title.value,this.tooltip=null!==(l="string"==typeof t.tooltip?t.tooltip:null===(a=t.tooltip)||void 0===a?void 0:a.value)&&void 0!==l?l:"",this.enabled=!t.precondition||r.contextMatchesRules(t.precondition),this.checked=void 0,t.toggled){const e=t.toggled.condition?t.toggled:{condition:t.toggled};this.checked=r.contextMatchesRules(e.condition),this.checked&&e.tooltip&&(this.tooltip="string"==typeof e.tooltip?e.tooltip:e.tooltip.value),e.title&&(this.label="string"==typeof e.title?e.title:e.title.value)}this.item=t,this.alt=i?new e(i,void 0,n,r,s):void 0,this._options=n,h.kS.isThemeIcon(t.icon)&&(this.class=o.dT.asClassName(t.icon))}dispose(){}run(...e){var t,i;let n=[];return(null===(t=this._options)||void 0===t?void 0:t.arg)&&(n=[...n,this._options.arg]),(null===(i=this._options)||void 0===i?void 0:i.shouldForwardArgs)&&(n=[...n,...e]),this._commandService.executeCommand(this.id,...n)}};v=function(e,t,i,n){var o,r=arguments.length,s=r<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,i):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(e,t,i,n);else for(var a=e.length-1;a>=0;a--)(o=e[a])&&(s=(r<3?o(s):r>3?o(t,i,s):o(t,i))||s);return r>3&&s&&Object.defineProperty(t,i,s),s}([g(3,d.i6),g(4,c.Hy)],v)},22837:function(e,t,i){"use strict";i.d(t,{p:function(){return n}});const n=(0,i(12260).yh)("clipboardService")},14756:function(e,t,i){"use strict";i.d(t,{Hy:function(){return l},P0:function(){return c}});var n=i(46718),o=i(44780),r=i(4004),s=i(57512),a=i(28295);const l=(0,i(12260).yh)("commandService"),c=new class{constructor(){this._commands=new Map,this._onDidRegisterCommand=new n.Q5,this.onDidRegisterCommand=this._onDidRegisterCommand.event}registerCommand(e,t){if(!e)throw new Error("invalid command");if("string"==typeof e){if(!t)throw new Error("invalid command");return this.registerCommand({id:e,handler:t})}if(e.description){const t=[];for(let i of e.description.args)t.push(i.constraint);const i=e.handler;e.handler=function(e,...n){return(0,a.D8)(n,t),i(e,...n)}}const{id:i}=e;let n=this._commands.get(i);n||(n=new s.S,this._commands.set(i,n));let o=n.unshift(e),l=(0,r.OF)((()=>{o();const e=this._commands.get(i);(null==e?void 0:e.isEmpty())&&this._commands.delete(i)}));return this._onDidRegisterCommand.fire(i),l}registerCommandAlias(e,t){return c.registerCommand(e,((e,...i)=>e.get(l).executeCommand(t,...i)))}getCommand(e){const t=this._commands.get(e);if(t&&!t.isEmpty())return o.$.first(t)}getCommands(){const e=new Map;for(const t of this._commands.keys()){const i=this.getCommand(t);i&&e.set(t,i)}return e}};c.registerCommand("noop",(()=>{}))},40539:function(e,t,i){"use strict";i.d(t,{KV:function(){return r},Mt:function(){return l},Od:function(){return o},Ui:function(){return n},xL:function(){return s}});const n=(0,i(12260).yh)("configurationService");function o(e,t){const i=Object.create(null);for(let n in e)r(i,n,e[n],t);return i}function r(e,t,i,n){const o=t.split("."),r=o.pop();let s=e;for(let e=0;e{i.push(...this.validateAndRegisterProperties(e,t,e.extensionInfo,e.restrictedProperties)),this.configurationContributors.push(e),this.registerJSONConfiguration(e)})),i}validateAndRegisterProperties(e,t=!0,i,n,o=3){o=r.Jp(e.scope)?o:e.scope;let s=[],a=e.properties;if(a)for(let e in a){if(t&&S(e)){delete a[e];continue}const l=a[e];l.source=i,l.defaultDefaultValue=a[e].default,this.updatePropertyDefaultValue(e,l),C.test(e)?l.scope=void 0:(l.scope=r.Jp(l.scope)?o:l.scope,l.restricted=r.Jp(l.restricted)?!!(null==n?void 0:n.includes(e)):l.restricted),!a[e].hasOwnProperty("included")||a[e].included?(this.configurationProperties[e]=a[e],!a[e].deprecationMessage&&a[e].markdownDeprecationMessage&&(a[e].deprecationMessage=a[e].markdownDeprecationMessage),s.push(e)):(this.excludedConfigurationProperties[e]=a[e],delete a[e])}let l=e.allOf;if(l)for(let e of l)s.push(...this.validateAndRegisterProperties(e,t,i,n,o));return s}getConfigurationProperties(){return this.configurationProperties}registerJSONConfiguration(e){const t=e=>{let i=e.properties;if(i)for(const e in i)this.updateSchema(e,i[e]);let n=e.allOf;n&&n.forEach(t)};t(e)}updateSchema(e,t){switch(d.properties[e]=t,t.scope){case 1:u.properties[e]=t;break;case 2:h.properties[e]=t;break;case 6:g.properties[e]=t;break;case 3:p.properties[e]=t;break;case 4:m.properties[e]=t;break;case 5:m.properties[e]=t,this.resourceLanguageSettingsSchema.properties[e]=t}}updateOverridePropertyPatternKey(){for(const e of this.overrideIdentifiers.values()){const t=`[${e}]`,i={type:"object",description:s.NC("vs/platform/configuration/common/configurationRegistry","overrideSettings.defaultDescription","Configure editor settings to be overridden for a language."),errorMessage:s.NC("vs/platform/configuration/common/configurationRegistry","overrideSettings.errorMessage","This setting does not support per-language configuration."),$ref:f};this.updatePropertyDefaultValue(t,i),d.properties[t]=i,u.properties[t]=i,h.properties[t]=i,g.properties[t]=i,p.properties[t]=i,m.properties[t]=i}this._onDidSchemaChange.fire()}registerOverridePropertyPatternKey(){const e={type:"object",description:s.NC("vs/platform/configuration/common/configurationRegistry","overrideSettings.defaultDescription","Configure editor settings to be overridden for a language."),errorMessage:s.NC("vs/platform/configuration/common/configurationRegistry","overrideSettings.errorMessage","This setting does not support per-language configuration."),$ref:f};d.patternProperties["^(\\[([^\\]]+)\\])+$"]=e,u.patternProperties["^(\\[([^\\]]+)\\])+$"]=e,h.patternProperties["^(\\[([^\\]]+)\\])+$"]=e,g.patternProperties["^(\\[([^\\]]+)\\])+$"]=e,p.patternProperties["^(\\[([^\\]]+)\\])+$"]=e,m.patternProperties["^(\\[([^\\]]+)\\])+$"]=e,this._onDidSchemaChange.fire()}updatePropertyDefaultValue(e,t){const i=this.configurationDefaultsOverrides.get(e);let n=null==i?void 0:i.value,o=null==i?void 0:i.source;r.o8(n)&&(n=t.defaultDefaultValue,o=void 0),r.o8(n)&&(n=function(e){switch(Array.isArray(e)?e[0]:e){case"boolean":return!1;case"integer":case"number":return 0;case"string":return"";case"array":return[];case"object":return{};default:return null}}(t.type)),t.default=n,t.defaultValueSource=o}};function S(e){return e.trim()?C.test(e)?s.NC("vs/platform/configuration/common/configurationRegistry","config.property.languageDefault","Cannot register '{0}'. This matches property pattern '\\\\[.*\\\\]$' for describing language specific editor settings. Use 'configurationDefaults' contribution.",e):void 0!==y.getConfigurationProperties()[e]?s.NC("vs/platform/configuration/common/configurationRegistry","config.property.duplicate","Cannot register '{0}'. This property is already registered.",e):null:s.NC("vs/platform/configuration/common/configurationRegistry","config.property.empty","Cannot register an empty property")}l.B.add(c.Configuration,y)},60393:function(e,t,i){"use strict";i.d(t,{Ao:function(){return l},Eq:function(){return T},Fb:function(){return c},K8:function(){return M},i6:function(){return I},uy:function(){return D}});var n=i(6954),o=i(18039),r=i(12260);const s=new Map;s.set("false",!1),s.set("true",!0),s.set("isMac",n.dz),s.set("isLinux",n.IJ),s.set("isWindows",n.ED),s.set("isWeb",n.$L),s.set("isMacNative",n.dz&&!n.$L),s.set("isEdge",n.un),s.set("isFirefox",n.vU),s.set("isChrome",n.i7),s.set("isSafari",n.G6);const a=Object.prototype.hasOwnProperty;class l{static has(e){return g.create(e)}static equals(e,t){return p.create(e,t)}static regex(e,t){return x.create(e,t)}static not(e){return b.create(e)}static and(...e){return E.create(e,null)}static or(...e){return N.create(e,null,!0)}static deserialize(e,t=!1){if(e)return this._deserializeOrExpression(e,t)}static _deserializeOrExpression(e,t){let i=e.split("||");return N.create(i.map((e=>this._deserializeAndExpression(e,t))),null,!0)}static _deserializeAndExpression(e,t){let i=e.split("&&");return E.create(i.map((e=>this._deserializeOne(e,t))),null)}static _deserializeOne(e,t){if((e=e.trim()).indexOf("!=")>=0){let i=e.split("!=");return _.create(i[0].trim(),this._deserializeValue(i[1],t))}if(e.indexOf("==")>=0){let i=e.split("==");return p.create(i[0].trim(),this._deserializeValue(i[1],t))}if(e.indexOf("=~")>=0){let i=e.split("=~");return x.create(i[0].trim(),this._deserializeRegexValue(i[1],t))}if(e.indexOf(" in ")>=0){let t=e.split(" in ");return m.create(t[0].trim(),t[1].trim())}if(/^[^<=>]+>=[^<=>]+$/.test(e)){const t=e.split(">=");return w.create(t[0].trim(),t[1].trim())}if(/^[^<=>]+>[^<=>]+$/.test(e)){const t=e.split(">");return C.create(t[0].trim(),t[1].trim())}if(/^[^<=>]+<=[^<=>]+$/.test(e)){const t=e.split("<=");return S.create(t[0].trim(),t[1].trim())}if(/^[^<=>]+<[^<=>]+$/.test(e)){const t=e.split("<");return y.create(t[0].trim(),t[1].trim())}return/^\!\s*/.test(e)?b.create(e.substr(1).trim()):g.create(e)}static _deserializeValue(e,t){if("true"===(e=e.trim()))return!0;if("false"===e)return!1;let i=/^'([^']*)'$/.exec(e);return i?i[1].trim():e}static _deserializeRegexValue(e,t){if((0,o.m5)(e)){if(t)throw new Error("missing regexp-value for =~-expression");return console.warn("missing regexp-value for =~-expression"),null}let i=e.indexOf("/"),n=e.lastIndexOf("/");if(i===n||i<0){if(t)throw new Error(`bad regexp-value '${e}', missing /-enclosure`);return console.warn(`bad regexp-value '${e}', missing /-enclosure`),null}let r=e.slice(i+1,n),s="i"===e[n+1]?"i":"";try{return new RegExp(r,s)}catch(i){if(t)throw new Error(`bad regexp-value '${e}', parse error: ${i}`);return console.warn(`bad regexp-value '${e}', parse error: ${i}`),null}}}function c(e,t){const i=e?e.substituteConstants():void 0,n=t?t.substituteConstants():void 0;return!i&&!n||!(!i||!n)&&i.equals(n)}function d(e,t){return e.cmp(t)}class u{constructor(){this.type=0}cmp(e){return this.type-e.type}equals(e){return e.type===this.type}substituteConstants(){return this}evaluate(e){return!1}serialize(){return"false"}keys(){return[]}negate(){return h.INSTANCE}}u.INSTANCE=new u;class h{constructor(){this.type=1}cmp(e){return this.type-e.type}equals(e){return e.type===this.type}substituteConstants(){return this}evaluate(e){return!0}serialize(){return"true"}keys(){return[]}negate(){return u.INSTANCE}}h.INSTANCE=new h;class g{constructor(e,t){this.key=e,this.negated=t,this.type=2}static create(e,t=null){const i=s.get(e);return"boolean"==typeof i?i?h.INSTANCE:u.INSTANCE:new g(e,t)}cmp(e){return e.type!==this.type?this.type-e.type:A(this.key,e.key)}equals(e){return e.type===this.type&&this.key===e.key}substituteConstants(){const e=s.get(this.key);return"boolean"==typeof e?e?h.INSTANCE:u.INSTANCE:this}evaluate(e){return!!e.getValue(this.key)}serialize(){return this.key}keys(){return[this.key]}negate(){return this.negated||(this.negated=b.create(this.key,this)),this.negated}}class p{constructor(e,t,i){this.key=e,this.value=t,this.negated=i,this.type=4}static create(e,t,i=null){if("boolean"==typeof t)return t?g.create(e,i):b.create(e,i);const n=s.get(e);return"boolean"==typeof n?t===(n?"true":"false")?h.INSTANCE:u.INSTANCE:new p(e,t,i)}cmp(e){return e.type!==this.type?this.type-e.type:R(this.key,this.value,e.key,e.value)}equals(e){return e.type===this.type&&this.key===e.key&&this.value===e.value}substituteConstants(){const e=s.get(this.key);if("boolean"==typeof e){const t=e?"true":"false";return this.value===t?h.INSTANCE:u.INSTANCE}return this}evaluate(e){return e.getValue(this.key)==this.value}serialize(){return`${this.key} == '${this.value}'`}keys(){return[this.key]}negate(){return this.negated||(this.negated=_.create(this.key,this.value,this)),this.negated}}class m{constructor(e,t){this.key=e,this.valueKey=t,this.type=10,this.negated=null}static create(e,t){return new m(e,t)}cmp(e){return e.type!==this.type?this.type-e.type:R(this.key,this.valueKey,e.key,e.valueKey)}equals(e){return e.type===this.type&&this.key===e.key&&this.valueKey===e.valueKey}substituteConstants(){return this}evaluate(e){const t=e.getValue(this.valueKey),i=e.getValue(this.key);return Array.isArray(t)?t.indexOf(i)>=0:"string"==typeof i&&"object"==typeof t&&null!==t&&a.call(t,i)}serialize(){return`${this.key} in '${this.valueKey}'`}keys(){return[this.key,this.valueKey]}negate(){return this.negated||(this.negated=f.create(this)),this.negated}}class f{constructor(e){this._actual=e,this.type=11}static create(e){return new f(e)}cmp(e){return e.type!==this.type?this.type-e.type:this._actual.cmp(e._actual)}equals(e){return e.type===this.type&&this._actual.equals(e._actual)}substituteConstants(){return this}evaluate(e){return!this._actual.evaluate(e)}serialize(){throw new Error("Method not implemented.")}keys(){return this._actual.keys()}negate(){return this._actual}}class _{constructor(e,t,i){this.key=e,this.value=t,this.negated=i,this.type=5}static create(e,t,i=null){if("boolean"==typeof t)return t?b.create(e,i):g.create(e,i);const n=s.get(e);return"boolean"==typeof n?t===(n?"true":"false")?u.INSTANCE:h.INSTANCE:new _(e,t,i)}cmp(e){return e.type!==this.type?this.type-e.type:R(this.key,this.value,e.key,e.value)}equals(e){return e.type===this.type&&this.key===e.key&&this.value===e.value}substituteConstants(){const e=s.get(this.key);if("boolean"==typeof e){const t=e?"true":"false";return this.value===t?u.INSTANCE:h.INSTANCE}return this}evaluate(e){return e.getValue(this.key)!=this.value}serialize(){return`${this.key} != '${this.value}'`}keys(){return[this.key]}negate(){return this.negated||(this.negated=p.create(this.key,this.value,this)),this.negated}}class b{constructor(e,t){this.key=e,this.negated=t,this.type=3}static create(e,t=null){const i=s.get(e);return"boolean"==typeof i?i?u.INSTANCE:h.INSTANCE:new b(e,t)}cmp(e){return e.type!==this.type?this.type-e.type:A(this.key,e.key)}equals(e){return e.type===this.type&&this.key===e.key}substituteConstants(){const e=s.get(this.key);return"boolean"==typeof e?e?u.INSTANCE:h.INSTANCE:this}evaluate(e){return!e.getValue(this.key)}serialize(){return`!${this.key}`}keys(){return[this.key]}negate(){return this.negated||(this.negated=g.create(this.key,this)),this.negated}}function v(e,t){if("string"==typeof e){const t=parseFloat(e);isNaN(t)||(e=t)}return"string"==typeof e||"number"==typeof e?t(e):u.INSTANCE}class C{constructor(e,t,i){this.key=e,this.value=t,this.negated=i,this.type=12}static create(e,t,i=null){return v(t,(t=>new C(e,t,i)))}cmp(e){return e.type!==this.type?this.type-e.type:R(this.key,this.value,e.key,e.value)}equals(e){return e.type===this.type&&this.key===e.key&&this.value===e.value}substituteConstants(){return this}evaluate(e){return"string"!=typeof this.value&&parseFloat(e.getValue(this.key))>this.value}serialize(){return`${this.key} > ${this.value}`}keys(){return[this.key]}negate(){return this.negated||(this.negated=S.create(this.key,this.value,this)),this.negated}}class w{constructor(e,t,i){this.key=e,this.value=t,this.negated=i,this.type=13}static create(e,t,i=null){return v(t,(t=>new w(e,t,i)))}cmp(e){return e.type!==this.type?this.type-e.type:R(this.key,this.value,e.key,e.value)}equals(e){return e.type===this.type&&this.key===e.key&&this.value===e.value}substituteConstants(){return this}evaluate(e){return"string"!=typeof this.value&&parseFloat(e.getValue(this.key))>=this.value}serialize(){return`${this.key} >= ${this.value}`}keys(){return[this.key]}negate(){return this.negated||(this.negated=y.create(this.key,this.value,this)),this.negated}}class y{constructor(e,t,i){this.key=e,this.value=t,this.negated=i,this.type=14}static create(e,t,i=null){return v(t,(t=>new y(e,t,i)))}cmp(e){return e.type!==this.type?this.type-e.type:R(this.key,this.value,e.key,e.value)}equals(e){return e.type===this.type&&this.key===e.key&&this.value===e.value}substituteConstants(){return this}evaluate(e){return"string"!=typeof this.value&&parseFloat(e.getValue(this.key))new S(e,t,i)))}cmp(e){return e.type!==this.type?this.type-e.type:R(this.key,this.value,e.key,e.value)}equals(e){return e.type===this.type&&this.key===e.key&&this.value===e.value}substituteConstants(){return this}evaluate(e){return"string"!=typeof this.value&&parseFloat(e.getValue(this.key))<=this.value}serialize(){return`${this.key} <= ${this.value}`}keys(){return[this.key]}negate(){return this.negated||(this.negated=C.create(this.key,this.value,this)),this.negated}}class x{constructor(e,t){this.key=e,this.regexp=t,this.type=7,this.negated=null}static create(e,t){return new x(e,t)}cmp(e){if(e.type!==this.type)return this.type-e.type;if(this.keye.key)return 1;const t=this.regexp?this.regexp.source:"",i=e.regexp?e.regexp.source:"";return ti?1:0}equals(e){if(e.type===this.type){const t=this.regexp?this.regexp.source:"",i=e.regexp?e.regexp.source:"";return this.key===e.key&&t===i}return!1}substituteConstants(){return this}evaluate(e){let t=e.getValue(this.key);return!!this.regexp&&this.regexp.test(t)}serialize(){const e=this.regexp?`/${this.regexp.source}/${this.regexp.ignoreCase?"i":""}`:"/invalid/";return`${this.key} =~ ${e}`}keys(){return[this.key]}negate(){return this.negated||(this.negated=k.create(this)),this.negated}}class k{constructor(e){this._actual=e,this.type=8}static create(e){return new k(e)}cmp(e){return e.type!==this.type?this.type-e.type:this._actual.cmp(e._actual)}equals(e){return e.type===this.type&&this._actual.equals(e._actual)}substituteConstants(){return this}evaluate(e){return!this._actual.evaluate(e)}serialize(){throw new Error("Method not implemented.")}keys(){return this._actual.keys()}negate(){return this._actual}}function L(e){let t=null;for(let i=0,n=e.length;ie.expr.length)return 1;for(let t=0,i=this.expr.length;t1;){const e=i[i.length-1];if(9!==e.type)break;i.pop();const t=i.pop(),n=0===i.length,o=N.create(e.expr.map((e=>E.create([e,t],null))),null,n);o&&(i.push(o),i.sort(d))}return 1===i.length?i[0]:new E(i,t)}}serialize(){return this.expr.map((e=>e.serialize())).join(" && ")}keys(){const e=[];for(let t of this.expr)e.push(...t.keys());return e}negate(){if(!this.negated){const e=[];for(let t of this.expr)e.push(t.negate());this.negated=N.create(e,this,!0)}return this.negated}}class N{constructor(e,t){this.expr=e,this.negated=t,this.type=9}static create(e,t,i){return N._normalizeArr(e,t,i)}cmp(e){if(e.type!==this.type)return this.type-e.type;if(this.expr.lengthe.expr.length)return 1;for(let t=0,i=this.expr.length;te.serialize())).join(" || ")}keys(){const e=[];for(let t of this.expr)e.push(...t.keys());return e}negate(){if(!this.negated){let e=[];for(let t of this.expr)e.push(t.negate());for(;e.length>1;){const t=e.shift(),i=e.shift(),n=[];for(const e of O(t))for(const t of O(i))n.push(E.create([e,t],null));const o=0===e.length;e.unshift(N.create(n,null,o))}this.negated=e[0]}return this.negated}}class D extends g{constructor(e,t,i){super(e,null),this._defaultValue=t,"object"==typeof i?D._info.push(Object.assign(Object.assign({},i),{key:e})):!0!==i&&D._info.push({key:e,description:i,type:null!=t?typeof t:void 0})}static all(){return D._info.values()}bindTo(e){return e.createKey(this.key,this._defaultValue)}getValue(e){return e.getContextKeyValue(this.key)}toNegated(){return this.negate()}isEqualTo(e){return p.create(this.key,e)}}D._info=[];const I=(0,r.yh)("contextKeyService"),T="setContext";function A(e,t){return et?1:0}function R(e,t,i,n){return ei?1:tn?1:0}function M(e,t){if(6===t.type&&9!==e.type&&6!==e.type)for(const i of t.expr)if(e.equals(i))return!0;const i=O(e.negate()).concat(O(t));i.sort(d);for(let e=0;e{this._onDidOptionChange.fire(e),!e&&this.fixFocusOnOptionClickEnabled&&this.inputBox.focus(),this.validate()}))),this._register(this.regex.onKeyDown((e=>{this._onRegexKeyDown.fire(e)}))),this.wholeWords=this._register(new o.n3({appendTitle:c,isChecked:!1,inputActiveOptionBorder:this.inputActiveOptionBorder,inputActiveOptionForeground:this.inputActiveOptionForeground,inputActiveOptionBackground:this.inputActiveOptionBackground})),this._register(this.wholeWords.onChange((e=>{this._onDidOptionChange.fire(e),!e&&this.fixFocusOnOptionClickEnabled&&this.inputBox.focus(),this.validate()}))),this.caseSensitive=this._register(new o.vk({appendTitle:l,isChecked:!1,inputActiveOptionBorder:this.inputActiveOptionBorder,inputActiveOptionForeground:this.inputActiveOptionForeground,inputActiveOptionBackground:this.inputActiveOptionBackground})),this._register(this.caseSensitive.onChange((e=>{this._onDidOptionChange.fire(e),!e&&this.fixFocusOnOptionClickEnabled&&this.inputBox.focus(),this.validate()}))),this._register(this.caseSensitive.onKeyDown((e=>{this._onCaseSensitiveKeyDown.fire(e)}))),this._showOptionButtons&&(this.inputBox.paddingRight=this.caseSensitive.width()+this.wholeWords.width()+this.regex.width());let m=[this.caseSensitive.domNode,this.wholeWords.domNode,this.regex.domNode];this.onkeydown(this.domNode,(e=>{if(e.equals(15)||e.equals(17)||e.equals(9)){let t=m.indexOf(document.activeElement);if(t>=0){let i=-1;e.equals(17)?i=(t+1)%m.length:e.equals(15)&&(i=0===t?m.length-1:t-1),e.equals(9)?(m[t].blur(),this.inputBox.focus()):i>=0&&m[i].focus(),n.zB.stop(e,!0)}}})),this.controls=document.createElement("div"),this.controls.className="controls",this.controls.style.display=this._showOptionButtons?"block":"none",this.controls.appendChild(this.caseSensitive.domNode),this.controls.appendChild(this.wholeWords.domNode),this.controls.appendChild(this.regex.domNode),this.domNode.appendChild(this.controls),e&&e.appendChild(this.domNode),this._register(n.nm(this.inputBox.inputElement,"compositionstart",(e=>{this.imeSessionInProgress=!0}))),this._register(n.nm(this.inputBox.inputElement,"compositionend",(e=>{this.imeSessionInProgress=!1,this._onInput.fire()}))),this.onkeydown(this.inputBox.inputElement,(e=>this._onKeyDown.fire(e))),this.onkeyup(this.inputBox.inputElement,(e=>this._onKeyUp.fire(e))),this.oninput(this.inputBox.inputElement,(e=>this._onInput.fire())),this.onmousedown(this.inputBox.inputElement,(e=>this._onMouseDown.fire(e)))}enable(){this.domNode.classList.remove("disabled"),this.inputBox.enable(),this.regex.enable(),this.wholeWords.enable(),this.caseSensitive.enable()}disable(){this.domNode.classList.add("disabled"),this.inputBox.disable(),this.regex.disable(),this.wholeWords.disable(),this.caseSensitive.disable()}setFocusInputOnOptionClick(e){this.fixFocusOnOptionClickEnabled=e}setEnabled(e){e?this.enable():this.disable()}getValue(){return this.inputBox.value}setValue(e){this.inputBox.value!==e&&(this.inputBox.value=e)}style(e){this.inputActiveOptionBorder=e.inputActiveOptionBorder,this.inputActiveOptionForeground=e.inputActiveOptionForeground,this.inputActiveOptionBackground=e.inputActiveOptionBackground,this.inputBackground=e.inputBackground,this.inputForeground=e.inputForeground,this.inputBorder=e.inputBorder,this.inputValidationInfoBackground=e.inputValidationInfoBackground,this.inputValidationInfoForeground=e.inputValidationInfoForeground,this.inputValidationInfoBorder=e.inputValidationInfoBorder,this.inputValidationWarningBackground=e.inputValidationWarningBackground,this.inputValidationWarningForeground=e.inputValidationWarningForeground,this.inputValidationWarningBorder=e.inputValidationWarningBorder,this.inputValidationErrorBackground=e.inputValidationErrorBackground,this.inputValidationErrorForeground=e.inputValidationErrorForeground,this.inputValidationErrorBorder=e.inputValidationErrorBorder,this.applyStyles()}applyStyles(){if(this.domNode){const e={inputActiveOptionBorder:this.inputActiveOptionBorder,inputActiveOptionForeground:this.inputActiveOptionForeground,inputActiveOptionBackground:this.inputActiveOptionBackground};this.regex.style(e),this.wholeWords.style(e),this.caseSensitive.style(e);const t={inputBackground:this.inputBackground,inputForeground:this.inputForeground,inputBorder:this.inputBorder,inputValidationInfoBackground:this.inputValidationInfoBackground,inputValidationInfoForeground:this.inputValidationInfoForeground,inputValidationInfoBorder:this.inputValidationInfoBorder,inputValidationWarningBackground:this.inputValidationWarningBackground,inputValidationWarningForeground:this.inputValidationWarningForeground,inputValidationWarningBorder:this.inputValidationWarningBorder,inputValidationErrorBackground:this.inputValidationErrorBackground,inputValidationErrorForeground:this.inputValidationErrorForeground,inputValidationErrorBorder:this.inputValidationErrorBorder};this.inputBox.style(t)}}select(){this.inputBox.select()}focus(){this.inputBox.focus()}getCaseSensitive(){return this.caseSensitive.checked}setCaseSensitive(e){this.caseSensitive.checked=e}getWholeWords(){return this.wholeWords.checked}setWholeWords(e){this.wholeWords.checked=e}getRegex(){return this.regex.checked}setRegex(e){this.regex.checked=e,this.validate()}focusOnCaseSensitive(){this.caseSensitive.focus()}highlightFindOptions(){this.domNode.classList.remove("highlight-"+this._lastHighlightFindOptions),this._lastHighlightFindOptions=1-this._lastHighlightFindOptions,this.domNode.classList.add("highlight-"+this._lastHighlightFindOptions)}validate(){this.inputBox.validate()}clearMessage(){this.inputBox.hideMessage()}}var k=i(98973),L=i(4821);const E=y.NC("vs/base/browser/ui/findinput/replaceInput","defaultLabel","input"),N=y.NC("vs/base/browser/ui/findinput/replaceInput","label.preserveCaseCheckbox","Preserve Case");class D extends k.X{constructor(e){super({icon:L.lA.preserveCase,title:N+e.appendTitle,isChecked:e.isChecked,inputActiveOptionBorder:e.inputActiveOptionBorder,inputActiveOptionForeground:e.inputActiveOptionForeground,inputActiveOptionBackground:e.inputActiveOptionBackground})}}class I extends s.${constructor(e,t,i,o){super(),this._showOptionButtons=i,this.fixFocusOnOptionClickEnabled=!0,this.cachedOptionsWidth=0,this._onDidOptionChange=this._register(new a.Q5),this.onDidOptionChange=this._onDidOptionChange.event,this._onKeyDown=this._register(new a.Q5),this.onKeyDown=this._onKeyDown.event,this._onMouseDown=this._register(new a.Q5),this._onInput=this._register(new a.Q5),this._onKeyUp=this._register(new a.Q5),this._onPreserveCaseKeyDown=this._register(new a.Q5),this.onPreserveCaseKeyDown=this._onPreserveCaseKeyDown.event,this.contextViewProvider=t,this.placeholder=o.placeholder||"",this.validation=o.validation,this.label=o.label||E,this.inputActiveOptionBorder=o.inputActiveOptionBorder,this.inputActiveOptionForeground=o.inputActiveOptionForeground,this.inputActiveOptionBackground=o.inputActiveOptionBackground,this.inputBackground=o.inputBackground,this.inputForeground=o.inputForeground,this.inputBorder=o.inputBorder,this.inputValidationInfoBorder=o.inputValidationInfoBorder,this.inputValidationInfoBackground=o.inputValidationInfoBackground,this.inputValidationInfoForeground=o.inputValidationInfoForeground,this.inputValidationWarningBorder=o.inputValidationWarningBorder,this.inputValidationWarningBackground=o.inputValidationWarningBackground,this.inputValidationWarningForeground=o.inputValidationWarningForeground,this.inputValidationErrorBorder=o.inputValidationErrorBorder,this.inputValidationErrorBackground=o.inputValidationErrorBackground,this.inputValidationErrorForeground=o.inputValidationErrorForeground;const s=o.appendPreserveCaseLabel||"",l=o.history||[],c=!!o.flexibleHeight,d=!!o.flexibleWidth,u=o.flexibleMaxHeight;this.domNode=document.createElement("div"),this.domNode.classList.add("monaco-findInput"),this.inputBox=this._register(new r.p(this.domNode,this.contextViewProvider,{ariaLabel:this.label||"",placeholder:this.placeholder||"",validationOptions:{validation:this.validation},inputBackground:this.inputBackground,inputForeground:this.inputForeground,inputBorder:this.inputBorder,inputValidationInfoBackground:this.inputValidationInfoBackground,inputValidationInfoForeground:this.inputValidationInfoForeground,inputValidationInfoBorder:this.inputValidationInfoBorder,inputValidationWarningBackground:this.inputValidationWarningBackground,inputValidationWarningForeground:this.inputValidationWarningForeground,inputValidationWarningBorder:this.inputValidationWarningBorder,inputValidationErrorBackground:this.inputValidationErrorBackground,inputValidationErrorForeground:this.inputValidationErrorForeground,inputValidationErrorBorder:this.inputValidationErrorBorder,history:l,showHistoryHint:o.showHistoryHint,flexibleHeight:c,flexibleWidth:d,flexibleMaxHeight:u})),this.preserveCase=this._register(new D({appendTitle:s,isChecked:!1,inputActiveOptionBorder:this.inputActiveOptionBorder,inputActiveOptionForeground:this.inputActiveOptionForeground,inputActiveOptionBackground:this.inputActiveOptionBackground})),this._register(this.preserveCase.onChange((e=>{this._onDidOptionChange.fire(e),!e&&this.fixFocusOnOptionClickEnabled&&this.inputBox.focus(),this.validate()}))),this._register(this.preserveCase.onKeyDown((e=>{this._onPreserveCaseKeyDown.fire(e)}))),this._showOptionButtons?this.cachedOptionsWidth=this.preserveCase.width():this.cachedOptionsWidth=0;let h=[this.preserveCase.domNode];this.onkeydown(this.domNode,(e=>{if(e.equals(15)||e.equals(17)||e.equals(9)){let t=h.indexOf(document.activeElement);if(t>=0){let i=-1;e.equals(17)?i=(t+1)%h.length:e.equals(15)&&(i=0===t?h.length-1:t-1),e.equals(9)?(h[t].blur(),this.inputBox.focus()):i>=0&&h[i].focus(),n.zB.stop(e,!0)}}}));let g=document.createElement("div");g.className="controls",g.style.display=this._showOptionButtons?"block":"none",g.appendChild(this.preserveCase.domNode),this.domNode.appendChild(g),e&&e.appendChild(this.domNode),this.onkeydown(this.inputBox.inputElement,(e=>this._onKeyDown.fire(e))),this.onkeyup(this.inputBox.inputElement,(e=>this._onKeyUp.fire(e))),this.oninput(this.inputBox.inputElement,(e=>this._onInput.fire())),this.onmousedown(this.inputBox.inputElement,(e=>this._onMouseDown.fire(e)))}enable(){this.domNode.classList.remove("disabled"),this.inputBox.enable(),this.preserveCase.enable()}disable(){this.domNode.classList.add("disabled"),this.inputBox.disable(),this.preserveCase.disable()}setEnabled(e){e?this.enable():this.disable()}style(e){this.inputActiveOptionBorder=e.inputActiveOptionBorder,this.inputActiveOptionForeground=e.inputActiveOptionForeground,this.inputActiveOptionBackground=e.inputActiveOptionBackground,this.inputBackground=e.inputBackground,this.inputForeground=e.inputForeground,this.inputBorder=e.inputBorder,this.inputValidationInfoBackground=e.inputValidationInfoBackground,this.inputValidationInfoForeground=e.inputValidationInfoForeground,this.inputValidationInfoBorder=e.inputValidationInfoBorder,this.inputValidationWarningBackground=e.inputValidationWarningBackground,this.inputValidationWarningForeground=e.inputValidationWarningForeground,this.inputValidationWarningBorder=e.inputValidationWarningBorder,this.inputValidationErrorBackground=e.inputValidationErrorBackground,this.inputValidationErrorForeground=e.inputValidationErrorForeground,this.inputValidationErrorBorder=e.inputValidationErrorBorder,this.applyStyles()}applyStyles(){if(this.domNode){const e={inputActiveOptionBorder:this.inputActiveOptionBorder,inputActiveOptionForeground:this.inputActiveOptionForeground,inputActiveOptionBackground:this.inputActiveOptionBackground};this.preserveCase.style(e);const t={inputBackground:this.inputBackground,inputForeground:this.inputForeground,inputBorder:this.inputBorder,inputValidationInfoBackground:this.inputValidationInfoBackground,inputValidationInfoForeground:this.inputValidationInfoForeground,inputValidationInfoBorder:this.inputValidationInfoBorder,inputValidationWarningBackground:this.inputValidationWarningBackground,inputValidationWarningForeground:this.inputValidationWarningForeground,inputValidationWarningBorder:this.inputValidationWarningBorder,inputValidationErrorBackground:this.inputValidationErrorBackground,inputValidationErrorForeground:this.inputValidationErrorForeground,inputValidationErrorBorder:this.inputValidationErrorBorder};this.inputBox.style(t)}}select(){this.inputBox.select()}focus(){this.inputBox.focus()}getPreserveCase(){return this.preserveCase.checked}setPreserveCase(e){this.preserveCase.checked=e}focusOnPreserve(){this.preserveCase.focus()}validate(){this.inputBox&&this.inputBox.validate()}set width(e){this.inputBox.paddingRight=this.cachedOptionsWidth,this.inputBox.width=e,this.domNode.style.width=e+"px"}dispose(){super.dispose()}}var T=i(60393),A=i(77101),R=function(e,t,i,n){var o,r=arguments.length,s=r<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,i):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(e,t,i,n);else for(var a=e.length-1;a>=0;a--)(o=e[a])&&(s=(r<3?o(s):r>3?o(t,i,s):o(t,i))||s);return r>3&&s&&Object.defineProperty(t,i,s),s},M=function(e,t){return function(i,n){t(i,n,e)}};const O=new T.uy("suggestWidgetVisible",!1,(0,y.NC)("vs/platform/history/browser/contextScopedHistoryWidget","suggestWidgetVisible","Whether suggestion are visible")),P="historyNavigationWidget",F="historyNavigationForwardsEnabled",B="historyNavigationBackwardsEnabled";function W(e,t){return e.getContext(document.activeElement).getValue(t)}function V(e,t){const i=function(e,t){return e.createScoped(t.target)}(e,t);return function(e,t,i){new T.uy("historyNavigationWidget",t).bindTo(e)}(i,t),{scopedContextKeyService:i,historyNavigationForwardsEnablement:new T.uy(F,!0).bindTo(i),historyNavigationBackwardsEnablement:new T.uy(B,!0).bindTo(i)}}let H=class extends x{constructor(e,t,i,n,o=!1){super(e,t,o,i),this._register(V(n,{target:this.inputBox.element,historyNavigator:this.inputBox}).scopedContextKeyService)}};H=R([M(3,T.i6)],H);let z=class extends I{constructor(e,t,i,n,o=!1){super(e,t,o,i),this._register(V(n,{target:this.inputBox.element,historyNavigator:this.inputBox}).scopedContextKeyService)}};z=R([M(3,T.i6)],z),A.W.registerCommandAndKeybindingRule({id:"history.showPrevious",weight:200,when:T.Ao.and(T.Ao.has(P),T.Ao.equals(B,!0),O.isEqualTo(!1)),primary:16,secondary:[528],handler:e=>{const t=W(e.get(T.i6),P);t&&t.historyNavigator.showPreviousValue()}}),A.W.registerCommandAndKeybindingRule({id:"history.showNext",weight:200,when:T.Ao.and(T.Ao.has(P),T.Ao.equals(F,!0),O.isEqualTo(!1)),primary:18,secondary:[530],handler:e=>{const t=W(e.get(T.i6),P);t&&t.historyNavigator.showNextValue()}})},58778:function(e,t,i){"use strict";i.d(t,{M:function(){return n}});class n{constructor(e,t=[],i=!1){this.ctor=e,this.staticArguments=t,this.supportsDelayedInstantiation=i}}},14472:function(e,t,i){"use strict";i.d(t,{d:function(){return s},z:function(){return r}});var n=i(58778);const o=[];function r(e,t,i){t instanceof n.M||(t=new n.M(t,[],i)),o.push([e,t])}function s(){return o}},12260:function(e,t,i){"use strict";var n;i.d(t,{I8:function(){return n},TG:function(){return o},yh:function(){return s}}),function(e){e.serviceIds=new Map,e.DI_TARGET="$di$target",e.DI_DEPENDENCIES="$di$dependencies",e.getServiceDependencies=function(t){return t[e.DI_DEPENDENCIES]||[]}}(n||(n={}));const o=s("instantiationService");function r(e,t,i){t[n.DI_TARGET]===t?t[n.DI_DEPENDENCIES].push({id:e,index:i}):(t[n.DI_DEPENDENCIES]=[{id:e,index:i}],t[n.DI_TARGET]=t)}function s(e){if(n.serviceIds.has(e))return n.serviceIds.get(e);const t=function(e,i,n){if(3!==arguments.length)throw new Error("@IServiceName-decorator can only be used to decorate a parameter");r(t,e,n)};return t.toString=()=>e,n.serviceIds.set(e,t),t}},97259:function(e,t,i){"use strict";i.d(t,{y:function(){return n}});class n{constructor(...e){this._entries=new Map;for(let[t,i]of e)this.set(t,i)}set(e,t){const i=this._entries.get(e);return this._entries.set(e,t),i}get(e){return this._entries.get(e)}}},32801:function(e,t,i){"use strict";i.d(t,{I:function(){return r}});var n=i(46718),o=i(73403);const r={JSONContribution:"base.contributions.json"},s=new class{constructor(){this._onDidChangeSchema=new n.Q5,this.schemasById={}}registerSchema(e,t){var i;this.schemasById[(i=e,i.length>0&&"#"===i.charAt(i.length-1)?i.substring(0,i.length-1):i)]=t,this._onDidChangeSchema.fire(e)}notifySchemaChanged(e){this._onDidChangeSchema.fire(e)}};o.B.add(r.JSONContribution,s)},67517:function(e,t,i){"use strict";i.d(t,{d:function(){return n}});const n=(0,i(12260).yh)("keybindingService")},77101:function(e,t,i){"use strict";i.d(t,{W:function(){return l}});var n=i(99410),o=i(6954),r=i(14756),s=i(73403);class a{constructor(){this._coreKeybindings=[],this._extensionKeybindings=[],this._cachedMergedKeybindings=null}static bindToCurrentPlatform(e){if(1===o.OS){if(e&&e.win)return e.win}else if(2===o.OS){if(e&&e.mac)return e.mac}else if(e&&e.linux)return e.linux;return e}registerKeybindingRule(e){const t=a.bindToCurrentPlatform(e);if(t&&t.primary){const i=(0,n.gm)(t.primary,o.OS);i&&this._registerDefaultKeybinding(i,e.id,e.args,e.weight,0,e.when)}if(t&&Array.isArray(t.secondary))for(let i=0,r=t.secondary.length;i=21&&e<=30||e>=31&&e<=56||80===e||81===e||82===e||83===e||84===e||85===e||86===e||110===e||111===e||87===e||88===e||89===e||90===e||91===e||92===e}_assertNoCtrlAlt(e,t){e.ctrlKey&&e.altKey&&!e.metaKey&&a._mightProduceChar(e.keyCode)&&console.warn("Ctrl+Alt+ keybindings should not be used by default under Windows. Offender: ",e," for ",t)}_registerDefaultKeybinding(e,t,i,n,r,s){1===o.OS&&this._assertNoCtrlAlt(e.parts[0],t),this._coreKeybindings.push({keybinding:e.parts,command:t,commandArgs:i,when:s,weight1:n,weight2:r,extensionId:null,isBuiltinExtension:!1}),this._cachedMergedKeybindings=null}getDefaultKeybindings(){return this._cachedMergedKeybindings||(this._cachedMergedKeybindings=[].concat(this._coreKeybindings).concat(this._extensionKeybindings),this._cachedMergedKeybindings.sort(c)),this._cachedMergedKeybindings.slice(0)}}const l=new a;function c(e,t){return e.weight1!==t.weight1?e.weight1-t.weight1:e.commandt.command?1:e.weight2-t.weight2}s.B.add("platform.keybindingsRegistry",l)},99125:function(e,t,i){"use strict";i.d(t,{e:function(){return n}});const n=(0,i(12260).yh)("labelService")},69128:function(e,t,i){"use strict";i.d(t,{Lw:function(){return nt},XN:function(){return ot},ls:function(){return $t},ev:function(){return At},CQ:function(){return at},PS:function(){return ht},uJ:function(){return pt}});var n=i(68695),o=i(57800),r=i(60677),s=i(46718),a=i(4004),l=(i(99704),i(77290));class c{constructor(e,t){this.renderer=e,this.modelProvider=t}get templateId(){return this.renderer.templateId}renderTemplate(e){return{data:this.renderer.renderTemplate(e),disposable:a.JT.None}}renderElement(e,t,i,n){if(i.disposable&&i.disposable.dispose(),!i.data)return;const o=this.modelProvider();if(o.isResolved(e))return this.renderer.renderElement(o.get(e),e,i.data,n);const s=new r.A,a=o.resolve(e,s.token);i.disposable={dispose:()=>s.cancel()},this.renderer.renderPlaceholder(e,i.data),a.then((t=>this.renderer.renderElement(t,e,i.data,n)))}disposeTemplate(e){e.disposable&&(e.disposable.dispose(),e.disposable=void 0),e.data&&(this.renderer.disposeTemplate(e.data),e.data=void 0)}}class d{constructor(e,t){this.modelProvider=e,this.accessibilityProvider=t}getWidgetAriaLabel(){return this.accessibilityProvider.getWidgetAriaLabel()}getAriaLabel(e){const t=this.modelProvider();return t.isResolved(e)?this.accessibilityProvider.getAriaLabel(t.get(e)):null}}var u=i(92987),h=i(93379),g=i.n(h),p=i(7795),m=i.n(p),f=i(90569),_=i.n(f),b=i(3565),v=i.n(b),C=i(19216),w=i.n(C),y=i(44589),S=i.n(y),x=i(51383),k={};k.styleTagTransform=S(),k.setAttributes=v(),k.insert=_().bind(null,"head"),k.domAPI=m(),k.insertStyleElement=w(),g()(x.Z,k),x.Z&&x.Z.locals&&x.Z.locals;class L{constructor(e,t,i){this.columns=e,this.getColumnSize=i,this.templateId=L.TemplateId,this.renderedTemplates=new Set;const n=new Map(t.map((e=>[e.templateId,e])));this.renderers=[];for(const t of e){const e=n.get(t.templateId);if(!e)throw new Error(`Table cell renderer for template id ${t.templateId} not found.`);this.renderers.push(e)}}renderTemplate(e){const t=(0,n.R3)(e,(0,n.$)(".monaco-table-tr")),i=[],o=[];for(let e=0;enew E(e,t))),h={size:d.reduce(((e,t)=>e+t.column.weight),0),views:d.map((e=>({size:e.column.weight,view:e})))};this.splitview=this.disposables.add(new u.z(this.domNode,{orientation:1,scrollbarVisibility:2,getSashOrthogonalSize:()=>this.cachedHeight,descriptor:h})),this.splitview.el.style.height=`${i.headerRowHeight}px`,this.splitview.el.style.lineHeight=`${i.headerRowHeight}px`;const g=new L(o,r,(e=>this.splitview.getViewSize(e)));var p;this.list=this.disposables.add(new l.aV(e,this.domNode,(p=i,{getHeight:e=>p.getHeight(e),getTemplateId:()=>L.TemplateId}),[g],c)),s.ju.any(...d.map((e=>e.onDidLayout)))((([e,t])=>g.layoutColumn(e,t)),null,this.disposables),this.splitview.onDidSashReset((e=>{const t=o.reduce(((e,t)=>e+t.weight),0),i=o[e].weight/t*this.cachedWidth;this.splitview.resizeView(e,i)}),null,this.disposables),this.styleElement=(0,n.dS)(this.domNode),this.style({})}get onDidChangeFocus(){return this.list.onDidChangeFocus}get onDidChangeSelection(){return this.list.onDidChangeSelection}get onMouseDblClick(){return this.list.onMouseDblClick}get onPointer(){return this.list.onPointer}get onDidFocus(){return this.list.onDidFocus}get onDidDispose(){return this.list.onDidDispose}updateOptions(e){this.list.updateOptions(e)}splice(e,t,i=[]){this.list.splice(e,t,i)}getHTMLElement(){return this.domNode}style(e){const t=[];t.push(`.monaco-table.${this.domId} > .monaco-split-view2 .monaco-sash.vertical::before {\n\t\t\ttop: ${this.virtualDelegate.headerRowHeight+1}px;\n\t\t\theight: calc(100% - ${this.virtualDelegate.headerRowHeight}px);\n\t\t}`),this.styleElement.textContent=t.join("\n"),this.list.style(e)}getSelectedElements(){return this.list.getSelectedElements()}getSelection(){return this.list.getSelection()}getFocus(){return this.list.getFocus()}dispose(){this.disposables.dispose()}}N.InstanceCount=0;var D,I=i(20768),T=i(42560),A=i(27163),R=i(33200);!function(e){e[e.Unknown=0]="Unknown",e[e.Twistie=1]="Twistie",e[e.Element=2]="Element"}(D||(D={}));class M extends Error{constructor(e,t){super(`TreeError [${e}] ${t}`)}}class O{constructor(e){this.fn=e,this._map=new WeakMap}map(e){let t=this._map.get(e);return t||(t=this.fn(e),this._map.set(e,t)),t}}var P=i(40027),F=i(53276),B=i(44780);function W(e){return"object"==typeof e&&"visibility"in e&&"data"in e}function V(e){switch(e){case!0:return 1;case!1:return 0;default:return e}}function H(e){return"boolean"==typeof e.collapsible}class z{constructor(e,t,i,n={}){this.user=e,this.list=t,this.rootRef=[],this.eventBufferer=new s.E7,this._onDidChangeCollapseState=new s.Q5,this.onDidChangeCollapseState=this.eventBufferer.wrapEvent(this._onDidChangeCollapseState.event),this._onDidChangeRenderNodeCount=new s.Q5,this.onDidChangeRenderNodeCount=this.eventBufferer.wrapEvent(this._onDidChangeRenderNodeCount.event),this._onDidSplice=new s.Q5,this.onDidSplice=this._onDidSplice.event,this.refilterDelayer=new P.vp(P.ne),this.collapseByDefault=void 0!==n.collapseByDefault&&n.collapseByDefault,this.filter=n.filter,this.autoExpandSingleChildren=void 0!==n.autoExpandSingleChildren&&n.autoExpandSingleChildren,this.root={parent:void 0,element:i,children:[],depth:0,visibleChildrenCount:0,visibleChildIndex:-1,collapsible:!1,collapsed:!1,renderNodeCount:0,visibility:1,visible:!0,filterData:void 0}}splice(e,t,i=B.$.empty(),n={}){if(0===e.length)throw new M(this.user,"Invalid tree location");n.diffIdentityProvider?this.spliceSmart(n.diffIdentityProvider,e,t,i,n):this.spliceSimple(e,t,i,n)}spliceSmart(e,t,i,n,o,r){var s;void 0===n&&(n=B.$.empty()),void 0===r&&(r=null!==(s=o.diffDepth)&&void 0!==s?s:0);const{parentNode:a}=this.getParentNodeWithListIndex(t);if(!a.lastDiffIds)return this.spliceSimple(t,i,n,o);const l=[...n],c=t[t.length-1],d=new F.Hs({getElements:()=>a.lastDiffIds},{getElements:()=>[...a.children.slice(0,c),...l,...a.children.slice(c+i)].map((t=>e.getId(t.element).toString()))}).ComputeDiff(!1);if(d.quitEarly)return a.lastDiffIds=void 0,this.spliceSimple(t,i,l,o);const u=t.slice(0,-1),h=(t,i,n)=>{if(r>0)for(let s=0;st.originalStart-e.originalStart)))h(g,p,g-(e.originalStart+e.originalLength)),g=e.originalStart,p=e.modifiedStart-c,this.spliceSimple([...u,g],e.originalLength,B.$.slice(l,p,p+e.modifiedLength),o);h(g,p,g)}spliceSimple(e,t,i=B.$.empty(),{onDidCreateNode:n,onDidDeleteNode:r,diffIdentityProvider:s}){const{parentNode:a,listIndex:l,revealed:c,visible:d}=this.getParentNodeWithListIndex(e),u=[],h=B.$.map(i,(e=>this.createTreeNode(e,a,a.visible?1:0,c,u,n))),g=e[e.length-1],p=a.children.length>0;let m=0;for(let e=g;e>=0&&es.getId(e.element).toString()))):a.lastDiffIds=a.children.map((e=>s.getId(e.element).toString())):a.lastDiffIds=void 0;let C=0;for(const e of v)e.visible&&C++;if(0!==C)for(let e=g+f.length;ee+(t.visible?t.renderNodeCount:0)),0);this._updateAncestorsRenderNodeCount(a,b-e),this.list.splice(l,e,u)}if(v.length>0&&r){const e=t=>{r(t),t.children.forEach(e)};v.forEach(e)}this._onDidSplice.fire({insertedNodes:f,deletedNodes:v});const w=a.children.length>0;p!==w&&this.setCollapsible(e.slice(0,-1),w);let y=a;for(;y;){if(2===y.visibility){this.refilterDelayer.trigger((()=>this.refilter()));break}y=y.parent}}rerender(e){if(0===e.length)throw new M(this.user,"Invalid tree location");const{node:t,listIndex:i,revealed:n}=this.getTreeNodeWithListIndex(e);t.visible&&n&&this.list.splice(i,1,[t])}has(e){return this.hasTreeNode(e)}getListIndex(e){const{listIndex:t,visible:i,revealed:n}=this.getTreeNodeWithListIndex(e);return i&&n?t:-1}getListRenderCount(e){return this.getTreeNode(e).renderNodeCount}isCollapsible(e){return this.getTreeNode(e).collapsible}setCollapsible(e,t){const i=this.getTreeNode(e);void 0===t&&(t=!i.collapsible);const n={collapsible:t};return this.eventBufferer.bufferEvents((()=>this._setCollapseState(e,n)))}isCollapsed(e){return this.getTreeNode(e).collapsed}setCollapsed(e,t,i){const n=this.getTreeNode(e);void 0===t&&(t=!n.collapsed);const o={collapsed:t,recursive:i||!1};return this.eventBufferer.bufferEvents((()=>this._setCollapseState(e,o)))}_setCollapseState(e,t){const{node:i,listIndex:n,revealed:o}=this.getTreeNodeWithListIndex(e),r=this._setListNodeCollapseState(i,n,o,t);if(i!==this.root&&this.autoExpandSingleChildren&&r&&!H(t)&&i.collapsible&&!i.collapsed&&!t.recursive){let n=-1;for(let e=0;e-1){n=-1;break}n=e}n>-1&&this._setCollapseState([...e,n],t)}return r}_setListNodeCollapseState(e,t,i,n){const o=this._setNodeCollapseState(e,n,!1);if(!i||!e.visible||!o)return o;const r=e.renderNodeCount,s=this.updateNodeAfterCollapseChange(e),a=r-(-1===t?0:1);return this.list.splice(t+1,a,s.slice(1)),o}_setNodeCollapseState(e,t,i){let n;if(e===this.root?n=!1:(H(t)?(n=e.collapsible!==t.collapsible,e.collapsible=t.collapsible):e.collapsible?(n=e.collapsed!==t.collapsed,e.collapsed=t.collapsed):n=!1,n&&this._onDidChangeCollapseState.fire({node:e,deep:i})),!H(t)&&t.recursive)for(const i of e.children)n=this._setNodeCollapseState(i,t,!0)||n;return n}expandTo(e){this.eventBufferer.bufferEvents((()=>{let t=this.getTreeNode(e);for(;t.parent;)t=t.parent,e=e.slice(0,e.length-1),t.collapsed&&this._setCollapseState(e,{collapsed:!1,recursive:!1})}))}refilter(){const e=this.root.renderNodeCount,t=this.updateNodeAfterFilterChange(this.root);this.list.splice(0,e,t),this.refilterDelayer.cancel()}createTreeNode(e,t,i,n,o,r){const s={parent:t,element:e.element,children:[],depth:t.depth+1,visibleChildrenCount:0,visibleChildIndex:-1,collapsible:"boolean"==typeof e.collapsible?e.collapsible:void 0!==e.collapsed,collapsed:void 0===e.collapsed?this.collapseByDefault:e.collapsed,renderNodeCount:1,visibility:1,visible:!0,filterData:void 0},a=this._filterNode(s,i);s.visibility=a,n&&o.push(s);const l=e.children||B.$.empty(),c=n&&0!==a&&!s.collapsed,d=B.$.map(l,(e=>this.createTreeNode(e,s,a,c,o,r)));let u=0,h=1;for(const e of d)s.children.push(e),h+=e.renderNodeCount,e.visible&&(e.visibleChildIndex=u++);return s.collapsible=s.collapsible||s.children.length>0,s.visibleChildrenCount=u,s.visible=2===a?u>0:1===a,s.visible?s.collapsed||(s.renderNodeCount=h):(s.renderNodeCount=0,n&&o.pop()),r&&r(s),s}updateNodeAfterCollapseChange(e){const t=e.renderNodeCount,i=[];return this._updateNodeAfterCollapseChange(e,i),this._updateAncestorsRenderNodeCount(e.parent,i.length-t),i}_updateNodeAfterCollapseChange(e,t){if(!1===e.visible)return 0;if(t.push(e),e.renderNodeCount=1,!e.collapsed)for(const i of e.children)e.renderNodeCount+=this._updateNodeAfterCollapseChange(i,t);return this._onDidChangeRenderNodeCount.fire(e),e.renderNodeCount}updateNodeAfterFilterChange(e){const t=e.renderNodeCount,i=[];return this._updateNodeAfterFilterChange(e,e.visible?1:0,i),this._updateAncestorsRenderNodeCount(e.parent,i.length-t),i}_updateNodeAfterFilterChange(e,t,i,n=!0){let o;if(e!==this.root){if(o=this._filterNode(e,t),0===o)return e.visible=!1,e.renderNodeCount=0,!1;n&&i.push(e)}const r=i.length;e.renderNodeCount=e===this.root?0:1;let s=!1;if(e.collapsed&&0===o)e.visibleChildrenCount=0;else{let t=0;for(const r of e.children)s=this._updateNodeAfterFilterChange(r,o,i,n&&!e.collapsed)||s,r.visible&&(r.visibleChildIndex=t++);e.visibleChildrenCount=t}return e!==this.root&&(e.visible=2===o?s:1===o,e.visibility=o),e.visible?e.collapsed||(e.renderNodeCount+=i.length-r):(e.renderNodeCount=0,n&&i.pop()),this._onDidChangeRenderNodeCount.fire(e),e.visible}_updateAncestorsRenderNodeCount(e,t){if(0!==t)for(;e;)e.renderNodeCount+=t,this._onDidChangeRenderNodeCount.fire(e),e=e.parent}_filterNode(e,t){const i=this.filter?this.filter.filter(e.element,t):1;return"boolean"==typeof i?(e.filterData=void 0,i?1:0):W(i)?(e.filterData=i.data,V(i.visibility)):(e.filterData=void 0,V(i))}hasTreeNode(e,t=this.root){if(!e||0===e.length)return!0;const[i,...n]=e;return!(i<0||i>t.children.length)&&this.hasTreeNode(n,t.children[i])}getTreeNode(e,t=this.root){if(!e||0===e.length)return t;const[i,...n]=e;if(i<0||i>t.children.length)throw new M(this.user,"Invalid tree location");return this.getTreeNode(n,t.children[i])}getTreeNodeWithListIndex(e){if(0===e.length)return{node:this.root,listIndex:-1,revealed:!0,visible:!1};const{parentNode:t,listIndex:i,revealed:n,visible:o}=this.getParentNodeWithListIndex(e),r=e[e.length-1];if(r<0||r>t.children.length)throw new M(this.user,"Invalid tree location");const s=t.children[r];return{node:s,listIndex:i,revealed:n,visible:o&&s.visible}}getParentNodeWithListIndex(e,t=this.root,i=0,n=!0,o=!0){const[r,...s]=e;if(r<0||r>t.children.length)throw new M(this.user,"Invalid tree location");for(let e=0;ee.element))),this.data=e}}function J(e){return e instanceof I.kX?new X(e):e}class ee{constructor(e,t){this.modelProvider=e,this.dnd=t,this.autoExpandDisposable=a.JT.None}getDragURI(e){return this.dnd.getDragURI(e.element)}getDragLabel(e,t){if(this.dnd.getDragLabel)return this.dnd.getDragLabel(e.map((e=>e.element)),t)}onDragStart(e,t){this.dnd.onDragStart&&this.dnd.onDragStart(J(e),t)}onDragOver(e,t,i,n,r=!0){const s=this.dnd.onDragOver(J(e),t&&t.element,i,n),a=this.autoExpandNode!==t;if(a&&(this.autoExpandDisposable.dispose(),this.autoExpandNode=t),void 0===t)return s;if(a&&"boolean"!=typeof s&&s.autoExpand&&(this.autoExpandDisposable=(0,P.Vg)((()=>{const e=this.modelProvider(),i=e.getNodeLocation(t);e.isCollapsed(i)&&e.setCollapsed(i,!1),this.autoExpandNode=void 0}),500)),"boolean"==typeof s||!s.accept||void 0===s.bubble||s.feedback)return r?s:{accept:"boolean"==typeof s?s:s.accept,effect:"boolean"==typeof s?void 0:s.effect,feedback:[i]};if(1===s.bubble){const i=this.modelProvider(),o=i.getNodeLocation(t),r=i.getParentNodeLocation(o),s=i.getNode(r),a=r&&i.getListIndex(r);return this.onDragOver(e,s,a,n,!1)}const l=this.modelProvider(),c=l.getNodeLocation(t),d=l.getListIndex(c),u=l.getListRenderCount(c);return Object.assign(Object.assign({},s),{feedback:(0,o.w6)(d,d+u)})}drop(e,t,i,n){this.autoExpandDisposable.dispose(),this.autoExpandNode=void 0,this.dnd.drop(J(e),t&&t.element,i,n)}onDragEnd(e){this.dnd.onDragEnd&&this.dnd.onDragEnd(e)}}class te{constructor(e){this.delegate=e}getHeight(e){return this.delegate.getHeight(e.element)}getTemplateId(e){return this.delegate.getTemplateId(e.element)}hasDynamicHeight(e){return!!this.delegate.hasDynamicHeight&&this.delegate.hasDynamicHeight(e.element)}setDynamicHeight(e,t){this.delegate.setDynamicHeight&&this.delegate.setDynamicHeight(e.element,t)}}!function(e){e.None="none",e.OnHover="onHover",e.Always="always"}(Y||(Y={}));class ie{constructor(e,t=[]){this._elements=t,this.onDidChange=s.ju.forEach(e,(e=>this._elements=e))}get elements(){return this._elements}}class ne{constructor(e,t,i,n,o={}){this.renderer=e,this.modelProvider=t,this.activeNodes=n,this.renderedElements=new Map,this.renderedNodes=new Map,this.indent=ne.DefaultIndent,this.hideTwistiesOfChildlessElements=!1,this.shouldRenderIndentGuides=!1,this.renderedIndentGuides=new U.r,this.activeIndentNodes=new Set,this.indentGuidesDisposable=a.JT.None,this.disposables=new a.SL,this.templateId=e.templateId,this.updateOptions(o),s.ju.map(i,(e=>e.node))(this.onDidChangeNodeTwistieState,this,this.disposables),e.onDidChangeTwistieState&&e.onDidChangeTwistieState(this.onDidChangeTwistieState,this,this.disposables)}updateOptions(e={}){if(void 0!==e.indent&&(this.indent=(0,K.uZ)(e.indent,0,40)),void 0!==e.renderIndentGuides){const t=e.renderIndentGuides!==Y.None;if(t!==this.shouldRenderIndentGuides&&(this.shouldRenderIndentGuides=t,this.indentGuidesDisposable.dispose(),t)){const e=new a.SL;this.activeNodes.onDidChange(this._onDidChangeActiveNodes,this,e),this.indentGuidesDisposable=e,this._onDidChangeActiveNodes(this.activeNodes.elements)}}void 0!==e.hideTwistiesOfChildlessElements&&(this.hideTwistiesOfChildlessElements=e.hideTwistiesOfChildlessElements)}renderTemplate(e){const t=(0,n.R3)(e,(0,n.$)(".monaco-tl-row")),i=(0,n.R3)(t,(0,n.$)(".monaco-tl-indent")),o=(0,n.R3)(t,(0,n.$)(".monaco-tl-twistie")),r=(0,n.R3)(t,(0,n.$)(".monaco-tl-contents")),s=this.renderer.renderTemplate(r);return{container:e,indent:i,twistie:o,indentGuidesDisposable:a.JT.None,templateData:s}}renderElement(e,t,i,n){"number"==typeof n&&(this.renderedNodes.set(e,{templateData:i,height:n}),this.renderedElements.set(e.element,e));const o=ne.DefaultIndent+(e.depth-1)*this.indent;i.twistie.style.paddingLeft=`${o}px`,i.indent.style.width=o+this.indent-16+"px",this.renderTwistie(e,i),"number"==typeof n&&this.renderIndentGuides(e,i),this.renderer.renderElement(e,t,i.templateData,n)}disposeElement(e,t,i,n){i.indentGuidesDisposable.dispose(),this.renderer.disposeElement&&this.renderer.disposeElement(e,t,i.templateData,n),"number"==typeof n&&(this.renderedNodes.delete(e),this.renderedElements.delete(e.element))}disposeTemplate(e){this.renderer.disposeTemplate(e.templateData)}onDidChangeTwistieState(e){const t=this.renderedElements.get(e);t&&this.onDidChangeNodeTwistieState(t)}onDidChangeNodeTwistieState(e){const t=this.renderedNodes.get(e);t&&(this.renderTwistie(e,t.templateData),this._onDidChangeActiveNodes(this.activeNodes.elements),this.renderIndentGuides(e,t.templateData))}renderTwistie(e,t){t.twistie.classList.remove(...$.lA.treeItemExpanded.classNamesArray);let i=!1;this.renderer.renderTwistie&&(i=this.renderer.renderTwistie(e.element,t.twistie)),e.collapsible&&(!this.hideTwistiesOfChildlessElements||e.visibleChildrenCount>0)?(i||t.twistie.classList.add(...$.lA.treeItemExpanded.classNamesArray),t.twistie.classList.add("collapsible"),t.twistie.classList.toggle("collapsed",e.collapsed)):t.twistie.classList.remove("collapsible","collapsed"),e.collapsible?t.container.setAttribute("aria-expanded",String(!e.collapsed)):t.container.removeAttribute("aria-expanded")}renderIndentGuides(e,t){if((0,n.PO)(t.indent),t.indentGuidesDisposable.dispose(),!this.shouldRenderIndentGuides)return;const i=new a.SL,o=this.modelProvider();let r=e;for(;;){const e=o.getNodeLocation(r),s=o.getParentNodeLocation(e);if(!s)break;const l=o.getNode(s),c=(0,n.$)(".indent-guide",{style:`width: ${this.indent}px`});this.activeIndentNodes.has(l)&&c.classList.add("active"),0===t.indent.childElementCount?t.indent.appendChild(c):t.indent.insertBefore(c,t.indent.firstElementChild),this.renderedIndentGuides.add(l,c),i.add((0,a.OF)((()=>this.renderedIndentGuides.delete(l,c)))),r=l}t.indentGuidesDisposable=i}_onDidChangeActiveNodes(e){if(!this.shouldRenderIndentGuides)return;const t=new Set,i=this.modelProvider();e.forEach((e=>{const n=i.getNodeLocation(e);try{const o=i.getParentNodeLocation(n);e.collapsible&&e.children.length>0&&!e.collapsed?t.add(e):o&&t.add(i.getNode(o))}catch(e){}})),this.activeIndentNodes.forEach((e=>{t.has(e)||this.renderedIndentGuides.forEach(e,(e=>e.classList.remove("active")))})),t.forEach((e=>{this.activeIndentNodes.has(e)||this.renderedIndentGuides.forEach(e,(e=>e.classList.add("active")))})),this.activeIndentNodes=t}dispose(){this.renderedNodes.clear(),this.renderedElements.clear(),this.indentGuidesDisposable.dispose(),(0,a.B9)(this.disposables)}}ne.DefaultIndent=8;class oe{constructor(e,t,i){this.tree=e,this.keyboardNavigationLabelProvider=t,this._filter=i,this._totalCount=0,this._matchCount=0,this._pattern="",this._lowercasePattern="",this.disposables=new a.SL,e.onWillRefilter(this.reset,this,this.disposables)}get totalCount(){return this._totalCount}get matchCount(){return this._matchCount}set pattern(e){this._pattern=e,this._lowercasePattern=e.toLowerCase()}filter(e,t){if(this._filter){const i=this._filter.filter(e,t);if(this.tree.options.simpleKeyboardNavigation)return i;let n;if(n="boolean"==typeof i?i?1:0:W(i)?V(i.visibility):i,0===n)return!1}if(this._totalCount++,this.tree.options.simpleKeyboardNavigation||!this._pattern)return this._matchCount++,{data:j.CL.Default,visibility:!0};const i=this.keyboardNavigationLabelProvider.getKeyboardNavigationLabel(e),n=Array.isArray(i)?i:[i];for(const e of n){const t=e&&e.toString();if(void 0===t)return{data:j.CL.Default,visibility:!0};const i=(0,j.EW)(this._pattern,this._lowercasePattern,0,t,t.toLowerCase(),0,!0);if(i)return this._matchCount++,1===n.length?{data:i,visibility:!0}:{data:{label:t,score:i},visibility:!0}}return this.tree.options.filterOnType?2:{data:j.CL.Default,visibility:!0}}reset(){this._totalCount=0,this._matchCount=0}dispose(){(0,a.B9)(this.disposables)}}class re{constructor(e,t,i,o,r){this.tree=e,this.view=i,this.filter=o,this.keyboardNavigationDelegate=r,this._enabled=!1,this._pattern="",this._empty=!1,this._onDidChangeEmptyState=new s.Q5,this.positionClassName="ne",this.automaticKeyboardNavigation=!0,this.triggered=!1,this._onDidChangePattern=new s.Q5,this.enabledDisposables=new a.SL,this.disposables=new a.SL,this.domNode=(0,n.$)(`.monaco-list-type-filter.${this.positionClassName}`),this.domNode.draggable=!0,this.disposables.add((0,n.nm)(this.domNode,"dragstart",(()=>this.onDragStart()))),this.messageDomNode=(0,n.R3)(i.getHTMLElement(),(0,n.$)(".monaco-list-type-filter-message")),this.labelDomNode=(0,n.R3)(this.domNode,(0,n.$)("span.label"));const l=(0,n.R3)(this.domNode,(0,n.$)(".controls"));this._filterOnType=!!e.options.filterOnType,this.filterOnTypeDomNode=(0,n.R3)(l,(0,n.$)("input.filter")),this.filterOnTypeDomNode.type="checkbox",this.filterOnTypeDomNode.checked=this._filterOnType,this.filterOnTypeDomNode.tabIndex=-1,this.updateFilterOnTypeTitleAndIcon(),this.disposables.add((0,n.nm)(this.filterOnTypeDomNode,"input",(()=>this.onDidChangeFilterOnType()))),this.clearDomNode=(0,n.R3)(l,(0,n.$)("button.clear"+$.lA.treeFilterClear.cssSelector)),this.clearDomNode.tabIndex=-1,this.clearDomNode.title=(0,Q.NC)("vs/base/browser/ui/tree/abstractTree","clear","Clear"),this.keyboardNavigationEventFilter=e.options.keyboardNavigationEventFilter,t.onDidSplice(this.onDidSpliceModel,this,this.disposables),this.updateOptions(e.options)}get enabled(){return this._enabled}get pattern(){return this._pattern}get filterOnType(){return this._filterOnType}updateOptions(e){e.simpleKeyboardNavigation?this.disable():this.enable(),void 0!==e.filterOnType&&(this._filterOnType=!!e.filterOnType,this.filterOnTypeDomNode.checked=this._filterOnType,this.updateFilterOnTypeTitleAndIcon()),void 0!==e.automaticKeyboardNavigation&&(this.automaticKeyboardNavigation=e.automaticKeyboardNavigation),this.tree.refilter(),this.render(),this.automaticKeyboardNavigation||this.onEventOrInput("")}enable(){if(this._enabled)return;const e=this.enabledDisposables.add(new A.Y(this.view.getHTMLElement(),"keydown")),t=s.ju.chain(e.event).filter((e=>!(0,l.cK)(e.target)||e.target===this.filterOnTypeDomNode)).filter((e=>"Dead"!==e.key&&!/^Media/.test(e.key))).map((e=>new R.y(e))).filter(this.keyboardNavigationEventFilter||(()=>!0)).filter((()=>this.automaticKeyboardNavigation||this.triggered)).filter((e=>this.keyboardNavigationDelegate.mightProducePrintableCharacter(e)&&!(18===e.keyCode||16===e.keyCode||15===e.keyCode||17===e.keyCode)||(this.pattern.length>0||this.triggered)&&(9===e.keyCode||1===e.keyCode)&&!e.altKey&&!e.ctrlKey&&!e.metaKey||1===e.keyCode&&(q.dz?e.altKey&&!e.metaKey:e.ctrlKey)&&!e.shiftKey)).forEach((e=>{e.stopPropagation(),e.preventDefault()})).event,i=this.enabledDisposables.add(new A.Y(this.clearDomNode,"click"));s.ju.chain(s.ju.any(t,i.event)).event(this.onEventOrInput,this,this.enabledDisposables),this.filter.pattern="",this.tree.refilter(),this.render(),this._enabled=!0,this.triggered=!1}disable(){this._enabled&&(this.domNode.remove(),this.enabledDisposables.clear(),this.tree.refilter(),this.render(),this._enabled=!1,this.triggered=!1)}onEventOrInput(e){"string"==typeof e?this.onInput(e):e instanceof MouseEvent||9===e.keyCode||1===e.keyCode&&(q.dz?e.altKey:e.ctrlKey)?this.onInput(""):1===e.keyCode?this.onInput(0===this.pattern.length?"":this.pattern.substr(0,this.pattern.length-1)):this.onInput(this.pattern+e.browserEvent.key)}onInput(e){const t=this.view.getHTMLElement();e&&!this.domNode.parentElement?t.append(this.domNode):!e&&this.domNode.parentElement&&(this.domNode.remove(),this.tree.domFocus()),this._pattern=e,this._onDidChangePattern.fire(e),this.filter.pattern=e,this.tree.refilter(),e&&this.tree.focusNext(0,!0,void 0,(e=>!j.CL.isDefault(e.filterData)));const i=this.tree.getFocus();if(i.length>0){const e=i[0];null===this.tree.getRelativeTop(e)&&this.tree.reveal(e,.5)}this.render(),e||(this.triggered=!1)}onDragStart(){const e=this.view.getHTMLElement(),{left:t}=(0,n.i)(e),i=e.clientWidth,o=i/2,r=this.domNode.clientWidth,s=new a.SL;let l=this.positionClassName;const c=()=>{switch(l){case"nw":this.domNode.style.top="4px",this.domNode.style.left="4px";break;case"ne":this.domNode.style.top="4px",this.domNode.style.left=i-r-6+"px"}},d=()=>{this.positionClassName=l,this.domNode.className=`monaco-list-type-filter ${this.positionClassName}`,this.domNode.style.top="",this.domNode.style.left="",(0,a.B9)(s)};c(),this.domNode.classList.remove(l),this.domNode.classList.add("dragging"),s.add((0,a.OF)((()=>this.domNode.classList.remove("dragging")))),s.add((0,n.nm)(document,"dragover",(e=>(e=>{e.preventDefault();const i=e.clientX-t;e.dataTransfer&&(e.dataTransfer.dropEffect="none"),l=id()))),T.P$.CurrentDragAndDropData=new T.TN("vscode-ui"),s.add((0,a.OF)((()=>T.P$.CurrentDragAndDropData=void 0)))}onDidSpliceModel(){this._enabled&&0!==this.pattern.length&&(this.tree.refilter(),this.render())}onDidChangeFilterOnType(){this.tree.updateOptions({filterOnType:this.filterOnTypeDomNode.checked}),this.tree.refilter(),this.tree.domFocus(),this.render(),this.updateFilterOnTypeTitleAndIcon()}updateFilterOnTypeTitleAndIcon(){this.filterOnType?(this.filterOnTypeDomNode.classList.remove(...$.lA.treeFilterOnTypeOff.classNamesArray),this.filterOnTypeDomNode.classList.add(...$.lA.treeFilterOnTypeOn.classNamesArray),this.filterOnTypeDomNode.title=(0,Q.NC)("vs/base/browser/ui/tree/abstractTree","disable filter on type","Disable Filter on Type")):(this.filterOnTypeDomNode.classList.remove(...$.lA.treeFilterOnTypeOn.classNamesArray),this.filterOnTypeDomNode.classList.add(...$.lA.treeFilterOnTypeOff.classNamesArray),this.filterOnTypeDomNode.title=(0,Q.NC)("vs/base/browser/ui/tree/abstractTree","enable filter on type","Enable Filter on Type"))}render(){const e=this.filter.totalCount>0&&0===this.filter.matchCount;this.pattern&&this.tree.options.filterOnType&&e?(this.messageDomNode.textContent=(0,Q.NC)("vs/base/browser/ui/tree/abstractTree","empty","No elements found"),this._empty=!0):(this.messageDomNode.innerText="",this._empty=!1),this.domNode.classList.toggle("no-matches",e),this.domNode.title=(0,Q.NC)("vs/base/browser/ui/tree/abstractTree","found","Matched {0} out of {1} elements",this.filter.matchCount,this.filter.totalCount),this.labelDomNode.textContent=this.pattern.length>16?"…"+this.pattern.substr(this.pattern.length-16):this.pattern,this._onDidChangeEmptyState.fire(this._empty)}shouldAllowFocus(e){return!(this.enabled&&this.pattern&&!this.filterOnType)||this.filter.totalCount>0&&this.filter.matchCount<=1||!j.CL.isDefault(e.filterData)}dispose(){this._enabled&&(this.domNode.remove(),this.enabledDisposables.dispose(),this._enabled=!1,this.triggered=!1),this._onDidChangePattern.dispose(),(0,a.B9)(this.disposables)}}function se(e){let t=D.Unknown;return(0,n.uU)(e.browserEvent.target,"monaco-tl-twistie","monaco-tl-row")?t=D.Twistie:(0,n.uU)(e.browserEvent.target,"monaco-tl-contents","monaco-tl-row")&&(t=D.Element),{browserEvent:e.browserEvent,element:e.element?e.element.element:null,target:t}}function ae(e,t){t(e),e.children.forEach((e=>ae(e,t)))}class le{constructor(e,t){this.getFirstViewElementWithTrait=e,this.identityProvider=t,this.nodes=[],this._onDidChange=new s.Q5,this.onDidChange=this._onDidChange.event}get nodeSet(){return this._nodeSet||(this._nodeSet=this.createNodeSet()),this._nodeSet}set(e,t){!(null==t?void 0:t.__forceEvent)&&(0,o.fS)(this.nodes,e)||this._set(e,!1,t)}_set(e,t,i){if(this.nodes=[...e],this.elements=void 0,this._nodeSet=void 0,!t){const e=this;this._onDidChange.fire({get elements(){return e.get()},browserEvent:i})}}get(){return this.elements||(this.elements=this.nodes.map((e=>e.element))),[...this.elements]}getNodes(){return this.nodes}has(e){return this.nodeSet.has(e)}onDidModelSplice({insertedNodes:e,deletedNodes:t}){if(!this.identityProvider){const e=this.createNodeSet(),i=t=>e.delete(t);return t.forEach((e=>ae(e,i))),void this.set([...e.values()])}const i=new Set,n=e=>i.add(this.identityProvider.getId(e.element).toString());t.forEach((e=>ae(e,n)));const o=new Map,r=e=>o.set(this.identityProvider.getId(e.element).toString(),e);e.forEach((e=>ae(e,r)));const s=[];for(const e of this.nodes){const t=this.identityProvider.getId(e.element).toString();if(i.has(t)){const e=o.get(t);e&&s.push(e)}else s.push(e)}if(this.nodes.length>0&&0===s.length){const e=this.getFirstViewElementWithTrait();e&&s.push(e)}this._set(s,!0)}createNodeSet(){const e=new Set;for(const t of this.nodes)e.add(t);return e}}class ce extends l.sx{constructor(e,t){super(e),this.tree=t}onViewPointer(e){if((0,l.cK)(e.browserEvent.target)||(0,l.hD)(e.browserEvent.target))return;const t=e.element;if(!t)return super.onViewPointer(e);if(this.isSelectionRangeChangeEvent(e)||this.isSelectionSingleChangeEvent(e))return super.onViewPointer(e);const i=e.browserEvent.target,n=i.classList.contains("monaco-tl-twistie")||i.classList.contains("monaco-icon-label")&&i.classList.contains("folder-icon")&&e.browserEvent.offsetX<16;let o=!1;if(o="function"==typeof this.tree.expandOnlyOnTwistieClick?this.tree.expandOnlyOnTwistieClick(t.element):!!this.tree.expandOnlyOnTwistieClick,o&&!n&&2!==e.browserEvent.detail)return super.onViewPointer(e);if(!this.tree.expandOnDoubleClick&&2===e.browserEvent.detail)return super.onViewPointer(e);if(t.collapsible){const i=this.tree.model,r=i.getNodeLocation(t),s=e.browserEvent.altKey;if(this.tree.setFocus([r]),i.setCollapsed(r,void 0,s),o&&n)return}super.onViewPointer(e)}onDoubleClick(e){!e.browserEvent.target.classList.contains("monaco-tl-twistie")&&this.tree.expandOnDoubleClick&&super.onDoubleClick(e)}}class de extends l.aV{constructor(e,t,i,n,o,r,s,a){super(e,t,i,n,a),this.focusTrait=o,this.selectionTrait=r,this.anchorTrait=s}createMouseController(e){return new ce(this,e.tree)}splice(e,t,i=[]){if(super.splice(e,t,i),0===i.length)return;const n=[],r=[];let s;i.forEach(((t,i)=>{this.focusTrait.has(t)&&n.push(e+i),this.selectionTrait.has(t)&&r.push(e+i),this.anchorTrait.has(t)&&(s=e+i)})),n.length>0&&super.setFocus((0,o.EB)([...super.getFocus(),...n])),r.length>0&&super.setSelection((0,o.EB)([...super.getSelection(),...r])),"number"==typeof s&&super.setAnchor(s)}setFocus(e,t,i=!1){super.setFocus(e,t),i||this.focusTrait.set(e.map((e=>this.element(e))),t)}setSelection(e,t,i=!1){super.setSelection(e,t),i||this.selectionTrait.set(e.map((e=>this.element(e))),t)}setAnchor(e,t=!1){super.setAnchor(e),t||(void 0===e?this.anchorTrait.set([]):this.anchorTrait.set([this.element(e)]))}}class ue{constructor(e,t,i,o,r={}){this._user=e,this._options=r,this.eventBufferer=new s.E7,this.disposables=new a.SL,this._onWillRefilter=new s.Q5,this.onWillRefilter=this._onWillRefilter.event,this._onDidUpdateOptions=new s.Q5;const c=new te(i),d=new s.ZD,u=new s.ZD,h=new ie(u.event);this.renderers=o.map((e=>new ne(e,(()=>this.model),d.event,h,r)));for(let e of this.renderers)this.disposables.add(e);let g;r.keyboardNavigationLabelProvider&&(g=new oe(this,r.keyboardNavigationLabelProvider,r.filter),r=Object.assign(Object.assign({},r),{filter:g}),this.disposables.add(g)),this.focus=new le((()=>this.view.getFocusedElements()[0]),r.identityProvider),this.selection=new le((()=>this.view.getSelectedElements()[0]),r.identityProvider),this.anchor=new le((()=>this.view.getAnchorElement()),r.identityProvider),this.view=new de(e,t,c,this.renderers,this.focus,this.selection,this.anchor,Object.assign(Object.assign({},function(e,t){return t&&Object.assign(Object.assign({},t),{identityProvider:t.identityProvider&&{getId:e=>t.identityProvider.getId(e.element)},dnd:t.dnd&&new ee(e,t.dnd),multipleSelectionController:t.multipleSelectionController&&{isSelectionSingleChangeEvent:e=>t.multipleSelectionController.isSelectionSingleChangeEvent(Object.assign(Object.assign({},e),{element:e.element})),isSelectionRangeChangeEvent:e=>t.multipleSelectionController.isSelectionRangeChangeEvent(Object.assign(Object.assign({},e),{element:e.element}))},accessibilityProvider:t.accessibilityProvider&&Object.assign(Object.assign({},t.accessibilityProvider),{getSetSize(t){const i=e(),n=i.getNodeLocation(t),o=i.getParentNodeLocation(n);return i.getNode(o).visibleChildrenCount},getPosInSet:e=>e.visibleChildIndex+1,isChecked:t.accessibilityProvider&&t.accessibilityProvider.isChecked?e=>t.accessibilityProvider.isChecked(e.element):void 0,getRole:t.accessibilityProvider&&t.accessibilityProvider.getRole?e=>t.accessibilityProvider.getRole(e.element):()=>"treeitem",getAriaLabel:e=>t.accessibilityProvider.getAriaLabel(e.element),getWidgetAriaLabel:()=>t.accessibilityProvider.getWidgetAriaLabel(),getWidgetRole:t.accessibilityProvider&&t.accessibilityProvider.getWidgetRole?()=>t.accessibilityProvider.getWidgetRole():()=>"tree",getAriaLevel:t.accessibilityProvider&&t.accessibilityProvider.getAriaLevel?e=>t.accessibilityProvider.getAriaLevel(e.element):e=>e.depth,getActiveDescendantId:t.accessibilityProvider.getActiveDescendantId&&(e=>t.accessibilityProvider.getActiveDescendantId(e.element))}),keyboardNavigationLabelProvider:t.keyboardNavigationLabelProvider&&Object.assign(Object.assign({},t.keyboardNavigationLabelProvider),{getKeyboardNavigationLabel:e=>t.keyboardNavigationLabelProvider.getKeyboardNavigationLabel(e.element)}),enableKeyboardNavigation:t.simpleKeyboardNavigation})}((()=>this.model),r)),{tree:this})),this.model=this.createModel(e,this.view,r),d.input=this.model.onDidChangeCollapseState;const p=s.ju.forEach(this.model.onDidSplice,(e=>{this.eventBufferer.bufferEvents((()=>{this.focus.onDidModelSplice(e),this.selection.onDidModelSplice(e)}))}));if(p((()=>null),null,this.disposables),u.input=s.ju.chain(s.ju.any(p,this.focus.onDidChange,this.selection.onDidChange)).debounce((()=>null),0).map((()=>{const e=new Set;for(const t of this.focus.getNodes())e.add(t);for(const t of this.selection.getNodes())e.add(t);return[...e.values()]})).event,!1!==r.keyboardSupport){const e=s.ju.chain(this.view.onKeyDown).filter((e=>!(0,l.cK)(e.target))).map((e=>new R.y(e)));e.filter((e=>15===e.keyCode)).on(this.onLeftArrow,this,this.disposables),e.filter((e=>17===e.keyCode)).on(this.onRightArrow,this,this.disposables),e.filter((e=>10===e.keyCode)).on(this.onSpace,this,this.disposables)}if(r.keyboardNavigationLabelProvider){const e=r.keyboardNavigationDelegate||l.WK;this.typeFilterController=new re(this,this.model,this.view,g,e),this.focusNavigationFilter=e=>this.typeFilterController.shouldAllowFocus(e),this.disposables.add(this.typeFilterController)}this.styleElement=(0,n.dS)(this.view.getHTMLElement()),this.getHTMLElement().classList.toggle("always",this._options.renderIndentGuides===Y.Always)}get onDidChangeFocus(){return this.eventBufferer.wrapEvent(this.focus.onDidChange)}get onDidChangeSelection(){return this.eventBufferer.wrapEvent(this.selection.onDidChange)}get onMouseDblClick(){return s.ju.map(this.view.onMouseDblClick,se)}get onPointer(){return s.ju.map(this.view.onPointer,se)}get onDidFocus(){return this.view.onDidFocus}get onDidChangeModel(){return s.ju.signal(this.model.onDidSplice)}get onDidChangeCollapseState(){return this.model.onDidChangeCollapseState}get expandOnDoubleClick(){return void 0===this._options.expandOnDoubleClick||this._options.expandOnDoubleClick}get expandOnlyOnTwistieClick(){return void 0===this._options.expandOnlyOnTwistieClick||this._options.expandOnlyOnTwistieClick}get onDidDispose(){return this.view.onDidDispose}updateOptions(e={}){this._options=Object.assign(Object.assign({},this._options),e);for(const t of this.renderers)t.updateOptions(e);this.view.updateOptions(Object.assign(Object.assign({},this._options),{enableKeyboardNavigation:this._options.simpleKeyboardNavigation})),this.typeFilterController&&this.typeFilterController.updateOptions(this._options),this._onDidUpdateOptions.fire(this._options),this.getHTMLElement().classList.toggle("always",this._options.renderIndentGuides===Y.Always)}get options(){return this._options}getHTMLElement(){return this.view.getHTMLElement()}get scrollTop(){return this.view.scrollTop}set scrollTop(e){this.view.scrollTop=e}domFocus(){this.view.domFocus()}layout(e,t){this.view.layout(e,t)}style(e){const t=`.${this.view.domId}`,i=[];e.treeIndentGuidesStroke&&(i.push(`.monaco-list${t}:hover .monaco-tl-indent > .indent-guide, .monaco-list${t}.always .monaco-tl-indent > .indent-guide { border-color: ${e.treeIndentGuidesStroke.transparent(.4)}; }`),i.push(`.monaco-list${t} .monaco-tl-indent > .indent-guide.active { border-color: ${e.treeIndentGuidesStroke}; }`)),this.styleElement.textContent=i.join("\n"),this.view.style(e)}getParentElement(e){const t=this.model.getParentNodeLocation(e);return this.model.getNode(t).element}getFirstElementChild(e){return this.model.getFirstElementChild(e)}getNode(e){return this.model.getNode(e)}collapse(e,t=!1){return this.model.setCollapsed(e,!0,t)}expand(e,t=!1){return this.model.setCollapsed(e,!1,t)}isCollapsible(e){return this.model.isCollapsible(e)}setCollapsible(e,t){return this.model.setCollapsible(e,t)}isCollapsed(e){return this.model.isCollapsed(e)}refilter(){this._onWillRefilter.fire(void 0),this.model.refilter()}setSelection(e,t){const i=e.map((e=>this.model.getNode(e)));this.selection.set(i,t);const n=e.map((e=>this.model.getListIndex(e))).filter((e=>e>-1));this.view.setSelection(n,t,!0)}getSelection(){return this.selection.get()}setFocus(e,t){const i=e.map((e=>this.model.getNode(e)));this.focus.set(i,t);const n=e.map((e=>this.model.getListIndex(e))).filter((e=>e>-1));this.view.setFocus(n,t,!0)}focusNext(e=1,t=!1,i,n=this.focusNavigationFilter){this.view.focusNext(e,t,i,n)}getFocus(){return this.focus.get()}reveal(e,t){this.model.expandTo(e);const i=this.model.getListIndex(e);-1!==i&&this.view.reveal(i,t)}getRelativeTop(e){const t=this.model.getListIndex(e);return-1===t?null:this.view.getRelativeTop(t)}onLeftArrow(e){e.preventDefault(),e.stopPropagation();const t=this.view.getFocusedElements();if(0===t.length)return;const i=t[0],n=this.model.getNodeLocation(i);if(!this.model.setCollapsed(n,!0)){const e=this.model.getParentNodeLocation(n);if(!e)return;const t=this.model.getListIndex(e);this.view.reveal(t),this.view.setFocus([t])}}onRightArrow(e){e.preventDefault(),e.stopPropagation();const t=this.view.getFocusedElements();if(0===t.length)return;const i=t[0],n=this.model.getNodeLocation(i);if(!this.model.setCollapsed(n,!1)){if(!i.children.some((e=>e.visible)))return;const[e]=this.view.getFocus(),t=e+1;this.view.reveal(t),this.view.setFocus([t])}}onSpace(e){e.preventDefault(),e.stopPropagation();const t=this.view.getFocusedElements();if(0===t.length)return;const i=t[0],n=this.model.getNodeLocation(i),o=e.browserEvent.altKey;this.model.setCollapsed(n,void 0,o)}dispose(){(0,a.B9)(this.disposables),this.view.dispose()}}class he{constructor(e,t,i={}){this.user=e,this.rootRef=null,this.nodes=new Map,this.nodesByIdentity=new Map,this.model=new z(e,t,null,i),this.onDidSplice=this.model.onDidSplice,this.onDidChangeCollapseState=this.model.onDidChangeCollapseState,this.onDidChangeRenderNodeCount=this.model.onDidChangeRenderNodeCount,i.sorter&&(this.sorter={compare:(e,t)=>i.sorter.compare(e.element,t.element)}),this.identityProvider=i.identityProvider}setChildren(e,t=B.$.empty(),i={}){const n=this.getElementLocation(e);this._setChildren(n,this.preserveCollapseState(t),i)}_setChildren(e,t=B.$.empty(),i){const n=new Set,o=new Set;this.model.splice([...e,0],Number.MAX_VALUE,t,Object.assign(Object.assign({},i),{onDidCreateNode:e=>{var t;if(null===e.element)return;const r=e;if(n.add(r.element),this.nodes.set(r.element,r),this.identityProvider){const e=this.identityProvider.getId(r.element).toString();o.add(e),this.nodesByIdentity.set(e,r)}null===(t=i.onDidCreateNode)||void 0===t||t.call(i,r)},onDidDeleteNode:e=>{var t;if(null===e.element)return;const r=e;if(n.has(r.element)||this.nodes.delete(r.element),this.identityProvider){const e=this.identityProvider.getId(r.element).toString();o.has(e)||this.nodesByIdentity.delete(e)}null===(t=i.onDidDeleteNode)||void 0===t||t.call(i,r)}}))}preserveCollapseState(e=B.$.empty()){return this.sorter&&(e=[...e].sort(this.sorter.compare.bind(this.sorter))),B.$.map(e,(e=>{let t=this.nodes.get(e.element);if(!t&&this.identityProvider){const i=this.identityProvider.getId(e.element).toString();t=this.nodesByIdentity.get(i)}if(!t)return Object.assign(Object.assign({},e),{children:this.preserveCollapseState(e.children)});const i="boolean"==typeof e.collapsible?e.collapsible:t.collapsible,n=void 0!==e.collapsed?e.collapsed:t.collapsed;return Object.assign(Object.assign({},e),{collapsible:i,collapsed:n,children:this.preserveCollapseState(e.children)})}))}rerender(e){const t=this.getElementLocation(e);this.model.rerender(t)}getFirstElementChild(e=null){const t=this.getElementLocation(e);return this.model.getFirstElementChild(t)}has(e){return this.nodes.has(e)}getListIndex(e){const t=this.getElementLocation(e);return this.model.getListIndex(t)}getListRenderCount(e){const t=this.getElementLocation(e);return this.model.getListRenderCount(t)}isCollapsible(e){const t=this.getElementLocation(e);return this.model.isCollapsible(t)}setCollapsible(e,t){const i=this.getElementLocation(e);return this.model.setCollapsible(i,t)}isCollapsed(e){const t=this.getElementLocation(e);return this.model.isCollapsed(t)}setCollapsed(e,t,i){const n=this.getElementLocation(e);return this.model.setCollapsed(n,t,i)}expandTo(e){const t=this.getElementLocation(e);this.model.expandTo(t)}refilter(){this.model.refilter()}getNode(e=null){if(null===e)return this.model.getNode(this.model.rootRef);const t=this.nodes.get(e);if(!t)throw new M(this.user,`Tree element not found: ${e}`);return t}getNodeLocation(e){return e.element}getParentNodeLocation(e){if(null===e)throw new M(this.user,"Invalid getParentNodeLocation call");const t=this.nodes.get(e);if(!t)throw new M(this.user,`Tree element not found: ${e}`);const i=this.model.getNodeLocation(t),n=this.model.getParentNodeLocation(i);return this.model.getNode(n).element}getElementLocation(e){if(null===e)return[];const t=this.nodes.get(e);if(!t)throw new M(this.user,`Tree element not found: ${e}`);return this.model.getNodeLocation(t)}}function ge(e){return{element:{elements:[e.element],incompressible:e.incompressible||!1},children:B.$.map(B.$.from(e.children),ge),collapsible:e.collapsible,collapsed:e.collapsed}}function pe(e){const t=[e.element],i=e.incompressible||!1;let n,o;for(;[o,n]=B.$.consume(B.$.from(e.children),2),1===o.length&&!o[0].incompressible;)e=o[0],t.push(e.element);return{element:{elements:t,incompressible:i},children:B.$.map(B.$.concat(o,n),pe),collapsible:e.collapsible,collapsed:e.collapsed}}function me(e,t=0){let i;return i=tme(e,0))),0===t&&e.element.incompressible?{element:e.element.elements[t],children:i,incompressible:!0,collapsible:e.collapsible,collapsed:e.collapsed}:{element:e.element.elements[t],children:i,collapsible:e.collapsible,collapsed:e.collapsed}}function fe(e){return me(e,0)}function _e(e,t,i){return e.element===t?Object.assign(Object.assign({},e),{children:i}):Object.assign(Object.assign({},e),{children:B.$.map(B.$.from(e.children),(e=>_e(e,t,i)))})}class be{constructor(e,t,i={}){this.user=e,this.rootRef=null,this.nodes=new Map,this.model=new he(e,t,i),this.enabled=void 0===i.compressionEnabled||i.compressionEnabled,this.identityProvider=i.identityProvider}get onDidSplice(){return this.model.onDidSplice}get onDidChangeCollapseState(){return this.model.onDidChangeCollapseState}get onDidChangeRenderNodeCount(){return this.model.onDidChangeRenderNodeCount}setChildren(e,t=B.$.empty(),i){const n=i.diffIdentityProvider&&(o=i.diffIdentityProvider,{getId:e=>e.elements.map((e=>o.getId(e).toString())).join("\0")});var o;if(null===e){const e=B.$.map(t,this.enabled?pe:ge);return void this._setChildren(null,e,{diffIdentityProvider:n,diffDepth:1/0})}const r=this.nodes.get(e);if(!r)throw new Error("Unknown compressed tree node");const s=this.model.getNode(r),a=this.model.getParentNodeLocation(r),l=this.model.getNode(a),c=_e(fe(s),e,t),d=(this.enabled?pe:ge)(c),u=l.children.map((e=>e===s?d:e));this._setChildren(l.element,u,{diffIdentityProvider:n,diffDepth:s.depth-l.depth})}setCompressionEnabled(e){if(e===this.enabled)return;this.enabled=e;const t=this.model.getNode().children,i=B.$.map(t,fe),n=B.$.map(i,e?pe:ge);this._setChildren(null,n,{diffIdentityProvider:this.identityProvider,diffDepth:1/0})}_setChildren(e,t,i){const n=new Set;this.model.setChildren(e,t,Object.assign(Object.assign({},i),{onDidCreateNode:e=>{for(const t of e.element.elements)n.add(t),this.nodes.set(t,e.element)},onDidDeleteNode:e=>{for(const t of e.element.elements)n.has(t)||this.nodes.delete(t)}}))}has(e){return this.nodes.has(e)}getListIndex(e){const t=this.getCompressedNode(e);return this.model.getListIndex(t)}getListRenderCount(e){const t=this.getCompressedNode(e);return this.model.getListRenderCount(t)}getNode(e){if(void 0===e)return this.model.getNode();const t=this.getCompressedNode(e);return this.model.getNode(t)}getNodeLocation(e){const t=this.model.getNodeLocation(e);return null===t?null:t.elements[t.elements.length-1]}getParentNodeLocation(e){const t=this.getCompressedNode(e),i=this.model.getParentNodeLocation(t);return null===i?null:i.elements[i.elements.length-1]}getFirstElementChild(e){const t=this.getCompressedNode(e);return this.model.getFirstElementChild(t)}isCollapsible(e){const t=this.getCompressedNode(e);return this.model.isCollapsible(t)}setCollapsible(e,t){const i=this.getCompressedNode(e);return this.model.setCollapsible(i,t)}isCollapsed(e){const t=this.getCompressedNode(e);return this.model.isCollapsed(t)}setCollapsed(e,t,i){const n=this.getCompressedNode(e);return this.model.setCollapsed(n,t,i)}expandTo(e){const t=this.getCompressedNode(e);this.model.expandTo(t)}rerender(e){const t=this.getCompressedNode(e);this.model.rerender(t)}refilter(){this.model.refilter()}getCompressedNode(e){if(null===e)return null;const t=this.nodes.get(e);if(!t)throw new M(this.user,`Tree element not found: ${e}`);return t}}const ve=e=>e[e.length-1];class Ce{constructor(e,t){this.unwrapper=e,this.node=t}get element(){return null===this.node.element?null:this.unwrapper(this.node.element)}get children(){return this.node.children.map((e=>new Ce(this.unwrapper,e)))}get depth(){return this.node.depth}get visibleChildrenCount(){return this.node.visibleChildrenCount}get visibleChildIndex(){return this.node.visibleChildIndex}get collapsible(){return this.node.collapsible}get collapsed(){return this.node.collapsed}get visible(){return this.node.visible}get filterData(){return this.node.filterData}}class we{constructor(e,t,i={}){this.rootRef=null,this.elementMapper=i.elementMapper||ve;const n=e=>this.elementMapper(e.elements);this.nodeMapper=new O((e=>new Ce(n,e))),this.model=new be(e,function(e,t){return{splice(i,n,o){t.splice(i,n,o.map((t=>e.map(t))))},updateElementHeight(e,i){t.updateElementHeight(e,i)}}}(this.nodeMapper,t),function(e,t){return Object.assign(Object.assign({},t),{identityProvider:t.identityProvider&&{getId:i=>t.identityProvider.getId(e(i))},sorter:t.sorter&&{compare:(e,i)=>t.sorter.compare(e.elements[0],i.elements[0])},filter:t.filter&&{filter:(i,n)=>t.filter.filter(e(i),n)}})}(n,i))}get onDidSplice(){return s.ju.map(this.model.onDidSplice,(({insertedNodes:e,deletedNodes:t})=>({insertedNodes:e.map((e=>this.nodeMapper.map(e))),deletedNodes:t.map((e=>this.nodeMapper.map(e)))})))}get onDidChangeCollapseState(){return s.ju.map(this.model.onDidChangeCollapseState,(({node:e,deep:t})=>({node:this.nodeMapper.map(e),deep:t})))}get onDidChangeRenderNodeCount(){return s.ju.map(this.model.onDidChangeRenderNodeCount,(e=>this.nodeMapper.map(e)))}setChildren(e,t=B.$.empty(),i={}){this.model.setChildren(e,t,i)}setCompressionEnabled(e){this.model.setCompressionEnabled(e)}has(e){return this.model.has(e)}getListIndex(e){return this.model.getListIndex(e)}getListRenderCount(e){return this.model.getListRenderCount(e)}getNode(e){return this.nodeMapper.map(this.model.getNode(e))}getNodeLocation(e){return e.element}getParentNodeLocation(e){return this.model.getParentNodeLocation(e)}getFirstElementChild(e){const t=this.model.getFirstElementChild(e);return null==t?t:this.elementMapper(t.elements)}isCollapsible(e){return this.model.isCollapsible(e)}setCollapsible(e,t){return this.model.setCollapsible(e,t)}isCollapsed(e){return this.model.isCollapsed(e)}setCollapsed(e,t,i){return this.model.setCollapsed(e,t,i)}expandTo(e){return this.model.expandTo(e)}rerender(e){return this.model.rerender(e)}refilter(){return this.model.refilter()}getCompressedTreeNode(e=null){return this.model.getNode(e)}}var ye=i(79945);class Se extends ue{constructor(e,t,i,n,o={}){super(e,t,i,n,o),this.user=e}get onDidChangeCollapseState(){return this.model.onDidChangeCollapseState}setChildren(e,t=B.$.empty(),i){this.model.setChildren(e,t,i)}rerender(e){void 0!==e?this.model.rerender(e):this.view.rerender()}hasElement(e){return this.model.has(e)}createModel(e,t,i){return new he(e,t,i)}}class xe{constructor(e,t){this._compressedTreeNodeProvider=e,this.renderer=t,this.templateId=t.templateId,t.onDidChangeTwistieState&&(this.onDidChangeTwistieState=t.onDidChangeTwistieState)}get compressedTreeNodeProvider(){return this._compressedTreeNodeProvider()}renderTemplate(e){return{compressedTreeNode:void 0,data:this.renderer.renderTemplate(e)}}renderElement(e,t,i,n){const o=this.compressedTreeNodeProvider.getCompressedTreeNode(e.element);1===o.element.elements.length?(i.compressedTreeNode=void 0,this.renderer.renderElement(e,t,i.data,n)):(i.compressedTreeNode=o,this.renderer.renderCompressedElements(o,t,i.data,n))}disposeElement(e,t,i,n){i.compressedTreeNode?this.renderer.disposeCompressedElements&&this.renderer.disposeCompressedElements(i.compressedTreeNode,t,i.data,n):this.renderer.disposeElement&&this.renderer.disposeElement(e,t,i.data,n)}disposeTemplate(e){this.renderer.disposeTemplate(e.data)}renderTwistie(e,t){return!!this.renderer.renderTwistie&&this.renderer.renderTwistie(e,t)}}!function(e,t,i,n){var o,r=arguments.length,s=r<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,i):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(e,t,i,n);else for(var a=e.length-1;a>=0;a--)(o=e[a])&&(s=(r<3?o(s):r>3?o(t,i,s):o(t,i))||s);r>3&&s&&Object.defineProperty(t,i,s)}([ye.H],xe.prototype,"compressedTreeNodeProvider",null);class ke extends Se{constructor(e,t,i,n,o={}){const r=()=>this;super(e,t,i,n.map((e=>new xe(r,e))),function(e,t){return t&&Object.assign(Object.assign({},t),{keyboardNavigationLabelProvider:t.keyboardNavigationLabelProvider&&{getKeyboardNavigationLabel(i){let n;try{n=e().getCompressedTreeNode(i)}catch(e){return t.keyboardNavigationLabelProvider.getKeyboardNavigationLabel(i)}return 1===n.element.elements.length?t.keyboardNavigationLabelProvider.getKeyboardNavigationLabel(i):t.keyboardNavigationLabelProvider.getCompressedNodeKeyboardNavigationLabel(n.element.elements)}}})}(r,o))}setChildren(e,t=B.$.empty(),i){this.model.setChildren(e,t,i)}createModel(e,t,i){return new we(e,t,i)}updateOptions(e={}){super.updateOptions(e),void 0!==e.compressionEnabled&&this.model.setCompressionEnabled(e.compressionEnabled)}getCompressedTreeNode(e=null){return this.model.getCompressedTreeNode(e)}}var Le=i(16182),Ee=i(28295),Ne=function(e,t,i,n){return new(i||(i=Promise))((function(o,r){function s(e){try{l(n.next(e))}catch(e){r(e)}}function a(e){try{l(n.throw(e))}catch(e){r(e)}}function l(e){var t;e.done?o(e.value):(t=e.value,t instanceof i?t:new i((function(e){e(t)}))).then(s,a)}l((n=n.apply(e,t||[])).next())}))};function De(e){return Object.assign(Object.assign({},e),{children:[],refreshPromise:void 0,stale:!0,slow:!1,collapsedByDefault:void 0})}function Ie(e,t){return!!t.parent&&(t.parent===e||Ie(e,t.parent))}class Te{constructor(e){this.node=e}get element(){return this.node.element.element}get children(){return this.node.children.map((e=>new Te(e)))}get depth(){return this.node.depth}get visibleChildrenCount(){return this.node.visibleChildrenCount}get visibleChildIndex(){return this.node.visibleChildIndex}get collapsible(){return this.node.collapsible}get collapsed(){return this.node.collapsed}get visible(){return this.node.visible}get filterData(){return this.node.filterData}}class Ae{constructor(e,t,i){this.renderer=e,this.nodeMapper=t,this.onDidChangeTwistieState=i,this.renderedNodes=new Map,this.templateId=e.templateId}renderTemplate(e){return{templateData:this.renderer.renderTemplate(e)}}renderElement(e,t,i,n){this.renderer.renderElement(this.nodeMapper.map(e),t,i.templateData,n)}renderTwistie(e,t){return e.slow?(t.classList.add(...$.lA.treeItemLoading.classNamesArray),!0):(t.classList.remove(...$.lA.treeItemLoading.classNamesArray),!1)}disposeElement(e,t,i,n){this.renderer.disposeElement&&this.renderer.disposeElement(this.nodeMapper.map(e),t,i.templateData,n)}disposeTemplate(e){this.renderer.disposeTemplate(e.templateData)}dispose(){this.renderedNodes.clear()}}function Re(e){return{browserEvent:e.browserEvent,elements:e.elements.map((e=>e.element))}}function Me(e){return{browserEvent:e.browserEvent,element:e.element&&e.element.element,target:e.target}}class Oe extends I.kX{constructor(e){super(e.elements.map((e=>e.element))),this.data=e}}function Pe(e){return e instanceof I.kX?new Oe(e):e}class Fe{constructor(e){this.dnd=e}getDragURI(e){return this.dnd.getDragURI(e.element)}getDragLabel(e,t){if(this.dnd.getDragLabel)return this.dnd.getDragLabel(e.map((e=>e.element)),t)}onDragStart(e,t){this.dnd.onDragStart&&this.dnd.onDragStart(Pe(e),t)}onDragOver(e,t,i,n,o=!0){return this.dnd.onDragOver(Pe(e),t&&t.element,i,n)}drop(e,t,i,n){this.dnd.drop(Pe(e),t&&t.element,i,n)}onDragEnd(e){this.dnd.onDragEnd&&this.dnd.onDragEnd(e)}}function Be(e){return e&&Object.assign(Object.assign({},e),{collapseByDefault:!0,identityProvider:e.identityProvider&&{getId:t=>e.identityProvider.getId(t.element)},dnd:e.dnd&&new Fe(e.dnd),multipleSelectionController:e.multipleSelectionController&&{isSelectionSingleChangeEvent:t=>e.multipleSelectionController.isSelectionSingleChangeEvent(Object.assign(Object.assign({},t),{element:t.element})),isSelectionRangeChangeEvent:t=>e.multipleSelectionController.isSelectionRangeChangeEvent(Object.assign(Object.assign({},t),{element:t.element}))},accessibilityProvider:e.accessibilityProvider&&Object.assign(Object.assign({},e.accessibilityProvider),{getPosInSet:void 0,getSetSize:void 0,getRole:e.accessibilityProvider.getRole?t=>e.accessibilityProvider.getRole(t.element):()=>"treeitem",isChecked:e.accessibilityProvider.isChecked?t=>{var i;return!!(null===(i=e.accessibilityProvider)||void 0===i?void 0:i.isChecked(t.element))}:void 0,getAriaLabel:t=>e.accessibilityProvider.getAriaLabel(t.element),getWidgetAriaLabel:()=>e.accessibilityProvider.getWidgetAriaLabel(),getWidgetRole:e.accessibilityProvider.getWidgetRole?()=>e.accessibilityProvider.getWidgetRole():()=>"tree",getAriaLevel:e.accessibilityProvider.getAriaLevel&&(t=>e.accessibilityProvider.getAriaLevel(t.element)),getActiveDescendantId:e.accessibilityProvider.getActiveDescendantId&&(t=>e.accessibilityProvider.getActiveDescendantId(t.element))}),filter:e.filter&&{filter:(t,i)=>e.filter.filter(t.element,i)},keyboardNavigationLabelProvider:e.keyboardNavigationLabelProvider&&Object.assign(Object.assign({},e.keyboardNavigationLabelProvider),{getKeyboardNavigationLabel:t=>e.keyboardNavigationLabelProvider.getKeyboardNavigationLabel(t.element)}),sorter:void 0,expandOnlyOnTwistieClick:void 0===e.expandOnlyOnTwistieClick?void 0:"function"!=typeof e.expandOnlyOnTwistieClick?e.expandOnlyOnTwistieClick:t=>e.expandOnlyOnTwistieClick(t.element),additionalScrollHeight:e.additionalScrollHeight})}function We(e,t){t(e),e.children.forEach((e=>We(e,t)))}class Ve{constructor(e,t,i,n,o,r={}){this.user=e,this.dataSource=o,this.nodes=new Map,this.subTreeRefreshPromises=new Map,this.refreshPromises=new Map,this._onDidRender=new s.Q5,this._onDidChangeNodeSlowState=new s.Q5,this.nodeMapper=new O((e=>new Te(e))),this.disposables=new a.SL,this.identityProvider=r.identityProvider,this.autoExpandSingleChildren=void 0!==r.autoExpandSingleChildren&&r.autoExpandSingleChildren,this.sorter=r.sorter,this.collapseByDefault=r.collapseByDefault,this.tree=this.createTree(e,t,i,n,r),this.root=De({element:void 0,parent:null,hasChildren:!0}),this.identityProvider&&(this.root=Object.assign(Object.assign({},this.root),{id:null})),this.nodes.set(null,this.root),this.tree.onDidChangeCollapseState(this._onDidChangeCollapseState,this,this.disposables)}get onDidChangeFocus(){return s.ju.map(this.tree.onDidChangeFocus,Re)}get onDidChangeSelection(){return s.ju.map(this.tree.onDidChangeSelection,Re)}get onMouseDblClick(){return s.ju.map(this.tree.onMouseDblClick,Me)}get onPointer(){return s.ju.map(this.tree.onPointer,Me)}get onDidFocus(){return this.tree.onDidFocus}get onDidChangeModel(){return this.tree.onDidChangeModel}get onDidChangeCollapseState(){return this.tree.onDidChangeCollapseState}get onDidDispose(){return this.tree.onDidDispose}createTree(e,t,i,n,o){const r=new te(i),s=n.map((e=>new Ae(e,this.nodeMapper,this._onDidChangeNodeSlowState.event))),a=Be(o)||{};return new Se(e,t,r,s,a)}updateOptions(e={}){this.tree.updateOptions(e)}getHTMLElement(){return this.tree.getHTMLElement()}get scrollTop(){return this.tree.scrollTop}set scrollTop(e){this.tree.scrollTop=e}domFocus(){this.tree.domFocus()}layout(e,t){this.tree.layout(e,t)}style(e){this.tree.style(e)}getInput(){return this.root.element}setInput(e,t){return Ne(this,void 0,void 0,(function*(){this.refreshPromises.forEach((e=>e.cancel())),this.refreshPromises.clear(),this.root.element=e;const i=t&&{viewState:t,focus:[],selection:[]};yield this._updateChildren(e,!0,!1,i),i&&(this.tree.setFocus(i.focus),this.tree.setSelection(i.selection)),t&&"number"==typeof t.scrollTop&&(this.scrollTop=t.scrollTop)}))}_updateChildren(e=this.root.element,t=!0,i=!1,n,o){return Ne(this,void 0,void 0,(function*(){if(void 0===this.root.element)throw new M(this.user,"Tree input not set");this.root.refreshPromise&&(yield this.root.refreshPromise,yield s.ju.toPromise(this._onDidRender.event));const r=this.getDataNode(e);if(yield this.refreshAndRenderNode(r,t,n,o),i)try{this.tree.rerender(r)}catch(e){}}))}rerender(e){if(void 0===e||e===this.root.element)return void this.tree.rerender();const t=this.getDataNode(e);this.tree.rerender(t)}getNode(e=this.root.element){const t=this.getDataNode(e),i=this.tree.getNode(t===this.root?null:t);return this.nodeMapper.map(i)}collapse(e,t=!1){const i=this.getDataNode(e);return this.tree.collapse(i===this.root?null:i,t)}expand(e,t=!1){return Ne(this,void 0,void 0,(function*(){if(void 0===this.root.element)throw new M(this.user,"Tree input not set");this.root.refreshPromise&&(yield this.root.refreshPromise,yield s.ju.toPromise(this._onDidRender.event));const i=this.getDataNode(e);if(this.tree.hasElement(i)&&!this.tree.isCollapsible(i))return!1;if(i.refreshPromise&&(yield this.root.refreshPromise,yield s.ju.toPromise(this._onDidRender.event)),i!==this.root&&!i.refreshPromise&&!this.tree.isCollapsed(i))return!1;const n=this.tree.expand(i===this.root?null:i,t);return i.refreshPromise&&(yield this.root.refreshPromise,yield s.ju.toPromise(this._onDidRender.event)),n}))}setSelection(e,t){const i=e.map((e=>this.getDataNode(e)));this.tree.setSelection(i,t)}getSelection(){return this.tree.getSelection().map((e=>e.element))}setFocus(e,t){const i=e.map((e=>this.getDataNode(e)));this.tree.setFocus(i,t)}getFocus(){return this.tree.getFocus().map((e=>e.element))}reveal(e,t){this.tree.reveal(this.getDataNode(e),t)}getParentElement(e){const t=this.tree.getParentElement(this.getDataNode(e));return t&&t.element}getFirstElementChild(e=this.root.element){const t=this.getDataNode(e),i=this.tree.getFirstElementChild(t===this.root?null:t);return i&&i.element}getDataNode(e){const t=this.nodes.get(e===this.root.element?null:e);if(!t)throw new M(this.user,`Data tree node not found: ${e}`);return t}refreshAndRenderNode(e,t,i,n){return Ne(this,void 0,void 0,(function*(){yield this.refreshNode(e,t,i),this.render(e,i,n)}))}refreshNode(e,t,i){return Ne(this,void 0,void 0,(function*(){let n;return this.subTreeRefreshPromises.forEach(((o,r)=>{!n&&function(e,t){return e===t||Ie(e,t)||Ie(t,e)}(r,e)&&(n=o.then((()=>this.refreshNode(e,t,i))))})),n||this.doRefreshSubTree(e,t,i)}))}doRefreshSubTree(e,t,i){return Ne(this,void 0,void 0,(function*(){let n;e.refreshPromise=new Promise((e=>n=e)),this.subTreeRefreshPromises.set(e,e.refreshPromise),e.refreshPromise.finally((()=>{e.refreshPromise=void 0,this.subTreeRefreshPromises.delete(e)}));try{const o=yield this.doRefreshNode(e,t,i);e.stale=!1,yield P.jT.settled(o.map((e=>this.doRefreshSubTree(e,t,i))))}finally{n()}}))}doRefreshNode(e,t,i){return Ne(this,void 0,void 0,(function*(){let n;if(e.hasChildren=!!this.dataSource.hasChildren(e.element),e.hasChildren){const t=this.doGetChildren(e);if((0,Ee.TW)(t))n=Promise.resolve(t);else{const i=(0,P.Vs)(800);i.then((()=>{e.slow=!0,this._onDidChangeNodeSlowState.fire(e)}),(e=>null)),n=t.finally((()=>i.cancel()))}}else n=Promise.resolve(B.$.empty());try{const o=yield n;return this.setChildren(e,o,t,i)}catch(t){if(e!==this.root&&this.tree.hasElement(e)&&this.tree.collapse(e),(0,Le.n2)(t))return[];throw t}finally{e.slow&&(e.slow=!1,this._onDidChangeNodeSlowState.fire(e))}}))}doGetChildren(e){let t=this.refreshPromises.get(e);if(t)return t;const i=this.dataSource.getChildren(e.element);return(0,Ee.TW)(i)?this.processChildren(i):(t=(0,P.PG)((()=>Ne(this,void 0,void 0,(function*(){return this.processChildren(yield i)})))),this.refreshPromises.set(e,t),t.finally((()=>{this.refreshPromises.delete(e)})))}_onDidChangeCollapseState({node:e,deep:t}){null!==e.element&&!e.collapsed&&e.element.stale&&(t?this.collapse(e.element.element):this.refreshAndRenderNode(e.element,!1).catch(Le.dL))}setChildren(e,t,i,n){const o=[...t];if(0===e.children.length&&0===o.length)return[];const r=new Map,s=new Map;for(const t of e.children)if(r.set(t.element,t),this.identityProvider){const e=this.tree.isCollapsed(t);s.set(t.id,{node:t,collapsed:e})}const a=[],l=o.map((t=>{const o=!!this.dataSource.hasChildren(t);if(!this.identityProvider){const i=De({element:t,parent:e,hasChildren:o});return o&&this.collapseByDefault&&!this.collapseByDefault(t)&&(i.collapsedByDefault=!1,a.push(i)),i}const l=this.identityProvider.getId(t).toString(),c=s.get(l);if(c){const e=c.node;return r.delete(e.element),this.nodes.delete(e.element),this.nodes.set(t,e),e.element=t,e.hasChildren=o,i?c.collapsed?(e.children.forEach((e=>We(e,(e=>this.nodes.delete(e.element))))),e.children.splice(0,e.children.length),e.stale=!0):a.push(e):o&&this.collapseByDefault&&!this.collapseByDefault(t)&&(e.collapsedByDefault=!1,a.push(e)),e}const d=De({element:t,parent:e,id:l,hasChildren:o});return n&&n.viewState.focus&&n.viewState.focus.indexOf(l)>-1&&n.focus.push(d),n&&n.viewState.selection&&n.viewState.selection.indexOf(l)>-1&&n.selection.push(d),n&&n.viewState.expanded&&n.viewState.expanded.indexOf(l)>-1?a.push(d):o&&this.collapseByDefault&&!this.collapseByDefault(t)&&(d.collapsedByDefault=!1,a.push(d)),d}));for(const e of r.values())We(e,(e=>this.nodes.delete(e.element)));for(const e of l)this.nodes.set(e.element,e);return e.children.splice(0,e.children.length,...l),e!==this.root&&this.autoExpandSingleChildren&&1===l.length&&0===a.length&&(l[0].collapsedByDefault=!1,a.push(l[0])),a}render(e,t,i){const n=e.children.map((e=>this.asTreeElement(e,t))),o=i&&Object.assign(Object.assign({},i),{diffIdentityProvider:i.diffIdentityProvider&&{getId:e=>i.diffIdentityProvider.getId(e.element)}});this.tree.setChildren(e===this.root?null:e,n,o),e!==this.root&&this.tree.setCollapsible(e,e.hasChildren),this._onDidRender.fire()}asTreeElement(e,t){if(e.stale)return{element:e,collapsible:e.hasChildren,collapsed:!0};let i;return i=!(t&&t.viewState.expanded&&e.id&&t.viewState.expanded.indexOf(e.id)>-1)&&e.collapsedByDefault,e.collapsedByDefault=void 0,{element:e,children:e.hasChildren?B.$.map(e.children,(e=>this.asTreeElement(e,t))):[],collapsible:e.hasChildren,collapsed:i}}processChildren(e){return this.sorter&&(e=[...e].sort(this.sorter.compare.bind(this.sorter))),e}dispose(){this.disposables.dispose()}}class He{constructor(e){this.node=e}get element(){return{elements:this.node.element.elements.map((e=>e.element)),incompressible:this.node.element.incompressible}}get children(){return this.node.children.map((e=>new He(e)))}get depth(){return this.node.depth}get visibleChildrenCount(){return this.node.visibleChildrenCount}get visibleChildIndex(){return this.node.visibleChildIndex}get collapsible(){return this.node.collapsible}get collapsed(){return this.node.collapsed}get visible(){return this.node.visible}get filterData(){return this.node.filterData}}class ze{constructor(e,t,i,n){this.renderer=e,this.nodeMapper=t,this.compressibleNodeMapperProvider=i,this.onDidChangeTwistieState=n,this.renderedNodes=new Map,this.disposables=[],this.templateId=e.templateId}renderTemplate(e){return{templateData:this.renderer.renderTemplate(e)}}renderElement(e,t,i,n){this.renderer.renderElement(this.nodeMapper.map(e),t,i.templateData,n)}renderCompressedElements(e,t,i,n){this.renderer.renderCompressedElements(this.compressibleNodeMapperProvider().map(e),t,i.templateData,n)}renderTwistie(e,t){return e.slow?(t.classList.add(...$.lA.treeItemLoading.classNamesArray),!0):(t.classList.remove(...$.lA.treeItemLoading.classNamesArray),!1)}disposeElement(e,t,i,n){this.renderer.disposeElement&&this.renderer.disposeElement(this.nodeMapper.map(e),t,i.templateData,n)}disposeCompressedElements(e,t,i,n){this.renderer.disposeCompressedElements&&this.renderer.disposeCompressedElements(this.compressibleNodeMapperProvider().map(e),t,i.templateData,n)}disposeTemplate(e){this.renderer.disposeTemplate(e.templateData)}dispose(){this.renderedNodes.clear(),this.disposables=(0,a.B9)(this.disposables)}}class $e extends Ve{constructor(e,t,i,n,o,r,s={}){super(e,t,i,o,r,s),this.compressionDelegate=n,this.compressibleNodeMapper=new O((e=>new He(e))),this.filter=s.filter}createTree(e,t,i,n,o){const r=new te(i),s=n.map((e=>new ze(e,this.nodeMapper,(()=>this.compressibleNodeMapper),this._onDidChangeNodeSlowState.event))),a=function(e){const t=e&&Be(e);return t&&Object.assign(Object.assign({},t),{keyboardNavigationLabelProvider:t.keyboardNavigationLabelProvider&&Object.assign(Object.assign({},t.keyboardNavigationLabelProvider),{getCompressedNodeKeyboardNavigationLabel:t=>e.keyboardNavigationLabelProvider.getCompressedNodeKeyboardNavigationLabel(t.map((e=>e.element)))})})}(o)||{};return new ke(e,t,r,s,a)}asTreeElement(e,t){return Object.assign({incompressible:this.compressionDelegate.isIncompressible(e.element)},super.asTreeElement(e,t))}updateOptions(e={}){this.tree.updateOptions(e)}render(e,t){if(!this.identityProvider)return super.render(e,t);const i=e=>this.identityProvider.getId(e).toString(),n=e=>{const t=new Set;for(const n of e){const e=this.tree.getCompressedTreeNode(n===this.root?null:n);if(e.element)for(const n of e.element.elements)t.add(i(n.element))}return t},o=n(this.tree.getSelection()),r=n(this.tree.getFocus());super.render(e,t);const s=this.getSelection();let a=!1;const l=this.getFocus();let c=!1;const d=e=>{const t=e.element;if(t)for(let e=0;e{const t="boolean"==typeof(i=this.filter.filter(e,1))?i?1:0:W(i)?V(i.visibility):V(i);var i;if(2===t)throw new Error("Recursive tree visibility not supported in async data compressed trees");return 1===t}))),super.processChildren(e)}}class Ue extends ue{constructor(e,t,i,n,o,r={}){super(e,t,i,n,r),this.user=e,this.dataSource=o,this.identityProvider=r.identityProvider}createModel(e,t,i){return new he(e,t,i)}}var je=i(33060),Ke=i(40539),qe=i(97618),Ge=i(60393),Ze=i(61263),Ye=i(12260),Qe=i(67517),Xe=i(73403),Je=i(64348),et=i(81585),tt=function(e,t,i,n){var o,r=arguments.length,s=r<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,i):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(e,t,i,n);else for(var a=e.length-1;a>=0;a--)(o=e[a])&&(s=(r<3?o(s):r>3?o(t,i,s):o(t,i))||s);return r>3&&s&&Object.defineProperty(t,i,s),s},it=function(e,t){return function(i,n){t(i,n,e)}};const nt=(0,Ye.yh)("listService");let ot=class{constructor(e){this._themeService=e,this.disposables=new a.SL,this.lists=[],this._lastFocusedWidget=void 0,this._hasCreatedStyleController=!1}get lastFocusedList(){return this._lastFocusedWidget}setLastFocusedList(e){var t,i;e!==this._lastFocusedWidget&&(null===(t=this._lastFocusedWidget)||void 0===t||t.getHTMLElement().classList.remove("last-focused"),this._lastFocusedWidget=e,null===(i=this._lastFocusedWidget)||void 0===i||i.getHTMLElement().classList.add("last-focused"))}register(e,t){if(!this._hasCreatedStyleController){this._hasCreatedStyleController=!0;const e=new l.wD((0,n.dS)(),"");this.disposables.add((0,Je.Jl)(e,this._themeService))}if(this.lists.some((t=>t.widget===e)))throw new Error("Cannot register the same widget multiple times");const i={widget:e,extraContextKeys:t};return this.lists.push(i),e.getHTMLElement()===document.activeElement&&this.setLastFocusedList(e),(0,a.F8)(e.onDidFocus((()=>this.setLastFocusedList(e))),(0,a.OF)((()=>this.lists.splice(this.lists.indexOf(i),1))),e.onDidDispose((()=>{this.lists=this.lists.filter((e=>e!==i)),this._lastFocusedWidget===e&&this.setLastFocusedList(void 0)})))}dispose(){this.disposables.dispose()}};ot=tt([it(0,et.XE)],ot);const rt=new Ge.uy("listFocus",!0),st=new Ge.uy("listSupportsMultiselect",!0),at=Ge.Ao.and(rt,Ge.Ao.not(Ze.d0)),lt=new Ge.uy("listHasSelectionOrFocus",!1),ct=new Ge.uy("listDoubleSelection",!1),dt=new Ge.uy("listMultiSelection",!1),ut=new Ge.uy("listSelectionNavigation",!1),ht=new Ge.uy("treeElementCanCollapse",!1),gt=new Ge.uy("treeElementHasParent",!1),pt=new Ge.uy("treeElementCanExpand",!1),mt=new Ge.uy("treeElementHasChild",!1),ft="listAutomaticKeyboardNavigation";function _t(e,t){const i=e.createScoped(t.getHTMLElement());return rt.bindTo(i),i}const bt="workbench.list.multiSelectModifier",vt="workbench.list.openMode",Ct="workbench.list.horizontalScrolling",wt="workbench.list.keyboardNavigation",yt="workbench.list.automaticKeyboardNavigation",St="workbench.tree.indent",xt="workbench.tree.renderIndentGuides",kt="workbench.list.smoothScrolling",Lt="workbench.list.mouseWheelScrollSensitivity",Et="workbench.list.fastScrollSensitivity",Nt="workbench.tree.expandMode";function Dt(e){return"alt"===e.getValue(bt)}class It extends a.JT{constructor(e){super(),this.configurationService=e,this.useAltAsMultipleSelectionModifier=Dt(e),this.registerListeners()}registerListeners(){this._register(this.configurationService.onDidChangeConfiguration((e=>{e.affectsConfiguration(bt)&&(this.useAltAsMultipleSelectionModifier=Dt(this.configurationService))})))}isSelectionSingleChangeEvent(e){return this.useAltAsMultipleSelectionModifier?e.browserEvent.altKey:(0,l.Zo)(e)}isSelectionRangeChangeEvent(e){return(0,l.wn)(e)}}function Tt(e,t,i){var n;const o=new a.SL;return[Object.assign(Object.assign({},e),{keyboardNavigationDelegate:{mightProducePrintableCharacter:e=>i.mightProducePrintableCharacter(e)},smoothScrolling:Boolean(t.getValue(kt)),mouseWheelScrollSensitivity:t.getValue(Lt),fastScrollSensitivity:t.getValue(Et),multipleSelectionController:null!==(n=e.multipleSelectionController)&&void 0!==n?n:o.add(new It(t))}),o]}let At=class extends l.aV{constructor(e,t,i,n,o,r,s,a,l,c){const d=void 0!==o.horizontalScrolling?o.horizontalScrolling:Boolean(l.getValue(Ct)),[u,h]=Tt(o,l,c);super(e,t,i,n,Object.assign(Object.assign(Object.assign({keyboardSupport:!1},(0,Je.o)(a.getColorTheme(),Je.O2)),u),{horizontalScrolling:d})),this.disposables.add(h),this.contextKeyService=_t(r,this),this.themeService=a,this.listSupportsMultiSelect=st.bindTo(this.contextKeyService),this.listSupportsMultiSelect.set(!1!==o.multipleSelectionSupport),ut.bindTo(this.contextKeyService).set(Boolean(o.selectionNavigation)),this.listHasSelectionOrFocus=lt.bindTo(this.contextKeyService),this.listDoubleSelection=ct.bindTo(this.contextKeyService),this.listMultiSelection=dt.bindTo(this.contextKeyService),this.horizontalScrolling=o.horizontalScrolling,this._useAltAsMultipleSelectionModifier=Dt(l),this.disposables.add(this.contextKeyService),this.disposables.add(s.register(this)),o.overrideStyles&&this.updateStyles(o.overrideStyles),this.disposables.add(this.onDidChangeSelection((()=>{const e=this.getSelection(),t=this.getFocus();this.contextKeyService.bufferChangeEvents((()=>{this.listHasSelectionOrFocus.set(e.length>0||t.length>0),this.listMultiSelection.set(e.length>1),this.listDoubleSelection.set(2===e.length)}))}))),this.disposables.add(this.onDidChangeFocus((()=>{const e=this.getSelection(),t=this.getFocus();this.listHasSelectionOrFocus.set(e.length>0||t.length>0)}))),this.disposables.add(l.onDidChangeConfiguration((e=>{e.affectsConfiguration(bt)&&(this._useAltAsMultipleSelectionModifier=Dt(l));let t={};if(e.affectsConfiguration(Ct)&&void 0===this.horizontalScrolling){const e=Boolean(l.getValue(Ct));t=Object.assign(Object.assign({},t),{horizontalScrolling:e})}if(e.affectsConfiguration(kt)){const e=Boolean(l.getValue(kt));t=Object.assign(Object.assign({},t),{smoothScrolling:e})}if(e.affectsConfiguration(Lt)){const e=l.getValue(Lt);t=Object.assign(Object.assign({},t),{mouseWheelScrollSensitivity:e})}if(e.affectsConfiguration(Et)){const e=l.getValue(Et);t=Object.assign(Object.assign({},t),{fastScrollSensitivity:e})}Object.keys(t).length>0&&this.updateOptions(t)}))),this.navigator=new Pt(this,Object.assign({configurationService:l},o)),this.disposables.add(this.navigator)}updateOptions(e){super.updateOptions(e),e.overrideStyles&&this.updateStyles(e.overrideStyles),void 0!==e.multipleSelectionSupport&&this.listSupportsMultiSelect.set(!!e.multipleSelectionSupport)}updateStyles(e){var t;null===(t=this._styler)||void 0===t||t.dispose(),this._styler=(0,Je.Jl)(this,this.themeService,e)}dispose(){var e;null===(e=this._styler)||void 0===e||e.dispose(),super.dispose()}};At=tt([it(5,Ge.i6),it(6,nt),it(7,et.XE),it(8,Ke.Ui),it(9,Qe.d)],At);let Rt=class extends class{constructor(e,t,i,n,o={}){const r=()=>this.model,s=n.map((e=>new c(e,r)));this.list=new l.aV(e,t,i,s,function(e,t){return Object.assign(Object.assign({},t),{accessibilityProvider:t.accessibilityProvider&&new d(e,t.accessibilityProvider)})}(r,o))}updateOptions(e){this.list.updateOptions(e)}getHTMLElement(){return this.list.getHTMLElement()}get onDidFocus(){return this.list.onDidFocus}get onDidDispose(){return this.list.onDidDispose}get onMouseDblClick(){return s.ju.map(this.list.onMouseDblClick,(({element:e,index:t,browserEvent:i})=>({element:void 0===e?void 0:this._model.get(e),index:t,browserEvent:i})))}get onPointer(){return s.ju.map(this.list.onPointer,(({element:e,index:t,browserEvent:i})=>({element:void 0===e?void 0:this._model.get(e),index:t,browserEvent:i})))}get onDidChangeSelection(){return s.ju.map(this.list.onDidChangeSelection,(({elements:e,indexes:t,browserEvent:i})=>({elements:e.map((e=>this._model.get(e))),indexes:t,browserEvent:i})))}get model(){return this._model}set model(e){this._model=e,this.list.splice(0,this.list.length,(0,o.w6)(e.length))}getFocus(){return this.list.getFocus()}getSelection(){return this.list.getSelection()}getSelectedElements(){return this.getSelection().map((e=>this.model.get(e)))}style(e){this.list.style(e)}dispose(){this.list.dispose()}}{constructor(e,t,i,n,o,r,s,l,c,d){const u=void 0!==o.horizontalScrolling?o.horizontalScrolling:Boolean(c.getValue(Ct)),[h,g]=Tt(o,c,d);super(e,t,i,n,Object.assign(Object.assign(Object.assign({keyboardSupport:!1},(0,Je.o)(l.getColorTheme(),Je.O2)),h),{horizontalScrolling:u})),this.disposables=new a.SL,this.disposables.add(g),this.contextKeyService=_t(r,this),this.themeService=l,this.horizontalScrolling=o.horizontalScrolling,this.listSupportsMultiSelect=st.bindTo(this.contextKeyService),this.listSupportsMultiSelect.set(!1!==o.multipleSelectionSupport),ut.bindTo(this.contextKeyService).set(Boolean(o.selectionNavigation)),this._useAltAsMultipleSelectionModifier=Dt(c),this.disposables.add(this.contextKeyService),this.disposables.add(s.register(this)),o.overrideStyles&&this.updateStyles(o.overrideStyles),o.overrideStyles&&this.disposables.add((0,Je.Jl)(this,l,o.overrideStyles)),this.disposables.add(c.onDidChangeConfiguration((e=>{e.affectsConfiguration(bt)&&(this._useAltAsMultipleSelectionModifier=Dt(c));let t={};if(e.affectsConfiguration(Ct)&&void 0===this.horizontalScrolling){const e=Boolean(c.getValue(Ct));t=Object.assign(Object.assign({},t),{horizontalScrolling:e})}if(e.affectsConfiguration(kt)){const e=Boolean(c.getValue(kt));t=Object.assign(Object.assign({},t),{smoothScrolling:e})}if(e.affectsConfiguration(Lt)){const e=c.getValue(Lt);t=Object.assign(Object.assign({},t),{mouseWheelScrollSensitivity:e})}if(e.affectsConfiguration(Et)){const e=c.getValue(Et);t=Object.assign(Object.assign({},t),{fastScrollSensitivity:e})}Object.keys(t).length>0&&this.updateOptions(t)}))),this.navigator=new Pt(this,Object.assign({configurationService:c},o)),this.disposables.add(this.navigator)}updateOptions(e){super.updateOptions(e),e.overrideStyles&&this.updateStyles(e.overrideStyles),void 0!==e.multipleSelectionSupport&&this.listSupportsMultiSelect.set(!!e.multipleSelectionSupport)}updateStyles(e){var t;null===(t=this._styler)||void 0===t||t.dispose(),this._styler=(0,Je.Jl)(this,this.themeService,e)}dispose(){var e;null===(e=this._styler)||void 0===e||e.dispose(),this.disposables.dispose(),super.dispose()}};Rt=tt([it(5,Ge.i6),it(6,nt),it(7,et.XE),it(8,Ke.Ui),it(9,Qe.d)],Rt);let Mt=class extends N{constructor(e,t,i,n,o,r,s,a,l,c,d){const u=void 0!==r.horizontalScrolling?r.horizontalScrolling:Boolean(c.getValue(Ct)),[h,g]=Tt(r,c,d);super(e,t,i,n,o,Object.assign(Object.assign(Object.assign({keyboardSupport:!1},(0,Je.o)(l.getColorTheme(),Je.O2)),h),{horizontalScrolling:u})),this.disposables.add(g),this.contextKeyService=_t(s,this),this.themeService=l,this.listSupportsMultiSelect=st.bindTo(this.contextKeyService),this.listSupportsMultiSelect.set(!1!==r.multipleSelectionSupport),ut.bindTo(this.contextKeyService).set(Boolean(r.selectionNavigation)),this.listHasSelectionOrFocus=lt.bindTo(this.contextKeyService),this.listDoubleSelection=ct.bindTo(this.contextKeyService),this.listMultiSelection=dt.bindTo(this.contextKeyService),this.horizontalScrolling=r.horizontalScrolling,this._useAltAsMultipleSelectionModifier=Dt(c),this.disposables.add(this.contextKeyService),this.disposables.add(a.register(this)),r.overrideStyles&&this.updateStyles(r.overrideStyles),this.disposables.add(this.onDidChangeSelection((()=>{const e=this.getSelection(),t=this.getFocus();this.contextKeyService.bufferChangeEvents((()=>{this.listHasSelectionOrFocus.set(e.length>0||t.length>0),this.listMultiSelection.set(e.length>1),this.listDoubleSelection.set(2===e.length)}))}))),this.disposables.add(this.onDidChangeFocus((()=>{const e=this.getSelection(),t=this.getFocus();this.listHasSelectionOrFocus.set(e.length>0||t.length>0)}))),this.disposables.add(c.onDidChangeConfiguration((e=>{e.affectsConfiguration(bt)&&(this._useAltAsMultipleSelectionModifier=Dt(c));let t={};if(e.affectsConfiguration(Ct)&&void 0===this.horizontalScrolling){const e=Boolean(c.getValue(Ct));t=Object.assign(Object.assign({},t),{horizontalScrolling:e})}if(e.affectsConfiguration(kt)){const e=Boolean(c.getValue(kt));t=Object.assign(Object.assign({},t),{smoothScrolling:e})}if(e.affectsConfiguration(Lt)){const e=c.getValue(Lt);t=Object.assign(Object.assign({},t),{mouseWheelScrollSensitivity:e})}if(e.affectsConfiguration(Et)){const e=c.getValue(Et);t=Object.assign(Object.assign({},t),{fastScrollSensitivity:e})}Object.keys(t).length>0&&this.updateOptions(t)}))),this.navigator=new Ft(this,Object.assign({configurationService:c},r)),this.disposables.add(this.navigator)}updateOptions(e){super.updateOptions(e),e.overrideStyles&&this.updateStyles(e.overrideStyles),void 0!==e.multipleSelectionSupport&&this.listSupportsMultiSelect.set(!!e.multipleSelectionSupport)}updateStyles(e){var t;null===(t=this._styler)||void 0===t||t.dispose(),this._styler=(0,Je.Jl)(this,this.themeService,e)}dispose(){var e;null===(e=this._styler)||void 0===e||e.dispose(),this.disposables.dispose(),super.dispose()}};Mt=tt([it(6,Ge.i6),it(7,nt),it(8,et.XE),it(9,Ke.Ui),it(10,Qe.d)],Mt);class Ot extends a.JT{constructor(e,t){var i;super(),this.widget=e,this._onDidOpen=this._register(new s.Q5),this.onDidOpen=this._onDidOpen.event,this._register(s.ju.filter(this.widget.onDidChangeSelection,(e=>e.browserEvent instanceof KeyboardEvent))((e=>this.onSelectionFromKeyboard(e)))),this._register(this.widget.onPointer((e=>this.onPointer(e.element,e.browserEvent)))),this._register(this.widget.onMouseDblClick((e=>this.onMouseDblClick(e.element,e.browserEvent)))),"boolean"!=typeof(null==t?void 0:t.openOnSingleClick)&&(null==t?void 0:t.configurationService)?(this.openOnSingleClick="doubleClick"!==(null==t?void 0:t.configurationService.getValue(vt)),this._register(null==t?void 0:t.configurationService.onDidChangeConfiguration((()=>{this.openOnSingleClick="doubleClick"!==(null==t?void 0:t.configurationService.getValue(vt))})))):this.openOnSingleClick=null===(i=null==t?void 0:t.openOnSingleClick)||void 0===i||i}onSelectionFromKeyboard(e){if(1!==e.elements.length)return;const t=e.browserEvent,i="boolean"!=typeof t.preserveFocus||t.preserveFocus,n="boolean"==typeof t.pinned?t.pinned:!i;this._open(this.getSelectedElement(),i,n,!1,e.browserEvent)}onPointer(e,t){if(!this.openOnSingleClick)return;if(2===t.detail)return;const i=1===t.button,n=t.ctrlKey||t.metaKey||t.altKey;this._open(e,!0,i,n,t)}onMouseDblClick(e,t){if(!t)return;const i=t.target;if(i.classList.contains("monaco-tl-twistie")||i.classList.contains("monaco-icon-label")&&i.classList.contains("folder-icon")&&t.offsetX<16)return;const n=t.ctrlKey||t.metaKey||t.altKey;this._open(e,!1,!0,n,t)}_open(e,t,i,n,o){e&&this._onDidOpen.fire({editorOptions:{preserveFocus:t,pinned:i,revealIfVisible:!0},sideBySide:n,element:e,browserEvent:o})}}class Pt extends Ot{constructor(e,t){super(e,t),this.widget=e}getSelectedElement(){return this.widget.getSelectedElements()[0]}}class Ft extends Ot{constructor(e,t){super(e,t)}getSelectedElement(){return this.widget.getSelectedElements()[0]}}class Bt extends Ot{constructor(e,t){super(e,t)}getSelectedElement(){var e;return null!==(e=this.widget.getSelection()[0])&&void 0!==e?e:void 0}}function Wt(e,t){let i=!1;return n=>{if(n.toKeybinding().isModifierKey())return!1;if(i)return i=!1,!1;const o=t.softDispatch(n,e);return o&&o.enterChord?(i=!0,!1):(i=!1,!0)}}let Vt=class extends Se{constructor(e,t,i,n,o,r,s,a,l,c,d){const{options:u,getAutomaticKeyboardNavigation:h,disposable:g}=jt(t,o,r,l,c,d);super(e,t,i,n,u),this.disposables.add(g),this.internals=new Kt(this,o,h,o.overrideStyles,r,s,a,l,d),this.disposables.add(this.internals)}updateOptions(e){super.updateOptions(e),this.internals.updateOptions(e)}};Vt=tt([it(5,Ge.i6),it(6,nt),it(7,et.XE),it(8,Ke.Ui),it(9,Qe.d),it(10,je.F)],Vt);let Ht=class extends ke{constructor(e,t,i,n,o,r,s,a,l,c,d){const{options:u,getAutomaticKeyboardNavigation:h,disposable:g}=jt(t,o,r,l,c,d);super(e,t,i,n,u),this.disposables.add(g),this.internals=new Kt(this,o,h,o.overrideStyles,r,s,a,l,d),this.disposables.add(this.internals)}updateOptions(e={}){super.updateOptions(e),e.overrideStyles&&this.internals.updateStyleOverrides(e.overrideStyles),this.internals.updateOptions(e)}};Ht=tt([it(5,Ge.i6),it(6,nt),it(7,et.XE),it(8,Ke.Ui),it(9,Qe.d),it(10,je.F)],Ht);let zt=class extends Ue{constructor(e,t,i,n,o,r,s,a,l,c,d,u){const{options:h,getAutomaticKeyboardNavigation:g,disposable:p}=jt(t,r,s,c,d,u);super(e,t,i,n,o,h),this.disposables.add(p),this.internals=new Kt(this,r,g,r.overrideStyles,s,a,l,c,u),this.disposables.add(this.internals)}updateOptions(e={}){super.updateOptions(e),e.overrideStyles&&this.internals.updateStyleOverrides(e.overrideStyles),this.internals.updateOptions(e)}};zt=tt([it(6,Ge.i6),it(7,nt),it(8,et.XE),it(9,Ke.Ui),it(10,Qe.d),it(11,je.F)],zt);let $t=class extends Ve{constructor(e,t,i,n,o,r,s,a,l,c,d,u){const{options:h,getAutomaticKeyboardNavigation:g,disposable:p}=jt(t,r,s,c,d,u);super(e,t,i,n,o,h),this.disposables.add(p),this.internals=new Kt(this,r,g,r.overrideStyles,s,a,l,c,u),this.disposables.add(this.internals)}get onDidOpen(){return this.internals.onDidOpen}updateOptions(e={}){super.updateOptions(e),e.overrideStyles&&this.internals.updateStyleOverrides(e.overrideStyles),this.internals.updateOptions(e)}};$t=tt([it(6,Ge.i6),it(7,nt),it(8,et.XE),it(9,Ke.Ui),it(10,Qe.d),it(11,je.F)],$t);let Ut=class extends $e{constructor(e,t,i,n,o,r,s,a,l,c,d,u,h){const{options:g,getAutomaticKeyboardNavigation:p,disposable:m}=jt(t,s,a,d,u,h);super(e,t,i,n,o,r,g),this.disposables.add(m),this.internals=new Kt(this,s,p,s.overrideStyles,a,l,c,d,h),this.disposables.add(this.internals)}updateOptions(e){super.updateOptions(e),this.internals.updateOptions(e)}};function jt(e,t,i,n,o,r){var s;const a=()=>{let e=Boolean(i.getContextKeyValue(ft));return e&&(e=Boolean(n.getValue(yt))),e},l=r.isScreenReaderOptimized(),c=t.simpleKeyboardNavigation||l?"simple":n.getValue(wt),d=void 0!==t.horizontalScrolling?t.horizontalScrolling:Boolean(n.getValue(Ct)),[u,h]=Tt(t,n,o),g=t.additionalScrollHeight;return{getAutomaticKeyboardNavigation:a,disposable:h,options:Object.assign(Object.assign({keyboardSupport:!1},u),{indent:"number"==typeof n.getValue(St)?n.getValue(St):void 0,renderIndentGuides:n.getValue(xt),smoothScrolling:Boolean(n.getValue(kt)),automaticKeyboardNavigation:a(),simpleKeyboardNavigation:"simple"===c,filterOnType:"filter"===c,horizontalScrolling:d,keyboardNavigationEventFilter:Wt(e,o),additionalScrollHeight:g,hideTwistiesOfChildlessElements:t.hideTwistiesOfChildlessElements,expandOnlyOnTwistieClick:null!==(s=t.expandOnlyOnTwistieClick)&&void 0!==s?s:"doubleClick"===n.getValue(Nt)})}}Ut=tt([it(7,Ge.i6),it(8,nt),it(9,et.XE),it(10,Ke.Ui),it(11,Qe.d),it(12,je.F)],Ut);let Kt=class{constructor(e,t,i,n,o,r,s,a,l){this.tree=e,this.themeService=s,this.disposables=[],this.contextKeyService=_t(o,e),this.listSupportsMultiSelect=st.bindTo(this.contextKeyService),this.listSupportsMultiSelect.set(!1!==t.multipleSelectionSupport),ut.bindTo(this.contextKeyService).set(Boolean(t.selectionNavigation)),this.hasSelectionOrFocus=lt.bindTo(this.contextKeyService),this.hasDoubleSelection=ct.bindTo(this.contextKeyService),this.hasMultiSelection=dt.bindTo(this.contextKeyService),this.treeElementCanCollapse=ht.bindTo(this.contextKeyService),this.treeElementHasParent=gt.bindTo(this.contextKeyService),this.treeElementCanExpand=pt.bindTo(this.contextKeyService),this.treeElementHasChild=mt.bindTo(this.contextKeyService),this._useAltAsMultipleSelectionModifier=Dt(a);const c=new Set;c.add(ft);const d=()=>{const t=l.isScreenReaderOptimized()?"simple":a.getValue(wt);e.updateOptions({simpleKeyboardNavigation:"simple"===t,filterOnType:"filter"===t})};this.updateStyleOverrides(n);const u=()=>{const t=e.getFocus()[0];if(!t)return;const i=e.getNode(t);this.treeElementCanCollapse.set(i.collapsible&&!i.collapsed),this.treeElementHasParent.set(!!e.getParentElement(t)),this.treeElementCanExpand.set(i.collapsible&&i.collapsed),this.treeElementHasChild.set(!!e.getFirstElementChild(t))};this.disposables.push(this.contextKeyService,r.register(e),e.onDidChangeSelection((()=>{const t=e.getSelection(),i=e.getFocus();this.contextKeyService.bufferChangeEvents((()=>{this.hasSelectionOrFocus.set(t.length>0||i.length>0),this.hasMultiSelection.set(t.length>1),this.hasDoubleSelection.set(2===t.length)}))})),e.onDidChangeFocus((()=>{const t=e.getSelection(),i=e.getFocus();this.hasSelectionOrFocus.set(t.length>0||i.length>0),u()})),e.onDidChangeCollapseState(u),e.onDidChangeModel(u),a.onDidChangeConfiguration((n=>{let o={};if(n.affectsConfiguration(bt)&&(this._useAltAsMultipleSelectionModifier=Dt(a)),n.affectsConfiguration(St)){const e=a.getValue(St);o=Object.assign(Object.assign({},o),{indent:e})}if(n.affectsConfiguration(xt)){const e=a.getValue(xt);o=Object.assign(Object.assign({},o),{renderIndentGuides:e})}if(n.affectsConfiguration(kt)){const e=Boolean(a.getValue(kt));o=Object.assign(Object.assign({},o),{smoothScrolling:e})}if(n.affectsConfiguration(wt)&&d(),n.affectsConfiguration(yt)&&(o=Object.assign(Object.assign({},o),{automaticKeyboardNavigation:i()})),n.affectsConfiguration(Ct)&&void 0===t.horizontalScrolling){const e=Boolean(a.getValue(Ct));o=Object.assign(Object.assign({},o),{horizontalScrolling:e})}if(n.affectsConfiguration(Nt)&&void 0===t.expandOnlyOnTwistieClick&&(o=Object.assign(Object.assign({},o),{expandOnlyOnTwistieClick:"doubleClick"===a.getValue(Nt)})),n.affectsConfiguration(Lt)){const e=a.getValue(Lt);o=Object.assign(Object.assign({},o),{mouseWheelScrollSensitivity:e})}if(n.affectsConfiguration(Et)){const e=a.getValue(Et);o=Object.assign(Object.assign({},o),{fastScrollSensitivity:e})}Object.keys(o).length>0&&e.updateOptions(o)})),this.contextKeyService.onDidChangeContext((t=>{t.affectsSome(c)&&e.updateOptions({automaticKeyboardNavigation:i()})})),l.onDidChangeScreenReaderOptimized((()=>d()))),this.navigator=new Bt(e,Object.assign({configurationService:a},t)),this.disposables.push(this.navigator)}get onDidOpen(){return this.navigator.onDidOpen}updateOptions(e){void 0!==e.multipleSelectionSupport&&this.listSupportsMultiSelect.set(!!e.multipleSelectionSupport)}updateStyleOverrides(e){(0,a.B9)(this.styler),this.styler=e?(0,Je.Jl)(this.tree,this.themeService,e):a.JT.None}dispose(){this.disposables=(0,a.B9)(this.disposables),(0,a.B9)(this.styler),this.styler=void 0}};Kt=tt([it(4,Ge.i6),it(5,nt),it(6,et.XE),it(7,Ke.Ui),it(8,je.F)],Kt),Xe.B.as(qe.IP.Configuration).registerConfiguration({id:"workbench",order:7,title:(0,Q.NC)("vs/platform/list/browser/listService","workbenchConfigurationTitle","Workbench"),type:"object",properties:{[bt]:{type:"string",enum:["ctrlCmd","alt"],enumDescriptions:[(0,Q.NC)("vs/platform/list/browser/listService","multiSelectModifier.ctrlCmd","Maps to `Control` on Windows and Linux and to `Command` on macOS."),(0,Q.NC)("vs/platform/list/browser/listService","multiSelectModifier.alt","Maps to `Alt` on Windows and Linux and to `Option` on macOS.")],default:"ctrlCmd",description:(0,Q.NC)("vs/platform/list/browser/listService",{key:"multiSelectModifier",comment:["- `ctrlCmd` refers to a value the setting can take and should not be localized.","- `Control` and `Command` refer to the modifier keys Ctrl or Cmd on the keyboard and can be localized."]},"The modifier to be used to add an item in trees and lists to a multi-selection with the mouse (for example in the explorer, open editors and scm view). The 'Open to Side' mouse gestures - if supported - will adapt such that they do not conflict with the multiselect modifier.")},[vt]:{type:"string",enum:["singleClick","doubleClick"],default:"singleClick",description:(0,Q.NC)("vs/platform/list/browser/listService",{key:"openModeModifier",comment:["`singleClick` and `doubleClick` refers to a value the setting can take and should not be localized."]},"Controls how to open items in trees and lists using the mouse (if supported). Note that some trees and lists might choose to ignore this setting if it is not applicable.")},[Ct]:{type:"boolean",default:!1,description:(0,Q.NC)("vs/platform/list/browser/listService","horizontalScrolling setting","Controls whether lists and trees support horizontal scrolling in the workbench. Warning: turning on this setting has a performance implication.")},[St]:{type:"number",default:8,minimum:4,maximum:40,description:(0,Q.NC)("vs/platform/list/browser/listService","tree indent setting","Controls tree indentation in pixels.")},[xt]:{type:"string",enum:["none","onHover","always"],default:"onHover",description:(0,Q.NC)("vs/platform/list/browser/listService","render tree indent guides","Controls whether the tree should render indent guides.")},[kt]:{type:"boolean",default:!1,description:(0,Q.NC)("vs/platform/list/browser/listService","list smoothScrolling setting","Controls whether lists and trees have smooth scrolling.")},[Lt]:{type:"number",default:1,description:(0,Q.NC)("vs/platform/list/browser/listService","Mouse Wheel Scroll Sensitivity","A multiplier to be used on the `deltaX` and `deltaY` of mouse wheel scroll events.")},[Et]:{type:"number",default:5,description:(0,Q.NC)("vs/platform/list/browser/listService","Fast Scroll Sensitivity","Scrolling speed multiplier when pressing `Alt`.")},[wt]:{type:"string",enum:["simple","highlight","filter"],enumDescriptions:[(0,Q.NC)("vs/platform/list/browser/listService","keyboardNavigationSettingKey.simple","Simple keyboard navigation focuses elements which match the keyboard input. Matching is done only on prefixes."),(0,Q.NC)("vs/platform/list/browser/listService","keyboardNavigationSettingKey.highlight","Highlight keyboard navigation highlights elements which match the keyboard input. Further up and down navigation will traverse only the highlighted elements."),(0,Q.NC)("vs/platform/list/browser/listService","keyboardNavigationSettingKey.filter","Filter keyboard navigation will filter out and hide all the elements which do not match the keyboard input.")],default:"highlight",description:(0,Q.NC)("vs/platform/list/browser/listService","keyboardNavigationSettingKey","Controls the keyboard navigation style for lists and trees in the workbench. Can be simple, highlight and filter.")},[yt]:{type:"boolean",default:!0,markdownDescription:(0,Q.NC)("vs/platform/list/browser/listService","automatic keyboard navigation setting","Controls whether keyboard navigation in lists and trees is automatically triggered simply by typing. If set to `false`, keyboard navigation is only triggered when executing the `list.toggleKeyboardNavigation` command, for which you can assign a keyboard shortcut.")},[Nt]:{type:"string",enum:["singleClick","doubleClick"],default:"singleClick",description:(0,Q.NC)("vs/platform/list/browser/listService","expand mode","Controls how tree folders are expanded when clicking the folder names. Note that some trees and lists might choose to ignore this setting if it is not applicable.")}}})},16592:function(e,t,i){"use strict";i.d(t,{$V:function(){return d},VZ:function(){return r},in:function(){return s},kw:function(){return c}});var n=i(46718),o=i(4004);const r=(0,i(12260).yh)("logService");var s;!function(e){e[e.Trace=0]="Trace",e[e.Debug=1]="Debug",e[e.Info=2]="Info",e[e.Warning=3]="Warning",e[e.Error=4]="Error",e[e.Critical=5]="Critical",e[e.Off=6]="Off"}(s||(s={}));const a=s.Info;class l extends o.JT{constructor(){super(...arguments),this.level=a,this._onDidChangeLogLevel=this._register(new n.Q5)}setLevel(e){this.level!==e&&(this.level=e,this._onDidChangeLogLevel.fire(this.level))}getLevel(){return this.level}}class c extends l{constructor(e=a){super(),this.setLevel(e)}trace(e,...t){this.getLevel()<=s.Trace&&console.log("%cTRACE","color: #888",e,...t)}debug(e,...t){this.getLevel()<=s.Debug&&console.log("%cDEBUG","background: #eee; color: #888",e,...t)}info(e,...t){this.getLevel()<=s.Info&&console.log("%c INFO","color: #33f",e,...t)}error(e,...t){this.getLevel()<=s.Error&&console.log("%c ERR","color: #f33",e,...t)}dispose(){}}class d extends o.JT{constructor(e){super(),this.logger=e,this._register(e)}getLevel(){return this.logger.getLevel()}trace(e,...t){this.logger.trace(e,...t)}debug(e,...t){this.logger.debug(e,...t)}info(e,...t){this.logger.info(e,...t)}error(e,...t){this.logger.error(e,...t)}}},27498:function(e,t,i){"use strict";i.d(t,{H0:function(){return o},ZL:function(){return n},lT:function(){return l}});var n,o,r=i(81234),s=i(89982),a=i(12260);!function(e){e[e.Hint=1]="Hint",e[e.Info=2]="Info",e[e.Warning=4]="Warning",e[e.Error=8]="Error"}(n||(n={})),function(e){e.compare=function(e,t){return t-e};const t=Object.create(null);t[e.Error]=(0,s.NC)("vs/platform/markers/common/markers","sev.error","Error"),t[e.Warning]=(0,s.NC)("vs/platform/markers/common/markers","sev.warning","Warning"),t[e.Info]=(0,s.NC)("vs/platform/markers/common/markers","sev.info","Info"),e.toString=function(e){return t[e]||""},e.fromSeverity=function(t){switch(t){case r.Z.Error:return e.Error;case r.Z.Warning:return e.Warning;case r.Z.Info:return e.Info;case r.Z.Ignore:return e.Hint}},e.toSeverity=function(t){switch(t){case e.Error:return r.Z.Error;case e.Warning:return r.Z.Warning;case e.Info:return r.Z.Info;case e.Hint:return r.Z.Ignore}}}(n||(n={})),function(e){const t="";function i(e,i){let o=[t];return e.source?o.push(e.source.replace("¦","\\¦")):o.push(t),e.code?"string"==typeof e.code?o.push(e.code.replace("¦","\\¦")):o.push(e.code.value.replace("¦","\\¦")):o.push(t),void 0!==e.severity&&null!==e.severity?o.push(n.toString(e.severity)):o.push(t),e.message&&i?o.push(e.message.replace("¦","\\¦")):o.push(t),void 0!==e.startLineNumber&&null!==e.startLineNumber?o.push(e.startLineNumber.toString()):o.push(t),void 0!==e.startColumn&&null!==e.startColumn?o.push(e.startColumn.toString()):o.push(t),void 0!==e.endLineNumber&&null!==e.endLineNumber?o.push(e.endLineNumber.toString()):o.push(t),void 0!==e.endColumn&&null!==e.endColumn?o.push(e.endColumn.toString()):o.push(t),o.push(t),o.join("¦")}e.makeKey=function(e){return i(e,!0)},e.makeKeyOptionalMessage=i}(o||(o={}));const l=(0,a.yh)("markerService")},66877:function(e,t,i){"use strict";i.d(t,{EO:function(){return a},lT:function(){return s},zb:function(){return r}});var n=i(81234),o=i(12260),r=n.Z;const s=(0,o.yh)("notificationService");class a{}},82523:function(e,t,i){"use strict";i.d(t,{Gs:function(){return u},SW:function(){return c},v4:function(){return l},xI:function(){return h},xn:function(){return d}});var n=i(4004),o=i(18039),r=i(39675),s=i(12260),a=function(e,t,i,n){return new(i||(i=Promise))((function(o,r){function s(e){try{l(n.next(e))}catch(e){r(e)}}function a(e){try{l(n.throw(e))}catch(e){r(e)}}function l(e){var t;e.done?o(e.value):(t=e.value,t instanceof i?t:new i((function(e){e(t)}))).then(s,a)}l((n=n.apply(e,t||[])).next())}))};const l=(0,s.yh)("openerService"),c=Object.freeze({_serviceBrand:void 0,registerOpener:()=>n.JT.None,registerValidator:()=>n.JT.None,registerExternalUriResolver:()=>n.JT.None,setDefaultExternalOpener(){},registerExternalOpener:()=>n.JT.None,open(){return a(this,void 0,void 0,(function*(){return!1}))},resolveExternalUri(e){return a(this,void 0,void 0,(function*(){return{resolved:e,dispose(){}}}))}});function d(e,t){return r.o.isUri(e)?(0,o.qq)(e.scheme,t):(0,o.ok)(e,t+":")}function u(e,...t){return t.some((t=>d(e,t)))}function h(e){let t;const i=/^L?(\d+)(?:,(\d+))?(-L?(\d+)(?:,(\d+))?)?/.exec(e.fragment);return i&&(t={startLineNumber:parseInt(i[1]),startColumn:i[2]?parseInt(i[2]):1,endLineNumber:i[4]?parseInt(i[4]):void 0,endColumn:i[4]?i[5]?parseInt(i[5]):1:void 0},e=e.with({fragment:""})),{selection:t,uri:e}}},35073:function(e,t,i){"use strict";i.d(t,{Ex:function(){return o},ek:function(){return r}});var n=i(12260);Object.freeze({total(){},worked(){},done(){}});class o{constructor(e){this.callback=e}report(e){this._value=e,this.callback(this._value)}}o.None=Object.freeze({report(){}});const r=(0,n.yh)("editorProgressService")},34073:function(e,t,i){"use strict";i.d(t,{IP:function(){return a},Ry:function(){return n}});var n,o=i(57800),r=i(4004),s=i(73403);!function(e){e[e.PRESERVE=0]="PRESERVE",e[e.LAST=1]="LAST"}(n||(n={}));const a={Quickaccess:"workbench.contributions.quickaccess"};s.B.add(a.Quickaccess,new class{constructor(){this.providers=[],this.defaultProvider=void 0}registerQuickAccessProvider(e){return 0===e.prefix.length?this.defaultProvider=e:this.providers.push(e),this.providers.sort(((e,t)=>t.prefix.length-e.prefix.length)),(0,r.OF)((()=>{this.providers.splice(this.providers.indexOf(e),1),this.defaultProvider===e&&(this.defaultProvider=void 0)}))}getQuickAccessProviders(){return(0,o.kX)([this.defaultProvider,...this.providers])}getQuickAccessProvider(e){return e&&this.providers.find((t=>e.startsWith(t.prefix)))||this.defaultProvider}})},22447:function(e,t,i){"use strict";i.d(t,{eJ:function(){return r},jG:function(){return o.jG}});var n=i(12260),o=i(55470);const r=(0,n.yh)("quickInputService")},73403:function(e,t,i){"use strict";i.d(t,{B:function(){return r}});var n=i(69974),o=i(28295);const r=new class{constructor(){this.data=new Map}add(e,t){n.ok(o.HD(e)),n.ok(o.Kn(t)),n.ok(!this.data.has(e),"There is already an extension with this id"),this.data.set(e,t)}as(e){return this.data.get(e)||null}}},86303:function(e,t,i){"use strict";i.d(t,{Uy:function(){return g},vm:function(){return f},fk:function(){return p}});var n,o=i(46718),r=i(4004),s=i(28295),a=i(40027),l=function(e,t,i,n){return new(i||(i=Promise))((function(o,r){function s(e){try{l(n.next(e))}catch(e){r(e)}}function a(e){try{l(n.throw(e))}catch(e){r(e)}}function l(e){var t;e.done?o(e.value):(t=e.value,t instanceof i?t:new i((function(e){e(t)}))).then(s,a)}l((n=n.apply(e,t||[])).next())}))};!function(e){e[e.None=0]="None",e[e.Initialized=1]="Initialized",e[e.Closed=2]="Closed"}(n||(n={}));class c extends r.JT{constructor(e,t=Object.create(null)){super(),this.database=e,this.options=t,this._onDidChangeStorage=this._register(new o.Q5),this.onDidChangeStorage=this._onDidChangeStorage.event,this.state=n.None,this.cache=new Map,this.flushDelayer=new a.rH(c.DEFAULT_FLUSH_DELAY),this.pendingDeletes=new Set,this.pendingInserts=new Map,this.whenFlushedCallbacks=[],this.registerListeners()}registerListeners(){this._register(this.database.onDidChangeItemsExternal((e=>this.onDidChangeItemsExternal(e))))}onDidChangeItemsExternal(e){var t,i;null===(t=e.changed)||void 0===t||t.forEach(((e,t)=>this.accept(t,e))),null===(i=e.deleted)||void 0===i||i.forEach((e=>this.accept(e,void 0)))}accept(e,t){if(this.state===n.Closed)return;let i=!1;(0,s.Jp)(t)?i=this.cache.delete(e):this.cache.get(e)!==t&&(this.cache.set(e,t),i=!0),i&&this._onDidChangeStorage.fire(e)}get(e,t){const i=this.cache.get(e);return(0,s.Jp)(i)?t:i}getBoolean(e,t){const i=this.get(e);return(0,s.Jp)(i)?t:"true"===i}getNumber(e,t){const i=this.get(e);return(0,s.Jp)(i)?t:parseInt(i,10)}set(e,t){return l(this,void 0,void 0,(function*(){if(this.state===n.Closed)return;if((0,s.Jp)(t))return this.delete(e);const i=String(t);return this.cache.get(e)!==i?(this.cache.set(e,i),this.pendingInserts.set(e,i),this.pendingDeletes.delete(e),this._onDidChangeStorage.fire(e),this.doFlush()):void 0}))}delete(e){return l(this,void 0,void 0,(function*(){if(this.state!==n.Closed)return this.cache.delete(e)?(this.pendingDeletes.has(e)||this.pendingDeletes.add(e),this.pendingInserts.delete(e),this._onDidChangeStorage.fire(e),this.doFlush()):void 0}))}get hasPending(){return this.pendingInserts.size>0||this.pendingDeletes.size>0}flushPending(){return l(this,void 0,void 0,(function*(){if(!this.hasPending)return;const e={insert:this.pendingInserts,delete:this.pendingDeletes};return this.pendingDeletes=new Set,this.pendingInserts=new Map,this.database.updateItems(e).finally((()=>{var e;if(!this.hasPending)for(;this.whenFlushedCallbacks.length;)null===(e=this.whenFlushedCallbacks.pop())||void 0===e||e()}))}))}doFlush(e){return l(this,void 0,void 0,(function*(){return this.flushDelayer.trigger((()=>this.flushPending()),e)}))}dispose(){this.flushDelayer.dispose(),super.dispose()}}c.DEFAULT_FLUSH_DELAY=100;class d{constructor(){this.onDidChangeItemsExternal=o.ju.None,this.items=new Map}updateItems(e){return l(this,void 0,void 0,(function*(){e.insert&&e.insert.forEach(((e,t)=>this.items.set(t,e))),e.delete&&e.delete.forEach((e=>this.items.delete(e)))}))}}var u=i(12260);const h="__$__targetStorageMarker",g=(0,u.yh)("storageService");var p;!function(e){e[e.NONE=0]="NONE",e[e.SHUTDOWN=1]="SHUTDOWN"}(p||(p={}));class m extends r.JT{constructor(e={flushInterval:m.DEFAULT_FLUSH_INTERVAL}){super(),this.options=e,this._onDidChangeValue=this._register(new o.K3),this._onDidChangeTarget=this._register(new o.K3),this._onWillSaveState=this._register(new o.Q5),this.onWillSaveState=this._onWillSaveState.event,this._workspaceKeyTargets=void 0,this._globalKeyTargets=void 0}emitDidChangeValue(e,t){t===h?(0===e?this._globalKeyTargets=void 0:1===e&&(this._workspaceKeyTargets=void 0),this._onDidChangeTarget.fire({scope:e})):this._onDidChangeValue.fire({scope:e,key:t,target:this.getKeyTargets(e)[t]})}get(e,t,i){var n;return null===(n=this.getStorage(t))||void 0===n?void 0:n.get(e,i)}getBoolean(e,t,i){var n;return null===(n=this.getStorage(t))||void 0===n?void 0:n.getBoolean(e,i)}getNumber(e,t,i){var n;return null===(n=this.getStorage(t))||void 0===n?void 0:n.getNumber(e,i)}store(e,t,i,n){(0,s.Jp)(t)?this.remove(e,i):this.withPausedEmitters((()=>{var o;this.updateKeyTarget(e,i,n),null===(o=this.getStorage(i))||void 0===o||o.set(e,t)}))}remove(e,t){this.withPausedEmitters((()=>{var i;this.updateKeyTarget(e,t,void 0),null===(i=this.getStorage(t))||void 0===i||i.delete(e)}))}withPausedEmitters(e){this._onDidChangeValue.pause(),this._onDidChangeTarget.pause();try{e()}finally{this._onDidChangeValue.resume(),this._onDidChangeTarget.resume()}}updateKeyTarget(e,t,i){var n,o;const r=this.getKeyTargets(t);"number"==typeof i?r[e]!==i&&(r[e]=i,null===(n=this.getStorage(t))||void 0===n||n.set(h,JSON.stringify(r))):"number"==typeof r[e]&&(delete r[e],null===(o=this.getStorage(t))||void 0===o||o.set(h,JSON.stringify(r)))}get workspaceKeyTargets(){return this._workspaceKeyTargets||(this._workspaceKeyTargets=this.loadKeyTargets(1)),this._workspaceKeyTargets}get globalKeyTargets(){return this._globalKeyTargets||(this._globalKeyTargets=this.loadKeyTargets(0)),this._globalKeyTargets}getKeyTargets(e){return 0===e?this.globalKeyTargets:this.workspaceKeyTargets}loadKeyTargets(e){const t=this.get(h,e);if(t)try{return JSON.parse(t)}catch(e){}return Object.create(null)}}m.DEFAULT_FLUSH_INTERVAL=6e4;class f extends m{constructor(){super(),this.globalStorage=this._register(new c(new d)),this.workspaceStorage=this._register(new c(new d)),this._register(this.workspaceStorage.onDidChangeStorage((e=>this.emitDidChangeValue(1,e)))),this._register(this.globalStorage.onDidChangeStorage((e=>this.emitDidChangeValue(0,e))))}getStorage(e){return 0===e?this.globalStorage:this.workspaceStorage}}},56080:function(e,t,i){"use strict";i.d(t,{b:function(){return n}});const n=(0,i(12260).yh)("telemetryService")},45164:function(e,t,i){"use strict";i.d(t,{$DX:function(){return zt},$d5:function(){return yt},ABB:function(){return Y},AS1:function(){return St},AWI:function(){return Se},BOY:function(){return gi},C3g:function(){return O},CA6:function(){return ci},CNo:function(){return We},Cdg:function(){return Bt},CzK:function(){return Ye},D0T:function(){return he},D1_:function(){return pe},DEr:function(){return Wt},Dut:function(){return le},E3h:function(){return $t},EPQ:function(){return A},EQn:function(){return Rt},ES4:function(){return Ee},EiJ:function(){return Me},F3d:function(){return Ct},F9q:function(){return rt},Fm_:function(){return ei},Fu1:function(){return Ge},GO4:function(){return U},Gj_:function(){return ri},Gwp:function(){return xt},HCL:function(){return Ke},Hfx:function(){return ge},Hz8:function(){return Vt},IPX:function(){return u},IYc:function(){return ni},Ido:function(){return m},Itd:function(){return li},Ivo:function(){return si},JpG:function(){return hi},K19:function(){return xe},LLc:function(){return lt},L_H:function(){return J},L_t:function(){return ct},LoV:function(){return Ve},M6C:function(){return pt},MUv:function(){return Te},NOs:function(){return ue},NPS:function(){return Ot},Ng6:function(){return me},OLZ:function(){return pi},OZR:function(){return B},Oop:function(){return ht},P4M:function(){return Je},P6G:function(){return g},P6Y:function(){return ot},PRb:function(){return E},PX0:function(){return kt},PpC:function(){return $e},Pvw:function(){return D},QO2:function(){return d},R80:function(){return _},RV_:function(){return R},Rzx:function(){return Ne},SPM:function(){return ti},SUG:function(){return M},SUY:function(){return ii},Saq:function(){return It},Sbf:function(){return Be},Snq:function(){return Ci},SwI:function(){return y},T83:function(){return ae},Tnx:function(){return mt},UnT:function(){return Tt},VVv:function(){return ze},Vqd:function(){return Ft},XEs:function(){return N},XL$:function(){return st},XZx:function(){return f},Xy4:function(){return di},YI3:function(){return T},ZGJ:function(){return Ut},ZnX:function(){return _i},_2n:function(){return ut},_Yy:function(){return He},_bK:function(){return dt},_lC:function(){return I},_t9:function(){return F},_wn:function(){return G},b6y:function(){return te},b7$:function(){return $},bKB:function(){return je},brw:function(){return ui},c63:function(){return se},cbQ:function(){return Pt},cvW:function(){return de},dCr:function(){return gt},dRz:function(){return p},dt_:function(){return L},etL:function(){return Z},fEB:function(){return ce},few:function(){return re},g8u:function(){return K},g_n:function(){return De},gkn:function(){return Oe},gpD:function(){return ie},hEj:function(){return ke},hX8:function(){return Ue},hzo:function(){return et},j51:function(){return it},j5u:function(){return z},jUe:function(){return Ae},jbW:function(){return Ht},kJk:function(){return ve},kVY:function(){return ai},keg:function(){return Qe},kvU:function(){return bt},kwl:function(){return bi},lRK:function(){return b},lUq:function(){return jt},lWp:function(){return ye},lXJ:function(){return ee},loF:function(){return be},mHy:function(){return at},mV1:function(){return wt},nyM:function(){return Ie},oQ$:function(){return we},oSI:function(){return Dt},opG:function(){return Ce},ov3:function(){return oi},pW3:function(){return oe},paE:function(){return P},phM:function(){return qe},pnM:function(){return Re},ptc:function(){return Pe},qeD:function(){return q},rg2:function(){return ft},rh:function(){return S},s$:function(){return vt},sEe:function(){return x},sKV:function(){return Ze},sgC:function(){return w},tZ6:function(){return _e},uoC:function(){return ne},url:function(){return C},uxu:function(){return At},vGG:function(){return Nt},xL1:function(){return v},xi6:function(){return tt},yJx:function(){return Fe},yb5:function(){return Le},ynu:function(){return Q},ypS:function(){return Xe},ytC:function(){return _t},zJb:function(){return k},zKr:function(){return fe},zOm:function(){return nt},zRJ:function(){return X}});var n=i(40027),o=i(18689),r=i(46718),s=i(28295),a=i(89982),l=i(32801),c=i(73403);function d(e){return`--vscode-${e.replace(/\./g,"-")}`}const u={ColorContribution:"base.contributions.colors"},h=new class{constructor(){this._onDidChangeSchema=new r.Q5,this.onDidChangeSchema=this._onDidChangeSchema.event,this.colorSchema={type:"object",properties:{}},this.colorReferenceSchema={type:"string",enum:[],enumDescriptions:[]},this.colorsById={}}registerColor(e,t,i,n=!1,o){let r={id:e,description:i,defaults:t,needsTransparency:n,deprecationMessage:o};this.colorsById[e]=r;let s={type:"string",description:i,format:"color-hex",defaultSnippets:[{body:"${1:#ff0000}"}]};return o&&(s.deprecationMessage=o),this.colorSchema.properties[e]=s,this.colorReferenceSchema.enum.push(e),this.colorReferenceSchema.enumDescriptions.push(i),this._onDidChangeSchema.fire(),e}getColors(){return Object.keys(this.colorsById).map((e=>this.colorsById[e]))}resolveDefaultColor(e,t){const i=this.colorsById[e];if(i&&i.defaults)return Ci(i.defaults[t.type],t)}getColorSchema(){return this.colorSchema}toString(){return Object.keys(this.colorsById).sort(((e,t)=>{let i=-1===e.indexOf(".")?0:1,n=-1===t.indexOf(".")?0:1;return i!==n?i-n:e.localeCompare(t)})).map((e=>`- \`${e}\`: ${this.colorsById[e].description}`)).join("\n")}};function g(e,t,i,n,o){return h.registerColor(e,t,i,n,o)}c.B.add(u.ColorContribution,h);const p=g("foreground",{dark:"#CCCCCC",light:"#616161",hc:"#FFFFFF"},a.NC("vs/platform/theme/common/colorRegistry","foreground","Overall foreground color. This color is only used if not overridden by a component.")),m=g("errorForeground",{dark:"#F48771",light:"#A1260D",hc:"#F48771"},a.NC("vs/platform/theme/common/colorRegistry","errorForeground","Overall foreground color for error messages. This color is only used if not overridden by a component.")),f=(g("descriptionForeground",{light:"#717171",dark:_i(p,.7),hc:_i(p,.7)},a.NC("vs/platform/theme/common/colorRegistry","descriptionForeground","Foreground color for description text providing additional information, for example for a label.")),g("icon.foreground",{dark:"#C5C5C5",light:"#424242",hc:"#FFFFFF"},a.NC("vs/platform/theme/common/colorRegistry","iconForeground","The default color for icons in the workbench."))),_=g("focusBorder",{dark:"#007FD4",light:"#0090F1",hc:"#F38518"},a.NC("vs/platform/theme/common/colorRegistry","focusBorder","Overall border color for focused elements. This color is only used if not overridden by a component.")),b=g("contrastBorder",{light:null,dark:null,hc:"#6FC3DF"},a.NC("vs/platform/theme/common/colorRegistry","contrastBorder","An extra border around elements to separate them from others for greater contrast.")),v=g("contrastActiveBorder",{light:null,dark:null,hc:_},a.NC("vs/platform/theme/common/colorRegistry","activeContrastBorder","An extra border around active elements to separate them from others for greater contrast.")),C=(g("selection.background",{light:null,dark:null,hc:null},a.NC("vs/platform/theme/common/colorRegistry","selectionBackground","The background color of text selections in the workbench (e.g. for input fields or text areas). Note that this does not apply to selections within the editor.")),g("textSeparator.foreground",{light:"#0000002e",dark:"#ffffff2e",hc:o.Il.black},a.NC("vs/platform/theme/common/colorRegistry","textSeparatorForeground","Color for text separators.")),g("textLink.foreground",{light:"#006AB1",dark:"#3794FF",hc:"#3794FF"},a.NC("vs/platform/theme/common/colorRegistry","textLinkForeground","Foreground color for links in text."))),w=g("textLink.activeForeground",{light:"#006AB1",dark:"#3794FF",hc:"#3794FF"},a.NC("vs/platform/theme/common/colorRegistry","textLinkActiveForeground","Foreground color for links in text when clicked on and on mouse hover.")),y=(g("textPreformat.foreground",{light:"#A31515",dark:"#D7BA7D",hc:"#D7BA7D"},a.NC("vs/platform/theme/common/colorRegistry","textPreformatForeground","Foreground color for preformatted text segments.")),g("textBlockQuote.background",{light:"#7f7f7f1a",dark:"#7f7f7f1a",hc:null},a.NC("vs/platform/theme/common/colorRegistry","textBlockQuoteBackground","Background color for block quotes in text.")),g("textBlockQuote.border",{light:"#007acc80",dark:"#007acc80",hc:o.Il.white},a.NC("vs/platform/theme/common/colorRegistry","textBlockQuoteBorder","Border color for block quotes in text.")),g("textCodeBlock.background",{light:"#dcdcdc66",dark:"#0a0a0a66",hc:o.Il.black},a.NC("vs/platform/theme/common/colorRegistry","textCodeBlockBackground","Background color for code blocks in text."))),S=g("widget.shadow",{dark:_i(o.Il.black,.36),light:_i(o.Il.black,.16),hc:null},a.NC("vs/platform/theme/common/colorRegistry","widgetShadow","Shadow color of widgets such as find/replace inside the editor.")),x=g("input.background",{dark:"#3C3C3C",light:o.Il.white,hc:o.Il.black},a.NC("vs/platform/theme/common/colorRegistry","inputBoxBackground","Input box background.")),k=g("input.foreground",{dark:p,light:p,hc:p},a.NC("vs/platform/theme/common/colorRegistry","inputBoxForeground","Input box foreground.")),L=g("input.border",{dark:null,light:null,hc:b},a.NC("vs/platform/theme/common/colorRegistry","inputBoxBorder","Input box border.")),E=g("inputOption.activeBorder",{dark:"#007ACC00",light:"#007ACC00",hc:b},a.NC("vs/platform/theme/common/colorRegistry","inputBoxActiveOptionBorder","Border color of activated options in input fields.")),N=(g("inputOption.hoverBackground",{dark:"#5a5d5e80",light:"#b8b8b850",hc:null},a.NC("vs/platform/theme/common/colorRegistry","inputOption.hoverBackground","Background color of activated options in input fields.")),g("inputOption.activeBackground",{dark:_i(_,.4),light:_i(_,.2),hc:o.Il.transparent},a.NC("vs/platform/theme/common/colorRegistry","inputOption.activeBackground","Background hover color of options in input fields."))),D=g("inputOption.activeForeground",{dark:o.Il.white,light:o.Il.black,hc:null},a.NC("vs/platform/theme/common/colorRegistry","inputOption.activeForeground","Foreground color of activated options in input fields.")),I=(g("input.placeholderForeground",{light:_i(p,.5),dark:_i(p,.5),hc:_i(p,.7)},a.NC("vs/platform/theme/common/colorRegistry","inputPlaceholderForeground","Input box foreground color for placeholder text.")),g("inputValidation.infoBackground",{dark:"#063B49",light:"#D6ECF2",hc:o.Il.black},a.NC("vs/platform/theme/common/colorRegistry","inputValidationInfoBackground","Input validation background color for information severity."))),T=g("inputValidation.infoForeground",{dark:null,light:null,hc:null},a.NC("vs/platform/theme/common/colorRegistry","inputValidationInfoForeground","Input validation foreground color for information severity.")),A=g("inputValidation.infoBorder",{dark:"#007acc",light:"#007acc",hc:b},a.NC("vs/platform/theme/common/colorRegistry","inputValidationInfoBorder","Input validation border color for information severity.")),R=g("inputValidation.warningBackground",{dark:"#352A05",light:"#F6F5D2",hc:o.Il.black},a.NC("vs/platform/theme/common/colorRegistry","inputValidationWarningBackground","Input validation background color for warning severity.")),M=g("inputValidation.warningForeground",{dark:null,light:null,hc:null},a.NC("vs/platform/theme/common/colorRegistry","inputValidationWarningForeground","Input validation foreground color for warning severity.")),O=g("inputValidation.warningBorder",{dark:"#B89500",light:"#B89500",hc:b},a.NC("vs/platform/theme/common/colorRegistry","inputValidationWarningBorder","Input validation border color for warning severity.")),P=g("inputValidation.errorBackground",{dark:"#5A1D1D",light:"#F2DEDE",hc:o.Il.black},a.NC("vs/platform/theme/common/colorRegistry","inputValidationErrorBackground","Input validation background color for error severity.")),F=g("inputValidation.errorForeground",{dark:null,light:null,hc:null},a.NC("vs/platform/theme/common/colorRegistry","inputValidationErrorForeground","Input validation foreground color for error severity.")),B=g("inputValidation.errorBorder",{dark:"#BE1100",light:"#BE1100",hc:b},a.NC("vs/platform/theme/common/colorRegistry","inputValidationErrorBorder","Input validation border color for error severity.")),W=g("dropdown.background",{dark:"#3C3C3C",light:o.Il.white,hc:o.Il.black},a.NC("vs/platform/theme/common/colorRegistry","dropdownBackground","Dropdown background.")),V=(g("dropdown.listBackground",{dark:null,light:null,hc:o.Il.black},a.NC("vs/platform/theme/common/colorRegistry","dropdownListBackground","Dropdown list background.")),g("dropdown.foreground",{dark:"#F0F0F0",light:null,hc:o.Il.white},a.NC("vs/platform/theme/common/colorRegistry","dropdownForeground","Dropdown foreground."))),H=g("dropdown.border",{dark:W,light:"#CECECE",hc:b},a.NC("vs/platform/theme/common/colorRegistry","dropdownBorder","Dropdown border.")),z=(g("checkbox.background",{dark:W,light:W,hc:W},a.NC("vs/platform/theme/common/colorRegistry","checkbox.background","Background color of checkbox widget.")),g("checkbox.foreground",{dark:V,light:V,hc:V},a.NC("vs/platform/theme/common/colorRegistry","checkbox.foreground","Foreground color of checkbox widget.")),g("checkbox.border",{dark:H,light:H,hc:H},a.NC("vs/platform/theme/common/colorRegistry","checkbox.border","Border color of checkbox widget.")),g("button.foreground",{dark:o.Il.white,light:o.Il.white,hc:o.Il.white},a.NC("vs/platform/theme/common/colorRegistry","buttonForeground","Button foreground color."))),$=g("button.background",{dark:"#0E639C",light:"#007ACC",hc:null},a.NC("vs/platform/theme/common/colorRegistry","buttonBackground","Button background color.")),U=g("button.hoverBackground",{dark:fi($,.2),light:mi($,.2),hc:null},a.NC("vs/platform/theme/common/colorRegistry","buttonHoverBackground","Button background color when hovering.")),j=(g("button.border",{dark:b,light:b,hc:b},a.NC("vs/platform/theme/common/colorRegistry","buttonBorder","Button border color.")),g("button.secondaryForeground",{dark:o.Il.white,light:o.Il.white,hc:o.Il.white},a.NC("vs/platform/theme/common/colorRegistry","buttonSecondaryForeground","Secondary button foreground color.")),g("button.secondaryBackground",{dark:"#3A3D41",light:"#5F6A79",hc:null},a.NC("vs/platform/theme/common/colorRegistry","buttonSecondaryBackground","Secondary button background color."))),K=(g("button.secondaryHoverBackground",{dark:fi(j,.2),light:mi(j,.2),hc:null},a.NC("vs/platform/theme/common/colorRegistry","buttonSecondaryHoverBackground","Secondary button background color when hovering.")),g("badge.background",{dark:"#4D4D4D",light:"#C4C4C4",hc:o.Il.black},a.NC("vs/platform/theme/common/colorRegistry","badgeBackground","Badge background color. Badges are small information labels, e.g. for search results count."))),q=g("badge.foreground",{dark:o.Il.white,light:"#333",hc:o.Il.white},a.NC("vs/platform/theme/common/colorRegistry","badgeForeground","Badge foreground color. Badges are small information labels, e.g. for search results count.")),G=g("scrollbar.shadow",{dark:"#000000",light:"#DDDDDD",hc:null},a.NC("vs/platform/theme/common/colorRegistry","scrollbarShadow","Scrollbar shadow to indicate that the view is scrolled.")),Z=g("scrollbarSlider.background",{dark:o.Il.fromHex("#797979").transparent(.4),light:o.Il.fromHex("#646464").transparent(.4),hc:_i(b,.6)},a.NC("vs/platform/theme/common/colorRegistry","scrollbarSliderBackground","Scrollbar slider background color.")),Y=g("scrollbarSlider.hoverBackground",{dark:o.Il.fromHex("#646464").transparent(.7),light:o.Il.fromHex("#646464").transparent(.7),hc:_i(b,.8)},a.NC("vs/platform/theme/common/colorRegistry","scrollbarSliderHoverBackground","Scrollbar slider background color when hovering.")),Q=g("scrollbarSlider.activeBackground",{dark:o.Il.fromHex("#BFBFBF").transparent(.4),light:o.Il.fromHex("#000000").transparent(.6),hc:b},a.NC("vs/platform/theme/common/colorRegistry","scrollbarSliderActiveBackground","Scrollbar slider background color when clicked on.")),X=g("progressBar.background",{dark:o.Il.fromHex("#0E70C0"),light:o.Il.fromHex("#0E70C0"),hc:b},a.NC("vs/platform/theme/common/colorRegistry","progressBarBackground","Background color of the progress bar that can show for long running operations.")),J=g("editorError.background",{dark:null,light:null,hc:null},a.NC("vs/platform/theme/common/colorRegistry","editorError.background","Background color of error text in the editor. The color must not be opaque so as not to hide underlying decorations."),!0),ee=g("editorError.foreground",{dark:"#F14C4C",light:"#E51400",hc:null},a.NC("vs/platform/theme/common/colorRegistry","editorError.foreground","Foreground color of error squigglies in the editor.")),te=g("editorError.border",{dark:null,light:null,hc:o.Il.fromHex("#E47777").transparent(.8)},a.NC("vs/platform/theme/common/colorRegistry","errorBorder","Border color of error boxes in the editor.")),ie=g("editorWarning.background",{dark:null,light:null,hc:null},a.NC("vs/platform/theme/common/colorRegistry","editorWarning.background","Background color of warning text in the editor. The color must not be opaque so as not to hide underlying decorations."),!0),ne=g("editorWarning.foreground",{dark:"#CCA700",light:"#BF8803",hc:null},a.NC("vs/platform/theme/common/colorRegistry","editorWarning.foreground","Foreground color of warning squigglies in the editor.")),oe=g("editorWarning.border",{dark:null,light:null,hc:o.Il.fromHex("#FFCC00").transparent(.8)},a.NC("vs/platform/theme/common/colorRegistry","warningBorder","Border color of warning boxes in the editor.")),re=g("editorInfo.background",{dark:null,light:null,hc:null},a.NC("vs/platform/theme/common/colorRegistry","editorInfo.background","Background color of info text in the editor. The color must not be opaque so as not to hide underlying decorations."),!0),se=g("editorInfo.foreground",{dark:"#3794FF",light:"#1a85ff",hc:"#3794FF"},a.NC("vs/platform/theme/common/colorRegistry","editorInfo.foreground","Foreground color of info squigglies in the editor.")),ae=g("editorInfo.border",{dark:null,light:null,hc:o.Il.fromHex("#3794FF").transparent(.8)},a.NC("vs/platform/theme/common/colorRegistry","infoBorder","Border color of info boxes in the editor.")),le=g("editorHint.foreground",{dark:o.Il.fromHex("#eeeeee").transparent(.7),light:"#6c6c6c",hc:null},a.NC("vs/platform/theme/common/colorRegistry","editorHint.foreground","Foreground color of hint squigglies in the editor.")),ce=g("editorHint.border",{dark:null,light:null,hc:o.Il.fromHex("#eeeeee").transparent(.8)},a.NC("vs/platform/theme/common/colorRegistry","hintBorder","Border color of hint boxes in the editor.")),de=(g("sash.hoverBorder",{dark:_,light:_,hc:_},a.NC("vs/platform/theme/common/colorRegistry","sashActiveBorder","Border color of active sashes.")),g("editor.background",{light:"#fffffe",dark:"#1E1E1E",hc:o.Il.black},a.NC("vs/platform/theme/common/colorRegistry","editorBackground","Editor background color."))),ue=g("editor.foreground",{light:"#333333",dark:"#BBBBBB",hc:o.Il.white},a.NC("vs/platform/theme/common/colorRegistry","editorForeground","Editor default foreground color.")),he=g("editorWidget.background",{dark:"#252526",light:"#F3F3F3",hc:"#0C141F"},a.NC("vs/platform/theme/common/colorRegistry","editorWidgetBackground","Background color of editor widgets, such as find/replace.")),ge=g("editorWidget.foreground",{dark:p,light:p,hc:p},a.NC("vs/platform/theme/common/colorRegistry","editorWidgetForeground","Foreground color of editor widgets, such as find/replace.")),pe=g("editorWidget.border",{dark:"#454545",light:"#C8C8C8",hc:b},a.NC("vs/platform/theme/common/colorRegistry","editorWidgetBorder","Border color of editor widgets. The color is only used if the widget chooses to have a border and if the color is not overridden by a widget.")),me=g("editorWidget.resizeBorder",{light:null,dark:null,hc:null},a.NC("vs/platform/theme/common/colorRegistry","editorWidgetResizeBorder","Border color of the resize bar of editor widgets. The color is only used if the widget chooses to have a resize border and if the color is not overridden by a widget.")),fe=g("quickInput.background",{dark:he,light:he,hc:he},a.NC("vs/platform/theme/common/colorRegistry","pickerBackground","Quick picker background color. The quick picker widget is the container for pickers like the command palette.")),_e=g("quickInput.foreground",{dark:ge,light:ge,hc:ge},a.NC("vs/platform/theme/common/colorRegistry","pickerForeground","Quick picker foreground color. The quick picker widget is the container for pickers like the command palette.")),be=g("quickInputTitle.background",{dark:new o.Il(new o.VS(255,255,255,.105)),light:new o.Il(new o.VS(0,0,0,.06)),hc:"#000000"},a.NC("vs/platform/theme/common/colorRegistry","pickerTitleBackground","Quick picker title background color. The quick picker widget is the container for pickers like the command palette.")),ve=g("pickerGroup.foreground",{dark:"#3794FF",light:"#0066BF",hc:o.Il.white},a.NC("vs/platform/theme/common/colorRegistry","pickerGroupForeground","Quick picker color for grouping labels.")),Ce=g("pickerGroup.border",{dark:"#3F3F46",light:"#CCCEDB",hc:o.Il.white},a.NC("vs/platform/theme/common/colorRegistry","pickerGroupBorder","Quick picker color for grouping borders.")),we=g("keybindingLabel.background",{dark:new o.Il(new o.VS(128,128,128,.17)),light:new o.Il(new o.VS(221,221,221,.4)),hc:o.Il.transparent},a.NC("vs/platform/theme/common/colorRegistry","keybindingLabelBackground","Keybinding label background color. The keybinding label is used to represent a keyboard shortcut.")),ye=g("keybindingLabel.foreground",{dark:o.Il.fromHex("#CCCCCC"),light:o.Il.fromHex("#555555"),hc:o.Il.white},a.NC("vs/platform/theme/common/colorRegistry","keybindingLabelForeground","Keybinding label foreground color. The keybinding label is used to represent a keyboard shortcut.")),Se=g("keybindingLabel.border",{dark:new o.Il(new o.VS(51,51,51,.6)),light:new o.Il(new o.VS(204,204,204,.4)),hc:new o.Il(new o.VS(111,195,223))},a.NC("vs/platform/theme/common/colorRegistry","keybindingLabelBorder","Keybinding label border color. The keybinding label is used to represent a keyboard shortcut.")),xe=g("keybindingLabel.bottomBorder",{dark:new o.Il(new o.VS(68,68,68,.6)),light:new o.Il(new o.VS(187,187,187,.4)),hc:new o.Il(new o.VS(111,195,223))},a.NC("vs/platform/theme/common/colorRegistry","keybindingLabelBottomBorder","Keybinding label border bottom color. The keybinding label is used to represent a keyboard shortcut.")),ke=g("editor.selectionBackground",{light:"#ADD6FF",dark:"#264F78",hc:"#f3f518"},a.NC("vs/platform/theme/common/colorRegistry","editorSelectionBackground","Color of the editor selection.")),Le=g("editor.selectionForeground",{light:null,dark:null,hc:"#000000"},a.NC("vs/platform/theme/common/colorRegistry","editorSelectionForeground","Color of the selected text for high contrast.")),Ee=g("editor.inactiveSelectionBackground",{light:_i(ke,.5),dark:_i(ke,.5),hc:_i(ke,.5)},a.NC("vs/platform/theme/common/colorRegistry","editorInactiveSelection","Color of the selection in an inactive editor. The color must not be opaque so as not to hide underlying decorations."),!0),Ne=g("editor.selectionHighlightBackground",{light:vi(ke,de,.3,.6),dark:vi(ke,de,.3,.6),hc:null},a.NC("vs/platform/theme/common/colorRegistry","editorSelectionHighlight","Color for regions with the same content as the selection. The color must not be opaque so as not to hide underlying decorations."),!0),De=g("editor.selectionHighlightBorder",{light:null,dark:null,hc:v},a.NC("vs/platform/theme/common/colorRegistry","editorSelectionHighlightBorder","Border color for regions with the same content as the selection.")),Ie=g("editor.findMatchBackground",{light:"#A8AC94",dark:"#515C6A",hc:null},a.NC("vs/platform/theme/common/colorRegistry","editorFindMatch","Color of the current search match.")),Te=g("editor.findMatchHighlightBackground",{light:"#EA5C0055",dark:"#EA5C0055",hc:null},a.NC("vs/platform/theme/common/colorRegistry","findMatchHighlight","Color of the other search matches. The color must not be opaque so as not to hide underlying decorations."),!0),Ae=g("editor.findRangeHighlightBackground",{dark:"#3a3d4166",light:"#b4b4b44d",hc:null},a.NC("vs/platform/theme/common/colorRegistry","findRangeHighlight","Color of the range limiting the search. The color must not be opaque so as not to hide underlying decorations."),!0),Re=g("editor.findMatchBorder",{light:null,dark:null,hc:v},a.NC("vs/platform/theme/common/colorRegistry","editorFindMatchBorder","Border color of the current search match.")),Me=g("editor.findMatchHighlightBorder",{light:null,dark:null,hc:v},a.NC("vs/platform/theme/common/colorRegistry","findMatchHighlightBorder","Border color of the other search matches.")),Oe=g("editor.findRangeHighlightBorder",{dark:null,light:null,hc:_i(v,.4)},a.NC("vs/platform/theme/common/colorRegistry","findRangeHighlightBorder","Border color of the range limiting the search. The color must not be opaque so as not to hide underlying decorations."),!0),Pe=(g("searchEditor.findMatchBackground",{light:_i(Te,.66),dark:_i(Te,.66),hc:Te},a.NC("vs/platform/theme/common/colorRegistry","searchEditor.queryMatch","Color of the Search Editor query matches.")),g("searchEditor.findMatchBorder",{light:_i(Me,.66),dark:_i(Me,.66),hc:Me},a.NC("vs/platform/theme/common/colorRegistry","searchEditor.editorFindMatchBorder","Border color of the Search Editor query matches.")),g("editor.hoverHighlightBackground",{light:"#ADD6FF26",dark:"#264f7840",hc:"#ADD6FF26"},a.NC("vs/platform/theme/common/colorRegistry","hoverHighlight","Highlight below the word for which a hover is shown. The color must not be opaque so as not to hide underlying decorations."),!0)),Fe=g("editorHoverWidget.background",{light:he,dark:he,hc:he},a.NC("vs/platform/theme/common/colorRegistry","hoverBackground","Background color of the editor hover.")),Be=g("editorHoverWidget.foreground",{light:ge,dark:ge,hc:ge},a.NC("vs/platform/theme/common/colorRegistry","hoverForeground","Foreground color of the editor hover.")),We=g("editorHoverWidget.border",{light:pe,dark:pe,hc:pe},a.NC("vs/platform/theme/common/colorRegistry","hoverBorder","Border color of the editor hover.")),Ve=g("editorHoverWidget.statusBarBackground",{dark:fi(Fe,.2),light:mi(Fe,.05),hc:he},a.NC("vs/platform/theme/common/colorRegistry","statusBarBackground","Background color of the editor hover status bar.")),He=g("editorLink.activeForeground",{dark:"#4E94CE",light:o.Il.blue,hc:o.Il.cyan},a.NC("vs/platform/theme/common/colorRegistry","activeLinkForeground","Color of active links.")),ze=g("editorInlayHint.foreground",{dark:_i(q,.8),light:_i(q,.8),hc:q},a.NC("vs/platform/theme/common/colorRegistry","editorInlayHintForeground","Foreground color of inline hints")),$e=g("editorInlayHint.background",{dark:_i(K,.6),light:_i(K,.3),hc:K},a.NC("vs/platform/theme/common/colorRegistry","editorInlayHintBackground","Background color of inline hints")),Ue=g("editorInlayHint.typeForeground",{dark:ze,light:ze,hc:ze},a.NC("vs/platform/theme/common/colorRegistry","editorInlayHintForegroundTypes","Foreground color of inline hints for types")),je=g("editorInlayHint.typeBackground",{dark:$e,light:$e,hc:$e},a.NC("vs/platform/theme/common/colorRegistry","editorInlayHintBackgroundTypes","Background color of inline hints for types")),Ke=g("editorInlayHint.parameterForeground",{dark:ze,light:ze,hc:ze},a.NC("vs/platform/theme/common/colorRegistry","editorInlayHintForegroundParameter","Foreground color of inline hints for parameters")),qe=g("editorInlayHint.parameterBackground",{dark:$e,light:$e,hc:$e},a.NC("vs/platform/theme/common/colorRegistry","editorInlayHintBackgroundParameter","Background color of inline hints for parameters")),Ge=g("editorLightBulb.foreground",{dark:"#FFCC00",light:"#DDB100",hc:"#FFCC00"},a.NC("vs/platform/theme/common/colorRegistry","editorLightBulbForeground","The color used for the lightbulb actions icon.")),Ze=g("editorLightBulbAutoFix.foreground",{dark:"#75BEFF",light:"#007ACC",hc:"#75BEFF"},a.NC("vs/platform/theme/common/colorRegistry","editorLightBulbAutoFixForeground","The color used for the lightbulb auto fix actions icon.")),Ye=new o.Il(new o.VS(155,185,85,.2)),Qe=new o.Il(new o.VS(255,0,0,.2)),Xe=g("diffEditor.insertedTextBackground",{dark:Ye,light:Ye,hc:null},a.NC("vs/platform/theme/common/colorRegistry","diffEditorInserted","Background color for text that got inserted. The color must not be opaque so as not to hide underlying decorations."),!0),Je=g("diffEditor.removedTextBackground",{dark:Qe,light:Qe,hc:null},a.NC("vs/platform/theme/common/colorRegistry","diffEditorRemoved","Background color for text that got removed. The color must not be opaque so as not to hide underlying decorations."),!0),et=g("diffEditor.insertedLineBackground",{dark:null,light:null,hc:null},a.NC("vs/platform/theme/common/colorRegistry","diffEditorInsertedLines","Background color for lines that got inserted. The color must not be opaque so as not to hide underlying decorations."),!0),tt=g("diffEditor.removedLineBackground",{dark:null,light:null,hc:null},a.NC("vs/platform/theme/common/colorRegistry","diffEditorRemovedLines","Background color for lines that got removed. The color must not be opaque so as not to hide underlying decorations."),!0),it=g("diffEditorGutter.insertedLineBackground",{dark:null,light:null,hc:null},a.NC("vs/platform/theme/common/colorRegistry","diffEditorInsertedLineGutter","Background color for the margin where lines got inserted.")),nt=g("diffEditorGutter.removedLineBackground",{dark:null,light:null,hc:null},a.NC("vs/platform/theme/common/colorRegistry","diffEditorRemovedLineGutter","Background color for the margin where lines got removed.")),ot=g("diffEditorOverview.insertedForeground",{dark:null,light:null,hc:null},a.NC("vs/platform/theme/common/colorRegistry","diffEditorOverviewInserted","Diff overview ruler foreground for inserted content.")),rt=g("diffEditorOverview.removedForeground",{dark:null,light:null,hc:null},a.NC("vs/platform/theme/common/colorRegistry","diffEditorOverviewRemoved","Diff overview ruler foreground for removed content.")),st=g("diffEditor.insertedTextBorder",{dark:null,light:null,hc:"#33ff2eff"},a.NC("vs/platform/theme/common/colorRegistry","diffEditorInsertedOutline","Outline color for the text that got inserted.")),at=g("diffEditor.removedTextBorder",{dark:null,light:null,hc:"#FF008F"},a.NC("vs/platform/theme/common/colorRegistry","diffEditorRemovedOutline","Outline color for text that got removed.")),lt=g("diffEditor.border",{dark:null,light:null,hc:b},a.NC("vs/platform/theme/common/colorRegistry","diffEditorBorder","Border color between the two text editors.")),ct=g("diffEditor.diagonalFill",{dark:"#cccccc33",light:"#22222233",hc:null},a.NC("vs/platform/theme/common/colorRegistry","diffDiagonalFill","Color of the diff editor's diagonal fill. The diagonal fill is used in side-by-side diff views.")),dt=g("list.focusBackground",{dark:null,light:null,hc:null},a.NC("vs/platform/theme/common/colorRegistry","listFocusBackground","List/Tree background color for the focused item when the list/tree is active. An active list/tree has keyboard focus, an inactive does not.")),ut=g("list.focusForeground",{dark:null,light:null,hc:null},a.NC("vs/platform/theme/common/colorRegistry","listFocusForeground","List/Tree foreground color for the focused item when the list/tree is active. An active list/tree has keyboard focus, an inactive does not.")),ht=g("list.focusOutline",{dark:_,light:_,hc:v},a.NC("vs/platform/theme/common/colorRegistry","listFocusOutline","List/Tree outline color for the focused item when the list/tree is active. An active list/tree has keyboard focus, an inactive does not.")),gt=g("list.activeSelectionBackground",{dark:"#094771",light:"#0060C0",hc:null},a.NC("vs/platform/theme/common/colorRegistry","listActiveSelectionBackground","List/Tree background color for the selected item when the list/tree is active. An active list/tree has keyboard focus, an inactive does not.")),pt=g("list.activeSelectionForeground",{dark:o.Il.white,light:o.Il.white,hc:null},a.NC("vs/platform/theme/common/colorRegistry","listActiveSelectionForeground","List/Tree foreground color for the selected item when the list/tree is active. An active list/tree has keyboard focus, an inactive does not.")),mt=g("list.activeSelectionIconForeground",{dark:null,light:null,hc:null},a.NC("vs/platform/theme/common/colorRegistry","listActiveSelectionIconForeground","List/Tree icon foreground color for the selected item when the list/tree is active. An active list/tree has keyboard focus, an inactive does not.")),ft=g("list.inactiveSelectionBackground",{dark:"#37373D",light:"#E4E6F1",hc:null},a.NC("vs/platform/theme/common/colorRegistry","listInactiveSelectionBackground","List/Tree background color for the selected item when the list/tree is inactive. An active list/tree has keyboard focus, an inactive does not.")),_t=g("list.inactiveSelectionForeground",{dark:null,light:null,hc:null},a.NC("vs/platform/theme/common/colorRegistry","listInactiveSelectionForeground","List/Tree foreground color for the selected item when the list/tree is inactive. An active list/tree has keyboard focus, an inactive does not.")),bt=g("list.inactiveSelectionIconForeground",{dark:null,light:null,hc:null},a.NC("vs/platform/theme/common/colorRegistry","listInactiveSelectionIconForeground","List/Tree icon foreground color for the selected item when the list/tree is inactive. An active list/tree has keyboard focus, an inactive does not.")),vt=g("list.inactiveFocusBackground",{dark:null,light:null,hc:null},a.NC("vs/platform/theme/common/colorRegistry","listInactiveFocusBackground","List/Tree background color for the focused item when the list/tree is inactive. An active list/tree has keyboard focus, an inactive does not.")),Ct=g("list.inactiveFocusOutline",{dark:null,light:null,hc:null},a.NC("vs/platform/theme/common/colorRegistry","listInactiveFocusOutline","List/Tree outline color for the focused item when the list/tree is inactive. An active list/tree has keyboard focus, an inactive does not.")),wt=g("list.hoverBackground",{dark:"#2A2D2E",light:"#F0F0F0",hc:null},a.NC("vs/platform/theme/common/colorRegistry","listHoverBackground","List/Tree background when hovering over items using the mouse.")),yt=g("list.hoverForeground",{dark:null,light:null,hc:null},a.NC("vs/platform/theme/common/colorRegistry","listHoverForeground","List/Tree foreground when hovering over items using the mouse.")),St=g("list.dropBackground",{dark:"#062F4A",light:"#D6EBFF",hc:null},a.NC("vs/platform/theme/common/colorRegistry","listDropBackground","List/Tree drag and drop background when moving items around using the mouse.")),xt=g("list.highlightForeground",{dark:"#18A3FF",light:"#0066BF",hc:_},a.NC("vs/platform/theme/common/colorRegistry","highlight","List/Tree foreground color of the match highlights when searching inside the list/tree.")),kt=g("list.focusHighlightForeground",{dark:xt,light:(Lt=gt,Et=xt,"#9DDDFF",{op:5,if:Lt,then:Et,else:"#9DDDFF"}),hc:xt},a.NC("vs/platform/theme/common/colorRegistry","listFocusHighlightForeground","List/Tree foreground color of the match highlights on actively focused items when searching inside the list/tree."));var Lt,Et;g("list.invalidItemForeground",{dark:"#B89500",light:"#B89500",hc:"#B89500"},a.NC("vs/platform/theme/common/colorRegistry","invalidItemForeground","List/Tree foreground color for invalid items, for example an unresolved root in explorer.")),g("list.errorForeground",{dark:"#F88070",light:"#B01011",hc:null},a.NC("vs/platform/theme/common/colorRegistry","listErrorForeground","Foreground color of list items containing errors.")),g("list.warningForeground",{dark:"#CCA700",light:"#855F00",hc:null},a.NC("vs/platform/theme/common/colorRegistry","listWarningForeground","Foreground color of list items containing warnings."));const Nt=g("listFilterWidget.background",{light:"#efc1ad",dark:"#653723",hc:o.Il.black},a.NC("vs/platform/theme/common/colorRegistry","listFilterWidgetBackground","Background color of the type filter widget in lists and trees.")),Dt=g("listFilterWidget.outline",{dark:o.Il.transparent,light:o.Il.transparent,hc:"#f38518"},a.NC("vs/platform/theme/common/colorRegistry","listFilterWidgetOutline","Outline color of the type filter widget in lists and trees.")),It=g("listFilterWidget.noMatchesOutline",{dark:"#BE1100",light:"#BE1100",hc:b},a.NC("vs/platform/theme/common/colorRegistry","listFilterWidgetNoMatchesOutline","Outline color of the type filter widget in lists and trees, when there are no matches.")),Tt=(g("list.filterMatchBackground",{dark:Te,light:Te,hc:null},a.NC("vs/platform/theme/common/colorRegistry","listFilterMatchHighlight","Background color of the filtered match.")),g("list.filterMatchBorder",{dark:Me,light:Me,hc:b},a.NC("vs/platform/theme/common/colorRegistry","listFilterMatchHighlightBorder","Border color of the filtered match.")),g("tree.indentGuidesStroke",{dark:"#585858",light:"#a9a9a9",hc:"#a9a9a9"},a.NC("vs/platform/theme/common/colorRegistry","treeIndentGuidesStroke","Tree stroke color for the indentation guides."))),At=g("tree.tableColumnsBorder",{dark:"#CCCCCC20",light:"#61616120",hc:null},a.NC("vs/platform/theme/common/colorRegistry","tableColumnsBorder","Table border color between columns.")),Rt=g("tree.tableOddRowsBackground",{dark:_i(p,.04),light:_i(p,.04),hc:null},a.NC("vs/platform/theme/common/colorRegistry","tableOddRowsBackgroundColor","Background color for odd table rows.")),Mt=(g("list.deemphasizedForeground",{dark:"#8C8C8C",light:"#8E8E90",hc:"#A7A8A9"},a.NC("vs/platform/theme/common/colorRegistry","listDeemphasizedForeground","List/Tree foreground color for items that are deemphasized. ")),g("quickInput.list.focusBackground",{dark:null,light:null,hc:null},"",void 0,a.NC("vs/platform/theme/common/colorRegistry","quickInput.list.focusBackground deprecation","Please use quickInputList.focusBackground instead"))),Ot=g("quickInputList.focusForeground",{dark:pt,light:pt,hc:pt},a.NC("vs/platform/theme/common/colorRegistry","quickInput.listFocusForeground","Quick picker foreground color for the focused item.")),Pt=g("quickInputList.focusIconForeground",{dark:mt,light:mt,hc:mt},a.NC("vs/platform/theme/common/colorRegistry","quickInput.listFocusIconForeground","Quick picker icon foreground color for the focused item.")),Ft=g("quickInputList.focusBackground",{dark:bi(Mt,gt),light:bi(Mt,gt),hc:null},a.NC("vs/platform/theme/common/colorRegistry","quickInput.listFocusBackground","Quick picker background color for the focused item.")),Bt=g("menu.border",{dark:null,light:null,hc:b},a.NC("vs/platform/theme/common/colorRegistry","menuBorder","Border color of menus.")),Wt=g("menu.foreground",{dark:V,light:p,hc:V},a.NC("vs/platform/theme/common/colorRegistry","menuForeground","Foreground color of menu items.")),Vt=g("menu.background",{dark:W,light:W,hc:W},a.NC("vs/platform/theme/common/colorRegistry","menuBackground","Background color of menu items.")),Ht=g("menu.selectionForeground",{dark:pt,light:pt,hc:pt},a.NC("vs/platform/theme/common/colorRegistry","menuSelectionForeground","Foreground color of the selected menu item in menus.")),zt=g("menu.selectionBackground",{dark:gt,light:gt,hc:gt},a.NC("vs/platform/theme/common/colorRegistry","menuSelectionBackground","Background color of the selected menu item in menus.")),$t=g("menu.selectionBorder",{dark:null,light:null,hc:v},a.NC("vs/platform/theme/common/colorRegistry","menuSelectionBorder","Border color of the selected menu item in menus.")),Ut=g("menu.separatorBackground",{dark:"#BBBBBB",light:"#888888",hc:b},a.NC("vs/platform/theme/common/colorRegistry","menuSeparatorBackground","Color of a separator menu item in menus.")),jt=g("toolbar.hoverBackground",{dark:"#5a5d5e50",light:"#b8b8b850",hc:null},a.NC("vs/platform/theme/common/colorRegistry","toolbarHoverBackground","Toolbar background when hovering over actions using the mouse")),Kt=(g("toolbar.hoverOutline",{dark:null,light:null,hc:v},a.NC("vs/platform/theme/common/colorRegistry","toolbarHoverOutline","Toolbar outline when hovering over actions using the mouse")),g("toolbar.activeBackground",{dark:fi(jt,.1),light:mi(jt,.1),hc:null},a.NC("vs/platform/theme/common/colorRegistry","toolbarActiveBackground","Toolbar background when holding the mouse over actions")),g("editor.snippetTabstopHighlightBackground",{dark:new o.Il(new o.VS(124,124,124,.3)),light:new o.Il(new o.VS(10,50,100,.2)),hc:new o.Il(new o.VS(124,124,124,.3))},a.NC("vs/platform/theme/common/colorRegistry","snippetTabstopHighlightBackground","Highlight background color of a snippet tabstop.")),g("editor.snippetTabstopHighlightBorder",{dark:null,light:null,hc:null},a.NC("vs/platform/theme/common/colorRegistry","snippetTabstopHighlightBorder","Highlight border color of a snippet tabstop.")),g("editor.snippetFinalTabstopHighlightBackground",{dark:null,light:null,hc:null},a.NC("vs/platform/theme/common/colorRegistry","snippetFinalTabstopHighlightBackground","Highlight background color of the final tabstop of a snippet.")),g("editor.snippetFinalTabstopHighlightBorder",{dark:"#525252",light:new o.Il(new o.VS(10,50,100,.5)),hc:"#525252"},a.NC("vs/platform/theme/common/colorRegistry","snippetFinalTabstopHighlightBorder","Highlight border color of the final tabstop of a snippet.")),g("breadcrumb.foreground",{light:_i(p,.8),dark:_i(p,.8),hc:_i(p,.8)},a.NC("vs/platform/theme/common/colorRegistry","breadcrumbsFocusForeground","Color of focused breadcrumb items.")),g("breadcrumb.background",{light:de,dark:de,hc:de},a.NC("vs/platform/theme/common/colorRegistry","breadcrumbsBackground","Background color of breadcrumb items.")),g("breadcrumb.focusForeground",{light:mi(p,.2),dark:fi(p,.1),hc:fi(p,.1)},a.NC("vs/platform/theme/common/colorRegistry","breadcrumbsFocusForeground","Color of focused breadcrumb items.")),g("breadcrumb.activeSelectionForeground",{light:mi(p,.2),dark:fi(p,.1),hc:fi(p,.1)},a.NC("vs/platform/theme/common/colorRegistry","breadcrumbsSelectedForegound","Color of selected breadcrumb items.")),g("breadcrumbPicker.background",{light:he,dark:he,hc:he},a.NC("vs/platform/theme/common/colorRegistry","breadcrumbsSelectedBackground","Background color of breadcrumb item picker.")),o.Il.fromHex("#40C8AE").transparent(.5)),qt=o.Il.fromHex("#40A6FF").transparent(.5),Gt=o.Il.fromHex("#606060").transparent(.4),Zt=.4,Yt=g("merge.currentHeaderBackground",{dark:Kt,light:Kt,hc:null},a.NC("vs/platform/theme/common/colorRegistry","mergeCurrentHeaderBackground","Current header background in inline merge-conflicts. The color must not be opaque so as not to hide underlying decorations."),!0),Qt=(g("merge.currentContentBackground",{dark:_i(Yt,Zt),light:_i(Yt,Zt),hc:_i(Yt,Zt)},a.NC("vs/platform/theme/common/colorRegistry","mergeCurrentContentBackground","Current content background in inline merge-conflicts. The color must not be opaque so as not to hide underlying decorations."),!0),g("merge.incomingHeaderBackground",{dark:qt,light:qt,hc:null},a.NC("vs/platform/theme/common/colorRegistry","mergeIncomingHeaderBackground","Incoming header background in inline merge-conflicts. The color must not be opaque so as not to hide underlying decorations."),!0)),Xt=(g("merge.incomingContentBackground",{dark:_i(Qt,Zt),light:_i(Qt,Zt),hc:_i(Qt,Zt)},a.NC("vs/platform/theme/common/colorRegistry","mergeIncomingContentBackground","Incoming content background in inline merge-conflicts. The color must not be opaque so as not to hide underlying decorations."),!0),g("merge.commonHeaderBackground",{dark:Gt,light:Gt,hc:null},a.NC("vs/platform/theme/common/colorRegistry","mergeCommonHeaderBackground","Common ancestor header background in inline merge-conflicts. The color must not be opaque so as not to hide underlying decorations."),!0)),Jt=(g("merge.commonContentBackground",{dark:_i(Xt,Zt),light:_i(Xt,Zt),hc:_i(Xt,Zt)},a.NC("vs/platform/theme/common/colorRegistry","mergeCommonContentBackground","Common ancestor content background in inline merge-conflicts. The color must not be opaque so as not to hide underlying decorations."),!0),g("merge.border",{dark:null,light:null,hc:"#C3DF6F"},a.NC("vs/platform/theme/common/colorRegistry","mergeBorder","Border color on headers and the splitter in inline merge-conflicts."))),ei=(g("editorOverviewRuler.currentContentForeground",{dark:_i(Yt,1),light:_i(Yt,1),hc:Jt},a.NC("vs/platform/theme/common/colorRegistry","overviewRulerCurrentContentForeground","Current overview ruler foreground for inline merge-conflicts.")),g("editorOverviewRuler.incomingContentForeground",{dark:_i(Qt,1),light:_i(Qt,1),hc:Jt},a.NC("vs/platform/theme/common/colorRegistry","overviewRulerIncomingContentForeground","Incoming overview ruler foreground for inline merge-conflicts.")),g("editorOverviewRuler.commonContentForeground",{dark:_i(Xt,1),light:_i(Xt,1),hc:Jt},a.NC("vs/platform/theme/common/colorRegistry","overviewRulerCommonContentForeground","Common ancestor overview ruler foreground for inline merge-conflicts.")),g("editorOverviewRuler.findMatchForeground",{dark:"#d186167e",light:"#d186167e",hc:"#AB5A00"},a.NC("vs/platform/theme/common/colorRegistry","overviewRulerFindMatchForeground","Overview ruler marker color for find matches. The color must not be opaque so as not to hide underlying decorations."),!0)),ti=g("editorOverviewRuler.selectionHighlightForeground",{dark:"#A0A0A0CC",light:"#A0A0A0CC",hc:"#A0A0A0CC"},a.NC("vs/platform/theme/common/colorRegistry","overviewRulerSelectionHighlightForeground","Overview ruler marker color for selection highlights. The color must not be opaque so as not to hide underlying decorations."),!0),ii=g("minimap.findMatchHighlight",{light:"#d18616",dark:"#d18616",hc:"#AB5A00"},a.NC("vs/platform/theme/common/colorRegistry","minimapFindMatchHighlight","Minimap marker color for find matches."),!0),ni=g("minimap.selectionOccurrenceHighlight",{light:"#c9c9c9",dark:"#676767",hc:"#ffffff"},a.NC("vs/platform/theme/common/colorRegistry","minimapSelectionOccurrenceHighlight","Minimap marker color for repeating editor selections."),!0),oi=g("minimap.selectionHighlight",{light:"#ADD6FF",dark:"#264F78",hc:"#ffffff"},a.NC("vs/platform/theme/common/colorRegistry","minimapSelectionHighlight","Minimap marker color for the editor selection."),!0),ri=g("minimap.errorHighlight",{dark:new o.Il(new o.VS(255,18,18,.7)),light:new o.Il(new o.VS(255,18,18,.7)),hc:new o.Il(new o.VS(255,50,50,1))},a.NC("vs/platform/theme/common/colorRegistry","minimapError","Minimap marker color for errors.")),si=g("minimap.warningHighlight",{dark:ne,light:ne,hc:oe},a.NC("vs/platform/theme/common/colorRegistry","overviewRuleWarning","Minimap marker color for warnings.")),ai=g("minimap.background",{dark:null,light:null,hc:null},a.NC("vs/platform/theme/common/colorRegistry","minimapBackground","Minimap background color.")),li=g("minimap.foregroundOpacity",{dark:o.Il.fromHex("#000f"),light:o.Il.fromHex("#000f"),hc:o.Il.fromHex("#000f")},a.NC("vs/platform/theme/common/colorRegistry","minimapForegroundOpacity",'Opacity of foreground elements rendered in the minimap. For example, "#000000c0" will render the elements with 75% opacity.')),ci=g("minimapSlider.background",{light:_i(Z,.5),dark:_i(Z,.5),hc:_i(Z,.5)},a.NC("vs/platform/theme/common/colorRegistry","minimapSliderBackground","Minimap slider background color.")),di=g("minimapSlider.hoverBackground",{light:_i(Y,.5),dark:_i(Y,.5),hc:_i(Y,.5)},a.NC("vs/platform/theme/common/colorRegistry","minimapSliderHoverBackground","Minimap slider background color when hovering.")),ui=g("minimapSlider.activeBackground",{light:_i(Q,.5),dark:_i(Q,.5),hc:_i(Q,.5)},a.NC("vs/platform/theme/common/colorRegistry","minimapSliderActiveBackground","Minimap slider background color when clicked on.")),hi=g("problemsErrorIcon.foreground",{dark:ee,light:ee,hc:ee},a.NC("vs/platform/theme/common/colorRegistry","problemsErrorIconForeground","The color used for the problems error icon.")),gi=g("problemsWarningIcon.foreground",{dark:ne,light:ne,hc:ne},a.NC("vs/platform/theme/common/colorRegistry","problemsWarningIconForeground","The color used for the problems warning icon.")),pi=g("problemsInfoIcon.foreground",{dark:se,light:se,hc:se},a.NC("vs/platform/theme/common/colorRegistry","problemsInfoIconForeground","The color used for the problems info icon."));function mi(e,t){return{op:0,value:e,factor:t}}function fi(e,t){return{op:1,value:e,factor:t}}function _i(e,t){return{op:2,value:e,factor:t}}function bi(...e){return{op:3,values:e}}function vi(e,t,i,n){return{op:4,value:e,background:t,factor:i,transparency:n}}function Ci(e,t){if(null!==e)return"string"==typeof e?"#"===e[0]?o.Il.fromHex(e):t.getColor(e):e instanceof o.Il?e:"object"==typeof e?function(e,t){var i,n,r;switch(e.op){case 0:return null===(i=Ci(e.value,t))||void 0===i?void 0:i.darken(e.factor);case 1:return null===(n=Ci(e.value,t))||void 0===n?void 0:n.lighten(e.factor);case 2:return null===(r=Ci(e.value,t))||void 0===r?void 0:r.transparent(e.factor);case 3:for(const i of e.values){const e=Ci(i,t);if(e)return e}return;case 5:return Ci(t.defines(e.if)?e.then:e.else,t);case 4:{const i=Ci(e.value,t);if(!i)return;const n=Ci(e.background,t);return n?i.isDarkerThan(n)?o.Il.getLighterColor(i,n,e.factor).transparent(e.transparency):o.Il.getDarkerColor(i,n,e.factor).transparent(e.transparency):i.transparent(e.factor*e.transparency)}default:throw(0,s.vE)(e)}}(e,t):void 0}g("charts.foreground",{dark:p,light:p,hc:p},a.NC("vs/platform/theme/common/colorRegistry","chartsForeground","The foreground color used in charts.")),g("charts.lines",{dark:_i(p,.5),light:_i(p,.5),hc:_i(p,.5)},a.NC("vs/platform/theme/common/colorRegistry","chartsLines","The color used for horizontal lines in charts.")),g("charts.red",{dark:ee,light:ee,hc:ee},a.NC("vs/platform/theme/common/colorRegistry","chartsRed","The red color used in chart visualizations.")),g("charts.blue",{dark:se,light:se,hc:se},a.NC("vs/platform/theme/common/colorRegistry","chartsBlue","The blue color used in chart visualizations.")),g("charts.yellow",{dark:ne,light:ne,hc:ne},a.NC("vs/platform/theme/common/colorRegistry","chartsYellow","The yellow color used in chart visualizations.")),g("charts.orange",{dark:ii,light:ii,hc:ii},a.NC("vs/platform/theme/common/colorRegistry","chartsOrange","The orange color used in chart visualizations.")),g("charts.green",{dark:"#89D185",light:"#388A34",hc:"#89D185"},a.NC("vs/platform/theme/common/colorRegistry","chartsGreen","The green color used in chart visualizations.")),g("charts.purple",{dark:"#B180D7",light:"#652D90",hc:"#B180D7"},a.NC("vs/platform/theme/common/colorRegistry","chartsPurple","The purple color used in chart visualizations."));const wi="vscode://schemas/workbench-colors";let yi=c.B.as(l.I.JSONContribution);yi.registerSchema(wi,h.getColorSchema());const Si=new n.pY((()=>yi.notifySchemaChanged(wi)),200);h.onDidChangeSchema((()=>{Si.isScheduled()||Si.schedule()}))},26181:function(e,t,i){"use strict";i.d(t,{Ks:function(){return g},q5:function(){return h},s_:function(){return _}});var n,o=i(40027),r=i(4821),s=i(46718),a=i(89982),l=i(32801),c=i(73403),d=i(81585);!function(e){e.getDefinition=function(e,t){let i=e.defaults;for(;d.kS.isThemeIcon(i);){const e=u.getIcon(i.id);if(!e)return;i=e.defaults}return i}}(n||(n={}));const u=new class{constructor(){this._onDidChange=new s.Q5,this.onDidChange=this._onDidChange.event,this.iconSchema={definitions:{icons:{type:"object",properties:{fontId:{type:"string",description:(0,a.NC)("vs/platform/theme/common/iconRegistry","iconDefinition.fontId","The id of the font to use. If not set, the font that is defined first is used.")},fontCharacter:{type:"string",description:(0,a.NC)("vs/platform/theme/common/iconRegistry","iconDefinition.fontCharacter","The font character associated with the icon definition.")}},additionalProperties:!1,defaultSnippets:[{body:{fontCharacter:"\\\\e030"}}]}},type:"object",properties:{}},this.iconReferenceSchema={type:"string",pattern:`^${r.dT.iconNameExpression}$`,enum:[],enumDescriptions:[]},this.iconsById={},this.iconFontsById={}}registerIcon(e,t,i,n){const o=this.iconsById[e];if(o){if(i&&!o.description){o.description=i,this.iconSchema.properties[e].markdownDescription=`${i} $(${e})`;const t=this.iconReferenceSchema.enum.indexOf(e);-1!==t&&(this.iconReferenceSchema.enumDescriptions[t]=i),this._onDidChange.fire()}return o}let r={id:e,description:i,defaults:t,deprecationMessage:n};this.iconsById[e]=r;let s={$ref:"#/definitions/icons"};return n&&(s.deprecationMessage=n),i&&(s.markdownDescription=`${i}: $(${e})`),this.iconSchema.properties[e]=s,this.iconReferenceSchema.enum.push(e),this.iconReferenceSchema.enumDescriptions.push(i||""),this._onDidChange.fire(),{id:e}}getIcons(){return Object.keys(this.iconsById).map((e=>this.iconsById[e]))}getIcon(e){return this.iconsById[e]}getIconSchema(){return this.iconSchema}toString(){const e=(e,t)=>e.id.localeCompare(t.id),t=e=>{for(;d.kS.isThemeIcon(e.defaults);)e=this.iconsById[e.defaults.id];return`codicon codicon-${e?e.id:""}`};let i=[];i.push("| preview | identifier | default codicon ID | description"),i.push("| ----------- | --------------------------------- | --------------------------------- | --------------------------------- |");const n=Object.keys(this.iconsById).map((e=>this.iconsById[e]));for(const o of n.filter((e=>!!e.description)).sort(e))i.push(`||${o.id}|${d.kS.isThemeIcon(o.defaults)?o.defaults.id:o.id}|${o.description||""}|`);i.push("| preview | identifier "),i.push("| ----------- | --------------------------------- |");for(const o of n.filter((e=>!d.kS.isThemeIcon(e.defaults))).sort(e))i.push(`||${o.id}|`);return i.join("\n")}};function h(e,t,i,n){return u.registerIcon(e,t,i,n)}function g(){return u}c.B.add("base.contributions.icons",u),function(){for(const e of r.lA.getAll())u.registerIcon(e.id,e.definition,e.description)}();const p="vscode://schemas/icons";let m=c.B.as(l.I.JSONContribution);m.registerSchema(p,u.getIconSchema());const f=new o.pY((()=>m.notifySchemaChanged(p)),200);u.onDidChange((()=>{f.isScheduled()||f.schedule()}));const _=h("widget-close",r.lA.close,(0,a.NC)("vs/platform/theme/common/iconRegistry","widgetClose","Icon for the close action in widgets."));h("goto-previous-location",r.lA.arrowUp,(0,a.NC)("vs/platform/theme/common/iconRegistry","previousChangeIcon","Icon for goto previous editor location.")),h("goto-next-location",r.lA.arrowDown,(0,a.NC)("vs/platform/theme/common/iconRegistry","nextChangeIcon","Icon for goto next editor location.")),d.kS.modify(r.lA.sync,"spin"),d.kS.modify(r.lA.loading,"spin")},64348:function(e,t,i){"use strict";i.d(t,{Jl:function(){return a},O2:function(){return l},WZ:function(){return s},o:function(){return o},tj:function(){return d}});var n=i(45164);function o(e,t){const i=Object.create(null);for(let o in t){const r=t[o];r&&(i[o]=(0,n.Snq)(r,e))}return i}function r(e,t,i){function n(){const n=o(e.getColorTheme(),t);"function"==typeof i?i(n):i.style(n)}return n(),e.onDidColorThemeChange(n)}function s(e,t,i){return r(t,{badgeBackground:(null==i?void 0:i.badgeBackground)||n.g8u,badgeForeground:(null==i?void 0:i.badgeForeground)||n.qeD,badgeBorder:n.lRK},e)}function a(e,t,i){return r(t,Object.assign(Object.assign({},l),i||{}),e)}const l={listFocusBackground:n._bK,listFocusForeground:n._2n,listFocusOutline:n.Oop,listActiveSelectionBackground:n.dCr,listActiveSelectionForeground:n.M6C,listActiveSelectionIconForeground:n.Tnx,listFocusAndSelectionBackground:n.dCr,listFocusAndSelectionForeground:n.M6C,listInactiveSelectionBackground:n.rg2,listInactiveSelectionIconForeground:n.kvU,listInactiveSelectionForeground:n.ytC,listInactiveFocusBackground:n.s$,listInactiveFocusOutline:n.F3d,listHoverBackground:n.mV1,listHoverForeground:n.$d5,listDropBackground:n.AS1,listSelectionOutline:n.xL1,listHoverOutline:n.xL1,listFilterWidgetBackground:n.vGG,listFilterWidgetOutline:n.oSI,listFilterWidgetNoMatchesOutline:n.Saq,listMatchesShadow:n.rh,treeIndentGuidesStroke:n.UnT,tableColumnsBorder:n.uxu,tableOddRowsBackgroundColor:n.EQn},c={shadowColor:n.rh,borderColor:n.Cdg,foregroundColor:n.DEr,backgroundColor:n.Hz8,selectionForegroundColor:n.jbW,selectionBackgroundColor:n.$DX,selectionBorderColor:n.E3h,separatorColor:n.ZGJ,scrollbarShadow:n._wn,scrollbarSliderBackground:n.etL,scrollbarSliderHoverBackground:n.ABB,scrollbarSliderActiveBackground:n.ynu};function d(e,t,i){return r(t,Object.assign(Object.assign({},c),i),e)}},14540:function(e,t,i){"use strict";var n;i.d(t,{e:function(){return n}}),function(e){e.DARK="dark",e.LIGHT="light",e.HIGH_CONTRAST="hc"}(n||(n={}))},81585:function(e,t,i){"use strict";i.d(t,{EN:function(){return h},IP:function(){return p},Ic:function(){return f},XE:function(){return c},bB:function(){return _},kS:function(){return u},m6:function(){return g}});var n=i(4821),o=i(46718),r=i(4004),s=i(12260),a=i(73403),l=i(14540);const c=(0,s.yh)("themeService");var d,u;function h(e){return{id:e}}function g(e){switch(e){case l.e.DARK:return"vs-dark";case l.e.HIGH_CONTRAST:return"hc-black";default:return"vs"}}!function(e){e.isThemeColor=function(e){return e&&"object"==typeof e&&"string"==typeof e.id}}(d||(d={})),function(e){e.isThemeIcon=function(e){return e&&"object"==typeof e&&"string"==typeof e.id&&(void 0===e.color||d.isThemeColor(e.color))};const t=new RegExp(`^\\$\\((${n.dT.iconNameExpression}(?:${n.dT.iconModifierExpression})?)\\)$`);e.fromString=function(e){const i=t.exec(e);if(!i)return;let[,n]=i;return{id:n}},e.fromId=function(e){return{id:e}},e.modify=function(e,t){let i=e.id;const n=i.lastIndexOf("~");return-1!==n&&(i=i.substring(0,n)),t&&(i=`${i}~${t}`),{id:i}},e.getModifier=function(e){const t=e.id.lastIndexOf("~");if(-1!==t)return e.id.substring(t+1)},e.isEqual=function(e,t){var i,n;return e.id===t.id&&(null===(i=e.color)||void 0===i?void 0:i.id)===(null===(n=t.color)||void 0===n?void 0:n.id)},e.asThemeIcon=function(e,t){return{id:e.id,color:t?h(t):void 0}},e.asClassNameArray=n.dT.asClassNameArray,e.asClassName=n.dT.asClassName,e.asCSSSelector=n.dT.asCSSSelector}(u||(u={}));const p={ThemingContribution:"base.contributions.theming"};let m=new class{constructor(){this.themingParticipants=[],this.themingParticipants=[],this.onThemingParticipantAddedEmitter=new o.Q5}onColorThemeChange(e){return this.themingParticipants.push(e),this.onThemingParticipantAddedEmitter.fire(e),(0,r.OF)((()=>{const t=this.themingParticipants.indexOf(e);this.themingParticipants.splice(t,1)}))}getThemingParticipants(){return this.themingParticipants}};function f(e){return m.onColorThemeChange(e)}a.B.add(p.ThemingContribution,m);class _ extends r.JT{constructor(e){super(),this.themeService=e,this.theme=e.getColorTheme(),this._register(this.themeService.onDidColorThemeChange((e=>this.onThemeChange(e))))}onThemeChange(e){this.theme=e,this.updateStyles()}updateStyles(){}}},68511:function(e,t,i){"use strict";i.d(t,{Xt:function(){return r},YO:function(){return o},gJ:function(){return s},tJ:function(){return n}});const n=(0,i(12260).yh)("undoRedoService");class o{constructor(e,t){this.resource=e,this.elements=t}}class r{constructor(){this.id=r._ID++,this.order=1}nextOrder(){return 0===this.id?0:this.order++}}r._ID=0,r.None=new r;class s{constructor(){this.id=s._ID++,this.order=1}nextOrder(){return 0===this.id?0:this.order++}}s._ID=0,s.None=new s},38630:function(e,t,i){"use strict";i.d(t,{A6:function(){return c},eb:function(){return s},ec:function(){return r},md:function(){return l},uT:function(){return a}});var n=i(89982),o=(i(38455),i(39675));const r=(0,i(12260).yh)("contextService");function s(e){const t=e;return"string"==typeof(null==t?void 0:t.id)&&o.o.isUri(t.uri)}function a(e){return e.configuration?{id:e.id,configPath:e.configuration}:1===e.folders.length?{id:e.id,uri:e.folders[0].uri}:void 0}class l{constructor(e,t){this.raw=t,this.uri=e.uri,this.index=e.index,this.name=e.name}toJSON(){return{uri:this.uri,name:this.name,index:this.index}}}const c="code-workspace";(0,n.NC)("vs/platform/workspace/common/workspace","codeWorkspace","Code Workspace")},32817:function(e,t,i){"use strict";i.d(t,{Y:function(){return n}});const n=(0,i(12260).yh)("workspaceTrustManagementService")},54918:function(e,t,i){var n;self.MonacoEnvironment=(n={editorWorkerService:"editor.worker.js",css:"css.worker.js",html:"html.worker.js",json:"json.worker.js",typescript:"ts.worker.js",javascript:"ts.worker.js",less:"css.worker.js",scss:"css.worker.js",handlebars:"html.worker.js",razor:"html.worker.js"},{globalAPI:!0,getWorkerUrl:function(e,t){var o=i.p,r=(o?o.replace(/\/$/,"")+"/":"")+n[t];if(/^((http:)|(https:)|(file:)|(\/\/))/.test(r)){var s=String(window.location),a=s.substr(0,s.length-window.location.hash.length-window.location.search.length-window.location.pathname.length);if(r.substring(0,a.length)!==a){/^(\/\/)/.test(r)&&(r=window.location.protocol+r);var l=new Blob(["/*"+t+'*/importScripts("'+r+'");'],{type:"application/javascript"});return URL.createObjectURL(l)}}return r}}),i(32210),i(77082),i(26421),i(47095),i(90089),i(42336),i(63149),i(97807),i(42201),i(13257),i(57856),i(2769),i(80015),i(96593),i(81177),i(90251),i(16244),i(48693),i(27239),i(15707),i(57402),i(82879),i(6718),i(34944),i(17026),i(63022),i(7859),i(37089),i(28859),i(21094),i(82105),i(68620),i(16486),i(70663),i(78053),i(99966),i(50717),i(71874),i(88640),i(5380),i(98483),i(32072),i(29820),i(1266),i(82597),i(13876),i(27710),i(88942),i(60803),i(32547),i(40216),i(37184),i(65042),e.exports=i(38203),i(47729),i(24900),i(23434),i(63631),i(33475),i(93048),i(98184),i(3186),i(53651),i(34669),i(3654),i(63698),i(31118),i(73151),i(80631),i(10944),i(25456),i(2395),i(630),i(4275),i(61089),i(80527),i(9243),i(64825),i(77322),i(72080),i(62965),i(80571),i(89852),i(45580),i(66424),i(93741),i(27174),i(68971),i(21401),i(50612),i(33903),i(20366),i(60301),i(21823),i(54201),i(5895),i(60107),i(86229),i(9086),i(24972),i(83105),i(79931),i(53828),i(7406),i(64026),i(33173),i(11138),i(61116),i(31961),i(43717),i(63074),i(99032),i(28897),i(45439),i(94184),i(48367),i(33464),i(4595),i(8592),i(49607),i(78027),i(45089),i(22900),i(6714),i(59305),i(51345),i(61797),i(86),i(35184),i(36945),i(59114),i(75797),i(19396),i(77897),i(24311)},70071:function(e,t,i){var n;self.MonacoEnvironment=(n={editorWorkerService:"editor.worker.js",css:"css.worker.js",html:"html.worker.js",json:"json.worker.js",typescript:"ts.worker.js",javascript:"ts.worker.js",less:"css.worker.js",scss:"css.worker.js",handlebars:"html.worker.js",razor:"html.worker.js"},{globalAPI:!0,getWorkerUrl:function(e,t){var o=i.p,r=(o?o.replace(/\/$/,"")+"/":"")+n[t];if(/^((http:)|(https:)|(file:)|(\/\/))/.test(r)){var s=String(window.location),a=s.substr(0,s.length-window.location.hash.length-window.location.search.length-window.location.pathname.length);if(r.substring(0,a.length)!==a){/^(\/\/)/.test(r)&&(r=window.location.protocol+r);var l=new Blob(["/*"+t+'*/importScripts("'+r+'");'],{type:"application/javascript"});return URL.createObjectURL(l)}}return r}}),i(32210),i(77082),i(26421),i(47095),i(90089),i(42336),i(63149),i(97807),i(42201),i(13257),i(57856),i(2769),i(80015),i(96593),i(81177),i(90251),i(16244),i(48693),i(27239),i(15707),i(57402),i(82879),i(6718),i(34944),i(17026),i(63022),i(7859),i(37089),i(28859),i(21094),i(82105),i(68620),i(16486),i(70663),i(78053),i(99966),i(50717),i(71874),i(88640),i(5380),i(98483),i(32072),i(29820),i(1266),i(82597),i(13876),i(27710),i(88942),i(60803),i(32547),i(40216),i(37184),i(65042),e.exports=i(49982),i(47729),i(24900),i(23434),i(63631),i(33475),i(93048),i(98184),i(3186),i(53651),i(34669),i(3654),i(63698),i(31118),i(73151),i(80631),i(10944),i(25456),i(2395),i(630),i(4275),i(61089),i(80527),i(9243),i(64825),i(77322),i(72080),i(62965),i(80571),i(89852),i(45580),i(66424),i(93741),i(27174),i(68971),i(21401),i(50612),i(33903),i(20366),i(60301),i(21823),i(54201),i(5895),i(60107),i(86229),i(9086),i(24972),i(83105),i(79931),i(53828),i(7406),i(64026),i(33173),i(11138),i(61116),i(31961),i(43717),i(63074),i(99032),i(28897),i(45439),i(94184),i(48367),i(33464),i(4595),i(8592),i(49607),i(78027),i(45089),i(22900),i(6714),i(59305),i(51345),i(61797),i(86),i(35184),i(36945),i(59114),i(75797),i(19396),i(77897),i(24311)},63050:function(e,t,i){"use strict";var n=i(93379),o=i.n(n),r=i(7795),s=i.n(r),a=i(90569),l=i.n(a),c=i(3565),d=i.n(c),u=i(19216),h=i.n(u),g=i(44589),p=i.n(g),m=i(86160),f={};f.styleTagTransform=p(),f.setAttributes=d(),f.insert=l().bind(null,"head"),f.domAPI=s(),f.insertStyleElement=h(),o()(m.Z,f),m.Z&&m.Z.locals&&m.Z.locals},99704:function(e,t,i){"use strict";var n=i(93379),o=i.n(n),r=i(7795),s=i.n(r),a=i(90569),l=i.n(a),c=i(3565),d=i.n(c),u=i(19216),h=i.n(u),g=i(44589),p=i.n(g),m=i(41859),f={};f.styleTagTransform=p(),f.setAttributes=d(),f.insert=l().bind(null,"head"),f.domAPI=s(),f.insertStyleElement=h(),o()(m.Z,f),m.Z&&m.Z.locals&&m.Z.locals},93379:function(e){"use strict";var t=[];function i(e){for(var i=-1,n=0;n0?" ".concat(i.layer):""," {")),n+=i.css,o&&(n+="}"),i.media&&(n+="}"),i.supports&&(n+="}");var r=i.sourceMap;r&&"undefined"!=typeof btoa&&(n+="\n/*# sourceMappingURL=data:application/json;base64,".concat(btoa(unescape(encodeURIComponent(JSON.stringify(r))))," */")),t.styleTagTransform(n,e,t.options)}(t,e,i)},remove:function(){!function(e){if(null===e.parentNode)return!1;e.parentNode.removeChild(e)}(t)}}}},44589:function(e){"use strict";e.exports=function(e,t){if(t.styleSheet)t.styleSheet.cssText=e;else{for(;t.firstChild;)t.removeChild(t.firstChild);t.appendChild(document.createTextNode(e))}}},94748:function(e){"use strict";e.exports="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAQAAAAECAYAAACp8Z5+AAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAAAJcEhZcwAADsMAAA7DAcdvqGQAAAAZdEVYdFNvZnR3YXJlAHBhaW50Lm5ldCA0LjAuMTZEaa/1AAAAHUlEQVQYV2PYvXu3JAi7uLiAMaYAjAGTQBPYLQkAa/0Zef3qRswAAAAASUVORK5CYII="},6161:function(e){"use strict";e.exports="data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iNTMiIGhlaWdodD0iMzYiIHZpZXdCb3g9IjAgMCA1MyAzNiIgZmlsbD0ibm9uZSIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIj4KPGcgY2xpcC1wYXRoPSJ1cmwoI2NsaXAwKSI+CjxwYXRoIGZpbGwtcnVsZT0iZXZlbm9kZCIgY2xpcC1ydWxlPSJldmVub2RkIiBkPSJNNDguMDM2NCA0LjAxMDQySDQuMDA3NzlMNC4wMDc3OSAzMi4wMjg2SDQ4LjAzNjRWNC4wMTA0MlpNNC4wMDc3OSAwLjAwNzgxMjVDMS43OTcyMSAwLjAwNzgxMjUgMC4wMDUxODc5OSAxLjc5OTg0IDAuMDA1MTg3OTkgNC4wMTA0MlYzMi4wMjg2QzAuMDA1MTg3OTkgMzQuMjM5MiAxLjc5NzIxIDM2LjAzMTIgNC4wMDc3OSAzNi4wMzEySDQ4LjAzNjRDNTAuMjQ3IDM2LjAzMTIgNTIuMDM5IDM0LjIzOTIgNTIuMDM5IDMyLjAyODZWNC4wMTA0MkM1Mi4wMzkgMS43OTk4NCA1MC4yNDcgMC4wMDc4MTI1IDQ4LjAzNjQgMC4wMDc4MTI1SDQuMDA3NzlaTTguMDEwNDIgOC4wMTMwMkgxMi4wMTNWMTIuMDE1Nkg4LjAxMDQyVjguMDEzMDJaTTIwLjAxODIgOC4wMTMwMkgxNi4wMTU2VjEyLjAxNTZIMjAuMDE4MlY4LjAxMzAyWk0yNC4wMjA4IDguMDEzMDJIMjguMDIzNFYxMi4wMTU2SDI0LjAyMDhWOC4wMTMwMlpNMzYuMDI4NiA4LjAxMzAySDMyLjAyNlYxMi4wMTU2SDM2LjAyODZWOC4wMTMwMlpNNDAuMDMxMiA4LjAxMzAySDQ0LjAzMzlWMTIuMDE1Nkg0MC4wMzEyVjguMDEzMDJaTTE2LjAxNTYgMTYuMDE4Mkg4LjAxMDQyVjIwLjAyMDhIMTYuMDE1NlYxNi4wMTgyWk0yMC4wMTgyIDE2LjAxODJIMjQuMDIwOFYyMC4wMjA4SDIwLjAxODJWMTYuMDE4MlpNMzIuMDI2IDE2LjAxODJIMjguMDIzNFYyMC4wMjA4SDMyLjAyNlYxNi4wMTgyWk00NC4wMzM5IDE2LjAxODJWMjAuMDIwOEgzNi4wMjg2VjE2LjAxODJINDQuMDMzOVpNMTIuMDEzIDI0LjAyMzRIOC4wMTA0MlYyOC4wMjZIMTIuMDEzVjI0LjAyMzRaTTE2LjAxNTYgMjQuMDIzNEgzNi4wMjg2VjI4LjAyNkgxNi4wMTU2VjI0LjAyMzRaTTQ0LjAzMzkgMjQuMDIzNEg0MC4wMzEyVjI4LjAyNkg0NC4wMzM5VjI0LjAyMzRaIiBmaWxsPSIjNDI0MjQyIi8+CjwvZz4KPGRlZnM+CjxjbGlwUGF0aCBpZD0iY2xpcDAiPgo8cmVjdCB3aWR0aD0iNTMiIGhlaWdodD0iMzYiIGZpbGw9IndoaXRlIi8+CjwvY2xpcFBhdGg+CjwvZGVmcz4KPC9zdmc+Cg=="},51096:function(e){"use strict";e.exports="data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iNTMiIGhlaWdodD0iMzYiIHZpZXdCb3g9IjAgMCA1MyAzNiIgZmlsbD0ibm9uZSIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIj4KPGcgY2xpcC1wYXRoPSJ1cmwoI2NsaXAwKSI+CjxwYXRoIGZpbGwtcnVsZT0iZXZlbm9kZCIgY2xpcC1ydWxlPSJldmVub2RkIiBkPSJNNDguMDM2NCA0LjAxMDQySDQuMDA3NzlMNC4wMDc3OSAzMi4wMjg2SDQ4LjAzNjRWNC4wMTA0MlpNNC4wMDc3OSAwLjAwNzgxMjVDMS43OTcyMSAwLjAwNzgxMjUgMC4wMDUxODc5OSAxLjc5OTg0IDAuMDA1MTg3OTkgNC4wMTA0MlYzMi4wMjg2QzAuMDA1MTg3OTkgMzQuMjM5MiAxLjc5NzIxIDM2LjAzMTIgNC4wMDc3OSAzNi4wMzEySDQ4LjAzNjRDNTAuMjQ3IDM2LjAzMTIgNTIuMDM5IDM0LjIzOTIgNTIuMDM5IDMyLjAyODZWNC4wMTA0MkM1Mi4wMzkgMS43OTk4NCA1MC4yNDcgMC4wMDc4MTI1IDQ4LjAzNjQgMC4wMDc4MTI1SDQuMDA3NzlaTTguMDEwNDIgOC4wMTMwMkgxMi4wMTNWMTIuMDE1Nkg4LjAxMDQyVjguMDEzMDJaTTIwLjAxODIgOC4wMTMwMkgxNi4wMTU2VjEyLjAxNTZIMjAuMDE4MlY4LjAxMzAyWk0yNC4wMjA4IDguMDEzMDJIMjguMDIzNFYxMi4wMTU2SDI0LjAyMDhWOC4wMTMwMlpNMzYuMDI4NiA4LjAxMzAySDMyLjAyNlYxMi4wMTU2SDM2LjAyODZWOC4wMTMwMlpNNDAuMDMxMiA4LjAxMzAySDQ0LjAzMzlWMTIuMDE1Nkg0MC4wMzEyVjguMDEzMDJaTTE2LjAxNTYgMTYuMDE4Mkg4LjAxMDQyVjIwLjAyMDhIMTYuMDE1NlYxNi4wMTgyWk0yMC4wMTgyIDE2LjAxODJIMjQuMDIwOFYyMC4wMjA4SDIwLjAxODJWMTYuMDE4MlpNMzIuMDI2IDE2LjAxODJIMjguMDIzNFYyMC4wMjA4SDMyLjAyNlYxNi4wMTgyWk00NC4wMzM5IDE2LjAxODJWMjAuMDIwOEgzNi4wMjg2VjE2LjAxODJINDQuMDMzOVpNMTIuMDEzIDI0LjAyMzRIOC4wMTA0MlYyOC4wMjZIMTIuMDEzVjI0LjAyMzRaTTE2LjAxNTYgMjQuMDIzNEgzNi4wMjg2VjI4LjAyNkgxNi4wMTU2VjI0LjAyMzRaTTQ0LjAzMzkgMjQuMDIzNEg0MC4wMzEyVjI4LjAyNkg0NC4wMzM5VjI0LjAyMzRaIiBmaWxsPSIjQzVDNUM1Ii8+CjwvZz4KPGRlZnM+CjxjbGlwUGF0aCBpZD0iY2xpcDAiPgo8cmVjdCB3aWR0aD0iNTMiIGhlaWdodD0iMzYiIGZpbGw9IndoaXRlIi8+CjwvY2xpcFBhdGg+CjwvZGVmcz4KPC9zdmc+Cg=="},38137:function(e,t,i){"use strict";e.exports=i.p+"ade705761eb7e702770d.ttf"}},t={};function i(n){var o=t[n];if(void 0!==o)return o.exports;var r=t[n]={id:n,exports:{}};return e[n](r,r.exports,i),r.exports}i.m=e,i.amdO={},i.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return i.d(t,{a:t}),t},i.d=function(e,t){for(var n in t)i.o(t,n)&&!i.o(e,n)&&Object.defineProperty(e,n,{enumerable:!0,get:t[n]})},i.g=function(){if("object"==typeof globalThis)return globalThis;try{return this||new Function("return this")()}catch(e){if("object"==typeof window)return window}}(),i.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},i.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},function(){var e;i.g.importScripts&&(e=i.g.location+"");var t=i.g.document;if(!e&&t&&(t.currentScript&&(e=t.currentScript.src),!e)){var n=t.getElementsByTagName("script");n.length&&(e=n[n.length-1].src)}if(!e)throw new Error("Automatic publicPath is not supported in this browser");e=e.replace(/#.*$/,"").replace(/\?.*$/,"").replace(/\/[^\/]+$/,"/"),i.p=e}(),i.b=document.baseURI||self.location.href,function(){"use strict";var e=i(70071);window.monaco=e,window.MonacoEnvironment=window.MonacoEnvironment||{},window.MonacoEnvironment.Locale||(window.MonacoEnvironment.Locale=window.MonacoLocale)}()}(); \ No newline at end of file diff --git a/software/dashboard/grafana/csv/Node-RED_files/font-awesome.min.css b/software/dashboard/grafana/csv/Node-RED_files/font-awesome.min.css new file mode 100644 index 0000000..540440c --- /dev/null +++ b/software/dashboard/grafana/csv/Node-RED_files/font-awesome.min.css @@ -0,0 +1,4 @@ +/*! + * Font Awesome 4.7.0 by @davegandy - http://fontawesome.io - @fontawesome + * License - http://fontawesome.io/license (Font: SIL OFL 1.1, CSS: MIT License) + */@font-face{font-family:'FontAwesome';src:url('../fonts/fontawesome-webfont.eot?v=4.7.0');src:url('../fonts/fontawesome-webfont.eot?#iefix&v=4.7.0') format('embedded-opentype'),url('../fonts/fontawesome-webfont.woff2?v=4.7.0') format('woff2'),url('../fonts/fontawesome-webfont.woff?v=4.7.0') format('woff'),url('../fonts/fontawesome-webfont.ttf?v=4.7.0') format('truetype'),url('../fonts/fontawesome-webfont.svg?v=4.7.0#fontawesomeregular') format('svg');font-weight:normal;font-style:normal}.fa{display:inline-block;font:normal normal normal 14px/1 FontAwesome;font-size:inherit;text-rendering:auto;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale}.fa-lg{font-size:1.33333333em;line-height:.75em;vertical-align:-15%}.fa-2x{font-size:2em}.fa-3x{font-size:3em}.fa-4x{font-size:4em}.fa-5x{font-size:5em}.fa-fw{width:1.28571429em;text-align:center}.fa-ul{padding-left:0;margin-left:2.14285714em;list-style-type:none}.fa-ul>li{position:relative}.fa-li{position:absolute;left:-2.14285714em;width:2.14285714em;top:.14285714em;text-align:center}.fa-li.fa-lg{left:-1.85714286em}.fa-border{padding:.2em .25em .15em;border:solid .08em #eee;border-radius:.1em}.fa-pull-left{float:left}.fa-pull-right{float:right}.fa.fa-pull-left{margin-right:.3em}.fa.fa-pull-right{margin-left:.3em}.pull-right{float:right}.pull-left{float:left}.fa.pull-left{margin-right:.3em}.fa.pull-right{margin-left:.3em}.fa-spin{-webkit-animation:fa-spin 2s infinite linear;animation:fa-spin 2s infinite linear}.fa-pulse{-webkit-animation:fa-spin 1s infinite steps(8);animation:fa-spin 1s infinite steps(8)}@-webkit-keyframes fa-spin{0%{-webkit-transform:rotate(0deg);transform:rotate(0deg)}100%{-webkit-transform:rotate(359deg);transform:rotate(359deg)}}@keyframes fa-spin{0%{-webkit-transform:rotate(0deg);transform:rotate(0deg)}100%{-webkit-transform:rotate(359deg);transform:rotate(359deg)}}.fa-rotate-90{-ms-filter:"progid:DXImageTransform.Microsoft.BasicImage(rotation=1)";-webkit-transform:rotate(90deg);-ms-transform:rotate(90deg);transform:rotate(90deg)}.fa-rotate-180{-ms-filter:"progid:DXImageTransform.Microsoft.BasicImage(rotation=2)";-webkit-transform:rotate(180deg);-ms-transform:rotate(180deg);transform:rotate(180deg)}.fa-rotate-270{-ms-filter:"progid:DXImageTransform.Microsoft.BasicImage(rotation=3)";-webkit-transform:rotate(270deg);-ms-transform:rotate(270deg);transform:rotate(270deg)}.fa-flip-horizontal{-ms-filter:"progid:DXImageTransform.Microsoft.BasicImage(rotation=0, mirror=1)";-webkit-transform:scale(-1, 1);-ms-transform:scale(-1, 1);transform:scale(-1, 1)}.fa-flip-vertical{-ms-filter:"progid:DXImageTransform.Microsoft.BasicImage(rotation=2, mirror=1)";-webkit-transform:scale(1, -1);-ms-transform:scale(1, -1);transform:scale(1, -1)}:root .fa-rotate-90,:root .fa-rotate-180,:root .fa-rotate-270,:root .fa-flip-horizontal,:root .fa-flip-vertical{filter:none}.fa-stack{position:relative;display:inline-block;width:2em;height:2em;line-height:2em;vertical-align:middle}.fa-stack-1x,.fa-stack-2x{position:absolute;left:0;width:100%;text-align:center}.fa-stack-1x{line-height:inherit}.fa-stack-2x{font-size:2em}.fa-inverse{color:#fff}.fa-glass:before{content:"\f000"}.fa-music:before{content:"\f001"}.fa-search:before{content:"\f002"}.fa-envelope-o:before{content:"\f003"}.fa-heart:before{content:"\f004"}.fa-star:before{content:"\f005"}.fa-star-o:before{content:"\f006"}.fa-user:before{content:"\f007"}.fa-film:before{content:"\f008"}.fa-th-large:before{content:"\f009"}.fa-th:before{content:"\f00a"}.fa-th-list:before{content:"\f00b"}.fa-check:before{content:"\f00c"}.fa-remove:before,.fa-close:before,.fa-times:before{content:"\f00d"}.fa-search-plus:before{content:"\f00e"}.fa-search-minus:before{content:"\f010"}.fa-power-off:before{content:"\f011"}.fa-signal:before{content:"\f012"}.fa-gear:before,.fa-cog:before{content:"\f013"}.fa-trash-o:before{content:"\f014"}.fa-home:before{content:"\f015"}.fa-file-o:before{content:"\f016"}.fa-clock-o:before{content:"\f017"}.fa-road:before{content:"\f018"}.fa-download:before{content:"\f019"}.fa-arrow-circle-o-down:before{content:"\f01a"}.fa-arrow-circle-o-up:before{content:"\f01b"}.fa-inbox:before{content:"\f01c"}.fa-play-circle-o:before{content:"\f01d"}.fa-rotate-right:before,.fa-repeat:before{content:"\f01e"}.fa-refresh:before{content:"\f021"}.fa-list-alt:before{content:"\f022"}.fa-lock:before{content:"\f023"}.fa-flag:before{content:"\f024"}.fa-headphones:before{content:"\f025"}.fa-volume-off:before{content:"\f026"}.fa-volume-down:before{content:"\f027"}.fa-volume-up:before{content:"\f028"}.fa-qrcode:before{content:"\f029"}.fa-barcode:before{content:"\f02a"}.fa-tag:before{content:"\f02b"}.fa-tags:before{content:"\f02c"}.fa-book:before{content:"\f02d"}.fa-bookmark:before{content:"\f02e"}.fa-print:before{content:"\f02f"}.fa-camera:before{content:"\f030"}.fa-font:before{content:"\f031"}.fa-bold:before{content:"\f032"}.fa-italic:before{content:"\f033"}.fa-text-height:before{content:"\f034"}.fa-text-width:before{content:"\f035"}.fa-align-left:before{content:"\f036"}.fa-align-center:before{content:"\f037"}.fa-align-right:before{content:"\f038"}.fa-align-justify:before{content:"\f039"}.fa-list:before{content:"\f03a"}.fa-dedent:before,.fa-outdent:before{content:"\f03b"}.fa-indent:before{content:"\f03c"}.fa-video-camera:before{content:"\f03d"}.fa-photo:before,.fa-image:before,.fa-picture-o:before{content:"\f03e"}.fa-pencil:before{content:"\f040"}.fa-map-marker:before{content:"\f041"}.fa-adjust:before{content:"\f042"}.fa-tint:before{content:"\f043"}.fa-edit:before,.fa-pencil-square-o:before{content:"\f044"}.fa-share-square-o:before{content:"\f045"}.fa-check-square-o:before{content:"\f046"}.fa-arrows:before{content:"\f047"}.fa-step-backward:before{content:"\f048"}.fa-fast-backward:before{content:"\f049"}.fa-backward:before{content:"\f04a"}.fa-play:before{content:"\f04b"}.fa-pause:before{content:"\f04c"}.fa-stop:before{content:"\f04d"}.fa-forward:before{content:"\f04e"}.fa-fast-forward:before{content:"\f050"}.fa-step-forward:before{content:"\f051"}.fa-eject:before{content:"\f052"}.fa-chevron-left:before{content:"\f053"}.fa-chevron-right:before{content:"\f054"}.fa-plus-circle:before{content:"\f055"}.fa-minus-circle:before{content:"\f056"}.fa-times-circle:before{content:"\f057"}.fa-check-circle:before{content:"\f058"}.fa-question-circle:before{content:"\f059"}.fa-info-circle:before{content:"\f05a"}.fa-crosshairs:before{content:"\f05b"}.fa-times-circle-o:before{content:"\f05c"}.fa-check-circle-o:before{content:"\f05d"}.fa-ban:before{content:"\f05e"}.fa-arrow-left:before{content:"\f060"}.fa-arrow-right:before{content:"\f061"}.fa-arrow-up:before{content:"\f062"}.fa-arrow-down:before{content:"\f063"}.fa-mail-forward:before,.fa-share:before{content:"\f064"}.fa-expand:before{content:"\f065"}.fa-compress:before{content:"\f066"}.fa-plus:before{content:"\f067"}.fa-minus:before{content:"\f068"}.fa-asterisk:before{content:"\f069"}.fa-exclamation-circle:before{content:"\f06a"}.fa-gift:before{content:"\f06b"}.fa-leaf:before{content:"\f06c"}.fa-fire:before{content:"\f06d"}.fa-eye:before{content:"\f06e"}.fa-eye-slash:before{content:"\f070"}.fa-warning:before,.fa-exclamation-triangle:before{content:"\f071"}.fa-plane:before{content:"\f072"}.fa-calendar:before{content:"\f073"}.fa-random:before{content:"\f074"}.fa-comment:before{content:"\f075"}.fa-magnet:before{content:"\f076"}.fa-chevron-up:before{content:"\f077"}.fa-chevron-down:before{content:"\f078"}.fa-retweet:before{content:"\f079"}.fa-shopping-cart:before{content:"\f07a"}.fa-folder:before{content:"\f07b"}.fa-folder-open:before{content:"\f07c"}.fa-arrows-v:before{content:"\f07d"}.fa-arrows-h:before{content:"\f07e"}.fa-bar-chart-o:before,.fa-bar-chart:before{content:"\f080"}.fa-twitter-square:before{content:"\f081"}.fa-facebook-square:before{content:"\f082"}.fa-camera-retro:before{content:"\f083"}.fa-key:before{content:"\f084"}.fa-gears:before,.fa-cogs:before{content:"\f085"}.fa-comments:before{content:"\f086"}.fa-thumbs-o-up:before{content:"\f087"}.fa-thumbs-o-down:before{content:"\f088"}.fa-star-half:before{content:"\f089"}.fa-heart-o:before{content:"\f08a"}.fa-sign-out:before{content:"\f08b"}.fa-linkedin-square:before{content:"\f08c"}.fa-thumb-tack:before{content:"\f08d"}.fa-external-link:before{content:"\f08e"}.fa-sign-in:before{content:"\f090"}.fa-trophy:before{content:"\f091"}.fa-github-square:before{content:"\f092"}.fa-upload:before{content:"\f093"}.fa-lemon-o:before{content:"\f094"}.fa-phone:before{content:"\f095"}.fa-square-o:before{content:"\f096"}.fa-bookmark-o:before{content:"\f097"}.fa-phone-square:before{content:"\f098"}.fa-twitter:before{content:"\f099"}.fa-facebook-f:before,.fa-facebook:before{content:"\f09a"}.fa-github:before{content:"\f09b"}.fa-unlock:before{content:"\f09c"}.fa-credit-card:before{content:"\f09d"}.fa-feed:before,.fa-rss:before{content:"\f09e"}.fa-hdd-o:before{content:"\f0a0"}.fa-bullhorn:before{content:"\f0a1"}.fa-bell:before{content:"\f0f3"}.fa-certificate:before{content:"\f0a3"}.fa-hand-o-right:before{content:"\f0a4"}.fa-hand-o-left:before{content:"\f0a5"}.fa-hand-o-up:before{content:"\f0a6"}.fa-hand-o-down:before{content:"\f0a7"}.fa-arrow-circle-left:before{content:"\f0a8"}.fa-arrow-circle-right:before{content:"\f0a9"}.fa-arrow-circle-up:before{content:"\f0aa"}.fa-arrow-circle-down:before{content:"\f0ab"}.fa-globe:before{content:"\f0ac"}.fa-wrench:before{content:"\f0ad"}.fa-tasks:before{content:"\f0ae"}.fa-filter:before{content:"\f0b0"}.fa-briefcase:before{content:"\f0b1"}.fa-arrows-alt:before{content:"\f0b2"}.fa-group:before,.fa-users:before{content:"\f0c0"}.fa-chain:before,.fa-link:before{content:"\f0c1"}.fa-cloud:before{content:"\f0c2"}.fa-flask:before{content:"\f0c3"}.fa-cut:before,.fa-scissors:before{content:"\f0c4"}.fa-copy:before,.fa-files-o:before{content:"\f0c5"}.fa-paperclip:before{content:"\f0c6"}.fa-save:before,.fa-floppy-o:before{content:"\f0c7"}.fa-square:before{content:"\f0c8"}.fa-navicon:before,.fa-reorder:before,.fa-bars:before{content:"\f0c9"}.fa-list-ul:before{content:"\f0ca"}.fa-list-ol:before{content:"\f0cb"}.fa-strikethrough:before{content:"\f0cc"}.fa-underline:before{content:"\f0cd"}.fa-table:before{content:"\f0ce"}.fa-magic:before{content:"\f0d0"}.fa-truck:before{content:"\f0d1"}.fa-pinterest:before{content:"\f0d2"}.fa-pinterest-square:before{content:"\f0d3"}.fa-google-plus-square:before{content:"\f0d4"}.fa-google-plus:before{content:"\f0d5"}.fa-money:before{content:"\f0d6"}.fa-caret-down:before{content:"\f0d7"}.fa-caret-up:before{content:"\f0d8"}.fa-caret-left:before{content:"\f0d9"}.fa-caret-right:before{content:"\f0da"}.fa-columns:before{content:"\f0db"}.fa-unsorted:before,.fa-sort:before{content:"\f0dc"}.fa-sort-down:before,.fa-sort-desc:before{content:"\f0dd"}.fa-sort-up:before,.fa-sort-asc:before{content:"\f0de"}.fa-envelope:before{content:"\f0e0"}.fa-linkedin:before{content:"\f0e1"}.fa-rotate-left:before,.fa-undo:before{content:"\f0e2"}.fa-legal:before,.fa-gavel:before{content:"\f0e3"}.fa-dashboard:before,.fa-tachometer:before{content:"\f0e4"}.fa-comment-o:before{content:"\f0e5"}.fa-comments-o:before{content:"\f0e6"}.fa-flash:before,.fa-bolt:before{content:"\f0e7"}.fa-sitemap:before{content:"\f0e8"}.fa-umbrella:before{content:"\f0e9"}.fa-paste:before,.fa-clipboard:before{content:"\f0ea"}.fa-lightbulb-o:before{content:"\f0eb"}.fa-exchange:before{content:"\f0ec"}.fa-cloud-download:before{content:"\f0ed"}.fa-cloud-upload:before{content:"\f0ee"}.fa-user-md:before{content:"\f0f0"}.fa-stethoscope:before{content:"\f0f1"}.fa-suitcase:before{content:"\f0f2"}.fa-bell-o:before{content:"\f0a2"}.fa-coffee:before{content:"\f0f4"}.fa-cutlery:before{content:"\f0f5"}.fa-file-text-o:before{content:"\f0f6"}.fa-building-o:before{content:"\f0f7"}.fa-hospital-o:before{content:"\f0f8"}.fa-ambulance:before{content:"\f0f9"}.fa-medkit:before{content:"\f0fa"}.fa-fighter-jet:before{content:"\f0fb"}.fa-beer:before{content:"\f0fc"}.fa-h-square:before{content:"\f0fd"}.fa-plus-square:before{content:"\f0fe"}.fa-angle-double-left:before{content:"\f100"}.fa-angle-double-right:before{content:"\f101"}.fa-angle-double-up:before{content:"\f102"}.fa-angle-double-down:before{content:"\f103"}.fa-angle-left:before{content:"\f104"}.fa-angle-right:before{content:"\f105"}.fa-angle-up:before{content:"\f106"}.fa-angle-down:before{content:"\f107"}.fa-desktop:before{content:"\f108"}.fa-laptop:before{content:"\f109"}.fa-tablet:before{content:"\f10a"}.fa-mobile-phone:before,.fa-mobile:before{content:"\f10b"}.fa-circle-o:before{content:"\f10c"}.fa-quote-left:before{content:"\f10d"}.fa-quote-right:before{content:"\f10e"}.fa-spinner:before{content:"\f110"}.fa-circle:before{content:"\f111"}.fa-mail-reply:before,.fa-reply:before{content:"\f112"}.fa-github-alt:before{content:"\f113"}.fa-folder-o:before{content:"\f114"}.fa-folder-open-o:before{content:"\f115"}.fa-smile-o:before{content:"\f118"}.fa-frown-o:before{content:"\f119"}.fa-meh-o:before{content:"\f11a"}.fa-gamepad:before{content:"\f11b"}.fa-keyboard-o:before{content:"\f11c"}.fa-flag-o:before{content:"\f11d"}.fa-flag-checkered:before{content:"\f11e"}.fa-terminal:before{content:"\f120"}.fa-code:before{content:"\f121"}.fa-mail-reply-all:before,.fa-reply-all:before{content:"\f122"}.fa-star-half-empty:before,.fa-star-half-full:before,.fa-star-half-o:before{content:"\f123"}.fa-location-arrow:before{content:"\f124"}.fa-crop:before{content:"\f125"}.fa-code-fork:before{content:"\f126"}.fa-unlink:before,.fa-chain-broken:before{content:"\f127"}.fa-question:before{content:"\f128"}.fa-info:before{content:"\f129"}.fa-exclamation:before{content:"\f12a"}.fa-superscript:before{content:"\f12b"}.fa-subscript:before{content:"\f12c"}.fa-eraser:before{content:"\f12d"}.fa-puzzle-piece:before{content:"\f12e"}.fa-microphone:before{content:"\f130"}.fa-microphone-slash:before{content:"\f131"}.fa-shield:before{content:"\f132"}.fa-calendar-o:before{content:"\f133"}.fa-fire-extinguisher:before{content:"\f134"}.fa-rocket:before{content:"\f135"}.fa-maxcdn:before{content:"\f136"}.fa-chevron-circle-left:before{content:"\f137"}.fa-chevron-circle-right:before{content:"\f138"}.fa-chevron-circle-up:before{content:"\f139"}.fa-chevron-circle-down:before{content:"\f13a"}.fa-html5:before{content:"\f13b"}.fa-css3:before{content:"\f13c"}.fa-anchor:before{content:"\f13d"}.fa-unlock-alt:before{content:"\f13e"}.fa-bullseye:before{content:"\f140"}.fa-ellipsis-h:before{content:"\f141"}.fa-ellipsis-v:before{content:"\f142"}.fa-rss-square:before{content:"\f143"}.fa-play-circle:before{content:"\f144"}.fa-ticket:before{content:"\f145"}.fa-minus-square:before{content:"\f146"}.fa-minus-square-o:before{content:"\f147"}.fa-level-up:before{content:"\f148"}.fa-level-down:before{content:"\f149"}.fa-check-square:before{content:"\f14a"}.fa-pencil-square:before{content:"\f14b"}.fa-external-link-square:before{content:"\f14c"}.fa-share-square:before{content:"\f14d"}.fa-compass:before{content:"\f14e"}.fa-toggle-down:before,.fa-caret-square-o-down:before{content:"\f150"}.fa-toggle-up:before,.fa-caret-square-o-up:before{content:"\f151"}.fa-toggle-right:before,.fa-caret-square-o-right:before{content:"\f152"}.fa-euro:before,.fa-eur:before{content:"\f153"}.fa-gbp:before{content:"\f154"}.fa-dollar:before,.fa-usd:before{content:"\f155"}.fa-rupee:before,.fa-inr:before{content:"\f156"}.fa-cny:before,.fa-rmb:before,.fa-yen:before,.fa-jpy:before{content:"\f157"}.fa-ruble:before,.fa-rouble:before,.fa-rub:before{content:"\f158"}.fa-won:before,.fa-krw:before{content:"\f159"}.fa-bitcoin:before,.fa-btc:before{content:"\f15a"}.fa-file:before{content:"\f15b"}.fa-file-text:before{content:"\f15c"}.fa-sort-alpha-asc:before{content:"\f15d"}.fa-sort-alpha-desc:before{content:"\f15e"}.fa-sort-amount-asc:before{content:"\f160"}.fa-sort-amount-desc:before{content:"\f161"}.fa-sort-numeric-asc:before{content:"\f162"}.fa-sort-numeric-desc:before{content:"\f163"}.fa-thumbs-up:before{content:"\f164"}.fa-thumbs-down:before{content:"\f165"}.fa-youtube-square:before{content:"\f166"}.fa-youtube:before{content:"\f167"}.fa-xing:before{content:"\f168"}.fa-xing-square:before{content:"\f169"}.fa-youtube-play:before{content:"\f16a"}.fa-dropbox:before{content:"\f16b"}.fa-stack-overflow:before{content:"\f16c"}.fa-instagram:before{content:"\f16d"}.fa-flickr:before{content:"\f16e"}.fa-adn:before{content:"\f170"}.fa-bitbucket:before{content:"\f171"}.fa-bitbucket-square:before{content:"\f172"}.fa-tumblr:before{content:"\f173"}.fa-tumblr-square:before{content:"\f174"}.fa-long-arrow-down:before{content:"\f175"}.fa-long-arrow-up:before{content:"\f176"}.fa-long-arrow-left:before{content:"\f177"}.fa-long-arrow-right:before{content:"\f178"}.fa-apple:before{content:"\f179"}.fa-windows:before{content:"\f17a"}.fa-android:before{content:"\f17b"}.fa-linux:before{content:"\f17c"}.fa-dribbble:before{content:"\f17d"}.fa-skype:before{content:"\f17e"}.fa-foursquare:before{content:"\f180"}.fa-trello:before{content:"\f181"}.fa-female:before{content:"\f182"}.fa-male:before{content:"\f183"}.fa-gittip:before,.fa-gratipay:before{content:"\f184"}.fa-sun-o:before{content:"\f185"}.fa-moon-o:before{content:"\f186"}.fa-archive:before{content:"\f187"}.fa-bug:before{content:"\f188"}.fa-vk:before{content:"\f189"}.fa-weibo:before{content:"\f18a"}.fa-renren:before{content:"\f18b"}.fa-pagelines:before{content:"\f18c"}.fa-stack-exchange:before{content:"\f18d"}.fa-arrow-circle-o-right:before{content:"\f18e"}.fa-arrow-circle-o-left:before{content:"\f190"}.fa-toggle-left:before,.fa-caret-square-o-left:before{content:"\f191"}.fa-dot-circle-o:before{content:"\f192"}.fa-wheelchair:before{content:"\f193"}.fa-vimeo-square:before{content:"\f194"}.fa-turkish-lira:before,.fa-try:before{content:"\f195"}.fa-plus-square-o:before{content:"\f196"}.fa-space-shuttle:before{content:"\f197"}.fa-slack:before{content:"\f198"}.fa-envelope-square:before{content:"\f199"}.fa-wordpress:before{content:"\f19a"}.fa-openid:before{content:"\f19b"}.fa-institution:before,.fa-bank:before,.fa-university:before{content:"\f19c"}.fa-mortar-board:before,.fa-graduation-cap:before{content:"\f19d"}.fa-yahoo:before{content:"\f19e"}.fa-google:before{content:"\f1a0"}.fa-reddit:before{content:"\f1a1"}.fa-reddit-square:before{content:"\f1a2"}.fa-stumbleupon-circle:before{content:"\f1a3"}.fa-stumbleupon:before{content:"\f1a4"}.fa-delicious:before{content:"\f1a5"}.fa-digg:before{content:"\f1a6"}.fa-pied-piper-pp:before{content:"\f1a7"}.fa-pied-piper-alt:before{content:"\f1a8"}.fa-drupal:before{content:"\f1a9"}.fa-joomla:before{content:"\f1aa"}.fa-language:before{content:"\f1ab"}.fa-fax:before{content:"\f1ac"}.fa-building:before{content:"\f1ad"}.fa-child:before{content:"\f1ae"}.fa-paw:before{content:"\f1b0"}.fa-spoon:before{content:"\f1b1"}.fa-cube:before{content:"\f1b2"}.fa-cubes:before{content:"\f1b3"}.fa-behance:before{content:"\f1b4"}.fa-behance-square:before{content:"\f1b5"}.fa-steam:before{content:"\f1b6"}.fa-steam-square:before{content:"\f1b7"}.fa-recycle:before{content:"\f1b8"}.fa-automobile:before,.fa-car:before{content:"\f1b9"}.fa-cab:before,.fa-taxi:before{content:"\f1ba"}.fa-tree:before{content:"\f1bb"}.fa-spotify:before{content:"\f1bc"}.fa-deviantart:before{content:"\f1bd"}.fa-soundcloud:before{content:"\f1be"}.fa-database:before{content:"\f1c0"}.fa-file-pdf-o:before{content:"\f1c1"}.fa-file-word-o:before{content:"\f1c2"}.fa-file-excel-o:before{content:"\f1c3"}.fa-file-powerpoint-o:before{content:"\f1c4"}.fa-file-photo-o:before,.fa-file-picture-o:before,.fa-file-image-o:before{content:"\f1c5"}.fa-file-zip-o:before,.fa-file-archive-o:before{content:"\f1c6"}.fa-file-sound-o:before,.fa-file-audio-o:before{content:"\f1c7"}.fa-file-movie-o:before,.fa-file-video-o:before{content:"\f1c8"}.fa-file-code-o:before{content:"\f1c9"}.fa-vine:before{content:"\f1ca"}.fa-codepen:before{content:"\f1cb"}.fa-jsfiddle:before{content:"\f1cc"}.fa-life-bouy:before,.fa-life-buoy:before,.fa-life-saver:before,.fa-support:before,.fa-life-ring:before{content:"\f1cd"}.fa-circle-o-notch:before{content:"\f1ce"}.fa-ra:before,.fa-resistance:before,.fa-rebel:before{content:"\f1d0"}.fa-ge:before,.fa-empire:before{content:"\f1d1"}.fa-git-square:before{content:"\f1d2"}.fa-git:before{content:"\f1d3"}.fa-y-combinator-square:before,.fa-yc-square:before,.fa-hacker-news:before{content:"\f1d4"}.fa-tencent-weibo:before{content:"\f1d5"}.fa-qq:before{content:"\f1d6"}.fa-wechat:before,.fa-weixin:before{content:"\f1d7"}.fa-send:before,.fa-paper-plane:before{content:"\f1d8"}.fa-send-o:before,.fa-paper-plane-o:before{content:"\f1d9"}.fa-history:before{content:"\f1da"}.fa-circle-thin:before{content:"\f1db"}.fa-header:before{content:"\f1dc"}.fa-paragraph:before{content:"\f1dd"}.fa-sliders:before{content:"\f1de"}.fa-share-alt:before{content:"\f1e0"}.fa-share-alt-square:before{content:"\f1e1"}.fa-bomb:before{content:"\f1e2"}.fa-soccer-ball-o:before,.fa-futbol-o:before{content:"\f1e3"}.fa-tty:before{content:"\f1e4"}.fa-binoculars:before{content:"\f1e5"}.fa-plug:before{content:"\f1e6"}.fa-slideshare:before{content:"\f1e7"}.fa-twitch:before{content:"\f1e8"}.fa-yelp:before{content:"\f1e9"}.fa-newspaper-o:before{content:"\f1ea"}.fa-wifi:before{content:"\f1eb"}.fa-calculator:before{content:"\f1ec"}.fa-paypal:before{content:"\f1ed"}.fa-google-wallet:before{content:"\f1ee"}.fa-cc-visa:before{content:"\f1f0"}.fa-cc-mastercard:before{content:"\f1f1"}.fa-cc-discover:before{content:"\f1f2"}.fa-cc-amex:before{content:"\f1f3"}.fa-cc-paypal:before{content:"\f1f4"}.fa-cc-stripe:before{content:"\f1f5"}.fa-bell-slash:before{content:"\f1f6"}.fa-bell-slash-o:before{content:"\f1f7"}.fa-trash:before{content:"\f1f8"}.fa-copyright:before{content:"\f1f9"}.fa-at:before{content:"\f1fa"}.fa-eyedropper:before{content:"\f1fb"}.fa-paint-brush:before{content:"\f1fc"}.fa-birthday-cake:before{content:"\f1fd"}.fa-area-chart:before{content:"\f1fe"}.fa-pie-chart:before{content:"\f200"}.fa-line-chart:before{content:"\f201"}.fa-lastfm:before{content:"\f202"}.fa-lastfm-square:before{content:"\f203"}.fa-toggle-off:before{content:"\f204"}.fa-toggle-on:before{content:"\f205"}.fa-bicycle:before{content:"\f206"}.fa-bus:before{content:"\f207"}.fa-ioxhost:before{content:"\f208"}.fa-angellist:before{content:"\f209"}.fa-cc:before{content:"\f20a"}.fa-shekel:before,.fa-sheqel:before,.fa-ils:before{content:"\f20b"}.fa-meanpath:before{content:"\f20c"}.fa-buysellads:before{content:"\f20d"}.fa-connectdevelop:before{content:"\f20e"}.fa-dashcube:before{content:"\f210"}.fa-forumbee:before{content:"\f211"}.fa-leanpub:before{content:"\f212"}.fa-sellsy:before{content:"\f213"}.fa-shirtsinbulk:before{content:"\f214"}.fa-simplybuilt:before{content:"\f215"}.fa-skyatlas:before{content:"\f216"}.fa-cart-plus:before{content:"\f217"}.fa-cart-arrow-down:before{content:"\f218"}.fa-diamond:before{content:"\f219"}.fa-ship:before{content:"\f21a"}.fa-user-secret:before{content:"\f21b"}.fa-motorcycle:before{content:"\f21c"}.fa-street-view:before{content:"\f21d"}.fa-heartbeat:before{content:"\f21e"}.fa-venus:before{content:"\f221"}.fa-mars:before{content:"\f222"}.fa-mercury:before{content:"\f223"}.fa-intersex:before,.fa-transgender:before{content:"\f224"}.fa-transgender-alt:before{content:"\f225"}.fa-venus-double:before{content:"\f226"}.fa-mars-double:before{content:"\f227"}.fa-venus-mars:before{content:"\f228"}.fa-mars-stroke:before{content:"\f229"}.fa-mars-stroke-v:before{content:"\f22a"}.fa-mars-stroke-h:before{content:"\f22b"}.fa-neuter:before{content:"\f22c"}.fa-genderless:before{content:"\f22d"}.fa-facebook-official:before{content:"\f230"}.fa-pinterest-p:before{content:"\f231"}.fa-whatsapp:before{content:"\f232"}.fa-server:before{content:"\f233"}.fa-user-plus:before{content:"\f234"}.fa-user-times:before{content:"\f235"}.fa-hotel:before,.fa-bed:before{content:"\f236"}.fa-viacoin:before{content:"\f237"}.fa-train:before{content:"\f238"}.fa-subway:before{content:"\f239"}.fa-medium:before{content:"\f23a"}.fa-yc:before,.fa-y-combinator:before{content:"\f23b"}.fa-optin-monster:before{content:"\f23c"}.fa-opencart:before{content:"\f23d"}.fa-expeditedssl:before{content:"\f23e"}.fa-battery-4:before,.fa-battery:before,.fa-battery-full:before{content:"\f240"}.fa-battery-3:before,.fa-battery-three-quarters:before{content:"\f241"}.fa-battery-2:before,.fa-battery-half:before{content:"\f242"}.fa-battery-1:before,.fa-battery-quarter:before{content:"\f243"}.fa-battery-0:before,.fa-battery-empty:before{content:"\f244"}.fa-mouse-pointer:before{content:"\f245"}.fa-i-cursor:before{content:"\f246"}.fa-object-group:before{content:"\f247"}.fa-object-ungroup:before{content:"\f248"}.fa-sticky-note:before{content:"\f249"}.fa-sticky-note-o:before{content:"\f24a"}.fa-cc-jcb:before{content:"\f24b"}.fa-cc-diners-club:before{content:"\f24c"}.fa-clone:before{content:"\f24d"}.fa-balance-scale:before{content:"\f24e"}.fa-hourglass-o:before{content:"\f250"}.fa-hourglass-1:before,.fa-hourglass-start:before{content:"\f251"}.fa-hourglass-2:before,.fa-hourglass-half:before{content:"\f252"}.fa-hourglass-3:before,.fa-hourglass-end:before{content:"\f253"}.fa-hourglass:before{content:"\f254"}.fa-hand-grab-o:before,.fa-hand-rock-o:before{content:"\f255"}.fa-hand-stop-o:before,.fa-hand-paper-o:before{content:"\f256"}.fa-hand-scissors-o:before{content:"\f257"}.fa-hand-lizard-o:before{content:"\f258"}.fa-hand-spock-o:before{content:"\f259"}.fa-hand-pointer-o:before{content:"\f25a"}.fa-hand-peace-o:before{content:"\f25b"}.fa-trademark:before{content:"\f25c"}.fa-registered:before{content:"\f25d"}.fa-creative-commons:before{content:"\f25e"}.fa-gg:before{content:"\f260"}.fa-gg-circle:before{content:"\f261"}.fa-tripadvisor:before{content:"\f262"}.fa-odnoklassniki:before{content:"\f263"}.fa-odnoklassniki-square:before{content:"\f264"}.fa-get-pocket:before{content:"\f265"}.fa-wikipedia-w:before{content:"\f266"}.fa-safari:before{content:"\f267"}.fa-chrome:before{content:"\f268"}.fa-firefox:before{content:"\f269"}.fa-opera:before{content:"\f26a"}.fa-internet-explorer:before{content:"\f26b"}.fa-tv:before,.fa-television:before{content:"\f26c"}.fa-contao:before{content:"\f26d"}.fa-500px:before{content:"\f26e"}.fa-amazon:before{content:"\f270"}.fa-calendar-plus-o:before{content:"\f271"}.fa-calendar-minus-o:before{content:"\f272"}.fa-calendar-times-o:before{content:"\f273"}.fa-calendar-check-o:before{content:"\f274"}.fa-industry:before{content:"\f275"}.fa-map-pin:before{content:"\f276"}.fa-map-signs:before{content:"\f277"}.fa-map-o:before{content:"\f278"}.fa-map:before{content:"\f279"}.fa-commenting:before{content:"\f27a"}.fa-commenting-o:before{content:"\f27b"}.fa-houzz:before{content:"\f27c"}.fa-vimeo:before{content:"\f27d"}.fa-black-tie:before{content:"\f27e"}.fa-fonticons:before{content:"\f280"}.fa-reddit-alien:before{content:"\f281"}.fa-edge:before{content:"\f282"}.fa-credit-card-alt:before{content:"\f283"}.fa-codiepie:before{content:"\f284"}.fa-modx:before{content:"\f285"}.fa-fort-awesome:before{content:"\f286"}.fa-usb:before{content:"\f287"}.fa-product-hunt:before{content:"\f288"}.fa-mixcloud:before{content:"\f289"}.fa-scribd:before{content:"\f28a"}.fa-pause-circle:before{content:"\f28b"}.fa-pause-circle-o:before{content:"\f28c"}.fa-stop-circle:before{content:"\f28d"}.fa-stop-circle-o:before{content:"\f28e"}.fa-shopping-bag:before{content:"\f290"}.fa-shopping-basket:before{content:"\f291"}.fa-hashtag:before{content:"\f292"}.fa-bluetooth:before{content:"\f293"}.fa-bluetooth-b:before{content:"\f294"}.fa-percent:before{content:"\f295"}.fa-gitlab:before{content:"\f296"}.fa-wpbeginner:before{content:"\f297"}.fa-wpforms:before{content:"\f298"}.fa-envira:before{content:"\f299"}.fa-universal-access:before{content:"\f29a"}.fa-wheelchair-alt:before{content:"\f29b"}.fa-question-circle-o:before{content:"\f29c"}.fa-blind:before{content:"\f29d"}.fa-audio-description:before{content:"\f29e"}.fa-volume-control-phone:before{content:"\f2a0"}.fa-braille:before{content:"\f2a1"}.fa-assistive-listening-systems:before{content:"\f2a2"}.fa-asl-interpreting:before,.fa-american-sign-language-interpreting:before{content:"\f2a3"}.fa-deafness:before,.fa-hard-of-hearing:before,.fa-deaf:before{content:"\f2a4"}.fa-glide:before{content:"\f2a5"}.fa-glide-g:before{content:"\f2a6"}.fa-signing:before,.fa-sign-language:before{content:"\f2a7"}.fa-low-vision:before{content:"\f2a8"}.fa-viadeo:before{content:"\f2a9"}.fa-viadeo-square:before{content:"\f2aa"}.fa-snapchat:before{content:"\f2ab"}.fa-snapchat-ghost:before{content:"\f2ac"}.fa-snapchat-square:before{content:"\f2ad"}.fa-pied-piper:before{content:"\f2ae"}.fa-first-order:before{content:"\f2b0"}.fa-yoast:before{content:"\f2b1"}.fa-themeisle:before{content:"\f2b2"}.fa-google-plus-circle:before,.fa-google-plus-official:before{content:"\f2b3"}.fa-fa:before,.fa-font-awesome:before{content:"\f2b4"}.fa-handshake-o:before{content:"\f2b5"}.fa-envelope-open:before{content:"\f2b6"}.fa-envelope-open-o:before{content:"\f2b7"}.fa-linode:before{content:"\f2b8"}.fa-address-book:before{content:"\f2b9"}.fa-address-book-o:before{content:"\f2ba"}.fa-vcard:before,.fa-address-card:before{content:"\f2bb"}.fa-vcard-o:before,.fa-address-card-o:before{content:"\f2bc"}.fa-user-circle:before{content:"\f2bd"}.fa-user-circle-o:before{content:"\f2be"}.fa-user-o:before{content:"\f2c0"}.fa-id-badge:before{content:"\f2c1"}.fa-drivers-license:before,.fa-id-card:before{content:"\f2c2"}.fa-drivers-license-o:before,.fa-id-card-o:before{content:"\f2c3"}.fa-quora:before{content:"\f2c4"}.fa-free-code-camp:before{content:"\f2c5"}.fa-telegram:before{content:"\f2c6"}.fa-thermometer-4:before,.fa-thermometer:before,.fa-thermometer-full:before{content:"\f2c7"}.fa-thermometer-3:before,.fa-thermometer-three-quarters:before{content:"\f2c8"}.fa-thermometer-2:before,.fa-thermometer-half:before{content:"\f2c9"}.fa-thermometer-1:before,.fa-thermometer-quarter:before{content:"\f2ca"}.fa-thermometer-0:before,.fa-thermometer-empty:before{content:"\f2cb"}.fa-shower:before{content:"\f2cc"}.fa-bathtub:before,.fa-s15:before,.fa-bath:before{content:"\f2cd"}.fa-podcast:before{content:"\f2ce"}.fa-window-maximize:before{content:"\f2d0"}.fa-window-minimize:before{content:"\f2d1"}.fa-window-restore:before{content:"\f2d2"}.fa-times-rectangle:before,.fa-window-close:before{content:"\f2d3"}.fa-times-rectangle-o:before,.fa-window-close-o:before{content:"\f2d4"}.fa-bandcamp:before{content:"\f2d5"}.fa-grav:before{content:"\f2d6"}.fa-etsy:before{content:"\f2d7"}.fa-imdb:before{content:"\f2d8"}.fa-ravelry:before{content:"\f2d9"}.fa-eercast:before{content:"\f2da"}.fa-microchip:before{content:"\f2db"}.fa-snowflake-o:before{content:"\f2dc"}.fa-superpowers:before{content:"\f2dd"}.fa-wpexplorer:before{content:"\f2de"}.fa-meetup:before{content:"\f2e0"}.sr-only{position:absolute;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip:rect(0, 0, 0, 0);border:0}.sr-only-focusable:active,.sr-only-focusable:focus{position:static;width:auto;height:auto;margin:0;overflow:visible;clip:auto} diff --git a/software/dashboard/grafana/csv/Node-RED_files/gridstack-extra.min.css b/software/dashboard/grafana/csv/Node-RED_files/gridstack-extra.min.css new file mode 100644 index 0000000..f3fd946 --- /dev/null +++ b/software/dashboard/grafana/csv/Node-RED_files/gridstack-extra.min.css @@ -0,0 +1,6 @@ +/*! + * gridstack 0.6.3-dev extra CSS for [2-11] columns (non default) + * https://gridstackjs.com/ + * (c) 2014-2020 Alain Dumesny, Dylan Weiss, Pavel Reznikov + * gridstack.js may be freely distributed under the MIT license. +*/.grid-stack.grid-stack-2>.grid-stack-item{min-width:50%}.grid-stack.grid-stack-2>.grid-stack-item[data-gs-width="1"]{width:50%}.grid-stack.grid-stack-2>.grid-stack-item[data-gs-x="1"]{left:50%}.grid-stack.grid-stack-2>.grid-stack-item[data-gs-min-width="1"]{min-width:50%}.grid-stack.grid-stack-2>.grid-stack-item[data-gs-max-width="1"]{max-width:50%}.grid-stack.grid-stack-2>.grid-stack-item[data-gs-width="2"]{width:100%}.grid-stack.grid-stack-2>.grid-stack-item[data-gs-x="2"]{left:100%}.grid-stack.grid-stack-2>.grid-stack-item[data-gs-min-width="2"]{min-width:100%}.grid-stack.grid-stack-2>.grid-stack-item[data-gs-max-width="2"]{max-width:100%}.grid-stack.grid-stack-3>.grid-stack-item{min-width:33.3333333333%}.grid-stack.grid-stack-3>.grid-stack-item[data-gs-width="1"]{width:33.3333333333%}.grid-stack.grid-stack-3>.grid-stack-item[data-gs-x="1"]{left:33.3333333333%}.grid-stack.grid-stack-3>.grid-stack-item[data-gs-min-width="1"]{min-width:33.3333333333%}.grid-stack.grid-stack-3>.grid-stack-item[data-gs-max-width="1"]{max-width:33.3333333333%}.grid-stack.grid-stack-3>.grid-stack-item[data-gs-width="2"]{width:66.6666666667%}.grid-stack.grid-stack-3>.grid-stack-item[data-gs-x="2"]{left:66.6666666667%}.grid-stack.grid-stack-3>.grid-stack-item[data-gs-min-width="2"]{min-width:66.6666666667%}.grid-stack.grid-stack-3>.grid-stack-item[data-gs-max-width="2"]{max-width:66.6666666667%}.grid-stack.grid-stack-3>.grid-stack-item[data-gs-width="3"]{width:100%}.grid-stack.grid-stack-3>.grid-stack-item[data-gs-x="3"]{left:100%}.grid-stack.grid-stack-3>.grid-stack-item[data-gs-min-width="3"]{min-width:100%}.grid-stack.grid-stack-3>.grid-stack-item[data-gs-max-width="3"]{max-width:100%}.grid-stack.grid-stack-4>.grid-stack-item{min-width:25%}.grid-stack.grid-stack-4>.grid-stack-item[data-gs-width="1"]{width:25%}.grid-stack.grid-stack-4>.grid-stack-item[data-gs-x="1"]{left:25%}.grid-stack.grid-stack-4>.grid-stack-item[data-gs-min-width="1"]{min-width:25%}.grid-stack.grid-stack-4>.grid-stack-item[data-gs-max-width="1"]{max-width:25%}.grid-stack.grid-stack-4>.grid-stack-item[data-gs-width="2"]{width:50%}.grid-stack.grid-stack-4>.grid-stack-item[data-gs-x="2"]{left:50%}.grid-stack.grid-stack-4>.grid-stack-item[data-gs-min-width="2"]{min-width:50%}.grid-stack.grid-stack-4>.grid-stack-item[data-gs-max-width="2"]{max-width:50%}.grid-stack.grid-stack-4>.grid-stack-item[data-gs-width="3"]{width:75%}.grid-stack.grid-stack-4>.grid-stack-item[data-gs-x="3"]{left:75%}.grid-stack.grid-stack-4>.grid-stack-item[data-gs-min-width="3"]{min-width:75%}.grid-stack.grid-stack-4>.grid-stack-item[data-gs-max-width="3"]{max-width:75%}.grid-stack.grid-stack-4>.grid-stack-item[data-gs-width="4"]{width:100%}.grid-stack.grid-stack-4>.grid-stack-item[data-gs-x="4"]{left:100%}.grid-stack.grid-stack-4>.grid-stack-item[data-gs-min-width="4"]{min-width:100%}.grid-stack.grid-stack-4>.grid-stack-item[data-gs-max-width="4"]{max-width:100%}.grid-stack.grid-stack-5>.grid-stack-item{min-width:20%}.grid-stack.grid-stack-5>.grid-stack-item[data-gs-width="1"]{width:20%}.grid-stack.grid-stack-5>.grid-stack-item[data-gs-x="1"]{left:20%}.grid-stack.grid-stack-5>.grid-stack-item[data-gs-min-width="1"]{min-width:20%}.grid-stack.grid-stack-5>.grid-stack-item[data-gs-max-width="1"]{max-width:20%}.grid-stack.grid-stack-5>.grid-stack-item[data-gs-width="2"]{width:40%}.grid-stack.grid-stack-5>.grid-stack-item[data-gs-x="2"]{left:40%}.grid-stack.grid-stack-5>.grid-stack-item[data-gs-min-width="2"]{min-width:40%}.grid-stack.grid-stack-5>.grid-stack-item[data-gs-max-width="2"]{max-width:40%}.grid-stack.grid-stack-5>.grid-stack-item[data-gs-width="3"]{width:60%}.grid-stack.grid-stack-5>.grid-stack-item[data-gs-x="3"]{left:60%}.grid-stack.grid-stack-5>.grid-stack-item[data-gs-min-width="3"]{min-width:60%}.grid-stack.grid-stack-5>.grid-stack-item[data-gs-max-width="3"]{max-width:60%}.grid-stack.grid-stack-5>.grid-stack-item[data-gs-width="4"]{width:80%}.grid-stack.grid-stack-5>.grid-stack-item[data-gs-x="4"]{left:80%}.grid-stack.grid-stack-5>.grid-stack-item[data-gs-min-width="4"]{min-width:80%}.grid-stack.grid-stack-5>.grid-stack-item[data-gs-max-width="4"]{max-width:80%}.grid-stack.grid-stack-5>.grid-stack-item[data-gs-width="5"]{width:100%}.grid-stack.grid-stack-5>.grid-stack-item[data-gs-x="5"]{left:100%}.grid-stack.grid-stack-5>.grid-stack-item[data-gs-min-width="5"]{min-width:100%}.grid-stack.grid-stack-5>.grid-stack-item[data-gs-max-width="5"]{max-width:100%}.grid-stack.grid-stack-6>.grid-stack-item{min-width:16.6666666667%}.grid-stack.grid-stack-6>.grid-stack-item[data-gs-width="1"]{width:16.6666666667%}.grid-stack.grid-stack-6>.grid-stack-item[data-gs-x="1"]{left:16.6666666667%}.grid-stack.grid-stack-6>.grid-stack-item[data-gs-min-width="1"]{min-width:16.6666666667%}.grid-stack.grid-stack-6>.grid-stack-item[data-gs-max-width="1"]{max-width:16.6666666667%}.grid-stack.grid-stack-6>.grid-stack-item[data-gs-width="2"]{width:33.3333333333%}.grid-stack.grid-stack-6>.grid-stack-item[data-gs-x="2"]{left:33.3333333333%}.grid-stack.grid-stack-6>.grid-stack-item[data-gs-min-width="2"]{min-width:33.3333333333%}.grid-stack.grid-stack-6>.grid-stack-item[data-gs-max-width="2"]{max-width:33.3333333333%}.grid-stack.grid-stack-6>.grid-stack-item[data-gs-width="3"]{width:50%}.grid-stack.grid-stack-6>.grid-stack-item[data-gs-x="3"]{left:50%}.grid-stack.grid-stack-6>.grid-stack-item[data-gs-min-width="3"]{min-width:50%}.grid-stack.grid-stack-6>.grid-stack-item[data-gs-max-width="3"]{max-width:50%}.grid-stack.grid-stack-6>.grid-stack-item[data-gs-width="4"]{width:66.6666666667%}.grid-stack.grid-stack-6>.grid-stack-item[data-gs-x="4"]{left:66.6666666667%}.grid-stack.grid-stack-6>.grid-stack-item[data-gs-min-width="4"]{min-width:66.6666666667%}.grid-stack.grid-stack-6>.grid-stack-item[data-gs-max-width="4"]{max-width:66.6666666667%}.grid-stack.grid-stack-6>.grid-stack-item[data-gs-width="5"]{width:83.3333333333%}.grid-stack.grid-stack-6>.grid-stack-item[data-gs-x="5"]{left:83.3333333333%}.grid-stack.grid-stack-6>.grid-stack-item[data-gs-min-width="5"]{min-width:83.3333333333%}.grid-stack.grid-stack-6>.grid-stack-item[data-gs-max-width="5"]{max-width:83.3333333333%}.grid-stack.grid-stack-6>.grid-stack-item[data-gs-width="6"]{width:100%}.grid-stack.grid-stack-6>.grid-stack-item[data-gs-x="6"]{left:100%}.grid-stack.grid-stack-6>.grid-stack-item[data-gs-min-width="6"]{min-width:100%}.grid-stack.grid-stack-6>.grid-stack-item[data-gs-max-width="6"]{max-width:100%}.grid-stack.grid-stack-7>.grid-stack-item{min-width:14.2857142857%}.grid-stack.grid-stack-7>.grid-stack-item[data-gs-width="1"]{width:14.2857142857%}.grid-stack.grid-stack-7>.grid-stack-item[data-gs-x="1"]{left:14.2857142857%}.grid-stack.grid-stack-7>.grid-stack-item[data-gs-min-width="1"]{min-width:14.2857142857%}.grid-stack.grid-stack-7>.grid-stack-item[data-gs-max-width="1"]{max-width:14.2857142857%}.grid-stack.grid-stack-7>.grid-stack-item[data-gs-width="2"]{width:28.5714285714%}.grid-stack.grid-stack-7>.grid-stack-item[data-gs-x="2"]{left:28.5714285714%}.grid-stack.grid-stack-7>.grid-stack-item[data-gs-min-width="2"]{min-width:28.5714285714%}.grid-stack.grid-stack-7>.grid-stack-item[data-gs-max-width="2"]{max-width:28.5714285714%}.grid-stack.grid-stack-7>.grid-stack-item[data-gs-width="3"]{width:42.8571428571%}.grid-stack.grid-stack-7>.grid-stack-item[data-gs-x="3"]{left:42.8571428571%}.grid-stack.grid-stack-7>.grid-stack-item[data-gs-min-width="3"]{min-width:42.8571428571%}.grid-stack.grid-stack-7>.grid-stack-item[data-gs-max-width="3"]{max-width:42.8571428571%}.grid-stack.grid-stack-7>.grid-stack-item[data-gs-width="4"]{width:57.1428571429%}.grid-stack.grid-stack-7>.grid-stack-item[data-gs-x="4"]{left:57.1428571429%}.grid-stack.grid-stack-7>.grid-stack-item[data-gs-min-width="4"]{min-width:57.1428571429%}.grid-stack.grid-stack-7>.grid-stack-item[data-gs-max-width="4"]{max-width:57.1428571429%}.grid-stack.grid-stack-7>.grid-stack-item[data-gs-width="5"]{width:71.4285714286%}.grid-stack.grid-stack-7>.grid-stack-item[data-gs-x="5"]{left:71.4285714286%}.grid-stack.grid-stack-7>.grid-stack-item[data-gs-min-width="5"]{min-width:71.4285714286%}.grid-stack.grid-stack-7>.grid-stack-item[data-gs-max-width="5"]{max-width:71.4285714286%}.grid-stack.grid-stack-7>.grid-stack-item[data-gs-width="6"]{width:85.7142857143%}.grid-stack.grid-stack-7>.grid-stack-item[data-gs-x="6"]{left:85.7142857143%}.grid-stack.grid-stack-7>.grid-stack-item[data-gs-min-width="6"]{min-width:85.7142857143%}.grid-stack.grid-stack-7>.grid-stack-item[data-gs-max-width="6"]{max-width:85.7142857143%}.grid-stack.grid-stack-7>.grid-stack-item[data-gs-width="7"]{width:100%}.grid-stack.grid-stack-7>.grid-stack-item[data-gs-x="7"]{left:100%}.grid-stack.grid-stack-7>.grid-stack-item[data-gs-min-width="7"]{min-width:100%}.grid-stack.grid-stack-7>.grid-stack-item[data-gs-max-width="7"]{max-width:100%}.grid-stack.grid-stack-8>.grid-stack-item{min-width:12.5%}.grid-stack.grid-stack-8>.grid-stack-item[data-gs-width="1"]{width:12.5%}.grid-stack.grid-stack-8>.grid-stack-item[data-gs-x="1"]{left:12.5%}.grid-stack.grid-stack-8>.grid-stack-item[data-gs-min-width="1"]{min-width:12.5%}.grid-stack.grid-stack-8>.grid-stack-item[data-gs-max-width="1"]{max-width:12.5%}.grid-stack.grid-stack-8>.grid-stack-item[data-gs-width="2"]{width:25%}.grid-stack.grid-stack-8>.grid-stack-item[data-gs-x="2"]{left:25%}.grid-stack.grid-stack-8>.grid-stack-item[data-gs-min-width="2"]{min-width:25%}.grid-stack.grid-stack-8>.grid-stack-item[data-gs-max-width="2"]{max-width:25%}.grid-stack.grid-stack-8>.grid-stack-item[data-gs-width="3"]{width:37.5%}.grid-stack.grid-stack-8>.grid-stack-item[data-gs-x="3"]{left:37.5%}.grid-stack.grid-stack-8>.grid-stack-item[data-gs-min-width="3"]{min-width:37.5%}.grid-stack.grid-stack-8>.grid-stack-item[data-gs-max-width="3"]{max-width:37.5%}.grid-stack.grid-stack-8>.grid-stack-item[data-gs-width="4"]{width:50%}.grid-stack.grid-stack-8>.grid-stack-item[data-gs-x="4"]{left:50%}.grid-stack.grid-stack-8>.grid-stack-item[data-gs-min-width="4"]{min-width:50%}.grid-stack.grid-stack-8>.grid-stack-item[data-gs-max-width="4"]{max-width:50%}.grid-stack.grid-stack-8>.grid-stack-item[data-gs-width="5"]{width:62.5%}.grid-stack.grid-stack-8>.grid-stack-item[data-gs-x="5"]{left:62.5%}.grid-stack.grid-stack-8>.grid-stack-item[data-gs-min-width="5"]{min-width:62.5%}.grid-stack.grid-stack-8>.grid-stack-item[data-gs-max-width="5"]{max-width:62.5%}.grid-stack.grid-stack-8>.grid-stack-item[data-gs-width="6"]{width:75%}.grid-stack.grid-stack-8>.grid-stack-item[data-gs-x="6"]{left:75%}.grid-stack.grid-stack-8>.grid-stack-item[data-gs-min-width="6"]{min-width:75%}.grid-stack.grid-stack-8>.grid-stack-item[data-gs-max-width="6"]{max-width:75%}.grid-stack.grid-stack-8>.grid-stack-item[data-gs-width="7"]{width:87.5%}.grid-stack.grid-stack-8>.grid-stack-item[data-gs-x="7"]{left:87.5%}.grid-stack.grid-stack-8>.grid-stack-item[data-gs-min-width="7"]{min-width:87.5%}.grid-stack.grid-stack-8>.grid-stack-item[data-gs-max-width="7"]{max-width:87.5%}.grid-stack.grid-stack-8>.grid-stack-item[data-gs-width="8"]{width:100%}.grid-stack.grid-stack-8>.grid-stack-item[data-gs-x="8"]{left:100%}.grid-stack.grid-stack-8>.grid-stack-item[data-gs-min-width="8"]{min-width:100%}.grid-stack.grid-stack-8>.grid-stack-item[data-gs-max-width="8"]{max-width:100%}.grid-stack.grid-stack-9>.grid-stack-item{min-width:11.1111111111%}.grid-stack.grid-stack-9>.grid-stack-item[data-gs-width="1"]{width:11.1111111111%}.grid-stack.grid-stack-9>.grid-stack-item[data-gs-x="1"]{left:11.1111111111%}.grid-stack.grid-stack-9>.grid-stack-item[data-gs-min-width="1"]{min-width:11.1111111111%}.grid-stack.grid-stack-9>.grid-stack-item[data-gs-max-width="1"]{max-width:11.1111111111%}.grid-stack.grid-stack-9>.grid-stack-item[data-gs-width="2"]{width:22.2222222222%}.grid-stack.grid-stack-9>.grid-stack-item[data-gs-x="2"]{left:22.2222222222%}.grid-stack.grid-stack-9>.grid-stack-item[data-gs-min-width="2"]{min-width:22.2222222222%}.grid-stack.grid-stack-9>.grid-stack-item[data-gs-max-width="2"]{max-width:22.2222222222%}.grid-stack.grid-stack-9>.grid-stack-item[data-gs-width="3"]{width:33.3333333333%}.grid-stack.grid-stack-9>.grid-stack-item[data-gs-x="3"]{left:33.3333333333%}.grid-stack.grid-stack-9>.grid-stack-item[data-gs-min-width="3"]{min-width:33.3333333333%}.grid-stack.grid-stack-9>.grid-stack-item[data-gs-max-width="3"]{max-width:33.3333333333%}.grid-stack.grid-stack-9>.grid-stack-item[data-gs-width="4"]{width:44.4444444444%}.grid-stack.grid-stack-9>.grid-stack-item[data-gs-x="4"]{left:44.4444444444%}.grid-stack.grid-stack-9>.grid-stack-item[data-gs-min-width="4"]{min-width:44.4444444444%}.grid-stack.grid-stack-9>.grid-stack-item[data-gs-max-width="4"]{max-width:44.4444444444%}.grid-stack.grid-stack-9>.grid-stack-item[data-gs-width="5"]{width:55.5555555556%}.grid-stack.grid-stack-9>.grid-stack-item[data-gs-x="5"]{left:55.5555555556%}.grid-stack.grid-stack-9>.grid-stack-item[data-gs-min-width="5"]{min-width:55.5555555556%}.grid-stack.grid-stack-9>.grid-stack-item[data-gs-max-width="5"]{max-width:55.5555555556%}.grid-stack.grid-stack-9>.grid-stack-item[data-gs-width="6"]{width:66.6666666667%}.grid-stack.grid-stack-9>.grid-stack-item[data-gs-x="6"]{left:66.6666666667%}.grid-stack.grid-stack-9>.grid-stack-item[data-gs-min-width="6"]{min-width:66.6666666667%}.grid-stack.grid-stack-9>.grid-stack-item[data-gs-max-width="6"]{max-width:66.6666666667%}.grid-stack.grid-stack-9>.grid-stack-item[data-gs-width="7"]{width:77.7777777778%}.grid-stack.grid-stack-9>.grid-stack-item[data-gs-x="7"]{left:77.7777777778%}.grid-stack.grid-stack-9>.grid-stack-item[data-gs-min-width="7"]{min-width:77.7777777778%}.grid-stack.grid-stack-9>.grid-stack-item[data-gs-max-width="7"]{max-width:77.7777777778%}.grid-stack.grid-stack-9>.grid-stack-item[data-gs-width="8"]{width:88.8888888889%}.grid-stack.grid-stack-9>.grid-stack-item[data-gs-x="8"]{left:88.8888888889%}.grid-stack.grid-stack-9>.grid-stack-item[data-gs-min-width="8"]{min-width:88.8888888889%}.grid-stack.grid-stack-9>.grid-stack-item[data-gs-max-width="8"]{max-width:88.8888888889%}.grid-stack.grid-stack-9>.grid-stack-item[data-gs-width="9"]{width:100%}.grid-stack.grid-stack-9>.grid-stack-item[data-gs-x="9"]{left:100%}.grid-stack.grid-stack-9>.grid-stack-item[data-gs-min-width="9"]{min-width:100%}.grid-stack.grid-stack-9>.grid-stack-item[data-gs-max-width="9"]{max-width:100%}.grid-stack.grid-stack-10>.grid-stack-item{min-width:10%}.grid-stack.grid-stack-10>.grid-stack-item[data-gs-width="1"]{width:10%}.grid-stack.grid-stack-10>.grid-stack-item[data-gs-x="1"]{left:10%}.grid-stack.grid-stack-10>.grid-stack-item[data-gs-min-width="1"]{min-width:10%}.grid-stack.grid-stack-10>.grid-stack-item[data-gs-max-width="1"]{max-width:10%}.grid-stack.grid-stack-10>.grid-stack-item[data-gs-width="2"]{width:20%}.grid-stack.grid-stack-10>.grid-stack-item[data-gs-x="2"]{left:20%}.grid-stack.grid-stack-10>.grid-stack-item[data-gs-min-width="2"]{min-width:20%}.grid-stack.grid-stack-10>.grid-stack-item[data-gs-max-width="2"]{max-width:20%}.grid-stack.grid-stack-10>.grid-stack-item[data-gs-width="3"]{width:30%}.grid-stack.grid-stack-10>.grid-stack-item[data-gs-x="3"]{left:30%}.grid-stack.grid-stack-10>.grid-stack-item[data-gs-min-width="3"]{min-width:30%}.grid-stack.grid-stack-10>.grid-stack-item[data-gs-max-width="3"]{max-width:30%}.grid-stack.grid-stack-10>.grid-stack-item[data-gs-width="4"]{width:40%}.grid-stack.grid-stack-10>.grid-stack-item[data-gs-x="4"]{left:40%}.grid-stack.grid-stack-10>.grid-stack-item[data-gs-min-width="4"]{min-width:40%}.grid-stack.grid-stack-10>.grid-stack-item[data-gs-max-width="4"]{max-width:40%}.grid-stack.grid-stack-10>.grid-stack-item[data-gs-width="5"]{width:50%}.grid-stack.grid-stack-10>.grid-stack-item[data-gs-x="5"]{left:50%}.grid-stack.grid-stack-10>.grid-stack-item[data-gs-min-width="5"]{min-width:50%}.grid-stack.grid-stack-10>.grid-stack-item[data-gs-max-width="5"]{max-width:50%}.grid-stack.grid-stack-10>.grid-stack-item[data-gs-width="6"]{width:60%}.grid-stack.grid-stack-10>.grid-stack-item[data-gs-x="6"]{left:60%}.grid-stack.grid-stack-10>.grid-stack-item[data-gs-min-width="6"]{min-width:60%}.grid-stack.grid-stack-10>.grid-stack-item[data-gs-max-width="6"]{max-width:60%}.grid-stack.grid-stack-10>.grid-stack-item[data-gs-width="7"]{width:70%}.grid-stack.grid-stack-10>.grid-stack-item[data-gs-x="7"]{left:70%}.grid-stack.grid-stack-10>.grid-stack-item[data-gs-min-width="7"]{min-width:70%}.grid-stack.grid-stack-10>.grid-stack-item[data-gs-max-width="7"]{max-width:70%}.grid-stack.grid-stack-10>.grid-stack-item[data-gs-width="8"]{width:80%}.grid-stack.grid-stack-10>.grid-stack-item[data-gs-x="8"]{left:80%}.grid-stack.grid-stack-10>.grid-stack-item[data-gs-min-width="8"]{min-width:80%}.grid-stack.grid-stack-10>.grid-stack-item[data-gs-max-width="8"]{max-width:80%}.grid-stack.grid-stack-10>.grid-stack-item[data-gs-width="9"]{width:90%}.grid-stack.grid-stack-10>.grid-stack-item[data-gs-x="9"]{left:90%}.grid-stack.grid-stack-10>.grid-stack-item[data-gs-min-width="9"]{min-width:90%}.grid-stack.grid-stack-10>.grid-stack-item[data-gs-max-width="9"]{max-width:90%}.grid-stack.grid-stack-10>.grid-stack-item[data-gs-width="10"]{width:100%}.grid-stack.grid-stack-10>.grid-stack-item[data-gs-x="10"]{left:100%}.grid-stack.grid-stack-10>.grid-stack-item[data-gs-min-width="10"]{min-width:100%}.grid-stack.grid-stack-10>.grid-stack-item[data-gs-max-width="10"]{max-width:100%}.grid-stack.grid-stack-11>.grid-stack-item{min-width:9.0909090909%}.grid-stack.grid-stack-11>.grid-stack-item[data-gs-width="1"]{width:9.0909090909%}.grid-stack.grid-stack-11>.grid-stack-item[data-gs-x="1"]{left:9.0909090909%}.grid-stack.grid-stack-11>.grid-stack-item[data-gs-min-width="1"]{min-width:9.0909090909%}.grid-stack.grid-stack-11>.grid-stack-item[data-gs-max-width="1"]{max-width:9.0909090909%}.grid-stack.grid-stack-11>.grid-stack-item[data-gs-width="2"]{width:18.1818181818%}.grid-stack.grid-stack-11>.grid-stack-item[data-gs-x="2"]{left:18.1818181818%}.grid-stack.grid-stack-11>.grid-stack-item[data-gs-min-width="2"]{min-width:18.1818181818%}.grid-stack.grid-stack-11>.grid-stack-item[data-gs-max-width="2"]{max-width:18.1818181818%}.grid-stack.grid-stack-11>.grid-stack-item[data-gs-width="3"]{width:27.2727272727%}.grid-stack.grid-stack-11>.grid-stack-item[data-gs-x="3"]{left:27.2727272727%}.grid-stack.grid-stack-11>.grid-stack-item[data-gs-min-width="3"]{min-width:27.2727272727%}.grid-stack.grid-stack-11>.grid-stack-item[data-gs-max-width="3"]{max-width:27.2727272727%}.grid-stack.grid-stack-11>.grid-stack-item[data-gs-width="4"]{width:36.3636363636%}.grid-stack.grid-stack-11>.grid-stack-item[data-gs-x="4"]{left:36.3636363636%}.grid-stack.grid-stack-11>.grid-stack-item[data-gs-min-width="4"]{min-width:36.3636363636%}.grid-stack.grid-stack-11>.grid-stack-item[data-gs-max-width="4"]{max-width:36.3636363636%}.grid-stack.grid-stack-11>.grid-stack-item[data-gs-width="5"]{width:45.4545454545%}.grid-stack.grid-stack-11>.grid-stack-item[data-gs-x="5"]{left:45.4545454545%}.grid-stack.grid-stack-11>.grid-stack-item[data-gs-min-width="5"]{min-width:45.4545454545%}.grid-stack.grid-stack-11>.grid-stack-item[data-gs-max-width="5"]{max-width:45.4545454545%}.grid-stack.grid-stack-11>.grid-stack-item[data-gs-width="6"]{width:54.5454545455%}.grid-stack.grid-stack-11>.grid-stack-item[data-gs-x="6"]{left:54.5454545455%}.grid-stack.grid-stack-11>.grid-stack-item[data-gs-min-width="6"]{min-width:54.5454545455%}.grid-stack.grid-stack-11>.grid-stack-item[data-gs-max-width="6"]{max-width:54.5454545455%}.grid-stack.grid-stack-11>.grid-stack-item[data-gs-width="7"]{width:63.6363636364%}.grid-stack.grid-stack-11>.grid-stack-item[data-gs-x="7"]{left:63.6363636364%}.grid-stack.grid-stack-11>.grid-stack-item[data-gs-min-width="7"]{min-width:63.6363636364%}.grid-stack.grid-stack-11>.grid-stack-item[data-gs-max-width="7"]{max-width:63.6363636364%}.grid-stack.grid-stack-11>.grid-stack-item[data-gs-width="8"]{width:72.7272727273%}.grid-stack.grid-stack-11>.grid-stack-item[data-gs-x="8"]{left:72.7272727273%}.grid-stack.grid-stack-11>.grid-stack-item[data-gs-min-width="8"]{min-width:72.7272727273%}.grid-stack.grid-stack-11>.grid-stack-item[data-gs-max-width="8"]{max-width:72.7272727273%}.grid-stack.grid-stack-11>.grid-stack-item[data-gs-width="9"]{width:81.8181818182%}.grid-stack.grid-stack-11>.grid-stack-item[data-gs-x="9"]{left:81.8181818182%}.grid-stack.grid-stack-11>.grid-stack-item[data-gs-min-width="9"]{min-width:81.8181818182%}.grid-stack.grid-stack-11>.grid-stack-item[data-gs-max-width="9"]{max-width:81.8181818182%}.grid-stack.grid-stack-11>.grid-stack-item[data-gs-width="10"]{width:90.9090909091%}.grid-stack.grid-stack-11>.grid-stack-item[data-gs-x="10"]{left:90.9090909091%}.grid-stack.grid-stack-11>.grid-stack-item[data-gs-min-width="10"]{min-width:90.9090909091%}.grid-stack.grid-stack-11>.grid-stack-item[data-gs-max-width="10"]{max-width:90.9090909091%}.grid-stack.grid-stack-11>.grid-stack-item[data-gs-width="11"]{width:100%}.grid-stack.grid-stack-11>.grid-stack-item[data-gs-x="11"]{left:100%}.grid-stack.grid-stack-11>.grid-stack-item[data-gs-min-width="11"]{min-width:100%}.grid-stack.grid-stack-11>.grid-stack-item[data-gs-max-width="11"]{max-width:100%}.grid-stack.grid-stack-12>.grid-stack-item{min-width:8.3333333333%}.grid-stack.grid-stack-12>.grid-stack-item[data-gs-width="1"]{width:8.3333333333%}.grid-stack.grid-stack-12>.grid-stack-item[data-gs-x="1"]{left:8.3333333333%}.grid-stack.grid-stack-12>.grid-stack-item[data-gs-min-width="1"]{min-width:8.3333333333%}.grid-stack.grid-stack-12>.grid-stack-item[data-gs-max-width="1"]{max-width:8.3333333333%}.grid-stack.grid-stack-12>.grid-stack-item[data-gs-width="2"]{width:16.6666666667%}.grid-stack.grid-stack-12>.grid-stack-item[data-gs-x="2"]{left:16.6666666667%}.grid-stack.grid-stack-12>.grid-stack-item[data-gs-min-width="2"]{min-width:16.6666666667%}.grid-stack.grid-stack-12>.grid-stack-item[data-gs-max-width="2"]{max-width:16.6666666667%}.grid-stack.grid-stack-12>.grid-stack-item[data-gs-width="3"]{width:25%}.grid-stack.grid-stack-12>.grid-stack-item[data-gs-x="3"]{left:25%}.grid-stack.grid-stack-12>.grid-stack-item[data-gs-min-width="3"]{min-width:25%}.grid-stack.grid-stack-12>.grid-stack-item[data-gs-max-width="3"]{max-width:25%}.grid-stack.grid-stack-12>.grid-stack-item[data-gs-width="4"]{width:33.3333333333%}.grid-stack.grid-stack-12>.grid-stack-item[data-gs-x="4"]{left:33.3333333333%}.grid-stack.grid-stack-12>.grid-stack-item[data-gs-min-width="4"]{min-width:33.3333333333%}.grid-stack.grid-stack-12>.grid-stack-item[data-gs-max-width="4"]{max-width:33.3333333333%}.grid-stack.grid-stack-12>.grid-stack-item[data-gs-width="5"]{width:41.6666666667%}.grid-stack.grid-stack-12>.grid-stack-item[data-gs-x="5"]{left:41.6666666667%}.grid-stack.grid-stack-12>.grid-stack-item[data-gs-min-width="5"]{min-width:41.6666666667%}.grid-stack.grid-stack-12>.grid-stack-item[data-gs-max-width="5"]{max-width:41.6666666667%}.grid-stack.grid-stack-12>.grid-stack-item[data-gs-width="6"]{width:50%}.grid-stack.grid-stack-12>.grid-stack-item[data-gs-x="6"]{left:50%}.grid-stack.grid-stack-12>.grid-stack-item[data-gs-min-width="6"]{min-width:50%}.grid-stack.grid-stack-12>.grid-stack-item[data-gs-max-width="6"]{max-width:50%}.grid-stack.grid-stack-12>.grid-stack-item[data-gs-width="7"]{width:58.3333333333%}.grid-stack.grid-stack-12>.grid-stack-item[data-gs-x="7"]{left:58.3333333333%}.grid-stack.grid-stack-12>.grid-stack-item[data-gs-min-width="7"]{min-width:58.3333333333%}.grid-stack.grid-stack-12>.grid-stack-item[data-gs-max-width="7"]{max-width:58.3333333333%}.grid-stack.grid-stack-12>.grid-stack-item[data-gs-width="8"]{width:66.6666666667%}.grid-stack.grid-stack-12>.grid-stack-item[data-gs-x="8"]{left:66.6666666667%}.grid-stack.grid-stack-12>.grid-stack-item[data-gs-min-width="8"]{min-width:66.6666666667%}.grid-stack.grid-stack-12>.grid-stack-item[data-gs-max-width="8"]{max-width:66.6666666667%}.grid-stack.grid-stack-12>.grid-stack-item[data-gs-width="9"]{width:75%}.grid-stack.grid-stack-12>.grid-stack-item[data-gs-x="9"]{left:75%}.grid-stack.grid-stack-12>.grid-stack-item[data-gs-min-width="9"]{min-width:75%}.grid-stack.grid-stack-12>.grid-stack-item[data-gs-max-width="9"]{max-width:75%}.grid-stack.grid-stack-12>.grid-stack-item[data-gs-width="10"]{width:83.3333333333%}.grid-stack.grid-stack-12>.grid-stack-item[data-gs-x="10"]{left:83.3333333333%}.grid-stack.grid-stack-12>.grid-stack-item[data-gs-min-width="10"]{min-width:83.3333333333%}.grid-stack.grid-stack-12>.grid-stack-item[data-gs-max-width="10"]{max-width:83.3333333333%}.grid-stack.grid-stack-12>.grid-stack-item[data-gs-width="11"]{width:91.6666666667%}.grid-stack.grid-stack-12>.grid-stack-item[data-gs-x="11"]{left:91.6666666667%}.grid-stack.grid-stack-12>.grid-stack-item[data-gs-min-width="11"]{min-width:91.6666666667%}.grid-stack.grid-stack-12>.grid-stack-item[data-gs-max-width="11"]{max-width:91.6666666667%}.grid-stack.grid-stack-12>.grid-stack-item[data-gs-width="12"]{width:100%}.grid-stack.grid-stack-12>.grid-stack-item[data-gs-x="12"]{left:100%}.grid-stack.grid-stack-12>.grid-stack-item[data-gs-min-width="12"]{min-width:100%}.grid-stack.grid-stack-12>.grid-stack-item[data-gs-max-width="12"]{max-width:100%}.grid-stack.grid-stack-13>.grid-stack-item{min-width:7.6923076923%}.grid-stack.grid-stack-13>.grid-stack-item[data-gs-width="1"]{width:7.6923076923%}.grid-stack.grid-stack-13>.grid-stack-item[data-gs-x="1"]{left:7.6923076923%}.grid-stack.grid-stack-13>.grid-stack-item[data-gs-min-width="1"]{min-width:7.6923076923%}.grid-stack.grid-stack-13>.grid-stack-item[data-gs-max-width="1"]{max-width:7.6923076923%}.grid-stack.grid-stack-13>.grid-stack-item[data-gs-width="2"]{width:15.3846153846%}.grid-stack.grid-stack-13>.grid-stack-item[data-gs-x="2"]{left:15.3846153846%}.grid-stack.grid-stack-13>.grid-stack-item[data-gs-min-width="2"]{min-width:15.3846153846%}.grid-stack.grid-stack-13>.grid-stack-item[data-gs-max-width="2"]{max-width:15.3846153846%}.grid-stack.grid-stack-13>.grid-stack-item[data-gs-width="3"]{width:23.0769230769%}.grid-stack.grid-stack-13>.grid-stack-item[data-gs-x="3"]{left:23.0769230769%}.grid-stack.grid-stack-13>.grid-stack-item[data-gs-min-width="3"]{min-width:23.0769230769%}.grid-stack.grid-stack-13>.grid-stack-item[data-gs-max-width="3"]{max-width:23.0769230769%}.grid-stack.grid-stack-13>.grid-stack-item[data-gs-width="4"]{width:30.7692307692%}.grid-stack.grid-stack-13>.grid-stack-item[data-gs-x="4"]{left:30.7692307692%}.grid-stack.grid-stack-13>.grid-stack-item[data-gs-min-width="4"]{min-width:30.7692307692%}.grid-stack.grid-stack-13>.grid-stack-item[data-gs-max-width="4"]{max-width:30.7692307692%}.grid-stack.grid-stack-13>.grid-stack-item[data-gs-width="5"]{width:38.4615384615%}.grid-stack.grid-stack-13>.grid-stack-item[data-gs-x="5"]{left:38.4615384615%}.grid-stack.grid-stack-13>.grid-stack-item[data-gs-min-width="5"]{min-width:38.4615384615%}.grid-stack.grid-stack-13>.grid-stack-item[data-gs-max-width="5"]{max-width:38.4615384615%}.grid-stack.grid-stack-13>.grid-stack-item[data-gs-width="6"]{width:46.1538461538%}.grid-stack.grid-stack-13>.grid-stack-item[data-gs-x="6"]{left:46.1538461538%}.grid-stack.grid-stack-13>.grid-stack-item[data-gs-min-width="6"]{min-width:46.1538461538%}.grid-stack.grid-stack-13>.grid-stack-item[data-gs-max-width="6"]{max-width:46.1538461538%}.grid-stack.grid-stack-13>.grid-stack-item[data-gs-width="7"]{width:53.8461538462%}.grid-stack.grid-stack-13>.grid-stack-item[data-gs-x="7"]{left:53.8461538462%}.grid-stack.grid-stack-13>.grid-stack-item[data-gs-min-width="7"]{min-width:53.8461538462%}.grid-stack.grid-stack-13>.grid-stack-item[data-gs-max-width="7"]{max-width:53.8461538462%}.grid-stack.grid-stack-13>.grid-stack-item[data-gs-width="8"]{width:61.5384615385%}.grid-stack.grid-stack-13>.grid-stack-item[data-gs-x="8"]{left:61.5384615385%}.grid-stack.grid-stack-13>.grid-stack-item[data-gs-min-width="8"]{min-width:61.5384615385%}.grid-stack.grid-stack-13>.grid-stack-item[data-gs-max-width="8"]{max-width:61.5384615385%}.grid-stack.grid-stack-13>.grid-stack-item[data-gs-width="9"]{width:69.2307692308%}.grid-stack.grid-stack-13>.grid-stack-item[data-gs-x="9"]{left:69.2307692308%}.grid-stack.grid-stack-13>.grid-stack-item[data-gs-min-width="9"]{min-width:69.2307692308%}.grid-stack.grid-stack-13>.grid-stack-item[data-gs-max-width="9"]{max-width:69.2307692308%}.grid-stack.grid-stack-13>.grid-stack-item[data-gs-width="10"]{width:76.9230769231%}.grid-stack.grid-stack-13>.grid-stack-item[data-gs-x="10"]{left:76.9230769231%}.grid-stack.grid-stack-13>.grid-stack-item[data-gs-min-width="10"]{min-width:76.9230769231%}.grid-stack.grid-stack-13>.grid-stack-item[data-gs-max-width="10"]{max-width:76.9230769231%}.grid-stack.grid-stack-13>.grid-stack-item[data-gs-width="11"]{width:84.6153846154%}.grid-stack.grid-stack-13>.grid-stack-item[data-gs-x="11"]{left:84.6153846154%}.grid-stack.grid-stack-13>.grid-stack-item[data-gs-min-width="11"]{min-width:84.6153846154%}.grid-stack.grid-stack-13>.grid-stack-item[data-gs-max-width="11"]{max-width:84.6153846154%}.grid-stack.grid-stack-13>.grid-stack-item[data-gs-width="12"]{width:92.3076923077%}.grid-stack.grid-stack-13>.grid-stack-item[data-gs-x="12"]{left:92.3076923077%}.grid-stack.grid-stack-13>.grid-stack-item[data-gs-min-width="12"]{min-width:92.3076923077%}.grid-stack.grid-stack-13>.grid-stack-item[data-gs-max-width="12"]{max-width:92.3076923077%}.grid-stack.grid-stack-13>.grid-stack-item[data-gs-width="13"]{width:100%}.grid-stack.grid-stack-13>.grid-stack-item[data-gs-x="13"]{left:100%}.grid-stack.grid-stack-13>.grid-stack-item[data-gs-min-width="13"]{min-width:100%}.grid-stack.grid-stack-13>.grid-stack-item[data-gs-max-width="13"]{max-width:100%}.grid-stack.grid-stack-14>.grid-stack-item{min-width:7.1428571429%}.grid-stack.grid-stack-14>.grid-stack-item[data-gs-width="1"]{width:7.1428571429%}.grid-stack.grid-stack-14>.grid-stack-item[data-gs-x="1"]{left:7.1428571429%}.grid-stack.grid-stack-14>.grid-stack-item[data-gs-min-width="1"]{min-width:7.1428571429%}.grid-stack.grid-stack-14>.grid-stack-item[data-gs-max-width="1"]{max-width:7.1428571429%}.grid-stack.grid-stack-14>.grid-stack-item[data-gs-width="2"]{width:14.2857142857%}.grid-stack.grid-stack-14>.grid-stack-item[data-gs-x="2"]{left:14.2857142857%}.grid-stack.grid-stack-14>.grid-stack-item[data-gs-min-width="2"]{min-width:14.2857142857%}.grid-stack.grid-stack-14>.grid-stack-item[data-gs-max-width="2"]{max-width:14.2857142857%}.grid-stack.grid-stack-14>.grid-stack-item[data-gs-width="3"]{width:21.4285714286%}.grid-stack.grid-stack-14>.grid-stack-item[data-gs-x="3"]{left:21.4285714286%}.grid-stack.grid-stack-14>.grid-stack-item[data-gs-min-width="3"]{min-width:21.4285714286%}.grid-stack.grid-stack-14>.grid-stack-item[data-gs-max-width="3"]{max-width:21.4285714286%}.grid-stack.grid-stack-14>.grid-stack-item[data-gs-width="4"]{width:28.5714285714%}.grid-stack.grid-stack-14>.grid-stack-item[data-gs-x="4"]{left:28.5714285714%}.grid-stack.grid-stack-14>.grid-stack-item[data-gs-min-width="4"]{min-width:28.5714285714%}.grid-stack.grid-stack-14>.grid-stack-item[data-gs-max-width="4"]{max-width:28.5714285714%}.grid-stack.grid-stack-14>.grid-stack-item[data-gs-width="5"]{width:35.7142857143%}.grid-stack.grid-stack-14>.grid-stack-item[data-gs-x="5"]{left:35.7142857143%}.grid-stack.grid-stack-14>.grid-stack-item[data-gs-min-width="5"]{min-width:35.7142857143%}.grid-stack.grid-stack-14>.grid-stack-item[data-gs-max-width="5"]{max-width:35.7142857143%}.grid-stack.grid-stack-14>.grid-stack-item[data-gs-width="6"]{width:42.8571428571%}.grid-stack.grid-stack-14>.grid-stack-item[data-gs-x="6"]{left:42.8571428571%}.grid-stack.grid-stack-14>.grid-stack-item[data-gs-min-width="6"]{min-width:42.8571428571%}.grid-stack.grid-stack-14>.grid-stack-item[data-gs-max-width="6"]{max-width:42.8571428571%}.grid-stack.grid-stack-14>.grid-stack-item[data-gs-width="7"]{width:50%}.grid-stack.grid-stack-14>.grid-stack-item[data-gs-x="7"]{left:50%}.grid-stack.grid-stack-14>.grid-stack-item[data-gs-min-width="7"]{min-width:50%}.grid-stack.grid-stack-14>.grid-stack-item[data-gs-max-width="7"]{max-width:50%}.grid-stack.grid-stack-14>.grid-stack-item[data-gs-width="8"]{width:57.1428571429%}.grid-stack.grid-stack-14>.grid-stack-item[data-gs-x="8"]{left:57.1428571429%}.grid-stack.grid-stack-14>.grid-stack-item[data-gs-min-width="8"]{min-width:57.1428571429%}.grid-stack.grid-stack-14>.grid-stack-item[data-gs-max-width="8"]{max-width:57.1428571429%}.grid-stack.grid-stack-14>.grid-stack-item[data-gs-width="9"]{width:64.2857142857%}.grid-stack.grid-stack-14>.grid-stack-item[data-gs-x="9"]{left:64.2857142857%}.grid-stack.grid-stack-14>.grid-stack-item[data-gs-min-width="9"]{min-width:64.2857142857%}.grid-stack.grid-stack-14>.grid-stack-item[data-gs-max-width="9"]{max-width:64.2857142857%}.grid-stack.grid-stack-14>.grid-stack-item[data-gs-width="10"]{width:71.4285714286%}.grid-stack.grid-stack-14>.grid-stack-item[data-gs-x="10"]{left:71.4285714286%}.grid-stack.grid-stack-14>.grid-stack-item[data-gs-min-width="10"]{min-width:71.4285714286%}.grid-stack.grid-stack-14>.grid-stack-item[data-gs-max-width="10"]{max-width:71.4285714286%}.grid-stack.grid-stack-14>.grid-stack-item[data-gs-width="11"]{width:78.5714285714%}.grid-stack.grid-stack-14>.grid-stack-item[data-gs-x="11"]{left:78.5714285714%}.grid-stack.grid-stack-14>.grid-stack-item[data-gs-min-width="11"]{min-width:78.5714285714%}.grid-stack.grid-stack-14>.grid-stack-item[data-gs-max-width="11"]{max-width:78.5714285714%}.grid-stack.grid-stack-14>.grid-stack-item[data-gs-width="12"]{width:85.7142857143%}.grid-stack.grid-stack-14>.grid-stack-item[data-gs-x="12"]{left:85.7142857143%}.grid-stack.grid-stack-14>.grid-stack-item[data-gs-min-width="12"]{min-width:85.7142857143%}.grid-stack.grid-stack-14>.grid-stack-item[data-gs-max-width="12"]{max-width:85.7142857143%}.grid-stack.grid-stack-14>.grid-stack-item[data-gs-width="13"]{width:92.8571428571%}.grid-stack.grid-stack-14>.grid-stack-item[data-gs-x="13"]{left:92.8571428571%}.grid-stack.grid-stack-14>.grid-stack-item[data-gs-min-width="13"]{min-width:92.8571428571%}.grid-stack.grid-stack-14>.grid-stack-item[data-gs-max-width="13"]{max-width:92.8571428571%}.grid-stack.grid-stack-14>.grid-stack-item[data-gs-width="14"]{width:100%}.grid-stack.grid-stack-14>.grid-stack-item[data-gs-x="14"]{left:100%}.grid-stack.grid-stack-14>.grid-stack-item[data-gs-min-width="14"]{min-width:100%}.grid-stack.grid-stack-14>.grid-stack-item[data-gs-max-width="14"]{max-width:100%}.grid-stack.grid-stack-15>.grid-stack-item{min-width:6.6666666667%}.grid-stack.grid-stack-15>.grid-stack-item[data-gs-width="1"]{width:6.6666666667%}.grid-stack.grid-stack-15>.grid-stack-item[data-gs-x="1"]{left:6.6666666667%}.grid-stack.grid-stack-15>.grid-stack-item[data-gs-min-width="1"]{min-width:6.6666666667%}.grid-stack.grid-stack-15>.grid-stack-item[data-gs-max-width="1"]{max-width:6.6666666667%}.grid-stack.grid-stack-15>.grid-stack-item[data-gs-width="2"]{width:13.3333333333%}.grid-stack.grid-stack-15>.grid-stack-item[data-gs-x="2"]{left:13.3333333333%}.grid-stack.grid-stack-15>.grid-stack-item[data-gs-min-width="2"]{min-width:13.3333333333%}.grid-stack.grid-stack-15>.grid-stack-item[data-gs-max-width="2"]{max-width:13.3333333333%}.grid-stack.grid-stack-15>.grid-stack-item[data-gs-width="3"]{width:20%}.grid-stack.grid-stack-15>.grid-stack-item[data-gs-x="3"]{left:20%}.grid-stack.grid-stack-15>.grid-stack-item[data-gs-min-width="3"]{min-width:20%}.grid-stack.grid-stack-15>.grid-stack-item[data-gs-max-width="3"]{max-width:20%}.grid-stack.grid-stack-15>.grid-stack-item[data-gs-width="4"]{width:26.6666666667%}.grid-stack.grid-stack-15>.grid-stack-item[data-gs-x="4"]{left:26.6666666667%}.grid-stack.grid-stack-15>.grid-stack-item[data-gs-min-width="4"]{min-width:26.6666666667%}.grid-stack.grid-stack-15>.grid-stack-item[data-gs-max-width="4"]{max-width:26.6666666667%}.grid-stack.grid-stack-15>.grid-stack-item[data-gs-width="5"]{width:33.3333333333%}.grid-stack.grid-stack-15>.grid-stack-item[data-gs-x="5"]{left:33.3333333333%}.grid-stack.grid-stack-15>.grid-stack-item[data-gs-min-width="5"]{min-width:33.3333333333%}.grid-stack.grid-stack-15>.grid-stack-item[data-gs-max-width="5"]{max-width:33.3333333333%}.grid-stack.grid-stack-15>.grid-stack-item[data-gs-width="6"]{width:40%}.grid-stack.grid-stack-15>.grid-stack-item[data-gs-x="6"]{left:40%}.grid-stack.grid-stack-15>.grid-stack-item[data-gs-min-width="6"]{min-width:40%}.grid-stack.grid-stack-15>.grid-stack-item[data-gs-max-width="6"]{max-width:40%}.grid-stack.grid-stack-15>.grid-stack-item[data-gs-width="7"]{width:46.6666666667%}.grid-stack.grid-stack-15>.grid-stack-item[data-gs-x="7"]{left:46.6666666667%}.grid-stack.grid-stack-15>.grid-stack-item[data-gs-min-width="7"]{min-width:46.6666666667%}.grid-stack.grid-stack-15>.grid-stack-item[data-gs-max-width="7"]{max-width:46.6666666667%}.grid-stack.grid-stack-15>.grid-stack-item[data-gs-width="8"]{width:53.3333333333%}.grid-stack.grid-stack-15>.grid-stack-item[data-gs-x="8"]{left:53.3333333333%}.grid-stack.grid-stack-15>.grid-stack-item[data-gs-min-width="8"]{min-width:53.3333333333%}.grid-stack.grid-stack-15>.grid-stack-item[data-gs-max-width="8"]{max-width:53.3333333333%}.grid-stack.grid-stack-15>.grid-stack-item[data-gs-width="9"]{width:60%}.grid-stack.grid-stack-15>.grid-stack-item[data-gs-x="9"]{left:60%}.grid-stack.grid-stack-15>.grid-stack-item[data-gs-min-width="9"]{min-width:60%}.grid-stack.grid-stack-15>.grid-stack-item[data-gs-max-width="9"]{max-width:60%}.grid-stack.grid-stack-15>.grid-stack-item[data-gs-width="10"]{width:66.6666666667%}.grid-stack.grid-stack-15>.grid-stack-item[data-gs-x="10"]{left:66.6666666667%}.grid-stack.grid-stack-15>.grid-stack-item[data-gs-min-width="10"]{min-width:66.6666666667%}.grid-stack.grid-stack-15>.grid-stack-item[data-gs-max-width="10"]{max-width:66.6666666667%}.grid-stack.grid-stack-15>.grid-stack-item[data-gs-width="11"]{width:73.3333333333%}.grid-stack.grid-stack-15>.grid-stack-item[data-gs-x="11"]{left:73.3333333333%}.grid-stack.grid-stack-15>.grid-stack-item[data-gs-min-width="11"]{min-width:73.3333333333%}.grid-stack.grid-stack-15>.grid-stack-item[data-gs-max-width="11"]{max-width:73.3333333333%}.grid-stack.grid-stack-15>.grid-stack-item[data-gs-width="12"]{width:80%}.grid-stack.grid-stack-15>.grid-stack-item[data-gs-x="12"]{left:80%}.grid-stack.grid-stack-15>.grid-stack-item[data-gs-min-width="12"]{min-width:80%}.grid-stack.grid-stack-15>.grid-stack-item[data-gs-max-width="12"]{max-width:80%}.grid-stack.grid-stack-15>.grid-stack-item[data-gs-width="13"]{width:86.6666666667%}.grid-stack.grid-stack-15>.grid-stack-item[data-gs-x="13"]{left:86.6666666667%}.grid-stack.grid-stack-15>.grid-stack-item[data-gs-min-width="13"]{min-width:86.6666666667%}.grid-stack.grid-stack-15>.grid-stack-item[data-gs-max-width="13"]{max-width:86.6666666667%}.grid-stack.grid-stack-15>.grid-stack-item[data-gs-width="14"]{width:93.3333333333%}.grid-stack.grid-stack-15>.grid-stack-item[data-gs-x="14"]{left:93.3333333333%}.grid-stack.grid-stack-15>.grid-stack-item[data-gs-min-width="14"]{min-width:93.3333333333%}.grid-stack.grid-stack-15>.grid-stack-item[data-gs-max-width="14"]{max-width:93.3333333333%}.grid-stack.grid-stack-15>.grid-stack-item[data-gs-width="15"]{width:100%}.grid-stack.grid-stack-15>.grid-stack-item[data-gs-x="15"]{left:100%}.grid-stack.grid-stack-15>.grid-stack-item[data-gs-min-width="15"]{min-width:100%}.grid-stack.grid-stack-15>.grid-stack-item[data-gs-max-width="15"]{max-width:100%}.grid-stack.grid-stack-16>.grid-stack-item{min-width:6.25%}.grid-stack.grid-stack-16>.grid-stack-item[data-gs-width="1"]{width:6.25%}.grid-stack.grid-stack-16>.grid-stack-item[data-gs-x="1"]{left:6.25%}.grid-stack.grid-stack-16>.grid-stack-item[data-gs-min-width="1"]{min-width:6.25%}.grid-stack.grid-stack-16>.grid-stack-item[data-gs-max-width="1"]{max-width:6.25%}.grid-stack.grid-stack-16>.grid-stack-item[data-gs-width="2"]{width:12.5%}.grid-stack.grid-stack-16>.grid-stack-item[data-gs-x="2"]{left:12.5%}.grid-stack.grid-stack-16>.grid-stack-item[data-gs-min-width="2"]{min-width:12.5%}.grid-stack.grid-stack-16>.grid-stack-item[data-gs-max-width="2"]{max-width:12.5%}.grid-stack.grid-stack-16>.grid-stack-item[data-gs-width="3"]{width:18.75%}.grid-stack.grid-stack-16>.grid-stack-item[data-gs-x="3"]{left:18.75%}.grid-stack.grid-stack-16>.grid-stack-item[data-gs-min-width="3"]{min-width:18.75%}.grid-stack.grid-stack-16>.grid-stack-item[data-gs-max-width="3"]{max-width:18.75%}.grid-stack.grid-stack-16>.grid-stack-item[data-gs-width="4"]{width:25%}.grid-stack.grid-stack-16>.grid-stack-item[data-gs-x="4"]{left:25%}.grid-stack.grid-stack-16>.grid-stack-item[data-gs-min-width="4"]{min-width:25%}.grid-stack.grid-stack-16>.grid-stack-item[data-gs-max-width="4"]{max-width:25%}.grid-stack.grid-stack-16>.grid-stack-item[data-gs-width="5"]{width:31.25%}.grid-stack.grid-stack-16>.grid-stack-item[data-gs-x="5"]{left:31.25%}.grid-stack.grid-stack-16>.grid-stack-item[data-gs-min-width="5"]{min-width:31.25%}.grid-stack.grid-stack-16>.grid-stack-item[data-gs-max-width="5"]{max-width:31.25%}.grid-stack.grid-stack-16>.grid-stack-item[data-gs-width="6"]{width:37.5%}.grid-stack.grid-stack-16>.grid-stack-item[data-gs-x="6"]{left:37.5%}.grid-stack.grid-stack-16>.grid-stack-item[data-gs-min-width="6"]{min-width:37.5%}.grid-stack.grid-stack-16>.grid-stack-item[data-gs-max-width="6"]{max-width:37.5%}.grid-stack.grid-stack-16>.grid-stack-item[data-gs-width="7"]{width:43.75%}.grid-stack.grid-stack-16>.grid-stack-item[data-gs-x="7"]{left:43.75%}.grid-stack.grid-stack-16>.grid-stack-item[data-gs-min-width="7"]{min-width:43.75%}.grid-stack.grid-stack-16>.grid-stack-item[data-gs-max-width="7"]{max-width:43.75%}.grid-stack.grid-stack-16>.grid-stack-item[data-gs-width="8"]{width:50%}.grid-stack.grid-stack-16>.grid-stack-item[data-gs-x="8"]{left:50%}.grid-stack.grid-stack-16>.grid-stack-item[data-gs-min-width="8"]{min-width:50%}.grid-stack.grid-stack-16>.grid-stack-item[data-gs-max-width="8"]{max-width:50%}.grid-stack.grid-stack-16>.grid-stack-item[data-gs-width="9"]{width:56.25%}.grid-stack.grid-stack-16>.grid-stack-item[data-gs-x="9"]{left:56.25%}.grid-stack.grid-stack-16>.grid-stack-item[data-gs-min-width="9"]{min-width:56.25%}.grid-stack.grid-stack-16>.grid-stack-item[data-gs-max-width="9"]{max-width:56.25%}.grid-stack.grid-stack-16>.grid-stack-item[data-gs-width="10"]{width:62.5%}.grid-stack.grid-stack-16>.grid-stack-item[data-gs-x="10"]{left:62.5%}.grid-stack.grid-stack-16>.grid-stack-item[data-gs-min-width="10"]{min-width:62.5%}.grid-stack.grid-stack-16>.grid-stack-item[data-gs-max-width="10"]{max-width:62.5%}.grid-stack.grid-stack-16>.grid-stack-item[data-gs-width="11"]{width:68.75%}.grid-stack.grid-stack-16>.grid-stack-item[data-gs-x="11"]{left:68.75%}.grid-stack.grid-stack-16>.grid-stack-item[data-gs-min-width="11"]{min-width:68.75%}.grid-stack.grid-stack-16>.grid-stack-item[data-gs-max-width="11"]{max-width:68.75%}.grid-stack.grid-stack-16>.grid-stack-item[data-gs-width="12"]{width:75%}.grid-stack.grid-stack-16>.grid-stack-item[data-gs-x="12"]{left:75%}.grid-stack.grid-stack-16>.grid-stack-item[data-gs-min-width="12"]{min-width:75%}.grid-stack.grid-stack-16>.grid-stack-item[data-gs-max-width="12"]{max-width:75%}.grid-stack.grid-stack-16>.grid-stack-item[data-gs-width="13"]{width:81.25%}.grid-stack.grid-stack-16>.grid-stack-item[data-gs-x="13"]{left:81.25%}.grid-stack.grid-stack-16>.grid-stack-item[data-gs-min-width="13"]{min-width:81.25%}.grid-stack.grid-stack-16>.grid-stack-item[data-gs-max-width="13"]{max-width:81.25%}.grid-stack.grid-stack-16>.grid-stack-item[data-gs-width="14"]{width:87.5%}.grid-stack.grid-stack-16>.grid-stack-item[data-gs-x="14"]{left:87.5%}.grid-stack.grid-stack-16>.grid-stack-item[data-gs-min-width="14"]{min-width:87.5%}.grid-stack.grid-stack-16>.grid-stack-item[data-gs-max-width="14"]{max-width:87.5%}.grid-stack.grid-stack-16>.grid-stack-item[data-gs-width="15"]{width:93.75%}.grid-stack.grid-stack-16>.grid-stack-item[data-gs-x="15"]{left:93.75%}.grid-stack.grid-stack-16>.grid-stack-item[data-gs-min-width="15"]{min-width:93.75%}.grid-stack.grid-stack-16>.grid-stack-item[data-gs-max-width="15"]{max-width:93.75%}.grid-stack.grid-stack-16>.grid-stack-item[data-gs-width="16"]{width:100%}.grid-stack.grid-stack-16>.grid-stack-item[data-gs-x="16"]{left:100%}.grid-stack.grid-stack-16>.grid-stack-item[data-gs-min-width="16"]{min-width:100%}.grid-stack.grid-stack-16>.grid-stack-item[data-gs-max-width="16"]{max-width:100%}.grid-stack.grid-stack-17>.grid-stack-item{min-width:5.8823529412%}.grid-stack.grid-stack-17>.grid-stack-item[data-gs-width="1"]{width:5.8823529412%}.grid-stack.grid-stack-17>.grid-stack-item[data-gs-x="1"]{left:5.8823529412%}.grid-stack.grid-stack-17>.grid-stack-item[data-gs-min-width="1"]{min-width:5.8823529412%}.grid-stack.grid-stack-17>.grid-stack-item[data-gs-max-width="1"]{max-width:5.8823529412%}.grid-stack.grid-stack-17>.grid-stack-item[data-gs-width="2"]{width:11.7647058824%}.grid-stack.grid-stack-17>.grid-stack-item[data-gs-x="2"]{left:11.7647058824%}.grid-stack.grid-stack-17>.grid-stack-item[data-gs-min-width="2"]{min-width:11.7647058824%}.grid-stack.grid-stack-17>.grid-stack-item[data-gs-max-width="2"]{max-width:11.7647058824%}.grid-stack.grid-stack-17>.grid-stack-item[data-gs-width="3"]{width:17.6470588235%}.grid-stack.grid-stack-17>.grid-stack-item[data-gs-x="3"]{left:17.6470588235%}.grid-stack.grid-stack-17>.grid-stack-item[data-gs-min-width="3"]{min-width:17.6470588235%}.grid-stack.grid-stack-17>.grid-stack-item[data-gs-max-width="3"]{max-width:17.6470588235%}.grid-stack.grid-stack-17>.grid-stack-item[data-gs-width="4"]{width:23.5294117647%}.grid-stack.grid-stack-17>.grid-stack-item[data-gs-x="4"]{left:23.5294117647%}.grid-stack.grid-stack-17>.grid-stack-item[data-gs-min-width="4"]{min-width:23.5294117647%}.grid-stack.grid-stack-17>.grid-stack-item[data-gs-max-width="4"]{max-width:23.5294117647%}.grid-stack.grid-stack-17>.grid-stack-item[data-gs-width="5"]{width:29.4117647059%}.grid-stack.grid-stack-17>.grid-stack-item[data-gs-x="5"]{left:29.4117647059%}.grid-stack.grid-stack-17>.grid-stack-item[data-gs-min-width="5"]{min-width:29.4117647059%}.grid-stack.grid-stack-17>.grid-stack-item[data-gs-max-width="5"]{max-width:29.4117647059%}.grid-stack.grid-stack-17>.grid-stack-item[data-gs-width="6"]{width:35.2941176471%}.grid-stack.grid-stack-17>.grid-stack-item[data-gs-x="6"]{left:35.2941176471%}.grid-stack.grid-stack-17>.grid-stack-item[data-gs-min-width="6"]{min-width:35.2941176471%}.grid-stack.grid-stack-17>.grid-stack-item[data-gs-max-width="6"]{max-width:35.2941176471%}.grid-stack.grid-stack-17>.grid-stack-item[data-gs-width="7"]{width:41.1764705882%}.grid-stack.grid-stack-17>.grid-stack-item[data-gs-x="7"]{left:41.1764705882%}.grid-stack.grid-stack-17>.grid-stack-item[data-gs-min-width="7"]{min-width:41.1764705882%}.grid-stack.grid-stack-17>.grid-stack-item[data-gs-max-width="7"]{max-width:41.1764705882%}.grid-stack.grid-stack-17>.grid-stack-item[data-gs-width="8"]{width:47.0588235294%}.grid-stack.grid-stack-17>.grid-stack-item[data-gs-x="8"]{left:47.0588235294%}.grid-stack.grid-stack-17>.grid-stack-item[data-gs-min-width="8"]{min-width:47.0588235294%}.grid-stack.grid-stack-17>.grid-stack-item[data-gs-max-width="8"]{max-width:47.0588235294%}.grid-stack.grid-stack-17>.grid-stack-item[data-gs-width="9"]{width:52.9411764706%}.grid-stack.grid-stack-17>.grid-stack-item[data-gs-x="9"]{left:52.9411764706%}.grid-stack.grid-stack-17>.grid-stack-item[data-gs-min-width="9"]{min-width:52.9411764706%}.grid-stack.grid-stack-17>.grid-stack-item[data-gs-max-width="9"]{max-width:52.9411764706%}.grid-stack.grid-stack-17>.grid-stack-item[data-gs-width="10"]{width:58.8235294118%}.grid-stack.grid-stack-17>.grid-stack-item[data-gs-x="10"]{left:58.8235294118%}.grid-stack.grid-stack-17>.grid-stack-item[data-gs-min-width="10"]{min-width:58.8235294118%}.grid-stack.grid-stack-17>.grid-stack-item[data-gs-max-width="10"]{max-width:58.8235294118%}.grid-stack.grid-stack-17>.grid-stack-item[data-gs-width="11"]{width:64.7058823529%}.grid-stack.grid-stack-17>.grid-stack-item[data-gs-x="11"]{left:64.7058823529%}.grid-stack.grid-stack-17>.grid-stack-item[data-gs-min-width="11"]{min-width:64.7058823529%}.grid-stack.grid-stack-17>.grid-stack-item[data-gs-max-width="11"]{max-width:64.7058823529%}.grid-stack.grid-stack-17>.grid-stack-item[data-gs-width="12"]{width:70.5882352941%}.grid-stack.grid-stack-17>.grid-stack-item[data-gs-x="12"]{left:70.5882352941%}.grid-stack.grid-stack-17>.grid-stack-item[data-gs-min-width="12"]{min-width:70.5882352941%}.grid-stack.grid-stack-17>.grid-stack-item[data-gs-max-width="12"]{max-width:70.5882352941%}.grid-stack.grid-stack-17>.grid-stack-item[data-gs-width="13"]{width:76.4705882353%}.grid-stack.grid-stack-17>.grid-stack-item[data-gs-x="13"]{left:76.4705882353%}.grid-stack.grid-stack-17>.grid-stack-item[data-gs-min-width="13"]{min-width:76.4705882353%}.grid-stack.grid-stack-17>.grid-stack-item[data-gs-max-width="13"]{max-width:76.4705882353%}.grid-stack.grid-stack-17>.grid-stack-item[data-gs-width="14"]{width:82.3529411765%}.grid-stack.grid-stack-17>.grid-stack-item[data-gs-x="14"]{left:82.3529411765%}.grid-stack.grid-stack-17>.grid-stack-item[data-gs-min-width="14"]{min-width:82.3529411765%}.grid-stack.grid-stack-17>.grid-stack-item[data-gs-max-width="14"]{max-width:82.3529411765%}.grid-stack.grid-stack-17>.grid-stack-item[data-gs-width="15"]{width:88.2352941176%}.grid-stack.grid-stack-17>.grid-stack-item[data-gs-x="15"]{left:88.2352941176%}.grid-stack.grid-stack-17>.grid-stack-item[data-gs-min-width="15"]{min-width:88.2352941176%}.grid-stack.grid-stack-17>.grid-stack-item[data-gs-max-width="15"]{max-width:88.2352941176%}.grid-stack.grid-stack-17>.grid-stack-item[data-gs-width="16"]{width:94.1176470588%}.grid-stack.grid-stack-17>.grid-stack-item[data-gs-x="16"]{left:94.1176470588%}.grid-stack.grid-stack-17>.grid-stack-item[data-gs-min-width="16"]{min-width:94.1176470588%}.grid-stack.grid-stack-17>.grid-stack-item[data-gs-max-width="16"]{max-width:94.1176470588%}.grid-stack.grid-stack-17>.grid-stack-item[data-gs-width="17"]{width:100%}.grid-stack.grid-stack-17>.grid-stack-item[data-gs-x="17"]{left:100%}.grid-stack.grid-stack-17>.grid-stack-item[data-gs-min-width="17"]{min-width:100%}.grid-stack.grid-stack-17>.grid-stack-item[data-gs-max-width="17"]{max-width:100%}.grid-stack.grid-stack-18>.grid-stack-item{min-width:5.5555555556%}.grid-stack.grid-stack-18>.grid-stack-item[data-gs-width="1"]{width:5.5555555556%}.grid-stack.grid-stack-18>.grid-stack-item[data-gs-x="1"]{left:5.5555555556%}.grid-stack.grid-stack-18>.grid-stack-item[data-gs-min-width="1"]{min-width:5.5555555556%}.grid-stack.grid-stack-18>.grid-stack-item[data-gs-max-width="1"]{max-width:5.5555555556%}.grid-stack.grid-stack-18>.grid-stack-item[data-gs-width="2"]{width:11.1111111111%}.grid-stack.grid-stack-18>.grid-stack-item[data-gs-x="2"]{left:11.1111111111%}.grid-stack.grid-stack-18>.grid-stack-item[data-gs-min-width="2"]{min-width:11.1111111111%}.grid-stack.grid-stack-18>.grid-stack-item[data-gs-max-width="2"]{max-width:11.1111111111%}.grid-stack.grid-stack-18>.grid-stack-item[data-gs-width="3"]{width:16.6666666667%}.grid-stack.grid-stack-18>.grid-stack-item[data-gs-x="3"]{left:16.6666666667%}.grid-stack.grid-stack-18>.grid-stack-item[data-gs-min-width="3"]{min-width:16.6666666667%}.grid-stack.grid-stack-18>.grid-stack-item[data-gs-max-width="3"]{max-width:16.6666666667%}.grid-stack.grid-stack-18>.grid-stack-item[data-gs-width="4"]{width:22.2222222222%}.grid-stack.grid-stack-18>.grid-stack-item[data-gs-x="4"]{left:22.2222222222%}.grid-stack.grid-stack-18>.grid-stack-item[data-gs-min-width="4"]{min-width:22.2222222222%}.grid-stack.grid-stack-18>.grid-stack-item[data-gs-max-width="4"]{max-width:22.2222222222%}.grid-stack.grid-stack-18>.grid-stack-item[data-gs-width="5"]{width:27.7777777778%}.grid-stack.grid-stack-18>.grid-stack-item[data-gs-x="5"]{left:27.7777777778%}.grid-stack.grid-stack-18>.grid-stack-item[data-gs-min-width="5"]{min-width:27.7777777778%}.grid-stack.grid-stack-18>.grid-stack-item[data-gs-max-width="5"]{max-width:27.7777777778%}.grid-stack.grid-stack-18>.grid-stack-item[data-gs-width="6"]{width:33.3333333333%}.grid-stack.grid-stack-18>.grid-stack-item[data-gs-x="6"]{left:33.3333333333%}.grid-stack.grid-stack-18>.grid-stack-item[data-gs-min-width="6"]{min-width:33.3333333333%}.grid-stack.grid-stack-18>.grid-stack-item[data-gs-max-width="6"]{max-width:33.3333333333%}.grid-stack.grid-stack-18>.grid-stack-item[data-gs-width="7"]{width:38.8888888889%}.grid-stack.grid-stack-18>.grid-stack-item[data-gs-x="7"]{left:38.8888888889%}.grid-stack.grid-stack-18>.grid-stack-item[data-gs-min-width="7"]{min-width:38.8888888889%}.grid-stack.grid-stack-18>.grid-stack-item[data-gs-max-width="7"]{max-width:38.8888888889%}.grid-stack.grid-stack-18>.grid-stack-item[data-gs-width="8"]{width:44.4444444444%}.grid-stack.grid-stack-18>.grid-stack-item[data-gs-x="8"]{left:44.4444444444%}.grid-stack.grid-stack-18>.grid-stack-item[data-gs-min-width="8"]{min-width:44.4444444444%}.grid-stack.grid-stack-18>.grid-stack-item[data-gs-max-width="8"]{max-width:44.4444444444%}.grid-stack.grid-stack-18>.grid-stack-item[data-gs-width="9"]{width:50%}.grid-stack.grid-stack-18>.grid-stack-item[data-gs-x="9"]{left:50%}.grid-stack.grid-stack-18>.grid-stack-item[data-gs-min-width="9"]{min-width:50%}.grid-stack.grid-stack-18>.grid-stack-item[data-gs-max-width="9"]{max-width:50%}.grid-stack.grid-stack-18>.grid-stack-item[data-gs-width="10"]{width:55.5555555556%}.grid-stack.grid-stack-18>.grid-stack-item[data-gs-x="10"]{left:55.5555555556%}.grid-stack.grid-stack-18>.grid-stack-item[data-gs-min-width="10"]{min-width:55.5555555556%}.grid-stack.grid-stack-18>.grid-stack-item[data-gs-max-width="10"]{max-width:55.5555555556%}.grid-stack.grid-stack-18>.grid-stack-item[data-gs-width="11"]{width:61.1111111111%}.grid-stack.grid-stack-18>.grid-stack-item[data-gs-x="11"]{left:61.1111111111%}.grid-stack.grid-stack-18>.grid-stack-item[data-gs-min-width="11"]{min-width:61.1111111111%}.grid-stack.grid-stack-18>.grid-stack-item[data-gs-max-width="11"]{max-width:61.1111111111%}.grid-stack.grid-stack-18>.grid-stack-item[data-gs-width="12"]{width:66.6666666667%}.grid-stack.grid-stack-18>.grid-stack-item[data-gs-x="12"]{left:66.6666666667%}.grid-stack.grid-stack-18>.grid-stack-item[data-gs-min-width="12"]{min-width:66.6666666667%}.grid-stack.grid-stack-18>.grid-stack-item[data-gs-max-width="12"]{max-width:66.6666666667%}.grid-stack.grid-stack-18>.grid-stack-item[data-gs-width="13"]{width:72.2222222222%}.grid-stack.grid-stack-18>.grid-stack-item[data-gs-x="13"]{left:72.2222222222%}.grid-stack.grid-stack-18>.grid-stack-item[data-gs-min-width="13"]{min-width:72.2222222222%}.grid-stack.grid-stack-18>.grid-stack-item[data-gs-max-width="13"]{max-width:72.2222222222%}.grid-stack.grid-stack-18>.grid-stack-item[data-gs-width="14"]{width:77.7777777778%}.grid-stack.grid-stack-18>.grid-stack-item[data-gs-x="14"]{left:77.7777777778%}.grid-stack.grid-stack-18>.grid-stack-item[data-gs-min-width="14"]{min-width:77.7777777778%}.grid-stack.grid-stack-18>.grid-stack-item[data-gs-max-width="14"]{max-width:77.7777777778%}.grid-stack.grid-stack-18>.grid-stack-item[data-gs-width="15"]{width:83.3333333333%}.grid-stack.grid-stack-18>.grid-stack-item[data-gs-x="15"]{left:83.3333333333%}.grid-stack.grid-stack-18>.grid-stack-item[data-gs-min-width="15"]{min-width:83.3333333333%}.grid-stack.grid-stack-18>.grid-stack-item[data-gs-max-width="15"]{max-width:83.3333333333%}.grid-stack.grid-stack-18>.grid-stack-item[data-gs-width="16"]{width:88.8888888889%}.grid-stack.grid-stack-18>.grid-stack-item[data-gs-x="16"]{left:88.8888888889%}.grid-stack.grid-stack-18>.grid-stack-item[data-gs-min-width="16"]{min-width:88.8888888889%}.grid-stack.grid-stack-18>.grid-stack-item[data-gs-max-width="16"]{max-width:88.8888888889%}.grid-stack.grid-stack-18>.grid-stack-item[data-gs-width="17"]{width:94.4444444444%}.grid-stack.grid-stack-18>.grid-stack-item[data-gs-x="17"]{left:94.4444444444%}.grid-stack.grid-stack-18>.grid-stack-item[data-gs-min-width="17"]{min-width:94.4444444444%}.grid-stack.grid-stack-18>.grid-stack-item[data-gs-max-width="17"]{max-width:94.4444444444%}.grid-stack.grid-stack-18>.grid-stack-item[data-gs-width="18"]{width:100%}.grid-stack.grid-stack-18>.grid-stack-item[data-gs-x="18"]{left:100%}.grid-stack.grid-stack-18>.grid-stack-item[data-gs-min-width="18"]{min-width:100%}.grid-stack.grid-stack-18>.grid-stack-item[data-gs-max-width="18"]{max-width:100%}.grid-stack.grid-stack-19>.grid-stack-item{min-width:5.2631578947%}.grid-stack.grid-stack-19>.grid-stack-item[data-gs-width="1"]{width:5.2631578947%}.grid-stack.grid-stack-19>.grid-stack-item[data-gs-x="1"]{left:5.2631578947%}.grid-stack.grid-stack-19>.grid-stack-item[data-gs-min-width="1"]{min-width:5.2631578947%}.grid-stack.grid-stack-19>.grid-stack-item[data-gs-max-width="1"]{max-width:5.2631578947%}.grid-stack.grid-stack-19>.grid-stack-item[data-gs-width="2"]{width:10.5263157895%}.grid-stack.grid-stack-19>.grid-stack-item[data-gs-x="2"]{left:10.5263157895%}.grid-stack.grid-stack-19>.grid-stack-item[data-gs-min-width="2"]{min-width:10.5263157895%}.grid-stack.grid-stack-19>.grid-stack-item[data-gs-max-width="2"]{max-width:10.5263157895%}.grid-stack.grid-stack-19>.grid-stack-item[data-gs-width="3"]{width:15.7894736842%}.grid-stack.grid-stack-19>.grid-stack-item[data-gs-x="3"]{left:15.7894736842%}.grid-stack.grid-stack-19>.grid-stack-item[data-gs-min-width="3"]{min-width:15.7894736842%}.grid-stack.grid-stack-19>.grid-stack-item[data-gs-max-width="3"]{max-width:15.7894736842%}.grid-stack.grid-stack-19>.grid-stack-item[data-gs-width="4"]{width:21.0526315789%}.grid-stack.grid-stack-19>.grid-stack-item[data-gs-x="4"]{left:21.0526315789%}.grid-stack.grid-stack-19>.grid-stack-item[data-gs-min-width="4"]{min-width:21.0526315789%}.grid-stack.grid-stack-19>.grid-stack-item[data-gs-max-width="4"]{max-width:21.0526315789%}.grid-stack.grid-stack-19>.grid-stack-item[data-gs-width="5"]{width:26.3157894737%}.grid-stack.grid-stack-19>.grid-stack-item[data-gs-x="5"]{left:26.3157894737%}.grid-stack.grid-stack-19>.grid-stack-item[data-gs-min-width="5"]{min-width:26.3157894737%}.grid-stack.grid-stack-19>.grid-stack-item[data-gs-max-width="5"]{max-width:26.3157894737%}.grid-stack.grid-stack-19>.grid-stack-item[data-gs-width="6"]{width:31.5789473684%}.grid-stack.grid-stack-19>.grid-stack-item[data-gs-x="6"]{left:31.5789473684%}.grid-stack.grid-stack-19>.grid-stack-item[data-gs-min-width="6"]{min-width:31.5789473684%}.grid-stack.grid-stack-19>.grid-stack-item[data-gs-max-width="6"]{max-width:31.5789473684%}.grid-stack.grid-stack-19>.grid-stack-item[data-gs-width="7"]{width:36.8421052632%}.grid-stack.grid-stack-19>.grid-stack-item[data-gs-x="7"]{left:36.8421052632%}.grid-stack.grid-stack-19>.grid-stack-item[data-gs-min-width="7"]{min-width:36.8421052632%}.grid-stack.grid-stack-19>.grid-stack-item[data-gs-max-width="7"]{max-width:36.8421052632%}.grid-stack.grid-stack-19>.grid-stack-item[data-gs-width="8"]{width:42.1052631579%}.grid-stack.grid-stack-19>.grid-stack-item[data-gs-x="8"]{left:42.1052631579%}.grid-stack.grid-stack-19>.grid-stack-item[data-gs-min-width="8"]{min-width:42.1052631579%}.grid-stack.grid-stack-19>.grid-stack-item[data-gs-max-width="8"]{max-width:42.1052631579%}.grid-stack.grid-stack-19>.grid-stack-item[data-gs-width="9"]{width:47.3684210526%}.grid-stack.grid-stack-19>.grid-stack-item[data-gs-x="9"]{left:47.3684210526%}.grid-stack.grid-stack-19>.grid-stack-item[data-gs-min-width="9"]{min-width:47.3684210526%}.grid-stack.grid-stack-19>.grid-stack-item[data-gs-max-width="9"]{max-width:47.3684210526%}.grid-stack.grid-stack-19>.grid-stack-item[data-gs-width="10"]{width:52.6315789474%}.grid-stack.grid-stack-19>.grid-stack-item[data-gs-x="10"]{left:52.6315789474%}.grid-stack.grid-stack-19>.grid-stack-item[data-gs-min-width="10"]{min-width:52.6315789474%}.grid-stack.grid-stack-19>.grid-stack-item[data-gs-max-width="10"]{max-width:52.6315789474%}.grid-stack.grid-stack-19>.grid-stack-item[data-gs-width="11"]{width:57.8947368421%}.grid-stack.grid-stack-19>.grid-stack-item[data-gs-x="11"]{left:57.8947368421%}.grid-stack.grid-stack-19>.grid-stack-item[data-gs-min-width="11"]{min-width:57.8947368421%}.grid-stack.grid-stack-19>.grid-stack-item[data-gs-max-width="11"]{max-width:57.8947368421%}.grid-stack.grid-stack-19>.grid-stack-item[data-gs-width="12"]{width:63.1578947368%}.grid-stack.grid-stack-19>.grid-stack-item[data-gs-x="12"]{left:63.1578947368%}.grid-stack.grid-stack-19>.grid-stack-item[data-gs-min-width="12"]{min-width:63.1578947368%}.grid-stack.grid-stack-19>.grid-stack-item[data-gs-max-width="12"]{max-width:63.1578947368%}.grid-stack.grid-stack-19>.grid-stack-item[data-gs-width="13"]{width:68.4210526316%}.grid-stack.grid-stack-19>.grid-stack-item[data-gs-x="13"]{left:68.4210526316%}.grid-stack.grid-stack-19>.grid-stack-item[data-gs-min-width="13"]{min-width:68.4210526316%}.grid-stack.grid-stack-19>.grid-stack-item[data-gs-max-width="13"]{max-width:68.4210526316%}.grid-stack.grid-stack-19>.grid-stack-item[data-gs-width="14"]{width:73.6842105263%}.grid-stack.grid-stack-19>.grid-stack-item[data-gs-x="14"]{left:73.6842105263%}.grid-stack.grid-stack-19>.grid-stack-item[data-gs-min-width="14"]{min-width:73.6842105263%}.grid-stack.grid-stack-19>.grid-stack-item[data-gs-max-width="14"]{max-width:73.6842105263%}.grid-stack.grid-stack-19>.grid-stack-item[data-gs-width="15"]{width:78.9473684211%}.grid-stack.grid-stack-19>.grid-stack-item[data-gs-x="15"]{left:78.9473684211%}.grid-stack.grid-stack-19>.grid-stack-item[data-gs-min-width="15"]{min-width:78.9473684211%}.grid-stack.grid-stack-19>.grid-stack-item[data-gs-max-width="15"]{max-width:78.9473684211%}.grid-stack.grid-stack-19>.grid-stack-item[data-gs-width="16"]{width:84.2105263158%}.grid-stack.grid-stack-19>.grid-stack-item[data-gs-x="16"]{left:84.2105263158%}.grid-stack.grid-stack-19>.grid-stack-item[data-gs-min-width="16"]{min-width:84.2105263158%}.grid-stack.grid-stack-19>.grid-stack-item[data-gs-max-width="16"]{max-width:84.2105263158%}.grid-stack.grid-stack-19>.grid-stack-item[data-gs-width="17"]{width:89.4736842105%}.grid-stack.grid-stack-19>.grid-stack-item[data-gs-x="17"]{left:89.4736842105%}.grid-stack.grid-stack-19>.grid-stack-item[data-gs-min-width="17"]{min-width:89.4736842105%}.grid-stack.grid-stack-19>.grid-stack-item[data-gs-max-width="17"]{max-width:89.4736842105%}.grid-stack.grid-stack-19>.grid-stack-item[data-gs-width="18"]{width:94.7368421053%}.grid-stack.grid-stack-19>.grid-stack-item[data-gs-x="18"]{left:94.7368421053%}.grid-stack.grid-stack-19>.grid-stack-item[data-gs-min-width="18"]{min-width:94.7368421053%}.grid-stack.grid-stack-19>.grid-stack-item[data-gs-max-width="18"]{max-width:94.7368421053%}.grid-stack.grid-stack-19>.grid-stack-item[data-gs-width="19"]{width:100%}.grid-stack.grid-stack-19>.grid-stack-item[data-gs-x="19"]{left:100%}.grid-stack.grid-stack-19>.grid-stack-item[data-gs-min-width="19"]{min-width:100%}.grid-stack.grid-stack-19>.grid-stack-item[data-gs-max-width="19"]{max-width:100%}.grid-stack.grid-stack-20>.grid-stack-item{min-width:5%}.grid-stack.grid-stack-20>.grid-stack-item[data-gs-width="1"]{width:5%}.grid-stack.grid-stack-20>.grid-stack-item[data-gs-x="1"]{left:5%}.grid-stack.grid-stack-20>.grid-stack-item[data-gs-min-width="1"]{min-width:5%}.grid-stack.grid-stack-20>.grid-stack-item[data-gs-max-width="1"]{max-width:5%}.grid-stack.grid-stack-20>.grid-stack-item[data-gs-width="2"]{width:10%}.grid-stack.grid-stack-20>.grid-stack-item[data-gs-x="2"]{left:10%}.grid-stack.grid-stack-20>.grid-stack-item[data-gs-min-width="2"]{min-width:10%}.grid-stack.grid-stack-20>.grid-stack-item[data-gs-max-width="2"]{max-width:10%}.grid-stack.grid-stack-20>.grid-stack-item[data-gs-width="3"]{width:15%}.grid-stack.grid-stack-20>.grid-stack-item[data-gs-x="3"]{left:15%}.grid-stack.grid-stack-20>.grid-stack-item[data-gs-min-width="3"]{min-width:15%}.grid-stack.grid-stack-20>.grid-stack-item[data-gs-max-width="3"]{max-width:15%}.grid-stack.grid-stack-20>.grid-stack-item[data-gs-width="4"]{width:20%}.grid-stack.grid-stack-20>.grid-stack-item[data-gs-x="4"]{left:20%}.grid-stack.grid-stack-20>.grid-stack-item[data-gs-min-width="4"]{min-width:20%}.grid-stack.grid-stack-20>.grid-stack-item[data-gs-max-width="4"]{max-width:20%}.grid-stack.grid-stack-20>.grid-stack-item[data-gs-width="5"]{width:25%}.grid-stack.grid-stack-20>.grid-stack-item[data-gs-x="5"]{left:25%}.grid-stack.grid-stack-20>.grid-stack-item[data-gs-min-width="5"]{min-width:25%}.grid-stack.grid-stack-20>.grid-stack-item[data-gs-max-width="5"]{max-width:25%}.grid-stack.grid-stack-20>.grid-stack-item[data-gs-width="6"]{width:30%}.grid-stack.grid-stack-20>.grid-stack-item[data-gs-x="6"]{left:30%}.grid-stack.grid-stack-20>.grid-stack-item[data-gs-min-width="6"]{min-width:30%}.grid-stack.grid-stack-20>.grid-stack-item[data-gs-max-width="6"]{max-width:30%}.grid-stack.grid-stack-20>.grid-stack-item[data-gs-width="7"]{width:35%}.grid-stack.grid-stack-20>.grid-stack-item[data-gs-x="7"]{left:35%}.grid-stack.grid-stack-20>.grid-stack-item[data-gs-min-width="7"]{min-width:35%}.grid-stack.grid-stack-20>.grid-stack-item[data-gs-max-width="7"]{max-width:35%}.grid-stack.grid-stack-20>.grid-stack-item[data-gs-width="8"]{width:40%}.grid-stack.grid-stack-20>.grid-stack-item[data-gs-x="8"]{left:40%}.grid-stack.grid-stack-20>.grid-stack-item[data-gs-min-width="8"]{min-width:40%}.grid-stack.grid-stack-20>.grid-stack-item[data-gs-max-width="8"]{max-width:40%}.grid-stack.grid-stack-20>.grid-stack-item[data-gs-width="9"]{width:45%}.grid-stack.grid-stack-20>.grid-stack-item[data-gs-x="9"]{left:45%}.grid-stack.grid-stack-20>.grid-stack-item[data-gs-min-width="9"]{min-width:45%}.grid-stack.grid-stack-20>.grid-stack-item[data-gs-max-width="9"]{max-width:45%}.grid-stack.grid-stack-20>.grid-stack-item[data-gs-width="10"]{width:50%}.grid-stack.grid-stack-20>.grid-stack-item[data-gs-x="10"]{left:50%}.grid-stack.grid-stack-20>.grid-stack-item[data-gs-min-width="10"]{min-width:50%}.grid-stack.grid-stack-20>.grid-stack-item[data-gs-max-width="10"]{max-width:50%}.grid-stack.grid-stack-20>.grid-stack-item[data-gs-width="11"]{width:55%}.grid-stack.grid-stack-20>.grid-stack-item[data-gs-x="11"]{left:55%}.grid-stack.grid-stack-20>.grid-stack-item[data-gs-min-width="11"]{min-width:55%}.grid-stack.grid-stack-20>.grid-stack-item[data-gs-max-width="11"]{max-width:55%}.grid-stack.grid-stack-20>.grid-stack-item[data-gs-width="12"]{width:60%}.grid-stack.grid-stack-20>.grid-stack-item[data-gs-x="12"]{left:60%}.grid-stack.grid-stack-20>.grid-stack-item[data-gs-min-width="12"]{min-width:60%}.grid-stack.grid-stack-20>.grid-stack-item[data-gs-max-width="12"]{max-width:60%}.grid-stack.grid-stack-20>.grid-stack-item[data-gs-width="13"]{width:65%}.grid-stack.grid-stack-20>.grid-stack-item[data-gs-x="13"]{left:65%}.grid-stack.grid-stack-20>.grid-stack-item[data-gs-min-width="13"]{min-width:65%}.grid-stack.grid-stack-20>.grid-stack-item[data-gs-max-width="13"]{max-width:65%}.grid-stack.grid-stack-20>.grid-stack-item[data-gs-width="14"]{width:70%}.grid-stack.grid-stack-20>.grid-stack-item[data-gs-x="14"]{left:70%}.grid-stack.grid-stack-20>.grid-stack-item[data-gs-min-width="14"]{min-width:70%}.grid-stack.grid-stack-20>.grid-stack-item[data-gs-max-width="14"]{max-width:70%}.grid-stack.grid-stack-20>.grid-stack-item[data-gs-width="15"]{width:75%}.grid-stack.grid-stack-20>.grid-stack-item[data-gs-x="15"]{left:75%}.grid-stack.grid-stack-20>.grid-stack-item[data-gs-min-width="15"]{min-width:75%}.grid-stack.grid-stack-20>.grid-stack-item[data-gs-max-width="15"]{max-width:75%}.grid-stack.grid-stack-20>.grid-stack-item[data-gs-width="16"]{width:80%}.grid-stack.grid-stack-20>.grid-stack-item[data-gs-x="16"]{left:80%}.grid-stack.grid-stack-20>.grid-stack-item[data-gs-min-width="16"]{min-width:80%}.grid-stack.grid-stack-20>.grid-stack-item[data-gs-max-width="16"]{max-width:80%}.grid-stack.grid-stack-20>.grid-stack-item[data-gs-width="17"]{width:85%}.grid-stack.grid-stack-20>.grid-stack-item[data-gs-x="17"]{left:85%}.grid-stack.grid-stack-20>.grid-stack-item[data-gs-min-width="17"]{min-width:85%}.grid-stack.grid-stack-20>.grid-stack-item[data-gs-max-width="17"]{max-width:85%}.grid-stack.grid-stack-20>.grid-stack-item[data-gs-width="18"]{width:90%}.grid-stack.grid-stack-20>.grid-stack-item[data-gs-x="18"]{left:90%}.grid-stack.grid-stack-20>.grid-stack-item[data-gs-min-width="18"]{min-width:90%}.grid-stack.grid-stack-20>.grid-stack-item[data-gs-max-width="18"]{max-width:90%}.grid-stack.grid-stack-20>.grid-stack-item[data-gs-width="19"]{width:95%}.grid-stack.grid-stack-20>.grid-stack-item[data-gs-x="19"]{left:95%}.grid-stack.grid-stack-20>.grid-stack-item[data-gs-min-width="19"]{min-width:95%}.grid-stack.grid-stack-20>.grid-stack-item[data-gs-max-width="19"]{max-width:95%}.grid-stack.grid-stack-20>.grid-stack-item[data-gs-width="20"]{width:100%}.grid-stack.grid-stack-20>.grid-stack-item[data-gs-x="20"]{left:100%}.grid-stack.grid-stack-20>.grid-stack-item[data-gs-min-width="20"]{min-width:100%}.grid-stack.grid-stack-20>.grid-stack-item[data-gs-max-width="20"]{max-width:100%}.grid-stack.grid-stack-21>.grid-stack-item{min-width:4.7619047619%}.grid-stack.grid-stack-21>.grid-stack-item[data-gs-width="1"]{width:4.7619047619%}.grid-stack.grid-stack-21>.grid-stack-item[data-gs-x="1"]{left:4.7619047619%}.grid-stack.grid-stack-21>.grid-stack-item[data-gs-min-width="1"]{min-width:4.7619047619%}.grid-stack.grid-stack-21>.grid-stack-item[data-gs-max-width="1"]{max-width:4.7619047619%}.grid-stack.grid-stack-21>.grid-stack-item[data-gs-width="2"]{width:9.5238095238%}.grid-stack.grid-stack-21>.grid-stack-item[data-gs-x="2"]{left:9.5238095238%}.grid-stack.grid-stack-21>.grid-stack-item[data-gs-min-width="2"]{min-width:9.5238095238%}.grid-stack.grid-stack-21>.grid-stack-item[data-gs-max-width="2"]{max-width:9.5238095238%}.grid-stack.grid-stack-21>.grid-stack-item[data-gs-width="3"]{width:14.2857142857%}.grid-stack.grid-stack-21>.grid-stack-item[data-gs-x="3"]{left:14.2857142857%}.grid-stack.grid-stack-21>.grid-stack-item[data-gs-min-width="3"]{min-width:14.2857142857%}.grid-stack.grid-stack-21>.grid-stack-item[data-gs-max-width="3"]{max-width:14.2857142857%}.grid-stack.grid-stack-21>.grid-stack-item[data-gs-width="4"]{width:19.0476190476%}.grid-stack.grid-stack-21>.grid-stack-item[data-gs-x="4"]{left:19.0476190476%}.grid-stack.grid-stack-21>.grid-stack-item[data-gs-min-width="4"]{min-width:19.0476190476%}.grid-stack.grid-stack-21>.grid-stack-item[data-gs-max-width="4"]{max-width:19.0476190476%}.grid-stack.grid-stack-21>.grid-stack-item[data-gs-width="5"]{width:23.8095238095%}.grid-stack.grid-stack-21>.grid-stack-item[data-gs-x="5"]{left:23.8095238095%}.grid-stack.grid-stack-21>.grid-stack-item[data-gs-min-width="5"]{min-width:23.8095238095%}.grid-stack.grid-stack-21>.grid-stack-item[data-gs-max-width="5"]{max-width:23.8095238095%}.grid-stack.grid-stack-21>.grid-stack-item[data-gs-width="6"]{width:28.5714285714%}.grid-stack.grid-stack-21>.grid-stack-item[data-gs-x="6"]{left:28.5714285714%}.grid-stack.grid-stack-21>.grid-stack-item[data-gs-min-width="6"]{min-width:28.5714285714%}.grid-stack.grid-stack-21>.grid-stack-item[data-gs-max-width="6"]{max-width:28.5714285714%}.grid-stack.grid-stack-21>.grid-stack-item[data-gs-width="7"]{width:33.3333333333%}.grid-stack.grid-stack-21>.grid-stack-item[data-gs-x="7"]{left:33.3333333333%}.grid-stack.grid-stack-21>.grid-stack-item[data-gs-min-width="7"]{min-width:33.3333333333%}.grid-stack.grid-stack-21>.grid-stack-item[data-gs-max-width="7"]{max-width:33.3333333333%}.grid-stack.grid-stack-21>.grid-stack-item[data-gs-width="8"]{width:38.0952380952%}.grid-stack.grid-stack-21>.grid-stack-item[data-gs-x="8"]{left:38.0952380952%}.grid-stack.grid-stack-21>.grid-stack-item[data-gs-min-width="8"]{min-width:38.0952380952%}.grid-stack.grid-stack-21>.grid-stack-item[data-gs-max-width="8"]{max-width:38.0952380952%}.grid-stack.grid-stack-21>.grid-stack-item[data-gs-width="9"]{width:42.8571428571%}.grid-stack.grid-stack-21>.grid-stack-item[data-gs-x="9"]{left:42.8571428571%}.grid-stack.grid-stack-21>.grid-stack-item[data-gs-min-width="9"]{min-width:42.8571428571%}.grid-stack.grid-stack-21>.grid-stack-item[data-gs-max-width="9"]{max-width:42.8571428571%}.grid-stack.grid-stack-21>.grid-stack-item[data-gs-width="10"]{width:47.619047619%}.grid-stack.grid-stack-21>.grid-stack-item[data-gs-x="10"]{left:47.619047619%}.grid-stack.grid-stack-21>.grid-stack-item[data-gs-min-width="10"]{min-width:47.619047619%}.grid-stack.grid-stack-21>.grid-stack-item[data-gs-max-width="10"]{max-width:47.619047619%}.grid-stack.grid-stack-21>.grid-stack-item[data-gs-width="11"]{width:52.380952381%}.grid-stack.grid-stack-21>.grid-stack-item[data-gs-x="11"]{left:52.380952381%}.grid-stack.grid-stack-21>.grid-stack-item[data-gs-min-width="11"]{min-width:52.380952381%}.grid-stack.grid-stack-21>.grid-stack-item[data-gs-max-width="11"]{max-width:52.380952381%}.grid-stack.grid-stack-21>.grid-stack-item[data-gs-width="12"]{width:57.1428571429%}.grid-stack.grid-stack-21>.grid-stack-item[data-gs-x="12"]{left:57.1428571429%}.grid-stack.grid-stack-21>.grid-stack-item[data-gs-min-width="12"]{min-width:57.1428571429%}.grid-stack.grid-stack-21>.grid-stack-item[data-gs-max-width="12"]{max-width:57.1428571429%}.grid-stack.grid-stack-21>.grid-stack-item[data-gs-width="13"]{width:61.9047619048%}.grid-stack.grid-stack-21>.grid-stack-item[data-gs-x="13"]{left:61.9047619048%}.grid-stack.grid-stack-21>.grid-stack-item[data-gs-min-width="13"]{min-width:61.9047619048%}.grid-stack.grid-stack-21>.grid-stack-item[data-gs-max-width="13"]{max-width:61.9047619048%}.grid-stack.grid-stack-21>.grid-stack-item[data-gs-width="14"]{width:66.6666666667%}.grid-stack.grid-stack-21>.grid-stack-item[data-gs-x="14"]{left:66.6666666667%}.grid-stack.grid-stack-21>.grid-stack-item[data-gs-min-width="14"]{min-width:66.6666666667%}.grid-stack.grid-stack-21>.grid-stack-item[data-gs-max-width="14"]{max-width:66.6666666667%}.grid-stack.grid-stack-21>.grid-stack-item[data-gs-width="15"]{width:71.4285714286%}.grid-stack.grid-stack-21>.grid-stack-item[data-gs-x="15"]{left:71.4285714286%}.grid-stack.grid-stack-21>.grid-stack-item[data-gs-min-width="15"]{min-width:71.4285714286%}.grid-stack.grid-stack-21>.grid-stack-item[data-gs-max-width="15"]{max-width:71.4285714286%}.grid-stack.grid-stack-21>.grid-stack-item[data-gs-width="16"]{width:76.1904761905%}.grid-stack.grid-stack-21>.grid-stack-item[data-gs-x="16"]{left:76.1904761905%}.grid-stack.grid-stack-21>.grid-stack-item[data-gs-min-width="16"]{min-width:76.1904761905%}.grid-stack.grid-stack-21>.grid-stack-item[data-gs-max-width="16"]{max-width:76.1904761905%}.grid-stack.grid-stack-21>.grid-stack-item[data-gs-width="17"]{width:80.9523809524%}.grid-stack.grid-stack-21>.grid-stack-item[data-gs-x="17"]{left:80.9523809524%}.grid-stack.grid-stack-21>.grid-stack-item[data-gs-min-width="17"]{min-width:80.9523809524%}.grid-stack.grid-stack-21>.grid-stack-item[data-gs-max-width="17"]{max-width:80.9523809524%}.grid-stack.grid-stack-21>.grid-stack-item[data-gs-width="18"]{width:85.7142857143%}.grid-stack.grid-stack-21>.grid-stack-item[data-gs-x="18"]{left:85.7142857143%}.grid-stack.grid-stack-21>.grid-stack-item[data-gs-min-width="18"]{min-width:85.7142857143%}.grid-stack.grid-stack-21>.grid-stack-item[data-gs-max-width="18"]{max-width:85.7142857143%}.grid-stack.grid-stack-21>.grid-stack-item[data-gs-width="19"]{width:90.4761904762%}.grid-stack.grid-stack-21>.grid-stack-item[data-gs-x="19"]{left:90.4761904762%}.grid-stack.grid-stack-21>.grid-stack-item[data-gs-min-width="19"]{min-width:90.4761904762%}.grid-stack.grid-stack-21>.grid-stack-item[data-gs-max-width="19"]{max-width:90.4761904762%}.grid-stack.grid-stack-21>.grid-stack-item[data-gs-width="20"]{width:95.2380952381%}.grid-stack.grid-stack-21>.grid-stack-item[data-gs-x="20"]{left:95.2380952381%}.grid-stack.grid-stack-21>.grid-stack-item[data-gs-min-width="20"]{min-width:95.2380952381%}.grid-stack.grid-stack-21>.grid-stack-item[data-gs-max-width="20"]{max-width:95.2380952381%}.grid-stack.grid-stack-21>.grid-stack-item[data-gs-width="21"]{width:100%}.grid-stack.grid-stack-21>.grid-stack-item[data-gs-x="21"]{left:100%}.grid-stack.grid-stack-21>.grid-stack-item[data-gs-min-width="21"]{min-width:100%}.grid-stack.grid-stack-21>.grid-stack-item[data-gs-max-width="21"]{max-width:100%}.grid-stack.grid-stack-22>.grid-stack-item{min-width:4.5454545455%}.grid-stack.grid-stack-22>.grid-stack-item[data-gs-width="1"]{width:4.5454545455%}.grid-stack.grid-stack-22>.grid-stack-item[data-gs-x="1"]{left:4.5454545455%}.grid-stack.grid-stack-22>.grid-stack-item[data-gs-min-width="1"]{min-width:4.5454545455%}.grid-stack.grid-stack-22>.grid-stack-item[data-gs-max-width="1"]{max-width:4.5454545455%}.grid-stack.grid-stack-22>.grid-stack-item[data-gs-width="2"]{width:9.0909090909%}.grid-stack.grid-stack-22>.grid-stack-item[data-gs-x="2"]{left:9.0909090909%}.grid-stack.grid-stack-22>.grid-stack-item[data-gs-min-width="2"]{min-width:9.0909090909%}.grid-stack.grid-stack-22>.grid-stack-item[data-gs-max-width="2"]{max-width:9.0909090909%}.grid-stack.grid-stack-22>.grid-stack-item[data-gs-width="3"]{width:13.6363636364%}.grid-stack.grid-stack-22>.grid-stack-item[data-gs-x="3"]{left:13.6363636364%}.grid-stack.grid-stack-22>.grid-stack-item[data-gs-min-width="3"]{min-width:13.6363636364%}.grid-stack.grid-stack-22>.grid-stack-item[data-gs-max-width="3"]{max-width:13.6363636364%}.grid-stack.grid-stack-22>.grid-stack-item[data-gs-width="4"]{width:18.1818181818%}.grid-stack.grid-stack-22>.grid-stack-item[data-gs-x="4"]{left:18.1818181818%}.grid-stack.grid-stack-22>.grid-stack-item[data-gs-min-width="4"]{min-width:18.1818181818%}.grid-stack.grid-stack-22>.grid-stack-item[data-gs-max-width="4"]{max-width:18.1818181818%}.grid-stack.grid-stack-22>.grid-stack-item[data-gs-width="5"]{width:22.7272727273%}.grid-stack.grid-stack-22>.grid-stack-item[data-gs-x="5"]{left:22.7272727273%}.grid-stack.grid-stack-22>.grid-stack-item[data-gs-min-width="5"]{min-width:22.7272727273%}.grid-stack.grid-stack-22>.grid-stack-item[data-gs-max-width="5"]{max-width:22.7272727273%}.grid-stack.grid-stack-22>.grid-stack-item[data-gs-width="6"]{width:27.2727272727%}.grid-stack.grid-stack-22>.grid-stack-item[data-gs-x="6"]{left:27.2727272727%}.grid-stack.grid-stack-22>.grid-stack-item[data-gs-min-width="6"]{min-width:27.2727272727%}.grid-stack.grid-stack-22>.grid-stack-item[data-gs-max-width="6"]{max-width:27.2727272727%}.grid-stack.grid-stack-22>.grid-stack-item[data-gs-width="7"]{width:31.8181818182%}.grid-stack.grid-stack-22>.grid-stack-item[data-gs-x="7"]{left:31.8181818182%}.grid-stack.grid-stack-22>.grid-stack-item[data-gs-min-width="7"]{min-width:31.8181818182%}.grid-stack.grid-stack-22>.grid-stack-item[data-gs-max-width="7"]{max-width:31.8181818182%}.grid-stack.grid-stack-22>.grid-stack-item[data-gs-width="8"]{width:36.3636363636%}.grid-stack.grid-stack-22>.grid-stack-item[data-gs-x="8"]{left:36.3636363636%}.grid-stack.grid-stack-22>.grid-stack-item[data-gs-min-width="8"]{min-width:36.3636363636%}.grid-stack.grid-stack-22>.grid-stack-item[data-gs-max-width="8"]{max-width:36.3636363636%}.grid-stack.grid-stack-22>.grid-stack-item[data-gs-width="9"]{width:40.9090909091%}.grid-stack.grid-stack-22>.grid-stack-item[data-gs-x="9"]{left:40.9090909091%}.grid-stack.grid-stack-22>.grid-stack-item[data-gs-min-width="9"]{min-width:40.9090909091%}.grid-stack.grid-stack-22>.grid-stack-item[data-gs-max-width="9"]{max-width:40.9090909091%}.grid-stack.grid-stack-22>.grid-stack-item[data-gs-width="10"]{width:45.4545454545%}.grid-stack.grid-stack-22>.grid-stack-item[data-gs-x="10"]{left:45.4545454545%}.grid-stack.grid-stack-22>.grid-stack-item[data-gs-min-width="10"]{min-width:45.4545454545%}.grid-stack.grid-stack-22>.grid-stack-item[data-gs-max-width="10"]{max-width:45.4545454545%}.grid-stack.grid-stack-22>.grid-stack-item[data-gs-width="11"]{width:50%}.grid-stack.grid-stack-22>.grid-stack-item[data-gs-x="11"]{left:50%}.grid-stack.grid-stack-22>.grid-stack-item[data-gs-min-width="11"]{min-width:50%}.grid-stack.grid-stack-22>.grid-stack-item[data-gs-max-width="11"]{max-width:50%}.grid-stack.grid-stack-22>.grid-stack-item[data-gs-width="12"]{width:54.5454545455%}.grid-stack.grid-stack-22>.grid-stack-item[data-gs-x="12"]{left:54.5454545455%}.grid-stack.grid-stack-22>.grid-stack-item[data-gs-min-width="12"]{min-width:54.5454545455%}.grid-stack.grid-stack-22>.grid-stack-item[data-gs-max-width="12"]{max-width:54.5454545455%}.grid-stack.grid-stack-22>.grid-stack-item[data-gs-width="13"]{width:59.0909090909%}.grid-stack.grid-stack-22>.grid-stack-item[data-gs-x="13"]{left:59.0909090909%}.grid-stack.grid-stack-22>.grid-stack-item[data-gs-min-width="13"]{min-width:59.0909090909%}.grid-stack.grid-stack-22>.grid-stack-item[data-gs-max-width="13"]{max-width:59.0909090909%}.grid-stack.grid-stack-22>.grid-stack-item[data-gs-width="14"]{width:63.6363636364%}.grid-stack.grid-stack-22>.grid-stack-item[data-gs-x="14"]{left:63.6363636364%}.grid-stack.grid-stack-22>.grid-stack-item[data-gs-min-width="14"]{min-width:63.6363636364%}.grid-stack.grid-stack-22>.grid-stack-item[data-gs-max-width="14"]{max-width:63.6363636364%}.grid-stack.grid-stack-22>.grid-stack-item[data-gs-width="15"]{width:68.1818181818%}.grid-stack.grid-stack-22>.grid-stack-item[data-gs-x="15"]{left:68.1818181818%}.grid-stack.grid-stack-22>.grid-stack-item[data-gs-min-width="15"]{min-width:68.1818181818%}.grid-stack.grid-stack-22>.grid-stack-item[data-gs-max-width="15"]{max-width:68.1818181818%}.grid-stack.grid-stack-22>.grid-stack-item[data-gs-width="16"]{width:72.7272727273%}.grid-stack.grid-stack-22>.grid-stack-item[data-gs-x="16"]{left:72.7272727273%}.grid-stack.grid-stack-22>.grid-stack-item[data-gs-min-width="16"]{min-width:72.7272727273%}.grid-stack.grid-stack-22>.grid-stack-item[data-gs-max-width="16"]{max-width:72.7272727273%}.grid-stack.grid-stack-22>.grid-stack-item[data-gs-width="17"]{width:77.2727272727%}.grid-stack.grid-stack-22>.grid-stack-item[data-gs-x="17"]{left:77.2727272727%}.grid-stack.grid-stack-22>.grid-stack-item[data-gs-min-width="17"]{min-width:77.2727272727%}.grid-stack.grid-stack-22>.grid-stack-item[data-gs-max-width="17"]{max-width:77.2727272727%}.grid-stack.grid-stack-22>.grid-stack-item[data-gs-width="18"]{width:81.8181818182%}.grid-stack.grid-stack-22>.grid-stack-item[data-gs-x="18"]{left:81.8181818182%}.grid-stack.grid-stack-22>.grid-stack-item[data-gs-min-width="18"]{min-width:81.8181818182%}.grid-stack.grid-stack-22>.grid-stack-item[data-gs-max-width="18"]{max-width:81.8181818182%}.grid-stack.grid-stack-22>.grid-stack-item[data-gs-width="19"]{width:86.3636363636%}.grid-stack.grid-stack-22>.grid-stack-item[data-gs-x="19"]{left:86.3636363636%}.grid-stack.grid-stack-22>.grid-stack-item[data-gs-min-width="19"]{min-width:86.3636363636%}.grid-stack.grid-stack-22>.grid-stack-item[data-gs-max-width="19"]{max-width:86.3636363636%}.grid-stack.grid-stack-22>.grid-stack-item[data-gs-width="20"]{width:90.9090909091%}.grid-stack.grid-stack-22>.grid-stack-item[data-gs-x="20"]{left:90.9090909091%}.grid-stack.grid-stack-22>.grid-stack-item[data-gs-min-width="20"]{min-width:90.9090909091%}.grid-stack.grid-stack-22>.grid-stack-item[data-gs-max-width="20"]{max-width:90.9090909091%}.grid-stack.grid-stack-22>.grid-stack-item[data-gs-width="21"]{width:95.4545454545%}.grid-stack.grid-stack-22>.grid-stack-item[data-gs-x="21"]{left:95.4545454545%}.grid-stack.grid-stack-22>.grid-stack-item[data-gs-min-width="21"]{min-width:95.4545454545%}.grid-stack.grid-stack-22>.grid-stack-item[data-gs-max-width="21"]{max-width:95.4545454545%}.grid-stack.grid-stack-22>.grid-stack-item[data-gs-width="22"]{width:100%}.grid-stack.grid-stack-22>.grid-stack-item[data-gs-x="22"]{left:100%}.grid-stack.grid-stack-22>.grid-stack-item[data-gs-min-width="22"]{min-width:100%}.grid-stack.grid-stack-22>.grid-stack-item[data-gs-max-width="22"]{max-width:100%}.grid-stack.grid-stack-23>.grid-stack-item{min-width:4.347826087%}.grid-stack.grid-stack-23>.grid-stack-item[data-gs-width="1"]{width:4.347826087%}.grid-stack.grid-stack-23>.grid-stack-item[data-gs-x="1"]{left:4.347826087%}.grid-stack.grid-stack-23>.grid-stack-item[data-gs-min-width="1"]{min-width:4.347826087%}.grid-stack.grid-stack-23>.grid-stack-item[data-gs-max-width="1"]{max-width:4.347826087%}.grid-stack.grid-stack-23>.grid-stack-item[data-gs-width="2"]{width:8.6956521739%}.grid-stack.grid-stack-23>.grid-stack-item[data-gs-x="2"]{left:8.6956521739%}.grid-stack.grid-stack-23>.grid-stack-item[data-gs-min-width="2"]{min-width:8.6956521739%}.grid-stack.grid-stack-23>.grid-stack-item[data-gs-max-width="2"]{max-width:8.6956521739%}.grid-stack.grid-stack-23>.grid-stack-item[data-gs-width="3"]{width:13.0434782609%}.grid-stack.grid-stack-23>.grid-stack-item[data-gs-x="3"]{left:13.0434782609%}.grid-stack.grid-stack-23>.grid-stack-item[data-gs-min-width="3"]{min-width:13.0434782609%}.grid-stack.grid-stack-23>.grid-stack-item[data-gs-max-width="3"]{max-width:13.0434782609%}.grid-stack.grid-stack-23>.grid-stack-item[data-gs-width="4"]{width:17.3913043478%}.grid-stack.grid-stack-23>.grid-stack-item[data-gs-x="4"]{left:17.3913043478%}.grid-stack.grid-stack-23>.grid-stack-item[data-gs-min-width="4"]{min-width:17.3913043478%}.grid-stack.grid-stack-23>.grid-stack-item[data-gs-max-width="4"]{max-width:17.3913043478%}.grid-stack.grid-stack-23>.grid-stack-item[data-gs-width="5"]{width:21.7391304348%}.grid-stack.grid-stack-23>.grid-stack-item[data-gs-x="5"]{left:21.7391304348%}.grid-stack.grid-stack-23>.grid-stack-item[data-gs-min-width="5"]{min-width:21.7391304348%}.grid-stack.grid-stack-23>.grid-stack-item[data-gs-max-width="5"]{max-width:21.7391304348%}.grid-stack.grid-stack-23>.grid-stack-item[data-gs-width="6"]{width:26.0869565217%}.grid-stack.grid-stack-23>.grid-stack-item[data-gs-x="6"]{left:26.0869565217%}.grid-stack.grid-stack-23>.grid-stack-item[data-gs-min-width="6"]{min-width:26.0869565217%}.grid-stack.grid-stack-23>.grid-stack-item[data-gs-max-width="6"]{max-width:26.0869565217%}.grid-stack.grid-stack-23>.grid-stack-item[data-gs-width="7"]{width:30.4347826087%}.grid-stack.grid-stack-23>.grid-stack-item[data-gs-x="7"]{left:30.4347826087%}.grid-stack.grid-stack-23>.grid-stack-item[data-gs-min-width="7"]{min-width:30.4347826087%}.grid-stack.grid-stack-23>.grid-stack-item[data-gs-max-width="7"]{max-width:30.4347826087%}.grid-stack.grid-stack-23>.grid-stack-item[data-gs-width="8"]{width:34.7826086957%}.grid-stack.grid-stack-23>.grid-stack-item[data-gs-x="8"]{left:34.7826086957%}.grid-stack.grid-stack-23>.grid-stack-item[data-gs-min-width="8"]{min-width:34.7826086957%}.grid-stack.grid-stack-23>.grid-stack-item[data-gs-max-width="8"]{max-width:34.7826086957%}.grid-stack.grid-stack-23>.grid-stack-item[data-gs-width="9"]{width:39.1304347826%}.grid-stack.grid-stack-23>.grid-stack-item[data-gs-x="9"]{left:39.1304347826%}.grid-stack.grid-stack-23>.grid-stack-item[data-gs-min-width="9"]{min-width:39.1304347826%}.grid-stack.grid-stack-23>.grid-stack-item[data-gs-max-width="9"]{max-width:39.1304347826%}.grid-stack.grid-stack-23>.grid-stack-item[data-gs-width="10"]{width:43.4782608696%}.grid-stack.grid-stack-23>.grid-stack-item[data-gs-x="10"]{left:43.4782608696%}.grid-stack.grid-stack-23>.grid-stack-item[data-gs-min-width="10"]{min-width:43.4782608696%}.grid-stack.grid-stack-23>.grid-stack-item[data-gs-max-width="10"]{max-width:43.4782608696%}.grid-stack.grid-stack-23>.grid-stack-item[data-gs-width="11"]{width:47.8260869565%}.grid-stack.grid-stack-23>.grid-stack-item[data-gs-x="11"]{left:47.8260869565%}.grid-stack.grid-stack-23>.grid-stack-item[data-gs-min-width="11"]{min-width:47.8260869565%}.grid-stack.grid-stack-23>.grid-stack-item[data-gs-max-width="11"]{max-width:47.8260869565%}.grid-stack.grid-stack-23>.grid-stack-item[data-gs-width="12"]{width:52.1739130435%}.grid-stack.grid-stack-23>.grid-stack-item[data-gs-x="12"]{left:52.1739130435%}.grid-stack.grid-stack-23>.grid-stack-item[data-gs-min-width="12"]{min-width:52.1739130435%}.grid-stack.grid-stack-23>.grid-stack-item[data-gs-max-width="12"]{max-width:52.1739130435%}.grid-stack.grid-stack-23>.grid-stack-item[data-gs-width="13"]{width:56.5217391304%}.grid-stack.grid-stack-23>.grid-stack-item[data-gs-x="13"]{left:56.5217391304%}.grid-stack.grid-stack-23>.grid-stack-item[data-gs-min-width="13"]{min-width:56.5217391304%}.grid-stack.grid-stack-23>.grid-stack-item[data-gs-max-width="13"]{max-width:56.5217391304%}.grid-stack.grid-stack-23>.grid-stack-item[data-gs-width="14"]{width:60.8695652174%}.grid-stack.grid-stack-23>.grid-stack-item[data-gs-x="14"]{left:60.8695652174%}.grid-stack.grid-stack-23>.grid-stack-item[data-gs-min-width="14"]{min-width:60.8695652174%}.grid-stack.grid-stack-23>.grid-stack-item[data-gs-max-width="14"]{max-width:60.8695652174%}.grid-stack.grid-stack-23>.grid-stack-item[data-gs-width="15"]{width:65.2173913043%}.grid-stack.grid-stack-23>.grid-stack-item[data-gs-x="15"]{left:65.2173913043%}.grid-stack.grid-stack-23>.grid-stack-item[data-gs-min-width="15"]{min-width:65.2173913043%}.grid-stack.grid-stack-23>.grid-stack-item[data-gs-max-width="15"]{max-width:65.2173913043%}.grid-stack.grid-stack-23>.grid-stack-item[data-gs-width="16"]{width:69.5652173913%}.grid-stack.grid-stack-23>.grid-stack-item[data-gs-x="16"]{left:69.5652173913%}.grid-stack.grid-stack-23>.grid-stack-item[data-gs-min-width="16"]{min-width:69.5652173913%}.grid-stack.grid-stack-23>.grid-stack-item[data-gs-max-width="16"]{max-width:69.5652173913%}.grid-stack.grid-stack-23>.grid-stack-item[data-gs-width="17"]{width:73.9130434783%}.grid-stack.grid-stack-23>.grid-stack-item[data-gs-x="17"]{left:73.9130434783%}.grid-stack.grid-stack-23>.grid-stack-item[data-gs-min-width="17"]{min-width:73.9130434783%}.grid-stack.grid-stack-23>.grid-stack-item[data-gs-max-width="17"]{max-width:73.9130434783%}.grid-stack.grid-stack-23>.grid-stack-item[data-gs-width="18"]{width:78.2608695652%}.grid-stack.grid-stack-23>.grid-stack-item[data-gs-x="18"]{left:78.2608695652%}.grid-stack.grid-stack-23>.grid-stack-item[data-gs-min-width="18"]{min-width:78.2608695652%}.grid-stack.grid-stack-23>.grid-stack-item[data-gs-max-width="18"]{max-width:78.2608695652%}.grid-stack.grid-stack-23>.grid-stack-item[data-gs-width="19"]{width:82.6086956522%}.grid-stack.grid-stack-23>.grid-stack-item[data-gs-x="19"]{left:82.6086956522%}.grid-stack.grid-stack-23>.grid-stack-item[data-gs-min-width="19"]{min-width:82.6086956522%}.grid-stack.grid-stack-23>.grid-stack-item[data-gs-max-width="19"]{max-width:82.6086956522%}.grid-stack.grid-stack-23>.grid-stack-item[data-gs-width="20"]{width:86.9565217391%}.grid-stack.grid-stack-23>.grid-stack-item[data-gs-x="20"]{left:86.9565217391%}.grid-stack.grid-stack-23>.grid-stack-item[data-gs-min-width="20"]{min-width:86.9565217391%}.grid-stack.grid-stack-23>.grid-stack-item[data-gs-max-width="20"]{max-width:86.9565217391%}.grid-stack.grid-stack-23>.grid-stack-item[data-gs-width="21"]{width:91.3043478261%}.grid-stack.grid-stack-23>.grid-stack-item[data-gs-x="21"]{left:91.3043478261%}.grid-stack.grid-stack-23>.grid-stack-item[data-gs-min-width="21"]{min-width:91.3043478261%}.grid-stack.grid-stack-23>.grid-stack-item[data-gs-max-width="21"]{max-width:91.3043478261%}.grid-stack.grid-stack-23>.grid-stack-item[data-gs-width="22"]{width:95.652173913%}.grid-stack.grid-stack-23>.grid-stack-item[data-gs-x="22"]{left:95.652173913%}.grid-stack.grid-stack-23>.grid-stack-item[data-gs-min-width="22"]{min-width:95.652173913%}.grid-stack.grid-stack-23>.grid-stack-item[data-gs-max-width="22"]{max-width:95.652173913%}.grid-stack.grid-stack-23>.grid-stack-item[data-gs-width="23"]{width:100%}.grid-stack.grid-stack-23>.grid-stack-item[data-gs-x="23"]{left:100%}.grid-stack.grid-stack-23>.grid-stack-item[data-gs-min-width="23"]{min-width:100%}.grid-stack.grid-stack-23>.grid-stack-item[data-gs-max-width="23"]{max-width:100%}.grid-stack.grid-stack-24>.grid-stack-item{min-width:4.1666666667%}.grid-stack.grid-stack-24>.grid-stack-item[data-gs-width="1"]{width:4.1666666667%}.grid-stack.grid-stack-24>.grid-stack-item[data-gs-x="1"]{left:4.1666666667%}.grid-stack.grid-stack-24>.grid-stack-item[data-gs-min-width="1"]{min-width:4.1666666667%}.grid-stack.grid-stack-24>.grid-stack-item[data-gs-max-width="1"]{max-width:4.1666666667%}.grid-stack.grid-stack-24>.grid-stack-item[data-gs-width="2"]{width:8.3333333333%}.grid-stack.grid-stack-24>.grid-stack-item[data-gs-x="2"]{left:8.3333333333%}.grid-stack.grid-stack-24>.grid-stack-item[data-gs-min-width="2"]{min-width:8.3333333333%}.grid-stack.grid-stack-24>.grid-stack-item[data-gs-max-width="2"]{max-width:8.3333333333%}.grid-stack.grid-stack-24>.grid-stack-item[data-gs-width="3"]{width:12.5%}.grid-stack.grid-stack-24>.grid-stack-item[data-gs-x="3"]{left:12.5%}.grid-stack.grid-stack-24>.grid-stack-item[data-gs-min-width="3"]{min-width:12.5%}.grid-stack.grid-stack-24>.grid-stack-item[data-gs-max-width="3"]{max-width:12.5%}.grid-stack.grid-stack-24>.grid-stack-item[data-gs-width="4"]{width:16.6666666667%}.grid-stack.grid-stack-24>.grid-stack-item[data-gs-x="4"]{left:16.6666666667%}.grid-stack.grid-stack-24>.grid-stack-item[data-gs-min-width="4"]{min-width:16.6666666667%}.grid-stack.grid-stack-24>.grid-stack-item[data-gs-max-width="4"]{max-width:16.6666666667%}.grid-stack.grid-stack-24>.grid-stack-item[data-gs-width="5"]{width:20.8333333333%}.grid-stack.grid-stack-24>.grid-stack-item[data-gs-x="5"]{left:20.8333333333%}.grid-stack.grid-stack-24>.grid-stack-item[data-gs-min-width="5"]{min-width:20.8333333333%}.grid-stack.grid-stack-24>.grid-stack-item[data-gs-max-width="5"]{max-width:20.8333333333%}.grid-stack.grid-stack-24>.grid-stack-item[data-gs-width="6"]{width:25%}.grid-stack.grid-stack-24>.grid-stack-item[data-gs-x="6"]{left:25%}.grid-stack.grid-stack-24>.grid-stack-item[data-gs-min-width="6"]{min-width:25%}.grid-stack.grid-stack-24>.grid-stack-item[data-gs-max-width="6"]{max-width:25%}.grid-stack.grid-stack-24>.grid-stack-item[data-gs-width="7"]{width:29.1666666667%}.grid-stack.grid-stack-24>.grid-stack-item[data-gs-x="7"]{left:29.1666666667%}.grid-stack.grid-stack-24>.grid-stack-item[data-gs-min-width="7"]{min-width:29.1666666667%}.grid-stack.grid-stack-24>.grid-stack-item[data-gs-max-width="7"]{max-width:29.1666666667%}.grid-stack.grid-stack-24>.grid-stack-item[data-gs-width="8"]{width:33.3333333333%}.grid-stack.grid-stack-24>.grid-stack-item[data-gs-x="8"]{left:33.3333333333%}.grid-stack.grid-stack-24>.grid-stack-item[data-gs-min-width="8"]{min-width:33.3333333333%}.grid-stack.grid-stack-24>.grid-stack-item[data-gs-max-width="8"]{max-width:33.3333333333%}.grid-stack.grid-stack-24>.grid-stack-item[data-gs-width="9"]{width:37.5%}.grid-stack.grid-stack-24>.grid-stack-item[data-gs-x="9"]{left:37.5%}.grid-stack.grid-stack-24>.grid-stack-item[data-gs-min-width="9"]{min-width:37.5%}.grid-stack.grid-stack-24>.grid-stack-item[data-gs-max-width="9"]{max-width:37.5%}.grid-stack.grid-stack-24>.grid-stack-item[data-gs-width="10"]{width:41.6666666667%}.grid-stack.grid-stack-24>.grid-stack-item[data-gs-x="10"]{left:41.6666666667%}.grid-stack.grid-stack-24>.grid-stack-item[data-gs-min-width="10"]{min-width:41.6666666667%}.grid-stack.grid-stack-24>.grid-stack-item[data-gs-max-width="10"]{max-width:41.6666666667%}.grid-stack.grid-stack-24>.grid-stack-item[data-gs-width="11"]{width:45.8333333333%}.grid-stack.grid-stack-24>.grid-stack-item[data-gs-x="11"]{left:45.8333333333%}.grid-stack.grid-stack-24>.grid-stack-item[data-gs-min-width="11"]{min-width:45.8333333333%}.grid-stack.grid-stack-24>.grid-stack-item[data-gs-max-width="11"]{max-width:45.8333333333%}.grid-stack.grid-stack-24>.grid-stack-item[data-gs-width="12"]{width:50%}.grid-stack.grid-stack-24>.grid-stack-item[data-gs-x="12"]{left:50%}.grid-stack.grid-stack-24>.grid-stack-item[data-gs-min-width="12"]{min-width:50%}.grid-stack.grid-stack-24>.grid-stack-item[data-gs-max-width="12"]{max-width:50%}.grid-stack.grid-stack-24>.grid-stack-item[data-gs-width="13"]{width:54.1666666667%}.grid-stack.grid-stack-24>.grid-stack-item[data-gs-x="13"]{left:54.1666666667%}.grid-stack.grid-stack-24>.grid-stack-item[data-gs-min-width="13"]{min-width:54.1666666667%}.grid-stack.grid-stack-24>.grid-stack-item[data-gs-max-width="13"]{max-width:54.1666666667%}.grid-stack.grid-stack-24>.grid-stack-item[data-gs-width="14"]{width:58.3333333333%}.grid-stack.grid-stack-24>.grid-stack-item[data-gs-x="14"]{left:58.3333333333%}.grid-stack.grid-stack-24>.grid-stack-item[data-gs-min-width="14"]{min-width:58.3333333333%}.grid-stack.grid-stack-24>.grid-stack-item[data-gs-max-width="14"]{max-width:58.3333333333%}.grid-stack.grid-stack-24>.grid-stack-item[data-gs-width="15"]{width:62.5%}.grid-stack.grid-stack-24>.grid-stack-item[data-gs-x="15"]{left:62.5%}.grid-stack.grid-stack-24>.grid-stack-item[data-gs-min-width="15"]{min-width:62.5%}.grid-stack.grid-stack-24>.grid-stack-item[data-gs-max-width="15"]{max-width:62.5%}.grid-stack.grid-stack-24>.grid-stack-item[data-gs-width="16"]{width:66.6666666667%}.grid-stack.grid-stack-24>.grid-stack-item[data-gs-x="16"]{left:66.6666666667%}.grid-stack.grid-stack-24>.grid-stack-item[data-gs-min-width="16"]{min-width:66.6666666667%}.grid-stack.grid-stack-24>.grid-stack-item[data-gs-max-width="16"]{max-width:66.6666666667%}.grid-stack.grid-stack-24>.grid-stack-item[data-gs-width="17"]{width:70.8333333333%}.grid-stack.grid-stack-24>.grid-stack-item[data-gs-x="17"]{left:70.8333333333%}.grid-stack.grid-stack-24>.grid-stack-item[data-gs-min-width="17"]{min-width:70.8333333333%}.grid-stack.grid-stack-24>.grid-stack-item[data-gs-max-width="17"]{max-width:70.8333333333%}.grid-stack.grid-stack-24>.grid-stack-item[data-gs-width="18"]{width:75%}.grid-stack.grid-stack-24>.grid-stack-item[data-gs-x="18"]{left:75%}.grid-stack.grid-stack-24>.grid-stack-item[data-gs-min-width="18"]{min-width:75%}.grid-stack.grid-stack-24>.grid-stack-item[data-gs-max-width="18"]{max-width:75%}.grid-stack.grid-stack-24>.grid-stack-item[data-gs-width="19"]{width:79.1666666667%}.grid-stack.grid-stack-24>.grid-stack-item[data-gs-x="19"]{left:79.1666666667%}.grid-stack.grid-stack-24>.grid-stack-item[data-gs-min-width="19"]{min-width:79.1666666667%}.grid-stack.grid-stack-24>.grid-stack-item[data-gs-max-width="19"]{max-width:79.1666666667%}.grid-stack.grid-stack-24>.grid-stack-item[data-gs-width="20"]{width:83.3333333333%}.grid-stack.grid-stack-24>.grid-stack-item[data-gs-x="20"]{left:83.3333333333%}.grid-stack.grid-stack-24>.grid-stack-item[data-gs-min-width="20"]{min-width:83.3333333333%}.grid-stack.grid-stack-24>.grid-stack-item[data-gs-max-width="20"]{max-width:83.3333333333%}.grid-stack.grid-stack-24>.grid-stack-item[data-gs-width="21"]{width:87.5%}.grid-stack.grid-stack-24>.grid-stack-item[data-gs-x="21"]{left:87.5%}.grid-stack.grid-stack-24>.grid-stack-item[data-gs-min-width="21"]{min-width:87.5%}.grid-stack.grid-stack-24>.grid-stack-item[data-gs-max-width="21"]{max-width:87.5%}.grid-stack.grid-stack-24>.grid-stack-item[data-gs-width="22"]{width:91.6666666667%}.grid-stack.grid-stack-24>.grid-stack-item[data-gs-x="22"]{left:91.6666666667%}.grid-stack.grid-stack-24>.grid-stack-item[data-gs-min-width="22"]{min-width:91.6666666667%}.grid-stack.grid-stack-24>.grid-stack-item[data-gs-max-width="22"]{max-width:91.6666666667%}.grid-stack.grid-stack-24>.grid-stack-item[data-gs-width="23"]{width:95.8333333333%}.grid-stack.grid-stack-24>.grid-stack-item[data-gs-x="23"]{left:95.8333333333%}.grid-stack.grid-stack-24>.grid-stack-item[data-gs-min-width="23"]{min-width:95.8333333333%}.grid-stack.grid-stack-24>.grid-stack-item[data-gs-max-width="23"]{max-width:95.8333333333%}.grid-stack.grid-stack-24>.grid-stack-item[data-gs-width="24"]{width:100%}.grid-stack.grid-stack-24>.grid-stack-item[data-gs-x="24"]{left:100%}.grid-stack.grid-stack-24>.grid-stack-item[data-gs-min-width="24"]{min-width:100%}.grid-stack.grid-stack-24>.grid-stack-item[data-gs-max-width="24"]{max-width:100%}.grid-stack.grid-stack-25>.grid-stack-item{min-width:4%}.grid-stack.grid-stack-25>.grid-stack-item[data-gs-width="1"]{width:4%}.grid-stack.grid-stack-25>.grid-stack-item[data-gs-x="1"]{left:4%}.grid-stack.grid-stack-25>.grid-stack-item[data-gs-min-width="1"]{min-width:4%}.grid-stack.grid-stack-25>.grid-stack-item[data-gs-max-width="1"]{max-width:4%}.grid-stack.grid-stack-25>.grid-stack-item[data-gs-width="2"]{width:8%}.grid-stack.grid-stack-25>.grid-stack-item[data-gs-x="2"]{left:8%}.grid-stack.grid-stack-25>.grid-stack-item[data-gs-min-width="2"]{min-width:8%}.grid-stack.grid-stack-25>.grid-stack-item[data-gs-max-width="2"]{max-width:8%}.grid-stack.grid-stack-25>.grid-stack-item[data-gs-width="3"]{width:12%}.grid-stack.grid-stack-25>.grid-stack-item[data-gs-x="3"]{left:12%}.grid-stack.grid-stack-25>.grid-stack-item[data-gs-min-width="3"]{min-width:12%}.grid-stack.grid-stack-25>.grid-stack-item[data-gs-max-width="3"]{max-width:12%}.grid-stack.grid-stack-25>.grid-stack-item[data-gs-width="4"]{width:16%}.grid-stack.grid-stack-25>.grid-stack-item[data-gs-x="4"]{left:16%}.grid-stack.grid-stack-25>.grid-stack-item[data-gs-min-width="4"]{min-width:16%}.grid-stack.grid-stack-25>.grid-stack-item[data-gs-max-width="4"]{max-width:16%}.grid-stack.grid-stack-25>.grid-stack-item[data-gs-width="5"]{width:20%}.grid-stack.grid-stack-25>.grid-stack-item[data-gs-x="5"]{left:20%}.grid-stack.grid-stack-25>.grid-stack-item[data-gs-min-width="5"]{min-width:20%}.grid-stack.grid-stack-25>.grid-stack-item[data-gs-max-width="5"]{max-width:20%}.grid-stack.grid-stack-25>.grid-stack-item[data-gs-width="6"]{width:24%}.grid-stack.grid-stack-25>.grid-stack-item[data-gs-x="6"]{left:24%}.grid-stack.grid-stack-25>.grid-stack-item[data-gs-min-width="6"]{min-width:24%}.grid-stack.grid-stack-25>.grid-stack-item[data-gs-max-width="6"]{max-width:24%}.grid-stack.grid-stack-25>.grid-stack-item[data-gs-width="7"]{width:28%}.grid-stack.grid-stack-25>.grid-stack-item[data-gs-x="7"]{left:28%}.grid-stack.grid-stack-25>.grid-stack-item[data-gs-min-width="7"]{min-width:28%}.grid-stack.grid-stack-25>.grid-stack-item[data-gs-max-width="7"]{max-width:28%}.grid-stack.grid-stack-25>.grid-stack-item[data-gs-width="8"]{width:32%}.grid-stack.grid-stack-25>.grid-stack-item[data-gs-x="8"]{left:32%}.grid-stack.grid-stack-25>.grid-stack-item[data-gs-min-width="8"]{min-width:32%}.grid-stack.grid-stack-25>.grid-stack-item[data-gs-max-width="8"]{max-width:32%}.grid-stack.grid-stack-25>.grid-stack-item[data-gs-width="9"]{width:36%}.grid-stack.grid-stack-25>.grid-stack-item[data-gs-x="9"]{left:36%}.grid-stack.grid-stack-25>.grid-stack-item[data-gs-min-width="9"]{min-width:36%}.grid-stack.grid-stack-25>.grid-stack-item[data-gs-max-width="9"]{max-width:36%}.grid-stack.grid-stack-25>.grid-stack-item[data-gs-width="10"]{width:40%}.grid-stack.grid-stack-25>.grid-stack-item[data-gs-x="10"]{left:40%}.grid-stack.grid-stack-25>.grid-stack-item[data-gs-min-width="10"]{min-width:40%}.grid-stack.grid-stack-25>.grid-stack-item[data-gs-max-width="10"]{max-width:40%}.grid-stack.grid-stack-25>.grid-stack-item[data-gs-width="11"]{width:44%}.grid-stack.grid-stack-25>.grid-stack-item[data-gs-x="11"]{left:44%}.grid-stack.grid-stack-25>.grid-stack-item[data-gs-min-width="11"]{min-width:44%}.grid-stack.grid-stack-25>.grid-stack-item[data-gs-max-width="11"]{max-width:44%}.grid-stack.grid-stack-25>.grid-stack-item[data-gs-width="12"]{width:48%}.grid-stack.grid-stack-25>.grid-stack-item[data-gs-x="12"]{left:48%}.grid-stack.grid-stack-25>.grid-stack-item[data-gs-min-width="12"]{min-width:48%}.grid-stack.grid-stack-25>.grid-stack-item[data-gs-max-width="12"]{max-width:48%}.grid-stack.grid-stack-25>.grid-stack-item[data-gs-width="13"]{width:52%}.grid-stack.grid-stack-25>.grid-stack-item[data-gs-x="13"]{left:52%}.grid-stack.grid-stack-25>.grid-stack-item[data-gs-min-width="13"]{min-width:52%}.grid-stack.grid-stack-25>.grid-stack-item[data-gs-max-width="13"]{max-width:52%}.grid-stack.grid-stack-25>.grid-stack-item[data-gs-width="14"]{width:56%}.grid-stack.grid-stack-25>.grid-stack-item[data-gs-x="14"]{left:56%}.grid-stack.grid-stack-25>.grid-stack-item[data-gs-min-width="14"]{min-width:56%}.grid-stack.grid-stack-25>.grid-stack-item[data-gs-max-width="14"]{max-width:56%}.grid-stack.grid-stack-25>.grid-stack-item[data-gs-width="15"]{width:60%}.grid-stack.grid-stack-25>.grid-stack-item[data-gs-x="15"]{left:60%}.grid-stack.grid-stack-25>.grid-stack-item[data-gs-min-width="15"]{min-width:60%}.grid-stack.grid-stack-25>.grid-stack-item[data-gs-max-width="15"]{max-width:60%}.grid-stack.grid-stack-25>.grid-stack-item[data-gs-width="16"]{width:64%}.grid-stack.grid-stack-25>.grid-stack-item[data-gs-x="16"]{left:64%}.grid-stack.grid-stack-25>.grid-stack-item[data-gs-min-width="16"]{min-width:64%}.grid-stack.grid-stack-25>.grid-stack-item[data-gs-max-width="16"]{max-width:64%}.grid-stack.grid-stack-25>.grid-stack-item[data-gs-width="17"]{width:68%}.grid-stack.grid-stack-25>.grid-stack-item[data-gs-x="17"]{left:68%}.grid-stack.grid-stack-25>.grid-stack-item[data-gs-min-width="17"]{min-width:68%}.grid-stack.grid-stack-25>.grid-stack-item[data-gs-max-width="17"]{max-width:68%}.grid-stack.grid-stack-25>.grid-stack-item[data-gs-width="18"]{width:72%}.grid-stack.grid-stack-25>.grid-stack-item[data-gs-x="18"]{left:72%}.grid-stack.grid-stack-25>.grid-stack-item[data-gs-min-width="18"]{min-width:72%}.grid-stack.grid-stack-25>.grid-stack-item[data-gs-max-width="18"]{max-width:72%}.grid-stack.grid-stack-25>.grid-stack-item[data-gs-width="19"]{width:76%}.grid-stack.grid-stack-25>.grid-stack-item[data-gs-x="19"]{left:76%}.grid-stack.grid-stack-25>.grid-stack-item[data-gs-min-width="19"]{min-width:76%}.grid-stack.grid-stack-25>.grid-stack-item[data-gs-max-width="19"]{max-width:76%}.grid-stack.grid-stack-25>.grid-stack-item[data-gs-width="20"]{width:80%}.grid-stack.grid-stack-25>.grid-stack-item[data-gs-x="20"]{left:80%}.grid-stack.grid-stack-25>.grid-stack-item[data-gs-min-width="20"]{min-width:80%}.grid-stack.grid-stack-25>.grid-stack-item[data-gs-max-width="20"]{max-width:80%}.grid-stack.grid-stack-25>.grid-stack-item[data-gs-width="21"]{width:84%}.grid-stack.grid-stack-25>.grid-stack-item[data-gs-x="21"]{left:84%}.grid-stack.grid-stack-25>.grid-stack-item[data-gs-min-width="21"]{min-width:84%}.grid-stack.grid-stack-25>.grid-stack-item[data-gs-max-width="21"]{max-width:84%}.grid-stack.grid-stack-25>.grid-stack-item[data-gs-width="22"]{width:88%}.grid-stack.grid-stack-25>.grid-stack-item[data-gs-x="22"]{left:88%}.grid-stack.grid-stack-25>.grid-stack-item[data-gs-min-width="22"]{min-width:88%}.grid-stack.grid-stack-25>.grid-stack-item[data-gs-max-width="22"]{max-width:88%}.grid-stack.grid-stack-25>.grid-stack-item[data-gs-width="23"]{width:92%}.grid-stack.grid-stack-25>.grid-stack-item[data-gs-x="23"]{left:92%}.grid-stack.grid-stack-25>.grid-stack-item[data-gs-min-width="23"]{min-width:92%}.grid-stack.grid-stack-25>.grid-stack-item[data-gs-max-width="23"]{max-width:92%}.grid-stack.grid-stack-25>.grid-stack-item[data-gs-width="24"]{width:96%}.grid-stack.grid-stack-25>.grid-stack-item[data-gs-x="24"]{left:96%}.grid-stack.grid-stack-25>.grid-stack-item[data-gs-min-width="24"]{min-width:96%}.grid-stack.grid-stack-25>.grid-stack-item[data-gs-max-width="24"]{max-width:96%}.grid-stack.grid-stack-25>.grid-stack-item[data-gs-width="25"]{width:100%}.grid-stack.grid-stack-25>.grid-stack-item[data-gs-x="25"]{left:100%}.grid-stack.grid-stack-25>.grid-stack-item[data-gs-min-width="25"]{min-width:100%}.grid-stack.grid-stack-25>.grid-stack-item[data-gs-max-width="25"]{max-width:100%}.grid-stack.grid-stack-26>.grid-stack-item{min-width:3.8461538462%}.grid-stack.grid-stack-26>.grid-stack-item[data-gs-width="1"]{width:3.8461538462%}.grid-stack.grid-stack-26>.grid-stack-item[data-gs-x="1"]{left:3.8461538462%}.grid-stack.grid-stack-26>.grid-stack-item[data-gs-min-width="1"]{min-width:3.8461538462%}.grid-stack.grid-stack-26>.grid-stack-item[data-gs-max-width="1"]{max-width:3.8461538462%}.grid-stack.grid-stack-26>.grid-stack-item[data-gs-width="2"]{width:7.6923076923%}.grid-stack.grid-stack-26>.grid-stack-item[data-gs-x="2"]{left:7.6923076923%}.grid-stack.grid-stack-26>.grid-stack-item[data-gs-min-width="2"]{min-width:7.6923076923%}.grid-stack.grid-stack-26>.grid-stack-item[data-gs-max-width="2"]{max-width:7.6923076923%}.grid-stack.grid-stack-26>.grid-stack-item[data-gs-width="3"]{width:11.5384615385%}.grid-stack.grid-stack-26>.grid-stack-item[data-gs-x="3"]{left:11.5384615385%}.grid-stack.grid-stack-26>.grid-stack-item[data-gs-min-width="3"]{min-width:11.5384615385%}.grid-stack.grid-stack-26>.grid-stack-item[data-gs-max-width="3"]{max-width:11.5384615385%}.grid-stack.grid-stack-26>.grid-stack-item[data-gs-width="4"]{width:15.3846153846%}.grid-stack.grid-stack-26>.grid-stack-item[data-gs-x="4"]{left:15.3846153846%}.grid-stack.grid-stack-26>.grid-stack-item[data-gs-min-width="4"]{min-width:15.3846153846%}.grid-stack.grid-stack-26>.grid-stack-item[data-gs-max-width="4"]{max-width:15.3846153846%}.grid-stack.grid-stack-26>.grid-stack-item[data-gs-width="5"]{width:19.2307692308%}.grid-stack.grid-stack-26>.grid-stack-item[data-gs-x="5"]{left:19.2307692308%}.grid-stack.grid-stack-26>.grid-stack-item[data-gs-min-width="5"]{min-width:19.2307692308%}.grid-stack.grid-stack-26>.grid-stack-item[data-gs-max-width="5"]{max-width:19.2307692308%}.grid-stack.grid-stack-26>.grid-stack-item[data-gs-width="6"]{width:23.0769230769%}.grid-stack.grid-stack-26>.grid-stack-item[data-gs-x="6"]{left:23.0769230769%}.grid-stack.grid-stack-26>.grid-stack-item[data-gs-min-width="6"]{min-width:23.0769230769%}.grid-stack.grid-stack-26>.grid-stack-item[data-gs-max-width="6"]{max-width:23.0769230769%}.grid-stack.grid-stack-26>.grid-stack-item[data-gs-width="7"]{width:26.9230769231%}.grid-stack.grid-stack-26>.grid-stack-item[data-gs-x="7"]{left:26.9230769231%}.grid-stack.grid-stack-26>.grid-stack-item[data-gs-min-width="7"]{min-width:26.9230769231%}.grid-stack.grid-stack-26>.grid-stack-item[data-gs-max-width="7"]{max-width:26.9230769231%}.grid-stack.grid-stack-26>.grid-stack-item[data-gs-width="8"]{width:30.7692307692%}.grid-stack.grid-stack-26>.grid-stack-item[data-gs-x="8"]{left:30.7692307692%}.grid-stack.grid-stack-26>.grid-stack-item[data-gs-min-width="8"]{min-width:30.7692307692%}.grid-stack.grid-stack-26>.grid-stack-item[data-gs-max-width="8"]{max-width:30.7692307692%}.grid-stack.grid-stack-26>.grid-stack-item[data-gs-width="9"]{width:34.6153846154%}.grid-stack.grid-stack-26>.grid-stack-item[data-gs-x="9"]{left:34.6153846154%}.grid-stack.grid-stack-26>.grid-stack-item[data-gs-min-width="9"]{min-width:34.6153846154%}.grid-stack.grid-stack-26>.grid-stack-item[data-gs-max-width="9"]{max-width:34.6153846154%}.grid-stack.grid-stack-26>.grid-stack-item[data-gs-width="10"]{width:38.4615384615%}.grid-stack.grid-stack-26>.grid-stack-item[data-gs-x="10"]{left:38.4615384615%}.grid-stack.grid-stack-26>.grid-stack-item[data-gs-min-width="10"]{min-width:38.4615384615%}.grid-stack.grid-stack-26>.grid-stack-item[data-gs-max-width="10"]{max-width:38.4615384615%}.grid-stack.grid-stack-26>.grid-stack-item[data-gs-width="11"]{width:42.3076923077%}.grid-stack.grid-stack-26>.grid-stack-item[data-gs-x="11"]{left:42.3076923077%}.grid-stack.grid-stack-26>.grid-stack-item[data-gs-min-width="11"]{min-width:42.3076923077%}.grid-stack.grid-stack-26>.grid-stack-item[data-gs-max-width="11"]{max-width:42.3076923077%}.grid-stack.grid-stack-26>.grid-stack-item[data-gs-width="12"]{width:46.1538461538%}.grid-stack.grid-stack-26>.grid-stack-item[data-gs-x="12"]{left:46.1538461538%}.grid-stack.grid-stack-26>.grid-stack-item[data-gs-min-width="12"]{min-width:46.1538461538%}.grid-stack.grid-stack-26>.grid-stack-item[data-gs-max-width="12"]{max-width:46.1538461538%}.grid-stack.grid-stack-26>.grid-stack-item[data-gs-width="13"]{width:50%}.grid-stack.grid-stack-26>.grid-stack-item[data-gs-x="13"]{left:50%}.grid-stack.grid-stack-26>.grid-stack-item[data-gs-min-width="13"]{min-width:50%}.grid-stack.grid-stack-26>.grid-stack-item[data-gs-max-width="13"]{max-width:50%}.grid-stack.grid-stack-26>.grid-stack-item[data-gs-width="14"]{width:53.8461538462%}.grid-stack.grid-stack-26>.grid-stack-item[data-gs-x="14"]{left:53.8461538462%}.grid-stack.grid-stack-26>.grid-stack-item[data-gs-min-width="14"]{min-width:53.8461538462%}.grid-stack.grid-stack-26>.grid-stack-item[data-gs-max-width="14"]{max-width:53.8461538462%}.grid-stack.grid-stack-26>.grid-stack-item[data-gs-width="15"]{width:57.6923076923%}.grid-stack.grid-stack-26>.grid-stack-item[data-gs-x="15"]{left:57.6923076923%}.grid-stack.grid-stack-26>.grid-stack-item[data-gs-min-width="15"]{min-width:57.6923076923%}.grid-stack.grid-stack-26>.grid-stack-item[data-gs-max-width="15"]{max-width:57.6923076923%}.grid-stack.grid-stack-26>.grid-stack-item[data-gs-width="16"]{width:61.5384615385%}.grid-stack.grid-stack-26>.grid-stack-item[data-gs-x="16"]{left:61.5384615385%}.grid-stack.grid-stack-26>.grid-stack-item[data-gs-min-width="16"]{min-width:61.5384615385%}.grid-stack.grid-stack-26>.grid-stack-item[data-gs-max-width="16"]{max-width:61.5384615385%}.grid-stack.grid-stack-26>.grid-stack-item[data-gs-width="17"]{width:65.3846153846%}.grid-stack.grid-stack-26>.grid-stack-item[data-gs-x="17"]{left:65.3846153846%}.grid-stack.grid-stack-26>.grid-stack-item[data-gs-min-width="17"]{min-width:65.3846153846%}.grid-stack.grid-stack-26>.grid-stack-item[data-gs-max-width="17"]{max-width:65.3846153846%}.grid-stack.grid-stack-26>.grid-stack-item[data-gs-width="18"]{width:69.2307692308%}.grid-stack.grid-stack-26>.grid-stack-item[data-gs-x="18"]{left:69.2307692308%}.grid-stack.grid-stack-26>.grid-stack-item[data-gs-min-width="18"]{min-width:69.2307692308%}.grid-stack.grid-stack-26>.grid-stack-item[data-gs-max-width="18"]{max-width:69.2307692308%}.grid-stack.grid-stack-26>.grid-stack-item[data-gs-width="19"]{width:73.0769230769%}.grid-stack.grid-stack-26>.grid-stack-item[data-gs-x="19"]{left:73.0769230769%}.grid-stack.grid-stack-26>.grid-stack-item[data-gs-min-width="19"]{min-width:73.0769230769%}.grid-stack.grid-stack-26>.grid-stack-item[data-gs-max-width="19"]{max-width:73.0769230769%}.grid-stack.grid-stack-26>.grid-stack-item[data-gs-width="20"]{width:76.9230769231%}.grid-stack.grid-stack-26>.grid-stack-item[data-gs-x="20"]{left:76.9230769231%}.grid-stack.grid-stack-26>.grid-stack-item[data-gs-min-width="20"]{min-width:76.9230769231%}.grid-stack.grid-stack-26>.grid-stack-item[data-gs-max-width="20"]{max-width:76.9230769231%}.grid-stack.grid-stack-26>.grid-stack-item[data-gs-width="21"]{width:80.7692307692%}.grid-stack.grid-stack-26>.grid-stack-item[data-gs-x="21"]{left:80.7692307692%}.grid-stack.grid-stack-26>.grid-stack-item[data-gs-min-width="21"]{min-width:80.7692307692%}.grid-stack.grid-stack-26>.grid-stack-item[data-gs-max-width="21"]{max-width:80.7692307692%}.grid-stack.grid-stack-26>.grid-stack-item[data-gs-width="22"]{width:84.6153846154%}.grid-stack.grid-stack-26>.grid-stack-item[data-gs-x="22"]{left:84.6153846154%}.grid-stack.grid-stack-26>.grid-stack-item[data-gs-min-width="22"]{min-width:84.6153846154%}.grid-stack.grid-stack-26>.grid-stack-item[data-gs-max-width="22"]{max-width:84.6153846154%}.grid-stack.grid-stack-26>.grid-stack-item[data-gs-width="23"]{width:88.4615384615%}.grid-stack.grid-stack-26>.grid-stack-item[data-gs-x="23"]{left:88.4615384615%}.grid-stack.grid-stack-26>.grid-stack-item[data-gs-min-width="23"]{min-width:88.4615384615%}.grid-stack.grid-stack-26>.grid-stack-item[data-gs-max-width="23"]{max-width:88.4615384615%}.grid-stack.grid-stack-26>.grid-stack-item[data-gs-width="24"]{width:92.3076923077%}.grid-stack.grid-stack-26>.grid-stack-item[data-gs-x="24"]{left:92.3076923077%}.grid-stack.grid-stack-26>.grid-stack-item[data-gs-min-width="24"]{min-width:92.3076923077%}.grid-stack.grid-stack-26>.grid-stack-item[data-gs-max-width="24"]{max-width:92.3076923077%}.grid-stack.grid-stack-26>.grid-stack-item[data-gs-width="25"]{width:96.1538461538%}.grid-stack.grid-stack-26>.grid-stack-item[data-gs-x="25"]{left:96.1538461538%}.grid-stack.grid-stack-26>.grid-stack-item[data-gs-min-width="25"]{min-width:96.1538461538%}.grid-stack.grid-stack-26>.grid-stack-item[data-gs-max-width="25"]{max-width:96.1538461538%}.grid-stack.grid-stack-26>.grid-stack-item[data-gs-width="26"]{width:100%}.grid-stack.grid-stack-26>.grid-stack-item[data-gs-x="26"]{left:100%}.grid-stack.grid-stack-26>.grid-stack-item[data-gs-min-width="26"]{min-width:100%}.grid-stack.grid-stack-26>.grid-stack-item[data-gs-max-width="26"]{max-width:100%}.grid-stack.grid-stack-27>.grid-stack-item{min-width:3.7037037037%}.grid-stack.grid-stack-27>.grid-stack-item[data-gs-width="1"]{width:3.7037037037%}.grid-stack.grid-stack-27>.grid-stack-item[data-gs-x="1"]{left:3.7037037037%}.grid-stack.grid-stack-27>.grid-stack-item[data-gs-min-width="1"]{min-width:3.7037037037%}.grid-stack.grid-stack-27>.grid-stack-item[data-gs-max-width="1"]{max-width:3.7037037037%}.grid-stack.grid-stack-27>.grid-stack-item[data-gs-width="2"]{width:7.4074074074%}.grid-stack.grid-stack-27>.grid-stack-item[data-gs-x="2"]{left:7.4074074074%}.grid-stack.grid-stack-27>.grid-stack-item[data-gs-min-width="2"]{min-width:7.4074074074%}.grid-stack.grid-stack-27>.grid-stack-item[data-gs-max-width="2"]{max-width:7.4074074074%}.grid-stack.grid-stack-27>.grid-stack-item[data-gs-width="3"]{width:11.1111111111%}.grid-stack.grid-stack-27>.grid-stack-item[data-gs-x="3"]{left:11.1111111111%}.grid-stack.grid-stack-27>.grid-stack-item[data-gs-min-width="3"]{min-width:11.1111111111%}.grid-stack.grid-stack-27>.grid-stack-item[data-gs-max-width="3"]{max-width:11.1111111111%}.grid-stack.grid-stack-27>.grid-stack-item[data-gs-width="4"]{width:14.8148148148%}.grid-stack.grid-stack-27>.grid-stack-item[data-gs-x="4"]{left:14.8148148148%}.grid-stack.grid-stack-27>.grid-stack-item[data-gs-min-width="4"]{min-width:14.8148148148%}.grid-stack.grid-stack-27>.grid-stack-item[data-gs-max-width="4"]{max-width:14.8148148148%}.grid-stack.grid-stack-27>.grid-stack-item[data-gs-width="5"]{width:18.5185185185%}.grid-stack.grid-stack-27>.grid-stack-item[data-gs-x="5"]{left:18.5185185185%}.grid-stack.grid-stack-27>.grid-stack-item[data-gs-min-width="5"]{min-width:18.5185185185%}.grid-stack.grid-stack-27>.grid-stack-item[data-gs-max-width="5"]{max-width:18.5185185185%}.grid-stack.grid-stack-27>.grid-stack-item[data-gs-width="6"]{width:22.2222222222%}.grid-stack.grid-stack-27>.grid-stack-item[data-gs-x="6"]{left:22.2222222222%}.grid-stack.grid-stack-27>.grid-stack-item[data-gs-min-width="6"]{min-width:22.2222222222%}.grid-stack.grid-stack-27>.grid-stack-item[data-gs-max-width="6"]{max-width:22.2222222222%}.grid-stack.grid-stack-27>.grid-stack-item[data-gs-width="7"]{width:25.9259259259%}.grid-stack.grid-stack-27>.grid-stack-item[data-gs-x="7"]{left:25.9259259259%}.grid-stack.grid-stack-27>.grid-stack-item[data-gs-min-width="7"]{min-width:25.9259259259%}.grid-stack.grid-stack-27>.grid-stack-item[data-gs-max-width="7"]{max-width:25.9259259259%}.grid-stack.grid-stack-27>.grid-stack-item[data-gs-width="8"]{width:29.6296296296%}.grid-stack.grid-stack-27>.grid-stack-item[data-gs-x="8"]{left:29.6296296296%}.grid-stack.grid-stack-27>.grid-stack-item[data-gs-min-width="8"]{min-width:29.6296296296%}.grid-stack.grid-stack-27>.grid-stack-item[data-gs-max-width="8"]{max-width:29.6296296296%}.grid-stack.grid-stack-27>.grid-stack-item[data-gs-width="9"]{width:33.3333333333%}.grid-stack.grid-stack-27>.grid-stack-item[data-gs-x="9"]{left:33.3333333333%}.grid-stack.grid-stack-27>.grid-stack-item[data-gs-min-width="9"]{min-width:33.3333333333%}.grid-stack.grid-stack-27>.grid-stack-item[data-gs-max-width="9"]{max-width:33.3333333333%}.grid-stack.grid-stack-27>.grid-stack-item[data-gs-width="10"]{width:37.037037037%}.grid-stack.grid-stack-27>.grid-stack-item[data-gs-x="10"]{left:37.037037037%}.grid-stack.grid-stack-27>.grid-stack-item[data-gs-min-width="10"]{min-width:37.037037037%}.grid-stack.grid-stack-27>.grid-stack-item[data-gs-max-width="10"]{max-width:37.037037037%}.grid-stack.grid-stack-27>.grid-stack-item[data-gs-width="11"]{width:40.7407407407%}.grid-stack.grid-stack-27>.grid-stack-item[data-gs-x="11"]{left:40.7407407407%}.grid-stack.grid-stack-27>.grid-stack-item[data-gs-min-width="11"]{min-width:40.7407407407%}.grid-stack.grid-stack-27>.grid-stack-item[data-gs-max-width="11"]{max-width:40.7407407407%}.grid-stack.grid-stack-27>.grid-stack-item[data-gs-width="12"]{width:44.4444444444%}.grid-stack.grid-stack-27>.grid-stack-item[data-gs-x="12"]{left:44.4444444444%}.grid-stack.grid-stack-27>.grid-stack-item[data-gs-min-width="12"]{min-width:44.4444444444%}.grid-stack.grid-stack-27>.grid-stack-item[data-gs-max-width="12"]{max-width:44.4444444444%}.grid-stack.grid-stack-27>.grid-stack-item[data-gs-width="13"]{width:48.1481481481%}.grid-stack.grid-stack-27>.grid-stack-item[data-gs-x="13"]{left:48.1481481481%}.grid-stack.grid-stack-27>.grid-stack-item[data-gs-min-width="13"]{min-width:48.1481481481%}.grid-stack.grid-stack-27>.grid-stack-item[data-gs-max-width="13"]{max-width:48.1481481481%}.grid-stack.grid-stack-27>.grid-stack-item[data-gs-width="14"]{width:51.8518518519%}.grid-stack.grid-stack-27>.grid-stack-item[data-gs-x="14"]{left:51.8518518519%}.grid-stack.grid-stack-27>.grid-stack-item[data-gs-min-width="14"]{min-width:51.8518518519%}.grid-stack.grid-stack-27>.grid-stack-item[data-gs-max-width="14"]{max-width:51.8518518519%}.grid-stack.grid-stack-27>.grid-stack-item[data-gs-width="15"]{width:55.5555555556%}.grid-stack.grid-stack-27>.grid-stack-item[data-gs-x="15"]{left:55.5555555556%}.grid-stack.grid-stack-27>.grid-stack-item[data-gs-min-width="15"]{min-width:55.5555555556%}.grid-stack.grid-stack-27>.grid-stack-item[data-gs-max-width="15"]{max-width:55.5555555556%}.grid-stack.grid-stack-27>.grid-stack-item[data-gs-width="16"]{width:59.2592592593%}.grid-stack.grid-stack-27>.grid-stack-item[data-gs-x="16"]{left:59.2592592593%}.grid-stack.grid-stack-27>.grid-stack-item[data-gs-min-width="16"]{min-width:59.2592592593%}.grid-stack.grid-stack-27>.grid-stack-item[data-gs-max-width="16"]{max-width:59.2592592593%}.grid-stack.grid-stack-27>.grid-stack-item[data-gs-width="17"]{width:62.962962963%}.grid-stack.grid-stack-27>.grid-stack-item[data-gs-x="17"]{left:62.962962963%}.grid-stack.grid-stack-27>.grid-stack-item[data-gs-min-width="17"]{min-width:62.962962963%}.grid-stack.grid-stack-27>.grid-stack-item[data-gs-max-width="17"]{max-width:62.962962963%}.grid-stack.grid-stack-27>.grid-stack-item[data-gs-width="18"]{width:66.6666666667%}.grid-stack.grid-stack-27>.grid-stack-item[data-gs-x="18"]{left:66.6666666667%}.grid-stack.grid-stack-27>.grid-stack-item[data-gs-min-width="18"]{min-width:66.6666666667%}.grid-stack.grid-stack-27>.grid-stack-item[data-gs-max-width="18"]{max-width:66.6666666667%}.grid-stack.grid-stack-27>.grid-stack-item[data-gs-width="19"]{width:70.3703703704%}.grid-stack.grid-stack-27>.grid-stack-item[data-gs-x="19"]{left:70.3703703704%}.grid-stack.grid-stack-27>.grid-stack-item[data-gs-min-width="19"]{min-width:70.3703703704%}.grid-stack.grid-stack-27>.grid-stack-item[data-gs-max-width="19"]{max-width:70.3703703704%}.grid-stack.grid-stack-27>.grid-stack-item[data-gs-width="20"]{width:74.0740740741%}.grid-stack.grid-stack-27>.grid-stack-item[data-gs-x="20"]{left:74.0740740741%}.grid-stack.grid-stack-27>.grid-stack-item[data-gs-min-width="20"]{min-width:74.0740740741%}.grid-stack.grid-stack-27>.grid-stack-item[data-gs-max-width="20"]{max-width:74.0740740741%}.grid-stack.grid-stack-27>.grid-stack-item[data-gs-width="21"]{width:77.7777777778%}.grid-stack.grid-stack-27>.grid-stack-item[data-gs-x="21"]{left:77.7777777778%}.grid-stack.grid-stack-27>.grid-stack-item[data-gs-min-width="21"]{min-width:77.7777777778%}.grid-stack.grid-stack-27>.grid-stack-item[data-gs-max-width="21"]{max-width:77.7777777778%}.grid-stack.grid-stack-27>.grid-stack-item[data-gs-width="22"]{width:81.4814814815%}.grid-stack.grid-stack-27>.grid-stack-item[data-gs-x="22"]{left:81.4814814815%}.grid-stack.grid-stack-27>.grid-stack-item[data-gs-min-width="22"]{min-width:81.4814814815%}.grid-stack.grid-stack-27>.grid-stack-item[data-gs-max-width="22"]{max-width:81.4814814815%}.grid-stack.grid-stack-27>.grid-stack-item[data-gs-width="23"]{width:85.1851851852%}.grid-stack.grid-stack-27>.grid-stack-item[data-gs-x="23"]{left:85.1851851852%}.grid-stack.grid-stack-27>.grid-stack-item[data-gs-min-width="23"]{min-width:85.1851851852%}.grid-stack.grid-stack-27>.grid-stack-item[data-gs-max-width="23"]{max-width:85.1851851852%}.grid-stack.grid-stack-27>.grid-stack-item[data-gs-width="24"]{width:88.8888888889%}.grid-stack.grid-stack-27>.grid-stack-item[data-gs-x="24"]{left:88.8888888889%}.grid-stack.grid-stack-27>.grid-stack-item[data-gs-min-width="24"]{min-width:88.8888888889%}.grid-stack.grid-stack-27>.grid-stack-item[data-gs-max-width="24"]{max-width:88.8888888889%}.grid-stack.grid-stack-27>.grid-stack-item[data-gs-width="25"]{width:92.5925925926%}.grid-stack.grid-stack-27>.grid-stack-item[data-gs-x="25"]{left:92.5925925926%}.grid-stack.grid-stack-27>.grid-stack-item[data-gs-min-width="25"]{min-width:92.5925925926%}.grid-stack.grid-stack-27>.grid-stack-item[data-gs-max-width="25"]{max-width:92.5925925926%}.grid-stack.grid-stack-27>.grid-stack-item[data-gs-width="26"]{width:96.2962962963%}.grid-stack.grid-stack-27>.grid-stack-item[data-gs-x="26"]{left:96.2962962963%}.grid-stack.grid-stack-27>.grid-stack-item[data-gs-min-width="26"]{min-width:96.2962962963%}.grid-stack.grid-stack-27>.grid-stack-item[data-gs-max-width="26"]{max-width:96.2962962963%}.grid-stack.grid-stack-27>.grid-stack-item[data-gs-width="27"]{width:100%}.grid-stack.grid-stack-27>.grid-stack-item[data-gs-x="27"]{left:100%}.grid-stack.grid-stack-27>.grid-stack-item[data-gs-min-width="27"]{min-width:100%}.grid-stack.grid-stack-27>.grid-stack-item[data-gs-max-width="27"]{max-width:100%}.grid-stack.grid-stack-28>.grid-stack-item{min-width:3.5714285714%}.grid-stack.grid-stack-28>.grid-stack-item[data-gs-width="1"]{width:3.5714285714%}.grid-stack.grid-stack-28>.grid-stack-item[data-gs-x="1"]{left:3.5714285714%}.grid-stack.grid-stack-28>.grid-stack-item[data-gs-min-width="1"]{min-width:3.5714285714%}.grid-stack.grid-stack-28>.grid-stack-item[data-gs-max-width="1"]{max-width:3.5714285714%}.grid-stack.grid-stack-28>.grid-stack-item[data-gs-width="2"]{width:7.1428571429%}.grid-stack.grid-stack-28>.grid-stack-item[data-gs-x="2"]{left:7.1428571429%}.grid-stack.grid-stack-28>.grid-stack-item[data-gs-min-width="2"]{min-width:7.1428571429%}.grid-stack.grid-stack-28>.grid-stack-item[data-gs-max-width="2"]{max-width:7.1428571429%}.grid-stack.grid-stack-28>.grid-stack-item[data-gs-width="3"]{width:10.7142857143%}.grid-stack.grid-stack-28>.grid-stack-item[data-gs-x="3"]{left:10.7142857143%}.grid-stack.grid-stack-28>.grid-stack-item[data-gs-min-width="3"]{min-width:10.7142857143%}.grid-stack.grid-stack-28>.grid-stack-item[data-gs-max-width="3"]{max-width:10.7142857143%}.grid-stack.grid-stack-28>.grid-stack-item[data-gs-width="4"]{width:14.2857142857%}.grid-stack.grid-stack-28>.grid-stack-item[data-gs-x="4"]{left:14.2857142857%}.grid-stack.grid-stack-28>.grid-stack-item[data-gs-min-width="4"]{min-width:14.2857142857%}.grid-stack.grid-stack-28>.grid-stack-item[data-gs-max-width="4"]{max-width:14.2857142857%}.grid-stack.grid-stack-28>.grid-stack-item[data-gs-width="5"]{width:17.8571428571%}.grid-stack.grid-stack-28>.grid-stack-item[data-gs-x="5"]{left:17.8571428571%}.grid-stack.grid-stack-28>.grid-stack-item[data-gs-min-width="5"]{min-width:17.8571428571%}.grid-stack.grid-stack-28>.grid-stack-item[data-gs-max-width="5"]{max-width:17.8571428571%}.grid-stack.grid-stack-28>.grid-stack-item[data-gs-width="6"]{width:21.4285714286%}.grid-stack.grid-stack-28>.grid-stack-item[data-gs-x="6"]{left:21.4285714286%}.grid-stack.grid-stack-28>.grid-stack-item[data-gs-min-width="6"]{min-width:21.4285714286%}.grid-stack.grid-stack-28>.grid-stack-item[data-gs-max-width="6"]{max-width:21.4285714286%}.grid-stack.grid-stack-28>.grid-stack-item[data-gs-width="7"]{width:25%}.grid-stack.grid-stack-28>.grid-stack-item[data-gs-x="7"]{left:25%}.grid-stack.grid-stack-28>.grid-stack-item[data-gs-min-width="7"]{min-width:25%}.grid-stack.grid-stack-28>.grid-stack-item[data-gs-max-width="7"]{max-width:25%}.grid-stack.grid-stack-28>.grid-stack-item[data-gs-width="8"]{width:28.5714285714%}.grid-stack.grid-stack-28>.grid-stack-item[data-gs-x="8"]{left:28.5714285714%}.grid-stack.grid-stack-28>.grid-stack-item[data-gs-min-width="8"]{min-width:28.5714285714%}.grid-stack.grid-stack-28>.grid-stack-item[data-gs-max-width="8"]{max-width:28.5714285714%}.grid-stack.grid-stack-28>.grid-stack-item[data-gs-width="9"]{width:32.1428571429%}.grid-stack.grid-stack-28>.grid-stack-item[data-gs-x="9"]{left:32.1428571429%}.grid-stack.grid-stack-28>.grid-stack-item[data-gs-min-width="9"]{min-width:32.1428571429%}.grid-stack.grid-stack-28>.grid-stack-item[data-gs-max-width="9"]{max-width:32.1428571429%}.grid-stack.grid-stack-28>.grid-stack-item[data-gs-width="10"]{width:35.7142857143%}.grid-stack.grid-stack-28>.grid-stack-item[data-gs-x="10"]{left:35.7142857143%}.grid-stack.grid-stack-28>.grid-stack-item[data-gs-min-width="10"]{min-width:35.7142857143%}.grid-stack.grid-stack-28>.grid-stack-item[data-gs-max-width="10"]{max-width:35.7142857143%}.grid-stack.grid-stack-28>.grid-stack-item[data-gs-width="11"]{width:39.2857142857%}.grid-stack.grid-stack-28>.grid-stack-item[data-gs-x="11"]{left:39.2857142857%}.grid-stack.grid-stack-28>.grid-stack-item[data-gs-min-width="11"]{min-width:39.2857142857%}.grid-stack.grid-stack-28>.grid-stack-item[data-gs-max-width="11"]{max-width:39.2857142857%}.grid-stack.grid-stack-28>.grid-stack-item[data-gs-width="12"]{width:42.8571428571%}.grid-stack.grid-stack-28>.grid-stack-item[data-gs-x="12"]{left:42.8571428571%}.grid-stack.grid-stack-28>.grid-stack-item[data-gs-min-width="12"]{min-width:42.8571428571%}.grid-stack.grid-stack-28>.grid-stack-item[data-gs-max-width="12"]{max-width:42.8571428571%}.grid-stack.grid-stack-28>.grid-stack-item[data-gs-width="13"]{width:46.4285714286%}.grid-stack.grid-stack-28>.grid-stack-item[data-gs-x="13"]{left:46.4285714286%}.grid-stack.grid-stack-28>.grid-stack-item[data-gs-min-width="13"]{min-width:46.4285714286%}.grid-stack.grid-stack-28>.grid-stack-item[data-gs-max-width="13"]{max-width:46.4285714286%}.grid-stack.grid-stack-28>.grid-stack-item[data-gs-width="14"]{width:50%}.grid-stack.grid-stack-28>.grid-stack-item[data-gs-x="14"]{left:50%}.grid-stack.grid-stack-28>.grid-stack-item[data-gs-min-width="14"]{min-width:50%}.grid-stack.grid-stack-28>.grid-stack-item[data-gs-max-width="14"]{max-width:50%}.grid-stack.grid-stack-28>.grid-stack-item[data-gs-width="15"]{width:53.5714285714%}.grid-stack.grid-stack-28>.grid-stack-item[data-gs-x="15"]{left:53.5714285714%}.grid-stack.grid-stack-28>.grid-stack-item[data-gs-min-width="15"]{min-width:53.5714285714%}.grid-stack.grid-stack-28>.grid-stack-item[data-gs-max-width="15"]{max-width:53.5714285714%}.grid-stack.grid-stack-28>.grid-stack-item[data-gs-width="16"]{width:57.1428571429%}.grid-stack.grid-stack-28>.grid-stack-item[data-gs-x="16"]{left:57.1428571429%}.grid-stack.grid-stack-28>.grid-stack-item[data-gs-min-width="16"]{min-width:57.1428571429%}.grid-stack.grid-stack-28>.grid-stack-item[data-gs-max-width="16"]{max-width:57.1428571429%}.grid-stack.grid-stack-28>.grid-stack-item[data-gs-width="17"]{width:60.7142857143%}.grid-stack.grid-stack-28>.grid-stack-item[data-gs-x="17"]{left:60.7142857143%}.grid-stack.grid-stack-28>.grid-stack-item[data-gs-min-width="17"]{min-width:60.7142857143%}.grid-stack.grid-stack-28>.grid-stack-item[data-gs-max-width="17"]{max-width:60.7142857143%}.grid-stack.grid-stack-28>.grid-stack-item[data-gs-width="18"]{width:64.2857142857%}.grid-stack.grid-stack-28>.grid-stack-item[data-gs-x="18"]{left:64.2857142857%}.grid-stack.grid-stack-28>.grid-stack-item[data-gs-min-width="18"]{min-width:64.2857142857%}.grid-stack.grid-stack-28>.grid-stack-item[data-gs-max-width="18"]{max-width:64.2857142857%}.grid-stack.grid-stack-28>.grid-stack-item[data-gs-width="19"]{width:67.8571428571%}.grid-stack.grid-stack-28>.grid-stack-item[data-gs-x="19"]{left:67.8571428571%}.grid-stack.grid-stack-28>.grid-stack-item[data-gs-min-width="19"]{min-width:67.8571428571%}.grid-stack.grid-stack-28>.grid-stack-item[data-gs-max-width="19"]{max-width:67.8571428571%}.grid-stack.grid-stack-28>.grid-stack-item[data-gs-width="20"]{width:71.4285714286%}.grid-stack.grid-stack-28>.grid-stack-item[data-gs-x="20"]{left:71.4285714286%}.grid-stack.grid-stack-28>.grid-stack-item[data-gs-min-width="20"]{min-width:71.4285714286%}.grid-stack.grid-stack-28>.grid-stack-item[data-gs-max-width="20"]{max-width:71.4285714286%}.grid-stack.grid-stack-28>.grid-stack-item[data-gs-width="21"]{width:75%}.grid-stack.grid-stack-28>.grid-stack-item[data-gs-x="21"]{left:75%}.grid-stack.grid-stack-28>.grid-stack-item[data-gs-min-width="21"]{min-width:75%}.grid-stack.grid-stack-28>.grid-stack-item[data-gs-max-width="21"]{max-width:75%}.grid-stack.grid-stack-28>.grid-stack-item[data-gs-width="22"]{width:78.5714285714%}.grid-stack.grid-stack-28>.grid-stack-item[data-gs-x="22"]{left:78.5714285714%}.grid-stack.grid-stack-28>.grid-stack-item[data-gs-min-width="22"]{min-width:78.5714285714%}.grid-stack.grid-stack-28>.grid-stack-item[data-gs-max-width="22"]{max-width:78.5714285714%}.grid-stack.grid-stack-28>.grid-stack-item[data-gs-width="23"]{width:82.1428571429%}.grid-stack.grid-stack-28>.grid-stack-item[data-gs-x="23"]{left:82.1428571429%}.grid-stack.grid-stack-28>.grid-stack-item[data-gs-min-width="23"]{min-width:82.1428571429%}.grid-stack.grid-stack-28>.grid-stack-item[data-gs-max-width="23"]{max-width:82.1428571429%}.grid-stack.grid-stack-28>.grid-stack-item[data-gs-width="24"]{width:85.7142857143%}.grid-stack.grid-stack-28>.grid-stack-item[data-gs-x="24"]{left:85.7142857143%}.grid-stack.grid-stack-28>.grid-stack-item[data-gs-min-width="24"]{min-width:85.7142857143%}.grid-stack.grid-stack-28>.grid-stack-item[data-gs-max-width="24"]{max-width:85.7142857143%}.grid-stack.grid-stack-28>.grid-stack-item[data-gs-width="25"]{width:89.2857142857%}.grid-stack.grid-stack-28>.grid-stack-item[data-gs-x="25"]{left:89.2857142857%}.grid-stack.grid-stack-28>.grid-stack-item[data-gs-min-width="25"]{min-width:89.2857142857%}.grid-stack.grid-stack-28>.grid-stack-item[data-gs-max-width="25"]{max-width:89.2857142857%}.grid-stack.grid-stack-28>.grid-stack-item[data-gs-width="26"]{width:92.8571428571%}.grid-stack.grid-stack-28>.grid-stack-item[data-gs-x="26"]{left:92.8571428571%}.grid-stack.grid-stack-28>.grid-stack-item[data-gs-min-width="26"]{min-width:92.8571428571%}.grid-stack.grid-stack-28>.grid-stack-item[data-gs-max-width="26"]{max-width:92.8571428571%}.grid-stack.grid-stack-28>.grid-stack-item[data-gs-width="27"]{width:96.4285714286%}.grid-stack.grid-stack-28>.grid-stack-item[data-gs-x="27"]{left:96.4285714286%}.grid-stack.grid-stack-28>.grid-stack-item[data-gs-min-width="27"]{min-width:96.4285714286%}.grid-stack.grid-stack-28>.grid-stack-item[data-gs-max-width="27"]{max-width:96.4285714286%}.grid-stack.grid-stack-28>.grid-stack-item[data-gs-width="28"]{width:100%}.grid-stack.grid-stack-28>.grid-stack-item[data-gs-x="28"]{left:100%}.grid-stack.grid-stack-28>.grid-stack-item[data-gs-min-width="28"]{min-width:100%}.grid-stack.grid-stack-28>.grid-stack-item[data-gs-max-width="28"]{max-width:100%}.grid-stack.grid-stack-29>.grid-stack-item{min-width:3.4482758621%}.grid-stack.grid-stack-29>.grid-stack-item[data-gs-width="1"]{width:3.4482758621%}.grid-stack.grid-stack-29>.grid-stack-item[data-gs-x="1"]{left:3.4482758621%}.grid-stack.grid-stack-29>.grid-stack-item[data-gs-min-width="1"]{min-width:3.4482758621%}.grid-stack.grid-stack-29>.grid-stack-item[data-gs-max-width="1"]{max-width:3.4482758621%}.grid-stack.grid-stack-29>.grid-stack-item[data-gs-width="2"]{width:6.8965517241%}.grid-stack.grid-stack-29>.grid-stack-item[data-gs-x="2"]{left:6.8965517241%}.grid-stack.grid-stack-29>.grid-stack-item[data-gs-min-width="2"]{min-width:6.8965517241%}.grid-stack.grid-stack-29>.grid-stack-item[data-gs-max-width="2"]{max-width:6.8965517241%}.grid-stack.grid-stack-29>.grid-stack-item[data-gs-width="3"]{width:10.3448275862%}.grid-stack.grid-stack-29>.grid-stack-item[data-gs-x="3"]{left:10.3448275862%}.grid-stack.grid-stack-29>.grid-stack-item[data-gs-min-width="3"]{min-width:10.3448275862%}.grid-stack.grid-stack-29>.grid-stack-item[data-gs-max-width="3"]{max-width:10.3448275862%}.grid-stack.grid-stack-29>.grid-stack-item[data-gs-width="4"]{width:13.7931034483%}.grid-stack.grid-stack-29>.grid-stack-item[data-gs-x="4"]{left:13.7931034483%}.grid-stack.grid-stack-29>.grid-stack-item[data-gs-min-width="4"]{min-width:13.7931034483%}.grid-stack.grid-stack-29>.grid-stack-item[data-gs-max-width="4"]{max-width:13.7931034483%}.grid-stack.grid-stack-29>.grid-stack-item[data-gs-width="5"]{width:17.2413793103%}.grid-stack.grid-stack-29>.grid-stack-item[data-gs-x="5"]{left:17.2413793103%}.grid-stack.grid-stack-29>.grid-stack-item[data-gs-min-width="5"]{min-width:17.2413793103%}.grid-stack.grid-stack-29>.grid-stack-item[data-gs-max-width="5"]{max-width:17.2413793103%}.grid-stack.grid-stack-29>.grid-stack-item[data-gs-width="6"]{width:20.6896551724%}.grid-stack.grid-stack-29>.grid-stack-item[data-gs-x="6"]{left:20.6896551724%}.grid-stack.grid-stack-29>.grid-stack-item[data-gs-min-width="6"]{min-width:20.6896551724%}.grid-stack.grid-stack-29>.grid-stack-item[data-gs-max-width="6"]{max-width:20.6896551724%}.grid-stack.grid-stack-29>.grid-stack-item[data-gs-width="7"]{width:24.1379310345%}.grid-stack.grid-stack-29>.grid-stack-item[data-gs-x="7"]{left:24.1379310345%}.grid-stack.grid-stack-29>.grid-stack-item[data-gs-min-width="7"]{min-width:24.1379310345%}.grid-stack.grid-stack-29>.grid-stack-item[data-gs-max-width="7"]{max-width:24.1379310345%}.grid-stack.grid-stack-29>.grid-stack-item[data-gs-width="8"]{width:27.5862068966%}.grid-stack.grid-stack-29>.grid-stack-item[data-gs-x="8"]{left:27.5862068966%}.grid-stack.grid-stack-29>.grid-stack-item[data-gs-min-width="8"]{min-width:27.5862068966%}.grid-stack.grid-stack-29>.grid-stack-item[data-gs-max-width="8"]{max-width:27.5862068966%}.grid-stack.grid-stack-29>.grid-stack-item[data-gs-width="9"]{width:31.0344827586%}.grid-stack.grid-stack-29>.grid-stack-item[data-gs-x="9"]{left:31.0344827586%}.grid-stack.grid-stack-29>.grid-stack-item[data-gs-min-width="9"]{min-width:31.0344827586%}.grid-stack.grid-stack-29>.grid-stack-item[data-gs-max-width="9"]{max-width:31.0344827586%}.grid-stack.grid-stack-29>.grid-stack-item[data-gs-width="10"]{width:34.4827586207%}.grid-stack.grid-stack-29>.grid-stack-item[data-gs-x="10"]{left:34.4827586207%}.grid-stack.grid-stack-29>.grid-stack-item[data-gs-min-width="10"]{min-width:34.4827586207%}.grid-stack.grid-stack-29>.grid-stack-item[data-gs-max-width="10"]{max-width:34.4827586207%}.grid-stack.grid-stack-29>.grid-stack-item[data-gs-width="11"]{width:37.9310344828%}.grid-stack.grid-stack-29>.grid-stack-item[data-gs-x="11"]{left:37.9310344828%}.grid-stack.grid-stack-29>.grid-stack-item[data-gs-min-width="11"]{min-width:37.9310344828%}.grid-stack.grid-stack-29>.grid-stack-item[data-gs-max-width="11"]{max-width:37.9310344828%}.grid-stack.grid-stack-29>.grid-stack-item[data-gs-width="12"]{width:41.3793103448%}.grid-stack.grid-stack-29>.grid-stack-item[data-gs-x="12"]{left:41.3793103448%}.grid-stack.grid-stack-29>.grid-stack-item[data-gs-min-width="12"]{min-width:41.3793103448%}.grid-stack.grid-stack-29>.grid-stack-item[data-gs-max-width="12"]{max-width:41.3793103448%}.grid-stack.grid-stack-29>.grid-stack-item[data-gs-width="13"]{width:44.8275862069%}.grid-stack.grid-stack-29>.grid-stack-item[data-gs-x="13"]{left:44.8275862069%}.grid-stack.grid-stack-29>.grid-stack-item[data-gs-min-width="13"]{min-width:44.8275862069%}.grid-stack.grid-stack-29>.grid-stack-item[data-gs-max-width="13"]{max-width:44.8275862069%}.grid-stack.grid-stack-29>.grid-stack-item[data-gs-width="14"]{width:48.275862069%}.grid-stack.grid-stack-29>.grid-stack-item[data-gs-x="14"]{left:48.275862069%}.grid-stack.grid-stack-29>.grid-stack-item[data-gs-min-width="14"]{min-width:48.275862069%}.grid-stack.grid-stack-29>.grid-stack-item[data-gs-max-width="14"]{max-width:48.275862069%}.grid-stack.grid-stack-29>.grid-stack-item[data-gs-width="15"]{width:51.724137931%}.grid-stack.grid-stack-29>.grid-stack-item[data-gs-x="15"]{left:51.724137931%}.grid-stack.grid-stack-29>.grid-stack-item[data-gs-min-width="15"]{min-width:51.724137931%}.grid-stack.grid-stack-29>.grid-stack-item[data-gs-max-width="15"]{max-width:51.724137931%}.grid-stack.grid-stack-29>.grid-stack-item[data-gs-width="16"]{width:55.1724137931%}.grid-stack.grid-stack-29>.grid-stack-item[data-gs-x="16"]{left:55.1724137931%}.grid-stack.grid-stack-29>.grid-stack-item[data-gs-min-width="16"]{min-width:55.1724137931%}.grid-stack.grid-stack-29>.grid-stack-item[data-gs-max-width="16"]{max-width:55.1724137931%}.grid-stack.grid-stack-29>.grid-stack-item[data-gs-width="17"]{width:58.6206896552%}.grid-stack.grid-stack-29>.grid-stack-item[data-gs-x="17"]{left:58.6206896552%}.grid-stack.grid-stack-29>.grid-stack-item[data-gs-min-width="17"]{min-width:58.6206896552%}.grid-stack.grid-stack-29>.grid-stack-item[data-gs-max-width="17"]{max-width:58.6206896552%}.grid-stack.grid-stack-29>.grid-stack-item[data-gs-width="18"]{width:62.0689655172%}.grid-stack.grid-stack-29>.grid-stack-item[data-gs-x="18"]{left:62.0689655172%}.grid-stack.grid-stack-29>.grid-stack-item[data-gs-min-width="18"]{min-width:62.0689655172%}.grid-stack.grid-stack-29>.grid-stack-item[data-gs-max-width="18"]{max-width:62.0689655172%}.grid-stack.grid-stack-29>.grid-stack-item[data-gs-width="19"]{width:65.5172413793%}.grid-stack.grid-stack-29>.grid-stack-item[data-gs-x="19"]{left:65.5172413793%}.grid-stack.grid-stack-29>.grid-stack-item[data-gs-min-width="19"]{min-width:65.5172413793%}.grid-stack.grid-stack-29>.grid-stack-item[data-gs-max-width="19"]{max-width:65.5172413793%}.grid-stack.grid-stack-29>.grid-stack-item[data-gs-width="20"]{width:68.9655172414%}.grid-stack.grid-stack-29>.grid-stack-item[data-gs-x="20"]{left:68.9655172414%}.grid-stack.grid-stack-29>.grid-stack-item[data-gs-min-width="20"]{min-width:68.9655172414%}.grid-stack.grid-stack-29>.grid-stack-item[data-gs-max-width="20"]{max-width:68.9655172414%}.grid-stack.grid-stack-29>.grid-stack-item[data-gs-width="21"]{width:72.4137931034%}.grid-stack.grid-stack-29>.grid-stack-item[data-gs-x="21"]{left:72.4137931034%}.grid-stack.grid-stack-29>.grid-stack-item[data-gs-min-width="21"]{min-width:72.4137931034%}.grid-stack.grid-stack-29>.grid-stack-item[data-gs-max-width="21"]{max-width:72.4137931034%}.grid-stack.grid-stack-29>.grid-stack-item[data-gs-width="22"]{width:75.8620689655%}.grid-stack.grid-stack-29>.grid-stack-item[data-gs-x="22"]{left:75.8620689655%}.grid-stack.grid-stack-29>.grid-stack-item[data-gs-min-width="22"]{min-width:75.8620689655%}.grid-stack.grid-stack-29>.grid-stack-item[data-gs-max-width="22"]{max-width:75.8620689655%}.grid-stack.grid-stack-29>.grid-stack-item[data-gs-width="23"]{width:79.3103448276%}.grid-stack.grid-stack-29>.grid-stack-item[data-gs-x="23"]{left:79.3103448276%}.grid-stack.grid-stack-29>.grid-stack-item[data-gs-min-width="23"]{min-width:79.3103448276%}.grid-stack.grid-stack-29>.grid-stack-item[data-gs-max-width="23"]{max-width:79.3103448276%}.grid-stack.grid-stack-29>.grid-stack-item[data-gs-width="24"]{width:82.7586206897%}.grid-stack.grid-stack-29>.grid-stack-item[data-gs-x="24"]{left:82.7586206897%}.grid-stack.grid-stack-29>.grid-stack-item[data-gs-min-width="24"]{min-width:82.7586206897%}.grid-stack.grid-stack-29>.grid-stack-item[data-gs-max-width="24"]{max-width:82.7586206897%}.grid-stack.grid-stack-29>.grid-stack-item[data-gs-width="25"]{width:86.2068965517%}.grid-stack.grid-stack-29>.grid-stack-item[data-gs-x="25"]{left:86.2068965517%}.grid-stack.grid-stack-29>.grid-stack-item[data-gs-min-width="25"]{min-width:86.2068965517%}.grid-stack.grid-stack-29>.grid-stack-item[data-gs-max-width="25"]{max-width:86.2068965517%}.grid-stack.grid-stack-29>.grid-stack-item[data-gs-width="26"]{width:89.6551724138%}.grid-stack.grid-stack-29>.grid-stack-item[data-gs-x="26"]{left:89.6551724138%}.grid-stack.grid-stack-29>.grid-stack-item[data-gs-min-width="26"]{min-width:89.6551724138%}.grid-stack.grid-stack-29>.grid-stack-item[data-gs-max-width="26"]{max-width:89.6551724138%}.grid-stack.grid-stack-29>.grid-stack-item[data-gs-width="27"]{width:93.1034482759%}.grid-stack.grid-stack-29>.grid-stack-item[data-gs-x="27"]{left:93.1034482759%}.grid-stack.grid-stack-29>.grid-stack-item[data-gs-min-width="27"]{min-width:93.1034482759%}.grid-stack.grid-stack-29>.grid-stack-item[data-gs-max-width="27"]{max-width:93.1034482759%}.grid-stack.grid-stack-29>.grid-stack-item[data-gs-width="28"]{width:96.5517241379%}.grid-stack.grid-stack-29>.grid-stack-item[data-gs-x="28"]{left:96.5517241379%}.grid-stack.grid-stack-29>.grid-stack-item[data-gs-min-width="28"]{min-width:96.5517241379%}.grid-stack.grid-stack-29>.grid-stack-item[data-gs-max-width="28"]{max-width:96.5517241379%}.grid-stack.grid-stack-29>.grid-stack-item[data-gs-width="29"]{width:100%}.grid-stack.grid-stack-29>.grid-stack-item[data-gs-x="29"]{left:100%}.grid-stack.grid-stack-29>.grid-stack-item[data-gs-min-width="29"]{min-width:100%}.grid-stack.grid-stack-29>.grid-stack-item[data-gs-max-width="29"]{max-width:100%}.grid-stack.grid-stack-30>.grid-stack-item{min-width:3.3333333333%}.grid-stack.grid-stack-30>.grid-stack-item[data-gs-width="1"]{width:3.3333333333%}.grid-stack.grid-stack-30>.grid-stack-item[data-gs-x="1"]{left:3.3333333333%}.grid-stack.grid-stack-30>.grid-stack-item[data-gs-min-width="1"]{min-width:3.3333333333%}.grid-stack.grid-stack-30>.grid-stack-item[data-gs-max-width="1"]{max-width:3.3333333333%}.grid-stack.grid-stack-30>.grid-stack-item[data-gs-width="2"]{width:6.6666666667%}.grid-stack.grid-stack-30>.grid-stack-item[data-gs-x="2"]{left:6.6666666667%}.grid-stack.grid-stack-30>.grid-stack-item[data-gs-min-width="2"]{min-width:6.6666666667%}.grid-stack.grid-stack-30>.grid-stack-item[data-gs-max-width="2"]{max-width:6.6666666667%}.grid-stack.grid-stack-30>.grid-stack-item[data-gs-width="3"]{width:10%}.grid-stack.grid-stack-30>.grid-stack-item[data-gs-x="3"]{left:10%}.grid-stack.grid-stack-30>.grid-stack-item[data-gs-min-width="3"]{min-width:10%}.grid-stack.grid-stack-30>.grid-stack-item[data-gs-max-width="3"]{max-width:10%}.grid-stack.grid-stack-30>.grid-stack-item[data-gs-width="4"]{width:13.3333333333%}.grid-stack.grid-stack-30>.grid-stack-item[data-gs-x="4"]{left:13.3333333333%}.grid-stack.grid-stack-30>.grid-stack-item[data-gs-min-width="4"]{min-width:13.3333333333%}.grid-stack.grid-stack-30>.grid-stack-item[data-gs-max-width="4"]{max-width:13.3333333333%}.grid-stack.grid-stack-30>.grid-stack-item[data-gs-width="5"]{width:16.6666666667%}.grid-stack.grid-stack-30>.grid-stack-item[data-gs-x="5"]{left:16.6666666667%}.grid-stack.grid-stack-30>.grid-stack-item[data-gs-min-width="5"]{min-width:16.6666666667%}.grid-stack.grid-stack-30>.grid-stack-item[data-gs-max-width="5"]{max-width:16.6666666667%}.grid-stack.grid-stack-30>.grid-stack-item[data-gs-width="6"]{width:20%}.grid-stack.grid-stack-30>.grid-stack-item[data-gs-x="6"]{left:20%}.grid-stack.grid-stack-30>.grid-stack-item[data-gs-min-width="6"]{min-width:20%}.grid-stack.grid-stack-30>.grid-stack-item[data-gs-max-width="6"]{max-width:20%}.grid-stack.grid-stack-30>.grid-stack-item[data-gs-width="7"]{width:23.3333333333%}.grid-stack.grid-stack-30>.grid-stack-item[data-gs-x="7"]{left:23.3333333333%}.grid-stack.grid-stack-30>.grid-stack-item[data-gs-min-width="7"]{min-width:23.3333333333%}.grid-stack.grid-stack-30>.grid-stack-item[data-gs-max-width="7"]{max-width:23.3333333333%}.grid-stack.grid-stack-30>.grid-stack-item[data-gs-width="8"]{width:26.6666666667%}.grid-stack.grid-stack-30>.grid-stack-item[data-gs-x="8"]{left:26.6666666667%}.grid-stack.grid-stack-30>.grid-stack-item[data-gs-min-width="8"]{min-width:26.6666666667%}.grid-stack.grid-stack-30>.grid-stack-item[data-gs-max-width="8"]{max-width:26.6666666667%}.grid-stack.grid-stack-30>.grid-stack-item[data-gs-width="9"]{width:30%}.grid-stack.grid-stack-30>.grid-stack-item[data-gs-x="9"]{left:30%}.grid-stack.grid-stack-30>.grid-stack-item[data-gs-min-width="9"]{min-width:30%}.grid-stack.grid-stack-30>.grid-stack-item[data-gs-max-width="9"]{max-width:30%}.grid-stack.grid-stack-30>.grid-stack-item[data-gs-width="10"]{width:33.3333333333%}.grid-stack.grid-stack-30>.grid-stack-item[data-gs-x="10"]{left:33.3333333333%}.grid-stack.grid-stack-30>.grid-stack-item[data-gs-min-width="10"]{min-width:33.3333333333%}.grid-stack.grid-stack-30>.grid-stack-item[data-gs-max-width="10"]{max-width:33.3333333333%}.grid-stack.grid-stack-30>.grid-stack-item[data-gs-width="11"]{width:36.6666666667%}.grid-stack.grid-stack-30>.grid-stack-item[data-gs-x="11"]{left:36.6666666667%}.grid-stack.grid-stack-30>.grid-stack-item[data-gs-min-width="11"]{min-width:36.6666666667%}.grid-stack.grid-stack-30>.grid-stack-item[data-gs-max-width="11"]{max-width:36.6666666667%}.grid-stack.grid-stack-30>.grid-stack-item[data-gs-width="12"]{width:40%}.grid-stack.grid-stack-30>.grid-stack-item[data-gs-x="12"]{left:40%}.grid-stack.grid-stack-30>.grid-stack-item[data-gs-min-width="12"]{min-width:40%}.grid-stack.grid-stack-30>.grid-stack-item[data-gs-max-width="12"]{max-width:40%}.grid-stack.grid-stack-30>.grid-stack-item[data-gs-width="13"]{width:43.3333333333%}.grid-stack.grid-stack-30>.grid-stack-item[data-gs-x="13"]{left:43.3333333333%}.grid-stack.grid-stack-30>.grid-stack-item[data-gs-min-width="13"]{min-width:43.3333333333%}.grid-stack.grid-stack-30>.grid-stack-item[data-gs-max-width="13"]{max-width:43.3333333333%}.grid-stack.grid-stack-30>.grid-stack-item[data-gs-width="14"]{width:46.6666666667%}.grid-stack.grid-stack-30>.grid-stack-item[data-gs-x="14"]{left:46.6666666667%}.grid-stack.grid-stack-30>.grid-stack-item[data-gs-min-width="14"]{min-width:46.6666666667%}.grid-stack.grid-stack-30>.grid-stack-item[data-gs-max-width="14"]{max-width:46.6666666667%}.grid-stack.grid-stack-30>.grid-stack-item[data-gs-width="15"]{width:50%}.grid-stack.grid-stack-30>.grid-stack-item[data-gs-x="15"]{left:50%}.grid-stack.grid-stack-30>.grid-stack-item[data-gs-min-width="15"]{min-width:50%}.grid-stack.grid-stack-30>.grid-stack-item[data-gs-max-width="15"]{max-width:50%}.grid-stack.grid-stack-30>.grid-stack-item[data-gs-width="16"]{width:53.3333333333%}.grid-stack.grid-stack-30>.grid-stack-item[data-gs-x="16"]{left:53.3333333333%}.grid-stack.grid-stack-30>.grid-stack-item[data-gs-min-width="16"]{min-width:53.3333333333%}.grid-stack.grid-stack-30>.grid-stack-item[data-gs-max-width="16"]{max-width:53.3333333333%}.grid-stack.grid-stack-30>.grid-stack-item[data-gs-width="17"]{width:56.6666666667%}.grid-stack.grid-stack-30>.grid-stack-item[data-gs-x="17"]{left:56.6666666667%}.grid-stack.grid-stack-30>.grid-stack-item[data-gs-min-width="17"]{min-width:56.6666666667%}.grid-stack.grid-stack-30>.grid-stack-item[data-gs-max-width="17"]{max-width:56.6666666667%}.grid-stack.grid-stack-30>.grid-stack-item[data-gs-width="18"]{width:60%}.grid-stack.grid-stack-30>.grid-stack-item[data-gs-x="18"]{left:60%}.grid-stack.grid-stack-30>.grid-stack-item[data-gs-min-width="18"]{min-width:60%}.grid-stack.grid-stack-30>.grid-stack-item[data-gs-max-width="18"]{max-width:60%}.grid-stack.grid-stack-30>.grid-stack-item[data-gs-width="19"]{width:63.3333333333%}.grid-stack.grid-stack-30>.grid-stack-item[data-gs-x="19"]{left:63.3333333333%}.grid-stack.grid-stack-30>.grid-stack-item[data-gs-min-width="19"]{min-width:63.3333333333%}.grid-stack.grid-stack-30>.grid-stack-item[data-gs-max-width="19"]{max-width:63.3333333333%}.grid-stack.grid-stack-30>.grid-stack-item[data-gs-width="20"]{width:66.6666666667%}.grid-stack.grid-stack-30>.grid-stack-item[data-gs-x="20"]{left:66.6666666667%}.grid-stack.grid-stack-30>.grid-stack-item[data-gs-min-width="20"]{min-width:66.6666666667%}.grid-stack.grid-stack-30>.grid-stack-item[data-gs-max-width="20"]{max-width:66.6666666667%}.grid-stack.grid-stack-30>.grid-stack-item[data-gs-width="21"]{width:70%}.grid-stack.grid-stack-30>.grid-stack-item[data-gs-x="21"]{left:70%}.grid-stack.grid-stack-30>.grid-stack-item[data-gs-min-width="21"]{min-width:70%}.grid-stack.grid-stack-30>.grid-stack-item[data-gs-max-width="21"]{max-width:70%}.grid-stack.grid-stack-30>.grid-stack-item[data-gs-width="22"]{width:73.3333333333%}.grid-stack.grid-stack-30>.grid-stack-item[data-gs-x="22"]{left:73.3333333333%}.grid-stack.grid-stack-30>.grid-stack-item[data-gs-min-width="22"]{min-width:73.3333333333%}.grid-stack.grid-stack-30>.grid-stack-item[data-gs-max-width="22"]{max-width:73.3333333333%}.grid-stack.grid-stack-30>.grid-stack-item[data-gs-width="23"]{width:76.6666666667%}.grid-stack.grid-stack-30>.grid-stack-item[data-gs-x="23"]{left:76.6666666667%}.grid-stack.grid-stack-30>.grid-stack-item[data-gs-min-width="23"]{min-width:76.6666666667%}.grid-stack.grid-stack-30>.grid-stack-item[data-gs-max-width="23"]{max-width:76.6666666667%}.grid-stack.grid-stack-30>.grid-stack-item[data-gs-width="24"]{width:80%}.grid-stack.grid-stack-30>.grid-stack-item[data-gs-x="24"]{left:80%}.grid-stack.grid-stack-30>.grid-stack-item[data-gs-min-width="24"]{min-width:80%}.grid-stack.grid-stack-30>.grid-stack-item[data-gs-max-width="24"]{max-width:80%}.grid-stack.grid-stack-30>.grid-stack-item[data-gs-width="25"]{width:83.3333333333%}.grid-stack.grid-stack-30>.grid-stack-item[data-gs-x="25"]{left:83.3333333333%}.grid-stack.grid-stack-30>.grid-stack-item[data-gs-min-width="25"]{min-width:83.3333333333%}.grid-stack.grid-stack-30>.grid-stack-item[data-gs-max-width="25"]{max-width:83.3333333333%}.grid-stack.grid-stack-30>.grid-stack-item[data-gs-width="26"]{width:86.6666666667%}.grid-stack.grid-stack-30>.grid-stack-item[data-gs-x="26"]{left:86.6666666667%}.grid-stack.grid-stack-30>.grid-stack-item[data-gs-min-width="26"]{min-width:86.6666666667%}.grid-stack.grid-stack-30>.grid-stack-item[data-gs-max-width="26"]{max-width:86.6666666667%}.grid-stack.grid-stack-30>.grid-stack-item[data-gs-width="27"]{width:90%}.grid-stack.grid-stack-30>.grid-stack-item[data-gs-x="27"]{left:90%}.grid-stack.grid-stack-30>.grid-stack-item[data-gs-min-width="27"]{min-width:90%}.grid-stack.grid-stack-30>.grid-stack-item[data-gs-max-width="27"]{max-width:90%}.grid-stack.grid-stack-30>.grid-stack-item[data-gs-width="28"]{width:93.3333333333%}.grid-stack.grid-stack-30>.grid-stack-item[data-gs-x="28"]{left:93.3333333333%}.grid-stack.grid-stack-30>.grid-stack-item[data-gs-min-width="28"]{min-width:93.3333333333%}.grid-stack.grid-stack-30>.grid-stack-item[data-gs-max-width="28"]{max-width:93.3333333333%}.grid-stack.grid-stack-30>.grid-stack-item[data-gs-width="29"]{width:96.6666666667%}.grid-stack.grid-stack-30>.grid-stack-item[data-gs-x="29"]{left:96.6666666667%}.grid-stack.grid-stack-30>.grid-stack-item[data-gs-min-width="29"]{min-width:96.6666666667%}.grid-stack.grid-stack-30>.grid-stack-item[data-gs-max-width="29"]{max-width:96.6666666667%}.grid-stack.grid-stack-30>.grid-stack-item[data-gs-width="30"]{width:100%}.grid-stack.grid-stack-30>.grid-stack-item[data-gs-x="30"]{left:100%}.grid-stack.grid-stack-30>.grid-stack-item[data-gs-min-width="30"]{min-width:100%}.grid-stack.grid-stack-30>.grid-stack-item[data-gs-max-width="30"]{max-width:100%}.grid-stack>.grid-stack-item>.grid-stack-item-content{overflow:hidden;line-height:18px} \ No newline at end of file diff --git a/software/dashboard/grafana/csv/Node-RED_files/gridstack.jQueryUI.min.js b/software/dashboard/grafana/csv/Node-RED_files/gridstack.jQueryUI.min.js new file mode 100644 index 0000000..6ab22f2 --- /dev/null +++ b/software/dashboard/grafana/csv/Node-RED_files/gridstack.jQueryUI.min.js @@ -0,0 +1,3 @@ +/** gridstack.js 0.6.4 - JQuery UI Drag&Drop plugin @preserve */ +!function(t){if("function"==typeof define&&define.amd)define(["jquery","gridstack","exports"],t);else if("undefined"!=typeof exports){try{jQuery=require("jquery")}catch(t){}try{gridstack=require("gridstack")}catch(t){}t(jQuery,gridstack.GridStackUI,exports)}else t(jQuery,GridStackUI,window)}(function(a,e,t){function r(t){e.GridStackDragDropPlugin.call(this,t)}return e.GridStackDragDropPlugin.registerPlugin(r),((r.prototype=Object.create(e.GridStackDragDropPlugin.prototype)).constructor=r).prototype.resizable=function(t,e){if(t=a(t),"disable"===e||"enable"===e)t.resizable(e);else if("option"===e){var r=arguments[2],i=arguments[3];t.resizable(e,r,i)}else{var n=t.data("gs-resize-handles")?t.data("gs-resize-handles"):this.grid.opts.resizable.handles;t.resizable(a.extend({},this.grid.opts.resizable,{handles:n},{start:e.start||function(){},stop:e.stop||function(){},resize:e.resize||function(){}}))}return this},r.prototype.draggable=function(t,e){return t=a(t),"disable"===e||"enable"===e?t.draggable(e):t.draggable(a.extend({},this.grid.opts.draggable,{containment:this.grid.opts.isNested&&!this.grid.opts.dragOut?this.grid.container.parent():this.grid.opts.draggable.containment||null,start:e.start||function(){},stop:e.stop||function(){},drag:e.drag||function(){}})),this},r.prototype.droppable=function(t,e){return(t=a(t)).droppable(e),this},r.prototype.isDroppable=function(t,e){return t=a(t),Boolean(t.data("droppable"))},r.prototype.on=function(t,e,r){return a(t).on(e,r),this},t.JQueryUIGridStackDragDropPlugin=r}); +//# sourceMappingURL=gridstack.min.map \ No newline at end of file diff --git a/software/dashboard/grafana/csv/Node-RED_files/gridstack.min.css b/software/dashboard/grafana/csv/Node-RED_files/gridstack.min.css new file mode 100644 index 0000000..b874768 --- /dev/null +++ b/software/dashboard/grafana/csv/Node-RED_files/gridstack.min.css @@ -0,0 +1,6 @@ +/*! + * required gridstack 0.6.4 CSS for default 12 and 1 columnMode size. Use gridstack-extra.css for others + * https://gridstackjs.com/ + * (c) 2014-2020 Alain Dumesny, Dylan Weiss, Pavel Reznikov + * gridstack.js may be freely distributed under the MIT license. +*/:root .grid-stack-item>.ui-resizable-handle{filter:none}.grid-stack{position:relative}.grid-stack.grid-stack-rtl{direction:ltr}.grid-stack.grid-stack-rtl>.grid-stack-item{direction:rtl}.grid-stack .grid-stack-placeholder>.placeholder-content{border:1px dashed #d3d3d3;margin:0;position:absolute;top:0;left:10px;right:10px;bottom:0;width:auto;z-index:0!important;text-align:center}.grid-stack>.grid-stack-item{min-width:8.3333333333%;position:absolute;padding:0}.grid-stack>.grid-stack-item>.grid-stack-item-content{margin:0;position:absolute;top:0;left:10px;right:10px;bottom:0;width:auto;overflow-x:hidden;overflow-y:auto}.grid-stack>.grid-stack-item>.ui-resizable-handle{position:absolute;font-size:.1px;display:block;-ms-touch-action:none;touch-action:none}.grid-stack>.grid-stack-item.ui-resizable-autohide>.ui-resizable-handle,.grid-stack>.grid-stack-item.ui-resizable-disabled>.ui-resizable-handle{display:none}.grid-stack>.grid-stack-item.ui-draggable-dragging,.grid-stack>.grid-stack-item.ui-resizable-resizing{z-index:100}.grid-stack>.grid-stack-item.ui-draggable-dragging>.grid-stack-item-content,.grid-stack>.grid-stack-item.ui-resizable-resizing>.grid-stack-item-content{box-shadow:1px 4px 6px rgba(0,0,0,.2);opacity:.8}.grid-stack>.grid-stack-item>.ui-resizable-se,.grid-stack>.grid-stack-item>.ui-resizable-sw{background-image:url(data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0iaXNvLTg4NTktMSI/Pgo8IS0tIEdlbmVyYXRvcjogQWRvYmUgSWxsdXN0cmF0b3IgMTYuMC4wLCBTVkcgRXhwb3J0IFBsdWctSW4gLiBTVkcgVmVyc2lvbjogNi4wMCBCdWlsZCAwKSAgLS0+CjwhRE9DVFlQRSBzdmcgUFVCTElDICItLy9XM0MvL0RURCBTVkcgMS4xLy9FTiIgImh0dHA6Ly93d3cudzMub3JnL0dyYXBoaWNzL1NWRy8xLjEvRFREL3N2ZzExLmR0ZCI+CjxzdmcgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIiB4bWxuczp4bGluaz0iaHR0cDovL3d3dy53My5vcmcvMTk5OS94bGluayIgdmVyc2lvbj0iMS4xIiBpZD0iQ2FwYV8xIiB4PSIwcHgiIHk9IjBweCIgd2lkdGg9IjE2cHgiIGhlaWdodD0iMTZweCIgdmlld0JveD0iMCAwIDUxMS42MjYgNTExLjYyNyIgc3R5bGU9ImVuYWJsZS1iYWNrZ3JvdW5kOm5ldyAwIDAgNTExLjYyNiA1MTEuNjI3OyIgeG1sOnNwYWNlPSJwcmVzZXJ2ZSI+CjxnPgoJPHBhdGggZD0iTTMyOC45MDYsNDAxLjk5NGgtMzYuNTUzVjEwOS42MzZoMzYuNTUzYzQuOTQ4LDAsOS4yMzYtMS44MDksMTIuODQ3LTUuNDI2YzMuNjEzLTMuNjE1LDUuNDIxLTcuODk4LDUuNDIxLTEyLjg0NSAgIGMwLTQuOTQ5LTEuODAxLTkuMjMxLTUuNDI4LTEyLjg1MWwtNzMuMDg3LTczLjA5QzI2NS4wNDQsMS44MDksMjYwLjc2LDAsMjU1LjgxMywwYy00Ljk0OCwwLTkuMjI5LDEuODA5LTEyLjg0Nyw1LjQyNCAgIGwtNzMuMDg4LDczLjA5Yy0zLjYxOCwzLjYxOS01LjQyNCw3LjkwMi01LjQyNCwxMi44NTFjMCw0Ljk0NiwxLjgwNyw5LjIyOSw1LjQyNCwxMi44NDVjMy42MTksMy42MTcsNy45MDEsNS40MjYsMTIuODUsNS40MjYgICBoMzYuNTQ1djI5Mi4zNThoLTM2LjU0MmMtNC45NTIsMC05LjIzNSwxLjgwOC0xMi44NSw1LjQyMWMtMy42MTcsMy42MjEtNS40MjQsNy45MDUtNS40MjQsMTIuODU0ICAgYzAsNC45NDUsMS44MDcsOS4yMjcsNS40MjQsMTIuODQ3bDczLjA4OSw3My4wODhjMy42MTcsMy42MTcsNy44OTgsNS40MjQsMTIuODQ3LDUuNDI0YzQuOTUsMCw5LjIzNC0xLjgwNywxMi44NDktNS40MjQgICBsNzMuMDg3LTczLjA4OGMzLjYxMy0zLjYyLDUuNDIxLTcuOTAxLDUuNDIxLTEyLjg0N2MwLTQuOTQ4LTEuODA4LTkuMjMyLTUuNDIxLTEyLjg1NCAgIEMzMzguMTQyLDQwMy44MDIsMzMzLjg1Nyw0MDEuOTk0LDMyOC45MDYsNDAxLjk5NHoiIGZpbGw9IiM2NjY2NjYiLz4KPC9nPgo8Zz4KPC9nPgo8Zz4KPC9nPgo8Zz4KPC9nPgo8Zz4KPC9nPgo8Zz4KPC9nPgo8Zz4KPC9nPgo8Zz4KPC9nPgo8Zz4KPC9nPgo8Zz4KPC9nPgo8Zz4KPC9nPgo8Zz4KPC9nPgo8Zz4KPC9nPgo8Zz4KPC9nPgo8Zz4KPC9nPgo8Zz4KPC9nPgo8L3N2Zz4K);background-repeat:no-repeat;background-position:center;-webkit-transform:rotate(45deg);-moz-transform:rotate(45deg);-ms-transform:rotate(45deg);-o-transform:rotate(45deg);transform:rotate(45deg)}.grid-stack>.grid-stack-item>.ui-resizable-se{-webkit-transform:rotate(-45deg);-moz-transform:rotate(-45deg);-ms-transform:rotate(-45deg);-o-transform:rotate(-45deg);transform:rotate(-45deg)}.grid-stack>.grid-stack-item>.ui-resizable-nw{cursor:nw-resize;width:20px;height:20px;left:10px;top:0}.grid-stack>.grid-stack-item>.ui-resizable-n{cursor:n-resize;height:10px;top:0;left:25px;right:25px}.grid-stack>.grid-stack-item>.ui-resizable-ne{cursor:ne-resize;width:20px;height:20px;right:10px;top:0}.grid-stack>.grid-stack-item>.ui-resizable-e{cursor:e-resize;width:10px;right:10px;top:15px;bottom:15px}.grid-stack>.grid-stack-item>.ui-resizable-se{cursor:se-resize;width:20px;height:20px;right:10px;bottom:0}.grid-stack>.grid-stack-item>.ui-resizable-s{cursor:s-resize;height:10px;left:25px;bottom:0;right:25px}.grid-stack>.grid-stack-item>.ui-resizable-sw{cursor:sw-resize;width:20px;height:20px;left:10px;bottom:0}.grid-stack>.grid-stack-item>.ui-resizable-w{cursor:w-resize;width:10px;left:10px;top:15px;bottom:15px}.grid-stack>.grid-stack-item.ui-draggable-dragging>.ui-resizable-handle{display:none!important}.grid-stack>.grid-stack-item[data-gs-width='1']{width:8.3333333333%}.grid-stack>.grid-stack-item[data-gs-x='1']{left:8.3333333333%}.grid-stack>.grid-stack-item[data-gs-min-width='1']{min-width:8.3333333333%}.grid-stack>.grid-stack-item[data-gs-max-width='1']{max-width:8.3333333333%}.grid-stack>.grid-stack-item[data-gs-width='2']{width:16.6666666667%}.grid-stack>.grid-stack-item[data-gs-x='2']{left:16.6666666667%}.grid-stack>.grid-stack-item[data-gs-min-width='2']{min-width:16.6666666667%}.grid-stack>.grid-stack-item[data-gs-max-width='2']{max-width:16.6666666667%}.grid-stack>.grid-stack-item[data-gs-width='3']{width:25%}.grid-stack>.grid-stack-item[data-gs-x='3']{left:25%}.grid-stack>.grid-stack-item[data-gs-min-width='3']{min-width:25%}.grid-stack>.grid-stack-item[data-gs-max-width='3']{max-width:25%}.grid-stack>.grid-stack-item[data-gs-width='4']{width:33.3333333333%}.grid-stack>.grid-stack-item[data-gs-x='4']{left:33.3333333333%}.grid-stack>.grid-stack-item[data-gs-min-width='4']{min-width:33.3333333333%}.grid-stack>.grid-stack-item[data-gs-max-width='4']{max-width:33.3333333333%}.grid-stack>.grid-stack-item[data-gs-width='5']{width:41.6666666667%}.grid-stack>.grid-stack-item[data-gs-x='5']{left:41.6666666667%}.grid-stack>.grid-stack-item[data-gs-min-width='5']{min-width:41.6666666667%}.grid-stack>.grid-stack-item[data-gs-max-width='5']{max-width:41.6666666667%}.grid-stack>.grid-stack-item[data-gs-width='6']{width:50%}.grid-stack>.grid-stack-item[data-gs-x='6']{left:50%}.grid-stack>.grid-stack-item[data-gs-min-width='6']{min-width:50%}.grid-stack>.grid-stack-item[data-gs-max-width='6']{max-width:50%}.grid-stack>.grid-stack-item[data-gs-width='7']{width:58.3333333333%}.grid-stack>.grid-stack-item[data-gs-x='7']{left:58.3333333333%}.grid-stack>.grid-stack-item[data-gs-min-width='7']{min-width:58.3333333333%}.grid-stack>.grid-stack-item[data-gs-max-width='7']{max-width:58.3333333333%}.grid-stack>.grid-stack-item[data-gs-width='8']{width:66.6666666667%}.grid-stack>.grid-stack-item[data-gs-x='8']{left:66.6666666667%}.grid-stack>.grid-stack-item[data-gs-min-width='8']{min-width:66.6666666667%}.grid-stack>.grid-stack-item[data-gs-max-width='8']{max-width:66.6666666667%}.grid-stack>.grid-stack-item[data-gs-width='9']{width:75%}.grid-stack>.grid-stack-item[data-gs-x='9']{left:75%}.grid-stack>.grid-stack-item[data-gs-min-width='9']{min-width:75%}.grid-stack>.grid-stack-item[data-gs-max-width='9']{max-width:75%}.grid-stack>.grid-stack-item[data-gs-width='10']{width:83.3333333333%}.grid-stack>.grid-stack-item[data-gs-x='10']{left:83.3333333333%}.grid-stack>.grid-stack-item[data-gs-min-width='10']{min-width:83.3333333333%}.grid-stack>.grid-stack-item[data-gs-max-width='10']{max-width:83.3333333333%}.grid-stack>.grid-stack-item[data-gs-width='11']{width:91.6666666667%}.grid-stack>.grid-stack-item[data-gs-x='11']{left:91.6666666667%}.grid-stack>.grid-stack-item[data-gs-min-width='11']{min-width:91.6666666667%}.grid-stack>.grid-stack-item[data-gs-max-width='11']{max-width:91.6666666667%}.grid-stack>.grid-stack-item[data-gs-width='12']{width:100%}.grid-stack>.grid-stack-item[data-gs-x='12']{left:100%}.grid-stack>.grid-stack-item[data-gs-min-width='12']{min-width:100%}.grid-stack>.grid-stack-item[data-gs-max-width='12']{max-width:100%}.grid-stack.grid-stack-1>.grid-stack-item{min-width:100%}.grid-stack.grid-stack-1>.grid-stack-item[data-gs-width='1']{width:100%}.grid-stack.grid-stack-1>.grid-stack-item[data-gs-x='1']{left:100%}.grid-stack.grid-stack-1>.grid-stack-item[data-gs-min-width='1']{min-width:100%}.grid-stack.grid-stack-1>.grid-stack-item[data-gs-max-width='1']{max-width:100%}.grid-stack.grid-stack-animate,.grid-stack.grid-stack-animate .grid-stack-item{-webkit-transition:left .3s,top .3s,height .3s,width .3s;-moz-transition:left .3s,top .3s,height .3s,width .3s;-ms-transition:left .3s,top .3s,height .3s,width .3s;-o-transition:left .3s,top .3s,height .3s,width .3s;transition:left .3s,top .3s,height .3s,width .3s}.grid-stack.grid-stack-animate .grid-stack-item.grid-stack-placeholder,.grid-stack.grid-stack-animate .grid-stack-item.ui-draggable-dragging,.grid-stack.grid-stack-animate .grid-stack-item.ui-resizable-resizing{-webkit-transition:left 0s,top 0s,height 0s,width 0s;-moz-transition:left 0s,top 0s,height 0s,width 0s;-ms-transition:left 0s,top 0s,height 0s,width 0s;-o-transition:left 0s,top 0s,height 0s,width 0s;transition:left 0s,top 0s,height 0s,width 0s} \ No newline at end of file diff --git a/software/dashboard/grafana/csv/Node-RED_files/gridstack.min.js b/software/dashboard/grafana/csv/Node-RED_files/gridstack.min.js new file mode 100644 index 0000000..af781f3 --- /dev/null +++ b/software/dashboard/grafana/csv/Node-RED_files/gridstack.min.js @@ -0,0 +1,9 @@ +/** + * gridstack.js 0.6.4 + * https://gridstackjs.com/ + * (c) 2014-2020 Alain Dumesny, Dylan Weiss, Pavel Reznikov + * gridstack.js may be freely distributed under the MIT license. + * @preserve +*/ +!function(t){if("function"==typeof define&&define.amd)define(["jquery","exports"],t);else if("undefined"!=typeof exports){var e;try{e=require("jquery")}catch(t){}t(e||window.jQuery,exports)}else t(window.jQuery,window)}(function(m,t){function n(t,e,i,o){void 0!==t[e]&&(t[i]=t[e],console.warn("gridstack.js: Option `"+e+"` is deprecated in "+o+" and has been replaced with `"+i+"`. It will be **completely** removed in v1.0"))}function d(t,e,i,o){var a=t.attr(e);void 0!==a&&(t.attr(i,a),console.warn("gridstack.js: attribute `"+e+"`="+a+" is deprecated on this object in "+o+" and has been replaced with `"+i+"`. It will be **completely** removed in v1.0"))}var f={isIntercepted:function(t,e){return!(t.x+t.width<=e.x||e.x+e.width<=t.x||t.y+t.height<=e.y||e.y+e.height<=t.y)},sort:function(t,e,i){if(!i){var o=t.map(function(t){return t.x+t.width});i=Math.max.apply(Math,o)}return-1===e?f.sortBy(t,function(t){return-(t.x+t.y*i)}):f.sortBy(t,function(t){return t.x+t.y*i})},createStylesheet:function(t,e){var i=document.createElement("style");return i.setAttribute("type","text/css"),i.setAttribute("data-gs-style-id",t),i.styleSheet?i.styleSheet.cssText="":i.appendChild(document.createTextNode("")),(e=e||document.getElementsByTagName("head")[0]).insertBefore(i,e.firstChild),i.sheet},removeStylesheet:function(t){m("STYLE[data-gs-style-id="+t+"]").remove()},insertCSSRule:function(t,e,i,o){"function"==typeof t.insertRule?t.insertRule(e+"{"+i+"}",o):"function"==typeof t.addRule&&t.addRule(e,i,o)},toBool:function(t){return"boolean"==typeof t?t:"string"==typeof t?!(""===(t=t.toLowerCase())||"no"===t||"false"===t||"0"===t):Boolean(t)},_collisionNodeCheck:function(t){return t!==this.node&&f.isIntercepted(t,this.nn)},_didCollide:function(t){return f.isIntercepted({x:this.n.x,y:this.newY,width:this.n.width,height:this.n.height},t)},_isAddNodeIntercepted:function(t){return f.isIntercepted({x:this.x,y:this.y,width:this.node.width,height:this.node.height},t)},parseHeight:function(t){var e=t,i="px";if(e&&"string"==typeof e){var o=e.match(/^(-[0-9]+\.[0-9]+|[0-9]*\.[0-9]+|-[0-9]+|[0-9]+)(px|em|rem|vh|vw|%)?$/);if(!o)throw new Error("Invalid height");i=o[2]||"px",e=parseFloat(o[1])}return{height:e,unit:i}},without:function(t,e){var i=t.indexOf(e);return-1!==i&&(t=t.slice(0)).splice(i,1),t},sortBy:function(t,a){return t.slice(0).sort(function(t,e){var i=a(t),o=a(e);return o===i?0:ot.clientHeight?t:f.getScrollParent(t.parentNode)},updateScrollPosition:function(t,e,i){var o=t.getBoundingClientRect(),a=window.innerHeight||document.documentElement.clientHeight;if(o.top<0||o.bottom>a){var s=o.bottom-a,r=o.top,n=f.getScrollParent(t);if(null!==n){var d=n.scrollTop;o.top<0&&i<0?t.offsetHeight>a?n.scrollTop+=i:n.scrollTop+=Math.abs(r)>Math.abs(i)?i:r:0a?n.scrollTop+=i:n.scrollTop+=i=t._packY;){this.nodes.slice(0,e).find(f._didCollide,{n:t,newY:i})||(t._dirty=!0,t.y=i),--i}},this):this.nodes.forEach(function(t,e){if(!t.locked)for(;0this.column?t.width=this.column:t.width<1&&(t.width=1),t.height<1&&(t.height=1),t.x<0&&(t.x=0),t.x+t.width>this.column&&(e?t.width=this.column-t.x:t.x=this.column-t.width),t.y<0&&(t.y=0),t},l.prototype._notify=function(){if(!this._batchMode){var t=Array.prototype.slice.call(arguments,0);t[0]=void 0===t[0]?[]:Array.isArray(t[0])?t[0]:[t[0]],t[1]=void 0===t[1]||t[1];var e=t[0].concat(this.getDirtyNodes());this.onchange(e,t[1])}},l.prototype.cleanNodes=function(){this._batchMode||this.nodes.forEach(function(t){delete t._dirty})},l.prototype.getDirtyNodes=function(t){if(t){var e=[];return this.nodes.forEach(function(t){t._dirty&&(t.y===t._origY&&t.x===t._origX&&t.width===t._origW&&t.height===t._origH?delete t._dirty:e.push(t))}),e}return this.nodes.filter(function(t){return t._dirty})},l.prototype.addNode=function(t,e){if(void 0!==(t=this._prepareNode(t)).maxWidth&&(t.width=Math.min(t.width,t.maxWidth)),void 0!==t.maxHeight&&(t.height=Math.min(t.height,t.maxHeight)),void 0!==t.minWidth&&(t.width=Math.max(t.width,t.minWidth)),void 0!==t.minHeight&&(t.height=Math.max(t.height,t.minHeight)),t._id=t._id||++s,t.autoPosition){this._sortNodes();for(var i=0;;++i){var o=i%this.column,a=Math.floor(i/this.column);if(!(o+t.width>this.column)&&!this.nodes.find(f._isAddNodeIntercepted,{x:o,y:a,node:t})){t.x=o,t.y=a,delete t.autoPosition;break}}}return this.nodes.push(t),e&&this._addedNodes.push(t),this._fixCollisions(t),this._packNodes(),this._notify(),t},l.prototype.removeNode=function(t,e){e=void 0===e||e,this._removedNodes.push(t),t._id=null,this.nodes=f.without(this.nodes,t),this._packNodes(),this._notify(t,e)},l.prototype.removeAll=function(t){delete this._layouts,0!==this.nodes.length&&(t=void 0===t||t,this.nodes.forEach(function(t){t._id=null}),this._removedNodes=this.nodes,this.nodes=[],this._notify(this._removedNodes,t))},l.prototype.canMoveNode=function(e,t,i,o,a){if(!this.isNodeChangedPosition(e,t,i,o,a))return!1;var s,r=Boolean(this.nodes.find(function(t){return t.locked}));if(!this.maxRow&&!r)return!0;var n=new l(this.column,null,this.float,0,this.nodes.map(function(t){return t===e?s=m.extend({},t):m.extend({},t)}));if(!s)return!0;n.moveNode(s,t,i,o,a);var d=!0;return r&&(d&=!Boolean(n.nodes.find(function(t){return t!==s&&Boolean(t.locked)&&Boolean(t._dirty)}))),this.maxRow&&(d&=n.getGridHeight()<=this.maxRow),d},l.prototype.canBePlacedWithRespectToHeight=function(t){if(!this.maxRow)return!0;var e=new l(this.column,null,this.float,0,this.nodes.map(function(t){return m.extend({},t)}));return e.addNode(t),e.getGridHeight()<=this.maxRow},l.prototype.isNodeChangedPosition=function(t,e,i,o,a){return"number"!=typeof e&&(e=t.x),"number"!=typeof i&&(i=t.y),"number"!=typeof o&&(o=t.width),"number"!=typeof a&&(a=t.height),void 0!==t.maxWidth&&(o=Math.min(o,t.maxWidth)),void 0!==t.maxHeight&&(a=Math.min(a,t.maxHeight)),void 0!==t.minWidth&&(o=Math.max(o,t.minWidth)),void 0!==t.minHeight&&(a=Math.max(a,t.minHeight)),t.x!==e||t.y!==i||t.width!==o||t.height!==a},l.prototype.moveNode=function(t,e,i,o,a,s){if("number"!=typeof e&&(e=t.x),"number"!=typeof i&&(i=t.y),"number"!=typeof o&&(o=t.width),"number"!=typeof a&&(a=t.height),void 0!==t.maxWidth&&(o=Math.min(o,t.maxWidth)),void 0!==t.maxHeight&&(a=Math.min(a,t.maxHeight)),void 0!==t.minWidth&&(o=Math.max(o,t.minWidth)),void 0!==t.minHeight&&(a=Math.max(a,t.minHeight)),t.x===e&&t.y===i&&t.width===o&&t.height===a)return t;var r=t.width!==o;return t._dirty=!0,t.x=e,t.y=i,t.width=o,t.height=a,t.lastTriedX=e,t.lastTriedY=i,t.lastTriedWidth=o,t.lastTriedHeight=a,t=this._prepareNode(t,r),this._fixCollisions(t),s||(this._packNodes(),this._notify()),t},l.prototype.getGridHeight=function(){return this.nodes.reduce(function(t,e){return Math.max(t,e.y+e.height)},0)},l.prototype.beginUpdate=function(t){t._updating||(t._updating=!0,this.nodes.forEach(function(t){t._packY=t.y}))},l.prototype.endUpdate=function(){var t=this.nodes.find(function(t){return t._updating});t&&(t._updating=!1,this.nodes.forEach(function(t){delete t._packY}))};function i(t,e){var i,c=this;e=e||{},this.container=m(t),n(e,"width","column","v0.5.3"),n(e,"height","maxRow","v0.5.3"),function(t,e,i,o){void 0!==t[e]&&console.warn("gridstack.js: Option `"+e+"` is deprecated in "+i+o)}(e,"oneColumnModeClass","v0.6.3",". Use class `.grid-stack-1` instead"),d(this.container,"data-gs-width","data-gs-column","v0.5.3"),d(this.container,"data-gs-height","data-gs-max-row","v0.5.3"),e.itemClass=e.itemClass||"grid-stack-item";var o=0
          '+this.opts.placeholderText+"
          ").hide(),this._updateContainerHeight(),this._updateHeightsOnResize=f.throttle(function(){c.cellHeight(c.cellWidth(),!1)},100),this.onResizeHandler=function(){if(i&&c._updateHeightsOnResize(),!c.opts.staticGrid)if(!c.opts.disableOneColumnMode&&(window.innerWidth||document.documentElement.clientWidth||document.body.clientWidth)<=c.opts.minWidth){if(c.oneColumnMode)return;c.oneColumnMode=!0,c.setColumn(1)}else{if(!c.oneColumnMode)return;c.oneColumnMode=!1,c.setColumn(c._prevColumn)}},m(window).resize(this.onResizeHandler),this.onResizeHandler(),!c.opts.staticGrid&&"string"==typeof c.opts.removable){var r=m(c.opts.removable);this.dd.isDroppable(r)||this.dd.droppable(r,c.opts.removableOptions),this.dd.on(r,"dropover",function(t,e){var i=m(e.draggable),o=i.data("_gridstack_node");o&&o._grid===c&&(i.data("inTrashZone",!0),c._setupRemovingTimeout(i))}).on(r,"dropout",function(t,e){var i=m(e.draggable),o=i.data("_gridstack_node");o&&o._grid===c&&(i.data("inTrashZone",!1),c._clearRemovingTimeout(i))})}if(!c.opts.staticGrid&&c.opts.acceptWidgets){function p(t,e){var i=u,o=i.data("_gridstack_node"),a=c.getCellFromPixel({left:t.pageX,top:t.pageY},!0),s=Math.max(0,a.x),r=Math.max(0,a.y);o._added||(o._added=!0,o.el=i,o.autoPosition=!0,o.x=s,o.y=r,c.grid.cleanNodes(),c.grid.beginUpdate(o),c.grid.addNode(o),c.container.append(c.placeholder),c.placeholder.attr("data-gs-x",o.x).attr("data-gs-y",o.y).attr("data-gs-width",o.width).attr("data-gs-height",o.height).show(),o.el=c.placeholder,o._beforeDragX=o.x,o._beforeDragY=o.y,c._updateContainerHeight()),c.grid.canMoveNode(o,s,r)&&(c.grid.moveNode(o,s,r),c._updateContainerHeight())}var u=null;this.dd.droppable(c.container,{accept:function(t){var e=(t=m(t)).data("_gridstack_node");return(!e||e._grid!==c)&&t.is(!0===c.opts.acceptWidgets?".grid-stack-item":c.opts.acceptWidgets)}}).on(c.container,"dropover",function(t,e){var i,o,a=m(e.draggable),s=a.data("_gridstack_node");if(!s||!s.width||!s.height){var r=parseInt(a.attr("data-gs-width"));0this._styles._max)){for(var a=this._styles._max;a=p.grid.column||s<0||!p.grid.float&&s>p.grid.getGridHeight()){if(l._temporaryRemoved)return;!0===p.opts.removable&&p._setupRemovingTimeout(h),a=l._beforeDragX,s=l._beforeDragY,p.placeholder.detach(),p.placeholder.hide(),p.grid.removeNode(l),p._updateContainerHeight(),l._temporaryRemoved=!0}else p._clearRemovingTimeout(h),l._temporaryRemoved&&(p.grid.addNode(l),p.placeholder.attr("data-gs-x",a).attr("data-gs-y",s).attr("data-gs-width",i).attr("data-gs-height",o).show(),p.container.append(p.placeholder),l.el=p.placeholder,l._temporaryRemoved=!1)}else if("resize"===t.type&&a<0)return;var n=void 0!==i?i:l.lastTriedWidth,d=void 0!==o?o:l.lastTriedHeight;!p.grid.canMoveNode(l,a,s,i,o)||l.lastTriedX===a&&l.lastTriedY===s&&l.lastTriedWidth===n&&l.lastTriedHeight===d||(l.lastTriedX=a,l.lastTriedY=s,l.lastTriedWidth=i,l.lastTriedHeight=o,p.grid.moveNode(l,a,s,i,o),p._updateContainerHeight(),"resize"===t.type&&m(t.target).trigger("gsresize",l))}function e(t,e){p.container.append(p.placeholder);var i=m(this);p.grid.cleanNodes(),p.grid.beginUpdate(l),g=p.cellWidth();var o=p.cellHeight();c=p.container.height()/parseInt(p.container.attr("data-gs-current-height")),p.placeholder.attr("data-gs-x",i.attr("data-gs-x")).attr("data-gs-y",i.attr("data-gs-y")).attr("data-gs-width",i.attr("data-gs-width")).attr("data-gs-height",i.attr("data-gs-height")).show(),l.el=p.placeholder,l._beforeDragX=l.x,l._beforeDragY=l.y,l._prevYPix=e.position.top;var a=l.minHeight||1,s=p.opts.verticalMargin;p.dd.resizable(h,"option","minWidth",g*(l.minWidth||1)),p.dd.resizable(h,"option","minHeight",o*a+(a-1)*s),"resizestart"===t.type&&i.find(".grid-stack-item").trigger("resizestart")}function i(t,e){var i=m(this);if(i.data("_gridstack_node")){if(p.placeholder.detach(),l.el=i,p.placeholder.hide(),l._isAboutToRemove)h.data("_gridstack_node")._grid._triggerRemoveEvent(),h.removeData("_gridstack_node"),h.remove();else p._clearRemovingTimeout(h),l._temporaryRemoved?(f.removePositioningStyles(i),i.attr("data-gs-x",l._beforeDragX).attr("data-gs-y",l._beforeDragY).attr("data-gs-width",l.width).attr("data-gs-height",l.height),l.x=l._beforeDragX,l.y=l._beforeDragY,l._temporaryRemoved=!1,p.grid.addNode(l)):(f.removePositioningStyles(i),i.attr("data-gs-x",l.x).attr("data-gs-y",l.y).attr("data-gs-width",l.width).attr("data-gs-height",l.height));p._updateContainerHeight(),p._triggerChangeEvent(),p.grid.endUpdate();var o=i.find(".grid-stack");o.length&&"resizestop"===t.type&&(o.each(function(t,e){m(e).data("gridstack").onResizeHandler()}),i.find(".grid-stack-item").trigger("resizestop"),i.find(".grid-stack-item").trigger("gsresizestop")),"resizestop"===t.type&&p.container.trigger("gsresizestop",i)}}var g,c,p=this;this.dd.draggable(h,{start:e,stop:i,drag:t}).resizable(h,{start:e,stop:i,resize:t}),(l.noMove||this.opts.disableDrag||this.opts.staticGrid)&&this.dd.draggable(h,"disable"),(l.noResize||this.opts.disableResize||this.opts.staticGrid)&&this.dd.resizable(h,"disable"),this._writeAttr(h,l)},i.prototype._prepareElement=function(t,e){e=void 0!==e&&e;(t=m(t)).addClass(this.opts.itemClass);var i=this._readAttr(t,{el:t,_grid:this});i=this.grid.addNode(i,e),t.data("_gridstack_node",i),this._prepareElementsByNode(t,i)},i.prototype._writeAttr=function(t,e){t=m(t),void 0!==(e=e||{}).x&&t.attr("data-gs-x",e.x),void 0!==e.y&&t.attr("data-gs-y",e.y),void 0!==e.width&&t.attr("data-gs-width",e.width),void 0!==e.height&&t.attr("data-gs-height",e.height),void 0!==e.autoPosition&&t.attr("data-gs-auto-position",!!e.autoPosition||null),void 0!==e.minWidth&&t.attr("data-gs-min-width",e.minWidth),void 0!==e.maxWidth&&t.attr("data-gs-max-width",e.maxWidth),void 0!==e.minHeight&&t.attr("data-gs-min-height",e.minHeight),void 0!==e.maxHeight&&t.attr("data-gs-max-height",e.maxHeight),void 0!==e.noResize&&t.attr("data-gs-no-resize",!!e.noResize||null),void 0!==e.noMove&&t.attr("data-gs-no-move",!!e.noMove||null),void 0!==e.locked&&t.attr("data-gs-locked",!!e.locked||null),void 0!==e.resizeHandles&&t.attr("data-gs-resize-handles",e.resizeHandles),void 0!==e.id&&t.attr("data-gs-id",e.id)},i.prototype._readAttr=function(t,e){return t=m(t),(e=e||{}).x=t.attr("data-gs-x"),e.y=t.attr("data-gs-y"),e.width=t.attr("data-gs-width"),e.height=t.attr("data-gs-height"),e.autoPosition=f.toBool(t.attr("data-gs-auto-position")),e.maxWidth=t.attr("data-gs-max-width"),e.minWidth=t.attr("data-gs-min-width"),e.maxHeight=t.attr("data-gs-max-height"),e.minHeight=t.attr("data-gs-min-height"),e.noResize=f.toBool(t.attr("data-gs-no-resize")),e.noMove=f.toBool(t.attr("data-gs-no-move")),e.locked=f.toBool(t.attr("data-gs-locked")),e.resizeHandles=t.attr("data-gs-resize-handles"),e.id=t.attr("data-gs-id"),e},i.prototype.setAnimation=function(t){t?this.container.addClass("grid-stack-animate"):this.container.removeClass("grid-stack-animate")},i.prototype.addWidget=function(t,e,i,o,a,s,r,n,d,h,l){return void 0!==e&&"object"!=typeof e?this.addWidget(t,{x:e,y:i,width:o,height:a,autoPosition:s,minWidth:r,maxWidth:n,minHeight:d,maxHeight:h,id:l}):(e=e||{},t=m(t),this._writeAttr(t,e),this.container.append(t),this.makeWidget(t))},i.prototype.makeWidget=function(t){return t=m(t),this._prepareElement(t,!0),this._updateContainerHeight(),this._triggerAddEvent(),this._triggerChangeEvent(!0),t},i.prototype.willItFit=function(t,e,i,o,a){var s={x:t,y:e,width:i,height:o,autoPosition:a};return this.grid.canBePlacedWithRespectToHeight(s)},i.prototype.removeWidget=function(t,e){e=void 0===e||e;var i=(t=m(t)).data("_gridstack_node");i=i||this.grid.getNodeDataByDOMEl(t),t.removeData("_gridstack_node"),this.grid.removeNode(i,e),this._triggerRemoveEvent(),this._triggerChangeEvent(!0)},i.prototype.removeAll=function(t){!1!==t&&this.grid.nodes.forEach(function(t){t.el.removeData("_gridstack_node")}),this.grid.removeAll(t),this._triggerRemoveEvent()},i.prototype.destroy=function(t){m(window).off("resize",this.onResizeHandler),this.disable(),void 0===t||t?this.container.remove():(this.removeAll(!1),this.container.removeData("gridstack")),f.removeStylesheet(this._stylesId),this.grid&&(this.grid=null)},i.prototype.resizable=function(t,o){var a=this;return(t=m(t)).each(function(t,e){var i=(e=m(e)).data("_gridstack_node");i&&(i.noResize=!o,i.noResize?a.dd.resizable(e,"disable"):a.dd.resizable(e,"enable"))}),this},i.prototype.movable=function(t,o){var a=this;return(t=m(t)).each(function(t,e){var i=(e=m(e)).data("_gridstack_node");i&&(i.noMove=!o,i.noMove?(a.dd.draggable(e,"disable"),e.removeClass("ui-draggable-handle")):(a.dd.draggable(e,"enable"),e.addClass("ui-draggable-handle")))}),this},i.prototype.enableMove=function(t,e){this.movable(this.container.children("."+this.opts.itemClass),t),e&&(this.opts.disableDrag=!t)},i.prototype.enableResize=function(t,e){this.resizable(this.container.children("."+this.opts.itemClass),t),e&&(this.opts.disableResize=!t)},i.prototype.disable=function(){this.movable(this.container.children("."+this.opts.itemClass),!1),this.resizable(this.container.children("."+this.opts.itemClass),!1),this.container.trigger("disable")},i.prototype.enable=function(){this.movable(this.container.children("."+this.opts.itemClass),!0),this.resizable(this.container.children("."+this.opts.itemClass),!0),this.container.trigger("enable")},i.prototype.locked=function(t,o){return(t=m(t)).each(function(t,e){var i=(e=m(e)).data("_gridstack_node");i&&(i.locked=o||!1,e.attr("data-gs-locked",i.locked?"yes":null))}),this},i.prototype.maxHeight=function(t,o){return(t=m(t)).each(function(t,e){var i=(e=m(e)).data("_gridstack_node");i&&(isNaN(o)||(i.maxHeight=o||!1,e.attr("data-gs-max-height",o)))}),this},i.prototype.minHeight=function(t,o){return(t=m(t)).each(function(t,e){var i=(e=m(e)).data("_gridstack_node");i&&(isNaN(o)||(i.minHeight=o||!1,e.attr("data-gs-min-height",o)))}),this},i.prototype.maxWidth=function(t,o){return(t=m(t)).each(function(t,e){var i=(e=m(e)).data("_gridstack_node");i&&(isNaN(o)||(i.maxWidth=o||!1,e.attr("data-gs-max-width",o)))}),this},i.prototype.minWidth=function(t,o){return(t=m(t)).each(function(t,e){var i=(e=m(e)).data("_gridstack_node");i&&(isNaN(o)||(i.minWidth=o||!1,e.attr("data-gs-min-width",o)))}),this},i.prototype._updateElement=function(t,e){var i=(t=m(t).first()).data("_gridstack_node");if(i){var o=this;o.grid.cleanNodes(),o.grid.beginUpdate(i),e.call(this,t,i),o._updateContainerHeight(),o._triggerChangeEvent(),o.grid.endUpdate()}},i.prototype.resize=function(t,i,o){this._updateElement(t,function(t,e){i=null!=i?i:e.width,o=null!=o?o:e.height,this.grid.moveNode(e,e.x,e.y,i,o)})},i.prototype.move=function(t,i,o){this._updateElement(t,function(t,e){i=null!=i?i:e.x,o=null!=o?o:e.y,this.grid.moveNode(e,i,o,e.width,e.height)})},i.prototype.update=function(t,i,o,a,s){this._updateElement(t,function(t,e){i=null!=i?i:e.x,o=null!=o?o:e.y,a=null!=a?a:e.width,s=null!=s?s:e.height,this.grid.moveNode(e,i,o,a,s)})},i.prototype.compact=function(){if(0!==this.grid.nodes.length){this.batchUpdate(),this.grid._sortNodes();var t=this.grid.nodes;this.grid.nodes=[],t.forEach(function(t){t.noMove||t.locked||(t.autoPosition=!0),this.grid.addNode(t,!1),t._dirty=!0},this),this.commit()}},i.prototype.verticalMargin=function(t,e){if(void 0===t)return this.opts.verticalMargin;var i=f.parseHeight(t);this.opts.verticalMarginUnit===i.unit&&this.opts.maxRow===i.height||(this.opts.verticalMarginUnit=i.unit,this.opts.verticalMargin=i.height,e||this._updateStyles())},i.prototype.cellHeight=function(t,e){if(void 0===t){if(this.opts.cellHeight&&"auto"!==this.opts.cellHeight)return this.opts.cellHeight;var i=this.container.children("."+this.opts.itemClass).first(),o=i.attr("data-gs-height"),a=this.opts.verticalMargin;return Math.round((i.outerHeight()-(o-1)*a)/o)}var s=f.parseHeight(t);this.opts.cellHeightUnit===s.unit&&this.opts.cellHeight===s.height||(this.opts.cellHeightUnit=s.unit,this.opts.cellHeight=s.height,e||this._updateStyles())},i.prototype.cellWidth=function(){return Math.round(this.container.outerWidth()/this.opts.column)},i.prototype.getCellFromPixel=function(t,e){var i=void 0!==e&&e?this.container.offset():this.container.position(),o=t.left-i.left,a=t.top-i.top,s=Math.floor(this.container.width()/this.opts.column),r=Math.floor(this.container.height()/parseInt(this.container.attr("data-gs-current-height")));return{x:Math.floor(o/s),y:Math.floor(a/r)}},i.prototype.batchUpdate=function(){this.grid.batchUpdate()},i.prototype.commit=function(){this.grid.commit(),this._triggerRemoveEvent(),this._triggerAddEvent(),this._triggerChangeEvent()},i.prototype.isAreaEmpty=function(t,e,i,o){return this.grid.isAreaEmpty(t,e,i,o)},i.prototype.setStatic=function(t){this.opts.staticGrid=!0===t,this.enableMove(!t),this.enableResize(!t),this._setStaticClass()},i.prototype._setStaticClass=function(){var t="grid-stack-static";!0===this.opts.staticGrid?this.container.addClass(t):this.container.removeClass(t)},l.prototype._layoutsNodesChange=function(t){this._layouts&&!this._ignoreLayoutsNodeChange&&this._layouts.forEach(function(o,a){o&&a!==this.column&&(a + +
          \ No newline at end of file diff --git a/software/dashboard/grafana/csv/Node-RED_files/jquery-ui.min.css b/software/dashboard/grafana/csv/Node-RED_files/jquery-ui.min.css new file mode 100644 index 0000000..776e259 --- /dev/null +++ b/software/dashboard/grafana/csv/Node-RED_files/jquery-ui.min.css @@ -0,0 +1,7 @@ +/*! jQuery UI - v1.12.1 - 2016-09-14 +* http://jqueryui.com +* Includes: core.css, accordion.css, autocomplete.css, menu.css, button.css, controlgroup.css, checkboxradio.css, datepicker.css, dialog.css, draggable.css, resizable.css, progressbar.css, selectable.css, selectmenu.css, slider.css, sortable.css, spinner.css, tabs.css, tooltip.css, theme.css +* To view and modify this theme, visit http://jqueryui.com/themeroller/?bgShadowXPos=&bgOverlayXPos=&bgErrorXPos=&bgHighlightXPos=&bgContentXPos=&bgHeaderXPos=&bgActiveXPos=&bgHoverXPos=&bgDefaultXPos=&bgShadowYPos=&bgOverlayYPos=&bgErrorYPos=&bgHighlightYPos=&bgContentYPos=&bgHeaderYPos=&bgActiveYPos=&bgHoverYPos=&bgDefaultYPos=&bgShadowRepeat=&bgOverlayRepeat=&bgErrorRepeat=&bgHighlightRepeat=&bgContentRepeat=&bgHeaderRepeat=&bgActiveRepeat=&bgHoverRepeat=&bgDefaultRepeat=&iconsHover=url(%22images%2Fui-icons_555555_256x240.png%22)&iconsHighlight=url(%22images%2Fui-icons_777620_256x240.png%22)&iconsHeader=url(%22images%2Fui-icons_444444_256x240.png%22)&iconsError=url(%22images%2Fui-icons_cc0000_256x240.png%22)&iconsDefault=url(%22images%2Fui-icons_777777_256x240.png%22)&iconsContent=url(%22images%2Fui-icons_444444_256x240.png%22)&iconsActive=url(%22images%2Fui-icons_ffffff_256x240.png%22)&bgImgUrlShadow=&bgImgUrlOverlay=&bgImgUrlHover=&bgImgUrlHighlight=&bgImgUrlHeader=&bgImgUrlError=&bgImgUrlDefault=&bgImgUrlContent=&bgImgUrlActive=&opacityFilterShadow=Alpha(Opacity%3D30)&opacityFilterOverlay=Alpha(Opacity%3D30)&opacityShadowPerc=30&opacityOverlayPerc=30&iconColorHover=%23555555&iconColorHighlight=%23777620&iconColorHeader=%23444444&iconColorError=%23cc0000&iconColorDefault=%23777777&iconColorContent=%23444444&iconColorActive=%23ffffff&bgImgOpacityShadow=0&bgImgOpacityOverlay=0&bgImgOpacityError=95&bgImgOpacityHighlight=55&bgImgOpacityContent=75&bgImgOpacityHeader=75&bgImgOpacityActive=65&bgImgOpacityHover=75&bgImgOpacityDefault=75&bgTextureShadow=flat&bgTextureOverlay=flat&bgTextureError=flat&bgTextureHighlight=flat&bgTextureContent=flat&bgTextureHeader=flat&bgTextureActive=flat&bgTextureHover=flat&bgTextureDefault=flat&cornerRadius=3px&fwDefault=normal&ffDefault=Arial%2CHelvetica%2Csans-serif&fsDefault=1em&cornerRadiusShadow=8px&thicknessShadow=5px&offsetLeftShadow=0px&offsetTopShadow=0px&opacityShadow=.3&bgColorShadow=%23666666&opacityOverlay=.3&bgColorOverlay=%23aaaaaa&fcError=%235f3f3f&borderColorError=%23f1a899&bgColorError=%23fddfdf&fcHighlight=%23777620&borderColorHighlight=%23dad55e&bgColorHighlight=%23fffa90&fcContent=%23333333&borderColorContent=%23dddddd&bgColorContent=%23ffffff&fcHeader=%23333333&borderColorHeader=%23dddddd&bgColorHeader=%23e9e9e9&fcActive=%23ffffff&borderColorActive=%23003eff&bgColorActive=%23007fff&fcHover=%232b2b2b&borderColorHover=%23cccccc&bgColorHover=%23ededed&fcDefault=%23454545&borderColorDefault=%23c5c5c5&bgColorDefault=%23f6f6f6 +* Copyright jQuery Foundation and other contributors; Licensed MIT */ + +.ui-helper-hidden{display:none}.ui-helper-hidden-accessible{border:0;clip:rect(0 0 0 0);height:1px;margin:-1px;overflow:hidden;padding:0;position:absolute;width:1px}.ui-helper-reset{margin:0;padding:0;border:0;outline:0;line-height:1.3;text-decoration:none;font-size:100%;list-style:none}.ui-helper-clearfix:before,.ui-helper-clearfix:after{content:"";display:table;border-collapse:collapse}.ui-helper-clearfix:after{clear:both}.ui-helper-zfix{width:100%;height:100%;top:0;left:0;position:absolute;opacity:0;filter:Alpha(Opacity=0)}.ui-front{z-index:100}.ui-state-disabled{cursor:default!important;pointer-events:none}.ui-icon{display:inline-block;vertical-align:middle;margin-top:-.25em;position:relative;text-indent:-99999px;overflow:hidden;background-repeat:no-repeat}.ui-widget-icon-block{left:50%;margin-left:-8px;display:block}.ui-widget-overlay{position:fixed;top:0;left:0;width:100%;height:100%}.ui-accordion .ui-accordion-header{display:block;cursor:pointer;position:relative;margin:2px 0 0 0;padding:.5em .5em .5em .7em;font-size:100%}.ui-accordion .ui-accordion-content{padding:1em 2.2em;border-top:0;overflow:auto}.ui-autocomplete{position:absolute;top:0;left:0;cursor:default}.ui-menu{list-style:none;padding:0;margin:0;display:block;outline:0}.ui-menu .ui-menu{position:absolute}.ui-menu .ui-menu-item{margin:0;cursor:pointer;list-style-image:url("data:image/gif;base64,R0lGODlhAQABAIAAAAAAAP///yH5BAEAAAAALAAAAAABAAEAAAIBRAA7")}.ui-menu .ui-menu-item-wrapper{position:relative;padding:3px 1em 3px .4em}.ui-menu .ui-menu-divider{margin:5px 0;height:0;font-size:0;line-height:0;border-width:1px 0 0 0}.ui-menu .ui-state-focus,.ui-menu .ui-state-active{margin:-1px}.ui-menu-icons{position:relative}.ui-menu-icons .ui-menu-item-wrapper{padding-left:2em}.ui-menu .ui-icon{position:absolute;top:0;bottom:0;left:.2em;margin:auto 0}.ui-menu .ui-menu-icon{left:auto;right:0}.ui-button{padding:.4em 1em;display:inline-block;position:relative;line-height:normal;margin-right:.1em;cursor:pointer;vertical-align:middle;text-align:center;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;overflow:visible}.ui-button,.ui-button:link,.ui-button:visited,.ui-button:hover,.ui-button:active{text-decoration:none}.ui-button-icon-only{width:2em;box-sizing:border-box;text-indent:-9999px;white-space:nowrap}input.ui-button.ui-button-icon-only{text-indent:0}.ui-button-icon-only .ui-icon{position:absolute;top:50%;left:50%;margin-top:-8px;margin-left:-8px}.ui-button.ui-icon-notext .ui-icon{padding:0;width:2.1em;height:2.1em;text-indent:-9999px;white-space:nowrap}input.ui-button.ui-icon-notext .ui-icon{width:auto;height:auto;text-indent:0;white-space:normal;padding:.4em 1em}input.ui-button::-moz-focus-inner,button.ui-button::-moz-focus-inner{border:0;padding:0}.ui-controlgroup{vertical-align:middle;display:inline-block}.ui-controlgroup > .ui-controlgroup-item{float:left;margin-left:0;margin-right:0}.ui-controlgroup > .ui-controlgroup-item:focus,.ui-controlgroup > .ui-controlgroup-item.ui-visual-focus{z-index:9999}.ui-controlgroup-vertical > .ui-controlgroup-item{display:block;float:none;width:100%;margin-top:0;margin-bottom:0;text-align:left}.ui-controlgroup-vertical .ui-controlgroup-item{box-sizing:border-box}.ui-controlgroup .ui-controlgroup-label{padding:.4em 1em}.ui-controlgroup .ui-controlgroup-label span{font-size:80%}.ui-controlgroup-horizontal .ui-controlgroup-label + .ui-controlgroup-item{border-left:none}.ui-controlgroup-vertical .ui-controlgroup-label + .ui-controlgroup-item{border-top:none}.ui-controlgroup-horizontal .ui-controlgroup-label.ui-widget-content{border-right:none}.ui-controlgroup-vertical .ui-controlgroup-label.ui-widget-content{border-bottom:none}.ui-controlgroup-vertical .ui-spinner-input{width:75%;width:calc( 100% - 2.4em )}.ui-controlgroup-vertical .ui-spinner .ui-spinner-up{border-top-style:solid}.ui-checkboxradio-label .ui-icon-background{box-shadow:inset 1px 1px 1px #ccc;border-radius:.12em;border:none}.ui-checkboxradio-radio-label .ui-icon-background{width:16px;height:16px;border-radius:1em;overflow:visible;border:none}.ui-checkboxradio-radio-label.ui-checkboxradio-checked .ui-icon,.ui-checkboxradio-radio-label.ui-checkboxradio-checked:hover .ui-icon{background-image:none;width:8px;height:8px;border-width:4px;border-style:solid}.ui-checkboxradio-disabled{pointer-events:none}.ui-datepicker{width:17em;padding:.2em .2em 0;display:none}.ui-datepicker .ui-datepicker-header{position:relative;padding:.2em 0}.ui-datepicker .ui-datepicker-prev,.ui-datepicker .ui-datepicker-next{position:absolute;top:2px;width:1.8em;height:1.8em}.ui-datepicker .ui-datepicker-prev-hover,.ui-datepicker .ui-datepicker-next-hover{top:1px}.ui-datepicker .ui-datepicker-prev{left:2px}.ui-datepicker .ui-datepicker-next{right:2px}.ui-datepicker .ui-datepicker-prev-hover{left:1px}.ui-datepicker .ui-datepicker-next-hover{right:1px}.ui-datepicker .ui-datepicker-prev span,.ui-datepicker .ui-datepicker-next span{display:block;position:absolute;left:50%;margin-left:-8px;top:50%;margin-top:-8px}.ui-datepicker .ui-datepicker-title{margin:0 2.3em;line-height:1.8em;text-align:center}.ui-datepicker .ui-datepicker-title select{font-size:1em;margin:1px 0}.ui-datepicker select.ui-datepicker-month,.ui-datepicker select.ui-datepicker-year{width:45%}.ui-datepicker table{width:100%;font-size:.9em;border-collapse:collapse;margin:0 0 .4em}.ui-datepicker th{padding:.7em .3em;text-align:center;font-weight:bold;border:0}.ui-datepicker td{border:0;padding:1px}.ui-datepicker td span,.ui-datepicker td a{display:block;padding:.2em;text-align:right;text-decoration:none}.ui-datepicker .ui-datepicker-buttonpane{background-image:none;margin:.7em 0 0 0;padding:0 .2em;border-left:0;border-right:0;border-bottom:0}.ui-datepicker .ui-datepicker-buttonpane button{float:right;margin:.5em .2em .4em;cursor:pointer;padding:.2em .6em .3em .6em;width:auto;overflow:visible}.ui-datepicker .ui-datepicker-buttonpane button.ui-datepicker-current{float:left}.ui-datepicker.ui-datepicker-multi{width:auto}.ui-datepicker-multi .ui-datepicker-group{float:left}.ui-datepicker-multi .ui-datepicker-group table{width:95%;margin:0 auto .4em}.ui-datepicker-multi-2 .ui-datepicker-group{width:50%}.ui-datepicker-multi-3 .ui-datepicker-group{width:33.3%}.ui-datepicker-multi-4 .ui-datepicker-group{width:25%}.ui-datepicker-multi .ui-datepicker-group-last .ui-datepicker-header,.ui-datepicker-multi .ui-datepicker-group-middle .ui-datepicker-header{border-left-width:0}.ui-datepicker-multi .ui-datepicker-buttonpane{clear:left}.ui-datepicker-row-break{clear:both;width:100%;font-size:0}.ui-datepicker-rtl{direction:rtl}.ui-datepicker-rtl .ui-datepicker-prev{right:2px;left:auto}.ui-datepicker-rtl .ui-datepicker-next{left:2px;right:auto}.ui-datepicker-rtl .ui-datepicker-prev:hover{right:1px;left:auto}.ui-datepicker-rtl .ui-datepicker-next:hover{left:1px;right:auto}.ui-datepicker-rtl .ui-datepicker-buttonpane{clear:right}.ui-datepicker-rtl .ui-datepicker-buttonpane button{float:left}.ui-datepicker-rtl .ui-datepicker-buttonpane button.ui-datepicker-current,.ui-datepicker-rtl .ui-datepicker-group{float:right}.ui-datepicker-rtl .ui-datepicker-group-last .ui-datepicker-header,.ui-datepicker-rtl .ui-datepicker-group-middle .ui-datepicker-header{border-right-width:0;border-left-width:1px}.ui-datepicker .ui-icon{display:block;text-indent:-99999px;overflow:hidden;background-repeat:no-repeat;left:.5em;top:.3em}.ui-dialog{position:absolute;top:0;left:0;padding:.2em;outline:0}.ui-dialog .ui-dialog-titlebar{padding:.4em 1em;position:relative}.ui-dialog .ui-dialog-title{float:left;margin:.1em 0;white-space:nowrap;width:90%;overflow:hidden;text-overflow:ellipsis}.ui-dialog .ui-dialog-titlebar-close{position:absolute;right:.3em;top:50%;width:20px;margin:-10px 0 0 0;padding:1px;height:20px}.ui-dialog .ui-dialog-content{position:relative;border:0;padding:.5em 1em;background:none;overflow:auto}.ui-dialog .ui-dialog-buttonpane{text-align:left;border-width:1px 0 0 0;background-image:none;margin-top:.5em;padding:.3em 1em .5em .4em}.ui-dialog .ui-dialog-buttonpane .ui-dialog-buttonset{float:right}.ui-dialog .ui-dialog-buttonpane button{margin:.5em .4em .5em 0;cursor:pointer}.ui-dialog .ui-resizable-n{height:2px;top:0}.ui-dialog .ui-resizable-e{width:2px;right:0}.ui-dialog .ui-resizable-s{height:2px;bottom:0}.ui-dialog .ui-resizable-w{width:2px;left:0}.ui-dialog .ui-resizable-se,.ui-dialog .ui-resizable-sw,.ui-dialog .ui-resizable-ne,.ui-dialog .ui-resizable-nw{width:7px;height:7px}.ui-dialog .ui-resizable-se{right:0;bottom:0}.ui-dialog .ui-resizable-sw{left:0;bottom:0}.ui-dialog .ui-resizable-ne{right:0;top:0}.ui-dialog .ui-resizable-nw{left:0;top:0}.ui-draggable .ui-dialog-titlebar{cursor:move}.ui-draggable-handle{-ms-touch-action:none;touch-action:none}.ui-resizable{position:relative}.ui-resizable-handle{position:absolute;font-size:0.1px;display:block;-ms-touch-action:none;touch-action:none}.ui-resizable-disabled .ui-resizable-handle,.ui-resizable-autohide .ui-resizable-handle{display:none}.ui-resizable-n{cursor:n-resize;height:7px;width:100%;top:-5px;left:0}.ui-resizable-s{cursor:s-resize;height:7px;width:100%;bottom:-5px;left:0}.ui-resizable-e{cursor:e-resize;width:7px;right:-5px;top:0;height:100%}.ui-resizable-w{cursor:w-resize;width:7px;left:-5px;top:0;height:100%}.ui-resizable-se{cursor:se-resize;width:12px;height:12px;right:1px;bottom:1px}.ui-resizable-sw{cursor:sw-resize;width:9px;height:9px;left:-5px;bottom:-5px}.ui-resizable-nw{cursor:nw-resize;width:9px;height:9px;left:-5px;top:-5px}.ui-resizable-ne{cursor:ne-resize;width:9px;height:9px;right:-5px;top:-5px}.ui-progressbar{height:2em;text-align:left;overflow:hidden}.ui-progressbar .ui-progressbar-value{margin:-1px;height:100%}.ui-progressbar .ui-progressbar-overlay{background:url("data:image/gif;base64,R0lGODlhKAAoAIABAAAAAP///yH/C05FVFNDQVBFMi4wAwEAAAAh+QQJAQABACwAAAAAKAAoAAACkYwNqXrdC52DS06a7MFZI+4FHBCKoDeWKXqymPqGqxvJrXZbMx7Ttc+w9XgU2FB3lOyQRWET2IFGiU9m1frDVpxZZc6bfHwv4c1YXP6k1Vdy292Fb6UkuvFtXpvWSzA+HycXJHUXiGYIiMg2R6W459gnWGfHNdjIqDWVqemH2ekpObkpOlppWUqZiqr6edqqWQAAIfkECQEAAQAsAAAAACgAKAAAApSMgZnGfaqcg1E2uuzDmmHUBR8Qil95hiPKqWn3aqtLsS18y7G1SzNeowWBENtQd+T1JktP05nzPTdJZlR6vUxNWWjV+vUWhWNkWFwxl9VpZRedYcflIOLafaa28XdsH/ynlcc1uPVDZxQIR0K25+cICCmoqCe5mGhZOfeYSUh5yJcJyrkZWWpaR8doJ2o4NYq62lAAACH5BAkBAAEALAAAAAAoACgAAAKVDI4Yy22ZnINRNqosw0Bv7i1gyHUkFj7oSaWlu3ovC8GxNso5fluz3qLVhBVeT/Lz7ZTHyxL5dDalQWPVOsQWtRnuwXaFTj9jVVh8pma9JjZ4zYSj5ZOyma7uuolffh+IR5aW97cHuBUXKGKXlKjn+DiHWMcYJah4N0lYCMlJOXipGRr5qdgoSTrqWSq6WFl2ypoaUAAAIfkECQEAAQAsAAAAACgAKAAAApaEb6HLgd/iO7FNWtcFWe+ufODGjRfoiJ2akShbueb0wtI50zm02pbvwfWEMWBQ1zKGlLIhskiEPm9R6vRXxV4ZzWT2yHOGpWMyorblKlNp8HmHEb/lCXjcW7bmtXP8Xt229OVWR1fod2eWqNfHuMjXCPkIGNileOiImVmCOEmoSfn3yXlJWmoHGhqp6ilYuWYpmTqKUgAAIfkECQEAAQAsAAAAACgAKAAAApiEH6kb58biQ3FNWtMFWW3eNVcojuFGfqnZqSebuS06w5V80/X02pKe8zFwP6EFWOT1lDFk8rGERh1TTNOocQ61Hm4Xm2VexUHpzjymViHrFbiELsefVrn6XKfnt2Q9G/+Xdie499XHd2g4h7ioOGhXGJboGAnXSBnoBwKYyfioubZJ2Hn0RuRZaflZOil56Zp6iioKSXpUAAAh+QQJAQABACwAAAAAKAAoAAACkoQRqRvnxuI7kU1a1UU5bd5tnSeOZXhmn5lWK3qNTWvRdQxP8qvaC+/yaYQzXO7BMvaUEmJRd3TsiMAgswmNYrSgZdYrTX6tSHGZO73ezuAw2uxuQ+BbeZfMxsexY35+/Qe4J1inV0g4x3WHuMhIl2jXOKT2Q+VU5fgoSUI52VfZyfkJGkha6jmY+aaYdirq+lQAACH5BAkBAAEALAAAAAAoACgAAAKWBIKpYe0L3YNKToqswUlvznigd4wiR4KhZrKt9Upqip61i9E3vMvxRdHlbEFiEXfk9YARYxOZZD6VQ2pUunBmtRXo1Lf8hMVVcNl8JafV38aM2/Fu5V16Bn63r6xt97j09+MXSFi4BniGFae3hzbH9+hYBzkpuUh5aZmHuanZOZgIuvbGiNeomCnaxxap2upaCZsq+1kAACH5BAkBAAEALAAAAAAoACgAAAKXjI8By5zf4kOxTVrXNVlv1X0d8IGZGKLnNpYtm8Lr9cqVeuOSvfOW79D9aDHizNhDJidFZhNydEahOaDH6nomtJjp1tutKoNWkvA6JqfRVLHU/QUfau9l2x7G54d1fl995xcIGAdXqMfBNadoYrhH+Mg2KBlpVpbluCiXmMnZ2Sh4GBqJ+ckIOqqJ6LmKSllZmsoq6wpQAAAh+QQJAQABACwAAAAAKAAoAAAClYx/oLvoxuJDkU1a1YUZbJ59nSd2ZXhWqbRa2/gF8Gu2DY3iqs7yrq+xBYEkYvFSM8aSSObE+ZgRl1BHFZNr7pRCavZ5BW2142hY3AN/zWtsmf12p9XxxFl2lpLn1rseztfXZjdIWIf2s5dItwjYKBgo9yg5pHgzJXTEeGlZuenpyPmpGQoKOWkYmSpaSnqKileI2FAAACH5BAkBAAEALAAAAAAoACgAAAKVjB+gu+jG4kORTVrVhRlsnn2dJ3ZleFaptFrb+CXmO9OozeL5VfP99HvAWhpiUdcwkpBH3825AwYdU8xTqlLGhtCosArKMpvfa1mMRae9VvWZfeB2XfPkeLmm18lUcBj+p5dnN8jXZ3YIGEhYuOUn45aoCDkp16hl5IjYJvjWKcnoGQpqyPlpOhr3aElaqrq56Bq7VAAAOw==");height:100%;filter:alpha(opacity=25);opacity:0.25}.ui-progressbar-indeterminate .ui-progressbar-value{background-image:none}.ui-selectable{-ms-touch-action:none;touch-action:none}.ui-selectable-helper{position:absolute;z-index:100;border:1px dotted black}.ui-selectmenu-menu{padding:0;margin:0;position:absolute;top:0;left:0;display:none}.ui-selectmenu-menu .ui-menu{overflow:auto;overflow-x:hidden;padding-bottom:1px}.ui-selectmenu-menu .ui-menu .ui-selectmenu-optgroup{font-size:1em;font-weight:bold;line-height:1.5;padding:2px 0.4em;margin:0.5em 0 0 0;height:auto;border:0}.ui-selectmenu-open{display:block}.ui-selectmenu-text{display:block;margin-right:20px;overflow:hidden;text-overflow:ellipsis}.ui-selectmenu-button.ui-button{text-align:left;white-space:nowrap;width:14em}.ui-selectmenu-icon.ui-icon{float:right;margin-top:0}.ui-slider{position:relative;text-align:left}.ui-slider .ui-slider-handle{position:absolute;z-index:2;width:1.2em;height:1.2em;cursor:default;-ms-touch-action:none;touch-action:none}.ui-slider .ui-slider-range{position:absolute;z-index:1;font-size:.7em;display:block;border:0;background-position:0 0}.ui-slider.ui-state-disabled .ui-slider-handle,.ui-slider.ui-state-disabled .ui-slider-range{filter:inherit}.ui-slider-horizontal{height:.8em}.ui-slider-horizontal .ui-slider-handle{top:-.3em;margin-left:-.6em}.ui-slider-horizontal .ui-slider-range{top:0;height:100%}.ui-slider-horizontal .ui-slider-range-min{left:0}.ui-slider-horizontal .ui-slider-range-max{right:0}.ui-slider-vertical{width:.8em;height:100px}.ui-slider-vertical .ui-slider-handle{left:-.3em;margin-left:0;margin-bottom:-.6em}.ui-slider-vertical .ui-slider-range{left:0;width:100%}.ui-slider-vertical .ui-slider-range-min{bottom:0}.ui-slider-vertical .ui-slider-range-max{top:0}.ui-sortable-handle{-ms-touch-action:none;touch-action:none}.ui-spinner{position:relative;display:inline-block;overflow:hidden;padding:0;vertical-align:middle}.ui-spinner-input{border:none;background:none;color:inherit;padding:.222em 0;margin:.2em 0;vertical-align:middle;margin-left:.4em;margin-right:2em}.ui-spinner-button{width:1.6em;height:50%;font-size:.5em;padding:0;margin:0;text-align:center;position:absolute;cursor:default;display:block;overflow:hidden;right:0}.ui-spinner a.ui-spinner-button{border-top-style:none;border-bottom-style:none;border-right-style:none}.ui-spinner-up{top:0}.ui-spinner-down{bottom:0}.ui-tabs{position:relative;padding:.2em}.ui-tabs .ui-tabs-nav{margin:0;padding:.2em .2em 0}.ui-tabs .ui-tabs-nav li{list-style:none;float:left;position:relative;top:0;margin:1px .2em 0 0;border-bottom-width:0;padding:0;white-space:nowrap}.ui-tabs .ui-tabs-nav .ui-tabs-anchor{float:left;padding:.5em 1em;text-decoration:none}.ui-tabs .ui-tabs-nav li.ui-tabs-active{margin-bottom:-1px;padding-bottom:1px}.ui-tabs .ui-tabs-nav li.ui-tabs-active .ui-tabs-anchor,.ui-tabs .ui-tabs-nav li.ui-state-disabled .ui-tabs-anchor,.ui-tabs .ui-tabs-nav li.ui-tabs-loading .ui-tabs-anchor{cursor:text}.ui-tabs-collapsible .ui-tabs-nav li.ui-tabs-active .ui-tabs-anchor{cursor:pointer}.ui-tabs .ui-tabs-panel{display:block;border-width:0;padding:1em 1.4em;background:none}.ui-tooltip{padding:8px;position:absolute;z-index:9999;max-width:300px}body .ui-tooltip{border-width:2px}.ui-widget{font-family:Arial,Helvetica,sans-serif;font-size:1em}.ui-widget .ui-widget{font-size:1em}.ui-widget input,.ui-widget select,.ui-widget textarea,.ui-widget button{font-family:Arial,Helvetica,sans-serif;font-size:1em}.ui-widget.ui-widget-content{border:1px solid #c5c5c5}.ui-widget-content{border:1px solid #ddd;background:#fff;color:#333}.ui-widget-content a{color:#333}.ui-widget-header{border:1px solid #ddd;background:#e9e9e9;color:#333;font-weight:bold}.ui-widget-header a{color:#333}.ui-state-default,.ui-widget-content .ui-state-default,.ui-widget-header .ui-state-default,.ui-button,html .ui-button.ui-state-disabled:hover,html .ui-button.ui-state-disabled:active{border:1px solid #c5c5c5;background:#f6f6f6;font-weight:normal;color:#454545}.ui-state-default a,.ui-state-default a:link,.ui-state-default a:visited,a.ui-button,a:link.ui-button,a:visited.ui-button,.ui-button{color:#454545;text-decoration:none}.ui-state-hover,.ui-widget-content .ui-state-hover,.ui-widget-header .ui-state-hover,.ui-state-focus,.ui-widget-content .ui-state-focus,.ui-widget-header .ui-state-focus,.ui-button:hover,.ui-button:focus{border:1px solid #ccc;background:#ededed;font-weight:normal;color:#2b2b2b}.ui-state-hover a,.ui-state-hover a:hover,.ui-state-hover a:link,.ui-state-hover a:visited,.ui-state-focus a,.ui-state-focus a:hover,.ui-state-focus a:link,.ui-state-focus a:visited,a.ui-button:hover,a.ui-button:focus{color:#2b2b2b;text-decoration:none}.ui-visual-focus{box-shadow:0 0 3px 1px rgb(94,158,214)}.ui-state-active,.ui-widget-content .ui-state-active,.ui-widget-header .ui-state-active,a.ui-button:active,.ui-button:active,.ui-button.ui-state-active:hover{border:1px solid #003eff;background:#007fff;font-weight:normal;color:#fff}.ui-icon-background,.ui-state-active .ui-icon-background{border:#003eff;background-color:#fff}.ui-state-active a,.ui-state-active a:link,.ui-state-active a:visited{color:#fff;text-decoration:none}.ui-state-highlight,.ui-widget-content .ui-state-highlight,.ui-widget-header .ui-state-highlight{border:1px solid #dad55e;background:#fffa90;color:#777620}.ui-state-checked{border:1px solid #dad55e;background:#fffa90}.ui-state-highlight a,.ui-widget-content .ui-state-highlight a,.ui-widget-header .ui-state-highlight a{color:#777620}.ui-state-error,.ui-widget-content .ui-state-error,.ui-widget-header .ui-state-error{border:1px solid #f1a899;background:#fddfdf;color:#5f3f3f}.ui-state-error a,.ui-widget-content .ui-state-error a,.ui-widget-header .ui-state-error a{color:#5f3f3f}.ui-state-error-text,.ui-widget-content .ui-state-error-text,.ui-widget-header .ui-state-error-text{color:#5f3f3f}.ui-priority-primary,.ui-widget-content .ui-priority-primary,.ui-widget-header .ui-priority-primary{font-weight:bold}.ui-priority-secondary,.ui-widget-content .ui-priority-secondary,.ui-widget-header .ui-priority-secondary{opacity:.7;filter:Alpha(Opacity=70);font-weight:normal}.ui-state-disabled,.ui-widget-content .ui-state-disabled,.ui-widget-header .ui-state-disabled{opacity:.35;filter:Alpha(Opacity=35);background-image:none}.ui-state-disabled .ui-icon{filter:Alpha(Opacity=35)}.ui-icon{width:16px;height:16px}.ui-icon,.ui-widget-content .ui-icon{background-image:url("images/ui-icons_444444_256x240.png")}.ui-widget-header .ui-icon{background-image:url("images/ui-icons_444444_256x240.png")}.ui-state-hover .ui-icon,.ui-state-focus .ui-icon,.ui-button:hover .ui-icon,.ui-button:focus .ui-icon{background-image:url("images/ui-icons_555555_256x240.png")}.ui-state-active .ui-icon,.ui-button:active .ui-icon{background-image:url("images/ui-icons_ffffff_256x240.png")}.ui-state-highlight .ui-icon,.ui-button .ui-state-highlight.ui-icon{background-image:url("images/ui-icons_777620_256x240.png")}.ui-state-error .ui-icon,.ui-state-error-text .ui-icon{background-image:url("images/ui-icons_cc0000_256x240.png")}.ui-button .ui-icon{background-image:url("images/ui-icons_777777_256x240.png")}.ui-icon-blank{background-position:16px 16px}.ui-icon-caret-1-n{background-position:0 0}.ui-icon-caret-1-ne{background-position:-16px 0}.ui-icon-caret-1-e{background-position:-32px 0}.ui-icon-caret-1-se{background-position:-48px 0}.ui-icon-caret-1-s{background-position:-65px 0}.ui-icon-caret-1-sw{background-position:-80px 0}.ui-icon-caret-1-w{background-position:-96px 0}.ui-icon-caret-1-nw{background-position:-112px 0}.ui-icon-caret-2-n-s{background-position:-128px 0}.ui-icon-caret-2-e-w{background-position:-144px 0}.ui-icon-triangle-1-n{background-position:0 -16px}.ui-icon-triangle-1-ne{background-position:-16px -16px}.ui-icon-triangle-1-e{background-position:-32px -16px}.ui-icon-triangle-1-se{background-position:-48px -16px}.ui-icon-triangle-1-s{background-position:-65px -16px}.ui-icon-triangle-1-sw{background-position:-80px -16px}.ui-icon-triangle-1-w{background-position:-96px -16px}.ui-icon-triangle-1-nw{background-position:-112px -16px}.ui-icon-triangle-2-n-s{background-position:-128px -16px}.ui-icon-triangle-2-e-w{background-position:-144px -16px}.ui-icon-arrow-1-n{background-position:0 -32px}.ui-icon-arrow-1-ne{background-position:-16px -32px}.ui-icon-arrow-1-e{background-position:-32px -32px}.ui-icon-arrow-1-se{background-position:-48px -32px}.ui-icon-arrow-1-s{background-position:-65px -32px}.ui-icon-arrow-1-sw{background-position:-80px -32px}.ui-icon-arrow-1-w{background-position:-96px -32px}.ui-icon-arrow-1-nw{background-position:-112px -32px}.ui-icon-arrow-2-n-s{background-position:-128px -32px}.ui-icon-arrow-2-ne-sw{background-position:-144px -32px}.ui-icon-arrow-2-e-w{background-position:-160px -32px}.ui-icon-arrow-2-se-nw{background-position:-176px -32px}.ui-icon-arrowstop-1-n{background-position:-192px -32px}.ui-icon-arrowstop-1-e{background-position:-208px -32px}.ui-icon-arrowstop-1-s{background-position:-224px -32px}.ui-icon-arrowstop-1-w{background-position:-240px -32px}.ui-icon-arrowthick-1-n{background-position:1px -48px}.ui-icon-arrowthick-1-ne{background-position:-16px -48px}.ui-icon-arrowthick-1-e{background-position:-32px -48px}.ui-icon-arrowthick-1-se{background-position:-48px -48px}.ui-icon-arrowthick-1-s{background-position:-64px -48px}.ui-icon-arrowthick-1-sw{background-position:-80px -48px}.ui-icon-arrowthick-1-w{background-position:-96px -48px}.ui-icon-arrowthick-1-nw{background-position:-112px -48px}.ui-icon-arrowthick-2-n-s{background-position:-128px -48px}.ui-icon-arrowthick-2-ne-sw{background-position:-144px -48px}.ui-icon-arrowthick-2-e-w{background-position:-160px -48px}.ui-icon-arrowthick-2-se-nw{background-position:-176px -48px}.ui-icon-arrowthickstop-1-n{background-position:-192px -48px}.ui-icon-arrowthickstop-1-e{background-position:-208px -48px}.ui-icon-arrowthickstop-1-s{background-position:-224px -48px}.ui-icon-arrowthickstop-1-w{background-position:-240px -48px}.ui-icon-arrowreturnthick-1-w{background-position:0 -64px}.ui-icon-arrowreturnthick-1-n{background-position:-16px -64px}.ui-icon-arrowreturnthick-1-e{background-position:-32px -64px}.ui-icon-arrowreturnthick-1-s{background-position:-48px -64px}.ui-icon-arrowreturn-1-w{background-position:-64px -64px}.ui-icon-arrowreturn-1-n{background-position:-80px -64px}.ui-icon-arrowreturn-1-e{background-position:-96px -64px}.ui-icon-arrowreturn-1-s{background-position:-112px -64px}.ui-icon-arrowrefresh-1-w{background-position:-128px -64px}.ui-icon-arrowrefresh-1-n{background-position:-144px -64px}.ui-icon-arrowrefresh-1-e{background-position:-160px -64px}.ui-icon-arrowrefresh-1-s{background-position:-176px -64px}.ui-icon-arrow-4{background-position:0 -80px}.ui-icon-arrow-4-diag{background-position:-16px -80px}.ui-icon-extlink{background-position:-32px -80px}.ui-icon-newwin{background-position:-48px -80px}.ui-icon-refresh{background-position:-64px -80px}.ui-icon-shuffle{background-position:-80px -80px}.ui-icon-transfer-e-w{background-position:-96px -80px}.ui-icon-transferthick-e-w{background-position:-112px -80px}.ui-icon-folder-collapsed{background-position:0 -96px}.ui-icon-folder-open{background-position:-16px -96px}.ui-icon-document{background-position:-32px -96px}.ui-icon-document-b{background-position:-48px -96px}.ui-icon-note{background-position:-64px -96px}.ui-icon-mail-closed{background-position:-80px -96px}.ui-icon-mail-open{background-position:-96px -96px}.ui-icon-suitcase{background-position:-112px -96px}.ui-icon-comment{background-position:-128px -96px}.ui-icon-person{background-position:-144px -96px}.ui-icon-print{background-position:-160px -96px}.ui-icon-trash{background-position:-176px -96px}.ui-icon-locked{background-position:-192px -96px}.ui-icon-unlocked{background-position:-208px -96px}.ui-icon-bookmark{background-position:-224px -96px}.ui-icon-tag{background-position:-240px -96px}.ui-icon-home{background-position:0 -112px}.ui-icon-flag{background-position:-16px -112px}.ui-icon-calendar{background-position:-32px -112px}.ui-icon-cart{background-position:-48px -112px}.ui-icon-pencil{background-position:-64px -112px}.ui-icon-clock{background-position:-80px -112px}.ui-icon-disk{background-position:-96px -112px}.ui-icon-calculator{background-position:-112px -112px}.ui-icon-zoomin{background-position:-128px -112px}.ui-icon-zoomout{background-position:-144px -112px}.ui-icon-search{background-position:-160px -112px}.ui-icon-wrench{background-position:-176px -112px}.ui-icon-gear{background-position:-192px -112px}.ui-icon-heart{background-position:-208px -112px}.ui-icon-star{background-position:-224px -112px}.ui-icon-link{background-position:-240px -112px}.ui-icon-cancel{background-position:0 -128px}.ui-icon-plus{background-position:-16px -128px}.ui-icon-plusthick{background-position:-32px -128px}.ui-icon-minus{background-position:-48px -128px}.ui-icon-minusthick{background-position:-64px -128px}.ui-icon-close{background-position:-80px -128px}.ui-icon-closethick{background-position:-96px -128px}.ui-icon-key{background-position:-112px -128px}.ui-icon-lightbulb{background-position:-128px -128px}.ui-icon-scissors{background-position:-144px -128px}.ui-icon-clipboard{background-position:-160px -128px}.ui-icon-copy{background-position:-176px -128px}.ui-icon-contact{background-position:-192px -128px}.ui-icon-image{background-position:-208px -128px}.ui-icon-video{background-position:-224px -128px}.ui-icon-script{background-position:-240px -128px}.ui-icon-alert{background-position:0 -144px}.ui-icon-info{background-position:-16px -144px}.ui-icon-notice{background-position:-32px -144px}.ui-icon-help{background-position:-48px -144px}.ui-icon-check{background-position:-64px -144px}.ui-icon-bullet{background-position:-80px -144px}.ui-icon-radio-on{background-position:-96px -144px}.ui-icon-radio-off{background-position:-112px -144px}.ui-icon-pin-w{background-position:-128px -144px}.ui-icon-pin-s{background-position:-144px -144px}.ui-icon-play{background-position:0 -160px}.ui-icon-pause{background-position:-16px -160px}.ui-icon-seek-next{background-position:-32px -160px}.ui-icon-seek-prev{background-position:-48px -160px}.ui-icon-seek-end{background-position:-64px -160px}.ui-icon-seek-start{background-position:-80px -160px}.ui-icon-seek-first{background-position:-80px -160px}.ui-icon-stop{background-position:-96px -160px}.ui-icon-eject{background-position:-112px -160px}.ui-icon-volume-off{background-position:-128px -160px}.ui-icon-volume-on{background-position:-144px -160px}.ui-icon-power{background-position:0 -176px}.ui-icon-signal-diag{background-position:-16px -176px}.ui-icon-signal{background-position:-32px -176px}.ui-icon-battery-0{background-position:-48px -176px}.ui-icon-battery-1{background-position:-64px -176px}.ui-icon-battery-2{background-position:-80px -176px}.ui-icon-battery-3{background-position:-96px -176px}.ui-icon-circle-plus{background-position:0 -192px}.ui-icon-circle-minus{background-position:-16px -192px}.ui-icon-circle-close{background-position:-32px -192px}.ui-icon-circle-triangle-e{background-position:-48px -192px}.ui-icon-circle-triangle-s{background-position:-64px -192px}.ui-icon-circle-triangle-w{background-position:-80px -192px}.ui-icon-circle-triangle-n{background-position:-96px -192px}.ui-icon-circle-arrow-e{background-position:-112px -192px}.ui-icon-circle-arrow-s{background-position:-128px -192px}.ui-icon-circle-arrow-w{background-position:-144px -192px}.ui-icon-circle-arrow-n{background-position:-160px -192px}.ui-icon-circle-zoomin{background-position:-176px -192px}.ui-icon-circle-zoomout{background-position:-192px -192px}.ui-icon-circle-check{background-position:-208px -192px}.ui-icon-circlesmall-plus{background-position:0 -208px}.ui-icon-circlesmall-minus{background-position:-16px -208px}.ui-icon-circlesmall-close{background-position:-32px -208px}.ui-icon-squaresmall-plus{background-position:-48px -208px}.ui-icon-squaresmall-minus{background-position:-64px -208px}.ui-icon-squaresmall-close{background-position:-80px -208px}.ui-icon-grip-dotted-vertical{background-position:0 -224px}.ui-icon-grip-dotted-horizontal{background-position:-16px -224px}.ui-icon-grip-solid-vertical{background-position:-32px -224px}.ui-icon-grip-solid-horizontal{background-position:-48px -224px}.ui-icon-gripsmall-diagonal-se{background-position:-64px -224px}.ui-icon-grip-diagonal-se{background-position:-80px -224px}.ui-corner-all,.ui-corner-top,.ui-corner-left,.ui-corner-tl{border-top-left-radius:3px}.ui-corner-all,.ui-corner-top,.ui-corner-right,.ui-corner-tr{border-top-right-radius:3px}.ui-corner-all,.ui-corner-bottom,.ui-corner-left,.ui-corner-bl{border-bottom-left-radius:3px}.ui-corner-all,.ui-corner-bottom,.ui-corner-right,.ui-corner-br{border-bottom-right-radius:3px}.ui-widget-overlay{background:#aaa;opacity:.003;filter:Alpha(Opacity=.3)}.ui-widget-shadow{-webkit-box-shadow:0 0 5px #666;box-shadow:0 0 5px #666} \ No newline at end of file diff --git a/software/dashboard/grafana/csv/Node-RED_files/main.min.js b/software/dashboard/grafana/csv/Node-RED_files/main.min.js new file mode 100644 index 0000000..e14bfa2 --- /dev/null +++ b/software/dashboard/grafana/csv/Node-RED_files/main.min.js @@ -0,0 +1,16 @@ +/** + * Copyright OpenJS Foundation and other contributors, https://openjsf.org/ + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + **/ +$(function(){"localhost"!==window.location.hostname&&"127.0.0.1"!==window.location.hostname&&(document.title=document.title+" : "+window.location.hostname),RED.init({apiRootUrl:""})}); \ No newline at end of file diff --git a/software/dashboard/grafana/csv/Node-RED_files/modal.html b/software/dashboard/grafana/csv/Node-RED_files/modal.html new file mode 100644 index 0000000..2f6a392 --- /dev/null +++ b/software/dashboard/grafana/csv/Node-RED_files/modal.html @@ -0,0 +1,3 @@ + + +
          \ No newline at end of file diff --git a/software/dashboard/grafana/csv/Node-RED_files/monaco-bootstrap.js b/software/dashboard/grafana/csv/Node-RED_files/monaco-bootstrap.js new file mode 100644 index 0000000..2c66859 --- /dev/null +++ b/software/dashboard/grafana/csv/Node-RED_files/monaco-bootstrap.js @@ -0,0 +1,26 @@ +(function() { + var _isIE = /MSIE \d|Trident.*rv:/.test(navigator.userAgent); + //dont load monaco if IE + if(_isIE === false) { + var userLocale = (localStorage.getItem("editor-language") + "") + var browserLocale = typeof navigator === "undefined" ? "" : (navigator.language || navigator.userLanguage || ""); + var cultureDists = { + "zh-cn":"zh-hans", + "zh-tw":"zh-hant", + "ja":"ja", + "ko":"ko", + "de":"de", + "fr":"fr", + "it":"it", + "es":"es", + "ru":"ru", + "tr":"tr", + "pl":"pl", + "pt-br":"pt-br", + "cs":"cs" + }; + var uiLanguage = cultureDists[userLocale.toLowerCase()] || cultureDists[browserLocale.toLowerCase()]; + if(uiLanguage) document.write('
          \ No newline at end of file diff --git a/software/dashboard/grafana/csv/Node-RED_files/red.min.js b/software/dashboard/grafana/csv/Node-RED_files/red.min.js new file mode 100644 index 0000000..051dfe7 --- /dev/null +++ b/software/dashboard/grafana/csv/Node-RED_files/red.min.js @@ -0,0 +1,18 @@ +/** + * Copyright OpenJS Foundation and other contributors, https://openjsf.org/ + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + **/ +!function(){var o;!window.MSInputMethodContext||!document.documentMode||(window.DOMTokenList.prototype.toggle=function(e,t){1===arguments.length&&(t=!this.contains(e)),this[t?"add":"remove"](e)},"classList"in SVGElement.prototype||Object.defineProperty(SVGElement.prototype,"classList",Object.getOwnPropertyDescriptor(HTMLElement.prototype,"classList")),"children"in SVGElement.prototype||Object.defineProperty(SVGElement.prototype,"children",Object.getOwnPropertyDescriptor(HTMLElement.prototype,"children")),Array.from=function(){if(1)/),n=(o.length,function(){var e,t;0===o.length?i():(e=o.shift(),t=n,a(e,//.exec(e.trim()),"#red-ui-editor-plugin-configs",t))});n()}})})}})}function a(e,t,i,a){var s;a=a||function(){},t?(s=t[1],RED._loadingModule=s):s="unknown";try{var r=!1,d=$("
          "+e+"
          "),o=d.find("script"),l=o.length;o.each(function(e,t){var o,n=$(t).attr("src");n&&!/^\s*(https?:|\/|\.)/.test(n)?($(t).remove(),(o=document.createElement("script")).onload=function(){0===--l&&($(i).append(d),delete RED._loadingModule,a())},"module"===$(t).attr("type")&&(o.type="module"),$(i).append(o),o.src=RED.settings.apiRootUrl+n,r=!0):((/\/ace.js$/.test(n)||/\/ext-language_tools.js$/.test(n))&&(console.warn("Blocked attempt to load",n,"by",s),$(t).remove()),l--)}),r||($(i).append(d),delete RED._loadingModule,a())}catch(e){RED.notify(RED._("notification.errors.failedToAppendNode",{module:s,error:e.toString()}),{type:"error",timeout:1e4}),console.log("["+s+"] "+e.toString()),delete RED._loadingModule,a()}}function s(e,t){a(e,//.exec(e.trim()),"#red-ui-editor-node-configs",t)}function r(t){$.ajax({headers:{Accept:"application/json"},cache:!1,url:"icons",success:function(e){RED.nodes.setIconSets(e),t&&t()}})}function t(){f.reportProgress(RED._("event.loadNodes",{count:""}),30);var e=localStorage.getItem("editor-language")||RED.i18n.detectLanguage();$.ajax({headers:{Accept:"text/html","Accept-Language":e},cache:!1,url:"nodes",success:function(e){var t=e.trim().split(/(?=)/),o=t.length,n=function(){f.reportProgress(RED._("event.loadNodes",{count:o-t.length+"/"+o}),30+(o-t.length)/o*40),0===t.length?($("#red-ui-editor").i18n(),$("#red-ui-palette > .red-ui-palette-spinner").hide(),$(".red-ui-palette-scroll").removeClass("hide"),$("#red-ui-palette-search").removeClass("hide"),RED.settings.theme("projects.enabled",!1)?RED.projects.refresh(function(t){d(function(){RED.sidebar.info.refresh();var e=!1;t||(RED.menu.setDisabled("menu-item-projects-open",!0),RED.menu.setDisabled("menu-item-projects-settings",!0),!1!==t&&(e=!0)),l(e)})}):d(function(){RED.sidebar.info.refresh(),l()})):s(t.shift(),n)};n()}})}function d(a){f.reportProgress(RED._("event.loadFlows"),80),$.ajax({headers:{Accept:"application/json"},cache:!1,url:"flows",success:function(e){if(e){var t=window.location.hash;RED.nodes.version(e.rev),f.reportProgress(RED._("event.importFlows"),90);try{if(RED.nodes.import(e.flows),RED.nodes.dirty(!1),RED.view.redraw(!0),/^#flow\/.+$/.test(t)&&RED.workspaces.show(t.substring(6),!0),0").text(e)),RED.sidebar.info.refresh()})})):(t.text?(t.default=t.text,e=RED._(t.text,t),o={type:t.type,fixed:void 0===t.timeout,timeout:t.timeout,id:n},"runtime-state"===n&&("safe-mode"===t.error?o.buttons=[{text:RED._("common.label.close"),click:function(){i[n].hideNotification()}}]:"missing-types"===t.error?(e+="
          • "+t.types.map(RED.utils.sanitize).join("
          • ")+"
          ",RED.projects.getActiveProject()?o.buttons=[{text:RED._("notification.label.manage-project-dep"),click:function(){i[n].hideNotification(),RED.projects.settings.show("deps")}}]:o.buttons=[{text:RED._("notification.label.unknownNodesButton"),class:"pull-left",click:function(){RED.actions.invoke("core:search","type:unknown ")}},{class:"primary",text:RED._("common.label.close"),click:function(){i[n].hideNotification()}}]):"missing-modules"===t.error?(e+="
          • "+t.modules.map(function(e){return RED.utils.sanitize(e.module)+(e.error?" - "+RED.utils.sanitize(""+e.error)+"":"")}).join("
          • ")+"
          ",o.buttons=[{text:RED._("common.label.close"),click:function(){i[n].hideNotification()}}]):"credentials_load_failed"===t.error?RED.settings.theme("projects.enabled",!1)?RED.user.hasPermission("projects.write")&&(o.buttons=[{text:RED._("notification.project.setupCredentials"),click:function(){i[n].hideNotification(),RED.projects.showCredentialsPrompt()}}]):o.buttons=[{text:RED._("common.label.close"),click:function(){i[n].hideNotification()}}]:"missing_flow_file"===t.error||"missing_package_file"===t.error?RED.user.hasPermission("projects.write")&&(o.buttons=[{text:RED._("notification.project.setupProjectFiles"),click:function(){i[n].hideNotification(),RED.projects.showFilesPrompt()}}]):"project_empty"===t.error?RED.user.hasPermission("projects.write")&&(o.buttons=[{text:RED._("notification.project.no"),click:function(){i[n].hideNotification()}},{text:RED._("notification.project.createDefault"),click:function(){i[n].hideNotification(),RED.projects.createDefaultFileSet()}}]):"git_merge_conflict"===t.error&&(RED.nodes.clear(),RED.sidebar.versionControl.refresh(!0),RED.user.hasPermission("projects.write")&&(o.buttons=[{text:RED._("notification.project.mergeConflict"),click:function(){i[n].hideNotification(),RED.sidebar.versionControl.showLocalChanges()}}]))),i.hasOwnProperty(n)?i[n].update(e,o):i[n]=RED.notify(e,o)):i.hasOwnProperty(n)&&(i[n].close(),delete i[n]),"runtime-state"===n&&RED.events.emit("runtime-state",t)))}),RED.comms.subscribe("status/#",function(e,t){e=e.split("/"),e=RED.nodes.node(e[1]);e&&(t.hasOwnProperty("text")&&null!==t.text&&/^[@a-zA-Z]/.test(t.text)&&(t.text=e._(t.text.toString(),{defaultValue:t.text.toString()})),e.status=t,e.dirtyStatus=!0,e.dirty=!0,RED.view.redrawStatus(e))}),RED.comms.subscribe("notification/node/#",function(e,n){var t,o,i;if("notification/node/added"==e)RED.settings.refreshSettings(function(e,t){var o=[];n.forEach(function(e){var t=e.id;RED.nodes.addNodeSet(e),o=o.concat(e.types),RED.i18n.loadNodeCatalog(t,function(){var e=localStorage.getItem("editor-language")||RED.i18n.detectLanguage();$.ajax({headers:{Accept:"text/html","Accept-Language":e},cache:!1,url:"nodes/"+t,success:function(e){s(e)}})})}),o.length&&(i="
          • "+o.map(RED.utils.sanitize).join("
          • ")+"
          ",RED.notify(RED._("palette.event.nodeAdded",{count:o.length})+i,"success")),r()});else if("notification/node/removed"==e){for(t=0;t
        3. "+o.types.map(RED.utils.sanitize).join("
        4. ")+"
        5. ",RED.notify(RED._("palette.event.nodeRemoved",{count:o.types.length})+i,"success"));r()}else"notification/node/enabled"==e?n.types&&RED.settings.refreshSettings(function(e,t){var o;RED.nodes.getNodeSet(n.id).added?(RED.nodes.enableNodeSet(n.id),i="
          • "+n.types.map(RED.utils.sanitize).join("
          • ")+"
          ",RED.notify(RED._("palette.event.nodeEnabled",{count:n.types.length})+i,"success")):(o=localStorage.getItem("editor-language")||RED.i18n.detectLanguage(),$.ajax({headers:{Accept:"text/html","Accept-Language":o},cache:!1,url:"nodes/"+n.id,success:function(e){s(e),i="
          • "+n.types.map(RED.utils.sanitize).join("
          • ")+"
          ",RED.notify(RED._("palette.event.nodeAdded",{count:n.types.length})+i,"success")}}))}):"notification/node/disabled"==e?n.types&&(RED.nodes.disableNodeSet(n.id),i="
          • "+n.types.map(RED.utils.sanitize).join("
          • ")+"
          ",RED.notify(RED._("palette.event.nodeDisabled",{count:n.types.length})+i,"success")):"notification/node/upgraded"==e&&(RED.notify(RED._("palette.event.nodeUpgraded",{module:n.module,version:n.version}),"success"),RED.nodes.registry.setModulePendingUpdated(n.module,n.version))}),RED.comms.subscribe("event-log/#",function(e,t){e=e.substring(9);RED.eventLog.log(e,t)}),$(".red-ui-header-toolbar").show(),RED.sidebar.show(":first",!0),setTimeout(function(){var e;f.end(),!(e=function(){t&&RED.projects.showStartup()})!==RED.settings.theme("tours")&&RED.settings.get("editor.view.view-show-welcome-tours",!0)?RED.actions.invoke("core:show-welcome-tour",RED.settings.get("editor.tours.welcome"),e):e()},100)}function c(){var e=[];RED.settings.theme("projects.enabled",!1)&&e.push({id:"menu-item-projects-menu",label:RED._("menu.label.projects"),options:[{id:"menu-item-projects-new",label:RED._("menu.label.projects-new"),disabled:!1,onselect:"core:new-project"},{id:"menu-item-projects-open",label:RED._("menu.label.projects-open"),disabled:!1,onselect:"core:open-project"},{id:"menu-item-projects-settings",label:RED._("menu.label.projects-settings"),disabled:!1,onselect:"core:show-project-settings"}]}),e.push({id:"menu-item-edit-menu",label:RED._("menu.label.edit"),options:[{id:"menu-item-edit-undo",label:RED._("keyboard.undoChange"),disabled:!0,onselect:"core:undo"},{id:"menu-item-edit-redo",label:RED._("keyboard.redoChange"),disabled:!0,onselect:"core:redo"},null,{id:"menu-item-edit-cut",label:RED._("keyboard.cutNode"),onselect:"core:cut-selection-to-internal-clipboard"},{id:"menu-item-edit-copy",label:RED._("keyboard.copyNode"),onselect:"core:copy-selection-to-internal-clipboard"},{id:"menu-item-edit-paste",label:RED._("keyboard.pasteNode"),disabled:!0,onselect:"core:paste-from-internal-clipboard"},null,{id:"menu-item-edit-copy-group-style",label:RED._("keyboard.copyGroupStyle"),onselect:"core:copy-group-style"},{id:"menu-item-edit-paste-group-style",label:RED._("keyboard.pasteGroupStyle"),disabled:!0,onselect:"core:paste-group-style"},null,{id:"menu-item-edit-select-all",label:RED._("keyboard.selectAll"),onselect:"core:select-all-nodes"},{id:"menu-item-edit-select-connected",label:RED._("keyboard.selectAllConnected"),onselect:"core:select-connected-nodes"},{id:"menu-item-edit-select-none",label:RED._("keyboard.selectNone"),onselect:"core:select-none"},null,{id:"menu-item-edit-split-wire-with-links",label:RED._("keyboard.splitWireWithLinks"),onselect:"core:split-wire-with-link-nodes"}]}),e.push({id:"menu-item-view-menu",label:RED._("menu.label.view.view"),options:[{id:"menu-item-palette",label:RED._("menu.label.palette.show"),toggle:!0,onselect:"core:toggle-palette",selected:!0},{id:"menu-item-sidebar",label:RED._("menu.label.sidebar.show"),toggle:!0,onselect:"core:toggle-sidebar",selected:!0},{id:"menu-item-event-log",label:RED._("eventLog.title"),onselect:"core:show-event-log"},{id:"menu-item-action-list",label:RED._("keyboard.actionList"),onselect:"core:show-action-list"},null]}),e.push({id:"menu-item-arrange-menu",label:RED._("menu.label.arrange"),options:[{id:"menu-item-view-tools-move-to-back",label:RED._("menu.label.moveToBack"),disabled:!0,onselect:"core:move-selection-to-back"},{id:"menu-item-view-tools-move-to-front",label:RED._("menu.label.moveToFront"),disabled:!0,onselect:"core:move-selection-to-front"},{id:"menu-item-view-tools-move-backwards",label:RED._("menu.label.moveBackwards"),disabled:!0,onselect:"core:move-selection-backwards"},{id:"menu-item-view-tools-move-forwards",label:RED._("menu.label.moveForwards"),disabled:!0,onselect:"core:move-selection-forwards"},null,{id:"menu-item-view-tools-align-left",label:RED._("menu.label.alignLeft"),disabled:!0,onselect:"core:align-selection-to-left"},{id:"menu-item-view-tools-align-center",label:RED._("menu.label.alignCenter"),disabled:!0,onselect:"core:align-selection-to-center"},{id:"menu-item-view-tools-align-right",label:RED._("menu.label.alignRight"),disabled:!0,onselect:"core:align-selection-to-right"},null,{id:"menu-item-view-tools-align-top",label:RED._("menu.label.alignTop"),disabled:!0,onselect:"core:align-selection-to-top"},{id:"menu-item-view-tools-align-middle",label:RED._("menu.label.alignMiddle"),disabled:!0,onselect:"core:align-selection-to-middle"},{id:"menu-item-view-tools-align-bottom",label:RED._("menu.label.alignBottom"),disabled:!0,onselect:"core:align-selection-to-bottom"},null,{id:"menu-item-view-tools-distribute-horizontally",label:RED._("menu.label.distributeHorizontally"),disabled:!0,onselect:"core:distribute-selection-horizontally"},{id:"menu-item-view-tools-distribute-veritcally",label:RED._("menu.label.distributeVertically"),disabled:!0,onselect:"core:distribute-selection-vertically"}]}),e.push(null),RED.settings.theme("menu.menu-item-import-library",!0)&&e.push({id:"menu-item-import",label:RED._("menu.label.import"),onselect:"core:show-import-dialog"}),RED.settings.theme("menu.menu-item-export-library",!0)&&e.push({id:"menu-item-export",label:RED._("menu.label.export"),onselect:"core:show-export-dialog"}),e.push(null),e.push({id:"menu-item-search",label:RED._("menu.label.search"),onselect:"core:search"}),e.push(null),e.push({id:"menu-item-config-nodes",label:RED._("menu.label.displayConfig"),onselect:"core:show-config-tab"}),e.push({id:"menu-item-workspace",label:RED._("menu.label.flows"),options:[{id:"menu-item-workspace-add",label:RED._("menu.label.add"),onselect:"core:add-flow"},{id:"menu-item-workspace-edit",label:RED._("menu.label.rename"),onselect:"core:edit-flow"},{id:"menu-item-workspace-delete",label:RED._("menu.label.delete"),onselect:"core:remove-flow"}]}),e.push({id:"menu-item-subflow",label:RED._("menu.label.subflows"),options:[{id:"menu-item-subflow-create",label:RED._("menu.label.createSubflow"),onselect:"core:create-subflow"},{id:"menu-item-subflow-convert",label:RED._("menu.label.selectionToSubflow"),disabled:!0,onselect:"core:convert-to-subflow"}]}),e.push({id:"menu-item-group",label:RED._("menu.label.groups"),options:[{id:"menu-item-group-group",label:RED._("menu.label.groupSelection"),disabled:!0,onselect:"core:group-selection"},{id:"menu-item-group-ungroup",label:RED._("menu.label.ungroupSelection"),disabled:!0,onselect:"core:ungroup-selection"},null,{id:"menu-item-group-merge",label:RED._("menu.label.groupMergeSelection"),disabled:!0,onselect:"core:merge-selection-to-group"},{id:"menu-item-group-remove",label:RED._("menu.label.groupRemoveSelection"),disabled:!0,onselect:"core:remove-selection-from-group"}]}),e.push(null),!1!==RED.settings.get("externalModules.palette.allowInstall",!0)&&(e.push({id:"menu-item-edit-palette",label:RED._("menu.label.editPalette"),onselect:"core:manage-palette"}),e.push(null)),e.push({id:"menu-item-user-settings",label:RED._("menu.label.settings"),onselect:"core:show-user-settings"}),e.push(null),RED.settings.theme("menu.menu-item-keyboard-shortcuts",!0)&&e.push({id:"menu-item-keyboard-shortcuts",label:RED._("menu.label.keyboardShortcuts"),onselect:"core:show-help"}),e.push({id:"menu-item-help",label:RED.settings.theme("menu.menu-item-help.label",RED._("menu.label.help")),href:RED.settings.theme("menu.menu-item-help.url","http://nodered.org/docs")}),e.push({id:"menu-item-node-red-version",label:"v"+RED.settings.version,onselect:"core:show-about"}),$('
        6. ').appendTo(".red-ui-header-toolbar"),RED.menu.init({id:"red-ui-header-button-sidemenu",options:e})}var u=null,p=!1;var f={init:function(){var e=$('
          ').hide(),t=$("
          ").appendTo(e),t=($("
          ",{class:"red-ui-loading-bar-label"}).appendTo(t),$("
          ",{class:"red-ui-loading-bar"}).appendTo(t));$("").appendTo(t);return e},start:function(e,t){e&&f.reportProgress(e,t),$("#red-ui-loading-progress").show()},reportProgress:function(e,t){$(".red-ui-loading-bar-label").text(e),$(".red-ui-loading-bar span").width(t+"%")},end:function(){$("#red-ui-loading-progress").hide(),f.reportProgress("",0)}};return{init:function(e){if(p)throw new Error("RED already initialised");var t,o,n;p=!0,window.ace&&window.ace.require("ace/ext/language_tools"),(e=e||{}).apiRootUrl=e.apiRootUrl||"",e.apiRootUrl&&!/\/$/.test(e.apiRootUrl)&&(e.apiRootUrl=e.apiRootUrl+"/"),e.target=$("#red-ui-editor"),e.target.addClass("red-ui-editor"),t=e,o=$('
          ').appendTo(t.target),n=$('').appendTo(o),$('
            ').appendTo(o),$('
            ').appendTo(o),$('
            ').appendTo(t.target),$('
            ').appendTo(t.target),$('
            ').appendTo(t.target),$('
            ').appendTo(t.target),f.init().appendTo("#red-ui-main-container"),f.start("...",0),$.getJSON(t.apiRootUrl+"theme",function(e){e.header&&(e.header.url&&(n=$("",{href:e.header.url}).appendTo(n)),e.header.image&&$("",{src:e.header.image}).appendTo(n),e.header.title&&$("").html(e.header.title).appendTo(n)),e.themes&&(u=e.themes)}),RED.i18n.init(e,function(){RED.settings.init(e,function(){u&&(RED.settings.editorTheme=RED.settings.editorTheme||{},RED.settings.editorTheme.themes=u),RED.workspaces.init(),RED.statusBar.init(),RED.view.init(),RED.userSettings.init(),RED.user.init(),RED.notifications.init(),RED.library.init(),RED.palette.init(),RED.eventLog.init(),!1!==RED.settings.get("externalModules.palette.allowInstall",!0)?RED.palette.editor.init():console.log("Palette editor disabled"),RED.sidebar.init(),RED.settings.theme("projects.enabled",!1)?RED.projects.init():console.log("Projects disabled"),RED.subflow.init(),RED.group.init(),RED.clipboard.init(),RED.search.init(),RED.actionList.init(),RED.editor.init(),RED.diagnostics.init(),RED.diff.init(),RED.deploy.init(RED.settings.theme("deployButton",null)),RED.keyboard.init(c),RED.nodes.init(),RED.runtime.init(),RED.comms.connect(),$("#red-ui-main-container").show(),i()})})},loader:f}}();RED.events=function(){var i={};return{on:function(e,t){i[e]=i[e]||[],i[e].push(t)},off:function(e,t){var o=i[e];if(o)for(var n=0;n"+RED.settings.user.username+""}),RED.menu.addItem("red-ui-header-button-user",{id:"usermenu-item-logout",label:RED._("menu.label.logout"),onselect:function(){RED.user.logout()}}))}var i=/^((.+)\.)?read$/,a=/^((.+)\.)?write$/;return{init:function(){var e;!RED.settings.user||RED.settings.editorTheme&&RED.settings.editorTheme.hasOwnProperty("userMenu")&&!RED.settings.editorTheme.userMenu||(e=$('
          • ').prependTo(".red-ui-header-toolbar"),(RED.settings.user.image?$('').css({backgroundImage:"url("+RED.settings.user.image+")"}):$('')).appendTo(e.find("a")),RED.menu.init({id:"red-ui-header-button-user",options:[]}),p())},login:function(l,c){"function"==typeof l&&(c=l,l={});var u=$('
            ');u.dialog({autoOpen:!1,classes:{"ui-dialog":"red-ui-editor-dialog","ui-dialog-titlebar-close":"hide","ui-widget-overlay":"red-ui-editor-dialog"},modal:!0,closeOnEscape:!!l.cancelable,width:600,resizable:!1,draggable:!1,close:function(e,t){$("#node-dialog-login").dialog("destroy").remove(),RED.keyboard.enable()}}),$("#node-dialog-login-fields").empty(),$.ajax({dataType:"json",url:"auth/login",success:function(i){var e=0;if("credentials"==i.type){for(;e",{class:"form-row"}),n=($('
            ").appendTo(o),$('').appendTo(o));e'+RED._("user.loginFailed")+''+(l.cancelable?''+RED._("common.label.cancel")+"":"")+'
            ').appendTo("#node-dialog-login-fields"),$("#node-dialog-login-submit").button(),$("#node-dialog-login-fields").on("submit",function(e){$("#node-dialog-login-submit").button("option","disabled",!0),$("#node-dialog-login-failed").hide(),$(".login-spinner").show();for(var t={client_id:"node-red-editor",grant_type:"password",scope:""},o=0;o",{class:"form-row",style:"text-align: center"}).appendTo("#node-dialog-login-fields"),RED.sessionMessages.forEach(function(e){$("
            ").css("color","var(--red-ui-text-color-error)").text(e).appendTo(s)}),delete RED.sessionMessages),$("
            ",{class:"form-row",style:"text-align: center"}).appendTo("#node-dialog-login-fields")),d=$('',{style:"padding: 10px"}).appendTo(o).on("click",function(){document.location=t.url});t.image?$("",{src:t.image}).appendTo(d):t.label&&(r=$("").text(t.label),t.icon&&($("",{class:"fa fa-2x "+t.icon,style:"vertical-align: middle"}).appendTo(d),r.css({verticalAlign:"middle",marginLeft:"8px"})),r.appendTo(d)),d.button()}}l.cancelable&&$("#node-dialog-login-cancel").button().on("click",function(e){$("#node-dialog-login").dialog("close")});a=i.image||"red/images/node-red-256.svg";$("#node-dialog-login-image").load(function(){u.dialog("open")}).attr("src",a),RED.keyboard.disable()}})},logout:function(){var e=(e=RED.settings.get("auth-tokens"))?e.access_token:"";$.ajax({url:"auth/revoke",type:"POST",data:{token:e}}).done(function(e,t,o){RED.settings.remove("auth-tokens"),e&&e.redirect?document.location.href=e.redirect:document.location.reload(!0)}).fail(function(e,t,o){401===e.status?document.location.reload(!0):console.log(t)})},hasPermission:function(e){return""===e||(!RED.settings.user||function e(t,o){if(""===o)return!0;var n;if(Array.isArray(o)){for(n=0;n'+RED._("notification.errors.lostConnectionTry")+"",a.update(e,{silent:!0}),$(a).find("a").on("click",function(e){e.preventDefault(),a.update(RED._("notification.errors.lostConnection"),{silent:!0}),clearInterval(l),r()}))},1e3)))}},subscribe:function(e,t){null==u[e]&&(u[e]=[]),u[e].push(t),i&&1==i.readyState&&i.send(JSON.stringify({subscribe:e}))},unsubscribe:function(e,t){if(u[e]){for(var o=0;o=e.length)break;if(!(e[s].isParsed||e.keep||e[s].isSeparator)){var r=e[s].content,d=r.indexOf(o.content);if(!(d<0)){var l,c=0;if(o.continued)for(;c++,0===(l=r.indexOf(o.content,d+c*o.content.length)););else c=1;if(l=d+c*o.content.length,e.splice(s,1),0=e.length)break;if(!(e[s].isParsed||e[s].inBounds||e.keep||e[s].isSeparator)){var r=function(e,t){var o,n={};for(o in t)t.hasOwnProperty(o)&&(n[o]=t[o]);var e=e.content,i=n.usePos&&n.startPos=e.length)break;e[d].isParsed||e[d].keep||e[d].isSeparator||0<=(r=(s=e[d].content).indexOf(o[a]))&&(e.splice(d,1),0/g,"")},getDirection:function(e,t,o,n){if("auto"!==t&&/^(rtl|ltr)$/i.test(t))return t;o=/^(rtl|ltr)$/i.test(o)?o:"ltr";t=n?e.split("").reverse().join(""):e,n=/[A-Za-z\u05d0-\u065f\u066a-\u06ef\u06fa-\u07ff\ufb1d-\ufdff\ufe70-\ufefc]/.exec(t);return n?n[0]<="z"?"ltr":"rtl":o},hasArabicChar:function(e){return!!/[\u0600-\u065f\u066a-\u06ef\u06fa-\u07ff\ufb1d-\ufdff\ufe70-\ufefc]/.exec(e)},showMarks:function(e,t){for(var o="",n=0;n/g,this.LRM).replace(//g,this.RLM).replace(//g,this.LRE).replace(//g,this.RLE).replace(//g,this.LRO).replace(//g,this.RLO).replace(//g,this.PDF)},showTags:function(e){return""+e+""},hideTags:function(e){return e.replace(//g,"").replace(/<\/xmp>/g,"")}},l=((e={}).parseAndDisplayStructure=function(e,t,o,n){return e&&t?a(i(e,t,n),t,o):e},e.parseStructure=i,e.displayStructure=a,e.restore=function(e,t){return e},e);function y(e,t){e=Array.isArray(e)?e[0]:e;return e.guiDir||(e.guiDir="ltr"),e.dir||(e.dir=e.guiDir),t&&(void 0===e.points&&(e.points=[]),e.cases||(e.cases=[]),e.bounds||(e.bounds=[]),e.commonHandler=r),e}function i(e,t,o){if(!e||!t)return new u({content:""});var t=y(t,!0),n=[new u({content:e,actual:e,localGui:t.dir})],i=r.handle;return(i=t.handler&&"function"==typeof t.handler?t.handler.handle:i)(e,n,t,o),n}function a(e,t,o){t=y(t,!1);if(o){for(var n,i,a=e,s=t,r="",d="",l=0;l<a.length;l++)stop=!a[l].isVisible||(i=a[l].textDirection,""!==(n=a[l].localGui)&&""===d?r+="<bdi dir='"+("rtl"===n?"rtl":"ltr")+"'>":""===d||""!==n&&n===d&&!stop||(r+="</bdi>"+(l==a.length-1&&""!==n?"":"<span style='unicode-bidi: embed; direction: "+("rtl"===s.dir?"rtl":"ltr")+";'></span>"),""!==n&&(r+="<bdi dir='"+("rtl"===n?"rtl":"ltr")+"'>")),"auto"===i&&(i=b.getDirection(a[l].content,i,s.guiDir)),/^(rtl|ltr)$/i.test(i)?r+="<bdi dir='"+("rtl"===i?"rtl":"ltr")+"'>"+a[l].content+"</bdi>":(r+=a[l].content,b.getDirection(a[l].content,i,s.guiDir,!0)),l<a.length-1?(i=n&&a[l+1].localGui?n:s.dir,r+="<span style='unicode-bidi: embed; direction: "+("rtl"===i?"rtl":"ltr")+";'></span>"):""!==d&&(r+="</bdi>"),d=n,!1);o="auto"===s.dir?b.getDirection(a[0].actual,s.dir,s.guiDir):s.dir;return r=o!==s.guiDir?"<bdi dir='"+("rtl"===o?"rtl":"ltr")+"'>"+r+"</bdi>":r}for(var c,u,p=e,f=t,h="",g="",m=!1,v=0;v<p.length;v++)m=!p[v].isVisible||(u=p[v].textDirection,""!==(c=p[v].localGui)&&""===g?h+="rtl"===c?b.RLE:b.LRE:""===g||""!==c&&c===g&&!m||(h+=b.PDF+(v==p.length-1&&""!==c?"":"rtl"===f.dir?b.RLM:b.LRM),""!==c&&(h+="rtl"===c?b.RLE:b.LRE)),"auto"===u&&(u=b.getDirection(p[v].content,u,f.guiDir)),/^(rtl|ltr)$/i.test(u)?h+=("rtl"===u?b.RLE:b.LRE)+p[v].content+b.PDF:(h+=p[v].content,b.getDirection(p[v].content,u,f.guiDir,!0)),v<p.length-1?(u=c&&p[v+1].localGui?c:f.dir,h+="rtl"===u?b.RLM:b.LRM):""!==g&&(h+=b.PDF),g=c,!1);o="auto"===f.dir?b.getDirection(p[0].actual,f.dir,f.guiDir):f.dir;return h=o!==f.guiDir?("rtl"===o?b.RLE:b.LRE)+h+b.PDF:h}var t,o,n={format:function(e,t,o,n,i,a){t={guiDir:o?"rtl":"ltr",dir:t.dir||(o?"rtl":"ltr"),subs:{content:">",continued:!0,subDir:o?"rtl":"ltr"},cases:[{args:{subs:{content:"<",continued:!0,subDir:o?"ltr":"rtl"}}}]};return a?l.parseStructure(e,t,!!n,i):l.parseAndDisplayStructure(e,t,!!n,i)}},s={format:function(e,t,o,n,i,a){o={guiDir:o?"rtl":"ltr",dir:"ltr",points:","};return a?l.parseStructure(e,o,!!n,i):l.parseAndDisplayStructure(e,o,!!n,i)}},c={format:function(e,t,o,n,i,a){var s,o={guiDir:o?"rtl":"ltr",dir:(o=e,s=i,"ar"===b.getLocaleDetails(s).lang&&0<(s=o.indexOf("@"))&&s<o.length-1&&b.hasArabicChar(o.substring(s+1))?"rtl":"ltr"),points:"<>.:,;@",cases:[{handler:r,args:{bounds:[{startAfter:'"',endBefore:'"'},{startAfter:"(",endBefore:")"}],points:""}}]};return a?l.parseStructure(e,o,!!n,i):l.parseAndDisplayStructure(e,o,!!n,i)}},p={format:function(e,t,o,n,i,a){o={guiDir:o?"rtl":"ltr",dir:"ltr",points:"/\\:."};return a?l.parseStructure(e,o,!!n,i):l.parseAndDisplayStructure(e,o,!!n,i)}},f={format:function(e,t,o,n,i,a){o={guiDir:o?"rtl":"ltr",dir:"ltr",points:" /%^&[]<>=!?~:.,|()+-*{}"};return a?l.parseStructure(e,o,!!n,i):l.parseAndDisplayStructure(e,o,!!n,i)}},h={format:function(e,t,o,n,i,a){o={guiDir:o?"rtl":"ltr",dir:"ltr",points:"\t!#%&()*+,-./:;<=>?|[]{}",cases:[{handler:r,args:{bounds:[{startAfter:"/*",endBefore:"*/"},{startAfter:"--",end:"\n"},{startAfter:"--"}]}},{handler:r,args:{subs:{content:" ",continued:!0}}},{handler:r,args:{bounds:[{startAfter:"'",endBefore:"'"},{startAfter:'"',endBefore:'"'}]}}]};return a?l.parseStructure(e,o,!!n,i):l.parseAndDisplayStructure(e,o,!!n,i)}},g={format:function(e,t,o,n,i,a){o={guiDir:o?"rtl":"ltr",dir:"ltr",points:"_"};return a?l.parseStructure(e,o,!!n,i):l.parseAndDisplayStructure(e,o,!!n,i)}},m={format:function(e,t,o,n,i,a){o={guiDir:o?"rtl":"ltr",dir:"ltr",points:":?#/@.[]="};return a?l.parseStructure(e,o,!!n,i):l.parseAndDisplayStructure(e,o,!!n,i)}},v={format:function(e,t,o,n,i,a){t={guiDir:o?"rtl":"ltr",dir:t.dir||(o?"rtl":"ltr"),points:" ,.!?;:"};return a?l.parseStructure(e,t,!!n,i):l.parseAndDisplayStructure(e,t,!!n,i)}},w={format:function(e,t,o,n,i,a){o={guiDir:o?"rtl":"ltr",dir:"ltr",points:" /[]<>=!:@.|()+-*",cases:[{handler:r,args:{bounds:[{startAfter:'"',endBefore:'"'},{startAfter:"'",endBefore:"'"}],points:""}}]};return a?l.parseStructure(e,o,!!n,i):l.parseAndDisplayStructure(e,o,!!n,i)}},E={format:function(e,t,o,n,i,a){var s={},r="",d=Array.isArray(t)?t[0]:t;for(r in d)d.hasOwnProperty(r)&&(s[r]=d[r]);return s.guiDir=o?"rtl":"ltr",s.dir=s.dir||s.guiDir,a?l.parseStructure(e,s,!!n,i):l.parseAndDisplayStructure(e,s,!!n,i)}};o=!(t={msgLang:"en",msgDir:"",phLang:"",phDir:"",phPacking:["{","}"],phStt:{type:"none",args:{}},guiDir:""});function D(e){return"he"===e||"iw"===e||"ar"===e?"rtl":"ltr"}function R(e){0===e.msgDir.length&&(e.msgDir=D(e.msgLang)),e.msgDir="ltr"!==e.msgDir&&"rtl"!==e.msgDir&&"auto"!=e.msgDir?"ltr":e.msgDir,0===e.guiDir.length&&(e.guiDir=e.msgDir),e.guiDir="rtl"!==e.guiDir?"ltr":"rtl",0===e.phDir.length&&(e.phDir=0===e.phLang.length?e.msgDir:D(e.phLang)),e.phDir="ltr"!==e.phDir&&"rtl"!==e.phDir&&"auto"!=e.phDir?"ltr":e.phDir,"string"==typeof e.phPacking&&(e.phPacking=e.phPacking.split("")),e.phPacking.length<2&&(e.phPacking=["{","}"])}var x=null;function _(e){switch(e){case"breadcrumb":return n;case"comma":return s;case"email":return c;case"filepath":return p;case"formula":return f;case"sql":return h;case"underscore":return g;case"url":return m;case"word":return v;case"xpath":return w;default:return E}}function $(t,e,o,n,i){if(!t||1!=t.nodeType)return!1;x||(x=document.createEvent("Event")).initEvent("TF",!0,!0),t.setAttribute("data-tf-type",e);e="undefined"===o?"{}":JSON.stringify(Array.isArray(o)?o[0]:o),t.setAttribute("data-tf-args",e),o="ltr";return"undefined"===n&&(t.dir?o=t.dir:t.style&&t.style.direction&&(o=t.style.direction),n="rtl"===o.toLowerCase()),t.setAttribute("data-tf-dir",n),t.setAttribute("data-tf-locale",b.getLocaleDetails(i).lang),!function(e){var t=window.navigator.userAgent;if(!(0<=t.indexOf("MSIE")||0<=t.indexOf("Trident")||0<=t.indexOf("Edge")))return(t=document.createElement(e.tagName)).contentEditable=!0,(e="oninput"in t)||(t.setAttribute("oninput","return;"),e="function"==typeof t.oninput),t=null,e}(t)?(t.onkeyup=function(e){k(e.target),t.dispatchEvent(x)},t.onmouseup=function(e){k(e.target),t.dispatchEvent(x)}):(t.oninput,t.oninput=function(e){k(e.target)}),k(t),!0}function k(e){var t=e.textContent||"",o=document.getSelection();if(0===t.length||!o||o.rangeCount<=0)e.dispatchEvent(x);else{var n=o.getRangeAt(0),i=n.cloneRange(),a=n.startContainer,s=n.startOffset,r=0,s=(3===a.nodeType&&(r+=s),i.setStart(e,0),i.setEndBefore(a),document.createElement("div")),d=(s.appendChild(i.cloneContents()),r+=s.textContent.length,e.innerHTML=_(e.getAttribute("data-tf-type")).format(t,JSON.parse(e.getAttribute("data-tf-args")),"true"===e.getAttribute("data-tf-dir"),!0,e.getAttribute("data-tf-locale")),e),l=e,c=0,u=!1;for(o.removeAllRanges(),n.setStart(e,0),n.setEnd(e,0);l;){if(3===l.nodeType){if(c+l.nodeValue.length>=r){n.setStart(l,r-c);break}c+=l.nodeValue.length,l=l.nextSibling}else{if(l.hasChildNodes()){l=(d=l).firstChild;continue}l=l.nextSibling}for(;!l;){if(d===e){u=!0;break}l=d.nextSibling,d=d.parentNode}if(u)break}o.addRange(n),e.dispatchEvent(x)}}return{getHtml:function(e,t,o,n,i){return _(t).format(e,o,n,!0,i)},attach:$}}(),RED.state={DEFAULT:0,MOVING:1,JOINING:2,MOVING_ACTIVE:3,ADDING:4,EDITING:5,EXPORT:6,IMPORT:7,IMPORT_DRAGGING:8,QUICK_JOINING:9,PANNING:10,SELECTING_NODE:11,GROUP_DRAGGING:12,GROUP_RESIZE:13,DETACHED_DRAGGING:14,SLICING:15,SLICING_JUNCTION:16},RED.plugins=function(){var t={},o={};return{registerPlugin:function(e,n){(t[e]=n).type&&(o[n.type]=o[n.type]||[],o[n.type].push(n)),RED._loadingModule?(n.module=RED._loadingModule,n._=function(){var e=Array.prototype.slice.call(arguments),t=e[0],o=(/:/.test(e[0])||(e[0]=n.module+":"+e[0]),RED._.apply(null,e));return o===e[0]?t:o}):n._=RED._,n.onadd&&"function"==typeof n.onadd&&n.onadd(),RED.events.emit("registry:plugin-added",e)},getPlugin:function(e){return t[e]},getPluginsByType:function(e){return o[e]||[]}}}(),RED.nodes=function(){var ae,se,l={},re={},h=[],c={},de={},u=[],le={},x=null,ce={},p={},ue={},d={},t=!1;a={},s=[],r={},f={},o={},(g={}).tab={defaults:{label:{value:""},disabled:{value:!1},info:{value:""},env:{value:[]}}};var a,s,r,f,g,o,m,v,b,y,pe=m={setModulePendingUpdated:function(e,t){a[e].pending_version=t,RED.events.emit("registry:module-updated",{module:e,version:t})},getModule:function(e){return a[e]},getNodeSetForType:function(e){return m.getNodeSet(f[e])},getModuleList:function(){return a},getNodeList:function(){return s},getNodeTypes:function(){return Object.keys(g)},setNodeList:function(e){s=[];for(var t=0;t<e.length;t++){var o=e[t];m.addNodeSet(o)}},addNodeSet:function(e){if(e.types){e.added=!1,r[e.id]=e;for(var t=0;t<e.types.length;t++)f[e.types[t]]=e.id;s.push(e),a[e.module]=a[e.module]||{name:e.module,version:e.version,local:e.local,sets:{}},e.pending_version&&(a[e.module].pending_version=e.pending_version),a[e.module].sets[e.name]=e,RED.events.emit("registry:node-set-added",e)}},removeNodeSet:function(e){for(var t=r[e],o=0;o<t.types.length;o++)delete f[t.types[o]];delete r[e];for(var n=0;n<s.length;n++)if(s[n].id===e){s.splice(n,1);break}return delete a[t.module].sets[t.name],0===Object.keys(a[t.module].sets).length&&delete a[t.module],RED.events.emit("registry:node-set-removed",t),t},getNodeSet:function(e){return r[e]},enableNodeSet:function(e){e=r[e];e.enabled=!0,RED.events.emit("registry:node-set-enabled",e)},disableNodeSet:function(e){e=r[e];e.enabled=!1,RED.events.emit("registry:node-set-disabled",e)},registerNodeType:function(e,t){if("subflow:"!=e.substring(0,8)){var o,n,i;if(!r[f[e]])return o="",n=e,RED._loadingModule&&(n="["+RED._loadingModule+"] "+e,o=r[RED._loadingModule]?r[RED._loadingModule].err||"":"Unknown error"),void RED.notify(RED._("palette.event.unknownNodeRegistered",{type:n,error:o}),"error");t.set=r[f[e]],r[f[e]].added=!0,r[f[e]].enabled=!0,i="node-red"===t.set.module?"node-red":t.set.id,t._=function(){var e=Array.prototype.slice.call(arguments,0),t=e[0],o=(-1===e[0].indexOf(":")&&(e[0]=i+":"+e[0]),RED._.apply(null,e));return o=o===e[0]?t:o}}if(t.type=e,(g[e]=t).defaults)for(var a in t.defaults)if(t.defaults.hasOwnProperty(a)&&t.defaults[a].type)try{t.defaults[a]._type=function(e){e=e.trim();var t,o=0,n=/\[\]$/.test(e);n&&(e=e.substring(0,e.length-2));var i=e.length,a=!1,s=!1,r="",d=[];for(;o<i;){if(t=e[o],s)"|"===t?(d.push(r.trim()),r="",s=!1):")"===t?(d.push(r.trim()),r="",s=a=!1):r+=t;else if("("===t){if(a)throw new Error("Invalid character '"+t+"' at position "+o);a=!0}else" "!==t&&(s=!0,r=t);o++}0<(r=r.trim()).length&&d.push(r);return{types:d,array:n}}(t.defaults[a].type)}catch(e){console.warn(e)}RED.events.emit("registry:node-type-added",e)},removeNodeType:function(e){if("subflow:"!=e.substring(0,8))throw new Error("this api is subflow only. called with:",e);delete g[e],RED.events.emit("registry:node-type-removed",e)},getNodeType:function(e){return g[e]},setIconSets:function(e){(o=e)["font-awesome"]=RED.nodes.fontAwesome.getIconList()},getIconSets:function(){return o}},fe=(v={},b={},y={addTab:function(e){b[e]=[]},hasTab:function(e){return b.hasOwnProperty(e)},removeTab:function(e){delete b[e]},addNode:function(e){v[e.id]=e,b.hasOwnProperty(e.z)?b[e.z].push(e):(console.warn("Node added to unknown tab/subflow:",e),b._=b._||[],b._.push(e))},removeNode:function(e){var t;delete v[e.id],b.hasOwnProperty(e.z)&&-1<(t=b[e.z].indexOf(e))&&b[e.z].splice(t,1)},hasNode:function(e){return v.hasOwnProperty(e)},getNode:function(e){return v[e]},moveNode:function(e,t){y.removeNode(e),e.z=t,y.addNode(e)},moveNodesForwards:function(e){for(var t=[],o=(Array.isArray(e)||(e=[e]),b[e[0].z]),n=new Set(e.filter(function(e){return"group"!==e.type&&"subflow"!==e.type})),i=new Set,a=o.length-1;0<=a&&0!==n.size;a--){var s=o[a];n.has(s)&&(a<o.length-1&&!i.has(o[a+1])&&(o.splice(a,1),o.splice(a+1,0,s),s._reordered=!0,t.push(s)),n.delete(s),i.add(s))}return 0<t.length&&RED.events.emit("nodes:reorder",{z:e[0].z,nodes:t}),t},moveNodesBackwards:function(e){for(var t=[],o=(Array.isArray(e)||(e=[e]),b[e[0].z]),n=new Set(e.filter(function(e){return"group"!==e.type&&"subflow"!==e.type})),i=new Set,a=0;a<o.length&&0!==n.size;a++){var s=o[a];n.has(s)&&(0<a&&!i.has(o[a-1])&&(o.splice(a,1),o.splice(a-1,0,s),s._reordered=!0,t.push(s)),n.delete(s),i.add(s))}return 0<t.length&&RED.events.emit("nodes:reorder",{z:e[0].z,nodes:t}),t},moveNodesToFront:function(e){for(var t=[],o=(Array.isArray(e)||(e=[e]),b[e[0].z]),n=new Set(e.filter(function(e){return"group"!==e.type&&"subflow"!==e.type})),i=o.length-1,a=o.length-1;0<=a&&0!==n.size;a--){var s=o[a];n.has(s)&&(a<i&&(o.splice(a,1),o.splice(i,0,s),s._reordered=!0,t.push(s)),i--,n.delete(s))}return 0<t.length&&RED.events.emit("nodes:reorder",{z:e[0].z,nodes:t}),t},moveNodesToBack:function(e){for(var t=[],o=(Array.isArray(e)||(e=[e]),b[e[0].z]),n=new Set(e.filter(function(e){return"group"!==e.type&&"subflow"!==e.type})),i=0,a=0;a<o.length&&0!==n.size;a++){var s=o[a];n.has(s)&&(i<a&&(o.splice(a,1),o.splice(i,0,s),s._reordered=!0,t.push(s)),i++,n.delete(s))}return 0<t.length&&RED.events.emit("nodes:reorder",{z:e[0].z,nodes:t}),t},getNodes:function(e){return b[e]},clear:function(){v={},b={}},eachNode:function(e){var t,o,n;for(o in le)if(le.hasOwnProperty(o))for(t=b[o],n=0;n<t.length;n++)if(!1===e(t[n]))return;for(o=0;o<u.length;o++)for(t=b[u[o]],n=0;n<t.length;n++)if(!1===e(t[n]))return;if(b._)for(t=b._,n=0;n<t.length;n++)if(!1===e(t[n]))return},filterNodes:function(e){var t=[],o=null,n=!1,i=(e.hasOwnProperty("z")&&(b.hasOwnProperty(e.z)?o=b[e.z]:n=!0),!1);null===o&&(o=Object.keys(v),i=!0);for(var a=0;a<o.length;a++){var s=o[a];i&&(s=v[s]),e.hasOwnProperty("type")&&s.type!==e.type||n&&s.z!==e.z||t.push(s)}return t},getNodeOrder:function(e){return b[e].map(function(e){return e.id})},setNodeOrder:function(e,t){var o={};t.forEach(function(e,t){o[e]=t}),b[e].sort(function(e,t){return e._reordered=!0,t._reordered=!0,o[e.id]-o[t.id]})}});function he(){for(var e=[],t=0;t<8;t++)e.push(Math.round(255*Math.random()).toString(16).padStart(2,"0"));return e.join("")}function we(e){var t,o;0!==e.type.indexOf("subflow")?e._=e._def._:(t=e.type.substring(8),(t=RED.nodes.subflow(t))&&t.instances.push(t),e._=RED._),"config"==e._def.category?re[e.id]=e:(e.wires&&e.wires.length>e.outputs&&(e.outputs=e.wires.length),e.dirty=!0,C(e),"subflows"==e._def.category&&void 0===e.i&&(o=0,RED.nodes.eachNode(function(e){o=Math.max(o,e.i||0)}),e.i=o+1),fe.addNode(e),c[e.id]||(c[e.id]={in:[],out:[]})),RED.events.emit("nodes:add",e)}function ge(t){if(c[t.source.id]&&!c[t.source.id].out.every(function(e){return e.sourcePort!==t.sourcePort||e.target.id!==t.target.id}))return;h.push(t),t.source&&(c[t.source.id]||(c[t.source.id]={in:[],out:[]}),c[t.source.id].out.push(t)),t.target&&(c[t.target.id]||(c[t.target.id]={in:[],out:[]}),c[t.target.id].in.push(t)),t.source.z===t.target.z&&l[t.source.z]&&l[t.source.z].push(t),RED.events.emit("links:add",t)}function _(e){return e in re?re[e]:fe.getNode(e)}function w(e){var t,o=[],i=[];if(e in re)t=re[e],delete re[e],RED.events.emit("nodes:remove",t),RED.workspaces.refresh();else if(fe.hasNode(e)){t=fe.getNode(e),fe.removeNode(t),delete c[e],(o=h.filter(function(e){return e.source===t||e.target===t})).forEach(E);var a,s,r,d=!1;for(a in t._def.defaults)!t._def.defaults.hasOwnProperty(a)||(s=t._def.defaults[a]).type&&(s=pe.getNodeType(s.type))&&"config"==s.category&&(s=re[t[a]])&&(d=!0,s._def.exclusive?(w(t[a]),i.push(s)):((r=s.users).splice(r.indexOf(t),1),RED.events.emit("nodes:change",s)));0===t.type.indexOf("subflow:")&&(e=t.type.substring(8),(e=RED.nodes.subflow(e))&&e.instances.splice(e.instances.indexOf(t),1)),d&&RED.workspaces.refresh();try{t._def.oneditdelete&&t._def.oneditdelete.call(t)}catch(e){console.log("oneditdelete",t.id,t.type,e.toString())}RED.events.emit("nodes:remove",t)}return t&&t._def.onremove&&(console.log("Deprecated API warning: node type ",t.type," has an onremove function - should be oneditremove - please report"),t._def.onremove.call(n)),{links:o,nodes:i}}function E(e){var t,o=h.indexOf(e);-1!=o&&(h.splice(o,1),e.source&&c[e.source.id]&&(-1!==(t=c[e.source.id].out.indexOf(e))&&c[e.source.id].out.splice(t,1)),e.target&&c[e.target.id]&&(-1!==(t=c[e.target.id].in.indexOf(e))&&c[e.target.id].in.splice(t,1)),e.source.z===e.target.z&&l[e.source.z]&&-1!==(o=l[e.source.z].indexOf(e))&&l[e.source.z].splice(o,1)),RED.events.emit("links:remove",e)}function me(e,t){de[e.id]=e,fe.addTab(e.id),l[e.id]=[],e._def=RED.nodes.getType("tab"),void 0===t?u.push(e.id):u.splice(t,0,e.id),RED.events.emit("flows:add",e),void 0!==t&&RED.events.emit("flows:reorder",u)}function Ee(t,e){var o,n;e&&((e=Object.keys(le).map(function(e){return le[e].name})).sort(),o=1,n=t.name,e.forEach(function(e){n==e&&(o++,n=t.name+" ("+o+")")}),t.name=n),le[t.id]=t,fe.addTab(t.id),l[t.id]=[],RED.nodes.registerType("subflow:"+t.id,{defaults:{name:{value:""},env:{value:[]}},icon:function(){return t.icon||"subflow.svg"},category:t.category||"subflows",inputs:t.in.length,outputs:t.out.length,color:t.color||"#DDAA99",label:function(){return this.name||RED.nodes.subflow(t.id).name},labelStyle:function(){return this.name?"red-ui-flow-node-label-italic":""},paletteLabel:function(){return RED.nodes.subflow(t.id).name},inputLabels:function(e){return t.inputLabels?t.inputLabels[e]:null},outputLabels:function(e){return t.outputLabels?t.outputLabels[e]:null},oneditprepare:function(){"subflow"!==this.type?RED.subflow.buildEditForm("subflow",this):RED.subflow.buildEditForm("subflow-template",this)},oneditresize:function(e){"subflow"===this.type&&$("#node-input-env-container").editableList("height",e.height-80)},set:{module:"node-red"}}),t.instances=[],t._def=RED.nodes.getType("subflow:"+t.id),RED.events.emit("subflows:add",t)}function ve(e){return le[e]}function be(e,t){for(var o=fe.getNodes(e),n=0;n<o.length;n++){var i=o[n],i=/^subflow:(.+)$/.exec(i.type);if(i){if(i[1]===t)return!0;if(be(i[1],t))return!0}}return!1}function e(e,t){RED.view.selection();for(var o=new Set,n=[e],i=!0;0<n.length;){var a=n.shift(),s=(o.add(a),[]);i&&t&&(!i||"up"!==t)||(s=s.concat(c[a.id].in)),i&&t&&(!i||"down"!==t)||(s=s.concat(c[a.id].out)),i=!1,s.forEach(function(e){o.has(e.source)||n.push(e.source),o.has(e.target)||n.push(e.target)})}return Array.from(o)}function k(e,t){var o,n=!0,i=(t&&t.hasOwnProperty("credentials")&&(n=t.credentials),{});for(o in i.id=e.id,i.type=e.type,e._def.defaults)e._def.defaults.hasOwnProperty(o)&&(i[o]=e[o]);if(n){var a={};if(e.credentials){for(var s in e.credentials)e.credentials.hasOwnProperty(s)&&(!e.credentials._||e.credentials["has_"+s]!=e.credentials._["has_"+s]||e.credentials["has_"+s]&&e.credentials[s])&&(a[s]=e.credentials[s]);0<Object.keys(a).length&&(i.credentials=a)}}return i}function D(t,e){var o=!0,n=!1;if(!1===e?o=!1:"object"==typeof e&&(e.hasOwnProperty("credentials")&&(o=e.credentials),e.hasOwnProperty("dimensions")&&(n=e.dimensions)),"tab"===t.type)return k(t,{credentials:o});var i={};if(i.id=t.id,i.type=t.type,i.z=t.z,0!==i.z&&""!==i.z||delete i.z,!0===t.d&&(i.d=!0),t.g&&(i.g=t.g),"unknown"==i.type)for(var a in t._orig)t._orig.hasOwnProperty(a)&&(i[a]=t._orig[a]);else{for(var s in t._def.defaults)t._def.defaults.hasOwnProperty(s)&&(i[s]=t[s]);if(o){var r={};if((/^subflow:/.test(i.type)||"group"===i.type)&&t.credentials)for(var d in t.credentials)t.credentials.hasOwnProperty(d)&&(!t.credentials._||t.credentials["has_"+d]!=t.credentials._["has_"+d]||t.credentials["has_"+d]&&t.credentials[d])&&(r[d]=t.credentials[d]);else if(t.credentials)for(var l in i.credentials={},t._def.credentials)t._def.credentials.hasOwnProperty(l)&&("password"==t._def.credentials[l].type?(!t.credentials._||t.credentials["has_"+l]!=t.credentials._["has_"+l]||t.credentials["has_"+l]&&t.credentials[l])&&(r[l]=t.credentials[l]):null==t.credentials[l]||t.credentials._&&t.credentials[l]==t.credentials._[l]||(r[l]=t.credentials[l]));0<Object.keys(r).length&&(i.credentials=r)}}if("group"===t.type&&(i.x=t.x,i.y=t.y,i.w=t.w,i.h=t.h,i.nodes=i.nodes.filter(function(e){return!!e}).map(function(e){return e.id})),"tab"!==t.type&&"group"!==t.type||i.env&&0===i.env.length&&delete i.env,"config"!=t._def.category||"junction"===t.type){i.x=t.x,i.y=t.y,n&&(t.hasOwnProperty("w")||(e=RED.view.calculateNodeDimensions(t),t.w=e[0],t.h=e[1]),i.w=t.w,i.h=t.h),i.wires=[];for(var c=0;c<t.outputs;c++)i.wires.push([]);for(var u=h.filter(function(e){return e.source===t}),p=0;p<u.length;p++){var f=u[p];"subflow"!=f.target.type&&f.sourcePort<i.wires.length&&i.wires[f.sourcePort].push(f.target.id)}0<t.inputs&&t.inputLabels&&!/^\s*$/.test(t.inputLabels.join(""))&&(i.inputLabels=t.inputLabels.slice()),0<t.outputs&&t.outputLabels&&!/^\s*$/.test(t.outputLabels.join(""))&&(i.outputLabels=t.outputLabels.slice()),t._def.defaults&&t._def.defaults.hasOwnProperty("icon")||!t.icon||(o=RED.utils.getDefaultNodeIcon(t._def,t),t.icon!==o.module+"/"+o.file&&(i.icon=t.icon)),t._def.defaults&&t._def.defaults.hasOwnProperty("l")||!t.hasOwnProperty("l")||(!t._def.hasOwnProperty("showLabel")||t._def.showLabel)!=t.l&&(i.l=t.l)}return t.info&&(i.info=t.info),i}function T(a,e){var t=!0,s=(!1===e?t=!1:"object"==typeof e&&(e.hasOwnProperty("credentials")&&(t=e.credentials),e.hasOwnProperty("dimensions")&&e.dimensions),{});if(s.id=a.id,s.type=a.type,s.name=a.name,s.info=a.info,s.category=a.category,s.in=[],s.out=[],s.env=a.env,s.meta=a.meta,t){var o,n={};for(o in a.credentials)a.credentials.hasOwnProperty(o)&&(!a.credentials._||a.credentials["has_"+o]!=a.credentials._["has_"+o]||a.credentials["has_"+o]&&a.credentials[o])&&(n[o]=a.credentials[o]);0<Object.keys(n).length&&(s.credentials=n)}return s.color=a.color,a.in.forEach(function(t){for(var e={x:t.x,y:t.y,wires:[]},o=h.filter(function(e){return e.source===t}),n=0;n<o.length;n++){var i=o[n];"subflow"!=i.target.type&&e.wires.push({id:i.target.id})}s.in.push(e)}),a.out.forEach(function(t,e){var o={x:t.x,y:t.y,wires:[]},n=h.filter(function(e){return e.target===t});for(i=0;i<n.length;i++)"subflow"!=n[i].source.type?o.wires.push({id:n[i].source.id,port:n[i].sourcePort}):o.wires.push({id:a.id,port:0});s.out.push(o)}),0<s.in.length&&a.inputLabels&&!/^\s*$/.test(a.inputLabels.join(""))&&(s.inputLabels=a.inputLabels.slice()),0<s.out.length&&a.outputLabels&&!/^\s*$/.test(a.outputLabels.join(""))&&(s.outputLabels=a.outputLabels.slice()),a.icon&&"node-red/subflow.svg"!==a.icon&&(s.icon=a.icon),a.status&&(s.status={x:a.status.x,y:a.status.y,wires:[]},h.forEach(function(e){e.target===a.status&&("subflow"!=e.source.type?s.status.wires.push({id:e.source.id,port:e.sourcePort}):s.status.wires.push({id:a.id,port:0}))})),s}function ye(o,t,e,n){var i=[];t=t||{},o=o.filter(function(e){return!t[e.id]&&(t[e.id]=!0)}),n=n||{},e=e||{};for(var a=0;a<o.length;a++){var s,r,d=o[a];if("subflow:"!=d.type.substring(0,8)||e[s=d.type.substring(8)]||(e[s]=!0,p=ve(s),(r=fe.getNodes(s).slice()).unshift(p),RED.nodes.eachConfig(function(e){e.z==s&&(r.push(e),n[e.id]=!0)}),i=ye(r=(r=r.concat(RED.nodes.junctions(s))).concat(RED.nodes.groups(s)),t,e,n).concat(i)),"subflow"!==d.type){var l,c,u=RED.nodes.convertNode(d);for(l in d._def.defaults)d._def.defaults[l].type&&(c=d[l],0===(c=(c=Array.isArray(c)?c:[c]).filter(function(e){var t;return!(e in re)||!1!==(t=re[e])._def.exportable&&(e in n||(n[e]=!0,o.push(t)),!0)})).length?u[l]=Array.isArray(d[l])?[]:"":u[l]=Array.isArray(d[l])?c:c[0]);i.push(u),"group"===d.type&&(i=i.concat(ye(d.nodes,t,e,n)))}else{var p=T(d);i.push(p)}}return i}function De(e){var o={tabs:{},subflows:{},groups:{},junctions:{},configs:{},nodes:{},all:[],conflicted:{},zMap:{}};return e.forEach(function(e){o.all.push(e),"tab"===e.type?o.tabs[e.id]=e:"subflow"===e.type?o.subflows[e.id]=e:"group"===e.type?o.groups[e.id]=e:"junction"===e.type?o.junctions[e.id]=e:e.hasOwnProperty("x")&&e.hasOwnProperty("y")?o.nodes[e.id]=e:o.configs[e.id]=e;var t=e.z||"__global__";o.zMap[t]=o.zMap[t]||[],o.zMap[t].push(e),(fe.hasNode(e.id)||re[e.id]||de[e.id]||le[e.id]||ce[e.id]||ue[e.id])&&(o.conflicted[e.id]=e)}),o}function Re(e){var a={},s={},o={},r=[],e=(e.forEach(function(e){"subflow"===e.type?s[e.id]=e:e.hasOwnProperty("x")||e.hasOwnProperty("y")||(o[e.id]=e),e.z&&(a[e.z]=a[e.z]||[],a[e.z].push(e))}),Object.keys(o)),t=(e.forEach(function(e){var t=o[e];s[t.z]&&delete o[e]}),e=Object.keys(o),Object.keys(s));return t.forEach(function(e){var t,o,n,i=s[e];r=r.concat((t=ve(t=e),(n=fe.getNodes(t.id))?(o=n.slice()).unshift(t):o=[t],ye(o))),RED.subflow.removeSubflow(i.id,!0),R([i].concat(a[i.id]));s[e]=ve(e)}),RED.nodes.eachNode(function(e){var t;/^subflow:/.test(e.type)&&(t=e.type.substring(8),s[t]&&(s[t].instances.push(e),e._def=RED.nodes.getType(e.type),e.dirty=!0,e.changed=!0,e._colorChanged=!0))}),t.forEach(function(e){e=s[e];RED.events.emit("subflows:change",e)}),RED.utils.clearNodeColorCache(),e.forEach(function(e){r=r.concat(D(_(e))),w(e),R([o[e]])}),{removedNodes:r}}function R(e,o){(o=Object.assign({},{generateIds:!1,addFlow:!1,reimport:!1,importMap:{}},o)).importMap=o.importMap||{};var t,n=o.generateIds,A=!n&&!!o.reimport,M=o.addFlow,i={};if("string"==typeof e){if(""===e)return;try{r=JSON.parse(e)}catch(g){var a=new Error(RED._("clipboard.invalidFlow",{message:g.message}));throw a.code="NODE_RED",a}}else r=e;$.isArray(r)||(r=[r]);var z,B={},s=[],G=[],r=r.filter(function(e){var t=e.id;if(B[e.id])return!1;if(B[e.id]=!0,!o.generateIds)if(o.importMap[t]){if("replace"===o.importMap[t])return G.push(e),!1}else{t=fe.getNode(t)||re[t]||de[t]||le[t]||ce[t]||ue[t];t&&s.push({existing:t,imported:e})}return!0});if(0<s.length){for(var a=RED._("clipboard.importDuplicate",{count:s.length}),d=$("<ul>"),F=Math.min(5,s.length),l=0;l<F;l++){var c=s[l];$("<li>").text(c.existing.id+" [ "+c.existing.type+(c.imported.type!==c.existing.type?" | "+c.imported.type:"")+" ]").appendTo(d)}F!==s.length&&$("<li>").text(RED._("deploy.confirm.plusNMore",{count:s.length-F})).appendTo(d);e=$("<p>").append(d),a=new Error(a+e.html());throw a.code="import_conflict",a.importConfig=De(r),a}0<G.length&&(z=Re(G).removedNodes);var u,U=!1,p=(se||(U=!0,se=JSON.parse(JSON.stringify(r))),[]);for(l=0;l<r.length;l++){var f;(f=r[l]).id;"workspace"==f.type||"tab"==f.type||"subflow"==f.type||"group"==f.type||"junction"==f.type||pe.getNodeType(f.type)||"subflow:"==f.type.substring(0,8)||-1!=p.indexOf(f.type)||p.push(f.type),f.z?(i[f.z]=i[f.z]||[],i[f.z].push(f)):U&&f.hasOwnProperty("x")&&f.hasOwnProperty("y")&&!f.z&&(t||(me(t={id:RED.nodes.id(),type:"tab",disabled:!1,label:RED._("clipboard.recoveredNodes"),info:RED._("clipboard.recoveredNodesInfo"),env:[]}),RED.workspaces.add(t),i[t.id]=[]),f.z=t.id,i[t.id].push(f))}!U&&0<p.length&&(u=$("<ul>"),p.forEach(function(e){$("<li>").text(e).appendTo(u)}),u=u[0].outerHTML,RED.notify("<p>"+RED._("clipboard.importUnrecognised",{count:p.length})+"</p>"+u,"error",!1,1e4));var h=RED.workspaces.active(),V=ve(h);for(l=0;l<r.length;l++){var J=/^subflow:(.+)$/.exec(r[l].type);if(J){var g,J=J[1],q=ve(h);if(q)if(J===q.id&&(g=new Error(RED._("notification.errors.cannotAddSubflowToItself"))),g=be(J,q.id)?new Error(RED._("notification.errors.cannotAddCircularReference")):g)throw g.code="NODE_RED",g}}var m,v,b,y,W,w=[],E={},K=[],D={},H={},R={},x=[],_=[],k=[],T=[],X=new Set,C=null;for(t&&w.push(t),l=0;l<r.length;l++)"workspace"===(f=r[l]).type||"tab"===f.type?("workspace"===f.type&&(f.type="tab"),null==ae&&(ae=f),0===h&&(h=f.id),n||"copy"===o.importMap[f.id]?(m=he(),E[f.id]=m,f.id=m):E[f.id]=f.id,me(f),RED.workspaces.add(f),w.push(f)):"subflow"===f.type&&((W=o.importMap[f.id]?W:function(a,s){s=s||[];var r,d=null;return RED.nodes.eachSubflow(function(e){if(e.name==a.name&&e.info==a.info&&e.in.length==a.in.length&&e.out.length==a.out.length){var t=RED.nodes.filterNodes({z:e.id});if(t.length==s.length){var o=[a].concat(s),n=[e].concat(t),i=JSON.stringify(o),o=JSON.stringify(ye(n));for(r=0;r<t.length;r++)i=i.replace(new RegExp('"'+s[r].id+'"',"g"),'"'+t[r].id+'"');if((i=i.replace(new RegExp('"'+a.id+'"',"g"),'"'+e.id+'"'))===o)return d=e,!1}}}),d}(f,i[f.id]))?H[f.id]=W:(D[f.id]=f,!n&&"copy"!==o.importMap[f.id]||(m=he(),f.id=m),f.in.forEach(function(e,t){e.type="subflow",e.direction="in",e.z=f.id,e.i=t,e.id=he()}),f.out.forEach(function(e,t){e.type="subflow",e.direction="out",e.z=f.id,e.i=t,e.id=he()}),f.status&&(f.status.type="subflow",f.status.direction="status",f.status.z=f.id,f.status.id=he()),K.push(f),Ee(f,n||"copy"===o.importMap[f.id])));for(null==ae&&(me(ae={type:"tab",id:he(),disabled:!1,info:"",label:RED._("workspace.defaultName",{number:1}),env:[]}),RED.workspaces.add(ae),w.push(ae),h=RED.workspaces.active()),l=0;l<r.length;l++)if(f=r[l],(v=pe.getNodeType(f.type))&&"config"==v.category){var j=null;if(n||"copy"===o.importMap[f.id]){if(f.z){if(H[f.z])continue;D[f.z]?f.z=D[f.z].id:(f.z=E[f.z],de[f.z]||(M?(null===C&&(C=RED.workspaces.add(null,!0),w.push(C)),f.z=C.id):f.z=h))}if("copy"!==o.importMap[f.id]&&(j=RED.nodes.node(f.id))&&f.z&&j.z!==f.z)for(var L in j=null,re)if(re.hasOwnProperty(L)&&re[L].z===f.z&&function(e,t,o){if((!o||e.id==t.id)&&e.type==t.type){var n,i=e._def;for(n in i.defaults)if(i.defaults.hasOwnProperty(n)){var a=e[n],s=t[n];if(typeof a!=typeof s)return;if(null===a||"string"==typeof a||"number"==typeof a){if(a!==s)return}else if(JSON.stringify(a)!==JSON.stringify(s))return}return 1}}(re[L],f,!1)){j=re[L],R[f.id]=re[L];break}}else A&&f.z&&RED.workspaces.contains(f.z)||!f.z||E[f.z]||D[f.z]||(f.z=h);if(!j||j._def.exclusive){for(y in b={id:f.id,z:f.z,type:f.type,info:f.info,users:[],_config:{}},f.z||delete b.z,f.hasOwnProperty("d")&&(b.d=f.d),v.defaults)v.defaults.hasOwnProperty(y)&&(b[y]=f[y],b._config[y]=JSON.stringify(f[y]));if(v.hasOwnProperty("credentials")&&f.hasOwnProperty("credentials"))for(y in b.credentials={},v.credentials)v.credentials.hasOwnProperty(y)&&f.credentials.hasOwnProperty(y)&&(b.credentials[y]=f.credentials[y]);b.label=v.label,b._def=v,!n&&"copy"!==o.importMap[f.id]||(b.id=he()),R[f.id]=b,x.push(b)}}for(l=0;l<r.length;l++)if("workspace"!==(f=r[l]).type&&"tab"!==f.type&&"subflow"!==f.type&&(!(v=pe.getNodeType(f.type))||"config"!=v.category)){var S={x:parseFloat(f.x||0),y:parseFloat(f.y||0),z:f.z,type:0,info:f.info,changed:!1,_config:{}};if("group"!==f.type&&"junction"!==f.type&&(S.wires=f.wires||[],S.inputLabels=f.inputLabels,S.outputLabels=f.outputLabels,S.icon=f.icon),"junction"===f.type&&(S.wires=f.wires||[]),f.hasOwnProperty("l")&&(S.l=f.l),f.hasOwnProperty("d")&&(S.d=f.d),f.hasOwnProperty("g")&&(S.g=f.g),n||"copy"===o.importMap[f.id]){if(H[f.z])continue;D[S.z]?S.z=D[S.z].id:(S.z=E[S.z],de[S.z]||(M?(null===C&&(C=RED.workspaces.add(null,!0),w.push(C)),S.z=C.id):S.z=h)),S.id=he()}else S.id=f.id,A&&S.z&&RED.workspaces.contains(S.z)||null!=S.z&&(E[S.z]||D[S.z])||(M?(null===C&&(C=RED.workspaces.add(null,!0),w.push(C)),S.z=C.id):S.z=h);if(S.type=f.type,S._def=v,"group"===S.type){for(y in S._def=RED.group.def,S._def.defaults)S._def.defaults.hasOwnProperty(y)&&"inputs"!==y&&"outputs"!==y&&(S[y]=f[y],S._config[y]=JSON.stringify(f[y]));S._config.x=S.x,S._config.y=S.y}else if("subflow"===f.type.substring(0,7)){var Y=f.type.split(":")[1],Z=H[Y]||D[Y]||ve(Y);!n&&"copy"!==o.importMap[f.id]||(Y=Z.id,S.type="subflow:"+Y,S._def=pe.getNodeType(S.type),delete S.i),S.name=f.name,S.outputs=Z.out.length,S.inputs=Z.in.length,S.env=f.env}else if("junction"===f.type)S._def={defaults:{}},S._config.x=S.x,S._config.y=S.y,S.inputs=1,S.outputs=1,S.w=0,S.h=0;else{if(!S._def){S.x&&S.y?S._def={color:"#fee",defaults:{},label:"unknown: "+f.type,labelStyle:"red-ui-flow-node-label-italic",outputs:f.outputs||f.wires&&f.wires.length||0,set:pe.getNodeSet("node-red/unknown")}:(S._def={category:"config",set:pe.getNodeSet("node-red/unknown")},S.users=[],delete S.x,delete S.y,delete S.wires,delete S.inputLabels,delete S.outputLabels,f.z||delete S.z);var O,Q={};for(O in f)f.hasOwnProperty(O)&&"x"!=O&&"y"!=O&&"z"!=O&&"id"!=O&&"wires"!=O&&(Q[O]=f[O]);S._orig=Q,S.name=f.type,S.type="unknown"}if("config"!=S._def.category){for(y in f.hasOwnProperty("inputs")?(S.inputs=f.inputs,S._config.inputs=JSON.stringify(f.inputs)):S.inputs=S._def.inputs,f.hasOwnProperty("outputs")?(S.outputs=f.outputs,S._config.outputs=JSON.stringify(f.outputs)):S.outputs=S._def.outputs,S.hasOwnProperty("wires")&&S.wires.length>S.outputs&&(S._def.defaults.hasOwnProperty("outputs")&&isNaN(parseInt(f.outputs))?S.outputs=S.wires.length:(console.log("Warning: node.wires longer than node.outputs - trimming wires:",S.id," wires:",S.wires.length," outputs:",S.outputs),S.wires=S.wires.slice(0,S.outputs))),S._def.defaults)S._def.defaults.hasOwnProperty(y)&&"inputs"!==y&&"outputs"!==y&&(S[y]=f[y],S._config[y]=JSON.stringify(f[y]));if(S._config.x=S.x,S._config.y=S.y,S._def.hasOwnProperty("credentials")&&f.hasOwnProperty("credentials"))for(y in S.credentials={},S._def.credentials)S._def.credentials.hasOwnProperty(y)&&f.credentials.hasOwnProperty(y)&&(S.credentials[y]=f.credentials[y])}}"junction"===(R[f.id]=S).type?T.push(S):"unknown"===S.type||"config"!==S._def.category?x.push(S):"group"===S.type&&(k.push(S),X.add(S.id))}for(l=0;l<x.length+T.length;l++){if((f=l<x.length?x[l]:T[l-x.length]).wires){for(var I=0;I<f.wires.length;I++)for(var ee,te=Array.isArray(f.wires[I])?f.wires[I]:[f.wires[I]],N=0;N<te.length;N++)R.hasOwnProperty(te[N])&&(f.z===R[te[N]].z?(ge(ee={source:f,sourcePort:I,target:R[te[N]]}),_.push(ee)):console.log("Warning: dropping link that crosses tabs:",f.id,"->",R[te[N]].id));delete f.wires}for(var oe in f.g&&R[f.g]?f.g=R[f.g].id:delete f.g,f._def.defaults)f._def.defaults.hasOwnProperty(oe)&&f._def.defaults[oe].type&&(d=f[oe],d=(d=Array.isArray(d)?d:[d]).map(function(e){var t=R[e];return t?("config"===t._def.category&&-1===t.users.indexOf(f)&&t.users.push(f),t.id):e}),f[oe]=Array.isArray(f[oe])?d:d[0]);V&&/^link /.test(f.type)&&f.links&&(f.links=f.links.filter(function(e){e=RED.nodes.node(e);return e&&e.z===h}))}for(l=0;l<K.length;l++)(f=K[l]).in.forEach(function(t){t.wires.forEach(function(e){e={source:t,sourcePort:0,target:R[e.id]};ge(e),_.push(e)}),delete t.wires}),f.out.forEach(function(t){t.wires.forEach(function(e){e=D[e.id]&&D[e.id].id==f.id?{source:f.in[e.port],sourcePort:e.port,target:t}:{source:R[e.id]||D[e.id],sourcePort:e.port,target:t};ge(e),_.push(e)}),delete t.wires}),f.status&&(f.status.wires.forEach(function(e){e=D[e.id]&&D[e.id].id==f.id?{source:f.in[e.port],sourcePort:e.port,target:f.status}:{source:R[e.id]||D[e.id],sourcePort:e.port,target:f.status};ge(e),_.push(e)}),delete f.status.wires);var ne,ie,P={};for(l=0;l<k.length;l++)(f=k[l]).g&&!X.has(f.g)&&delete f.g,f.nodes=f.nodes.map(function(e){return R[e]}),f.nodes=f.nodes.filter(function(e){return e&&e.g!==f.id&&(e.g=f.id),!!e}),f.g||(P[f.id]=0);do{for(ne=!1,l=0;l<k.length;l++)(f=k[l]).g&&P[f.id]!==P[f.g]+1&&(P[f.id]=P[f.g]+1,ne=!0)}while(ne);for(k.sort(function(e,t){return P[e.id]-P[t.id]}),l=0;l<k.length;l++)xe(f=k[l]);for(l=0;l<T.length;l++)_e(T[l]);for(l=0;l<x.length;l++)we(S=x[l]);for(l=0;l<x.length;l++){S=x[l];RED.editor.validateNode(S)}return RED.workspaces.refresh(),t&&(ie=RED.notify(RED._("clipboard.recoveredNodesNotification",{flowName:RED._("clipboard.recoveredNodes")}),{type:"warning",fixed:!0,buttons:[{text:RED._("common.label.close"),click:function(){ie.close()}}]})),{nodes:x,links:_,groups:k,junctions:T,workspaces:w,subflows:K,missingWorkspace:C,removedNodes:z}}function C(e){for(var t in e._def.defaults){var o;!e._def.defaults.hasOwnProperty(t)||(o=e._def.defaults[t]).type&&(o=pe.getNodeType(o.type))&&"config"==o.category&&(o=re[e[t]])&&-1===o.users.indexOf(e)&&(o.users.push(e),RED.events.emit("nodes:change",o))}}function xe(e){p[e.z]=p[e.z]||[],p[e.z].push(e),ce[e.id]=e,RED.events.emit("groups:add",e)}function j(e){var t=p[e.z].indexOf(e);p[e.z].splice(t,1),0===p[e.z].length&&delete p[e.z],e.g&&ce[e.g]&&(t=ce[e.g].nodes.indexOf(e),ce[e.g].nodes.splice(t,1)),RED.group.markDirty(e),delete ce[e.id],RED.events.emit("groups:remove",e)}function _e(e){d[e.z]=d[e.z]||[],d[e.z].push(e),ue[e.id]=e,c[e.id]||(c[e.id]={in:[],out:[]}),RED.events.emit("junctions:add",e)}function L(t){var e=d[t.z].indexOf(t),e=(d[t.z].splice(e,1),0===d[t.z].length&&delete d[t.z],delete ue[t.id],delete c[t.id],RED.events.emit("junctions:remove",t),h.filter(function(e){return e.source===t||e.target===t}));return e.forEach(E),{links:e}}return{init:function(){RED.events.on("registry:node-type-added",function(t){pe.getNodeType(t);var o,n,i,a={},e=(RED.nodes.eachNode(function(e){"unknown"===e.type&&e.name===t&&(a[e.id]=e)}),RED.nodes.eachConfig(function(e){"unknown"===e.type&&e.name===t&&(a[e.id]=e)}),Object.keys(a));0<e.length&&(o=[],e.forEach(function(e){e=a[e];re.hasOwnProperty(e.id)?delete re[e.id]:fe.removeNode(e),o.push(D(e)),RED.events.emit("nodes:remove",e)}),n=[],RED.nodes.eachLink(function(e){a.hasOwnProperty(e.source.id)&&a.hasOwnProperty(e.target.id)&&n.push(e)}),n.forEach(E),RED.view.redraw(!0,!0),e=R(o,{generateIds:!1,reimport:!0}),i={},e.nodes.forEach(function(e){i[e.id]=e}),RED.nodes.eachLink(function(e){i.hasOwnProperty(e.source.id)&&(e.source=i[e.source.id]),i.hasOwnProperty(e.target.id)&&(e.target=i[e.target.id])}),RED.view.redraw(!0))})},registry:pe,setNodeList:pe.setNodeList,getNodeSet:pe.getNodeSet,addNodeSet:pe.addNodeSet,removeNodeSet:pe.removeNodeSet,enableNodeSet:pe.enableNodeSet,disableNodeSet:pe.disableNodeSet,setIconSets:pe.setIconSets,getIconSets:pe.getIconSets,registerType:pe.registerNodeType,getType:pe.getNodeType,getNodeHelp:function(e){var t="";return(e=$("script[data-help-name='"+e+"']"))&&(t=e.html(),"text/markdown"===e.attr("type")&&(t=RED.utils.renderMarkdown(t))),t},convertNode:D,add:we,remove:w,clear:function(){h=[],l={},c={},re={},u=[],ce={},p={},ue={},d={},Object.keys(le).forEach(function(e){RED.subflow.removeSubflow(e)}),Object.keys(de).forEach(function(e){RED.workspaces.remove(de[e])}),se=ae=null,de={},fe.clear(),RED.nodes.dirty(!1),RED.view.redraw(!0,!0),RED.palette.refresh(),RED.workspaces.refresh(),RED.sidebar.config.refresh(),RED.sidebar.info.refresh(),RED.events.emit("workspace:clear")},detachNodes:function(e){let o=[];if(e.forEach(e=>{var t;"group"===e.type?(t=RED.group.getNodes(e,!0,!0),o=o.concat(t)):o.push(e)}),0<o.length){const n=RED.nodes.getNodeIslands(o);let t=[],d=[],l=new Set;return n.forEach(e=>{let r=new Set(e),o=[],n=[];e.forEach(e=>{var t=RED.nodes.getNodeLinks(e,1),e=RED.nodes.getNodeLinks(e,0);t.forEach(e=>{r.has(e.source)||o.push(e)}),e.forEach(e=>{r.has(e.target)||n.push(e)})}),o.forEach(o=>{let n=o.source,t=new Set,i=new Set,a=[o.target];for(;0<a.length;){var s=a.pop(a);i.add(s);let e=RED.nodes.getNodeLinks(s,0);e.forEach(e=>{i.has(e.target)||(i.add(e.target),r.has(e.target)?a.push(e.target):t.add(e.target))})}t.forEach(e=>{var t=`${n.id}[${o.sourcePort}] -> `+e.id;l.has(t)||(l.add(t),t={source:n,sourcePort:o.sourcePort,target:e},0===RED.nodes.filterLinks(t).length&&d.push(t))})}),o.forEach(e=>{RED.nodes.removeLink(e),t.push(e)}),n.forEach(e=>{RED.nodes.removeLink(e),t.push(e)})}),d.forEach(e=>RED.nodes.addLink(e)),{newLinks:d,removedLinks:t}}},moveNodesForwards:function(e){return fe.moveNodesForwards(e)},moveNodesBackwards:function(e){return fe.moveNodesBackwards(e)},moveNodesToFront:function(e){return fe.moveNodesToFront(e)},moveNodesToBack:function(e){return fe.moveNodesToBack(e)},getNodeOrder:function(e){return fe.getNodeOrder(e)},setNodeOrder:function(e,t){fe.setNodeOrder(e,t)},moveNodeToTab:function(e,o){var t,n,i,a,s,r;"group"===e.type?(a=o,t=p[(r=e).z].indexOf(r),p[r.z].splice(t,1),p[a]=p[a]||[],p[a].push(r),r.z=a,RED.events.emit("groups:change",r)):"junction"===e.type?(n=o,a=d[(t=e).z].indexOf(t),d[t.z].splice(a,1),d[n]=d[n]||[],d[n].push(t),i=t.z,t.z=n,(a=c[t.id])&&(a.in.forEach(function(e){var t=l[i].indexOf(e);-1!=t&&l[i].splice(t,1),e.source.z===n&&l[n]&&l[n].push(e)}),a.out.forEach(function(e){var t=l[i].indexOf(e);-1!=t&&l[i].splice(t,1),e.target.z===n&&l[n]&&l[n].push(e)})),RED.events.emit("junctions:change",t)):(s=e.z,fe.moveNode(e,o),(r=c[e.id])&&(r.in.forEach(function(e){var t=l[s].indexOf(e);-1!=t&&l[s].splice(t,1),e.source.z===o&&l[o]&&l[o].push(e)}),r.out.forEach(function(e){var t=l[s].indexOf(e);-1!=t&&l[s].splice(t,1),e.target.z===o&&l[o]&&l[o].push(e)})),RED.events.emit("nodes:change",e))},addLink:ge,removeLink:E,getNodeLinks:function(e,t){return"string"!=typeof e&&(e=e.id),c[e]?[].concat(1===t?c[e].in:c[e].out):[]},addWorkspace:me,removeWorkspace:function(e){var t,o,n=de[e],i=[],a=[],s=[],r=[];if(n){for(t in delete de[e],delete l[e],u.splice(u.indexOf(e),1),fe.hasTab(e)&&(i=fe.getNodes(e).slice()),re)re.hasOwnProperty(t)&&(o=re[t]).z==e&&i.push(o);for(r=RED.nodes.junctions(e),t=0;t<i.length;t++)var d=w(i[t].id),a=a.concat(d.links);for(t=0;t<r.length;t++){d=L(r[t]);a=a.concat(d.links)}for(s=(p[e]||[]).filter(function(e){return!e.g}),t=0;t<s.length;t++)s[t].nodes.forEach(function(e){"group"===e.type&&s.push(e)});for(t=s.length-1;0<=t;t--)j(s[t]);fe.removeTab(e),RED.events.emit("flows:remove",n)}return{nodes:i,links:a,groups:s,junctions:r}},getWorkspaceOrder:function(){return u},setWorkspaceOrder:function(e){u=e},workspace:function(e){return de[e]},addSubflow:Ee,removeSubflow:function(e){le[e.id]&&(delete le[e.id],fe.removeTab(e.id),pe.removeNodeType("subflow:"+e.id),RED.events.emit("subflows:remove",e))},subflow:ve,subflowContains:be,addGroup:xe,removeGroup:j,group:function(e){return ce[e]},groups:function(e){return p[e]?p[e].slice():[]},addJunction:_e,removeJunction:L,junction:function(e){return ue[e]},junctions:function(e){return d[e]?d[e].slice():[]},eachNode:function(e){fe.eachNode(e)},eachLink:function(e){for(var t=0;t<h.length&&!1!==e(h[t]);t++);},eachConfig:function(e){for(var t in re)if(re.hasOwnProperty(t)&&!1===e(re[t]))break},eachSubflow:function(e){for(var t in le)if(le.hasOwnProperty(t)&&!1===e(le[t]))break},eachWorkspace:function(e){for(var t=0;t<u.length&&!1!==e(de[u[t]]);t++);},node:_,version:function(e){if(void 0===e)return x;x=e},originalFlow:function(e){if(void 0===e)return se;se=e},filterNodes:function(e){return fe.filterNodes(e)},filterLinks:function(e){var t,o=[],n=[],i=!1,a=e.source&&e.source.z,s=e.target&&e.target.z;(t=a||s?a!==s&&void 0===a?s:a:t)?(n=l[t]||[],i=!0):e.source&&e.source.hasOwnProperty("id")?c[e.source.id]&&(i=!0,n=n.concat(c[e.source.id].out)):e.target&&e.target.hasOwnProperty("id")&&c[e.target.id]&&(i=!0,n=n.concat(c[e.target.id].in)),i||(n=h);for(var r=0;r<n.length;r++){var d=n[r];if(e.source){if(e.source.hasOwnProperty("id")&&d.source.id!==e.source.id)continue;if(e.source.hasOwnProperty("z")&&d.source.z!==e.source.z)continue}if(e.target){if(e.target.hasOwnProperty("id")&&d.target.id!==e.target.id)continue;if(e.target.hasOwnProperty("z")&&d.target.z!==e.target.z)continue}e.hasOwnProperty("sourcePort")&&d.sourcePort!==e.sourcePort||o.push(d)}return o},import:R,identifyImportConflicts:De,getAllFlowNodes:e,getAllUpstreamNodes:function(t){return e(t,"up").filter(function(e){return e!==t})},getAllDownstreamNodes:function(t){return e(t,"down").filter(function(e){return e!==t})},getNodeIslands:function(e){var o=new Set(e),i=new Map,a=new Map,n=new Set;e.forEach((e,t)=>{i.set(e,t),a.set(t,[e]);t=RED.nodes.getNodeLinks(e,1),e=RED.nodes.getNodeLinks(e,0);t.forEach(e=>{o.has(e.source)&&n.add(e)}),e.forEach(e=>{o.has(e.target)&&n.add(e)})}),n.forEach(o=>{var n=o.source,o=o.target;if(i.get(n)!==i.get(o)){let t=i.get(n);n=i.get(o);let e=a.get(n);e.forEach(e=>{i.set(e,t),a.get(t).push(e)}),a.delete(n)}});const s=[];return a.forEach((e,t)=>{s.push(e)}),s},createExportableNodeSet:ye,createCompleteNodeSet:function(t){for(var o=[],e=0;e<u.length;e++)"tab"==de[u[e]].type&&o.push(k(de[u[e]],t));for(e in le)le.hasOwnProperty(e)&&o.push(T(le[e],t));for(e in ce)ce.hasOwnProperty(e)&&o.push(D(ce[e],t));for(e in ue)ue.hasOwnProperty(e)&&o.push(D(ue[e],t));for(e in re)re.hasOwnProperty(e)&&o.push(D(re[e],t));return RED.nodes.eachNode(function(e){o.push(D(e,t))}),o},updateConfigNodeUsers:C,id:he,dirty:function(e){if(null==e)return t;t=e,RED.events.emit("workspace:dirty",{dirty:t})}}}(),RED.nodes.fontAwesome=function(){var t={"fa-address-book-o":"","fa-address-book":"","fa-address-card-o":"","fa-address-card":"","fa-adjust":"","fa-align-center":"","fa-align-justify":"","fa-align-left":"","fa-align-right":"","fa-ambulance":"","fa-american-sign-language-interpreting":"","fa-anchor":"","fa-angle-double-down":"","fa-angle-double-left":"","fa-angle-double-right":"","fa-angle-double-up":"","fa-angle-down":"","fa-angle-left":"","fa-angle-right":"","fa-angle-up":"","fa-archive":"","fa-area-chart":"","fa-arrow-circle-down":"","fa-arrow-circle-left":"","fa-arrow-circle-o-down":"","fa-arrow-circle-o-left":"","fa-arrow-circle-o-right":"","fa-arrow-circle-o-up":"","fa-arrow-circle-right":"","fa-arrow-circle-up":"","fa-arrow-down":"","fa-arrow-left":"","fa-arrow-right":"","fa-arrow-up":"","fa-arrows-alt":"","fa-arrows-h":"","fa-arrows-v":"","fa-arrows":"","fa-asl-interpreting":"","fa-assistive-listening-systems":"","fa-asterisk":"","fa-at":"","fa-audio-description":"","fa-automobile":"","fa-backward":"","fa-balance-scale":"","fa-ban":"","fa-bank":"","fa-bar-chart-o":"","fa-bar-chart":"","fa-barcode":"","fa-bars":"","fa-bath":"","fa-bathtub":"","fa-battery-0":"","fa-battery-1":"","fa-battery-2":"","fa-battery-3":"","fa-battery-4":"","fa-battery-empty":"","fa-battery-full":"","fa-battery-half":"","fa-battery-quarter":"","fa-battery-three-quarters":"","fa-battery":"","fa-bed":"","fa-beer":"","fa-bell-o":"","fa-bell-slash-o":"","fa-bell-slash":"","fa-bell":"","fa-bicycle":"","fa-binoculars":"","fa-birthday-cake":"","fa-blind":"","fa-bold":"","fa-bolt":"","fa-bomb":"","fa-book":"","fa-bookmark-o":"","fa-bookmark":"","fa-braille":"","fa-briefcase":"","fa-bug":"","fa-building-o":"","fa-building":"","fa-bullhorn":"","fa-bullseye":"","fa-bus":"","fa-cab":"","fa-calculator":"","fa-calendar-check-o":"","fa-calendar-minus-o":"","fa-calendar-o":"","fa-calendar-plus-o":"","fa-calendar-times-o":"","fa-calendar":"","fa-camera-retro":"","fa-camera":"","fa-car":"","fa-caret-down":"","fa-caret-left":"","fa-caret-right":"","fa-caret-square-o-down":"","fa-caret-square-o-left":"","fa-caret-square-o-right":"","fa-caret-square-o-up":"","fa-caret-up":"","fa-cart-arrow-down":"","fa-cart-plus":"","fa-cc":"","fa-certificate":"","fa-chain-broken":"","fa-chain":"","fa-check-circle-o":"","fa-check-circle":"","fa-check-square-o":"","fa-check-square":"","fa-check":"","fa-chevron-circle-down":"","fa-chevron-circle-left":"","fa-chevron-circle-right":"","fa-chevron-circle-up":"","fa-chevron-down":"","fa-chevron-left":"","fa-chevron-right":"","fa-chevron-up":"","fa-child":"","fa-circle-o-notch":"","fa-circle-o":"","fa-circle-thin":"","fa-circle":"","fa-clipboard":"","fa-clock-o":"","fa-clone":"","fa-close":"","fa-cloud-download":"","fa-cloud-upload":"","fa-cloud":"","fa-cny":"","fa-code-fork":"","fa-code":"","fa-coffee":"","fa-cog":"","fa-cogs":"","fa-columns":"","fa-comment-o":"","fa-comment":"","fa-commenting-o":"","fa-commenting":"","fa-comments-o":"","fa-comments":"","fa-compass":"","fa-compress":"","fa-copy":"","fa-copyright":"","fa-creative-commons":"","fa-credit-card-alt":"","fa-credit-card":"","fa-crop":"","fa-crosshairs":"","fa-cube":"","fa-cubes":"","fa-cut":"","fa-cutlery":"","fa-dashboard":"","fa-database":"","fa-deaf":"","fa-deafness":"","fa-dedent":"","fa-desktop":"","fa-diamond":"","fa-dollar":"","fa-dot-circle-o":"","fa-download":"","fa-drivers-license-o":"","fa-drivers-license":"","fa-edit":"","fa-eject":"","fa-ellipsis-h":"","fa-ellipsis-v":"","fa-envelope-o":"","fa-envelope-open-o":"","fa-envelope-open":"","fa-envelope-square":"","fa-envelope":"","fa-eraser":"","fa-eur":"","fa-euro":"","fa-exchange":"","fa-exclamation-circle":"","fa-exclamation-triangle":"","fa-exclamation":"","fa-expand":"","fa-external-link-square":"","fa-external-link":"","fa-eye-slash":"","fa-eye":"","fa-eyedropper":"","fa-fast-backward":"","fa-fast-forward":"","fa-fax":"","fa-feed":"","fa-female":"","fa-fighter-jet":"","fa-file-archive-o":"","fa-file-audio-o":"","fa-file-code-o":"","fa-file-excel-o":"","fa-file-image-o":"","fa-file-movie-o":"","fa-file-o":"","fa-file-pdf-o":"","fa-file-photo-o":"","fa-file-picture-o":"","fa-file-powerpoint-o":"","fa-file-sound-o":"","fa-file-text-o":"","fa-file-text":"","fa-file-video-o":"","fa-file-word-o":"","fa-file-zip-o":"","fa-file":"","fa-files-o":"","fa-film":"","fa-filter":"","fa-fire-extinguisher":"","fa-fire":"","fa-flag-checkered":"","fa-flag-o":"","fa-flag":"","fa-flash":"","fa-flask":"","fa-floppy-o":"","fa-folder-o":"","fa-folder-open-o":"","fa-folder-open":"","fa-folder":"","fa-font":"","fa-forward":"","fa-frown-o":"","fa-futbol-o":"","fa-gamepad":"","fa-gavel":"","fa-gbp":"","fa-gear":"","fa-gears":"","fa-genderless":"","fa-gift":"","fa-glass":"","fa-globe":"","fa-graduation-cap":"","fa-group":"","fa-h-square":"","fa-hand-grab-o":"","fa-hand-lizard-o":"","fa-hand-o-down":"","fa-hand-o-left":"","fa-hand-o-right":"","fa-hand-o-up":"","fa-hand-paper-o":"","fa-hand-peace-o":"","fa-hand-pointer-o":"","fa-hand-rock-o":"","fa-hand-scissors-o":"","fa-hand-spock-o":"","fa-hand-stop-o":"","fa-handshake-o":"","fa-hard-of-hearing":"","fa-hashtag":"","fa-hdd-o":"","fa-header":"","fa-headphones":"","fa-heart-o":"","fa-heart":"","fa-heartbeat":"","fa-history":"","fa-home":"","fa-hospital-o":"","fa-hotel":"","fa-hourglass-1":"","fa-hourglass-2":"","fa-hourglass-3":"","fa-hourglass-end":"","fa-hourglass-half":"","fa-hourglass-o":"","fa-hourglass-start":"","fa-hourglass":"","fa-i-cursor":"","fa-id-badge":"","fa-id-card-o":"","fa-id-card":"","fa-ils":"","fa-image":"","fa-inbox":"","fa-indent":"","fa-industry":"","fa-info-circle":"","fa-info":"","fa-inr":"","fa-institution":"","fa-intersex":"","fa-italic":"","fa-jpy":"","fa-key":"","fa-keyboard-o":"","fa-krw":"","fa-language":"","fa-laptop":"","fa-leaf":"","fa-legal":"","fa-lemon-o":"","fa-level-down":"","fa-level-up":"","fa-life-bouy":"","fa-life-buoy":"","fa-life-ring":"","fa-life-saver":"","fa-lightbulb-o":"","fa-line-chart":"","fa-link":"","fa-list-alt":"","fa-list-ol":"","fa-list-ul":"","fa-list":"","fa-location-arrow":"","fa-lock":"","fa-long-arrow-down":"","fa-long-arrow-left":"","fa-long-arrow-right":"","fa-long-arrow-up":"","fa-low-vision":"","fa-magic":"","fa-magnet":"","fa-mail-forward":"","fa-mail-reply-all":"","fa-mail-reply":"","fa-male":"","fa-map-marker":"","fa-map-o":"","fa-map-pin":"","fa-map-signs":"","fa-map":"","fa-mars-double":"","fa-mars-stroke-h":"","fa-mars-stroke-v":"","fa-mars-stroke":"","fa-mars":"","fa-medkit":"","fa-meh-o":"","fa-mercury":"","fa-microchip":"","fa-microphone-slash":"","fa-microphone":"","fa-minus-circle":"","fa-minus-square-o":"","fa-minus-square":"","fa-minus":"","fa-mobile-phone":"","fa-mobile":"","fa-money":"","fa-moon-o":"","fa-mortar-board":"","fa-motorcycle":"","fa-mouse-pointer":"","fa-music":"","fa-navicon":"","fa-neuter":"","fa-newspaper-o":"","fa-object-group":"","fa-object-ungroup":"","fa-outdent":"","fa-paint-brush":"","fa-paper-plane-o":"","fa-paper-plane":"","fa-paperclip":"","fa-paragraph":"","fa-paste":"","fa-pause-circle-o":"","fa-pause-circle":"","fa-pause":"","fa-paw":"","fa-pencil-square-o":"","fa-pencil-square":"","fa-pencil":"","fa-percent":"","fa-phone-square":"","fa-phone":"","fa-photo":"","fa-picture-o":"","fa-pie-chart":"","fa-plane":"","fa-play-circle-o":"","fa-play-circle":"","fa-play":"","fa-plug":"","fa-plus-circle":"","fa-plus-square-o":"","fa-plus-square":"","fa-plus":"","fa-podcast":"","fa-power-off":"","fa-print":"","fa-puzzle-piece":"","fa-qrcode":"","fa-question-circle-o":"","fa-question-circle":"","fa-question":"","fa-quote-left":"","fa-quote-right":"","fa-random":"","fa-recycle":"","fa-refresh":"","fa-registered":"","fa-remove":"","fa-reorder":"","fa-repeat":"","fa-reply-all":"","fa-reply":"","fa-retweet":"","fa-rmb":"","fa-road":"","fa-rocket":"","fa-rotate-left":"","fa-rotate-right":"","fa-rouble":"","fa-rss-square":"","fa-rss":"","fa-rub":"","fa-ruble":"","fa-rupee":"","fa-s15":"","fa-save":"","fa-scissors":"","fa-search-minus":"","fa-search-plus":"","fa-search":"","fa-send-o":"","fa-send":"","fa-server":"","fa-share-square-o":"","fa-share-square":"","fa-share":"","fa-shekel":"","fa-sheqel":"","fa-shield":"","fa-ship":"","fa-shopping-bag":"","fa-shopping-basket":"","fa-shopping-cart":"","fa-shower":"","fa-sign-in":"","fa-sign-language":"","fa-sign-out":"","fa-signal":"","fa-signing":"","fa-sitemap":"","fa-sliders":"","fa-smile-o":"","fa-snowflake-o":"","fa-soccer-ball-o":"","fa-sort-alpha-asc":"","fa-sort-alpha-desc":"","fa-sort-amount-asc":"","fa-sort-amount-desc":"","fa-sort-asc":"","fa-sort-desc":"","fa-sort-down":"","fa-sort-numeric-asc":"","fa-sort-numeric-desc":"","fa-sort-up":"","fa-sort":"","fa-space-shuttle":"","fa-spinner":"","fa-spoon":"","fa-square-o":"","fa-square":"","fa-star-half-empty":"","fa-star-half-full":"","fa-star-half-o":"","fa-star-half":"","fa-star-o":"","fa-star":"","fa-step-backward":"","fa-step-forward":"","fa-stethoscope":"","fa-sticky-note-o":"","fa-sticky-note":"","fa-stop-circle-o":"","fa-stop-circle":"","fa-stop":"","fa-street-view":"","fa-strikethrough":"","fa-subscript":"","fa-subway":"","fa-suitcase":"","fa-sun-o":"","fa-superscript":"","fa-support":"","fa-table":"","fa-tablet":"","fa-tachometer":"","fa-tag":"","fa-tags":"","fa-tasks":"","fa-taxi":"","fa-television":"","fa-terminal":"","fa-text-height":"","fa-text-width":"","fa-th-large":"","fa-th-list":"","fa-th":"","fa-thermometer-0":"","fa-thermometer-1":"","fa-thermometer-2":"","fa-thermometer-3":"","fa-thermometer-4":"","fa-thermometer-empty":"","fa-thermometer-full":"","fa-thermometer-half":"","fa-thermometer-quarter":"","fa-thermometer-three-quarters":"","fa-thermometer":"","fa-thumb-tack":"","fa-thumbs-down":"","fa-thumbs-o-down":"","fa-thumbs-o-up":"","fa-thumbs-up":"","fa-ticket":"","fa-times-circle-o":"","fa-times-circle":"","fa-times-rectangle-o":"","fa-times-rectangle":"","fa-times":"","fa-tint":"","fa-toggle-down":"","fa-toggle-left":"","fa-toggle-off":"","fa-toggle-on":"","fa-toggle-right":"","fa-toggle-up":"","fa-trademark":"","fa-train":"","fa-transgender-alt":"","fa-transgender":"","fa-trash-o":"","fa-trash":"","fa-tree":"","fa-trophy":"","fa-truck":"","fa-try":"","fa-tty":"","fa-turkish-lira":"","fa-tv":"","fa-umbrella":"","fa-underline":"","fa-undo":"","fa-universal-access":"","fa-university":"","fa-unlink":"","fa-unlock-alt":"","fa-unlock":"","fa-unsorted":"","fa-upload":"","fa-usd":"","fa-user-circle-o":"","fa-user-circle":"","fa-user-md":"","fa-user-o":"","fa-user-plus":"","fa-user-secret":"","fa-user-times":"","fa-user":"","fa-users":"","fa-vcard-o":"","fa-vcard":"","fa-venus-double":"","fa-venus-mars":"","fa-venus":"","fa-video-camera":"","fa-volume-control-phone":"","fa-volume-down":"","fa-volume-off":"","fa-volume-up":"","fa-warning":"","fa-wheelchair-alt":"","fa-wheelchair":"","fa-wifi":"","fa-window-close-o":"","fa-window-close":"","fa-window-maximize":"","fa-window-minimize":"","fa-window-restore":"","fa-won":"","fa-wrench":"","fa-yen":""},o={"fa-500px":"","fa-adn":"","fa-amazon":"","fa-android":"","fa-angellist":"","fa-apple":"","fa-bandcamp":"","fa-behance-square":"","fa-behance":"","fa-bitbucket-square":"","fa-bitbucket":"","fa-bitcoin":"","fa-black-tie":"","fa-bluetooth-b":"","fa-bluetooth":"","fa-btc":"","fa-buysellads":"","fa-cc-amex":"","fa-cc-diners-club":"","fa-cc-discover":"","fa-cc-jcb":"","fa-cc-mastercard":"","fa-cc-paypal":"","fa-cc-stripe":"","fa-cc-visa":"","fa-chrome":"","fa-codepen":"","fa-codiepie":"","fa-connectdevelop":"","fa-contao":"","fa-css3":"","fa-dashcube":"","fa-delicious":"","fa-deviantart":"","fa-digg":"","fa-dribbble":"","fa-dropbox":"","fa-drupal":"","fa-edge":"","fa-eercast":"","fa-empire":"","fa-envira":"","fa-etsy":"","fa-expeditedssl":"","fa-fa":"","fa-facebook-f":"","fa-facebook-official":"","fa-facebook-square":"","fa-facebook":"","fa-firefox":"","fa-first-order":"","fa-flickr":"","fa-font-awesome":"","fa-fonticons":"","fa-fort-awesome":"","fa-forumbee":"","fa-foursquare":"","fa-free-code-camp":"","fa-ge":"","fa-get-pocket":"","fa-gg-circle":"","fa-gg":"","fa-git-square":"","fa-git":"","fa-github-alt":"","fa-github-square":"","fa-github":"","fa-gitlab":"","fa-gittip":"","fa-glide-g":"","fa-glide":"","fa-google-plus-circle":"","fa-google-plus-official":"","fa-google-plus-square":"","fa-google-plus":"","fa-google-wallet":"","fa-google":"","fa-gratipay":"","fa-grav":"","fa-hacker-news":"","fa-houzz":"","fa-html5":"","fa-imdb":"","fa-instagram":"","fa-internet-explorer":"","fa-ioxhost":"","fa-joomla":"","fa-jsfiddle":"","fa-lastfm-square":"","fa-lastfm":"","fa-leanpub":"","fa-linkedin-square":"","fa-linkedin":"","fa-linode":"","fa-linux":"","fa-maxcdn":"","fa-meanpath":"","fa-medium":"","fa-meetup":"","fa-mixcloud":"","fa-modx":"","fa-odnoklassniki-square":"","fa-odnoklassniki":"","fa-opencart":"","fa-openid":"","fa-opera":"","fa-optin-monster":"","fa-pagelines":"","fa-paypal":"","fa-pied-piper-alt":"","fa-pied-piper-pp":"","fa-pied-piper":"","fa-pinterest-p":"","fa-pinterest-square":"","fa-pinterest":"","fa-product-hunt":"","fa-qq":"","fa-quora":"","fa-ra":"","fa-ravelry":"","fa-rebel":"","fa-reddit-alien":"","fa-reddit-square":"","fa-reddit":"","fa-renren":"","fa-resistance":"","fa-safari":"","fa-scribd":"","fa-sellsy":"","fa-share-alt-square":"","fa-share-alt":"","fa-shirtsinbulk":"","fa-simplybuilt":"","fa-skyatlas":"","fa-skype":"","fa-slack":"","fa-slideshare":"","fa-snapchat-ghost":"","fa-snapchat-square":"","fa-snapchat":"","fa-soundcloud":"","fa-spotify":"","fa-stack-exchange":"","fa-stack-overflow":"","fa-steam-square":"","fa-steam":"","fa-stumbleupon-circle":"","fa-stumbleupon":"","fa-superpowers":"","fa-telegram":"","fa-tencent-weibo":"","fa-themeisle":"","fa-trello":"","fa-tripadvisor":"","fa-tumblr-square":"","fa-tumblr":"","fa-twitch":"","fa-twitter-square":"","fa-twitter":"","fa-usb":"","fa-viacoin":"","fa-viadeo-square":"","fa-viadeo":"","fa-vimeo-square":"","fa-vimeo":"","fa-vine":"","fa-vk":"","fa-wechat":"","fa-weibo":"","fa-weixin":"","fa-whatsapp":"","fa-wikipedia-w":"","fa-windows":"","fa-wordpress":"","fa-wpbeginner":"","fa-wpexplorer":"","fa-wpforms":"","fa-xing-square":"","fa-xing":"","fa-y-combinator-square":"","fa-y-combinator":"","fa-yahoo":"","fa-yc-square":"","fa-yc":"","fa-yelp":"","fa-yoast":"","fa-youtube-play":"","fa-youtube-square":"","fa-youtube":""},e=Object.keys(t);return{getIconUnicode:function(e){return t[e]||o[e]},getIconList:function(){return e}}}(),RED.history=function(){var t=[],o=[];function _(t){var e,o,n,i,a,s,r,d,l,c,u,p={};if(t){if("multi"==t.t)for(n={t:"multi",events:[]},e=t.events.length-1;0<=e;e--){var f=_(t.events[e]);n.events.push(f)}else if("replace"==t.t)t.complete?(n={t:"replace",config:RED.nodes.createCompleteNodeSet(),changed:{},rev:RED.nodes.version()},RED.nodes.clear(),RED.nodes.import(t.config).nodes.forEach(function(e){t.changed[e.id]&&(e.changed=!0,n.changed[e.id]=!0)}),RED.nodes.version(t.rev)):(i={},t.config.forEach(function(e){i[e.id]="replace"}),R=RED.nodes.import(t.config,{importMap:i}),n={t:"replace",config:R.removedNodes,dirty:RED.nodes.dirty()});else if("add"==t.t){if(n={t:"delete",dirty:RED.nodes.dirty()},t.nodes)for(n.nodes=[],e=0;e<t.nodes.length;e++)(a=RED.nodes.node(t.nodes[e])).z&&(p[a.z]=!0),n.nodes.push(a),RED.nodes.remove(t.nodes[e]),a.g&&-1!==(r=(s=RED.nodes.group(a.g)).nodes.indexOf(a))&&(s.nodes.splice(r,1),RED.group.markDirty(s));if(t.links)for(n.links=[],e=0;e<t.links.length;e++)n.links.push(t.links[e]),RED.nodes.removeLink(t.links[e]);if(t.junctions)for(n.junctions=[],e=0;e<t.junctions.length;e++)n.junctions.push(t.junctions[e]),RED.nodes.removeJunction(t.junctions[e]),t.junctions[e].g&&-1!==(r=(s=RED.nodes.group(t.junctions[e].g)).nodes.indexOf(t.junctions[e]))&&(s.nodes.splice(r,1),RED.group.markDirty(s));if(t.groups)for(n.groups=[],e=t.groups.length-1;0<=e;e--)p[(s=t.groups[e]).z]=!0,n.groups.unshift(s),RED.nodes.removeGroup(s);if(t.workspaces)for(n.workspaces=[],e=0;e<t.workspaces.length;e++){var h=RED.nodes.getWorkspaceOrder();t.workspaces[e]._index=h.indexOf(t.workspaces[e].id),n.workspaces.push(t.workspaces[e]),RED.nodes.removeWorkspace(t.workspaces[e].id),RED.workspaces.remove(t.workspaces[e])}if(t.subflows)for(n.subflows=[],e=0;e<t.subflows.length;e++)n.subflows.push(t.subflows[e]),RED.nodes.removeSubflow(t.subflows[e]),RED.workspaces.remove(t.subflows[e]);if(t.subflow&&(n.subflow={},t.subflow.instances&&(n.subflow.instances=[],t.subflow.instances.forEach(function(e){n.subflow.instances.push(e);var t=RED.nodes.node(e.id);t&&(t.changed=e.changed,t.dirty=!0)})),t.subflow.hasOwnProperty("changed")&&(o=RED.nodes.subflow(t.subflow.id))&&(o.changed=t.subflow.changed)),t.removedLinks)for(n.createdLinks=[],e=0;e<t.removedLinks.length;e++)n.createdLinks.push(t.removedLinks[e]),RED.nodes.addLink(t.removedLinks[e])}else if("delete"==t.t){if(n={t:"add",dirty:RED.nodes.dirty()},t.workspaces)for(n.workspaces=[],e=0;e<t.workspaces.length;e++)n.workspaces.push(t.workspaces[e]),RED.nodes.addWorkspace(t.workspaces[e],t.workspaces[e]._index),RED.workspaces.add(t.workspaces[e],void 0,t.workspaces[e]._index),delete t.workspaces[e]._index;if(t.subflows)for(n.subflows=[],e=0;e<t.subflows.length;e++)n.subflows.push(t.subflows[e]),RED.nodes.addSubflow(t.subflows[e]);if(t.subflowInputs&&0<t.subflowInputs.length&&((o=RED.nodes.subflow(t.subflowInputs[0].z)).in.push(t.subflowInputs[0]),o.in[0].dirty=!0),t.subflowOutputs&&0<t.subflowOutputs.length)for(o=RED.nodes.subflow(t.subflowOutputs[0].z),t.subflowOutputs.sort(function(e,t){return e.i-t.i}),e=0;e<t.subflowOutputs.length;e++){var g=t.subflowOutputs[e];o.out.splice(g.i,0,g);for(var m=g.i+1;m<o.out.length;m++)o.out[m].i++,o.out[m].dirty=!0;RED.nodes.eachLink(function(e){e.source.type=="subflow:"+o.id&&e.sourcePort>=g.i&&e.sourcePort++})}if(t.subflow&&(n.subflow={},t.subflow.hasOwnProperty("instances")&&(n.subflow.instances=[],t.subflow.instances.forEach(function(e){n.subflow.instances.push(e);var t=RED.nodes.node(e.id);t&&(t.changed=e.changed,t.dirty=!0)})),t.subflow.hasOwnProperty("status")&&((o=RED.nodes.subflow(t.subflow.id)).status=t.subflow.status)),o&&RED.nodes.filterNodes({type:"subflow:"+o.id}).forEach(function(e){e.inputs=o.in.length,e.outputs=o.out.length,e.resize=!0,e.dirty=!0}),t.groups){n.groups=[];var v={};for(t.groups.forEach(function(e){v[e.id]=e}),e=t.groups.length-1;0<=e;e--)RED.nodes.addGroup(t.groups[e]),p[t.groups[e].z]=!0,n.groups.unshift(t.groups[e]),t.groups[e].g&&(-1===(s=v[t.groups[e].g]||RED.nodes.group(t.groups[e].g)).nodes.indexOf(t.groups[e])&&s.nodes.push(t.groups[e]),RED.group.markDirty(t.groups[e]))}if(t.nodes)for(n.nodes=[],e=0;e<t.nodes.length;e++)RED.nodes.add(t.nodes[e]),p[t.nodes[e].z]=!0,n.nodes.push(t.nodes[e].id),t.nodes[e].g&&(-1===(s=RED.nodes.group(t.nodes[e].g)).nodes.indexOf(t.nodes[e])&&s.nodes.push(t.nodes[e]),RED.group.markDirty(s));if(t.junctions)for(n.junctions=[],e=0;e<t.junctions.length;e++)n.junctions.push(t.junctions[e]),RED.nodes.addJunction(t.junctions[e]),t.junctions[e].g&&(-1===(s=RED.nodes.group(t.junctions[e].g)).nodes.indexOf(t.junctions[e])&&s.nodes.push(t.junctions[e]),RED.group.markDirty(s));if(t.links)for(n.links=[],e=0;e<t.links.length;e++)RED.nodes.addLink(t.links[e]),n.links.push(t.links[e]);if(t.createdLinks)for(n.removedLinks=[],e=0;e<t.createdLinks.length;e++)n.removedLinks.push(t.createdLinks[e]),RED.nodes.removeLink(t.createdLinks[e]);if(t.changes)for(e in t.changes)if(t.changes.hasOwnProperty(e)){if(a=RED.nodes.node(e)){for(var b in t.changes[e])t.changes[e].hasOwnProperty(b)&&(a[b]=t.changes[e][b]);a.dirty=!0}RED.events.emit("nodes:change",a)}o&&RED.events.emit("subflows:change",o)}else if("move"==t.t){for(n={t:"move",nodes:[],dirty:RED.nodes.dirty()},e=0;e<t.nodes.length;e++){var y=t.nodes[e],w={n:y.n,ox:y.n.x,oy:y.n.y,dirty:!0,moved:y.n.moved};n.nodes.push(w),y.n.x=y.ox,y.n.y=y.oy,y.n.dirty=!0,y.n.moved=y.moved}if(t.links)for(n.removedLinks=[],e=0;e<t.links.length;e++)n.removedLinks.push(t.links[e]),RED.nodes.removeLink(t.links[e]);if(t.removedLinks)for(n.links=[],e=0;e<t.removedLinks.length;e++)n.links.push(t.removedLinks[e]),RED.nodes.addLink(t.removedLinks[e]);t.addToGroup?(RED.group.removeFromGroup(t.addToGroup,t.nodes.map(function(e){return e.n}),!1),n.removeFromGroup=t.addToGroup):t.removeFromGroup&&(RED.group.addToGroup(t.removeFromGroup,t.nodes.map(function(e){return e.n})),n.addToGroup=t.removeFromGroup)}else if("edit"==t.t){for(e in(n={t:"edit",changes:{},changed:t.node.changed,dirty:RED.nodes.dirty()}).node=t.node,t.changes)t.changes.hasOwnProperty(e)&&(n.changes[e]=t.node[e],t.node._def.defaults&&t.node._def.defaults[e]&&t.node._def.defaults[e].type&&(d=t.node[e],(d=Array.isArray(d)?d:[d]).forEach(function(e){e=RED.nodes.node(e);e&&"config"===e._def.category&&(e.users.splice(e.users.indexOf(t.node),1),RED.events.emit("nodes:change",e))}),d=t.changes[e],(d=Array.isArray(d)?d:[d]).forEach(function(e){e=RED.nodes.node(e);e&&"config"===e._def.category&&(e.users.push(t.node),RED.events.emit("nodes:change",e))})),t.node[e]=t.changes[e]);switch(t.node.type){case"tab":l="flows";break;case"group":l="groups";break;case"subflow":l="subflows";break;default:l="nodes"}if(RED.events.emit(l+=":change",t.node),"tab"===t.node.type&&t.changes.hasOwnProperty("disabled")&&($("#red-ui-tab-"+t.node.id.replace(".","-")).toggleClass("red-ui-workspace-disabled",!!t.node.disabled),$("#red-ui-workspace").toggleClass("red-ui-workspace-disabled",!!t.node.disabled)),t.subflow)n.subflow={},t.subflow.hasOwnProperty("inputCount")&&(n.subflow.inputCount=t.node.in.length,t.node.in.length>t.subflow.inputCount?(n.subflow.inputs=t.node.in.slice(t.subflow.inputCount),t.node.in.splice(t.subflow.inputCount)):0<t.subflow.inputs.length&&(t.node.in=t.node.in.concat(t.subflow.inputs))),t.subflow.hasOwnProperty("outputCount")&&(n.subflow.outputCount=t.node.out.length,t.node.out.length>t.subflow.outputCount?(n.subflow.outputs=t.node.out.slice(t.subflow.outputCount),t.node.out.splice(t.subflow.outputCount)):0<t.subflow.outputs.length&&(t.node.out=t.node.out.concat(t.subflow.outputs))),t.subflow.hasOwnProperty("instances")&&(n.subflow.instances=[],t.subflow.instances.forEach(function(e){n.subflow.instances.push(e);var t=RED.nodes.node(e.id);t&&(t.changed=e.changed,t.dirty=!0)})),t.subflow.hasOwnProperty("status")&&t.subflow.status&&delete t.node.status,RED.editor.validateNode(t.node),RED.nodes.filterNodes({type:"subflow:"+t.node.id}).forEach(function(e){e.inputs=t.node.in.length,e.outputs=t.node.out.length,RED.editor.updateNodeProperties(e),RED.editor.validateNode(e)});else{if(t.outputMap)for(var E in c={},n.outputMap={},t.outputMap)t.outputMap.hasOwnProperty(E)&&"-1"!==t.outputMap[E]&&(c[t.outputMap[E]]=E,n.outputMap[t.outputMap[E]]=E);t.node.__outputs=n.changes.outputs,RED.editor.updateNodeProperties(t.node,c),RED.editor.validateNode(t.node)}if(t.links)for(n.createdLinks=[],e=0;e<t.links.length;e++)RED.nodes.addLink(t.links[e]),n.createdLinks.push(t.links[e]);if(t.createdLinks)for(n.links=[],e=0;e<t.createdLinks.length;e++)RED.nodes.removeLink(t.createdLinks[e]),n.links.push(t.createdLinks[e]);t.node.dirty=!0,t.node.changed=t.changed}else if("createSubflow"==t.t){if(n={t:"deleteSubflow",activeWorkspace:t.activeWorkspace,dirty:RED.nodes.dirty()},t.nodes){n.movedNodes=[];var D=t.activeWorkspace,R=RED.nodes.filterNodes({z:t.subflow.subflow.id});for((R=(R=R.concat(RED.nodes.groups(t.subflow.subflow.id))).concat(RED.nodes.junctions(t.subflow.subflow.id))).forEach(function(e){e.x+=t.subflow.offsetX,e.y+=t.subflow.offsetY,e.dirty=!0,n.movedNodes.push(e.id),RED.nodes.moveNodeToTab(e,D)}),n.subflows=[],e=0;e<t.nodes.length;e++)n.subflows.push((u=t.nodes[e],RED.nodes.node(u)||RED.nodes.junction(u))),RED.nodes.remove(t.nodes[e])}if(t.links)for(n.links=[],e=0;e<t.links.length;e++)n.links.push(t.links[e]),RED.nodes.removeLink(t.links[e]);if(n.subflow=t.subflow,RED.nodes.removeSubflow(t.subflow.subflow),RED.workspaces.remove(t.subflow.subflow),t.removedLinks)for(n.createdLinks=[],e=0;e<t.removedLinks.length;e++)n.createdLinks.push(t.removedLinks[e]),RED.nodes.addLink(t.removedLinks[e])}else if("deleteSubflow"==t.t){if(n={t:"createSubflow",activeWorkspace:t.activeWorkspace,dirty:RED.nodes.dirty()},t.subflow&&(RED.nodes.addSubflow(t.subflow.subflow),n.subflow=t.subflow,t.subflow.subflow.g&&RED.group.addToGroup(RED.nodes.group(t.subflow.subflow.g),t.subflow.subflow)),t.subflows)for(n.nodes=[],e=0;e<t.subflows.length;e++)RED.nodes.add(t.subflows[e]),n.nodes.push(t.subflows[e].id);if(t.movedNodes&&t.movedNodes.forEach(function(e){(nn=(nn=RED.nodes.node(e))||RED.nodes.group(e)).x-=t.subflow.offsetX,nn.y-=t.subflow.offsetY,nn.dirty=!0,RED.nodes.moveNodeToTab(nn,t.subflow.subflow.id)}),t.links)for(n.links=[],e=0;e<t.links.length;e++)n.links.push(t.links[e]),RED.nodes.addLink(t.links[e]);if(t.createdLinks)for(n.removedLinks=[],e=0;e<t.createdLinks.length;e++)n.removedLinks.push(t.createdLinks[e]),RED.nodes.removeLink(t.createdLinks[e])}else if("reorder"==t.t)n={t:"reorder",dirty:RED.nodes.dirty()},t.workspaces&&(n.workspaces={from:t.workspaces.to,to:t.workspaces.from},RED.workspaces.order(t.workspaces.from)),t.nodes&&(n.nodes={z:t.nodes.z,from:t.nodes.to,to:t.nodes.from},RED.nodes.setNodeOrder(t.nodes.z,t.nodes.from));else if("createGroup"==t.t){if(n={t:"ungroup",dirty:RED.nodes.dirty(),groups:[]},t.groups)for(e=0;e<t.groups.length;e++)n.groups.push(t.groups[e]),RED.group.ungroup(t.groups[e])}else if("ungroup"==t.t){if(n={t:"createGroup",dirty:RED.nodes.dirty(),groups:[]},t.groups)for(e=0;e<t.groups.length;e++){n.groups.push(t.groups[e]);var x=t.groups[e].nodes.slice();t.groups[e].nodes=[],RED.nodes.addGroup(t.groups[e]),RED.group.addToGroup(t.groups[e],x)}}else"addToGroup"==t.t?(n={t:"removeFromGroup",dirty:RED.nodes.dirty(),group:t.group,nodes:t.nodes,reparent:t.reparent},t.nodes&&RED.group.removeFromGroup(t.group,t.nodes,!t.hasOwnProperty("reparent")||void 0===t.hasOwnProperty("reparent")||t.reparent)):"removeFromGroup"==t.t&&(n={t:"addToGroup",dirty:RED.nodes.dirty(),group:t.group,nodes:t.nodes,reparent:t.reparent},t.nodes&&RED.group.addToGroup(t.group,t.nodes));return t.callback&&"function"==typeof t.callback&&(n.callback=t.callback,t.callback(t)),Object.keys(p).forEach(function(e){e=RED.nodes.subflow(e);e&&RED.editor.validateNode(e)}),RED.nodes.dirty(t.dirty),RED.view.updateActive(),RED.view.select(null),RED.workspaces.refresh(),RED.sidebar.config.refresh(),RED.subflow.refresh(),n}}return{markAllDirty:function(){for(var e=0;e<t.length;e++)t[e].dirty=!0},list:function(){return t},listRedo:function(){return o},depth:function(){return t.length},push:function(e){t.push(e),o=[],RED.menu.setDisabled("menu-item-edit-undo",!1),RED.menu.setDisabled("menu-item-edit-redo",!0)},pop:function(){var e=_(t.pop());e&&o.push(e),RED.menu.setDisabled("menu-item-edit-undo",0===t.length),RED.menu.setDisabled("menu-item-edit-redo",0===o.length)},peek:function(){return t[t.length-1]},replace:function(e){0===t.length?RED.history.push(e):t[t.length-1]=e},clear:function(){t=[],o=[],RED.menu.setDisabled("menu-item-edit-undo",!0),RED.menu.setDisabled("menu-item-edit-redo",!0)},redo:function(){var e=o.pop();e&&(e=_(e))&&t.push(e),RED.menu.setDisabled("menu-item-edit-undo",0===t.length),RED.menu.setDisabled("menu-item-edit-redo",0===o.length)}}}(),RED.validators={number:function(o,e){return function(e,t){return!((!o||""!==e&&void 0!==e)&&(""===e||isNaN(e)))||(t&&t.label?RED._("validator.errors.invalid-num-prop",{prop:t.label}):!!t&&RED._("validator.errors.invalid-num"))}},regex:function(o,e){return function(e,t){return!!o.test(e)||(t&&t.label?RED._("validator.errors.invalid-regex-prop",{prop:t.label}):!!t&&RED._("validator.errors.invalid-regexp"))}},typedInput:function(n,i,e){return function(e,t){var o=$("#node-"+(i?"config-":"")+"input-"+n).val()||this[n];if("json"===o)try{JSON.parse(e)}catch(e){return t&&t.label?RED._("validator.errors.invalid-json-prop",{error:e.message,prop:t.label}):!!t&&RED._("validator.errors.invalid-json",{error:e.message})}else{if("msg"===o||"flow"===o||"global"===o)return!!RED.utils.validatePropertyExpression(e)||(t&&t.label?RED._("validator.errors.invalid-prop-prop",{prop:t.label}):!!t&&RED._("validator.errors.invalid-prop"));if("num"===o)return!!/^[+-]?[0-9]*\.?[0-9]*([eE][-+]?[0-9]+)?$/.test(e)||(t&&t.label?RED._("validator.errors.invalid-num-prop",{prop:t.label}):!!t&&RED._("validator.errors.invalid-num"))}return!0}}},RED.utils=function(){window._marked=window.marked,window.marked=function(e){return console.warn("Use of 'marked()' is deprecated. Use RED.utils.renderMarkdown() instead"),t(e)};const e=new window._marked.Renderer;function t(e){e=_marked.parse(e);return DOMPurify.sanitize(e,{SAFE_FOR_JQUERY:!0})}function B(e){return e.replace(/\r?\n/g,"&crarr;").replace(/\t/g,"&rarr;")}function G(e){return e.replace(/&/g,"&amp;").replace(/</g,"&lt;").replace(/>/g,"&gt;")}function F(e){var t;return Array.isArray(e)?$('<span class="red-ui-debug-msg-object-value red-ui-debug-msg-type-meta"></span>').text("array["+e.length+"]"):null===e?$('<span class="red-ui-debug-msg-object-value red-ui-debug-msg-type-null">null</span>'):"object"==typeof e?e.hasOwnProperty("type")&&"undefined"===e.type?$('<span class="red-ui-debug-msg-object-value red-ui-debug-msg-type-null">undefined</span>'):e.hasOwnProperty("type")&&"Buffer"===e.type&&e.hasOwnProperty("data")?$('<span class="red-ui-debug-msg-object-value red-ui-debug-msg-type-meta"></span>').text("buffer["+e.length+"]"):e.hasOwnProperty("type")&&"array"===e.type&&e.hasOwnProperty("data")?$('<span class="red-ui-debug-msg-object-value red-ui-debug-msg-type-meta"></span>').text("array["+e.length+"]"):e.hasOwnProperty("type")&&"set"===e.type&&e.hasOwnProperty("data")?$('<span class="red-ui-debug-msg-object-value red-ui-debug-msg-type-meta"></span>').text("set["+e.length+"]"):e.hasOwnProperty("type")&&"map"===e.type&&e.hasOwnProperty("data")?$('<span class="red-ui-debug-msg-object-value red-ui-debug-msg-type-meta"></span>').text("map"):e.hasOwnProperty("type")&&"function"===e.type?$('<span class="red-ui-debug-msg-object-value red-ui-debug-msg-type-meta"></span>').text("function"):!e.hasOwnProperty("type")||"number"!==e.type&&"bigint"!==e.type?e.hasOwnProperty("type")&&"regexp"===e.type?$('<span class="red-ui-debug-msg-object-value red-ui-debug-msg-type-string"></span>').text(e.data):$('<span class="red-ui-debug-msg-object-value red-ui-debug-msg-type-meta">object</span>'):$('<span class="red-ui-debug-msg-object-value red-ui-debug-msg-type-number"></span>').text(e.data):"string"==typeof e?(t=30<e.length?G(e.substring(0,30))+"&hellip;":G(e),$('<span class="red-ui-debug-msg-object-value red-ui-debug-msg-type-string"></span>').html('"'+B(t)+'"')):("number"==typeof e?$('<span class="red-ui-debug-msg-object-value red-ui-debug-msg-type-number"></span>'):$('<span class="red-ui-debug-msg-object-value red-ui-debug-msg-type-other"></span>')).text(""+e)}function U(o,n,i,e){o.addClass("red-ui-debug-msg-expandable"),o.prop("toggle",function(){return function(e){var t=o.parent();if(t.hasClass("collapsed")){if(e)return n&&!t.hasClass("built")&&(n(),t.addClass("built")),t.removeClass("collapsed"),!0}else if(!e)return t.addClass("collapsed"),!0;return!1}}),o.on("click",function(e){var t=!$(this).parent().hasClass("collapsed");$(this).prop("toggle")(!t)&&i&&i(!t),e.preventDefault()}),e&&o.trigger("click")}e.list=function(e,t,o){return/dl.*?class.*?message-properties.*/.test(e)&&t?'<ol class="node-ports">'+e+"</ol>":t?"<ol>"+e+"</ol>":"<ul>"+e+"</ul>"},window._marked.setOptions({renderer:e,gfm:!0,tables:!0,breaks:!1,pedantic:!1,smartLists:!0,smartypants:!1}),window._marked.use({extensions:[{name:"descriptionList",level:"block",start(e){if(!e)return null;e=e.match(/:[^:\n]/g);return e&&e.index},tokenizer(e,t){if(!e)return null;const o=/^(?::[^:\n]+:[^:\n]*(?:\n|$))+/.exec(e);return o?{type:"descriptionList",raw:o[0],text:o[0].trim(),tokens:this.lexer.inlineTokens(o[0].trim())}:void 0},renderer(e){return`<dl class="message-properties">${this.parser.parseInline(e.tokens)} +</dl>`}},{name:"description",level:"inline",start(e){if(!e)return null;e=e.match(/:/g);return e&&e.index},tokenizer(e,t){if(!e)return null;const o=/^:([^:\n]+)\(([^:\n]+)\).*?:([^:\n]*)(?:\n|$)/.exec(e);return o?{type:"description",raw:o[0],dt:this.lexer.inlineTokens(o[1].trim()),types:this.lexer.inlineTokens(o[2].trim()),dd:this.lexer.inlineTokens(o[3].trim())}:void 0},renderer(e){return` +<dt>${this.parser.parseInline(e.dt)}<span class="property-type">${this.parser.parseInline(e.types)}</span></dt><dd>${this.parser.parseInline(e.dd)}</dd>`},childTokens:["dt","dd"],walkTokens(e){"strong"===e.type&&(e.text+=" walked")}}]});var V={},r={};function J(e,t,o,n){if(t&&0<t.length){if(""===e&&void 0===o)return!0;for(var i=0;i<t.length;i++){var a=t[i];if(0===a.indexOf(e)&&("."===a[e.length]||"["===a[e.length])){if(void 0===o||"["!==a[e.length])return!0;var a=a.substring(e.length),a=/\[(\d+)\]/.exec(a);if(a)return o<=(a=parseInt(a[1]))&&a<=n}}}return!1}function q(e,t,o,n,i,a){var s=r[o]&&r[o][n]&&r[o][n].number||a||"dec";i?(s="dec"===s?13===t.toString().length&&t<=2147483647e3?"dateMS":10===t.toString().length&&t<=2147483647?"dateS":"hex":"dateMS"===s||"dateS"==s?13===t.toString().length&&t<=2147483647e3?"dateML":10===t.toString().length&&t<=2147483647?"dateL":"hex":"dateML"===s||"dateL"==s?"hex":"dec",r[o]=r[o]||{},r[o][n]=r[o][n]||{},r[o][n].number=s):void 0!==a&&(r[o]=r[o]||{},r[o][n]=r[o][n]||{},r[o][n].number=s),"dec"===s?e.text(""+t):"dateMS"===s?e.text(new Date(t).toISOString()):"dateS"===s?e.text(new Date(1e3*t).toISOString()):"dateML"===s?(i=new Date(t),e.text(i.toLocaleString()+" [UTC"+(i.getTimezoneOffset()/-60<=0?"":"+")+i.getTimezoneOffset()/-60+"]")):"dateL"===s?(a=new Date(1e3*t),e.text(a.toLocaleString()+" [UTC"+(a.getTimezoneOffset()/-60<=0?"":"+")+a.getTimezoneOffset()/-60+"]")):"hex"===s&&e.text("0x"+t.toString(16))}function W(e,t,o,n,i){var a=r[o]&&r[o][n]&&r[o][n].buffer||"raw";i&&(a="raw"===a?"string":"raw",r[o]=r[o]||{},r[o][n]=r[o][n]||{},r[o][n].buffer=a),"raw"===a?(t.text("raw"),e.removeClass("red-ui-debug-msg-buffer-string").addClass("red-ui-debug-msg-buffer-raw")):"string"===a&&(t.text("string"),e.addClass("red-ui-debug-msg-buffer-string").removeClass("red-ui-debug-msg-buffer-raw"))}function g(e,t){t=new Error(t);return t.code=e,t}function K(e,t){var o=e.length;if(0===o)throw g("INVALID_EXPR","Invalid property expression: zero-length");for(var n,i,a=[],s=0,r=!1,d=!1,l=0;l<o;l++){var c=e[l];if(r){if(c===n){if(l-s==0)throw g("INVALID_EXPR","Invalid property expression: zero-length string at position "+s);if(a.push(e.substring(s,l)),d&&!/\]/.test(e[l+1]))throw g("INVALID_EXPR","Invalid property expression: unexpected array expression at position "+s);if(!d&&l+1!==o&&!/[\[\.]/.test(e[l+1]))throw g("INVALID_EXPR","Invalid property expression: unexpected "+e[l+1]+" expression at position "+(l+1));s=l+1,r=!1}}else if("'"===c||'"'===c){if(l!=s)throw g("INVALID_EXPR","Invalid property expression: unexpected "+c+" at position "+l);r=!0,n=c,s=l+1}else if("."===c){if(0===l)throw g("INVALID_EXPR","Invalid property expression: unexpected . at position 0");if(s!=l&&(i=e.substring(s,l),/^\d+$/.test(i)?a.push(parseInt(i)):a.push(i)),l===o-1)throw g("INVALID_EXPR","Invalid property expression: unterminated expression");if(!/[a-z0-9\$\_]/i.test(e[l+1]))throw g("INVALID_EXPR","Invalid property expression: unexpected "+e[l+1]+" at position "+(l+1));s=l+1}else if("["===c){if(0===l)throw g("INVALID_EXPR","Invalid property expression: unexpected "+c+" at position "+l);if(s!=l&&a.push(e.substring(s,l)),l===o-1)throw g("INVALID_EXPR","Invalid property expression: unterminated expression");if(/^msg[.\[]/.test(e.substring(l+1))){for(var u,p=1,f=!1,h=l+1;h<o;h++)if(/["']/.test(e[h])&&(f?e[h]===u&&(f=!1):(f=!0,u=e[h])),"["===e[h]?p++:"]"===e[h]&&p--,0===p)try{t?a.push(H(t,e.substring(l+1,h))):a.push(K(e.substring(l+1,h),t)),d=!1,s=(l=h)+1;break}catch(e){throw g("INVALID_EXPR","Invalid expression started at position "+(l+1))}if(0<p)throw g("INVALID_EXPR","Invalid property expression: unmatched '[' at position "+l)}else{if(!/["'\d]/.test(e[l+1]))throw g("INVALID_EXPR","Invalid property expression: unexpected "+e[l+1]+" at position "+(l+1));s=l+1,d=!0}}else if("]"===c){if(!d)throw g("INVALID_EXPR","Invalid property expression: unexpected "+c+" at position "+l);if(s!=l){if(i=e.substring(s,l),!/^\d+$/.test(i))throw g("INVALID_EXPR","Invalid property expression: unexpected array expression at position "+s);a.push(parseInt(i))}s=l+1,d=!1}else if(" "===c)throw g("INVALID_EXPR","Invalid property expression: unexpected ' ' at position "+l)}if(d||r)throw new g("INVALID_EXPR","Invalid property expression: unterminated expression");return s<o&&a.push(e.substring(s)),a}function H(e,t){var o=null,t="string"==typeof t?K(t=0===t.indexOf("msg.")?t.substring(4):t):t;return t.reduce(function(e,t){return o=void 0===(o=void 0!==e[t]?e[t]:void 0)&&e.hasOwnProperty("type")&&e.hasOwnProperty("data")&&e.hasOwnProperty("length")?void 0!==e.data[t]?e.data[t]:void 0:o},e),o}function a(e){var t,o={module:"",file:""};return e&&(0===e.indexOf(RED.settings.apiRootUrl+"icons/")&&(e=e.substring((RED.settings.apiRootUrl+"icons/").length)),(t=/^((?:@[^/]+\/)?[^/]+)\/(.*)$/.exec(e))?(o.module=t[1],o.file=t[2]):o.file=e),o}function n(t,e){var o;if(t=t||{},e&&"subflow"===e.type)o="node-red/subflow.svg";else if("function"==typeof t.icon)try{o=t.icon.call(e)}catch(e){console.log("Definition error: "+t.type+".icon",e),o="arrow-in.svg"}else o=t.icon;e=a(o);return e.module||(t.set?e.module=t.set.module:e.module="node-red"),e}function i(e){var t=RED.nodes.getIconSets()[e.module];return!(!t||-1===t.indexOf(e.file))}var d={};function l(e){if(/^#[a-f0-9]{6}$/i.test(e))t=parseInt(e.substring(1,3),16),o=parseInt(e.substring(3,5),16),n=parseInt(e.substring(5,7),16);else{if(!/^#[a-f0-9]{3}$/i.test(e))return e;t=parseInt(e.substring(1,2)+e.substring(1,2),16),o=parseInt(e.substring(2,3)+e.substring(2,3),16),n=parseInt(e.substring(3,4)+e.substring(3,4),16)}var t,o,n,e=(((t=Math.max(0,t-50))<<16)+((o=Math.max(0,o-50))<<8)+(n=Math.max(0,n-50))).toString(16);return"#"+"000000".slice(0,6-e.length)+e}function s(e,t,o){for(var n=0;n<o.length;n++){var i=o[n];if(i.module.test(e))return i}}return{createObjectElement:function r(t,e){var o,n,i,d,a,s,l,c,u,p,A,f=(e=e||{}).key,h=e.typeHint,M=e.hideKey,g=e.path,m=e.sourceId,v=e.rootPath,b=e.expandPaths,y=e.ontoggle,w=e.exposeApi,e=e.tools,E={},D=(void 0!==g&&void 0!==v&&(d=g.substring(v.length+("."===g[v.length]?1:0))),$('<span class="red-ui-debug-msg-element"></span>'));if(D.collapse=function(){D.find(".red-ui-debug-msg-expandable").parent().addClass("collapsed")},n=$('<span class="red-ui-debug-msg-row"></span>').appendTo(D),m&&(a=n,s=m,l=g,c=t,u=d,V.hasOwnProperty(s)||(V[s]={}),k=$('<span class="red-ui-debug-msg-tools"></span>').appendTo(a),_=$('<span class="red-ui-debug-msg-tools-copy button-group"></span>').appendTo(k),l&&(p=$('<button class="red-ui-button red-ui-button-small"><i class="fa fa-terminal"></i></button>').appendTo(_).on("click",function(e){e.preventDefault(),e.stopPropagation(),RED.clipboard.copyText(l,p,"clipboard.copyMessagePath")}),RED.popover.tooltip(p,RED._("node-red:debug.sidebar.copyPath"))),A=$('<button class="red-ui-button red-ui-button-small"><i class="fa fa-clipboard"></i></button>').appendTo(_).on("click",function(e){e.preventDefault(),e.stopPropagation(),RED.clipboard.copyText(c,A,"clipboard.copyMessageValue")}),RED.popover.tooltip(A,RED._("node-red:debug.sidebar.copyPayload")),void 0!==u&&""!==u&&(_=V[s].hasOwnProperty(u),x=$('<button class="red-ui-button red-ui-button-small red-ui-debug-msg-tools-pin"><i class="fa fa-map-pin"></i></button>').appendTo(k).on("click",function(e){e.preventDefault(),e.stopPropagation(),V[s].hasOwnProperty(u)?(delete V[s][u],$(this).removeClass("selected"),a.removeClass("red-ui-debug-msg-row-pinned")):(e="$"+("["===u[0]?"":".")+u,V[s][u]=K(e),$(this).addClass("selected"),a.addClass("red-ui-debug-msg-row-pinned"))}).toggleClass("selected",_),a.toggleClass("red-ui-debug-msg-row-pinned",_),RED.popover.tooltip(x,RED._("node-red:debug.sidebar.pinPath"))),e&&(_="function"==typeof(_=e)?_(l,c):_)&&(_.addClass("red-ui-debug-msg-tools-other"),_.appendTo(k))),f)M||($('<span class="red-ui-debug-msg-object-key"></span>').text(f).appendTo(n),$("<span>: </span>").appendTo(n));else if(D.addClass("red-ui-debug-msg-top-level"),m){var R=V[m],b=[];if(R){for(var z in R)if(R.hasOwnProperty(z))try{void 0!==H({$:t},R[z])&&b.push(z)}catch(e){}b.sort()}D.clearPinned=function(){D.find(".red-ui-debug-msg-row-pinned").removeClass("red-ui-debug-msg-row-pinned"),V[m]={}}}var x=$('<span class="red-ui-debug-msg-object-value"></span>').appendTo(n),e=Array.isArray(t),_=!1;if(t&&"object"==typeof t&&t.hasOwnProperty("type")&&t.hasOwnProperty("data")&&(t.__enc__&&"set"===t.type||t.__enc__&&"array"===t.type||"Buffer"===t.type)&&(_=e=!0),null==t)$('<span class="red-ui-debug-msg-type-null">'+t+"</span>").appendTo(x);else if(t.__enc__&&"undefined"===t.type)$('<span class="red-ui-debug-msg-type-null">undefined</span>').appendTo(x);else if(!t.__enc__||"number"!==t.type&&"bigint"!==t.type)if("regexp"===h||t.__enc__&&"regexp"===t.type)o=$('<span class="red-ui-debug-msg-type-string red-ui-debug-msg-object-header"></span>').text("string"==typeof t?t:t.data).appendTo(x);else if("function"===h||t.__enc__&&"function"===t.type)o=$('<span class="red-ui-debug-msg-type-meta red-ui-debug-msg-object-header"></span>').text("function").appendTo(x);else if("internal"===h||t.__enc__&&"internal"===t.type)o=$('<span class="red-ui-debug-msg-type-meta red-ui-debug-msg-object-header"></span>').text("[internal]").appendTo(x);else if("string"==typeof t)/[\t\n\r]/.test(t)&&(D.addClass("collapsed"),$('<i class="fa fa-caret-right red-ui-debug-msg-object-handle"></i> ').prependTo(n),U(n,function(){$('<span class="red-ui-debug-msg-type-meta red-ui-debug-msg-object-type-header"></span>').text(h||"string").appendTo(n);var e=$('<div class="red-ui-debug-msg-object-entry collapsed"></div>').appendTo(D);$('<pre class="red-ui-debug-msg-type-string"></pre>').text(t).appendTo(e)},function(e){y&&y(g,e)},J(d,b))),o=$('<span class="red-ui-debug-msg-type-string red-ui-debug-msg-object-header"></span>').html('"'+B(G(t))+'"').appendTo(x),/^#[0-9a-f]{6}$/i.test(t)&&$('<span class="red-ui-debug-msg-type-string-swatch"></span>').css("backgroundColor",t).appendTo(o);else if("number"==typeof t)o=$('<span class="red-ui-debug-msg-type-number"></span>').appendTo(x),Number.isInteger(t)&&0<=t&&(o.addClass("red-ui-debug-msg-type-number-toggle"),o.on("click",function(e){e.preventDefault(),q($(this),t,m,g,!0)})),q(o,t,m,g,!1,"hex"===h?"hex":void 0);else if(e){D.addClass("collapsed");var k,T,C=t.length,j=(h&&(k=/\[(\d+)\]/.exec(h))&&(C=parseInt(k[1])),t),L="array",S=(_?(j=t.data,void 0===C&&(C=j.length),j.__enc__&&(j=j.data),L=t.type.toLowerCase()):/buffer/.test(h)&&(L="buffer"),j.length);if(0<C&&($('<i class="fa fa-caret-right red-ui-debug-msg-object-handle"></i> ').prependTo(n),T=$('<div class="red-ui-debug-msg-array-rows"></div>').appendTo(D),D.addClass("red-ui-debug-msg-buffer-raw")),f)i=$('<span class="red-ui-debug-msg-type-meta"></span>').text(h||L+"["+C+"]").appendTo(x);else{i=$('<span class="red-ui-debug-msg-object-header"></span>').appendTo(x),$("<span>[ </span>").appendTo(i);for(var O=Math.min(C,10),I=0;I<O;I++)F(j[I]).appendTo(i),I<O-1&&$("<span>, </span>").appendTo(i);O<C&&$("<span> &hellip;</span>").appendTo(i),0===O&&$('<span class="red-ui-debug-msg-type-meta">empty</span>').appendTo(i),$("<span> ]</span>").appendTo(i)}0<C&&U(n,function(){if(f||(i=$('<span class="red-ui-debug-msg-type-meta red-ui-debug-msg-object-type-header"></span>').text(h||L+"["+C+"]").appendTo(n)),"buffer"===L){var e=$('<div class="red-ui-debug-msg-string-rows"></div>').appendTo(D),e=$('<div class="red-ui-debug-msg-object-entry collapsed"></div>').appendTo(e),t="";try{t=String.fromCharCode.apply(null,new Uint16Array(j))}catch(e){console.log(e)}$('<pre class="red-ui-debug-msg-type-string"></pre>').text(t).appendTo(e),t=$('<span class="red-ui-debug-msg-buffer-opts"></span>').appendTo(i),e=$('<a class="red-ui-button red-ui-button-small" href="#"></a>').text("raw").appendTo(t).on("click",function(e){e.preventDefault(),e.stopPropagation(),W(D,$(this),m,g,!0)}),W(D,e,m,g,!1)}if(S<=10)for(I=0;I<S;I++)s=$('<div class="red-ui-debug-msg-object-entry collapsed"></div>').appendTo(T),E[g+"["+I+"]"]=r(j[I],{key:""+I,typeHint:"buffer"===L&&"hex",hideKey:!1,path:g+"["+I+"]",sourceId:m,rootPath:v,expandPaths:b,ontoggle:y,exposeApi:w}).appendTo(s);else{for(I=0;I<S;I+=10){var a=I,s=$('<div class="red-ui-debug-msg-object-entry collapsed"></div>').appendTo(T);n=$("<span></span>").appendTo(s),$('<i class="fa fa-caret-right red-ui-debug-msg-object-handle"></i> ').appendTo(n),U(n,function(){var o=a,n=Math.min(S-1,a+9),i=s;return function(){for(var e=o;e<=n;e++){var t=$('<div class="red-ui-debug-msg-object-entry collapsed"></div>').appendTo(i);E[g+"["+e+"]"]=r(j[e],{key:""+e,typeHint:"buffer"===L&&"hex",hideKey:!1,path:g+"["+e+"]",sourceId:m,rootPath:v,expandPaths:b,ontoggle:y,exposeApi:w}).appendTo(t)}}}(),function(){var t=void 0+"["+I+"]";return function(e){y&&y(t,e)}}(),J(d,b,a,Math.min(S-1,a+9))),$('<span class="red-ui-debug-msg-object-key"></span>').html("["+a+" &hellip; "+Math.min(S-1,a+9)+"]").appendTo(n)}S<C&&$('<div class="red-ui-debug-msg-object-entry collapsed"><span class="red-ui-debug-msg-object-key">['+S+" &hellip; "+C+"]</span></div>").appendTo(T)}},function(e){y&&y(g,e)},J(d,b))}else if("object"==typeof t){D.addClass("collapsed");var L="object",N=((j=t).__enc__&&(j=j.data,L=t.type.toLowerCase()),Object.keys(j));if((f||0<N.length)&&($('<i class="fa fa-caret-right red-ui-debug-msg-object-handle"></i> ').prependTo(n),U(n,function(){for(f||$('<span class="red-ui-debug-msg-type-meta red-ui-debug-msg-object-type-header"></span>').text(L).appendTo(n),I=0;I<N.length;I++){var e=$('<div class="red-ui-debug-msg-object-entry collapsed"></div>').appendTo(D),t=g;void 0!==t&&(/^[a-zA-Z_$][0-9a-zA-Z_$]*$/.test(N[I])?t+=(0<t.length?".":"")+N[I]:t+='["'+N[I].replace(/"/,'\\"')+'"]'),E[t]=r(j[N[I]],{key:N[I],typeHint:!1,hideKey:!1,path:t,sourceId:m,rootPath:v,expandPaths:b,ontoggle:y,exposeApi:w}).appendTo(e)}0===N.length&&$('<div class="red-ui-debug-msg-object-entry red-ui-debug-msg-type-meta collapsed"></div>').text("empty").appendTo(D)},function(e){y&&y(g,e)},J(d,b))),f)$('<span class="red-ui-debug-msg-type-meta"></span>').text(L).appendTo(x);else{i=$('<span class="red-ui-debug-msg-object-header"></span>').appendTo(x),$("<span>{ </span>").appendTo(i);var P=Math.min(N.length,5);for(I=0;I<P;I++)$('<span class="red-ui-debug-msg-object-key"></span>').text(N[I]).appendTo(i),$("<span>: </span>").appendTo(i),F(j[N[I]]).appendTo(i),I<P-1&&$("<span>, </span>").appendTo(i);N.length>P&&$("<span> &hellip;</span>").appendTo(i),0===P&&$('<span class="red-ui-debug-msg-type-meta">empty</span>').appendTo(i),$("<span> }</span>").appendTo(i)}}else $('<span class="red-ui-debug-msg-type-other"></span>').text(""+t).appendTo(x);else o=$('<span class="red-ui-debug-msg-type-number red-ui-debug-msg-object-header"></span>').text(t.data).appendTo(x);return w&&D.prop("expand",function(){return function(e,t){if(g===e)n.prop("toggle")&&n.prop("toggle")(t);else if(E[e]&&E[e].prop("expand"))E[e].prop("expand")(e,t);else for(var o in E)if(E.hasOwnProperty(o)&&0===e.indexOf(o)){E[o].prop("expand")&&E[o].prop("expand")(e,t);break}}}),D},getMessageProperty:H,setMessageProperty:function(e,t,o,n){void 0===n&&(n=void 0!==o);for(var i,a=K(t=0===t.indexOf("msg.")?t.substring(4):t),s=a.length,r=e,d=0;d<s-1;d++)if("string"==typeof(i=a[d])||"number"==typeof i&&!Array.isArray(r))if(r.hasOwnProperty(i))r=r[i];else{if(!n)return null;"string"==typeof a[d+1]?r[i]={}:r[i]=[],r=r[i]}else if("number"==typeof i)if(void 0===r[i]){if(!n)return null;"string"==typeof a[d+1]?r[i]={}:r[i]=[],r=r[i]}else r=r[i];i=a[s-1],void 0===o?"number"==typeof i&&Array.isArray(r)?r.splice(i,1):delete r[i]:r[i]=o},normalisePropertyExpression:K,validatePropertyExpression:function(e){try{K(e);return!0}catch(e){return!1}},separateIconPath:a,getDefaultNodeIcon:n,getNodeIcon:function(e,t){if(e=e||{},t&&"_selection_"===t.type)return"font-awesome/fa-object-ungroup";if(t&&"group"===t.type)return"font-awesome/fa-object-group";if(t&&"junction"===t.type||"junction"===e.type)return"font-awesome/fa-circle-o";if("config"===e.category)return RED.settings.apiRootUrl+"icons/node-red/cog.svg";if(t&&/^_action_:/.test(t.type)||/^_action_:/.test(e.type))return"font-awesome/fa-cogs";if(t&&"tab"===t.type)return"red-ui-icons/red-ui-icons-flow";if(t&&"unknown"===t.type)return RED.settings.apiRootUrl+"icons/node-red/alert.svg";if(t&&t.icon){if(i(o=a(t.icon)))return"font-awesome"===o.module?t.icon:RED.settings.apiRootUrl+"icons/"+t.icon;if("font-awesome"!==o.module&&/.png$/i.test(o.file)&&(o.file=o.file.replace(/.png$/,".svg"),i(o)))return RED.settings.apiRootUrl+"icons/"+t.icon.replace(/.png$/,".svg")}var o;if(i(o=n(e,t)))return"font-awesome"===o.module?o.module+"/"+o.file:RED.settings.apiRootUrl+"icons/"+o.module+"/"+o.file;if(/.png$/i.test(o.file)){t=o.file;if(o.file=o.file.replace(/.png$/,".svg"),i(o))return RED.settings.apiRootUrl+"icons/"+o.module+"/"+o.file;o.file=t}return o.module="node-red",i(o)||/.png$/i.test(o.file)&&(o.file=o.file.replace(/.png$/,".svg"),i(o))?RED.settings.apiRootUrl+"icons/"+o.module+"/"+o.file:"subflows"===e.category?RED.settings.apiRootUrl+"icons/node-red/subflow.svg":RED.settings.apiRootUrl+"icons/node-red/arrow-in.svg"},getNodeLabel:function(t,o){var n;if(o=o||"","tab"===t.type)n=t.label||o;else if("group"===t.type)n=t.name||o;else if("junction"===t.type)n="junction";else{n=t._def.label;try{n=("function"==typeof n?n.call(t):n)||o}catch(e){console.log("Definition error: "+t.type+".label",e),n=o}}return RED.text.bidi.enforceTextDirectionWithUCC(n)},getNodeColor:function(e,t){var o=(t=t||{}).color,n=RED.settings.theme("palette.theme")||[];if(0<n.length){if(!d.hasOwnProperty(e)){d[e]=t.color;for(var i=n.length,a=0;a<i;a++){var s=n[a];if((!s.hasOwnProperty("category")||(s.hasOwnProperty("_category")||(s._category=new RegExp(s.category)),s._category.test(t.category)))&&(!s.hasOwnProperty("type")||(s.hasOwnProperty("_type")||(s._type=new RegExp(s.type)),s._type.test(e)))){d[e]=s.color||t.color;break}}}o=d[e]}return o||"#ddd"},getPaletteLabel:function(t,e){var o=t;if(void 0!==e.paletteLabel)try{o=("function"==typeof e.paletteLabel?e.paletteLabel.call(e):e.paletteLabel)||""}catch(e){console.log("Definition error: "+t+".paletteLabel",e)}return o},clearNodeColorCache:function(){d={}},addSpinnerOverlay:function(e,t){return e=$('<div class="red-ui-component-spinner "><img src="red/images/spin.svg"/></div>').appendTo(e),t&&e.addClass("red-ui-component-spinner-contain"),e},decodeObject:function(e,t){if("number"===t&&"NaN"===e)e=Number.NaN;else if("number"===t&&"Infinity"===e)e=1/0;else if("number"===t&&"-Infinity"===e)e=-1/0;else if("Object"===t||/^(array|set|map)/.test(t)||"boolean"===t||"number"===t)e=JSON.parse(e);else if(/error/i.test(t))e=((e=JSON.parse(e)).name?e.name+": ":"")+e.message;else if("null"===t)e=null;else if("undefined"===t)e=void 0;else if(/^buffer/.test(t)){var o=e;e=[];for(var n=0;n<o.length;n+=2)e.push(parseInt(o.substr(n,2),16))}return e},parseContextKey:function(e,t){var o={},n=/^#:\((\S+?)\)::(.*)$/.exec(e);return n?(o.store=n[1],o.key=n[2]):(o.key=e,t?o.store=t:RED.settings.context&&(o.store=RED.settings.context.default)),o},createIconElement:function(e,t,o){var n=t.find(".red-ui-palette-icon");0!==n.length&&n.remove();0!==(n=t.find("i")).length&&n.remove();var i=a(e);if("font-awesome"===i.module){if(RED.nodes.fontAwesome.getIconUnicode(i.file))return void(n=$("<i/>").appendTo(t)).addClass("red-ui-palette-icon-fa fa fa-fw "+(o?"fa-lg ":"")+i.file);e=RED.settings.apiRootUrl+"icons/node-red/arrow-in.svg"}else if("red-ui-icons"===i.module)return void $("<i/>").appendTo(t).addClass("red-ui-palette-icon red-ui-icons "+i.file);$("<div/>",{class:"red-ui-palette-icon"}).appendTo(t).css("backgroundImage","url("+e+")")},sanitize:G,renderMarkdown:t,createNodeIcon:function(e,t){var o,n=$('<span class="red-ui-node-icon-container">'),i=e._def,a=$("<div>",{class:"red-ui-node-icon"}),s=("_selection_"===e.type?a.addClass("red-ui-palette-icon-selection"):"group"===e.type?a.addClass("red-ui-palette-icon-group"):"junction"===e.type?a.addClass("red-ui-palette-icon-junction"):"tab"===e.type?a.addClass("red-ui-palette-icon-flow"):(s=RED.utils.getNodeColor(e.type,i),a.css("backgroundColor",s),(o=l(s))!==s&&a.css("border-color",o)),RED.utils.getNodeIcon(i,e));return RED.utils.createIconElement(s,a,!0),a.appendTo(n),t&&(o=RED.utils.getNodeLabel(e,e.name||e.type+": "+e.id),i=$("<div>",{class:"red-ui-node-label"}).appendTo(n),o?i.text(o):i.html("&nbsp;")),n},getDarkerColor:l,parseModuleList:function(e){return(e=e||["*"]).map(function(e){var e=/^(.+?)(?:@(.*))?$/.exec(e),t=-1===(t=e[1].indexOf("*"))?1/0:t;return{module:new RegExp("^"+e[1].replace(/\*/g,".*")+"$"),version:e[2],wildcardPos:t}})},checkModuleAllowed:function(e,t,o,n){return!o&&!n||(0===o.length&&0===n.length||(o=s(e,0,o),e=s(e,0,n),!(!o||e)||!(!o&&e)&&(!o&&!e||(o.wildcardPos!==e.wildcardPos?o.wildcardPos>e.wildcardPos:o.module.toString().length>e.module.toString().length))))},getBrowserInfo:function(){var e={};try{var t=navigator.userAgent;e.ua=t,e.browser=/Edge\/\d+/.test(t)?"ed":/MSIE 9/.test(t)?"ie9":/MSIE 10/.test(t)?"ie10":/MSIE 11/.test(t)?"ie11":/MSIE\s\d/.test(t)?"ie?":/rv\:11/.test(t)?"ie11":/Firefox\W\d/.test(t)?"ff":/Chrom(e|ium)\W\d|CriOS\W\d/.test(t)?"gc":/\bSafari\W\d/.test(t)?"sa":/\bOpera\W\d/.test(t)||/\bOPR\W\d/i.test(t)?"op":"undefined"!=typeof MSPointerEvent?"ie?":"",e.os=/Windows NT 10/.test(t)?"win10":/Windows NT 6\.0/.test(t)?"winvista":/Windows NT 6\.1/.test(t)?"win7":/Windows NT 6\.\d/.test(t)?"win8":/Windows NT 5\.1/.test(t)?"winxp":/Windows NT [1-5]\./.test(t)?"winnt":/Mac/.test(t)?"mac":/Linux/.test(t)?"linux":/X11/.test(t)?"nix":"",e.touch="ontouchstart"in document.documentElement,e.mobile=/IEMobile|Windows Phone|Lumia/i.test(t)?"w":/iPhone|iP[oa]d/.test(t)?"i":/Android/.test(t)?"a":/BlackBerry|PlayBook|BB10/.test(t)?"b":/Mobile Safari/.test(t)?"s":/webOS|Mobile|Tablet|Opera Mini|\bCrMo\/|Opera Mobi/i.test(t)?1:0,e.tablet=/Tablet|iPad/i.test(t),e.ie=/MSIE \d|Trident.*rv:/.test(navigator.userAgent),e.android=/android/i.test(navigator.userAgent)}catch(e){}return e}}}(),function(r){r.widget("nodered.editableList",{_create:function(){var o=this,e=(this.element.addClass("red-ui-editableList-list"),this.uiWidth=this.element.width(),this.uiContainer=this.element.wrap("<div>").parent(),this.options.header?(this.options.header.addClass("red-ui-editableList-header"),this.borderContainer=this.uiContainer.wrap("<div>").parent(),this.borderContainer.prepend(this.options.header),this.topContainer=this.borderContainer.wrap("<div>").parent()):this.topContainer=this.uiContainer.wrap("<div>").parent(),this.topContainer.addClass("red-ui-editableList"),this.options.class&&this.topContainer.addClass(this.options.class),this.options.buttons||[]),t=(!1!==this.options.addButton&&("string"==typeof this.options.addButton?t=this.options.addButton:n=RED&&RED._?(t=RED._("editableList.add"),RED._("editableList.addTitle")):(t="add","add new item"),e.unshift({label:t,icon:"fa fa-plus",click:function(e){o.addItem({})},title:n})),e.forEach(function(t){var e=r('<button type="button" class="red-ui-button red-ui-button-small red-ui-editableList-addButton" style="margin-top: 4px; margin-right: 5px;"></button>').appendTo(o.topContainer).on("click",function(e){e.preventDefault(),void 0!==t.click&&t.click(e)});t.id&&e.attr("id",t.id),t.title&&e.attr("title",t.title),t.icon&&e.append(r("<i></i>").attr("class",t.icon)),t.label&&e.append(r("<span></span>").text(" "+t.label))}),"absolute"===this.element.css("position")&&(["top","left","bottom","right"].forEach(function(e){var t=o.element.css(e);"auto"!==t&&""!==t&&(o.topContainer.css(e,t),o.uiContainer.css(e,"0"),"top"===e&&o.options.header&&o.uiContainer.css(e,"20px"),o.element.css(e,"auto"))}),this.element.css("position","static"),this.topContainer.css("position","absolute"),this.uiContainer.css("position","absolute")),(this.options.header?this.borderContainer:this.uiContainer).addClass("red-ui-editableList-border"),this.uiContainer.addClass("red-ui-editableList-container"),this.uiHeight=this.element.height(),this.activeFilter=this.options.filter||null,this.activeSort=this.options.sort||null,this.scrollOnAdd=this.options.scrollOnAdd,void 0===this.scrollOnAdd&&(this.scrollOnAdd=!0),this.element.css("minHeight")),n=("0px"!==t&&(this.uiContainer.css("minHeight",t),this.element.css("minHeight",0)),this.element.css("maxHeight")),e=("0px"!==n&&(this.uiContainer.css("maxHeight",n),this.element.css("maxHeight",null)),"auto"!==this.options.height&&(this.uiContainer.css("overflow-y","auto"),isNaN(this.options.height)||(this.uiHeight=this.options.height)),this.element.height("auto"),this.element.attr("style"));null!==(t=/width\s*:\s*(\d+%)/i.exec(e))&&(this.element.width("100%"),this.uiContainer.width(t[1])),this.options.sortable&&(n={axis:"y",update:function(e,t){o.options.sortItems&&o.options.sortItems(o.items())},handle:"string"==typeof this.options.sortable?this.options.sortable:".red-ui-editableList-item-handle",cursor:"move",tolerance:"pointer",forcePlaceholderSize:!0,placeholder:"red-ui-editabelList-item-placeholder",start:function(e,t){t.placeholder.height(t.item.height()-4)}},this.options.connectWith&&(n.connectWith=this.options.connectWith),this.element.sortable(n)),this._resize()},_resize:function(){var t,e=this.topContainer.height(),o=this.uiContainer.height();0!==this.uiHeight&&this.uiContainer.height(this.uiHeight-(e-o)),this.options.resize&&this.options.resize(),this.options.resizeItem&&(t=this).element.children().each(function(e){t.options.resizeItem(r(this).children(".red-ui-editableList-item-content"),e)})},_destroy:function(){var e;this.topContainer&&(e=this.topContainer,delete this.topContainer,e.remove())},_refreshFilter:function(){var n=this,i=0;return this.activeFilter?(this.items().each(function(e,t){var o=t.data("data");try{n.activeFilter(o)?(t.parent().show(),i++):t.parent().hide()}catch(e){console.log(e),t.parent().show(),i++}}),i):this.element.children().show()},_refreshSort:function(){var e,o;this.activeSort&&(e=this.element.children(),o=this,e.sort(function(e,t){return o.activeSort(r(e).children(".red-ui-editableList-item-content").data("data"),r(t).children(".red-ui-editableList-item-content").data("data"))}),r.each(e,function(e,t){o.element.append(t)}))},width:function(e){this.uiWidth=e,this._resize()},height:function(e){this.uiHeight=e,this._resize()},getItemAt:function(e){var t=this.items();if(0<=e&&e<t.length)return r(t[e]).data("data")},indexOf:function(e){for(var t=this.items(),o=0;o<t.length;o++)if(r(t[o]).data("data")===e)return o;return-1},insertItemAt:function(n,e){var t,i=this,a=(n=n||{},r("<li>")),o=r("<div/>").addClass("red-ui-editableList-item-content").appendTo(a),s=(o.data("data",n),!0===this.options.sortable&&(r('<i class="red-ui-editableList-item-handle fa fa-bars"></i>').appendTo(a),a.addClass("red-ui-editableList-item-sortable")),this.options.removable&&(t=r("<a/>",{href:"#",class:"red-ui-editableList-item-remove red-ui-button red-ui-button-small"}).appendTo(a),r("<i/>",{class:"fa fa-remove"}).appendTo(t),a.addClass("red-ui-editableList-item-removable"),t.on("click",function(e){e.preventDefault();var t=o.data("data");a.addClass("red-ui-editableList-item-deleting"),a.fadeOut(300,function(){r(this).remove(),i.options.removeItem&&i.options.removeItem(t)})})),!1);if(this.activeSort&&this.items().each(function(e,t){var o;s||(o=t.data("data"),i.activeSort(n,o)<0&&(a.insertBefore(t.closest("li")),s=!0))}),s||(e<=0?a.prependTo(this.element):e>i.element.children().length-1?a.appendTo(this.element):a.insertBefore(this.element.children().eq(e))),this.options.addItem){e=i.element.children().length-1;if(i.options.addItem(o,e,n),i.activeFilter)try{i.activeFilter(n)||a.hide()}catch(e){}!i.activeSort&&i.scrollOnAdd&&setTimeout(function(){i.uiContainer.scrollTop(i.element.height())},0)}},addItem:function(e){this.insertItemAt(e,this.element.children().length)},addItems:function(e){for(var t=0;t<e.length;t++)this.addItem(e[t])},removeItem:function(t,e){var o=this.element.children().filter(function(e){return t===r(this).children(".red-ui-editableList-item-content").data("data")});e?o.detach():o.remove(),this.options.removeItem&&this.options.removeItem(t)},items:function(){return this.element.children().map(function(e){return r(this).children(".red-ui-editableList-item-content")})},empty:function(){this.element.empty(),this.uiContainer.scrollTop(0)},filter:function(e){return void 0!==e&&(this.activeFilter=e),this._refreshFilter()},sort:function(e){return void 0!==e&&(this.activeSort=e),this._refreshSort()},length:function(){return this.element.children().length},show:function(t){var e=this.element.children().filter(function(e){return t===r(this).children(".red-ui-editableList-item-content").data("data")});0<e.length&&this.uiContainer.scrollTop(this.uiContainer.scrollTop()+e.position().top)},getItem:function(e){e=e.children(".red-ui-editableList-item-content");return e.length?e.data("data"):null}})}(jQuery),function(u){u.widget("nodered.treeList",{_create:function(){var n=this,i=!0,e=(!1===n.options.autoSelect&&(i=!1),this.element.addClass("red-ui-treeList"),this.element.attr("tabIndex",0),u("<div>",{class:"red-ui-treeList-container"}).appendTo(this.element)),e=(this.element.on("keydown",function(e){var t,o=n._topList.find(".focus").parent().data("data");if(o||40!==e.keyCode&&38!==e.keyCode){switch(e.keyCode){case 32:case 13:if(!n.options.selectable)return;if(e.altKey||e.ctrlKey||e.metaKey||e.shiftKey)return;e.preventDefault(),e.stopPropagation(),o.checkbox?o.treeList.checkbox.trigger("click"):o.radio?o.treeList.radio.trigger("click"):o.children?o.treeList.container.hasClass("expanded")?o.treeList.collapse():o.treeList.expand():n._trigger("confirm",null,o);break;case 37:e.preventDefault(),e.stopPropagation(),o.children&&o.treeList.container.hasClass("expanded")?o.treeList.collapse():o.parent&&(t=o.parent);break;case 38:e.preventDefault(),e.stopPropagation(),!(t=(t=n._getPreviousSibling(o))&&n._getLastDescendant(t))&&o.parent&&(t=o.parent);break;case 39:e.preventDefault(),e.stopPropagation(),!o.children||o.treeList.container.hasClass("expanded")||o.treeList.expand();break;case 40:if(e.preventDefault(),e.stopPropagation(),o.children&&Array.isArray(o.children)&&0<o.children.length&&o.treeList.container.hasClass("expanded"))t=o.children[0];else for(t=n._getNextSibling(o);!t&&o.parent;)o=o.parent,t=n._getNextSibling(o)}t&&(i?n.select(t):n._topList.find(".focus").removeClass("focus"),t.treeList.label.addClass("focus"))}else n._data[0]&&(i?n.select(n._data[0]):n._topList.find(".focus").removeClass("focus"),n._data[0].treeList.label.addClass("focus"))}),this._data=[],this._items={},this._selected=new Set,this._topList=u('<ol class="red-ui-treeList-list">').css({position:"absolute",top:0,left:0,right:0,bottom:0}).appendTo(e),{addButton:!1,scrollOnAdd:!1,height:"100%",addItem:function(e,t,o){n._addSubtree(n._topList,e,o,0)}});this.options.header&&(e.header=this.options.header),!1!==this.options.rootSortable&&this.options.sortable&&(e.sortable=this.options.sortable,e.connectWith=".red-ui-treeList-sortable",this._topList.addClass("red-ui-treeList-sortable")),this._topList.editableList(e),this.options.data&&this.data(this.options.data)},_getLastDescendant:function(e){return e.children&&e.treeList.container.hasClass("expanded")&&0!==e.children.length?this._getLastDescendant(e.children[e.children.length-1]):e},_getPreviousSibling:function(e){var t=e.parent?e.parent.children:this._data,e=t.indexOf(e);return 0===e?null:t[e-1]},_getNextSibling:function(e){var t=e.parent?e.parent.children:this._data,e=t.indexOf(e);return e===t.length-1?null:t[e+1]},_addChildren:function(e,n,o,i,a){var s=this,r=u('<ol class="red-ui-treeList-list">').appendTo(e).editableList({connectWith:".red-ui-treeList-sortable",sortable:s.options.sortable,addButton:!1,scrollOnAdd:!1,height:"auto",addItem:function(e,t,o){s._addSubtree(r,e,o,i+1)},sortItems:function(e){var t=[],o=[];e.each(function(){var e=u(this).data("data"),e=(t.push(e),s._fixDepths(n,e));e&&o.push(e)}),Array.isArray(n.children)&&(n.children=t),o.forEach(function(e){s._trigger("changeparent",null,e)}),s._trigger("sort",null,n)},filter:n.treeList.childFilter}),d=(s.options.sortable&&r.addClass("red-ui-treeList-sortable"),30),l=0,c=function(){for(var e=l,t=0;t<d;t++){if((l=e+t)===o.length)return void setTimeout(function(){a&&a()},10);o[l].parent=n,r.editableList("addItem",o[l])}++l<o.length&&setTimeout(function(){c()},10)};return c(),r.hide(),r},_fixDepths:function(e,t){var o,n=this,i=null;return t.parent!==e&&(reparented=!0,o=t.parent,t.parent=e,i={item:t,old:o}),t.depth!==e.depth+1&&(t.depth=e.depth+1,o=(t.gutter&&!t.gutter.hasClass("red-ui-treeList-gutter-float")?t.gutter.width()+2:0)+20*t.depth,t.treeList.labelPadding.width(o+"px"),t.element&&u(t.element).css({width:"calc(100% - "+(o+20+(t.icon?20:0))+"px)"}),t.children&&Array.isArray(t.children)&&t.children.forEach(function(e){n._fixDepths(t,e)})),i},_initItem:function(s,r){var d;s.treeList||(((d=this)._items[s.id]=s).treeList={},s.depth=r,s.treeList.remove=function(e){var t;if(s.treeList.parentList&&s.treeList.parentList.editableList("removeItem",s,e),s.parent&&(e=s.parent.children.indexOf(s),s.parent.children.splice(e,1),d._trigger("sort",null,s.parent)),d._selected.delete(s),delete s.treeList,delete d._items[s.id],0===s.depth){for(var o in d._items)!d._items.hasOwnProperty(o)||(t=d._items[o]).parent&&t.parent.id===s.id&&(delete d._items[o].treeList,delete d._items[o]);d._data=d._data.filter(function(e){return e.id!==s.id})}},s.treeList.insertChildAt=function(e,t,o){(e.parent=s).children.splice(t,0,e);function n(t,o){d._initItem(o,t.depth+1),o.parent=t,o.children&&"function"!=typeof o.children&&o.children.forEach(function(e){n(o,e,t.depth)})}n(s,e),!s.deferBuild&&s.treeList.childList&&(s.treeList.childList.editableList("insertItemAt",e,t),o&&setTimeout(function(){d.select(e)},100),d._trigger("sort",null,s),d.activeFilter&&d.filter(d.activeFilter))},s.treeList.addChild=function(e,t){s.treeList.insertChildAt(e,s.children.length,t)},s.treeList.expand=function(t){var o,n,i,a,e;s.children?s.treeList.container?(o=s.treeList.container).hasClass("expanded")?t&&t(!1):(o.hasClass("built")||!s.deferBuild&&"function"!=typeof s.children?(d._loadingData||20<s.children.length?s.treeList.childList.show():s.treeList.childList.slideDown("fast"),s.expanded=!0,t&&t(!d._loadingData)):(o.addClass("built"),n=!1,a=0,Date.now(),e=function(e){n=!0,s.treeList.childList=d._addChildren(o,s,e,r,function(){t&&t(!0),d._trigger("childrenloaded",null,s)});e=Date.now()-a;e<400?setTimeout(function(){s.treeList.childList.slideDown("fast"),i&&i.remove()},400-e):(s.treeList.childList.slideDown("fast"),i&&i.remove()),s.expanded=!0},"function"==typeof s.children?s.children(e,s):(delete s.deferBuild,e(s.children)),n||(a=Date.now(),i=u('<div class="red-ui-treeList-spinner">').css({"background-position":35+20*r+"px 50%"}).appendTo(o))),o.addClass("expanded")):(s.expanded=!0,t&&t(!1)):t&&t(!1)},s.treeList.collapse=function(){!1!==s.collapsible&&s.children&&(s.expanded=!1,s.treeList.container&&(s.children.length<20?s.treeList.childList.slideUp("fast"):s.treeList.childList.hide(),s.treeList.container.removeClass("expanded")))},s.treeList.sortChildren=function(e){s.children&&(s.children.sort(e),s.treeList.childList&&(s.treeList.childList.editableList("sort",e),s.treeList.childList.editableList("sort",null)))},s.treeList.replaceElement=function(e){var t;s.element&&(s.treeList.container&&(u(s.element).remove(),u(e).appendTo(s.treeList.label),t=(s.gutter?s.gutter[0].offsetWidth+2:0)+20*s.depth,u(e).css({width:"calc(100% - "+(t+20+(s.icon?20:0))+"px)"})),s.element=e)},s.children&&"function"!=typeof s.children&&s.children.forEach(function(e){d._initItem(e,r+1)}))},_addSubtree:function(e,o,n,t){var i,a,s=this,r=(this._initItem(n,t),n.treeList.container=o,n.treeList.parentList=e,u("<div>",{class:"red-ui-treeList-label"})),e=(r.appendTo(o),n.treeList.label=r,n.class&&r.addClass(n.class),n.gutter&&n.gutter.css({position:"absolute"}).appendTo(r),(n.gutter&&!n.gutter.hasClass("red-ui-treeList-gutter-float")?n.gutter.width()+2:0)+20*t),d=(n.treeList.labelPadding=u("<span>").css({display:"inline-block","flex-shrink":0,width:e+"px"}).appendTo(r),r.on("mouseover",function(e){s._trigger("itemmouseover",e,n)}),r.on("mouseout",function(e){s._trigger("itemmouseout",e,n)}),r.on("mouseenter",function(e){s._trigger("itemmouseenter",e,n)}),r.on("mouseleave",function(e){s._trigger("itemmouseleave",e,n)}),n.treeList.makeLeaf=function(e){var t;d.children().length&&(e&&n.children&&(t=function(e){e.children&&e.children.forEach(function(e){e.element&&e.element.detach(),e.gutter&&e.gutter.detach(),t(e)})})(n),d.empty(),n.deferBuild||(n.treeList.childList.remove(),delete n.treeList.childList),r.off("click.red-ui-treeList-expand"),d.off("click.red-ui-treeList-expand"),delete n.children,o.removeClass("expanded"),delete n.expanded)},n.treeList.makeParent=function(e){d.children().length||(u('<i class="fa fa-angle-right" />').toggleClass("hide",!1===n.collapsible).appendTo(d),d.on("click.red-ui-treeList-expand",function(e){e.stopPropagation(),e.preventDefault(),o.hasClass("expanded")?n.treeList.collapse():n.treeList.expand()}),r.on("click.red-ui-treeList-expand",function(e){o.hasClass("expanded")?(n.hasOwnProperty("selected")||r.hasClass("selected"))&&n.treeList.collapse():n.treeList.expand()}),n.children||(n.children=e||[],n.treeList.childList=s._addChildren(o,n,n.children,t)))},u('<span class="red-ui-treeList-icon"></span>').appendTo(r));n.children&&n.treeList.makeParent(),n.checkbox?(i=u('<span class="red-ui-treeList-icon"></span>'),(a=u('<input class="red-ui-treeList-checkbox" type="checkbox">').prop("checked",n.selected).appendTo(i)).on("click",function(e){e.stopPropagation()}),a.on("change",function(e){n.selected=this.checked,n.selected?s._selected.add(n):s._selected.delete(n),r.toggleClass("selected",this.checked),s._trigger("select",e,n)}),n.children||r.on("click",function(e){e.stopPropagation(),a.trigger("click"),s._topList.find(".focus").removeClass("focus"),r.addClass("focus")}),n.treeList.select=function(e){e!==n.selected&&a.trigger("click")},n.treeList.checkbox=a,i.appendTo(r)):n.radio?(i=u('<span class="red-ui-treeList-icon"></span>'),(a=u('<input class="red-ui-treeList-radio" type="radio">').prop("name",n.radio).prop("checked",n.selected).appendTo(i)).on("click",function(e){e.stopPropagation()}),a.on("change",function(e){n.selected=this.checked,s._selected.forEach(function(e){e.radio===n.radio&&(e.treeList.label.removeClass("selected"),e.selected=!1,s._selected.delete(e))}),n.selected?s._selected.add(n):s._selected.delete(n),r.toggleClass("selected",this.checked),s._trigger("select",e,n)}),n.children||r.on("click",function(e){e.stopPropagation(),a.trigger("click"),s._topList.find(".focus").removeClass("focus"),r.addClass("focus")}),n.treeList.select=function(e){e!==n.selected&&a.trigger("click")},i.appendTo(r),n.treeList.radio=a):(r.on("click",function(e){s.options.multi||s.clearSelection(),r.addClass("selected"),s._selected.add(n),s._topList.find(".focus").removeClass("focus"),r.addClass("focus"),s._trigger("select",e,n)}),r.on("dblclick",function(e){s._topList.find(".focus").removeClass("focus"),r.addClass("focus"),n.children||s._trigger("confirm",e,n)}),n.treeList.select=function(e){s.options.multi||s.clearSelection(),r.toggleClass("selected",e),e?(s._selected.add(n),s._trigger("select",null,n)):s._selected.delete(n),s.reveal(n)}),r.toggleClass("selected",!!n.selected),n.selected&&s._selected.add(n),n.icon&&("string"==typeof n.icon?u('<span class="red-ui-treeList-icon"><i class="'+n.icon+'" /></span>').appendTo(r):u('<span class="red-ui-treeList-icon">').appendTo(r).append(n.icon)),n.hasOwnProperty("label")||n.hasOwnProperty("sublabel")?(n.hasOwnProperty("label")&&u('<span class="red-ui-treeList-label-text"></span>').text(n.label).appendTo(r),n.hasOwnProperty("sublabel")&&u('<span class="red-ui-treeList-sublabel-text"></span>').text(n.sublabel).appendTo(r)):n.element&&(u(n.element).appendTo(r),u(n.element).css({width:"calc(100% - "+(e+20+(n.icon?20:0))+"px)"})),n.children&&(Array.isArray(n.children)&&!n.deferBuild&&(n.treeList.childList=s._addChildren(o,n,n.children,t)),n.expanded&&n.treeList.expand())},empty:function(){this._topList.editableList("empty")},data:function(e){var t=this;if(void 0===e)return this._data;this._data=e,this._items={},this._topList.editableList("empty"),this._loadingData=!0;for(var o=0;o<e.length;o++)this._topList.editableList("addItem",e[o]);setTimeout(function(){delete t._loadingData},200),this._trigger("select")},show:function(e,o){if(e="string"==typeof e?this._items[e]:e){for(var n=this,i=[],t=e;t;)i.unshift(t),t=t.parent;var a=!1,s=function(e){a=a||e;var t=i.shift();0===i.length?setTimeout(function(){n.reveal(t),o&&o()},a?200:0):t.treeList.expand(s)};s()}},reveal:function(e){var t,o,n;(e="string"==typeof e?this._items[e]:e)&&(o=this._topList.offset().top,t=e.treeList.label.offset().top,t-=o+(o=this._topList.parent().scrollTop()),n=this._topList.parent().height(),t<(e=e.treeList.label.outerHeight())/2?this._topList.parent().scrollTop(o+t-e/2-e):n<t+e&&this._topList.parent().scrollTop(o+(t+2.5*e-n)))},select:function(e,t,o){var n=this;this.options.multi||!1===o||this.clearSelection(),Array.isArray(e)?e.forEach(function(e){n.select(e,t,!1)}):(e="string"==typeof e?this._items[e]:e)&&(e.selected=!0,this._selected.add(e),e.treeList.label&&e.treeList.label.addClass("selected"),n._topList.find(".focus").removeClass("focus"),!1!==t&&this._trigger("select",null,e))},clearSelection:function(){this._selected.forEach(function(e){e.selected=!1,e.treeList.checkbox&&e.treeList.checkbox.prop("checked",!1),e.treeList.label&&e.treeList.label.removeClass("selected")}),this._selected.clear()},selected:function(){var t=[];return this._selected.forEach(function(e){t.push(e)}),this.options.multi?t:t.length?t[0]:void 0},filter:function(n){this.activeFilter=n;function i(e){var t=0,o=(n&&n(e)&&(t++,a++),0);return e.children&&"function"!=typeof e.children&&(e.treeList.childList?o=e.treeList.childList.editableList("filter",i):(e.treeList.childFilter=i,n&&e.children.forEach(function(e){i(e)&&o++})),t+=o,n&&0<o&&setTimeout(function(){e.treeList.expand()},10)),n?0<t:(a++,!0)}var a=0;return this._topList.editableList("filter",i),a},get:function(e){return this._items[e]||null}})}(jQuery),function(t){t.widget("nodered.checkboxSet",{_create:function(){var o=this,e=(this.uiElement=this.element.wrap("<span>").parent(),this.uiElement.addClass("red-ui-checkboxSet"),this.options.parent&&(this.parent=this.options.parent,this.parent.checkboxSet("addChild",this.element)),this.children=[],this.partialFlag=!1,this.stateValue=0,this.element.prop("checked"));this.states=[t('<span class="red-ui-checkboxSet-option hide"><i class="fa fa-square-o"></i></span>').appendTo(this.uiElement),t('<span class="red-ui-checkboxSet-option hide"><i class="fa fa-check-square-o"></i></span>').appendTo(this.uiElement),t('<span class="red-ui-checkboxSet-option hide"><i class="fa fa-minus-square-o"></i></span>').appendTo(this.uiElement)],(e?this.states[1]:this.states[0]).show(),this.element.on("change",function(){this.checked?(o.states[0].hide(),o.states[1].show()):(o.states[1].hide(),o.states[0].show()),o.states[2].hide();var t=this.checked;o.children.forEach(function(e){e.checkboxSet("state",t,!1,!0)})}),this.uiElement.on("click",function(e){e.stopPropagation(),o.state(!1===o.state())}),this.parent&&this.parent.checkboxSet("updateChild",this)},_destroy:function(){this.parent&&this.parent.checkboxSet("removeChild",this.element)},addChild:function(e){this.children.push(e)},removeChild:function(e){e=this.children.indexOf(e);-1<e&&this.children.splice(e,1)},updateChild:function(e){var o=0;this.children.forEach(function(e,t){!0===e.checkboxSet("state")&&o++}),0===o?this.state(!1,!0):o===this.children.length?this.state(!0,!0):this.state(null,!0)},disable:function(){this.uiElement.addClass("disabled")},state:function(e,t,o){if(0===arguments.length)return this.partialFlag?null:this.element.is(":checked");this.partialFlag=null===e;var n=this.partialFlag||e;this.element.prop("checked",n),!0===e?(this.states[0].hide(),this.states[1].show(),this.states[2].hide()):!1===e?(this.states[2].hide(),this.states[1].hide(),this.states[0].show()):null===e&&(this.states[0].hide(),this.states[1].hide(),this.states[2].show()),t||this.element.trigger("change",null),!o&&this.parent&&this.parent.checkboxSet("updateChild",this)}})}(jQuery),RED.menu=function(){var c={};let u=0;function p(t){var o;if(null!==t&&t.id&&!1===RED.settings.theme("menu."+t.id))return null;if(null===t)o=$('<li class="red-ui-menu-divider"></li>');else{o=$("<li></li>"),t.id||(t.id="red-ui-menu-item-"+u++),t.group&&o.addClass("red-ui-menu-group-"+t.group);var n="<a "+(t.id?'id="'+t.id+'" ':"")+'tabindex="-1" href="#">';t.toggle&&(n=(n+='<i class="fa fa-square'+("right"!==t.direction?" pull-left":"")+'"></i>')+'<i class="fa fa-check-square'+("right"!==t.direction?" pull-left":"")+'"></i>'),void 0!==t.icon&&(/\.(png|svg)/.test(t.icon)?n+='<img src="'+t.icon+'"/> ':n+='<i class="'+(t.icon||'" style="display: inline-block;"')+'"></i> ');let e=t.label;t.label||"string"!=typeof t.onselect||(e=RED.actions.getLabel(t.onselect)),t.sublabel?n+='<span class="red-ui-menu-label-container"><span class="red-ui-menu-label">'+e+'</span><span class="red-ui-menu-sublabel">'+t.sublabel+"</span></span>":n+='<span class="red-ui-menu-label"><span>'+e+"</span></span>",n+="</a>";var i,n=$(n).appendTo(o);if(t.link=n,"string"!=typeof t.onselect||(i=RED.keyboard.getShortcut(t.onselect))&&i.key&&(t.shortcutSpan=$('<span class="red-ui-popover-key">'+RED.keyboard.formatKey(i.key,!0)+"</span>").appendTo(n.find(".red-ui-menu-label"))),(c[t.id]=t).onselect?(n.on("click",function(e){e.preventDefault(),$(this).parent().hasClass("disabled")||(t.toggle?!0===t.toggle?g(t.id,!h(t.id)):g(t.id,!0):f(t.id))}),t.toggle&&(i=RED.settings.get("menu-"+t.id),t.setting&&(null!==i?(RED.settings.set(t.setting,i),RED.settings.remove("menu-"+t.id)):i=RED.settings.get(t.setting)),i?(n.addClass("active"),f(t.id,!0)):!1===i?(n.removeClass("active"),f(t.id,!1)):t.hasOwnProperty("selected")&&(t.selected?n.addClass("active"):n.removeClass("active"),f(t.id,t.selected)))):t.href?n.attr("target","_blank").attr("href",t.href):t.options||(o.addClass("disabled"),n.on("click",function(e){e.preventDefault()})),t.options){o.addClass("red-ui-menu-dropdown-submenu"+("right"!==t.direction?" pull-left":""));for(var a=$('<ul id="'+t.id+'-submenu" class="red-ui-menu-dropdown"></ul>').appendTo(o),s=!1,r=!1,d=0;d<t.options.length;d++){t.options[d]&&(t.onpreselect&&void 0===t.options[d].onpreselect&&(t.options[d].onpreselect=t.onpreselect),t.onpostselect&&void 0===t.options[d].onpostselect&&(t.options[d].onpostselect=t.onpostselect),t.options[d].direction=t.direction,s=s||t.options[d].icon,r=r||t.options[d].options);var l=p(t.options[d]);l&&l.appendTo(a)}s||a.addClass("red-ui-menu-dropdown-noicons"),r&&a.addClass("red-ui-menu-dropdown-submenus")}t.disabled&&o.addClass("disabled"),!1===t.visible&&o.addClass("hide")}return o}function f(e,t){var o=c[e],n=o.onselect;o.onpreselect&&o.onpreselect.call(o,t),(n="string"==typeof o.onselect?RED.actions.get(o.onselect):n)?n.call(o,t):console.log("No callback for",e,o.onselect),o.onpostselect&&o.onpostselect.call(o,t)}function h(e){return $("#"+e).hasClass("active")}function g(e,t){var o=!1,n=(h(e)==t&&(o=!0),c[e]);if(t?$("#"+e).addClass("active"):$("#"+e).removeClass("active"),n){if(n.toggle&&"string"==typeof n.toggle&&t)for(var i in c)!c.hasOwnProperty(i)||(i=c[i]).id!=n.id&&n.toggle==i.toggle&&g(i.id,!1);!o&&n.onselect&&f(n.id,t),n.local||o||RED.settings.set(n.setting||"menu-"+n.id,t)}}return{init:function(e){for(var t,o=$("<ul/>",{class:"red-ui-menu red-ui-menu-dropdown pull-right"}),n=(e.direction&&o.addClass("red-ui-menu-dropdown-direction-"+e.direction),e.id&&(o.attr({id:e.id+"-submenu"}),1===(t=$("#"+e.id)).length&&(o.insertAfter(t),t.on("click",function(e){e.stopPropagation(),e.preventDefault(),o.is(":visible")?($(document).off("click.red-ui-menu"),o.hide()):($(document).on("click.red-ui-menu",function(e){$(document).off("click.red-ui-menu"),activeMenu=null,o.hide()}),$(".red-ui-menu.red-ui-menu-dropdown").hide(),o.show())}))),!1),i=!1,a=!1,s=0;s<e.options.length;s++){var r,d=e.options[s];d&&(e.onpreselect&&void 0===d.onpreselect&&(d.onpreselect=e.onpreselect),e.onpostselect&&void 0===d.onpostselect&&(d.onpostselect=e.onpostselect),d.direction=e.direction||"left"),null===d&&n||(a=a||d&&d.icon,i=i||d&&d.options,(r=p(d))&&(r.appendTo(o),n=null===d))}return a||o.addClass("red-ui-menu-dropdown-noicons"),i&&o.addClass("red-ui-menu-dropdown-submenus"),o},setSelected:g,isSelected:h,toggleSelected:function(e){g(e,!h(e))},setDisabled:function(e,t){t?$("#"+e).parent().addClass("disabled"):$("#"+e).parent().removeClass("disabled")},setVisible:function(e,t){t?$("#"+e).parent().removeClass("hide"):$("#"+e).parent().addClass("hide")},addItem:function(e,t){var o=p(t);if(null!==t&&t.group){var n=$("#"+e+"-submenu").children(".red-ui-menu-group-"+t.group);if(0===n.length)o.appendTo("#"+e+"-submenu");else{for(var i=0;i<n.length;i++){var a=n[i],s=$(a).find(".red-ui-menu-label").html();if(t.label<s){$(a).before(o);break}}i===n.length&&o.appendTo("#"+e+"-submenu")}}else o.appendTo("#"+e+"-submenu")},removeItem:function(e){$("#"+e).parent().remove()},setAction:function(e,t){(e=c[e])&&(e.onselect=t)},refreshShortcuts:function(){for(var e in c){var t;!c.hasOwnProperty(e)||"string"==typeof(e=c[e]).onselect&&e.shortcutSpan&&(e.shortcutSpan.remove(),delete e.shortcutSpan,(t=RED.keyboard.getShortcut(e.onselect))&&t.key&&(e.shortcutSpan=$('<span class="red-ui-popover-key">'+RED.keyboard.formatKey(t.key,!0)+"</span>").appendTo(e.link.find(".red-ui-menu-label"))))}}}}(),RED.panels={create:function(a){var s=a.container||$("#"+a.id),r=s.children();if(2!==r.length)throw console.log(a.id),new Error("Container must have exactly two children");var d,l=!a.dir||"vertical"===a.dir,t=(s.addClass("red-ui-panels"),l||s.addClass("red-ui-panels-horizontal"),$(r[0]).addClass("red-ui-panel"),$(r[1]).addClass("red-ui-panel"),$('<div class="red-ui-panels-separator"></div>').insertAfter(r[0])),c=[],n=!1,u=.5,o=(t.draggable({axis:l?"y":"x",containment:s,scroll:!1,start:function(e,t){d=l?t.position.top:t.position.left,c=[l?$(r[0]).height():$(r[0]).width(),l?$(r[1]).height():$(r[1]).width()]},drag:function(e,t){var o=l?s.height():s.width(),n=(l?t.position.top:t.position.left)-d,i=[c[0]+n,c[1]-n];l?($(r[0]).height(i[0]),t.position.top-=n):($(r[0]).width(i[0]),t.position.left-=n),a.resize&&a.resize(i[0],i[1]),u=i[0]/(o-8)},stop:function(e,t){n=!0}}),{ratio:function(e){if(void 0===e)return u;n=!0,0===(u=e)||1===e?t.hide():t.show(),l?o.resize(s.height()):o.resize(s.width())},resize:function(e){var t,o;l?(o=[$(r[0]).outerHeight(),$(r[1]).outerHeight()],s.height(e)):(o=[$(r[0]).outerWidth(),$(r[1]).outerWidth()],s.width(e)),n&&(o=[t=u*(e-8),e-t-8],l?$(r[0]).outerHeight(o[0]):$(r[0]).outerWidth(o[0])),a.resize&&(o=l?[$(r[0]).height(),$(r[1]).height()]:[$(r[0]).width(),$(r[1]).width()],a.resize(o[0],o[1]))}});return o}},RED.popover=function(){var E={default:{x:12,y:12},small:{x:8,y:8}};return{create:function(n){var c=n.target,u=n.direction||"right",i=n.trigger,a=n.content,s=n.delay||{show:750,hide:50},t=n.autoClose,r=n.width||"auto",d=n.maxWidth,p=n.size||"default",f=n.offset||0;if(!E[p])throw new Error("Invalid RED.popover size value:",p);function o(e){if(g){var t=c.data("red-ui-popover");if(n.tooltip&&t)g=!1;else{if(m=$('<div class="red-ui-popover"></div>'),n.class&&m.addClass(n.class),v=$('<div class="red-ui-popover-content">').appendTo(m),"default"!==p&&m.addClass("red-ui-popover-size-"+p),"function"==typeof a){var o=a.call(w);if(null===o)return;"string"==typeof o?v.text(o):v.append(o)}else v.html(a);m.appendTo("body"),l({target:c,direction:u,width:r,maxWidth:d}),t&&t.close(!0),"manual"!==n.trigger&&c.data("red-ui-popover",w),n.tooltip&&m.on("mousedown",function(e){h(!0)}),"hover"===i&&n.interactive&&(m.on("mouseenter",function(e){clearTimeout(y),g=!0}),m.on("mouseleave",function(e){y&&clearTimeout(y),g&&(y=setTimeout(function(){g=!1,h()},s.hide))})),e?m.show():m.fadeIn("fast")}}}function l(e){c=e.target||c,u=e.direction||u||"right",f=e.offset||f;var t=e.transition,o=e.width||"auto";m.width(o),e.maxWidth?m.css("max-width",e.maxWidth):m.css("max-width","auto");var e=(o=c[0].getBoundingClientRect()).height,n=o.width,i=m.outerHeight(),a=m.outerWidth(),s=$(window).scrollTop(),r=$(window).scrollLeft(),s=s+$(window).height(),r=r+$(window).width(),d=0,l=0;"right"===u?(d=o.top+e/2-i/2,l=o.left+n+E[p].x+f):"left"===u?(d=o.top+e/2-i/2,l=o.left-E[p].x-a-f):"bottom"===u?(d=o.top+e+E[p].y+f,(l=o.left+n/2-a/2)<0?(u="right",d=o.top+e/2-i/2,l=o.left+n+E[p].x+f):r<l+a+10?(u="left",d=o.top+e/2-i/2,l=o.left-E[p].x-a-f,s<d+i+e/2+5&&(d-=d+i+e/2-s+5)):s<d+i&&(u="top",d=o.top-E[p].y-i-f,l=o.left+n/2-a/2)):"top"===u?(d=o.top-E[p].y-i-f,l=o.left+n/2-a/2,d<0&&(u="bottom",d=o.top+e+E[p].y+f,l=o.left+n/2-a/2)):/inset/.test(u)&&(d=o.top+e/2-i/2,l=o.left+n/2-a/2,/bottom/.test(u)&&(d=o.top+e-i-f),/top/.test(u)&&(d=o.top+f),/left/.test(u)&&(l=o.left+f),/right/.test(u)&&(l=o.left+n-a-f)),b&&m.removeClass(b),t&&m.css({transition:"0.6s ease","transition-property":"top,left,right,bottom"}),b="red-ui-popover-"+u,m.addClass(b).css({top:d,left:l}),t&&setTimeout(function(){m.css({transition:"none"})},600)}function h(e){$(document).off("mousedown.red-ui-popover"),g||m&&(e?m.remove():m.fadeOut("fast",function(){$(this).remove()}),m=null,c.removeData("red-ui-popover",w))}var g,m,v,b,y=null,w=(c.on("remove",function(e){y&&clearTimeout(y),g&&(g=!1,setTimeout(h,s.hide))}),"hover"===i?(c.on("mouseenter",function(e){clearTimeout(y),g||(g=!0,y=setTimeout(o,s.show))}),c.on("mouseleave disabled",function(e){y&&clearTimeout(y),g&&(g=!1,setTimeout(h,s.hide))})):"click"===i?(c.on("click",function(e){e.preventDefault(),e.stopPropagation(),((g=!g)?o:h)()}),t&&c.on("mouseleave disabled",function(e){y&&clearTimeout(y),g&&(g=!1,setTimeout(h,t))})):"modal"===i?$(document).on("mousedown.red-ui-popover",function(e){for(var t=e.target;"BODY"!==t.nodeName&&t!==m[0];)t=t.parentElement;"BODY"===t.nodeName&&(g=!1,h())}):t&&setTimeout(function(){g=!1,h()},t),{get element(){return m},setContent:function(e){return a=e,w},open:function(e){return g=!0,o(e),w},close:function(e){return g=!1,h(e),w},move:function(e){l(e)}});return w},tooltip:function(e,o,n){var t=RED.popover.create({tooltip:!0,target:e,trigger:"hover",size:"small",direction:"bottom",content:function(){var e,t=o;return t=n&&(e=RED.keyboard.getShortcut(n))&&e.key?$("<span>"+o+' <span class="red-ui-popover-key">'+RED.keyboard.formatKey(e.key,!0)+"</span></span>"):t},delay:{show:750,hide:50}});return t.setContent=function(e){o=e},t.setAction=function(e){n=e},t.delete=function(){t.close(!0),e.off("mouseenter"),e.off("mouseleave")},t},menu:function(o){var n=$('<ul class="red-ui-menu"></ul>'),i=("compact"===o.style&&n.addClass("red-ui-menu-compact"),o.options||[]),t=RED.popover.panel(n),a=(o.width&&t.container.width(o.width),o.class&&t.container.addClass(o.class),o.maxHeight&&t.container.css({"max-height":o.maxHeight,"overflow-y":"auto"}),{options:function(e){if(void 0===e)return i;i=e||[],n.empty(),i.forEach(function(t){var e=$("<li>").appendTo(n),e=$('<a href="#"></a>').appendTo(e);"string"==typeof t.label?e.text(t.label):t.label&&t.label.appendTo(e),e.on("click",function(e){e.preventDefault(),t.onselect?t.onselect():o.onselect&&o.onselect(t),a.hide()}),0})},show:function(e){$(document).on("keydown.red-ui-menu",function(e){var t=n.find(":focus").parent();40===e.keyCode?(e.preventDefault(),(!(0<t.length)||t.index()===i.length-1?n.children().first():t.next()).children().first().focus()):38===e.keyCode?(e.preventDefault(),(!(0<t.length)||0===t.index()?n.children().last():t.prev()).children().first().focus()):27===e.keyCode?(e.preventDefault(),a.hide(!0)):9===e.keyCode&&o.tabSelect&&(e.preventDefault(),t.find("a").trigger("click")),e.stopPropagation()}),e.onclose=function(){$(document).off("keydown.red-ui-menu"),o.onclose&&o.onclose(!0)},t.show(e)},hide:function(e){$(document).off("keydown.red-ui-menu"),t.hide(o.disposeOnClose),o.onclose&&o.onclose(e)}});return a.options(i),a},panel:function(e){var l=$('<div class="red-ui-editor-dialog red-ui-popover-panel"></div>');function c(e){$(document).off("mousedown.red-ui-popover-panel-close"),$(document).off("keydown.red-ui-popover-panel-close"),l.hide(),l.css({height:"auto"}),!1!==e&&l.remove()}return l.css({display:"none"}),l.appendTo(document.body),e.appendTo(l),{container:l,show:function(t){var o=t.onclose,n=t.closeButton,e=t.target,i=t.align||"right",a=t.offset||[0,0],s=t.x,r=t.y,s=(d=void 0!==s&&void 0!==r)?{left:s,top:r}:e.offset(),r=(d||e.width(),d?0:e.outerHeight()),d=l.height(),e=l.width();(r=r+s.top+a[1])+d-$(document).scrollTop()>$(window).height()&&(r-=r+d-$(window).height()+5),r<0&&(l.height(d+r),r=0),"right"===i?l.css({top:r+"px",left:s.left+a[0]+"px"}):"left"===i&&l.css({top:r+"px",left:s.left-e+a[0]+"px"}),l.slideDown(100),$(document).on("keydown.red-ui-popover-panel-close",function(e){27===e.keyCode&&(o&&o(),c(t.dispose))}),$(document).on("mousedown.red-ui-popover-panel-close",function(e){n&&$(e.target).closest(n).length||$(e.target).closest(l).length||$(e.target).closest(".red-ui-editor-dialog").length||(o&&o(),c(t.dispose))})},hide:c}}}}(),function(i){i.widget("nodered.searchBox",{_create:function(){var t,o,n=this;this.currentTimeout=null,this.lastSent="",this.element.val(""),this.element.addClass("red-ui-searchBox-input"),this.uiContainer=this.element.wrap("<div>").parent(),this.uiContainer.addClass("red-ui-searchBox-container"),"compact"===this.options.style&&this.uiContainer.addClass("red-ui-searchBox-compact"),0===this.element.parents("form").length&&this.element.wrap("<form>").parent().addClass("red-ui-searchBox-form"),i('<i class="fa fa-search"></i>').prependTo(this.uiContainer),this.clearButton=i('<a class="red-ui-searchBox-clear" href="#"><i class="fa fa-times"></i></a>').appendTo(this.uiContainer),this.clearButton.on("click",function(e){e.preventDefault(),n.element.val(""),n._change("",!0),n.element.trigger("focus")}),this.options.options&&(this.uiContainer.addClass("red-ui-searchBox-has-options"),this.optsButton=i('<a class="red-ui-searchBox-opts" href="#"><i class="fa fa-caret-down"></i></a>').appendTo(this.uiContainer),t=!1,this.optsMenu=RED.popover.menu({style:this.options.style,options:this.options.options.map(function(e){return{label:e.label,onselect:function(){n.element.val(e.value+" "),n._change(e.value,!0)}}}),onclose:function(e){t=!1,n.element.trigger("focus")},disposeOnClose:!1}),o=function(){t=!0,n.optsMenu.show({target:n.optsButton,align:"left",offset:[n.optsButton.width()-2,-1],dispose:!1})},this.optsButton.on("click",function(e){e.preventDefault(),t?n.optsMenu.hide(!0):o()}),this.optsButton.on("keydown",function(e){t||40!==e.keyCode||o()}),this.element.on("keydown",function(e){t||40!==e.keyCode||""!==i(this).val()||o()})),this.resultCount=i("<span>",{class:"red-ui-searchBox-resultCount hide"}).appendTo(this.uiContainer),this.element.val(""),this.element.on("keydown",function(e){27===e.keyCode&&n.element.val(""),13===e.keyCode&&e.preventDefault()}),this.element.on("keyup",function(e){n._change(i(this).val())}),this.element.on("focus",function(){i(document).one("mousedown",function(){n.element.blur()})})},_change:function(e,t){var o,n=!1,n=""===e?(this.clearButton.hide(),!0):(this.clearButton.show(),e.length>=(this.options.minimumLength||0)),e=this.element.val();(n=n&&e!==this.lastSent)&&(!t&&0<this.options.delay?(clearTimeout(this.currentTimeout),(o=this).currentTimeout=setTimeout(function(){o.lastSent=o.element.val(),o._trigger("change")},this.options.delay)):(this.lastSent=this.element.val(),this._trigger("change")))},value:function(e){if(void 0===e)return this.element.val();this.element.val(e),this._change(e)},count:function(e){null==e||""===e?this.resultCount.text("").hide():this.resultCount.text(e).show()},change:function(){this._trigger("change")}})}(jQuery),RED.tabs=function(){var O,I="fa fa-lemon-o",N=!1,P=!1;return{create:function(f){var d,h,g,e,t,o,n,i,a,s,m,r,v={},b=0,l=0,y=f.order,w=f.element||$("#"+f.id),c=w.wrap("<div>").parent(),E=w.wrap("<div>").parent();function u(e,t){var o,n;e.preventDefault(),$(this).hasClass("disabled")||(o=E.scrollLeft(),E.animate({scrollLeft:t},100),n=setInterval(function(){var e=E.scrollLeft();e===o?clearInterval(n):(o=e,E.animate({scrollLeft:t},100))},100),$(this).one("mouseup",function(){clearInterval(n)}))}function p(){var e=w.find("li.red-ui-tab.selected"),t=[];return e.each(function(){t.push(v[$(this).find("a").attr("href").slice(1)])}),t}function D(){f.onselect(p())}function R(e){if(!N)if(e.currentTarget!==g)g=null;else{if(g=null,O&&Date.now()-O<400)return P=!(O=0),function(e){if(e.preventDefault(),!e.metaKey&&!e.shiftKey)return f.ondblclick&&f.ondblclick(v[$(this).attr("href").slice(1)]),!1}.call(this,e);O=Date.now();var t,o,n=w.find("li.red-ui-tab.active"),i=$(this).parent(),a=!1;if(f.onselect)if(e.metaKey||e.ctrlKey){if(i.hasClass("selected")){if(i.removeClass("selected"),i[0]!==n[0])return void D();if(0===(o=w.find("li.red-ui-tab.selected")).length)return void D();i=o.first()}else n.hasClass("selected")||(v[n.find("a").attr("href").slice(1)],n.addClass("selected")),i.addClass("selected");a=!0}else e.shiftKey?(n[0]!==i[0]&&(e=n.index()<i.index()?(t=n,i):(t=i,n),w.find("li.red-ui-tab").removeClass("selected"),t.addClass("selected"),e.addClass("selected"),t.nextUntil(e).addClass("selected")),a=!0):0<(o=w.find("li.red-ui-tab.selected")).length&&(o.removeClass("selected"),a=!0);n=i.find("a");f.onclick&&f.onclick(v[n.attr("href").slice(1)]),_(n),a&&D()}}function x(){var e,t,o;0!==w.children().length&&(e=E.scrollLeft(),t=E.width(),o=w.width(),0===e?a.hide():a.show(),e===o-t?s.hide():s.show())}function _(e){var t;0!==(e="string"==typeof e?w.find("a[href='#"+e+"']"):e).length&&(e.parent().hasClass("hide-tab")&&(e.parent().removeClass("hide-tab").removeClass("hide"),f.onshow&&f.onshow(v[e.attr("href").slice(1)])),e.parent().hasClass("active")||(w.children().removeClass("active"),w.children().css({transition:"width 100ms"}),e.parent().addClass("active"),t=e.parent().attr("id"),c.find(".red-ui-tab-link-button").removeClass("active selected"),$("#"+t+"-link-button").addClass("active selected"),f.scrollable&&((t=e.parent().position().left)-21<0?E.animate({scrollLeft:"+="+(t-50)},300):t+120>E.width()&&E.animate({scrollLeft:"+="+(t+140-E.width())},300)),f.onchange&&f.onchange(v[e.attr("href").slice(1)]),k(),setTimeout(function(){w.children().css({transition:""})},100)))}function k(){if(!f.vertical){var e,t=w.find("li.red-ui-tab"),o=t.filter(":not(.hide-tab)"),t=t.filter(".hide-tab"),n=c.width(),i=o.length;if(f.collapsible){var a=m.children().length,s=m.children(":visible").length;if((e=n-m.width()-10)<=120||e<198&&5<s){var r=m.find("a:last").prev();for(m.children().length;r.is(":not(:visible)");)r=r.prev(),0;(e<=120||6<s)&&r.hide(),e=Math.max(120,n-m.width()-10)}else 40<n-(e=s!==a?s<6?120:198:e)-m.width()&&m.find("a:not(:visible):first").show(),e=n-m.width()-10;o.css({width:e})}else l=(d=100*(e=(n-12-6*i)/i)/n+"%")+"%",f.scrollable?(e=Math.max(e,140),d=e+"px",l=0,a=Math.max(c.width(),12+(e+6)*i),w.width(a),x()):f.hasOwnProperty("minimumActiveTabWidth")&&(l=e<f.minimumActiveTabWidth?(e=(n-12-f.minimumActiveTabWidth-6*--i)/i,d=100*e/n+"%",f.minimumActiveTabWidth+"px"):0),o.css({width:d}),t.css({width:"0px"}),e<50?(w.find(".red-ui-tab-icon").hide(),w.find(".red-ui-tab-label").css({paddingLeft:Math.min(12,Math.max(0,e-38))+"px"})):(w.find(".red-ui-tab-icon").show(),w.find(".red-ui-tab-label").css({paddingLeft:""})),0!==l&&(w.find("li.red-ui-tab.active").css({width:f.minimumActiveTabWidth}),w.find("li.red-ui-tab.active .red-ui-tab-icon").show(),w.find("li.red-ui-tab.active .red-ui-tab-label").css({paddingLeft:""}))}}function T(e){f.onselect&&0<(o=w.find("li.red-ui-tab.selected")).length&&(o.removeClass("selected"),D());var t,o=w.find("a[href='#"+e+"']").parent();o.hasClass("active")&&(0<(t=0===(t=C(o)).length?j(o):t).length?_(t.find("a")):f.onchange&&f.onchange(null)),o.remove(),v[e].pinned&&b--,f.onremove&&f.onremove(v[e]),delete v[e],k(),h&&(h.remove(),h=null)}function C(e){for(var t=(e=e||w.find("li.active")).prev();0<t.length&&t.hasClass("hide-tab");)t=t.prev();return t}function j(e){for(var t=(e=e||w.find("li.active")).next();0<t.length&&t.hasClass("hide-tab");)t=t.next();return t}function L(t){var o,e;v[t]&&!(o=w.find("a[href='#"+t+"']").parent()).hasClass("hide-tab")&&(o.hasClass("active")&&(0<(e=0===(e=C(o)).length?j(o):e).length?_(e.find("a")):f.onchange&&f.onchange(null)),o.removeClass("active"),o.one("transitionend",function(e){o.addClass("hide"),k(),f.onhide&&f.onhide(v[t]),setTimeout(function(){x()},200)}),o.addClass("hide-tab"),o.css({width:0}))}c.addClass("red-ui-tabs"),f.vertical&&c.addClass("red-ui-tabs-vertical"),f.addButton&&(c.addClass("red-ui-tabs-add"),(o=$('<div class="red-ui-tab-button red-ui-tabs-add"><a href="#"><i class="fa fa-plus"></i></a></div>').appendTo(c)).find("a").on("click",function(e){e.preventDefault(),"function"==typeof f.addButton?f.addButton():"string"==typeof f.addButton&&RED.actions.invoke(f.addButton)}),"string"==typeof f.addButton&&(e=f.addButton,f.addButtonCaption&&(e=f.addButtonCaption),RED.popover.tooltip(o,e,f.addButton)),w.on("dblclick",function(e){var t=w.children(),o=e.clientX,n=0;t.each(function(e){if($(this).offset().left>o)return!1;n=e+1}),"function"==typeof f.addButton?f.addButton({index:n}):"string"==typeof f.addButton&&RED.actions.invoke(f.addButton,{index:n})})),f.searchButton&&(c.addClass("red-ui-tabs-search"),(o=$('<div class="red-ui-tab-button red-ui-tabs-search"><a href="#"><i class="fa fa-list-ul"></i></a></div>').appendTo(c)).find("a").on("click",function(e){e.preventDefault(),"function"==typeof f.searchButton?f.searchButton():"string"==typeof f.searchButton&&RED.actions.invoke(f.searchButton)}),"string"==typeof f.searchButton&&(e=f.searchButton,f.searchButtonCaption&&(e=f.searchButtonCaption),RED.popover.tooltip(o,e,f.searchButton))),f.menu&&(c.addClass("red-ui-tabs-menu"),o=(t=$('<div class="red-ui-tab-button red-ui-tabs-menu"><a href="#"><i class="fa fa-caret-down"></i></a></div>').appendTo(c)).find("a"),n=!1,o.on("click",function(e){e.stopPropagation(),e.preventDefault(),n?(i.remove(),n=!1):(n=!0,e=[],"function"==typeof f.searchButton?e=f.menu():Array.isArray(f.menu)?e=f.menu:"function"==typeof f.menu&&(e=f.menu()),(i=RED.menu.init({options:e})).attr("id",f.id+"-menu"),i.css({position:"absolute"}),i.appendTo("body"),e=t.offset(),i.css({top:e.top+t.height()-2+"px",left:e.left-i.width()+t.width()+"px"}),$(".red-ui-menu.red-ui-menu-dropdown").hide(),$(document).on("click.red-ui-tabmenu",function(e){$(document).off("click.red-ui-tabmenu"),n=!1,i.remove()}),i.show())})),f.scrollable&&(c.addClass("red-ui-tabs-scrollable"),E.addClass("red-ui-tabs-scroll-container"),E.on("scroll",function(e){x()}),E.on("wheel",function(e){var t;0===e.originalEvent.deltaX&&(e.preventDefault(),t=E.scrollLeft(),t-=e.originalEvent.deltaY,E.scrollLeft(t))}),(a=$('<div class="red-ui-tab-button red-ui-tab-scroll red-ui-tab-scroll-left"><a href="#" style="display:none;"><i class="fa fa-caret-left"></i></a></div>').appendTo(c).find("a")).on("mousedown",function(e){u(e,e.shiftKey?"-="+E.scrollLeft():"-=150")}).on("click",function(e){e.preventDefault()}),(s=$('<div class="red-ui-tab-button red-ui-tab-scroll red-ui-tab-scroll-right"><a href="#" style="display:none;"><i class="fa fa-caret-right"></i></a></div>').appendTo(c).find("a")).on("mousedown",function(e){u(e,e.shiftKey?"+="+(E[0].scrollWidth-E.width()-E.scrollLeft()):"+=150")}).on("click",function(e){e.preventDefault()})),f.collapsible&&(c.addClass("red-ui-tabs-collapsible"),m=$('<div class="red-ui-tab-link-buttons"></div>').appendTo(c),!1!==f.menu&&((r=$('<a href="#"><i class="fa fa-caret-down"></i></a>').appendTo(m)).addClass("red-ui-tab-link-button-menu"),r.on("click",function(e){e.stopPropagation(),e.preventDefault(),h||(n=[],w.children().each(function(e,t){var o=$(t).data("tabId"),t={id:"red-ui-tabs-menu-option-"+o,icon:v[o].iconClass||I,label:v[o].name,onselect:function(){_(o)}};n.push(t)}),n=[].concat(n),(h=RED.menu.init({options:n})).css({position:"absolute"}),h.appendTo("body"));var n,e=r.offset();h.css({top:e.top+r.height()-2+"px",left:e.left-h.width()+r.width()+"px"}),h.is(":visible")?$(document).off("click.red-ui-tabmenu"):($(".red-ui-menu.red-ui-menu-dropdown").hide(),$(document).on("click.red-ui-tabmenu",function(e){$(document).off("click.red-ui-tabmenu"),h.hide()})),h.toggle()}))),w.children().first().addClass("active"),w.children().addClass("red-ui-tab"),w.find("li.red-ui-tab a").on("mousedown",function(e){g=e.currentTarget}).on("mouseup",R).on("click",function(e){e.preventDefault()}).on("dblclick",function(e){e.stopPropagation(),e.preventDefault()}),setTimeout(function(){k()},0);var S={addTab:function(t,e){f.onselect&&0<(n=w.find("li.red-ui-tab.selected")).length&&(n.removeClass("selected"),D()),v[t.id]=t;var o=$("<li/>",{class:"red-ui-tab"}),n=(0===(e=0===w.children().length?void 0:e)?o.prependTo(w):0<e?o.insertAfter(w.find("li:nth-child("+e+")")):o.appendTo(w),o.attr("id","red-ui-tab-"+t.id.replace(".","-")),o.data("tabId",t.id),(f.maximumTabWidth||t.maximumTabWidth)&&o.css("maxWidth",(f.maximumTabWidth||t.maximumTabWidth)+"px"),$("<a/>",{href:"#"+t.id,class:"red-ui-tab-label"}).appendTo(o));t.icon?$("<i>",{class:"red-ui-tab-icon",style:"mask-image: url("+t.icon+"); -webkit-mask-image: url("+t.icon+");"}).appendTo(n):t.iconClass&&$("<i>",{class:"red-ui-tab-icon "+t.iconClass}).appendTo(n);$("<span/>",{class:"red-ui-text-bidi-aware"}).text(t.label).appendTo(n).attr("dir",RED.text.bidi.resolveBaseTextDir(t.label)),f.collapsible&&(o.addClass("red-ui-tab-pinned"),i=$('<a href="#'+t.id+'" class="red-ui-tab-link-button"></a>'),t.pinned?0===b?i.prependTo(m):i.insertAfter(m.find("a.red-ui-tab-link-button-pinned:last")):!1!==f.menu?i.insertBefore(m.find("a:last")):i.appendTo(m),i.attr("id",o.attr("id")+"-link-button"),(t.iconClass?$("<i>",{class:t.iconClass}):$("<i>",{class:I})).appendTo(i),i.on("click",function(e){e.preventDefault(),_(t.id)}),i.data("tabId",t.id),t.pinned&&(i.addClass("red-ui-tab-link-button-pinned"),b++),RED.popover.tooltip($(i),t.name,t.action),f.onreorder&&(s=[],i.draggable({distance:10,axis:"x",containment:".red-ui-tab-link-buttons",start:function(e,t){if(N=!0,$(".red-ui-tab-link-buttons").width($(".red-ui-tab-link-buttons").width()),P)return P=!1;m.children().each(function(e){s[e]={el:$(this),text:$(this).text(),left:$(this).position().left,width:$(this).width(),menu:$(this).hasClass("red-ui-tab-link-button-menu")},$(this).is(i)&&(r=a=e)}),m.children().each(function(e){e!==a&&$(this).css({position:"absolute",left:s[e].left+"px",width:s[e].width+2,transition:"left 0.3s"})}),i.hasClass("active")||i.css({zIndex:1})},drag:function(e,t){t.position.left+=s[a].left;for(var o=t.position.left+s[a].width/2,n=0;n<s.length;n++)if(n!==a&&!s[n].menu&&!s[n].el.is(":not(:visible)")&&o>s[n].left&&o<s[n].left+s[n].width){n<a?(s[n].left+=s[a].width+8,s[a].el.detach().insertBefore(s[n].el)):(s[n].left-=s[a].width+8,s[a].el.detach().insertAfter(s[n].el)),s[n].el.css({left:s[n].left+"px"}),s.splice(n,0,s.splice(a,1)[0]),a=n;break}},stop:function(e,t){var o;N=!1,m.children().css({position:"relative",left:"",transition:""}),$(".red-ui-tab-link-buttons").width("auto"),i.css({zIndex:""}),k(),r!==a&&(h&&(h.remove(),h=null),o=$.makeArray(m.children().map(function(){return $(this).data("tabId")})),S.order(o),f.onreorder(o))}}))),n.on("mousedown",function(e){g=e.currentTarget}),n.on("mouseup",R),n.on("click",function(e){e.preventDefault()}),n.on("dblclick",function(e){e.stopPropagation(),e.preventDefault()}),$('<span class="red-ui-tabs-fade"></span>').appendTo(o),t.closeable&&(o.addClass("red-ui-tabs-closeable"),(d=$("<a/>",{href:"#",class:"red-ui-tab-close"}).appendTo(o)).append('<i class="fa fa-times" />'),d.on("click",function(e){e.preventDefault(),T(t.id)}),RED.popover.tooltip(d,RED._("workspace.hideFlow"))),t.hideable&&(o.addClass("red-ui-tabs-closeable"),(d=$("<a/>",{href:"#",class:"red-ui-tab-close red-ui-tab-hide"}).appendTo(o)).append('<i class="fa fa-eye" />'),d.append('<i class="fa fa-eye-slash" />'),d.on("click",function(e){e.preventDefault(),L(t.id)}),RED.popover.tooltip(d,RED._("workspace.hideFlow")));var i,a,s,r,d,l,c,u,p,e=$('<span class="red-ui-tabs-badges"></span>').appendTo(o);f.onselect&&($('<i class="red-ui-tabs-badge-changed fa fa-circle"></i>').appendTo(e),$('<i class="red-ui-tabs-badge-selected fa fa-check-circle"></i>').appendTo(e)),RED.popover.tooltip(n,function(){return RED.utils.sanitize(t.label)}),f.onadd&&f.onadd(t),1==w.find("li.red-ui-tab").length&&_(n),f.onreorder&&!f.collapsible&&(u=[],o.draggable({axis:"x",distance:20,start:function(e,t){if(P)return P=!1;N=!0,l=[],u=[],w.children().each(function(e){u[e]={el:$(this),text:$(this).text(),left:$(this).position().left,width:$(this).width()},$(this).is(o)&&(p=c=e),l.push($(this).data("tabId"))}),w.children().each(function(e){e!==c&&$(this).css({position:"absolute",left:u[e].left+"px",width:u[e].width+2,transition:"left 0.3s"})}),o.hasClass("active")||o.css({zIndex:1})},drag:function(e,t){t.position.left+=u[c].left+E.scrollLeft();for(var o=t.position.left+u[c].width/2-E.scrollLeft(),n=0;n<u.length;n++)if(n!==c&&o>u[n].left&&o<u[n].left+u[n].width){n<c?(u[n].left+=u[c].width+8,u[c].el.detach().insertBefore(u[n].el)):(u[n].left-=u[c].width+8,u[c].el.detach().insertAfter(u[n].el)),u[n].el.css({left:u[n].left+"px"}),u.splice(n,0,u.splice(c,1)[0]),c=n;break}},stop:function(e,t){N=!1,w.children().css({position:"relative",left:"",transition:""}),o.hasClass("active")||o.css({zIndex:""}),k(),p!==c&&f.onreorder(l,$.makeArray(w.children().map(function(){return $(this).data("tabId")}))),_(u[c].el.data("tabId"))}})),setTimeout(function(){k()},10),h&&(h.remove(),h=null),y&&S.order(y)},removeTab:T,activateTab:_,nextTab:function(){var e=j();0<e.length&&_(e.find("a"))},previousTab:function(){var e=C();0<e.length&&_(e.find("a"))},resize:k,count:function(){return w.find("li.red-ui-tab:not(.hide)").length},activeIndex:function(){return w.find("li.active").index()},contains:function(e){return 0<w.find("a[href='#"+e+"']").length},showTab:function(e){var t;v[e]&&(t=w.find("a[href='#"+e+"']").parent()).hasClass("hide-tab")&&(t.removeClass("hide-tab").removeClass("hide"),1===w.find("li.red-ui-tab:not(.hide-tab)").length&&_(t.find("a")),k(),f.onshow&&f.onshow(v[e]))},hideTab:L,renameTab:function(e,t){v[e].label=t,w.find("a[href='#"+e+"']").find("span.red-ui-text-bidi-aware").text(t).attr("dir",RED.text.bidi.resolveBaseTextDir(t)),k()},listTabs:function(){return $.makeArray(w.children().map(function(){return $(this).data("tabId")}))},selection:p,clearSelection:function(){var e;f.onselect&&0<(e=w.find("li.red-ui-tab.selected")).length&&(e.removeClass("selected"),D())},order:function(e){y=e;for(var t=$.makeArray(w.children().map(function(){return $(this).data("tabId")})),o=!0,n=0;n<e.length;n++)if(e[n]!==t[n]){o=!1;break}if(!o){var i={},a=(w.children().detach().each(function(){i[$(this).data("tabId")]=$(this)}),{});for(f.collapsible&&m.children().detach().each(function(){var e=$(this).data("tabId");a[e=e||"__menu__"]=$(this)}),n=0;n<e.length;n++)i[e[n]]&&(i[e[n]].appendTo(w),f.collapsible&&a[e[n]].appendTo(m),delete i[e[n]]);for(n in i)i.hasOwnProperty(n)&&(i[n].appendTo(w),f.collapsible&&a[n].appendTo(m));f.collapsible&&(a.__menu__.appendTo(m),k())}}};return S}}}(),RED.stack={create:function(n){function i(){var t,e;0<r.length&&(t=0,r.forEach(function(e){t+=e.header.outerHeight()}),e=a.innerHeight(),s=e-t-(r.length-1),r.forEach(function(e){e.contentWrap.height(s)}))}var a=n.container,s=(a.addClass("red-ui-stack"),0),r=[],d=!0;return n.fill&&n.singleExpanded&&($(window).on("resize",i),$(window).on("focus",i)),{add:function(t){r.push(t),t.container=$('<div class="red-ui-palette-category">').appendTo(a),d||t.container.hide();var e,o=$('<div class="red-ui-palette-header"></div>').appendTo(t.container);return t.header=o,t.contentWrap=$("<div></div>",{style:"position:relative"}).appendTo(t.container),n.fill&&t.contentWrap.css("height",s),t.content=$("<div></div>").appendTo(t.contentWrap),!1!==t.collapsible?(o.on("click",function(){if(n.singleExpanded)if(t.isExpanded())2===r.length&&(r[0]===t?(r[0].collapse(),r[1].expand()):(r[1].collapse(),r[0].expand()));else{for(var e=0;e<r.length;e++)r[e].isExpanded()&&r[e].collapse();t.expand()}else t.toggle()}),e=$('<i class="fa fa-angle-down"></i>').appendTo(o),t.expanded?(t.container.addClass("expanded"),e.addClass("expanded")):t.contentWrap.hide()):($('<i style="opacity: 0.5;" class="fa fa-angle-down expanded"></i>').appendTo(o),o.css("cursor","default")),t.title=$("<span></span>").html(t.title).appendTo(o),t.toggle=function(){return t.isExpanded()?(t.collapse(),!1):(t.expand(),!0)},t.expand=function(){if(!t.isExpanded())return t.onexpand&&t.onexpand.call(t),n.singleExpanded&&r.forEach(function(e){e!==t&&e.collapse()}),e.addClass("expanded"),t.container.addClass("expanded"),t.contentWrap.slideDown(200),!0},t.collapse=function(){if(t.isExpanded())return e.removeClass("expanded"),t.container.removeClass("expanded"),t.contentWrap.slideUp(200),!0},t.isExpanded=function(){return t.container.hasClass("expanded")},n.fill&&n.singleExpanded&&i(),t},hide:function(){return d=!1,r.forEach(function(e){e.container.hide()}),this},show:function(){return d=!0,r.forEach(function(e){e.container.show()}),this},resize:function(){i()}}}},function(l){function e(e,t){return{option:(e=RED.utils.parseContextKey(e,t&&t.value)).store,value:e.key}}function t(e,t){return t&&(t="string"==typeof t?t:t.value)!==RED.settings.context.default?"#:("+t+")::"+e:e}function o(e,t){e.css("pointer-events","none"),e.css("flex-grow",0),e.css("position","relative"),e.css("overflow","visible"),l("<div></div>").text(t).css({position:"absolute",bottom:"-2px",right:"5px","font-size":"0.7em",opacity:.3}).appendTo(e),this.elementDiv.show()}var n,s={msg:{value:"msg",label:"msg.",validate:RED.utils.validatePropertyExpression,autoComplete:(n=[{value:"payload"},{value:"topic",source:["mqtt","inject","rbe"]},{value:"action",source:["mqtt"]},{value:"complete",source:["join"]},{value:"contentType",source:["mqtt"]},{value:"cookies",source:["http request","http response"]},{value:"correlationData",source:["mqtt"]},{value:"delay",source:["delay","trigger"]},{value:"encoding",source:["file"]},{value:"error",source:["catch"]},{value:"error.message",source:["catch"]},{value:"error.source",source:["catch"]},{value:"error.source.id",source:["catch"]},{value:"error.source.type",source:["catch"]},{value:"error.source.name",source:["catch"]},{value:"filename",source:["file","file in"]},{value:"flush",source:["delay"]},{value:"followRedirects",source:["http request"]},{value:"headers",source:["http response","http request"]},{value:"host",source:["tcp request","http request"]},{value:"ip",source:["udp out"]},{value:"kill",source:["exec"]},{value:"messageExpiryInterval",source:["mqtt"]},{value:"method",source:["http request"]},{value:"options",source:["xml"]},{value:"parts",source:["split","join","batch","sort"]},{value:"pid",source:["exec"]},{value:"port",source:["tcp request"," udp out"]},{value:"qos",source:["mqtt"]},{value:"rate",source:["delay"]},{value:"rejectUnauthorized",source:["http request"]},{value:"req",source:["http in"]},{value:"req.body",source:["http in"]},{value:"req.headers",source:["http in"]},{value:"req.query",source:["http in"]},{value:"req.params",source:["http in"]},{value:"req.cookies",source:["http in"]},{value:"req.files",source:["http in"]},{value:"requestTimeout",source:["http request"]},{value:"reset",source:["delay","trigger","join","rbe"]},{value:"responseCookies",source:["http request"]},{value:"responseTopic",source:["mqtt"]},{value:"responseURL",source:["http request"]},{value:"restartTimeout",source:["join"]},{value:"retain",source:["mqtt"]},{value:"schema",source:["json"]},{value:"select",source:["html"]},{value:"statusCode",source:["http response","http request"]},{value:"status",source:["status"]},{value:"status.text",source:["status"]},{value:"status.source",source:["status"]},{value:"status.source.type",source:["status"]},{value:"status.source.id",source:["status"]},{value:"status.source.name",source:["status"]},{value:"target",source:["link call"]},{value:"template",source:["template"]},{value:"toFront",source:["delay"]},{value:"url",source:["http request"]},{value:"userProperties",source:["mqtt"]},{value:"_session",source:["websocket out","tcp out"]}],function(r){var d=[];return n.forEach(e=>{var t=e.value,e=(e.source||[]).join(","),o=c(t,r),n=c(e,r);if(o.found||n.found){var i=l("<div>",{style:"display: flex"});const a=l("<div/>",{style:"font-family: var(--red-ui-monospace-font); white-space:nowrap; overflow: hidden; flex-grow:1"});if(a.append(u(o)),a.appendTo(i),e){const s=l("<div>").css({"font-size":"0.8em"});s.append(u(n)),s.appendTo(i)}d.push({value:t,label:i,i:(o.found?o:n).index})}}),d.sort(function(e,t){return e.i-t.i}),d})},flow:{value:"flow",label:"flow.",hasValue:!0,options:[],validate:RED.utils.validatePropertyExpression,parse:e,export:t,valueLabel:o},global:{value:"global",label:"global.",hasValue:!0,options:[],validate:RED.utils.validatePropertyExpression,parse:e,export:t,valueLabel:o},str:{value:"str",label:"string",icon:"red/images/typedInput/az.svg"},num:{value:"num",label:"number",icon:"red/images/typedInput/09.svg",validate:/^[+-]?[0-9]*\.?[0-9]*([eE][-+]?[0-9]+)?$/},bool:{value:"bool",label:"boolean",icon:"red/images/typedInput/bool.svg",options:["true","false"]},json:{value:"json",label:"JSON",icon:"red/images/typedInput/json.svg",validate:function(e){try{return JSON.parse(e),!0}catch(e){return!1}},expand:function(){var o=this,e=this.value();try{e=JSON.stringify(JSON.parse(e),null,4)}catch(e){}RED.editor.editJSON({value:e,stateId:RED.editor.generateViewStateId("typedInput",o,"json"),focus:!0,complete:function(e){var t=e;try{t=JSON.stringify(JSON.parse(e))}catch(e){}o.value(t)}})}},re:{value:"re",label:"regular expression",icon:"red/images/typedInput/re.svg"},date:{value:"date",label:"timestamp",icon:"fa fa-clock-o",hasValue:!1},jsonata:{value:"jsonata",label:"expression",icon:"red/images/typedInput/expr.svg",validate:function(e){try{return jsonata(e),!0}catch(e){return!1}},expand:function(){var t=this;RED.editor.editExpression({value:this.value().replace(/\t/g,"\n"),stateId:RED.editor.generateViewStateId("typedInput",t,"jsonata"),focus:!0,complete:function(e){t.value(e.replace(/\n/g,"\t"))}})}},bin:{value:"bin",label:"buffer",icon:"red/images/typedInput/bin.svg",expand:function(){var t=this;RED.editor.editBuffer({value:this.value(),stateId:RED.editor.generateViewStateId("typedInput",t,"bin"),focus:!0,complete:function(e){t.value(e)}})}},env:{value:"env",label:"env variable",icon:"red/images/typedInput/env.svg"},node:{value:"node",label:"node",icon:"red/images/typedInput/target.svg",valueLabel:function(e,t){var o,n,t=RED.nodes.node(t),i=l("<div>",{class:"red-ui-search-result-node"}).css({"margin-top":"2px","margin-left":"3px"}).appendTo(e),e=l("<span>").css({"line-height":"32px","margin-left":"6px"}).appendTo(e);t?(o=RED.utils.getNodeColor(t.type,t._def),n=RED.utils.getNodeIcon(t._def,t),"tab"===t.type&&(o="#C0DEED"),i.css("backgroundColor",o),o=l("<div/>",{class:"red-ui-palette-icon-container"}).appendTo(i),RED.utils.createIconElement(n,o,!0),n=RED.utils.getNodeLabel(t,t.id),e.text(n)):i.css({backgroundColor:"#eee","border-style":"dashed"})},expand:function(){var t=this;RED.tray.hide(),RED.view.selectNodes({single:!0,selected:[t.value()],onselect:function(e){t.value(e.id),RED.tray.show()},oncancel:function(){RED.tray.show()}})}},cred:{value:"cred",label:"credential",icon:"fa fa-lock",inputType:"password",valueLabel:function(t,e){var o,n,i,a=this,s=(t.css("pointer-events","none"),t.css("flex-grow",0),this.elementDiv.hide(),l("<div>").css({position:"absolute",right:"6px",top:"6px","pointer-events":"all"}).appendTo(t)),r=l('<button type="button" class="red-ui-button red-ui-button-small"></button>').css({width:"20px"}).appendTo(s).on("click",function(e){e.preventDefault();var t=a.input[0].selectionStart;"text"===a.input.attr("type")?(a.input.attr("type","password"),d.removeClass("fa-eye-slash").addClass("fa-eye")):(a.input.attr("type","text"),d.removeClass("fa-eye").addClass("fa-eye-slash")),setTimeout(function(){a.input.focus(),a.input[0].setSelectionRange(t,t)},50)}).hide(),d=l('<i class="fa fa-eye"></i>').css("margin-left","-2px").appendTo(r);"__PWRD__"===e?(o=l('<div><i class="fa fa-asterisk"></i><i class="fa fa-asterisk"></i><i class="fa fa-asterisk"></i><i class="fa fa-asterisk"></i><i class="fa fa-asterisk"></i></div>').css({padding:"6px 6px",borderRadius:"4px"}).addClass("red-ui-typedInput-value-label-inactive").appendTo(t),n=l('<button type="button" class="red-ui-button red-ui-button-small"><i class="fa fa-pencil"></i></button>').appendTo(s).on("click",function(e){e.preventDefault(),o.hide(),t.css("background","none"),t.css("pointer-events","none"),a.input.val(""),a.element.val(""),a.elementDiv.show(),n.hide(),i.show(),r.show(),setTimeout(function(){a.input.focus()},50)}),i=l('<button type="button" class="red-ui-button red-ui-button-small"><i class="fa fa-times"></i></button>').css("margin-left","3px").appendTo(s).on("click",function(e){e.preventDefault(),o.show(),t.css("background",""),a.input.val("__PWRD__"),a.element.val("__PWRD__"),a.elementDiv.hide(),n.show(),i.hide(),r.hide(),a.input.attr("type","password"),d.removeClass("fa-eye-slash").addClass("fa-eye")}).hide()):(t.css("background","none"),t.css("pointer-events","none"),this.elementDiv.show(),r.show())}}};function c(e,t){var o=e.toLowerCase().indexOf(t.toLowerCase()),t=-1<o?t.length:0;return{index:o,found:-1<o,pre:e.substring(0,o),match:e.substring(o,o+t),post:e.substring(o+t)}}function u(e){const t=[];return e.pre&&t.push(l("<span/>").text(e.pre)),e.match&&t.push(l("<span/>",{style:"font-weight: bold; color: var(--red-ui-text-color-link);"}).text(e.match)),e.post&&t.push(l("<span/>").text(e.post)),t}function r(e,t){if(e.multiple){var o={},n=[];t.split(",").forEach(function(e){e&&(o[e]=!0)});for(a=0;a<e.options.length;a++){var i="string"==typeof(op=e.options[a])?op:op.value;o.hasOwnProperty(i)&&(delete o[i],n.push("string"==typeof op?{value:op}:op.value))}return l.isEmptyObject(o)?n:null}for(var a=0;a<e.options.length;a++){if("string"==typeof(op=e.options[a])&&op===t)return{value:t};if(op.value===t)return op}}var d=!1;l.widget("nodered.typedInput",{_create:function(){try{if(!d&&RED&&RED._){for(var e in s)s.hasOwnProperty(e)&&(s[e].label=RED._("typedInput.type."+e,{defaultValue:s[e].label}));var t=RED.settings.context.stores.map(function(e){return{value:e,label:e,icon:'<i class="red-ui-typedInput-icon fa fa-database"></i>'}}).sort(function(e,t){return e.value===RED.settings.context.default?-1:t.value===RED.settings.context.default?1:e.value.localeCompare(t.value)});t.length<2?(s.flow.options=[],s.global.options=[]):(s.flow.options=t,s.global.options=t)}d=!0;var o,n,i=this,a=(this.identifier=this.element.attr("id")||"TypedInput-"+Math.floor(100*Math.random()),this.options.debug&&console.log(this.identifier,"Create",{defaultType:this.options.default,value:this.element.val()}),this.disarmClick=!1,this.input=l('<input class="red-ui-typedInput-input" type="text"></input>'),this.input.insertAfter(this.element),this.input.val(this.element.val()),this.element.addClass("red-ui-typedInput"),this.uiWidth=this.element.outerWidth(),this.elementDiv=this.input.wrap("<div>").parent().addClass("red-ui-typedInput-input-wrap"),this.uiSelect=this.elementDiv.wrap("<div>").parent(),this.element.attr("style"));null!==(o=/width\s*:\s*(calc\s*\(.*\)|\d+(%|px))/i.exec(a))?(this.input.css("width","100%"),this.uiSelect.width(o[1]),this.uiWidth=null):0!==this.uiWidth&&this.uiSelect.width(this.uiWidth),["Right","Left"].forEach(function(e){var t=i.element.css("margin"+e);i.uiSelect.css("margin"+e,t),i.input.css("margin"+e,0)}),["type","placeholder","autocomplete","data-i18n"].forEach(function(e){var t=i.element.attr(e);i.input.attr(e,t)}),this.defaultInputType=this.input.attr("type"),this.oldValues={},this.uiSelect.addClass("red-ui-typedInput-container"),this.element.attr("type","hidden"),!this.options.types&&this.options.type?this.options.types=[this.options.type]:this.options.types=this.options.types||Object.keys(s),this.selectTrigger=l('<button type="button" class="red-ui-typedInput-type-select" tabindex="0"></button>').prependTo(this.uiSelect),l('<i class="red-ui-typedInput-icon fa fa-caret-down"></i>').toggle(1<this.options.types.length).appendTo(this.selectTrigger),this.selectLabel=l('<span class="red-ui-typedInput-type-label"></span>').appendTo(this.selectTrigger),this.valueLabelContainer=l('<div class="red-ui-typedInput-value-label">').appendTo(this.uiSelect),this.types(this.options.types),this.options.typeField?(this.typeField=l(this.options.typeField).hide(),(n=this.typeField.val())&&this.typeMap[n]&&(this.options.default=n)):this.typeField=l("<input>",{type:"hidden"}).appendTo(this.uiSelect),this.input.on("focus",function(){i.uiSelect.addClass("red-ui-typedInput-focus")}),this.input.on("blur",function(){i.uiSelect.removeClass("red-ui-typedInput-focus")}),this.input.on("change",function(){i.validate(),i.element.val(i.value()),i.element.trigger("change",[i.propertyType,i.value()])}),this.input.on("keyup",function(e){i.validate(),i.element.val(i.value()),i.element.trigger("keyup",e)}),this.input.on("paste",function(e){i.validate(),i.element.val(i.value()),i.element.trigger("paste",e)}),this.input.on("keydown",function(e){i.typeMap[i.propertyType].autoComplete||37<=e.keyCode&&e.keyCode<=40&&e.stopPropagation()}),this.selectTrigger.on("click",function(e){e.preventDefault(),e.stopPropagation(),i._showTypeMenu()}),this.selectTrigger.on("keydown",function(e){40===e.keyCode&&i._showTypeMenu(),e.stopPropagation()}).on("focus",function(){i.uiSelect.addClass("red-ui-typedInput-focus")}).on("blur",function(){!1===i.typeMap[i.propertyType].hasValue&&i.uiSelect.removeClass("red-ui-typedInput-focus")}),this.optionSelectTrigger=l('<button type="button" tabindex="0" class="red-ui-typedInput-option-trigger" style="display:inline-block"><span class="red-ui-typedInput-option-caret"><i class="red-ui-typedInput-icon fa fa-caret-down"></i></span></button>').appendTo(this.uiSelect),this.optionSelectLabel=l('<span class="red-ui-typedInput-option-label"></span>').prependTo(this.optionSelectTrigger),this.optionSelectTrigger.on("click",function(e){e.preventDefault(),e.stopPropagation(),i._showOptionSelectMenu()}).on("keydown",function(e){40===e.keyCode&&i._showOptionSelectMenu(),e.stopPropagation()}).on("blur",function(){i.uiSelect.removeClass("red-ui-typedInput-focus")}).on("focus",function(){i.uiSelect.addClass("red-ui-typedInput-focus")}),this.optionExpandButton=l('<button type="button" tabindex="0" class="red-ui-typedInput-option-expand" style="display:inline-block"></button>').appendTo(this.uiSelect),this.optionExpandButtonIcon=l('<i class="red-ui-typedInput-icon fa fa-ellipsis-h"></i>').appendTo(this.optionExpandButton),this.type(this.typeField.val()||this.options.default||this.typeList[0].value),this.typeChanged=!!this.options.default}catch(e){console.log(e.stack)}},_showTypeMenu:function(){var e;1<this.typeList.length?(this._showMenu(this.menu,this.selectTrigger),e=this.menu.find("[value='"+this.propertyType+"']"),setTimeout(function(){e.trigger("focus")},120)):this.input.trigger("focus")},_showOptionSelectMenu:function(){var e;this.optionMenu&&(this.optionMenu.css({minWidth:this.optionSelectLabel.width()}),this._showMenu(this.optionMenu,this.optionSelectTrigger),e=this.optionValue,null!==this.optionValue&&void 0!==this.optionValue||(e=this.value()),(e=0===(e=this.optionMenu.find("[value='"+e+"']")).length?this.optionMenu.children(":first"):e).trigger("focus"))},_hideMenu:function(e){var t;l(document).off("mousedown.red-ui-typedInput-close-property-select"),e.hide(),e.css({height:"auto"}),e.opts.multiple&&(t=[],e.find('input[type="checkbox"]').each(function(){l(this).prop("checked")&&t.push(l(this).data("value"))}),e.callback(t)),(this.elementDiv.is(":visible")?this.input:this.optionSelectTrigger.is(":visible")?this.optionSelectTrigger:this.selectTrigger).trigger("focus")},_createMenu:function(e,n,i){var a=this,s=l("<div>").addClass("red-ui-typedInput-options red-ui-editor-dialog");return s.opts=n,s.callback=i,e.forEach(function(t){"string"==typeof t&&(t={value:t,label:t});var o,e=l('<a href="#"></a>').attr("value",t.value).appendTo(s);t.label&&e.text(t.label),t.title&&e.prop("title",t.title),t.icon?(0===t.icon.indexOf("<")?l(t.icon):-1!==t.icon.indexOf("/")?l("<i>",{class:"red-ui-typedInput-icon",style:"mask-image: url("+t.icon+"); -webkit-mask-image: url("+t.icon+");"}):l("<i>",{class:"red-ui-typedInput-icon "+t.icon})).prependTo(e):e.css({paddingLeft:"18px"}),t.icon||t.label||e.text(t.value),n.multiple&&(o=l('<input type="checkbox">').css("pointer-events","none").data("value",t.value).prependTo(e).on("mousedown",function(e){e.preventDefault()})),e.on("click",function(e){e.preventDefault(),e.stopPropagation(),n.multiple?o.prop("checked",!o.prop("checked")):(i(t.value),a._hideMenu(s))})}),s.css({display:"none"}),s.appendTo(document.body),s.on("keydown",function(e){40===e.keyCode?(e.preventDefault(),l(this).children(":focus").next().trigger("focus")):38===e.keyCode?(e.preventDefault(),l(this).children(":focus").prev().trigger("focus")):27===e.keyCode&&(e.preventDefault(),a._hideMenu(s)),e.stopPropagation()}),s},_showMenu:function(t,o){var n,i,e,a,s;this.disarmClick?this.disarmClick=!1:(t.opts.multiple&&(n={},this.value().split(",").forEach(function(e){n[e]=!0}),t.find('input[type="checkbox"]').each(function(){l(this).prop("checked",n[l(this).data("value")])})),i=this,e=o.offset(),s=o.height(),a=t.height(),(s=s+e.top)+a-l(document).scrollTop()>l(window).height()&&(s-=s+a-l(window).height()+5),s<0&&(t.height(a+s),s=0),t.css({top:s+"px",left:e.left+"px"}),t.slideDown(100),this._delay(function(){i.uiSelect.addClass("red-ui-typedInput-focus"),l(document).on("mousedown.red-ui-typedInput-close-property-select",function(e){l(e.target).closest(t).length||i._hideMenu(t),l(e.target).closest(o).length&&(i.disarmClick=!0,e.preventDefault())})}))},_getLabelWidth:function(e,t){var o,n,i,a=e.outerWidth();0===a?(o=l('<div class="red-ui-editor"></div>').css({position:"absolute","white-space":"nowrap",top:-2e3}).appendTo(document.body),n=l('<div class="red-ui-typedInput-container"></div>').appendTo(o),i=e.clone().appendTo(n),setTimeout(function(){a=i.outerWidth(),o.remove(),t(a)},50)):t(a)},_updateOptionSelectLabel:function(e){var t,o=this.typeMap[this.propertyType];this.optionSelectLabel.empty(),o.hasValue?(this.valueLabelContainer.empty(),this.valueLabelContainer.show()):this.valueLabelContainer.hide(),this.typeMap[this.propertyType].valueLabel&&(o.multiple?this.typeMap[this.propertyType].valueLabel.call(this,o.hasValue?this.valueLabelContainer:this.optionSelectLabel,e):this.typeMap[this.propertyType].valueLabel.call(this,o.hasValue?this.valueLabelContainer:this.optionSelectLabel,e.value)),this.typeMap[this.propertyType].valueLabel&&!o.hasValue||(o.multiple?this.optionSelectLabel.text(e.length+" selected"):(e.icon?(0===e.icon.indexOf("<")?l(e.icon):-1!==e.icon.indexOf("/")?l("<img>",{src:(t=e.icon,t=/^red\/images\/typedInput\/.+\.png$/.test(t)?t.replace(/.png$/,".svg"):t),style:"height: 18px;"}):l("<i>",{class:"red-ui-typedInput-icon "+e.icon})).prependTo(this.optionSelectLabel):e.label?this.optionSelectLabel.text(e.label):this.optionSelectLabel.text(e.value),o.hasValue&&(this.optionValue=e.value,this.input.trigger("change",[this.propertyType,this.value()]))))},_destroy:function(){this.optionMenu&&this.optionMenu.remove(),this.menu.remove(),this.uiSelect.remove()},types:function(e){var t=this,o=this.type(),n=(this.typeMap={},void 0===this.typeList);this.typeList=e.map(function(e){e="string"==typeof e?s[e]:e;return t.typeMap[e.value]=e}),this.typeList.length<2?(this.selectTrigger.attr("tabindex",-1),this.selectTrigger.on("mousedown.red-ui-typedInput-focus-block",function(e){e.preventDefault()})):(this.selectTrigger.attr("tabindex",0),this.selectTrigger.off("mousedown.red-ui-typedInput-focus-block")),this.selectTrigger.toggleClass("disabled",1===this.typeList.length),this.selectTrigger.find(".fa-caret-down").toggle(1<this.typeList.length),this.menu&&this.menu.remove(),this.menu=this._createMenu(this.typeList,{},function(e){t.type(e)}),o&&!this.typeMap.hasOwnProperty(o)?n||this.type(this.typeList[0].value):(this.propertyType=null,n||this.type(o)),1!==this.typeList.length||this.typeList[0].icon||this.typeList[0].label&&!1!==this.typeList[0].showLabel?this.selectTrigger.show():this.selectTrigger.hide()},width:function(e){this.uiWidth=e,null!==this.uiWidth&&this.uiSelect.width(this.uiWidth)},value:function(e){var n,t,o,i=this,a=this.typeMap[this.propertyType]||{};if(!arguments.length)return o=this.input.val(),a.export?a.export(o,this.optionValue):o;this.options.debug&&console.log(this.identifier,"----- SET VALUE ------",e),n=[],o=e,a.options?(a.hasValue&&a.parse&&(t=a.parse(e),this.options.debug&&console.log(this.identifier,"new parse",t),e=t.value,o=t.option||t.value),t=[o],a.multiple&&(n=[],t=o.split(",")),t.forEach(function(e){for(var t=0;t<a.options.length;t++){var o=a.options[t];if("string"==typeof o){if(o===e||o===""+e){n.push(i.activeOptions[o]);break}}else if(o.value===e){n.push(o);break}}}),this.options.debug&&console.log(this.identifier,"set value to",e),this.input.val(e),a.multiple?this._updateOptionSelectLabel(n):(0===n.length&&(n=[{value:""}]),this._updateOptionSelectLabel(n[0]))):(this.input.val(e),a.valueLabel&&(this.valueLabelContainer.empty(),a.valueLabel.call(this,this.valueLabelContainer,e))),this.input.trigger("change",[this.type(),e])},type:function(e){if(!arguments.length)return this.propertyType;var t,o,n=this,i=(this.options.debug&&console.log(this.identifier,"----- SET TYPE -----",e),null),a=this.typeMap[e];a&&this.propertyType!==e&&(o=this.typeMap[this.propertyType],i=this.input.val(),o&&this.typeChanged&&(this.options.debug&&console.log(this.identifier,"typeChanged",{previousType:o,previousValue:i}),o.options&&!0!==a.hasValue||!1===o.hasValue?this.oldValues[o.value]=i:this.oldValues._=i,a.options&&!0!==a.hasValue||!1===a.hasValue?this.oldValues.hasOwnProperty(a.value)?(this.options.debug&&console.log(this.identifier,"restored previous (1)",this.oldValues[a.value]),this.input.val(this.oldValues[a.value])):a.options?(t=r(a,i),this.options.debug&&console.log(this.identifier,{previousValue:i,opt:a,validOptions:t}),(i||""===i)&&t?(this.options.debug&&console.log(this.identifier,"restored previous (2)"),this.input.val(i)):"string"==typeof a.default?(this.options.debug&&console.log(this.identifier,"restored previous (3)",a.default),this.input.val(a.default)):Array.isArray(a.default)?(this.options.debug&&console.log(this.identifier,"restored previous (4)",a.default.join(",")),this.input.val(a.default.join(","))):(this.options.debug&&console.log(this.identifier,"restored previous (5)"),this.input.val(""))):(this.options.debug&&console.log(this.identifier,"restored default/blank",a.default||""),this.input.val(a.default||"")):(this.options.debug&&console.log(this.identifier,"restored old/default/blank"),this.input.val(this.oldValues.hasOwnProperty("_")?this.oldValues._:a.default||"")),o.autoComplete&&this.input.autoComplete("destroy")),this.propertyType=e,this.typeChanged=!0,this.typeField&&this.typeField.val(e),this.selectLabel.empty(),a.icon&&!1!==a.showLabel&&(0===a.icon.indexOf("<")?l(a.icon):-1!==a.icon.indexOf("/")?l("<i>",{class:"red-ui-typedInput-icon",style:"mask-image: url("+a.icon+"); -webkit-mask-image: url("+a.icon+"); margin-right: 4px;height: 18px;width:13px"}):l("<i>",{class:"red-ui-typedInput-icon "+a.icon,style:"min-width: 13px; margin-right: 4px;"})).prependTo(this.selectLabel),!1!==a.hasValue&&(!1===a.showLabel||a.icon)||this.selectLabel.text(a.label),a.label?this.selectTrigger.attr("title",a.label):this.selectTrigger.attr("title",""),!1===a.hasValue?this.selectTrigger.addClass("red-ui-typedInput-full-width"):this.selectTrigger.removeClass("red-ui-typedInput-full-width"),this.optionMenu&&(this.optionMenu.remove(),this.optionMenu=null),a.options?(this.optionExpandButton&&(this.optionExpandButton.hide(),this.optionExpandButton.shown=!1),this.optionSelectTrigger&&(this.optionSelectTrigger.css({display:"inline-flex"}),a.hasValue?(this.optionSelectTrigger.css({"flex-grow":0}),this.elementDiv.show()):(this.optionSelectTrigger.css({"flex-grow":1}),this.elementDiv.hide()),this.valueLabelContainer.hide(),this.activeOptions={},a.options.forEach(function(e){"string"==typeof e?n.activeOptions[e]={label:e,value:e}:n.activeOptions[e.value]=e}),n.activeOptions.hasOwnProperty(n.optionValue)||(n.optionValue=null),a.hasValue?(t=this.optionValue||a.options[0],a.parse&&(i="string"==typeof t?{value:t}:t,(o=a.parse(this.input.val(),i)).option&&(t=o.option,this.activeOptions.hasOwnProperty(t)||(o.option=Object.keys(this.activeOptions)[0],t=o.option)),this.input.val(o.value),a.export&&this.element.val(a.export(o.value,o.option||t))),"string"==typeof t?(this.optionValue=t,(t=this.activeOptions.hasOwnProperty(t)?t:Object.keys(this.activeOptions)[0])?this._updateOptionSelectLabel(this.activeOptions[t]):this.optionSelectTrigger.hide()):t?(this.options.debug&&console.log(this.identifier,"HERE",{optionValue:t.value}),this.optionValue=t.value,this._updateOptionSelectLabel(t)):this.optionSelectTrigger.hide()):(i=r(a,this.input.val()),a.multiple?(i||(i=(a.default||[]).map(function(e){return"string"==typeof e?e:e.value}),this.value(i.join(","))),n._updateOptionSelectLabel(i)):i?n._updateOptionSelectLabel(i):"string"==typeof(o=a.options[0])?(this.value(o),n._updateOptionSelectLabel({value:o})):(this.value(o.value),n._updateOptionSelectLabel(o))),this.optionMenu=this._createMenu(a.options,a,function(e){a.multiple?(n._updateOptionSelectLabel(e),a.hasValue||n.value(e.join(","))):(n._updateOptionSelectLabel(n.activeOptions[e]),a.hasValue||n.value(n.activeOptions[e].value))}))):(this.optionSelectTrigger&&this.optionSelectTrigger.hide(),a.inputType?this.input.attr("type",a.inputType):this.input.attr("type",this.defaultInputType),!1===a.hasValue?(this.elementDiv.hide(),this.valueLabelContainer.hide()):a.valueLabel?(this.valueLabelContainer.css("pointer-events",""),this.valueLabelContainer.css("flex-grow",1),this.valueLabelContainer.css("overflow","hidden"),this.valueLabelContainer.show(),this.valueLabelContainer.empty(),this.elementDiv.hide(),a.valueLabel.call(this,this.valueLabelContainer,this.input.val())):(this.valueLabelContainer.hide(),this.elementDiv.show(),a.autoComplete&&this.input.autoComplete({search:a.autoComplete,minLength:0})),this.optionExpandButton&&(a.expand?(a.expand.icon?this.optionExpandButtonIcon.removeClass().addClass("red-ui-typedInput-icon fa "+a.expand.icon):this.optionExpandButtonIcon.removeClass().addClass("red-ui-typedInput-icon fa fa-ellipsis-h"),this.optionExpandButton.shown=!0,this.optionExpandButton.show(),this.optionExpandButton.off("click"),this.optionExpandButton.on("click",function(e){var t;e.preventDefault(),"function"==typeof a.expand?a.expand.call(n):(e=l("<div>"),t=a.expand.content.call(n,e),(e=RED.popover.panel(e)).container.css({width:n.valueLabelContainer.width()}),a.expand.minWidth&&e.container.css({minWidth:a.expand.minWidth+"px"}),e.show({target:n.optionExpandButton,onclose:t.onclose,align:"left"}))})):(this.optionExpandButton.shown=!1,this.optionExpandButton.hide()))),this._trigger("typechange",null,this.propertyType),this.input.trigger("change",[this.propertyType,this.value()]))},validate:function(){var e=this.value(),t=this.type();return(t=!this.typeMap[t]||!this.typeMap[t].validate||("function"==typeof(t=this.typeMap[t].validate)?t(e):t.test(e)))?this.uiSelect.removeClass("input-error"):this.uiSelect.addClass("input-error"),t},show:function(){this.uiSelect.show()},hide:function(){this.uiSelect.hide()},disable:function(e){void 0===e||e?this.uiSelect.attr("disabled","disabled"):this.uiSelect.attr("disabled",null)},enable:function(){this.uiSelect.attr("disabled",null)},disabled:function(){return"disabled"===this.uiSelect.attr("disabled")},focus:function(){this.input.focus()}})}(jQuery),function(r){r.widget("nodered.toggleButton",{_create:function(){var t=this,o=!1,e=(this.options.hasOwnProperty("invertState")&&(o=this.options.invertState),this.options.baseClass||"red-ui-button"),n=this.options.hasOwnProperty("enabledIcon")?this.options.enabledIcon:"fa-check-square-o",i=this.options.hasOwnProperty("disabledIcon")?this.options.disabledIcon:"fa-square-o",a=this.options.hasOwnProperty("enabledLabel")?this.options.enabledLabel:RED._("editor:workspace.enabled"),s=this.options.hasOwnProperty("disabledLabel")?this.options.disabledLabel:RED._("editor:workspace.disabled"),e=(this.element.css("display","none"),this.element.on("focus",function(){t.button.focus()}),this.button=r('<button type="button" class="red-ui-toggleButton '+e+' toggle single"></button>'),(a||s)&&(this.buttonLabel=r("<span>").appendTo(this.button).css("margin-left","5px")),this.options.class&&this.button.addClass(this.options.class),this.element.after(this.button),n&&i&&(this.buttonIcon=r('<i class="fa"></i>').prependTo(this.button)),this.button.addClass("selected"),this.buttonIcon&&this.buttonIcon.addClass(n),this.buttonLabel&&this.buttonLabel.text(a),this.button.width());this.button.removeClass("selected"),this.buttonIcon&&(this.buttonIcon.removeClass(n),t.buttonIcon.addClass(i)),this.buttonLabel&&t.buttonLabel.text(s),e=Math.max(e,this.button.width()),this.buttonIcon&&this.buttonIcon.removeClass(i),0<e&&this.button.width(Math.ceil(e)),this.button.on("click",function(e){e.stopPropagation(),t.state?t.element.prop("checked",o):t.element.prop("checked",!o),t.element.trigger("change")}),this.element.on("change",function(e){r(this).prop("checked")!==o?(t.button.addClass("selected"),t.state=!0,t.buttonIcon&&(t.buttonIcon.addClass(n),t.buttonIcon.removeClass(i)),t.buttonLabel&&t.buttonLabel.text(a)):(t.button.removeClass("selected"),t.state=!1,t.buttonIcon&&(t.buttonIcon.addClass(i),t.buttonIcon.removeClass(n)),t.buttonLabel&&t.buttonLabel.text(s))}),this.element.trigger("change")}})}(jQuery),jQuery.widget("nodered.autoComplete",{_create:function(){const o=this;this.completionMenuShown=!1,this.options.minLength=function(e,t,o,n){if(null==e)return t||0;o=null==o?Number.NEGATIVE_INFINITY:o,n=null==n?Number.POSITIVE_INFINITY:n;let i=parseInt(e);(isNaN(i)||i<o||i>n)&&(i=t||0);return i}(this.options.minLength,1,0),this.options.search=this.options.search||function(){return[]},this.element.addClass("red-ui-autoComplete"),this.element.on("keydown.red-ui-autoComplete",function(e){var t;13!==e.keyCode&&9!==e.keyCode||!o.completionMenuShown||(t=o.menu.options(),o.element.val(t[0].value),o.menu.hide(),e.preventDefault())}),this.element.on("keyup.red-ui-autoComplete",function(e){13!==e.keyCode&&9!==e.keyCode&&27!==e.keyCode&&(8!==e.keyCode&&46!==e.keyCode||o.completionMenuShown)&&o._updateCompletions(this.value)})},_showCompletionMenu:function(e){this.completionMenuShown||(this.menu=RED.popover.menu({tabSelect:!0,width:300,maxHeight:200,class:"red-ui-autoComplete-container",options:e,onselect:e=>{this.element.val(e.value),this.element.focus(),this.element.trigger("change")},onclose:()=>{this.completionMenuShown=!1,delete this.menu,this.element.focus()}}),this.menu.show({target:this.element}),this.completionMenuShown=!0)},_updateCompletions:function(e){const o=this;if(e.trim().length<this.options.minLength)this.completionMenuShown&&this.menu.hide();else if(2===this.options.search.length){const n=1+Math.floor(1e4*Math.random());this.pendingRequest=n,this.options.search(e,function(e){t(e,n)})}else t(this.options.search(e));function t(e,t){t&&t!==o.pendingRequest||(e&&0!==e.length?o.completionMenuShown?o.menu.options(e):o._showCompletionMenu(e):o.completionMenuShown&&o.menu.hide())}},_destroy:function(){this.element.removeClass("red-ui-autoComplete"),this.element.off("keydown.red-ui-autoComplete"),this.element.off("keyup.red-ui-autoComplete"),this.completionMenuShown&&this.menu.hide()}}),RED.actions=function(){var a={};function s(e){let t=a[e];return t?(t.label||(o=(o=(o=t.options)?o.label:void 0)||"action-list."+e.replace(/^.*:/,""),(n=RED._(o))===o&&(n=e.replace(/(^.+:([a-z]))|(-([a-z]))/g,function(){return 0===arguments[5]?arguments[2].toUpperCase():" "+arguments[4].toUpperCase()})),t.label=n),t.label):"";var o,n}return{add:function(e,t,o){if("function"!=typeof t)throw new Error("Action handler not a function");if(a[e])throw new Error("Cannot override existing action");a[e]={handler:t,options:o}},remove:function(e){delete a[e]},get:function(e){return a[e].handler},getLabel:s,invoke:function(){var e=Array.prototype.slice.call(arguments),t=e.shift();a.hasOwnProperty(t)&&a[t].handler.apply(null,e)},list:function(){var i=[];return Object.keys(a).forEach(function(e){var t=a[e],o=RED.keyboard.getShortcut(e),n=!1,n=o?o.user:!!RED.keyboard.getUserShortcut(e);t.label||(t.label=s(e)),i.push({id:e,scope:o?o.scope:void 0,key:o?o.key:void 0,user:n,label:t.label,options:t.options})}),i}}}(),RED.deploy=function(){var t={full:{img:"red/images/deploy-full-o.svg"},nodes:{img:"red/images/deploy-nodes-o.svg"},flows:{img:"red/images/deploy-flows-o.svg"}},c={unknown:!1,unusedConfig:!1,invalid:!1},u="full",p=!1,l=null;function s(e){u=e,$("#red-ui-header-button-deploy-icon").attr("src",t[e].img)}function f(e){var t="",o=(e.z&&(t=(o=RED.nodes.workspace(e.z))?o.label:(o=RED.nodes.subflow(e.z)).name),RED.utils.getNodeLabel(e,e.id));return{tab:t,type:e.type,label:o}}function h(e,t){return e.tab<t.tab?-1:e.tab>t.tab?1:e.type<t.type?-1:e.type>t.type?1:e.name<t.name?-1:e.name>t.name?1:0}function g(e,t){var o=$("<div>"),n=($('<p data-i18n="deploy.confirm.conflict"></p>').appendTo(o),$('<div class="red-ui-deploy-dialog-confirm-conflict-row"><img src="red/images/spin.svg"/><div data-i18n="deploy.confirm.conflictChecking"></div></div>').appendTo(o)),i=$('<div class="red-ui-deploy-dialog-confirm-conflict-row"><i class="fa fa-check"></i><div data-i18n="deploy.confirm.conflictAutoMerge"></div></div>').hide().appendTo(o),a=$('<div class="red-ui-deploy-dialog-confirm-conflict-row"><i class="fa fa-exclamation"></i><div data-i18n="deploy.confirm.conflictManualMerge"></div></div>').hide().appendTo(o),s=(o.i18n(),l=null,[{text:RED._("common.label.cancel"),click:function(){r.close()}},{id:"red-ui-deploy-dialog-confirm-deploy-review",text:RED._("deploy.confirm.button.review"),class:"primary disabled",click:function(){$("#red-ui-deploy-dialog-confirm-deploy-review").hasClass("disabled")||(RED.diff.showRemoteDiff(),r.close())}},{id:"red-ui-deploy-dialog-confirm-deploy-merge",text:RED._("deploy.confirm.button.merge"),class:"primary disabled",click:function(){$("#red-ui-deploy-dialog-confirm-deploy-merge").hasClass("disabled")||(RED.diff.mergeDiff(l),r.close())}}]),r=(t&&s.push({id:"red-ui-deploy-dialog-confirm-deploy-overwrite",text:RED._("deploy.confirm.button.overwrite"),class:"primary",click:function(){D(!0,t),r.close()}}),RED.notify(o,{modal:!0,fixed:!0,width:600,buttons:s})),d=Date.now();RED.diff.getRemoteDiff(function(e){var t=Math.max(1e3-(Date.now()-d),0);l=e,setTimeout(function(){n.hide(),0===Object.keys(e.conflicts).length?(i.show(),$("#red-ui-deploy-dialog-confirm-deploy-merge").removeClass("disabled")):a.show(),$("#red-ui-deploy-dialog-confirm-deploy-review").removeClass("disabled")},t)})}function m(e){var t;return 5<e.length&&(t=e.length-5,(e=e.slice(0,5)).push(RED._("deploy.confirm.plusNMore",{count:t}))),e}function v(e){return e.replace(/&/g,"&amp;").replace(/</g,"&lt;").replace(/>/g,"&gt;")}function b(){$("#red-ui-header-shade").show(),$("#red-ui-editor-shade").show(),$("#red-ui-palette-shade").show(),$("#red-ui-sidebar-shade").show()}function y(){$("#red-ui-header-shade").hide(),$("#red-ui-editor-shade").hide(),$("#red-ui-palette-shade").hide(),$("#red-ui-sidebar-shade").hide()}function w(){$(".red-ui-deploy-button-content").css("opacity",0),$(".red-ui-deploy-button-spinner").show(),$("#red-ui-header-button-deploy").addClass("disabled")}function E(){$(".red-ui-deploy-button-content").css("opacity",1),$(".red-ui-deploy-button-spinner").hide()}function r(e){const t=Date.now(),i=!$("#red-ui-header-button-deploy").hasClass("disabled");p=!0,w(),b(),$.ajax({url:"flows/state",type:"POST",data:{state:e}}).done(function(e,t,o){i&&$("#red-ui-header-button-deploy").removeClass("disabled")}).fail(function(e,t,o){if(i&&$("#red-ui-header-button-deploy").removeClass("disabled"),401===e.status)RED.notify(RED._("notification.error",{message:RED._("user.notAuthorized")}),"error");else if(e.responseText){const n={message:o?o+"":""};try{n.message=JSON.parse(e.responseText).message}finally{n.message=n.message||e.responseText}RED.notify(RED._("notification.error",n),"error")}else RED.notify(RED._("notification.error",{message:RED._("deploy.errors.noResponse")}),"error")}).always(function(){var e=Math.max(0,300-(Date.now()-t));setTimeout(function(){E(),y(),p=!1},e)})}function d(){var t=Date.now(),n=!$("#red-ui-header-button-deploy").hasClass("disabled");p=!0,w(),$.ajax({url:"flows",type:"POST",headers:{"Node-RED-Deployment-Type":"reload"}}).done(function(e,t,o){n&&$("#red-ui-header-button-deploy").removeClass("disabled"),RED.notify("<p>"+RED._("deploy.successfulRestart")+"</p>","success")}).fail(function(e,t,o){n&&$("#red-ui-header-button-deploy").removeClass("disabled"),401===e.status?RED.notify(RED._("deploy.deployFailed",{message:RED._("user.notAuthorized")}),"error"):409===e.status?g(nns,!0):e.responseText?RED.notify(RED._("deploy.deployFailed",{message:e.responseText}),"error"):RED.notify(RED._("deploy.deployFailed",{message:RED._("deploy.errors.noResponse")}),"error")}).always(function(){var e=Math.max(0,300-(Date.now()-t));setTimeout(function(){E(),p=!1},e)})}function D(a,e){if(!$("#red-ui-header-button-deploy").hasClass("disabled")&&!$("#red-ui-header-shade").is(":visible"))if(RED.user.hasPermission("flows.write")){let i=!1;if(!a){var s;const r=[],d=[],l=(RED.nodes.eachConfig(function(e){void 0===e.valid&&RED.editor.validateNode(e),e.valid||e.d||d.push(f(e)),"unknown"===e.type&&-1==r.indexOf(e.name)&&r.push(e.name)}),RED.nodes.eachNode(function(e){e.valid||e.d||d.push(f(e)),"unknown"===e.type&&-1==r.indexOf(e.name)&&r.push(e.name)}),a=0<r.length,s=0<d.length,[]);RED.nodes.eachConfig(function(e){!1!==e._def.hasUsers&&0===e.users.length&&(l.push(f(e)),i=!0)});let e=!1,t,o=[],n;if(a&&!c.unknown?(e=!0,t="<p>"+RED._("deploy.confirm.unknown")+'</p><ul class="red-ui-deploy-dialog-confirm-list"><li>'+m(r).map(v).join("</li><li>")+"</li></ul><p>"+RED._("deploy.confirm.confirm")+"</p>",o=[{text:RED._("deploy.unknownNodesButton"),class:"pull-left",click:function(){n.close(),RED.actions.invoke("core:search","type:unknown ")}},{id:"red-ui-deploy-dialog-confirm-deploy-deploy",text:RED._("deploy.confirm.button.confirm"),class:"primary",click:function(){D(!0),n.close()}}]):s&&!c.invalid&&(e=!0,d.sort(h),t="<p>"+RED._("deploy.confirm.improperlyConfigured")+'</p><ul class="red-ui-deploy-dialog-confirm-list"><li>'+m(d.map(function(e){return v((e.tab?"["+e.tab+"] ":"")+e.label+" ("+e.type+")")})).join("</li><li>")+"</li></ul><p>"+RED._("deploy.confirm.confirm")+"</p>",o=[{text:RED._("deploy.invalidNodesButton"),class:"pull-left",click:function(){n.close(),RED.actions.invoke("core:search","is:invalid ")}},{id:"red-ui-deploy-dialog-confirm-deploy-deploy",text:RED._("deploy.confirm.button.confirm"),class:"primary",click:function(){D(!0),n.close()}}]),e)return o.unshift({text:RED._("common.label.cancel"),click:function(){n.close()}}),void(n=RED.notify(t,{modal:!0,fixed:!0,buttons:o}))}const n=RED.nodes.createCompleteNodeSet(),t=Date.now(),o=(w(),{flows:n});e||(o.rev=RED.nodes.version()),p=!0,b(),$.ajax({url:"flows",type:"POST",data:JSON.stringify(o),contentType:"application/json; charset=utf-8",headers:{"Node-RED-Deployment-Type":u}}).done(function(t,e,o){if(RED.nodes.dirty(!1),RED.nodes.version(t.rev),RED.nodes.originalFlow(n),i){let e;t={type:"success",fixed:!1,timeout:6e3,buttons:[{text:RED._("deploy.unusedConfigNodesButton"),class:"pull-left",click:function(){e.close(),RED.actions.invoke("core:search","is:config is:unused ")}},{text:RED._("common.label.close"),class:"primary",click:function(){D(!0),e.close()}}]};e=RED.notify("<p>"+RED._("deploy.successfulDeploy")+"</p><p>"+RED._("deploy.unusedConfigNodes")+"</p>",t)}else RED.notify("<p>"+RED._("deploy.successfulDeploy")+"</p>","success");RED.nodes.eachNode(function(e){e.changed&&(e.dirty=!0,e.changed=!1),e.moved&&(e.dirty=!0,e.moved=!1),e.credentials&&delete e.credentials}),RED.nodes.eachConfig(function(e){e.changed=!1,e.credentials&&delete e.credentials}),RED.nodes.eachSubflow(function(e){e.changed=!1}),RED.nodes.eachWorkspace(function(e){e.changed=!1}),RED.history.markAllDirty(),RED.view.redraw(),RED.events.emit("deploy")}).fail(function(e,t,o){RED.nodes.dirty(!0),$("#red-ui-header-button-deploy").removeClass("disabled"),401===e.status?RED.notify(RED._("deploy.deployFailed",{message:RED._("user.notAuthorized")}),"error"):409===e.status?g(n,!0):e.responseText?RED.notify(RED._("deploy.deployFailed",{message:e.responseText}),"error"):RED.notify(RED._("deploy.deployFailed",{message:RED._("deploy.errors.noResponse")}),"error")}).always(function(){var e=Math.max(0,300-(Date.now()-t));setTimeout(function(){p=!1,E(),y()},e)})}else RED.notify(RED._("user.errors.deploy"),"error")}return{init:function(e){var t,o,n,i=(e=e||{}).type||"default";if("default"==i){$('<li><span class="red-ui-deploy-button-group button-group"><a id="red-ui-header-button-deploy" class="red-ui-deploy-button disabled" href="#"><span class="red-ui-deploy-button-content"><img id="red-ui-header-button-deploy-icon" src="red/images/deploy-full-o.svg"> <span>'+RED._("deploy.deploy")+'</span></span><span class="red-ui-deploy-button-spinner hide"><img src="red/images/spin.svg"/></span></a><a id="red-ui-header-button-deploy-options" class="red-ui-deploy-button" href="#"><i class="fa fa-caret-down"></i></a></span></li>').prependTo(".red-ui-header-toolbar");const a=[{id:"deploymenu-item-full",toggle:"deploy-type",icon:"red/images/deploy-full.svg",label:RED._("deploy.full"),sublabel:RED._("deploy.fullDesc"),selected:!0,onselect:function(e){e&&s("full")}},{id:"deploymenu-item-flow",toggle:"deploy-type",icon:"red/images/deploy-flows.svg",label:RED._("deploy.modifiedFlows"),sublabel:RED._("deploy.modifiedFlowsDesc"),onselect:function(e){e&&s("flows")}},{id:"deploymenu-item-node",toggle:"deploy-type",icon:"red/images/deploy-nodes.svg",label:RED._("deploy.modifiedNodes"),sublabel:RED._("deploy.modifiedNodesDesc"),onselect:function(e){e&&s("nodes")}},null];RED.settings.runtimeState&&!0===RED.settings.runtimeState.ui&&(a.push({id:"deploymenu-item-runtime-start",icon:"red/images/start.svg",label:RED._("deploy.startFlows"),sublabel:RED._("deploy.startFlowsDesc"),onselect:"core:start-flows",visible:!1}),a.push({id:"deploymenu-item-runtime-stop",icon:"red/images/stop.svg",label:RED._("deploy.stopFlows"),sublabel:RED._("deploy.stopFlowsDesc"),onselect:"core:stop-flows",visible:!1})),a.push({id:"deploymenu-item-reload",icon:"red/images/deploy-reload.svg",label:RED._("deploy.restartFlows"),sublabel:RED._("deploy.restartFlowsDesc"),onselect:"core:restart-flows"}),RED.menu.init({id:"red-ui-header-button-deploy-options",options:a})}else"simple"==i&&(t=e.label||RED._("deploy.deploy"),o="red/images/deploy-full-o.svg",e.hasOwnProperty("icon")&&(o=e.icon),$('<li><span class="red-ui-deploy-button-group button-group"><a id="red-ui-header-button-deploy" class="red-ui-deploy-button disabled" href="#"><span class="red-ui-deploy-button-content">'+(o?'<img id="red-ui-header-button-deploy-icon" src="'+o+'"> ':"")+"<span>"+t+'</span></span><span class="red-ui-deploy-button-spinner hide"><img src="red/images/spin.svg"/></span></a></span></li>').prependTo(".red-ui-header-toolbar"));$("#red-ui-header-button-deploy").on("click",function(e){e.preventDefault(),D()}),RED.actions.add("core:deploy-flows",D),"default"===i&&(RED.settings.runtimeState&&!0===RED.settings.runtimeState.ui&&(RED.actions.add("core:stop-flows",function(){r("stop")}),RED.actions.add("core:start-flows",function(){r("start")})),RED.actions.add("core:restart-flows",d),RED.actions.add("core:set-deploy-type-to-full",function(){RED.menu.setSelected("deploymenu-item-full",!0)}),RED.actions.add("core:set-deploy-type-to-modified-flows",function(){RED.menu.setSelected("deploymenu-item-flow",!0)}),RED.actions.add("core:set-deploy-type-to-modified-nodes",function(){RED.menu.setSelected("deploymenu-item-node",!0)})),RED.events.on("workspace:dirty",function(e){e.dirty?(window.onbeforeunload=function(){return RED._("deploy.confirm.undeployedChanges")},$("#red-ui-header-button-deploy").removeClass("disabled")):(window.onbeforeunload=null,$("#red-ui-header-button-deploy").addClass("disabled"))}),RED.comms.subscribe("notification/runtime-deploy",function(e,t){var o;n||(null===(o=RED.nodes.version())||p||o===t.revision||(o=$("<p>").text(RED._("deploy.confirm.backgroundUpdate")),n=RED.notify(o,{modal:!0,fixed:!0,buttons:[{text:RED._("deploy.confirm.button.ignore"),click:function(){n.close(),n=null}},{text:RED._("deploy.confirm.button.review"),class:"primary",click:function(){n.close(),g(RED.nodes.createCompleteNodeSet(),!1),n=null}}]})))})},setDeployInflight:function(e){p=e}}}(),RED.diagnostics={init:function(){!1!==RED.settings.get("diagnostics.ui",!0)&&RED.actions.add("core:show-system-info",function(){$.ajax({headers:{Accept:"application/json"},cache:!1,url:"diagnostics",success:function(e){var t=JSON.stringify(e||{},"",4);"{}"===t&&(t="{\n\n}"),RED.editor.editJSON({title:RED._("diagnostics.title"),value:t,requireValid:!0,readOnly:!0,toolbarButtons:[{text:RED._("clipboard.export.copy"),icon:"fa fa-copy",click:function(){RED.clipboard.copyText(t,$(this),RED._("clipboard.copyMessageValue"))}},{text:RED._("clipboard.download"),icon:"fa fa-download",click:function(){var e=document.createElement("a");e.setAttribute("href","data:text/plain;charset=utf-8,"+encodeURIComponent(t)),e.setAttribute("download","system-info.json"),e.style.display="none",document.body.appendChild(e),e.click(),document.body.removeChild(e)}}]})},error:function(e,t,o){console.log("Unexpected error loading system info:",e.status,t,o)}})})}},RED.diff=function(){var s=!1;function p(e,t,o){var D,n,e=$('<div class="red-ui-diff-panel"></div>').appendTo(e),i=$('<div class="red-ui-diff-panel-headers"></div>').appendTo(e),a=("merge"===o.mode&&e.addClass("red-ui-diff-panel-merge"),n=e,D=t,(n=$('<ol class="red-ui-diff-list"></ol>').appendTo(n)).editableList({addButton:!1,height:"auto",scrollOnAdd:!1,addItem:function(e,t,o){var n,i,a,s,r,d=o.diff,l=o.remoteDiff,c=o.tab.n,u=o.def,p=D.conflicts,f=$("<div>",{class:"red-ui-diff-list-flow"}).appendTo(e),h=(f.addClass("collapsed"),$("<div>",{class:"red-ui-diff-list-flow-title"}).appendTo(f)),g=$("<div>").appendTo(f),m=$("<div>",{class:"red-ui-diff-list-node-cell"}).appendTo(h),v=$("<div>",{class:"red-ui-diff-list-node-cell red-ui-diff-list-node-local"}).appendTo(h),b=(l&&(n=$("<div>",{class:"red-ui-diff-list-node-cell red-ui-diff-list-node-remote"}).appendTo(h)),$('<span class="red-ui-diff-list-chevron"><i class="fa fa-angle-down"></i></span>').appendTo(m),R(c,u).appendTo(m),(o.newTab||o.tab).n),m=$("<span>",{class:"red-ui-diff-list-flow-title-meta"}).appendTo(m),y=("tab"===b.type?m.text(b.label||b.id):"subflow"===c.type?m.text(b.name||b.id):m.text(RED._("diff.globalNodes")),{local:{addedCount:0,deletedCount:0,changedCount:0,unchangedCount:0},remote:{addedCount:0,deletedCount:0,changedCount:0,unchangedCount:0},conflicts:0}),w=((o.newTab||o.remoteTab)&&(b={node:d.newConfig.all[c.id],all:d.newConfig.all,diff:d},l&&(r={node:l.newConfig.all[c.id]||null,all:l.newConfig.all,diff:l}),void 0!==c.type&&(m=$("<div>",{class:"red-ui-diff-list-node red-ui-diff-list-node-props collapsed"}).appendTo(g),w=$("<div>",{class:"red-ui-diff-list-node-header"}).appendTo(m),i=$("<div>",{class:"red-ui-diff-list-node-cell"}).appendTo(w),a=$("<div>",{class:"red-ui-diff-list-node-cell red-ui-diff-list-node-local"}).appendTo(w),0,d.newConfig.all[c.id]?d.added[c.id]?(a.addClass("red-ui-diff-status-added"),$('<span class="red-ui-diff-status"><i class="fa fa-plus-square"></i> <span data-i18n="diff.type.added"></span></span>').appendTo(a)):d.changed[c.id]?(a.addClass("red-ui-diff-status-changed"),$('<span class="red-ui-diff-status"><i class="fa fa-square"></i> <span data-i18n="diff.type.changed"></span></span>').appendTo(a)):(a.addClass("red-ui-diff-status-unchanged"),$('<span class="red-ui-diff-status"><i class="fa fa-square-o"></i> <span data-i18n="diff.type.unchanged"></span></span>').appendTo(a)):a.addClass("red-ui-diff-empty"),l&&(s=$("<div>",{class:"red-ui-diff-list-node-cell red-ui-diff-list-node-remote"}).appendTo(w),l.newConfig.all[c.id]?l.added[c.id]?(s.addClass("red-ui-diff-status-added"),$('<span class="red-ui-diff-status"><i class="fa fa-plus-square"></i> <span data-i18n="diff.type.added"></span></span>').appendTo(s)):l.changed[c.id]?(s.addClass("red-ui-diff-status-changed"),$('<span class="red-ui-diff-status"><i class="fa fa-square"></i> <span data-i18n="diff.type.changed"></span></span>').appendTo(s)):(s.addClass("red-ui-diff-status-unchanged"),$('<span class="red-ui-diff-status"><i class="fa fa-square-o"></i> <span data-i18n="diff.type.unchanged"></span></span>').appendTo(s)):(s.addClass("red-ui-diff-empty"),l.deleted[c.id]&&0)),$('<span class="red-ui-diff-list-chevron"><i class="fa fa-angle-down"></i></span>').appendTo(i),$("<span>").text(RED._("diff.flowProperties")).appendTo(i),w.on("click",function(e){e.preventDefault(),$(this).parent().toggleClass("collapsed")}),_(u,c,b,r).appendTo(m),i="",p[c.id]?(y.conflicts++,a.hasClass("red-ui-diff-empty")||$('<span class="red-ui-diff-status-conflict"><span class="red-ui-diff-status"><i class="fa fa-exclamation"></i></span></span>').prependTo(a),s.hasClass("red-ui-diff-empty")||$('<span class="red-ui-diff-status-conflict"><span class="red-ui-diff-status"><i class="fa fa-exclamation"></i></span></span>').prependTo(s),m.addClass("red-ui-diff-list-node-conflict")):i=D.resolutions[c.id],k(c,m,a,s,!0,!p[c.id],i,D))),0),u=0,E={};o.tab.nodes.forEach(function(e){E[e.id]=!0,x(e,y,D).appendTo(g)}),o.newTab&&(w=o.newTab.nodes.length,o.newTab.nodes.forEach(function(e){E[e.id]||(E[e.id]=!0,x(e,y,D).appendTo(g))})),o.remoteTab&&(u=o.remoteTab.nodes.length,o.remoteTab.nodes.forEach(function(e){E[e.id]||x(e,y,D).appendTo(g)})),h.on("click",function(e){h.parent().toggleClass("collapsed"),$(this).parent().hasClass("collapsed")&&($(this).parent().find(".red-ui-diff-list-node").addClass("collapsed"),$(this).parent().find(".red-ui-debug-msg-element").addClass("collapsed"))}),d.deleted[c.id]?$('<span class="red-ui-diff-status-deleted"><span class="red-ui-diff-status"><i class="fa fa-minus-square"></i> <span data-i18n="diff.type.flowDeleted"></span></span></span>').appendTo(v):o.newTab?d.added[c.id]?$('<span class="red-ui-diff-status-added"><span class="red-ui-diff-status"><i class="fa fa-plus-square"></i> <span data-i18n="diff.type.flowAdded"></span></span></span>').appendTo(v):(c.id&&(d.changed[c.id]?y.local.changedCount++:y.local.unchangedCount++),b=$("<span>",{class:"red-ui-diff-list-flow-stats"}).appendTo(v),$('<span class="red-ui-diff-status"></span>').text(RED._("diff.nodeCount",{count:w})).appendTo(b),0<y.conflicts+y.local.addedCount+y.local.changedCount+y.local.deletedCount&&($('<span class="red-ui-diff-status"> [ </span>').appendTo(b),0<y.conflicts&&$('<span class="red-ui-diff-status-conflict"><span class="red-ui-diff-status"><i class="fa fa-exclamation"></i> '+y.conflicts+"</span></span>").appendTo(b),0<y.local.addedCount&&$('<span class="red-ui-diff-status-added"><span class="red-ui-diff-status"><i class="fa fa-plus-square"></i> '+y.local.addedCount+"</span></span>").appendTo(b),0<y.local.changedCount&&$('<span class="red-ui-diff-status-changed"><span class="red-ui-diff-status"><i class="fa fa-square"></i> '+y.local.changedCount+"</span></span>").appendTo(b),0<y.local.deletedCount&&$('<span class="red-ui-diff-status-deleted"><span class="red-ui-diff-status"><i class="fa fa-minus-square"></i> '+y.local.deletedCount+"</span></span>").appendTo(b),$('<span class="red-ui-diff-status"> ] </span>').appendTo(b))):v.addClass("red-ui-diff-empty"),l&&(l.deleted[c.id]?$('<span class="red-ui-diff-status-deleted"><span class="red-ui-diff-status"><i class="fa fa-minus-square"></i> <span data-i18n="diff.type.flowDeleted"></span></span></span>').appendTo(n):o.remoteTab?l.added[c.id]?$('<span class="red-ui-diff-status-added"><span class="red-ui-diff-status"><i class="fa fa-plus-square"></i> <span data-i18n="diff.type.flowAdded"></span></span></span>').appendTo(n):(c.id&&(l.changed[c.id]?y.remote.changedCount++:y.remote.unchangedCount++),r=$("<span>",{class:"red-ui-diff-list-flow-stats"}).appendTo(n),$('<span class="red-ui-diff-status"></span>').text(RED._("diff.nodeCount",{count:u})).appendTo(r),0<y.conflicts+y.remote.addedCount+y.remote.changedCount+y.remote.deletedCount&&($('<span class="red-ui-diff-status"> [ </span>').appendTo(r),0<y.conflicts&&$('<span class="red-ui-diff-status-conflict"><span class="red-ui-diff-status"><i class="fa fa-exclamation"></i> '+y.conflicts+"</span></span>").appendTo(r),0<y.remote.addedCount&&$('<span class="red-ui-diff-status-added"><span class="red-ui-diff-status"><i class="fa fa-plus-square"></i> '+y.remote.addedCount+"</span></span>").appendTo(r),0<y.remote.changedCount&&$('<span class="red-ui-diff-status-changed"><span class="red-ui-diff-status"><i class="fa fa-square"></i> '+y.remote.changedCount+"</span></span>").appendTo(r),0<y.remote.deletedCount&&$('<span class="red-ui-diff-status-deleted"><span class="red-ui-diff-status"><i class="fa fa-minus-square"></i> '+y.remote.deletedCount+"</span></span>").appendTo(r),$('<span class="red-ui-diff-status"> ] </span>').appendTo(r))):n.addClass("red-ui-diff-empty"),i="",0<y.conflicts?h.addClass("red-ui-diff-list-node-conflict"):i=D.resolutions[c.id],c.id&&(m=!(0<y.conflicts&&(d.deleted[c.id]||l.deleted[c.id])),k(c,h,v,n,!1,m,i,D))),0===f.find(".red-ui-diff-list-node").length&&f.addClass("red-ui-diff-list-flow-empty"),e.i18n()}}),n),s=t.localDiff,r=t.remoteDiff,d=(t.conflicts,s.currentConfig),l=s.newConfig;return void 0!==r?(e.addClass("red-ui-diff-three-way"),n=o.oldRevTitle||RED._("diff.local"),t=o.newRevTitle||RED._("diff.remote"),$("<div></div>").text(n).appendTo(i),$("<div></div>").text(t).appendTo(i)):e.removeClass("red-ui-diff-three-way"),{list:a,finish:function(){var e,t={diff:s,def:{category:"config",color:"#f0f0f0"},tab:{n:{},nodes:d.globals},newTab:{n:{},nodes:l.globals}},o=(void 0!==r&&(t.remoteTab={n:{},nodes:r.newConfig.globals},t.remoteDiff=r),a.editableList("addItem",t),{});for(e in d.tabOrder.forEach(function(e){var t=d.tabs[e],t={diff:s,def:RED.nodes.getType("tab"),tab:t};l.tabs.hasOwnProperty(e)&&(t.newTab=l.tabs[e]),void 0!==r&&(t.remoteTab=r.newConfig.tabs[e],t.remoteDiff=r),o[e]=!0,a.editableList("addItem",t)}),l.tabOrder.forEach(function(e){o[e]||(o[e]=!0,e=l.tabs[e],e={diff:s,def:RED.nodes.getType("tab"),tab:e,newTab:e},void 0!==r&&(e.remoteDiff=r),a.editableList("addItem",e))}),void 0!==r&&r.newConfig.tabOrder.forEach(function(e){o[e]||(e=r.newConfig.tabs[e],e={diff:s,remoteDiff:r,def:RED.nodes.getType("tab"),tab:e,remoteTab:e},a.editableList("addItem",e))}),d.subflows)d.subflows.hasOwnProperty(e)&&(o[e]=!0,t={diff:s,def:{defaults:{},icon:"subflow.svg",category:"subflows",color:"#DDAA99"},tab:d.subflows[e]},l.subflows.hasOwnProperty(e)&&(t.newTab=l.subflows[e]),void 0!==r&&(t.remoteTab=r.newConfig.subflows[e],t.remoteDiff=r),a.editableList("addItem",t));for(e in l.subflows)l.subflows.hasOwnProperty(e)&&!o[e]&&(o[e]=!0,t={diff:s,def:{defaults:{},icon:"subflow.svg",category:"subflows",color:"#DDAA99"},tab:l.subflows[e],newTab:l.subflows[e]},void 0!==r&&(t.remoteDiff=r),a.editableList("addItem",t));if(void 0!==r)for(e in r.newConfig.subflows)r.newConfig.subflows.hasOwnProperty(e)&&!o[e]&&(t={diff:s,remoteDiff:r,def:{defaults:{},icon:"subflow.svg",category:"subflows",color:"#DDAA99"},tab:r.newConfig.subflows[e],remoteTab:r.newConfig.subflows[e]},a.editableList("addItem",t))}}}function E(e,i){var t=$("<div>",{class:"red-ui-diff-list-wires"}),a=$("<ol></ol>"),s=0;return e.forEach(function(e,t){var n,o=$("<li>").appendTo(a);e&&0<e.length?($("<span>").text(t+1).appendTo(o),n=$("<ul>").appendTo(o),e.forEach(function(e){s++;var t=$("<li>").appendTo(n),o=i[e];o?g(o,RED.nodes.getType(o.type)||{}).appendTo(t):t.text(e)})):o.text("none")}),0===s?t.text("none"):a.appendTo(t),t}function R(e,t){var o=$("<div>",{class:"red-ui-diff-list-node-icon"}),n=RED.utils.getNodeColor(e.type,t),t=RED.utils.getNodeIcon(t,e),e=("tab"===e.type&&(n="#C0DEED"),o.css("backgroundColor",n),$("<div/>",{class:"red-ui-palette-icon-container"}).appendTo(o));return RED.utils.createIconElement(t,e,!1),o}function g(e,t){var o=$("<div>",{class:"red-ui-diff-list-node-title"}),t=(R(e,t).appendTo(o),e.label||e.name||e.id);return $("<div>",{class:"red-ui-diff-list-node-description"}).text(t).appendTo(o),o}function x(t,e,o){var n,i,a=o.localDiff,s=o.remoteDiff,r=o.conflicts[t.id],d=!0,l=(a.added[t.id]&&(e.local.addedCount++,d=!1),s&&s.added[t.id]&&(e.remote.addedCount++,d=!1),a.deleted[t.id]&&(e.local.deletedCount++,d=!1),s&&s.deleted[t.id]&&(e.remote.deletedCount++,d=!1),a.changed[t.id]&&(e.local.changedCount++,d=!!0),s&&s.changed[t.id]&&(e.remote.changedCount++,d=!!0),RED.nodes.getType(t.type)),c=(void 0===l&&(l=/^subflow:/.test(t.type)?{icon:"subflow.svg",category:"subflows",color:"#DDAA99",defaults:{name:{value:""}}}:"group"===t.type?RED.group.def:{}),$("<div>",{class:"red-ui-diff-list-node collapsed"})),u=$("<div>",{class:"red-ui-diff-list-node-header"}).appendTo(c),p=$("<div>",{class:"red-ui-diff-list-node-cell"}).appendTo(u),f=$("<div>",{class:"red-ui-diff-list-node-cell red-ui-diff-list-node-local"}).appendTo(u),h=(s&&(n=$("<div>",{class:"red-ui-diff-list-node-cell red-ui-diff-list-node-remote"}).appendTo(u)),$('<span class="red-ui-diff-list-chevron"><i class="fa fa-angle-down"></i></span>').appendTo(p),d?(e.local.unchangedCount++,g(t,l).appendTo(p),f.addClass("red-ui-diff-status-unchanged"),$('<span class="red-ui-diff-status"><i class="fa fa-square-o"></i> <span data-i18n="diff.type.unchanged"></span></span>').appendTo(f),s&&(e.remote.unchangedCount++,n.addClass("red-ui-diff-status-unchanged"),$('<span class="red-ui-diff-status"><i class="fa fa-square-o"></i> <span data-i18n="diff.type.unchanged"></span></span>').appendTo(n)),c.addClass("red-ui-diff-status-unchanged")):a.added[t.id]?(f.addClass("red-ui-diff-status-added"),n&&n.addClass("red-ui-diff-empty"),$('<span class="red-ui-diff-status"><i class="fa fa-plus-square"></i> <span data-i18n="diff.type.added"></span></span>').appendTo(f),g(t,l).appendTo(p)):s&&s.added[t.id]?(f.addClass("red-ui-diff-empty"),n.addClass("red-ui-diff-status-added"),$('<span class="red-ui-diff-status"><i class="fa fa-plus-square"></i> <span data-i18n="diff.type.added"></span></span>').appendTo(n),g(t,l).appendTo(p)):(g(t,l).appendTo(p),a.moved[t.id]?(d=a.newConfig.all[t.id],a.deleted[t.z]||t.z===d.z||""===t.z||a.newConfig.all[t.z]?(f.addClass("red-ui-diff-status-moved"),p="",p=t.z===d.z?RED._("diff.type.movedFrom",{id:a.currentConfig.all[t.id].z||"global"}):RED._("diff.type.movedTo",{id:d.z||"global"}),$('<span class="red-ui-diff-status"><i class="fa fa-caret-square-o-right"></i> '+p+"</span>").appendTo(f)):f.addClass("red-ui-diff-empty"),0):a.deleted[t.z]?(f.addClass("red-ui-diff-empty"),0):a.deleted[t.id]?(f.addClass("red-ui-diff-status-deleted"),$('<span class="red-ui-diff-status"><i class="fa fa-minus-square"></i> <span data-i18n="diff.type.deleted"></span></span>').appendTo(f),0):a.changed[t.id]?a.newConfig.all[t.id].z!==t.z?f.addClass("red-ui-diff-empty"):(f.addClass("red-ui-diff-status-changed"),$('<span class="red-ui-diff-status"><i class="fa fa-square"></i> <span data-i18n="diff.type.changed"></span></span>').appendTo(f),0):a.newConfig.all[t.id].z!==t.z?f.addClass("red-ui-diff-empty"):(e.local.unchangedCount++,f.addClass("red-ui-diff-status-unchanged"),$('<span class="red-ui-diff-status"><i class="fa fa-square-o"></i> <span data-i18n="diff.type.unchanged"></span></span>').appendTo(f)),s&&(s.moved[t.id]?(d=s.newConfig.all[t.id],s.deleted[t.z]||t.z===d.z||""===t.z||s.newConfig.all[t.z]?(n.addClass("red-ui-diff-status-moved"),p="",p=t.z===d.z?RED._("diff.type.movedFrom",{id:s.currentConfig.all[t.id].z||"global"}):RED._("diff.type.movedTo",{id:d.z||"global"}),$('<span class="red-ui-diff-status"><i class="fa fa-caret-square-o-right"></i> '+p+"</span>").appendTo(n)):n.addClass("red-ui-diff-empty")):s.deleted[t.z]?n.addClass("red-ui-diff-empty"):s.deleted[t.id]?(n.addClass("red-ui-diff-status-deleted"),$('<span class="red-ui-diff-status"><i class="fa fa-minus-square"></i> <span data-i18n="diff.type.deleted"></span></span>').appendTo(n)):s.changed[t.id]?s.newConfig.all[t.id].z!==t.z?n.addClass("red-ui-diff-empty"):(n.addClass("red-ui-diff-status-changed"),$('<span class="red-ui-diff-status"><i class="fa fa-square"></i> <span data-i18n="diff.type.changed"></span></span>').appendTo(n)):s.newConfig.all[t.id].z!==t.z?n.addClass("red-ui-diff-empty"):(e.remote.unchangedCount++,n.addClass("red-ui-diff-status-unchanged"),$('<span class="red-ui-diff-status"><i class="fa fa-square-o"></i> <span data-i18n="diff.type.unchanged"></span></span>').appendTo(n)))),{node:a.newConfig.all[t.id],all:a.newConfig.all,diff:a}),d=(s&&(i={node:s.newConfig.all[t.id]||null,all:s.newConfig.all,diff:s}),"");return r?(e.conflicts++,f.hasClass("red-ui-diff-empty")||$('<span class="red-ui-diff-status-conflict"><span class="red-ui-diff-status"><i class="fa fa-exclamation"></i></span></span>').prependTo(f),n.hasClass("red-ui-diff-empty")||$('<span class="red-ui-diff-status-conflict"><span class="red-ui-diff-status"><i class="fa fa-exclamation"></i></span></span>').prependTo(n),c.addClass("red-ui-diff-list-node-conflict")):d=o.resolutions[t.id],k(t,c,f,n,!1,!r,d,o),u.on("click",function(e){$(this).parent().toggleClass("collapsed"),0===$(this).siblings(".red-ui-diff-list-node-properties").length&&_(l,t,h,i).appendTo(c)}),c}function _(t,n,i,a){var s,r,d,l,c,u,p,f={},h=i.node,e=(a&&(s=a.node),$("<div>",{class:"red-ui-diff-list-node-properties"})),o=$("<table>").appendTo(e),g=$("<colgroup><col/><col/></colgroup>").appendTo(o),m=(void 0!==s&&$("<col/>").appendTo(g),$("<tbody>").appendTo(o)),v=!1,b=!1,y=!1,w=$("<tr>").appendTo(m),g=($("<td>",{class:"red-ui-diff-list-cell-label"}).text("id").appendTo(w),r=$("<td>",{class:"red-ui-diff-list-cell red-ui-diff-list-node-local"}).appendTo(w),h?(r.addClass("red-ui-diff-status-unchanged"),$('<span class="red-ui-diff-status"></span>').appendTo(r),u=$('<span class="red-ui-diff-list-element"></span>').appendTo(r),f["local.id"]=RED.utils.createObjectElement(h.id).appendTo(u)):r.addClass("red-ui-diff-empty"),void 0!==s&&((p=$("<td>",{class:"red-ui-diff-list-cell red-ui-diff-list-node-remote"}).appendTo(w)).addClass("red-ui-diff-status-unchanged"),s?($('<span class="red-ui-diff-status"></span>').appendTo(p),u=$('<span class="red-ui-diff-list-element"></span>').appendTo(p),f["remote.id"]=RED.utils.createObjectElement(s.id).appendTo(u)):p.addClass("red-ui-diff-empty")),n.hasOwnProperty("x")&&(!h||h.x===n.x&&h.y===n.y&&h.w===n.w&&h.h===n.h||(v=!0,0),!s||s.x===n.x&&s.y===n.y&&s.w===n.w&&s.h===n.h||(b=!0,0),(b&&v&&(h.x!==s.x||h.y!==s.y)||!v&&b&&i.diff.deleted[n.id]||v&&!b&&a.diff.deleted[n.id])&&(y=!0),w=$("<tr>").appendTo(m),$("<td>",{class:"red-ui-diff-list-cell-label"}).text("position").appendTo(w),r=$("<td>",{class:"red-ui-diff-list-cell red-ui-diff-list-node-local"}).appendTo(w),h?(r.addClass("red-ui-diff-status-"+(v?"changed":"unchanged")),$('<span class="red-ui-diff-status">'+(v?'<i class="fa fa-square"></i>':"")+"</span>").appendTo(r),u=$('<span class="red-ui-diff-list-element"></span>').appendTo(r),g={x:h.x,y:h.y},h.hasOwnProperty("w")&&(g.w=h.w,g.h=h.h),f["local.position"]=RED.utils.createObjectElement(g,{path:"position",exposeApi:!0,ontoggle:function(e,t){f["remote."+e]&&f["remote."+e].prop("expand")(e,t)}}).appendTo(u)):r.addClass("red-ui-diff-empty"),void 0!==s&&((p=$("<td>",{class:"red-ui-diff-list-cell red-ui-diff-list-node-remote"}).appendTo(w)).addClass("red-ui-diff-status-"+(b?"changed":"unchanged")),s?($('<span class="red-ui-diff-status">'+(b?'<i class="fa fa-square"></i>':"")+"</span>").appendTo(p),u=$('<span class="red-ui-diff-list-element"></span>').appendTo(p),o={x:s.x,y:s.y},s.hasOwnProperty("w")&&(o.w=s.w,o.h=s.h),f["remote.position"]=RED.utils.createObjectElement(o,{path:"position",exposeApi:!0,ontoggle:function(e,t){f["local."+e]&&f["local."+e].prop("expand")(e,t)}}).appendTo(u)):p.addClass("red-ui-diff-empty"))),v=b=y=!1,n.hasOwnProperty("wires")&&(d=JSON.stringify(n.wires),h&&(l=JSON.stringify(h.wires),d!==l&&(v=!0,0)),s&&(c=JSON.stringify(s.wires),d!==c&&(b=!0,0)),(b&&v&&l!==c||!v&&b&&i.diff.deleted[n.id]||v&&!b&&a.diff.deleted[n.id])&&(y=!0),w=$("<tr>").appendTo(m),$("<td>",{class:"red-ui-diff-list-cell-label"}).text("wires").appendTo(w),r=$("<td>",{class:"red-ui-diff-list-cell red-ui-diff-list-node-local"}).appendTo(w),h?(y?(r.addClass("red-ui-diff-status-conflict"),$('<span class="red-ui-diff-status"><i class="fa fa-exclamation"></i></span>').appendTo(r)):(r.addClass("red-ui-diff-status-"+(v?"changed":"unchanged")),$('<span class="red-ui-diff-status">'+(v?'<i class="fa fa-square"></i>':"")+"</span>").appendTo(r)),E(h.wires,i.all).appendTo(r)):r.addClass("red-ui-diff-empty"),void 0!==s&&(p=$("<td>",{class:"red-ui-diff-list-cell red-ui-diff-list-node-remote"}).appendTo(w),s?(y?(p.addClass("red-ui-diff-status-conflict"),$('<span class="red-ui-diff-status"><i class="fa fa-exclamation"></i></span>').appendTo(p)):(p.addClass("red-ui-diff-status-"+(b?"changed":"unchanged")),$('<span class="red-ui-diff-status">'+(b?'<i class="fa fa-square"></i>':"")+"</span>").appendTo(p)),E(s.wires,a.all).appendTo(p)):p.addClass("red-ui-diff-empty"))),Object.keys(n).filter(function(e){return!("inputLabels"==e||"outputLabels"==e||"z"==e||"wires"==e||"x"===e||"y"===e||"w"===e||"h"===e||"id"===e||"type"===e||t.defaults&&t.defaults.hasOwnProperty(e))}));return t.defaults&&(g=g.concat(Object.keys(t.defaults))),"tab"!==n.type&&"group"!==n.type&&(g=g.concat(["inputLabels","outputLabels"])),(h&&h.hasOwnProperty("icon")||s&&s.hasOwnProperty("icon"))&&-1===g.indexOf("icon")&&g.unshift("icon"),g.forEach(function(o){y=b=v=!1,d=JSON.stringify(n[o]),h&&(l=JSON.stringify(h[o]),d!==l&&(v=!0,0)),s&&(c=JSON.stringify(s[o]),d!==c&&(b=!0,0)),(b&&v&&l!==c||!v&&b&&i.diff.deleted[n.id]||v&&!b&&a.diff.deleted[n.id])&&(y=!0),w=$("<tr>").appendTo(m);var e=$("<td>",{class:"red-ui-diff-list-cell-label"}).text(o).appendTo(w);r=$("<td>",{class:"red-ui-diff-list-cell red-ui-diff-list-node-local"}).appendTo(w),h?(y?(r.addClass("red-ui-diff-status-conflict"),$('<span class="red-ui-diff-status"><i class="fa fa-exclamation"></i></span>').appendTo(r)):(r.addClass("red-ui-diff-status-"+(v?"changed":"unchanged")),$('<span class="red-ui-diff-status">'+(v?'<i class="fa fa-square"></i>':"")+"</span>").appendTo(r)),u=$('<span class="red-ui-diff-list-element"></span>').appendTo(r),f["local."+o]=RED.utils.createObjectElement(h[o],{path:o,exposeApi:!0,ontoggle:function(e,t){f["remote."+o]&&f["remote."+o].prop("expand")(e,t)}}).appendTo(u)):r.addClass("red-ui-diff-empty"),void 0!==s&&(p=$("<td>",{class:"red-ui-diff-list-cell red-ui-diff-list-node-remote"}).appendTo(w),s?(y?(p.addClass("red-ui-diff-status-conflict"),$('<span class="red-ui-diff-status"><i class="fa fa-exclamation"></i></span>').appendTo(p)):(p.addClass("red-ui-diff-status-"+(b?"changed":"unchanged")),$('<span class="red-ui-diff-status">'+(b?'<i class="fa fa-square"></i>':"")+"</span>").appendTo(p)),u=$('<span class="red-ui-diff-list-element"></span>').appendTo(p),f["remote."+o]=RED.utils.createObjectElement(s[o],{path:o,exposeApi:!0,ontoggle:function(e,t){f["local."+o]&&f["local."+o].prop("expand")(e,t)}}).appendTo(u)):p.addClass("red-ui-diff-empty")),h&&s&&"string"==typeof h[o]&&(/\n/.test(h[o])||/\n/.test(s[o]))&&$('<button class="red-ui-button red-ui-button-small red-ui-diff-text-diff-button"><i class="fa fa-file-o"> <i class="fa fa-caret-left"></i> <i class="fa fa-caret-right"></i> <i class="fa fa-file-o"></i></button>').on("click",function(){C(h[o],s[o])}).appendTo(e)}),e}function k(o,n,e,t,i,a,s,r){function d(e){var t;void 0!==o.type&&(u?(t="red-ui-diff-selectbox-tab-"+o.id.replace(/\./g,"-"),$("."+t+"-"+this.value).prop("checked",!0),"local"===this.value?($("."+t+"-"+this.value).closest(".red-ui-diff-list-node").addClass("red-ui-diff-select-local"),$("."+t+"-"+this.value).closest(".red-ui-diff-list-node").removeClass("red-ui-diff-select-remote")):($("."+t+"-"+this.value).closest(".red-ui-diff-list-node").removeClass("red-ui-diff-select-local"),$("."+t+"-"+this.value).closest(".red-ui-diff-list-node").addClass("red-ui-diff-select-remote"))):(t="red-ui-diff-selectbox-"+(i?o.id:o.z).replace(/\./g,"-"),$("#"+t+"-local").prop("checked",!1),$("#"+t+"-remote").prop("checked",!1),(t=$("#"+t+"-local").closest(".red-ui-diff-list-flow").find(".red-ui-diff-list-flow-title")).removeClass("red-ui-diff-select-local"),t.removeClass("red-ui-diff-select-remote"))),"local"===this.value?(n.removeClass("red-ui-diff-select-remote"),n.addClass("red-ui-diff-select-local")):"remote"===this.value&&(n.addClass("red-ui-diff-select-remote"),n.removeClass("red-ui-diff-select-local")),w(r)}var l="red-ui-diff-selectbox-"+o.id.replace(/\./g,"-")+(i?"-props":""),c="",u=((o.z||i)&&(c="red-ui-diff-selectbox-tab-"+(i?o.id:o.z).replace(/\./g,"-")),!i&&("tab"===o.type||"subflow"===o.type)),p=$("<label>",{class:"red-ui-diff-selectbox",for:l+"-local"}).on("click",function(e){e.stopPropagation()}).appendTo(e),f=$("<input>",{class:"red-ui-diff-selectbox-input "+c+"-local",id:l+"-local",type:"radio",value:"local",name:l}).data("node-id",o.id).on("change",d).appendTo(p),h=$("<label>",{class:"red-ui-diff-selectbox",for:l+"-remote"}).on("click",function(e){e.stopPropagation()}).appendTo(t),c=$("<input>",{class:"red-ui-diff-selectbox-input "+c+"-remote",id:l+"-remote",type:"radio",value:"remote",name:l}).data("node-id",o.id).on("change",d).appendTo(h);"local"===s?f.prop("checked",!0):"remote"===s&&c.prop("checked",!0),(a||e.hasClass("red-ui-diff-empty")||t.hasClass("red-ui-diff-empty"))&&(p.hide(),h.hide())}function w(e){var t=0,o=($(".red-ui-diff-selectbox>input:checked").each(function(){e.conflicts[$(this).data("node-id")]&&t++,e.resolutions[$(this).data("node-id")]=$(this).val()}),Object.keys(e.conflicts).length);o-t==0?$("#red-ui-diff-dialog-toolbar-resolved-conflicts").html('<span class="red-ui-diff-status-added"><span class="red-ui-diff-status"><i class="fa fa-check"></i></span></span> '+RED._("diff.unresolvedCount",{count:o-t})):$("#red-ui-diff-dialog-toolbar-resolved-conflicts").html('<span class="red-ui-diff-status-conflict"><span class="red-ui-diff-status"><i class="fa fa-exclamation"></i></span></span> '+RED._("diff.unresolvedCount",{count:o-t})),o===t&&($("#red-ui-diff-view-diff-merge").removeClass("disabled"),$("#red-ui-diff-view-resolve-diff").removeClass("disabled"))}function t(i){$.ajax({headers:{Accept:"application/json"},cache:!1,url:"flows",success:function(e){var t=RED.nodes.createCompleteNodeSet(),o=RED.nodes.originalFlow(),n=e.flows,t=D(o,t),o=D(o,n);o.rev=e.rev,i(T(t,o))}})}function r(e){var o,n,i,a;void 0===e?t(r):(o=e,n={mode:"merge"},s||(n=n||{},o.localDiff,i=o.remoteDiff,a=o.conflicts,e={title:n.title||RED._("diff.reviewChanges"),width:1/0,overlay:!0,buttons:[{text:RED._("merge"===n.mode?"common.label.cancel":"common.label.close"),click:function(){RED.tray.close()}}],resize:function(e){},open:function(e){var e=e.find(".red-ui-tray-body"),t=($('<div class="red-ui-diff-dialog-toolbar"><span><span id="red-ui-diff-dialog-toolbar-resolved-conflicts"></span></span> </div>').prependTo(e),p($('<div class="red-ui-diff-container"></div>').appendTo(e),o,n));t.list.hide(),i?($("#red-ui-diff-view-diff-merge").show(),0===Object.keys(a).length?$("#red-ui-diff-view-diff-merge").removeClass("disabled"):$("#red-ui-diff-view-diff-merge").addClass("disabled")):$("#red-ui-diff-view-diff-merge").hide(),w(o),setTimeout(function(){t.finish(),t.list.show()},300),$("#red-ui-sidebar-shade").show()},close:function(){s=!1,$("#red-ui-sidebar-shade").hide()},show:function(){}},"merge"===n.mode&&e.buttons.push({id:"red-ui-diff-view-diff-merge",text:RED._("deploy.confirm.button.merge"),class:"primary disabled",click:function(){$("#red-ui-diff-view-diff-merge").hasClass("disabled")||(w(o),c(o),RED.tray.close())}}),RED.tray.show(e)))}function d(e){var t=[],o={},n={},i=[],a={};return e.forEach(function(e){"tab"===(a[e.id]=e).type?(t.push(e.id),o[e.id]={n:e,nodes:[]}):"subflow"===e.type&&(n[e.id]={n:e,nodes:[]})}),e.forEach(function(e){"tab"!==e.type&&"subflow"!==e.type&&(o[e.z]?o[e.z].nodes:n[e.z]?n[e.z].nodes:i).push(e)}),{all:a,tabOrder:t,tabs:o,subflows:n,globals:i}}function D(e,t){var o=d(e),n=d(t),i={},a={},s={},r={};return Object.keys(o.all).forEach(function(e){RED.nodes.workspace(e)||RED.nodes.subflow(e)||RED.nodes.node(e);n.all.hasOwnProperty(e)?JSON.stringify(o.all[e])!==JSON.stringify(n.all[e])&&(s[e]=!0,o.all[e].z!==n.all[e].z&&(r[e]=!0)):a[e]=!0}),Object.keys(n.all).forEach(function(e){o.all.hasOwnProperty(e)||(i[e]=!0)}),{currentConfig:o,newConfig:n,added:i,deleted:a,changed:s,moved:r}}function T(e,t){var o,n,i,a,s={},r={},d={localDiff:e,remoteDiff:t,conflicts:s,resolutions:r},l={};for(o in e.currentConfig.all)e.currentConfig.all.hasOwnProperty(o)&&(l[o]=!0,i=e.newConfig.all[o],e.changed[o]&&t.deleted[o]||e.deleted[o]&&t.changed[o]?s[o]=!0:e.changed[o]&&t.changed[o]&&(a=t.newConfig.all[o],JSON.stringify(i)!==JSON.stringify(a)&&(s[o]=!0)),s[o]||(t.added[o]||t.changed[o]||t.deleted[o]?r[o]="remote":r[o]="local"));for(o in e.added)e.added.hasOwnProperty(o)&&(n=e.newConfig.all[o],t.deleted[n.z]?s[o]=!0:r[o]="local");for(o in t.added)t.added.hasOwnProperty(o)&&(n=t.newConfig.all[o],e.deleted[n.z]?s[o]=!0:r[o]="remote");return d}function l(e){e.localDiff.currentConfig;var t,o=e.localDiff,n=e.remoteDiff,i=e.conflicts,a=e.resolutions;for(t in i)if(i.hasOwnProperty(t)&&!a.hasOwnProperty(t))throw console.log(e),new Error("No resolution for conflict on node",t);var s,r=[],d={},l={};for(t in o.newConfig.all)o.newConfig.all.hasOwnProperty(t)&&(s=RED.nodes.node(t),"local"===a[t]?(s&&(d[t]=s.changed),r.push(o.newConfig.all[t])):"remote"===a[t]?!n.deleted[t]&&n.newConfig.all.hasOwnProperty(t)&&(s&&(d[t]=s.changed),l[t]=1,r.push(n.newConfig.all[t])):console.log("Unresolved",t));for(t in n.added)n.added.hasOwnProperty(t)&&((s=RED.nodes.node(t))&&(d[t]=s.changed),o.added.hasOwnProperty(t)||(l[t]=2,r.push(n.newConfig.all[t])));return{config:r,nodeChangedStates:d,localChangedStates:l}}function c(e){var t,o=RED.workspaces.active(),n=l(e),i=n.config,a=n.nodeChangedStates,s=n.localChangedStates,n=RED.nodes.dirty(),r={t:"replace",config:RED.nodes.createCompleteNodeSet(),changed:a,dirty:n,rev:RED.nodes.version()},d=(RED.history.push(r),RED.nodes.originalFlow());for(t in e.remoteDiff.added)e.remoteDiff.added.hasOwnProperty(t)&&e.remoteDiff.newConfig.all.hasOwnProperty(t)&&d.push(JSON.parse(JSON.stringify(e.remoteDiff.newConfig.all[t])));RED.nodes.clear();r=RED.nodes.import(i);RED.nodes.originalFlow(d),r.nodes.forEach(function(e){(a[e.id]||s[e.id])&&(e.changed=!0)}),RED.nodes.version(e.remoteDiff.rev),n&&RED.nodes.dirty(!0),RED.view.redraw(!0),RED.palette.refresh(),RED.workspaces.refresh(),RED.workspaces.show(o,!0),RED.sidebar.config.refresh()}function C(m,v){var e={title:RED._("diff.compareChanges"),width:1/0,overlay:!0,buttons:[{text:RED._("common.label.close"),click:function(){RED.tray.close()}}],resize:function(e){},open:function(e){for(var t,e=e.find(".red-ui-tray-body"),e=$('<div class="red-ui-diff-text"></div>').appendTo(e),e=$("<table>",{class:"red-ui-diff-text-content"}).appendTo(e),o=($('<colgroup><col width="50"><col width="50%"><col width="50"><col width="50%"></colgroup>').appendTo(e),$("<tbody>").appendTo(e)),n=function(e,t,o){var n,i,a=e.split(/\r?\n/),s=t.split(/\r?\n/),r=a.length,d=s.length,l={a:[],b:[]},c=[];for(n=0;n<r+1;n++)for(c[n]=[],i=0;i<d+1;i++)c[n][i]=0;for(n=r-1;0<=n;n--)for(i=d-1;0<=i;i--)1!==y(a[n],s[i],o)?c[n][i]=c[n+1][i+1]+1:c[n][i]=Math.max(c[n+1][i],c[n][i+1]);i=n=0;for(;n<r&&i<d;){var u,p=y(a[n],s[i],o);1!==p?((u=0)===p?u=0:2==p&&(u=3),l.a.push({i:n+1,j:i+1,line:a[n],type:u}),l.b.push({i:i+1,j:n+1,line:s[i],type:u}),n++,i++):c[n+1][i]>=c[n][i+1]?(l.a.push({i:n+1,line:a[n],type:1}),n++):(l.b.push({i:i+1,line:s[i],type:4}),i++)}for(;n<r||i<d;)n==r?(l.b.push({i:i+1,line:s[i],type:4}),i++):i==d&&(l.a.push({i:n+1,line:a[n],type:1}),n++);return l}(m||"",v||""),i=0,a=0,s=Math.max(n.a.length,n.b.length),r=[],d=[],l=0,c=0,u=0;u<s;u++){n[u];var p=i<n.a.length?n.a[i]:{type:2,line:""},f=a<n.b.length?n.b[a]:{type:2,line:""};0===p.type&&0!==f.type?(p={type:2,line:""},a++):0===f.type&&0!==p.type?(f={type:2,line:""},i++):(i++,a++),r.push({a:p,b:f}),void 0===t?(t={start:u,end:u},c=(l=0)===p.type&&0===f.type?0:1):0===p.type&&0===f.type?0===c?(t.end=u,l++):1===c?(t.end=u,c=2,l=0):2===c&&(t.end=u,8===++l&&(t.end-=5,d.push(t),t={start:u-5,end:u-5},l=c=0)):(t.end=u,l++,0===c?(3<t.end&&(t.end-=3,t.empty=!0,d.push(t),t={start:u-3,end:u-3}),c=1):2===c&&(c=1))}0===c&&(t.empty=!0),t.end=s,d.push(t),console.table(d);for(var h=0;h<d.length;h++)if((t=d[h]).empty)(function(n,i,a){diffRow=$('<tr class="red-ui-diff-text-header red-ui-diff-text-expand">');var e=$('<td colspan="4"> <i class="fa fa-arrows-v"></i> </td>').appendTo(diffRow),s=$("<span></span>").appendTo(e);i<a.length-1&&s.text("@@ -"+(a[i-1].a.i+1)+" +"+(a[i-1].b.i+1));return diffRow.on("click",function(e){if(20<i-n){var t=$(this).offset();if(0<n){for(var o=n;o<n+10;o++)b(a[o]).addClass("unchanged").insertBefore($(this));n+=10}if(i<a.length-1){for(o=i-1;i-11<o;o--)b(a[o]).addClass("unchanged").insertAfter($(this));i-=10}i<a.length-1&&s.text("@@ -"+(a[i-1].a.i+1)+" +"+(a[i-1].b.i+1));t=$(this).offset().top-t.top;$(".red-ui-diff-text").scrollTop($(".red-ui-diff-text").scrollTop()+t)}else{for(o=n;o<i;o++)b(a[o]).addClass("unchanged").insertBefore($(this));$(this).remove()}}),diffRow})(t.start,t.end,r).appendTo(o);else for(u=t.start;u<t.end;u++){var g=b(r[u]).appendTo(o);u===t.start?g.addClass("start-block"):u===t.end-1&&g.addClass("end-block")}},close:function(){s=!1},show:function(){}};RED.tray.show(e)}function b(e){var t=$("<tr>"),o=e.a,e=e.b,n=$('<td class="lineno">').text(2===o.type?"":o.i).appendTo(t),i=$('<td class="linetext">').text(o.line).appendTo(t);return 2===o.type?(n.addClass("blank"),i.addClass("blank")):4===o.type?(n.addClass("added"),i.addClass("added")):1===o.type&&(n.addClass("removed"),i.addClass("removed")),n=$('<td class="lineno">').text(2===e.type?"":e.i).appendTo(t),i=$('<td class="linetext">').text(e.line).appendTo(t),2===e.type?(n.addClass("blank"),i.addClass("blank")):4===e.type?(n.addClass("added"),i.addClass("added")):1===e.type&&(n.addClass("removed"),i.addClass("removed")),t}function y(e,t,o){return o?e===t?0:e.trim()===t.trime()?2:1:e===t?0:1}function a(e,y){var u=$("<div></div>");return e.forEach(function(f){var h,r,d,l,t,c,e,o,n=f.hunks,i=f.binary,a=$("<table>",{class:"red-ui-diff-text-content"}).appendTo(u),g=($('<colgroup><col width="50"><col width="50"><col width="100%"></colgroup>').appendTo(a),$("<tbody>").appendTo(a)),s=$('<tr class="red-ui-diff-text-file-header">').appendTo(g),a=$('<td colspan="3"></td>').appendTo(s),m=($('<i class="red-ui-diff-list-chevron fa fa-angle-down"></i>').appendTo(a),s.on("click",function(e){s.toggleClass("collapsed");var t=s.hasClass("collapsed");s.nextUntil(".red-ui-diff-text-file-header").toggle(!t)}),$('<span class="filename"></span>').text(f.file).appendTo(a),0),v=0,b={};y.project.files&&y.project.files.flow===f.file?(y.unmerged&&$('<span style="float: right;"><span id="red-ui-diff-dialog-toolbar-resolved-conflicts"></span></span>').appendTo(a),e=$('<tr class="red-ui-diff-text-header">').appendTo(g),r=$('<td class="red-ui-diff-flow-diff" colspan="3"></td>').appendTo(e),e=y.project.name,d=y.project.files.flow,c="projects/"+e+"/files/"+y.commonRev+"/"+d,l="projects/"+e+"/files/"+y.oldRev+"/"+d,o="projects/"+e+"/files/"+y.newRev+"/"+d,t=[$.Deferred(),$.Deferred(),$.Deferred()],y.commonRev?(c="projects/"+e+"/files/"+y.commonRev+"/"+d,$.ajax({dataType:"json",url:c}).then(function(e){t[0].resolve(e)}).fail(function(){t[0].resolve(null)})):t[0].resolve(null),$.ajax({dataType:"json",url:l}).then(function(e){t[1].resolve(e)}).fail(function(){t[1].resolve({content:"[]"})}),$.ajax({dataType:"json",url:o}).then(function(e){t[2].resolve(e)}).fail(function(){t[2].resolve({content:"[]"})}),$.when.apply($,t).always(function(e,t,o){var n,i,a;if(e)try{n=JSON.parse(e.content||"[]")}catch(e){return console.log(RED._("diff.commonVersionError"),c),void console.log(e)}try{i=JSON.parse(t.content||"[]")}catch(e){return console.log(RED._("diff.oldVersionError"),l),void console.log(e)}n=n||i;try{a=JSON.parse(o.content||"[]")}catch(e){return console.log(RED._("diff.newVersionError"),a),void console.log(e)}var e=D(n,i),t=D(n,a),s=(y.currentDiff=T(e,t),p(r,y.currentDiff,{title:d,mode:y.commonRev?"merge":"view",oldRevTitle:y.oldRevTitle,newRevTitle:y.newRevTitle}));s.list.hide(),w(y.currentDiff),setTimeout(function(){s.finish(),s.list.show()},300)})):i?(e=$('<tr class="red-ui-diff-text-header">').appendTo(g),o=$('<td colspan="3"></td>').appendTo(e),$("<span></span>").text(RED._("diff.noBinaryFileShowed")).appendTo(o)):(y.unmerged&&(h=$('<span style="float: right;">'+RED._("diff.conflictHeader",{resolved:v,unresolved:m})+"</span>").appendTo(a)),n.forEach(function(l){var e=$('<tr class="red-ui-diff-text-header">').appendTo(g),e=$('<td colspan="3"></td>').appendTo(e),c=($("<span></span>").text(l.header).appendTo(e),l.conflict),u=l.localStartLine,p=l.remoteStartLine;c&&m++,l.lines.forEach(function(e,t){var o,n,t=l.diffStart+t,i=c&&/^\+\+(<<<<<<<|=======$|>>>>>>>)/.test(e),a=$("<tr>").appendTo(g),s=$('<td class="lineno">').appendTo(a),r=(i?s.attr("colspan",2):o=$('<td class="lineno">').appendTo(a),$('<td class="linetext">').appendTo(a)),d=c?2:1;i?(a.addClass("mergeHeader"),/^\+\+=======$/.test(e)?(l.changeSeparator=t,a.addClass("mergeHeader-separator")):((n=/^..<<<<<<</.test(e))?($("<span>").text("<<<<<<< Local Changes").appendTo(r),l.localChangeStart=t):(l.remoteChangeEnd=t,$("<span>").text(">>>>>>> Remote Changes").appendTo(r)),a.addClass("mergeHeader-"+(n?"ours":"theirs")),$('<button class="red-ui-button red-ui-button-small" style="float: right; margin-right: 20px;"><i class="fa fa-angle-double-'+(n?"down":"up")+'"></i> use '+(n?"local":"remote")+" changes</button>").appendTo(r).on("click",function(e){var t,o;e.preventDefault(),v++,n?((o=(t=a.nextUntil(".mergeHeader-separator")).last().next()).nextUntil(".mergeHeader").remove(),o.next().remove()):((o=(t=a.prevUntil(".mergeHeader-separator")).last().prev()).prevUntil(".mergeHeader").remove(),o.prev().remove()),o.remove(),a.remove(),t.find(".linetext").addClass("added"),h.empty(),$("<span>"+RED._("diff.conflictHeader",{resolved:v,unresolved:m})+"</span>").appendTo(h),b[f.file]=b[f.file]||{},b[f.file][l.localChangeStart]={changeStart:l.localChangeStart,separator:l.changeSeparator,changeEnd:l.remoteChangeEnd,selection:n?"A":"B"},y.resolveConflict&&y.resolveConflict({conflicts:m,resolved:v,resolutions:b})}))):(i=e[0],c&&!y.unmerged&&" "===i&&(i=e[1]),$('<span class="prefix">').text(i).appendTo(r),t=!1,c&&y.unmerged?($('<span class="prefix">').text(e[1]).appendTo(r),"+"===e[0]&&(s.text(u++),t=!0),"+"===e[1]&&(o.text(p++),t=!0)):"+"===e[0]||c&&"+"===e[1]?(s.addClass("added"),o.addClass("added"),r.addClass("added"),o.text(p++),t=!0):("-"===e[0]||c&&"-"===e[1])&&(s.addClass("removed"),o.addClass("removed"),r.addClass("removed"),s.text(u++),t=!0),t||(r.addClass("unchanged"),0<u&&"\\"!==e[0]&&""!==e&&s.text(u++),0<p&&"\\"!==e[0]&&""!==e&&o.text(p++)),$("<span>").text(e.substring(d)).appendTo(r))})}))}),u}function u(e){for(var t,o,n=Array.isArray(e)?e:e.split("\n"),i=/^diff (?:(?:--git a\/(.*) b\/(.*))|(?:--cc (.*)))$/,a=/^\+\+\+ b\/(.*)\t?/,s=/^Binary files /,r=/^@@ -((\d+)(,(\d+))?) \+((\d+)(,(\d+))?) @@ ?(.*)$/,d=/^@+ -((\d+)(,(\d+))?) -((\d+)(,(\d+))?) \+((\d+)(,(\d+))?) @+/,l=[],c=0;c<n.length;c++){var u=n[c],p=i.exec(u);p?(o&&(t.hunks.push(o),l.push(t)),o=null,t={file:p[1]||p[3],hunks:[]}):s.test(u)?t&&(t.binary=!0):(p=a.exec(u))?t.file=p[1]:(p=r.exec(u))?(o&&t.hunks.push(o),o={header:u,localStartLine:p[2],localLength:p[4]||1,remoteStartLine:p[6],remoteLength:p[8]||1,lines:[],conflict:!1}):(p=d.exec(u))?(o&&t.hunks.push(o),o={header:u,localStartLine:p[2],localLength:p[4]||1,remoteStartLine:p[6],remoteLength:p[8]||1,diffStart:parseInt(p[10]),lines:[],conflict:!0}):o&&o.lines.push(u)}return o&&t.hunks.push(o),l.push(t),l}return{init:function(){RED.actions.add("core:show-remote-diff",r)},getRemoteDiff:t,showRemoteDiff:r,showUnifiedDiff:function(t){var o,e=t.diff,n=t.title,i=u(e),e=(t.unmerged&&(t.resolveConflict=function(e){(o=e).conflicts===e.resolved&&$("#red-ui-diff-view-resolve-diff").removeClass("disabled")}),{title:n||RED._("diff.compareChanges"),width:1/0,overlay:!0,buttons:[{text:RED._(t.unmerged?"common.label.cancel":"common.label.close"),click:function(){t.oncancel&&t.oncancel(),RED.tray.close()}}],resize:function(e){},open:function(e){e=e.find(".red-ui-tray-body"),e=$('<div class="red-ui-diff-text"></div>').appendTo(e);a(i,t).appendTo(e)},close:function(){s=!1},show:function(){}});t.unmerged&&e.buttons.push({id:"red-ui-diff-view-resolve-diff",text:RED._("diff.saveConflict"),class:"primary disabled",click:function(){var e;$("#red-ui-diff-view-resolve-diff").hasClass("disabled")||(t.currentDiff&&(e=l(t.currentDiff),(o={resolutions:{}}).resolutions[t.project.files.flow]=JSON.stringify(e.config,"",4)),t.onresolve&&t.onresolve(o),RED.tray.close())}}),RED.tray.show(e)},showCommitDiff:function(o){var n=function(e){for(var t={},o=e.split("\n"),n=[],i=0;i<o.length;i++)if(/^commit /.test(o[i]))t.sha=o[i].substring(7);else if(/^Author: /.test(o[i])){t.author=o[i].substring(8);var a=/^(.*) <(.*)>$/.exec(t.author);a&&(t.authorName=a[1],t.authorEmail=a[2])}else if(/^Date: /.test(o[i]))t.date=o[i].substring(8);else if(/^ /.test(o[i]))t.title?(4!==o[i].length||0<n.length)&&n.push(o[i].substring(4)):t.title=o[i].substring(4);else if(/^diff /.test(o[i])){t.files=u(o.slice(i));break}return t.comment=n.join("\n"),t}(o.commit),e={title:RED._("diff.viewCommitDiff"),width:1/0,overlay:!0,buttons:[{text:RED._("common.label.close"),click:function(){RED.tray.close()}}],resize:function(e){},open:function(e){var e=e.find(".red-ui-tray-body"),e=$('<div class="red-ui-diff-text"></div>').appendTo(e),t=$("<table>",{class:"red-ui-diff-text-content"}).appendTo(e),t=($('<colgroup><col width="50"><col width="50"><col width="100%"></colgroup>').appendTo(t),$("<tbody>").appendTo(t)),t=$('<tr class="red-ui-diff-text-commit-header">').appendTo(t),t=$('<td colspan="3"></td>').appendTo(t),t=($("<h3>").text(n.title).appendTo(t),$('<div class="commit-body"></div>').text(n.comment).appendTo(t),$('<div class="commit-summary"></div>').appendTo(t));$('<div style="float: right">').text("Commit "+n.sha).appendTo(t),$("<div>").text((n.authorName||n.author)+" - "+o.date).appendTo(t),n.files&&a(n.files,o).appendTo(e)},close:function(){s=!1},show:function(){}};RED.tray.show(e)},mergeDiff:c}}(),RED.keyboard=function(){var d,u,n=/Mac/i.test(window.navigator.platform),t=!0,p={},a={left:37,up:38,right:39,down:40,escape:27,enter:13,backspace:8,delete:46,space:32,";":186,"=":187,"+":187,",":188,"-":189,".":190,"/":191,"\\":220,"'":222,"?":191,"[":219,"]":221,"{":219,"}":221},o={16:!0,17:!0,18:!0,91:!0,93:!0},f={},h={},g={59:186,61:187,173:189};function m(e){return RED.settings.get("editor.keymap",{})[e]}function v(e){for(var t,o=e.toLowerCase().split("-"),n={},i=0;i<o.length;i++)switch(o[i]){case"ctrl":case"cmd":n.ctrl=!0,n.meta=!0;break;case"alt":n.alt=!0;break;case"shift":n.shift=!0;break;case"":t=a["-"];break;default:if(a.hasOwnProperty(o[i]))t=a[o[i]];else{if(1<o[i].length)return null;t=o[i].toUpperCase().charCodeAt(0)}}return[t,n]}function b(e,t){for(var o=e.target,n=0;"BODY"!==o.nodeName&&o.id!==t.scope;)o=o.parentElement,n++;return n="BODY"===o.nodeName&&"*"!==t.scope?-1:n}function r(e,t,o,n){var i=o,a=n,s=("function"!=typeof o&&"string"!=typeof o||(i={},a=o),[]),r=0;if("string"==typeof t){if("string"==typeof a){if(n||h.hasOwnProperty(a)||(h[a]={scope:e,key:t,user:!1}),!n)if(m(a))return;f[a]={scope:e,key:t},"boolean"==typeof n&&(f[a].user=n)}for(var d=t.split(" "),r=0;r<d.length;r++){var l=v(d[r]);if(!l)return;s.push(l)}}else s.push([t,i]);var c=p;for(r=0;r<s.length;r++)t=s[r][0],(i=s[r][1]).ctrl&&(c.ctrl=c.ctrl||{},c=c.ctrl),i.shift&&(c.shift=c.shift||{},c=c.shift),i.alt&&(c.alt=c.alt||{},c=c.alt),c[t]=c[t]||{},c=c[t];c.handlers=c.handlers||[],c.handlers.push({scope:e,ondown:a}),c.scope=e,c.ondown=a}function s(e,t){var o=t||{},n=[],i=0;if("string"==typeof e)for(var a=e.split(" "),i=0;i<a.length;i++){var s=v(a[i]);if(!s)return void console.log("Unrecognised key specifier:",e);n.push(s)}else n.push([e,o]);var r=p;for(i=0;i<n.length;i++){if(e=n[i][0],!(r=(r=(r=(o=n[i][1]).ctrl?r.ctrl:r)&&o.shift?r.shift:r)&&o.alt?r.alt:r)[e])return;r=r[e]}"string"==typeof r.ondown&&("boolean"==typeof t&&t?f[r.ondown]={user:t}:delete f[r.ondown]),delete r.scope,delete r.ondown,delete r.handlers}d3.select(window).on("keydown",function(){var e;t&&!o[d3.event.keyCode]&&(e=function e(t){var o=u||p,n=((o=(o=(t.ctrlKey||t.metaKey)&&t.ctrlKey!==t.metaKey?o.ctrl:o)&&t.shiftKey?o.shift:o)&&t.altKey&&(o=o.alt),g[t.keyCode]||t.keyCode);if(o&&o[n]){var i=o[n];if(!i.handlers){if(u)return u=null,e(t);if(0<Object.keys(i).length)for(var a in i)if(-1<b(t,i[a])){u=i,t.preventDefault();break}return null}for(var s,r=1/0,d=0,l=i.handlers.length,d=0;d<l;d++){var c=b(t,i.handlers[d]);-1<c&&c<r&&(r=c,s=i.handlers[d])}return u=null,i=s}if(u)return u=null,e(t)}(d3.event))&&e.ondown&&("string"==typeof e.ondown?RED.actions.invoke(e.ondown):e.ondown(),d3.event.preventDefault())});function l(e){e.preventDefault();var t,o,n,i,a=$(this),s=a.data("data");a.hasClass("keyboard-shortcut-entry-expanded")||(c(),e=a.find(".keyboard-shortcut-entry-key"),i=a.find(".keyboard-shortcut-entry-scope"),a.addClass("keyboard-shortcut-entry-expanded"),(t=$('<input type="text">').attr("placeholder",RED._("keyboard.unassigned")).val(s.key||"").appendTo(e)).on("change paste keyup",function(e){if(13===e.keyCode&&!$(this).hasClass("input-error"))return c();if(27===e.keyCode)return c(!0);var e=$(this).val(),t=""===(e=e.trim())||RED.keyboard.validateKey(e);t&&""!==e&&(t=!d.has(o.val()+":"+e.toLowerCase())),$(this).toggleClass("input-error",!t),n.attr("disabled",!t)}),(o=$('<select><option value="*" data-i18n="keyboard.global"></option><option value="red-ui-workspace" data-i18n="keyboard.workspace"></option></select>').appendTo(i)).i18n(),"workspace"===s.scope&&(s.scope="red-ui-workspace"),o.val(s.scope||"*"),o.on("change",function(){t.trigger("change")}),e=$('<div class="keyboard-shortcut-edit button-group-vertical"></div>').appendTo(i),n=$('<button class="red-ui-button red-ui-button-small"><i class="fa fa-check"></i></button>').appendTo(e),i=$('<button class="red-ui-button red-ui-button-small"><i class="fa fa-reply"></i></button>').appendTo(e),n.on("click",function(e){e.stopPropagation(),c()}),i.on("click",function(e){e.stopPropagation(),a.empty(),a.removeClass("keyboard-shortcut-entry-expanded");e=RED.settings.get("editor.keymap",{}),e[s.id]=null,RED.settings.set("editor.keymap",e),RED.keyboard.revertToDefault(s.id),e=RED.keyboard.getShortcut(s.id),e={id:s.id,scope:e?e.scope:void 0,key:e?e.key:void 0,user:e?e.user:void 0,label:s.label,options:s.options};y(a,e)}),t.trigger("focus"))}function c(e){var t,o,n,i,a,s,r=$(".keyboard-shortcut-entry-expanded");1===r.length&&(t=r.data("data"),o=r.find(".keyboard-shortcut-entry-key input"),n=r.find(".keyboard-shortcut-entry-scope select"),e||(e=o.val().trim(),i=n.val(),(""===e||RED.keyboard.validateKey(e))&&(!(a=RED.keyboard.getShortcut(t.id))&&e||a&&(a.scope!==i||a.key!==e))&&(a=r.find(".keyboard-shortcut-entry-key"),s=r.find(".keyboard-shortcut-entry-scope"),a.empty(),s.empty(),t.key&&(d.delete(t.scope+":"+t.key),RED.keyboard.remove(t.key,!0)),r.find(".keyboard-shortcut-entry-text i").css("opacity",1),""===e?(a.parent().addClass("keyboard-shortcut-entry-unassigned"),a.append($("<span>").text(RED._("keyboard.unassigned"))),delete t.key,delete t.scope):(a.parent().removeClass("keyboard-shortcut-entry-unassigned"),a.append(RED.keyboard.formatKey(e)),$("<span>").text(i).appendTo(s),t.key=e,t.scope=i,d.add(t.scope+":"+t.key),RED.keyboard.add(t.scope,t.key,t.id,!0)),a=RED.settings.get("editor.keymap",{}),s=RED.keyboard.getShortcut(t.id),a[t.id]={scope:s.scope,key:s.key},RED.settings.set("editor.keymap",a))),o.remove(),n.remove(),$(".keyboard-shortcut-edit").remove(),r.removeClass("keyboard-shortcut-entry-expanded"))}function y(e,t){var o=$('<div class="keyboard-shortcut-entry">').appendTo(e),n=(e.data("data",t),t.label),n=$("<div>").addClass("keyboard-shortcut-entry-text").text(n).appendTo(o),n=$('<i class="fa fa-user"></i>').prependTo(n),n=(t.user||n.css("opacity",0),$('<div class="keyboard-shortcut-entry-key">').appendTo(o)),n=(t.key?n.append(RED.keyboard.formatKey(t.key)):(o.addClass("keyboard-shortcut-entry-unassigned"),n.append($("<span>").text(RED._("keyboard.unassigned")))),$('<div class="keyboard-shortcut-entry-scope">').appendTo(o));$("<span>").text("*"===t.scope?"global":t.scope||"").appendTo(n),e.on("click",l)}function w(){var e=$('<div id="red-ui-settings-tab-keyboard"></div>'),o=($('<div class="keyboard-shortcut-entry keyboard-shortcut-list-header"><div class="keyboard-shortcut-entry-key keyboard-shortcut-entry-text"><input autocomplete="off" name="keyboard-filter" id="red-ui-settings-tab-keyboard-filter" type="text" data-i18n="[placeholder]keyboard.filterActions"></div><div class="keyboard-shortcut-entry-key" data-i18n="keyboard.shortcut"></div><div class="keyboard-shortcut-entry-scope" data-i18n="keyboard.scope"></div></div>').appendTo(e),e.find("#red-ui-settings-tab-keyboard-filter").searchBox({delay:100,change:function(){var t=$(this).val().trim().toLowerCase();""===t?o.editableList("filter",null):(t=t.replace(/\s/g,""),o.editableList("filter",function(e){return-1<e.label.toLowerCase().indexOf(t)}))}}),$('<ol class="keyboard-shortcut-list"></ol>').css({position:"absolute",top:"32px",bottom:"0",left:"0",right:"0"}).appendTo(e).editableList({addButton:!1,scrollOnAdd:!1,addItem:function(e,t,o){y(e,o)}})),t=RED.actions.list();return t.sort(function(e,t){e=e.label,t=t.label;return e.localeCompare(t)}),d=new Set,t.forEach(function(e){e.key&&d.add(e.scope+":"+e.key),o.editableList("addItem",e)}),e}return{init:function(a){"localStorage"in window&&null!==window.localStorage&&(null!==(e=localStorage.getItem("keymap"))&&(localStorage.removeItem("keymap"),RED.settings.set("editor.keymap",JSON.parse(e))));var e,s=RED.settings.get("editor.keymap",{});$.getJSON("red/keymap.json",function(e){var t,o,n,i=function(e,t){var o,n,i={};for(o in e)if(e.hasOwnProperty(o)){var a,s=e[o];for(a in s)s.hasOwnProperty(a)&&(i[s[a]]?i[s[a]].push({scope:o,key:a,user:!1}):i[s[a]]=[{scope:o,key:a,user:!1}])}for(n in t)t.hasOwnProperty(n)&&(t[n].key?(i[n]=[{scope:t[n].scope||"*",key:t[n].key,user:!1}],"workspace"===i[n][0].scope&&(i[n][0].scope="red-ui-workspace")):delete i[n]);return i}(e,RED.settings.theme("keymap",{}));for(t in i)i.hasOwnProperty(t)&&(s.hasOwnProperty(t)||i[t].forEach(function(e){r(e.scope,e.key,t,!1)}),h[t]=i[t][0]);for(t in s)s.hasOwnProperty(t)&&s[t]&&((o=s[t]).hasOwnProperty("key")&&r(n="workspace"===(n=o.scope)?"red-ui-workspace":n,o.key,t,!0));a()}),RED.userSettings.add({id:"keyboard",title:RED._("keyboard.keyboard"),get:w,focus:function(){setTimeout(function(){$("#red-ui-settings-tab-keyboard-filter").trigger("focus")},200)},close:function(){RED.menu.refreshShortcuts()}})},add:r,remove:s,getShortcut:function(e){return f[e]},getUserShortcut:m,revertToDefault:function(e){var t=f[e];t&&s(t.key),h.hasOwnProperty(e)&&r((t=h[e]).scope,t.key,e,!1)},formatKey:function(e,t){var o=n?e.replace(/ctrl-?/,"&#8984;"):e;return o=(o=(o=(o=(o=(o=n?o.replace(/alt-?/,"&#8997;"):e).replace(/shift-?/,"&#8679;")).replace(/left/,"&#x2190;")).replace(/up/,"&#x2191;")).replace(/right/,"&#x2192;")).replace(/down/,"&#x2193;"),t?o:'<span class="help-key-block"><span class="help-key">'+o.split(" ").join('</span> <span class="help-key">')+"</span></span>"},validateKey:function(e){var t=(e=e.trim()).split(" ");for(i=0;i<t.length;i++)if(!v(t[i]))return!1;return!0},disable:function(){t=!1},enable:function(){t=!0}}}(),RED.workspaces=function(){var a,s=0,i=0,t=[],n=[],o=0;let r,d;function l(e){o!==t.length&&t.splice(o),t.push(e),o=t.length}function c(o){n=n.filter(function(e){return e!==o&&(!Array.isArray(e)||(-1<(t=e.indexOf(o))&&e.splice(t,1),0!==e.length));var t})}function u(e,t,o){if(e)e.closeable||(e.hideable=!0),a.addTab(e,o),JSON.parse(RED.settings.getLocal("hiddenTabs")||"{}")[e.id]&&a.hideTab(e.id),a.resize();else{for(var n=RED.nodes.id();i+=1,0!==$("#red-ui-workspace-tabs li[flowname='"+RED._("workspace.defaultName",{number:i})+"']").size(););e={type:"tab",id:n,disabled:!1,info:"",label:RED._("workspace.defaultName",{number:i}),env:[],hideable:!0},RED.nodes.addWorkspace(e,o),a.addTab(e,o),a.activateTab(n),t||(RED.history.push({t:"add",workspaces:[e],dirty:RED.nodes.dirty()}),RED.nodes.dirty(!0))}return $("#red-ui-tab-"+e.id.replace(".","-")).attr("flowname",e.label),RED.view.focus(),e}function p(e){var t;1!==h&&(t=RED.nodes.getWorkspaceOrder(),e._index=t.indexOf(e.id),w(e),(t=RED.nodes.removeWorkspace(e.id)).t="delete",t.dirty=RED.nodes.dirty(),t.workspaces=[e],RED.history.push(t),RED.nodes.dirty(!0),RED.sidebar.config.refresh())}function f(e){var t=RED.nodes.workspace(e);t?RED.editor.editFlow(t):(t=RED.nodes.subflow(e))&&RED.editor.editSubflow(t)}var h=0;function e(){a=RED.tabs.create({id:"red-ui-workspace-tabs",onchange:function(e){var t={old:s};e?($("#red-ui-workspace-chart").show(),s=e.id,window.location.hash="flow/"+e.id,$("#red-ui-workspace").toggleClass("red-ui-workspace-disabled",!!e.disabled)):($("#red-ui-workspace-chart").hide(),s=0,window.location.hash=""),t.workspace=s,RED.events.emit("workspace:change",t),RED.sidebar.config.refresh(),RED.view.focus()},onclick:function(e){e.id!==s&&l(s),RED.view.focus()},ondblclick:function(e){"subflow"!=e.type?f(e.id):RED.editor.editSubflow(RED.nodes.subflow(e.id))},onadd:function(e){"tab"===e.type&&h++,$('<span class="red-ui-workspace-disabled-icon"><i class="fa fa-ban"></i> </span>').prependTo("#red-ui-tab-"+e.id.replace(".","-")+" .red-ui-tab-label"),e.disabled&&$("#red-ui-tab-"+e.id.replace(".","-")).addClass("red-ui-workspace-disabled"),RED.menu.setDisabled("menu-item-workspace-delete",0===s||h<=1),1===h&&($("#red-ui-workspace .red-ui-tabs").show(),$("#red-ui-workspace-chart").show(),$("#red-ui-workspace-footer").children().show())},onremove:function(e){"tab"===e.type?h--:n.push(e.id),RED.menu.setDisabled("menu-item-workspace-delete",0===s||h<=1),0===h&&g()},onreorder:function(e,t){RED.history.push({t:"reorder",workspaces:{from:e,to:t},dirty:RED.nodes.dirty()}),RED.nodes.dirty(!0),E(t)},onselect:function(e){RED.view.select(!1),0===e.length?($("#red-ui-workspace-chart svg").css({"pointer-events":"auto",filter:"none"}),$("#red-ui-workspace-toolbar").css({"pointer-events":"auto",filter:"none"}),$("#red-ui-palette-container").css({"pointer-events":"auto",filter:"none"}),$(".red-ui-sidebar-shade").hide()):(RED.view.select(!1),$("#red-ui-workspace-chart svg").css({"pointer-events":"none",filter:"opacity(60%)"}),$("#red-ui-workspace-toolbar").css({"pointer-events":"none",filter:"opacity(60%)"}),$("#red-ui-palette-container").css({"pointer-events":"none",filter:"opacity(60%)"}),$(".red-ui-sidebar-shade").show())},onhide:function(e){n.push(e.id);var t=JSON.parse(RED.settings.getLocal("hiddenTabs")||"{}");t[e.id]=!0,RED.settings.setLocal("hiddenTabs",JSON.stringify(t)),RED.events.emit("workspace:hide",{workspace:e.id})},onshow:function(e){c(e.id);var t=JSON.parse(RED.settings.getLocal("hiddenTabs")||"{}");delete t[e.id],RED.settings.setLocal("hiddenTabs",JSON.stringify(t)),RED.events.emit("workspace:show",{workspace:e.id})},minimumActiveTabWidth:150,scrollable:!0,addButton:"core:add-flow",addButtonCaption:RED._("workspace.addFlow"),menu:function(){var e=[{id:"red-ui-tabs-menu-option-search-flows",label:RED._("workspace.listFlows"),onselect:"core:list-flows"},{id:"red-ui-tabs-menu-option-search-subflows",label:RED._("workspace.listSubflows"),onselect:"core:list-subflows"},null,{id:"red-ui-tabs-menu-option-add-flow",label:RED._("workspace.addFlow"),onselect:"core:add-flow"},{id:"red-ui-tabs-menu-option-add-flow-right",label:RED._("workspace.addFlowToRight"),onselect:"core:add-flow-to-right"},null,{id:"red-ui-tabs-menu-option-add-hide-flows",label:RED._("workspace.hideFlow"),onselect:"core:hide-flow"},{id:"red-ui-tabs-menu-option-add-hide-other-flows",label:RED._("workspace.hideOtherFlows"),onselect:"core:hide-other-flows"},{id:"red-ui-tabs-menu-option-add-show-all-flows",label:RED._("workspace.showAllFlows"),onselect:"core:show-all-flows"},{id:"red-ui-tabs-menu-option-add-hide-all-flows",label:RED._("workspace.hideAllFlows"),onselect:"core:hide-all-flows"},{id:"red-ui-tabs-menu-option-add-show-last-flow",label:RED._("workspace.showLastHiddenFlow"),onselect:"core:show-last-hidden-flow"}];let o=new Set;for(let t=0;t<n.length;t++){let e=n[t];(e=Array.isArray(e)?e:[e]).forEach(e=>{RED.nodes.workspace(e)&&o.add(e)})}var t=o.size;return 0<t&&e.unshift({label:RED._("workspace.hiddenFlows",{count:t}),onselect:"core:list-hidden-flows"}),e}}),h=0}function g(){$("#red-ui-workspace .red-ui-tabs").hide(),$("#red-ui-workspace-chart").hide(),$("#red-ui-workspace-footer").children().hide()}function m(e){f(e||s)}function v(e){y(e,!1)}function b(e){y(e,!0)}function y(e,t){var o,n=RED.nodes.workspace(e||s);n&&n.disabled!==t&&(o={disabled:n.disabled},n.disabled=t,$("#red-ui-tab-"+n.id.replace(".","-")).toggleClass("red-ui-workspace-disabled",!!n.disabled),e&&e!==s||$("#red-ui-workspace").toggleClass("red-ui-workspace-disabled",!!n.disabled),t={t:"edit",changes:o,node:n,dirty:RED.nodes.dirty()},n.changed=!0,RED.history.push(t),RED.events.emit("flows:change",n),RED.nodes.dirty(!0),RED.sidebar.config.refresh(),(e=RED.view.selection()).nodes||e.links||n.id!==s||RED.sidebar.info.refresh(n),o.hasOwnProperty("disabled")&&(RED.nodes.eachNode(function(e){e.z===n.id&&(e.dirty=!0)}),RED.view.redraw()))}function w(e){e?(a.contains(e.id)&&a.removeTab(e.id),e.id===s&&(s=0)):p(RED.nodes.workspace(s))}function E(e){var t=e.filter(function(e){return void 0!==RED.nodes.workspace(e)}),o=RED.nodes.getWorkspaceOrder();JSON.stringify(t)!==JSON.stringify(o)&&(RED.nodes.setWorkspaceOrder(t),RED.events.emit("flows:reorder",t)),a.order(e)}return{init:function(){$('<ul id="red-ui-workspace-tabs"></ul>').appendTo("#red-ui-workspace"),$('<div id="red-ui-workspace-tabs-shade" class="hide"></div>').appendTo("#red-ui-workspace"),$('<div id="red-ui-workspace-chart" tabindex="1"></div>').appendTo("#red-ui-workspace"),$('<div id="red-ui-workspace-toolbar"></div>').appendTo("#red-ui-workspace"),$('<div id="red-ui-workspace-footer" class="red-ui-component-footer"></div>').appendTo("#red-ui-workspace"),$('<div id="red-ui-editor-shade" class="hide"></div>').appendTo("#red-ui-workspace"),e(),RED.events.on("sidebar:resize",a.resize),RED.actions.add("core:show-next-tab",function(){var e=s;a.nextTab(),e!==s&&l(e)}),RED.actions.add("core:show-previous-tab",function(){var e=s;a.previousTab(),e!==s&&l(e)}),RED.menu.setAction("menu-item-workspace-delete",function(){p(RED.nodes.workspace(s))}),$(window).on("resize",function(){a.resize()}),RED.actions.add("core:add-flow",function(e){u(void 0,void 0,e?e.index:void 0)}),RED.actions.add("core:add-flow-to-right",function(e){u(void 0,void 0,a.activeIndex()+1)}),RED.actions.add("core:edit-flow",m),RED.actions.add("core:remove-flow",w),RED.actions.add("core:enable-flow",v),RED.actions.add("core:disable-flow",b),RED.actions.add("core:hide-flow",function(){var e=a.selection(),t=(0===e.length&&(e=[{id:s}]),[]);e.forEach(function(e){RED.workspaces.hide(e.id),n.pop(),t.push(e.id)}),0<t.length&&n.push(t),a.clearSelection()}),RED.actions.add("core:hide-other-flows",function(){var e=a.selection(),t=(0===e.length&&(e=[{id:s}]),new Set(e.map(function(e){return e.id}))),e=a.listTabs(),o=[];e.forEach(function(e){t.has(e)||(RED.workspaces.hide(e),n.pop(),o.push(e))}),0<o.length&&n.push(o)}),RED.actions.add("core:hide-all-flows",function(){var e=a.listTabs();e.forEach(function(e){RED.workspaces.hide(e),n.pop()}),0<e.length&&n.push(e),a.clearSelection()}),RED.actions.add("core:show-all-flows",function(){a.listTabs().forEach(function(e){RED.workspaces.show(e,null,!0)})}),RED.actions.add("core:show-last-hidden-flow",function(){var e,t=n.pop();t&&("string"==typeof t?RED.workspaces.show(t):(e=t.pop(),t.forEach(function(e){RED.workspaces.show(e,null,!0)}),setTimeout(function(){RED.workspaces.show(e)},150)))}),RED.actions.add("core:list-modified-nodes",function(){RED.actions.invoke("core:search","is:modified ")}),RED.actions.add("core:list-hidden-flows",function(){RED.actions.invoke("core:search","is:hidden ")}),RED.actions.add("core:list-flows",function(){RED.actions.invoke("core:search","type:tab ")}),RED.actions.add("core:list-subflows",function(){RED.actions.invoke("core:search","type:subflow ")}),RED.actions.add("core:go-to-previous-location",function(){0<o&&(o===t.length&&t.push(s),RED.workspaces.show(t[--o],!0))}),RED.actions.add("core:go-to-next-location",function(){o<t.length-1&&RED.workspaces.show(t[++o],!0)}),g()},add:u,remove:w,delete:p,order:E,edit:m,contains:function(e){return a.contains(e)},count:function(){return h},active:function(){return s},selection:function(){return a.selection()},hide:function(e){e=e||s,a.contains(e)&&a.hideTab(e)},isHidden:function(e){return n.includes(e)},show:function(e,t,o,n){if(!a.contains(e)){var i=RED.nodes.subflow(e);if(!i)return;u({type:"subflow",id:e,icon:"red/images/subflow_tab.svg",label:i.name,closeable:!0},null,a.activeIndex()+1),c(e)}if(o?a.showTab(e):(t||s===e||l(s),a.activateTab(e)),n){i=e.replace(".","-");r&&r.length&&(clearInterval(d),d=null,r.removeClass("highlighted"),r=null);let t=$("#red-ui-tab-"+i);t&&t.length&&(d=setInterval(function(e){e>=Date.now()?(e=t.hasClass("highlighted"),t.toggleClass("highlighted",!e)):(clearInterval(d),d=null,r=null,t.removeClass("highlighted"))},100,Date.now()+2200),(r=t).addClass("highlighted"))}},refresh:function(){RED.nodes.eachWorkspace(function(e){a.renameTab(e.id,e.label),$("#red-ui-tab-"+e.id.replace(".","-")).attr("flowname",e.label)}),RED.nodes.eachSubflow(function(e){a.contains(e.id)&&a.renameTab(e.id,e.name)}),RED.sidebar.config.refresh()},resize:function(){a.resize()},enable:v,disable:b}}(),RED.statusBar=function(){var o,n,i={};return{init:function(){o=$('<span class="red-ui-statusbar-bucket red-ui-statusbar-bucket-left">').appendTo("#red-ui-workspace-footer"),n=$('<span class="red-ui-statusbar-bucket red-ui-statusbar-bucket-right">').appendTo("#red-ui-workspace-footer")},add:function(e){i[e.id]=e;var t=$('<span class="red-ui-statusbar-widget"></span>');t.prop("id",e.id),e.element.appendTo(t),"left"===e.align?o.append(t):"right"===e.align&&n.prepend(t)}}}(),RED.view=function(){var X,Y,Z,u,w=5e3,Q=5e3,h=.75,R=1,I=100,N=30,p=650,l=1e3,c=0,f=[],d=0,n={},E=20,ee=!1,te=!1,P=null,y=[],oe=[],ne=[],ie=[],x={},g=null,D=null,_=[],ae={},k=null,T=null,se=null,C=null,re=0,j=null,de=[0,0],A=null,M=0,L=null,S=null,le=null,ce=null,s=!1,ue=null,pe=null,fe=0,he=0,ge=[],O=null,me=-1,ve=!1,be=[];let r;var ye="";let we;var z,Ee,m,De,Re,xe,_e,$e,ke,Te,B,Ce,a,je,t,Le={red:"#c00",green:"#5a8",yellow:"#F9DF31",blue:"#53A3F3",grey:"#d3d3d3",gray:"#d3d3d3"},G=1,F=0,U=(Ce=new Set,a=[],je={add:function(e){if(Array.isArray(e))for(var t=0;t<e.length;t++)je.add(e[t]);else if(!Ce.has(e.id)){a.push({n:e}),Ce.add(e.id);for(var o=RED.nodes.getNodeLinks(e.id,G).concat(RED.nodes.getNodeLinks(e.id,F)),t=0,n=o.length;t<n;t++){var i=o[t];(i.source===e&&Ce.has(i.target.id)||i.target===e&&Ce.has(i.source.id))&&V.add(i)}}},remove:function(e,t){if(Ce.has(e.id)){if(Ce.delete(e.id),void 0!==t&&a[t].n===e)a.splice(t,1);else for(var o=0;o<a.length;o++)if(a[o].n===e){a.splice(o,1);break}for(var n=RED.nodes.getNodeLinks(e.id,G).concat(RED.nodes.getNodeLinks(e.id,F)),o=0,i=n.length;o<i;o++)V.remove(n[o])}},clear:function(){Ce.clear(),a=[]},length:function(){return a.length},get:function(e){return a[e]},forEach:function(e){a.forEach(e)},nodes:function(){return a.map(function(e){return e.n})},has:function(e){return Ce.has(e.id)}}),V=(t=new Set,{add:function(e){t.add(e),e.selected=!0},remove:function(e){t.delete(e),e.selected=!1},clear:function(){t.forEach(function(e){e.selected=!1}),t.clear()},length:function(){return t.size},forEach:function(e){t.forEach(e)},has:function(e){return t.has(e)},toArray:function(){return Array.from(t)}});function Se(){for(var e=[],t=0;t<w;t+=+E)e.push(t);De.selectAll("line.red-ui-workspace-chart-grid-h").remove(),De.selectAll("line.red-ui-workspace-chart-grid-h").data(e).enter().append("line").attr({class:"red-ui-workspace-chart-grid-h",x1:0,x2:w,y1:function(e){return e},y2:function(e){return e}}),De.selectAll("line.red-ui-workspace-chart-grid-v").remove(),De.selectAll("line.red-ui-workspace-chart-grid-v").data(e).enter().append("line").attr({class:"red-ui-workspace-chart-grid-v",y1:0,y2:w,x1:function(e){return e},x2:function(e){return e}})}function Oe(e){me=-1;for(var t=0;t<e.length;t++){var o=e[t];o.el=_e.append("svg:path").attr("class","red-ui-flow-drag-line"),("link out"===o.node.type&&o.portType===F||"link in"===o.node.type&&o.portType===G)&&(o.el.attr("class","red-ui-flow-link-link red-ui-flow-drag-line"),o.virtualLink=!0,me=o.portType===F?G:F),B.push(o)}-1!==me&&y.forEach(function(e){"link in"!==e.type&&"link out"!==e.type||(e.dirty=!0)})}function Ie(){for(-1!==me&&y.forEach(function(e){"link in"!==e.type&&"link out"!==e.type||(e.dirty=!0)}),me=-1;B.length;){var e=B.pop();e.el&&e.el.remove()}}function J(){for(var e=RED.workspaces.active(),n=(0!==e?((y=RED.nodes.filterNodes({z:e})).forEach(function(e,t){e._index=t}),oe=RED.nodes.filterLinks({source:{z:e},target:{z:e}}),ne=RED.nodes.junctions(e)||[],(_=RED.nodes.groups(e)||[]).forEach(function(e,t){e._index=t,e.g?(e._root=e.g,e._depth=1):(e._root=e.id,e._depth=0)})):(y=[],oe=[],ne=[],_=[]),!1);n=!1,_.forEach(function(e){var t,o;e.g&&(t=RED.nodes.group(e.g))&&(o=t._depth,e._depth!==o+1&&(e._depth=o+1,n=!0),e._root!==t._root&&(e._root=t._root,n=!0))}),n;);_.sort(function(e,t){return e._root===t._root?e._depth-t._depth:e._index-t._index}),Te.selectAll(".red-ui-flow-group").data(_,function(e){return e.id}).sort(function(e,t){return e._root===t._root?e._depth-t._depth:e._index-t._index})}function Ne(e,t,o,n,i){var a,s,r,d,l,c=n-t,u=o-e,p=Math.sqrt(c*c+u*u),f=h;return 0<u*i?p<I&&(f=.75-(I-p)/I*.75):f=.4-.2*Math.max(0,(I-Math.min(Math.abs(u),Math.abs(c)))/I),0<u*i?"M "+e+" "+t+" C "+(e+i*(I*f))+" "+(t+0*N)+" "+(o-i*f*I)+" "+(n-0*N)+" "+o+" "+n:(p=Math.floor(o-u/2),u=Math.floor(n-c/2),a=N/2,d=(n+(u=0==c?n+N:u))/2,s=e+i*I*f,r=0<c?Math.min(d-c/2,t+a):Math.max(d-c/2,t-a),i=o-i*I*f,f=0<c?Math.max(d,n-a):Math.min(d,n+a),d=0<c?1:-1,(l=[[l=(e+s)/2,t],[s,0<c?Math.max(t,r-a):Math.min(t,r+a)],[l,0<c?Math.min(u,r+a):Math.max(u,r-a)],[i,0<c?Math.max(u,f-a):Math.min(u,f+a)],[(o+i)/2,n]])[2][1]===r+d*a&&(Math.abs(c)<10*a&&(l[1][1]=r-d*a/2,l[3][1]=f-d*a/2),l[2][0]=s),"M "+e+" "+t+" C "+l[0][0]+" "+l[0][1]+" "+l[1][0]+" "+l[1][1]+" "+s+" "+r+" S "+l[2][0]+" "+l[2][1]+" "+p+" "+u+" S "+l[3][0]+" "+l[3][1]+" "+i+" "+f+" S "+l[4][0]+" "+l[4][1]+" "+o+" "+n)}function Pe(){var e,t;RED.view.DEBUG&&console.warn("canvasMouseDown",{mouse_mode:M,point:d3.mouse(this),event:d3.event}),RED.contextMenu.hide(),M===RED.state.SELECTING_NODE?d3.event.stopPropagation():1===d3.event.button?(M=RED.state.PANNING,A=[d3.event.pageX,d3.event.pageY],ge=[z.scrollLeft(),z.scrollTop()]):2!==d3.event.button&&(T||k||se||d3.event.shiftKey||(V.clear(),W()),0===M&&L&&(L.remove(),L=null),!d3.event.touches&&0!==d3.event.button||(0!==M&&M!==RED.state.QUICK_JOINING||!d3.event.metaKey&&!d3.event.ctrlKey||d3.event.altKey||d3.event.shiftKey?0!==M||d3.event.metaKey||d3.event.ctrlKey||(d3.event.altKey?d3.event.altKey&&(q(),M=d3.event.shiftKey?RED.state.SLICING_JUNCTION:RED.state.SLICING,e=d3.mouse(this),S=m.append("path").attr("class","nr-ui-view-slice").attr("d",`M${e[0]} `+e[1]),le=e,RED.view.redraw()):d||(e=d3.mouse(this),L=m.append("rect").attr("ox",e[0]).attr("oy",e[1]).attr("rx",1).attr("ry",1).attr("x",e[0]).attr("y",e[1]).attr("width",0).attr("height",0).attr("class","nr-ui-view-lasso"),d3.event.preventDefault())):(d3.event.stopPropagation(),q(),t=Nt((e=d3.mouse(this))[0],e[1]),Ae({position:e,group:t=0<B.length?t||RED.nodes.group(B[0].node.g):t}))))}function Ae(e){function l(){var e,t,o;O&&(O.el||(O.el=_e.append("svg:path").attr("class","red-ui-flow-drag-line")),e=O.portType===F&&O.node.outputs||1,t=O.port,o=O.portType===F?1:-1,O.el.attr("d",Ne(O.node.x+o*O.node.w/2,O.node.y+(-(e-1)/2*13+13*t),p[0]-o*I/2,p[1],o)))}var t,c,u,p=(e=e||{}).position||be,f=e.splice,o=e.spliceMultiple,h=e.group,g=e.touchTrigger,e=(h&&!h.active&&(v(h,!1),b(h),RED.view.redraw()),p[0]),n=p[1],i=$("#red-ui-workspace-chart").offset(),a=e*R+i.left-$("#red-ui-workspace-chart").scrollLeft(),i=n*R+i.top-$("#red-ui-workspace-chart").scrollTop(),s=(RED.settings.get("editor").view["view-snap-grid"]&&(p[0]=Math.round(p[0]/E)*E,p[1]=Math.round(p[1]/E)*E),$("#red-ui-main-container").position());M!==RED.state.QUICK_JOINING&&(M=RED.state.QUICK_JOINING,$(window).on("keyup",it)),ce&&ce.remove(),(ce=m.append("g").attr("transform","translate("+(p[0]-I/2)+","+(p[1]-N/2)+")")).append("rect").attr("class","red-ui-flow-node-placeholder").attr("rx",5).attr("ry",5).attr("width",I).attr("height",N).attr("fill","none"),0<B.length&&(t=B[0].virtualLink?{type:"link in"===B[0].node.type?"link out":"link in"}:B[0].portType===F?{input:!0}:{output:!0},O={node:B[0].node,port:B[0].port,portType:B[0].portType},B[0].virtualLink&&(O.virtualLink=!0),Ie()),(f||o)&&(t={input:!0,output:!0,spliceMultiple:o});O&&l(),RED.typeSearch.show({x:a-s.left-I/2-(e-p[0]),y:i-s.top+N/2+5-(n-p[1]),disableFocus:g,filter:t,move:function(e,t){var o;ce&&(o=d3.transform(ce.attr("transform")).translate,ce.attr("transform","translate("+(o[0]+e)+","+(o[1]+t)+")"),p[0]+=e,p[1]+=t,l())},cancel:function(){O&&(O.el&&O.el.remove(),O=null),ce&&ce.remove(),K(),W(),Ie(),H()},add:function(e,t){var o;if(g&&(t=!1,K()),/^_action_:/.test(e))n=e.substring(9),ce.remove(),RED.actions.invoke(n);else{if("junction"===e)i={t:"add",junctions:[o={_def:{defaults:{}},type:"junction",z:RED.workspaces.active(),id:RED.nodes.id(),x:0,y:0,w:0,h:0,outputs:1,inputs:1,dirty:!0}]};else{var n=qt(e);if(!n)return;o=n.node,i=n.historyEvent}t&&(M=RED.state.QUICK_JOINING),o.x=p[0],o.y=p[1];var i,a,s,r,d,e=RED.utils.getMessageProperty(RED.settings.get("editor"),"view.view-node-show-label");void 0===e||o._def.hasOwnProperty("showLabel")&&!o._def.showLabel||o._def.defaults.hasOwnProperty("l")||(o.l=e),O?(n=null,(e=O).portType===F&&(0<o.inputs||e.virtualLink)?(n=e.node,r=e.port,d=o):e.portType===G&&(0<o.outputs||e.virtualLink)&&(n=o,d=e.node,r=0),null!==n?(e.virtualLink?(i={t:"multi",events:[i]},a=$.extend(!0,{},{v:n.links}).v,s=$.extend(!0,{},{v:d.links}).v,n.links.push(d.id),d.links.push(n.id),n.dirty=!0,d.dirty=!0,i.events.push({t:"edit",node:n,dirty:RED.nodes.dirty(),changed:n.changed,changes:{links:a}}),i.events.push({t:"edit",node:d,dirty:RED.nodes.dirty(),changed:d.changed,changes:{links:s}}),n.changed=!0,d.changed=!0):(RED.nodes.addLink(a={source:n,sourcePort:r,target:d}),i.links=[a]),t?(O.node=o,O.port=0):(O.el.remove(),O=null,M===RED.state.QUICK_JOINING&&(e.portType===F&&0<o.outputs?Oe([{node:o,port:0,portType:F}]):!O&&e.portType===G&&0<o.inputs?Oe([{node:o,port:0,portType:G}]):K()))):(Ie(),K())):t?0<o.outputs?O={node:o,port:0,portType:F}:0<o.inputs?O={node:o,port:0,portType:G}:K():M===RED.state.QUICK_JOINING&&(0<o.outputs?Oe([{node:o,port:0,portType:F}]):0<o.inputs?Oe([{node:o,port:0,portType:G}]):K()),"junction"===o.type?RED.nodes.addJunction(o):RED.nodes.add(o),RED.editor.validateNode(o),h&&(RED.group.addToGroup(h,o),(i="multi"!==i.t?{t:"multi",events:[i]}:i).events.push({t:"addToGroup",group:h,nodes:o})),f&&(K(),RED.nodes.removeLink(f),s={source:f.source,sourcePort:f.sourcePort,target:o},n={source:o,sourcePort:0,target:f.target},RED.nodes.addLink(s),RED.nodes.addLink(n),i.links=(i.links||[]).concat([s,n]),i.removedLinks=[f]),RED.history.push(i),RED.nodes.dirty(!0),q(),o.selected=!0,h&&(v(h,!1),b(h)),U.add(o),J(),W(),H(),void 0!==c&&(r=c+u/2,(d=o.x-o.w/2-r)!=2*E&&(o.x=o.x+2*E-d,o.dirty=!0,o.x=Math.ceil(o.x/E)*E,H())),t?(void 0===c&&setTimeout(function(){RED.typeSearch.refresh({filter:{input:!0}})},100),c=o.x,u=o.w,p[0]=o.x+o.w/2+I/2+2*E,ce.attr("transform","translate("+(p[0]-I/2)+","+(p[1]-N/2)+")"),l()):ce.remove()}}}),J(),W(),H()}function Me(){var c,e;if(M===RED.state.PANNING)l=[d3.event.pageX,d3.event.pageY],d3.event.touches&&(l=[(b=d3.event.touches.item(0)).pageX,b.pageY]),b=[A[0]-l[0],A[1]-l[1]],z.scrollLeft(ge[0]+b[0]),z.scrollTop(ge[1]+b[1]);else if(A=d3.touches(this)[0]||d3.mouse(this),L)l=parseInt(L.attr("ox")),b=parseInt(L.attr("oy")),e=parseInt(L.attr("x")),t=parseInt(L.attr("y")),l=A[0]<l?l-(e=A[0]):A[0]-e,b=A[1]<b?b-(t=A[1]):A[1]-t,L.attr("x",e).attr("y",t).attr("width",l).attr("height",b);else if(M===RED.state.SLICING||M===RED.state.SLICING_JUNCTION)S&&20<Math.max(1,Math.abs(le[0]-A[0]))*Math.max(1,Math.abs(le[1]-A[1]))&&(e=S.attr("d"),e+=" L"+A[0]+" "+A[1],S.attr("d",e),le=A);else if(M===RED.state.SELECTING_NODE)d3.event.stopPropagation();else if(M==RED.state.QUICK_JOINING||M==RED.state.IMPORT_DRAGGING||M==RED.state.DETACHED_DRAGGING||T||se||0!==V.length()){if(M==RED.state.JOINING||M===RED.state.QUICK_JOINING){if(0===B.length&&null!==C){if(d3.event.shiftKey){var t,o=[],n=[];for(0<V.length()?V.forEach(function(e){(C===F&&e.source===T&&e.sourcePort===re||C===G&&e.target===T)&&n.push(e)}):(t=C===F?{source:T,sourcePort:re}:{target:T},n=RED.nodes.filterLinks(t)),y=0;y<n.length;y++){var i=n[y];RED.nodes.removeLink(i),o.push({link:i,node:C===F?i.target:i.source,port:C===F?0:i.sourcePort,portType:C===F?G:F})}0===o.length?(K(),H()):(Oe(o),M=0,J(),H(),M=RED.state.JOINING)}else T&&!O&&Oe([{node:T,port:re,portType:C}]);V.clear()}for(u=A,y=0;y<B.length;y++){var a=B[y],s=a.portType===F&&a.node.outputs||1,r=a.port,d=a.portType===F?1:-1;a.el.attr("d",Ne(a.node.x+d*a.node.w/2,a.node.y+(-(s-1)/2*13+13*r),u[0],u[1],d))}d3.event.preventDefault()}else if(M==RED.state.MOVING){u=d3.mouse(document.body),isNaN(u[0])&&(u=d3.touches(document.body)[0]);var l=(de[0]-u[0])*(de[0]-u[0])+(de[1]-u[1])*(de[1]-u[1]);(3<l&&!pe||pe&&10<l)&&(M=RED.state.MOVING_ACTIVE,he=0,te=!1,1===U.length()&&(c=U.get(0),te=c.n.hasOwnProperty("_def")&&(c.n.hasOwnProperty("inputs")&&0<c.n.inputs||!c.n.hasOwnProperty("inputs")&&0<c.n._def.inputs)&&(c.n.hasOwnProperty("outputs")&&0<c.n.outputs||!c.n.hasOwnProperty("outputs")&&0<c.n._def.outputs)&&0===RED.nodes.filterLinks({source:c.n}).length&&0===RED.nodes.filterLinks({target:c.n}).length))}else if(M==RED.state.MOVING_ACTIVE||M==RED.state.IMPORT_DRAGGING||M==RED.state.DETACHED_DRAGGING){for(var u=A,p=0,f=0,h=w,g=Q,m=0;m<U.length();m++)c=U.get(m),d3.event.shiftKey&&(c.n.ox=c.n.x,c.n.oy=c.n.y),c.n.x=u[0]+c.dx,c.n.y=u[1]+c.dy,c.n.dirty=!0,g="group"===c.n.type?(!1!==c.n.groupMoved&&(c.n.groupMoved=!0),RED.group.markDirty(c.n),p=Math.min(c.n.x-5,p),f=Math.min(c.n.y-5,f),h=Math.max(c.n.x+c.n.w+5,h),Math.max(c.n.y+c.n.h+5,g)):(p=Math.min(c.n.x-c.n.w/2-5,p),f=Math.min(c.n.y-c.n.h/2-5,f),h=Math.max(c.n.x+c.n.w/2+5,h),Math.max(c.n.y+c.n.h/2+5,g));if(0!==p||0!==f)for(y=0;y<U.length();y++)(c=U.get(y)).n.x-=p,c.n.y-=f;if(h!==w||g!==Q)for(y=0;y<U.length();y++)(c=U.get(y)).n.x-=h-w,c.n.y-=g-Q;var v=[0,0];if(ee!=d3.event.shiftKey&&0<U.length()){for(var b,y=0;c=U.get(y++),y<U.length()&&"group"===c.n.type;);if("group"===c.n.type?(v[0]=c.n.x-E*Math.floor(c.n.x/E)-E/2,v[1]=c.n.y-E*Math.floor(c.n.y/E)-E/2):(b=RED.view.tools.calculateGridSnapOffsets(c.n),v[0]=b.x,v[1]=b.y),0!==v[0]||0!==v[1])for(y=0;y<U.length();y++)(c=U.get(y)).n.x-=v[0],c.n.y-=v[1],c.n.x==c.n.ox&&c.n.y==c.n.oy&&(c.dirty=!1)}1===U.length()&&"group"!==U.get(0).n.type&&(c=U.get(0),te&&(Y=Y||setTimeout(function(){for(var e,t=[],o=1/0,n=null,i=c.n.x,a=c.n.y,t=Ee[0][0].getIntersectionList?((e=Ee[0][0].createSVGRect()).x=i*R,e.y=a*R,e.width=1,e.height=1,Ee[0][0].getIntersectionList(e,Ee[0][0])):RED.view.getLinksAtPoint(i*R,a*R),s=0;s<t.length;s++)if(d3.select(t[s]).classed("red-ui-flow-link-background"))for(var r=t[s].getTotalLength(),d=0;d<r;d+=10){var l=t[s].getPointAtLength(d),l=(l.x-i)*(l.x-i)+(l.y-a)*(l.y-a);l<200&&l<o&&(o=l,n=t[s])}X&&X!==n&&d3.select(X.parentNode).classed("red-ui-flow-link-splice",!1),n?d3.select(n.parentNode).classed("red-ui-flow-link-splice",!0):d3.select(".red-ui-flow-link-splice").classed("red-ui-flow-link-splice",!1),X=n,Y=null},100)),"subflow"!==c.n.type&&!c.n.g&&_&&(Z=Z||setTimeout(function(){D=Nt(c.n.x,c.n.y);for(var e=0;e<_.length;e++){var t=_[e];t===D?(t.hovered=!0,t.dirty=!0):t.hovered&&(t.hovered=!1,t.dirty=!0)}Z=null},50)))}0!==M&&H()}}function ze(){0!==M&&0!==d3.event.buttons&&d3.select(document).on("mouseup.red-ui-workspace-tracker",function(){d3.select(document).on("mouseup.red-ui-workspace-tracker",null),Be.call(this)})}function Be(){var a,s,r,d;if(be=[d3.event.offsetX/R,d3.event.offsetY/R],RED.view.DEBUG&&console.warn("canvasMouseUp",{mouse_mode:M,point:d3.mouse(this),event:d3.event}),2!==d3.event.button)if(M===RED.state.PANNING)K();else if(M===RED.state.SELECTING_NODE)d3.event.stopPropagation();else if(M!==RED.state.QUICK_JOINING){if(T&&M==RED.state.JOINING){for(var e=[],t=0;t<B.length;t++)B[t].link&&e.push(B[t].link);0<e.length&&(f={t:"delete",links:e,dirty:RED.nodes.dirty()},RED.history.push(f),RED.nodes.dirty(!0)),Ie()}if(L?(a=parseInt(L.attr("x")),s=parseInt(L.attr("y")),r=a+parseInt(L.attr("width")),d=s+parseInt(L.attr("height")),o=g,d3.event.shiftKey||(q(),o&&a<o.x+o.w&&r>o.x&&s<o.y+o.h&&d>o.y&&(b(o),g.selected=!0)),_.forEach(function(e){if(!e.selected&&e.x>a&&e.x+e.w<r&&e.y>s&&e.y+e.h<d&&(!g||RED.group.contains(g,e))){for(;e.g&&(!g||e.g!==g.id);)e=RED.nodes.group(e.g);e.selected||v(e,!0)}}),y.forEach(function(e){if(!e.selected&&e.x>a&&e.x<r&&e.y>s&&e.y<d&&(!g||RED.group.contains(g,e)))if(!e.g||g&&e.g===g.id)e.selected=!0,e.dirty=!0,U.add(e);else{for(var t=RED.nodes.group(e.g);t.g&&(!g||t.g!==g.id);)t=RED.nodes.group(t.g);t.selected||v(t,!0)}}),ne.forEach(function(e){e.selected||e.x>a&&e.x<r&&e.y>s&&e.y<d&&(e.selected=!0,e.dirty=!0,U.add(e))}),oe.forEach(function(e){var t,o,n,i;e.selected||(t=e.source.y,o=e.target.y,n=e.source.x+e.source.w/2+10,i=e.target.x-e.target.w/2-10,a<n&&n<r&&s<t&&t<d&&a<i&&i<r&&s<o&&o<d&&V.add(e))}),P&&(P.in.forEach(function(e){e.selected=e.x>a&&e.x<r&&e.y>s&&e.y<d,e.selected&&(e.dirty=!0,U.add(e))}),P.out.forEach(function(e){e.selected=e.x>a&&e.x<r&&e.y>s&&e.y<d,e.selected&&(e.dirty=!0,U.add(e))}),P.status&&(P.status.selected=P.status.x>a&&P.status.x<r&&P.status.y>s&&P.status.y<d,P.status.selected&&(P.status.dirty=!0,U.add(P.status)))),W(),L.remove(),L=null):M!=RED.state.DEFAULT||null!=k||d3.event.ctrlKey||d3.event.metaKey?M==RED.state.SLICING?(Ye(),S.remove(),S=null,RED.view.redraw(!0)):M==RED.state.SLICING_JUNCTION&&(RED.actions.invoke("core:split-wires-with-junctions"),S.remove(),S=null):(q(),W()),M==RED.state.MOVING_ACTIVE&&0<U.length()){var o=null;if(D){for(var n=0;n<U.length();n++){var i=U.get(n);RED.group.addToGroup(D,i.n)}(o=D).hovered=!1,b(D),g.selected=!0,D=null}for(var l,c,u=[],n=0;n<U.length();n++)(i=U.get(n)).ox===i.n.x&&i.oy===i.n.y||(u.push({n:i.n,ox:i.ox,oy:i.oy,moved:i.n.moved}),i.n.dirty=!0,i.n.moved=!0);0<u.length&&M==RED.state.MOVING_ACTIVE&&(f={t:"move",nodes:u,dirty:RED.nodes.dirty()},X&&(l=d3.select(X).data()[0],RED.nodes.removeLink(l),p={source:l.source,sourcePort:l.sourcePort,target:U.get(0).n},c={source:U.get(0).n,sourcePort:0,target:l.target},RED.nodes.addLink(p),RED.nodes.addLink(c),f.links=[p,c],f.removedLinks=[l],J()),o&&(f.addToGroup=o),RED.nodes.dirty(!0),RED.history.push(f))}if(M==RED.state.MOVING||M==RED.state.MOVING_ACTIVE||M==RED.state.DETACHED_DRAGGING){if(M===RED.state.DETACHED_DRAGGING){for(u=[],n=0;n<U.length();n++)(i=U.get(n)).ox===i.n.x&&i.oy===i.n.y||(u.push({n:i.n,ox:i.ox,oy:i.oy,moved:i.n.moved}),i.n.dirty=!0,i.n.moved=!0);var p=RED.history.peek(),f={t:"move",nodes:u,dirty:RED.nodes.dirty()};("multi"===p.t?p.events:RED.history).push(f)}for(t=0;t<U.length();t++){var h=U.get(t);delete h.ox,delete h.oy}}M==RED.state.IMPORT_DRAGGING&&("cut"===we&&(we="copy"),J(),RED.nodes.dirty(!0)),K(),H()}}function Ge(){R<2&&e(R+.1)}function Fe(){.3<R&&e(R-.1)}function Ue(){e(1)}function Ve(){RED.actions.invoke("core:search",$(this).data("term"))}function Je(){RED.actions.invoke("core:search-previous")}function qe(){RED.actions.invoke("core:search-next")}function e(e){var t=[z.width(),z.height()],o=[z.scrollLeft(),z.scrollTop()],n=[(o[0]+t[0]/2)/R,(o[1]+t[1]/2)/R],t=(R=e,[(o[0]+t[0]/2)/R,(o[1]+t[1]/2)/R]),t=[(t[0]-n[0])*R,(t[1]-n[1])*R];z.scrollLeft(o[0]-t[0]),z.scrollTop(o[1]-t[1]),RED.view.navigator.resize(),H(),RED.settings.get("editor.view.view-store-zoom")&&RED.settings.setLocal("zoom-level",e.toFixed(1))}function We(){if(M!==RED.state.MOVING&&M!==RED.state.MOVING_ACTIVE){if(M===RED.state.DETACHED_DRAGGING){for(var e=0;e<U.length();e++){var t=U.get(e);t.n.x=t.ox,t.n.y=t.oy}q(),RED.history.pop(),M=0}else M===RED.state.IMPORT_DRAGGING?(q(),RED.history.pop(),M=0):M===RED.state.SLICING||M===RED.state.SLICING_JUNCTION?(S&&(S.remove(),S=null,K()),q()):L?(L.remove(),L=null):(g?Ot:q)();H()}}function Ke(){var e;M===RED.state.SELECTING_NODE&&u.single||(V.clear(),g?(e=g,q(),b(e),RED.group.getNodes(e,!1).forEach(function(e){"group"===e.type?v(e,!0,!0):(U.add(e),e.selected=!0,e.dirty=!0)}),g.selected=!0):(q(),Ot(),_.forEach(function(e){e.g?(e.selected=!1,e.dirty=!0):(v(e,!0),e.selected||(e.selected=!0,e.dirty=!0))}),y.forEach(function(e){M===RED.state.SELECTING_NODE&&u.filter&&!u.filter(e)||e.g||e.selected||(e.selected=!0,e.dirty=!0,U.add(e))}),ne.forEach(function(e){e.selected||(e.selected=!0,e.dirty=!0,U.add(e))}),M!==RED.state.SELECTING_NODE&&P&&(P.in.forEach(function(e){e.selected||(e.selected=!0,e.dirty=!0,U.add(e))}),P.out.forEach(function(e){e.selected||(e.selected=!0,e.dirty=!0,U.add(e))}),P.status&&!P.status.selected&&(P.status.selected=!0,P.status.dirty=!0,U.add(P.status)))),M!==RED.state.SELECTING_NODE&&W(),H())}function q(){RED.view.DEBUG&&console.warn("clearSelection",M,"movingSet.length():",U.length());for(var e=0;e<U.length();e++){var t=U.get(e);t.n.dirty=!0,t.n.selected=!1}U.clear(),V.clear(),g&&(g.active=!1,g.dirty=!0,g=null),_.forEach(function(e){e.selected=!1,e.dirty=!0})}var He=null;function W(){var e={},t=RED.workspaces.active(),o=RED.workspaces.selection();if(0!==t)if(0===o.length){e=Jt(),oe=RED.nodes.filterLinks({source:{z:t},target:{z:t}});RED.nodes.getWorkspaceOrder();var n={};ie=[],Object.keys(x).forEach(function(e){x[e].dirty=!0}),x={};for(var i=0;i<U.length();i++){var a,s,r=U.get(i);("link out"===r.n.type&&"return"!==r.n.mode||"link in"===r.n.type)&&r.n.z===t&&(a=r.n,x[a.id]=a,s={},a.links.forEach(function(e){e=RED.nodes.node(e);e&&("link out"===a.type?e.z===a.z?n[a.id+":"+e.id]||(oe.push({source:a,sourcePort:0,target:e,link:!0}),n[a.id+":"+e.id]=!0,(x[e.id]=e).dirty=!0):(s[e.z]=s[e.z]||[],s[e.z].push(e)):e.z===a.z?n[e.id+":"+a.id]||(oe.push({source:e,sourcePort:0,target:a,link:!0}),n[e.id+":"+a.id]=!0,(x[e.id]=e).dirty=!0):(s[e.z]=s[e.z]||[],s[e.z].push(e)))}),0<Object.keys(s).length&&ie.push({refresh:Math.floor(1e4*Math.random()),node:a,links:s}))}0===ie.length&&0<V.length()&&V.forEach(function(e){e.link&&(oe.push(e),x[e.source.id]=e.source,e.source.dirty=!0,x[e.target.id]=e.target,e.target.dirty=!0)})}else e.flows=o;o=t+":"+JSON.stringify(e,function(e,t){return"nodes"===e||"flows"===e?t.map(function(e){return e.id}):"link"===e?t.source.id+":"+t.sourcePort+":"+t.target.id:"links"===e?t.map(function(e){return e.source.id+":"+e.sourcePort+":"+e.target.id}):t});o!==He&&(He=o,RED.events.emit("view:selection-changed",e))}function Xe(){var e;0<U.length()&&("subflow"===(e=U.get(0).n).type?RED.editor.editSubflow(P):"group"===e.type?RED.editor.editGroup(e):RED.editor.edit(e))}function Ye(e){if(M!==RED.state.SELECTING_NODE){dt&&(dt.remove(),dt=null);var t=RED.workspaces.selection();if(0<t.length){var o=0;if(t.forEach(function(e){"tab"===e.type&&o++}),o!==RED.workspaces.count()){for(var n={t:"delete",dirty:RED.nodes.dirty(),nodes:[],links:[],groups:[],junctions:[],workspaces:[],subflows:[]},i=RED.nodes.getWorkspaceOrder().slice(0),a=0;a<t.length;a++){var s,r=t[a];r._index=i.indexOf(r.id),RED.workspaces.remove(r),"tab"===r.type?(n.workspaces.push(r),s=RED.nodes.removeWorkspace(r.id)):(s=RED.subflow.removeSubflow(r.id),n.subflows=n.subflows.concat(s.subflows)),n.nodes=n.nodes.concat(s.nodes),n.links=n.links.concat(s.links),n.groups=n.groups.concat(s.groups),n.junctions=n.junctions.concat(s.junctions)}RED.history.push(n),RED.nodes.dirty(!0),J(),W(),H()}}else if(0<U.length()||0<V.length()){function d(e){e&&(Array.isArray(e)?e:[e]).forEach(function(e){u.push(e),V.remove(e)})}var l,c=[],u=[],p=[],f=[],h=[],g=[],m=[],v=[],b=(e&&(0<(b=(e=RED.nodes.detachNodes(U.nodes())).newLinks).length&&v.push({t:"add",links:b}),d(e.removedLinks)),RED.nodes.dirty()),y=[];if(0<U.length()){for(a=0;a<U.length();a++)"group"===(R=U.get(a).n).type&&y.push(R);for(a=0;a<y.length;a++)y[a].nodes.forEach(function(e){"group"===e.type&&-1===y.indexOf(e)&&y.push(e)});for(var w,E,D,R,a=0;a<U.length();a++)(R=U.get(a).n).selected=!1,"group"!==R.type&&"subflow"!==R.type&&"junction"!==R.type?(R.x<0&&(R.x=25),w=RED.nodes.remove(R.id),c.push(R),c=c.concat(w.nodes),d(w.links),R.g&&(w=RED.nodes.group(R.g),-1===y.indexOf(w)&&(E=w.nodes.indexOf(R),w.nodes.splice(E,1),RED.group.markDirty(w)))):"junction"===R.type?(D=RED.nodes.removeJunction(R),f.push(R),u=u.concat(D.links)):("out"===R.direction?h.push(R):"in"===R.direction?g.push(R):"status"===R.direction&&(l=R),R.dirty=!0);for(a=y.length-1;0<=a;a--){var x=y[a];p.push(x),RED.nodes.removeGroup(x)}0<h.length&&(D=RED.subflow.removeOutput(h))&&d(D.links),1==g.length&&(D=RED.subflow.removeInput())&&d(D.links),l&&(D=RED.subflow.removeStatus())&&d(D.links);e=RED.subflow.refresh(!0);e&&(m=e.instances),U.clear(),(0<c.length||0<h.length||0<g.length||l||0<p.length||0<f.length)&&RED.nodes.dirty(!0)}0<V.length()&&V.forEach(function(e){var t,o;e.link?(t=e.source.id,o=e.target.id,t=e.target.links.indexOf(t),o=e.source.links.indexOf(o),v.push({t:"edit",node:e.source,changed:e.source.changed,changes:{links:$.extend(!0,{},{v:e.source.links}).v}}),v.push({t:"edit",node:e.target,changed:e.target.changed,changes:{links:$.extend(!0,{},{v:e.target.links}).v}}),e.source.changed=!0,e.target.changed=!0,e.target.links.splice(t,1),e.source.links.splice(o,1),e.source.dirty=!0,e.target.dirty=!0):(RED.nodes.removeLink(e),u.push(e))}),RED.nodes.dirty(!0);n={t:"delete",nodes:c,links:u,groups:p,junctions:f,subflowOutputs:h,subflowInputs:g,subflow:{id:P?P.id:void 0,instances:m},dirty:b};l&&(n.subflow.status=l),0<v.length?(v.unshift(n),RED.history.push({t:"multi",events:v})):RED.history.push(n),V.clear(),J(),W(),H()}}}function Ze(e){if(M!==RED.state.SELECTING_NODE){var t=[],o=RED.workspaces.selection();if(0<o.length?(t=[],o.forEach(function(e){"tab"===e.type&&(t.push(e),t=(t=t.concat(RED.nodes.groups(e.id))).concat(RED.nodes.filterNodes({z:e.id})))})):(o=RED.view.selection()).nodes&&o.nodes.forEach(function(e){t.push(e),"group"===e.type&&(t=t.concat(RED.group.getNodes(e,!0)))}),0<t.length){for(var n=[],i=0,a=0,s={},r=0;r<t.length;r++){var d=t[r];if(!s[d.id]&&(s[d.id]=!0,"subflow"!=d.type)){for(var l in"group"===d.type?a++:"junction"===d.type?0:i++,d._def.defaults)d._def.defaults.hasOwnProperty(l)&&d._def.defaults[l].type&&(l=RED.nodes.node(d[l]))&&l._def.exclusive&&n.push(RED.nodes.convertNode(l));n.push(RED.nodes.convertNode(d))}}ye=JSON.stringify(n),we=e?"cut":"copy",RED.menu.setDisabled("menu-item-edit-paste",!1),0<i?RED.notify(RED._("clipboard.nodeCopied",{count:i}),{id:"clipboard"}):0<a&&RED.notify(RED._("clipboard.groupCopied",{count:a}),{id:"clipboard"})}}}function Qe(e,t){for(var o=nt(e),n=0,i=0;i<o.length;i++){var a=ot(o[i],t)[0];n<a&&(n=a)}return{lines:o,width:n}}var et={},tt={};function ot(e,t){var o="!"+e;if(et[t]){if(tt[t][o])return tt[t][o]}else et[t]=document.createElement("span"),et[t].className=t,et[t].style.position="absolute",et[t].style.top="-1000px",document.getElementById("red-ui-editor").appendChild(et[t]),tt[t]={};et[t].textContent=e||"";var e=et[t].offsetWidth,n=et[t].offsetHeight;return tt[t][o]=[e,n],tt[t][o]}function nt(e){var t=[],o=e.split(/\\n /);if(1<o.length){for(var n=0,n=0;n<o.length-1;n++)/\\$/.test(o[n])?(t.push(o[n]+"\\n "+o[n+1]),n++):t.push(o[n]);n===o.length-1&&t.push(o[o.length-1])}else t=o;return t=t.map(function(e){return e.replace(/\\\\n /g,"\\n ").trim()})}function K(){M=0,X=C=k=j=se=T=null,te=!1,D&&(D.hovered=!1,D=null),d3.selectAll(".red-ui-flow-link-splice").classed("red-ui-flow-link-splice",!1),Y&&(clearTimeout(Y),Y=null),Z&&(clearTimeout(Z),Z=null)}function it(e){17!==e.keyCode&&"Meta"!==e.key&&91!==e.keyCode||(K(),Ie(),H(),$(window).off("keyup",it))}function at(e,t,o,n){RED.view.DEBUG&&console.warn("portMouseDown",M,e,t,o),RED.contextMenu.hide(),1!==(n=n||d3.event)&&(M===RED.state.SELECTING_NODE?n.stopPropagation():(T=e,C=t,re=o||0,M!==RED.state.QUICK_JOINING&&(M=RED.state.JOINING,document.body.style.cursor="crosshair",(n.ctrlKey||n.metaKey)&&(M=RED.state.QUICK_JOINING,Oe([{node:T,port:re,portType:C}]),$(window).on("keyup",it))),n.stopPropagation(),n.preventDefault()))}function st(e,n,i,t){if(RED.view.DEBUG&&console.warn("portMouseUp",M,e,n,i),t=t||d3.event,M===RED.state.SELECTING_NODE)t.stopPropagation();else{if(M===RED.state.QUICK_JOINING&&0<B.length){if(B[0].node===e)return;if(B[0].virtualLink&&("link in"===B[0].node.type&&"link out"!==e.type||"link out"===B[0].node.type&&"link in"!==e.type))return}if(document.body.style.cursor="",M==RED.state.JOINING||M==RED.state.QUICK_JOINING){if("undefined"!=typeof TouchEvent&&t instanceof TouchEvent){var a=!1;if(RED.nodes.eachNode(function(e){var t,o;e.z==RED.workspaces.active()&&(t=e.w/2,o=e.h/2,e.x-t<A[0]&&e.x+t>A[0]&&e.y-o<A[1]&&e.y+o>A[1]&&(a=!0,n=0<(j=e).inputs?G:F,i=0))}),!a&&P){var o=[];P.status&&o.push(P.status),P.in&&(o=o.concat(P.in)),P.out&&(o=o.concat(P.out));for(var s=0;s<o.length;s++){var r=o[s],d=r.w/2,l=r.h/2;if(r.x-d<A[0]&&r.x+d>A[0]&&r.y-l<A[1]&&r.y+l>A[1]){a=!0,n="in"===(j=r).direction?F:G,i=0;break}}}}else j=e;var c=[],u=[],p=[],f=null;for(s=0;s<B.length;s++)B[s].link&&u.push(B[s].link);var h,g,m,v,b,y,w,E,D=[];for(s=0;s<B.length;s++)n!=B[s].portType&&j!==B[s].node&&((h=B[s]).portType===F?(g=h.node,v=h.port,m=j):h.portType===G&&(g=j,m=h.node,v=i||0),b={source:g,sourcePort:v,target:m},h.virtualLink?/^link (in|out)$/.test(g.type)&&/^link (in|out)$/.test(m.type)&&g.type!==m.type&&-1===g.links.indexOf(m.id)&&-1===m.links.indexOf(g.id)&&(y=$.extend(!0,{},{v:g.links}).v,w=$.extend(!0,{},{v:m.links}).v,g.links.push(m.id),m.links.push(g.id),g.dirty=!0,m.dirty=!0,p.push(g),p.push(m),b.link=!0,oe.push(b),x[g.id]=g,x[m.id]=m,f=b,D.push({t:"edit",node:g,dirty:RED.nodes.dirty(),changed:g.changed,changes:{links:y}}),D.push({t:"edit",node:m,dirty:RED.nodes.dirty(),changed:m.changed,changes:{links:w}}),g.changed=!0,m.changed=!0):"link out"===e.type&&n===F||"link in"===e.type&&n===G||n===F&&"subflow"!==j.type&&0===j.outputs||n===G&&"subflow"!==j.type&&0===j.inputs||h.portType===G&&"subflow"===j.type&&("status"===j.direction||"out"===j.direction)||h.portType===F&&"subflow"===j.type&&"in"===j.direction||0!==RED.nodes.filterLinks({source:g,target:m,sourcePort:v}).length||(RED.nodes.addLink(b),c.push(b)));(0<c.length||0<u.length||0<p.length)&&(t=0<p.length?{t:"multi",events:D,dirty:RED.nodes.dirty()}:{t:"add",links:c,removedLinks:u,dirty:RED.nodes.dirty()},P&&(E=RED.subflow.refresh(!0))&&(t.subflow={id:P.id,changed:P.changed,instances:E.instances}),RED.history.push(t),J(),RED.nodes.dirty(!0)),M===RED.state.QUICK_JOINING?((0<c.length||0<p.length)&&(Ie(),n===G&&0<e.outputs?Oe([{node:e,port:0,portType:F}]):n===F&&0<e.inputs?Oe([{node:e,port:0,portType:G}]):K(),(k=f)?(V.clear(),V.add(f),W()):V.clear()),H()):(K(),Ie(),f&&(V.clear(),V.add(f)),(k=f)&&W(),H())}}}var o,rt=null,dt=null;function lt(e){var t=d3.select(e);if("red-ui-workspace-chart-event-layer"===t.attr("class"))return[0,0];var o=[0,0],n=("g"===e.nodeName.toLowerCase()?(n=t.attr("transform"))&&(o=d3.transform(n).translate):o=[t.attr("x")||0,t.attr("y")||0],lt(e.parentNode));return[o[0]+n[0],o[1]+n[1]]}function ct(t,o,e){var n,i=o===G?t.inputLabels:t.outputLabels;if(i&&i[e])return i[e];i=o===G?t._def.inputLabels:t._def.outputLabels;if("string"==typeof i)n=i;else if("function"==typeof i)try{n=i.call(t,e)}catch(e){console.log("Definition error: "+t.type+"."+(o===G?"inputLabels":"outputLabels"),e),n=null}else $.isArray(i)&&(n=i[e]);return n}function ut(e,t,o,n){var i,a,s,r=m.append("g").attr("transform","translate("+e+","+t+")").attr("class","red-ui-flow-port-tooltip"),e=o.indexOf("\\n "),t=(o=-1<e&&"\\"!==o[e-1]?o.substring(0,e)+"...":o).split("\n"),d=6,l=12,c=[],u=0,e=(t.forEach(function(e,t){e=ot(e||"&nbsp;","red-ui-flow-port-tooltip-label");d=Math.max(d,e[0]+14),c.push(e[1]),0===t&&(u=e[1]),l+=e[1]}),d/2-5-2),o=l/2-5-2,p=l-4,f=-l/2;return"left"===n?(i="M0 0 l -5 -5 v -"+o+" q 0 -2 -2 -2 h -"+d+" q -2 0 -2 2 v "+p+" q 0 2 2 2 h "+d+" q 2 0 2 -2 v -"+o+" l 5 -5",a=-14,s="end"):"right"===n?(i="M0 0 l 5 -5 v -"+o+" q 0 -2 2 -2 h "+d+" q 2 0 2 2 v "+p+" q 0 2 -2 2 h -"+d+" q -2 0 -2 -2 v -"+o+" l -5 -5",a=14,s="start"):"top"===n&&(i="M0 0 l 5 -5 h "+e+" q 2 0 2 -2 v -"+l+" q 0 -2 -2 -2 h -"+(d-4)+" q -2 0 -2 2 v "+l+" q 0 2 2 2 h "+e+" l 5 5",a=-d/2+6,f=-l-u+12,s="start"),r.append("path").attr("d",i),t.forEach(function(e,t){f+=c[t],r.append("svg:text").attr("class","red-ui-flow-port-tooltip-label").attr("x",a).attr("y",f).attr("text-anchor",s).text(e||" ")}),r}function pt(o,n,i,a){var e;M===RED.state.SELECTING_NODE?d3.event.stopPropagation():(clearTimeout(rt),(e=M!=RED.state.JOINING&&M!=RED.state.QUICK_JOINING||0<B.length&&B[0].portType!==i&&(!B[0].virtualLink||"link in"===B[0].node.type&&"link out"===n.type||"link out"===B[0].node.type&&"link in"===n.type))&&(i===G&&(n._def&&n._def.inputLabels||n.inputLabels)||i===F&&(n._def&&n._def.outputLabels||n.outputLabels))&&(rt=setTimeout(function(){var e,t=o&&o.node();t&&t.__data__&&t.__data__.id;t&&t.parentNode&&RED.nodes.node(t.__data__.id)&&((e=ct(n,i,a))&&(t=lt(t),rt=null,dt=ut(t[0]+(i===G?-2:12),t[1]+5,e,i===G?"left":"right")))},500)),o.classed("red-ui-flow-port-hovered",e))}function ft(e){M===RED.state.SELECTING_NODE?d3.event.stopPropagation():(clearTimeout(rt),dt&&(dt.remove(),dt=null),e.classed("red-ui-flow-port-hovered",!1))}function ht(e){for(M=RED.state.MOVING,i=0;i<U.length();i++){var t=U.get(i);t.ox=t.n.x,t.oy=t.n.y,t.dx=t.n.x-e[0],t.dy=t.n.y-e[1]}try{de=d3.mouse(document.body),isNaN(de[0])&&(de=d3.touches(document.body)[0])}catch(e){de=[0,0]}}function gt(e){if(RED.view.DEBUG&&console.warn("nodeMouseUp",M,e),M===RED.state.SELECTING_NODE)d3.event.stopPropagation();else if(pe&&T==e&&0<he&&he<p)M=RED.state.DEFAULT,"subflow"!=e.type?/^subflow:/.test(e.type)&&(d3.event.ctrlKey||d3.event.metaKey)?RED.workspaces.show(e.type.substring(8)):RED.editor.edit(e):RED.editor.editSubflow(P),he=0,d3.event.stopPropagation();else{if(M===RED.state.MOVING)if(!ve&&!e.selected&&e.g&&RED.nodes.group(e.g).selected)return q(),v(RED.nodes.group(e.g),!1),b(RED.nodes.group(e.g)),T.selected=!0,U.add(T),(t=d3.touches(this)[0]||d3.mouse(this))[0]+=e.x-e.w/2,t[1]+=e.y-e.h/2,ht(t),void W();ve=!1;var t=e._def?0<e.inputs?1:0:"in"==e.direction?0:1,o=!1;M!==RED.state.JOINING&&M!==RED.state.QUICK_JOINING||(o=!0,0<B.length&&(B[0].virtualLink?"link in"===e.type?t=1:"link out"===e.type&&(t=0):t=1===B[0].portType?F:G)),st(e,t,0),o&&d3.selectAll(".red-ui-flow-port-hovered").classed("red-ui-flow-port-hovered",!1)}}function mt(e){if(RED.view.DEBUG&&console.warn("nodeMouseDown",M,e),Ft(),RED.contextMenu.hide(),1!==d3.event.button)if(M==RED.state.IMPORT_DRAGGING||M==RED.state.DETACHED_DRAGGING){var t=RED.history.peek();if(X&&(c=d3.select(X).data()[0],RED.nodes.removeLink(c),a={source:c.source,sourcePort:c.sourcePort,target:U.get(0).n},r={source:U.get(0).n,sourcePort:0,target:c.target},RED.nodes.addLink(a),RED.nodes.addLink(r),t.links=[a,r],t.removedLinks=[c],J()),D){for(var o=0;o<U.length();o++){var n=U.get(o);RED.group.addToGroup(D,n.n)}(t.addedToGroup=D).hovered=!1,b(D),g.selected=!0,D=null}if(M==RED.state.DETACHED_DRAGGING){for(var i=[],o=0;o<U.length();o++)(n=U.get(o)).ox===n.n.x&&n.oy===n.n.y||(i.push({n:n.n,ox:n.ox,oy:n.oy,moved:n.n.moved}),n.n.dirty=!0,n.n.moved=!0);RED.history.replace({t:"multi",events:[t,{t:"move",nodes:i}],dirty:t.dirty})}W(),RED.nodes.dirty(!0),H(),"cut"===we&&(we="copy"),K(),d3.event.stopPropagation()}else if(M==RED.state.QUICK_JOINING)d3.event.stopPropagation();else{if(M===RED.state.SELECTING_NODE)return d3.event.stopPropagation(),"junction"===e.type?void 0:u.single?void u.done(e):(e.selected?(e.selected=!1,U.remove(e)):u.filter&&!u.filter(e)||(e.selected=!0,U.add(e)),e.dirty=!0,void H());T=e;var a=Date.now();if(he=a-fe,fe=a,pe=ue==T&&(d3.event.touches||0===d3.event.button)&&!d3.event.shiftKey&&!d3.event.altKey&&he<p&&"junction"!==e.type,ue=T,!e.selected&&e.g){var s,r=RED.nodes.group(e.g);if(r!==g&&(d3.event.ctrlKey||d3.event.metaKey))ve=(g&&r.g===g.id||Ot(),!0),r.selected?It(r):v(r,!0);else if(r===g)if(d3.event.shiftKey){d3.event.ctrlKey||d3.event.metaKey||(l=g,q(),b(l),g.selected=!0);for(var d=RED.nodes.getAllFlowNodes(T),n=0;n<d.length;n++)d[n].selected||(d[n].selected=!0,d[n].dirty=!0,U.add(d[n]))}else d3.event.ctrlKey||d3.event.metaKey||(l=g,q(),It(r),v(r,!1,!1),l&&(b(l),g.selected=!0)),T.selected=!0,U.add(T);else{ve=!r.selected;var l=g;r.selected||q(),l?l!==r&&l.id!==r.g?(l.active=!1,l.dirty=!0):(g=l).active=!0:pe=!1,v(r,!(g&&g===r),!!ve),g&&g===r&&(T.selected=!0,U.add(T))}2!=d3.event.button&&((s=d3.touches(this)[0]||d3.mouse(this))[0]+=e.x-e.w/2,s[1]+=e.y-e.h/2,ht(s))}else if(e.selected&&(d3.event.ctrlKey||d3.event.metaKey))T.selected=!1,U.remove(T);else{if(d3.event.shiftKey){d3.event.ctrlKey||d3.event.metaKey||q();var c=d3.event.offsetX/R-T.x;d=(T.w||10)/2-Math.abs(c)<(30<T.w?25:0<T.w?8:3)?[T].concat(c<0?RED.nodes.getAllUpstreamNodes(T):RED.nodes.getAllDownstreamNodes(T)):RED.nodes.getAllFlowNodes(T);for(n=0;n<d.length;n++)d[n].selected=!0,d[n].dirty=!0,U.add(d[n])}else e.selected||((d3.event.ctrlKey||d3.event.metaKey?Ot:q)(),T.selected=!0,U.add(T));2!=d3.event.button&&(M=RED.state.MOVING,(s=d3.touches(this)[0]||d3.mouse(this))[0]+=e.x-e.w/2,s[1]+=e.y-e.h/2,ht(s))}e.dirty=!0,W(),H(),d3.event.stopPropagation()}}function vt(e){RED.view.DEBUG&&console.warn("nodeTouchStart",M,e);var t=d3.select(this),o=d3.event.touches.item(0),n=[o.pageX,o.pageY];f=[o.pageX,o.pageY],c=0,d=setTimeout(function(){Mt(t,n)},l),mt.call(this,e),d3.event.preventDefault()}function bt(e){RED.view.DEBUG&&console.warn("nodeTouchEnd",M,e),d3.event.preventDefault(),clearTimeout(d),d=null,RED.touch.radialMenu.active()?d3.event.stopPropagation():gt.call(this,e)}function yt(o){var n,e,t;RED.view.DEBUG&&console.warn("nodeMouseOver",M,o),0===M||M===RED.state.SELECTING_NODE?(M===RED.state.SELECTING_NODE&&u&&u.filter&&!u.filter(o)||this.parentNode.classList.add("red-ui-flow-node-hovered"),clearTimeout(rt),(o.hasOwnProperty("l")?o.l:"link in"!==o.type&&"link out"!==o.type)||(n=this.parentNode,rt=setTimeout(function(){if(n&&n.parentNode&&RED.nodes.node(n.id)){var t,e;if(o._def.label){t=o._def.label;try{t=("function"==typeof t?t.call(o):t)||""}catch(e){console.log("Definition error: "+o.type+".label",e),t=o.type}}""!==t&&(e=lt(n),rt=null,dt=ut(e[0]+o.w/2,e[1]-1,t,"top"))}},500))):M!==RED.state.JOINING&&M!==RED.state.QUICK_JOINING||0<B.length&&(t=B[0].virtualLink&&B[0].portType===G||B[0].portType===F?(e=".red-ui-flow-port-input .red-ui-flow-port",G):(e=".red-ui-flow-port-output .red-ui-flow-port",F),pt(d3.select(this.parentNode).selectAll(e),o,t,0))}function wt(e){var t;RED.view.DEBUG&&console.warn("nodeMouseOut",M,e),this.parentNode.classList.remove("red-ui-flow-node-hovered"),clearTimeout(rt),dt&&(dt.remove(),dt=null),M!==RED.state.JOINING&&M!==RED.state.QUICK_JOINING||0<B.length&&(B[0].virtualLink&&B[0].portType===G||B[0].portType===F?t=".red-ui-flow-port-input .red-ui-flow-port":t=".red-ui-flow-port-output .red-ui-flow-port",ft(d3.select(this.parentNode).selectAll(t)))}function Et(e){at(this.__data__,this.__portType__,this.__portIndex__,e)}function Dt(e){at(this.__data__,this.__portType__,this.__portIndex__,e),e.preventDefault()}function Rt(e){st(this.__data__,this.__portType__,this.__portIndex__,e)}function xt(e){st(this.__data__,this.__portType__,this.__portIndex__,e),e.preventDefault()}function _t(e){pt(d3.select(this),this.__data__,this.__portType__,this.__portIndex__)}function $t(e){ft(d3.select(this),this.__data__,this.__portType__,this.__portIndex__)}function kt(e){var t,o;t=d3.select(this),this.__data__,o=void 0===(o=this.__portType__)||M!==RED.state.JOINING&&M!==RED.state.QUICK_JOINING||0<B.length&&B[0].portType!==o&&!B[0].virtualLink,t.classed("red-ui-flow-junction-hovered",o)}function Tt(e){var t;t=d3.select(this),this.__data__,t.classed("red-ui-flow-junction-hovered",!1)}function Ct(e){var t;RED.view.DEBUG&&console.warn("linkMouseDown",{mouse_mode:M,point:d3.mouse(this),event:d3.event}),RED.contextMenu.hide(),M===RED.state.SELECTING_NODE?d3.event.stopPropagation():2!==d3.event.button&&(k=e,d3.event.metaKey||d3.event.ctrlKey||q(),(d3.event.metaKey||d3.event.ctrlKey)&&V.has(k)?1!==V.length()&&V.remove(k):V.add(k),W(),H(),Ft(),d3.event.stopPropagation(),k.link||0!==U.length()||!d3.event.touches&&0!==d3.event.button||1!==V.length()||!V.has(k)||!d3.event.metaKey&&!d3.event.ctrlKey||(d3.select(this).classed("red-ui-flow-link-splice",!0),t=Nt((e=d3.mouse(this))[0],e[1]),Ae({position:e,splice:k,group:t})))}function jt(e){var t,o;M===RED.state.SELECTING_NODE?d3.event.stopPropagation():(k=e,q(),V.clear(),V.add(k),W(),H(),Ft(),d3.event.stopPropagation(),t=d3.select(document.body),e=d3.event.touches.item(0),o=[e.pageX,e.pageY],d=setTimeout(function(){d=null,Mt(t,o)},l),d3.event.preventDefault())}function Lt(e){RED.view.DEBUG&&console.warn("groupMouseUp",{mouse_mode:M,event:d3.event}),pe&&se==e&&0<he&&he<p&&(M=RED.state.DEFAULT,RED.editor.editGroup(e),d3.event.stopPropagation())}function St(e){var t,o=d3.touches(this.parentNode)[0]||d3.mouse(this.parentNode);RED.view.DEBUG&&console.warn("groupMouseDown",{mouse_mode:M,point:o,event:d3.event}),RED.contextMenu.hide(),Ft(),1!==d3.event.button&&(M!=RED.state.QUICK_JOINING&&M!==RED.state.SELECTING_NODE&&(se=e,t=Date.now(),he=t-fe,fe=t,pe=ue==e&&(d3.event.touches||0===d3.event.button)&&!d3.event.shiftKey&&!d3.event.metaKey&&!d3.event.altKey&&!d3.event.ctrlKey&&he<p,(ue=e).selected&&(d3.event.ctrlKey||d3.event.metaKey)?(e===g&&Ot(),It(e),d3.event.stopPropagation()):(e.selected?g&&e.g!==g.id&&Ot():(d3.event.ctrlKey||d3.event.metaKey||(t=g,q(),t&&e.g===t.id&&(b(t),g.selected=!0)),g&&!RED.group.contains(g,e)&&Ot(),v(e,!0)),2!=d3.event.button&&(e.nodes[0],ht(o),se.dx=se.x-o[0],se.dy=se.y-o[1])),W(),H()),d3.event.stopPropagation())}function v(e,t,o){var n;e.selected||(e.selected=!0,e.dirty=!0),!1!==o&&U.add(e),t&&(n=new Set(U.nodes()),RED.group.getNodes(e,!0).forEach(function(e){n.has(e)||U.add(e),e.dirty=!0}))}function b(e){g&&Ot(),e.active=!0,e.dirty=!0,g=e,U.remove(e)}function Ot(){g&&(g.active=!1,g.dirty=!0,It(g),v(g,!0),g=null)}function It(e){e.selected&&(e.selected=!1,e.dirty=!0);var t=new Set(e.nodes);t.add(e);for(var o=U.length()-1;0<=o;--o){var n=U.get(o);!t.has(n.n)&&n.n!==e||(n.n.selected=!1,n.n.dirty=!0,U.remove(n.n,o))}}function Nt(e,t){for(var o={},n=0;n<_.length;n++){var i=_[n];e>=i.x&&e<=i.x+i.w&&t>=i.y&&t<=i.y+i.h&&(o[i.id]=i)}var a=Object.keys(o);return 1<a.length&&(a.forEach(function(e){o[e]&&o[e].g&&delete o[o[e].g]}),a=Object.keys(o)),0===a.length?null:o[a[a.length-1]]}function Pt(e){var t=!0,o=RED.nodes.workspace(RED.workspaces.active());return!o||o.disabled||e.d?t=!1:e._def.button.hasOwnProperty("enabled")&&(t="function"==typeof e._def.button.enabled?e._def.button.enabled.call(e):e._def.button.enabled),t}function At(t){if(M===RED.state.SELECTING_NODE)d3.event&&d3.event.stopPropagation();else{var e=RED.workspaces.active(),e=RED.nodes.workspace(e);if(!e||e.disabled||t.d)P?RED.notify(RED._("notification.warning",{message:RED._("notification.warnings.nodeActionDisabledSubflow")}),"warning"):RED.notify(RED._("notification.warning",{message:RED._("notification.warnings.nodeActionDisabled")}),"warning");else{if(t._def.button.toggle&&(t[t._def.button.toggle]=!t[t._def.button.toggle],t.dirty=!0),t._def.button.onclick)try{t._def.button.onclick.call(t)}catch(e){console.log("Definition error: "+t.type+".onclick",e)}t.dirty&&H()}d3.event&&d3.event.preventDefault()}}function Mt(e,t){var o=T,n=[];n.push({name:"delete",disabled:0===U.length()&&0===V.length(),onselect:function(){Ye()}}),n.push({name:"cut",disabled:0===U.length(),onselect:function(){Ze(!0),Ye()}}),n.push({name:"copy",disabled:0===U.length(),onselect:function(){Ze()}}),n.push({name:"paste",disabled:0===ye.length,onselect:function(){Ut(ye,{generateIds:!0,touchImport:!0})}}),n.push({name:"edit",disabled:1!=U.length(),onselect:function(){RED.editor.edit(o)}}),n.push({name:"select",onselect:function(){Ke()}}),n.push({name:"undo",disabled:0===RED.history.depth(),onselect:function(){RED.history.pop()}}),n.push({name:"add",onselect:function(){chartPos=z.offset(),Ae({position:[t[0]-chartPos.left+z.scrollLeft(),t[1]-chartPos.top+z.scrollTop()],touchTrigger:!0})}}),RED.touch.radialMenu.show(e,t,n),K()}function zt(o,e,t){var n,i,a,s=null;0===o.indexOf("font-awesome/")&&(n=o.substr(13),(s=RED.nodes.fontAwesome.getIconUnicode(n))||(n=RED.utils.getDefaultNodeIcon(t._def,t),o=RED.settings.apiRootUrl+"icons/"+n.module+"/"+n.file)),s?e.append("text").attr("xlink:href",o).attr("class","fa-lg").attr("x",15).text(s):(i=e.append("image").style("display","none").attr("xlink:href",o).attr("class","red-ui-flow-node-icon").attr("x",0).attr("width","30").attr("height","30"),(a=new Image).src=o,a.onload=function(){var e,t;o.match(/\.svg$/)||(e=Math.max(a.width,a.height),t=1,e=a.width*(t=30<e?30/e:t),t=a.height*t,i.attr("width",e),i.attr("height",t),i.attr("x",15-e/2)),i.attr("xlink:href",o),i.style("display",null)})}function Bt(e,t){var o;e.z===RED.workspaces.active()&&(t=t||document.getElementById(e.id))&&(s&&e.status&&!0!==e.d?(t.__statusGroup__.style.display="inline",o=Le[e.status.fill],null==e.status.shape&&null==o?(t.__statusShape__.style.display="none",t.__statusGroup__.setAttribute("transform","translate(-14,"+(e.h+3)+")")):(t.__statusGroup__.setAttribute("transform","translate(3,"+(e.h+3)+")"),o="red-ui-flow-node-status-"+(e.status.shape||"dot")+"-"+e.status.fill,t.__statusShape__.style.display="inline",t.__statusShape__.setAttribute("class","red-ui-flow-node-status "+o)),e.status.hasOwnProperty("text")?t.__statusLabel__.textContent=e.status.text:t.__statusLabel__.textContent=""):t.__statusGroup__.style.display="none",delete e.dirtyStatus)}function H(){RED.view.DEBUG_SYNC_REDRAW?Gt():(o&&cancelAnimationFrame(o),o=requestAnimationFrame(Gt))}function Gt(){var E,D,e,t,o,n,i;m.attr("transform","scale("+R+")"),Ee.attr("width",w*R).attr("height",Q*R),-1!==me||M!=RED.state.JOINING?(E={},P?((n=ke.selectAll(".red-ui-flow-subflow-port-output").data(P.out,function(e,t){return e.id})).exit().remove(),n.enter().insert("svg:g").attr("class","red-ui-flow-node red-ui-flow-subflow-port-output").each(function(e,t){var o=d3.select(this),n=document.createDocumentFragment(),i=(e.h=40,e.resize=!0,e.dirty=!0,document.createElementNS("http://www.w3.org/2000/svg","rect")),i=(i.__data__=e,i.setAttribute("class","red-ui-flow-subflow-port"),i.setAttribute("rx",8),i.setAttribute("ry",8),i.setAttribute("width",40),i.setAttribute("height",40),o[0][0].__mainRect__=i,d3.select(i).on("mouseup",gt).on("mousedown",mt).on("touchstart",vt).on("touchend",bt),n.appendChild(i),document.createElementNS("http://www.w3.org/2000/svg","g")),a=(i.setAttribute("x",0),i.setAttribute("y",0),o[0][0].__outputLabelGroup__=i,document.createElementNS("http://www.w3.org/2000/svg","text")),a=(a.setAttribute("class","red-ui-flow-port-label"),a.style["font-size"]="10px",a.textContent="output",i.appendChild(a),o[0][0].__outputOutput__=a,document.createElementNS("http://www.w3.org/2000/svg","text")),a=(a.setAttribute("class","red-ui-flow-port-label red-ui-flow-port-index"),a.setAttribute("x",0),a.setAttribute("y",0),a.textContent=e.i+1,i.appendChild(a),o[0][0].__outputNumber__=a,document.createElementNS("http://www.w3.org/2000/svg","path")),a=(a.setAttribute("d","M 40 1 l 0 38"),a.setAttribute("class","red-ui-flow-node-icon-shade-border"),i.appendChild(a),o[0][0].__outputBorder__=a,n.appendChild(i),document.createElementNS("http://www.w3.org/2000/svg","g")),i=(a.setAttribute("class","red-ui-flow-port-label"),a.setAttribute("transform","translate(38,0)"),a.setAttribute("style","fill : #888"),o[0][0].__textGroup__=a,n.append(a),document.createElementNS("http://www.w3.org/2000/svg","g")),a=(i.setAttribute("transform","translate(-5,15)"),document.createElementNS("http://www.w3.org/2000/svg","rect"));a.setAttribute("class","red-ui-flow-port"),a.setAttribute("rx",3),a.setAttribute("ry",3),a.setAttribute("width",10),a.setAttribute("height",10),i.appendChild(a),a.__data__=e,d3.select(a).on("mousedown",function(e,t){at(e,G,0)}).on("touchstart",function(e,t){at(e,G,0),d3.event.preventDefault()}).on("mouseup",function(e,t){st(e,G,0)}).on("touchend",function(e,t){st(e,G,0),d3.event.preventDefault()}).on("mouseover",function(e){pt(d3.select(this),e,G,0)}).on("mouseout",function(e){ft(d3.select(this))}),o[0][0].__port__=i,n.appendChild(i),o[0][0].appendChild(n)}),(e=ke.selectAll(".red-ui-flow-subflow-port-input").data(P.in,function(e,t){return e.id})).exit().remove(),(t=e.enter().insert("svg:g").attr("class","red-ui-flow-node red-ui-flow-subflow-port-input").attr("transform",function(e){return"translate("+(e.x-20)+","+(e.y-20)+")"})).each(function(e,t){e.w=40,e.h=40}),t.append("rect").attr("class","red-ui-flow-subflow-port").attr("rx",8).attr("ry",8).attr("width",40).attr("height",40).on("mouseup",gt).on("mousedown",mt).on("touchstart",vt).on("touchend",bt),t.append("g").attr("transform","translate(35,15)").append("rect").attr("class","red-ui-flow-port").attr("rx",3).attr("ry",3).attr("width",10).attr("height",10).on("mousedown",function(e,t){at(e,F,t)}).on("touchstart",function(e,t){at(e,F,t),d3.event.preventDefault()}).on("mouseup",function(e,t){st(e,F,t)}).on("touchend",function(e,t){st(e,F,t),d3.event.preventDefault()}).on("mouseover",function(e){pt(d3.select(this),e,F,0)}).on("mouseout",function(e){ft(d3.select(this))}),t.append("svg:text").attr("class","red-ui-flow-port-label").attr("x",18).attr("y",20).style("font-size","10px").text("input"),(t=ke.selectAll(".red-ui-flow-subflow-port-status").data(P.status?[P.status]:[],function(e,t){return e.id})).exit().remove(),(o=t.enter().insert("svg:g").attr("class","red-ui-flow-node red-ui-flow-subflow-port-status").attr("transform",function(e){return"translate("+(e.x-20)+","+(e.y-20)+")"})).each(function(e,t){e.w=40,e.h=40}),o.append("rect").attr("class","red-ui-flow-subflow-port").attr("rx",8).attr("ry",8).attr("width",40).attr("height",40).on("mouseup",gt).on("mousedown",mt).on("touchstart",vt).on("touchend",bt),o.append("g").attr("transform","translate(-5,15)").append("rect").attr("class","red-ui-flow-port").attr("rx",3).attr("ry",3).attr("width",10).attr("height",10).on("mousedown",function(e,t){at(e,G,0)}).on("touchstart",function(e,t){at(e,G,0),d3.event.preventDefault()}).on("mouseup",function(e,t){st(e,G,0)}).on("touchend",function(e,t){st(e,G,0),d3.event.preventDefault()}).on("mouseover",function(e){pt(d3.select(this),e,G,0)}).on("mouseout",function(e){ft(d3.select(this))}),o.append("svg:text").attr("class","red-ui-flow-port-label").attr("x",22).attr("y",20).style("font-size","10px").text("status"),n.each(function(e,t){if(e.dirty){d3.select(this);E[e.id]=e;var o,n=ct(P,F,e.i)||"",i=n.length<1;if(!e.resize&&this.__hideLabel__===i&&this.__label__===n||((o=Qe(n,"red-ui-flow-node-label")).lines.length===this.__labelLineCount__&&this.__label__===n||(e.resize=!0),this.__label__=n,this.__labelLineCount__=o.lines.length,e.h=i?Math.max(40,15*(e.outputs||0)):Math.max(6+24*o.lines.length,15*(e.outputs||0),40),this.__hideLabel__=i),e.resize&&(n=e.w,e.w=i?40:Math.max(40,20*Math.ceil((o.width+50+7)/20)),void 0!==n&&(e.x+=(e.w-n)/2),e.resize=!1),this.setAttribute("transform","translate("+(e.x-e.w/2)+","+(e.y-e.h/2)+")"),this.classList.toggle("red-ui-flow-node-selected",!!e.selected),M!=RED.state.MOVING_ACTIVE){if(this.classList.toggle("red-ui-flow-node-disabled",!0===e.d),this.__mainRect__.setAttribute("width",e.w),this.__mainRect__.setAttribute("height",e.h),this.__mainRect__.classList.toggle("red-ui-flow-node-highlighted",!!e.highlighted),o){for(var a=o.lines,s=o.lines.length,r=this.__textGroup__.childNodes;r.length>s;)r[r.length-1].remove();for(var d,t=0;t<s;t++)t===r.length&&((d=document.createElementNS("http://www.w3.org/2000/svg","text")).setAttribute("class","red-ui-flow-node-label-text"),d.setAttribute("x",0),d.setAttribute("y",24*t),this.__textGroup__.appendChild(d)),r[t].textContent=a[t]}this.__textGroup__.setAttribute("class","red-ui-flow-node-label"+(i?" hide":""));n=e.h/2-this.__labelLineCount__/2*24+13;this.__textGroup__.setAttribute("transform","translate(48,"+n+")"),this.__outputBorder__.setAttribute("d","M 40 1 l 0 "+(i?0:e.h-2)),this.__port__.setAttribute("transform","translate(-5,"+(e.h/2-5)+")"),this.__outputOutput__.setAttribute("transform","translate(20,"+(e.h/2-8)+")"),this.__outputNumber__.setAttribute("transform","translate(20,"+(e.h/2+7)+")")}e.dirty=!1}}),e.each(function(e,t){var o;e.dirty&&((o=d3.select(this)).classed("red-ui-flow-node-selected",function(e){return e.selected}),o.attr("transform",function(e){return"translate("+(e.x-e.w/2)+","+(e.y-e.h/2)+")"}),(E[e.id]=e).dirty=!1)}),t.each(function(e,t){var o;e.dirty&&((o=d3.select(this)).classed("red-ui-flow-node-selected",function(e){return e.selected}),o.selectAll(".red-ui-flow-port-index").text(function(e){return e.i+1}),o.attr("transform",function(e){return"translate("+(e.x-e.w/2)+","+(e.y-e.h/2)+")"}),(E[e.id]=e).dirty=!1)})):(ke.selectAll(".red-ui-flow-subflow-port-output").remove(),ke.selectAll(".red-ui-flow-subflow-port-input").remove(),ke.selectAll(".red-ui-flow-subflow-port-status").remove()),(o=ke.selectAll(".red-ui-flow-node-group").data(y,function(e){return e.id})).exit().each(function(e,t){RED.hooks.trigger("viewRemoveNode",{node:e,el:this})}).remove(),o.enter().insert("svg:g").attr("class","red-ui-flow-node red-ui-flow-node-group").classed("red-ui-flow-subflow",null!=P).each(function(e,t){this.__outputs__=[],this.__inputs__=[];var o=d3.select(this),n=document.createDocumentFragment(),i="link in"===e.type||"link out"===e.type,i=e.hasOwnProperty("l")?!e.l:i,a=(o.attr("id",e.id),e.h=N,e.resize=!0,e._def.button&&((s=document.createElementNS("http://www.w3.org/2000/svg","g")).__data__=e,s.setAttribute("transform","translate("+("right"==e._def.align?94:-25)+",2)"),s.setAttribute("class","red-ui-flow-node-button"),o[0][0].__buttonGroup__=s,(a=document.createElementNS("http://www.w3.org/2000/svg","rect")).__data__=e,a.setAttribute("class","red-ui-flow-node-button-background"),a.setAttribute("rx",5),a.setAttribute("ry",5),a.setAttribute("width",32),a.setAttribute("height",N-4),s.appendChild(a),o[0][0].__buttonGroupBackground__=a,(a=document.createElementNS("http://www.w3.org/2000/svg","rect")).__data__=e,a.setAttribute("class","red-ui-flow-node-button-button"),a.setAttribute("x","right"==e._def.align?11:5),a.setAttribute("y",4),a.setAttribute("rx",4),a.setAttribute("ry",4),a.setAttribute("width",16),a.setAttribute("height",N-12),a.setAttribute("fill",RED.utils.getNodeColor(e.type,e._def)),d3.select(a).on("mousedown",function(e){!L&&Pt(e)&&(Ft(),d3.select(this).attr("fill-opacity",.2),d3.event.preventDefault(),d3.event.stopPropagation())}).on("mouseup",function(e){!L&&Pt(e)&&(d3.select(this).attr("fill-opacity",.4),d3.event.preventDefault(),d3.event.stopPropagation())}).on("mouseover",function(e){!L&&Pt(e)&&d3.select(this).attr("fill-opacity",.4)}).on("mouseout",function(e){var t;!L&&Pt(e)&&(t=1,e._def.button.toggle&&(t=e[e._def.button.toggle]?1:.2),d3.select(this).attr("fill-opacity",t))}).on("click",At).on("touchstart",function(e){At.call(this,e),d3.event.preventDefault()}),s.appendChild(a),o[0][0].__buttonGroupButton__=a,n.appendChild(s)),document.createElementNS("http://www.w3.org/2000/svg","rect")),s=(a.__data__=e,a.setAttribute("class","red-ui-flow-node "+("unknown"==e.type?"red-ui-flow-node-unknown":"")),a.setAttribute("rx",5),a.setAttribute("ry",5),a.setAttribute("fill",RED.utils.getNodeColor(e.type,e._def)),o[0][0].__mainRect__=a,d3.select(a).on("mouseup",gt).on("mousedown",mt).on("touchstart",vt).on("touchend",bt).on("mouseover",yt).on("mouseout",wt),n.appendChild(a),e._def.icon&&(s=RED.utils.getNodeIcon(e._def,e),(a=document.createElementNS("http://www.w3.org/2000/svg","g")).__data__=e,a.setAttribute("class","red-ui-flow-node-icon-group"+("right"==e._def.align?" red-ui-flow-node-icon-group-right":"")),a.setAttribute("x",0),a.setAttribute("y",0),a.style["pointer-events"]="none",o[0][0].__iconGroup__=a,(r=document.createElementNS("http://www.w3.org/2000/svg","path")).setAttribute("x",0),r.setAttribute("y",0),r.setAttribute("class","red-ui-flow-node-icon-shade"),a.appendChild(r),o[0][0].__iconShade__=r,zt(s,d3.select(a),e),(r=document.createElementNS("http://www.w3.org/2000/svg","path")).setAttribute("d","right"!=e._def.align?"M 30 1 l 0 "+(e.h-2):"M 0 1 l 0 "+(e.h-2)),r.setAttribute("class","red-ui-flow-node-icon-shade-border"),a.appendChild(r),o[0][0].__iconShadeBorder__=r,n.appendChild(a)),document.createElementNS("http://www.w3.org/2000/svg","g")),r=(s.setAttribute("class","red-ui-flow-node-label"+(i?" hide":"")+(e._def.align?" red-ui-flow-node-label-"+e._def.align:"")),s.setAttribute("transform","translate(38,0)"),n.appendChild(s),o[0][0].__textGroup__=s,document.createElementNS("http://www.w3.org/2000/svg","g")),a=(r.setAttribute("class","red-ui-flow-node-status-group"),r.style.display="none",o[0][0].__statusGroup__=r,document.createElementNS("http://www.w3.org/2000/svg","rect")),i=(a.setAttribute("class","red-ui-flow-node-status"),a.setAttribute("x",6),a.setAttribute("y",1),a.setAttribute("width",9),a.setAttribute("height",9),a.setAttribute("rx",2),a.setAttribute("ry",2),a.setAttribute("stroke-width","3"),r.appendChild(a),o[0][0].__statusShape__=a,document.createElementNS("http://www.w3.org/2000/svg","text"));i.setAttribute("class","red-ui-flow-node-status-label"),i.setAttribute("x",20),i.setAttribute("y",10),r.appendChild(i),o[0][0].__statusLabel__=i,n.appendChild(r),o[0][0].appendChild(n),RED.hooks.trigger("viewAddNode",{node:e,el:this})}),D=!1,o.each(function(t,e){if(t._reordered&&(D=!0,delete t._reordered),t.dirty){var o=this,n=d3.select(this),i="link in"===t.type||"link out"===t.type,a=t.hasOwnProperty("l")?!t.l:i,s=(E[t.id]=t,RED.utils.getNodeLabel(t,t.type));if(!t.resize&&this.__hideLabel__===a&&this.__label__===s&&this.__outputs__.length===t.outputs||((u=Qe(s,"red-ui-flow-node-label")).lines.length===this.__labelLineCount__&&this.__label__===s||(t.resize=!0),this.__label__=s,this.__labelLineCount__=u.lines.length,t.h=a?Math.max(N,15*(t.outputs||0)):Math.max(6+24*u.lines.length,15*(t.outputs||0),30),this.__hideLabel__=a),t.resize&&(s=t.w,t.w=a?N:Math.max(I,20*Math.ceil((u.width+50+(0<t._def.inputs?7:0))/20)),void 0!==s&&(t.x+=(t.w-s)/2),t.resize=!1),t._colorChanged&&(s=RED.utils.getNodeColor(t.type,t._def),this.__mainRect__.setAttribute("fill",s),this.__buttonGroupButton__&&this.__buttonGroupButton__.settAttribute("fill",s),delete t._colorChanged),this.setAttribute("transform","translate("+(t.x-t.w/2)+","+(t.y-t.h/2)+")"),this.classList.toggle("red-ui-flow-node-selected",!!t.selected),M!=RED.state.MOVING_ACTIVE){if(this.classList.toggle("red-ui-flow-node-disabled",!0===t.d),this.__mainRect__.setAttribute("width",t.w),this.__mainRect__.setAttribute("height",t.h),this.__mainRect__.classList.toggle("red-ui-flow-node-highlighted",!!t.highlighted),u){for(var r=u.lines,d=u.lines.length,l=this.__textGroup__.childNodes;l.length>d;)l[l.length-1].remove();for(var c,e=0;e<d;e++)e===l.length&&((c=document.createElementNS("http://www.w3.org/2000/svg","text")).setAttribute("class","red-ui-flow-node-label-text"),c.setAttribute("x",0),c.setAttribute("y",24*e),this.__textGroup__.appendChild(c)),l[e].textContent=r[e]}s="";if(t._def.labelStyle){s=t._def.labelStyle;try{s=("function"==typeof s?s.call(t):s)||""}catch(e){console.log("Definition error: "+t.type+".labelStyle",e),s=""}s=" "+s}s="red-ui-flow-node-label"+(t._def.align?" red-ui-flow-node-label-"+t._def.align:"")+s+(a?" hide":""),this.__textGroup__.setAttribute("class",s);var u=t.h/2-this.__labelLineCount__/2*24+13,s=(!t._def.align&&0!==t.inputs&&0===t.outputs||"right"===t._def.align?(this.__iconGroup__&&(this.__iconGroup__.classList.add("red-ui-flow-node-icon-group-right"),this.__iconGroup__.setAttribute("transform","translate("+(t.w-30)+",0)")),this.__textGroup__.classList.add("red-ui-flow-node-label-right"),this.__textGroup__.setAttribute("transform","translate("+(t.w-38)+","+u+")")):(this.__iconGroup__&&(this.__iconGroup__.classList.remove("red-ui-flow-node-icon-group-right"),this.__iconGroup__.setAttribute("transform","")),this.__textGroup__.classList.remove("red-ui-flow-node-label-right"),this.__textGroup__.setAttribute("transform","translate(38,"+u+")")),n.selectAll(".red-ui-flow-port-input")),p=(i&&(-1!==me||x[t.id])||0!==t.inputs||s.empty()?(i&&(me===G||x[t.id])||1===t.inputs)&&s.empty()&&(u=n.append("g").attr("class","red-ui-flow-port-input"),h="link in"===t.type?u.append("circle").attr("cx",-1).attr("cy",5).attr("r",5).attr("class","red-ui-flow-port red-ui-flow-link-port"):u.append("rect").attr("class","red-ui-flow-port").attr("rx",3).attr("ry",3).attr("width",10).attr("height",10),u[0][0].__port__=h[0][0],h[0][0].__data__=this.__data__,h[0][0].__portType__=G,h[0][0].__portIndex__=0,h.on("mousedown",function(e){at(e,G,0)}).on("touchstart",function(e){at(e,G,0),d3.event.preventDefault()}).on("mouseup",function(e){st(e,G,0)}).on("touchend",function(e){st(e,G,0),d3.event.preventDefault()}).on("mouseover",function(e){pt(d3.select(this),e,G,0)}).on("mouseout",function(e){ft(d3.select(this))}),RED.hooks.trigger("viewAddPort",{node:t,el:this,port:u[0][0],portType:"input",portIndex:0})):s.each(function(e,t){RED.hooks.trigger("viewRemovePort",{node:e,el:o,port:d3.select(this)[0][0],portType:"input",portIndex:0})}).remove(),t.outputs);for(i&&"link out"===t.type&&(p="return"===t.mode||me!==F&&!x[t.id]?0:1),t.h;this.__outputs__.length>p;){var f=this.__outputs__.pop();RED.hooks.trigger("viewRemovePort",{node:t,el:this,port:f,portType:"output",portIndex:this.__outputs__.length}),f.remove()}for(var h,g=0;g<p;g++){g===this.__outputs__.length?((v=document.createElementNS("http://www.w3.org/2000/svg","g")).setAttribute("class","red-ui-flow-port-output"),"link out"===t.type?((m=document.createElementNS("http://www.w3.org/2000/svg","circle")).setAttribute("cx",11),m.setAttribute("cy",5),m.setAttribute("r",5),m.setAttribute("class","red-ui-flow-port red-ui-flow-link-port")):((m=document.createElementNS("http://www.w3.org/2000/svg","rect")).setAttribute("rx",3),m.setAttribute("ry",3),m.setAttribute("width",10),m.setAttribute("height",10),m.setAttribute("class","red-ui-flow-port")),v.appendChild(m),(v.__port__=m).__data__=this.__data__,m.__portType__=F,m.__portIndex__=g,m.addEventListener("mousedown",Et),m.addEventListener("touchstart",Dt),m.addEventListener("mouseup",Rt),m.addEventListener("touchend",xt),m.addEventListener("mouseover",_t),m.addEventListener("mouseout",$t),this.appendChild(v),this.__outputs__.push(v),RED.hooks.trigger("viewAddPort",{node:t,el:this,port:v,portType:"output",portIndex:g})):v=this.__outputs__[g];var m,v,b=t.w-5,y=t.h/2-(p-1)/2*13;v.setAttribute("transform","translate("+b+","+(y+13*g-5)+")")}t._def.icon&&(h=n.select(".red-ui-flow-node-icon"),u=n.select(".fa-lg"),s=(h.empty()?u:h).attr("xlink:href"),(i=RED.utils.getNodeIcon(t._def,t))!==s&&((h.empty()?u:h).remove(),zt(i,n.select(".red-ui-flow-node-icon-group"),t),h=n.select(".red-ui-flow-node-icon"),u=n.select(".fa-lg")),h.attr("y",function(){return(t.h-d3.select(this).attr("height"))/2}),s=t.h,this.__iconShade__.setAttribute("d",a?`M5 0 h20 a 5 5 0 0 1 5 5 v${s-10} a 5 5 0 0 1 -5 5 h-20 a 5 5 0 0 1 -5 -5 v-${s-10} a 5 5 0 0 1 5 -5`:"right"===t._def.align?`M 0 0 h25 a 5 5 0 0 1 5 5 v${s-10} a 5 5 0 0 1 -5 5 h-25 v-`+s:`M5 0 h25 v${s} h-25 a 5 5 0 0 1 -5 -5 v-${s-10} a 5 5 0 0 1 5 -5`),this.__iconShadeBorder__.style.display=a?"none":"",this.__iconShadeBorder__.setAttribute("d","M "+(!t._def.align&&0!==t.inputs&&0===t.outputs||"right"===t._def.align?.5:29.5)+" "+(t.selected?1:.5)+" l 0 "+(t.h-(t.selected?2:1))),u.attr("y",(t.h+13)/2)),n.selectAll(".red-ui-flow-port-input").each(function(e,t){d3.select(this).attr("transform",function(e){return"translate(-5,"+(e.h/2-5)+")"})}),t._def.button&&(i=Pt(t),this.__buttonGroup__.classList.toggle("red-ui-flow-node-button-disabled",!i),RED.runtime&&void 0!==RED.runtime.started&&this.__buttonGroup__.classList.toggle("red-ui-flow-node-button-stopped",!RED.runtime.started),b="right"==t._def.align?t.w-6:-25,t._def.button.toggle&&!t[t._def.button.toggle]&&(b-="right"==t._def.align?8:-8),this.__buttonGroup__.setAttribute("transform","translate("+b+",2)"),t._def.button.toggle&&(this.__buttonGroupButton__.setAttribute("fill-opacity",t[t._def.button.toggle]?1:.2),this.__buttonGroupBackground__.setAttribute("fill-opacity",t[t._def.button.toggle]?1:.2)),"function"==typeof t._def.button.visible&&(!1===t._def.button.visible.call(t)?this.__buttonGroup__.style.display="none":this.__buttonGroup__.style.display="inherit"))}if(t.dirtyStatus&&Bt(t,this),t.dirty=!1,t.g&&!ae[t.g])for(var w=t.g;w&&!ae[w];)ae[w]=RED.nodes.group(w),w=ae[w].g}RED.hooks.trigger("viewRedrawNode",{node:t,el:this})}),D&&o.sort(function(e,t){return e._index-t._index}),(n=xe.selectAll(".red-ui-flow-junction").data(ne,e=>e.id)).enter().insert("svg:g").attr("class","red-ui-flow-junction").each(function(e,t){var o=d3.select(this),n=document.createDocumentFragment(),i=document.createElementNS("http://www.w3.org/2000/svg","rect"),a=(i.setAttribute("class","red-ui-flow-junction-background"),i.setAttribute("x",-5),i.setAttribute("y",-5),i.setAttribute("width",10),i.setAttribute("height",10),i.setAttribute("rx",3),i.setAttribute("ry",3),i.__data__=e,this.__junctionBack__=i,n.appendChild(i),document.createElementNS("http://www.w3.org/2000/svg","rect")),s=(a.setAttribute("class","red-ui-flow-junction-port red-ui-flow-junction-port-input"),a.setAttribute("x",-5),a.setAttribute("y",-5),a.setAttribute("width",10),a.setAttribute("height",10),a.setAttribute("rx",3),a.setAttribute("ry",3),a.__data__=e,a.__portType__=G,a.__portIndex__=0,this.__junctionInput__=void 0,n.appendChild(a),a.addEventListener("mouseup",Rt),a.addEventListener("mousedown",Et),this.__junctionInput__=a,n.appendChild(a),document.createElementNS("http://www.w3.org/2000/svg","rect"));s.setAttribute("class","red-ui-flow-junction-port red-ui-flow-junction-port-output"),s.setAttribute("x",-5),s.setAttribute("y",-5),s.setAttribute("width",10),s.setAttribute("height",10),s.setAttribute("rx",3),s.setAttribute("ry",3),s.__data__=e,s.__portType__=F,s.__portIndex__=0,this.__junctionOutput__=s,n.appendChild(s),s.addEventListener("mouseup",Rt),s.addEventListener("mousedown",Et),s.addEventListener("mouseover",kt),s.addEventListener("mouseout",Tt),a.addEventListener("mouseover",kt),a.addEventListener("mouseout",Tt),i.addEventListener("mouseover",kt),i.addEventListener("mouseout",Tt),d3.select(i).on("mousedown",mt).on("mouseup",gt),o[0][0].appendChild(n)}),n.exit().remove(),n.each(function(e){var t=d3.select(this);if(this.setAttribute("transform","translate("+e.x+","+e.y+")"),e.dirty&&(t.classed("red-ui-flow-junction-dragging",M===RED.state.MOVING_ACTIVE&&U.has(e)),t.classed("selected",!!e.selected),(E[e.id]=e).g&&!ae[e.g]))for(var o=e.g;o&&!ae[o];)ae[o]=RED.nodes.group(o),o=ae[o].g}),(e=Re.selectAll(".red-ui-flow-link").data(oe,function(e){return e.source.id+":"+e.sourcePort+":"+e.target.id+":"+e.target.i})).enter().insert("g",".red-ui-flow-node").attr("class","red-ui-flow-link").each(function(e,t){var d=d3.select(this),o=document.createDocumentFragment(),n=(e.added=!0,document.createElementNS("http://www.w3.org/2000/svg","path")),n=(n.__data__=e,n.setAttribute("class","red-ui-flow-link-background red-ui-flow-link-path"+(e.link?" red-ui-flow-link-link":"")),this.__pathBack__=n,o.appendChild(n),d3.select(n).on("mousedown",Ct).on("touchstart",jt).on("mousemove",function(e){if(M===RED.state.SLICING)V.add(e),d.classed("red-ui-flow-link-splice",!0),H();else if(M===RED.state.SLICING_JUNCTION&&!e.link&&!d.classed("red-ui-flow-link-splice")){for(var t,o=l.getTotalLength(),n=1/0,i=0;i<o;i++){var a=l.getPointAtLength(i),s=Math.abs(a.x-d3.event.offsetX),r=Math.abs(a.y-d3.event.offsetY),s=s*s+r*r;s<n&&(t=a,n=s)}e._sliceLocation=t,V.add(e),d.classed("red-ui-flow-link-splice",!0),H()}}),document.createElementNS("http://www.w3.org/2000/svg","path")),l=(n.__data__=e,n.setAttribute("class","red-ui-flow-link-outline red-ui-flow-link-path"),this.__pathOutline__=n,o.appendChild(n),document.createElementNS("http://www.w3.org/2000/svg","path"));l.__data__=e,l.setAttribute("class","red-ui-flow-link-line red-ui-flow-link-path"+(e.link?" red-ui-flow-link-link":P?" red-ui-flow-subflow-link":"")),this.__pathLine__=l,o.appendChild(l),d[0][0].appendChild(o)}),e.exit().remove(),e.each(function(e){var t;d3.select(this),(e.added||e.selected||E[e.source.id]||E[e.target.id])&&(t=-((e.source.outputs||1)-1)/2*13+13*(e.sourcePort||0),e.x1=e.source.x+(e.source.w/2||0),e.y1=e.source.y+t,e.x2=e.target.x-(e.target.w/2||0),e.y2=e.target.y,t=Ne(e.x1,e.y1,e.x2,e.y2,1),/NaN/.test(t)&&(t=""),this.__pathBack__.setAttribute("d",t),this.__pathOutline__.setAttribute("d",t),this.__pathLine__.setAttribute("d",t),this.__pathLine__.classList.toggle("red-ui-flow-node-disabled",!(!e.source.d&&!e.target.d)),this.__pathLine__.classList.toggle("red-ui-flow-subflow-link",!e.link&&P)),this.classList.toggle("red-ui-flow-link-selected",!!e.selected),"unknown"!=e.target.type&&e.source.type;this.classList.toggle("red-ui-flow-link-unknown",!("unknown"!=e.target.type&&"unknown"!=e.source.type)),delete e.added}),(t=Re.selectAll(".red-ui-flow-link-off-flow").data(ie,function(e){return e.node.id+":"+e.refresh})).enter().insert("g",".red-ui-flow-node").attr("class","red-ui-flow-link-off-flow").each(function(o,e){var t=d3.select(this),n=1,i="start",a=("link in"===o.node.type&&(n=-1,i="end"),30*n),s=20*n,r=(t.append("svg:path").attr("class","red-ui-flow-link-link").attr("d","M 0 0 h "+a),o.links),r=Object.keys(r),d=RED.nodes.getWorkspaceOrder(),l=(r.sort(function(e,t){return d.indexOf(e)-d.indexOf(t)}),N),c=-(r.length-1)*l/2,t=t.selectAll(".red-ui-flow-link-group").data(r);t.enter().append("g").attr("class","red-ui-flow-link-group").on("mouseover",function(){0===M&&d3.select(this).classed("red-ui-flow-link-group-active",!0)}).on("mouseout",function(){0===M&&d3.select(this).classed("red-ui-flow-link-group-active",!1)}).on("mousedown",function(){d3.event.preventDefault(),d3.event.stopPropagation()}).on("mouseup",function(e){var t;0===M&&(d3.event.stopPropagation(),t=o.links[e],RED.workspaces.show(e),t.forEach(function(e){e.selected=!0,e.dirty=!0,U.add(e),1===t.length&&RED.view.reveal(e.id)}),W(),H())}).each(function(e){var t,o=d3.select(this),e=(o.append("svg:path").attr("class","red-ui-flow-link-link").attr("d","M "+a+" 0 C "+(a+1.7*s)+" 0 "+(a+.1*s)+" "+c+" "+(a+1.5*s)+" "+c+" "),o.append("svg:path").attr("class","red-ui-flow-link-port").attr("d","M "+(a+1.5*s+17*n)+" "+(c-12)+" h "+10*-n+" a 3 3 45 0 "+(1===n?"0":"1")+" "+-3*n+" 3 v 18 a 3 3 45 0 "+(1===n?"0":"1")+" "+3*n+" 3 h "+10*n),o.append("svg:path").attr("class","red-ui-flow-link-port").attr("d","M "+(a+1.5*s+20*n)+" "+(c-12)+" h "+30*n+" M "+(a+1.5*s+20*n)+" "+(c+12)+" h "+30*n).style("stroke-dasharray","12 3 8 4 3"),o.append("rect").attr("class","red-ui-flow-port red-ui-flow-link-port").attr("x",a+1.5*s-4+4*n).attr("y",c-4).attr("rx",2).attr("ry",2).attr("width",8).attr("height",8),o.append("rect").attr("x",a+1.5*s-(-1===n?I:0)).attr("y",c-12).attr("width",I).attr("height",24).style("stroke","none").style("fill","transparent"),RED.nodes.workspace(e));e&&(t=e.label||e.id),o.append("svg:text").attr("class","red-ui-flow-port-label").attr("x",a+1.5*s+15*n).attr("y",c+1).style("font-size","10px").style("text-anchor",i).text(t),c+=l}),t.exit().remove()}),t.exit().remove(),(t=Re.selectAll(".red-ui-flow-link-off-flow")).each(function(e){var t=1;"link in"===e.node.type&&(t=-1),d3.select(this).attr("transform",function(e){return"translate("+(e.node.x+t*e.node.w/2)+","+e.node.y+")"})}),(o=Te.selectAll(".red-ui-flow-group").data(_,function(e){return e.id})).exit().each(function(e,t){document.getElementById("group_select_"+e.id).remove()}).remove(),n=o.enter().insert("svg:g").attr("class","red-ui-flow-group"),i=!1,n.each(function(e,t){i=!0;var o=d3.select(this),n=(o.attr("id",e.id),$e.append("g").attr("class","red-ui-flow-group").attr("id","group_select_"+e.id));n.append("rect").classed("red-ui-flow-group-outline-select",!0).classed("red-ui-flow-group-outline-select-background",!0).attr("rx",4).attr("ry",4).attr("x",-4).attr("y",-4),n.append("rect").classed("red-ui-flow-group-outline-select",!0).attr("rx",4).attr("ry",4).attr("x",-4).attr("y",-4),n.on("mousedown",function(){St.call(o[0][0],e)}),n.on("mouseup",function(){Lt.call(o[0][0],e)}),n.on("touchstart",function(){St.call(o[0][0],e),d3.event.preventDefault()}),n.on("touchend",function(){Lt.call(o[0][0],e),d3.event.preventDefault()}),o.append("rect").classed("red-ui-flow-group-outline",!0).attr("rx",.5).attr("ry",.5),o.append("rect").classed("red-ui-flow-group-body",!0).attr("rx",4).attr("ry",4).style({fill:e.fill||"none",stroke:e.stroke||"none"}),o.on("mousedown",St).on("mouseup",Lt),o.on("touchstart",function(){St.call(o[0][0],e),d3.event.preventDefault()}),o.on("touchend",function(){Lt.call(o[0][0],e),d3.event.preventDefault()}),o.append("svg:text").attr("class","red-ui-flow-group-label"),e.dirty=!0}),i&&o.sort(function(e,t){return e._root===t._root?e._depth-t._depth:e._index-t._index}),o[0].reverse(),o.each(function(e,t){var o,n,i,a,s,r,d,l,c,u;e.resize&&(e.minWidth=0,delete e.resize),(e.dirty||ae[e.id])&&(o=d3.select(this),u=!1,0<e.nodes.length?e.groupMoved?delete e.groupMoved:(n=Number.POSITIVE_INFINITY,i=Number.POSITIVE_INFINITY,s=a=0,e.nodes.forEach(function(e){s="group"!==e.type?(n=Math.min(n,e.x-e.w/2-26-(e._def.button&&"right"!==e._def.align?20:0)),i=Math.min(i,e.y-e.h/2-26),a=Math.max(a,e.x+e.w/2+26+(e._def.button&&"right"==e._def.align?20:0)),Math.max(s,e.y+e.h/2+26)):(n=Math.min(n,e.x-26),i=Math.min(i,e.y-26),a=Math.max(a,e.x+e.w+26),Math.max(s,e.y+e.h+26))}),e.x=n,e.y=i,e.w=a-n,e.h=s-i,!(u=!0)===e.groupMoved&&delete e.groupMoved):(e.w=40,e.h=40,u=!0),u&&(e.minWidth||(e.style.label&&e.name?(u=Qe(e.name||"","red-ui-flow-group-label"),e.minWidth=u.width+8,e.labels=u.lines):(e.minWidth=40,e.labels=[])),e.w=Math.max(e.minWidth,e.w),e.style.label&&0<e.labels.length&&(d=e.style["label-position"]||"nw",u=16*(e.labels.length-1),"s"===d[0]&&(u+=8),e.h+=u,"n"===d[0]&&0<e.nodes.length&&(e.y-=u))),o.attr("transform","translate("+e.x+","+e.y+")"),o.selectAll(".red-ui-flow-group-outline").attr("width",e.w).attr("height",e.h),(u=document.getElementById("group_select_"+e.id)).setAttribute("transform","translate("+e.x+","+e.y+")"),e.hovered?u.classList.add("red-ui-flow-group-hovered"):u.classList.remove("red-ui-flow-group-hovered"),(l=u.children[0]).setAttribute("width",e.w+8),l.setAttribute("height",e.h+8),l.style.strokeOpacity=e.active||e.selected||e.highlighted?.8:0,l.style.strokeDasharray=e.active?"10 4":"",(l=u.children[1]).setAttribute("width",e.w+8),l.setAttribute("height",e.h+8),l.style.strokeOpacity=e.active||e.selected||e.highlighted?.8:0,l.style.strokeDasharray=e.active?"10 4":"",e.highlighted?u.classList.add("red-ui-flow-node-highlighted"):u.classList.remove("red-ui-flow-node-highlighted"),o.selectAll(".red-ui-flow-group-body").attr("width",e.w).attr("height",e.h).style("stroke",e.style.stroke||"").style("stroke-opacity",e.style.hasOwnProperty("stroke-opacity")?e.style["stroke-opacity"]:"").style("fill",e.style.fill||"").style("fill-opacity",e.style.hasOwnProperty("fill-opacity")?e.style["fill-opacity"]:""),(r=o.selectAll(".red-ui-flow-group-label")).classed("hide",!e.style.label),e.style.label&&(u="n"===(d=e.style["label-position"]||"nw")[u=l=0]?15:e.h-5-16*(e.labels.length-1),labelAnchor="w"===d[1]?(l=5,"start"):"e"===d[1]?(l=e.w-5,"end"):(l=e.w/2,"middle"),e.style.hasOwnProperty("color")?r.style("fill",e.style.color):r.style("fill",null),r.attr("transform","translate("+l+","+u+")").attr("text-anchor",labelAnchor),e.labels?(c=0,o.selectAll(".red-ui-flow-group-label-text").remove(),e.labels.forEach(function(e){r.append("tspan").classed("red-ui-flow-group-label-text",!0).text(e).attr("x",0).attr("y",c),c+=16})):o.selectAll(".red-ui-flow-group-label-text").remove()),delete ae[e.id],delete e.dirty)})):Re.selectAll(".red-ui-flow-link-selected").data(oe,function(e){return e.source.id+":"+e.sourcePort+":"+e.target.id+":"+e.target.i}).classed("red-ui-flow-link-selected",!1),RED.view.navigator.refresh(),d3.event&&d3.event.preventDefault()}function Ft(){try{var e=window.parent.window.scrollX,t=window.parent.window.scrollY;z.trigger("focus"),window.parent.window.scrollTo(e,t)}catch(e){z.trigger("focus")}}function Ut(e,t){var o,n=(t=t||{addFlow:!1,touchImport:!1,generateIds:!1,generateDefaultNames:!1}).addFlow,i=t.touchImport;if(M!==RED.state.SELECTING_NODE){if("string"==typeof e){if(""===e)return;try{o=JSON.parse(e)}catch(e){var a=new Error(RED._("clipboard.invalidFlow",{message:e.message}));throw a.code="NODE_RED",a}}else o=e;$.isArray(o)||(o=[o]),t.generateDefaultNames&&RED.actions.invoke("core:generate-node-names",o,{renameBlank:!1,renameClash:!0,generateHistory:!1});try{P&&(s=P.changed);var s,r=RED.nodes.import(o,{generateIds:t.generateIds,addFlow:n,importMap:t.importMap});if(r){var d=r.nodes,l=r.links,c=r.groups,u=r.junctions,p=r.workspaces,f=r.subflows,h=r.removedNodes,g=r.missingWorkspace,m=(n&&g&&RED.workspaces.show(g.id),d.filter(function(e){return e.hasOwnProperty("x")&&e.hasOwnProperty("y")&&e.z==RED.workspaces.active()})),v=(m=(m=m.concat(c.filter(function(e){return e.z===RED.workspaces.active()}))).concat(u.filter(function(e){return e.z===RED.workspaces.active()})),d.map(function(e){return e.changed=!0,e.id}));if(q(),U.clear(),U.add(m),0<U.length()){for(var b,y,w=(A=null==A?[0,0]:A)[0],E=A[1],D=(0<U.length()&&(w=(b=U.get(0).n).x,E=b.y),0),R=0,x=U.length(),_=0;_<x;_++)(y=U.get(_)).n.selected=!0,y.n.changed=!0,y.n.moved=!0,y.n.x-=w-A[0],y.n.y-=E-A[1],"junction"!==y.n.type&&(y.n.w=I,y.n.h=N,y.n.resize=!0),y.dx=y.n.x-A[0],y.dy=y.n.y-A[1],R="group"===y.n.type?(y.n.groupMoved=!1,D=Math.min(y.n.x-5,D),Math.min(y.n.y-5,R)):(D=Math.min(y.n.x-I/2-5,D),Math.min(y.n.y-N/2-5,R));for(_=0;_<x;_++)if((y=U.get(_)).n.x-=D,y.n.y-=R,y.dx-=D,y.dy-=R,y.n._def.onadd)try{y.n._def.onadd.call(y.n)}catch(e){console.log("Definition error: "+y.n.type+".onadd:",e)}i||(M=RED.state.IMPORT_DRAGGING,te=!1,1===U.length()&&(y=U.get(0),te=y.n.hasOwnProperty("_def")&&(y.n.hasOwnProperty("inputs")&&0<y.n.inputs||!y.n.hasOwnProperty("inputs")&&0<y.n._def.inputs)&&(y.n.hasOwnProperty("outputs")&&0<y.n.outputs||!y.n.hasOwnProperty("outputs")&&0<y.n._def.outputs)))}var k,T,C={t:"add",nodes:v,links:l,groups:c,junctions:u,workspaces:p,subflows:f,dirty:RED.nodes.dirty()},j=(0===U.length()&&RED.nodes.dirty(!0),!P||(k=RED.subflow.refresh(!0))&&(C.subflow={id:P.id,changed:s,instances:k.instances}),h&&(C={t:"multi",events:[{t:"replace",config:h},C]}),RED.history.push(C),J(),H(),[]),L=0,S=0,O=(d.forEach(function(e){e.hasOwnProperty("x")&&e.hasOwnProperty("y")?L++:S++}),c.length);u.length;0<p.length&&j.push(RED._("clipboard.flow",{count:p.length})),0<L&&j.push(RED._("clipboard.node",{count:L})),0<O&&j.push(RED._("clipboard.group",{count:O})),0<S&&j.push(RED._("clipboard.configNode",{count:S})),0<f.length&&j.push(RED._("clipboard.subflow",{count:f.length})),h&&0<h.length&&j.push(RED._("clipboard.replacedNodes",{count:h.length})),0<j.length&&(T="<ul><li>"+j.join("</li><li>")+"</li></ul>",RED.notify("<p>"+RED._("clipboard.nodesImported")+"</p>"+T,{id:"clipboard"}))}}catch(e){if("import_conflict"===e.code)throw e;"NODE_RED"!=e.code?(console.log(e.stack),RED.notify(RED._("notification.error",{message:e.toString()}),"error")):RED.notify(RED._("notification.error",{message:e.message}),"error")}}}function Vt(e){if(M!==RED.state.SELECTING_NODE){var t=RED.workspaces.selection();if(!(0<t.length)&&0<U.length()){for(var o=[],n=0;n<U.length();n++){var i=U.get(n).n;"group"!==i.type&&"subflow"!==i.type&&e!=i.d&&(o.push({t:"edit",node:i,changed:i.changed,changes:{d:i.d}}),e?i.d=!0:delete i.d,i.dirty=!0,i.dirtyStatus=!0,i.changed=!0,"junction"===i.type?RED.events.emit("junctions:change",i):RED.events.emit("nodes:change",i))}0<o.length&&(RED.history.push({t:"multi",events:o,dirty:RED.nodes.dirty()}),RED.nodes.dirty(!0))}RED.view.redraw()}}function Jt(){var e={},t=new Set,o=(0<U.length()&&U.forEach(function(e){"group"!==e.n.type&&t.add(e.n)}),_.filter(function(e){return e.selected&&!e.active}));return 0<o.length&&(1===o.length&&o[0].active||o.forEach(function(e){RED.group.getNodes(e,!0).forEach(function(e){t.delete(e)}),t.add(e)})),0<t.size&&(e.nodes=Array.from(t)),0<V.length()&&(e.links=V.toArray(),e.link=e.links[0]),e}function qt(e,t,o,n){var i=RED.nodes.dirty(),a=/^subflow:(.+)$/.exec(e),s=n?RED.nodes.subflow(n):null;if(s&&a){if(a[1]===s.id)throw new Error(RED._("notification.error",{message:RED._("notification.errors.cannotAddSubflowToItself")}));if(RED.nodes.subflowContains(a[1],s.id))throw new Error(RED._("notification.error",{message:RED._("notification.errors.cannotAddCircularReference")}))}var r={id:RED.nodes.id(),z:n||RED.workspaces.active()};if(r.type=e,r._def=RED.nodes.getType(r.type),a){n=RED.nodes.subflow(a[1]);r.name="",r.inputs=n.in.length,r.outputs=n.out.length}else{for(var d in r.inputs=r._def.inputs||0,r.outputs=r._def.outputs,r._def.defaults)r._def.defaults.hasOwnProperty(d)&&void 0!==r._def.defaults[d].value&&(r[d]=JSON.parse(JSON.stringify(r._def.defaults[d].value)));if(r._def.onadd)try{r._def.onadd.call(r)}catch(e){console.log("Definition error: "+r.type+".onadd:",e)}}r.changed=!0,r.moved=!0,r.w=RED.view.node_width,r.h=Math.max(RED.view.node_height,15*(r.outputs||0)),r.resize=!0,null!=t&&"number"==typeof t&&0<=t&&(r.x=t),null!=o&&"number"==typeof o&&0<=o&&(r.y=o);e={t:"add",nodes:[r.id],dirty:i};return s&&(a=RED.subflow.refresh(!0))&&(e.subflow={id:s.id,changed:s.changed,instances:a.instances}),{node:r,historyEvent:e}}return{init:function(){(z=$("#red-ui-workspace-chart")).on("contextmenu",function(e){return e.preventDefault(),e.stopPropagation(),RED.contextMenu.show({x:e.clientX-5,y:e.clientY-5}),!1}),Ee=d3.select("#red-ui-workspace-chart").append("svg:svg").attr("width",w).attr("height",Q).attr("pointer-events","all").style("cursor","crosshair").style("touch-action","none").on("mousedown",function(){Ft()}).on("contextmenu",function(){d3.event.preventDefault()}),(m=Ee.append("svg:g").on("dblclick.zoom",null).append("svg:g").attr("class","red-ui-workspace-chart-event-layer").on("mousemove",Me).on("mousedown",Pe).on("mouseup",Be).on("mouseenter",function(){d3.select(document).on("mouseup.red-ui-workspace-tracker",null),L?1!==d3.event.buttons&&(L.remove(),L=null):M===RED.state.PANNING&&4!==d3.event.buttons?K():S&&2!==d3.event.buttons&&(S.remove(),S=null,K())}).on("mouseleave",ze).on("touchend",function(){d3.event.preventDefault(),clearTimeout(d),d=null,RED.touch.radialMenu.active()||Be.call(this)}).on("touchcancel",function(){RED.view.DEBUG&&console.warn("eventLayer.touchcancel",M),d3.event.preventDefault(),Be.call(this)}).on("touchstart",function(){var e,t,o,n,i,a,s,r;RED.view.DEBUG&&console.warn("eventLayer.touchstart",M),1<d3.event.touches.length?(clearTimeout(d),d=null,d3.event.preventDefault(),e=d3.event.touches.item(0),t=d3.event.touches.item(1),o=e.pageY-t.pageY,n=e.pageX-t.pageX,i=z.offset(),a=[z.scrollLeft(),z.scrollTop()],f=[(t.pageX+n/2-i.left+a[0])/R,(t.pageY+o/2-i.top+a[1])/R],t.pageX,t.pageY,c=Math.sqrt(o*o+n*n)):(s=d3.select(document.body),r=[(e=d3.event.touches.item(0)).pageX,e.pageY],f=[e.pageX,e.pageY],c=0,d3.touches(this)[0],d=setTimeout(function(){d=null,Mt(s,r)},l)),d3.event.preventDefault()}).on("touchmove",function(){var e,t,o,n,i;RED.touch.radialMenu.active()||(RED.view.DEBUG&&console.warn("eventLayer.touchmove",M,T),d3.event.touches.length<2?(d?(i=(n=d3.event.touches.item(0)).pageX-f[0],e=n.pageY-f[1],64<Math.abs(i*i+e*e)&&(clearTimeout(d),d=null,T||se||(M=RED.state.PANNING,A=[n.pageX,n.pageY],ge=[z.scrollLeft(),z.scrollTop()]))):L&&d3.event.preventDefault(),Me.call(this)):(n=d3.event.touches.item(0),i=d3.event.touches.item(1),e=n.pageY-i.pageY,n=n.pageX-i.pageX,z.offset(),t=[z.scrollLeft(),z.scrollTop()],o=Math.sqrt(e*e+n*n),n=[i.pageX+n/2,i.pageY+e/2],isNaN(o)||(oldScaleFactor=R,R=Math.min(2,Math.max(.3,R+Math.floor(100*o-100*c)/1e4)),i=[f[0]*(R-oldScaleFactor),f[1]*(R-oldScaleFactor)],c=o,z.scrollLeft(t[0]+i[0]),z.scrollTop(t[1]+i[1]),H()))),d3.event.preventDefault()})).append("svg:rect").attr("class","red-ui-workspace-chart-background").attr("width",w).attr("height",Q),De=m.append("g").attr("class","red-ui-workspace-chart-grid"),Se(),Te=m.append("g"),$e=m.append("g"),Re=m.append("g"),_e=m.append("g"),xe=m.append("g"),ke=m.append("g"),B=[],RED.events.on("workspace:change",function(e){(M=0)!==e.old&&(n[e.old]={left:z.scrollLeft(),top:z.scrollTop()});var t=z.scrollLeft(),o=z.scrollTop(),e=(P=RED.nodes.subflow(e.workspace),RED.menu.setDisabled("menu-item-workspace-edit",P||0===e.workspace),RED.menu.setDisabled("menu-item-workspace-delete",0===e.workspace||1==RED.workspaces.count()||P),n[e.workspace]?(z.scrollLeft(n[e.workspace].left),z.scrollTop(n[e.workspace].top)):(z.scrollLeft(0),z.scrollTop(0)),z.scrollLeft()-t),t=z.scrollTop()-o;null!=A&&(A[0]+=e,A[1]+=t),0===RED.workspaces.selection().length&&q(),RED.nodes.eachNode(function(e){e.dirty=!0,e.dirtyStatus=!0}),W(),J(),H()}),RED.statusBar.add({id:"view-zoom-controls",align:"right",element:$('<span class="button-group"><button class="red-ui-footer-button" id="red-ui-view-zoom-out"><i class="fa fa-minus"></i></button><button class="red-ui-footer-button" id="red-ui-view-zoom-zero"><i class="fa fa-circle-o"></i></button><button class="red-ui-footer-button" id="red-ui-view-zoom-in"><i class="fa fa-plus"></i></button></span>')}),$("#red-ui-view-zoom-out").on("click",Fe),RED.popover.tooltip($("#red-ui-view-zoom-out"),RED._("actions.zoom-out"),"core:zoom-out"),$("#red-ui-view-zoom-zero").on("click",Ue),RED.popover.tooltip($("#red-ui-view-zoom-zero"),RED._("actions.zoom-reset"),"core:zoom-reset"),$("#red-ui-view-zoom-in").on("click",Ge),RED.popover.tooltip($("#red-ui-view-zoom-in"),RED._("actions.zoom-in"),"core:zoom-in"),z.on("DOMMouseScroll mousewheel",function(e){e.altKey&&(e.preventDefault(),e.stopPropagation(),((-e.originalEvent.detail||e.originalEvent.wheelDelta)<=0?Fe:Ge)())}),RED.statusBar.add({id:"view-search-tools",align:"left",hidden:!1,element:$('<span class="button-group"><button class="red-ui-footer-button" id="red-ui-view-searchtools-search"><i class="fa fa-search"></i></button></span><span class="button-group search-counter"><span class="red-ui-footer-button" id="red-ui-view-searchtools-counter">? of ?</span></span><span class="button-group"><button class="red-ui-footer-button" id="red-ui-view-searchtools-prev"><i class="fa fa-chevron-left"></i></button><button class="red-ui-footer-button" id="red-ui-view-searchtools-next"><i class="fa fa-chevron-right"></i></button></span><span class="button-group"><button class="red-ui-footer-button" id="red-ui-view-searchtools-close"><i class="fa fa-close"></i></button></span>')}),$("#red-ui-view-searchtools-search").on("click",Ve),RED.popover.tooltip($("#red-ui-view-searchtools-search"),RED._("actions.search-flows"),"core:search"),$("#red-ui-view-searchtools-prev").on("click",Je),RED.popover.tooltip($("#red-ui-view-searchtools-prev"),RED._("actions.search-prev"),"core:search-previous"),$("#red-ui-view-searchtools-next").on("click",qe),RED.popover.tooltip($("#red-ui-view-searchtools-next"),RED._("actions.search-next"),"core:search-next"),RED.popover.tooltip($("#red-ui-view-searchtools-close"),RED._("common.label.close")),z.droppable({accept:".red-ui-palette-node",drop:function(e,t){d3.event=e;e=qt($(t.draggable[0]).attr("data-palette-type"));if(e){var o=e.historyEvent,e=e.node,n=(RED.nodes.add(e),RED.utils.getMessageProperty(RED.settings.get("editor"),"view.view-node-show-label")),n=(void 0===n||e._def.hasOwnProperty("showLabel")&&!e._def.showLabel||e._def.defaults.hasOwnProperty("l")||(e.l=n),d3.touches(t.helper.get(0))[0]||d3.mouse(t.helper.get(0))),i=t.helper.width(),a=t.helper.height(),s=d3.touches(this)[0]||d3.mouse(this);try{var r="link in"===e.type||"link out"===e.type,d=e.hasOwnProperty("l")?!e.l:r,l=Qe(RED.utils.getNodeLabel(e,e.type),"red-ui-flow-node-label");d?(e.w=N,e.h=Math.max(N,15*(e.outputs||0))):(e.w=Math.max(I,20*Math.ceil((l.width+50+(0<e._def.inputs?7:0))/20)),e.h=Math.max(6+24*l.lines.length,15*(e.outputs||0),30))}catch(e){}s[1]+=this.scrollTop+(a/2-n[1]),s[0]+=this.scrollLeft+(i/2-n[0]),s[1]/=R,s[0]/=R,e.x=s[0],e.y=s[1];var r=e.w/2-5,d=(e.x<r&&(e.x=r),e.h/2-5),l=(e.y<d&&(e.y=d),w-e.w/2+5),a=(e.x>l&&(e.x=l),Q-e.h+5),n=(e.y>a&&(e.y=a),ee&&(i=RED.view.tools.calculateGridSnapOffsets(e),e.x-=i.x,e.y-=i.y),$(t.helper).data("splice")),d=(n&&(RED.nodes.removeLink(n),s={source:n.source,sourcePort:n.sourcePort,target:e},r={source:e,sourcePort:0,target:n.target},RED.nodes.addLink(s),RED.nodes.addLink(r),o.links=[s,r],o.removedLinks=[n]),$(t.helper).data("group"));d&&(RED.group.addToGroup(d,e),(o={t:"multi",events:[o]}).events.push({t:"addToGroup",group:d,nodes:e})),RED.history.push(o),RED.editor.validateNode(e),RED.nodes.dirty(!0),Ot(),q(),e.selected=!0,U.add(e),d&&(v(d,!1),b(d),g=d),J(),W(),H(),e._def.autoedit&&RED.editor.edit(e)}}}),z.on("focus",function(){$("#red-ui-workspace-tabs").addClass("red-ui-workspace-focussed")}),z.on("blur",function(){$("#red-ui-workspace-tabs").removeClass("red-ui-workspace-focussed")}),RED.actions.add("core:copy-selection-to-internal-clipboard",Ze),RED.actions.add("core:cut-selection-to-internal-clipboard",function(){Ze(!0),Ye()}),RED.actions.add("core:paste-from-internal-clipboard",function(){Ut(ye,{generateIds:"copy"===we,generateDefaultNames:"copy"===we})}),RED.actions.add("core:detach-selected-nodes",function(){var e,t,o=RED.view.selection();o.nodes&&({newLinks:e,removedLinks:t}=RED.nodes.detachNodes(o.nodes),(t.length||e.length)&&(RED.history.push({t:"multi",events:[{t:"delete",links:t},{t:"add",links:e}],dirty:RED.nodes.dirty()}),RED.nodes.dirty(!0)),ht([o.nodes[0].x,o.nodes[0].y]),M=RED.state.DETACHED_DRAGGING,RED.view.redraw(!0))}),RED.events.on("view:selection-changed",function(e){var t=e.nodes&&0<e.nodes.length,e=t&&1<e.nodes.length;RED.menu.setDisabled("menu-item-edit-cut",!t),RED.menu.setDisabled("menu-item-edit-copy",!t),RED.menu.setDisabled("menu-item-edit-select-connected",!t),RED.menu.setDisabled("menu-item-view-tools-move-to-back",!t),RED.menu.setDisabled("menu-item-view-tools-move-to-front",!t),RED.menu.setDisabled("menu-item-view-tools-move-backwards",!t),RED.menu.setDisabled("menu-item-view-tools-move-forwards",!t),RED.menu.setDisabled("menu-item-view-tools-align-left",!e),RED.menu.setDisabled("menu-item-view-tools-align-center",!e),RED.menu.setDisabled("menu-item-view-tools-align-right",!e),RED.menu.setDisabled("menu-item-view-tools-align-top",!e),RED.menu.setDisabled("menu-item-view-tools-align-middle",!e),RED.menu.setDisabled("menu-item-view-tools-align-bottom",!e),RED.menu.setDisabled("menu-item-view-tools-distribute-horizontally",!e),RED.menu.setDisabled("menu-item-view-tools-distribute-veritcally",!e)}),RED.actions.add("core:delete-selection",Ye),RED.actions.add("core:delete-selection-and-reconnect",function(){Ye(!0)}),RED.actions.add("core:edit-selected-node",Xe),RED.actions.add("core:go-to-selection",function(){var e;0<U.length()&&(e=U.get(0).n,/^subflow:/.test(e.type)?RED.workspaces.show(e.type.substring(8)):"group"===e.type&&(b(e),H()))}),RED.actions.add("core:undo",RED.history.pop),RED.actions.add("core:redo",RED.history.redo),RED.actions.add("core:select-all-nodes",Ke),RED.actions.add("core:select-none",We),RED.actions.add("core:zoom-in",Ge),RED.actions.add("core:zoom-out",Fe),RED.actions.add("core:zoom-reset",Ue),RED.actions.add("core:enable-selected-nodes",function(){Vt(!1)}),RED.actions.add("core:disable-selected-nodes",function(){Vt(!0)}),RED.actions.add("core:toggle-show-grid",function(e){void 0===e?RED.userSettings.toggle("view-show-grid"):e?De.style("visibility","visible"):De.style("visibility","hidden")}),RED.actions.add("core:toggle-snap-grid",function(e){void 0===e?RED.userSettings.toggle("view-snap-grid"):(ee=e,H())}),RED.actions.add("core:toggle-status",function(e){void 0===e?RED.userSettings.toggle("view-node-status"):(s=e,RED.nodes.eachNode(function(e){e.dirtyStatus=!0,e.dirty=!0}),H())}),RED.view.annotations.init(),RED.view.navigator.init(),RED.view.tools.init(),RED.view.annotations.register("red-ui-flow-node-changed",{type:"badge",class:"red-ui-flow-node-changed",element:function(){var e=document.createElementNS("http://www.w3.org/2000/svg","circle");return e.setAttribute("cx",5),e.setAttribute("cy",5),e.setAttribute("r",5),e},show:function(e){return e.changed||e.moved}}),RED.view.annotations.register("red-ui-flow-node-error",{type:"badge",class:"red-ui-flow-node-error",element:function(e){var t=document.createElementNS("http://www.w3.org/2000/svg","path");return t.setAttribute("d","M 0,9 l 10,0 -5,-8 z"),t},tooltip:function(e){if(e.validationErrors&&0<e.validationErrors.length)return RED._("editor.errors.invalidProperties")+"\n - "+e.validationErrors.join("\n - ")},show:function(e){return!e.valid}}),RED.settings.get("editor.view.view-store-zoom")&&(o=parseFloat(RED.settings.getLocal("zoom-level")),isNaN(o)||(R=o));var e=null;function t(){n[RED.workspaces.active()]={left:z.scrollLeft(),top:z.scrollTop()},RED.settings.setLocal("scroll-positions",JSON.stringify(n))}if(z.on("scroll",function(){RED.settings.get("editor.view.view-store-position")&&(e&&clearTimeout(e),e=setTimeout(t,200))}),RED.settings.get("editor.view.view-store-position")){var o=RED.settings.getLocal("scroll-positions");if(o)try{n=JSON.parse(o)}catch(e){}}},state:function(e){if(null==e)return M;M=e},updateActive:J,redraw:function(e,t){e&&(J(),W()),(t?Gt:H)()},focus:Ft,importNodes:Ut,calculateTextWidth:function(e,t){for(var o=nt(e),n=0,i=0;i<o.length;i++){var a=ot(o[i],t)[0];n<a&&(n=a)}return n},select:function(e){var t;void 0!==e&&(q(),"string"==typeof e?(t=RED.nodes.node(e))&&(t.selected=!0,t.dirty=!0,U.clear(),U.add(t)):e&&e.nodes&&(J(),U.clear(),e.nodes.forEach(function(e){"group"!==e.type?(e.selected=!0,e.dirty=!0,U.add(e)):v(e,!0)}))),W(),H()},selection:Jt,clearSelection:q,createNode:qt,get node_width(){return I},get node_height(){return N},get snapGrid(){return ee},scale:function(){return R},getLinksAtPoint:function(e,t){for(var o=[],n=Ee.selectAll(".red-ui-flow-link-background")[0],i=0;i<n.length;i++){var a=n[i].getBBox();e>=a.x&&t>=a.y&&e<=a.x+a.width&&t<=a.y+a.height&&o.push(n[i])}return o},getGroupAtPoint:Nt,getActiveGroup:function(){return g},reveal:function(e,t){if(RED.nodes.workspace(e)||RED.nodes.subflow(e))RED.workspaces.show(e,null,null,!0);else{var o=RED.nodes.node(e)||RED.nodes.group(e);if(o)if(!o.z||"group"!==o.type&&"config"===o._def.category)"config"===o._def.category&&RED.sidebar.config.show(e);else{o.dirty=!0,RED.workspaces.show(o.z);var e=[z[0].clientWidth/R,z[0].clientHeight/R],n=[z.scrollLeft()/R,z.scrollTop()/R],i=o.x,a=o.y;if("group"===o.type&&(i+=o.w/2,a+=o.h/2),(i<n[0]||a<n[1]||e[0]+n[0]<i||e[1]+n[1]<a)&&(i="-="+(n[0]-i+e[0]/2)*R,n="-="+(n[1]-a+e[1]/2)*R,z.animate({scrollLeft:i,scrollTop:n},200)),!1!==t){a=o;let e=a;if(e="string"==typeof e?RED.nodes.node(a):e){const s=r&&RED.nodes.node(r);s&&(clearInterval(s.__flashTimer),delete s.__flashTimer,s.dirty=!0,s.highlighted=!1),e.__flashTimer=setInterval(function(e,t){t.dirty=!0,e>=Date.now()?t.highlighted=!t.highlighted:(clearInterval(t.__flashTimer),delete t.__flashTimer,r=null,t.highlighted=!1),RED.view.redraw()},100,Date.now()+2200,e),r=e.id,e.highlighted=!0,RED.view.redraw()}}}}},gridSize:function(e){if(void 0===e)return E;E=Math.max(5,e),Se()},getActiveNodes:function(){return y},getSubflowPorts:function(){var o=[];return P&&(ke.selectAll(".red-ui-flow-subflow-port-output").data(P.out,function(e,t){return e.id}).each(function(e,t){o.push(e)}),ke.selectAll(".red-ui-flow-subflow-port-input").data(P.in,function(e,t){return e.id}).each(function(e,t){o.push(e)}),ke.selectAll(".red-ui-flow-subflow-port-status").data(P.status?[P.status]:[],function(e,t){return e.id}).each(function(e,t){o.push(e)})),o},selectNodes:function(e){$("#red-ui-workspace-tabs-shade").show(),$("#red-ui-palette-shade").show(),$("#red-ui-sidebar-shade").show(),$("#red-ui-header-shade").show(),$("#red-ui-workspace").addClass("red-ui-workspace-select-mode"),M=RED.state.SELECTING_NODE,q(),e.selected&&e.selected.forEach(function(e){e=RED.nodes.node(e);e&&(e.selected=!0,e.dirty=!0,U.add(e))}),H();function t(){q(),$("#red-ui-workspace-tabs-shade").hide(),$("#red-ui-palette-shade").hide(),$("#red-ui-sidebar-shade").hide(),$("#red-ui-header-shade").hide(),$("#red-ui-workspace").removeClass("red-ui-workspace-select-mode"),K(),o.close()}(u=e||{}).done=function(e){t(),u.onselect&&u.onselect(e)};var e=[{text:RED._("common.label.cancel"),click:function(e){t(),u.oncancel&&u.oncancel()}}],o=(u.single||e.push({text:RED._("common.label.done"),class:"primary",click:function(e){var t=U.nodes();u.done(t)}}),RED.notify(u.prompt||RED._("workspace.selectNodes"),{modal:!1,fixed:!0,type:"compact",buttons:e}))},scroll:function(e,t){z.scrollLeft(z.scrollLeft()+e),z.scrollTop(z.scrollTop()+t)},clickNodeButton:function(e){e._def.button&&At(e)},clipboard:function(){return ye},redrawStatus:Bt,showQuickAddDialog:Ae,calculateNodeDimensions:function(t){var e=[I,N];try{var o="link in"===t.type||"link out"===t.type,n=t.hasOwnProperty("l")?!t.l:o,i=Qe(RED.utils.getNodeLabel(t,t.type),"red-ui-flow-node-label");e[1]=n?Math.max(N,15*(t.outputs||0)):Math.max(6+24*i.lines.length,15*(t.outputs||0),30),e[0]=n?N:Math.max(I,20*Math.ceil((i.width+50+(0<t._def.inputs?7:0))/20))}catch(e){console.log("Error",t)}return e},getElementPosition:lt,showTooltip:ut,dimensions:function(){return{width:w,height:Q}}}}(),RED.view.annotations=function(){var r,d,c={};function u(e,t){var n,i,a,o=c[e],s=(t.el.__annotations__=t.el.__annotations__||[],document.createElementNS("http://www.w3.org/2000/svg","g")),e=(s.setAttribute("class",o.class||""),t.el.__annotations__.push({id:e,element:s}),o.element(t.node));o.tooltip&&(e.addEventListener("mouseenter",(n=e,i=t.node,a=o.tooltip,function(){var o="function"==typeof a?a(i):a;o&&(clearTimeout(r),r=setTimeout(function(){var e=RED.view.getElementPosition(n),t=n.getBoundingClientRect();r=null,d=RED.view.showTooltip(e[0]+t.width/2,e[1],o,"top")},500))})),e.addEventListener("mouseleave",l)),s.appendChild(e),t.el.appendChild(s)}function l(){clearTimeout(r),d&&(d.remove(),d=null)}return{init:function(){RED.hooks.add("viewRedrawNode.annotations",function(e){try{e.node.__pendingAnnotation__&&(u(e.node.__pendingAnnotation__,e),delete e.node.__pendingAnnotation__);for(var t=0,o=0,n=0,i=e.el.__annotations__.length;n<i;n++){var a,s,r,d,l=e.el.__annotations__[n];c.hasOwnProperty(l.id)?(a=c[l.id],s=!0,r="badge"===a.type,void 0!==a.show&&(s="string"==typeof a.show?!!e.node[a.show]:"function"==typeof a.show?a.show(e.node):!!a.show,l.element.classList.toggle("hide",!s)),r?s&&(t+=(d=l.element.getBoundingClientRect()).width,l.element.setAttribute("transform","translate("+(e.node.w-3-t)+", -8)"),t+=4):s&&(d=l.element.getBoundingClientRect(),l.element.setAttribute("transform","translate("+(3+o)+", -12)"),o+=d.width+4)):(l.element.parentNode.removeChild(l.element),e.el.__annotations__.splice(n,1),n--,i--)}}catch(e){console.log(e)}})},register:function(t,o){if("badge"!==o.type)throw new Error("Unsupported annotation type: "+o.type);c[t]=o,RED.hooks.add("viewAddNode.annotation-"+t,function(e){o.filter&&!o.filter(e.node)||u(t,e)}),RED.view.getActiveNodes().forEach(function(e){e.__pendingAnnotation__=t}),RED.view.redraw()},unregister:function(e){delete c[e],RED.hooks.remove("*.annotation-"+e),RED.view.redraw()}}}(),RED.view.navigator=function(){var e,t,o,n,i,a,s,r,d,l=25,c=5e3/l,u=5e3/l,p=!1;function f(){var e;p&&((e=n.selectAll(".red-ui-navigator-node").data(RED.view.getActiveNodes(),function(e){return e.id})).exit().remove(),e.enter().insert("rect").attr("class","red-ui-navigator-node").attr("pointer-events","none"),e.each(function(e){d3.select(this).attr("x",function(e){return(e.x-e.w/2)/l}).attr("y",function(e){return(e.y-e.h/2)/l}).attr("width",function(e){return Math.max(9,e.w/l)}).attr("height",function(e){return Math.max(3,e.h/l)}).attr("fill",function(e){return RED.utils.getNodeColor(e.type,e._def)})}))}function h(){d||g()}function g(){o&&(a=RED.view.scale(),s=[$("#red-ui-workspace-chart").width(),$("#red-ui-workspace-chart").height()],i=[$("#red-ui-workspace-chart").scrollLeft(),$("#red-ui-workspace-chart").scrollTop()],o.attr("x",i[0]/l).attr("y",i[1]/l).attr("width",s[0]/l/a).attr("height",s[1]/l/a))}function m(){p?(p=!1,e.fadeOut(100),$("#red-ui-workspace-chart").off("scroll",h),$("#red-ui-view-navigate").removeClass("selected")):(p=!0,$("#red-ui-view-navigate").addClass("selected"),g(),f(),$("#red-ui-workspace-chart").on("scroll",h),e.fadeIn(200))}return{init:function(){$(window).on("resize",g),RED.events.on("sidebar:resize",g),RED.actions.add("core:toggle-navigator",m),e=$("<div>").css({position:"absolute",bottom:$("#red-ui-workspace-footer").height(),right:0,zIndex:1}).appendTo("#red-ui-workspace").hide(),(t=d3.select(e[0]).append("svg:svg").attr("width",c).attr("height",u).attr("pointer-events","all").attr("id","red-ui-navigator-canvas")).append("rect").attr("x",0).attr("y",0).attr("width",c).attr("height",u).style({fill:"none",stroke:"none",pointerEvents:"all"}).on("mousedown",function(){a=RED.view.scale(),s=[$("#red-ui-workspace-chart").width(),$("#red-ui-workspace-chart").height()],r=[s[0]/l/a,s[1]/l/a];var e=Math.max(0,Math.min(d3.event.offsetX+r[0]/2,c)-r[0]),t=Math.max(0,Math.min(d3.event.offsetY+r[1]/2,u)-r[1]);o.attr("x",e).attr("y",t),d=!0,$("#red-ui-workspace-chart").scrollLeft(e*l*a),$("#red-ui-workspace-chart").scrollTop(t*l*a)}).on("mousemove",function(){var e,t;d&&(0===d3.event.buttons?d=!1:(e=Math.max(0,Math.min(d3.event.offsetX+r[0]/2,c)-r[0]),t=Math.max(0,Math.min(d3.event.offsetY+r[1]/2,u)-r[1]),o.attr("x",e).attr("y",t),$("#red-ui-workspace-chart").scrollLeft(e*l*a),$("#red-ui-workspace-chart").scrollTop(t*l*a)))}).on("mouseup",function(){d=!1}),o=t.append("rect").attr("class","red-ui-navigator-border"),n=t.append("svg:g"),RED.statusBar.add({id:"view-navigator",align:"right",element:$('<button class="red-ui-footer-button-toggle single" id="red-ui-view-navigate"><i class="fa fa-map-o"></i></button>')}),$("#red-ui-view-navigate").on("click",function(e){e.preventDefault(),m()}),RED.popover.tooltip($("#red-ui-view-navigate"),RED._("actions.toggle-navigator"),"core:toggle-navigator")},refresh:f,resize:g,toggle:m}}(),RED.view.tools=function(){function t(o){var e=RED.view.selection(),n=new Set;e.nodes&&0<e.nodes.length&&(e.nodes.forEach(function(e){var t;n.has(e)||("all"===o?t=RED.nodes.getAllFlowNodes(e):"up"===o?t=[e].concat(RED.nodes.getAllUpstreamNodes(e)):"down"===o&&(t=[e].concat(RED.nodes.getAllDownstreamNodes(e))),t.forEach(function(e){n.add(e)}))}),RED.view.select({nodes:Array.from(n)}))}function e(){var n,e=RED.view.selection();e.nodes&&(n=[],e.nodes.forEach(function(e){var t=e.w/2+Math.round((e.x-e.w/2)/RED.view.gridSize())*RED.view.gridSize(),o=Math.round(e.y/RED.view.gridSize())*RED.view.gridSize();e.x===t&&e.y===o||(n.push({n:e,ox:e.x,oy:e.y,moved:e.moved}),e.x=t,e.y=o,e.dirty=!0,e.moved=!0)}),0<n.length&&(RED.history.push({t:"move",nodes:n,dirty:RED.nodes.dirty()}),RED.nodes.dirty(!0),RED.view.redraw(!0)))}var u=null,p=!1;function f(){if(p=!1,0<u.length){for(var e=[],t=0;t<u.length;t++)e.push({n:u[t].n,ox:u[t].ox,oy:u[t].oy,moved:u[t].moved}),u[t].n.moved=!0,u[t].n.dirty=!0,delete u[t].ox,delete u[t].oy;RED.view.redraw(),RED.history.push({t:"move",nodes:e,dirty:RED.nodes.dirty()}),RED.nodes.dirty(!0),u=null}}function o(e,t){if(null===u){u=[];var o=RED.view.selection();if(o.nodes)for(;0<o.nodes.length;){var n=o.nodes.shift();u.push({n:n}),"group"===n.type&&(o.nodes=o.nodes.concat(n.nodes))}}if(u&&0<u.length){p||($(document).one("keyup",f),p=!0);for(var i,a=RED.view.dimensions(),s=a.width,r=a.height,d=0,l=0,c=0;c<u.length;c++)null==(i=u[c]).ox&&null==i.oy&&(i.ox=i.n.x,i.oy=i.n.y,i.moved=i.n.moved),i.n.moved=!0,i.n.dirty=!0,i.n.x+=e,i.n.y+=t,i.n.x+i.n.w/2>=s&&(i.n.x=s-i.n.w/2),i.n.y+i.n.h/2>=r&&(i.n.y=r-i.n.h/2),i.n.dirty=!0,l="group"===i.n.type?(RED.group.markDirty(i.n),d=Math.min(i.n.x-5,d),Math.min(i.n.y-5,l)):(d=Math.min(i.n.x-i.n.w/2-5,d),Math.min(i.n.y-i.n.h/2-5,l));if(0!==d||0!==l)for(n=0;n<u.length;n++)(i=u[n]).n.x-=d,i.n.y-=l;RED.view.redraw()}else RED.view.scroll(10*e,10*t)}function n(i){var e=RED.view.selection(),a=[],t=[];e.nodes&&e.nodes.forEach(function(e){"subflow"!==e.type&&"group"!==e.type?t.push(e):"group"===e.type&&(t=t.concat(RED.group.getNodes(e,!0)))}),t.forEach(function(e){var t=!1,o=void 0===e.l||e.l,n=!e._def.hasOwnProperty("showLabel")||e._def.showLabel;i?!1!==e.l&&(n||e.hasOwnProperty("l"))||(t=e.l=!0):(!n||e.hasOwnProperty("l")&&!0!==e.l)&&(n||!0!==e.l)||(t=!(e.l=!1)),t&&(a.push({t:"edit",node:e,changed:e.changed,changes:{l:o}}),e.changed=!0,e.dirty=!0,e.resize=!0)}),0<a.length&&(RED.history.push({t:"multi",events:a,dirty:RED.nodes.dirty()}),RED.nodes.dirty(!0)),RED.view.redraw()}function i(){var n={x:0,y:0},e=RED.view.getActiveGroup(),i=(e?(candidates=RED.group.getNodes(e,!1),n=e):candidates=RED.view.getActiveNodes(),[]);candidates.forEach(function(e){var t=e.x-n.x,o=e.y-n.x;i.push({node:e,delta:o*o+t*t})}),0<i.length&&(i.sort(function(e,t){return e.delta-t.delta}),(e=i[0].node)&&(RED.view.select({nodes:[e]}),RED.view.reveal(e.id,!1)))}function a(e){return RED.nodes.filterLinks({source:e}).map(function(e){return e.target})}function s(e){return RED.nodes.filterLinks({target:e}).map(function(e){return e.source})}function r(e){var t=new Set;return s(e).forEach(function(e){a(e).forEach(function(e){t.add(e)})}),a(e).forEach(function(e){s(e).forEach(function(e){t.add(e)})}),t.delete(e),Array.from(t)}function d(s){var r,e,d,t,o=RED.view.selection();o.nodes&&1===o.nodes.length?(r=o.nodes[0],d=[],(e=(e=RED.nodes.filterNodes({z:r.z})).concat(RED.view.getSubflowPorts())).forEach(function(e){if(e!==r){var t,o=e.x-r.x,n=e.y-r.y,i=n*n+o*o,a=180/Math.PI*Math.atan2(n,o);switch(a<0&&(a+=360),360<a&&(a-=360),s){case"up":if(a<210||330<a)return;t=Math.max(Math.abs(270-a)/60,.2);break;case"down":if(a<30||150<a)return;t=Math.max(Math.abs(90-a)/60,.2);break;case"left":if(a<140||220<a)return;t=Math.max(Math.abs(180-a)/40,.1);break;case"right":if(40<a&&a<320)return;t=Math.max(Math.abs(a)/40,.1)}t=Math.max(t,.1),d.push({node:e,d:i,w:t,delta:i*t})}}),0<d.length&&(d.sort(function(e,t){return e.delta-t.delta}),(t=d[0].node)&&(RED.view.select({nodes:[t]}),RED.view.reveal(t.id,!1)))):0===RED.workspaces.selection().length&&(e=RED.view.getActiveNodes(),d=[],e.forEach(function(e){var t=e.x,o=e.y;d.push({node:e,delta:o*o+t*t})}),0<d.length&&(d.sort(function(e,t){return e.delta-t.delta}),(t=d[0].node)&&(RED.view.select({nodes:[t]}),RED.view.reveal(t.id,!1))))}function l(r){var d,l,e=RED.view.selection();e.nodes&&1<e.nodes.length&&(d=[],l={minX:Number.MAX_SAFE_INTEGER,minY:Number.MAX_SAFE_INTEGER,maxX:Number.MIN_SAFE_INTEGER,maxY:Number.MIN_SAFE_INTEGER},e.nodes.forEach(function(e){"group"===e.type?(l.minX=Math.min(l.minX,e.x),l.minY=Math.min(l.minY,e.y),l.maxX=Math.max(l.maxX,e.x+e.w),l.maxY=Math.max(l.maxY,e.y+e.h)):(l.minX=Math.min(l.minX,e.x-e.w/2),l.minY=Math.min(l.minY,e.y-e.h/2),l.maxX=Math.max(l.maxX,e.x+e.w/2),l.maxY=Math.max(l.maxY,e.y+e.h/2))}),l.midX=l.minX+(l.maxX-l.minX)/2,l.midY=l.minY+(l.maxY-l.minY)/2,e.nodes.forEach(function(e){var t,o,n,i,a,s="group"===e.type;switch(r){case"top":t=e.x,o=l.minY+(s?0:e.h/2);break;case"bottom":t=e.x,o=l.maxY-(s?e.h:e.h/2);break;case"left":t=l.minX+(s?0:e.w/2),o=e.y;break;case"right":t=l.maxX-(s?e.w:e.w/2),o=e.y;break;case"middle":t=e.x,o=l.midY-(s?e.h/2:0);break;case"center":t=l.midX-(s?e.w/2:0),o=e.y}e.x===t&&e.y===o||(s?(n=RED.group.getNodes(e,!0),i=e.x-t,a=e.y-o,n.forEach(function(e){"group"!==e.type&&(d.push({n:e,ox:e.x,oy:e.y,moved:e.moved}),e.x=e.x-i,e.y=e.y-a,e.dirty=!0,e.moved=!0)})):(d.push({n:e,ox:e.x,oy:e.y,moved:e.moved}),e.x=t,e.y=o,e.dirty=!0,e.moved=!0))}),0<d.length&&(RED.history.push({t:"move",nodes:d,dirty:RED.nodes.dirty()}),RED.nodes.dirty(!0),RED.view.redraw(!0)))}function c(n){var e=RED.view.selection();if(e.nodes&&2<e.nodes.length){var t=[],i={minX:Number.MAX_SAFE_INTEGER,minY:Number.MAX_SAFE_INTEGER,maxX:Number.MIN_SAFE_INTEGER,maxY:Number.MIN_SAFE_INTEGER},a=[],s=[],o=(e.nodes.forEach(function(e){var t,o="group"===e.type?(t=e.x+e.w/2,e.y+e.h/2):(t=e.x,e.y);"h"===n?(t<i.minX&&(a=[],i.minX=t),t===i.minX&&a.push(e),t>i.maxX&&(s=[],i.maxX=t),t===i.maxX&&s.push(e)):(o<i.minY&&(a=[],i.minY=o),o===i.minY&&a.push(e),o>i.maxY&&(s=[],i.maxY=o),o===i.maxY&&s.push(e))}),a[0]),r=s[0],d=0,l=e.nodes.filter(function(e){return e.id!==o.id&&e.id!==r.id&&(d+="h"===n?e.w:e.h,!0)}).sort(function(e,t){return"h"===n?e.x-t.x:e.y-t.y}),e=o.x+o.w/2,c=o.y+o.h/2,u=("group"===o.type&&(e=o.x+o.w,c=o.y+o.h),r.x),p=r.y;"group"!==r.type&&(u-=r.w/2,p-=r.h/2);for(var f=("h"===n?u-e-d:p-c-d)/(l.length+1),h=e,g=c;0<l.length;){"h"===n?h+=f:g+=f;var m,v,b,y=l.shift(),w="group"===y.type,E=y.x,D=y.y;w||(h+=y.w/2,g+=y.h/2),("h"===n&&E!==h||"v"===n&&D!==g)&&(w?(m=RED.group.getNodes(y,!0),v="h"===n?E-h:0,b="v"===n?D-g:0,m.forEach(function(e){"group"!==e.type&&(t.push({n:e,ox:e.x,oy:e.y,moved:e.moved}),e.x=e.x-v,e.y=e.y-b,e.dirty=!0,e.moved=!0)})):(t.push({n:y,ox:y.x,oy:y.y,moved:y.moved}),"h"===n?y.x=h:y.y=g,y.dirty=!0,y.moved=!0)),w?(h+=y.w,g+=y.h):(h+=y.w/2,g+=y.h/2)}0<t.length&&(RED.history.push({t:"move",nodes:t,dirty:RED.nodes.dirty()}),RED.nodes.dirty(!0),RED.view.redraw(!0))}}function h(e){var t,o,n,i=RED.view.selection();i.nodes&&(t=[],i.nodes.forEach(function(e){"group"===e.type?t=t.concat(RED.group.getNodes(e,!0).filter(function(e){return"group"!==e.type})):"subflow"!==e.type&&t.push(e)}),0<t.length&&(i=t[0].z,o=RED.nodes.getNodeOrder(i),"forwards"===e?n=RED.nodes.moveNodesForwards(t):"backwards"===e?n=RED.nodes.moveNodesBackwards(t):"front"===e?n=RED.nodes.moveNodesToFront(t):"back"===e&&(n=RED.nodes.moveNodesToBack(t)),0<n.length&&(e=RED.nodes.getNodeOrder(i),RED.history.push({t:"reorder",nodes:{z:i,from:o,to:e},dirty:RED.nodes.dirty()}),RED.nodes.dirty(!0),RED.view.redraw(!0))))}function g(e){let n=e||RED.view.selection().links&&RED.view.selection().links.filter(e=>!e.link);if(n&&!((n=Array.isArray(n)?n:[n]).length<1)){const p={t:"multi",events:[],dirty:RED.nodes.dirty()},f={},h={},g=RED.view.gridSize();for(let o=0;o<n.length;o++){function i(e,t,o,n,i){var a=RED.view.calculateNodeDimensions(t);t.w=a[0],t.h=a[1];const s={x:e.x||0,y:e.y||0,w:e.w||RED.view.node_width,h:e.h||RED.view.node_height};a=s.x-s.w/2;s.x=o?a-g-t.w/2:a+s.w+g+t.w/2,t.x=s.x,t.y=s.y,!1!==n&&(e=RED.view.tools.calculateGridSnapOffsets(t),t.x-=e.x,t.y-=e.y),t.y+=i||0}var a=n[o],s=a.source,r=a.target,d=a.sourcePort||0,l=s.id+":"+d;let t=f[l];if(!t){var c=RED.view.createNode("link out");t=c.node,f[l]=t;let e=0;1<s.outputs?(l=(s.outputs-1)/2+1,u=Math.abs(l-(d+1)),e=2*g*u,d+1<l&&(e=-e),i(s,t,!1,!1,e)):i(s,t,!1,RED.view.snapGrid,e),RED.nodes.add(t),RED.editor.validateNode(t),p.events.push(c.historyEvent);var u={source:s,sourcePort:a.sourcePort||0,target:t};RED.nodes.addLink(u),p.events.push({t:"add",links:[u]})}let e=h[r.id];e||(d=RED.view.createNode("link in"),e=d.node,i(r,h[r.id]=e,!0,RED.view.snapGrid,0),RED.nodes.add(e),RED.editor.validateNode(e),p.events.push(d.historyEvent),l={source:e,sourcePort:0,target:r},RED.nodes.addLink(l),p.events.push({t:"add",links:[l]})),-1==e.links.indexOf(t.id)&&e.links.push(t.id),-1==t.links.indexOf(e.id)&&t.links.push(e.id),RED.nodes.removeLink(a),p.events.push({t:"delete",links:[a]})}RED.history.push(p),RED.view.clearSelection(),RED.view.select({nodes:Object.values(h)}),t("down"),RED.nodes.dirty(!0),RED.view.redraw(!0)}}function m(e,s){s=Object.assign({renameBlank:!0,renameClash:!0,generateHistory:!0},s);let t=e;if(e?Array.isArray(e)||(t=[e]):t=RED.view.selection().nodes,t&&0<t.length){const r=s.generateHistory&&(!e||!!RED.nodes.node(e.id)),d=[],l={};let a=!1;t.forEach(e=>{var t=e._def||RED.nodes.getType(e.type);if(t&&t.defaults&&t.defaults.name){const o=RED.utils.getPaletteLabel(e.type,t),n=new RegExp("^"+o.replace(/[.*+?^${}()|[\]\\]/g,"\\$&")+" (\\d+)$");if(!l.hasOwnProperty(e.type)){const i=RED.nodes.filterNodes({type:e.type});let t=0;i.forEach(e=>{var e=n.exec(e.name);e&&(e=parseInt(e[1]))>t&&(t=e)}),l[e.type]=t+1}(s.renameBlank&&""===e.name||s.renameClash&&n.test(e.name))&&(r&&d.push({t:"edit",node:e,changes:{name:e.name},dirty:RED.nodes.dirty(),changed:e.changed}),e.name=o+" "+l[e.type],e.dirty=!0,l[e.type]++,a=!0)}}),a&&(0<d.length&&RED.history.push({t:"multi",events:d}),RED.nodes.dirty(!0),RED.view.redraw())}}return{init:function(){RED.actions.add("core:show-selected-node-labels",function(){n(!0)}),RED.actions.add("core:hide-selected-node-labels",function(){n(!1)}),RED.actions.add("core:scroll-view-up",function(){RED.view.scroll(0,-RED.view.gridSize())}),RED.actions.add("core:scroll-view-right",function(){RED.view.scroll(RED.view.gridSize(),0)}),RED.actions.add("core:scroll-view-down",function(){RED.view.scroll(0,RED.view.gridSize())}),RED.actions.add("core:scroll-view-left",function(){RED.view.scroll(-RED.view.gridSize(),0)}),RED.actions.add("core:step-view-up",function(){RED.view.scroll(0,-5*RED.view.gridSize())}),RED.actions.add("core:step-view-right",function(){RED.view.scroll(5*RED.view.gridSize(),0)}),RED.actions.add("core:step-view-down",function(){RED.view.scroll(0,5*RED.view.gridSize())}),RED.actions.add("core:step-view-left",function(){RED.view.scroll(-5*RED.view.gridSize(),0)}),RED.actions.add("core:move-selection-up",function(){o(0,-1)}),RED.actions.add("core:move-selection-right",function(){o(1,0)}),RED.actions.add("core:move-selection-down",function(){o(0,1)}),RED.actions.add("core:move-selection-left",function(){o(-1,0)}),RED.actions.add("core:move-selection-forwards",function(){h("forwards")}),RED.actions.add("core:move-selection-backwards",function(){h("backwards")}),RED.actions.add("core:move-selection-to-front",function(){h("front")}),RED.actions.add("core:move-selection-to-back",function(){h("back")}),RED.actions.add("core:step-selection-up",function(){o(0,-RED.view.gridSize())}),RED.actions.add("core:step-selection-right",function(){o(RED.view.gridSize(),0)}),RED.actions.add("core:step-selection-down",function(){o(0,RED.view.gridSize())}),RED.actions.add("core:step-selection-left",function(){o(-RED.view.gridSize(),0)}),RED.actions.add("core:select-connected-nodes",function(){t("all")}),RED.actions.add("core:select-downstream-nodes",function(){t("down")}),RED.actions.add("core:select-upstream-nodes",function(){t("up")}),RED.actions.add("core:go-to-next-node",function(){var o,e;(e=RED.view.selection()).nodes&&1===e.nodes.length?(o=e.nodes[0],0<(e=RED.nodes.filterLinks({source:o})).length&&(e.sort(function(e,t){return Math.abs(e.target.y-o.y)-Math.abs(t.target.y-o.y)}),(e=e[0].target)&&(RED.view.select({nodes:[e]}),RED.view.reveal(e.id,!1)))):0===RED.workspaces.selection().length&&i()}),RED.actions.add("core:go-to-previous-node",function(){var o,e;(e=RED.view.selection()).nodes&&1===e.nodes.length?(o=e.nodes[0],0<(e=RED.nodes.filterLinks({target:o})).length&&(e.sort(function(e,t){return Math.abs(e.source.y-o.y)-Math.abs(t.source.y-o.y)}),(e=e[0].source)&&(RED.view.select({nodes:[e]}),RED.view.reveal(e.id,!1)))):0===RED.workspaces.selection().length&&i()}),RED.actions.add("core:go-to-next-sibling",function(){var o,e;(e=RED.view.selection()).nodes&&1===e.nodes.length?0<(e=r(o=e.nodes[0])).length&&((e=e.filter(function(e){return e.y>o.y})).sort(function(e,t){return Math.abs(e.y-o.y)-Math.abs(t.y-o.y)}),(e=e[0])&&(RED.view.select({nodes:[e]}),RED.view.reveal(e.id,!1))):0===RED.workspaces.selection().length&&i()}),RED.actions.add("core:go-to-previous-sibling",function(){var o,e;(e=RED.view.selection()).nodes&&1===e.nodes.length?0<(e=r(o=e.nodes[0])).length&&((e=e.filter(function(e){return e.y<o.y})).sort(function(e,t){return Math.abs(e.y-o.y)-Math.abs(t.y-o.y)}),(e=e[0])&&(RED.view.select({nodes:[e]}),RED.view.reveal(e.id,!1))):0===RED.workspaces.selection().length&&i()}),RED.actions.add("core:go-to-nearest-node-on-left",function(){d("left")}),RED.actions.add("core:go-to-nearest-node-on-right",function(){d("right")}),RED.actions.add("core:go-to-nearest-node-above",function(){d("up")}),RED.actions.add("core:go-to-nearest-node-below",function(){d("down")}),RED.actions.add("core:align-selection-to-grid",e),RED.actions.add("core:align-selection-to-left",function(){l("left")}),RED.actions.add("core:align-selection-to-right",function(){l("right")}),RED.actions.add("core:align-selection-to-top",function(){l("top")}),RED.actions.add("core:align-selection-to-bottom",function(){l("bottom")}),RED.actions.add("core:align-selection-to-middle",function(){l("middle")}),RED.actions.add("core:align-selection-to-center",function(){l("center")}),RED.actions.add("core:distribute-selection-horizontally",function(){c("h")}),RED.actions.add("core:distribute-selection-vertically",function(){c("v")}),RED.actions.add("core:wire-series-of-nodes",function(){var e=RED.view.selection();if(e.nodes&&1<e.nodes.length){for(var t=0,o=[];t<e.nodes.length-1;){var n=e.nodes[t],i=e.nodes[t+1];0<n.outputs&&0<i.inputs&&0===RED.nodes.filterLinks({source:n,target:i,sourcePort:0}).length&&(RED.nodes.addLink(n={source:n,target:i,sourcePort:0}),o.push(n)),t++}0<o.length&&(RED.history.push({t:"add",links:o,dirty:RED.nodes.dirty()}),RED.nodes.dirty(!0),RED.view.redraw(!0))}}),RED.actions.add("core:wire-node-to-multiple",function(){var e=RED.view.selection();if(e.nodes&&1<e.nodes.length){var t=e.nodes[0];if(0!==t.outputs){for(var o=1,n=[];o<e.nodes.length;){var i=e.nodes[o];0<i.inputs&&0===RED.nodes.filterLinks({source:t,target:i,sourcePort:Math.min(t.outputs-1,o-1)}).length&&(i={source:t,target:i,sourcePort:Math.min(t.outputs-1,o-1)},RED.nodes.addLink(i),n.push(i)),o++}0<n.length&&(RED.history.push({t:"add",links:n,dirty:RED.nodes.dirty()}),RED.nodes.dirty(!0),RED.view.redraw(!0))}}}),RED.actions.add("core:split-wire-with-link-nodes",function(){g()}),RED.actions.add("core:split-wires-with-junctions",function(){{var t=void 0,r,d,l,c,o;let e=t||RED.view.selection().links&&RED.view.selection().links.filter(e=>!e.link);e&&0!==(e=Array.isArray(e)?e:[e]).length&&(r=new Set,d=[],l=[],c={},e.forEach(function(e){var t=e.source.id+":"+e.sourcePort;c[t]=c[t]||[],c[t].push(e),c[e.target.id]=c[e.target.id]||[],c[e.target.id].push(e)}),(t=Object.keys(c)).sort(function(e,t){return c[t].length-c[e].length}),o=RED.nodes.dirty(),t.forEach(function(o){var n=c[o],i={_def:{defaults:{}},type:"junction",z:RED.workspaces.active(),id:RED.nodes.id(),x:0,y:0,w:0,h:0,outputs:1,inputs:1,dirty:!0},n=n.filter(function(e){return!r.has(e)});if(0!==n.length){let t=0;n.forEach(function(e){e._sliceLocation?(i.x+=e._sliceLocation.x,i.y+=e._sliceLocation.y,delete e._sliceLocation,t++):(i.x+=e.source.x+e.source.w/2+e.target.x-e.target.w/2,i.y+=e.source.y+e.target.y,t+=2)}),i.x=Math.round(i.x/t),i.y=Math.round(i.y/t),RED.view.snapGrid&&(a=RED.view.gridSize(),i.x=a*Math.round(i.x/a),i.y=a*Math.round(i.y/a));var a,s=new Set;RED.nodes.addJunction(i),l.push(i);let e;e=o===n[0].source.id+":"+n[0].sourcePort?{source:n[0].source,sourcePort:n[0].sourcePort,target:i}:{source:i,sourcePort:0,target:n[0].target},d.push(e),RED.nodes.addLink(e),n.forEach(function(e){r.add(e),RED.nodes.removeLink(e);let t;t=o===e.target.id?{source:e.source,sourcePort:e.sourcePort,target:i}:{source:i,sourcePort:0,target:e.target},d.push(t),RED.nodes.addLink(t),s.add(e.source.g||"__NONE__"),s.add(e.target.g||"__NONE__")}),1!==s.size||"__NONE__"!==(a=s.values().next().value)&&RED.group.addToGroup(RED.nodes.group(a),i)}}),0<l.length&&(RED.history.push({dirty:o,t:"add",links:d,junctions:l,removedLinks:Array.from(r)}),RED.nodes.dirty(!0),RED.view.select({nodes:l})),RED.view.redraw(!0))}}),RED.actions.add("core:generate-node-names",m)},alignSelectionToGrid:e,moveSelection:o,calculateGridSnapOffsets:function(e,t){t=t||{align:"nearest"};const o={x:0,y:0};var n=RED.view.gridSize(),i=e.x-(n*Math.round((e.x-e.w/2)/n)+e.w/2),a=e.x-(n*Math.round((e.x+e.w/2)/n)-e.w/2);return o.x=a,"right"!==t.align&&("left"===t.align||Math.abs(i)<Math.abs(a))&&(o.x=i),o.y=e.y-n*Math.round(e.y/n),o}}}(),RED.sidebar=function(){var a,s={},o=null;var i={};function t(e){e?($("#red-ui-main-container").removeClass("red-ui-sidebar-closed"),a.resize()):$("#red-ui-main-container").addClass("red-ui-sidebar-closed"),RED.events.emit("sidebar:resize")}function r(e,t){(e=":first"===e?o||RED.settings.get("editor.sidebar.order",["info","help","version-control","debug"])[0]:e)&&(!n(e)&&s[e]&&a.addTab(s[e]),a.activateTab(e),t||RED.menu.isSelected("menu-item-sidebar")||RED.menu.setSelected("menu-item-sidebar",!0))}function n(e){return a.contains(e)}return i.dragging=!1,{init:function(){var e;$("#red-ui-sidebar-separator").draggable({axis:"x",start:function(e,t){i.closing=!1,i.opening=!1;var o=$("#red-ui-editor").width();i.start=t.position.left,i.chartWidth=$("#red-ui-workspace").width(),i.chartRight=o-$("#red-ui-workspace").width()-$("#red-ui-workspace").offset().left-2,i.dragging=!0,RED.menu.isSelected("menu-item-sidebar")||(i.opening=!0,$("#red-ui-sidebar").addClass("closing"),$("#red-ui-workspace").css("right",7),$("#red-ui-editor-stack").css("right",8),$("#red-ui-sidebar").width(0),RED.menu.setSelected("menu-item-sidebar",!0),RED.events.emit("sidebar:resize")),i.width=$("#red-ui-sidebar").width()},drag:function(e,t){var o=t.position.left-i.start,n=i.width-o,t=(i.opening&&(n-=3),150<n&&i.chartWidth+o<200&&(t.position.left=200+i.start-i.chartWidth,o=t.position.left-i.start,n=i.width-o),n<150?(i.closing||($("#red-ui-sidebar").addClass("closing"),i.closing=!0),i.opening||(t.position.left=i.width-((n=150)-i.start),o=t.position.left-i.start)):150<n&&(i.closing||i.opening)&&(i.closing=!1,$("#red-ui-sidebar").removeClass("closing")),i.chartRight-o);$("#red-ui-workspace").css("right",t),$("#red-ui-editor-stack").css("right",1+t),$("#red-ui-sidebar").width(n),a.resize(),RED.events.emit("sidebar:resize")},stop:function(e,t){i.dragging=!1,i.closing&&($("#red-ui-sidebar").removeClass("closing"),RED.menu.setSelected("menu-item-sidebar",!1),$("#red-ui-sidebar").width()<180&&($("#red-ui-sidebar").width(180),$("#red-ui-workspace").css("right",187),$("#red-ui-editor-stack").css("right",188))),$("#red-ui-sidebar-separator").css("left","auto"),$("#red-ui-sidebar-separator").css("right",$("#red-ui-sidebar").width()+2+"px"),RED.events.emit("sidebar:resize")}}),(e=$('<div class="red-ui-sidebar-control-right"><i class="fa fa-chevron-right"</div>').appendTo($("#red-ui-sidebar-separator"))).on("click",function(){e.hide(),RED.menu.toggleSelected("menu-item-sidebar")}),$("#red-ui-sidebar-separator").on("mouseenter",function(){i.dragging||(RED.menu.isSelected("menu-item-sidebar")?e.find("i").addClass("fa-chevron-right").removeClass("fa-chevron-left"):e.find("i").removeClass("fa-chevron-right").addClass("fa-chevron-left"),e.toggle("slide",{direction:"right"},200))}),$("#red-ui-sidebar-separator").on("mouseleave",function(){i.dragging||(e.stop(!1,!0),e.hide())}),a=RED.tabs.create({element:$('<ul id="red-ui-sidebar-tabs"></ul>').appendTo("#red-ui-sidebar"),onchange:function(e){$("#red-ui-sidebar-content").children().hide(),$("#red-ui-sidebar-footer").children().hide(),e.onchange&&e.onchange.call(e),$(e.wrapper).show(),e.toolbar&&$(e.toolbar).show(),RED.settings.setLocal("last-sidebar-tab",e.id)},onremove:function(e){$(e.wrapper).hide(),e.onremove&&e.onremove.call(e)},collapsible:!0,onreorder:function(e){RED.settings.set("editor.sidebar.order",e)},order:RED.settings.get("editor.sidebar.order",["info","help","version-control","debug"])}),$('<div id="red-ui-sidebar-content"></div>').appendTo("#red-ui-sidebar"),$('<div id="red-ui-sidebar-footer" class="red-ui-component-footer"></div>').appendTo("#red-ui-sidebar"),$('<div id="red-ui-sidebar-shade" class="hide"></div>').appendTo("#red-ui-sidebar"),RED.actions.add("core:toggle-sidebar",function(e){void 0===e?RED.menu.toggleSelected("menu-item-sidebar"):t(e)}),RED.popover.tooltip($("#red-ui-sidebar-separator").find(".red-ui-sidebar-control-right"),RED._("keyboard.toggleSidebar"),"core:toggle-sidebar"),o=RED.settings.getLocal("last-sidebar-tab"),RED.sidebar.info.init(),RED.sidebar.help.init(),RED.sidebar.config.init(),RED.sidebar.context.init(),$("#red-ui-editor").width()<600&&RED.menu.setSelected("menu-item-sidebar",!1)},addTab:function(e,t,o,n){var i;"string"==typeof e?i={id:t.id,label:e,name:e,content:t,closeable:o,visible:n}:"object"==typeof e&&(i=e),delete i.closeable,i.wrapper=$("<div>",{style:"height:100%"}).appendTo("#red-ui-sidebar-content"),i.wrapper.append(i.content),i.wrapper.hide(),i.enableOnEdit||(i.shade=$("<div>",{class:"red-ui-sidebar-shade hide"}).appendTo(i.wrapper)),i.toolbar&&($("#red-ui-sidebar-footer").append(i.toolbar),$(i.toolbar).hide()),i.id,RED.menu.addItem("menu-item-view-menu",{id:"menu-item-view-menu-"+i.id,label:i.name,onselect:function(){r(i.id)},group:"sidebar-tabs"}),i.iconClass=i.iconClass||"fa fa-square-o",!1!==(s[i.id]=i).visible&&a.addTab(s[i.id])},removeTab:function(e){a.removeTab(e),$(s[e].wrapper).remove(),s[e].footer&&s[e].footer.remove(),delete s[e],RED.menu.removeItem("menu-item-view-menu-"+e)},show:r,containsTab:n,toggleSidebar:t}}(),RED.palette=function(){var n,w=["config","unknown","deprecated"],E=["subflows","common","function","network","input","output","sequence","parser","storage","analysis","social","advanced"],D={};function R(e,t,o,n){0===$("#red-ui-palette-base-category-"+t).length&&i(e,t,n+":palette.label."+t),$("#red-ui-palette-container-"+t).show(),0===$("#red-ui-palette-"+o).length&&$("#red-ui-palette-base-category-"+t).append('<div id="red-ui-palette-'+o+'"></div>')}function i(e,t,o){var o=((o=RED._(o,{defaultValue:t}))||t).replace(/_/g," "),n=$('<div id="red-ui-palette-container-'+t+'" class="red-ui-palette-category hide"><div id="red-ui-palette-header-'+t+'" class="red-ui-palette-header"><i class="expanded fa fa-angle-down"></i><span>'+o+'</span></div><div class="red-ui-palette-content" id="red-ui-palette-base-category-'+t+'"><div id="red-ui-palette-'+t+'"></div><div id="red-ui-palette-'+t+'-input"></div><div id="red-ui-palette-'+t+'-output"></div><div id="red-ui-palette-'+t+'-function"></div></div></div>').appendTo("#red-ui-palette-container");n.data("category",e),n.data("label",o),D[t]={container:n,close:function(){n.removeClass("red-ui-palette-open"),n.addClass("red-ui-palette-closed"),$("#red-ui-palette-base-category-"+t).slideUp(),$("#red-ui-palette-header-"+t+" i").removeClass("expanded")},open:function(){n.addClass("red-ui-palette-open"),n.removeClass("red-ui-palette-closed"),$("#red-ui-palette-base-category-"+t).slideDown(),$("#red-ui-palette-header-"+t+" i").addClass("expanded")},toggle:function(){n.hasClass("red-ui-palette-open")?D[t].close():D[t].open()}},$("#red-ui-palette-header-"+t).on("click",function(e){D[t].toggle()})}function x(t,e,o,n){e.attr("data-palette-label",o);for(var i=(o=RED.utils.sanitize(o)).split(/([ -]|\\n )/),a=[],s="",r=0;r<i.length;r++){var d=i[r];if("\\n "===d)a.push(s),s="";else{var l=0==r?"":" ";if(RED.view.calculateTextWidth(s+l+d,"red-ui-palette-label")<82)s+=l+d;else for(0<r&&a.push(s);;){if(!(82<=RED.view.calculateTextWidth(d,"red-ui-palette-label"))){s=d;break}for(var c=d.length;0<c;c--){var u=d.substring(0,c);if(RED.view.calculateTextWidth(u,"red-ui-palette-label")<82){a.push(u),d=d.substring(c);break}}}}}a.push(s);var p=a.join("<br/>"),f=8+20*a.length;e.css({height:f+"px"}),e.find(".red-ui-palette-label").html(p).attr("dir",RED.text.bidi.resolveBaseTextDir(p)),e.find(".red-ui-palette-port").css({top:f/2-5+"px"});try{var h,g,m,v="<p><b>"+RED.text.bidi.enforceTextDirectionWithUCC(o)+"</b></p>",b=((h=$("<div></div>").append($(v+(n||RED.nodes.getNodeHelp(t)||"<p>"+RED._("palette.noInfo")+"</p>").trim()).filter(function(e){return 1==this.nodeType&&"P"==this.nodeName||3==this.nodeType&&0<this.textContent.trim().length}).slice(0,2))).find("a").each(function(){var e=$(this).text();$(this).before(e),$(this).remove()}),RED.nodes.getType(t));b&&(g="",b&&!/^subflow:/.test(t)&&(g=b.set.module+" : "),g+=t,/^subflow:/.test(t)&&$('<button type="button" onclick="RED.workspaces.show(\''+t.substring(8).replace(/'/g,"\\'")+'\'); return false;" class="red-ui-button red-ui-button-small" style="float: right; margin-left: 5px;"><i class="fa fa-pencil"></i></button>').appendTo(h),m=t.replace(/'/g,"\\'"),$('<button type="button" onclick="RED.search.show(\'type:'+m+'\'); return false;" class="red-ui-button red-ui-button-small" style="float: right; margin-left: 5px;"><i class="fa fa-search"></i></button>').appendTo(h),$('<button type="button" onclick="RED.sidebar.help.show(\''+m+'\'); return false;" class="red-ui-button red-ui-button-small" style="float: right; margin-left: 5px;"><i class="fa fa-book"></i></button>').appendTo(h),$("<p>",{style:"font-size: 0.8em"}).text(g).appendTo(h))}catch(e){console.log("Error generating pop-over label for ",t),console.log(e.toString()),h="<p><b>"+o+"</b></p><p>"+RED._("palette.noInfo")+"</p>"}e.data("popover").setContent(h)}function _(e){return $(".red-ui-palette-node[data-palette-type='"+e+"']")}function k(e){return e.replace(/[\x00-\x2c\x2e-\x2f\x3a-\x40\x5b-\x60\x7b-\x7f]/g,"_")}function a(o,n){var e,t,i,a,s,r,p,f,h,g,m,d,l,c,v,b,u,y;_(o).length||(u=n.category,-1===w.indexOf(u)&&(t=(e=k(u)).split("-")[0],i=$("<div>",{class:"red-ui-palette-node"}).attr("data-palette-type",o).data("category",t),a=RED.utils.getPaletteLabel(o,n),$("<div/>",{class:"red-ui-palette-label"+(!n.align&&0!==n.inputs&&0===n.outputs||"right"===n.align?" red-ui-palette-label-right":"")}).appendTo(i),n.icon&&(s=RED.utils.getNodeIcon(n),(y=$("<div/>",{class:"red-ui-palette-icon-container"+(!n.align&&0!==n.inputs&&0===n.outputs||"right"===n.align?" red-ui-palette-icon-container-right":"")}).appendTo(i)).attr("data-palette-icon",s),RED.utils.createIconElement(s,y,!0)),i.css("backgroundColor",RED.utils.getNodeColor(o,n)),0<n.outputs&&((s=document.createElement("div")).className="red-ui-palette-port red-ui-palette-port-output",i.append(s)),0<n.inputs&&((y=document.createElement("div")).className="red-ui-palette-port red-ui-palette-port-input",i.append(y)),R(u,t,e,-1!==E.indexOf(t)?"node-red":n.set.id),$("#red-ui-palette-"+e).append(i),i.on("mousedown",function(e){e.preventDefault()}),s=RED.popover.create({target:i,trigger:"hover",interactive:!0,width:"300px",content:"hi",delay:{show:750,hide:50}}),i.data("popover",s),r=$("#red-ui-workspace-chart"),p=$("#red-ui-workspace-chart>svg").get(0),$(i).draggable({helper:"clone",appendTo:"#red-ui-editor",revert:"invalid",revertDuration:200,containment:"#red-ui-main-container",start:function(){v=$("#red-ui-palette").width(),b=$("#red-ui-palette").parent().position().top+$("#red-ui-palette-container").position().top,c=null,(l=RED.view.getActiveGroup())&&document.getElementById("group_select_"+l.id).classList.add("red-ui-flow-group-active-hovered"),RED.view.focus()},stop:function(){d3.select(".red-ui-flow-link-splice").classed("red-ui-flow-link-splice",!1),c&&document.getElementById("group_select_"+c.id).classList.remove("red-ui-flow-group-hovered"),l&&document.getElementById("group_select_"+l.id).classList.remove("red-ui-flow-group-active-hovered"),m&&(clearTimeout(m),m=null),d&&(clearTimeout(d),d=null)},drag:function(e,u){var t=_(o);u.originalPosition.left=t.offset().left,h=u.position.left-v+u.helper.width()/2+r.scrollLeft(),g=u.position.top-b+u.helper.height()/2+r.scrollTop()+10,d=d||setTimeout(function(){var e=h/RED.view.scale(),t=g/RED.view.scale(),e=RED.view.getGroupAtPoint(e,t);e!==c&&(c&&document.getElementById("group_select_"+c.id).classList.remove("red-ui-flow-group-hovered"),e&&document.getElementById("group_select_"+e.id).classList.add("red-ui-flow-group-hovered"),(c=e)?$(u.helper).data("group",c):$(u.helper).removeData("group")),d=null},200),0<n.inputs&&0<n.outputs&&(m=m||setTimeout(function(){for(var e,t=[],o=1/0,n=null,t=p.getIntersectionList?((e=p.createSVGRect()).x=h,e.y=g,e.width=1,e.height=1,p.getIntersectionList(e,p)):RED.view.getLinksAtPoint(h,g),i=h/RED.view.scale(),a=g/RED.view.scale(),s=0;s<t.length;s++){var r=d3.select(t[s]);if(r.classed("red-ui-flow-link-background")&&!r.classed("red-ui-flow-link-link"))for(var d=t[s].getTotalLength(),l=0;l<d;l+=10){var c=t[s].getPointAtLength(l),c=(c.x-i)*(c.x-i)+(c.y-a)*(c.y-a);c<200&&c<o&&(o=c,n=t[s])}}f&&f!==n&&d3.select(f.parentNode).classed("red-ui-flow-link-splice",!1),n?d3.select(n.parentNode).classed("red-ui-flow-link-splice",!0):d3.select(".red-ui-flow-link-splice").classed("red-ui-flow-link-splice",!1),f!==n&&(n?$(u.helper).data("splice",d3.select(n).data()[0]):$(u.helper).removeData("splice")),f=n,m=null},200))}}),y=null,0===o.indexOf("subflow:")&&(i.on("dblclick",function(e){RED.workspaces.show(o.substring(8)),e.preventDefault()}),u=RED.nodes.subflow(o.substring(8)),y=RED.utils.renderMarkdown(u.info||"")),x(o,i,a,y),1===$("#red-ui-palette-container-"+t).find(".red-ui-palette-node").length&&D[t].open()))}function s(e){var e=_(e),t=e.closest(".red-ui-palette-category");e.remove(),0===t.find(".red-ui-palette-node").length&&t.find("i").hasClass("expanded")&&(t.find(".red-ui-palette-content").slideToggle(),t.find("i").toggleClass("expanded"))}function r(e){for(var e=_(e),e=(e.hide(),e.closest(".red-ui-palette-category")),t=e.find(".red-ui-palette-node"),o=0,n=0;n<t.length;n++)"none"===$(t[n]).css("display")&&(o+=1);o===t.length&&e.hide()}function d(e){e=_(e);e.closest(".red-ui-palette-category").show(),e.show()}function l(e){var t=_("subflow:"+e.id),o=t.find(".red-ui-palette-port-input"),n=t.find(".red-ui-palette-port-output");t.find(".red-ui-palette-label").attr("class","red-ui-palette-label"+(!e._def.align&&0!==e.in.length&&0===e.out.length||"right"===e._def.align?" red-ui-palette-label-right":""));t.find(".red-ui-palette-icon-container").attr("class","red-ui-palette-icon-container"+(!e._def.align&&0!==e.in.length&&0===e.out.length||"right"===e._def.align?" red-ui-palette-icon-container-right":"")),0===o.length&&0<e.in.length?((a=document.createElement("div")).className="red-ui-palette-port red-ui-palette-port-input",t.append(a)):0!==o.length&&0===e.in.length&&o.remove(),0===n.length&&0<e.out.length?((a=document.createElement("div")).className="red-ui-palette-port red-ui-palette-port-output",t.append(a)):0!==n.length&&0===e.out.length&&n.remove();var i,o=t.attr("data-palette-label"),a=t.attr("data-palette-info"),a=(o===e.name&&a===e.info||(t.attr("data-palette-info",e.info),x(e.type+":"+e.id,t,e.name,RED.utils.renderMarkdown(e.info||""))),n=t,o=e,o=RED.utils.getNodeIcon(o._def),(n=n.find(".red-ui-palette-icon-container")).attr("data-palette-icon")!==o&&(n.attr("data-palette-icon",o),RED.utils.createIconElement(o,n,!0)),t.data("category")),o=e.category||"subflows";a!==o&&(R(o,n=k(o),n,"node-red"),a=t.closest(".red-ui-palette-category"),(i=$("#red-ui-palette-"+n)).append(t),1===i.find(".red-ui-palette-node").length&&D[n].open(),t.data("category",o),0===a.find(".red-ui-palette-node").length&&a.find("i").hasClass("expanded")&&(a.find(".red-ui-palette-content").slideToggle(),a.find("i").toggleClass("expanded"))),t.css("backgroundColor",e.color)}return{init:function(){$('<img src="red/images/spin.svg" class="red-ui-palette-spinner hide"/>').appendTo("#red-ui-palette"),$('<div id="red-ui-palette-search" class="red-ui-palette-search hide"><input type="text" data-i18n="[placeholder]palette.filter"></input></div>').appendTo("#red-ui-palette"),$('<div id="red-ui-palette-container" class="red-ui-palette-scroll hide"></div>').appendTo("#red-ui-palette"),$('<div class="red-ui-component-footer"></div>').appendTo("#red-ui-palette"),$('<div id="red-ui-palette-shade" class="hide"></div>').appendTo("#red-ui-palette"),$("#red-ui-palette > .red-ui-palette-spinner").show(),RED.events.on("registry:node-type-added",function(e){var t=RED.nodes.getType(e);a(e,t),t.onpaletteadd&&"function"==typeof t.onpaletteadd&&t.onpaletteadd.call(t)}),RED.events.on("registry:node-type-removed",function(e){s(e)}),RED.events.on("registry:node-set-enabled",function(e){for(var t=0;t<e.types.length;t++){d(e.types[t]);var o=RED.nodes.getType(e.types[t]);o&&o.onpaletteadd&&"function"==typeof o.onpaletteadd&&o.onpaletteadd.call(o)}}),RED.events.on("registry:node-set-disabled",function(e){for(var t=0;t<e.types.length;t++){r(e.types[t]);var o=RED.nodes.getType(e.types[t]);o&&o.onpaletteremove&&"function"==typeof o.onpaletteremove&&o.onpaletteremove.call(o)}}),RED.events.on("registry:node-set-removed",function(e){if(e.added)for(var t=0;t<e.types.length;t++){s(e.types[t]);var o=RED.nodes.getType(e.types[t]);o&&o.onpaletteremove&&"function"==typeof o.onpaletteremove&&o.onpaletteremove.call(o)}}),RED.events.on("subflows:change",l),$("#red-ui-palette-search input").searchBox({delay:100,change:function(){var e,n=$(this).val(),i=new RegExp(n.replace(/[-\/\\^$*+?.()|[\]{}]/g,"\\$&"),"i");for(e in $("#red-ui-palette-container .red-ui-palette-node").each(function(e,t){var o=$(t).attr("data-palette-label"),t=$(t).attr("data-palette-type");""===n||i.test(t)||i.test(o)?$(this).show():$(this).hide()}),D)D.hasOwnProperty(e)&&(0===D[e].container.find(".red-ui-palette-node").filter(function(){return"none"!==$(this).css("display")}).length?(D[e].close(),D[e].container.slideUp()):(D[e].open(),D[e].container.show()))}}),n=$('<div class="red-ui-sidebar-control-left"><i class="fa fa-chevron-left"></i></div>').appendTo($("#red-ui-palette")),RED.popover.tooltip(n,RED._("keyboard.togglePalette"),"core:toggle-palette"),n.on("click",function(){RED.menu.toggleSelected("menu-item-palette")}),$("#red-ui-palette").on("mouseenter",function(){n.toggle("slide",{direction:"left"},200)}),$("#red-ui-palette").on("mouseleave",function(){n.stop(!1,!0),n.hide()});var e=[],t=(RED.settings.paletteCategories?e=RED.settings.paletteCategories:RED.settings.theme("palette.categories")&&(e=RED.settings.theme("palette.categories")),Array.isArray(e)||(e=[]),{}),e=(e.forEach(function(e){t[e]=!0,i(e,k(e),"palette.label."+k(e))}),E.forEach(function(e){t[e]||i(e,k(e),"palette.label."+k(e))}),$('<span class="button-group"></span>').appendTo("#red-ui-palette .red-ui-component-footer")),o=$('<button type="button" class="red-ui-footer-button"><i class="fa fa-angle-double-up"></i></button>').appendTo(e);o.on("click",function(e){for(var t in e.preventDefault(),D)D.hasOwnProperty(t)&&D[t].close()}),RED.popover.tooltip(o,RED._("palette.actions.collapse-all")),(o=$('<button type="button" class="red-ui-footer-button"><i class="fa fa-angle-double-down"></i></button>').appendTo(e)).on("click",function(e){for(var t in e.preventDefault(),D)D.hasOwnProperty(t)&&D[t].open()}),RED.popover.tooltip(o,RED._("palette.actions.expand-all")),RED.actions.add("core:toggle-palette",function(e){void 0===e?RED.menu.toggleSelected("menu-item-palette"):(e?($("#red-ui-main-container").removeClass("red-ui-palette-closed"),n.find("i").removeClass("fa-chevron-right").addClass("fa-chevron-left")):($("#red-ui-main-container").addClass("red-ui-palette-closed"),n.hide(),n.find("i").addClass("fa-chevron-right").removeClass("fa-chevron-left")),setTimeout(function(){$(window).trigger("resize")},200))})},add:a,remove:s,hide:r,show:d,refresh:function(){RED.nodes.eachSubflow(l)},getCategories:function(){var o=[];return $("#red-ui-palette-container .red-ui-palette-category").each(function(e,t){o.push({id:$(t).data("category"),label:$(t).data("label")})}),o}}}(),RED.sidebar.info=function(){var n,i,w,a,E,D,R,x,_,s,r,k={property:!1};function d(){var e;i&&(e=$(n).parent().height()-s.outerHeight(),i.resize(e))}function l(){RED.sidebar.show("info")}function o(e){if(void 0===e)T();else{$(w).empty();var t=$('<table class="red-ui-info-table"></table>').appendTo(w),o=$("<tbody>").appendTo(t);if(null===e)RED.sidebar.info.outliner.select(null),E.empty(),D.text(""),R.hide(),x.hide();else if(Array.isArray(e)){RED.sidebar.info.outliner.select(e),E.empty(),RED.utils.createNodeIcon({type:"_selection_"}).appendTo(E),D.text("Selection"),R.hide(),x.hide(),_=null;var n={nodes:0,flows:0,subflows:0,groups:0},i=(e.forEach(function(e){"tab"===e.type?(n.flows++,n.nodes+=RED.nodes.filterNodes({z:e.id}).length):"subflow"===e.type?n.subflows++:"group"===e.type?n.groups++:n.nodes++}),r=$('<tr class="red-ui-help-info-row"><td>'+RED._("sidebar.info.selection")+"</td><td></td></tr>").appendTo(o),$("<div>").appendTo($(r.children()[1])));0<n.flows&&$("<div>").text(RED._("clipboard.flow",{count:n.flows})).appendTo(i),0<n.subflows&&$("<div>").text(RED._("clipboard.subflow",{count:n.subflows})).appendTo(i),0<n.nodes&&$("<div>").text(RED._("clipboard.node",{count:n.nodes})).appendTo(i),0<n.groups&&$("<div>").text(RED._("clipboard.group",{count:n.groups})).appendTo(i)}else{RED.sidebar.info.outliner.select(e);var t=/^subflow(:(.+))?$/.exec(e.type),a=(t&&((y=t[2]?RED.nodes.subflow(t[2]):e).id,b=y.instances.length),E.empty(),RED.utils.createNodeIcon(e).appendTo(E),RED.utils.getNodeLabel(e,e.type+": "+e.id)),s=a.indexOf("\\n"),s=(-1<s&&(a=a.substring(0,s)+"..."),D.text(a),R.show(),_=e,r=$('<tr class="red-ui-help-info-row"><td></td><td></td></tr>').appendTo(o),"node");if("subflow"===e.type||t?s="subflow":"tab"===e.type?s="flow":"group"===e.type&&(s="group"),$(r.children()[0]).text(RED._("sidebar.info."+s)),RED.utils.createObjectElement(e.id,{sourceId:e.id}).appendTo(r.children()[1]),"tab"===e.type||"subflow"===e.type)x.hide();else if("group"===e.type){x.hide();var r=$('<tr class="red-ui-help-info-row"><td>&nbsp;</td><td></td></tr>').appendTo(o),d={nodes:0,groups:0},i=(RED.group.getNodes(e,!0).forEach(function(e){"group"===e.type?d.groups++:d.nodes++}),$("<div>").appendTo($(r.children()[1])));0<d.nodes&&$("<div>").text(RED._("clipboard.node",{count:d.nodes})).appendTo(i),0<d.groups&&$("<div>").text(RED._("clipboard.group",{count:d.groups})).appendTo(i)}else if("junction"===e.type)x.hide();else{x.show(),t||(r=$('<tr class="red-ui-help-info-row"><td>'+RED._("sidebar.info.type")+"</td><td></td></tr>").appendTo(o),$(r.children()[1]).text(("unknown"===e.type?e._orig:e).type),"unknown"===e.type&&$('<span style="float: right; font-size: 0.8em"><i class="fa fa-warning"></i></span>').prependTo($(r.children()[1])));var l=0;if(!t&&"subflow"!=e.type&&"group"!=e.type){var c,u,p,f,h,g,m,a=$('<tr class="red-ui-help-property-expand blank"><td colspan="2"></td></tr>').appendTo(o);if("unknown"===e.type?(c={},Object.keys(e._orig).forEach(function(e){"type"!==e&&(c[e]={})})):e._def&&(c=e._def.defaults,r=$('<tr class="red-ui-help-info-property-row'+(k.property?"":" hide")+'"><td>'+RED._("sidebar.info.module")+"</td><td></td></tr>").appendTo(o),$(r.children()[1]).text(RED.nodes.getType(e.type).set.module),l++),c)for(var v in c)"name"!=v&&"info"!=v&&c.hasOwnProperty(v)&&(u=e[v],l++,r=$('<tr class="red-ui-help-info-property-row'+(k.property?"":" hide")+'"><td></td><td></td></tr>').appendTo(o),$(r.children()[0]).text(v),c[v].type&&!c[v]._type.array?(p=RED.nodes.node(u))?(v=RED.utils.getNodeLabel(p,u),f=r.children()[1],h=$("<span>",{class:""}).appendTo(f),h=$("<div>",{class:"red-ui-palette-node red-ui-palette-node-small"}).appendTo(h),m=RED.utils.getNodeColor(p.type,p._def),g=RED.utils.getNodeIcon(p._def),h.css({backgroundColor:m,cursor:"pointer"}),m=$("<div/>",{class:"red-ui-palette-icon-container"}).appendTo(h),$("<div/>",{class:"red-ui-palette-icon",style:"background-image: url("+g+")"}).appendTo(m),$("<span></span>").css({verticalAlign:"top",marginLeft:"6px"}).text(v).appendTo(f),h.on("dblclick",function(){RED.editor.editConfig("",p.type,p.id)})):RED.utils.createObjectElement(void 0).appendTo(r.children()[1]):RED.utils.createObjectElement(u,{sourceId:e.id}).appendTo(r.children()[1]));0<l&&$('<a href="#" class="node-info-property-header'+(k.property?" expanded":"")+'"><span class="red-ui-help-property-more">'+RED._("sidebar.info.showMore")+'</span><span class="red-ui-help-property-less">'+RED._("sidebar.info.showLess")+'</span> <i class="fa fa-caret-down"></i></a>').appendTo(a.children()[0])}"tab"!==e.type&&t&&($('<tr class="blank"><th colspan="2">'+RED._("sidebar.info.subflow")+"</th></tr>").appendTo(o),$('<tr class="node-info-subflow-row"><td>'+RED._("common.label.name")+'</td><td><span class="red-ui-text-bidi-aware" dir="'+RED.text.bidi.resolveBaseTextDir(y.name)+'">'+RED.utils.sanitize(y.name)+"</span></td></tr>").appendTo(o))}t&&(r=$('<tr class="red-ui-help-info-row"><td>'+RED._("subflow.category")+"</td><td></td></tr>").appendTo(o),s=y.category||"subflows",$(r.children()[1]).text(RED._("palette.label."+s,{defaultValue:s})),$('<tr class="node-info-subflow-row"><td>'+RED._("sidebar.info.instances")+"</td><td>"+b+"</td></tr>").appendTo(o),y.meta&&(r=$('<tr class="red-ui-help-info-row"><td>'+RED._("subflow.module")+"</td><td></td></tr>").appendTo(o),$(r.children()[1]).text(y.meta.module||""),r=$('<tr class="red-ui-help-info-row"><td>'+RED._("subflow.version")+"</td><td></td></tr>").appendTo(o),$(r.children()[1]).text(y.meta.version||"")));var i="",s=(e._def&&e._def.info&&(t="function"==typeof(a=e._def.info)?a.call(e):a,i+=RED.utils.renderMarkdown(t)),e.info&&(i+=RED.utils.renderMarkdown(e.info||"")),$("<div>").css("padding","0 6px 6px").appendTo(w)),b=i,y=s;(b=function(e){return $(e).find("a").each(function(e){var t=$(this).attr("href");/^https?:/.test(t)&&$(this).attr("target","_blank")}),e}($('<div class="red-ui-help"><span class="red-ui-text-bidi-aware" dir="'+RED.text.bidi.resolveBaseTextDir(b)+'">'+b+"</span></div>")).appendTo(y)).find(".red-ui-text-bidi-aware").contents().filter(function(){return 3===this.nodeType&&""!==this.textContent.trim()}).wrap("<span></span>"),b.find("H3").wrapInner('<a class="red-ui-help-info-header expanded" href="#"></a>').find("a").prepend('<i class="fa fa-angle-right">').on("click",function(e){e.preventDefault();for(var t=$(this).hasClass("expanded"),o=$(this).parent().next();1===o.length&&"H3"!==o[0].nodeName;)o.toggle(!t),o=o.next();$(this).toggleClass("expanded",!t)}),$(".red-ui-sidebar-info-stack").scrollTop(0),$(".node-info-property-header").on("click",function(e){e.preventDefault(),k.property=!k.property,$(this).toggleClass("expanded",k.property),$(".red-ui-help-info-property-row").toggle(k.property)})}}}t=!0,p=15e3,f=-1,RED.actions.add("core:toggle-show-tips",function(e){void 0===e?RED.userSettings.toggle("view-show-tips"):((t=e)?m:v)()});var c,u,t,p,f,h={start:m,stop:v,next:function(){clearInterval(u),c=!0,e()},enabled:function(){return t}};function e(){for(var e,t=Math.floor(Math.random()*f),o=RED._("infotips:info.tip"+t);e=/({{(.*?)}})/.exec(o);){var n=RED.keyboard.getShortcut(e[2]);if(!n)return;o=o.replace(e[1],RED.keyboard.formatKey(n.key))}for(;e=/(\[([a-z]*?)\])/.exec(o);)o=o.replace(e[1],RED.keyboard.formatKey(e[2]));r.html(o).fadeIn(200),c&&(c=null,u=setInterval(g,p))}function g(){r.fadeOut(300,function(){e()})}function m(){if($(".red-ui-sidebar-info").addClass("show-tips"),d(),t&&!c&&!u){if(-1===f)for(;f++,RED._("infotips:info.tip"+f)!=="info.tip"+f;);c=setTimeout(e,1e3)}}function v(){$(".red-ui-sidebar-info").removeClass("show-tips"),d(),clearInterval(u),clearTimeout(c),c=u=null}function T(e){var t;(e=void 0===e?RED.view.selection():e).nodes?1==e.nodes.length?"subflow"===(t=e.nodes[0]).type&&t.direction?o(RED.nodes.subflow(t.z)):o(t):o(e.nodes):e.flows||e.subflows?o(e.flows):(t=RED.workspaces.active(),(e=RED.nodes.workspace(t)||RED.nodes.subflow(t))?o(e):(t=RED.nodes.workspace(RED.workspaces.active()))&&t.info?o(t):o(null))}return RED.events.on("view:selection-changed",T),{init:function(){(n=document.createElement("div")).className="red-ui-sidebar-info",RED.actions.add("core:show-info-tab",l);var e=$("<div>",{class:"red-ui-sidebar-info-stack"}).appendTo(n),t=$("<div>").css({overflow:"hidden",height:"calc(70%)"}).appendTo(e),o=$("<div>").css({overflow:"hidden",height:"100%",display:"flex","flex-direction":"column"}).appendTo(e),o=(a=$("<div>",{class:"red-ui-palette-header red-ui-info-header"}).css({flex:"0 0 auto"}).appendTo(o),E=$("<span>").appendTo(a),D=$("<span>").appendTo(a),x=$('<button class="red-ui-button red-ui-button-small"><i class="fa fa-book"></button>').css({position:"absolute",top:"12px",right:"32px"}).on("click",function(e){e.preventDefault(),e.stopPropagation(),_&&RED.sidebar.help.show(_.type)}).appendTo(a),RED.popover.tooltip(x,RED._("sidebar.help.showHelp")),R=$('<button class="red-ui-button red-ui-button-small"><i class="fa fa-search"></button>').css({position:"absolute",top:"12px",right:"8px"}).on("click",function(e){e.preventDefault(),e.stopPropagation(),_&&(RED.sidebar.info.outliner.reveal(_),RED.view.reveal(_.id))}).appendTo(a),RED.popover.tooltip(R,RED._("sidebar.help.showInOutline")),w=$("<div>").css({flex:"1 1 auto","overflow-y":"auto"}).appendTo(o),(i=RED.panels.create({container:e})).ratio(.6),RED.sidebar.info.outliner.build().appendTo(t),RED.sidebar.addTab({id:"info",label:RED._("sidebar.info.label"),name:RED._("sidebar.info.name"),iconClass:"fa fa-info",action:"core:show-info-tab",content:n,pinned:!0,enableOnEdit:!0}),RED.events.on("sidebar:resize",d),$(window).on("resize",d),$(window).on("focus",d),s=$('<div class="red-ui-help-tips"></div>').appendTo(n),r=$('<div class="red-ui-help-tip"></div>').appendTo(s),$('<div class="red-ui-help-tips-buttons"></div>').appendTo(s));$('<a href="#" class="red-ui-footer-button"><i class="fa fa-refresh"></a>').appendTo(o).on("click",function(e){e.preventDefault(),h.next()}),$('<a href="#" class="red-ui-footer-button"><i class="fa fa-times"></a>').appendTo(o).on("click",function(e){e.preventDefault(),RED.actions.invoke("core:toggle-show-tips"),RED.notify(RED._("sidebar.info.showTips"))}),h.enabled()?h.start():h.stop()},show:l,refresh:o,clear:function(){o(null)},set:function(e,t){console.warn("Deprecated use of RED.sidebar.info.set - use RED.sidebar.help.set instead"),RED.sidebar.help.set(e,t)}}}(),RED.sidebar.info.outliner=function(){var a,o,s,n,i,r,t,d,l={},c={};function u(){var e=[{label:RED._("menu.label.flows"),expanded:!0,children:[]},{id:"__subflow__",label:RED._("menu.label.subflows"),children:[f("__subflow__")]},{id:"__global__",flow:"__global__",label:RED._("sidebar.info.globalConfig"),types:{},children:[f("__global__")]}];return r=e[0],t=e[1],d={__global__:e[2]},e}var e,p={};function f(e){var t={empty:!0,element:$('<div class="red-ui-info-outline-item red-ui-info-outline-item-empty">').text(RED._("sidebar.info.empty"))};return p[e]=t}function h(e){var t=$("<div>",{class:"red-ui-node-list-item red-ui-info-outline-item"});return RED.utils.createNodeIcon(e,!0).appendTo(t),t.find(".red-ui-node-label").addClass("red-ui-info-outline-item-label"),g(e,t),t}function g(t,o){var e,n=$("<div>",{class:"red-ui-info-outline-item-controls red-ui-info-outline-item-hover-controls"}).appendTo(o);"subflow"===t.type&&$('<button type="button" class="red-ui-info-outline-item-control-users red-ui-button red-ui-button-small"><i class="fa fa-toggle-right"></i></button>').text(t.instances.length).appendTo(n).on("click",function(e){e.preventDefault(),e.stopPropagation(),RED.search.show("type:subflow:"+t.id)}),"config"===t._def.category&&"group"!==t.type&&(e=$('<button type="button" class="red-ui-info-outline-item-control-users red-ui-button red-ui-button-small"><i class="fa fa-toggle-right"></i></button>').text(t.users.length).appendTo(n).on("click",function(e){e.preventDefault(),e.stopPropagation(),RED.search.show("uses:"+t.id)}),RED.popover.tooltip(e,function(){return RED._("editor.nodesUse",{count:t.users.length})})),t._def.button&&(e=$('<button type="button" class="red-ui-info-outline-item-control-action red-ui-button red-ui-button-small"><i class="fa fa-toggle-right"></i></button>').appendTo(n).on("click",function(e){e.preventDefault(),e.stopPropagation(),RED.view.clickNodeButton(t)}),RED.popover.tooltip(e,RED._("sidebar.info.triggerAction"))),"tab"===t.type&&$('<button type="button" class="red-ui-info-outline-item-control-hide red-ui-button red-ui-button-small"><i class="fa fa-eye"></i><i class="fa fa-eye-slash"></i></button>').appendTo(n).on("click",function(e){e.preventDefault(),e.stopPropagation();e=!o.hasClass("red-ui-info-outline-item-hidden");o.toggleClass("red-ui-info-outline-item-hidden",e),e?RED.workspaces.hide(t.id):RED.workspaces.show(t.id,null,!0)}),"subflow"!==t.type?(e=$('<button type="button" class="red-ui-info-outline-item-control-disable red-ui-button red-ui-button-small"><i class="fa fa-circle-thin"></i><i class="fa fa-ban"></i></button>').appendTo(n).on("click",function(e){var o,n;e.preventDefault(),e.stopPropagation(),"tab"===t.type?t.disabled?RED.workspaces.enable(t.id):RED.workspaces.disable(t.id):"group"===t.type?(e=RED.group.getNodes(t,!0),o={t:"multi",events:[],dirty:RED.nodes.dirty()},e.forEach(function(e){var t;"group"!==e.type&&(void 0===n&&(n=!e.d),!!e.d!==n&&(t={t:"edit",node:e,changed:e.changed,changes:{d:e.d}},e.d?delete e.d:e.d=!0,e.dirty=!0,e.dirtyStatus=!0,e.changed=!0,RED.events.emit("nodes:change",e),o.events.push(t))),0<o.events.length&&(RED.history.push(o),RED.nodes.dirty(!0),RED.view.redraw())})):(e={t:"edit",node:t,changed:t.changed,changes:{d:t.d},dirty:RED.nodes.dirty()},t.d?delete t.d:t.d=!0,t.dirty=!0,t.dirtyStatus=!0,t.changed=!0,RED.events.emit("nodes:change",t),RED.history.push(e),RED.nodes.dirty(!0),RED.view.redraw())}),RED.popover.tooltip(e,function(){return"group"===t.type?RED._("common.label.enable")+" / "+RED._("common.label.disable"):RED._("common.label."+("tab"===t.type&&t.disabled||"tab"!==t.type&&t.d?"enable":"disable"))})):$('<div class="red-ui-info-outline-item-control-spacer">').appendTo(n),n.find("button").on("dblclick",function(e){e.preventDefault(),e.stopPropagation()})}function m(e){l={};var t,o=u();i.empty(),e=e,(t=$("<div>",{class:"red-ui-info-outline-item red-ui-info-outline-item-flow"})).css("width","calc(100% - 40px)"),$("<div>",{class:"red-ui-search-result-description red-ui-info-outline-item-label"}).appendTo(t).text(e.name),e=$("<div>",{class:"red-ui-info-outline-item-controls"}).appendTo(t),e=$('<button class="red-ui-button red-ui-button-small" style="position:absolute;right:5px;top: 3px;"><i class="fa fa-ellipsis-h"></i></button>').appendTo(e).on("click",function(e){e.preventDefault(),RED.projects.editProject()}),RED.popover.tooltip(e,RED._("sidebar.project.showProjectSettings")),t.appendTo(i),n.show(),a.treeList("data",o)}function v(){a.treeList("data",u())}function b(e){e=l[e.workspace];e&&e.element.removeClass("red-ui-info-outline-item-hidden")}function y(e){e=l[e.workspace];e&&e.element.addClass("red-ui-info-outline-item-hidden")}function w(e){var t,o,n,i,a;l[e.id]={id:e.id,element:(t=e,o=$("<div>",{class:"red-ui-info-outline-item red-ui-info-outline-item-flow"}),n=$("<div>",{class:"red-ui-search-result-description red-ui-info-outline-item-label"}).appendTo(o),i="string"==typeof t?t:t.label,-1<(a=i.indexOf("\\n"))&&(i=i.substring(0,a)+"..."),n.text(i),g(t,o),o),children:[],deferBuild:!0,icon:"red-ui-icons red-ui-icons-flow",gutter:T(e)},c[e.id]?(l[e.id].children=c[e.id],delete c[e.id]):l[e.id].children.push(f(e.id)),r.treeList.addChild(l[e.id]),l[e.id].element.toggleClass("red-ui-info-outline-item-disabled",!!e.disabled),l[e.id].treeList.container.toggleClass("red-ui-info-outline-item-disabled",!!e.disabled),L()}function E(e){var t=l[e.id],o=e.label||e.id,n=o.indexOf("\\n");-1<n&&(o=o.substring(0,n)+"..."),t.element.find(".red-ui-info-outline-item-label").text(o),t.element.toggleClass("red-ui-info-outline-item-disabled",!!e.disabled),t.treeList.container.toggleClass("red-ui-info-outline-item-disabled",!!e.disabled),L()}function D(e){var o={};e.forEach(function(e,t){o[e]=t}),r.treeList.sortChildren(function(e,t){return"__global__"===e.id?-1:"__global__"===t.id?1:o[e.id]-o[t.id]})}function R(e){l[e.id]={id:e.id,element:h(e),children:[],deferBuild:!0,gutter:T(e)},c[e.id]?(l[e.id].children=c[e.id],delete c[e.id]):l[e.id].children.push(f(e.id)),p.__subflow__&&(p.__subflow__.treeList.remove(),delete p.__subflow__),t.treeList.addChild(l[e.id]),L()}function x(t){l[t.id].treeList.replaceElement(h(t)),RED.nodes.eachNode(function(e){e.type=="subflow:"+t.id&&l[e.id].treeList.replaceElement(h(e))}),L()}function _(e){var t=l[e.id],o=e.g||e.z||"__global__",n=RED.utils.getNodeLabel(e,e.name||e.type+": "+e.id);n?t.element.find(".red-ui-info-outline-item-label").text(n):t.element.find(".red-ui-info-outline-item-label").html("&nbsp;"),o!==(t.parent.id||t.parent.parent.flow)&&(n=t.parent,t.treeList.remove(!0),0===n.children.length&&(n.config?(n.treeList.remove(),delete d[n.parent.id||n.parent.parent.id].types[e.type],0===n.parent.children.length&&("__global__"===n.parent.id?n.parent.treeList.addChild(f(n.parent.id)):(delete d[n.parent.parent.id],n.parent.treeList.remove(),0===n.parent.parent.children.length&&n.parent.parent.treeList.addChild(f(n.parent.parent.id))))):n.treeList.addChild(f(n.id))),"config"===e._def.category&&"group"!==e.type?(C(o,e.type),d[o].types[e.type].treeList.addChild(l[e.id])):(p[o]&&(p[o].treeList.remove(),delete p[o]),l[o].treeList.addChild(t))),t.element.toggleClass("red-ui-info-outline-item-disabled",!!e.d),"config"===e._def.category&&"group"!==e.type&&t.element.find(".red-ui-info-outline-item-control-users").text(e.users.length),L()}function k(e){var t=l[e.id],o=(t.treeList.remove(),delete l[e.id],/^subflow:/.test(e.type)&&(o=e.type.substring(8),l[o]&&l[o].element.find(".red-ui-info-outline-item-control-users").text(RED.nodes.subflow(o).instances.length)),p[e.id]&&delete p[e.id],t.parent);0===o.children.length&&(o.config?(o.treeList.remove(),delete d[o.parent.id||e.z].types[e.type],0===o.parent.children.length&&("__global__"===o.parent.id?o.parent.treeList.addChild(f(o.parent.id)):(delete d[e.z],o.parent.treeList.remove(),0===o.parent.parent.children.length&&o.parent.parent.treeList.addChild(f(o.parent.parent.id))))):o.treeList.addChild(f(o.id)))}function T(t){var e=$("<span>",{class:"red-ui-info-outline-gutter red-ui-treeList-gutter-float"}),o=$('<button type="button" class="red-ui-info-outline-item-control-reveal red-ui-button red-ui-button-small"><i class="fa fa-search"></i></button>').appendTo(e).on("click",function(e){e.preventDefault(),e.stopPropagation(),RED.view.reveal(t.id)});return RED.popover.tooltip(o,RED._("sidebar.info.find")),e}function C(e,t){p[e]&&(p[e].treeList.remove(),delete p[e]),d[e]||(d[e]={config:!0,flow:e,types:{},label:RED._("menu.label.displayConfig"),children:[]},l[e].treeList.insertChildAt(d[e],0)),d[e].types[t]||(d[e].types[t]={config:!0,label:t,children:[]},d[e].treeList.addChild(d[e].types[t]))}function j(e){l[e.id]={id:e.id,element:h(e),gutter:T(e)},"group"===e.type&&(l[e.id].children=[],l[e.id].deferBuild=!0,c[e.id]&&(l[e.id].children=c[e.id],delete c[e.id]));var t=e.g||e.z||"__global__";"config"!==e._def.category||"group"===e.type?l[t]?(p[t]&&(p[t].treeList.remove(),delete p[t]),l[t].treeList?l[t].treeList.addChild(l[e.id]):l[t].children.push(l[e.id])):(c[t]=c[t]||[],c[t].push(l[e.id])):(C(t,e.type),d[t].types[e.type].treeList.addChild(l[e.id])),l[e.id].element.toggleClass("red-ui-info-outline-item-disabled",!!e.d),/^subflow:/.test(e.type)&&(t=e.type.substring(8),l[t]&&l[t].element.find(".red-ui-info-outline-item-control-users").text(RED.nodes.subflow(t).instances.length)),L()}function L(){e&&clearTimeout(e),s&&(e=setTimeout(function(){o.searchBox("change")},100))}return{build:function(){var e=$("<div>",{class:"red-ui-info-outline"}).css({height:"100%"}),t=$("<div>",{class:"red-ui-sidebar-header red-ui-info-toolbar"}).appendTo(e);return o=$('<input type="text" data-i18n="[placeholder]menu.label.search">').appendTo(t).searchBox({style:"compact",delay:500,change:function(){var e=$(this).val(),t=RED.search.search(e);if(e){s=e;for(var o={},n=0,i=t.length;n<i;n++)o[t[n].node.id]=!0;a.treeList("filter",function(e){return 0===e.depth||e.id&&l[e.id]&&o[e.id]},!0)}else{s=null,a.treeList("filter",null);e=a.treeList("selected");e.id&&a.treeList("show",e.id)}},options:RED.search.getSearchOptions()}),n=$('<div class="red-ui-treeList-label red-ui-info-outline-project"><span class="red-ui-treeList-icon"><i class="fa fa-archive"></i></span></div>').hide().appendTo(e),i=$("<span>").appendTo(n),(a=$("<div>").css({width:"100%"}).appendTo(e).treeList({data:u()})).on("treelistselect",function(e,t){t=RED.nodes.node(t.id)||RED.nodes.group(t.id)||RED.nodes.workspace(t.id)||RED.nodes.subflow(t.id);t?RED.sidebar.info.refresh(t):RED.sidebar.info.refresh(null)}),a.on("treelistconfirm",function(e,t){t=RED.nodes.node(t.id);t&&("config"===t._def.category?RED.editor.editConfig("",t.type,t.id):RED.editor.edit(t))}),RED.events.on("projects:load",m),RED.events.on("flows:add",w),RED.events.on("flows:remove",k),RED.events.on("flows:change",E),RED.events.on("flows:reorder",D),RED.events.on("subflows:add",R),RED.events.on("subflows:remove",k),RED.events.on("subflows:change",x),RED.events.on("nodes:add",j),RED.events.on("nodes:remove",k),RED.events.on("nodes:change",_),RED.events.on("groups:add",j),RED.events.on("groups:remove",k),RED.events.on("groups:change",_),RED.events.on("workspace:show",b),RED.events.on("workspace:hide",y),RED.events.on("workspace:clear",v),e},search:function(e){o.searchBox("value",e)},select:function(e){e?Array.isArray(e)?a.treeList("select",e.map(function(e){return l[e.id]}),!1):a.treeList("select",l[e.id],!1):a.treeList("clearSelection")},reveal:function(e){a.treeList("show",l[e.id])}}}(),RED.sidebar.help=function(){var n,i,a,s,t,r,d,l;function c(){var e=$(n).parent().height()-i.outerHeight();s.resize(e)}function u(){l=l||setTimeout(function(){l=null;var a=RED.nodes.registry.getModuleList(),e=Object.keys(a),s=(e.sort(),{label:RED._("sidebar.help.nodeHelp"),children:[],expanded:!0}),t=RED.tourGuide.list().map(function(e){return{icon:"fa fa-play-circle-o",label:e.label,tour:e.path}}),t=[{label:"Node-RED",children:[{id:"changelog",label:RED._("sidebar.help.changeLog"),content:w},{label:RED._("tourGuide.welcomeTours"),children:t}]},s],o=RED.nodes.registry.getNodeTypes().filter(function(e){return/subflow/.test(e)});0<o.length&&(s.children.push({label:RED._("menu.label.subflows"),children:[]}),o.forEach(function(e){var t=RED.nodes.getType(e);s.children[0].children.push({id:"node-type:"+e,nodeType:e,subflowLabel:t.label().toLowerCase(),element:m({_def:t,type:t.label()})})})),e.forEach(function(e){var t=a[e];const o=[],n=t.sets,i=Object.keys(n);i.forEach(function(e){const t=n[e];t.types.forEach(function(e){if($("script[data-help-name='"+e+"']").length){const t={_def:RED.nodes.getType(e),type:e};t.name=g(t),o.push({id:"node-type:"+e,nodeType:e,palleteLabel:t.name,element:m(t)})}})}),0<o.length&&(o.sort(function(e,t){return e.nodeType.localeCompare(t.nodeType)}),s.children.push({id:e,icon:"fa fa-cube",label:e,children:o}))}),r.treeList("data",t)},500)}function p(e){var t=r.treeList("get","node-type:subflow:"+e.id);t.subflowLabel=e._def.label().toLowerCase(),t.treeList.replaceElement(m({_def:e._def,type:e._def.label()}))}function f(){var e=$("#red-ui-sidebar-help-show-toc");e.hasClass("selected")&&(e.removeClass("selected"),t=s.ratio(),d.css({transition:"height 0.2s"}),s.ratio(0),setTimeout(function(){d.css({transition:""})},250))}function h(){var e=$("#red-ui-sidebar-help-show-toc");e.hasClass("selected")||(e.addClass("selected"),d.css({transition:"height 0.2s"}),s.ratio(Math.max(.3,Math.min(t,.7))),setTimeout(function(){d.css({transition:""});var e=r.treeList("selected");e.id&&r.treeList("show",e)},250))}function g(e){let t=e.name;if(!t&&e._def&&e._def.paletteLabel)try{t=("function"==typeof e._def.paletteLabel?e._def.paletteLabel.call(e._def):e._def.paletteLabel)||""}catch(e){}return t||e.type}function m(e){var t=$("<div>",{class:"red-ui-node-list-item"}),o=RED.utils.createNodeIcon(e).appendTo(t);return $("<div>",{class:"red-ui-node-label"}).text(g(e)).appendTo(o),t}function v(t){a.empty();var e=/^subflow(:(.+))?$/.exec(t);if(e&&e[2])var e=RED.nodes.subflow(e[2]),o=RED.utils.renderMarkdown(e.info||"")||'<span class="red-ui-help-info-none">'+RED._("sidebar.info.none")+"</span>",n=e.name||t;else{o=RED.nodes.getNodeHelp(t)||'<span class="red-ui-help-info-none">'+RED._("sidebar.info.none")+"</span>";e=RED.nodes.registry.getNodeType(t);if("function"==typeof(n=e&&e.paletteLabel?e.paletteLabel:t))try{n=e.paletteLabel.call(e)}catch(e){n=t}}y(n,o),.7<s.ratio()&&s.ratio(.7),r.treeList("show","node-type:"+t),r.treeList("select","node-type:"+t,!1)}function b(e,t){!1!==t&&RED.sidebar.show("help"),e&&v(e),c()}function y(e,t){a.empty(),e&&$("<h1>",{class:"red-ui-help-title"}).text(e).appendTo(a);e=$('<div class="red-ui-help"><span class="red-ui-text-bidi-aware" dir="'+RED.text.bidi.resolveBaseTextDir(t)+'">'+t+"</span></div>"),$(e).find("a").each(function(e){var t=$(this).attr("href");/^https?:/.test(t)&&$(this).attr("target","_blank")});t=e.appendTo(a);t.find(".red-ui-text-bidi-aware").contents().filter(function(){return 3===this.nodeType&&""!==this.textContent.trim()}).wrap("<span></span>");t.find("H3").wrapInner('<a class="red-ui-help-info-header expanded" href="#"></a>').find("a").prepend('<i class="fa fa-angle-right">').on("click",function(e){e.preventDefault();for(var t=$(this).hasClass("expanded"),o=$(this).parent().next();1===o.length&&"H3"!==o[0].nodeName;)o.toggle(!t),o=o.next();$(this).toggleClass("expanded",!t)}),a.parent().scrollTop(0)}function w(a){$.get("red/about",function(i){i=RED.utils.sanitize(i),RED.tourGuide.load("./tours/welcome.js",function(e,t){var o,n='<div><img width="50px" src="red/images/node-red-icon.svg" /></div>';t&&(o=RED.settings.version.split("."),(t=t.version.split("."))[0]===o[0]&&t[1]===o[1]&&(n='<div><button type="button" onclick="RED.actions.invoke(\'core:show-welcome-tour\')" class="red-ui-button">'+RED._("tourGuide.takeATour")+"</button></div>")),a('<div style="text-align:center;">'+n+"</div>"+RED.utils.renderMarkdown(i))})})}return RED.events.on("view:selection-changed",function(e){!(e=void 0===e?RED.view.selection():e).nodes||1!=e.nodes.length||"subflow"===(e=e.nodes[0]).type&&e.direction||"group"!==e.type&&"junction"!==e.type&&v(e.type)}),RED.actions.add("core:show-about",function(){r.treeList("show","changelog"),r.treeList("select","changelog"),b()}),RED.actions.add("core:show-welcome-tour",function(o,n){n=n||function(){},RED.tourGuide.load("./tours/welcome.js",function(e,t){if(e)console.warn("Failed to load welcome tour",e),n();else{e=RED.settings.version.split("."),t=t.version.split(".");if(t[0]!==e[0]||t[1]!==e[1])n();else{if(o){if(o===RED.settings.version)return void n();t=o.split(".");if(e[0]<t[0]||e[0]===t[0]&&e[1]<t[1])return void n();if(e[0]===t[0]&&e[1]===t[1]){if(3===t.length&&3===e.length)return void n();if(4===e.length&&(3===t.length||e[3]<t[3]))return void n()}}RED.tourGuide.run("./tours/welcome.js",function(e){RED.settings.set("editor.tours.welcome",RED.settings.version),n()})}}})}),{init:function(){(n=document.createElement("div")).className="red-ui-sidebar-info",i=$("<div>",{class:"red-ui-sidebar-header red-ui-info-toolbar"}).appendTo(n),$('<span class="button-group"><a id="red-ui-sidebar-help-show-toc" class="red-ui-button red-ui-button-small selected" href="#"><i class="fa fa-list-ul"></i></a></span>').appendTo(i);var o,e=i.find("#red-ui-sidebar-help-show-toc"),e=(RED.popover.tooltip(e,RED._("sidebar.help.showTopics")),e.on("click",function(e){e.preventDefault(),($(this).hasClass("selected")?f:h)()}),$("<div>",{class:"red-ui-sidebar-help-stack"}).appendTo(n)),t=(d=$("<div>",{class:"red-ui-sidebar-help-toc"}).appendTo(e),$("<div>").css({"overflow-y":"auto"}).appendTo(e));(s=RED.panels.create({container:e})).ratio(.3),helpSearch=$('<input type="text" data-i18n="[placeholder]sidebar.help.search">').appendTo(i).searchBox({style:"compact",delay:100,change:function(){const t=$(this).val().toLowerCase();var e;t?(h(),r.treeList("filter",function(e){return 0===e.depth||(e.nodeType&&-1<e.nodeType.toLowerCase().indexOf(t)||e.subflowLabel&&-1<e.subflowLabel.toLowerCase().indexOf(t)||e.palleteLabel&&-1<e.palleteLabel.toLowerCase().indexOf(t))},!0)):(r.treeList("filter",null),(e=r.treeList("selected")).id&&r.treeList("show",e.id))}}),a=$("<div>",{class:"red-ui-help"}).css({padding:"6px"}).appendTo(t),$('<span class="red-ui-help-info-none">'+RED._("sidebar.help.noHelp")+"</span>").appendTo(a),(r=$("<div>").css({width:"100%"}).appendTo(d).treeList({data:[]})).on("treelistselect",function(e,t){(o=t).tour?RED.tourGuide.run(t.tour):t.nodeType?v(t.nodeType):t.content&&(a.empty(),"string"==typeof t.content?y(t.label,t.content):"function"==typeof t.content&&(0===t.content.length?y(t.label,t.content()):(y(t.label,'<div class="red-ui-component-spinner red-ui-component-spinner-contain"><img src="red/images/spin.svg" /></div>'),t.content(function(e){o===t&&(a.empty(),y(t.label,e))}))))}),RED.sidebar.addTab({id:"help",label:RED._("sidebar.help.label"),name:RED._("sidebar.help.name"),iconClass:"fa fa-book",action:"core:show-help-tab",content:n,pinned:!0,enableOnEdit:!0,onchange:function(){c()}}),$(window).on("resize",c),$(window).on("focus",c),RED.events.on("registry:node-type-added",u),RED.events.on("registry:node-type-removed",u),RED.events.on("subflows:change",p),RED.actions.add("core:show-help-tab",b)},show:b,set:function(e,t){$(a).empty(),y(t,e),f(),b()}}}(),RED.sidebar.config=function(){let r,d;var l=document.createElement("div"),e=(l.className="red-ui-sidebar-node-config",l.id="red-ui-sidebar-node-config",l.tabIndex=0,$('<div class="red-ui-sidebar-header"><span class="button-group"><a class="red-ui-sidebar-header-button-toggle selected" id="red-ui-sidebar-config-filter-all" href="#"><span data-i18n="sidebar.config.filterAll"></span></a><a class="red-ui-sidebar-header-button-toggle" id="red-ui-sidebar-config-filter-unused" href="#"><span data-i18n="sidebar.config.filterUnused"></span></a> </span></div>').appendTo(l),$('<div><a class="red-ui-footer-button" id="red-ui-sidebar-config-collapse-all" href="#"><i class="fa fa-angle-double-up"></i></a> <a class="red-ui-footer-button" id="red-ui-sidebar-config-expand-all" href="#"><i class="fa fa-angle-double-down"></i></a></div>')),i=$("<div>").appendTo(l),a=$("<div>").appendTo(l),s=$("<div>").appendTo(l),n=!1,c={};function u(e,t,o){var n,i,a;return e=e.replace(/\./i,"-"),c[e]?c[e].label!==o&&(c[e].list.parent().find(".red-ui-palette-node-config-label").text(o),c[e].label=o):(t=$('<div class="red-ui-palette-category red-ui-sidebar-config-category" id="red-ui-sidebar-config-category-'+e+'"></div>').appendTo(t),n=$('<div class="red-ui-sidebar-config-tray-header red-ui-palette-header"><i class="fa fa-angle-down expanded"></i></div>').appendTo(t),(o?$('<span class="red-ui-palette-node-config-label"/>').text(o):$('<span class="red-ui-palette-node-config-label" data-i18n="sidebar.config.'+e+'">')).appendTo(n),$('<span class="red-ui-sidebar-node-config-filter-info"></span>').appendTo(n),(category=$('<ul class="red-ui-palette-content red-ui-sidebar-node-config-list"></ul>').appendTo(t)).on("click",function(e){$(l).find(".red-ui-palette-node").removeClass("selected")}),t.i18n(),i=n.find("i"),a={label:o,list:category,size:function(){return a.list.find("li:not(.red-ui-palette-node-config-none)").length},open:function(e){i.hasClass("expanded")||(i.addClass("expanded"),e?a.list.show():a.list.slideDown())},close:function(e){i.hasClass("expanded")&&(i.removeClass("expanded"),e?a.list.hide():a.list.slideUp())},isOpen:function(){return i.hasClass("expanded")}},n.on("click",function(e){a.isOpen()?a.close():a.open()}),c[e]=a),c[e]}function p(e,t){var o,a,e=u(e.replace(/\./i,"-")),s=e.list;t.sort(function(e,t){return e.type<t.type?-1:e.type>t.type?1:0}),n?(o=t.length,0<(o-=(t=t.filter(function(e){return!1!==e._def.hasUsers&&0===e.users.length})).length)?s.parent().find(".red-ui-sidebar-node-config-filter-info").text(RED._("sidebar.config.filtered",{count:o})).show():s.parent().find(".red-ui-sidebar-node-config-filter-info").hide()):s.parent().find(".red-ui-sidebar-node-config-filter-info").hide(),s.empty(),0===t.length?($('<li class="red-ui-palette-node-config-none" data-i18n="sidebar.config.none">NONE</li>').i18n().appendTo(s),e.close(!0)):(a="",t.forEach(function(t){var e=RED.utils.getNodeLabel(t,t.id),o=(t.type!=a&&($('<li class="red-ui-palette-node-config-type">'+t.type+"</li>").appendTo(s),a=t.type),$('<li class="red-ui-palette-node_id_'+t.id.replace(/\./g,"-")+'"></li>').appendTo(s)),n=$('<div class="red-ui-palette-node-config red-ui-palette-node"></div>').appendTo(o),e=(o.data("node",t.id),n.data("node",t.id),$('<div class="red-ui-palette-label"></div>').text(e).appendTo(n)),i=(t.d&&(n.addClass("red-ui-palette-node-config-disabled"),$('<i class="fa fa-ban"></i>').prependTo(e)),!1!==t._def.hasUsers&&(o=$("<div/>",{class:"red-ui-palette-icon-container red-ui-palette-icon-container-right"}).appendTo(n),0===t.users.length?o.text(0):$('<a href="#"/>').on("click",function(e){e.stopPropagation(),e.preventDefault(),RED.search.show(t.id)}).text(t.users.length).appendTo(o),RED.popover.tooltip(o,RED._("editor.nodesUse",{count:t.users.length})),0===t.users.length&&n.addClass("red-ui-palette-node-config-unused")),n.on("click",function(e){e.stopPropagation(),RED.view.select(!1),e.metaKey?$(this).toggleClass("selected"):($(l).find(".red-ui-palette-node").removeClass("selected"),$(this).addClass("selected")),RED.sidebar.info.refresh(t)}),n.on("dblclick",function(e){e.stopPropagation(),RED.editor.editConfig("",t.type,t.id)}),t.users.map(function(e){return e.id}));n.on("mouseover",function(e){RED.nodes.eachNode(function(e){-1!=i.indexOf(e.id)&&(e.highlighted=!0,e.dirty=!0)}),RED.view.redraw()}),n.on("mouseout",function(e){RED.nodes.eachNode(function(e){e.highlighted&&(e.highlighted=!1,e.dirty=!0)}),RED.view.redraw()})}),e.open(!0))}function t(){var e,t={global:!0},o=(u("global",i),RED.nodes.eachWorkspace(function(e){t[e.id.replace(/\./g,"-")]=!0,u(e.id,a,e.label)}),RED.nodes.eachSubflow(function(e){t[e.id.replace(/\./g,"-")]=!0,u(e.id,s,e.name)}),$(".red-ui-sidebar-config-category").each(function(){var e=$(this).attr("id").substring("red-ui-sidebar-config-category-".length);t[e]||($(this).remove(),delete c[e])}),[]),n={};for(e in RED.nodes.eachConfig(function(e){e.z?(n[e.z.replace(/\./g,"-")]=n[e.z.replace(/\./g,"-")]||[],n[e.z.replace(/\./g,"-")].push(e)):e.z||o.push(e)}),t)t.hasOwnProperty(e)&&p(e,n[e]||[]);p("global",o)}return{init:function(){RED.sidebar.addTab({id:"config",label:RED._("sidebar.config.label"),name:RED._("sidebar.config.name"),content:l,toolbar:e,iconClass:"fa fa-cog",action:"core:show-config-tab",onchange:function(){t()}}),RED.actions.add("core:show-config-tab",function(){RED.sidebar.show("config")}),RED.actions.add("core:select-all-config-nodes",function(){$(l).find(".red-ui-palette-node").addClass("selected")}),RED.actions.add("core:delete-config-selection",function(){var a,e=[];$(l).find(".red-ui-palette-node.selected").each(function(){e.push($(this).parent().data("node"))}),0<e.length&&(a={t:"delete",nodes:[],changes:{},dirty:RED.nodes.dirty()},e.forEach(function(e){var t=RED.nodes.node(e);try{t._def.oneditdelete&&t._def.oneditdelete.call(t)}catch(e){console.log("oneditdelete",t.id,t.type,e.toString())}a.nodes.push(t);for(var o=0;o<t.users.length;o++){var n,i=t.users[o];for(n in a.changes[i.id]={changed:i.changed,valid:i.valid},i._def.defaults)i._def.defaults.hasOwnProperty(n)&&i[n]==e&&(a.changes[i.id][n]=e,i[n]="",i.changed=!0,i.dirty=!0);RED.editor.validateNode(i)}RED.nodes.remove(e)}),RED.nodes.dirty(!0),RED.view.redraw(!0),RED.history.push(a))}),RED.events.on("view:selection-changed",function(){$(l).find(".red-ui-palette-node").removeClass("selected")}),$("#red-ui-sidebar-config-collapse-all").on("click",function(e){for(var t in e.preventDefault(),c)c.hasOwnProperty(t)&&c[t].close()}),$("#red-ui-sidebar-config-expand-all").on("click",function(e){for(var t in e.preventDefault(),c)c.hasOwnProperty(t)&&0<c[t].size()&&c[t].open()}),$("#red-ui-sidebar-config-filter-all").on("click",function(e){e.preventDefault(),n&&($(this).addClass("selected"),$("#red-ui-sidebar-config-filter-unused").removeClass("selected"),n=!n,t())}),$("#red-ui-sidebar-config-filter-unused").on("click",function(e){e.preventDefault(),n||($(this).addClass("selected"),$("#red-ui-sidebar-config-filter-all").removeClass("selected"),n=!n,t())}),RED.popover.tooltip($("#red-ui-sidebar-config-filter-all"),RED._("sidebar.config.showAllConfigNodes")),RED.popover.tooltip($("#red-ui-sidebar-config-filter-unused"),RED._("sidebar.config.showAllUnusedConfigNodes"))},show:function(s){"boolean"==typeof s&&(s?$("#red-ui-sidebar-config-filter-unused"):$("#red-ui-sidebar-config-filter-all")).trigger("click"),t(),"string"==typeof s&&($("#red-ui-sidebar-config-filter-all").trigger("click"),s=s.replace(/\./g,"-"),setTimeout(function(){var t,e=$(".red-ui-palette-node_id_"+s),o=e.position().top,n=e.height(),i=$(".red-ui-sidebar-node-config"),a=i.height();a<o+n?i.animate({scrollTop:"-="+(a-(o+n)-30)},150):o<0&&i.animate({scrollTop:"+="+(o-10)},150),t=e,r&&r.length&&(clearInterval(d),d=null,r.children("div").removeClass("highlighted"),r=null),t&&t.children("div").length&&(d=setInterval(function(e){e>=Date.now()?(e=t.children("div").hasClass("highlighted"),t.children("div").toggleClass("highlighted",!e)):(clearInterval(d),d=null,r=null,t.children("div").removeClass("highlighted"))},100,Date.now()+2200),(r=t).children("div").addClass("highlighted"))},100)),RED.sidebar.show("config")},refresh:t}}(),RED.sidebar.context=function(){var i,a,s,r,d,l,c,u,p;function f(e,t){u=e,t||r.prop("checked")?e?g(d,"context/node/"+e.id,e.id):g(d):($(d.table).empty(),(e?$('<tr class="red-ui-help-info-row red-ui-search-empty blank" colspan="2"><td data-i18n="sidebar.context.refresh"></td></tr>'):$('<tr class="red-ui-help-info-row red-ui-search-empty blank" colspan="2"><td data-i18n="sidebar.context.none"></td></tr>')).appendTo(d.table).i18n(),d.timestamp.html("&nbsp;"))}function h(e,t){p=e,t||s.prop("checked")?e?g(l,"context/flow/"+e.id,e.id):g(l):($(l.table).empty(),$('<tr class="red-ui-help-info-row red-ui-search-empty blank" colspan="2"><td data-i18n="sidebar.context.refresh"></td></tr>').appendTo(l.table).i18n(),l.timestamp.html("&nbsp;"))}function g(e,t,o){var a,p,f,h,g,n=e.table;o?(a=e,p=t,f=o,h=RED.settings.context.stores,g=a.table,$.getJSON(p,function(e){$(g).empty();var t,o={};for(t in e)if(e.hasOwnProperty(t))for(var n in e[t])e[t].hasOwnProperty(n)&&(o.hasOwnProperty(n)||(o[n]=[]),e[t][n].store=t,o[n].push(e[t][n]));for(var c=Object.keys(o),i=(c.sort(),c.length),u=0;u<i;u++)o[c[u]].forEach(function(i){var a=c[u],s=(o[a].length,$('<tr class="red-ui-help-info-row"><td class="red-ui-sidebar-context-property"></td><td></td></tr>').appendTo(g)),r=($(s.children()[0]).text(a),$('<span class="button-group"></span>')),e=$('<button class="red-ui-button red-ui-button-small"><i class="fa fa-refresh"></i></button>').appendTo(r).on("click",function(e){e.preventDefault(),e.stopPropagation(),$.getJSON(p+"/"+a+"?store="+i.store,function(e){e.msg===d&&e.format===l||(d=e.msg,l=e.format,r.detach(),$(s.children()[1]).empty(),RED.utils.createObjectElement(RED.utils.decodeObject(d,l),{typeHint:e.format,sourceId:f+"."+a,tools:r,path:""}).appendTo(s.children()[1]))})}),e=(RED.popover.tooltip(e,RED._("sidebar.context.refrsh")),$('<button class="red-ui-button red-ui-button-small"><i class="fa fa-trash"></i></button>').appendTo(r).on("click",function(e){e.preventDefault(),e.stopPropagation();var n=RED.popover.create({trigger:"modal",target:s,direction:"left",content:function(){var e=$("<div>"),t=($('<p data-i18n="sidebar.context.deleteConfirm"></p>').appendTo(e),$("<p>").appendTo(e)),o=$('<span class="button-group"></span>').appendTo(t);return $('<button class="red-ui-button" data-i18n="common.label.cancel"></button>').appendTo(o).on("click",function(e){e.preventDefault(),n.close()}),o=$('<span class="button-group"></span>').appendTo(t),$('<button class="red-ui-button primary" data-i18n="common.label.delete"></button>').appendTo(o).on("click",function(e){e.preventDefault(),n.close(),$.ajax({url:p+"/"+a+"?store="+i.store,type:"DELETE"}).done(function(e,t,o){$.getJSON(p+"/"+a+"?store="+i.store,function(e){"undefined"===e.format?(s.remove(),0===g.children().length&&$('<tr class="red-ui-help-info-row red-ui-search-empty blank" colspan="2"><td data-i18n="sidebar.context.empty"></td></tr>').appendTo(g).i18n()):(d=e.msg,l=e.format,r.detach(),$(s.children()[1]).empty(),RED.utils.createObjectElement(RED.utils.decodeObject(d,l),{typeHint:e.format,sourceId:f+"."+a,tools:r,path:""}).appendTo(s.children()[1]))})}).fail(function(e,t,o){})}),e.i18n()}});n.open()})),d=(RED.popover.tooltip(e,RED._("sidebar.context.delete")),i.msg),l=i.format;RED.utils.createObjectElement(RED.utils.decodeObject(d,l),{typeHint:i.format,sourceId:f+"."+a,tools:r,path:""}).appendTo(s.children()[1]),1<h.length&&$("<span>",{class:"red-ui-sidebar-context-property-storename"}).text(i.store).appendTo($(s.children()[0]))});0===i&&$('<tr class="red-ui-help-info-row red-ui-search-empty blank" colspan="2"><td data-i18n="sidebar.context.empty"></td></tr>').appendTo(g).i18n(),$(a.timestamp).text((new Date).toLocaleString())})):($(n).empty(),$('<tr class="red-ui-help-info-row red-ui-search-empty blank" colspan="2"><td data-i18n="sidebar.context.none"></td></tr>').appendTo(n).i18n())}function m(){RED.sidebar.show("context")}return{init:function(){(i=$("<div>").css({position:"relative",height:"100%"})).className="red-ui-sidebar-context";var e=$("<div></div>"),t=$("<div>",{class:"red-ui-sidebar-context-stack"}).appendTo(i),t=(a=RED.stack.create({container:t}),(d=a.add({title:RED._("sidebar.context.node"),collapsible:!0})).expand(),d.content.css({height:"100%"}),d.timestamp=$('<div class="red-ui-sidebar-context-updated">&nbsp;</div>').appendTo(d.content),$('<table class="red-ui-info-table"></table>').appendTo(d.content)),o=(d.table=$("<tbody>").appendTo(t),$('<div style="float: right"></div>').appendTo(d.header)),n=RED.settings.get("editor.context.nodeRefresh",!1),n=(r=$('<input type="checkbox">').prop("checked",n).appendTo(o).toggleButton({baseClass:"red-ui-sidebar-header-button red-ui-button-small",enabledLabel:"",disabledLabel:""}).on("change",function(){var e=$(this).prop("checked");RED.settings.set("editor.context.flowRefresh",e)}),RED.popover.tooltip(r.next(),RED._("sidebar.context.autoRefresh")),$('<button class="red-ui-button red-ui-button-small" style="margin-left: 5px"><i class="fa fa-refresh"></i></button>').appendTo(o).on("click",function(e){e.stopPropagation(),e.preventDefault(),f(u,!0)})),t=(RED.popover.tooltip(n,RED._("sidebar.context.refrsh")),(l=a.add({title:RED._("sidebar.context.flow"),collapsible:!0})).expand(),l.content.css({height:"100%"}),l.timestamp=$('<div class="red-ui-sidebar-context-updated">&nbsp;</div>').appendTo(l.content),$('<table class="red-ui-info-table"></table>').appendTo(l.content)),n=(l.table=$("<tbody>").appendTo(t),o=$('<div style="float: right"></div>').appendTo(l.header),RED.settings.get("editor.context.flowRefresh",!1)),n=(s=$('<input type="checkbox">').prop("checked",n).appendTo(o).toggleButton({baseClass:"red-ui-sidebar-header-button red-ui-button-small",enabledLabel:"",disabledLabel:""}).on("change",function(){var e=$(this).prop("checked");RED.settings.set("editor.context.flowRefresh",e)}),RED.popover.tooltip(s.next(),RED._("sidebar.context.autoRefresh")),$('<button class="red-ui-button red-ui-button-small" style="margin-left: 5px"><i class="fa fa-refresh"></i></button>').appendTo(o).on("click",function(e){e.stopPropagation(),e.preventDefault(),h(p,!0)})),t=(RED.popover.tooltip(n,RED._("sidebar.context.refrsh")),(c=a.add({title:RED._("sidebar.context.global"),collapsible:!0})).expand(),c.content.css({height:"100%"}),c.timestamp=$('<div class="red-ui-sidebar-context-updated">&nbsp;</div>').appendTo(c.content),$('<table class="red-ui-info-table"></table>').appendTo(c.content));c.table=$("<tbody>").appendTo(t),o=$('<div style="float: right"></div>').appendTo(c.header),$('<button class="red-ui-button red-ui-button-small"><i class="fa fa-refresh"></i></button>').appendTo(o).on("click",function(e){e.stopPropagation(),e.preventDefault(),g(c,"context/global","global")}),RED.popover.tooltip(o,RED._("sidebar.context.refrsh")),RED.actions.add("core:show-context-tab",m),RED.sidebar.addTab({id:"context",label:RED._("sidebar.context.label"),name:RED._("sidebar.context.name"),iconClass:"fa fa-database",content:i,toolbar:e,enableOnEdit:!0,action:"core:show-context-tab"}),RED.events.on("view:selection-changed",function(e){f(e.nodes&&1===e.nodes.length&&e.nodes[0])}),RED.events.on("workspace:change",function(e){h(RED.nodes.workspace(e.workspace))}),$(c.table).empty(),$('<tr class="red-ui-help-info-row red-ui-search-empty blank" colspan="2"><td data-i18n="sidebar.context.refresh"></td></tr>').appendTo(c.table).i18n(),c.timestamp.html("&nbsp;")}}}(),RED.palette.editor=function(){var l,c,u,y,p,i,f=[],h=[],w={},E={},D={},t={},g="",n=/^(\d+)(\.(\d+))?(\.(\d+))?(-([0-9A-Za-z-]+))?(\.([0-9A-Za-z-.]+))?$/,z=/^\d+$/;function o(e){this.number=0,this.text=e,z.test(e)?(this.number=parseInt(e),this.type="N"):this.type=null==e||e.length<1?"E":"T"}function R(e){e=e.match(n);this.parts=[new o(e[1]),new o(e[3]),new o(e[5]),new o(e[7]),new o(e[9])]}function s(e,t){e=(e=Date.now()-e)<300?300:0;setTimeout(function(){t()},e)}function m(e,t,n,i){n.show();var a=Date.now();$.ajax({url:"nodes/"+e,type:"PUT",data:JSON.stringify({enabled:t}),contentType:"application/json; charset=utf-8"}).done(function(e,t,o){s(a,function(){n.hide(),i()})}).fail(function(e,t,o){s(a,function(){n.hide(),i(e)})})}function v(e,t,o,n){e={module:e};t&&(e.version=t),o&&(e.url=o),$.ajax({url:"nodes",type:"POST",data:JSON.stringify(e),contentType:"application/json; charset=utf-8"}).done(function(e,t,o){n()}).fail(function(e,t,o){n(e)})}function b(e){t.hasOwnProperty(e)||(t[e]=setTimeout(function(){delete t[e],a(e)},100))}function a(e){if(D.hasOwnProperty(e)){var t=D[e].info,o=D[e].elements;if(o){var n,i=0,a=0,s=0;for(n in o.errorList.empty(),D[e].totalUseCount=0,D[e].setUseCount={},t.sets)if(t.sets.hasOwnProperty(n)){var r,d=0,l=t.sets[n],c=o.sets[n];l.err&&(s++,r=l.err,l.err.message?r=l.err.message:l.err.code&&(r=l.err.code),$("<li>").text(r).appendTo(o.errorList)),l.enabled&&(i+=l.types.length),a+=l.types.length;for(var u=0;u<t.sets[n].types.length;u++){var p,f=t.sets[n].types[u],h=(d+=E[f]||0,c.swatches[f]);!l.enabled||(p=RED.nodes.getType(f))&&p.color&&(h.css({background:RED.utils.getNodeColor(f,p)}),h.css({border:"1px solid "+function(e){if(n=/^rgba?\(\s*(\d+),\s*(\d+),\s*(\d+)[,)]/.exec(e)){var t=parseInt(n[1]),o=parseInt(n[2]),n=parseInt(n[3]);if(160<(299*t+587*o+114*n)/1e3)return"rgb("+Math.floor(.8*t)+","+Math.floor(.8*o)+","+Math.floor(.8*n)+")"}return e}(h.css("backgroundColor"))}))}D[e].setUseCount[n]=d,D[e].totalUseCount+=d,0<d?(c.enableButton.text(RED._("palette.editor.inuse")),c.enableButton.addClass("disabled")):(c.enableButton.removeClass("disabled"),l.enabled?c.enableButton.text(RED._("palette.editor.disable")):c.enableButton.text(RED._("palette.editor.enable"))),c.setRow.toggleClass("red-ui-palette-module-set-disabled",!l.enabled)}0===s?o.errorRow.hide():o.errorRow.show(),o.setCount.text(RED._("palette.editor.nodeCount",{count:a,label:i===a?a:i+" / "+a})),0<D[e].totalUseCount?(o.enableButton.text(RED._("palette.editor.inuse")),o.enableButton.addClass("disabled"),o.removeButton.hide()):(o.enableButton.removeClass("disabled"),t.local&&o.removeButton.css("display","inline-block"),0===i?o.enableButton.text(RED._("palette.editor.enableall")):o.enableButton.text(RED._("palette.editor.disableall")),o.container.toggleClass("disabled",0===i))}t.pending_version?(o.versionSpan.html(t.version+' <i class="fa fa-long-arrow-right"></i> '+t.pending_version).appendTo(o.metaRow),o.updateButton.text(RED._("palette.editor.updated")).addClass("disabled").css("display","inline-block")):w.hasOwnProperty(e)&&N&&(v=w[e].version,b=t.version,v=new R(v),b=new R(b),0<v.compare(b))&&RED.utils.checkModuleAllowed(e,null,P,A)?(o.updateButton.show(),o.updateButton.text(RED._("palette.editor.update",{version:w[e].version}))):o.updateButton.hide()}else{D[e]={info:RED.nodes.registry.getModule(e)};var g,m=[e];for(g in D[e].info.sets)D[e].info.sets.hasOwnProperty(g)&&(m.push(g),m=m.concat(D[e].info.sets[g].types));D[e].index=m.join(",").toLowerCase(),y.editableList("addItem",D[e])}var v,b}o.prototype.compare=function(e){switch(this.type+e.type){case"EE":return 0;case"NT":case"TE":case"EN":return-1;case"NN":return this.number-e.number;case"TT":return this.text.localeCompare(e.text);case"ET":case"TN":case"NE":return 1}};var r,d=[],x=!(R.prototype.compare=function(e){for(var t=0,o=0,n=this.parts.length;0==t&&o<n;o++)t=this.parts[o].compare(e.parts[o]);return t}),_=j;function k(e,t,o,n){d.push(e||n),e?x=!0:(n.modules&&(n.modules=n.modules.filter(function(e){return!!RED.utils.checkModuleAllowed(e.id,e.version,O,I)&&((w[e.id]=e).index=[e.id],e.keywords&&(e.index=e.index.concat(e.keywords)),e.types&&(e.index=e.index.concat(e.types)),e.updated_at?e.timestamp=new Date(e.updated_at).getTime():e.timestamp=0,e.index=e.index.join(",").toLowerCase(),!0)}),f=f.concat(n.modules)),u.searchBox("count",f.length)),1<i&&$(".red-ui-palette-module-shade-status").html(RED._("palette.editor.loading")+"<br>"+d.length+"/"+i),d.length===i&&(x&&RED.notify(RED._("palette.editor.errors.catalogLoadFailed",{url:t}),"error",!1,8e3),e=250-(Date.now()-r),setTimeout(function(){$("#red-ui-palette-module-install-shade").hide()},Math.max(e,0)))}function T(){var e,t;0===f.length&&(f=[],w={},p.editableList("empty"),$(".red-ui-palette-module-shade-status").text(RED._("palette.editor.loading")),e=RED.settings.theme("palette.catalogues")||["https://catalogue.nodered.org/catalogue.json"],x=!(d=[]),i=e.length,1<e.length&&$(".red-ui-palette-module-shade-status").html(RED._("palette.editor.loading")+"<br>0/"+e.length),$("#red-ui-palette-module-install-shade").show(),r=Date.now(),t=0,e.forEach(function(n,e){$.getJSON(n,{_:(new Date).getTime()},function(e){for(var t in k(null,n,0,e),D)D.hasOwnProperty(t)&&a(t)}).fail(function(e,t,o){console.warn("Error loading catalog",n,":",o),k(e,n)}).always(function(){++t===i&&u.searchBox("change")})}))}function C(){if(p.editableList("empty"),""===u.searchBox("value").trim())p.editableList("addItem",{count:f.length});else{h.sort(_);for(var e=0;e<Math.min(10,h.length);e++)p.editableList("addItem",h[e]);0===h.length&&p.editableList("addItem",{}),10<h.length&&p.editableList("addItem",{start:10,more:h.length-10})}}function j(e,t){var o=u.searchBox("value").trim();if(""===o)return L(e,t);o=e.info.index.indexOf(o)-t.info.index.indexOf(o);return 0==o?L(e,t):o}function L(e,t){return e.info.id.localeCompare(t.info.id)}function B(e,t){return-1*(e.info.timestamp-t.info.timestamp)}var S,O=["*"],I=[],N=!0,P=["*"],A=[];function G(){return T(),l.activateTab("nodes"),S}function M(n,t,i){var e,a;!1===RED.settings.get("externalModules.palette.allowInstall",!0)?i(new Error("Palette not editable")):(e=[{text:RED._("common.label.cancel"),click:function(){a.close()}}],n.url&&e.push({text:RED._("palette.editor.confirm.button.review"),class:"primary red-ui-palette-module-install-confirm-button-install",click:function(){var e=n.url||"";window.open(e)}}),e.push({text:RED._("palette.editor.confirm.button.install"),class:"primary red-ui-palette-module-install-confirm-button-install",click:function(){var o=RED.utils.addSpinnerOverlay(t,!0),e=$('<div style="position: relative;bottom: calc(50% + 17px); padding-right: 10px;text-align: right;"></div>').appendTo(o);$('<button class="red-ui-button"></button>').text(RED._("eventLog.view")).appendTo(e).on("click",function(e){e.preventDefault(),RED.actions.invoke("core:show-event-log")}),RED.eventLog.startEvent(RED._("palette.editor.confirm.button.install")+" : "+n.id+" "+n.version),v(n.id,n.version,n.pkg_url,function(e){var t;o.remove(),e&&e.responseJSON&&(t=RED.notify(RED._("palette.editor.errors.installFailed",{module:n.id,message:e.responseJSON.message}),{type:"error",modal:!0,fixed:!0,buttons:[{text:RED._("common.label.close"),click:function(){t.close()}},{text:RED._("eventLog.view"),click:function(){t.close(),RED.actions.invoke("core:show-event-log")}}]})),i(e)}),a.close()}}),a=RED.notify(RED._("palette.editor.confirm.install.body",{module:n.id}),{modal:!0,fixed:!0,buttons:e}))}return{init:function(){var a,s,t,o,e,n,i,r,d;!1!==RED.settings.get("externalModules.palette.allowInstall",!0)&&(n=RED.settings.get("externalModules.palette.allowList"),e=RED.settings.get("externalModules.palette.denyList"),(n||e)&&(O=n,I=e),O=RED.utils.parseModuleList(O),I=RED.utils.parseModuleList(I),n=RED.settings.get("externalModules.palette.allowUpdateList"),e=RED.settings.get("externalModules.palette.denyUpdateList"),(n||e)&&(P=n,A=e),P=RED.utils.parseModuleList(P),A=RED.utils.parseModuleList(A),N=RED.settings.get("externalModules.palette.allowUpdate",!0),S=$('<div id="red-ui-settings-tab-palette"></div>'),o=$('<div id="red-ui-palette-editor"><ul id="red-ui-palette-editor-tabs"></ul></div>').appendTo(S),l=RED.tabs.create({element:S.find("#red-ui-palette-editor-tabs"),onchange:function(e){o.find(".red-ui-palette-editor-tab").hide(),e.content.show(),c&&c.searchBox("value",""),u&&u.searchBox("value",""),"install"===e.id?u&&u.trigger("focus"):c&&c.trigger("focus")},minimumActiveTabWidth:110}),n=o,n=$("<div>",{class:"red-ui-palette-editor-tab"}).appendTo(n),l.addTab({id:"nodes",label:RED._("palette.editor.tab-nodes"),content:n}),e=$("<div>",{class:"red-ui-palette-search"}).appendTo(n),c=$('<input type="text" data-i18n="[placeholder]palette.filter"></input>').appendTo(e).searchBox({delay:200,change:function(){var e,t,o;e=$(this).val(),g=e.toLowerCase(),t=y.editableList("filter"),o=y.editableList("length"),""===e?c.searchBox("count"):c.searchBox("count",t+" / "+o)}}),y=$("<ol>",{id:"red-ui-palette-module-list",style:"position: absolute;top: 35px;bottom: 0;left: 0;right: 0px;"}).appendTo(n).editableList({addButton:!1,scrollOnAdd:!1,sort:function(e,t){return e.info.name.localeCompare(t.info.name)},filter:function(e){return""===g||(""===g||-1<e.index.indexOf(g))},addItem:function(o,e,s){var t,n,i,a,r,d,l,c,u,p,f=s.info;f?(l=$("<div>",{class:"red-ui-palette-module-header"}).appendTo(o),t=$('<div class="red-ui-palette-module-meta red-ui-palette-module-name"><i class="fa fa-cube"></i></div>').appendTo(l),$("<span>").text(f.name).appendTo(t),t=$('<div class="red-ui-palette-module-meta red-ui-palette-module-version"><i class="fa fa-tag"></i></div>').appendTo(l),t=$("<span>").text(f.version).appendTo(t),n=$('<div class="red-ui-palette-module-meta red-ui-palette-module-errors"><i class="fa fa-warning"></i></div>').hide().appendTo(l),i=$('<ul class="red-ui-palette-module-error-list"></ul>').appendTo(n),l=$("<div>",{class:"red-ui-palette-module-meta"}).appendTo(l),a=$('<a href="#" class="red-ui-button red-ui-button-small red-ui-palette-module-set-button"><i class="fa fa-angle-right red-ui-palette-module-node-chevron"></i> </a>').appendTo(l),r=$("<span>").appendTo(a),l=$("<div>",{class:"red-ui-palette-module-button-group"}).appendTo(l),(p=$('<a href="#" class="red-ui-button red-ui-button-small"></a>').text(RED._("palette.editor.update")).appendTo(l)).attr("id","up_"+Math.floor(1e9*Math.random())),p.on("click",function(e){var n,t,i,a,s,r;e.preventDefault(),$(this).hasClass("disabled")||(t=w[(n=f).name].version,i=w[f.name].pkg_url,a=o,!(s=function(e){})===RED.settings.get("externalModules.palette.allowInstall",!0)?s(new Error("Palette not editable")):r=RED.notify(RED._("palette.editor.confirm.update.body",{module:n.name}),{modal:!0,fixed:!0,buttons:[{text:RED._("common.label.cancel"),click:function(){r.close()}},{text:RED._("palette.editor.confirm.button.update"),class:"primary red-ui-palette-module-install-confirm-button-update",click:function(){var o=RED.utils.addSpinnerOverlay(a,!0),e=$('<div style="position: relative;bottom: calc(50% + 17px); padding-right: 10px;text-align: right;"></div>').appendTo(o);$('<button class="red-ui-button"></button>').text(RED._("eventLog.view")).appendTo(e).on("click",function(e){e.preventDefault(),RED.actions.invoke("core:show-event-log")}),RED.eventLog.startEvent(RED._("palette.editor.confirm.button.install")+" : "+n.name+" "+t),v(n.name,t,i,function(e){var t;o.remove(),e&&e.responseJSON&&(t=RED.notify(RED._("palette.editor.errors.updateFailed",{module:n.name,message:e.responseJSON.message}),{type:"error",modal:!0,fixed:!0,buttons:[{text:RED._("common.label.close"),click:function(){t.close()}},{text:RED._("eventLog.view"),click:function(){t.close(),RED.actions.invoke("core:show-event-log")}}]})),s(e)}),r.close()}}]}))}),(d=$('<a href="#" class="red-ui-button red-ui-button-small"></a>').text(RED._("palette.editor.remove")).appendTo(l)).attr("id","up_"+Math.floor(1e9*Math.random())),d.on("click",function(e){var i,t,a;e.preventDefault(),i=f,t=o,!(e=function(e){})===RED.settings.get("externalModules.palette.allowInstall",!0)?e(new Error("Palette not editable")):a=RED.notify(RED._("palette.editor.confirm.remove.body",{module:i.name}),{modal:!0,fixed:!0,buttons:[{text:RED._("common.label.cancel"),click:function(){a.close()}},{text:RED._("palette.editor.confirm.button.remove"),class:"primary red-ui-palette-module-install-confirm-button-remove",click:function(){var n,o=RED.utils.addSpinnerOverlay(t,!0),e=$('<div style="position: relative;bottom: calc(50% + 17px); padding-right: 10px;text-align: right;"></div>').appendTo(o);$('<button class="red-ui-button"></button>').text(RED._("eventLog.view")).appendTo(e).on("click",function(e){e.preventDefault(),RED.actions.invoke("core:show-event-log")}),RED.eventLog.startEvent(RED._("palette.editor.confirm.button.remove")+" : "+i.name),e=i.name,n=function(e){var t;o.remove(),e&&e.responseJSON&&(t=RED.notify(RED._("palette.editor.errors.removeFailed",{module:i.name,message:e.responseJSON.message}),{type:"error",modal:!0,fixed:!0,buttons:[{text:RED._("common.label.close"),click:function(){t.close()}},{text:RED._("eventLog.view"),click:function(){t.close(),RED.actions.invoke("core:show-event-log")}}]}))},$.ajax({url:"nodes/"+e,type:"DELETE"}).done(function(e,t,o){n()}).fail(function(e,t,o){n(e)}),a.close()}}]})}),f.local||d.hide(),l=$('<a href="#" class="red-ui-button red-ui-button-small"></a>').text(RED._("palette.editor.disableall")).appendTo(l),c=$("<div>",{class:"red-ui-palette-module-content"}).appendTo(o),u=$('<div class="red-ui-palette-module-shade hide"><img src="red/images/spin.svg" class="red-ui-palette-spinner"/></div>').appendTo(o),s.elements={updateButton:p,removeButton:d,enableButton:l,errorRow:n,errorList:i,setCount:r,container:o,shade:u,versionSpan:t,sets:{}},a.on("click",function(e){e.preventDefault(),o.hasClass("expanded")?(o.removeClass("expanded"),c.slideUp()):(o.addClass("expanded"),c.slideDown())}),(p=Object.keys(f.sets)).sort(function(e,t){return e.toLowerCase().localeCompare(t.toLowerCase())}),p.forEach(function(o){var n=f.sets[o],i=$("<div>",{class:"red-ui-palette-module-set"}).appendTo(c),e=$("<div>",{class:"red-ui-palette-module-set-button-group"}).appendTo(i),a={},e=(n.types.forEach(function(e){var t=$("<div>",{class:"red-ui-palette-module-type"}).appendTo(i);a[e]=$("<span>",{class:"red-ui-palette-module-type-swatch"}).appendTo(t),$("<span>",{class:"red-ui-palette-module-type-node"}).text(e).appendTo(t)}),$('<a href="#" class="red-ui-button red-ui-button-small"></a>').appendTo(e));e.on("click",function(e){var t;e.preventDefault(),0===s.setUseCount[o]&&(e=RED.nodes.registry.getNodeSet(n.id),u.show(),t=!e.enabled,m(n.id,t,u,function(e){e&&e.responseJSON&&RED.notify(RED._("palette.editor.errors."+(t?"enable":"disable")+"Failed",{module:id,message:e.responseJSON.message}))}))}),s.elements.sets[n.name]={setRow:i,enableButton:e,swatches:a}}),l.on("click",function(e){e.preventDefault(),0===s.totalUseCount&&m(f.name,o.hasClass("disabled"),u,function(e){e&&e.responseJSON&&RED.notify(RED._("palette.editor.errors.installFailed",{module:id,message:e.responseJSON.message}))})}),b(f.name)):$("<div>",{class:"red-ui-search-empty"}).text(RED._("search.empty")).appendTo(o)}}),e=o,e=$("<div>",{class:"red-ui-palette-editor-tab hide"}).appendTo(e),l.addTab({id:"install",label:RED._("palette.editor.tab-install"),content:e}),n=$("<div>",{class:"red-ui-palette-editor-toolbar"}).appendTo(e),i=$("<div>",{class:"red-ui-palette-search"}).appendTo(e),u=$('<input type="text" data-i18n="[placeholder]palette.search"></input>').appendTo(i).searchBox({delay:300,change:function(){var t=$(this).val().trim().toLowerCase();0<t.length?(h=f.filter(function(e){return-1<e.index.indexOf(t)}).map(function(e){return{info:e}}),C(),u.searchBox("count",h.length+" / "+f.length)):(u.searchBox("count",f.length),p.editableList("empty"),p.editableList("addItem",{count:f.length}))}}),$("<span>").text(RED._("palette.editor.sort")+" ").appendTo(n),i=$('<span class="button-group"></span>').appendTo(n),r=$('<a href="#" class="red-ui-palette-editor-install-sort-option red-ui-sidebar-header-button-toggle selected"><i class="fa fa-sort-amount-desc"></i></a>').appendTo(i),d=$('<a href="#" class="red-ui-palette-editor-install-sort-option red-ui-sidebar-header-button-toggle" data-i18n="palette.editor.sortAZ"></a>').appendTo(i),i=$('<a href="#" class="red-ui-palette-editor-install-sort-option red-ui-sidebar-header-button-toggle" data-i18n="palette.editor.sortRecent"></a>').appendTo(i),[{button:r,func:j},{button:d,func:L},{button:i,func:B}].forEach(function(t){t.button.on("click",function(e){e.preventDefault(),$(this).hasClass("selected")||($(".red-ui-palette-editor-install-sort-option").removeClass("selected"),$(this).addClass("selected"),_=t.func,C())})}),r=$("<span>").appendTo(n),(d=$('<a href="#" class="red-ui-sidebar-header-button"><i class="fa fa-refresh"></i></a>').appendTo(r)).on("click",function(e){e.preventDefault(),f=[],w={},T()}),RED.popover.tooltip(d,RED._("palette.editor.refresh")),p=$("<ol>",{style:"position: absolute;top: 79px;bottom: 0;left: 0;right: 0px;"}).appendTo(e).editableList({addButton:!1,scrollOnAdd:!1,addItem:function(t,e,o){if(o.count)$("<div>",{class:"red-ui-search-empty"}).text(RED._("palette.editor.moduleCount",{count:o.count})).appendTo(t);else if(o.more)t.addClass("red-ui-palette-module-more"),i=$("<div>",{class:"red-ui-palette-module-header palette-module"}).appendTo(t),$('<a href="#"></a>').text(RED._("palette.editor.more",{count:o.more})).appendTo(i).on("click",function(e){e.preventDefault(),p.editableList("removeItem",o);for(var t=o.start;t<Math.min(o.start+10,o.start+o.more);t++)p.editableList("addItem",h[t]);10<o.more&&p.editableList("addItem",{start:o.start+10,more:o.more-10})});else if(o.info){var n=o.info,i=$("<div>",{class:"red-ui-palette-module-header"}).appendTo(t),a=$('<div class="red-ui-palette-module-meta red-ui-palette-module-name"><i class="fa fa-cube"></i></div>').appendTo(i),a=($("<span>").text(n.name||n.id).appendTo(a),$('<a target="_blank" class="red-ui-palette-module-link"><i class="fa fa-external-link"></i></a>').attr("href",n.url).appendTo(a),$('<div class="red-ui-palette-module-meta"></div>').appendTo(i)),a=($("<div>",{class:"red-ui-palette-module-description"}).text(n.description).appendTo(a),$('<div class="red-ui-palette-module-meta"></div>').appendTo(i)),s=($('<span class="red-ui-palette-module-version"><i class="fa fa-tag"></i> '+n.version+"</span>").appendTo(a),$('<span class="red-ui-palette-module-updated"><i class="fa fa-calendar"></i> '+function(e){if(new Date,new Date(e),(e=(Date.now()-new Date(e).getTime())/1e3)<60)return RED._("palette.editor.times.seconds");if((e=Math.floor(e/60))<10)return RED._("palette.editor.times.minutes");if(e<60)return RED._("palette.editor.times.minutesV",{count:e});if((e=Math.floor(e/60))<24)return RED._("palette.editor.times.hoursV",{count:e});if((e=Math.floor(e/24))<7)return RED._("palette.editor.times.daysV",{count:e});if((e=Math.floor(e/7))<4)return RED._("palette.editor.times.weeksV",{count:e});var t=Math.floor(e/4);return e%=4,t<12?RED._("palette.editor.times.monthsV",{count:t}):(e=Math.floor(t/12),0===(t%=12)?RED._("palette.editor.times.yearsV",{count:e}):RED._("palette.editor.times.year"+(1<e?"s":"")+"MonthsV",{y:e,count:t}))}(n.updated_at)+"</span>").appendTo(a),!1);if(n.types&&0<n.types.length)for(e=0;e<n.types.length;e++){var r=RED.nodes.registry.getNodeSetForType(n.types[e]);if(r){s=r.module;break}}a=$("<div>",{class:"red-ui-palette-module-meta"}).appendTo(i),i=$("<div>",{class:"red-ui-palette-module-button-group"}).appendTo(a),a=$('<a href="#" class="red-ui-button red-ui-button-small"></a>').text(RED._("palette.editor.install")).appendTo(i);a.on("click",function(e){e.preventDefault(),$(this).hasClass("disabled")||M(n,t,function(e){})}),D.hasOwnProperty(n.id)?(a.addClass("disabled"),a.text(RED._("palette.editor.installed"))):s&&(a.addClass("disabled"),a.text(RED._("palette.editor.conflict")),RED.popover.create({target:a,content:RED._("palette.editor.conflictTip",{module:s}),trigger:"hover",direction:"bottom",delay:{show:750,hide:50}})),o.elements={installButton:a}}else $("<div>",{class:"red-ui-search-empty"}).text(RED._("search.empty")).appendTo(t)}}),!1!==RED.settings.get("externalModules.palette.allowUpload",!0)&&(i=$('<span class="button-group">').prependTo(n),r=$('<button type="button" class="red-ui-sidebar-header-button red-ui-palette-editor-upload-button"><label><i class="fa fa-upload"></i><form id="red-ui-palette-editor-upload-form" enctype="multipart/form-data"><input name="tarball" type="file" accept=".tgz"></label></button>').appendTo(i),(a=r.find('input[type="file"]')).on("change",function(e){0<this.files.length&&(t.text(this.files[0].name),s.slideDown(200))}),s=$('<div class="red-ui-palette-editor-upload"></div>').appendTo(e),d=$("<div>").appendTo(s),n=$('<div class="placeholder-input"><i class="fa fa-upload"></i> </div>').appendTo(d),t=$("<span></span>").appendTo(n),i=$('<div class="red-ui-palette-editor-upload-buttons"></div>').appendTo(d),$('<button class="editor-button"></button>').text(RED._("common.label.cancel")).appendTo(i).on("click",function(e){e.preventDefault(),s.slideUp(200),a.val("")}),$('<button class="editor-button primary"></button>').text(RED._("common.label.upload")).appendTo(i).on("click",function(e){e.preventDefault();var n=RED.utils.addSpinnerOverlay(s,!0),e=$('<div style="position: relative;bottom: calc(50% + 17px); padding-right: 10px;text-align: right;"></div>').appendTo(n),e=($('<button class="red-ui-button"></button>').text(RED._("eventLog.view")).appendTo(e).on("click",function(e){e.preventDefault(),RED.actions.invoke("core:show-event-log")}),RED.eventLog.startEvent(RED._("palette.editor.confirm.button.install")+" : "+a[0].files[0].name),new FormData),i=(e.append("tarball",a[0].files[0]),a[0].files[0].name);$.ajax({url:"nodes",data:e,cache:!1,contentType:!1,processData:!1,method:"POST"}).always(function(e,t,o){n.remove(),a.val(""),s.slideUp(200)}).fail(function(e,t,o){e.responseJSON&&(t=e.responseJSON.message);var n=RED.notify(RED._("palette.editor.errors.installFailed",{module:i,message:t}),{type:"error",modal:!0,fixed:!0,buttons:[{text:RED._("common.label.close"),click:function(){n.close()}},{text:RED._("eventLog.view"),click:function(){n.close(),RED.actions.invoke("core:show-event-log")}}]});a.val(""),s.slideUp(200)})}),RED.popover.tooltip(r,RED._("palette.editor.upload"))),$('<div id="red-ui-palette-module-install-shade" class="red-ui-palette-module-shade hide"><div class="red-ui-palette-module-shade-status"></div><img src="red/images/spin.svg" class="red-ui-palette-spinner"/></div>').appendTo(e),RED.userSettings.add({id:"palette",title:RED._("palette.editor.palette"),get:G,close:function(){S.detach()},focus:function(){l.resize(),setTimeout(function(){c.trigger("focus")},200)}}),RED.actions.add("core:manage-palette",function(){RED.userSettings.show("palette")}),RED.events.on("registry:module-updated",function(e){b(e.module)}),RED.events.on("registry:node-set-enabled",function(e){b(e.module)}),RED.events.on("registry:node-set-disabled",function(e){b(e.module)}),RED.events.on("registry:node-type-added",function(e){/^subflow:/.test(e)||b(RED.nodes.registry.getNodeSetForType(e).module)}),RED.events.on("registry:node-type-removed",function(e){/^subflow:/.test(e)||b(RED.nodes.registry.getNodeSetForType(e).module)}),RED.events.on("registry:node-set-added",function(e){b(e.module);for(var t=0;t<h.length;t++)if(h[t].info.id===e.module){var o=h[t].elements.installButton;o.addClass("disabled"),o.text(RED._("palette.editor.installed"));break}}),RED.events.on("registry:node-set-removed",function(e){if(!RED.nodes.registry.getModule(e.module)){var t=D[e.module];if(t){y.editableList("removeItem",t),delete D[e.module];for(var o=0;o<h.length;o++)if(h[o].info.id===e.module){var n=h[o].elements.installButton;n.removeClass("disabled"),n.text(RED._("palette.editor.install"));break}}}}),RED.events.on("nodes:add",function(e){/^subflow:/.test(e.type)||(E[e.type]=(E[e.type]||0)+1,1===E[e.type]&&b(RED.nodes.registry.getNodeSetForType(e.type).module))}),RED.events.on("nodes:remove",function(e){E.hasOwnProperty(e.type)&&(E[e.type]--,0===E[e.type]&&(delete E[e.type],b(RED.nodes.registry.getNodeSetForType(e.type).module)))}))},install:M}}(),RED.editor=function(){var l=[],c=!1,o={},m={},v={},u={};function w(e){var t,o,n,i,a=e.valid,s=e.changed;if(e.valid=!0,0===e.type.indexOf("subflow:"))o=(t=RED.nodes.subflow(e.type.substring(8))).valid,i=t.changed,void 0===o&&(o=w(t),i=t.changed),n=p(e,e._def.defaults,e),e.valid=o&&0===n.length,e.changed=e.changed||i,e.validationErrors=n;else if(e._def)n=p(e,e._def.defaults,e),e._def._creds&&(n=n.concat(p(e,e._def.credentials,e._def._creds))),e.valid=0===n.length,e.validationErrors=n;else if("subflow"==e.type){for(var r=RED.nodes.filterNodes({z:e.id}),d=0;d<r.length;d++)o=r[d].valid,i=r[d].changed,void 0===o&&(o=w(r[d]),i=r[d].changed),e.valid=e.valid&&o,e.changed=e.changed||i;for(var l=RED.nodes.filterNodes({type:"subflow:"+e.id}),c={},d=0;d<l.length;d++)l[d].valid=e.valid,l[d].changed=l[d].changed||e.changed,l[d].dirty=!0,c[l[d].z]=!0;Object.keys(c).forEach(function(e){e=RED.nodes.subflow(e);e&&w(e)})}return a===e.valid&&s===e.changed||(e.dirty=!0,(t=RED.nodes.subflow(e.z))&&w(t)),e.valid}function p(e,t,o){var n,i,a=[];for(n in t)t.hasOwnProperty(n)&&("string"==typeof(i=s(e,t,n,o[n]))?a.push(i):i||a.push(n));return a}function s(t,e,o,n){var i=!0;if(/^\$\([a-zA-Z_][a-zA-Z0-9_]*\)$/.test(n))return!0;if(/^\$\{[a-zA-Z_][a-zA-Z0-9_]*\}$/.test(n))return!0;var a=null;if("label"in e[o]&&"string"==typeof e[o].label&&(a=e[o].label),"required"in e[o]&&e[o].required&&!(i=""!==n)&&a)return RED._("validator.errors.missing-required-prop",{prop:a});if(i&&"validate"in e[o])try{var s={};if(a&&(s.label=a),i=e[o].validate.call(t,n,s),2===e[o].validate.length&&"string"==typeof i)return i;i=!!i}catch(e){return console.log("Validation error:",t.type,t.id,"property: "+o,"value:",n,e),RED._("validator.errors.validation-error",{prop:o,node:t.type,id:t.id,error:e.message})}if(i&&e[o].type&&RED.nodes.getType(e[o].type)&&!("validate"in e[o])){if(n&&"_ADD_"!=n){s=RED.nodes.node(n);if(s){if(null==s.valid||s.valid)return!0;if(a)return RED._("validator.errors.invalid-config",{prop:a})}else if(a)return RED._("validator.errors.missing-config",{prop:a});return!1}if(!(i=e[o].hasOwnProperty("required")&&!e[o].required)&&a)return RED._("validator.errors.missing-required-prop",{prop:a})}return i}function b(e,t){for(var o in e._def.defaults)e._def.defaults.hasOwnProperty(o)&&n(e,e._def.defaults,o,t);if(e._def.credentials)for(o in e._def.credentials)e._def.credentials.hasOwnProperty(o)&&n(e,e._def.credentials,o,t)}function n(e,t,o,n){var i,a,n=$("#"+n+"-"+o);0<n.length&&(i=n.val(),t[o].hasOwnProperty("format")&&""!==t[o].format&&"DIV"===n[0].nodeName&&(i=n.text()),"string"!=typeof(e=s(e,t,o,i))&&e?(n.removeClass("input-error"),(a=n.data("tooltip"))&&(n.data("tooltip",null),a.delete())):(n.addClass("input-error"),"string"==typeof e&&((a=n.data("tooltip"))?a.setContent(e):(a=RED.popover.tooltip(n,e),n.data("tooltip",a)))))}function f(t,o){t.resize=!0,t.dirty=!0,t.dirtyStatus=!0;var n=[];o&&RED.nodes.eachLink(function(e){e.source===t&&o.hasOwnProperty(e.sourcePort)&&("-1"===o[e.sourcePort]?n.push(e):e.sourcePort=o[e.sourcePort])}),t.hasOwnProperty("__outputs")&&(t.outputs<t.__outputs&&RED.nodes.eachLink(function(e){e.source===t&&e.sourcePort>=t.outputs&&-1===n.indexOf(e)&&n.push(e)}),delete t.__outputs),t.inputs=Math.min(1,Math.max(0,parseInt(t.inputs))),isNaN(t.inputs)&&(t.inputs=0),0===t.inputs&&(n=n.concat(RED.nodes.filterLinks({target:t})));for(var e=0;e<n.length;e++)RED.nodes.removeLink(n[e]);return n}function y(e,t,o,n){o=$("#"+o+"-"+t);0!==o.length&&("checkbox"===o.attr("type")?o.prop("checked",e[t]):(null==(e=e[t])&&(e=""),void 0!==n&&n[t].hasOwnProperty("format")&&""!==n[t].format&&"DIV"===o[0].nodeName?(o.html(RED.text.format.getHtml(e,n[t].format,{},!1,"en")),RED.text.format.attach(o[0],n[t].format,{},!1,"en")):(o.val(e),"INPUT"!==o[0].nodeName&&"TEXTAREA"!==o[0].nodeName||RED.text.bidi.prepareInput(o))))}function E(t,e,o,n){$("#"+n+"-"+o).on("change keyup paste",function(e){$(this).attr("skipValidation")||b(t,n)})}function D(e,t,o,n){for(var i in t)t.hasOwnProperty(i)&&("password"==t[i].type?o[i]?$("#"+n+"-"+i).val(o[i]):o["has_"+i]?$("#"+n+"-"+i).val("__PWRD__"):$("#"+n+"-"+i).val(""):y(o,i,n,t),E(e,0,i,n))}function R(d,l,c,u,p,f,h){function t(){var e,t,o,n,i=$("<ul></ul>").appendTo(d),a=$("<div></div>").appendTo(d),s=RED.tabs.create({element:i,onchange:function(e){a.children().hide(),e.content.show(),e.onchange&&e.onchange.call(e),g&&RED.tray.resize()},collapsible:!0,menu:!1}),r=[];for(e in l=l.slice(),v)v.hasOwnProperty(e)&&v[e](c)&&l.push(e);for(o in l.forEach(function(t){try{var e,o,n=m[t];n?("function"==typeof n&&(n=n.call(n,c)),e=$("<div>",{class:"red-ui-tray-content"}).appendTo(a).hide(),n.create.call(n,e),o={id:t,label:n.label,name:n.name,iconClass:n.iconClass,content:e,onchange:function(){n.show&&n.show.call(n)}},s.addTab(o),r.push(n)):console.warn("Unregisted edit pane:",t)}catch(e){console.log(t,e)}}),u.defaults)u.defaults.hasOwnProperty(o)&&(u.defaults[o].type?u.defaults[o]._type.array||((t=RED.nodes.getType(u.defaults[o].type))&&"config"===t.category?t.exclusive?function(t,o,n,i){var a=$("#"+i+"-"+o),e=(a.val(t[o]),a.attr("type","hidden"),$("<a>",{id:i+"-edit-"+o,class:"red-ui-button"}));a.after(e),t[o]?e.text(RED._("editor.configEdit")):e.text(RED._("editor.configAdd")),e.on("click",function(e){k(o,n,a.val()||"_ADD_",i,t),e.preventDefault()})}(c,o,u.defaults[o].type,p):function(t,o,n,i,e){var a,s,r,d=$("#"+i+"-"+o);0!==d.length&&(r=d.width(),a=d.attr("style"),r=null!==(a=/(^|\s|;)width\s*:\s*([^;]+)/i.exec(a))?a[2].trim():"70%",a=$("<div></div>").css({width:r,display:"inline-flex"}),s=$('<select id="'+i+"-"+o+'"></select>').appendTo(a),d.replaceWith(a),s.css({"flex-grow":1}),_(o,n,t[o],i,e),$('<a id="'+i+"-lookup-"+o+'" class="red-ui-button"><i class="fa fa-pencil"></i></a>').css({"margin-left":"10px"}).appendTo(a),$("#"+i+"-lookup-"+o).on("click",function(e){k(o,n,s.find(":selected").val(),i,t),e.preventDefault()}),r="",e=RED.nodes.node(t[o]),RED.nodes.getType(n),e&&(r=RED.utils.getNodeLabel(e,e.id)),d.val(r))}(c,o,u.defaults[o].type,p,u.defaults[o].filter):(console.log("Unknown type:",u.defaults[o].type),y(c,o,p,u.defaults))):y(c,o,p,u.defaults),E(c,u.defaults,o,p));if(/^subflow:/.test(u.type)||D(c,u.credentials,c.credentials,p),u.oneditprepare)try{u.oneditprepare.call(c)}catch(e){console.log("oneditprepare",c.id,c.type,e.toString()),console.log(e.stack)}for(o in u.defaults)u.defaults.hasOwnProperty(o)&&((n=$("#"+p+"-"+o)).attr("skipValidation",!0),void 0!==n.data("noderedTypedInput")?n.trigger("change",[n.typedInput("type"),n.typedInput("value")]):n.trigger("change"),n.removeAttr("skipValidation"));if(u.credentials)for(o in u.credentials)u.credentials.hasOwnProperty(o)&&((n=$("#"+p+"-"+o)).attr("skipValidation",!0),void 0!==n.data("noderedTypedInput")?n.trigger("change",[n.typedInput("type"),n.typedInput("value")]):n.trigger("change"),n.removeAttr("skipValidation"));b(c,p),g=!0,f&&s.activateTab(f),h&&h(r)}var e,o,n,i,a,g=!1;u.credentials||/^subflow:/.test(u.type)||"group"===c.type||"tab"===c.type?c.credentials?(D(c,u.credentials,c.credentials,p),t()):(e=c.type,/^subflow:/.test(e)&&(e="subflow"),e=e,o=c.id,n=function(e){e&&(c.credentials=e,c.credentials._=$.extend(!0,{},e)),t()},a=setTimeout(function(){i=RED.notify($('<p data-i18n="[prepend]editor.loadCredentials"> <img src="red/images/spin.svg"/></p>').i18n(),{fixed:!0})},800),e="credentials/"+e.replace(/\s+/g,"-")+"/"+o,$.ajax({url:e,dataType:"json",success:function(e){i&&(i.close(),i=null),clearTimeout(a),n(e)},error:function(e,t,o){i&&(i.close(),i=null),clearTimeout(a),RED.notify(RED._("editor.errors.credentialLoadFailed"),"error"),n(null)},timeout:3e4})):t()}function x(){for(var e=l.length-1;e<l.length;e++){var t=l[e];if(n=t.type,"group"===t.type)n=RED._("group.editGroup",{name:RED.utils.sanitize(t.name||t.id)});else if("_expression"===t.type)n=RED._("expressionEditor.title");else if("_js"===t.type)n=RED._("jsEditor.title");else if("_text"===t.type)n=RED._("textEditor.title");else if("_json"===t.type)n=RED._("jsonEditor.title");else if("_markdown"===t.type)n=RED._("markdownEditor.title");else if("_buffer"===t.type)n=RED._("bufferEditor.title");else if("subflow"===t.type)n=RED._("subflow.editSubflow",{name:RED.utils.sanitize(t.name)});else if(0===t.type.indexOf("subflow:"))var o=RED.nodes.subflow(t.type.substring(8)),n=RED._("subflow.editSubflowInstance",{name:RED.utils.sanitize(o.name)});else if(void 0!==t._def){if(void 0!==t._def.paletteLabel)try{n=RED.utils.sanitize(("function"==typeof t._def.paletteLabel?t._def.paletteLabel.call(t._def):t._def.paletteLabel)||"")}catch(e){console.log("Definition error: "+t.type+".paletteLabel",e)}e===l.length-1&&(n=RED.nodes.node(t.id)?RED._("editor.editNode",{type:RED.utils.sanitize(n)}):RED._("editor.addNewConfig",{type:RED.utils.sanitize(n)}))}}return n}function h(t,e){if(t._def.oneditsave){var o={};for(var n in t._def.defaults)t._def.defaults.hasOwnProperty(n)&&("string"==typeof t[n]||"number"==typeof t[n]?o[n]=t[n]:o[n]=$.extend(!0,{},{v:t[n]}).v);try{!0===t._def.oneditsave.call(t)&&(e.changed=!0)}catch(e){console.warn("oneditsave",t.id,t.type,e.toString())}for(n in t._def.defaults)t._def.defaults.hasOwnProperty(n)&&(null===o[n]||"string"==typeof o[n]||"number"==typeof o[n]?o[n]!==t[n]&&(e.changes[n]=o[n],e.changed=!0):"group"===t.type&&"nodes"===n||JSON.stringify(o[n])!==JSON.stringify(t[n])&&(e.changes[n]=o[n],e.changed=!0))}}function g(e,t){return e.__label__<t.__label__?-1:e.__label__>t.__label__?1:0}function _(e,o,t,n,i){if(n){var a=$("#"+n+"-edit-"+e);if(a.length)t?a.text(RED._("editor.configEdit")):a.text(RED._("editor.configAdd")),$("#"+n+"-"+e).val(t);else{var s=$("#"+n+"-"+e),a=RED.nodes.getType(o);s.children().remove();var r=(r=RED.nodes.workspace(RED.workspaces.active()))||RED.nodes.subflow(RED.workspaces.active()),d=[],n=("function"!=typeof i&&(i=null),RED.nodes.eachConfig(function(e){var t;e.type!=o||e.z&&e.z!==r.id||i&&!i.call(null,e)||(t=RED.utils.getNodeLabel(e,e.id),e.__label__=t+(e.d?" ["+RED._("workspace.disabled")+"]":""),d.push(e))}),g);"function"==typeof a.sort&&(n=a.sort);try{d.sort(n)}catch(e){console.log("Definition error: "+a.type+".sort",e)}d.forEach(function(e){$('<option value="'+e.id+'"'+(t==e.id?" selected":"")+"></option>").text(RED.text.bidi.enforceTextDirectionWithUCC(e.__label__)).appendTo(s),delete e.__label__});e=o;if(void 0!==a.paletteLabel)try{e=RED.utils.sanitize(("function"==typeof a.paletteLabel?a.paletteLabel.call(a):a.paletteLabel)||o)}catch(e){console.log("Definition error: "+o+".paletteLabel",e)}s.append('<option value="_ADD_"'+(""===t?" selected":"")+">"+RED._("editor.addNewType",{type:e})+"</option>"),window.setTimeout(function(){s.trigger("change")},50)}}}function k(f,h,e,g,m){if(!c){c=!0;var v="_ADD_"==e,r=RED.nodes.getType(h),b=RED.nodes.node(e),y=[],e="",t=RED.nodes.subflow(RED.workspaces.active());if(t&&(e=t.id),null==b){for(var o in b={id:RED.nodes.id(),_def:r,type:h,z:e,users:[]},r.defaults)r.defaults[o].value&&(b[o]=JSON.parse(JSON.stringify(r.defaults[o].value)));b._=r._}l.push(b),RED.view.state(RED.state.EDITING);t={title:x(),resize:function(e){$(".red-ui-tray-content").height(e.height-50);var e=$("#node-config-dialog-edit-form"),t={width:e.width(),height:e.height()};y.forEach(function(e){e.resize&&e.resize.call(e,t)})},open:function(e,i){e.find(".red-ui-tray-header");var a=e.find(".red-ui-tray-body"),s=e.find(".red-ui-tray-footer"),e=$('<div class="red-ui-tray-footer-left"></div>').appendTo(s),e=($('<input id="node-config-input-node-disabled" type="checkbox">').prop("checked",!!b.d).appendTo(e).toggleButton({enabledIcon:"fa-circle-thin",disabledIcon:"fa-ban",invertState:!0}),!1!==r.hasUsers&&$('<span><i class="fa fa-info-circle"></i> <span id="red-ui-editor-config-user-count"></span></span>').css("margin-left","10px").appendTo(e),s.append('<span class="red-ui-tray-footer-right"><span id="red-ui-editor-config-scope-warning" data-i18n="[title]editor.errors.scopeChange"><i class="fa fa-warning"></i></span><select id="red-ui-editor-config-scope"></select></span>'),["editor-tab-properties"]);b._def.defaults&&b._def.defaults.hasOwnProperty("info")||e.push("editor-tab-description"),R(a,e,b,r,"node-config-input",null,function(e){y=e,b._def.exclusive?$("#red-ui-editor-config-scope").hide():$("#red-ui-editor-config-scope").show(),$("#red-ui-editor-config-scope-warning").hide();var o={},t=(b.users.forEach(function(e){o[e.z]=!0}),Object.keys(o).length),n=$("#red-ui-editor-config-scope").empty();n.off("change"),n.append('<option value=""'+(b.z?"":" selected")+' data-i18n="sidebar.config.global"></option>'),n.append('<option disabled data-i18n="sidebar.config.flows"></option>'),RED.nodes.eachWorkspace(function(e){var t=e.label;o[e.id]&&(t="* "+t),$('<option value="'+e.id+'"'+(e.id==b.z?" selected":"")+"></option>").text(t).appendTo(n)}),n.append('<option disabled data-i18n="sidebar.config.subflows"></option>'),RED.nodes.eachSubflow(function(e){var t=e.name;o[e.id]&&(t="* "+t),$('<option value="'+e.id+'"'+(e.id==b.z?" selected":"")+"></option>").text(t).appendTo(n)}),0<t&&n.on("change",function(){var e=$(this).val();""!==e&&(!o[e]||1<t)?$("#red-ui-editor-config-scope-warning").show():$("#red-ui-editor-config-scope-warning").hide()}),!1!==r.hasUsers&&$("#red-ui-editor-config-user-count").text(RED._("editor.nodesUse",{count:b.users.length})).parent().show(),a.i18n(),s.i18n(),c=!1,i()})},close:function(){RED.workspaces.refresh(),y.forEach(function(e){e.close&&e.close.call(e)}),l.pop()},show:function(){b&&(RED.sidebar.info.refresh(b),RED.sidebar.help.show(h,!1))}};t.buttons=[{id:"node-config-dialog-cancel",text:RED._("common.label.cancel"),click:function(){var t=h,o=b.id,e=RED.nodes.getType(t);if(e.oneditcancel&&e.oneditcancel){var n=RED.nodes.node(o);if(n)try{e.oneditcancel.call(n,!1)}catch(e){console.log("oneditcancel",n.id,n.type,e.toString())}else try{e.oneditcancel.call({id:o},!0)}catch(e){console.log("oneditcancel",o,t,e.toString())}}RED.tray.close()}},{id:"node-config-dialog-ok",text:v?RED._("editor.configAdd"):RED._("editor.configUpdate"),class:"primary",click:function(){var e,t,o,n,i={changes:{},changed:!1,outputMap:null},a=f,s=(b.id,h),r=v,d=RED.nodes.getType(s);if(d.oneditsave)try{d.oneditsave.call(b)}catch(e){console.warn("oneditsave",b.id,b.type,e.toString())}for(e in d.defaults)!d.defaults.hasOwnProperty(e)||null!=(n="checkbox"===(n=$("#node-config-input-"+e)).attr("type")?n.prop("checked"):"format"in d.defaults[e]&&""!==d.defaults[e].format&&"DIV"===n[0].nodeName?n.text():n.val())&&n!==b[e]&&(b._def.defaults[e].type&&("_ADD_"==n&&(n=""),(t=RED.nodes.node(b[e]))&&((o=t.users).splice(o.indexOf(b),1),RED.events.emit("nodes:change",t)),(t=RED.nodes.node(n))&&(t.users.push(b),RED.events.emit("nodes:change",t))),b[e]=n);y.forEach(function(e){e.apply&&e.apply.call(e,i)}),b.label=d.label;for(var l=$("#red-ui-editor-config-scope").val(),c=(b.z=l,$("#node-config-input-node-disabled").prop("checked")?!0!==b.d&&(b.d=!0):!0===b.d&&delete b.d,l&&(b.users=b.users.filter(function(e){var t,o=!0;for(t in e._def.defaults)e._def.defaults.hasOwnProperty(t)&&e._def.defaults[t].type===b.type&&e[t]===b.id&&e.z!==l&&(o=!1,e[t]=null,e.dirty=!0,e.changed=!0,w(e));return o})),r&&RED.nodes.add(b),w(b),{}),u=(c[b.id]=!0,b.users.slice());0<u.length;){var p=u.pop();c[p.id]||(c[p.id]=!0,p.users&&(u=u.concat(p.users)),w(p))}RED.nodes.dirty(!0),RED.view.redraw(!0),r||(RED.events.emit("editor:save",b),RED.events.emit("nodes:change",b)),RED.tray.close(function(){var e=null;m&&"function"==typeof m._def.defaults[a].filter&&(e=function(e){return m._def.defaults[a].filter.call(m,e)}),_(a,s,b.id,g,e)})}}],v||t.buttons.unshift({class:"leftButton",text:RED._("editor.configDelete"),click:function(){var t=f,e=b.id,o=h,n=RED.nodes.getType(o);try{n.ondelete&&(console.log("Deprecated API warning: config node type ",o," has an ondelete function - should be oneditdelete"),n.ondelete.call(b)),n.oneditdelete&&n.oneditdelete.call(b)}catch(e){console.log("oneditdelete",b.id,b.type,e.toString())}for(var i={t:"delete",nodes:[b],changes:{},dirty:RED.nodes.dirty()},a=0;a<b.users.length;a++){var s,r=b.users[a];for(s in i.changes[r.id]={changed:r.changed,valid:r.valid},r._def.defaults)r._def.defaults.hasOwnProperty(s)&&r[s]==e&&(i.changes[r.id][s]=e,r[s]="",r.changed=!0,r.dirty=!0);w(r)}RED.nodes.remove(e),RED.nodes.dirty(!0),RED.view.redraw(!0),RED.history.push(i),RED.tray.close(function(){var e=null;m&&"function"==typeof m._def.defaults[t].filter&&(e=function(e){return m._def.defaults[t].filter.call(m,e)}),_(t,o,"",g,e)})}}),RED.tray.show(t)}}function t(e,t){o.hasOwnProperty(e)?(0<l.length&&(t.parent=l[l.length-1].id),l.push({type:e}),t.title=t.title||x(),t.onclose=function(){l.pop()},o[e].show(t)):console.log("Unknown type editor:",e)}return{init:function(){window.ace&&window.ace.config.set("basePath","vendor/ace"),RED.tray.init(),RED.actions.add("core:confirm-edit-tray",function(){$(document.activeElement).blur(),$("#node-dialog-ok").trigger("click"),$("#node-config-dialog-ok").trigger("click")}),RED.actions.add("core:cancel-edit-tray",function(){$(document.activeElement).blur(),$("#node-dialog-cancel").trigger("click"),$("#node-config-dialog-cancel").trigger("click")}),RED.editor.codeEditor.init()},generateViewStateId:function(o,n,i){try{const s="object"==typeof(n=n||{}).options?n.options:{};let t;if(!1===(t=n.hasOwnProperty("stateId")||s.hasOwnProperty("stateId")?n.stateId:t))return!1;if(!t){let e;var a=RED.view.selection();if("node"===o&&n.id)e=n.id;else{if(!a.nodes||!a.nodes.length)return!1;e=a.nodes[0].id}const r=[e],d=$(n.element||s.element);d.length&&(r.push(d.closest(".form-row").index()),r.push(d.index())),"typedInput"==o&&(r.push(d.closest("li").index()),!i&&n.propertyType&&(i=n.propertyType)),t=r.join("/")}return t&&i&&(t+="/"+i),t}catch(e){return!1}},edit:function(s,i){var r,a,e,d,o,t,n;c||(r=s,a=!(c=!0),e=!1,d=[],l.push(s),RED.view.state(RED.state.EDITING),o=s.type,"subflow:"==s.type.substring(0,8)&&(o="subflow"),t={title:x(),buttons:[{id:"node-dialog-delete",class:"leftButton",text:RED._("common.label.delete"),click:function(){var e=RED.nodes.dirty(),t=[],o=[],n=RED.nodes.remove(r.id),t=(t.push(r),{t:"delete",nodes:t=t.concat(n.nodes),links:o=o.concat(n.links),changes:{},dirty:e});RED.nodes.dirty(!0),RED.view.redraw(!0),RED.history.push(t),RED.tray.close()}},{id:"node-dialog-cancel",text:RED._("common.label.cancel"),click:function(){if(r._def){if(r._def.oneditcancel)try{r._def.oneditcancel.call(r)}catch(e){console.log("oneditcancel",r.id,r.type,e.toString())}for(var e in r._def.defaults){var t;r._def.defaults.hasOwnProperty(e)&&(t=r._def.defaults[e]).type&&(t=RED.nodes.getType(t.type))&&t.exclusive&&(""===(t=$("#node-input-"+e).val()||"")||r[e]||RED.nodes.remove(t))}}RED.tray.close()}},{id:"node-dialog-ok",text:RED._("common.label.done"),class:"primary",click:function(){var e,t,o,n={changes:{},changed:!1,outputMap:null},i=RED.nodes.dirty(),a=(h(r,n),d.forEach(function(e){e.apply&&e.apply.call(e,n)}),f(r,n.outputMap));$("#node-input-node-disabled").prop("checked")?!0!==s.d&&(n.changes.d=s.d,n.changed=!0,s.d=!0):!0===s.d&&(n.changes.d=s.d,n.changed=!0,delete s.d),s.resize=!0,n.changed&&(e=r.changed,r.changed=!0,RED.nodes.dirty(!0),o=RED.nodes.subflow(RED.workspaces.active()),t=null,o&&(t=[],RED.nodes.eachNode(function(e){e.type=="subflow:"+RED.workspaces.active()&&(t.push({id:e.id,changed:e.changed}),e.changed=!0,e.dirty=!0,f(e))})),o={t:"edit",node:r,changes:n.changes,links:a,dirty:i,changed:e},n.outputMap&&(o.outputMap=n.outputMap),t&&(o.subflow={instances:t}),RED.history.push(o)),r.dirty=!0,w(r),RED.events.emit("editor:save",r),RED.events.emit("nodes:change",r),RED.tray.close()}}],resize:function(e){u[o]=e.width,$(".red-ui-tray-content").height(e.height-50);var e=$(".red-ui-tray-content form").height(e.height-50-40),t={width:e.width(),height:e.height()};d.forEach(function(e){e.resize&&e.resize.call(e,t)})},open:function(e,t){r.hasOwnProperty("outputs")&&(r.__outputs=r.outputs);var o=e.find(".red-ui-tray-footer"),n=e.find(".red-ui-tray-body"),e=(n.parent().css("overflow","hidden"),$('<div class="red-ui-tray-footer-left"></div>').appendTo(o)),e=($('<input id="node-input-node-disabled" type="checkbox">').prop("checked",!!s.d).appendTo(e).toggleButton({enabledIcon:"fa-circle-thin",disabledIcon:"fa-ban",invertState:!0}),["editor-tab-properties"]);/^subflow:/.test(s.type)&&e.push("editor-tab-envProperties"),s._def.defaults&&s._def.defaults.hasOwnProperty("info")||(e.push("editor-tab-description"),a=!0,s.infoEditor&&(s.infoEditor__orig=s.infoEditor,delete s.infoEditor,a=!1)),e.push("editor-tab-appearance"),R(n,e,s,s._def,"node-input",i,function(e){d=e,n.i18n(),o.i18n(),c=!1,t()})},close:function(){RED.view.state()!=RED.state.IMPORT_DRAGGING&&RED.view.state(RED.state.DEFAULT),r&&(r.infoEditor__orig&&(r.infoEditor=r.infoEditor__orig,delete r.infoEditor__orig),a&&delete r.infoEditor,e||RED.sidebar.info.refresh(r)),RED.workspaces.refresh(),d.forEach(function(e){e.close&&e.close.call(e)}),RED.view.redraw(!0),l.pop()},show:function(){r&&(RED.sidebar.info.refresh(r),RED.sidebar.help.show(r.type,!1),"BODY"===document.activeElement.tagName&&$("#red-ui-editor-stack").trigger("focus"))}},u.hasOwnProperty(o)&&(t.width=u[o]),"subflow"===o&&(n=r.type.substring(8),t.buttons.unshift({class:"leftButton",text:RED._("subflow.edit"),click:function(){RED.workspaces.show(n),e=!0,$("#node-dialog-ok").trigger("click")}})),RED.tray.show(t))},editConfig:k,editFlow:function(i,a){var s,e;c||(c=!0,s=[],RED.view.state(RED.state.EDITING),e={title:RED._("workspace.editFlow",{name:RED.utils.sanitize(i.label)}),buttons:[{id:"node-dialog-delete",class:"leftButton"+(1===RED.workspaces.count()?" disabled":""),text:RED._("common.label.delete"),click:function(){RED.workspaces.delete(i),RED.tray.close()}},{id:"node-dialog-cancel",text:RED._("common.label.cancel"),click:function(){RED.tray.close()}},{id:"node-dialog-ok",class:"primary",text:RED._("common.label.done"),click:function(){var t={changes:{},changed:!1,outputMap:null},e=RED.nodes.dirty(),o=(s.forEach(function(e){e.apply&&e.apply.call(e,t)}),$("#node-input-disabled").prop("checked"));i.disabled!==o&&(t.changes.disabled=i.disabled,t.changed=!0,i.disabled=o,$("#red-ui-tab-"+i.id.replace(".","-")).toggleClass("red-ui-workspace-disabled",!!i.disabled),i.id===RED.workspaces.active()&&$("#red-ui-workspace").toggleClass("red-ui-workspace-disabled",!!i.disabled)),t.changed&&(o={t:"edit",changes:t.changes,node:i,dirty:e},i.changed=!0,RED.history.push(o),RED.nodes.dirty(!0),t.changes.hasOwnProperty("disabled")&&(RED.nodes.eachNode(function(e){e.z===i.id&&(e.dirty=!0)}),RED.view.redraw()),RED.workspaces.refresh(),RED.events.emit("flows:change",i)),RED.tray.close()}}],resize:function(e){$(".red-ui-tray-content").height(e.height-50);var e=$(".red-ui-tray-content form").height(e.height-50-40),t={width:e.width(),height:e.height()};s.forEach(function(e){e.resize&&e.resize.call(e,t)})},open:function(e,t){var o=e.find(".red-ui-tray-footer"),n=e.find(".red-ui-tray-body"),e=(n.parent().css("overflow","hidden"),$('<div class="red-ui-tray-footer-left"></div>').appendTo(o));i.hasOwnProperty("disabled")||(i.disabled=!1),$('<input id="node-input-disabled" type="checkbox">').prop("checked",i.disabled).appendTo(e).toggleButton({enabledIcon:"fa-circle-thin",disabledIcon:"fa-ban",invertState:!0}),R(n,["editor-tab-flow-properties","editor-tab-envProperties"],i,{},"node-input",a,function(e){s=e,n.i18n(),o.i18n(),c=!1,t()})},close:function(){RED.view.state()!=RED.state.IMPORT_DRAGGING&&RED.view.state(RED.state.DEFAULT),s.forEach(function(e){e.close&&e.close.call(e)});var e=RED.view.selection();e.nodes||e.links||i.id!==RED.workspaces.active()||RED.sidebar.info.refresh(i)}},RED.tray.show(e))},editSubflow:function(a,s){var r,d,e;c||(c=!0,r=a,d=[],l.push(a),RED.view.state(RED.state.EDITING),e={title:x(),buttons:[{id:"node-dialog-cancel",text:RED._("common.label.cancel"),click:function(){RED.tray.close()}},{id:"node-dialog-ok",class:"primary",text:RED._("common.label.done"),click:function(){var t,e,o={changes:{},changed:!1,outputMap:null},n=RED.nodes.dirty(),i=(d.forEach(function(e){e.apply&&e.apply.call(e,o)}),$("#subflow-input-name").val()),i=(i!=r.name&&(o.changes.name=r.name,r.name=i,o.changed=!0),r.env),a=RED.subflow.exportSubflowTemplateEnv($("#node-input-env-container").editableList("items"));a&&0<a.length&&a.forEach(function(e){"cred"===e.type&&(r.credentials=r.credentials||{_:{}},r.credentials[e.name]=e.value,r.credentials["has_"+e.name]=""!==e.value,"__PWRD__"!==e.value&&(o.changed=!0),delete e.value)}),e=a,JSON.stringify(i)!==JSON.stringify(e)&&(r.env=a,o.changes.env=r.env,o.changed=!0),o.changed&&(i=r.changed,r.changed=!0,w(r),t=[],RED.nodes.eachNode(function(e){e.type=="subflow:"+r.id&&(t.push({id:e.id,changed:e.changed}),e._def.color=r.color,e.changed=!0,e.dirty=!0,f(e),w(e))}),RED.events.emit("subflows:change",r),RED.nodes.dirty(!0),e={t:"edit",node:r,changes:o.changes,dirty:n,changed:i,subflow:{instances:t}},RED.history.push(e)),r.dirty=!0,RED.tray.close()}}],resize:function(e){$(".red-ui-tray-content").height(e.height-50);var e=$(".red-ui-tray-content form").height(e.height-50-40),t={width:e.width(),height:e.height()};d.forEach(function(e){e.resize&&e.resize.call(e,t)})},open:function(e,t){var o=e.find(".red-ui-tray-footer"),n=$("<div/>",{class:"red-ui-tray-footer-left"}).appendTo(o),i=e.find(".red-ui-tray-body");i.parent().css("overflow","hidden"),$('<span style="margin-left: 10px"><i class="fa fa-info-circle"></i> <i id="red-ui-editor-subflow-user-count"></i></span>').appendTo(n),r&&RED.sidebar.info.refresh(r);R(i,["editor-tab-properties","editor-tab-subflow-module","editor-tab-description","editor-tab-appearance"],a,a._def,"node-input",s,function(e){d=e,$("#subflow-input-name").val(a.name),RED.text.bidi.prepareInput($("#subflow-input-name")),i.i18n(),o.i18n(),c=!1,t()})},close:function(){RED.view.state()!=RED.state.IMPORT_DRAGGING&&RED.view.state(RED.state.DEFAULT),RED.sidebar.info.refresh(r),RED.workspaces.refresh(),d.forEach(function(e){e.close&&e.close.call(e)}),l.pop(),r=null},show:function(){}},RED.tray.show(e))},editGroup:function(i,a){var n,s,e;c||(c=!0,n=i,l.push(i),RED.view.state(RED.state.EDITING),s=[],e={title:x(),buttons:[{id:"node-dialog-cancel",text:RED._("common.label.cancel"),click:function(){RED.tray.close()}},{id:"node-dialog-ok",class:"primary",text:RED._("common.label.done"),click:function(){var e,t={changes:{},changed:!1,outputMap:null},o=RED.nodes.dirty();h(n,t),s.forEach(function(e){e.apply&&e.apply.call(e,t)}),t.changed&&(e=n.changed,n.changed=!0,RED.nodes.dirty(!0),o={t:"edit",node:n,changes:t.changes,dirty:o,changed:e},RED.history.push(o),RED.events.emit("groups:change",n)),n.dirty=!0,RED.tray.close(),RED.view.redraw(!0)}}],resize:function(e){u.group=e.width,$(".red-ui-tray-content").height(e.height-50);var e=$(".red-ui-tray-content form").height(e.height-50-40),t={width:e.width(),height:e.height()};s.forEach(function(e){e.resize&&e.resize.call(e,t)})},open:function(e,t){var o=e.find(".red-ui-tray-footer"),n=($("<div/>",{class:"red-ui-tray-footer-left"}).appendTo(o),e.find(".red-ui-tray-body"));n.parent().css("overflow","hidden");R(n,["editor-tab-properties","editor-tab-envProperties","editor-tab-description"],i,i._def,"node-input",a,function(e){s=e,n.i18n(),c=!1,t()})},close:function(){RED.view.state()!=RED.state.IMPORT_DRAGGING&&RED.view.state(RED.state.DEFAULT),RED.sidebar.info.refresh(n),s.forEach(function(e){e.close&&e.close.call(e)}),l.pop(),n=null},show:function(){}},u.hasOwnProperty("group")&&(e.width=u.group),RED.tray.show(e))},editJavaScript:function(e){t("_js",e)},editExpression:function(e){t("_expression",e)},editJSON:function(e){t("_json",e)},editMarkdown:function(e){t("_markdown",e)},editText:function(e){"markdown"==e.mode?t("_markdown",e):t("_text",e)},editBuffer:function(e){t("_buffer",e)},buildEditForm:function(e,t,o,a,n){return(t=$('<form id="'+t+'" class="form-horizontal" autocomplete="off"></form>').appendTo(e)).html($("script[data-template-name='"+o+"']").html()),a=a||"node-red",t.find("[data-i18n]").each(function(){for(var e=$(this).attr("data-i18n").split(";"),t=0;t<e.length;t++){var o,n,i=e[t];-1===i.indexOf(":")&&(n="",0===i.indexOf("[")&&(n=(o=i.split("]"))[0]+"]",i=o[1]),e[t]=n+a+":"+i)}$(this).attr("data-i18n",e.join(";"))}),$('<span style="position: absolute; top: -2000px;"><input id="red-ui-trap-password" type="password"/></span>').prependTo(t),$('<span style="position: absolute; top: -2000px;"><input id="red-ui-trap-username" type="text"/></span>').prependTo(t),$('<span style="position: absolute; top: -2000px;"><input id="red-ui-trap-user" type="text"/></span>').prependTo(t),t.on("submit",function(e){e.preventDefault()}),t.find("input").attr("autocomplete","off"),t},validateNode:w,updateNodeProperties:f,showIconPicker:function(){RED.editor.iconPicker.show.apply(null,arguments)},showTypeEditor:t,registerTypeEditor:function(e,t){o[e]=t},createEditor:function(e){return RED.editor.codeEditor.create(e)},get customEditTypes(){return o},registerEditPane:function(e,t,o){o&&(v[e]=o),m[e]=t}}}(),function(){function w(e,t,o,n){var i,a=$("<div>",{class:"red-ui-editor-node-label-form-row"});return void 0===e?($("<span>").text(RED._("editor.noDefaultLabel")).appendTo(a),a.addClass("red-ui-editor-node-label-form-none")):(a.addClass(""),e="red-ui-editor-node-label-form-"+e+"-"+t,$("<label>",{for:e}).text(t+1+".").appendTo(a),i=$("<input>",{type:"text",id:e,placeholder:n}).val(o).appendTo(a),$('<button type="button" class="red-ui-button red-ui-button-small"><i class="fa fa-times"></i></button>').appendTo(a).on("click",function(e){e.preventDefault(),i.val("")})),a}RED.editor.registerEditPane("editor-tab-appearance",function(y){return{label:RED._("editor-tab.appearance"),name:RED._("editor-tab.appearance"),iconClass:"fa fa-object-group",create:function(e){this.content=e;var t,o,n,i,a,s,r,d,e=this.content,l=y,e=$('<form class="dialog-form form-horizontal" autocomplete="off"></form>').appendTo(e),c=("subflow"===l.type&&(n=$("<div/>",{class:"form-row"}).appendTo(e),$("<label/>",{for:"subflow-appearance-input-category","data-i18n":"editor:subflow.category"}).appendTo(n),o=$("<select/>",{id:"subflow-appearance-input-category"}).css({width:"250px"}).appendTo(n),$("<input/>",{type:"text",id:"subflow-appearance-input-custom-category"}).css({display:"none","margin-left":"10px",width:"calc(100% - 250px)"}).appendTo(n),(n=RED.palette.getCategories()).sort(function(e,t){return e.label.localeCompare(t.label)}),n.forEach(function(e){o.append($("<option/>").val(e.id).text(e.label))}),o.append($("<option/>").attr("disabled",!0).text("---")),o.append($("<option/>").val("_custom_").text(RED._("palette.addCategory"))),$("#subflow-appearance-input-category").on("change",function(){"_custom_"===$(this).val()?($("#subflow-appearance-input-category").width(120),$("#subflow-appearance-input-custom-category").show()):($("#subflow-appearance-input-category").width(250),$("#subflow-appearance-input-custom-category").hide())}),$("#subflow-appearance-input-category").val(l.category||"subflows"),l.id,$("#red-ui-editor-subflow-user-count").text(RED._("subflow.subflowInstances",{count:l.instances.length})).show()),$('<div class="form-row"><label for="node-input-show-label-btn" data-i18n="editor.label"></label><span style="margin-right: 2px;"/><input type="checkbox" id="node-input-show-label"/></div>').appendTo(e),$("#node-input-show-label").toggleButton({enabledLabel:RED._("editor.show"),disabledLabel:RED._("editor.hide")}),l.hasOwnProperty("l")||(l.l=!l._def.hasOwnProperty("showLabel")||l._def.showLabel),$("#node-input-show-label").prop("checked",l.l).trigger("change"),"subflow"===l.type&&(n=l.color||"#DDAA99",v=$("<div/>",{class:"form-row"}).appendTo(e),$("<label/>").text(RED._("editor.color")).appendTo(v),RED.editor.colorPicker.create({id:"red-ui-editor-node-color",value:n,defaultValue:"#DDAA99",palette:["#DDAA99","#3FADB5","#87A980","#A6BBCF","#AAAA66","#C0C0C0","#C0DEED","#C7E9C0","#D7D7A0","#D8BFD8","#DAC4B4","#DEB887","#DEBD5C","#E2D96E","#E6E0F8","#E7E7AE","#E9967A","#F3B567","#FDD0A2","#FDF0C2","#FFAAAA","#FFCC66","#FFF0F0","#FFFFFF"],sortPalette:function(e,t){return e.l-t.l}}).appendTo(v),$("#red-ui-editor-node-color").on("change",function(e){var t=$(this).val(),o=(a.css("backgroundColor",t),RED.utils.getDarkerColor(t));o!==t&&a.css("border-color",o)})),l._def.defaults&&l._def.defaults.hasOwnProperty("icon")||(n=$('<div class="form-row"></div>').appendTo(e),$('<label data-i18n="editor.settingIcon">').appendTo(n),i=$('<button type="button" class="red-ui-button red-ui-editor-node-appearance-button">').appendTo(n),$('<i class="fa fa-caret-down"></i>').appendTo(i),a=$("<div>",{class:"red-ui-search-result-node"}).appendTo(i),v=RED.utils.getNodeColor(l.type,l._def),s=RED.utils.getNodeIcon(l._def,l),a.css("backgroundColor",v),(r=RED.utils.getDarkerColor(v))!==v&&a.css("border-color",r),d=$("<div/>",{class:"red-ui-palette-icon-container"}).appendTo(a),RED.utils.createIconElement(s,d,!0),i.on("click",function(e){e.preventDefault();var e=$("#red-ui-editor-node-icon").val()||"",e=e?RED.utils.separateIconPath(e):RED.utils.getDefaultNodeIcon(l._def,l),t=RED.utils.getNodeColor(l.type,l._def);"subflow"===l.type&&(t=$("#red-ui-editor-node-color").val()),RED.editor.iconPicker.show(i,t,e,!1,function(e){$("#red-ui-editor-node-icon").val(e||"");e=RED.utils.getNodeIcon(l._def,{type:l.type,icon:e});RED.utils.createIconElement(e,d,!0)})}),RED.popover.tooltip(i,function(){return $("#red-ui-editor-node-icon").val()||RED._("editor.default")}),$('<input type="hidden" id="red-ui-editor-node-icon">').val(l.icon).appendTo(n)),$('<div class="form-row"><span data-i18n="editor.portLabels"></span></div>').appendTo(e),l.inputs||l._def.inputs||0),u=l.outputs||l._def.outputs||0,p=("subflow"===l.type&&(c=l.in.length,u=l.out.length),l.inputLabels||[]),f=l.outputLabels||[],h=l._def.inputLabels?RED._("editor.defaultLabel"):RED._("editor.noDefaultLabel"),g=l._def.outputLabels?RED._("editor.defaultLabel"):RED._("editor.noDefaultLabel"),m=($('<div class="form-row"><span style="margin-left: 50px;" data-i18n="editor.labelInputs"></span><div id="red-ui-editor-node-label-form-inputs"></div></div>').appendTo(e),$("#red-ui-editor-node-label-form-inputs"));if(0<c)for(t=0;t<c;t++)w("input",t,p[t],h).appendTo(m);else w().appendTo(m);$('<div class="form-row"><span style="margin-left: 50px;" data-i18n="editor.labelOutputs"></span><div id="red-ui-editor-node-label-form-outputs"></div></div>').appendTo(e);var v,b=$("#red-ui-editor-node-label-form-outputs");if(0<u)for(t=0;t<u;t++)w("output",t,f[t],g).appendTo(b);else w().appendTo(b);"subflow"===y.type?this.defaultIcon="node-red/subflow.svg":(v=RED.utils.getDefaultNodeIcon(y._def,y),this.defaultIcon=v.module+"/"+v.file,y.icon&&y.icon!==this.defaultIcon?this.isDefaultIcon=!1:this.isDefaultIcon=!0)},resize:function(e){},close:function(){},show:function(){this.content;var e,t=y,o=t._def.inputLabels?RED._("editor.defaultLabel"):RED._("editor.noDefaultLabel"),n=t._def.outputLabels?RED._("editor.defaultLabel"):RED._("editor.noDefaultLabel"),i=$("#red-ui-editor-node-label-form-inputs"),a=$("#red-ui-editor-node-label-form-outputs"),s=$("#node-input-inputs").val();void 0===s?e="subflow"===t.type?t.in.length:t.inputs||t._def.inputs||0:(e=Math.min(1,Math.max(0,parseInt(s))),isNaN(e)&&(e=0));var r,d,l,c,u=i.children(),p=u.length;if(1===p&&$(u[0]).hasClass("red-ui-editor-node-label-form-none")&&p--,p<e)for(0===p&&$(u[0]).remove(),d=p;d<e;d++)w("input",d,"",o).appendTo(i);else if(e<p){for(d=e;d<p;d++)$(u[d]).remove();0===e&&w().appendTo(i)}if(void 0===(s=$("#node-input-outputs").val())?"subflow"===t.type?r=t.out.length:e=t.outputs||t._def.outputs||0:isNaN(s)?(l=JSON.parse(s),t=Object.keys(l),u=a.children(),1===(p=u.length)&&$(u[0]).hasClass("red-ui-editor-node-label-form-none")&&p--,r=0,c=[],t.forEach(function(e){var t=$("#red-ui-editor-node-label-form-output-"+e).parent();0===t.length&&-1!==l[e]?(0===p&&($(u[0]).remove(),p=-1),t=w("output",e,"",n)):t.detach(),-1!==l[e]&&(r++,c.push({i:parseInt(l[e]),r:t}))}),c.sort(function(e,t){return e.i-t.i}),c.forEach(function(e,t){e.r.find("label").text(t+1+"."),e.r.appendTo(a)}),0===c.length&&w("output",d,"").appendTo(a)):r=Math.max(0,parseInt(s)),u=a.children(),1===(p=u.length)&&$(u[0]).hasClass("red-ui-editor-node-label-form-none")&&p--,p<r)for(0===p&&$(u[0]).remove(),d=p;d<r;d++)w("output",d,"").appendTo(a);else if(r<p){for(d=r;d<p;d++)$(u[d]).remove();0===r&&w().appendTo(a)}},apply:function(e){!function(o,e,n){var t=$("#red-ui-editor-node-label-form-inputs").children().find("input"),i=$("#red-ui-editor-node-label-form-outputs").children().find("input"),a=!1,s=!1,r=t.map(function(){var e=$(this).val();return a=a||""!==e,e}).toArray().slice(0,o.inputs);(void 0===o.inputLabels&&a||void 0!==o.inputLabels&&JSON.stringify(r)!==JSON.stringify(o.inputLabels))&&(e.inputLabels=o.inputLabels,o.inputLabels=r,s=!0);a=!1,r=new Array(o.outputs),i.each(function(){var e,t=$(this).attr("id").substring("red-ui-editor-node-label-form-output-".length);n&&n.hasOwnProperty(t)&&-1===(t=parseInt(n[t]))||(e=$(this).val(),a=a||""!==e,"subflow"!==o.type||o.outputLabels&&o.outputLabels[t]===e||(o.out[t].dirty=!0),r[t]=e)}),(void 0===o.outputLabels&&a||void 0!==o.outputLabels&&JSON.stringify(r)!==JSON.stringify(o.outputLabels))&&(e.outputLabels=o.outputLabels,o.outputLabels=r,s=!0,"subflow"===o.type&&RED.view.redraw());return s}(y,e.changes,e.outputMap)||(e.changed=!0),y._def.defaults&&y._def.defaults.hasOwnProperty("icon")||(t=$("#red-ui-editor-node-icon").val()||"",this.isDefaultIcon?""!==t&&t!==this.defaultIcon?(e.changes.icon=y.icon,y.icon=t,e.changed=!0):(o=(o=RED.utils.getDefaultNodeIcon(y._def,y)).module+"/"+o.file,this.defaultIcon!==o&&(e.changes.icon=y.icon,y.icon=o,e.changed=!0)):(y.icon&&t!==y.icon||!y.icon&&""!==t)&&(e.changes.icon=y.icon,y.icon=t,e.changed=!0)),"subflow"===y.type&&((o="subflows"===(o="_custom_"===(o=$("#subflow-appearance-input-category").val().trim())&&""===(o=$("#subflow-appearance-input-custom-category").val().trim())?y.category:o)?"":o)!=y.category&&(e.changes.category=y.category,y.category=o,e.changed=!0),y.color!==(t=$("#red-ui-editor-node-color").val())&&(e.changes.color=y.color,y.color=t,e.changed=!0,RED.utils.clearNodeColorCache(),"subflow"===y.type&&(RED.nodes.getType("subflow:"+y.id).color=t)));var t,o=!y._def.hasOwnProperty("showLabel")||y._def.showLabel;$("#node-input-show-label").prop("checked")?o?(y.hasOwnProperty("l")&&!y.l&&(e.changes.l=y.l,e.changed=!0),delete y.l):(y.l||(e.changes.l=y.l,e.changed=!0),y.l=!0):o?(!1!==y.l&&(e.changes.l=y.l,e.changed=!0),y.l=!1):(y.hasOwnProperty("l")&&y.l&&(e.changes.l=y.l,e.changed=!0),delete y.l)}}})}(),RED.editor.registerEditPane("editor-tab-description",function(n){return{label:RED._("editor-tab.description"),name:RED._("editor-tab.description"),iconClass:"fa fa-file-text-o",create:function(e){var t,o;this.editor=(e=e,t=n,e=$('<form class="dialog-form form-horizontal" autocomplete="off"></form>').appendTo(e),$("<div></div>").appendTo(e),e=$('<div class="form-row node-text-editor-row" style="position:relative; padding-top: 4px; height: 100%"></div>').appendTo(e),o="node-info-input-info-editor-"+Math.floor(1e3*Math.random()),$('<div style="height: 100%" class="node-text-editor" id="'+o+'" ></div>').appendTo(e),e=RED.editor.createEditor({id:o,mode:"ace/mode/markdown",stateId:RED.editor.generateViewStateId("node",t,"nodeinfo"),value:t.info||""}),t.infoEditor=e)},resize:function(e){this.editor.resize()},close:function(){this.editor.destroy(),this.editor=null},show:function(){this.editor.focus()},apply:function(e){var t=n.info,o=this.editor.getValue();t?""===o.trim()?(e.changed=!0,e.changes.info=t,delete n.info):o!==t&&(e.changed=!0,e.changes.info=t,n.info=o):""!==o.trim()&&(e.changed=!0,e.changes.info=void 0,n.info=o)}}}),RED.editor.registerEditPane("editor-tab-envProperties",function(i){return{label:RED._("editor-tab.envProperties"),name:RED._("editor-tab.envProperties"),iconClass:"fa fa-list",create:function(e){e=$('<form class="dialog-form form-horizontal"></form>').appendTo(e),e=$('<div class="form-row node-input-env-container-row"></div>').appendTo(e);this.list=$("<ol></ol>").appendTo(e),RED.editor.envVarList.create(this.list,i)},resize:function(e){this.list.editableList("height",e.height)},close:function(){},apply:function(t){var e,o=i.env,n=[];/^subflow:/.test(i.type)&&(n=RED.subflow.exportSubflowInstanceEnv(i)),this.list.editableList("items").each(function(e,t){var t=t.data("data");t.nameField&&t.valueField&&""!==(t={name:t.nameField.val(),value:t.valueField.typedInput("value"),type:t.valueField.typedInput("type")}).name.trim()&&n.push(t)}),n&&0<n.length&&n.forEach(function(e){"cred"===e.type&&(i.credentials=i.credentials||{_:{}},i.credentials[e.name]=e.value,i.credentials["has_"+e.name]=""!==e.value,"__PWRD__"!==e.value&&(t.changed=!0),delete e.value)}),o||0!==n.length?(e=n,JSON.stringify(o)!==JSON.stringify(e)&&(t.changes.env=i.env,0===n.length?delete i.env:i.env=n,t.changed=!0)):delete i.env}}}),RED.editor.registerEditPane("editor-tab-flow-properties",function(o){return{label:RED._("editor-tab.properties"),name:RED._("editor-tab.properties"),iconClass:"fa fa-cog",create:function(e){e=$('<form id="dialog-form" class="form-horizontal"></form>').appendTo(e);$('<div class="form-row"><label for="node-input-name" data-i18n="[append]editor:common.label.name"><i class="fa fa-tag"></i> </label><input type="text" id="node-input-name" data-i18n="[placeholder]common.label.name"></div>').appendTo(e),$('<div class="form-row node-text-editor-row"><label for="node-input-info" data-i18n="editor:workspace.info" style="width:300px;"></label><div style="min-height:150px;" class="node-text-editor" id="node-input-info"></div></div>').appendTo(e);this.tabflowEditor=RED.editor.createEditor({id:"node-input-info",mode:"ace/mode/markdown",value:""}),$('<input type="text" style="display: none;" />').prependTo(e),e.on("submit",function(e){e.preventDefault()}),$("#node-input-name").val(o.label),RED.text.bidi.prepareInput($("#node-input-name")),this.tabflowEditor.getSession().setValue(o.info||"",-1)},resize:function(e){$("#node-input-info").css("height",e.height-70+"px"),this.tabflowEditor.resize()},close:function(){this.tabflowEditor.destroy()},apply:function(e){var t=$("#node-input-name").val(),t=(o.label!=t&&(e.changes.label=o.label,e.changed=!0,o.label=t),this.tabflowEditor.getValue());o.info!==t&&(e.changes.info=o.info,e.changed=!0,o.info=t),$("#red-ui-tab-"+o.id.replace(".","-")).toggleClass("red-ui-workspace-disabled",!!o.disabled),$("#red-ui-workspace").toggleClass("red-ui-workspace-disabled",!!o.disabled)}}}),RED.editor.registerEditPane("editor-tab-properties",function(d){return{label:RED._("editor-tab.properties"),name:RED._("editor-tab.properties"),iconClass:"fa fa-cog",create:function(e){var t,o=d.type,n=("subflow"===d.type?o="subflow-template":"subflow:"==d.type.substring(0,8)&&(o="subflow"),t="node-red"===d._def.set.module?"node-red":d._def.set.id,"dialog-form");this.inputClass="node-input","config"===d._def.category&&"group"!==o&&(this.inputClass="node-config-input",n="node-config-dialog-edit-form"),RED.editor.buildEditForm(e,n,o,t,d)},resize:function(e){if(d&&d._def.oneditresize)try{d._def.oneditresize.call(d,e)}catch(e){console.log("oneditresize",d.id,d.type,e.toString())}},close:function(){},apply:function(t){var e,o,n;if(d._def.defaults)for(o in d._def.defaults)if(d._def.defaults.hasOwnProperty(o)){var i,a,s,r=$("#"+this.inputClass+"-"+o);if("checkbox"===r.attr("type")?e=r.prop("checked"):"select"===r.prop("nodeName")&&"multiple"===r.attr("multiple")?null==(e=r.val())&&(e=[]):e="format"in d._def.defaults[o]&&""!==d._def.defaults[o].format&&"DIV"===r[0].nodeName?r.text():r.val(),null!=e){if("outputs"===o){if(""===e.trim())continue;isNaN(e)?(t.outputMap=JSON.parse(e),i=0,a=!1,Object.keys(t.outputMap).forEach(function(e){isNaN(e)?(i++,delete t.outputMap[e]):(t.outputMap[e]=t.outputMap[e]+"","-1"!==t.outputMap[e]?(i++,t.outputMap[e]!==e?a=!0:delete t.outputMap[e]):a=!0)}),e=i,a&&(t.changed=!0)):e=parseInt(e)}d._def.defaults[o].type&&"_ADD_"==e&&(e=""),!function(e,t){try{return e==t?1:JSON.stringify(e)===JSON.stringify(t)}catch(e){}}(d[o],e)&&(d._def.defaults[o].type&&((r=RED.nodes.node(d[o]))&&((s=r.users).splice(s.indexOf(d),1),RED.events.emit("nodes:change",r)),(r=RED.nodes.node(e))&&(r.users.push(d),RED.events.emit("nodes:change",r))),t.changes[o]=d[o],d[o]=e,t.changed=!0)}}d._def.credentials&&(n=d._def.credentials,n=function(e,t,o){var n,i=!1;e.credentials?e.credentials._||(e.credentials._={}):e.credentials={_:{}};for(n in t)if(t.hasOwnProperty(n)){var a=$("#"+o+"-"+n);if(0<a.length){a=a.val();if("password"==t[n].type){if(e.credentials["has_"+n]=""!==a,"__PWRD__"==a)continue;i=!0}(e.credentials[n]=a)!=e.credentials._[n]&&(i=!0)}}return i}(d,n,this.inputClass),t.changed=t.changed||n)}}}),function(){function n(t,o){var n;t.on("change keyup paste",function(){n=n||setTimeout(function(){var e=o(t.val());t.toggleClass("input-error",!!e),n=null})})}RED.editor.registerEditPane("editor-tab-subflow-module",function(i){return{label:RED._("editor-tab.module"),name:RED._("editor-tab.module"),iconClass:"fa fa-cube",create:function(e){var t=i,o=($('<form class="dialog-form form-horizontal" autocomplete="off"><div class="form-row"><label for="subflow-input-module-module" data-i18n="[append]editor:subflow.module"><i class="fa fa-cube"></i> </label><input style="width: calc(100% - 110px)" type="text" id="subflow-input-module-module" data-i18n="[placeholder]common.label.name"></div><div class="form-row"><label for="subflow-input-module-type" data-i18n="[append]editor:subflow.type"> </label><input style="width: calc(100% - 110px)" type="text" id="subflow-input-module-type"></div><div class="form-row"><label for="subflow-input-module-version" data-i18n="[append]editor:subflow.version"></label><input style="width: calc(100% - 110px)" type="text" id="subflow-input-module-version" data-i18n="[placeholder]editor:subflow.versionPlaceholder"></div><div class="form-row"><label for="subflow-input-module-desc" data-i18n="[append]editor:subflow.desc"></label><input style="width: calc(100% - 110px)" type="text" id="subflow-input-module-desc"></div><div class="form-row"><label for="subflow-input-module-license" data-i18n="[append]editor:subflow.license"></label><input style="width: calc(100% - 110px)" type="text" id="subflow-input-module-license"></div><div class="form-row"><label for="subflow-input-module-author" data-i18n="[append]editor:subflow.author"></label><input style="width: calc(100% - 110px)" type="text" id="subflow-input-module-author" data-i18n="[placeholder]editor:subflow.authorPlaceholder"></div><div class="form-row"><label for="subflow-input-module-keywords" data-i18n="[append]editor:subflow.keys"></label><input style="width: calc(100% - 110px)" type="text" id="subflow-input-module-keywords" data-i18n="[placeholder]editor:subflow.keysPlaceholder"></div></form>').appendTo(e),t.meta||{});["module","type","version","author","desc","keywords","license"].forEach(function(e){$("#subflow-input-module-"+e).val(o[e]||"")}),$("#subflow-input-module-type").attr("placeholder",t.id),n($("#subflow-input-module-module"),function(e){var t=(e=e.trim()).length<215;return t=(t=t&&!/^[._]/.test(e))&&!/[A-Z]/.test(e),(t=e!==encodeURIComponent(e)?!!(e=/^@([^\/]+)\/([^\/]+)$/.exec(e))&&(t&&e[1]===encodeURIComponent(e[1])&&e[2]===encodeURIComponent(e[2])):t)?"":"Invalid module name"}),n($("#subflow-input-module-version"),function(e){return""===(e=e.trim())||/^(\d|[1-9]\d*)\.(\d|[1-9]\d*)\.(\d|[1-9]\d*)(-(0|[1-9A-Za-z-][0-9A-Za-z-]*|[0-9]*[A-Za-z-][0-9A-Za-z-]*)(\.(0|[1-9A-Za-z-][0-9A-Za-z-]*|[0-9]*[A-Za-z-][0-9A-Za-z-]*))*)?(\+[0-9A-Za-z-]+(\.[0-9A-Za-z-]+)*)?$/.test(e)?"":"Invalid version number"}),(t={types:(e=["none","Apache-2.0","BSD-3-Clause","BSD-2-Clause","GPL-2.0","GPL-3.0","MIT","MPL-2.0","CDDL-1.0","EPL-2.0"]).map(function(e){return{value:e,label:"none"===e?RED._("editor:subflow.licenseNone"):e,hasValue:!1}})}).types.push({value:"_custom_",label:RED._("editor:subflow.licenseOther"),icon:"red/images/typedInput/az.svg"}),o.license?-1<e.indexOf(o.license)?t.default=o.license:t.default="_custom_":t.default="none",$("#subflow-input-module-license").typedInput(t)},resize:function(e){},close:function(){},apply:function(e){var t,o,n=function(){var t,o={},e=(["module","type","version","author","desc","keywords"].forEach(function(e){(t=$("#subflow-input-module-"+e).val().trim())&&(o[e]=t)}),$("#subflow-input-module-license").typedInput("type"));"_custom_"===e?(t=$("#subflow-input-module-license").val())&&(o.license=t):"none"!==e&&(o.license=e);return o}();t=i.meta,o=n,JSON.stringify(t)!==JSON.stringify(o)&&(e.changes.meta=i.meta,i.meta=n,e.changed=!0)}}})}(),RED.editor.registerTypeEditor("_buffer",{show:function(i){var r,a,s=i.value,e=i.cancel,t=i.complete,d=(0===$("script[data-template-name='_buffer']").length&&$('<script type="text/x-red" data-template-name="_buffer"><div id="red-ui-editor-type-buffer-panels"><div id="red-ui-editor-type-buffer-panel-str" class="red-ui-panel"><div class="form-row" style="margin-bottom: 3px; text-align: right;"><button class="red-ui-editor-type-buffer-type red-ui-button red-ui-button-small"><i class="fa fa-exclamation-circle"></i> <span id="red-ui-editor-type-buffer-type-string" data-i18n="bufferEditor.modeString"></span><span id="red-ui-editor-type-buffer-type-array" data-i18n="bufferEditor.modeArray"></span></button></div><div class="form-row node-text-editor-row"><div class="node-text-editor" id="red-ui-editor-type-buffer-str"></div></div></div><div id="red-ui-editor-type-buffer-panel-bin" class="red-ui-panel"><div class="form-row node-text-editor-row" style="margin-top: 10px; margin-bottom:0;"><div class="node-text-editor" id="red-ui-editor-type-buffer-bin"></div></div></div></div><\/script>').appendTo("#red-ui-editor-node-configs"),RED.view.state(RED.state.EDITING),[]),o={title:i.title,focusElement:i.focusElement,width:"inherit",buttons:[{id:"node-dialog-cancel",text:RED._("common.label.cancel"),click:function(){e&&e(),RED.tray.close()}},{id:"node-dialog-ok",text:RED._("common.label.done"),class:"primary",click:function(){d.saveView(),t&&t(JSON.stringify(r),null,d),RED.tray.close()}}],resize:function(e){var t=$("#dialog-form").height();a&&a.resize(t)},open:function(e){function n(e){for(var t=!0,o="string"==typeof e,n=[],i=0,a=(r=o?function(e){for(var t=[],o=0,n=e.length,o=0;o<n;o++){var i=e.charCodeAt(o);i<128?t.push(i):(i<2048?t.push(192|i>>6):(i<55296||57344<=i?t.push(224|i>>12):(o++,i=65536+((1023&i)<<10|1023&e.charAt(o)),t.push(240|i>>18),t.push(128|i>>12&63)),t.push(128|i>>6&63)),t.push(128|63&i))}return t}(e):e).length,i=0;i<a;i++){var s=parseInt(r[i]);if(!o&&(isNaN(s)||s<0||255<s)){t=!1;break}0<i&&(i%8==0?i%16==0?n.push("\n"):n.push(" "):n.push(" ")),n.push((s<16?"0":"")+s.toString(16).toUpperCase())}return t&&($("#red-ui-editor-type-buffer-type-string").toggle(o),$("#red-ui-editor-type-buffer-type-array").toggle(!o),bufferBinEditor.setValue(n.join(""),1)),t}function t(){var e=d.getValue(),t=!1;if(/^[\s]*\[[\s\S]*\][\s]*$/.test(e)){t=!0;try{var o=JSON.parse(e),t=n(o)}catch(e){t=!1}}t||n(e)}var o,e=RED.editor.buildEditForm(e.find(".red-ui-tray-body"),"dialog-form","_buffer","editor");d=RED.editor.createEditor({id:"red-ui-editor-type-buffer-str",value:s||"",stateId:RED.editor.generateViewStateId("buffer",i,""),focus:!0,mode:"ace/mode/text"}),bufferBinEditor=RED.editor.createEditor({id:"red-ui-editor-type-buffer-bin",value:"",stateId:!1,focus:!1,mode:"ace/mode/text",readOnly:!0});d.getSession().on("change",function(){clearTimeout(o),o=setTimeout(t,200)}),t(),e.i18n(),a=RED.panels.create({id:"red-ui-editor-type-buffer-panels",resize:function(e,t){var o=$("#red-ui-editor-type-buffer-panel-str"),o=(e-=$(o.children()[0]).outerHeight(!0),$(o.children()[1])),e=(e-=parseInt(o.css("marginTop"))+parseInt(o.css("marginBottom")),$("#red-ui-editor-type-buffer-str").css("height",e-5+"px"),d.resize(),$("#red-ui-editor-type-buffer-panel-bin")),o=$(e.children()[0]);t-=parseInt(o.css("marginTop"))+parseInt(o.css("marginBottom")),$("#red-ui-editor-type-buffer-bin").css("height",t-5+"px"),bufferBinEditor.resize()}}),$(".red-ui-editor-type-buffer-type").on("click",function(e){e.preventDefault(),RED.sidebar.help.set(RED._("bufferEditor.modeDesc"))})},close:function(){i.onclose&&i.onclose(),d.destroy(),bufferBinEditor.destroy()},show:function(){}};RED.tray.show(o)}}),RED.editor.codeEditor=function(){const o="monaco",n=o,e={lib:n,options:{}};var i=null,a=!1;return{init:function(){var t=RED.editor.codeEditor.settings.lib===o?o:"ace";try{var e=RED.utils.getBrowserInfo();(i=RED.editor.codeEditor[t])&&(t!=o||!e.ie&&window.monaco)||(i=RED.editor.codeEditor[n]),a=i.init()}catch(e){i=null,console.warn("Problem initialising '"+t+"' code editor",e)}a||(i=RED.editor.codeEditor[n],a=i.init())},get settings(){return RED.settings.get("codeEditor")||e},get editor(){return i},create:function(e){return e||(console.warn("createEditor() options are missing"),e={}),this.editor.type===o&&(e.element||e.id||(e.id="node-backwards-compatability-dummy-editor"),e.element=e.element||$("#"+e.id)[0],e.element||(console.warn("createEditor() options.element or options.id is not valid",e),$("#dialog-form").append('<div id="'+e.id+'" style="display: none;" />'))),this.editor.create(e)}}}(),RED.editor.colorPicker=RED.colorPicker={create:function(c){function u(e){var t,o;"none"===e?(i.addClass("red-ui-color-picker-cell-none").css({"background-color":"",opacity:1}),n.css({"border-color":""})):(t=parseFloat(b.val()),i.removeClass("red-ui-color-picker-cell-none").css({"background-color":e,opacity:t}),"#"===(o=RED.utils.getDarkerColor(e))[0]?o+=Math.round(255*Math.floor(100*t)/100).toString(16):o="",n.css({"border-color":o})),c.hasOwnProperty("opacity")&&$(".red-ui-color-picker-opacity-slider-overlay").css({"background-image":"linear-gradient(90deg, transparent 0%, "+e+" 100%)"})}var e=c.value,t=c.id,p=c.palette||[],f=c.cellWidth||30,h=c.cellHeight||30,g=c.cellMargin||2,m=c.cellPerRow||6,o=$("<div>",{style:"display:inline-block"}),v=$("<input/>",{id:t,type:"hidden",value:e}).appendTo(o),b=$("<input/>",{id:t+"-opacity",type:"hidden",value:c.hasOwnProperty("opacity")?c.opacity:"1"}).appendTo(o),y=$('<button type="button" class="red-ui-button red-ui-editor-node-appearance-button">').appendTo(o),n=($('<i class="fa fa-caret-down"></i>').appendTo(y),$("<div>",{class:"red-ui-search-result-node"}).appendTo(y)),i=($("<div>",{class:"red-ui-color-picker-cell-none"}).appendTo(n),$("<div>",{class:"red-ui-color-picker-swatch"}).appendTo(n));return y.on("click",function(e){var t,o,n,i=p.length,a=$("<div/>",{class:"red-ui-color-picker"}).css({width:(f+g+g)*m+"px",height:Math.ceil(i/m)*(h+g+g)+"+px"}),s=0,r=null,d=(r=$("<div/>").appendTo(a),$("<input>",{type:"text",value:v.val()}).appendTo(r)),i=d,l=(d.on("change",function(e){var t=d.val();c.defaultValue&&!t.match(/^([a-z]+|#[0-9a-fA-F]{6}|#[0-9a-fA-F]{3})$/)&&(t=c.defaultValue),v.val(t).trigger("change"),u(t)}),c.none&&(r=$("<div/>").appendTo(a),$("<button/>",{class:"red-ui-color-picker-cell red-ui-color-picker-cell-none"}).css({width:f+"px",height:h+"px",margin:g+"px"}).appendTo(r).on("click",function(e){e.preventDefault(),d.val("none"),d.trigger("change")})),p.forEach(function(t){s%m==0&&(r=$("<div/>").appendTo(a)),$("<button/>",{class:"red-ui-color-picker-cell"}).css({width:f+"px",height:h+"px",margin:g+"px",backgroundColor:t,"border-color":RED.utils.getDarkerColor(t)}).appendTo(r).on("click",function(e){e.preventDefault(),d.val(t),d.trigger("change")}),s++}),(c.none||c.hasOwnProperty("opacity"))&&(r=$("<div/>").appendTo(a),c.hasOwnProperty("opacity")&&((t=$("<div>",{class:"red-ui-color-picker-opacity-slider"}).appendTo(r)).on("mousedown",function(e){e.target!==o[0]&&(e=e.offsetX/t.width(),o.css({left:e*(t.width()-o.outerWidth())+"px"}),e=Math.floor(100*e),b.val(e/100),n.text(e+"%"),u(v.val()))}),$("<div>",{class:"red-ui-color-picker-opacity-slider-overlay"}).appendTo(t),o=$("<div>",{class:"red-ui-color-picker-opacity-slider-handle red-ui-button red-ui-button-small"}).appendTo(t).draggable({containment:"parent",axis:"x",drag:function(e,t){t=Math.max(0,t.position.left/($(this).parent().width()-$(this).outerWidth())),t=Math.floor(100*t);b.val((t=99===t?100:t)/100),n.text(t+"%"),u(v.val())}}),n=$("<small></small>").appendTo(r),setTimeout(function(){o.css({left:parseFloat(b.val())*(t.width()-o.outerWidth())+"px"}),n.text(Math.floor(100*b.val())+"%")},50))),RED.popover.panel(a));setTimeout(function(){u(v.val())},50),l.show({target:y,onclose:function(){y.focus()}}),i&&i.focus()}),setTimeout(function(){u(v.val())},50),o}},RED.editor.envVarList=function(){var E="en-US",D=["str","num","bool","json","bin","env"],R=["str","num","bool","json","bin","env","cred"];function x(e,t,o){if(e){if(e[o])return e[o];if(o){o=o.substring(0,2);if(e[o])return e[o]}}return t}return{create:function(b,y){var e,w="subflow"===y.type,o=(b.css({"min-height":"150px","min-width":"450px"}).editableList({header:w?$('<div><div><div></div><div data-i18n="common.label.name"></div><div data-i18n="editor-tab.defaultValue"></div><div></div></div></div>'):void 0,addItem:function(t,e,o){w&&t.addClass("red-ui-editor-subflow-env-editable");var n,s,i,a,r,d,l,c,u,p,f=$("<div/>").appendTo(t),h=null,g=null,h=$("<input/>",{class:"node-input-env-name",type:"text",placeholder:RED._("common.label.name")}).attr("autocomplete","disable").appendTo(f).val(o.name),g=$("<input/>",{style:"width:100%",class:"node-input-env-value",type:"text"}).attr("autocomplete","disable").appendTo(f),m=(m=o.ui&&o.ui.opts&&o.ui.opts.types)||(w?D:R),m=(g.typedInput({default:"str",types:m}),g.typedInput("type",o.type),"cred"!==o.type||o.value?g.typedInput("value",o.value):y.credentials&&y.credentials[o.name]?g.typedInput("value",y.credentials[o.name]):y.credentials&&y.credentials["has_"+o.name]?g.typedInput("value","__PWRD__"):g.typedInput("value",""),o.nameField=h,o.valueField=g,$("<a/>",{href:"#",class:"red-ui-editableList-item-remove red-ui-button red-ui-button-small"}).appendTo(f)),v=($("<i/>",{class:"fa "+(o.parent?"fa-reply":"fa-remove")}).appendTo(m),RED.popover.tooltip(m,RED._("subflow.env.remove")));m.on("click",function(e){e.preventDefault(),v.close(),t.parent().addClass("red-ui-editableList-item-deleting"),t.fadeOut(300,function(){b.editableList("removeItem",o)})}),w&&("cred"===o.type?(o.ui=o.ui||{icon:"",type:"cred"},o.ui.type="cred"):o.ui=o.ui||{icon:"",type:"input",opts:{types:D}},o.ui.label=o.ui.label||{},o.ui.type=o.ui.type||"input","cred"===o.ui.type&&o.ui.opts&&o.ui.opts.types&&(o.ui.type="input"),n=$("<div/>").appendTo(t).hide(),$('<a href="#"><i class="fa fa-angle-right"></a>').prependTo(f).on("click",function(e){e.preventDefault(),$(this).hasClass("expanded")?(n.slideUp(),$(this).removeClass("expanded")):(n.slideDown(),$(this).addClass("expanded"))}),m=n,s=o.ui,f=h,i=g,m.addClass("red-ui-editor-subflow-env-ui-row"),g=$("<div></div>").appendTo(m),$("<div></div>").appendTo(g),$("<div>").text(RED._("editor.icon")).appendTo(g),$("<div>").text(RED._("editor.label")).appendTo(g),$("<div>").text(RED._("editor.inputType")).appendTo(g),g=$("<div></div>").appendTo(m),$('<div><i class="red-ui-editableList-item-handle fa fa-bars"></i></div>').appendTo(g),a={input:{types:D},select:{opts:[]},spinner:{},cred:{}},s.opts?a[s.type]=s.opts:s.opts=a[s.type],m=$("<div></div>").appendTo(g),(r=$('<a href="#"></a>').appendTo(m)).on("click",function(e){e.preventDefault();e=s.icon||"",e=e?RED.utils.separateIconPath(e):{};RED.editor.iconPicker.show(r,null,e,!0,function(e){r.empty();var e=e||"",t=RED.utils.separateIconPath(e);t&&$('<i class="fa"></i>').addClass(t.file).appendTo(r),s.icon=e})}),s.icon&&(m=RED.utils.separateIconPath(s.icon),$('<i class="fa '+m.file+'"></i>').appendTo(r)),m=$("<div></div>").appendTo(g),u=s.label&&s.label[E]||"",c=$('<input type="text">').val(u).appendTo(m),(s.labelField=c).on("change",function(e){s.label=s.label||{};var t=$(this).val().trim();""===t?delete s.label[E]:s.label[E]=t}),u=$('<span class="red-ui-editor-subflow-env-lang-icon"><i class="fa fa-language"></i></span>').appendTo(m),RED.popover.tooltip(u,function(){var e=Object.keys(s.label),o=$("<div>");return-1===e.indexOf(E)&&(e.push(E),e.sort()),e.forEach(function(e){var t=$("<div>").appendTo(o);$("<span>").css({display:"inline-block",width:"120px"}).text(RED._("languages."+e)+(e===E?"*":"")).appendTo(t),$("<span>").text(s.label[e]||"").appendTo(t)}),o}),f.on("change",function(e){c.attr("placeholder",$(this).val())}),m=$("<div></div>").appendTo(g),p=$('<input type="text">').css("width","100%").appendTo(m),"input"===s.type&&p.val(s.opts.types.join(",")),p.typedInput({types:[{value:"input",label:RED._("editor.inputs.input"),icon:"fa fa-i-cursor",showLabel:!1,multiple:!0,options:[{value:"str",label:RED._("editor.types.str"),icon:"red/images/typedInput/az.svg"},{value:"num",label:RED._("editor.types.num"),icon:"red/images/typedInput/09.svg"},{value:"bool",label:RED._("editor.types.bool"),icon:"red/images/typedInput/bool.svg"},{value:"json",label:RED._("editor.types.json"),icon:"red/images/typedInput/json.svg"},{value:"bin",label:RED._("editor.types.bin"),icon:"red/images/typedInput/bin.svg"},{value:"env",label:RED._("editor.types.env"),icon:"red/images/typedInput/env.svg"},{value:"cred",label:RED._("editor.types.cred"),icon:"fa fa-lock"}],default:D,valueLabel:function(e,t){e.css("padding",0);var e=$('<div class="red-ui-editor-subflow-env-input-type"></div>').appendTo(e),o=$('<div class="placeholder-input">').appendTo(e);$('<span><i class="fa fa-i-cursor"></i></span>').appendTo(o),t.length?t.forEach(function(e){var t;/^fa /.test(e.icon)?(t=$("<span>",{style:"max-width:14px; padding: 0 3px; margin-top:-4px; margin-left: 1px"}).appendTo(o),$("<i>",{class:e.icon}).appendTo(t)):$("<img>",{src:e.icon,style:"max-width:14px; padding: 0 3px; margin-top:-4px; margin-left: 1px"}).appendTo(o)}):$('<span class="red-ui-editor-subflow-env-input-type-placeholder"></span>').text(RED._("editor.selectType")).appendTo(o)}},{value:"cred",label:RED._("typedInput.type.cred"),icon:"fa fa-lock",showLabel:!1,valueLabel:function(e,t){e.css("padding",0);e=$('<div class="red-ui-editor-subflow-env-input-type">').css({"border-top-right-radius":"4px","border-bottom-right-radius":"4px"}).appendTo(e);$('<div class="placeholder-input">').html("&bull;&bull;&bull;&bull;&bull;&bull;&bull;&bull;").appendTo(e)}},{value:"select",label:RED._("editor.inputs.select"),icon:"fa fa-tasks",showLabel:!1,valueLabel:function(e,t){e.css("padding","0"),l=$("<select></select>").appendTo(e),s.opts&&Array.isArray(s.opts.opts)&&s.opts.opts.forEach(function(e){var t=x(e.l,e.l["en-US"]||e.v,E);$("<option>").val(e.v).text(t).appendTo(l)}),l.on("change",function(e){var t=l.val();i.typedInput("value",t)}),l.val(i.typedInput("value"))},expand:{icon:"fa-caret-down",minWidth:400,content:function(e){var e=$('<div class="red-ui-editor-subflow-ui-edit-panel">').appendTo(e),a=$("<ol>").appendTo(e).editableList({header:$("<div><div>"+RED._("editor.select.label")+"</div><div>"+RED._("editor.select.value")+"</div></div>"),addItem:function(e,t,n){var o=$("<div>").appendTo(e),i=x(n.l,"",E),i=(n.label=$('<input type="text">').val(i).appendTo(o),n.label.on("keydown",function(e){13===e.keyCode&&(n.input.focus(),e.preventDefault())}),$('<span class="red-ui-editor-subflow-env-lang-icon"><i class="fa fa-language"></i></span>').appendTo(o));RED.popover.tooltip(i,function(){return E}),n.input=$('<input type="text">').val(n.v).appendTo(e),n.input.on("keydown",function(e){var t,o;13===e.keyCode&&((o=a.editableList("indexOf",n))+1===a.editableList("length")?(t={},a.editableList("addItem",t),setTimeout(function(){t.label&&t.label.focus()},100)):(o=a.editableList("getItemAt",o+1)).label&&o.label.focus(),e.preventDefault())})},sortable:!0,removable:!0,height:160});return 0<s.opts.opts.length?s.opts.opts.forEach(function(e){a.editableList("addItem",$.extend(!0,{},e))}):a.editableList("addItem",{}),{onclose:function(){var e=a.editableList("items"),i=[];e.each(function(e,t){var t=t.data("data"),o=t.label.val().trim(),n=t.input.val();0<o.length&&(t.l=t.l||{},t.l[E]=o),t.v=n,(0<o.length||0<n.length)&&(o={l:t.l,v:t.v},i.push(o))}),s.opts.opts=i,p.typedInput("value",Date.now())}}}}},{value:"checkbox",label:RED._("editor.inputs.checkbox"),icon:"fa fa-check-square-o",showLabel:!1,valueLabel:function(e,t){e.css("padding",0),(d=$('<input type="checkbox">').appendTo(e)).on("change",function(e){i.typedInput("value",$(this).prop("checked")?"true":"false")}),d.prop("checked","true"===i.typedInput("value"))}},{value:"spinner",label:RED._("editor.inputs.spinner"),icon:"fa fa-sort-numeric-asc",showLabel:!1,valueLabel:function(e,t){e.css("padding",0);var e=$('<div class="red-ui-editor-subflow-env-input-type"></div>').appendTo(e),e=$('<div class="placeholder-input">').appendTo(e),o=($('<span><i class="fa fa-sort-numeric-asc"></i></span>').appendTo(e),s.opts&&s.opts.min),n=s.opts&&s.opts.max,i="";void 0!==o&&void 0!==n?i=Math.min(o,n)+" - "+Math.max(o,n):void 0!==o?i="> "+o:void 0!==n&&(i="< "+n),$("<span>").css("margin-left","15px").text(i).appendTo(e)},expand:{icon:"fa-caret-down",content:function(e){var e=$('<div class="red-ui-editor-subflow-ui-edit-panel">').appendTo(e),t=(e.css("padding","8px 5px"),s.opts.min),o=s.opts.max,n=$('<input type="number" style="margin-bottom:0; width:60px">'),i=(n.val(t),$('<input type="number" style="margin-bottom:0; width:60px">'));return i.val(o),$('<div class="form-row" style="margin-bottom:3px"><label>'+RED._("editor.spinner.min")+"</label></div>").append(n).appendTo(e),$('<div class="form-row" style="margin-bottom:0"><label>'+RED._("editor.spinner.max")+"</label></div>").append(i).appendTo(e),{onclose:function(){var e=n.val().trim(),t=i.val().trim();""!==e?s.opts.min=parseInt(e):delete s.opts.min,""!==t?s.opts.max=parseInt(t):delete s.opts.max,p.typedInput("value",Date.now())}}}}},{value:"none",label:RED._("editor.inputs.none"),icon:"fa fa-times",hasValue:!1},{value:"hide",label:RED._("editor.inputs.hidden"),icon:"fa fa-ban",hasValue:!1}],default:"none"}).on("typedinputtypechange",function(e,t){switch(s.type=$(this).typedInput("type"),s.opts=a[s.type],"input"===s.type?p.typedInput("value",s.opts.types.join(",")):p.typedInput("value",Date.now()),s.type){case"input":i.typedInput("types",s.opts.types);break;case"select":i.typedInput("types",["str"]);break;case"checkbox":i.typedInput("types",["bool"]);break;case"spinner":i.typedInput("types",["num"]);break;case"cred":i.typedInput("types",["cred"]);break;default:i.typedInput("types",D)}"checkbox"===s.type?i.typedInput("type","bool"):"spinner"===s.type&&i.typedInput("type","num"),"checkbox"!==s.type&&(d=null)}).on("change",function(e,t){var o;"input"===s.type&&(o=p.typedInput("value"),s.opts.types=""===o?["str"]:o.split(","),i.typedInput("types",s.opts.types))}),i.on("change",function(e){d&&d.prop("checked","true"===$(this).typedInput("value"))}),p.typedInput("type",s.type),h.trigger("change"))},sortable:".red-ui-editableList-item-handle",removable:!1}),{}),n=[];if(!/^subflow:/.test(y.type)||(e=RED.nodes.subflow(y.type.substring(8))).env&&e.env.forEach(function(e){var t={name:e.name,parent:{type:e.type,value:e.value,ui:e.ui}};n.push(t),o[e.name]=t}),y.env)for(var t=0;t<y.env.length;t++){var i=y.env[t];o.hasOwnProperty(i.name)?(o[i.name].type=i.type,o[i.name].value=i.value):n.push({name:i.name,type:i.type,value:i.value,ui:i.ui})}n.forEach(function(e){e.parent&&e.parent.ui&&"hide"===e.parent.ui.type||!w&&e.parent||b.editableList("addItem",JSON.parse(JSON.stringify(e)))})},setLocale:function(e,t){E=e,t&&t.editableList("items").each(function(e,t){var o=$(this).data("data"),n=o.ui.labelField;n.val(x(o.ui.label,"",E)),n.timeout&&(clearTimeout(n.timeout),delete n.timeout),n.addClass("input-updated"),n.timeout=setTimeout(function(){delete n.timeout,n.removeClass("input-updated")},3e3)})},lookupLabel:x,DEFAULT_ENV_TYPE_LIST:D,DEFAULT_ENV_TYPE_LIST_INC_CRED:R}}(),function(){var h={};RED.editor.registerTypeEditor("_expression",{show:function(n){var p,d,f,i,a=n.parent||"_",s=n.value,e=n.cancel,t=n.complete,r=(0===$("script[data-template-name='_expression']").length&&$('<script type="text/x-red" data-template-name="_expression"><div id="red-ui-editor-type-expression-panels"><div id="red-ui-editor-type-expression-panel-expr" class="red-ui-panel"><div class="form-row" style="margin-bottom: 3px; text-align: right;"><button class="red-ui-editor-type-expression-legacy red-ui-button red-ui-button-small"><i class="fa fa-exclamation-circle"></i> <span data-i18n="expressionEditor.compatMode"></span></button><button id="red-ui-editor-type-expression-reformat" class="red-ui-button red-ui-button-small"><span data-i18n="expressionEditor.format"></span></button></div><div class="form-row node-text-editor-row"><div class="node-text-editor" id="red-ui-editor-type-expression"></div></div></div><div id="red-ui-editor-type-expression-panel-info" class="red-ui-panel"><div class="form-row"><ul id="red-ui-editor-type-expression-tabs"></ul><div id="red-ui-editor-type-expression-tab-help" class="red-ui-editor-type-expression-tab-content hide"><div><select id="red-ui-editor-type-expression-func"></select><button id="red-ui-editor-type-expression-func-insert" class="red-ui-button" data-i18n="expressionEditor.insert"></button></div><div id="red-ui-editor-type-expression-help"></div></div><div id="red-ui-editor-type-expression-tab-test" class="red-ui-editor-type-expression-tab-content hide"><div><span style="display: inline-block; width: calc(50% - 5px);"><span data-i18n="expressionEditor.data"></span><button style="float: right; margin-right: 5px;" id="node-input-example-reformat" class="red-ui-button red-ui-button-small"><span data-i18n="jsonEditor.format"></span></button></span><span style="display: inline-block; margin-left: 10px; width: calc(50% - 5px);" data-i18n="expressionEditor.result"></span></div><div style="display: inline-block; width: calc(50% - 5px);" class="node-text-editor" id="red-ui-editor-type-expression-test-data"></div><div style="display: inline-block; margin-left: 10px; width:calc(50% - 5px);" class="node-text-editor" id="red-ui-editor-type-expression-test-result"></div></div></div></div></div><\/script>').appendTo("#red-ui-editor-node-configs"),RED.view.state(RED.state.EDITING),{title:n.title,focusElement:n.focusElement,width:"inherit",buttons:[{id:"node-dialog-cancel",text:RED._("common.label.cancel"),click:function(){e&&e(),RED.tray.close()}},{id:"node-dialog-ok",text:RED._("common.label.done"),class:"primary",click:function(){$("#red-ui-editor-type-expression-help").text(""),p.saveView(),t&&t(p.getValue(),p.getCursorPosition(),p),RED.tray.close()}}],resize:function(e){var t=$("#dialog-form").height();i&&i.resize(t)},open:function(e){function t(){var e,t,o=d.getValue(),n=p.getValue(),i=!1,a=/(^|[^a-zA-Z0-9_'".])msg([^a-zA-Z0-9_'"]|$)/.test(n);$(".red-ui-editor-type-expression-legacy").toggle(a);try{(t=jsonata(n)).assign("flowContext",function(e){return i=!0,null}),t.assign("globalContext",function(e){return i=!0,null})}catch(e){return void f.setValue(RED._("expressionEditor.errors.invalid-expr",{message:e.message}),-1)}try{e=JSON.parse(o)}catch(e){return void f.setValue(RED._("expressionEditor.errors.invalid-msg",{message:e.toString()}))}try{var s,r=t.evaluate(a?{msg:e}:e);i?f.setValue(RED._("expressionEditor.errors.context-unsupported"),-1):(s=void 0!==r?JSON.stringify(r,null,4):RED._("expressionEditor.noMatch"),f.setValue(s,-1))}catch(e){f.setValue(RED._("expressionEditor.errors.eval",{message:e.message}),-1)}}e.find(".red-ui-tray-body").addClass("red-ui-editor-type-expression");var o,e=RED.editor.buildEditForm(e.find(".red-ui-tray-body"),"dialog-form","_expression","editor"),l=$("#red-ui-editor-type-expression-func"),c=(Object.keys(jsonata.functions).forEach(function(e){l.append($("<option></option>").val(e).text(e))}),l.on("change",function(e){var t=$(this).val(),o="<h5>"+t+"("+RED._("jsonata:"+t+".args",{defaultValue:""})+")</h5>",t=RED.utils.renderMarkdown(RED._("jsonata:"+t+".desc",{defaultValue:""}));$("#red-ui-editor-type-expression-help").html(o+"<p>"+t+"</p>")}),p=RED.editor.createEditor({id:"red-ui-editor-type-expression",value:"",mode:"ace/mode/jsonata",stateId:n.stateId,focus:!0,options:{enableBasicAutocompletion:!0,enableSnippets:!0,enableLiveAutocompletion:!0}}),null),u=-1,e=(p.getSession().setValue(s||"",-1),"ace"==p.type&&p.on("changeSelection",function(){var e=p.getCursorPosition(),t=p.getSession().getTokenAt(e.row,e.column);if(t!==c||t&&/paren/.test(t.type)&&e.column!==u){var o,n=null;if((c=t)&&"keyword"===t.type)o=e.row,n=t;else for(var i=0,a=!1,s=t?("paren.rparen"===t.type&&(u=e.column,i=e.column-(t.start+t.value.length)),o=e.row,t.index):(o=e.row-1,-1);null===n&&-1<o;){var r=p.getSession().getTokens(o);for(-1===s&&(s=r.length-1);-1<s;){var d=r[s].type;if(a){if("keyword"===d){n=r[s];break}a=!1}"paren.lparen"===d?i-=r[s].value.length:"paren.rparen"===d&&(i+=r[s].value.length),i<0&&(a=!0,i=0),s--}n||o--}p.session.removeMarker(null),n&&l.val(n.value).trigger("change")}}),e.i18n(),$("#red-ui-editor-type-expression-func-insert").on("click",function(e){e.preventDefault();p.getCursorPosition();e=l.val(),e=jsonata.getFunctionSnippet(e);p.insertSnippet(e),p.focus()}),$("#red-ui-editor-type-expression-reformat").on("click",function(e){e.preventDefault();e=p.getValue()||"";try{e=jsonata.format(e)}catch(e){}p.getSession().setValue(e||"",-1)}),l.change(),RED.tabs.create({element:$("#red-ui-editor-type-expression-tabs"),onchange:function(e){$(".red-ui-editor-type-expression-tab-content").hide(),e.content.show(),r.resize()}}));e.addTab({id:"expression-help",label:RED._("expressionEditor.functionReference"),content:$("#red-ui-editor-type-expression-tab-help")}),e.addTab({id:"expression-tests",label:RED._("expressionEditor.test"),content:$("#red-ui-editor-type-expression-tab-test")}),d=RED.editor.createEditor({id:"red-ui-editor-type-expression-test-data",value:h[a]||'{\n "payload": "hello world"\n}',stateId:!1,focus:!1,mode:"ace/mode/json",lineNumbers:!1}),$(".red-ui-editor-type-expression-legacy").on("click",function(e){e.preventDefault(),RED.sidebar.help.set(RED._("expressionEditor.compatModeDesc"))});d.getSession().on("change",function(){clearTimeout(o),o=setTimeout(t,200),h[a]=d.getValue()}),p.getSession().on("change",function(){clearTimeout(o),o=setTimeout(t,200)}),f=RED.editor.createEditor({id:"red-ui-editor-type-expression-test-result",value:"",stateId:!1,focus:!1,mode:"ace/mode/json",lineNumbers:!1,readOnly:!0}),i=RED.panels.create({id:"red-ui-editor-type-expression-panels",resize:function(e,t){var o=$("#red-ui-editor-type-expression-panel-expr"),o=(e-=$(o.children()[0]).outerHeight(!0),$(o.children()[1]));e-=parseInt(o.css("marginTop"))+parseInt(o.css("marginBottom")),$("#red-ui-editor-type-expression").css("height",e-5+"px"),p.resize(),t-=$("#red-ui-editor-type-expression-panel-info > .form-row > div:first-child").outerHeight(!0)+20,$(".red-ui-editor-type-expression-tab-content").height(t),$("#red-ui-editor-type-expression-test-data").css("height",t-25+"px"),d.resize(),$("#red-ui-editor-type-expression-test-result").css("height",t-25+"px"),f.resize()}}),$("#node-input-example-reformat").on("click",function(e){e.preventDefault();e=d.getValue()||"";try{e=JSON.stringify(JSON.parse(e),null,4)}catch(e){}d.getSession().setValue(e||"",-1)}),t()},close:function(){n.onclose&&n.onclose(),p.destroy(),d.destroy(),f.destroy()},show:function(){}});RED.tray.show(r)}})}(),RED.editor.iconPicker={show:function(e,s,r,n,d){var t=$('<div class="red-ui-icon-picker">'),o=$("<div>",{class:"red-ui-search-container"}).appendTo(t),l=(searchInput=$('<input type="text">').attr("placeholder",RED._("editor.searchIcons")).appendTo(o).searchBox({delay:50,change:function(){var o=$(this).val().trim();""===o?(l.find(".red-ui-icon-list-module").show(),l.find(".red-ui-icon-list-icon").show()):(l.find(".red-ui-icon-list-module").hide(),l.find(".red-ui-icon-list-icon").each(function(e,t){-1===$(t).data("icon").indexOf(o)?$(t).hide():$(t).show()}))}}),$("<div>").appendTo(t),$('<div class="red-ui-icon-list">').appendTo(t)),o=$('<div class="red-ui-icon-meta"></div>').appendTo(t),c=$("<span>").appendTo(o),i=($('<button type="button" class="red-ui-button red-ui-button-small">'+RED._("editor.useDefault")+"</button>").appendTo(o).on("click",function(e){e.preventDefault(),u.hide(),d(null)}),!s&&n&&l.addClass("red-ui-icon-list-dark"),setTimeout(function(){var o=RED.nodes.getIconSets();Object.keys(o).forEach(function(a){var e,t;n&&"font-awesome"!==a||0<(e=o[a]).length&&(t=$('<div class="red-ui-icon-list-module"></div>').text(a).appendTo(l),$('<i class="fa fa-cube"></i>').prependTo(t),e.forEach(function(e){var t=$("<div>",{class:"red-ui-icon-list-icon"}).appendTo(l),o=$("<div>",{class:"red-ui-search-result-node"}).appendTo(t),n=RED.settings.apiRootUrl+"icons/"+a+"/"+e,i=(t.data("icon",n),s&&(o.css({backgroundColor:s}),(i=RED.utils.getDarkerColor(s))!==s&&o.css("border-color",i)),$("<div/>",{class:"red-ui-palette-icon-container"}).appendTo(o));RED.utils.createIconElement(n,i,!0),r.module===a&&r.file===e&&t.addClass("selected"),t.on("mouseover",function(){c.text(e)}),t.on("mouseout",function(){c.html("&nbsp;")}),t.on("click",function(){u.hide(),d(a+"/"+e)})}))}),setTimeout(function(){i.remove()},50)},300),RED.utils.addSpinnerOverlay(l,!0)),u=RED.popover.panel(t);u.show({target:e}),t.slideDown(100),searchInput.trigger("focus")}},RED.editor.registerTypeEditor("_js",{show:function(t){var i,o=t.value,e=t.cancel,n=t.complete,a=(0===$("script[data-template-name='_js']").length&&$('<script type="text/x-red" data-template-name="_js"><div class="form-row node-text-editor-row"><div style="height: 200px;min-height: 150px;" class="node-text-editor" id="node-input-js"></div></div><\/script>').appendTo("#red-ui-editor-node-configs"),RED.view.state(RED.state.EDITING),{title:t.title,focusElement:t.focusElement,width:t.width||"inherit",buttons:[{id:"node-dialog-cancel",text:RED._("common.label.cancel"),click:function(){e&&e(),RED.tray.close()}},{id:"node-dialog-ok",text:RED._("common.label.done"),class:"primary",click:function(){i.saveView(),n&&n(i.getValue(),i.getCursorPosition(),i),RED.tray.close()}}],resize:function(e){for(var t=$("#dialog-form>div:not(.node-text-editor-row)"),o=($("#dialog-form>div.node-text-editor-row"),$("#dialog-form").height()),n=0;n<t.size();n++)o-=$(t[n]).outerHeight(!0);$(".node-text-editor").css("height",o+"px"),i.resize()},open:function(e){e=RED.editor.buildEditForm(e.find(".red-ui-tray-body"),"dialog-form","_js","editor");i=RED.editor.createEditor({id:"node-input-js",mode:t.mode||"ace/mode/javascript",stateId:t.stateId,focus:!0,value:o,globals:{msg:!0,context:!0,RED:!0,util:!0,flow:!0,global:!0,console:!0,Buffer:!0,setTimeout:!0,clearTimeout:!0,setInterval:!0,clearInterval:!0},extraLibs:t.extraLibs}),t.cursor&&!i._initState&&i.gotoLine(t.cursor.row+1,t.cursor.column,!1),e.i18n()},close:function(){t.onclose&&t.onclose(),i.destroy()},show:function(){}});RED.tray.show(a)}}),function(){var u;function h(e,t,o,n){var i="";if(0<e.children.length)switch(e.children[Math.max(0,Math.min(e.children.length-1,o))].type){case"string":i="";break;case"number":i=0;break;case"boolean":i=!0;break;case"null":i=null;break;case"object":i={};break;case"array":i=[]}if("array"===e.type)r=e.children.length;else for(var a={},s=(e.children.forEach(function(e){a[e.key]=!0}),2),r="item";a[r];)r="item-"+s++;o=g(r,i,e.depth+1,e,n);e.treeList.insertChildAt(o,t,!0),e.treeList.expand()}function g(e,t,o,n,a){var i,s,r,d,l,c={depth:o,type:typeof t},u=$('<span class="red-ui-editor-type-json-editor-label">'),p=(null!=e&&(i="string"==typeof(c.key=e)?'"'+e+'"':e,(s=$('<span class="red-ui-debug-msg-object-key red-ui-editor-type-json-editor-label-key">').text(i).appendTo(u)).addClass("red-ui-debug-msg-type-"+typeof e),n&&"array"===n.type&&s.addClass("red-ui-editor-type-json-editor-label-array-key"),a&&s.addClass("readonly"),s.on("click",function(e){var n;"array"===c.parent.type||a||(e.preventDefault(),e.stopPropagation(),e=Math.max(150,s.width()),n=$('<input type="text" class="red-ui-editor-type-json-editor-key">').css({width:e+"px"}).val(""+c.key).insertAfter(s).typedInput({types:["str"]}),$(document).on("mousedown.nr-ui-json-editor",function(e){for(var t=n.next(".red-ui-typedInput-container")[0],o=e.target;"BODY"!==o.nodeName&&o!==t&&!$(o).hasClass("red-ui-typedInput-options");)o=o.parentElement;"BODY"===o.nodeName&&(e=n.typedInput("value"),c.key=e,s.text("string"==typeof e?'"'+e+'"':e),n.remove(),s.show(),$(document).off("mousedown.nr-ui-json-editor"),$(document).off("keydown.nr-ui-json-editor"))}),$(document).on("keydown.nr-ui-json-editor",function(e){27===e.keyCode&&(n.remove(),s.show(),$(document).off("mousedown.nr-ui-json-editor"),$(document).off("keydown.nr-ui-json-editor"))}),s.hide())}),$("<span>").text(" : ").appendTo(u)),Array.isArray(t)?(c.expanded=o<2,c.type="array",c.deferBuild=2<=o,c.children=function(e,t,o,n){for(var i=[],a=e.length,s=0;s<a;s++)i.push(g(s,e[s],t,o,n));return i}(t,o+1,c,a)):null!==t&&"object"===c.type?(c.expanded=o<2,c.children=function(e,t,o,n){var i,a=[];for(i in e)e.hasOwnProperty(i)&&a.push(g(i,e[i],t,o,n));return a}(t,o+1,c,a),c.deferBuild=2<=o):null===(c.value=t)&&(c.type="null"),"");switch(c.type){case"string":r="str",p='"'+c.value+'"',d="red-ui-debug-msg-type-string";break;case"number":r="num",p=c.value,d="red-ui-debug-msg-type-number";break;case"boolean":r="bool",p=c.value,d="red-ui-debug-msg-type-other";break;case"null":r=c.type,p=c.type,d="red-ui-debug-msg-type-null";break;case"object":r=c.type,p=c.type,d="red-ui-debug-msg-type-meta";break;case"array":r=c.type,p=c.type+"["+c.children.length+"]",d="red-ui-debug-msg-type-meta"}var f=$('<span class="red-ui-editor-type-json-editor-label-value">').addClass(d).text(p).appendTo(u);return a&&f.addClass("readonly"),f.on("click",function(e){var i;a||(e.preventDefault(),e.stopPropagation(),"str"===r?p=p.substring(1,p.length-1):"array"!==r&&"object"!==r||(p=""),e=Math.max(150,f.width()),i=$('<input type="text" class="red-ui-editor-type-json-editor-value">').css({width:e+"px"}).val(""+p).insertAfter(f).typedInput({types:["str","num","bool",{value:"null",label:RED._("common.type.null"),hasValue:!1},{value:"array",label:RED._("common.type.array"),hasValue:!1,icon:"red/images/typedInput/json.svg"},{value:"object",label:RED._("common.type.object"),hasValue:!1,icon:"red/images/typedInput/json.svg"}],default:r}),$(document).on("mousedown.nr-ui-json-editor",function(e){for(var t,o=i.next(".red-ui-typedInput-container")[0],n=e.target;"BODY"!==n.nodeName&&n!==o&&!$(n).hasClass("red-ui-typedInput-options");)n=n.parentElement;if("BODY"===n.nodeName){switch(r=i.typedInput("type"),p=i.typedInput("value"),"num"===r&&(p=p.trim(),isNaN(p)?r="str":""===p&&(p=0)),c.value=p,r){case"str":c.children&&(l=c.children),c.treeList.makeLeaf(!0),c.type="string",t="red-ui-debug-msg-type-string",p='"'+p+'"';break;case"num":c.children&&(l=c.children),c.treeList.makeLeaf(!0),c.type="number",t="red-ui-debug-msg-type-number";break;case"bool":c.children&&(l=c.children),c.treeList.makeLeaf(!0),c.type="boolean",t="red-ui-debug-msg-type-other",c.value="true"===p;break;case"null":c.children&&(l=c.children),c.treeList.makeLeaf(!0),c.type="null",t="red-ui-debug-msg-type-null",c.value=p="null";break;case"object":c.treeList.makeParent(l),c.type="object",t="red-ui-debug-msg-type-meta",c.value=p="object",c.children.forEach(function(e,t){var o,n;e.hasOwnProperty("_key")&&(e.key=e._key,delete e._key,(n=e.element.find(".red-ui-editor-type-json-editor-label-key")).removeClass("red-ui-editor-type-json-editor-label-array-key"),"string"==typeof e.key?(o='"'+e.key+'"',n.addClass("red-ui-debug-msg-type-string"),n.removeClass("red-ui-debug-msg-type-number")):(o=e.key,n.removeClass("red-ui-debug-msg-type-string"),n.addClass("red-ui-debug-msg-type-number")),n.text(o))});break;case"array":c.treeList.makeParent(l),c.type="array",t="red-ui-debug-msg-type-meta",c.value=p="array["+c.children.length+"]",c.children.forEach(function(e,t){e._key=e.key,e.key=t,e.element.find(".red-ui-editor-type-json-editor-label-key").addClass("red-ui-editor-type-json-editor-label-array-key").text(""+e.key).removeClass("red-ui-debug-msg-type-string").addClass("red-ui-debug-msg-type-number")})}f.text(p).removeClass().addClass("red-ui-editor-type-json-editor-label-value "+t),i.remove(),f.show(),$(document).off("mousedown.nr-ui-json-editor"),$(document).off("keydown.nr-ui-json-editor")}}),$(document).on("keydown.nr-ui-json-editor",function(e){27===e.keyCode&&(i.remove(),f.show(),"str"===r&&(p='"'+p+'"'),$(document).off("mousedown.nr-ui-json-editor"),$(document).off("keydown.nr-ui-json-editor"))}),f.hide())}),c.gutter=$('<span class="red-ui-editor-type-json-editor-item-gutter"></span>'),a||((n?$('<span class="red-ui-editor-type-json-editor-item-handle"><i class="fa fa-bars"></span>'):$("<span></span>")).appendTo(c.gutter),$('<button type="button" class="editor-button editor-button-small"><i class="fa fa-caret-down"></button>').appendTo(c.gutter).on("click",function(e){e.preventDefault(),e.stopPropagation();var e=$(this),s=c,r=a,e=e.offset(),t=[],o=(s.parent&&(t.push({id:"red-ui-editor-type-json-menu-insert-above",icon:"fa fa-toggle-up",label:RED._("jsonEditor.insertAbove"),onselect:function(){var e=s.parent.children.indexOf(s);h(s.parent,e,e,r)}}),t.push({id:"red-ui-editor-type-json-menu-insert-below",icon:"fa fa-toggle-down",label:RED._("jsonEditor.insertBelow"),onselect:function(){var e=s.parent.children.indexOf(s)+1;h(s.parent,e,e-1,r)}})),"array"!==s.type&&"object"!==s.type||t.push({id:"red-ui-editor-type-json-menu-add-child",icon:"fa fa-plus",label:RED._("jsonEditor.addItem"),onselect:function(){h(s,s.children.length,s.children.length-1,r)}}),s.parent&&(t.push({id:"red-ui-editor-type-json-menu-copy-path",icon:"fa fa-terminal",label:RED._("jsonEditor.copyPath"),onselect:function(){for(var e=s,t="";e.parent;)t=("array"===e.parent.type?"["+e.key+"]":/^[a-zA-Z_$][0-9a-zA-Z_$]*$/.test(e.key)?e.key:'["'+e.key.replace(/"/,'\\"')+'"]')+(0<t.length&&"["!==t[0]?".":"")+t,e=e.parent;RED.clipboard.copyText(t,s.element,"clipboard.copyMessagePath")}}),t.push({id:"red-ui-editor-type-json-menu-duplicate",icon:"fa fa-copy",label:RED._("jsonEditor.duplicate"),onselect:function(){var e=s.key;if("array"===s.parent.type)e=s.parent.children.length;else{var t=/^(.*?)(-(\d+))?$/.exec(e),o={},n=(s.parent.children.forEach(function(e){o[e.key]=!0}),t[1]),i=2;for(void 0!==t[3]&&(i=parseInt(t[3])),e=n;o[e];)e=n+"-"+i++}var t=g(e,m(s),s.parent.depth+1,s.parent,r),a=s.parent.children.indexOf(s)+1;s.parent.treeList.insertChildAt(t,a,!0),s.parent.treeList.expand()}}),t.push({id:"red-ui-editor-type-json-menu-delete",icon:"fa fa-times",label:RED._("common.label.delete"),onselect:function(){s.treeList.remove()}})),"array"!==s.type&&"object"!==s.type||(t.push(null),t.push({id:"red-ui-editor-type-json-menu-expand-children",icon:"fa fa-angle-double-down",label:RED._("jsonEditor.expandItems"),onselect:function(){s.treeList.expand(),s.children.forEach(function(e){e.treeList.expand()})}}),t.push({id:"red-ui-editor-type-json-menu-collapse-children",icon:"fa fa-angle-double-up",label:RED._("jsonEditor.collapseItems"),onselect:function(){s.treeList.collapse(),s.children.forEach(function(e){e.treeList.collapse()})}})),(t=RED.menu.init({id:"red-ui-editor-type-json-menu",options:t})).css({position:"absolute"}),t.on("mouseleave",function(){$(this).hide()}),t.on("mouseup",function(){$(this).hide()}),t.appendTo("body"),e.top),n=t.height(),i=$(window).height();i<o+n&&(o-=o+n-i+20),t.css({top:o+"px",left:e.left+"px"}),t.show()})),c.element=u,c}function m(e){var t;switch(e.type){case"string":t=e.value;break;case"number":t=Number(e.value);break;case"boolean":t=e.value;break;case"null":t=null;break;case"object":t={},e.children.forEach(function(e){t[e.key]=m(e)});break;case"array":t=e.children.map(m)}return t}RED.editor.registerTypeEditor("_json",{show:function(a){function o(){var e=s.getValue();try{return JSON.parse(e),$("#node-dialog-ok").removeClass("disabled"),!0}catch(e){return $("#node-dialog-ok").addClass("disabled"),!1}}var s,r,d,l=a.value,e=a.cancel,t=a.complete,c=(0===$("script[data-template-name='_json']").length&&$('<script type="text/x-red" data-template-name="_json"><ul id="red-ui-editor-type-json-tabs"></ul><div id="red-ui-editor-type-json-tab-raw" class="red-ui-editor-type-json-tab-content hide"><div class="form-row" style="margin-bottom: 3px; text-align: right;"><span class="button-group"><button id="node-input-json-reformat" class="red-ui-button red-ui-button-small"><span data-i18n="jsonEditor.format"></span></button><span class="button-group"></div><div class="form-row node-text-editor-row"><div style="height: 200px;min-height: 150px;" class="node-text-editor" id="node-input-json"></div></div></div><div id="red-ui-editor-type-json-tab-ui" class="red-ui-editor-type-json-tab-content hide"><div id="red-ui-editor-type-json-tab-ui-container"></div></div><\/script>').appendTo("#red-ui-editor-node-configs"),RED.view.state(RED.state.EDITING),{title:a.title,focusElement:a.focusElement,width:a.width||700,buttons:[{id:"node-dialog-cancel",text:RED._("common.label.cancel"),click:function(){e&&e(),RED.tray.close()}},{id:"node-dialog-ok",text:RED._("common.label.done"),class:"primary",click:function(){var e;a.requireValid&&!o()||("json-ui"===u?e=d?JSON.stringify(m(d),null,4):s.getValue():"json-raw"===u&&(e=s.getValue()),s.saveView(),t&&t(e,null,s),RED.tray.close())}}],resize:function(e){var t=$(".red-ui-editor-type-json-tab-content").height();$(".node-text-editor").css("height",t-45+"px"),s.resize()},open:function(e){e.find(".red-ui-tray-body");var e=RED.editor.buildEditForm(e.find(".red-ui-tray-body"),"dialog-form","_json","editor"),t=a.toolbarButtons||[],t=(t.length&&t.forEach(function(t){var o=$('<button type="button" class="red-ui-button red-ui-button-small"> </button>').insertBefore("#node-input-json-reformat").on("click",function(e){e.preventDefault(),void 0!==t.click&&t.click.call(o,e)});t.id&&o.attr("id",t.id),t.title&&o.attr("title",t.title),t.icon&&o.append($("<i></i>").attr("class",t.icon)),(t.label||t.text)&&o.append($("<span></span>").text(" "+(t.label||t.text)))}),$("#red-ui-editor-type-json-tab-ui-container").css({height:"100%"})),n=$('<div class="red-ui-debug-msg-payload red-ui-editor-type-json-editor">').appendTo(t).treeList({selectable:!1,rootSortable:!1,sortable:".red-ui-editor-type-json-editor-item-handle"}).on("treelistchangeparent",function(e,t){"array"===t.old.type&&t.old.element.find(".red-ui-editor-type-json-editor-label-type").text("array["+t.old.children.length+"]"),"array"===t.item.parent.type&&t.item.parent.element.find(".red-ui-editor-type-json-editor-label-type").text("array["+t.item.parent.children.length+"]")}).on("treelistsort",function(e,o){o.children.forEach(function(e,t){"array"===o.type?(e.key=t,e.element.find(".red-ui-editor-type-json-editor-label-key").text(e.key).removeClass("red-ui-debug-msg-type-string").addClass("red-ui-debug-msg-type-number")):e.element.find(".red-ui-editor-type-json-editor-label-key").text('"'+e.key+'"').removeClass("red-ui-debug-msg-type-number").addClass("red-ui-debug-msg-type-string")})}),i=(s=RED.editor.createEditor({id:"node-input-json",value:l||"",mode:"ace/mode/json",readOnly:!!a.readOnly,stateId:a.stateId,focus:!0}),a.requireValid&&(s.getSession().on("change",function(){clearTimeout(r),r=setTimeout(o,200)}),o()),$("#node-input-json-reformat").on("click",function(e){e.preventDefault();e=s.getValue()||"";try{e=JSON.stringify(JSON.parse(e),null,4)}catch(e){}s.getSession().setValue(e||"",-1)}),e.i18n(),!1),t=RED.tabs.create({element:$("#red-ui-editor-type-json-tabs"),onchange:function(e){if(u=e.id,$(".red-ui-editor-type-json-tab-content").hide(),i)if("json-raw"===e.id)d&&(t=JSON.stringify(m(d),null,4),s.getSession().setValue(t||"",-1));else if("json-ui"===e.id){var t=s.getValue().trim()||"{}";try{var o=JSON.parse(t);(d=g(null,o,0,null,a.readOnly)).class="red-ui-editor-type-json-root-node",n.treeList("data",[d])}catch(e){d=null,n.treeList("data",[{label:RED._("jsonEditor.error.invalidJSON")+e.toString()}])}}e.content.show(),c.resize()}});t.addTab({id:"json-raw",label:a.readOnly?RED._("jsonEditor.rawMode-readonly"):RED._("jsonEditor.rawMode"),content:$("#red-ui-editor-type-json-tab-raw")}),t.addTab({id:"json-ui",label:a.readOnly?RED._("jsonEditor.uiMode-readonly"):RED._("jsonEditor.uiMode"),content:$("#red-ui-editor-type-json-tab-ui")}),i=!0},close:function(){a.onclose&&a.onclose(),s.destroy()},show:function(){}});RED.tray.show(c)}})}(),function(){var s;RED.editor.registerTypeEditor("_markdown",{show:function(n){var i,a=n.value,e=n.cancel,t=n.complete,o=(0===$("script[data-template-name='_markdown']").length&&$('<script type="text/x-red" data-template-name="_markdown"><div id="red-ui-editor-type-markdown-panels"><div id="red-ui-editor-type-markdown-panel-editor" class="red-ui-panel"><div style="height: 100%; margin: auto;"><div id="red-ui-editor-type-markdown-toolbar"></div><div class="node-text-editor" style="height: 100%" id="red-ui-editor-type-markdown"></div></div></div><div class="red-ui-panel"><div class="red-ui-editor-type-markdown-panel-preview red-ui-help"></div></div><\/script>').appendTo("#red-ui-editor-node-configs"),RED.view.state(RED.state.EDITING),{title:n.title,focusElement:n.focusElement,width:n.width||1/0,buttons:[{id:"node-dialog-cancel",text:RED._("common.label.cancel"),click:function(){e&&e(),RED.tray.close()}},{id:"node-dialog-ok",text:RED._("common.label.done"),class:"primary",click:function(){i.saveView(),t&&t(i.getValue(),i.getCursorPosition(),i),RED.tray.close()}}],resize:function(e){var t=$("#dialog-form").width();s&&s.resize(t)},open:function(e){e.find(".red-ui-tray-body").addClass("red-ui-editor-type-markdown-editor");var t,o=RED.editor.buildEditForm(e.find(".red-ui-tray-body"),"dialog-form","_markdown","editor");(i=RED.editor.createEditor({id:"red-ui-editor-type-markdown",value:a,stateId:n.stateId,focus:!0,mode:"ace/mode/markdown",expandable:!1})).getSession().on("change",function(){clearTimeout(t),t=setTimeout(function(){var e=$(".red-ui-editor-type-markdown-panel-preview").scrollTop();$(".red-ui-editor-type-markdown-panel-preview").html(RED.utils.renderMarkdown(i.getValue())),$(".red-ui-editor-type-markdown-panel-preview").scrollTop(e)},200)}),n.header&&n.header.appendTo(e.find("#red-ui-editor-type-markdown-title")),a&&$(".red-ui-editor-type-markdown-panel-preview").html(RED.utils.renderMarkdown(i.getValue())),(s=RED.panels.create({id:"red-ui-editor-type-markdown-panels",dir:"horizontal",resize:function(e,t){i.resize()}})).ratio(1),$('<span class="button-group" style="float:right"><button type="button" id="node-btn-markdown-preview" class="red-ui-button toggle single"><i class="fa fa-eye"></i></button></span>').appendTo(i.toolbar),$("#node-btn-markdown-preview").on("click",function(e){e.preventDefault(),$(this).hasClass("selected")?($(this).removeClass("selected"),s.ratio(1)):($(this).addClass("selected"),s.ratio(.5))}),RED.popover.tooltip($("#node-btn-markdown-preview"),RED._("markdownEditor.toggle-preview")),n.cursor&&!i._initState&&i.gotoLine(n.cursor.row+1,n.cursor.column,!1),o.i18n()},close:function(){n.onclose&&n.onclose(),i.destroy()},show:function(){}});RED.tray.show(o)},buildToolbar:function(e,r){var t={h1:{newline:!0,before:"# ",tooltip:RED._("markdownEditor.heading1")},h2:{newline:!0,before:"## ",tooltip:RED._("markdownEditor.heading2")},h3:{newline:!0,before:"### ",tooltip:RED._("markdownEditor.heading3")},b:{before:"**",after:"**",tooltip:RED._("markdownEditor.bold")},i:{before:"_",after:"_",tooltip:RED._("markdownEditor.italic")},code:{before:"`",after:"`",tooltip:RED._("markdownEditor.code")},ol:{before:" 1. ",newline:!0,tooltip:RED._("markdownEditor.ordered-list")},ul:{before:" - ",newline:!0,tooltip:RED._("markdownEditor.unordered-list")},bq:{before:"> ",newline:!0,tooltip:RED._("markdownEditor.quote")},link:{before:"[",after:"]()",tooltip:RED._("markdownEditor.link")},hr:{before:"\n---\n\n",tooltip:RED._("markdownEditor.horizontal-rule")}},e=$('<div style="margin-bottom: 5px"><span class="button-group"><button type="button" class="red-ui-button" data-style="h1" style="font-size:1.1em; font-weight: bold">h1</button><button type="button" class="red-ui-button" data-style="h2" style="font-size:1.0em; font-weight: bold">h2</button><button type="button" class="red-ui-button" data-style="h3" style="font-size:0.9em; font-weight: bold">h3</button></span><span class="button-group"><button type="button" class="red-ui-button" data-style="b"><i class="fa fa-bold"></i></button><button type="button" class="red-ui-button" data-style="i"><i class="fa fa-italic"></i></button><button type="button" class="red-ui-button" data-style="code"><i class="fa fa-code"></i></button></span><span class="button-group"><button type="button" class="red-ui-button" data-style="ol"><i class="fa fa-list-ol"></i></button><button type="button" class="red-ui-button" data-style="ul"><i class="fa fa-list-ul"></i></button><button type="button" class="red-ui-button" data-style="bq"><i class="fa fa-quote-left"></i></button><button type="button" class="red-ui-button" data-style="hr"><i class="fa fa-minus"></i></button><button type="button" class="red-ui-button" data-style="link"><i class="fa fa-link"></i></button></span></div>').appendTo(e);return e.find("button[data-style]").each(function(e){var s=t[$(this).data("style")];$(this).on("click",function(e){e.preventDefault();var e=r.getSelectedText(),t=r.selection.getRange();if(s.newline)for(var o=0,n=((s.before||"").match(/\n/g)||[]).length,i=((s.after||"").match(/\n/g)||[]).length,a=t.start.row;a<=t.end.row+o;a++)s.before&&(r.session.insert({row:a,column:0},s.before),o+=n,a+=n),s.after&&(r.session.insert({row:a,column:1/0},s.after),o+=i,a+=i);else r.session.replace(r.selection.getRange(),(s.before||"")+e+(s.after||"")),""===e&&r.gotoLine(t.start.row+1,t.start.column+(s.before||"").length,!1);r.focus()}),s.tooltip&&RED.popover.tooltip($(this),s.tooltip)}),e}})}(),RED.editor.registerTypeEditor("_text",{show:function(t){var o,n=t.value,e=t.cancel,i=t.complete,a=(0===$("script[data-template-name='_text']").length&&$('<script type="text/x-red" data-template-name="_text"><div class="form-row node-text-editor-row"><div style="height: 200px;min-height: 150px;" class="node-text-editor" id="node-input-text"></div></div><\/script>').appendTo("#red-ui-editor-node-configs"),RED.view.state(RED.state.EDITING),{title:t.title,focusElement:t.focusElement,width:t.width||"inherit",buttons:[{id:"node-dialog-cancel",text:RED._("common.label.cancel"),click:function(){e&&e(),RED.tray.close()}},{id:"node-dialog-ok",text:RED._("common.label.done"),class:"primary",click:function(){o.saveView(),i&&i(o.getValue(),o.getCursorPosition(),o),RED.tray.close()}}],resize:function(e){$("#dialog-form>div:not(.node-text-editor-row)"),$("#dialog-form>div.node-text-editor-row");var t=$("#dialog-form").height();$(".node-text-editor").css("height",t+"px"),o.resize()},open:function(e){RED.editor.buildEditForm(e.find(".red-ui-tray-body"),"dialog-form","_text","editor");o=RED.editor.createEditor({id:"node-input-text",value:n||"",stateId:t.stateId,mode:"ace/mode/"+(t.mode||"text"),focus:!0}),t.cursor&&!o._initState&&o.gotoLine(t.cursor.row+1,t.cursor.column,!1)},close:function(){t.onclose&&t.onclose(),o.destroy()},show:function(){}});RED.tray.show(a)}}),RED.editor.codeEditor.ace=function(){var t=!1,s={};return{get type(){return"ace"},get initialised(){return t},init:function(e){return s=e||{},t=!0},create:function(o){var e=RED.editor.codeEditor.settings||{},t=o.element||$("#"+o.id)[0],n=$("<div>").appendTo(t),t=$("<div>").appendTo(t).addClass("red-ui-editor-text-container")[0],i=window.ace.edit(t),a=(i.setTheme(e.theme||s.theme||"ace/theme/tomorrow"),i.getSession());return a.on("changeAnnotation",function(){for(var e=a.getAnnotations()||[],t=e.length,o=e.length;t--;)(/doctype first\. Expected/.test(e[t].text)||/Unexpected End of file\. Expected/.test(e[t].text))&&e.splice(t,1);o>e.length&&a.setAnnotations(e)}),o.mode&&a.setMode(o.mode),o.foldStyle?a.setFoldStyle(o.foldStyle):a.setFoldStyle("markbeginend"),o.options?i.setOptions(o.options):i.setOptions({enableBasicAutocompletion:!0,enableSnippets:!0,tooltipFollowsMouse:!1}),o.readOnly&&(i.setOption("readOnly",o.readOnly),i.container.classList.add("ace_read-only")),o.hasOwnProperty("lineNumbers")&&i.renderer.setOption("showGutter",o.lineNumbers),i.$blockScrolling=1/0,o.value&&a.setValue(o.value,-1),o.globals&&setTimeout(function(){a.$worker&&a.$worker.send("setOptions",[{globals:o.globals,maxerr:1e3}])},100),o.stateId||!1===o.stateId||(o.stateId=RED.editor.generateViewStateId("ace",o,(o.mode||o.title).split("/").pop())),"ace/mode/markdown"===o.mode&&($(t).addClass("red-ui-editor-text-container-toolbar"),i.toolbar=RED.editor.customEditTypes._markdown.buildToolbar(n,i),!1!==o.expandable&&(e=$('<button type="button" class="red-ui-button" style="float: right;"><i class="fa fa-expand"></i></button>').appendTo(i.toolbar),RED.popover.tooltip(e,RED._("markdownEditor.expand")),e.on("click",function(e){e.preventDefault();e=i.getValue();RED.editor.editMarkdown({value:e,width:"Infinity",stateId:o.stateId,focus:!0,cancel:function(){i.focus()},complete:function(e,t){i.setValue(e,-1),setTimeout(function(){i.restoreView(),i.focus()},300)}})})),e=$('<button type="button" class="red-ui-editor-text-help red-ui-button red-ui-button-small"><i class="fa fa-question"></i></button>').appendTo($(t).parent()),RED.popover.create({target:e,trigger:"click",size:"small",direction:"left",content:RED._("markdownEditor.format"),autoClose:50}),a.setUseWrapMode(!0)),i._destroy=i.destroy,i.destroy=function(){try{i.saveView(),i._initState=null,this._destroy()}catch(e){}$(t).remove(),$(n).remove()},i.on("blur",function(){i.focusMemory=!1,i.saveView()}),i.on("focus",function(){i._initState&&(i.restoreView(i._initState),i._initState=null)}),i.getView=function(){var e=i.getSession();return{selection:e.selection.toJSON(),scrollTop:e.getScrollTop(),scrollLeft:e.getScrollLeft(),options:e.getOptions()}},i.saveView=function(){var e;if(o.stateId)return window._editorStateAce=window._editorStateAce||{},e=i.getView(),window._editorStateAce[o.stateId]=e},i.restoreView=function(e){if(o.stateId){window._editorStateAce=window._editorStateAce||{};e=e||window._editorStateAce[o.stateId];if(e)try{var t=i.getSession();t.setOptions(e.options),t.selection.fromJSON(e.selection),t.setScrollTop(e.scrollTop),t.setScrollLeft(e.scrollLeft),i._initState=e}catch(e){delete window._editorStateMonaco[o.stateId]}}},i.restoreView(),i.type="ace",i}}}(),RED.editor.codeEditor.monaco=function(){var y=!1;const w=["vs","vs-dark","hc-black"];let E;const b={assert:{package:"node",module:"assert",path:"node/assert.d.ts"},async_hooks:{package:"node",module:"async_hooks",path:"node/async_hooks.d.ts"},buffer:{package:"node",module:"buffer",path:"node/buffer.d.ts"},child_process:{package:"node",module:"child_process",path:"node/child_process.d.ts"},cluster:{package:"node",module:"cluster",path:"node/cluster.d.ts"},console:{package:"node",module:"console",path:"node/console.d.ts"},constants:{package:"node",module:"constants",path:"node/constants.d.ts"},crypto:{package:"node",module:"crypto",path:"node/crypto.d.ts"},dgram:{package:"node",module:"dgram",path:"node/dgram.d.ts"},dns:{package:"node",module:"dns",path:"node/dns.d.ts"},domain:{package:"node",module:"domain",path:"node/domain.d.ts"},events:{package:"node",module:"events",path:"node/events.d.ts"},fs:{package:"node",module:"fs",path:"node/fs.d.ts"},globals:{package:"node",module:"globals",path:"node/globals.d.ts"},http:{package:"node",module:"http",path:"node/http.d.ts"},http2:{package:"node",module:"http2",path:"node/http2.d.ts"},https:{package:"node",module:"https",path:"node/https.d.ts"},module:{package:"node",module:"module",path:"node/module.d.ts"},net:{package:"node",module:"net",path:"node/net.d.ts"},os:{package:"node",module:"os",path:"node/os.d.ts"},path:{package:"node",module:"path",path:"node/path.d.ts"},perf_hooks:{package:"node",module:"perf_hooks",path:"node/perf_hooks.d.ts"},process:{package:"node",module:"process",path:"node/process.d.ts"},querystring:{package:"node",module:"querystring",path:"node/querystring.d.ts"},readline:{package:"node",module:"readline",path:"node/readline.d.ts"},stream:{package:"node",module:"stream",path:"node/stream.d.ts"},string_decoder:{package:"node",module:"string_decoder",path:"node/string_decoder.d.ts"},timers:{package:"node",module:"timers",path:"node/timers.d.ts"},tls:{package:"node",module:"tls",path:"node/tls.d.ts"},trace_events:{package:"node",module:"trace_events",path:"node/trace_events.d.ts"},tty:{package:"node",module:"tty",path:"node/tty.d.ts"},url:{package:"node",module:"url",path:"node/url.d.ts"},util:{package:"node",module:"util",path:"node/util.d.ts"},v8:{package:"node",module:"v8",path:"node/v8.d.ts"},vm:{package:"node",module:"vm",path:"node/vm.d.ts"},wasi:{package:"node",module:"wasi",path:"node/wasi.d.ts"},worker_threads:{package:"node",module:"worker_threads",path:"node/worker_threads.d.ts"},zlib:{package:"node",module:"zlib",path:"node/zlib.d.ts"},"node-red":{package:"node-red",module:"node-red",path:"node-red/index.d.ts"},"node-red-util":{package:"node-red",module:"util",path:"node-red/util.d.ts"},"node-red-func":{package:"node-red",module:"func",path:"node-red/func.d.ts"}},D=[b["node-red-util"],b["node-red-func"],b.globals,b.console,b.buffer],l={};function R(e,t,o,n){var i="object"==typeof e?e:b[e];if(i){const s=i.package,r=i.module,d=i.path;var a,e=l[d];e?(t||(o.JS[r]=monaco.languages.typescript.javascriptDefaults.addExtraLib(e,"file://types/"+s+"/"+r+"/index.d.ts")),n&&setTimeout(function(){n(null,i)},5)):(a="types/"+d,$.get(a).done(function(e){l[d]=e,t||(o.JS[r]=monaco.languages.typescript.javascriptDefaults.addExtraLib(e,"file://types/"+s+"/"+r+"/index.d.ts")),n&&n(null,i)}).fail(function(e){var t="Failed to load '"+a+"'";l[d]="/* "+t+" */\n",n&&n(e,i),console.warn(t)}))}}function x(e){return!(!e.offsetHeight&&!e.offsetWidth)&&"hidden"!==getComputedStyle(e).visibility}return{get type(){return"monaco"},get initialised(){return y},init:function(e){RED.events.on("editor:close",function(){var t=window.monaco?monaco.editor.getModels():null;if(t&&t.length){console.warn("Cleaning up monaco models left behind. Any node that calls createEditor() should call .destroy().");for(let e=0;e<t.length;e++){const o=t[e];o.isDisposed()||o.dispose()}}}),window.MonacoEnvironment=window.MonacoEnvironment||{},window.MonacoEnvironment.getWorkerUrl=window.MonacoEnvironment.getWorkerUrl||function(e,t){return"json"===t?"./vendor/monaco/dist/json.worker.js":"css"===t||"scss"===t?"./vendor/monaco/dist/css.worker.js":"html"===t||"handlebars"===t?"./vendor/monaco/dist/html.worker.js":"typescript"===t||"javascript"===t?"./vendor/monaco/dist/ts.worker.js":"./vendor/monaco/dist/editor.worker.js"};var o=(RED.editor.codeEditor.settings||{}).options||{};try{const b=function(e,t){(t.rules&&Array.isArray(t.rules)||t.colors)&&(w.push(e),monaco.editor.defineTheme(e,t),monaco.editor.setTheme(e),E=e)};if(o.theme)if("object"==typeof o.theme&&RED.settings.editorTheme.theme){var t=o.theme.name||RED.settings.editorTheme.theme;b(t,o.theme)}else if("string"==typeof o.theme){let t=o.theme;w.includes(t)||$.get("vendor/monaco/dist/theme/"+t+".json",function(e){b(t,e)})}}catch(e){console.warn(e)}function i(e,t,o,n,i){return Array.isArray(o)&&(o=o.join("\n")),{label:e,kind:null==i?monaco.languages.CompletionItemKind.Snippet:i,documentation:{value:o},insertText:t,insertTextRules:monaco.languages.CompletionItemInsertTextRule.InsertAsSnippet,range:n}}(t=monaco).languages.registerCompletionItemProvider("javascript",{provideCompletionItems:function(e,t){var e=e.getWordUntilPosition(t),t={startLineNumber:t.lineNumber,endLineNumber:t.lineNumber,startColumn:e.startColumn,endColumn:e.endColumn};return{suggestions:[i("dowhile","do {\n\t${2}\n} while (${1:condition});","Do-While Statement (JavaScript Language Basics)",e=t),i("while","while (${1:condition}) {\n\t${2}\n}","While Statement (JavaScript Language Basics)",e),i("switch",'switch (${1:msg.topic}) {\n\tcase ${2:"value"}:\n\t\t${3}\n\t\tbreak;\n\tdefault:\n\t\t\n}',"Switch Statement (JavaScript Language Basics)",e),i("trycatch","try {\n\t${2}\n} catch (${1:error}) {\n\t\n};","Try-Catch Statement (JavaScript Language Basics)",e),i("for (for loop)","for (let ${1:index} = 0; ${1:index} < ${2:array}.length; ${1:index}++) {\n\tconst element = ${2:array}[${1:index}];\n\t${3}\n}","for loop",e),i("foreach","${1:array}.forEach(function(${2:element}) {\n\t${3}\n});","forEach(callbackfn: (value: T, index: number, array: readonly T[]) => void, thisArg?: any): void\n\nA function that accepts up to three arguments. forEach calls the callbackfn function one time for each element in the array.",e),i("forin","for (${1:prop} in ${2:obj}) {\n\tif (${2:obj}.hasOwnProperty(${1:prop})) {\n\t\t${3}\n\t}\n}","for in",e),i("forof","for (const ${1:iterator} of ${2:object}) {\n\t${3}\n}","for of",e),i("function","function ${1:methodName}(${2:arguments}) {\n\t${3}\n}","Function Declaration",e),i("func (anonymous function)","var ${1:fn} = function(${2:arguments}) {\n\t${3}\n}","Function Expression",e),i("pt (prototype)","${1:ClassName}.prototype.${2:methodName} = function(${3:arguments}) {\n\t${4}\n}","prototype",e),i("iife","(function(${1:arg}) {\n\t${1}\n})(${1:arg});","immediately-invoked function expression",e),i("call (function call)","${1:methodName}.call(${2:context}, ${3:arguments})","function call",e),i("apply (function apply)","${1:methodName}.apply(${2:context}, [${3:arguments}])","function apply",e),i("jsonparse","JSON.parse(${1:json});","JSON.parse",e),i("jsonstringify","JSON.stringify(${1:obj});","JSON.stringify",e),i("setinterval","setInterval(function() {\n\t${2}\n}, ${1:delay});","setInterval",e),i("settimeout","setTimeout(function() {\n\t${2}\n}, ${1:delay});","setTimeout",e),i("node.log",'node.log(${1:"info"});',"Write an info message to the console (not sent to sidebar)",e),i("node.warn",'node.warn(${1:"my warning"});',"Write a warning to the console and debug sidebar",e),i("node.error",'node.error(${1:"my error message"}, ${2:msg});',"Send an error to the console and debug sidebar. To trigger a Catch node on the same tab, the function should call `node.error` with the original message as a second argument",e),i("node.send","node.send(${1:msg});","async send a msg to the next node",e),i("node.send (multiple)","var ${1:msg1} = {payload:${2:1}};\nvar ${3:msg2} = {payload:${4:2}};\nnode.send([[${1:msg1}, ${3:msg2}]]);","send 1 or more messages out of 1 output",e),i("node.send (multiple outputs)","var ${1:msg1} = {payload:${2:1}};\nvar ${3:msg2} = {payload:${4:2}};\nnode.send([${1:msg1}, ${3:msg2}]);","send more than 1 message out of multiple outputs",e),i("node.status",'node.status({fill:"${1|red,green,yellow,blue,grey|}",shape:"${2|ring,dot|}",text:"${3:message}"});',"Set the status icon and text underneath the function node",e),i("get (node context)",'context.get("${1:name}");',"Get a value from node context",e),i("set (node context)",'context.set("${1:name}", ${1:value});',"Set a value in node context",e),i("get (flow context)",'flow.get("${1:name}");',"Get a value from flow context",e),i("set (flow context)",'flow.set("${1:name}", ${1:value});',"Set a value in flow context",e),i("get (global context)",'global.get("${1:name}");',"Get a value from global context",e),i("set (global context)",'global.set("${1:name}", ${1:value});',"Set a value in global context",e),i("get (env)",'env.get("${1|NR_NODE_ID,NR_NODE_NAME,NR_NODE_PATH,NR_GROUP_ID,NR_GROUP_NAME,NR_FLOW_ID,NR_FLOW_NAME|}");',"Get env variable value",e),i("cloneMessage (RED.util)","RED.util.cloneMessage(${1:msg});",["```typescript","RED.util.cloneMessage<T extends registry.NodeMessage>(msg: T): T","```","Safely clones a message object. This handles msg.req/msg.res objects that must not be cloned\n","*@param* `msg` — the msg object\n"],e),i("getObjectProperty (RED.util)","RED.util.getObjectProperty(${1:msg},${2:prop});",["```typescript","RED.util.getObjectProperty(msg: object, expr: string): any;","```","Gets a property of an object\n","*@param* `msg` — the msg object\n","*@param* `prop` — the msg object"],e),i("setObjectProperty (RED.util)","RED.util.setObjectProperty(${1:msg},${2:prop},${3:value},${4:createMissing});",["```typescript","RED.util.setObjectProperty(msg: object, prop: string, value: any, createMissing?: boolean): boolean","```","Sets a property of an object\n","`msg` — the object\n","`prop` — the property expression\n","`value` — the value to set\n","`createMissing` — whether to create missing parent properties"],e),i("getMessageProperty (RED.util)","RED.util.getMessageProperty(${1:msg},${2:prop});",["```typescript","RED.util.getMessageProperty(msg: object, expr: string): any;","```","Gets a property of an object\n","*@param* `msg` — the msg object\n","*@param* `prop` — the msg object"],e),i("setMessageProperty (RED.util)","RED.util.setMessageProperty(${1:msg},${2:prop},${3:value},${4:createMissing});",["```typescript","RED.util.setMessageProperty(msg: object, prop: string, value: any, createMissing?: boolean): boolean","```","Sets a property of an object\n","`msg` — the object\n","`prop` — the property expression\n","`value` — the value to set\n","`createMissing` — whether to create missing parent properties"],e)]}}});try{var n={allowJs:!0,checkJs:!0,allowNonTsExtensions:!0,target:monaco.languages.typescript.ScriptTarget.ESNext,strictNullChecks:!1,strictPropertyInitialization:!0,strictFunctionTypes:!0,strictBindCallApply:!0,useDefineForClassFields:!0,moduleResolution:monaco.languages.typescript.ModuleResolutionKind.NodeJs,module:monaco.languages.typescript.ModuleKind.CommonJS,typeRoots:["types"],lib:["esnext"]},a=RED.settings.get("codeEditor.monaco.languages.typescript.javascriptDefaults.compilerOptions")||{},n=Object.assign({},n,a),s=(t.languages.typescript.javascriptDefaults.setCompilerOptions(n),{noSemanticValidation:!1,noSyntaxValidation:!1,diagnosticCodesToIgnore:[1108,1375,1378,2307,2322,2339,2345,7043,80001,80004]}),r=RED.settings.get("codeEditor.monaco.languages.typescript.javascriptDefaults.diagnosticsOptions")||{},s=Object.assign({},s,r);t.languages.typescript.javascriptDefaults.setDiagnosticsOptions(s)}catch(e){console.warn("monaco - Error setting javascriptDefaults",e)}(o=monaco).languages.register({id:"jsonata"}),o.languages.setMonarchTokensProvider("jsonata",{defaultToken:"invalid",tokenPostfix:".js",keywords:["function","true","true","null","Infinity","NaN","undefined"].concat(Object.keys(jsonata.functions)),operatorsKeywords:["and","or","in"],operators:["<=",">=","!=","==","!=","=>","+","-","*","/","%",":=","~>","?",":","..","@","#","|","^","*","**"],symbols:/[=><!~?:&|+\-*\/\^%@#]+/,escapes:/\\(?:[abfnrtv\\"']|x[0-9A-Fa-f]{1,4}|u[0-9A-Fa-f]{4}|U[0-9A-Fa-f]{8})/,digits:/\d+(_+\d+)*/,octaldigits:/[0-7]+(_+[0-7]+)*/,binarydigits:/[0-1]+(_+[0-1]+)*/,hexdigits:/[[0-9a-fA-F]+(_+[0-9a-fA-F]+)*/,regexpctl:/[(){}\[\]\$\^|\-*+?\.]/,regexpesc:/\\(?:[bBdDfnrstvwWn0\\\/]|@regexpctl|c[A-Z]|x[0-9a-fA-F]{2}|u[0-9a-fA-F]{4})/,tokenizer:{root:[[/[{}]/,"delimiter.bracket"],{include:"common"}],common:[[/([a-zA-Z][\w$]*)|([$][\w$]*)/,{cases:{"@keywords":"keyword","@operatorsKeywords":"keyword",$2:"variable","@default":"identifier"}}],[/[$][\w\$]*/,"variable"],{include:"@whitespace"},[/\/(?=([^\\\/]|\\.)+\/([gimsuy]*)(\s*)(\.|;|\/|,|\)|\]|\}|$))/,{token:"regexp",bracket:"@open",next:"@regexp"}],[/[()\[\]]/,"@brackets"],[/[<>](?!@symbols)/,"@brackets"],[/(@symbols)|(\.\.)/,{cases:{"@operators":"operator","@default":""}}],[/(@digits)[eE]([\-+]?(@digits))?/,"number.float"],[/(@digits)\.(@digits)([eE][\-+]?(@digits))?/,"number.float"],[/0[xX](@hexdigits)/,"number.hex"],[/0[oO]?(@octaldigits)/,"number.octal"],[/0[bB](@binarydigits)/,"number.binary"],[/(@digits)/,"number"],[/[?:;,.]/,"delimiter"],[/"([^"\\]|\\.)*$/,"string.invalid"],[/'([^'\\]|\\.)*$/,"string.invalid"],[/"/,"string","@string_double"],[/'/,"string","@string_single"],[/`/,"string","@string_backtick"]],whitespace:[[/[ \t\r\n]+/,""],[/\/\*\*(?!\/)/,"comment.doc","@jsdoc"],[/\/\*/,"comment","@comment"],[/\/\/.*$/,"comment"]],comment:[[/[^\/*]+/,"comment"],[/\*\//,"comment","@pop"],[/[\/*]/,"comment"]],jsdoc:[[/[^\/*]+/,"comment.doc"],[/\*\//,"comment.doc","@pop"],[/[\/*]/,"comment.doc"]],regexp:[[/(\{)(\d+(?:,\d*)?)(\})/,["regexp.escape.control","regexp.escape.control","regexp.escape.control"]],[/(\[)(\^?)(?=(?:[^\]\\\/]|\\.)+)/,["regexp.escape.control",{token:"regexp.escape.control",next:"@regexrange"}]],[/(\()(\?:|\?=|\?!)/,["regexp.escape.control","regexp.escape.control"]],[/[()]/,"regexp.escape.control"],[/@regexpctl/,"regexp.escape.control"],[/[^\\\/]/,"regexp"],[/@regexpesc/,"regexp.escape"],[/\\\./,"regexp.invalid"],[/(\/)([gimsuy]*)/,[{token:"regexp",bracket:"@close",next:"@pop"},"keyword.other"]]],regexrange:[[/-/,"regexp.escape.control"],[/\^/,"regexp.invalid"],[/@regexpesc/,"regexp.escape"],[/[^\]]/,"regexp"],[/\]/,{token:"regexp.escape.control",next:"@pop",bracket:"@close"}]],string_double:[[/[^\\"]+/,"string"],[/@escapes/,"string.escape"],[/\\./,"string.escape.invalid"],[/"/,"string","@pop"]],string_single:[[/[^\\']+/,"string"],[/@escapes/,"string.escape"],[/\\./,"string.escape.invalid"],[/'/,"string","@pop"]],string_backtick:[[/\$\{/,{token:"delimiter.bracket",next:"@bracketCounting"}],[/[^\\`$]+/,"string"],[/@escapes/,"string.escape"],[/\\./,"string.escape.invalid"],[/`/,"string","@pop"]],bracketCounting:[[/\{/,"delimiter.bracket","@bracketCounting"],[/\}/,"delimiter.bracket","@pop"],{include:"common"}]}}),o.languages.setLanguageConfiguration("jsonata",{comments:{lineComment:"//",blockComment:["/*","*/"]},brackets:[["{","}"],["[","]"],["(",")"]],autoClosingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:"'",close:"'",notIn:["string","comment"]},{open:'"',close:'"',notIn:["string"]}],surroundingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:'"',close:'"'},{open:"'",close:"'"},{open:"<",close:">"}],folding:{markers:{start:new RegExp("^\\s*//\\s*(?:(?:#?region\\b)|(?:<editor-fold\\b))"),end:new RegExp("^\\s*//\\s*(?:(?:#?endregion\\b)|(?:</editor-fold>))")}}}),o.languages.registerCompletionItemProvider("jsonata",{provideCompletionItems:function(e,t){var n,o,e=e.getWordUntilPosition(t);if(e)return o=e.startColumn,"$"!==e.word[0]&&1<t.column&&o--,n={startLineNumber:t.lineNumber,endLineNumber:t.lineNumber,startColumn:o,endColumn:e.endColumn},t=Object.keys(jsonata.functions),o=t.map(function(e){var t=e+"("+RED._("jsonata:"+e+".args",{defaultValue:""})+")",o=RED._("jsonata:"+e+".desc",{defaultValue:""});return i(e,(jsonata.getFunctionSnippet(e)+"").trim(),{value:"`"+t+"`\n\n"+o},n,monaco.languages.CompletionItemKind.Function)}),t.sort(function(e,t){return t.length-e.length}),o.unshift(i("randominteger","(\n\t\\$minimum := ${1:1};\n\t\\$maximum := ${2:10};\n\t\\$round((\\$random() * (\\$maximum-\\$minimum)) + \\$minimum, 0)\n)","Random integer between 2 numbers",n)),{suggestions:o}}}),o.languages.registerHoverProvider("jsonata",{provideHover:function(e,t){var e=e.getWordAtPosition(t),o=e&&e.word;if(o&&"$"!==o[0]&&1<t.column){var o="$"+o,n=RED._("jsonata:"+o+".args",{defaultValue:""});if(n)return n=o+"("+n+")",o=RED._("jsonata:"+o+".desc",{defaultValue:""}),{range:new monaco.Range(t.lineNumber,t.column,t.lineNumber,t.column+e.word.length),contents:[{value:"**`"+n+"`**"},{value:o}]}}}}),a=monaco;try{var d=RED.settings.get("codeEditor.monaco.languages.json.jsonDefaults.diagnosticOptions"),l=RED.settings.get("codeEditor.monaco.languages.json.jsonDefaults.modeConfiguration"),d=Object.assign({},{validate:!0},d||{});a.languages.json.jsonDefaults.setDiagnosticsOptions(d),l&&a.languages.json.jsonDefaults.setModeConfiguration(l)}catch(e){console.warn("monaco - Error setting up json options",err)}n=monaco;try{var c=RED.settings.get("codeEditor.monaco.languages.css.cssDefaults.diagnosticsOptions"),u=RED.settings.get("codeEditor.monaco.languages.css.lessDefaults.diagnosticsOption"),p=RED.settings.get("codeEditor.monaco.languages.css.scssDefaults.diagnosticsOption"),f=RED.settings.get("codeEditor.monaco.languages.css.cssDefaults.modeConfiguration"),h=RED.settings.get("codeEditor.monaco.languages.css.lessDefaults.modeConfiguration"),g=RED.settings.get("codeEditor.monaco.languages.css.scssDefaults.modeConfiguration");c&&n.languages.css.cssDefaults.setDiagnosticsOptions(c),u&&n.languages.css.cssDefaults.setDiagnosticsOptions(u),p&&n.languages.css.cssDefaults.setDiagnosticsOptions(p),f&&n.languages.css.cssDefaults.setDiagnosticsOptions(f),h&&n.languages.css.cssDefaults.setDiagnosticsOptions(h),g&&n.languages.css.cssDefaults.setDiagnosticsOptions(g)}catch(e){console.warn("monaco - Error setting up CSS/SCSS/LESS options",err)}r=monaco;try{var m=RED.settings.get("codeEditor.monaco.languages.html.htmlDefaults.options"),v=RED.settings.get("codeEditor.monaco.languages.html.handlebarDefaults.options");m&&r.languages.html.htmlDefaults.setOptions(m),v&&r.languages.html.handlebarDefaults.setOptions(v)}catch(e){console.warn("monaco - Error setting up html options",err)}return D.forEach(function(e){R(e,!0)}),y=!0},create:function(o){function c(e){switch(e=(e="object"==typeof e&&e.path?e.path:e)?e.replace("ace/mode/",""):"text"){case"nrjavascript":case"mjs":e="javascript";break;case"vue":e="html";break;case"appcache":case"sh":case"bash":e="shell";break;case"batchfile":e="bat";break;case"protobuf":e="proto"}return e}var a,e=RED.editor.codeEditor.settings||{},u={JS:{},TS:{}},s=(o.stateId||!1===o.stateId||(o.stateId=RED.editor.generateViewStateId("monaco",o,(o.mode||o.title||"").split("/").pop())),o.element||$("#"+o.id)[0]),r=$("<div>").appendTo(s),s=$("<div>").appendTo(s).addClass("red-ui-editor-text-container")[0];(e=$.extend({},e.options,o)).language=c(o.mode),E&&(e.theme=E),"javascript"==e.language&&(e._language=e.language,e.language="text"),e.minimap||(e.minimap={enabled:!0,maxColumn:50,scale:1,showSlider:"mouseover",renderCharacters:!0}),!1===o.enableBasicAutocompletion&&(e.showSnippets=!1,e.quickSuggestions=!1,e.parameterHints={enabled:!1},e.suggestOnTriggerCharacters=!1,e.acceptSuggestionOnEnter="off",e.tabCompletion="off",e.wordBasedSuggestions=!1),!1===o.enableSnippets&&(e.showSnippets=!1),null==e.mouseWheelZoom&&(e.mouseWheelZoom=!0),null==e.suggestFontSize&&(e.suggestFontSize=12),null==e.formatOnPaste&&(e.formatOnPaste=!0),null==e.foldingHighlight&&(e.foldingHighlight=!0),null==e.foldStyle&&(e.foldStyle=!0),null!=e.readOnly&&(e.readOnly=e.readOnly),!1===e.lineNumbers&&(e.lineNumbers=!1),null==e.theme&&(e.theme=w[0]),null==e.mode&&(e.mode=c(o.mode)),null==e.automaticLayout&&(e.automaticLayout=!0),o.foldStyle&&"none"===o.foldStyle?(e.foldStyle=!1,e.foldingHighlight=!1):(e.foldStyle=!0,e.foldingHighlight=!0),e.roundedSelection=!1!==e.roundedSelection,e.contextmenu=!1!==e.contextmenu,e.snippetSuggestions=!1!==e.enableSnippets,e.value=o.value||"",e.wordSeparators||"jsonata"!=e.language&&"json"!=e.language&&"javascript"!=e.language||(e.wordSeparators="`~!@#%^&*()-=+[{]}|;:'\",.<>/?"),e.fixedOverflowWidgets=!1!==e.fixedOverflowWidgets;((t=RED.utils.getBrowserInfo()).mobile||t.tablet)&&(e.minimap={enabled:!1},e.formatOnType=!1,e.formatOnPaste=!1,e.disableMonospaceOptimizations=!0,e.columnSelection=!1,e.matchBrackets="never",e.maxTokenizationLineLength=1e4,e.stopRenderingLineAfter=2e3,e.roundedSelection=!1,e.trimAutoWhitespace=!1,e.parameterHints={enabled:!1},e.suggestOnTriggerCharacters=!1,e.wordBasedSuggestions=!1,e.suggest={maxVisibleSuggestions:6},!e.accessibilitySupport&&t.android&&(e.accessibilitySupport="off"));var t=!1,n=(null==o.clientSideSuggestions&&(0<=(o.mode+"").indexOf("nrjavascript")||o.globals&&(o.globals.RED||o.globals.Buffer))&&(t=!0),monaco.languages.typescript.javascriptDefaults.getCompilerOptions());function i(t){var n=[],i=[];const a="extraModuleLibs/index.d.ts",s="file://types/extraModuleLibs/index.d.ts";if(t&&0!=t.length){var r=[],o=(Array.prototype.push.apply(r,t),{});for(let e=0;e<t.length;e++){var d=t[e],l=d.var,d=d.module,l=(l&&d&&(i.push("import "+l+"_import = require('"+d+"');\n"),n.push("var "+l+": typeof "+l+"_import;\n")),b[d]);o[d]=l||{package:"other",module:d,path:"other/"+d+".d.ts"}}Object.values(o).forEach(function(e){R(e,!1,u,function(e,t){var o;0==(r=r.filter(function(e){return e.module!=t.module})).length&&(o=i.join("")+("\ndeclare global {\n"+n.join("")+"\n}"),setTimeout(function(){u.JS[a]=monaco.languages.typescript.javascriptDefaults.addExtraLib(o,s)},500))})})}else u.JS[a]=monaco.languages.typescript.javascriptDefaults.addExtraLib(" ",s)}t?(n.lib=["esnext"],D.forEach(function(e){R(e,!1,u)})):n.lib=["esnext","dom"],monaco.languages.typescript.javascriptDefaults.setCompilerOptions(n),i(e.extraLibs);var p=monaco.editor.create(s,e);try{p._standaloneKeybindingService.addDynamicKeybinding("-editor.action.insertLineAfter",null,()=>{})}catch(e){}p.nodered={refreshModuleLibs:i};for(var d=0;d<w.length;d++){var l=w[d];p.addAction(function(t,e){return{id:"set-theme-"+t,label:RED._("monaco.setTheme")+" "+t,precondition:null,keybindingContext:e||null,run:function(e){return e.setTheme(t),null}}}(l))}function f(e,t,o){e.getOption(monaco.editor.EditorOptions.readOnly.id)?e.getModel().pushEditOperations(e.getSelections(),t,function(){return o||null}):e.executeEdits("editor",t)}function h(e,t,o){t=t||50,e?(p.focusMemory&&setTimeout(function(){o.parentElement&&p.focus()},300),p._initState&&setTimeout(function(){o.parentElement&&(p.restoreViewState(p._initState),p._initState=null)},t),"javascript"==p._mode&&"text"==p._tempMode&&(p._tempMode="",setTimeout(function(){o.parentElement&&p.setMode("javascript",void 0,!1)},t))):"javascript"==p._mode&&"text"!=p._tempMode&&o.parentElement&&(p.setMode("text",void 0,!1),p._tempMode="text")}p.selection={},(p.session=p).renderer={},p.setMode=function(e,t,o){null==o&&(o=!0),e=c(e);var n,i=p.getModel(),a=p.getValue();if(i){var s=p.getScrollTop(),r=p.getScrollLeft(),d=p.getSelections(),l=p.getPosition(),a=i.getValue()||"";try{i.isDisposed()||i.dispose()}catch(e){}p.setModel(null),n=monaco.editor.createModel(a||"",e),p.setModel(n),p.setScrollTop(s,1),p.setScrollLeft(r,1),p.setPosition(l),p.setSelections(d)}else n=monaco.editor.createModel(a||"",e),p.setModel(n);t&&"function"==typeof t&&t(),o&&this.resize()},p.getRange=function(){var e=p.getSelection();return e.start={row:e.selectionStartLineNumber-1,column:e.selectionStartColumn-1},e.end={row:e.endLineNumber-1,column:e.endColumn-1},e},p.selection.getRange=p.getRange,p.session.insert=function(e,t){f(this,[{range:new monaco.Range(e.row+1,e.column+1,e.row+1,e.column+1),text:t,forceMoveMarkers:!0}])},p.setReadOnly=function(e){p.updateOptions({readOnly:e})},p.session.replace=function(e,t){f(this,[{range:e,text:t,forceMoveMarkers:!0}])},p.selectAll=function(){var e=p.getModel().getFullModelRange();p.setSelection(e)},p.clearSelection=function(){p.setPosition({column:1,lineNumber:1})},p.getSelectedText=function(){return p.getModel().getValueInRange(p.getSelection())},p.insertSnippet=function(e){let t=p.getContribution("snippetController2");t.insert(e)},p.destroy=function(){a&&clearInterval(a);try{if(Object.keys(u.JS).length){var t=Object.entries(u.JS);for(let e=0;e<t.length;e++)try{var o=t[e][0];u.JS[o].dispose(),u.JS[o]=null,delete u.JS[o]}catch(e){}}if(Object.keys(u.TS).length){var n=Object.entries(u.TS);for(let e=0;e<n.length;e++)try{var i=n[e][0];u.TS[i].dispose(),u.TS[i]=null,delete u.TS[i]}catch(e){}}}catch(e){}try{var e=this.getModel();e&&!e.isDisposed()&&(p._initState=null,e.dispose()),this.setModel(null)}catch(e){}$(s).remove(),$(r).remove()},p.resize=function(){p.layout()},p.renderer.updateFull=p.resize.bind(p),p.getSession=function(){return p},p.getLength=function(){var e=p.getModel();return null!==e?e.getLineCount():0},p.scrollToLine=function(e,t){p.revealLine(e,t)},p.moveCursorTo=function(e,t){p.setPosition({lineNumber:e,column:t})},p.getAnnotations=function(){var e=[];try{var i,a,s,r,t=p.getModel();null!==t&&(i=t._languageId,a=t._associatedResource.authority,s=t._associatedResource.path,r=t._associatedResource.scheme,e=(monaco.editor.getModelMarkers(t)||[]).filter(function(e){var t=e.resource.authority,o=e.resource.path,n=e.resource.scheme;return e.owner==i&&t===a&&o===s&&n===r}).map(function(e){return{row:e.startLineNumber,column:e.startColumn,endColumn:e.endColumn,endRow:e.endLineNumber,text:e.message,type:monaco.MarkerSeverity[e.severity]?monaco.MarkerSeverity[e.severity].toLowerCase():e.severity}}))}catch(e){console.log("Failed to get editor Annotations",e)}return e||[]},p.gotoLine=function(e,t){p.setPosition({lineNumber:e+1,column:t+1})},p.getCursorPosition=function(){var e=p.getPosition();return{row:e.lineNumber-1,column:e.column-1}},p.setTheme=function(e){monaco.editor.setTheme(e),E=e},p.on=function(e,t){switch(e){case"change":case"input":e="onDidChangeModelContent";break;case"focus":e="onDidFocusEditorWidget";break;case"blur":e="onDidBlurEditorWidget";break;case"paste":e="onDidPaste"}var o;if(p[e])o=p[e];else{if(!monaco.editor[e])return void console.warn("monaco - unknown event: "+e);o=monaco.editor[e]}o(t)},p.getUndoManager=function(){var e={};return e.isClean=function(){try{return!1===p.getModel().canUndo()}catch(e){return!1}}.bind(p),e},p.setFontSize=function(e){p.updateOptions({fontSize:e})},p.focusMemory=o.focus,p._mode=e.language,e._language&&(p._mode=e._language,p._tempMode=e.language),p.onDidBlurEditorWidget(function(){p.focusMemory=!1,p.saveView(),0==x(s)&&h(!1,0,s)}),p.onDidFocusEditorWidget(function(){h(!0,10,s)});var g=s,m=h;try{var v={root:$(g).closest("div.red-ui-tray-content")[0]||document,attributes:!0,childList:!0};new IntersectionObserver(function(e,t){e.forEach(function(e){m(0<e.intersectionRatio,5,e.target)})},v).observe(g)}catch(e){try{let t=x(s);a=setInterval(function(){var e=x(s);e!=t&&m(e,5,g),t=e},100)}catch(e){}}return"markdown"===e.language&&($(s).addClass("red-ui-editor-text-container-toolbar"),p.toolbar=RED.editor.customEditTypes._markdown.buildToolbar(r,p),!1!==o.expandable&&(t=$('<button type="button" class="red-ui-button" style="float: right;"><i class="fa fa-expand"></i></button>').appendTo(p.toolbar),RED.popover.tooltip(t,RED._("markdownEditor.expand")),t.on("click",function(e){e.preventDefault();e=p.getValue();p.saveView(),RED.editor.editMarkdown({value:e,width:"Infinity",stateId:o.stateId,cancel:function(){p.focus()},complete:function(e,t){p.setValue(e,-1),setTimeout(function(){p.focus(),p.restoreView()},300)}})})),n=$('<button type="button" class="red-ui-editor-text-help red-ui-button red-ui-button-small"><i class="fa fa-question"></i></button>').appendTo($(s).parent()),RED.popover.create({target:n,trigger:"click",size:"small",direction:"left",content:RED._("markdownEditor.format"),autoClose:50})),p.getView=function(){return p.saveViewState()},p.saveView=function(e){var t;if(o.stateId)return window._editorStateMonaco=window._editorStateMonaco||{},t=p.getView(),window._editorStateMonaco[o.stateId]=t},p.restoreView=function(e){if(o.stateId){window._editorStateMonaco=window._editorStateMonaco||{};e=e||window._editorStateMonaco[o.stateId];if(e)try{p.type?p.restoreViewState(e):p._initState=e}catch(e){delete window._editorStateMonaco[o.stateId]}}},p.restoreView(),o.cursor&&!p._initState&&(v=o.cursor.row||o.cursor.lineNumber,e=o.cursor.column||o.cursor.col,p.gotoLine(v,e)),p.type="monaco",p}}}(),RED.eventLog=function(){var i,n=[],t=!1;return{init:function(){$('<script type="text/x-red" data-template-name="_eventLog"><div class="form-row node-text-editor-row"><div style="height: 100%;min-height: 150px;" class="node-text-editor" id="red-ui-event-log-editor"></div></div><\/script>').appendTo("#red-ui-editor-node-configs"),RED.actions.add("core:show-event-log",RED.eventLog.show)},show:function(){var e;t||(t=!0,e={title:RED._("eventLog.title"),width:1/0,buttons:[{id:"node-dialog-close",text:RED._("common.label.close"),click:function(){RED.tray.close()}}],resize:function(e){for(var t=$("#dialog-form>div:not(.node-text-editor-row)"),o=($("#dialog-form>div.node-text-editor-row"),$("#dialog-form").height()),n=0;n<t.size();n++)o-=$(t[n]).outerHeight(!0);o-=parseInt($("#dialog-form").css("marginTop"))+parseInt($("#dialog-form").css("marginBottom")),$(".node-text-editor").css("height",o+"px"),i.resize()},open:function(e){e.find(".red-ui-tray-body");e=RED.editor.buildEditForm(e.find(".red-ui-tray-body"),"dialog-form","_eventLog","editor");i=RED.editor.createEditor({mode:"ace/mode/shell",id:"red-ui-event-log-editor",value:n.join("\n"),lineNumbers:!1,readOnly:!0,options:{showPrintMargin:!1}}),setTimeout(function(){i.scrollToLine(i.getSession().getLength())},200),e.i18n()},close:function(){i.destroy(),i=null,t=!1},show:function(){}},RED.tray.show(e))},log:function(e,t){var o=new Date(t.ts).toISOString()+" ";t.type&&(o+="["+t.type+"] "),t.data&&(t=(t=t.data).endsWith("\n")?t.substring(0,t.length-1):t).split(/\n/).forEach(function(e){e=o+e,n.push(e),500<n.length&&(n=n.slice(-500)),i&&(i.getSession().insert({row:i.getSession().getLength(),column:0},"\n"+e),i.scrollToLine(i.getSession().getLength()))})},startEvent:function(e){n.push(""),n.push("-----------------------------------------------------------"),n.push((new Date).toISOString()+" "+e),n.push("")}}}(),RED.tray=function(){var h,g=[],m=!1,o=!1;function n(e){var t,o,n=$('<div class="red-ui-tray"></div>'),i=$('<div class="red-ui-tray-header editor-tray-header"></div>').appendTo(n),a=$('<div class="red-ui-tray-body-wrapper"></div>').appendTo(n),s=$('<div class="red-ui-tray-body editor-tray-body"></div>').appendTo(a),a=$('<div class="red-ui-tray-footer"></div>').appendTo(n),r=$('<div class="red-ui-tray-resize-handle"></div>').appendTo(n),d=(e.title&&((t=g.map(function(e){return e.options.title})).push(e.title),t='<ul class="red-ui-tray-breadcrumbs"><li>'+t.join("</li><li>")+"</li></ul>",$('<div class="red-ui-tray-titlebar">'+t+"</div>").appendTo(i)),e.width===1/0&&(e.maximized=!0,r.addClass("red-ui-tray-resize-maximised")),$('<div class="red-ui-tray-toolbar"></div>').appendTo(i));if(e.buttons)for(var l=0;l<e.buttons.length;l++){var c=e.buttons[l],u=$("<button>").button().appendTo(d);c.id&&u.attr("id",c.id),c.text&&u.text(c.text),c.click&&u.on("click",function(t){return function(e){$(this).hasClass("disabled")||t(e)}}(c.click)),c.class&&(u.addClass(c.class),"primary"===c.class&&(o=c))}n.appendTo(h);var p={tray:n,header:i,body:s,footer:a,options:e,primaryButton:o};function f(){$("#red-ui-header-shade").show(),$("#red-ui-editor-shade").show(),$("#red-ui-palette-shade").show(),$(".red-ui-sidebar-shade").show(),p.preferredWidth=Math.max(n.width(),500),e.maximized||s.css({minWidth:p.preferredWidth-40}),e.width?(e.width>$("#red-ui-editor-stack").position().left-8&&(e.width=$("#red-ui-editor-stack").position().left-8),n.width(e.width)):n.width(p.preferredWidth),p.width=n.width(),p.width>$("#red-ui-editor-stack").position().left-8&&(p.width=Math.max(0,$("#red-ui-editor-stack").position().left-8),n.width(p.width)),$("#red-ui-main-container").scrollLeft(0),n.css({right:-(n.width()+10)+"px",transition:"right 0.25s ease"}),v(),m=!0,setTimeout(function(){setTimeout(function(){e.width||n.width(Math.min(p.preferredWidth,$("#red-ui-editor-stack").position().left-8)),e.resize&&e.resize({width:n.width()}),e.show&&e.show(),setTimeout(function(){m=!1,b(),v()},200),e.hasOwnProperty("focusElement")?!1!==e.focusElement&&$(e.focusElement).trigger("focus"):s.find(":focusable:first").trigger("focus")},150),n.css({right:0})},0)}g.push(p),e.maximized||n.draggable({handle:r,axis:"x",start:function(e,t){n.width("auto")},drag:function(e,t){var o=h.position().left+t.position.left;o<7?t.position.left+=7-o:t.position.left>-p.preferredWidth-1&&(t.position.left=-Math.min(h.position().left-7,p.preferredWidth-1)),p.options.resize&&setTimeout(function(){p.options.resize({width:-t.position.left})},0),p.width=-t.position.left},stop:function(e,t){n.width(-t.position.left),n.css({left:""}),p.options.resize&&p.options.resize({width:-t.position.left}),p.width=-t.position.left}}),e.open?1===e.open.length?(e.open(n),f()):e.open(n,f):f()}function v(){var e,t;0<g.length&&((e=g[g.length-1]).options.maximized||e.width>$("#red-ui-editor-stack").position().left-8?(e.width=$("#red-ui-editor-stack").position().left-8,e.tray.width(e.width)):e.width<e.preferredWidth&&(e.width=Math.min($("#red-ui-editor-stack").position().left-8,e.preferredWidth),e.tray.width(e.width)),t=e.tray.height()-e.header.outerHeight()-e.footer.outerHeight(),e.body.height(t),e.options.resize&&e.options.resize({width:e.width,height:t}))}function b(){setTimeout(function(){$("#red-ui-editor-stack").css("zIndex","13")},300)}function i(){$("#red-ui-editor-stack").css("zIndex","9")}return{init:function(){h=$("#red-ui-editor-stack"),$(window).on("resize",v),RED.events.on("sidebar:resize",v),$("#red-ui-editor-shade").on("click",function(){var e;m||(e=g[g.length-1])&&e.primaryButton&&e.primaryButton.click()})},show:function(e){if(i(),e){if(o)throw new Error("Cannot add to stack whilst hidden");var t;0<g.length&&!e.overlay?(t=g[g.length-1],"inherit"===e.width&&(e.width=t.tray.width()),t.tray.css({right:-(t.tray.width()+10)+"px"}),setTimeout(function(){t.tray.detach(),n(e)},250)):(0<g.length&&g[g.length-1].tray.css("z-index",0),RED.events.emit("editor:open"),n(e))}else 0<g.length&&(g[g.length-1].tray.css({right:0}),$("#red-ui-header-shade").show(),$("#red-ui-editor-shade").show(),$("#red-ui-palette-shade").show(),$(".red-ui-sidebar-shade").show(),o=!1)},hide:function(){var e;i(),0<g.length&&((e=g[g.length-1]).tray.css({right:-(e.tray.width()+10)+"px"}),$("#red-ui-header-shade").hide(),$("#red-ui-editor-shade").hide(),$("#red-ui-palette-shade").hide(),$(".red-ui-sidebar-shade").hide(),o=!0)},resize:v,close:function(t){var o;i(),0<g.length&&((o=g.pop()).tray.css({right:-(o.tray.width()+10)+"px"}),setTimeout(function(){try{o.options.close&&o.options.close()}catch(e){}var e;o.tray.remove(),0<g.length&&((e=g[g.length-1]).options.overlay?(v(),e.options.show&&e.options.show()):(e.tray.appendTo("#red-ui-editor-stack"),setTimeout(function(){v(),e.tray.css({right:0}),e.options.show&&(b(),v(),e.options.show())},0))),t&&t(),0===g.length?($("#red-ui-header-shade").hide(),$("#red-ui-editor-shade").hide(),$("#red-ui-palette-shade").hide(),$(".red-ui-sidebar-shade").hide(),RED.events.emit("editor:close"),RED.view.focus()):g[g.length-1].tray.css("z-index","auto")},250))}}}(),RED.clipboard=function(){var m,v,o,i,c,u,r,b,e,t,a=!1,d={};function n(){m=$('<div id="red-ui-clipboard-dialog" class="hide"><form class="dialog-form form-horizontal"></form></div>').appendTo("#red-ui-editor").dialog({modal:!0,autoOpen:!1,width:700,resizable:!1,classes:{"ui-dialog":"red-ui-editor-dialog","ui-dialog-titlebar-close":"hide","ui-widget-overlay":"red-ui-editor-dialog"},buttons:[{id:"red-ui-clipboard-dialog-cancel",text:RED._("common.label.cancel"),click:function(){$(this).dialog("close"),RED.view.focus()}},{id:"red-ui-clipboard-dialog-download",class:"primary",text:RED._("clipboard.download"),click:function(){var e,t,o=$("#red-ui-clipboard-dialog-export-text").val();e="flows.json",o=o,window.navigator.msSaveBlob?(t=new Blob([o],{type:"data:text/plain;charset=utf-8"}),navigator.msSaveBlob(t,e)):((t=document.createElement("a")).setAttribute("href","data:text/plain;charset=utf-8,"+encodeURIComponent(o)),t.setAttribute("download",e),t.style.display="none",document.body.appendChild(t),t.click(),document.body.removeChild(t)),$(this).dialog("close"),RED.view.focus()}},{id:"red-ui-clipboard-dialog-export",class:"primary",text:RED._("clipboard.export.copy"),click:function(){var e,t,o,n,i,a,s;"red-ui-clipboard-dialog-export-tab-clipboard"===r?(e=$("#red-ui-clipboard-dialog-export-text").val(),$(this).dialog("close"),w(e),RED.notify(RED._("clipboard.nodesExported"),{id:"clipboard"}),RED.view.focus()):(t=$("#red-ui-clipboard-dialog-export-text").val(),(o=d[r].getSelected()).children||(o=o.parent),n=$("#red-ui-clipboard-dialog-tab-library-name").val().trim(),i=function(){$.ajax({url:"library/"+o.library+"/"+o.type+"/"+o.path+n,type:"POST",data:t,contentType:"application/json; charset=utf-8"}).done(function(){$(m).dialog("close"),RED.view.focus(),RED.notify(RED._("library.exportedToLibrary"),"success")}).fail(function(e,t,o){401===e.status?RED.notify(RED._("library.saveFailed",{message:RED._("user.notAuthorized")}),"error"):RED.notify(RED._("library.saveFailed",{message:e.responseText}),"error")})},o.children?(a=!1,o.children.forEach(function(e){e.label===n&&(a=!0)}),a?(m.dialog("close"),s=RED.notify(RED._("clipboard.export.exists",{file:RED.utils.sanitize(n)}),{type:"warning",fixed:!0,buttons:[{text:RED._("common.label.cancel"),click:function(){s.hideNotification(),m.dialog("open")}},{text:RED._("clipboard.export.overwrite"),click:function(){s.hideNotification(),i()}}]})):i()):i())}},{id:"red-ui-clipboard-dialog-ok",class:"primary",text:RED._("common.label.import"),click:function(){var e,t="red-ui-clipboard-dialog-import-opt-new"===$("#red-ui-clipboard-dialog-import-opt > a.selected").attr("id");"red-ui-clipboard-dialog-import-tab-clipboard"===r?E($("#red-ui-clipboard-dialog-import-text").val(),t):(e=d[r].getSelected()).path&&$.get("library/"+e.library+"/"+e.type+"/"+e.path,function(e){E(e,t)}),$(this).dialog("close"),RED.view.focus()}},{id:"red-ui-clipboard-dialog-import-conflict",class:"primary",text:RED._("clipboard.import.importSelected"),click:function(){var t={},e=($('#red-ui-clipboard-dialog-import-conflicts-list input[type="checkbox"]').each(function(){t[$(this).attr("data-node-id")]=this.checked?"import":"skip"}),$('.red-ui-clipboard-dialog-import-conflicts-controls input[type="checkbox"]').each(function(){$(this).attr("disabled")||(t[$(this).attr("data-node-id")]=this.checked?"replace":"copy")}),b.importOptions.importMap=t,b.importNodes.filter(function(e){return t[e.id]&&!t[e.z]||(t[e.id]=t[e.z]),"skip"!==t[e.id]}));RED.view.importNodes(e,b.importOptions),$(this).dialog("close"),RED.view.focus()}}],open:function(e,t){RED.keyboard.disable()},close:function(e){RED.keyboard.enable(),c&&(c.close(!0),u=null)}}),v=m.children(".dialog-form"),o='<div class="form-row"><label style="width:auto;margin-right: 10px;" data-i18n="common.label.export"></label><span id="red-ui-clipboard-dialog-export-rng-group" class="button-group"><a id="red-ui-clipboard-dialog-export-rng-selected" class="red-ui-button toggle" href="#" data-i18n="clipboard.export.selected"></a><a id="red-ui-clipboard-dialog-export-rng-flow" class="red-ui-button toggle" href="#" data-i18n="clipboard.export.current"></a><a id="red-ui-clipboard-dialog-export-rng-full" class="red-ui-button toggle" href="#" data-i18n="clipboard.export.all"></a></span></div><div class="red-ui-clipboard-dialog-box"><div class="red-ui-clipboard-dialog-tabs"><ul id="red-ui-clipboard-dialog-export-tabs"></ul></div><div id="red-ui-clipboard-dialog-export-tabs-content" class="red-ui-clipboard-dialog-tabs-content"><div id="red-ui-clipboard-dialog-export-tab-clipboard" class="red-ui-clipboard-dialog-tab-clipboard"><div id="red-ui-clipboard-dialog-export-tab-clipboard-tab-bar"><ul id="red-ui-clipboard-dialog-export-tab-clipboard-tabs"></ul></div><div class="red-ui-clipboard-dialog-export-tab-clipboard-tab" id="red-ui-clipboard-dialog-export-tab-clipboard-preview"><div id="red-ui-clipboard-dialog-export-tab-clipboard-preview-list"></div></div><div class="red-ui-clipboard-dialog-export-tab-clipboard-tab" id="red-ui-clipboard-dialog-export-tab-clipboard-json"><div class="form-row" style="height:calc(100% - 40px)"><textarea readonly id="red-ui-clipboard-dialog-export-text"></textarea></div><div class="form-row" style="text-align: right;"><span id="red-ui-clipboard-dialog-export-fmt-group" class="button-group"><a id="red-ui-clipboard-dialog-export-fmt-mini" class="red-ui-button red-ui-button-small toggle" href="#" data-i18n="clipboard.export.compact"></a><a id="red-ui-clipboard-dialog-export-fmt-full" class="red-ui-button red-ui-button-small toggle" href="#" data-i18n="clipboard.export.formatted"></a></span></div></div></div><div class="form-row" id="red-ui-clipboard-dialog-export-tab-library-filename"><label data-i18n="clipboard.export.exportAs"></label><input id="red-ui-clipboard-dialog-tab-library-name" type="text"></div></div></div>',i='<div class="red-ui-clipboard-dialog-box" style="margin-bottom: 12px"><div class="red-ui-clipboard-dialog-tabs"><ul id="red-ui-clipboard-dialog-import-tabs"></ul></div><div id="red-ui-clipboard-dialog-import-tabs-content" class="red-ui-clipboard-dialog-tabs-content"><div id="red-ui-clipboard-dialog-import-tab-clipboard" class="red-ui-clipboard-dialog-tab-clipboard"><div class="form-row"><span data-i18n="clipboard.pasteNodes"></span> <a class="red-ui-button" id="red-ui-clipboard-dialog-import-file-upload-btn"><i class="fa fa-upload"></i> <span data-i18n="clipboard.selectFile"></span></a><input type="file" id="red-ui-clipboard-dialog-import-file-upload" accept=".json" style="display:none"></div><div class="form-row" style="height:calc(100% - 47px)"><textarea id="red-ui-clipboard-dialog-import-text"></textarea></div></div></div></div><div class="form-row"><label style="width:auto;margin-right: 10px;" data-i18n="clipboard.import.import"></label><span id="red-ui-clipboard-dialog-import-opt" class="button-group"><a id="red-ui-clipboard-dialog-import-opt-current" class="red-ui-button toggle selected" href="#" data-i18n="clipboard.export.current"></a><a id="red-ui-clipboard-dialog-import-opt-new" class="red-ui-button toggle" href="#" data-i18n="clipboard.import.newFlow"></a></span></div>',importConflictsDialog='<div class="form-row"><div class="form-row"><p data-i18n="clipboard.import.conflictNotification1"></p><p data-i18n="clipboard.import.conflictNotification2"></p></div><div class="red-ui-clipboard-dialog-import-conflicts-list-container"><div id="red-ui-clipboard-dialog-import-conflicts-list"></div></div></div>'}function s(){e&&clearTimeout(e),e=setTimeout(function(){var e=$("#red-ui-clipboard-dialog-tab-library-name"),t=e.val().trim();0<t.length&&!/[\/\\]/.test(t)?(e.removeClass("input-error"),$("#red-ui-clipboard-dialog-export").button("enable")):(e.addClass("input-error"),$("#red-ui-clipboard-dialog-export").button("disable"))},100)}function l(){var e;"red-ui-clipboard-dialog-import-tab-clipboard"===r?(t&&clearTimeout(t),t=setTimeout(function(){var t=$("#red-ui-clipboard-dialog-import-text");if(""===(n=t.val().trim()))c.close(!0),u=null,t.removeClass("input-error"),$("#red-ui-clipboard-dialog-ok").button("disable");else try{if(!/^\[[\s\S]*\]$/m.test(n))throw new Error(RED._("clipboard.import.errors.notArray"));for(var e=JSON.parse(n),o=0;o<e.length;o++){if("object"!=typeof e[o])throw new Error(RED._("clipboard.import.errors.itemNotObject",{index:o}));if(!e[o].hasOwnProperty("id"))throw new Error(RED._("clipboard.import.errors.missingId",{index:o}));if(!e[o].hasOwnProperty("type"))throw new Error(RED._("clipboard.import.errors.missingType",{index:o}))}u=null,c.close(!0),t.removeClass("input-error"),t.val(n),$("#red-ui-clipboard-dialog-ok").button("enable")}catch(e){if(""!==n){t.addClass("input-error");t=e.toString();if(t!==u){var n,i=$('<div class="red-ui-clipboard-import-error"></div>').text(t),a=/at position (\d+)/i.exec(t);if(a)l=parseInt(a[1]);else if(a=/at line (\d+) column (\d+)/i.exec(t)){for(var s=parseInt(a[1])-1,r=parseInt(a[2])-1,d=n.split("\n"),l=0,o=0;o<s;o++)l+=d[o].length+1;l+=r}void 0!==l&&(n=n.replace(/\n/g,"↵"),parseInt(a[1]),r=$("<div>").appendTo(i),a=$("<pre>").appendTo(r),$("<span>").text(n.substring(l-12,l)).appendTo(a),$('<span class="error">').text(n.charAt(l)).appendTo(a),$("<span>").text(n.substring(l+1,l+12)).appendTo(a)),c.close(!0).setContent(i).open(),u=t}}else u=null;$("#red-ui-clipboard-dialog-ok").button("disable")}},100)):(e=d[r].getSelected())&&e.label&&!e.children?$("#red-ui-clipboard-dialog-ok").button("enable"):$("#red-ui-clipboard-dialog-ok").button("disable")}function p(e){var n,t;a||(e=e||"clipboard",v.empty(),v.append($(i)),(n=RED.tabs.create({id:"red-ui-clipboard-dialog-import-tabs",vertical:!0,onchange:function(e){$("#red-ui-clipboard-dialog-import-tabs-content").children().hide(),$("#"+e.id).show(),r=e.id,c&&(c.close(!0),u=null),"red-ui-clipboard-dialog-import-tab-clipboard"===e.id?$("#red-ui-clipboard-dialog-import-text").trigger("focus"):d[e.id].focus(),l()}})).addTab({id:"red-ui-clipboard-dialog-import-tab-clipboard",label:RED._("clipboard.clipboard")}),(RED.settings.libraries||[]).forEach(function(e){var t="red-ui-clipboard-dialog-import-tab-"+e.id,o=(n.addTab({id:t,label:RED._(e.label||e.id)}),$('<div id="red-ui-clipboard-dialog-import-tab-library" class="red-ui-clipboard-dialog-tab-library"></div>').attr("id",t).hide().appendTo("#red-ui-clipboard-dialog-import-tabs-content")),o=RED.library.createBrowser({container:o,onselect:function(e){e&&e.label&&!e.children?$("#red-ui-clipboard-dialog-ok").button("enable"):$("#red-ui-clipboard-dialog-ok").button("disable")},onconfirm:function(e){e&&e.label&&!e.children&&$("#red-ui-clipboard-dialog-ok").trigger("click")}});g(o,e),d[t]=o}),$("#red-ui-clipboard-dialog-tab-library-name").on("keyup",s),$("#red-ui-clipboard-dialog-tab-library-name").on("paste",function(){setTimeout(s,10)}),$("#red-ui-clipboard-dialog-export").button("enable"),v.i18n(),$("#red-ui-clipboard-dialog-ok").show(),$("#red-ui-clipboard-dialog-cancel").show(),$("#red-ui-clipboard-dialog-export").hide(),$("#red-ui-clipboard-dialog-download").hide(),$("#red-ui-clipboard-dialog-import-conflict").hide(),$("#red-ui-clipboard-dialog-ok").button("disable"),$("#red-ui-clipboard-dialog-import-text").on("keyup",l),$("#red-ui-clipboard-dialog-import-text").on("paste",function(){setTimeout(l,10)}),0===RED.workspaces.active()?($("#red-ui-clipboard-dialog-import-opt-current").addClass("disabled").removeClass("selected"),$("#red-ui-clipboard-dialog-import-opt-new").addClass("selected")):($("#red-ui-clipboard-dialog-import-opt-current").removeClass("disabled").addClass("selected"),$("#red-ui-clipboard-dialog-import-opt-new").removeClass("selected")),$("#red-ui-clipboard-dialog-import-opt > a").on("click",function(e){e.preventDefault(),$(this).hasClass("disabled")||$(this).hasClass("selected")||($(this).parent().children().removeClass("selected"),$(this).addClass("selected"))}),$("#red-ui-clipboard-dialog-import-file-upload").on("change",function(){var e=new FileReader;e.onload=function(){$("#red-ui-clipboard-dialog-import-text").val(e.result),l()},e.readAsText($(this).prop("files")[0])}),$("#red-ui-clipboard-dialog-import-file-upload-btn").on("click",function(e){e.preventDefault(),$("#red-ui-clipboard-dialog-import-file-upload").trigger("click")}),n.activateTab("red-ui-clipboard-dialog-import-tab-"+e),"clipboard"===e&&setTimeout(function(){$("#red-ui-clipboard-dialog-import-text").trigger("focus")},100),e=400,(t=$(window).height())<600&&(e=400-(600-t)),$(".red-ui-clipboard-dialog-box").height(e),m.dialog("option","title",RED._("clipboard.importNodes")).dialog("option","width",700).dialog("open"),c=RED.popover.create({target:$("#red-ui-clipboard-dialog-import-text"),trigger:"manual",direction:"bottom",content:""}))}function f(e){var n,i,t;a||(e=e||"clipboard",v.empty(),v.append($(o)),(n=RED.tabs.create({id:"red-ui-clipboard-dialog-export-tabs",vertical:!0,onchange:function(e){$("#red-ui-clipboard-dialog-export-tabs-content").children().hide(),$("#"+e.id).show(),r=e.id,"red-ui-clipboard-dialog-export-tab-clipboard"===e.id?($("#red-ui-clipboard-dialog-export").button("option","label",RED._("clipboard.export.copy")),$("#red-ui-clipboard-dialog-download").show(),$("#red-ui-clipboard-dialog-export-tab-library-filename").hide()):($("#red-ui-clipboard-dialog-export").button("option","label",RED._("clipboard.export.export")),$("#red-ui-clipboard-dialog-download").hide(),$("#red-ui-clipboard-dialog-export-tab-library-filename").show(),d[r].focus())}})).addTab({id:"red-ui-clipboard-dialog-export-tab-clipboard",label:RED._("clipboard.clipboard")}),(RED.settings.libraries||[]).forEach(function(e){var t,o;e.readOnly||(t="red-ui-clipboard-dialog-export-tab-library-"+e.id,n.addTab({id:t,label:RED._(e.label||e.id)}),o=$('<div class="red-ui-clipboard-dialog-export-tab-library-browser red-ui-clipboard-dialog-tab-library"></div>').attr("id",t).hide().insertBefore("#red-ui-clipboard-dialog-export-tab-library-filename"),g(o=RED.library.createBrowser({container:o,folderTools:!0,onselect:function(e){e&&e.label&&!e.children&&$("#red-ui-clipboard-dialog-tab-library-name").val(e.label)}}),e),d[t]=o)}),$("#red-ui-clipboard-dialog-tab-library-name").on("keyup",s),$("#red-ui-clipboard-dialog-tab-library-name").on("paste",function(){setTimeout(s,10)}),$("#red-ui-clipboard-dialog-export").button("enable"),(t=RED.tabs.create({id:"red-ui-clipboard-dialog-export-tab-clipboard-tabs",onchange:function(e){$(".red-ui-clipboard-dialog-export-tab-clipboard-tab").hide(),$("#"+e.id).show()}})).addTab({id:"red-ui-clipboard-dialog-export-tab-clipboard-preview",label:RED._("clipboard.exportNodes")}),t.addTab({id:"red-ui-clipboard-dialog-export-tab-clipboard-json",label:RED._("editor.types.json")}),$("#red-ui-clipboard-dialog-export-tab-clipboard-preview-list").css({position:"absolute",top:0,right:0,bottom:0,left:0}).treeList({data:[]}),h(),$("#red-ui-clipboard-dialog-tab-library-name").val("flows.json").select(),v.i18n(),i=RED.settings.flowFilePretty?"red-ui-clipboard-dialog-export-fmt-full":"red-ui-clipboard-dialog-export-fmt-mini",$("#red-ui-clipboard-dialog-export-fmt-group > a").on("click",function(e){var t;e.preventDefault(),$(this).hasClass("disabled")||$(this).hasClass("selected")?$("#red-ui-clipboard-dialog-export-text").trigger("focus"):($(this).parent().children().removeClass("selected"),$(this).addClass("selected"),0<(e=$("#red-ui-clipboard-dialog-export-text").val()).length&&(t=JSON.parse(e),e="red-ui-clipboard-dialog-export-fmt-full"===(i=$(this).attr("id"))?JSON.stringify(t,null,4):JSON.stringify(t),$("#red-ui-clipboard-dialog-export-text").val(e),setTimeout(function(){$("#red-ui-clipboard-dialog-export-text").scrollTop(0)},50),$("#red-ui-clipboard-dialog-export-text").trigger("focus")))}),$("#red-ui-clipboard-dialog-export-rng-group > a").on("click",function(e){var t,o,n;e.preventDefault(),$(this).hasClass("disabled")||$(this).hasClass("selected")||($(this).parent().children().removeClass("selected"),$(this).addClass("selected"),t=$(this).attr("id").substring("red-ui-clipboard-dialog-export-rng-".length),e="",o=null,"selected"===t?(0<(n=RED.workspaces.selection()).length?(o=[],n.forEach(function(e){o.push(e),o=(o=o.concat(RED.nodes.groups(e.id))).concat(RED.nodes.filterNodes({z:e.id}))})):o=RED.view.selection().nodes||[],o=RED.nodes.createExportableNodeSet(o.filter(function(e){return"subflow"!==e.type}))):"flow"===t?(n=RED.workspaces.active(),o=(o=(o=RED.nodes.groups(n)).concat(RED.nodes.junctions(n))).concat(RED.nodes.filterNodes({z:n})),RED.nodes.eachConfig(function(e){e.z===RED.workspaces.active()&&!1===e._def.hasUsers&&o.push(e)}),n=RED.nodes.workspace(n)||RED.nodes.subflow(n),o.unshift(n),o=RED.nodes.createExportableNodeSet(o)):"full"===t&&(o=RED.nodes.createCompleteNodeSet(!1)),0<(e=null!==o?"red-ui-clipboard-dialog-export-fmt-full"===i?JSON.stringify(o,null,4):JSON.stringify(o):e).length?$("#red-ui-clipboard-dialog-export").removeClass("disabled"):$("#red-ui-clipboard-dialog-export").addClass("disabled"),$("#red-ui-clipboard-dialog-export-text").val(e),setTimeout(function(){$("#red-ui-clipboard-dialog-export-text").scrollTop(0),h(t)},50))}),$("#red-ui-clipboard-dialog-ok").hide(),$("#red-ui-clipboard-dialog-cancel").hide(),$("#red-ui-clipboard-dialog-export").hide(),$("#red-ui-clipboard-dialog-import-conflict").hide(),0===RED.workspaces.active()?($("#red-ui-clipboard-dialog-export-rng-selected").addClass("disabled").removeClass("selected"),$("#red-ui-clipboard-dialog-export-rng-flow").addClass("disabled").removeClass("selected"),$("#red-ui-clipboard-dialog-export-rng-full").trigger("click")):0<RED.workspaces.selection().length||RED.view.selection().nodes?$("#red-ui-clipboard-dialog-export-rng-selected").trigger("click"):($("#red-ui-clipboard-dialog-export-rng-selected").addClass("disabled").removeClass("selected"),$("#red-ui-clipboard-dialog-export-rng-flow").trigger("click")),("red-ui-clipboard-dialog-export-fmt-full"===i?$("#red-ui-clipboard-dialog-export-fmt-full"):$("#red-ui-clipboard-dialog-export-fmt-mini")).trigger("click"),n.activateTab("red-ui-clipboard-dialog-export-tab-"+e),t=400,(e=$(window).height())<600&&(t=400-(600-e)),$(".red-ui-clipboard-dialog-box").height(t),m.dialog("option","title",RED._("clipboard.exportNodes")).dialog("option","width",700).dialog("open"),$("#red-ui-clipboard-dialog-export-text").trigger("focus"),$("#red-ui-clipboard-dialog-cancel").show(),$("#red-ui-clipboard-dialog-export").show(),$("#red-ui-clipboard-dialog-download").show(),$("#red-ui-clipboard-dialog-import-conflict").hide())}function h(t){var e=$("#red-ui-clipboard-dialog-export-text").val()||"[]",e=JSON.parse(e),o={},n={},i=[],a=[],s=[],r=(e.forEach(function(e){"tab"===e.type?(o[e.id]={element:R(e),deferBuild:"flow"!==t,expanded:"flow"===t,children:[]},a.push(o[e.id])):"subflow"===e.type?(n[e.id]={element:x(e),deferBuild:!0,children:[]},s.push(n[e.id])):i.push(e)}),[]),d=[],e=(i.forEach(function(e){var t={element:x(e)};e.z?o[e.z]||n[e.z]?o[e.z]?o[e.z].children.push(t):n[e.z]&&n[e.z].children.push(t):d.push(t):r.push(t)}),[]);0<d.length&&(e=e.concat(d)),"flow"===t?e=e.concat(a):0<a.length&&e.push({label:RED._("menu.label.flows"),deferBuild:20<a.length,expanded:a.length<=20,children:a}),0<s.length&&e.push({label:RED._("menu.label.subflows"),deferBuild:10<s.length,expanded:s.length<=10,children:s}),0<r.length&&e.push({label:RED._("sidebar.info.globalConfig"),deferBuild:10<r.length,expanded:r.length<=10,children:r}),$("#red-ui-clipboard-dialog-export-tab-clipboard-preview-list").treeList("data",e)}function g(e,n){var t,o="fa fa-hdd-o";n.icon&&(o=("font-awesome"===(t=RED.utils.separateIconPath(n.icon)).module?"fa ":"")+t.file),e.data([{library:n.id,type:"flows",icon:o,label:RED._(n.label||n.id),path:"",expanded:!0,children:[{library:n.id,type:"flows",icon:"fa fa-cube",label:"flows",path:"",expanded:!0,children:function(t,o){RED.library.loadLibraryFolder(n.id,"flows","",function(e){o.children=e,t(e)})}}]}],!0)}function y(){$("#red-ui-drop-target").hide()}function w(e,t,o){var n,i=!1,a=document.activeElement,s=("string"!=typeof e&&(e=JSON.stringify(e,function(e,t){if(null!==t&&"object"==typeof t&&t.__enc__){if(t.hasOwnProperty("data")&&t.hasOwnProperty("length"))return i=t.data.length!==t.length,t.data;if("function"===t.type||"internal"===t.type)return;if("number"===t.type)return null;if("bigint"===t.type)return t.data.toString();if("undefined"===t.type)return}return t})),i&&(o+="_truncated"),$('<textarea type="text" id="red-ui-clipboard-hidden" tabIndex="-1">').appendTo(document.body)),e=(s.val(e).focus().select(),document.execCommand("copy"));return e&&t&&(n=RED.popover.create({target:t,direction:"left",size:"small",content:RED._(o)}),setTimeout(function(){n.close()},1e3),n.open()),s.remove(),a&&$(a).focus(),e}function E(t,e){var o=t;if("string"==typeof t)try{if(0===(t=t.trim()).length)return;o=JSON.parse(t)}catch(e){t=new Error(RED._("clipboard.invalidFlow",{message:e.message}));throw t.code="NODE_RED",t}var p,f,h,g,t={generateIds:!1,addFlow:e};try{RED.view.importNodes(o,t)}catch(e){console.log(e.importConfig),p=e.importConfig,f=o,h=t,g=RED.notify("<p>"+RED._("clipboard.import.conflictNotification1")+"</p>",{type:"info",fixed:!0,buttons:[{text:RED._("common.label.cancel"),click:function(){g.close()}},{text:RED._("clipboard.import.viewNodes"),click:function(){g.close();var e,t,o,n,i,a,s=p,r=f,d=h,l=[],c=!(b={importConfig:s,importNodes:r,importOptions:d});for(e in s.subflows)s.subflows.hasOwnProperty(e)&&(c||(l.push({gutter:$('<span data-i18n="menu.label.subflows"></span>'),label:"",class:"red-ui-clipboard-dialog-import-conflicts-item-header"}),c=!0),t=s.subflows[e],n=s.conflicted[t.id],a=D(t,n,i=!n),o={id:t.id,gutter:a.gutter.element,element:a.element,class:i?"":"disabled",deferBuild:!0,children:[]},l.push(o),s.zMap[e]&&s.zMap[e].forEach(function(e){var t=D(e,s.conflicted[e.id],i,a.gutter.cb);o.children.push({id:e.id,gutter:t.gutter.element,element:t.element,class:i?"":"disabled"})}));for(e in c=!1,s.tabs)s.tabs.hasOwnProperty(e)&&(c||(l.push({gutter:$('<span data-i18n="menu.label.flows"></span>'),label:"",class:"red-ui-clipboard-dialog-import-conflicts-item-header"}),c=!0),t=s.tabs[e],n=s.conflicted[t.id],a=D(t,n,i=!0),o={id:t.id,gutter:a.gutter.element,element:a.element,icon:"red-ui-icons red-ui-icons-flow",deferBuild:!0,class:i?"":"disabled",children:[]},l.push(o),s.zMap[e]&&s.zMap[e].forEach(function(e){var t=D(e,s.conflicted[e.id],i,a.gutter.cb);o.children.push({id:e.id,gutter:t.gutter.element,element:t.element,class:i?"":"disabled"})}));c=!1;var u=[];s.all.forEach(function(e){var t,o;"tab"===e.type||"subflow"===e.type||s.tabs[e.z]||s.subflows[e.z]||(o=D(e,t=s.conflicted[e.id],t=!t||!s.configs[e.id]),o={id:e.id,gutter:o.gutter.element,element:o.element,class:t?"":"disabled"},s.configs[e.id]?u.push(o):(c||(l.push({gutter:$('<span data-i18n="menu.label.nodes"></span>'),label:"",class:"red-ui-clipboard-dialog-import-conflicts-item-header"}),c=!0),l.push(o)))}),0<u.length&&(l.push({gutter:$('<span data-i18n="menu.label.displayConfig"></span>'),label:"",class:"red-ui-clipboard-dialog-import-conflicts-item-header"}),c=!0,l=l.concat(u)),v.empty(),v.append($(importConflictsDialog)),$("#red-ui-clipboard-dialog-import-conflicts-list").css({position:"absolute",top:0,right:0,bottom:0,left:0}).treeList({data:l}),v.i18n(),r=400,(d=$(window).height())<600&&(r=400-(600-d)),$(".red-ui-clipboard-dialog-box").height(r),$("#red-ui-clipboard-dialog-ok").hide(),$("#red-ui-clipboard-dialog-cancel").show(),$("#red-ui-clipboard-dialog-export").hide(),$("#red-ui-clipboard-dialog-download").hide(),$("#red-ui-clipboard-dialog-import-conflict").show(),m.dialog("option","title",RED._("clipboard.importNodes")).dialog("option","width",500).dialog("open")}},{text:RED._("clipboard.import.importCopy"),click:function(){g.close(),h.generateIds=!0,RED.view.importNodes(f,h)}}]})}}function D(e,t,o,n){var i="tab"===e.type?R(e):x(e),a=$("<div>",{class:"red-ui-clipboard-dialog-import-conflicts-controls"}).appendTo(i);return a.on("click",function(e){e.stopPropagation()}),t&&!n&&(t=$("<label><input "+(o?"":"disabled ")+'type="checkbox" data-node-id="'+e.id+'"> <span data-i18n="clipboard.import.replace"></span></label>').appendTo(a),("tab"===e.type||"subflow"!==e.type&&e.hasOwnProperty("x")&&e.hasOwnProperty("y"))&&t.hide()),{element:i,gutter:function(e,t,o){var n=$("<label>",{class:"red-ui-clipboard-dialog-import-conflicts-gutter"}),e=$('<input data-node-id="'+e.id+'" type="checkbox" '+(t?"checked":"")+">").appendTo(n);o&&(e.attr("disabled",!0),o.addChild(e));n.on("click",function(e){e.stopPropagation()}),e.on("change",function(e){var t=this.checked;n.parent().toggleClass("disabled",!t),n.parent().find('.red-ui-clipboard-dialog-import-conflicts-controls input[type="checkbox"]').attr("disabled",!t),i.forEach(function(e){e.attr("checked",t),e.trigger("change")})});var i=[];return{cb:{addChild:function(e){i.push(e)}},element:n}}(e,o,n)}}function R(e){(e=JSON.parse(JSON.stringify(e)))._def=RED.nodes.getType(e.type)||{},e._def&&(e._=e._def._);var t=$("<div>",{class:"red-ui-info-outline-item red-ui-info-outline-item-flow"}),o=$("<div>",{class:"red-ui-search-result-description red-ui-info-outline-item-label"}).appendTo(t),e="string"==typeof e?e:e.label,n=e.indexOf("\\n");return-1<n&&(e=e.substring(0,n)+"..."),o.text(e),t}function x(e){(e=JSON.parse(JSON.stringify(e)))._def=RED.nodes.getType(e.type)||{},e._def&&(e._=e._def._);var t=$("<div>",{class:"red-ui-node-list-item"});return RED.utils.createNodeIcon(e,!0).appendTo(t),t}return{init:function(){n(),RED.actions.add("core:show-export-dialog",f),RED.actions.add("core:show-import-dialog",p),RED.actions.add("core:show-library-export-dialog",function(){f("library")}),RED.actions.add("core:show-library-import-dialog",function(){p("library")}),RED.actions.add("core:show-examples-import-dialog",function(){p("examples")}),RED.events.on("editor:open",function(){a=!0}),RED.events.on("editor:close",function(){a=!1}),RED.events.on("search:open",function(){a=!0}),RED.events.on("search:close",function(){a=!1}),RED.events.on("actionList:open",function(){a=!0}),RED.events.on("actionList:close",function(){a=!1}),RED.events.on("type-search:open",function(){a=!0}),RED.events.on("type-search:close",function(){a=!1}),$('<div id="red-ui-drop-target"><div data-i18n="[append]workspace.dropFlowHere"><i class="fa fa-download"></i><br></div></div>').appendTo("#red-ui-editor"),RED.keyboard.add("#red-ui-drop-target","escape",y),$("#red-ui-workspace-chart").on("dragenter",function(e){-1==$.inArray("text/plain",e.originalEvent.dataTransfer.types)&&-1==$.inArray("Files",e.originalEvent.dataTransfer.types)||$("#red-ui-drop-target").css({display:"table"}).focus()}),$("#red-ui-drop-target").on("dragover",function(e){-1==$.inArray("text/plain",e.originalEvent.dataTransfer.types)&&-1==$.inArray("Files",e.originalEvent.dataTransfer.types)||e.preventDefault()}).on("dragleave",function(e){y()}).on("drop",function(e){try{var t,o,n,i;-1!=$.inArray("text/plain",e.originalEvent.dataTransfer.types)?E(t=(t=e.originalEvent.dataTransfer.getData("text/plain")).substring(t.indexOf("["),t.lastIndexOf("]")+1)):-1!=$.inArray("Files",e.originalEvent.dataTransfer.types)&&1===(o=e.originalEvent.dataTransfer.files).length&&(n=o[0],(i=new FileReader).onload=function(e){E(e.target.result)},i.readAsText(n))}catch(e){}y(),e.preventDefault()})},import:p,export:f,copyText:w}}(),RED.library=function(){var a,c,s,u,e;function r(n,i,a,t){$.getJSON("library/"+n+"/"+i+"/"+a,function(e){e=e.map(function(e){return"string"==typeof e?{library:n,type:i,icon:"fa fa-folder",label:e,path:a+e+"/",children:function(t,o){r(n,i,a+e+"/",function(e){o.children=e,t(e)})}}:{library:n,type:i,icon:"fa fa-file-o",label:e.fn,path:a+e.fn,props:e}});e.sort(function(e,t){return e.children&&!t.children?-1:!e.children&&t.children?1:e.label.localeCompare(t.label)}),t(e)})}function t(t){e&&clearTimeout(e),e=setTimeout(function(){var e=t.val().trim();0<e.length&&!/[\/\\]/.test(e)?(t.removeClass("input-error"),$("#red-ui-library-dialog-save-button").button("enable")):(t.addClass("input-error"),$("#red-ui-library-dialog-save-button").button("disable"))},100)}return{init:function(){$('<div id="red-ui-library-dialog-save" class="hide"><form class="form-horizontal"><div class="red-ui-library-dialog-box" style="height: 400px; position:relative; "><div id="red-ui-library-dialog-save-browser"></div><div class="form-row"><label data-i18n="clipboard.export.exportAs"></label><input id="red-ui-library-dialog-save-filename" type="text"></div></div></form></div>').appendTo("#red-ui-editor").i18n(),$('<div id="red-ui-library-dialog-load" class="hide"><form class="form-horizontal"><div class="red-ui-library-dialog-box" style="height: 400px; position:relative; "><div id="red-ui-library-dialog-load-panes"><div class="red-ui-panel" id="red-ui-library-dialog-load-browser"></div><div class="red-ui-panel"><div id="red-ui-library-dialog-load-preview"><div class="red-ui-panel" id="red-ui-library-dialog-load-preview-text" style="position:relative; height: 50%; overflow-y: hidden;"></div><div class="red-ui-panel" id="red-ui-library-dialog-load-preview-details"><table id="red-ui-library-dialog-load-preview-details-table" class="red-ui-info-table"></table></div></div></div></div></div></form></div>').appendTo("#red-ui-editor").i18n(),$("#red-ui-library-dialog-save").dialog({title:RED._("library.saveToLibrary"),modal:!0,autoOpen:!1,width:800,resizable:!1,open:function(e,t){RED.keyboard.disable()},close:function(e,t){RED.keyboard.enable()},classes:{"ui-dialog":"red-ui-editor-dialog","ui-dialog-titlebar-close":"hide","ui-widget-overlay":"red-ui-editor-dialog"},buttons:[{text:RED._("common.label.cancel"),click:function(){$(this).dialog("close")}},{id:"red-ui-library-dialog-save-button",text:RED._("common.label.save"),class:"primary",click:function(){for(var t,e,o=u.elementPrefix||"node-input-",n=$("#"+o+"name").val().trim(),i=(""===n&&(n=RED._("library.unnamedType",{type:u.type})),$("#red-ui-library-dialog-save-filename").val().trim()),a=c.getSelected(),s=(a.children||(a=a.parent),{}),r=0;r<u.fields.length;r++){var d=u.fields[r];"name"===d?s.name=n:"object"==typeof d?s[d.name]=d.get():s[d]=$("#"+o+d).val()}function l(){$.ajax({url:"library/"+a.library+"/"+a.type+"/"+a.path+i,type:"POST",data:JSON.stringify(s),contentType:"application/json; charset=utf-8"}).done(function(e,t,o){RED.notify(RED._("library.savedType",{type:u.type}),"success")}).fail(function(e,t,o){401===e.status?RED.notify(RED._("library.saveFailed",{message:RED._("user.notAuthorized")}),"error"):RED.notify(RED._("library.saveFailed",{message:e.responseText}),"error")})}s.text=u.editor.getValue(),a.children?(t=!1,a.children.forEach(function(e){e.label===i&&(t=!0)}),t?($("#red-ui-library-dialog-save").dialog("close"),e=RED.notify(RED._("clipboard.export.exists",{file:RED.utils.sanitize(i)}),{type:"warning",fixed:!0,buttons:[{text:RED._("common.label.cancel"),click:function(){e.hideNotification(),$("#red-ui-library-dialog-save").dialog("open")}},{text:RED._("clipboard.export.overwrite"),click:function(){e.hideNotification(),l()}}]})):l()):l(),$(this).dialog("close")}}]}),c=RED.library.createBrowser({container:$("#red-ui-library-dialog-save-browser"),folderTools:!0,onselect:function(e){e.label&&(e.children||($("#red-ui-library-dialog-save-filename").val(e.label),e=e.parent),!1===e.writable?$("#red-ui-library-dialog-save-button").button("disable"):$("#red-ui-library-dialog-save-button").button("enable"))}}),$("#red-ui-library-dialog-save-filename").on("keyup",function(){t($(this))}),$("#red-ui-library-dialog-save-filename").on("paste",function(){var e=$(this);setTimeout(function(){t(e)},10)}),$("#red-ui-library-dialog-load").dialog({modal:!0,autoOpen:!1,width:800,resizable:!1,classes:{"ui-dialog":"red-ui-editor-dialog","ui-dialog-titlebar-close":"hide","ui-widget-overlay":"red-ui-editor-dialog"},buttons:[{text:RED._("common.label.cancel"),click:function(){$(this).dialog("close")}},{text:RED._("common.label.load"),class:"primary",click:function(){if(selectedLibraryItem){for(var e=u.elementPrefix||"node-input-",t=0;t<u.fields.length;t++){var o,n=u.fields[t];"object"==typeof n?(o=selectedLibraryItem[n.name],n.set(o)):$("#"+e+n).val(selectedLibraryItem[n])}u.editor.setValue(s.getValue(),-1)}$(this).dialog("close")}}],open:function(e){RED.keyboard.disable(),$(this).parent().find(".ui-dialog-titlebar-close").hide(),s.resize()},close:function(e){RED.keyboard.enable(),s&&(s.destroy(),s=null)}}),a=RED.library.createBrowser({container:$("#red-ui-library-dialog-load-browser"),onselect:function(n){var i=$("#red-ui-library-dialog-load-preview-details-table").empty();selectedLibraryItem=n.props,n&&n.label&&!n.children?$.get("library/"+n.library+"/"+n.type+"/"+n.path,function(e){var t,o=$('<tr class="red-ui-help-info-row"><td>Type</td><td></td></tr>').appendTo(i);for(t in $(o.children()[1]).text(u.type),n.props.hasOwnProperty("name")&&(o=$('<tr class="red-ui-help-info-row"><td>Name</td><td>'+n.props.name+"</td></tr>").appendTo(i),$(o.children()[1]).text(n.props.name)),n.props)n.props.hasOwnProperty(t)&&"name"!==t&&"fn"!==t&&(o=$('<tr class="red-ui-help-info-row"><td></td><td></td></tr>').appendTo(i),$(o.children()[0]).text(t),RED.utils.createObjectElement(n.props[t]).appendTo(o.children()[1]));s.setValue(e,-1)}):s.setValue("",-1)}}),RED.panels.create({container:$("#red-ui-library-dialog-load-panes"),dir:"horizontal",resize:function(){s.resize()}}),RED.panels.create({container:$("#red-ui-library-dialog-load-preview"),dir:"vertical",resize:function(){s.resize()}})},create:function(n){var i=n.elementPrefix||"node-input-";n.editor.setText&&(n.editor.setValue=function(e,t){n.editor.setText.call(n.editor,e)}),n.editor.getText&&(n.editor.getValue=n.editor.getText),$("#"+i+"name").css("width","calc(100% - 52px)").after('<div style="margin-left:5px; display: inline-block;position: relative;"><a id="node-input-'+n.type+'-lookup" class="red-ui-button"><i class="fa fa-book"></i> <i class="fa fa-caret-down"></i></a></div>'),RED.menu.init({id:"node-input-"+n.type+"-lookup",options:[{id:"node-input-"+n.type+"-menu-open-library",label:RED._("library.openLibrary"),onselect:function(){var e={id:"red-ui-library-dialog-load-preview-text",mode:n.mode,readOnly:!0,highlightActiveLine:!1,highlightGutterLine:!1,contextmenu:!1},t=((s=RED.editor.createEditor(e)).isACE&&(n.mode&&s.getSession().setMode(n.mode),s.setOptions({readOnly:!0,highlightActiveLine:!1,highlightGutterLine:!1}),s.renderer.$cursorLayer.element.style.opacity=0,s.$blockScrolling=1/0),u=n,[]),e=((RED.settings.libraries||[]).forEach(function(e){e.types&&-1===e.types.indexOf(n.url)||t.push({library:e.id,type:n.url,icon:e.icon||"fa fa-hdd-o",label:RED._(e.label||e.id),path:"",expanded:!0,writable:!1,children:[{library:e.id,type:n.url,icon:"fa fa-cube",label:n.type,path:"",expanded:!1,children:function(t,o){r(e.id,n.url,"",function(e){o.children=e,t(e)})}}]})}),a.data(t),setTimeout(function(){a.select(t[0].children[0])},200),400),o=$(window).height();o<570&&(e=400-(570-o)),$("#red-ui-library-dialog-load .red-ui-library-dialog-box").height(e),$("#red-ui-library-dialog-load").dialog("option","title",RED._("library.typeLibrary",{type:n.type})).dialog("open")}},{id:"node-input-"+n.type+"-menu-save-library",label:RED._("library.saveToLibrary"),onselect:function(){u=n;var e=$("#"+i+"name").val().replace(/(^\s*)|(\s*$)/g,"").replace(/[^\w-]/g,"-"),t=(""===e&&(e="unnamed-"+n.type),$("#red-ui-library-dialog-save-filename").attr("value",e+"."+(n.ext||"txt")),[]),e=((RED.settings.libraries||[]).forEach(function(e){e.types&&-1===e.types.indexOf(n.url)||t.push({library:e.id,type:n.url,icon:e.icon||"fa fa-hdd-o",label:RED._(e.label||e.id),path:"",expanded:!0,writable:!1,children:[{library:e.id,type:n.url,icon:"fa fa-cube",label:n.type,path:"",expanded:!1,children:function(t,o){r(e.id,n.url,"",function(e){o.children=e,t(e)})}}]})}),c.data(t),setTimeout(function(){c.select(t[0].children[0])},200),400),o=$(window).height();o<570&&(e=400-(570-o)),$("#red-ui-library-dialog-save .red-ui-library-dialog-box").height(e),$("#red-ui-library-dialog-save").dialog("open")}}]})},createBrowser:function(o){var e=$('<div class="red-ui-library-browser"></div>').appendTo(o.container),n=$("<div>").css({width:"100%",height:"100%"}).appendTo(e).treeList({}).on("treelistselect",function(e,t){o.onselect&&o.onselect(t)}).on("treelistconfirm",function(e,t){o.onconfirm&&o.onconfirm(t)}),i=null;return o.folderTools&&n.on("treelistselect",function(e,t){var o;!1!==t.writable&&t.treeList&&(i&&i.remove(),i=$("<div>").css({position:"absolute",bottom:"6px",right:"8px"}),o=$('<button class="red-ui-button red-ui-button-small" type="button"><i class="fa fa-ellipsis-h"></i></button>').on("click",function(e){e.preventDefault(),e.stopPropagation();var e=o.offset(),t=RED.menu.init({id:"red-ui-library-browser-menu",options:[{id:"red-ui-library-browser-menu-addFolder",label:RED._("library.newFolder"),onselect:function(){var o="new-folder",s={},r=n.treeList("selected");(r=r.children?r:r.parent).treeList.expand(function(){r.children.forEach(function(e){/^new-folder/.test(e.label)&&(s[e.label]=!0)});for(var e=2;s[o];)o="new-folder-"+e++;r.treeList.expand();function t(){var e=i.val().trim();if(""===e)n();else{for(var t=0;t<r.children.length;t++)if(r.children[t].label===e)return n();a.treeList.remove();var o={library:r.library,type:r.type,icon:"fa fa-folder",children:[],label:e,path:a.path+e+"/"};r.treeList.addChild(o,!0)}}function n(){a.treeList.remove()}var i=$('<input type="text" class="red-ui-treeList-input">').val(o),a={icon:"fa fa-folder-o",children:[],path:r.path,element:i};i.on("keydown",function(e){e.stopPropagation(),13===e.keyCode?t():27===e.keyCode&&n()}),i.on("blur",function(){t()}),r.treeList.addChild(a),setTimeout(function(){i.trigger("focus"),i.select()},400)})}}]}).on("mouseleave",function(){$(this).remove(),n.focus()}).on("mouseup",function(){var e=$(this);e.hide(),n.focus(),setTimeout(function(){e.remove()},100)}).appendTo("body");t.css({position:"absolute",top:e.top+"px",left:e.left-t.width()+20+"px"}).show()}).appendTo(i),i.appendTo(t.treeList.label))}),{select:function(e){n.treeList("select",e)},getSelected:function(){return n.treeList("selected")},focus:function(){n.focus()},data:function(e,t){n.treeList("data",e),t&&setTimeout(function(){n.treeList("select",e[0])},100)}}},export:function(){console.warn("Deprecated call to RED.library.export")},loadLibraryFolder:r}}(),RED.notifications=function(){var e,m,v={},b={show:function(){e++,$("#red-ui-full-shade").show()},hide:function(){0===--e&&$("#red-ui-full-shade").hide()}},y=[],w=e=0;function t(e,i,a,s){var r={};if(null!==i&&"object"==typeof i?(a=(r=i).fixed,s=r.timeout,i=r.type):(r.type=i,r.fixed=a,r.timeout=r.timeout),r.id&&v.hasOwnProperty(r.id))return v[r.id].update(e,r),v[r.id];if(r.modal&&b.show(),4<y.length)for(var t=y.length,o=0;4<t&&o<y.length;o+=1){var n=y[o];n.fixed||(window.clearTimeout(n.timeoutid),n.close(),--t)}var d,l,c,u,p,f,h,g=document.createElement("div");return g.id="red-ui-notification-"+w,g.className="red-ui-notification",g.options=r,g.fixed=a,i&&(g.className="red-ui-notification red-ui-notification-"+i),r.width&&(d=$("#red-ui-notifications").width(),r.width>d&&(d=-(r.width-d)/2,$(g).css({width:r.width+"px",marginLeft:d+"px"}))),g.style.display="none","string"==typeof e?(/<p>/i.test(e)||(e="<p>"+e+"</p>"),g.innerHTML=e):$(g).append(e),r.buttons&&(l=$('<div class="ui-dialog-buttonset"></div>').appendTo(g),r.buttons.forEach(function(e){var t=$("<button>").html(e.text).on("click",e.click).appendTo(l);e.id&&t.attr("id",e.id),e.class&&t.addClass(e.class)})),$("#red-ui-notifications").append(g),RED.notifications.hide||$(g).slideDown(300),g.close=(c=g,function(){c.closed||(c.closed=!0,y.splice(y.indexOf(c),1),r.id&&(delete v[r.id],0===Object.keys(v).length&&m.hide()),RED.notifications.hide?c.parentNode.removeChild(c):$(c).slideUp(300,function(){c.parentNode.removeChild(c)}),c.options.modal&&b.hide())}),g.hideNotification=(u=g,function(){u.closed||(u.hidden=!0,RED.notifications.hide||$(u).slideUp(300))}),g.showNotification=(p=g,function(){!p.closed&&p.hidden&&(p.hidden=!1,RED.notifications.hide||$(p).slideDown(300))}),g.update=(f=g,function(e,t){var o,n;"string"==typeof e?(/<p>/i.test(e)||(e="<p>"+e+"</p>"),f.innerHTML=e):$(f).empty().append(e),"number"==typeof t?f.options.timeout=o=t:void 0!==t&&(!r.modal&&t.modal?(f.options.modal=!0,b.show()):r.modal&&!1===t.modal&&(f.options.modal=!1,b.hide()),(e=t.hasOwnProperty("type")?t.type:i)&&(g.className="red-ui-notification red-ui-notification-"+e),a&&!1!==t.fixed||(o=(t.hasOwnProperty("timeout")?t.timeout:s)||5e3),t.buttons&&(n=$('<div style="margin-top: 20px;" class="ui-dialog-buttonset"></div>').appendTo(f),t.buttons.forEach(function(e){var t=$("<button>").text(e.text).on("click",e.click).appendTo(n);e.id&&t.attr("id",e.id),e.class&&t.addClass(e.class)}))),$(f).off("click.red-ui-notification-close"),void 0!==o&&0<o?(window.clearTimeout(f.timeoutid),f.timeoutid=window.setTimeout(f.close,o),setTimeout(function(){$(f).on("click.red-ui-notification-close",function(){f.close(),window.clearTimeout(f.timeoutid)})},50)):window.clearTimeout(f.timeoutid),f.hidden?f.showNotification():t&&t.silent||($(f).addClass("red-ui-notification-shake-horizontal"),setTimeout(function(){$(f).removeClass("red-ui-notification-shake-horizontal")},300))}),a||($(g).on("click.red-ui-notification-close",(h=g,function(){h.close(),window.clearTimeout(h.timeoutid)})),g.timeoutid=window.setTimeout(g.close,s||5e3)),y.push(g),r.id&&(v[r.id]=g,r.fixed&&m.show()),w+=1,g}return{init:function(){$('<div id="red-ui-notifications"></div>').appendTo("#red-ui-editor"),m=$("<li></li>").prependTo(".red-ui-header-toolbar").hide(),$('<a class="button" href="#"><i class="fa fa-warning"></i></a>').appendTo(m).on("click",function(){for(var e in v)v.hasOwnProperty(e)&&v[e].showNotification()})},notify:RED.notify=t}}(),RED.search=function(){var s,r,o,n=!1,a=null,d=-1,l=!1,c=[],m={},u=[],p=[],f=0;function h(t,o,e){if("string"==typeof e||"number"==typeof e)e=(""+e).toLowerCase(),m[e]=m[e]||{},m[e][t.id]={node:t,label:o};else if(Array.isArray(e))e.forEach(function(e){h(t,o,e)});else if("object"==typeof e)for(var n in e)e.hasOwnProperty(n)&&h(t,o,e[n])}function v(e,t,o){var n=new RegExp("(?:^| )is:"+t+"(?: |$)");return n.exec(e)&&(e=e.replace(n," ").trim(),o[t]=!0),e}function b(e,t,o){for(var n,i=new RegExp("(?:^| )"+t+":([^ ]+)(?: |$)");n=i.exec(e);)e=e.replace(i," ").trim(),o[t]=o[t]||[],o[t].push(n[1]);return e}function g(t){var o,e,n=[],i=/(?:^| )type:([^ ]+)/.exec(t),a=(i&&(t=t.replace(/(?:^| )type:[^ ]+/,""),o=i[1]),{}),i=(t=v(t,"invalid",a),t=v(t,"unused",a),t=v(t,"config",a),t=v(t,"subflow",a),t=v(t,"hidden",a),t=b(t=v(t,"modified",a),"flow",a),t=(t=b(t,"uses",a)).trim(),0<Object.keys(a).length);if(a.flow&&0<=a.flow.indexOf("current")&&(e=a.flow.indexOf("current"),a.flow[e]=RED.workspaces.active()),a.flow&&a.flow.length&&(a.flow=[...new Set(a.flow)]),0<t.length||o||i){t=t.toLowerCase();var s,r=[],d={};let e=[];for(e=a.uses||Object.keys(m),s=0;s<e.length;s++){var l=e[s],c=e[s].indexOf(t);if(-1<c)for(var u=Object.keys(m[l]||{}),p=0;p<u.length;p++){var f=m[l][u[p]],h="config"===f.node._def.category&&"group"!==f.node.type;if(!a.uses||l!==f.node.id){if(a.hasOwnProperty("invalid")){var g=!f.node.hasOwnProperty("valid")||f.node.valid;if(a.invalid===g)continue}if((!a.hasOwnProperty("config")||a.config===h)&&(!a.hasOwnProperty("subflow")||a.subflow===("subflow"===f.node.type))&&(!a.hasOwnProperty("modified")||f.node.changed||f.node.moved)){if(a.hasOwnProperty("hidden")){if("tab"!==f.node.type)continue;if(!RED.workspaces.isHidden(f.node.id))continue}if(a.hasOwnProperty("unused")){g="subflow"===f.node.type&&0===f.node.instances.length||h&&0===f.node.users.length&&!1!==f.node._def.hasUsers;if(a.unused!==g)continue}a.hasOwnProperty("flow")&&a.flow.indexOf(f.node.z||f.node.id)<0||o&&f.node.type!==o||(d[f.node.id]=d[f.node.id]={node:f.node,label:f.label},d[f.node.id].index=Math.min(d[f.node.id].index||1/0,c))}}}}for((r=Object.keys(d)).sort(function(e,t){return d[e].index-d[t].index}),s=0;s<r.length;s++)n.push(d[r[s]])}return n}function y(){var e,t,o,n=r.find("li.selected");1===n.length&&(t=(e=r.parent()).height(),e.scrollTop(),t<(o=n.position().top)+(n=n.height())?e.animate({scrollTop:"-="+(t-(o+n)-10)},50):o<0&&e.animate({scrollTop:"+="+(o-10)},50))}function w(){0<c.length&&(r.editableList("addItem",{historyHeader:!0}),c.forEach(function(e){r.editableList("addItem",{history:!0,value:e})}))}function E(e){var t=s.val(),o=c.indexOf(t);-1<o&&c.splice(o,1),c.unshift(t),$("#red-ui-view-searchtools-search").data("term",t),R(0,0<(p=Object.assign([],u)).length),RED.view.reveal(e.id)}function e(){var e;n?x():r&&p.length?(0<f?f--:f=p.length-1,(e=p[f])&&e.node&&e.node.id&&(RED.view.reveal(e.node.id),$("#red-ui-view-searchtools-prev").trigger("focus")),x()):D()}function t(){var e;n?x():r&&p.length?(f<p.length-1?f++:f=0,(e=p[f])&&e.node&&e.node.id&&(RED.view.reveal(e.node.id),$("#red-ui-view-searchtools-next").trigger("focus")),x()):D()}function D(e){var t;n?x():(l||(o=document.activeElement,$("#red-ui-header-shade").show(),$("#red-ui-editor-shade").show(),$("#red-ui-palette-shade").show(),$("#red-ui-sidebar-shade").show(),$("#red-ui-sidebar-separator").hide(),null===a?(a=$("<div>",{id:"red-ui-search",class:"red-ui-search"}).appendTo("#red-ui-main-container"),t=$("<div>",{class:"red-ui-search-container"}).appendTo(a),s=$('<input type="text" data-i18n="[placeholder]menu.label.searchInput">').appendTo(t).searchBox({delay:200,change:function(){r.editableList("empty"),d=-1;var e=$(this).val();if(""===e)w();else if(0<(u=g(e)).length){for(let e=0;e<Math.min(u.length,25);e++)r.editableList("addItem",u[e]);25<u.length&&r.editableList("addItem",{more:{results:u,start:25}})}else r.editableList("addItem",{})},options:L()}),$('<button type="button" class="red-ui-button red-ui-button-small"><i class="fa fa-caret-right"></button>').appendTo(t).on("click",function(e){e.preventDefault(),RED.sidebar.info.outliner.search(s.val()),R()}),s.on("keydown",function(e){if(0<u.length)if(40===e.keyCode)o=r.children(),d<o.length-1&&(-1<d&&$(o[d]).removeClass("selected"),d++),$(o[d]).addClass("selected"),y(),e.preventDefault();else if(38===e.keyCode)o=r.children(),0<d&&(d<o.length&&$(o[d]).removeClass("selected"),d--),$(o[d]).addClass("selected"),y(),e.preventDefault();else if(13===e.keyCode){var t,o=r.children();if($(o[d]).hasClass("red-ui-search-more"))if(t=$(o[d]).find(".red-ui-editableList-item-content").data("data")){for(r.editableList("removeItem",t),i=t.more.start;i<Math.min(u.length,t.more.start+25);i++)r.editableList("addItem",u[i]);u.length>t.more.start+25&&r.editableList("addItem",{more:{results:u,start:t.more.start+25}})}$(o[d]).hasClass("red-ui-search-history")?(t=$(o[d]).find(".red-ui-editableList-item-content").data("data"))&&s.searchBox("value",t.value):$(o[d]).hasClass("red-ui-search-historyHeader")||0<u.length&&(f=Math.max(0,d),E(u[f].node))}}),s.i18n(),t=$("<div>",{class:"red-ui-search-results-container"}).appendTo(a),r=$("<ol>",{style:"position: absolute;top: 5px;bottom: 5px;left: 5px;right: 5px;"}).appendTo(t).editableList({addButton:!1,addItem:function(e,t,o){var n,i,a=o.node;o.historyHeader?(e.parent().addClass("red-ui-search-historyHeader"),$("<div>",{class:"red-ui-search-empty"}).text(RED._("search.history")).appendTo(e),$('<button type="button" class="red-ui-button red-ui-button-small"></button>').text(RED._("search.clear")).appendTo(e).on("click",function(e){e.preventDefault(),c=[],r.editableList("empty")})):o.history?(e.parent().addClass("red-ui-search-history"),(n=$("<a>",{href:"#",class:"red-ui-search-result"}).appendTo(e)).text(o.value),n.on("click",function(e){e.preventDefault(),s.searchBox("value",o.value),s.focus()}),$('<button type="button" class="red-ui-button red-ui-button-small"><i class="fa fa-remove"></i></button>').appendTo(e).on("click",function(e){e.preventDefault();e=c.indexOf(o.value);c.splice(e,1),r.editableList("removeItem",o)})):o.more?(e.parent().addClass("red-ui-search-more"),(n=$("<a>",{href:"#",class:"red-ui-search-result red-ui-search-empty"}).appendTo(e)).text(RED._("palette.editor.more",{count:o.more.results.length-o.more.start})),n.on("click",function(e){for(e.preventDefault(),r.editableList("removeItem",o),t=o.more.start;t<Math.min(u.length,o.more.start+25);t++)r.editableList("addItem",u[t]);u.length>o.more.start+25&&r.editableList("addItem",{more:{results:u,start:o.more.start+25}})})):void 0===a?$("<div>",{class:"red-ui-search-empty"}).text(RED._("search.empty")).appendTo(e):(a._def,n=$("<a>",{href:"#",class:"red-ui-search-result"}).appendTo(e),RED.utils.createNodeIcon(a).appendTo(n),e=$("<div>",{class:"red-ui-search-result-node-description"}).appendTo(n),a.z&&(i=(i=RED.nodes.workspace(a.z))?"flow:"+i.label:"subflow:"+(i=RED.nodes.subflow(a.z)).name,$("<div>",{class:"red-ui-search-result-node-flow"}).text(i).appendTo(e)),$("<div>",{class:"red-ui-search-result-node-label"}).text(o.label||a.id).appendTo(e),$("<div>",{class:"red-ui-search-result-node-type"}).text(a.type).appendTo(e),$("<div>",{class:"red-ui-search-result-node-id"}).text(a.id).appendTo(e),n.on("click",function(e){e.preventDefault(),f=t,E(a)}))},scrollOnAdd:!1})):r.editableList("empty"),a.slideDown(300),s.searchBox("value",e),e&&""!==e||w(),RED.events.emit("search:open"),l=!0),s.trigger("focus"))}function R(e,t){l&&(l=!1,$("#red-ui-header-shade").hide(),$("#red-ui-editor-shade").hide(),$("#red-ui-palette-shade").hide(),$("#red-ui-sidebar-shade").hide(),$("#red-ui-sidebar-separator").show(),null!==a&&a.slideUp(200,function(){s.searchBox("value","")}),RED.events.emit("search:close"),!o||t&&p.length||$(o).trigger("focus"),o=null),t||j(),x(),t&&p.length&&$("#red-ui-view-searchtools-next").trigger("focus")}function x(){if(!n&&0<=f&&p&&p.length){let e=$("#red-ui-view-searchtools-search").data("term")||"";var t={term:e=16<e.length?e.substring(0,12)+"...":e,result:f+1,count:p.length};$("#red-ui-view-searchtools-counter").text(RED._("actions.search-counter",t)),$("#view-search-tools > :not(:first-child)").show()}else j(),$("#view-search-tools > :not(:first-child)").hide()}function _(){m={}}function k(e){{var t=e,o=RED.utils.getNodeLabel(t),n=(o&&(o=(""+o).toLowerCase(),m[o]=m[o]||{},m[o][t.id]={node:t,label:o}),o=o||t.label||t.name||t.id||"",["id","type","name","label","info"]);const s=t&&t._def;if(s&&(s.defaults&&(n=n.concat(Object.keys(s.defaults))),"group"!==t.type&&s.paletteLabel&&s.paletteLabel!==s.type))try{var i=(""+("function"==typeof s.paletteLabel?s.paletteLabel.call(s):s.paletteLabel)).toLowerCase();i&&i!==(""+s.type).toLowerCase()&&h(t,o,i)}catch(e){console.warn("error indexing "+o,e)}for(var a=0;a<n.length;a++)!t.hasOwnProperty(n[a])||"group"===t.type&&"nodes"===n[a]||h(t,o,t[n[a]])}}function T(e){for(var t=Object.keys(m),o=0,n=t.length;o<n;o++)delete m[t[o]][e.id],0===Object.keys(m[t[o]]).length&&delete m[t[o]]}function C(e){T(e),k(e)}function j(){p=[],f=0,$("#red-ui-view-searchtools-search").data("term","")}function L(){return[{label:RED._("search.options.configNodes"),value:"is:config"},{label:RED._("search.options.unusedConfigNodes"),value:"is:config is:unused"},{label:RED._("search.options.modifiedNodes"),value:"is:modified"},{label:RED._("search.options.invalidNodes"),value:"is:invalid"},{label:RED._("search.options.uknownNodes"),value:"type:unknown"},{label:RED._("search.options.unusedSubflows"),value:"is:subflow is:unused"},{label:RED._("search.options.hiddenFlows"),value:"is:hidden"},{label:RED._("search.options.thisFlow"),value:"flow:current"}]}return{init:function(){RED.actions.add("core:search",D),RED.actions.add("core:search-previous",e),RED.actions.add("core:search-next",t),RED.events.on("editor:open",function(){n=!0}),RED.events.on("editor:close",function(){n=!1}),RED.events.on("type-search:open",function(){n=!0}),RED.events.on("type-search:close",function(){n=!1}),RED.events.on("actionList:open",function(){n=!0}),RED.events.on("actionList:close",function(){n=!1}),RED.keyboard.add("red-ui-search","escape",R),RED.keyboard.add("view-search-tools","escape",function(){j(),x()}),$("#red-ui-header-shade").on("mousedown",R),$("#red-ui-editor-shade").on("mousedown",R),$("#red-ui-palette-shade").on("mousedown",R),$("#red-ui-sidebar-shade").on("mousedown",R),$("#red-ui-view-searchtools-close").on("click",function(){j(),x()}),$("#red-ui-view-searchtools-close").trigger("click"),RED.events.on("workspace:clear",_),RED.events.on("flows:add",k),RED.events.on("flows:remove",T),RED.events.on("flows:change",C),RED.events.on("subflows:add",k),RED.events.on("subflows:remove",T),RED.events.on("subflows:change",C),RED.events.on("nodes:add",k),RED.events.on("nodes:remove",T),RED.events.on("nodes:change",C),RED.events.on("groups:add",k),RED.events.on("groups:remove",T),RED.events.on("groups:change",C)},show:D,hide:R,search:g,getSearchOptions:L}}(),RED.contextMenu=function(){let p;function f(){$(document).off("mousedown.red-ui-workspace-context-menu"),p&&p.remove(),p=null}return RED.keyboard.add("red-ui-workspace-context-menu","escape",function(){RED.contextMenu.hide()}),RED.events.on("editor:open",function(){RED.contextMenu.hide()}),RED.events.on("search:open",function(){RED.contextMenu.hide()}),RED.events.on("type-search:open",function(){RED.contextMenu.hide()}),RED.events.on("actionList:open",function(){RED.contextMenu.hide()}),RED.events.on("view:selection-changed",function(){RED.contextMenu.hide()}),{show:function(e){p&&p.remove();const t=RED.view.selection();t&&Object.keys(t).length;var o=t.nodes&&0<t.nodes.length;o&&t.nodes.length,t.links&&t.links.filter(e=>!!e.link);var n=0<(a=t.links&&t.links.filter(e=>!e.link)||[]).length;const i=!o&&n&&1===a.length;!o&&n&&a.length;var a=o||n,s=o&&1===t.nodes.length&&"group"===t.nodes[0].type,r=o&&!!t.nodes[0].g,d=$("#red-ui-workspace-chart").offset();let l=(e.x+5-d.left+$("#red-ui-workspace-chart").scrollLeft())/RED.view.scale(),c=(e.y+5-d.top+$("#red-ui-workspace-chart").scrollTop())/RED.view.scale();const u=[{onselect:"core:show-action-list",onpostselect:function(){}},{label:RED._("contextMenu.insert"),options:[{label:RED._("contextMenu.node"),onselect:function(){RED.view.showQuickAddDialog({position:[l,c],touchTrigger:!0,splice:i?t.links[0]:void 0})},onpostselect:function(){$("#red-ui-type-search-input").trigger("focus")}},n?{label:RED._("contextMenu.junction"),onselect:"core:split-wires-with-junctions",disabled:!n}:{label:RED._("contextMenu.junction"),onselect:function(){var e={_def:{defaults:{}},type:"junction",z:RED.workspaces.active(),id:RED.nodes.id(),x:l,y:c,w:0,h:0,outputs:1,inputs:1,dirty:!0},t={dirty:RED.nodes.dirty(),t:"add",junctions:[e]};RED.nodes.addJunction(e),RED.history.push(t),RED.nodes.dirty(!0),RED.view.select({nodes:[e]}),RED.view.redraw(!0)}},{label:RED._("contextMenu.linkNodes"),onselect:"core:split-wire-with-link-nodes",disabled:!n}]}];u.push(null,{onselect:"core:undo",disabled:0===RED.history.list().length},{onselect:"core:redo",disabled:0===RED.history.listRedo().length},null,{onselect:"core:cut-selection-to-internal-clipboard",label:RED._("keyboard.cutNode"),disabled:!o},{onselect:"core:copy-selection-to-internal-clipboard",label:RED._("keyboard.copyNode"),disabled:!o},{onselect:"core:paste-from-internal-clipboard",label:RED._("keyboard.pasteNode"),disabled:!RED.view.clipboard()},{onselect:"core:delete-selection",disabled:!a},{onselect:"core:show-export-dialog",label:RED._("menu.label.export")},{onselect:"core:select-all-nodes"}),o&&(u.push(null,s?{onselect:"core:ungroup-selection",disabled:!s}:{onselect:"core:group-selection",disabled:!o}),r&&u.push({onselect:"core:remove-selection-from-group",label:RED._("menu.label.groupRemoveSelection")})),d="right",e.x-$(document).scrollLeft()>$(window).width()-500&&(d="left"),(p=RED.menu.init({direction:d,onpreselect:function(){f()},onpostselect:function(){RED.view.focus()},options:u})).attr("id","red-ui-workspace-context-menu"),p.css({position:"absolute"}),p.appendTo("body"),n=e.y,a=e.x,n+p.height()-$(document).scrollTop()>$(window).height()&&(n-=n+p.height()-$(window).height()+22),a+p.width()-$(document).scrollLeft()>$(window).width()&&(a-=a+p.width()-$(window).width()+18),p.css({top:n+"px",left:a+"px"}),$(".red-ui-menu.red-ui-menu-dropdown").hide(),$(document).on("mousedown.red-ui-workspace-context-menu",function(e){p&&p[0].contains(e.target)||f()}),p.show(),$("#red-ui-workspace-context-menu :first(ul) > a").trigger("focus")},hide:f}}(),RED.actionList=function(){var o,i,n,a=!1,s=null,r=!1,d="",l=[];function c(){var e,t,o,n=i.find("li.selected");1===n.length&&(t=(e=i.parent()).height(),e.scrollTop(),t<(o=n.position().top)+(n=n.height())?e.animate({scrollTop:"-="+(t-(o+n)-10)},50):o<0&&e.animate({scrollTop:"+="+(o-10)},50))}function u(e){t(),e&&RED.actions.invoke(e.id)}function e(e){var t;a||(r||(n=document.activeElement,$("#red-ui-header-shade").show(),$("#red-ui-editor-shade").show(),$("#red-ui-palette-shade").show(),$("#red-ui-sidebar-shade").show(),$("#red-ui-sidebar-separator").hide(),null===s&&(s=$("<div>",{id:"red-ui-actionList",class:"red-ui-search"}).appendTo("#red-ui-main-container"),t=$("<div>",{class:"red-ui-search-container"}).appendTo(s),(o=$('<input type="text" data-i18n="[placeholder]keyboard.filterActions">').appendTo(t).searchBox({change:function(){d=$(this).val().trim(),l=d.split(" "),i.editableList("filter"),i.find("li.selected").removeClass("selected");var e=i.children(":visible");e.length&&$(e[0]).addClass("selected")}})).on("keydown",function(e){var t,o,n;40===e.keyCode?((o=i.find("li.selected")).length?(n=o.nextAll(":visible").first()).length&&(o.removeClass("selected"),n.addClass("selected")):(t=i.children(":visible")).length&&$(t[0]).addClass("selected"),c(),e.preventDefault()):38===e.keyCode?((n=(o=i.find("li.selected")).prevAll(":visible").first()).length&&(o.removeClass("selected"),n.addClass("selected")),c(),e.preventDefault()):13===e.keyCode&&(o=i.find("li.selected"),u(i.editableList("getItem",o)))}),o.i18n(),t=$("<div>",{class:"red-ui-search-results-container"}).appendTo(s),i=$("<ol>",{style:"position: absolute;top: 5px;bottom: 5px;left: 5px;right: 5px;"}).appendTo(t).editableList({addButton:!1,addItem:function(e,t,o){var n;void 0===o.id?$("<div>",{class:"red-ui-search-empty"}).text(RED._("search.empty")).appendTo(e):(e=$("<a>",{href:"#",class:"red-ui-search-result"}).appendTo(e),n=$("<div>",{class:"red-ui-search-result-action"}).appendTo(e),$("<div>").text(o.label).appendTo(n),o.key&&$("<div>",{class:"red-ui-search-result-action-key"}).html(RED.keyboard.formatKey(o.key)).appendTo(n),e.on("click",function(e){e.preventDefault(),u(o)}))},scrollOnAdd:!1,filter:function(e){if(""!==d)for(var t=0,o=0;o<l.length;o++){var n=e._label.indexOf(l[o],t);if(!(-1<n))return!1;t=n}return!0}})),s.slideDown(300),o.searchBox("value",e),i.editableList("empty"),results=[],(t=RED.actions.list()).sort(function(e,t){e=e.label,t=t.label;return e.localeCompare(t)}),t.forEach(function(e){e._label=e.label.toLowerCase(),i.editableList("addItem",e)}),RED.events.emit("actionList:open"),r=!0),o.trigger("focus"),(e=i.children(":visible")).length&&$(e[0]).addClass("selected"))}function t(){r&&(r=!1,$("#red-ui-header-shade").hide(),$("#red-ui-editor-shade").hide(),$("#red-ui-palette-shade").hide(),$("#red-ui-sidebar-shade").hide(),$("#red-ui-sidebar-separator").show(),null!==s&&s.slideUp(200,function(){o.searchBox("value","")}),RED.events.emit("actionList:close"),n&&($(n).trigger("focus"),n=null))}return{init:function(){RED.actions.add("core:show-action-list",e),RED.events.on("editor:open",function(){a=!0}),RED.events.on("editor:close",function(){a=!1}),RED.events.on("search:open",function(){a=!0}),RED.events.on("search:close",function(){a=!1}),RED.events.on("type-search:open",function(){a=!0}),RED.events.on("type-search:close",function(){a=!1}),RED.keyboard.add("red-ui-actionList","escape",function(){t()}),$("#red-ui-header-shade").on("mousedown",t),$("#red-ui-editor-shade").on("mousedown",t),$("#red-ui-palette-shade").on("mousedown",t),$("#red-ui-sidebar-shade").on("mousedown",t)},show:e,hide:t}}(),RED.typeSearch=function(){var d,l,t,i,o,n,a=null,c=-1,s=!1,r="",u={};function p(){var e,t,o,n=l.find("li.selected");1===n.length&&(t=(e=l.parent()).height(),e.scrollTop(),t<(o=n.position().top)+(n=n.height())?e.animate({scrollTop:"-="+(t-(o+n)-10)},50):o<0&&e.animate({scrollTop:"+="+(o-10)},50))}function f(e,t){var o=a.position();o.top=o.top+t+"px",o.left=o.left+e+"px",a.css(o),n(e,t)}function h(){a=$("<div>",{id:"red-ui-type-search",class:"red-ui-search red-ui-type-search"}).appendTo("#red-ui-main-container");var e=$("<div>",{class:"red-ui-search-container"}).appendTo(a);(d=$('<input type="text" id="red-ui-type-search-input">').attr("placeholder",RED._("search.addNode")).appendTo(e).searchBox({delay:50,change:function(){var e;e=$(this).val(),r=e.toLowerCase(),l.editableList("filter"),l.editableList("sort"),setTimeout(function(){c=0,l.children().removeClass("selected"),l.children(":visible:first").addClass("selected")},100)}})).on("keydown",function(e){var t,o,n=l.children(":visible");40===e.keyCode&&e.shiftKey?(e.preventDefault(),f(0,10)):38===e.keyCode&&e.shiftKey?(e.preventDefault(),f(0,-10)):39===e.keyCode&&e.shiftKey?(e.preventDefault(),f(10,0)):37===e.keyCode&&e.shiftKey?(e.preventDefault(),f(-10,0)):0<n.length?40===e.keyCode?(c<n.length-1&&(-1<c&&$(n[c]).removeClass("selected"),c++),$(n[c]).addClass("selected"),p(),e.preventDefault()):38===e.keyCode?(0<c&&(c<n.length&&$(n[c]).removeClass("selected"),c--),$(n[c]).addClass("selected"),p(),e.preventDefault()):(e.metaKey||e.ctrlKey)&&13===e.keyCode?(e.preventDefault(),(o=Math.max(0,c))<n.length&&(t=$(n[o]).find(".red-ui-editableList-item-content").data("data"),/^_action_:/.test(t.type)||(u[t.type]=Date.now()),0===t.def.outputs?g(t):i(t.type,!0),$("#red-ui-type-search-input").val("").trigger("keyup"),setTimeout(function(){$("#red-ui-type-search-input").focus()},100))):13===e.keyCode&&(e.preventDefault(),(o=Math.max(0,c))<n.length&&g($(n[o]).find(".red-ui-editableList-item-content").data("data"))):13===e.keyCode&&(e.stopPropagation(),e.preventDefault())}),t=$("<div>",{class:"red-ui-search-results-container"}).appendTo(a),l=$("<ol>",{style:"position: absolute;top: 0;bottom: 0;left: 0;right: 0;"}).appendTo(t).editableList({addButton:!1,filter:function(e){return""===r||!e.recent&&!e.common&&(""===r||-1<e.index.indexOf(r))},sort:function(e,t){if(""===r)return e.i-t.i;var o=e.index.indexOf(r),n=t.index.indexOf(r);return-1===o?1:-1===n?-1:o===n?y(e,t):o-n},addItem:function(e,t,o){var n=o.def,e=(o.index=o.type.toLowerCase(),o.separator&&e.addClass("red-ui-search-result-separator"),$("<div>",{class:"red-ui-search-result"}).appendTo(e)),i=$("<div>",{class:"red-ui-search-result-node"}).appendTo(e),a=("junction"===o.type||/^_action_:/.test(o.type)?i.addClass("red-ui-palette-icon-junction"):(a=RED.utils.getNodeColor(o.type,n),i.css("backgroundColor",a)),RED.utils.getNodeIcon(n)),s=$("<div/>",{class:"red-ui-palette-icon-container"}).appendTo(i),a=(RED.utils.createIconElement(a,s,!1),/^_action_:/.test(o.type)||"junction"===o.type||(0<n.inputs&&$("<div/>",{class:"red-ui-search-result-node-port"}).appendTo(i),0<n.outputs&&$("<div/>",{class:"red-ui-search-result-node-port red-ui-search-result-node-output"}).appendTo(i)),$("<div>",{class:"red-ui-search-result-description"}).appendTo(e)),s=o.label;o.index+="|"+s.toLowerCase(),$("<div>",{class:"red-ui-search-result-node-label"}).text(s).appendTo(a),e.on("click",function(e){e.preventDefault(),g(o)})},scrollOnAdd:!1})}function g(e){v(),/^_action_:/.test(e.type)||(u[e.type]=Date.now()),i(e.type)}function m(e){if(s){for(var t=$(e.target);"body"!==t.prop("nodeName").toLowerCase();){if("red-ui-type-search"===t.attr("id"))return;t=t.parent()}v(!0),o&&o()}}function v(e){s&&(s=!1,null!==a&&t.slideUp(e?50:200,function(){a.hide(),d.searchBox("value","")}),RED.events.emit("type-search:close"),RED.view.focus(),$(document).off("mousedown.red-ui-type-search"),$(document).off("mouseup.red-ui-type-search"),$(document).off("click.red-ui-type-search"),$(document).off("touchstart.red-ui-type-search"))}function b(t,e){var o=t;if(void 0!==e.paletteLabel)try{o=("function"==typeof e.paletteLabel?e.paletteLabel.call(e):e.paletteLabel)||"",o+=" ("+t+")"}catch(e){console.log("Definition error: "+t+".paletteLabel",e)}return o}function y(e,t){e=e.label.toLowerCase(),t=t.label.toLowerCase();return e<t?-1:e===t?0:1}function w(e,t,o){return!e||!e.spliceMultiple&&(!e.type||t===e.type)&&(!e.input||"junction"===t||0<o.inputs)&&(!e.output||"junction"===t||0<o.outputs)}function E(t){l.editableList("empty"),d.searchBox("value","").focus(),c=-1;for(var e,o=["inject","debug","function","change","switch","junction"].filter(function(e){return w(t.filter,e,RED.nodes.getType(e))}),n=Object.keys(u),i=(n.sort(function(e,t){return u[t]-u[e]}),n=n.filter(function(e){return w(t.filter,e,RED.nodes.getType(e))&&-1===o.indexOf(e)}),[]),a=(RED.nodes.registry.getNodeTypes().forEach(function(e){var t=RED.nodes.getType(e);"config"!==t.category&&"unknown"!==e&&"tab"!==e&&i.push({type:e,def:t,label:b(e,t)})}),i.sort(y),0),s=0;s<o.length;s++){var r=RED.nodes.getType(o[s]);"junction"===o[s]?r={inputs:1,outputs:1,label:"junction",type:"junction"}:/^_action_:/.test(o[s])&&(r={inputs:1,outputs:1,label:o[s],type:o[s]}),r&&((e={type:o[s],common:!0,def:r,i:a++}).label=b(e.type,e.def),s===o.length-1&&(e.separator=!0),l.editableList("addItem",e))}for(s=0;s<Math.min(5,n.length);s++)(e={type:n[s],def:RED.nodes.getType(n[s]),recent:!0,i:a++}).label=b(e.type,e.def),s===n.length-1&&(e.separator=!0),l.editableList("addItem",e);for(s=0;s<i.length;s++)w(t.filter,i[s].type,i[s].def)&&(i[s].i=a++,l.editableList("addItem",i[s]));setTimeout(function(){c=0,l.children(":first").addClass("selected")},100)}return{show:function(e){s?(a.hide(),t.hide()):(null===a&&(h(),RED.keyboard.add("red-ui-type-search","escape",function(){v(),o&&o()})),s=!0),$(document).off("mousedown.red-ui-type-search"),$(document).off("mouseup.red-ui-type-search"),$(document).off("click.red-ui-type-search"),$(document).off("touchstart.red-ui-type-search"),$(document).off("mousedown.red-ui-type-search"),setTimeout(function(){$(document).on("mousedown.red-ui-type-search",m),$(document).on("mouseup.red-ui-type-search",m),$(document).on("click.red-ui-type-search",m),$(document).on("touchstart.red-ui-type-search",m)},200),E(e),i=e.add,o=e.cancel,n=e.move,RED.events.emit("type-search:open"),$("#red-ui-main-container").height()-e.y-195<0&&(e.y=e.y-275),a.css({left:e.x+"px",top:e.y+"px"}).show(),t.slideDown(300),setTimeout(function(){t.find(".red-ui-editableList-container").scrollTop(0),e.disableFocus||d.trigger("focus")},200)},refresh:E,hide:v}}(),RED.subflow=function(){function s(e,t){var o={x:50,y:30},n=(t||(o.x+=110),[].concat(e.out).concat(e.in));e.status&&n.push(e.status),n.sort(function(e,t){return e.x-t.x});for(var i=0;i<n.length;i++){var a=n[i];a.x==o.x&&a.y==o.y&&(o.x+=55)}return o}function r(){var t,o,n=RED.nodes.subflow(RED.workspaces.active());if(0!==n.in.length)return t=n.in[0],o=[],RED.nodes.eachLink(function(e){("subflow"==e.source.type&&e.source.z==n.id&&e.source.i==t.i||e.target.type=="subflow:"+n.id)&&o.push(e)}),o.forEach(function(e){RED.nodes.removeLink(e)}),n.in=[],$("#red-ui-subflow-input-add").removeClass("active"),$("#red-ui-subflow-input-remove").addClass("active"),n.changed=!0,RED.events.emit("subflows:change",n),{subflowInputs:[t],links:o}}function d(e){var t=RED.nodes.subflow(RED.workspaces.active());if(0!==t.out.length){var o=[];for((e=void 0===e?[t.out[t.out.length-1]]:e).sort(function(e,t){return t.i-e.i}),i=0;i<e.length;i++){var n=e[i],a=(t.out.splice(n.i,1),[]),s=[];RED.nodes.eachLink(function(e){"subflow"==e.target.type&&e.target.z==t.id&&e.target.i==n.i&&a.push(e),e.source.type=="subflow:"+t.id&&(e.sourcePort==n.i?a.push(e):e.sourcePort>n.i&&s.push(e))}),a.forEach(function(e){RED.nodes.removeLink(e)}),s.forEach(function(e){e.sourcePort--});for(var o=o.concat(a),r=n.i;r<t.out.length;r++)t.out[r].i--,t.out[r].dirty=!0}return t.changed=!0,RED.events.emit("subflows:change",t),{subflowOutputs:e,links:o}}}function l(){var t,o=RED.nodes.subflow(RED.workspaces.active());if(o.status)return t=[],RED.nodes.eachLink(function(e){"subflow"==e.target.type&&e.target.z==o.id&&"status"==e.target.direction&&t.push(e)}),t.forEach(function(e){RED.nodes.removeLink(e)}),delete o.status,$("#red-ui-subflow-status").prop("checked",!!o.status),$("#red-ui-subflow-status").parent().parent().toggleClass("active",!!o.status),{links:t}}function c(t){var o=RED.nodes.subflow(RED.workspaces.active()),n=(u(o),[]);if(o)return RED.nodes.filterNodes({type:"subflow:"+o.id}).forEach(function(e){n.push({id:e.id,changed:e.changed}),t&&(e.changed=!0),e.inputs=o.in.length,e.outputs=o.out.length,e.resize=!0,e.dirty=!0,RED.editor.updateNodeProperties(e)}),RED.editor.validateNode(o),{instances:n}}function u(e){e&&($("#red-ui-subflow-input-add").toggleClass("active",0!==e.in.length),$("#red-ui-subflow-input-remove").toggleClass("active",0===e.in.length),$("#red-ui-subflow-output .spinner-value").text(e.out.length),$("#red-ui-subflow-status").prop("checked",!!e.status),$("#red-ui-subflow-status").parent().parent().toggleClass("active",!!e.status))}function t(a){var e=$("#red-ui-workspace-toolbar");e.empty(),$('<a class="button" id="red-ui-subflow-edit" href="#" data-i18n="[append]subflow.editSubflowProperties"><i class="fa fa-pencil"></i> </a>').appendTo(e),$('<span style="margin-left: 5px;" data-i18n="subflow.input"></span> <div style="display: inline-block;" class="button-group"><a id="red-ui-subflow-input-remove" class="button active" href="#">0</a><a id="red-ui-subflow-input-add" class="button" href="#">1</a></div>').appendTo(e),$('<span style="margin-left: 5px;" data-i18n="subflow.output"></span> <div id="red-ui-subflow-output" style="display: inline-block;" class="button-group spinner-group"><a id="red-ui-subflow-output-remove" class="button" href="#"><i class="fa fa-minus"></i></a><div class="spinner-value">3</div><a id="red-ui-subflow-output-add" class="button" href="#"><i class="fa fa-plus"></i></a></div>').appendTo(e),$('<span class="button-group"><span class="button" style="padding:0"><label for="red-ui-subflow-status"><input id="red-ui-subflow-status" type="checkbox"> <span data-i18n="subflow.status"></span></label></span></span>').appendTo(e),$('<a class="button" id="red-ui-subflow-delete" href="#" data-i18n="[append]subflow.deleteSubflow"><i class="fa fa-trash"></i> </a>').appendTo(e),e.i18n(),$("#red-ui-subflow-output-remove").on("click",function(e){e.preventDefault();var t,e=RED.nodes.dirty(),o=a.changed,n=d();n&&(t=c(!0),RED.history.push({t:"delete",links:n.links,subflowOutputs:n.subflowOutputs,changed:o,dirty:e,subflow:{instances:t.instances}}),RED.view.select(),RED.nodes.dirty(!0),RED.view.redraw(!0))}),$("#red-ui-subflow-output-add").on("click",function(e){var t,o,n,i;e.preventDefault(),e=RED.nodes.subflow(RED.workspaces.active()),t=s(e,!1),t={type:"subflow",direction:"out",z:e.id,i:e.out.length,x:t.x,y:t.y,id:RED.nodes.id()},o=e.out.length,e.out.push(t),e.dirty=!0,t=RED.nodes.dirty(),n=e.changed,i=c(e.changed=!0),t={t:"edit",node:e,dirty:t,changed:n,subflow:{outputCount:o,instances:i.instances}},RED.history.push(t),RED.view.select(),RED.nodes.dirty(!0),RED.view.redraw(),$("#red-ui-subflow-output .spinner-value").text(e.out.length),RED.events.emit("subflows:change",e)}),$("#red-ui-subflow-input-add").on("click",function(e){var t,o,n,i;e.preventDefault(),1!==(e=RED.nodes.subflow(RED.workspaces.active())).in.length&&(i=s(e,!0),i={type:"subflow",direction:"in",z:e.id,i:e.in.length,x:i.x,y:i.y,id:RED.nodes.id()},t=e.in.length,e.in.push(i),e.dirty=!0,i=RED.nodes.dirty(),o=e.changed,n=c(e.changed=!0),i={t:"edit",node:e,dirty:i,changed:o,subflow:{inputCount:t,instances:n.instances}},RED.history.push(i),RED.view.select(),RED.nodes.dirty(!0),RED.view.redraw(),$("#red-ui-subflow-input-add").addClass("active"),$("#red-ui-subflow-input-remove").removeClass("active"),RED.events.emit("subflows:change",e))}),$("#red-ui-subflow-input-remove").on("click",function(e){e.preventDefault();var t,e=RED.nodes.dirty(),o=a.changed,n=(a.changed=!0,r());n&&(t=c(!0),RED.history.push({t:"delete",links:n.links,changed:o,subflowInputs:n.subflowInputs,dirty:e,subflow:{instances:t.instances}}),RED.view.select(),RED.nodes.dirty(!0),RED.view.redraw(!0))}),$("#red-ui-subflow-status").on("change",function(e){var t,o,n,i;this.checked?(i=RED.nodes.subflow(RED.workspaces.active())).status||(o=s(i,!1),o={type:"subflow",direction:"status",z:i.id,x:o.x,y:o.y,id:RED.nodes.id()},i.status=o,i.dirty=!0,o=RED.nodes.dirty(),n=i.changed,c(i.changed=!0),RED.history.push({t:"edit",node:i,dirty:o,changed:n,subflow:{status:!0}}),RED.view.select(),RED.nodes.dirty(!0),RED.view.redraw(),RED.events.emit("subflows:change",i),$("#red-ui-subflow-status").prop("checked",!!i.status),$("#red-ui-subflow-status").parent().parent().toggleClass("active",!!i.status)):(o=a.status,n=a.changed,(i=l())&&(a.changed=!0,t=RED.nodes.dirty(),RED.history.push({t:"delete",links:i.links,changed:n,dirty:t,subflow:{id:a.id,status:o}}),RED.view.select(),RED.nodes.dirty(!0),RED.view.redraw()))}),$("#red-ui-subflow-edit").on("click",function(e){RED.editor.editSubflow(RED.nodes.subflow(RED.workspaces.active())),e.preventDefault()}),$("#red-ui-subflow-delete").on("click",function(e){e.preventDefault();var t,o,e=RED.nodes.subflow(RED.workspaces.active());function n(){var e=RED.nodes.dirty(),t=p(RED.workspaces.active());t.t="delete",t.dirty=e,RED.history.push(t)}0<e.instances.length?(t=$("<div>"),$("<p>").text(RED._("subflow.subflowInstances",{count:e.instances.length})).appendTo(t),$("<p>").text(RED._("subflow.confirmDelete")).appendTo(t),o=RED.notify(t,{modal:!0,fixed:!0,buttons:[{text:RED._("common.label.cancel"),click:function(){o.close()}},{text:RED._("workspace.confirmDelete"),class:"primary",click:function(){o.close(),n()}}]})):n()}),u(a),$("#red-ui-workspace-chart").css({"margin-top":"40px"}),$("#red-ui-workspace-toolbar").show()}function p(t,o){for(var n=[],e=[],i=[],a=RED.nodes.subflow(t),s=(RED.nodes.eachNode(function(e){o||e.type!="subflow:"+t||n.push(e),e.z==t&&n.push(e)}),RED.nodes.eachConfig(function(e){e.z==t&&n.push(e)}),RED.nodes.groups(t).forEach(function(e){i.push(e)}),RED.nodes.junctions(t)),r=0;r<s.length;r++)var d=RED.nodes.removeJunction(s[r]),e=e.concat(d.links);for(var l=[],r=0;r<n.length;r++){d=RED.nodes.remove(n[r].id);e=e.concat(d.links),l=l.concat(d.nodes)}for(n=n.concat(l),i=RED.nodes.groups(t).filter(function(e){return!e.g}),r=0;r<i.length;r++)i[r].nodes.forEach(function(e){"group"===e.type&&i.push(e)});for(r=i.length-1;0<=r;r--)RED.nodes.removeGroup(i[r]);return RED.nodes.removeSubflow(a),RED.workspaces.remove(a),RED.nodes.dirty(!0),RED.view.redraw(),{nodes:n,links:e,groups:i,junctions:s,subflows:[a]}}function e(){var t=0,e=(RED.nodes.eachSubflow(function(e){e=new RegExp("^Subflow (\\d+)$").exec(e.name);e&&(t=Math.max(t,e[1]))}),"Subflow "+(t+1)),o=RED.nodes.id(),e={type:"subflow",id:o,name:e,info:"",in:[],out:[]};RED.nodes.addSubflow(e),RED.history.push({t:"createSubflow",subflow:{subflow:e},dirty:RED.nodes.dirty()}),RED.workspaces.show(o),RED.nodes.dirty(!0)}function R(e){return e=RED.settings.get("editor").view["view-snap-grid"]?Math.round(e/RED.view.gridSize())*RED.view.gridSize():e}function x(e){var t=RED.nodes.node(e);return t||RED.nodes.junction(e)}function o(){var e=RED.view.selection();if(e.nodes){for(var n,t=new Set,o=e.nodes.slice(),i=new Set;0<o.length;)"group"===(n=o.shift()).type&&(i.add(n.id),o=o.concat(n.nodes)),t.add(n);for(var a=(t=Array.from(t))[0].g,s=[],r=0;r<t.length;r++)if(t[r].g&&!i.has(t[r].g)&&a!==t[r].g)return void RED.notify("Cannot create subflow across multiple groups","error");var a=a&&RED.nodes.group(a),d={},l=[],c=[],u=[],p=[],f={},h=[t[0].x,t[0].y,t[0].x,t[0].y];for(r=0;r<t.length;r++)n=t[r],d[n.id]={n:n,outputs:{}},h=[Math.min(h[0],n.x),Math.min(h[1],n.y),Math.max(h[2],n.x),Math.max(h[3],n.y)];var g=R(h[0]-200),m=R(h[1]-80),e=[R((h[2]+h[0])/2),R((h[3]+h[1])/2)],v=(RED.nodes.eachLink(function(e){d[e.source.id]&&d[e.target.id],d[e.source.id]&&!d[e.target.id]&&(p.push(e),c.push(e)),!d[e.source.id]&&d[e.target.id]&&(u.push(e),f[e.target.id]=e.target,c.push(e))}),{});if((p=p.filter(function(e){return v[e.source.id+":"+e.sourcePort]?(v[e.source.id+":"+e.sourcePort].targets.push(e.target),!1):(e.targets=[],e.targets.push(e.target),v[e.source.id+":"+e.sourcePort]=e,!0)})).sort(function(e,t){return e.source.y-t.source.y}),1<Object.keys(f).length)RED.notify(RED._("subflow.errors.multipleInputsToSelection"),"error");else{var b=0,y=(RED.nodes.eachSubflow(function(e){e=new RegExp("^Subflow (\\d+)$").exec(e.name);e&&(b=Math.max(b,e[1]))}),"Subflow "+(b+1)),w=RED.nodes.id(),E={type:"subflow",id:w,name:y,info:"",in:Object.keys(f).map(function(e,t){return{type:"subflow",direction:"in",x:R(f[e].x-f[e].w/2-80-g),y:R(f[e].y-m),z:w,i:t,id:RED.nodes.id(),wires:[{id:f[e].id}]}}),out:p.map(function(e,t){return{type:"subflow",direction:"out",x:R(e.source.x+e.source.w/2+80-g),y:R(e.source.y-m),z:w,i:t,id:RED.nodes.id(),wires:[{id:e.source.id,port:e.sourcePort}]}})},D=(RED.nodes.addSubflow(E),{id:RED.nodes.id(),type:"subflow:"+E.id,x:e[0],y:e[1],z:RED.workspaces.active(),inputs:E.in.length,outputs:E.out.length,h:Math.max(30,15*(E.out.length||0)),changed:!0});for(D._def=RED.nodes.getType(D.type),RED.editor.validateNode(D),RED.nodes.add(D),a&&(RED.group.addToGroup(a,D),t.forEach(function(e){var t;e.g===a.id&&(delete e.g,t=a.nodes.indexOf(e),a.nodes.splice(t,1),s.push(e))}),a.dirty=!0),u.forEach(function(e){e={source:e.source,sourcePort:e.sourcePort,target:D};l.push(e),RED.nodes.addLink(e)}),p.forEach(function(e,t){e.targets.forEach(function(e){e={source:D,sourcePort:t,target:e};l.push(e),RED.nodes.addLink(e)})}),E.in.forEach(function(t){t.wires.forEach(function(e){e={source:t,sourcePort:0,target:x(e.id)};l.push(e),RED.nodes.addLink(e)})}),E.out.forEach(function(t,e){t.wires.forEach(function(e){e={source:x(e.id),sourcePort:e.port,target:t};l.push(e),RED.nodes.addLink(e)})}),r=0;r<c.length;r++)RED.nodes.removeLink(c[r]);for(r=0;r<t.length;r++)n=t[r],/^link /.test(n.type)&&(n.links=n.links.filter(function(e){var t,o=d.hasOwnProperty(e);return o||(e=x(e))&&e.links&&(-1<(t=e.links.indexOf(n.id))&&e.links.splice(t,1)),o})),n.x-=g,n.y-=m,RED.nodes.moveNodeToTab(n,E.id);y={t:"createSubflow",nodes:[D.id],links:l,subflow:{subflow:E,offsetX:g,offsetY:m},activeWorkspace:RED.workspaces.active(),removedLinks:c,dirty:RED.nodes.dirty()};a&&((y={t:"multi",events:[y]}).events.push({t:"addToGroup",group:a,nodes:[D]}),y.events.push({t:"removeFromGroup",group:a,nodes:s,reparent:!1})),RED.history.push(y),RED.editor.validateNode(E),RED.nodes.dirty(!0),RED.view.updateActive(),RED.view.select(null),RED.view.focus()}}else RED.notify(RED._("subflow.errors.noNodesSelected"),"error")}function f(e,t,o){e.empty();for(var n=0;n<t.length;n++){var i=t[n];i.ui&&"hide"===i.ui.type||!function(e,t,o,n){o.label=o.label||{},("cred"===t.type||t.parent&&"cred"===t.parent.type)&&!o.type?(o.type="cred",o.opts={}):o.type?o.opts||(o.opts="select"===o.type?{opts:[]}:{}):(o.type="input",o.opts={types:RED.editor.envVarList.DEFAULT_ENV_TYPE_LIST});var i=o.label||{},a=RED.i18n.lang(),s=RED.editor.envVarList.lookupLabel(i,i["en-US"]||t.name,a),r=$("<label>").appendTo(e),d=($("<span>&nbsp;</span>").appendTo(e),$("<span></span>").appendTo(r)),l=(!o.icon||(i=RED.utils.separateIconPath(o.icon))&&$("<i class='fa "+i.file+"'/>").appendTo(d),"checkbox"!==o.type&&(i=o.icon?{"padding-left":"5px"}:{},$("<span>").css(i).text(s).appendTo(r),"none"===o.type&&r.width("100%")),{value:"",type:"str"});switch(t.parent&&(l.value=t.parent.value,l.type=t.parent.type),t.hasOwnProperty("value")&&(l.value=t.value),t.hasOwnProperty("type")&&(l.type=t.type),o.type){case"input":var c=$('<input type="text">').css("width","70%").appendTo(e);o.opts.types&&0<o.opts.types.length?(u=l.type,-1===o.opts.types.indexOf(u)&&(u=o.opts.types[0]),c.typedInput({types:o.opts.types,default:u}),c.typedInput("value",l.value),"cred"===u&&n.credentials&&(n.credentials[t.name]?c.typedInput("value",n.credentials[t.name]):n.credentials["has_"+t.name]?c.typedInput("value","__PWRD__"):c.typedInput("value",""))):c.val(l.value);break;case"select":c=$("<select>").css("width","70%").appendTo(e),o.opts.opts&&o.opts.opts.forEach(function(e){$("<option>").val(e.v).text(RED.editor.envVarList.lookupLabel(e.l,e.l["en-US"]||e.v,a)).appendTo(c)}),c.val(l.value);break;case"checkbox":r.css("cursor","default");var u=$("<label>").css("width","70%").appendTo(e),u=(c=$('<input type="checkbox">').css({marginTop:0,width:"auto",height:"34px"}).appendTo(u),d.css({"padding-left":"5px"}).appendTo(u),$("<span>").css({"padding-left":"5px"}).text(s).appendTo(u),!1),u="bool"===l.type?"true"===l.value:"num"===l.type?"0"!==l.value:""!==l.value;c.prop("checked",u);break;case"spinner":c=$("<input>").css("width","70%").appendTo(e);u={};o.opts.hasOwnProperty("min")&&(u.min=o.opts.min),o.opts.hasOwnProperty("max")&&(u.max=o.opts.max),c.spinner(u).parent().width("70%"),c.val(l.value);break;case"cred":c=$('<input type="password">').css("width","70%").appendTo(e),n.credentials?n.credentials[t.name]?c.val(n.credentials[t.name]):n.credentials["has_"+t.name]?c.val("__PWRD__"):c.val(""):c.val(""),c.typedInput({types:["cred"],default:"cred"})}c&&c.attr("id",m(t.name))}($("<div/>",{class:"form-row"}).appendTo(e),i,i.ui||{},o)}}function h(e,r){var d;return e?(d=[],e.each(function(e){var t=$(this).data("data"),o=(t.parent?t.name:t.nameField.val()).trim();if(""!==o||t.ui&&"none"===t.ui.type){var n=t.valueField,i=n.typedInput("value"),n=n.typedInput("type");if(r||!t.parent||t.parent.value!==i||t.parent.type!==n){var a={name:o,type:n,value:i};if(t.ui){var s={icon:t.ui.icon,label:$.extend(!0,{},t.ui.label),type:t.ui.type,opts:$.extend(!0,{},t.ui.opts)};switch(s.icon||delete s.icon,$.isEmptyObject(s.label)&&delete s.label,s.type){case"input":JSON.stringify(s.opts)===JSON.stringify({types:RED.editor.envVarList.DEFAULT_ENV_TYPE_LIST})&&(delete s.type,delete s.opts);break;case"cred":"cred"===a.type&&delete s.type,delete s.opts;break;case"select":s.opts&&$.isEmptyObject(s.opts.opts)&&delete s.opts;break;case"spinner":$.isEmptyObject(s.opts)&&delete s.opts;break;default:delete s.opts}$.isEmptyObject(s)||(a.ui=s)}d.push(a)}}}),d):null}function g(a){var o={},s=[];if(/^subflow:/.test(a.type)){var e=RED.nodes.subflow(a.type.substring(8));if(e.env&&e.env.forEach(function(e){var t={name:e.name,parent:{type:e.type,value:e.value},ui:$.extend(!0,{},e.ui)};s.push(t),o[e.name]=t}),a.env)for(var t=0;t<a.env.length;t++){var n=a.env[t];o.hasOwnProperty(n.name)&&(o[n.name].type=n.type,o[n.name].value=n.value)}}else a._def.subflowModule&&Object.keys(a._def.defaults).forEach(function(e){if("name"!==e){var t,o=a._def.defaults[e],n=a[e],i=n;if(o.ui&&"cred"===o.ui.type)t="cred";else switch(typeof n){case"string":t="str";break;case"number":t="num";break;case"boolean":t="bool",i=n?"true":"false";break;default:t=n.type,i=n.value}e={name:e,type:t,value:i,parent:{type:o.type,value:o.value},ui:$.extend(!0,{},o.ui)};s.push(e)}});return s}function m(e){return"node-input-subflow-env-"+e.replace(/[^a-z0-9-_]/gi,"_")}return{init:function(){RED.events.on("workspace:change",function(e){e=RED.nodes.subflow(e.workspace);e?t(e):($("#red-ui-workspace-toolbar").hide().empty(),$("#red-ui-workspace-chart").css({"margin-top":"0"}))}),RED.events.on("view:selection-changed",function(e){e.nodes?RED.menu.setDisabled("menu-item-subflow-convert",!1):RED.menu.setDisabled("menu-item-subflow-convert",!0)}),RED.actions.add("core:create-subflow",e),RED.actions.add("core:convert-to-subflow",o),$('<script type="text/x-red" data-template-name="subflow"><div class="form-row"><label for="node-input-name" data-i18n="[append]editor:common.label.name"><i class="fa fa-tag"></i> </label><input type="text" id="node-input-name" data-i18n="[placeholder]common.label.name"></div><div id="subflow-input-ui"></div><\/script>').appendTo("#red-ui-editor-node-configs"),$('<script type="text/x-red" data-template-name="subflow-template"><div class="form-row"><label for="subflow-input-name" data-i18n="[append]common.label.name"><i class="fa fa-tag"></i> </label><input type="text" id="subflow-input-name" data-i18n="[placeholder]common.label.name"></div><div class="form-row"><ul style="margin-bottom: 20px;" id="subflow-env-tabs"></ul></div><div id="subflow-env-tabs-content"><div id="subflow-env-tab-edit"><div class="form-row node-input-env-container-row" id="subflow-input-edit-ui"><ol id="node-input-env-container"></ol><div class="node-input-env-locales-row"><i class="fa fa-language"></i> <select id="subflow-input-env-locale"></select></div></div></div><div id="subflow-env-tab-preview"><div id="subflow-input-ui"/></div></div><\/script>').appendTo("#red-ui-editor-node-configs")},createSubflow:e,convertToSubflow:o,removeSubflow:p,refresh:c,removeInput:r,removeOutput:d,removeStatus:l,buildEditForm:function(e,t){var o,n,i,a;"subflow-template"===e?(o=$("#node-input-env-container"),n=t,(i=RED.tabs.create({id:"subflow-env-tabs",onchange:function(e){"subflow-env-tab-preview"===e.id&&f($("#subflow-input-ui"),h(o.editableList("items"),!0),n),$("#subflow-env-tabs-content").children().hide(),$("#"+e.id).show()}})).addTab({id:"subflow-env-tab-edit",label:RED._("editor-tab.envProperties")}),i.addTab({id:"subflow-env-tab-preview",label:RED._("editor-tab.preview")}),i=RED.settings.theme("languages").map(function(e){var t=RED._("languages."+e);return{text:t||e,val:e}}).sort(function(e,t){return e.text.localeCompare(t.text)}),RED.popover.tooltip($(".node-input-env-locales-row i"),RED._("editor.locale")),a=$("#subflow-input-env-locale"),i.forEach(function(e){var t={value:e.val};"en-US"===e.val&&(t.selected=""),$("<option/>",t).text(e.text).appendTo(a)}),i=RED.i18n.lang(),a.val(i),a.on("change",function(){RED.editor.envVarList.setLocale($(this).val(),$("#node-input-env-container"))}),RED.editor.envVarList.setLocale(i),RED.editor.envVarList.create($("#node-input-env-container"),t)):"subflow"===e&&f($("#subflow-input-ui"),g(t),t)},exportSubflowTemplateEnv:h,exportSubflowInstanceEnv:function(e){var i=[];return g(e).forEach(function(e){var t,o=e.ui||{},n=(o.type?o.opts=o.opts||{}:e.parent&&"cred"===e.parent.type?o.type="cred":(o.type="input",o.opts={types:RED.editor.envVarList.DEFAULT_ENV_TYPE_LIST}),$("#"+m(e.name)));if(n.length||"cred"===o.type){switch(t={name:e.name},o.type){case"input":o.opts.types&&0<o.opts.types.length?(t.value=n.typedInput("value"),t.type=n.typedInput("type")):(t.value=n.val(),t.type="str");break;case"cred":t.value=n.val(),t.type="cred";break;case"spinner":t.value=n.val(),t.type="num";break;case"select":t.value=n.val(),t.type="str";break;case"checkbox":t.type="bool",t.value=""+n.prop("checked")}"cred"!==o.type&&t.type===e.parent.type&&t.value===e.parent.value||i.push(t)}}),i}}}(),RED.group=function(){for(var i=["#ff0000","#ffC000","#ffff00","#92d04f","#0070c0","#001f60","#6f2fa0","#000000","#777777"],a=i.length,e=0,t=3*i.length;e<t;e++){var o=e%a,n=Math.floor(e/a)+1,s=i[o],r=parseInt(s.substring(1,3),16),d=parseInt(s.substring(3,5),16),s=parseInt(s.substring(5,7),16),l=(255-d)/(3+(o==a-1?0:1)),c=(255-s)/(3+(o==a-1?0:1)),r=((Math.min(255,Math.floor(r+n*((255-r)/(3+(o==a-1?0:1)))))<<16)+(Math.min(255,Math.floor(d+n*l))<<8)+Math.min(255,Math.floor(s+n*c))).toString(16);i.push("#"+"000000".slice(0,6-r.length)+r)}var u,f={label:!0,"label-position":"nw"};function p(e){var t=/^rgb\((\d+), (\d+), (\d+)\)$/.exec(e);return t?(t=((parseInt(t[1])<<16)+(parseInt(t[2])<<8)+parseInt(t[3])).toString(16),"#"+"000000".slice(0,6-t.length)+t):e}function h(e){var t=[],o=RED.nodes.group(e.g);return e.nodes.forEach(function(e){t.push(e),o?(e.g=o.id,o.nodes.push(e),o.dirty=!0,e.dirty=!0):delete e.g,"group"===e.type?RED.events.emit("groups:change",e):"junction"!==e.type?RED.events.emit("nodes:change",e):RED.events.emit("junctions:change",e)}),RED.nodes.removeGroup(e),t}function g(e){if(0!==e.length){if(!(0<e.filter(function(e){return"subflow"===e.type}).length)){var t={id:RED.nodes.id(),type:"group",nodes:[],style:JSON.parse(JSON.stringify(f)),x:Number.POSITIVE_INFINITY,y:Number.POSITIVE_INFINITY,w:0,h:0,_def:RED.group.def};t.z=e[0].z,RED.nodes.addGroup(t);try{m(t,e)}catch(e){return void RED.notify(e,"error")}return t}RED.notify(RED._("group.errors.cannotAddSubflowPorts"),"error")}}function m(e,t){var o,n,i,a,s;for(Array.isArray(t)||(t=[t]),o=0;o<t.length;o++){if(!(s=t[o]).z)throw new Error("Cannot add node without a z property to a group");if(n){if(n!==s.z)throw new Error("Cannot add nooes with different z properties")}else n=s.z;if(s.g&&!i){if(0!==o)throw new Error(RED._("group.errors.cannotCreateDiffGroups"));i=s.g}if(i!==s.g)throw new Error(RED._("group.errors.cannotCreateDiffGroups"))}for(i&&((i=RED.nodes.group(i)).nodes.push(e),i.dirty=!0,e.g=i.id),o=0;o<t.length;o++)"subflow"!==(s=t[o]).type&&(i&&s.g===i.id&&-1<(a=i.nodes.indexOf(s))&&i.nodes.splice(a,1),s.g=e.id,s.dirty=!0,e.nodes.push(s),e.x=Math.min(e.x,s.x-s.w/2-25-(s._def.button&&"right"!==s._def.align?20:0)),e.y=Math.min(e.y,s.y-s.h/2-25),e.w=Math.max(e.w,s.x+s.w/2+25+(s._def.button&&"right"==s._def.align?20:0)-e.x),e.h=Math.max(e.h,s.y+s.h/2+25-e.y),"group"===s.type?RED.events.emit("groups:change",s):"junction"!==s.type?RED.events.emit("nodes:change",s):RED.events.emit("junctions:change",s));i&&RED.events.emit("groups:change",e),b(e)}function v(e,t,o){var n;Array.isArray(t)||(t=[t]);for(var i=0;i<t.length;i++)if(t[i].g!==e.id)return;for(var a=RED.nodes.group(e.g),i=0;i<t.length;i++){(n=t[i]).dirty=!0;var s=e.nodes.indexOf(n);e.nodes.splice(s,1),o&&e.g?(n.g=e.g,a.nodes.push(n)):delete n.g,"group"===n.type?RED.events.emit("groups:change",n):"junction"!==n.type?RED.events.emit("nodes:change",n):RED.events.emit("junctions:change",n)}b(e)}function b(e){for(e.dirty=!0;e;)e.dirty=!0,e=RED.nodes.group(e.g)}return{def:{defaults:{name:{value:""},style:{value:{label:!0}},nodes:{value:[]},env:{value:[]}},category:"config",oneditprepare:function(){var e,t,c,u,o,n=this.style||{};function p(){var e=c.val();o.removeClass().addClass("red-ui-group-layout-picker-cell-text red-ui-group-layout-text-pos-"+e)}RED.editor.colorPicker.create({id:"node-input-style-stroke",value:n.stroke||f.stroke||"#a4a4a4",defaultValue:"#a4a4a4",palette:i,cellPerRow:a,cellWidth:16,cellHeight:16,cellMargin:3,none:!0,opacity:n.hasOwnProperty("stroke-opacity")?n["stroke-opacity"]:f.hasOwnProperty("stroke-opacity")?f["stroke-opacity"]:1}).appendTo("#node-input-row-style-stroke"),RED.editor.colorPicker.create({id:"node-input-style-fill",value:n.fill||f.fill||"none",defaultValue:"none",palette:i,cellPerRow:a,cellWidth:16,cellHeight:16,cellMargin:3,none:!0,opacity:n.hasOwnProperty("fill-opacity")?n["fill-opacity"]:f.hasOwnProperty("fill-opacity")?f["fill-opacity"]:1}).appendTo("#node-input-row-style-fill"),e={id:"node-input-style-label-position",value:n["label-position"]||"nw"},t=$("<div>",{style:"display:inline-block"}),c=$("<input/>",{id:e.id,type:"hidden",value:e.value}).appendTo(t),u=$('<button type="button" class="red-ui-button red-ui-editor-node-appearance-button">').appendTo(t),$('<i class="fa fa-caret-down"></i>').appendTo(u),e=$("<div>",{class:"red-ui-search-result-node"}).appendTo(u),o=$("<div>",{class:"red-ui-group-layout-picker-cell-text red-ui-group-layout-text-pos-"}).appendTo(e),u.on("click",function(e){var t,o=$("<div/>",{class:"red-ui-group-layout-picker"}).css({width:"126px"});$("<div/>").appendTo(o);for(var n=0;n<2;n++)for(var i="ns"[n],a=$("<div/>").appendTo(o),s=0;s<3;s++){var r=i+["w","","e"][s],d=$("<button/>",{class:"red-ui-search-result-node red-ui-button","data-pos":r}).appendTo(a);d.on("click",function(e){e.preventDefault(),c.val($(this).data("pos")),l.hide(),p()}),$("<div>",{class:"red-ui-group-layout-picker-cell-text red-ui-group-layout-text-pos-"+r}).appendTo(d),r===c.val()&&(t=d)}p();var l=RED.popover.panel(o);l.show({target:u,onclose:function(){u.focus()}}),t&&t.focus()}),p(),t.appendTo("#node-input-row-style-label-position"),RED.editor.colorPicker.create({id:"node-input-style-color",value:n.color||f.color||"#a4a4a4",defaultValue:"#a4a4a4",palette:i,cellPerRow:a,cellWidth:16,cellHeight:16,cellMargin:3}).appendTo("#node-input-row-style-label-color"),$("#node-input-style-label").toggleButton({enabledLabel:RED._("editor.show"),disabledLabel:RED._("editor.show")}),$("#node-input-style-label").on("change",function(e){$("#node-input-row-style-label-options").toggle($(this).prop("checked"))}),$("#node-input-style-label").prop("checked",this.style.label),$("#node-input-style-label").trigger("change")},oneditresize:function(e){},oneditsave:function(){this.style.stroke=$("#node-input-style-stroke").val(),this.style.fill=$("#node-input-style-fill").val(),this.style["stroke-opacity"]=$("#node-input-style-stroke-opacity").val(),this.style["fill-opacity"]=$("#node-input-style-fill-opacity").val(),this.style.label=$("#node-input-style-label").prop("checked"),this.style.label?(this.style["label-position"]=$("#node-input-style-label-position").val(),this.style.color=$("#node-input-style-color").val()):(delete this.style["label-position"],delete this.style.color);var t=this;["stroke","fill","stroke-opacity","fill-opacity","color","label-position"].forEach(function(e){t.style[e]===f[e]&&delete t.style[e]}),this.resize=!0},set:{module:"node-red"}},init:function(){RED.events.on("view:selection-changed",function(e){var t=!!e.nodes,o=!1,n=!1,i=!1,a=!1;t&&(a=1===e.nodes.length&&"group"===e.nodes[0].type,e.nodes.forEach(function(e){"group"===e.type&&(o=!0),e.g&&(i=!0)}),o&&(n=1<e.nodes.length)),RED.menu.setDisabled("menu-item-group-group",!t),RED.menu.setDisabled("menu-item-group-ungroup",!o),RED.menu.setDisabled("menu-item-group-merge",!n),RED.menu.setDisabled("menu-item-group-remove",!i),RED.menu.setDisabled("menu-item-edit-copy-group-style",!a),RED.menu.setDisabled("menu-item-edit-paste-group-style",!o)}),RED.actions.add("core:group-selection",function(){var e,t;RED.view.state()===RED.state.DEFAULT&&(e=RED.view.selection()).nodes&&(e=g(e.nodes))&&(t={t:"createGroup",groups:[e],dirty:RED.nodes.dirty()},RED.history.push(t),RED.view.select({nodes:[e]}),RED.nodes.dirty(!0),RED.view.focus())}),RED.actions.add("core:ungroup-selection",function(){var e,t,o;RED.view.state()===RED.state.DEFAULT&&(e=RED.view.selection()).nodes&&(t=[],groups=e.nodes.filter(function(e){return"group"===e.type}),o={t:"ungroup",groups:[],dirty:RED.nodes.dirty()},groups.forEach(function(e){t=t.concat(h(e)),o.groups.push(e)}),RED.history.push(o),RED.view.select({nodes:t}),RED.nodes.dirty(!0),RED.view.focus())}),RED.actions.add("core:merge-selection-to-group",function(){if(RED.view.state()===RED.state.DEFAULT){var e=RED.view.selection();if(e.nodes){for(var t,o,n,i=[],a={t:"multi",events:[]},s={t:"ungroup",groups:[]},r=0;r<e.nodes.length;r++)if(t=e.nodes[r],0===r)o=t.g;else if(t.g!==o)return void RED.notify(RED._("group.errors.cannotCreateDiffGroups"),"error");for(r=0;r<e.nodes.length;r++)"group"===(t=e.nodes[r]).type?(n=n||t,s.groups.push(t),i=i.concat(h(t))):i.push(t),t.dirty=!0;0<s.groups.length&&a.events.push(s);var d=g(i);d&&(n&&(d.style=n.style,d.name=n.name),RED.view.select({nodes:[d]})),a.events.push({t:"createGroup",groups:[d],dirty:RED.nodes.dirty()}),RED.history.push(a),RED.nodes.dirty(!0),RED.view.focus()}}}),RED.actions.add("core:remove-selection-from-group",function(){if(RED.view.state()===RED.state.DEFAULT){var e=RED.view.selection();if(e.nodes){var t=RED.nodes.group(e.nodes[0].g);if(t)try{v(t,e.nodes,!0);var o={t:"removeFromGroup",dirty:RED.nodes.dirty(),group:t,nodes:e.nodes};RED.history.push(o),RED.nodes.dirty(!0)}catch(e){return void RED.notify(e,"error")}RED.view.select({nodes:e.nodes}),RED.view.focus()}}}),RED.actions.add("core:copy-group-style",function(){var e;RED.view.state()===RED.state.DEFAULT&&(e=RED.view.selection()).nodes&&1===e.nodes.length&&"group"===e.nodes[0].type&&(u=JSON.parse(JSON.stringify(e.nodes[0].style)),RED.notify(RED._("clipboard.groupStyleCopied"),{id:"clipboard"}),RED.menu.setDisabled("menu-item-edit-paste-group-style",!1))}),RED.actions.add("core:paste-group-style",function(){var e,t;RED.view.state()===RED.state.DEFAULT&&u&&(e=RED.view.selection()).nodes&&(t={t:"multi",events:[],dirty:RED.nodes.dirty()},e.nodes.forEach(function(e){"group"===e.type&&(t.events.push({t:"edit",node:e,changes:{style:JSON.parse(JSON.stringify(e.style))},dirty:RED.nodes.dirty()}),e.style=JSON.parse(JSON.stringify(u)),e.dirty=!0)}),0<t.events.length&&(RED.history.push(t),RED.nodes.dirty(!0),RED.view.redraw()))}),$('<script type="text/x-red" data-template-name="group"><div class="form-row"><label for="node-input-name" data-i18n="[append]editor:common.label.name"><i class="fa fa-tag"></i> </label><input type="text" id="node-input-name" data-i18n="[placeholder]common.label.name"></div><div class="form-row" id="node-input-row-style-stroke"><label data-i18n="editor:common.label.style"></label><label style="width: 70px;margin-right:10px" for="node-input-style-stroke" data-i18n="editor:common.label.line"></label></div><div class="form-row" style="padding-left: 100px;" id="node-input-row-style-fill"><label style="width: 70px;margin-right: 10px " for="node-input-style-fill" data-i18n="editor:common.label.fill"></label></div><div class="form-row"><label for="node-input-style-label" data-i18n="editor:common.label.label"></label><input type="checkbox" id="node-input-style-label"/></div><div class="form-row" id="node-input-row-style-label-options"><div style="margin-left: 100px; display: inline-block"><div class="form-row"><span style="display: inline-block; min-width: 140px" id="node-input-row-style-label-color"><label style="width: 70px;margin-right: 10px" for="node-input-style-fill" data-i18n="editor:common.label.color"></label></span></div><div class="form-row"><span style="display: inline-block; min-width: 140px;" id="node-input-row-style-label-position"><label style="width: 70px;margin-right: 10px " for="node-input-style-label-position" data-i18n="editor:common.label.position"></label></span></div></div></div><\/script>').appendTo("#red-ui-editor-node-configs");var e=$("<div>",{class:"red-ui-flow-group-body",style:"position: absolute; top: -1000px;"}).appendTo(document.body),t=getComputedStyle(e[0]);f={stroke:p(t.stroke),"stroke-opacity":t.strokeOpacity,fill:p(t.fill),"fill-opacity":t.fillOpacity,label:!0,"label-position":"nw"},e.remove(),e=$("<div>",{class:"red-ui-flow-group-label",style:"position: absolute; top: -1000px;"}).appendTo(document.body),t=getComputedStyle(e[0]),f.color=p(t.fill),e.remove()},createGroup:g,ungroup:h,addToGroup:m,removeFromGroup:v,getNodes:function t(e,o,n){var i=[];return e.nodes.forEach(function(e){"group"===e.type&&n||i.push(e),o&&"group"===e.type&&(i=i.concat(t(e,o,n)))}),i},contains:function e(t,o){if(o.g===t.id)return!0;for(var n=0;n<t.nodes.length;n++)if("group"===t.nodes[n].type&&e(t.nodes[n],o))return!0;return!1},markDirty:b}}(),RED.userSettings=function(){var t=700,o=!1,a=[];function e(e){a.push(e)}function s(i){var e;o||(RED.user.hasPermission("settings.write")?(o=!0,e={title:RED._("menu.label.userSettings"),buttons:[{id:"node-dialog-ok",text:RED._("common.label.close"),class:"primary",click:function(){RED.tray.close()}}],resize:function(e){t=e.width},open:function(e){var e=e.find(".red-ui-tray-body"),e=$("<div></div>").appendTo(e),t=$("<div></div>",{class:"red-ui-settings-tabs-container"}).appendTo(e),o=($("<ul></ul>",{id:"user-settings-tabs"}).appendTo(t),RED.tabs.create({id:"user-settings-tabs",vertical:!0,onchange:function(e){setTimeout(function(){n.children().hide(),$("#"+e.id).show(),e.pane.focus&&e.pane.focus()},50)}})),n=$("<div></div>",{class:"red-ui-settings-tabs-content"}).appendTo(e);a.forEach(function(e){o.addTab({id:"red-ui-settings-tab-"+e.id,label:e.title,pane:e}),e.get().hide().appendTo(n)}),e.i18n(),o.activateTab("red-ui-settings-tab-"+(i||"view")),$("#red-ui-sidebar-shade").show()},close:function(){o=!1,a.forEach(function(e){e.close&&e.close()}),$("#red-ui-sidebar-shade").hide()},show:function(){}},null!==t&&(e.width=t),RED.tray.show(e)):RED.notify(RED._("user.errors.settings"),"error"))}function n(e){var t=RED._("languages."+e);return{text:t||e,val:e}}function i(e,t){return e.text.localeCompare(t.text)}var r=[{options:[{setting:"editor-language",local:!0,label:"menu.label.view.language",options:function(e){e([{val:"",text:RED._("menu.label.view.browserDefault")}].concat(RED.settings.theme("languages").map(n).sort(i)))}}]},{title:"menu.label.view.view",options:[{setting:"view-store-zoom",label:"menu.label.view.storeZoom",default:!1,toggle:!0,onchange:function(e){e||RED.settings.removeLocal("zoom-level")}},{setting:"view-store-position",label:"menu.label.view.storePosition",default:!1,toggle:!0,onchange:function(e){e||RED.settings.removeLocal("scroll-positions")}}]},{title:"menu.label.view.grid",options:[{setting:"view-show-grid",oldSetting:"menu-menu-item-view-show-grid",label:"menu.label.view.showGrid",default:!0,toggle:!0,onchange:"core:toggle-show-grid"},{setting:"view-snap-grid",oldSetting:"menu-menu-item-view-snap-grid",label:"menu.label.view.snapGrid",default:!0,toggle:!0,onchange:"core:toggle-snap-grid"},{setting:"view-grid-size",label:"menu.label.view.gridSize",type:"number",default:20,onchange:RED.view.gridSize}]},{title:"menu.label.nodes",options:[{setting:"view-node-status",oldSetting:"menu-menu-item-status",label:"menu.label.displayStatus",default:!0,toggle:!0,onchange:"core:toggle-status"},{setting:"view-node-show-label",label:"menu.label.showNodeLabelDefault",default:!0,toggle:!0}]},{title:"menu.label.other",options:[{setting:"view-show-tips",oldSettings:"menu-menu-item-show-tips",label:"menu.label.showTips",toggle:!0,default:!0,onchange:"core:toggle-show-tips"},{setting:"view-show-welcome-tours",label:"menu.label.showWelcomeTours",toggle:!0,default:!0}]}],d={};function l(){var i=$('<div id="red-ui-settings-tab-view" class="red-ui-help"></div>'),a=RED.settings.get("editor")||{};return a.view=a.view||{},r.forEach(function(e){e.title&&$("<h3></h3>").text(RED._(e.title)).appendTo(i),e.options.forEach(function(e){var n,t=e.local?localStorage.getItem(e.setting):a.view[e.setting],o=$('<div class="red-ui-settings-row"></div>').appendTo(i);e.toggle?$('<label for="user-settings-'+e.setting+'"><input id="user-settings-'+e.setting+'" type="checkbox"> '+RED._(e.label)+"</label>").appendTo(o).find("input").prop("checked",t):e.options?($('<label for="user-settings-'+e.setting+'">'+RED._(e.label)+"</label>").appendTo(o),n=$('<select id="user-settings-'+e.setting+'"></select>').appendTo(o),"function"==typeof e.options&&(e.options(function(e){e.forEach(function(e){var t=e,o=e;"string"!=typeof e&&(t=e.val,o=e.text),$("<option>").val(t).text(o).appendTo(n)})}),n.val(t))):($('<label for="user-settings-'+e.setting+'">'+RED._(e.label)+"</label>").appendTo(o),$('<input id="user-settings-'+e.setting+'" type="'+(e.type||"text")+'">').appendTo(o).val(t))})}),i}function c(e,t){var o,e=d[e];e.local?localStorage.setItem(e.setting,t):((o=RED.settings.get("editor")||{}).view=o.view||{},o.view[e.setting]=t,RED.settings.set("editor",o),(o="string"==typeof(o=e.onchange)?RED.actions.get(o):o)&&o.call(e,t))}return{init:function(){RED.actions.add("core:show-user-settings",s),RED.actions.add("core:show-help",function(){s("keyboard")}),e({id:"view",title:RED._("menu.label.view.view"),get:l,close:function(){r.forEach(function(e){e.options.forEach(function(e){var t=$("#user-settings-"+e.setting);e.toggle?c(e.setting,t.prop("checked")):c(e.setting,t.val())})})}});var n=RED.settings.get("editor")||{},i=(n.view=n.view||{},!1);r.forEach(function(e){e.options.forEach(function(e){var t,o;e.local?d[e.setting]=e:(e.oldSetting&&null!=(t=RED.settings.get(e.oldSetting))&&(n.view[e.setting]=t,i=!0,RED.settings.remove(e.oldSetting)),d[e.setting]=e,null==(t=n.view[e.setting])&&e.hasOwnProperty("default")&&(t=e.default,n.view[e.setting]=t,i=!0),e.onchange&&(o="string"==typeof(o=e.onchange)?RED.actions.get(o):o)&&o.call(e,t))})}),i&&RED.settings.set("editor",n)},toggle:function(e){var t=d[e],o=RED.settings.get("editor")||{};o.view=o.view||{},c(e,!o.view[t.setting])},show:s,add:e}}(),RED.projects=function(){var T,i,U;function p(e){var t="git_missing_user"===e.code?RED.notify("<p>"+RED._("projects.errors.no-username-email")+"</p>",{fixed:!0,type:"error",buttons:[{text:RED._("common.label.cancel"),click:function(){t.close()}},{text:RED._("projects.config-git"),click:function(){RED.userSettings.show("gitconfig"),t.close()}}]}):(console.log(e),RED.notify("<p>"+RED._("projects.errors.unexpected")+":</p><p>"+e.message+"</p><small>"+RED._("projects.errors.code")+": "+e.code+"</small>",{fixed:!0,modal:!0,type:"error",buttons:[{text:RED._("common.label.close"),click:function(){t.close()}}]}))}var a={};function t(){var L,S,O,I,N,P,A,M,z,B,G,F,d,s,r,b,y,w,E,D,R,x,_,f,h,l,c,k=$('<div class="red-ui-projects-dialog-screen-start-hero"></div>'),g=($('<span><i class="fa fa-files-o fa-2x"></i> &nbsp; &nbsp; <i class="fa fa-long-arrow-right fa-2x"></i> &nbsp; &nbsp; <i class="fa fa-archive fa-2x"></i></span>').appendTo(k),$("<hr>").appendTo(k),{});a={welcome:{content:function(e){var t=$('<div class="red-ui-projects-dialog-screen-start"></div>'),o=(k.appendTo(t),$('<div class="red-ui-projects-dialog-screen-start-body"></div>').appendTo(t)),o=($("<p>").text(RED._("projects.welcome.hello")).appendTo(o),$("<p>").text(RED._("projects.welcome.desc0")).appendTo(o),$("<p>").text(RED._("projects.welcome.desc1")).appendTo(o),$("<p>").text(RED._("projects.welcome.desc2")).appendTo(o),$('<div style="text-align: center"></div>').appendTo(o)),n=$('<button data-type="empty" class="red-ui-button red-ui-projects-dialog-button red-ui-projects-dialog-screen-create-type"><i class="fa fa-archive fa-2x"></i><i style="position: absolute;" class="fa fa-asterisk"></i><br/>'+RED._("projects.welcome.create")+"</button>").appendTo(o),o=$('<button data-type="clone" class="red-ui-button red-ui-projects-dialog-button red-ui-projects-dialog-screen-create-type"><i class="fa fa-archive fa-2x"></i><i style="position: absolute;" class="fa fa-git"></i><br/>'+RED._("projects.welcome.clone")+"</button>").appendTo(o);return n.on("click",function(e){e.preventDefault(),g={action:"create"},u("git-config")}),o.on("click",function(e){e.preventDefault(),g={action:"clone"},u("git-config")}),t},buttons:[{text:RED._("projects.welcome.openExistingProject"),class:"secondary",click:function(){g={action:"open"},u("git-config")}},{text:RED._("projects.welcome.not-right-now"),click:function(){g={},$(this).dialog("close")}}]},"git-config":{content:function(e){function t(){var e=l.val().trim(),t=c.val().trim(),e=0<e.length&&0<t.length;$("#red-ui-projects-dialog-git-config").prop("disabled",!e).toggleClass("disabled ui-button-disabled ui-state-disabled",!e)}var o=!1,n=RED.settings.get("git"),i=(n&&n.user?n=n.user:RED.settings.git&&RED.settings.git.globalUser&&(o=!0,n=RED.settings.git.globalUser),$('<div class="red-ui-projects-dialog-screen-start"></div>')),a=(k.appendTo(i),$('<div class="red-ui-projects-dialog-screen-start-body"></div>').appendTo(i)),o=($("<p>").text(RED._("projects.git-config.setup")).appendTo(a),$("<p>").text(RED._("projects.git-config.desc0")).appendTo(a),$("<p>").text(RED._("projects.git-config.desc1")).appendTo(a),o&&$("<p>").text(RED._("projects.git-config.desc2")).appendTo(a),$("<p>").text(RED._("projects.git-config.desc3")).appendTo(a),$('<div class="form-row"></div>').appendTo(a));return $('<label for="">'+RED._("projects.git-config.username")+"</label>").appendTo(o),(l=$('<input type="text">').val(n&&n.name||"").appendTo(o)).on("change keyup paste",t),o=$('<div class="form-row"></div>').appendTo(a),$('<label for="">'+RED._("projects.git-config.email")+"</label>").appendTo(o),(c=$('<input type="text">').val(n&&n.email||"").appendTo(o)).on("change keyup paste",t),setTimeout(function(){l.trigger("focus"),t()},50),i},buttons:[{text:RED._("common.label.back"),click:function(){u("welcome")}},{id:"red-ui-projects-dialog-git-config",text:RED._("common.label.next"),class:"primary",click:function(){var e=RED.settings.get("git")||{};e.user=e.user||{},e.user.name=l.val(),e.user.email=c.val(),RED.settings.set("git",e),"create"===g.action?u("project-details"):"clone"===g.action?u("clone-project"):"open"===g.action&&u("create",{screen:"open"})}}]},"project-details":{content:function(e){var o,t,n=null,i=!1,a=($.getJSON("projects",function(e){n={},e.projects.forEach(function(e){n[e]=!0,i&&(i=!1,r())})}),$('<div class="red-ui-projects-dialog-screen-start"></div>')),s=(k.appendTo(a),$('<div class="red-ui-projects-dialog-screen-start-body"></div>').appendTo(a)),r=($("<p>").text(RED._("projects.project-details.create")).appendTo(s),$("<p>").text(RED._("projects.project-details.desc0")).appendTo(s),$("<p>").text(RED._("projects.project-details.desc1")).appendTo(s),$("<p>").text(RED._("projects.project-details.desc2")).appendTo(s),function(){var e=f.val(),t=!0;if(u){if(null===n)return void(i=!0);c.empty(),!/^[a-zA-Z0-9\-_]+$/.test(e)||n[e]?(f.addClass("input-error"),$('<i style="margin-top: 8px;" class="fa fa-exclamation-triangle"></i>').appendTo(c),t=o=!1,n[e]?projectNameSublabel.text(RED._("projects.project-details.already-exists")):projectNameSublabel.text(RED._("projects.project-details.must-contain"))):(f.removeClass("input-error"),$('<i style="margin-top: 8px;" class="fa fa-check"></i>').appendTo(c),projectNameSublabel.text(RED._("projects.project-details.must-contain")),o=!0),p=e}t=o,$("#red-ui-projects-dialog-create-name").prop("disabled",!t).toggleClass("disabled ui-button-disabled ui-state-disabled",!t)}),d=$('<div class="form-row"></div>').appendTo(s),l=($('<label for="red-ui-projects-dialog-screen-create-project-name">'+RED._("projects.project-details.project-name")+"</label>").appendTo(d),$('<div style="position:relative;"></div>').appendTo(d)),c=(f=$('<input id="red-ui-projects-dialog-screen-create-project-name" type="text"></input>').val(g.name||"").appendTo(l),$('<div class="red-ui-projects-dialog-screen-input-status"></div>').appendTo(l)),u=!1,p="";return f.on("change keyup paste",function(){if(u=f.val()!==p,t)clearTimeout(t);else if(u&&(c.empty(),$('<img src="red/images/spin.svg"/>').appendTo(c),""===f.val()))return void r();t=setTimeout(function(){r(),t=null},300)}),projectNameSublabel=$('<label class="red-ui-projects-edit-form-sublabel"><small>'+RED._("projects.project-details.must-contain")+"</small></label>").appendTo(d).find("small"),d=$('<div class="form-row red-ui-projects-dialog-screen-create-row red-ui-projects-dialog-screen-create-row-empty"></div>').appendTo(s),$('<label for="red-ui-projects-dialog-screen-create-project-desc">'+RED._("projects.project-details.desc")+"</label>").appendTo(d),h=$('<input id="red-ui-projects-dialog-screen-create-project-desc" type="text">').val(g.summary||"").appendTo(d),$('<label class="red-ui-projects-edit-form-sublabel"><small>'+RED._("projects.project-details.opt")+"</small></label>").appendTo(d),setTimeout(function(){f.trigger("focus"),f.trigger("change")},50),a},buttons:function(e){return[{text:RED._("common.label.back"),click:function(){u("git-config")}},{id:"red-ui-projects-dialog-create-name",disabled:!0,text:RED._("common.label.next"),class:"primary disabled",click:function(){g.name=f.val(),g.summary=h.val(),u("default-files",e)}}]}},"clone-project":{content:function(e){var n,t,o=$('<div class="red-ui-projects-dialog-screen-start"></div>'),i=(k.appendTo(o),$('<div class="red-ui-projects-dialog-screen-start-body"></div>').appendTo(o)),a=($("<p>").text(RED._("projects.clone-project.clone")).appendTo(i),$("<p>").text(RED._("projects.clone-project.desc0")).appendTo(i),null),s=!1,r=($.getJSON("projects",function(e){a={},e.projects.forEach(function(e){a[e]=!0,s&&(s=!1,r())})}),function(){var e=b.val(),t=!0;if(u){if(null===a)return void(s=!0);c.empty(),!/^[a-zA-Z0-9\-_]+$/.test(e)||a[e]?(b.addClass("input-error"),$('<i style="margin-top: 8px;" class="fa fa-exclamation-triangle"></i>').appendTo(c),t=n=!1,a[e]?R.text(RED._("projects.clone-project.already-exists")):R.text(RED._("projects.clone-project.must-contain"))):(b.removeClass("input-error"),$('<i style="margin-top: 8px;" class="fa fa-check"></i>').appendTo(c),R.text(RED._("projects.clone-project.must-contain")),n=!0),p=e}var t=n,e=w.val(),o=0<e.length&&!/\s/.test(e);/^https?:\/\/[^/]+@/i.test(e)&&($("#red-ui-projects-dialog-screen-create-project-repo-label small").text(RED._("projects.clone-project.no-info-in-url")),o=!1),o?w.removeClass("input-error"):(h&&w.addClass("input-error"),t=!1),/^https?:\/\//.test(e)?($(".red-ui-projects-dialog-screen-create-row-creds").show(),$(".red-ui-projects-dialog-screen-create-row-sshkey").hide()):/^(?:ssh|[\S]+?@[\S]+?):(?:\/\/)?/.test(e)?($(".red-ui-projects-dialog-screen-create-row-creds").hide(),$(".red-ui-projects-dialog-screen-create-row-sshkey").show()):($(".red-ui-projects-dialog-screen-create-row-creds").hide(),$(".red-ui-projects-dialog-screen-create-row-sshkey").hide()),$("#red-ui-projects-dialog-clone-project").prop("disabled",!t).toggleClass("disabled ui-button-disabled ui-state-disabled",!t)}),d=$('<div class="form-row red-ui-projects-dialog-screen-create-row red-ui-projects-dialog-screen-create-row-empty red-ui-projects-dialog-screen-create-row-clone"></div>').appendTo(i),l=($('<label for="red-ui-projects-dialog-screen-create-project-name">'+RED._("projects.clone-project.project-name")+"</label>").appendTo(d),$('<div style="position:relative;"></div>').appendTo(d)),c=(b=$('<input id="red-ui-projects-dialog-screen-create-project-name" type="text"></input>').appendTo(l),$('<div class="red-ui-projects-dialog-screen-input-status"></div>').appendTo(l)),u=!1,p="",f="",h=(b.on("change keyup paste",function(){if(u=b.val()!==p,t)clearTimeout(t);else if(u&&(c.empty(),$('<img src="red/images/spin.svg"/>').appendTo(c),""===b.val()))return void r();t=setTimeout(function(){r(),t=null},300)}),R=$('<label class="red-ui-projects-edit-form-sublabel"><small>'+RED._("projects.clone-project.must-contain")+"</small></label>").appendTo(d).find("small"),d=$('<div class="form-row red-ui-projects-dialog-screen-create-row red-ui-projects-dialog-screen-create-row-clone"></div>').appendTo(i),$('<label for="red-ui-projects-dialog-screen-create-project-repo">'+RED._("projects.clone-project.git-url")+"</label>").appendTo(d),w=$('<input id="red-ui-projects-dialog-screen-create-project-repo" type="text" placeholder="https://git.example.com/path/my-project.git"></input>').appendTo(d),$('<label id="red-ui-projects-dialog-screen-create-project-repo-label" class="red-ui-projects-edit-form-sublabel"><small>'+RED._("projects.clone-project.protocols")+"</small></label>").appendTo(d),!1),g="",m=(w.on("change keyup paste",function(){h=!0;var e,t=$(this).val(),t=(g!==t&&$("#red-ui-projects-dialog-screen-create-project-repo-label small").text(RED._("projects.clone-project.protocols")),g=t,/\/([^/]+?)(?:\.git)?$/.exec(t));!t||""!==(e=b.val())&&e!==f||(f=t[1],b.val(f),b.trigger("change")),r()}),$('<div class="red-ui-projects-dialog-screen-create-row"></div>').appendTo(i)),l=(d=$('<div class="form-row red-ui-projects-dialog-screen-create-row-auth-error"></div>').hide().appendTo(m),$('<div><i class="fa fa-warning"></i> '+RED._("projects.clone-project.auth-failed")+"</div>").appendTo(d),d=$('<div class="hide form-row red-ui-projects-dialog-screen-create-row-creds"></div>').hide().appendTo(m),$('<div style="width: calc(50% - 10px); display:inline-block;"></div>').appendTo(d)),v=($('<label for="red-ui-projects-dialog-screen-create-project-repo-user">'+RED._("projects.clone-project.username")+"</label>").appendTo(l),E=$('<input id="red-ui-projects-dialog-screen-create-project-repo-user" type="text"></input>').appendTo(l),l=$('<div style="width: calc(50% - 10px); margin-left: 20px; display:inline-block;"></div>').appendTo(d),$('<label for="red-ui-projects-dialog-screen-create-project-repo-pass">'+RED._("projects.clone-project.passwd")+"</label>").appendTo(l),(D=$('<input style="width:100%" id="red-ui-projects-dialog-screen-create-project-repo-pass" type="password"></input>').appendTo(l)).typedInput({type:"cred"}),d=$('<div class="form-row red-ui-projects-dialog-screen-create-row red-ui-projects-dialog-screen-create-row-sshkey"></div>').hide().appendTo(m),l=$('<div style="width: calc(50% - 10px); display:inline-block;"></div>').appendTo(d),$('<label for="red-ui-projects-dialog-screen-create-project-repo-passphrase">'+RED._("projects.clone-project.ssh-key")+"</label>").appendTo(l),x=$("<select>",{style:"width: 100%"}).appendTo(l),$.getJSON("settings/user/keys",function(e){var t=0;e.keys.forEach(function(e){x.append($("<option></option>").val(e.name).text(e.name)),t++}),0===t?(x.addClass("input-error"),x.attr("disabled",!0),v.show()):(x.removeClass("input-error"),x.attr("disabled",!1),v.hide())}),l=$('<div style="width: calc(50% - 10px); margin-left: 20px; display:inline-block;"></div>').appendTo(d),$('<label for="red-ui-projects-dialog-screen-create-project-repo-passphrase">'+RED._("projects.clone-project.passphrase")+"</label>").appendTo(l),(_=$('<input id="red-ui-projects-dialog-screen-create-project-repo-passphrase" type="password"></input>').appendTo(l)).typedInput({type:"cred"}),l=$('<div class="form-row red-ui-projects-dialog-screen-create-row red-ui-projects-dialog-screen-create-row-sshkey"></div>').appendTo(m),$('<div class="red-ui-projects-dialog-screen-create-row-auth-error-no-keys"></div>').hide().appendTo(l));return $('<div class="form-row"><i class="fa fa-warning"></i> '+RED._("projects.clone-project.ssh-key-desc")+"</div>").appendTo(v),l=$('<div style="text-align: center">').appendTo(v),$('<button class="red-ui-button red-ui-projects-dialog-button">'+RED._("projects.clone-project.ssh-key-add")+"</button>").appendTo(l).on("click",function(e){e.preventDefault(),T.dialog("close"),RED.userSettings.show("gitconfig"),setTimeout(function(){$("#user-settings-gitconfig-add-key").trigger("click")},500)}),d=$('<div class="form-row red-ui-projects-dialog-screen-create-row red-ui-projects-dialog-screen-create-row-clone"></div>').appendTo(i),$("<label>"+RED._("projects.clone-project.credential-key")+"</label>").appendTo(d),(y=$('<input style="width: 100%" type="password"></input>').appendTo(d)).typedInput({type:"cred"}),o},buttons:function(e){return[{text:RED._("common.label.back"),click:function(){u("git-config")}},{id:"red-ui-projects-dialog-clone-project",disabled:!0,text:RED._("common.label.clone"),class:"primary disabled",click:function(){$(".red-ui-projects-dialog-screen-create-type.selected").data("type");var e={name:b.val()},t=(e.credentialSecret=y.val(),w.val());if(/^(?:ssh|[\d\w\.\-_]+@[\w\.]+):(?:\/\/)?/.test(t)){var o=x.val();if(!o)return void console.log(RED._("projects.clone-project.cant-get-ssh-key"));e.git={remotes:{origin:{url:t,keyFile:o,passphrase:_.val()}}}}else e.git={remotes:{origin:{url:t,username:E.val(),password:D.val()}}};$(".red-ui-projects-dialog-screen-create-row-auth-error").hide(),$("#red-ui-projects-dialog-screen-create-project-repo-label small").text(RED._("projects.clone-project.protocols")),E.removeClass("input-error"),D.removeClass("input-error"),x.removeClass("input-error"),_.removeClass("input-error"),RED.deploy.setDeployInflight(!0),RED.projects.settings.switchProject(e.name),V({url:"projects",type:"POST",handleAuthFail:!1,responses:{200:function(e){T.dialog("close")},400:{project_exists:function(e){console.log(RED._("projects.clone-project.already-exists2"))},git_error:function(e){console.log(RED._("projects.clone-project.git-error"),e)},git_connection_failed:function(e){w.addClass("input-error"),$("#red-ui-projects-dialog-screen-create-project-repo-label small").text(RED._("projects.clone-project.connection-failed"))},git_not_a_repository:function(e){w.addClass("input-error"),$("#red-ui-projects-dialog-screen-create-project-repo-label small").text(RED._("projects.clone-project.not-git-repo"))},git_repository_not_found:function(e){w.addClass("input-error"),$("#red-ui-projects-dialog-screen-create-project-repo-label small").text(RED._("projects.clone-project.repo-not-found"))},git_auth_failed:function(e){$(".red-ui-projects-dialog-screen-create-row-auth-error").show(),E.addClass("input-error"),D.addClass("input-error"),x.addClass("input-error"),_.addClass("input-error")},missing_flow_file:function(e){T.dialog("close")},missing_package_file:function(e){T.dialog("close")},project_empty:function(e){T.dialog("close")},credentials_load_failed:function(e){T.dialog("close")},"*":function(e){p(e),$(T).dialog("close")}}}},e).then(function(){RED.menu.setDisabled("menu-item-projects-open",!1),RED.menu.setDisabled("menu-item-projects-settings",!1),RED.events.emit("project:change",{name:name})}).always(function(){setTimeout(function(){RED.deploy.setDeployInflight(!1)},500)})}}]}},"default-files":{content:function(e){function t(){var e=!0,t=s.val();""!==t&&/\.json$/.test(t)?(s.hasClass("input-error")&&(s.removeClass("input-error"),s.next().empty()),r.hasClass("input-error")&&(r.removeClass("input-error"),r.next().empty()),r.text(t.substring(0,t.length-5)+"_cred.json")):(e=!1,s.hasClass("input-error")||(s.addClass("input-error"),s.next().empty().append('<i style="margin-top: 8px;" class="fa fa-exclamation-triangle"></i>')),r.text(""),r.hasClass("input-error")||(r.addClass("input-error"),r.next().empty().append('<i style="margin-top: 8px;" class="fa fa-exclamation-triangle"></i>'))),$("#red-ui-projects-dialog-create-default-files").prop("disabled",!e).toggleClass("disabled ui-button-disabled ui-state-disabled",!e)}var o=$('<div class="red-ui-projects-dialog-screen-start"></div>'),n=(k.appendTo(o),$('<div class="red-ui-projects-dialog-screen-start-body"></div>').appendTo(o)),e=($("<p>").text(RED._("projects.default-files.create")).appendTo(n),$("<p>").text(RED._("projects.default-files.desc0")).appendTo(n),$("<p>").text(RED._("projects.default-files.desc1")).appendTo(n),!e.existingProject&&RED.settings.files&&$("<p>").text(RED._("projects.default-files.desc2")).appendTo(n),$('<div class="form-row"></div>').appendTo(n)),i=($('<label for="red-ui-projects-dialog-screen-create-project-file">'+RED._("projects.default-files.flow-file")+"</label>").appendTo(e),$('<div style="position:relative;"></div>').appendTo(e)),a=g.files&&g.files.flow||RED.settings.files&&RED.settings.files.flow||"flow.json",a=(s=$('<input id="red-ui-projects-dialog-screen-create-project-file" type="text">').val(a).on("change keyup paste",t).appendTo(i),$('<div class="red-ui-projects-dialog-screen-input-status"></div>').appendTo(i),$('<label class="red-ui-projects-edit-form-sublabel"><small>*.json</small></label>').appendTo(e),g.files&&g.files.credentials||RED.settings.files&&RED.settings.files.credentials||"flow_cred.json"),e=$('<div class="form-row"></div>').appendTo(n);return $('<label for="red-ui-projects-dialog-screen-create-project-credfile">'+RED._("projects.default-files.credentials-file")+"</label>").appendTo(e),i=$('<div style="position:relative;"></div>').appendTo(e),r=$('<div style="width: 100%" class="uneditable-input" id="red-ui-projects-dialog-screen-create-project-credentials">').text(a).appendTo(i),$('<div class="red-ui-projects-dialog-screen-input-status"></div>').appendTo(i),setTimeout(function(){s.trigger("focus"),t()},50),o},buttons:function(e){return[{text:RED._(e.existingProject?"common.label.cancel":"common.label.back"),click:function(){e.existingProject?$(this).dialog("close"):u("project-details",e)}},{id:"red-ui-projects-dialog-create-default-files",text:RED._("common.label.next"),class:"primary",click:function(){g.files={flow:s.val(),credentials:r.text()},e.existingProject||(g.migrateFiles=!0),u("encryption-config",e)}}]}},"encryption-config":{content:function(e){function n(){var e=!0;"enabled"===$("input[name=projects-encryption-type]:checked").val()&&"custom"===$("input[name=projects-encryption-key]:checked").val()&&(e=e&&""!==d.val()),$("#red-ui-projects-dialog-create-encryption").prop("disabled",!e).toggleClass("disabled ui-button-disabled ui-state-disabled",!e)}var t=$('<div class="red-ui-projects-dialog-screen-start"></div>'),o=(k.appendTo(t),$('<div class="red-ui-projects-dialog-screen-start-body"></div>').appendTo(t)),e=($("<p>").text(RED._("projects.encryption-config.setup")).appendTo(o),e.existingProject?($("<p>").text(RED._("projects.encryption-config.desc0")).appendTo(o),$("<p>").text(RED._("projects.encryption-config.desc1")).appendTo(o)):"disabled"===RED.settings.flowEncryptionType?($("<p>").text(RED._("projects.encryption-config.desc2")).appendTo(o),$("<p>").text(RED._("projects.encryption-config.desc3")).appendTo(o),$("<p>").text(RED._("projects.encryption-config.desc4")).appendTo(o)):("user"===RED.settings.flowEncryptionType?$("<p>").text(RED._("projects.encryption-config.desc5")).appendTo(o):"system"===RED.settings.flowEncryptionType&&$("<p>").text(RED._("projects.encryption-config.desc6")).appendTo(o),$("<p>").text(RED._("projects.encryption-config.desc7")).appendTo(o)),$('<div class="form-row red-ui-projects-dialog-screen-create-row red-ui-projects-dialog-screen-create-row-empty"></div>').appendTo(o)),o=($("<label>"+RED._("projects.encryption-config.credentials")+"</label>").appendTo(e),$('<div class="red-ui-projects-dialog-credentials-box">').appendTo(e)),i=$('<div class="red-ui-projects-dialog-credentials-box-right">').appendTo(o),a=$('<div class="red-ui-projects-dialog-credentials-box-left">').appendTo(o),s=$('<div class="form-row red-ui-projects-dialog-credentials-box-enabled"></div>').appendTo(a),r=($('<label class="red-ui-projects-edit-form-inline-label"><input type="radio" name="projects-encryption-type" value="enabled"> <i class="fa fa-lock"></i> <span>'+RED._("projects.encryption-config.enable")+"</span></label>").appendTo(s),$('<div class="form-row red-ui-projects-dialog-credentials-box-disabled"></div>').appendTo(a));return $('<label class="red-ui-projects-edit-form-inline-label"><input type="radio" name="projects-encryption-type" value="disabled"> <i class="fa fa-unlock"></i> <span>'+RED._("projects.encryption-config.disable")+"</span></label>").appendTo(r),a.find("input[name=projects-encryption-type]").on("click",function(e){var t,o;"enabled"===$(this).val()?(t=s,o=r,$(".projects-encryption-enabled-row").show(),$(".projects-encryption-disabled-row").hide(),"custom"===$("input[name=projects-encryption-key]:checked").val()&&d.trigger("focus")):(o=s,t=r,$(".projects-encryption-enabled-row").hide(),$(".projects-encryption-disabled-row").show()),t.removeClass("disabled"),o.addClass("disabled"),n()}),e=$('<div class="form-row projects-encryption-enabled-row"></div>').appendTo(i),$('<label class="red-ui-projects-edit-form-inline-label '+("user"!==RED.settings.flowEncryptionType?"disabled":"")+'" style="margin-left: 5px"><input '+("user"!==RED.settings.flowEncryptionType?RED._("projects.encryption-config.disabled"):"")+' type="radio" style="vertical-align: middle; margin-top:0; margin-right: 10px;" value="default" name="projects-encryption-key"> <span style="vertical-align: middle;">'+RED._("projects.encryption-config.copy")+"</span></label>").appendTo(e),e=$('<div class="form-row projects-encryption-enabled-row"></div>').appendTo(i),$('<label class="red-ui-projects-edit-form-inline-label" style="margin-left: 5px"><input type="radio" style="vertical-align: middle; margin-top:0; margin-right: 10px;" value="custom" name="projects-encryption-key"> <span style="vertical-align: middle;">'+RED._("projects.encryption-config.use-custom")+"</span></label>").appendTo(e),e=$('<div class="projects-encryption-enabled-row"></div>').appendTo(i),(d=$('<input disabled type="password" style="margin-left: 25px; width: calc(100% - 30px);"></input>').appendTo(e)).typedInput({type:"cred"}),d.on("change keyup paste",n),e=$('<div class="form-row projects-encryption-disabled-row"></div>').hide().appendTo(i),$('<div class="" style="padding: 5px 20px;"><i class="fa fa-warning"></i> '+RED._("projects.encryption-config.desc8")+"</div>").appendTo(e),i.find("input[name=projects-encryption-key]").on("click",function(){var e=$(this).val();d.attr("disabled","default"===e),"custom"===e&&d.trigger("focus"),n()}),setTimeout(function(){a.find("input[name=projects-encryption-type][value=enabled]").trigger("click"),("user"!==RED.settings.flowEncryptionType?i.find("input[name=projects-encryption-key][value=custom]"):i.find("input[name=projects-encryption-key][value=default]")).trigger("click"),n()},100),t},buttons:function(n){return[{text:RED._("common.label.back"),click:function(){u("default-files",n)}},{id:"red-ui-projects-dialog-create-encryption",text:RED._(n.existingProject?"projects.encryption-config.create-project-files":"projects.encryption-config.create-project"),class:"primary disabled",disabled:!0,click:function(){"enabled"===$("input[name=projects-encryption-type]:checked").val()?"custom"===$("input[name=projects-encryption-key]:checked").val()&&(g.credentialSecret=d.val()):g.credentialSecret=!1,RED.deploy.setDeployInflight(!0),RED.projects.settings.switchProject(g.name);var e="POST",t="projects",o=(n.existingProject&&(g.initialise=!0,e="PUT",t="projects/"+U.name),this);V({url:t,type:e,requireCleanWorkspace:!0,handleAuthFail:!1,responses:{200:function(e){g={},n.existingProject?$(o).dialog("close"):(u("create-success"),RED.menu.setDisabled("menu-item-projects-open",!1),RED.menu.setDisabled("menu-item-projects-settings",!1))},400:{project_exists:function(e){console.log(RED._("projects.encryption-config.already-exists"))},git_error:function(e){console.log(RED._("projects.encryption-config.git-error"),e)},git_connection_failed:function(e){projectRepoInput.addClass("input-error")},git_auth_failed:function(e){projectRepoUserInput.addClass("input-error"),projectRepoPasswordInput.addClass("input-error"),console.log(RED._("projects.encryption-config.git-auth-error"),e)},"*":function(e){p(e),$(T).dialog("close")}}}},g).always(function(){setTimeout(function(){RED.deploy.setDeployInflight(!1)},500)})}}]}},"create-success":{content:function(e){var t=$('<div class="red-ui-projects-dialog-screen-start"></div>'),o=(k.appendTo(t),$('<div class="red-ui-projects-dialog-screen-start-body"></div>').appendTo(t));return $("<p>").text(RED._("projects.create-success.success")).appendTo(o),$("<p>").text(RED._("projects.create-success.desc0")).appendTo(o),$("<p>").text(RED._("projects.create-success.desc1")).appendTo(o),$("<p>").text(RED._("projects.create-success.desc2")).appendTo(o),t},buttons:[{text:RED._("common.label.done"),click:function(){$(this).dialog("close")}}]},create:{title:RED._("projects.create.projects"),content:function(e){var s,n,t,r,d,i,l,a,o,c=null,u=(F=null,!1),p=($.getJSON("projects",function(e){c={},e.projects.forEach(function(e){c[e]=!0,u&&(u=!1,f())})}),$('<div class="red-ui-projects-dialog-screen-create"></div>')),f=function(){var e=L.val(),t=!0;if(w){if(null===c)return void(u=!0);y.empty(),!/^[a-zA-Z0-9\-_]+$/.test(e)||c[e]?(L.addClass("input-error"),$('<i style="margin-top: 8px;" class="fa fa-exclamation-triangle"></i>').appendTo(y),t=a=!1,c[e]?z.text(RED._("projects.create.already-exists")):z.text(RED._("projects.create.must-contain"))):(L.removeClass("input-error"),$('<i style="margin-top: 8px;" class="fa fa-check"></i>').appendTo(y),z.text(RED._("projects.create.must-contain")),a=!0),E=e}var o,n,t=a,e=$(".red-ui-projects-dialog-screen-create-type.selected").data("type");"copy"===e?t=!1:"clone"===e?(n=0<(o=N.val()).length&&!/\s/.test(o),/^https?:\/\/[^/]+@/i.test(o)&&($("#red-ui-projects-dialog-screen-create-project-repo-label small").text(RED._("projects.create.no-info-in-url")),n=!1),n?N.removeClass("input-error"):(T&&N.addClass("input-error"),t=!1),/^https?:\/\//.test(o)?($(".red-ui-projects-dialog-screen-create-row-creds").show(),$(".red-ui-projects-dialog-screen-create-row-sshkey").hide()):/^(?:ssh|[\S]+?@[\S]+?):(?:\/\/)?/.test(o)?($(".red-ui-projects-dialog-screen-create-row-creds").hide(),$(".red-ui-projects-dialog-screen-create-row-sshkey").show()):($(".red-ui-projects-dialog-screen-create-row-creds").hide(),$(".red-ui-projects-dialog-screen-create-row-sshkey").hide())):"empty"===e?(""!==(n=O.val())&&/\.json$/.test(n)?O.hasClass("input-error")&&(O.removeClass("input-error"),O.next().empty()):(t=!1,O.hasClass("input-error")||(O.addClass("input-error"),O.next().empty().append('<i style="margin-top: 8px;" class="fa fa-exclamation-triangle"></i>'))),"enabled"===$("input[name=projects-encryption-type]:checked").val()&&"custom"===$("input[name=projects-encryption-key]:checked").val()&&(t=t&&""!==P.val())):"open"===e&&(t=!!F),$("#red-ui-projects-dialog-create").prop("disabled",!t).toggleClass("disabled ui-button-disabled ui-state-disabled",!t)},h=$('<div class="form-row button-group"></div>').appendTo(p),g=$('<button data-type="open" class="red-ui-button red-ui-projects-dialog-button red-ui-projects-dialog-screen-create-type toggle"><i class="fa fa-archive fa-2x"></i><i style="position: absolute;" class="fa fa-folder-open"></i><br/>'+RED._("projects.create.open")+"</button>").appendTo(h),m=$('<button data-type="empty" class="red-ui-button red-ui-projects-dialog-button red-ui-projects-dialog-screen-create-type toggle"><i class="fa fa-archive fa-2x"></i><i style="position: absolute;" class="fa fa-asterisk"></i><br/>'+RED._("projects.create.create")+"</button>").appendTo(h),v=$('<button data-type="clone" class="red-ui-button red-ui-projects-dialog-button red-ui-projects-dialog-screen-create-type toggle"><i class="fa fa-archive fa-2x"></i><i style="position: absolute;" class="fa fa-git"></i><br/>'+RED._("projects.create.clone")+"</button>").appendTo(h),b=(h.find(".red-ui-projects-dialog-screen-create-type").on("click",function(e){switch(e.preventDefault(),p.find(".red-ui-projects-dialog-screen-create-type").removeClass("selected"),$(this).addClass("selected"),p.find(".red-ui-projects-dialog-screen-create-row").hide(),p.find(".red-ui-projects-dialog-screen-create-row-"+$(this).data("type")).show(),f(),L.trigger("focus"),$(this).data("type")){case"open":$("#red-ui-projects-dialog-create").text(RED._("projects.create.open"));break;case"empty":$("#red-ui-projects-dialog-create").text(RED._("projects.create.create"));break;case"clone":$("#red-ui-projects-dialog-create").text(RED._("projects.create.clone"))}}),h=$('<div class="form-row red-ui-projects-dialog-screen-create-row red-ui-projects-dialog-screen-create-row-open"></div>').hide().appendTo(p),s=(s={canSelectActive:!1,dblclick:function(e){F=e,$("#red-ui-projects-dialog-create").trigger("click")},select:function(e){F=e,f()},delete:function(e){c&&delete c[e.name],F=null,f()}})||{},R=$("<div></div>",{class:"red-ui-projects-dialog-project-list-container"}),t="",b=$("<div>",{class:"red-ui-search-container"}).appendTo(R),(r=$('<input id="red-ui-projects-dialog-project-list-search" type="text" placeholder="'+RED._("projects.create-project-list.search")+'">').appendTo(b).searchBox({delay:200,change:function(){t=$(this).val().toLowerCase(),l.editableList("filter"),n&&!n.is(":visible")&&n.children().children().removeClass("selected"),(n=l.children(":visible").first()).children().children().addClass("selected"),s.select&&s.select(n.children().data("data")),d()}})).on("keydown",function(e){if(40===e.keyCode){e.preventDefault();var t=n;if(n){for(;0!==(t=t.next()).length&&!t.is(":visible"););if(0===t.length)return;n.children().children().removeClass("selected")}else t=l.children(":visible").first();(n=t).children().children().addClass("selected"),s.select&&s.select(n.children().data("data")),d()}else if(38===e.keyCode){e.preventDefault();var o=n;if(n){for(;0!==(o=o.prev()).length&&!o.is(":visible"););if(0===o.length)return;n.children().children().removeClass("selected")}else o=l.children(":visible").first();(n=o).children().children().addClass("selected"),s.select&&s.select(n.children().data("data")),d()}else 13===e.keyCode&&(e.preventDefault(),n&&s.dblclick&&s.dblclick(n.children().data("data")))}),r.i18n(),d=function(){var e,t,o,n=l.find(".red-ui-projects-dialog-project-list-entry.selected").parent().parent();1===n.length&&(t=(e=i).height(),e.scrollTop(),t<(o=n.position().top)+(n=n.height())?e.animate({scrollTop:"-="+(t-o-n)},50):o<0&&e.animate({scrollTop:"+="+o},50))},i=$("<div></div>",{class:"red-ui-projects-dialog-project-list-inner-container"}).appendTo(R),l=$("<ol>",{class:"red-ui-projects-dialog-project-list"}).appendTo(i).editableList({addButton:!1,height:"auto",scrollOnAdd:!1,addItem:function(i,e,a){var t,o=$("<div></div>",{class:"red-ui-projects-dialog-project-list-entry"}).appendTo(i);$('<span class="red-ui-projects-dialog-project-list-entry-icon"><i class="fa fa-archive"></i></span>').appendTo(o),$('<span class="red-ui-projects-dialog-project-list-entry-name" style=""></span>').text(a.name).appendTo(o),U&&U.name===a.name&&(o.addClass("projects-list-entry-current"),$('<span class="red-ui-projects-dialog-project-list-entry-current">'+RED._("projects.create-project-list.current")+"</span>").appendTo(o),!1===s.canSelectActive)||(o.addClass("selectable"),t=$('<div class="red-ui-projects-dialog-project-list-entry-tools"></div>').appendTo(o),$('<button class="red-ui-button red-ui-projects-dialog-button red-ui-button-small" style="float: right;"><i class="fa fa-trash"></i></button>').appendTo(t).on("click",function(e){var t,o,n;e.stopPropagation(),e.preventDefault(),e=i,t=a.name,o=function(e){e||i.fadeOut(300,function(){l.editableList("removeItem",a),s.delete&&s.delete(a)})},n=$('<div class="red-ui-projects-dialog-project-list-entry-delete-confirm"></div>').on("click",function(e){e.stopPropagation()}).appendTo(e),$("<span>").text(RED._("projects.delete.confirm")).appendTo(n),$('<button class="red-ui-button red-ui-projects-dialog-button">'+RED._("common.label.cancel")+"</button>").appendTo(n).on("click",function(e){e.stopPropagation(),n.remove(),o(!0)}),$('<button class="red-ui-button red-ui-projects-dialog-button primary">'+RED._("common.label.delete")+"</button>").appendTo(n).on("click",function(e){e.stopPropagation(),n.remove(),V({url:"projects/"+t,type:"DELETE",responses:{200:function(e){o(!1)},400:{unexpected_error:function(e){n.remove(),o(!0)}}}})}),setTimeout(function(){n.css("left",0)},50)}),i.on("click",function(e){$(".red-ui-projects-dialog-project-list-entry").removeClass("selected"),o.addClass("selected"),n=i.parent(),s.select&&s.select(a),d(),r.trigger("focus")}),s.dblclick&&i.on("dblclick",function(e){e.preventDefault(),s.dblclick(a)}))},filter:function(e){return""===t||-1!==e.name.toLowerCase().indexOf(t)}}),$.getJSON("projects",function(e){e.projects.forEach(function(e){l.editableList("addItem",{name:e})})}),R.appendTo(h),h=$('<div class="form-row red-ui-projects-dialog-screen-create-row red-ui-projects-dialog-screen-create-row-open"></div>').hide().appendTo(p),$('<span style="display: flex; align-items: center;"><input style="padding:0; margin: 0 5px 0 0" checked type="checkbox" id="red-ui-projects-dialog-screen-clear-context"> <label for="red-ui-projects-dialog-screen-clear-context" style="padding:0; margin: 0"> <span data-i18n="projects.create.clearContext"></span></label></span>').appendTo(h).i18n(),h=$('<div class="form-row red-ui-projects-dialog-screen-create-row red-ui-projects-dialog-screen-create-row-empty red-ui-projects-dialog-screen-create-row-clone"></div>').appendTo(p),$('<label for="red-ui-projects-dialog-screen-create-project-name">'+RED._("projects.create.project-name")+"</label>").appendTo(h),$('<div style="position:relative;"></div>').appendTo(h)),y=(L=$('<input id="red-ui-projects-dialog-screen-create-project-name" type="text"></input>').appendTo(b),$('<div class="red-ui-projects-dialog-screen-input-status"></div>').appendTo(b)),w=!1,E="",D="",R=(L.on("change keyup paste",function(){if(w=L.val()!==E,o)clearTimeout(o);else if(w&&(y.empty(),$('<img src="red/images/spin.svg"/>').appendTo(y),""===L.val()))return void f();o=setTimeout(function(){f(),o=null},300)}),z=$('<label class="red-ui-projects-edit-form-sublabel"><small>'+RED._("projects.create.must-contain")+"</small></label>").appendTo(h).find("small"),h=$('<div class="form-row red-ui-projects-dialog-screen-create-row red-ui-projects-dialog-screen-create-row-empty"></div>').appendTo(p),$('<label for="red-ui-projects-dialog-screen-create-project-desc">'+RED._("projects.create.desc")+"</label>").appendTo(h),S=$('<input id="red-ui-projects-dialog-screen-create-project-desc" type="text">').appendTo(h),$('<label class="red-ui-projects-edit-form-sublabel"><small>'+RED._("projects.create.opt")+"</small></label>").appendTo(h),h=$('<div class="form-row red-ui-projects-dialog-screen-create-row red-ui-projects-dialog-screen-create-row-empty"></div>').appendTo(p),$('<label for="red-ui-projects-dialog-screen-create-project-file">'+RED._("projects.create.flow-file")+"</label>").appendTo(h),b=$('<div style="position:relative;"></div>').appendTo(h),O=$('<input id="red-ui-projects-dialog-screen-create-project-file" type="text">').val("flow.json").on("change keyup paste",f).appendTo(b),$('<div class="red-ui-projects-dialog-screen-input-status"></div>').appendTo(b),$('<label class="red-ui-projects-edit-form-sublabel"><small>*.json</small></label>').appendTo(h),h=$('<div class="form-row red-ui-projects-dialog-screen-create-row red-ui-projects-dialog-screen-create-row-empty"></div>').appendTo(p),$("<label>"+RED._("projects.create.credentials")+"</label>").appendTo(h),$('<div class="red-ui-projects-dialog-credentials-box">').appendTo(h)),x=$('<div class="red-ui-projects-dialog-credentials-box-right">').appendTo(R),R=$('<div class="red-ui-projects-dialog-credentials-box-left">').appendTo(R),_=$('<div class="form-row red-ui-projects-dialog-credentials-box-enabled"></div>').appendTo(R),k=($('<label class="red-ui-projects-edit-form-inline-label"><input type="radio" name="projects-encryption-type" value="enabled"> <i class="fa fa-lock"></i> <span>'+RED._("projects.encryption-config.enable")+"</span></label>").appendTo(_),$('<div class="form-row red-ui-projects-dialog-credentials-box-disabled disabled"></div>').appendTo(R)),T=($('<label class="red-ui-projects-edit-form-inline-label"><input type="radio" name="projects-encryption-type" value="disabled"> <i class="fa fa-unlock"></i> <span>'+RED._("projects.encryption-config.disable")+"</span></label>").appendTo(k),R.find("input[name=projects-encryption-type]").on("click",function(e){var t,o;"enabled"===$(this).val()?(t=_,o=k,$(".projects-encryption-enabled-row").show(),$(".projects-encryption-disabled-row").hide(),"custom"===$("input[name=projects-encryption-key]:checked").val()&&P.trigger("focus")):(o=_,t=k,$(".projects-encryption-enabled-row").hide(),$(".projects-encryption-disabled-row").show()),t.removeClass("disabled"),o.addClass("disabled"),f()}),h=$('<div class="form-row projects-encryption-enabled-row"></div>').appendTo(x),$('<label class="red-ui-projects-edit-form-inline-label">'+RED._("projects.create.encryption-key")+"</label>").appendTo(h),(P=$('<input type="password"></input>').appendTo(h)).typedInput({type:"cred"}),P.on("change keyup paste",f),$('<label class="red-ui-projects-edit-form-sublabel"><small>'+RED._("projects.create.desc0")+"</small></label>").appendTo(h),h=$('<div class="form-row projects-encryption-disabled-row"></div>').hide().appendTo(x),$('<div class="" style="padding: 5px 20px;"><i class="fa fa-warning"></i> '+RED._("projects.create.desc1")+"</div>").appendTo(h),x.find("input[name=projects-encryption-key]").on("click",function(){var e=$(this).val();P.attr("disabled","default"===e),"custom"===e&&P.trigger("focus"),f()}),h=$('<div class="hide form-row red-ui-projects-dialog-screen-create-row red-ui-projects-dialog-screen-create-row-clone"></div>').appendTo(p),$('<label for="red-ui-projects-dialog-screen-create-project-repo">'+RED._("projects.create.git-url")+"</label>").appendTo(h),N=$('<input id="red-ui-projects-dialog-screen-create-project-repo" type="text" placeholder="https://git.example.com/path/my-project.git"></input>').appendTo(h),$('<label id="red-ui-projects-dialog-screen-create-project-repo-label" class="red-ui-projects-edit-form-sublabel"><small>'+RED._("projects.create.protocols")+"</small></label>").appendTo(h),!1),C="",R=(N.on("change keyup paste",function(){T=!0;var e,t=$(this).val(),t=(C!==t&&$("#red-ui-projects-dialog-screen-create-project-repo-label small").text(RED._("projects.create.protocols")),C=t,/\/([^/]+?)(?:\.git)?$/.exec(t));!t||""!==(e=L.val())&&e!==D||(D=t[1],L.val(D),L.trigger("change")),f()}),$('<div class="hide red-ui-projects-dialog-screen-create-row red-ui-projects-dialog-screen-create-row-clone"></div>').hide().appendTo(p)),b=(h=$('<div class="form-row red-ui-projects-dialog-screen-create-row-auth-error"></div>').hide().appendTo(R),$('<div><i class="fa fa-warning"></i> '+RED._("projects.create.auth-failed")+"</div>").appendTo(h),h=$('<div class="hide form-row red-ui-projects-dialog-screen-create-row-creds"></div>').hide().appendTo(R),$('<div style="width: calc(50% - 10px); display:inline-block;"></div>').appendTo(h)),j=($('<label for="red-ui-projects-dialog-screen-create-project-repo-user">'+RED._("projects.create.username")+"</label>").appendTo(b),A=$('<input id="red-ui-projects-dialog-screen-create-project-repo-user" type="text"></input>').appendTo(b),b=$('<div style="width: calc(50% - 10px); margin-left: 20px; display:inline-block;"></div>').appendTo(h),$('<label for="red-ui-projects-dialog-screen-create-project-repo-pass">'+RED._("projects.create.password")+"</label>").appendTo(b),(M=$('<input style="width:100%" id="red-ui-projects-dialog-screen-create-project-repo-pass" type="password"></input>').appendTo(b)).typedInput({type:"cred"}),h=$('<div class="form-row red-ui-projects-dialog-screen-create-row red-ui-projects-dialog-screen-create-row-sshkey"></div>').hide().appendTo(R),b=$('<div style="width: calc(50% - 10px); display:inline-block;"></div>').appendTo(h),$('<label for="red-ui-projects-dialog-screen-create-project-repo-passphrase">'+RED._("projects.create.ssh-key")+"</label>").appendTo(b),B=$("<select>",{style:"width: 100%"}).appendTo(b),$.getJSON("settings/user/keys",function(e){var t=0;e.keys.forEach(function(e){B.append($("<option></option>").val(e.name).text(e.name)),t++}),0===t?(B.addClass("input-error"),B.attr("disabled",!0),j.show()):(B.removeClass("input-error"),B.attr("disabled",!1),j.hide())}),b=$('<div style="width: calc(50% - 10px); margin-left: 20px; display:inline-block;"></div>').appendTo(h),$('<label for="red-ui-projects-dialog-screen-create-project-repo-passphrase">'+RED._("projects.create.passphrase")+"</label>").appendTo(b),(G=$('<input id="red-ui-projects-dialog-screen-create-project-repo-passphrase" type="password"></input>').appendTo(b)).typedInput({type:"cred"}),b=$('<div class="form-row red-ui-projects-dialog-screen-create-row red-ui-projects-dialog-screen-create-row-sshkey"></div>').appendTo(R),$('<div class="red-ui-projects-dialog-screen-create-row-auth-error-no-keys"></div>').hide().appendTo(b));switch($('<div class="form-row"><i class="fa fa-warning"></i> '+RED._("projects.create.desc2")+"</div>").appendTo(j),b=$('<div style="text-align: center">').appendTo(j),$('<button class="red-ui-button red-ui-projects-dialog-button">'+RED._("projects.create.add-ssh-key")+"</button>").appendTo(b).on("click",function(e){e.preventDefault(),$("#red-ui-projects-dialog-cancel").trigger("click"),RED.userSettings.show("gitconfig"),setTimeout(function(){$("#user-settings-gitconfig-add-key").trigger("click")},500)}),h=$('<div class="hide form-row red-ui-projects-dialog-screen-create-row red-ui-projects-dialog-screen-create-row-clone"></div>').appendTo(p),$("<label>"+RED._("projects.create.credentials-encryption-key")+"</label>").appendTo(h),(I=$('<input style="width:100%" type="password"></input>').appendTo(h)).typedInput({type:"cred"}),e.screen||"empty"){case"empty":m.trigger("click");break;case"open":g.trigger("click");break;case"clone":v.trigger("click")}return setTimeout(function(){("open"!==(e.screen||"empty")?L:$("#red-ui-projects-dialog-project-list-search")).trigger("focus")},50),p},buttons:function(e){var t;switch(e.screen||"empty"){case"open":t=RED._("projects.create.open");break;case"empty":t=RED._("projects.create.create");break;case"clone":t=RED._("projects.create.clone")}return[{id:"red-ui-projects-dialog-cancel",text:RED._("common.label.cancel"),click:function(){$(this).dialog("close")}},{id:"red-ui-projects-dialog-create",text:t,class:"primary disabled",disabled:!0,click:function(){var t,o,e=$(".red-ui-projects-dialog-screen-create-type.selected").data("type"),n={name:L.val()};if("empty"===e){n.summary=S.val(),n.files={flow:O.val()};var i=$("input[name=projects-encryption-type]:checked").val();n.credentialSecret="enabled"===i&&P.val()}else if("copy"===e)n.copy=(void 0).name;else if("clone"===e){n.credentialSecret=I.val();var i=N.val();if(/^(?:ssh|[\d\w\.\-_]+@[\w\.]+):(?:\/\/)?/.test(i)){var a=B.val();if(!a)return void console.log(RED._("projects.create.cant-get-ssh-key-path"));n.git={remotes:{origin:{url:i,keyFile:a,passphrase:G.val()}}}}else n.git={remotes:{origin:{url:i,username:A.val(),password:M.val()}}}}else if("open"===e)return a=$("#red-ui-projects-dialog-screen-clear-context").prop("checked"),t=F.name,i=a,o=function(e,t){e&&"credentials_load_failed"!==e.code&&console.log(RED._("projects.create.unexpected_error"),e)},RED.deploy.setDeployInflight(!0),RED.projects.settings.switchProject(t),void V({url:"projects/"+t,type:"PUT",responses:{200:function(e){o(null,e)},400:{credentials_load_failed:function(e){T.dialog("close"),RED.events.emit("project:change",{name:t}),o(null,e)},"*":o}}},{active:!0,clearContext:i}).then(function(){T.dialog("close"),RED.events.emit("project:change",{name:t})}).always(function(){setTimeout(function(){RED.deploy.setDeployInflight(!1)},500)});$(".red-ui-projects-dialog-screen-create-row-auth-error").hide(),$("#red-ui-projects-dialog-screen-create-project-repo-label small").text(RED._("projects.create.protocols")),A.removeClass("input-error"),M.removeClass("input-error"),B.removeClass("input-error"),G.removeClass("input-error"),RED.deploy.setDeployInflight(!0),RED.projects.settings.switchProject(n.name),V({url:"projects",type:"POST",handleAuthFail:!1,responses:{200:function(e){T.dialog("close")},400:{project_exists:function(e){console.log(RED._("projects.create.already-exists-2"))},git_error:function(e){console.log(RED._("projects.create.git-error"),e)},git_connection_failed:function(e){N.addClass("input-error"),$("#red-ui-projects-dialog-screen-create-project-repo-label small").text(RED._("projects.create.con-failed"))},git_not_a_repository:function(e){N.addClass("input-error"),$("#red-ui-projects-dialog-screen-create-project-repo-label small").text(RED._("projects.create.not-git"))},git_repository_not_found:function(e){N.addClass("input-error"),$("#red-ui-projects-dialog-screen-create-project-repo-label small").text(RED._("projects.create.no-resource"))},git_auth_failed:function(e){$(".red-ui-projects-dialog-screen-create-row-auth-error").show(),A.addClass("input-error"),M.addClass("input-error"),B.addClass("input-error"),G.addClass("input-error")},missing_flow_file:function(e){T.dialog("close")},missing_package_file:function(e){T.dialog("close")},project_empty:function(e){T.dialog("close")},credentials_load_failed:function(e){T.dialog("close")},"*":function(e){p(e),$(T).dialog("close")}}}},n).then(function(){RED.events.emit("project:change",{name:name})}).always(function(){setTimeout(function(){RED.deploy.setDeployInflight(!1)},500)})}}]}}}}function u(e,t){T||RED.projects.init();var e=a[e],o=e.content(t||{}),n=(i.empty(),e.buttons),t=("function"==typeof n&&(n=n(t||{})),T.dialog("option","buttons",n),i.append(o),590),n=$(window).height();n<750&&(t=590-(750-n)),$(".red-ui-projects-dialog-box").height(t),$(".red-ui-projects-dialog-project-list-inner-container").height(Math.max(500,t)-210),T.dialog("option","title",e.title||""),T.dialog("open")}function e(e){var t,o;RED.nodes.dirty()&&(t=RED._("projects.require-clean.confirm"),o=RED.notify(t,{type:"info",fixed:!0,modal:!0,buttons:[{text:RED._("common.label.cancel"),click:function(){o.close(),e(!0)}},{text:RED._("common.label.cont"),click:function(){o.close(),e(!1)}}]}))}function V(l,c){var t,o;if(l.requireCleanWorkspace&&RED.nodes.dirty())return e(function(e){e?l.cancel&&(l.cancel(),o&&o()):(delete l.requireCleanWorkspace,V(l,c).then(function(){t&&t()}).always(function(){o&&o()}))}),{then:function(e){return t=e,{always:function(e){o=e}}},always:function(e){o=e}};var u,p,n=Date.now();return $(".red-ui-component-spinner").show(),$("#red-ui-projects-dialog").parent().find(".ui-dialog-buttonset").children().css("visibility","hidden"),c&&(l.data=JSON.stringify(c),l.contentType="application/json; charset=utf-8"),$.ajax(l).done(function(e,t,o){l.responses&&l.responses[200]&&(u=l.responses[200],p=e)}).fail(function(o,e,t){var n,i,a,s,r,d;if(l.responses&&l.responses[o.status]){if("function"==typeof(n=l.responses[o.status]))return void(p={error:(u=n).statusText});if(!1===l.handleAuthFail||"git_auth_failed"!==o.responseJSON.code&&"git_host_key_verification_failed"!==o.responseJSON.code){if(n[o.responseJSON.code])return u=n[o.responseJSON.code],void(p=o.responseJSON);if(n["*"])return u=n["*"],void(p=o.responseJSON)}else{if("git_auth_failed"===o.responseJSON.code)return a=U.git.remotes[o.responseJSON.remote||l.remote||"origin"].fetch,r=$('<div><div class="form-row">'+RED._("projects.send-req.auth-req")+':</div><div class="form-row"><div style="margin-left: 20px;">'+a+"</div></div></div>"),i=!1,/^https?:\/\//.test(a)?($('<div class="form-row"><label for="projects-user-auth-username">'+RED._("projects.send-req.username")+'</label><input id="projects-user-auth-username" type="text"></input></div><div class="form-row"><label for="projects-user-auth-password">'+RED._("projects.send-req.password")+'</label><input id="projects-user-auth-password" type="password"></input></div>').appendTo(r),r.find("#projects-user-auth-password").typedInput({type:"cred"})):/^(?:ssh|[\d\w\.\-_]+@[\w\.]+):(?:\/\/)?/.test(a)&&(i=!0,a=$('<div class="form-row"></div>').appendTo(r),$('<label for="projects-user-auth-key">SSH Key</label>').appendTo(a),s=$('<select id="projects-user-auth-key">').width("70%").appendTo(a),$.getJSON("settings/user/keys",function(e){e.keys.forEach(function(e){s.append($("<option></option>").val(e.name).text(e.name)),0})}),a=$('<div class="form-row"></div>').appendTo(r),$('<label for="projects-user-auth-passphrase">'+RED._("projects.send-req.passphrase")+"</label>").appendTo(a),$('<input id="projects-user-auth-passphrase" type="password"></input>').appendTo(a).typedInput({type:"cred"})),void(d=RED.notify(r,{type:"error",fixed:!0,modal:!0,buttons:[{text:RED._("common.label.cancel"),click:function(){d.close()}},{text:'<span><i class="fa fa-refresh"></i> '+RED._("projects.send-req.retry")+"</span>",click:function(){c=c||{};function t(e){e?(console.log(RED._("projects.send-req.update-failed")),console.log(e)):(V(l,c),d.close())}var e={};i?(e.keyFile=$("#projects-user-auth-key").val(),e.passphrase=$("#projects-user-auth-passphrase").val()):(e.username=$("#projects-user-auth-username").val(),e.password=$("#projects-user-auth-password").val());V({url:"projects/"+U.name+"/remotes/"+(o.responseJSON.remote||l.remote||"origin"),type:"PUT",responses:{0:function(e){t(e)},200:function(e){t(null)},400:{unexpected_error:function(e){t(e)}}}},{auth:e})}}]}));if("git_host_key_verification_failed"===o.responseJSON.code)return r=$('<div><div class="form-row">'+RED._("projects.send-req.host-key-verify-failed")+"</div></div>"),void(d=RED.notify(r,{type:"error",fixed:!0,modal:!0,buttons:[{text:RED._("common.label.close"),click:function(){d.close()}}]}))}}console.log(n),console.log(RED._("projects.send-req.unhandled")+":"),console.log(o),console.log(e),console.log(t)}).always(function(){var e=Date.now()-n,e=Math.max(0,500-e);setTimeout(function(){$(".red-ui-component-spinner").hide(),$("#red-ui-projects-dialog").parent().find(".ui-dialog-buttonset").children().css("visibility",""),u&&u(p)},e)})}function o(n){var i,a="",s=new Set,r=[],d="",l=$('<div class="red-ui-projects-branch-list">').appendTo(n.container),c=$('<input type="text">').attr("placeholder",n.placeholder).appendTo(l).searchBox({delay:200,change:function(){a=$(this).val();var e=!1,t=!1,o=/^([^/]+)\/[^/.~*?\[]/.exec(a);o&&-1<r.indexOf(o[1])&&(t=e=!0),!e&&/(\.\.|\/\.|[?*[~^: \\]|\/\/|\/.$|\/$)/.test(a)?(i.hasClass("input-error")||(i.addClass("input-error"),i.find("i").addClass("fa-warning").removeClass("fa-code-fork")),i.find("span").text(RED._("projects.create-branch-list.invalid")+": "+(t?"":d)+a)):(i.hasClass("input-error")&&(i.removeClass("input-error"),i.find("i").removeClass("fa-warning").addClass("fa-code-fork")),i.find("span").text(RED._("projects.create-branch-list.create")+":"),i.find(".red-ui-sidebar-vc-branch-list-entry-create-name").text((t?"":d)+a)),u.editableList("filter")}}),u=$("<ol>",{style:"height: 130px;"}).appendTo(l);return u.editableList({addButton:!1,scrollOnAdd:!1,addItem:function(e,t,o){e=$('<div class="red-ui-sidebar-vc-branch-list-entry">').appendTo(e);o.hasOwnProperty("commit")?($('<i class="fa fa-code-fork"></i>').appendTo(e),$("<span>").text(o.name).appendTo(e),o.current&&(e.addClass("selected"),$('<span class="current"></span>').text(n.currentLabel||RED._("projects.create-branch-list.current")).appendTo(e))):(i=e,$('<i class="fa fa-code-fork"></i>').appendTo(e),$("<span>").text(RED._("projects.create-branch-list.create")+":").appendTo(e),$('<div class="red-ui-sidebar-vc-branch-list-entry-create-name" style="margin-left: 10px;">').text(o.name).appendTo(e)),e.on("click",function(e){var t;e.preventDefault(),$(this).hasClass("input-error")||(e={},o.hasOwnProperty("commit")?($(this).hasClass("selected")&&(e.current=!0),e.name=o.name):(e.name=c.val(),e.create=!0,!n.remotes||(t=/^([^/]+)\/[^/.~*?\[]/.exec(e.name))&&-1!==r.indexOf(t[1])||(e.name=r[0]+"/"+e.name)),n.onselect&&n.onselect(e))})},filter:function(e){var t,o=!e.hasOwnProperty("commit"),n=a;return 0<r.length&&(t=/^([^/]+)\/[^/.~*?\[]/.exec(n),""===n||t&&-1!=r.indexOf(t[1])||(n=r[0]+"/"+n)),o&&""!==n&&!s.has(n)||!o&&-1!==e.name.indexOf(a)}}),{refresh:function(e){c.searchBox("value",""),u.editableList("empty");var t=Date.now(),o=f(l).addClass("red-ui-component-spinner-contain");n.remotes?(r=n.remotes(),d=r[0]+"/"):(d="",r=[]),s=new Set,V({url:e,type:"GET",responses:{0:function(e){console.log(e)},200:function(e){e.branches,e.branches.forEach(function(e){u.editableList("addItem",e),s.add(e.name)}),u.editableList("addItem",{}),setTimeout(function(){o.remove()},Math.max(300-(Date.now()-t),0))},400:{git_connection_failed:function(e){RED.notify(e.message,"error")},git_not_a_repository:function(e){RED.notify(e.message,"error")},git_repository_not_found:function(e){RED.notify(e.message,"error")},unexpected_error:function(e){p(e)}}}})},filter:function(){u.editableList("filter")},focus:function(){c.trigger("focus")}}}function f(e){return $('<div class="red-ui-component-spinner"><img src="red/images/spin.svg"/></div>').appendTo(e)}function n(){createProjectOptions={},U?u("create",{screen:"empty"}):u("welcome")}return{init:function(){T=$('<div id="red-ui-projects-dialog" class="hide red-ui-projects-edit-form"><div class="red-ui-projects-dialog-box"><form class="form-horizontal"></form><div class="red-ui-component-spinner hide"><img src="red/images/spin.svg"/></div></div></div>').appendTo("#red-ui-editor").dialog({modal:!0,autoOpen:!1,width:600,resizable:!1,open:function(e){RED.keyboard.disable()},close:function(e){RED.keyboard.enable()},classes:{"ui-dialog":"red-ui-editor-dialog","ui-dialog-titlebar-close":"hide","ui-widget-overlay":"red-ui-editor-dialog"}}),i=T.find("form"),RED.actions.add("core:new-project",RED.projects.newProject),RED.actions.add("core:open-project",RED.projects.selectProject),RED.actions.add("core:show-project-settings",RED.projects.settings.show);var e={sendRequest:V,createBranchList:o,addSpinnerOverlay:f,reportUnexpectedError:p};RED.projects.settings.init(e),RED.projects.userSettings.init(e),RED.sidebar.versionControl.init(e),t()},showStartup:function(){console.warn("showStartup"),RED.user.hasPermission("projects.write")?u("welcome"):RED.notify(RED._("user.errors.notAuthorized"),"error")},newProject:function(){if(RED.user.hasPermission("projects.write"))return RED.nodes.dirty()?e(function(e){e||n()}):void n();RED.notify(RED._("user.errors.notAuthorized"),"error")},selectProject:function(){if(RED.user.hasPermission("projects.write"))return RED.nodes.dirty()?e(function(e){e||u("create",{screen:"open"})}):void u("create",{screen:"open"});RED.notify(RED._("user.errors.notAuthorized"),"error")},showCredentialsPrompt:function(){RED.user.hasPermission("projects.write")?RED.projects.settings.show("settings"):RED.notify(RED._("user.errors.notAuthorized"),"error")},showFilesPrompt:function(){RED.user.hasPermission("projects.write")?(RED.projects.settings.show("settings"),setTimeout(function(){$("#project-settings-tab-settings-file-edit").trigger("click")},200)):RED.notify(RED._("user.errors.notAuthorized"),"error")},showProjectDependencies:function(){RED.projects.settings.show("deps")},createDefaultFileSet:function(){if(!U)throw new Error(RED._("projects.create-default-file-set.no-active"));if(!U.empty)throw new Error(RED._("projects.create-default-file-set.no-empty"));RED.user.hasPermission("projects.write")?(createProjectOptions={},u("default-files",{existingProject:!0})):RED.notify(RED._("user.errors.notAuthorized"),"error")},createDefaultPackageFile:function(){RED.deploy.setDeployInflight(!0),RED.projects.settings.switchProject(U.name),V({url:"projects/"+U.name,type:"PUT",requireCleanWorkspace:!0,handleAuthFail:!1,responses:{200:function(e){},400:{git_error:function(e){console.log(RED._("projects.create-default-file-set.git-error"),e)},missing_flow_file:function(e){$(T).dialog("close")},"*":function(e){p(e),$(T).dialog("close")}}}},{initialise:!0}).always(function(){setTimeout(function(){RED.deploy.setDeployInflight(!1)},500)})},refresh:function(t){$.getJSON("projects",function(e){e.active?$.getJSON("projects/"+e.active,function(e){U=e,RED.events.emit("projects:load",U),RED.sidebar.versionControl.refresh(!0),t&&t(U)}):t&&t(null)})},editProject:function(){RED.projects.settings.show()},getActiveProject:function(){return U}}}(),RED.projects.settings=function(){var B,G,t=700,o=!1,s=[];function n(e){s.push(e)}function r(n,i){RED.editor.editMarkdown({title:RED._("sidebar.project.editDescription"),header:$('<span><i class="fa fa-book"></i> README.md</span>'),value:n.description,stateId:"sidebar.project.editDescription",complete:function(o){i.empty();function t(e,t){if(e)return r(n,i);n.description=o,d(n,i)}var e=G.addSpinnerOverlay(i);G.sendRequest({url:"projects/"+n.name,type:"PUT",responses:{0:function(e){t(e)},200:function(e){t(null),RED.sidebar.versionControl.refresh(!0)},400:{"*":function(e){G.reportUnexpectedError(e),t(e)}}}},{description:o}).always(function(){e.remove()})}})}function d(e,t){t.empty(),e=e.description?RED.utils.renderMarkdown(e.description):'<span class="red-ui-help-info-none">'+RED._("sidebar.project.noDescriptionAvailable")+"</span>",e=$('<span class="red-ui-text-bidi-aware" dir="'+RED.text.bidi.resolveBaseTextDir(e)+'">'+e+"</span>"),$(e).find("a").each(function(e){var t=$(this).attr("href");/^https?:/.test(t)&&$(this).attr("target","_blank")}),e.appendTo(t).find(".red-ui-text-bidi-aware").contents().filter(function(){return 3===this.nodeType&&""!==this.textContent.trim()}).wrap("<span></span>")}function f(a,s,r,d,l){var c=r.prev(),e=(c.hide(),r.empty(),l.empty(),$('<span class="button-row" style="position: relative; float: right; margin-right:0;"></span>').appendTo(r)),u=$('<input type="text" style="width: calc(100% - 150px); margin-right: 10px;">').val(s||"").appendTo(r),p=$('<input type="text" style="width: calc(100% - 150px); margin-right: 10px;">').val(d||"").appendTo(l);$('<button class="red-ui-button">'+RED._("common.label.cancel")+"</button>").appendTo(e).on("click",function(e){e.preventDefault(),h(a.summary,r),g(a.version,l),c.show()}),$('<button class="red-ui-button">'+RED._("common.label.save")+"</button>").appendTo(e).on("click",function(e){e.preventDefault();function t(e,t){if(e)return i.remove(),f(a,s,r,d,l);a.summary=o,a.version=n,i.remove(),h(a.summary,r),g(a.version,l),c.show()}var o=u.val(),n=p.val(),i=(h(o,r),g(n,l),G.addSpinnerOverlay(r).addClass("red-ui-component-spinner-contain"));G.sendRequest({url:"projects/"+a.name,type:"PUT",responses:{0:function(e){t(e)},200:function(e){RED.sidebar.versionControl.refresh(!0),t(null)},400:{"*":function(e){G.reportUnexpectedError(e),t(e)}}}},{summary:o,version:n})})}function h(e,t){t.empty(),e?t.text(e).removeClass("red-ui-help-info-none"):t.text(RED._("sidebar.project.noSummaryAvailable")).addClass("red-ui-help-info-none")}function g(e,t){t.empty(),e&&t.text(e)}function i(t){var e=$('<div id="red-ui-project-settings-tab-main" class="red-ui-project-settings-tab-pane red-ui-help"></div>'),o=($("<h1>").text(t.name).appendTo(e),$('<div style="position: relative">').appendTo(e)),n=$("<div></div>").appendTo(o),i=$("<div></div>").addClass("red-ui-help-info-none").appendTo(o),o=(h(t.summary,n),g(t.version,i),RED.user.hasPermission("projects.write")&&$('<button class="red-ui-button red-ui-button-small" style="float: right;">'+RED._("sidebar.project.editDescription")+"</button>").prependTo(o).on("click",function(e){e.preventDefault(),f(t,t.summary,n,t.version,i)}),$("<hr>").appendTo(e),$('<div class="red-ui-help" style="position: relative"></div>').appendTo(e)),a=$("<div>",{style:"min-height: 200px"}).appendTo(o);return d(t,a),RED.user.hasPermission("projects.write")&&$('<button class="red-ui-button red-ui-button-small" style="float: right;">'+RED._("sidebar.project.editReadme")+"</button>").prependTo(o).on("click",function(e){e.preventDefault(),r(t,a)}),e}function l(e,t){t.editableList("empty");var o,n=0;for(i in b)b.hasOwnProperty(i)&&(t.editableList("addItem",{id:b[i].module,version:b[i].version,count:b[i].count,known:e.dependencies.hasOwnProperty(i),installed:!0}),n++,0===b[i].count&&0,e.dependencies.hasOwnProperty(i)||0);if(e.dependencies)for(var i in e.dependencies)e.dependencies.hasOwnProperty(i)&&!b.hasOwnProperty(i)&&(o=!!RED.nodes.registry.getModule(i),t.editableList("addItem",{id:i,version:e.dependencies[i],count:0,known:!0,installed:o}),n++,o?0:0);0===n&&t.editableList("addItem",{index:0,label:RED._("sidebar.project.projectSettings.none")})}function c(e,t,o,n){function i(e,t){if(s.remove(),e)return n(e);a.dependencies=o,RED.sidebar.versionControl.refresh(!0),n()}var a=RED.projects.getActiveProject(),s=G.addSpinnerOverlay(t).addClass("red-ui-component-spinner-contain");G.sendRequest({url:"projects/"+a.name,type:"PUT",responses:{0:function(e){i(e)},200:function(e){RED.sidebar.versionControl.refresh(!0),i(null)},400:{"*":function(e){i(e)}}}},{dependencies:o})}function a(r){var t=$('<div id="red-ui-project-settings-tab-deps" class="red-ui-project-settings-tab-pane red-ui-help"></div>'),d=(RED.user.hasPermission("projects.write")&&$('<button class="red-ui-button red-ui-button-small" style="margin-top:10px;float: right;">'+RED._("sidebar.project.projectSettings.edit")+"</button>").appendTo(t).on("click",function(e){e.preventDefault(),function n(i,e,a,s){e=e||JSON.stringify(i.dependencies||{},"",4);"{}"===e&&(e="{\n\n}"),RED.editor.editJSON({title:RED._("sidebar.project.editDependencies"),value:e,requireValid:!0,complete:function(t){try{var o=JSON.parse(t);c(0,a,o,function(e){if(e)return n(i,t,a,s);i.dependencies=o,l(i,s)})}catch(e){n(i,t,a,s)}}})}(r,null,t,d)}),$("<ol>",{style:"position: absolute;top: 60px;bottom: 20px;left: 20px;right: 20px;"}).appendTo(t));return d.editableList({addButton:!1,addItem:function(t,e,o){var n,i,a,s=$("<div>",{class:"red-ui-palette-module-header"}).appendTo(t);o.label?(0===o.index?s.addClass("red-ui-search-empty"):t.parent().addClass("red-ui-palette-module-section"),s.text(o.label)):(s.addClass("red-ui-palette-module-header"),o.installed?0===o.count?s.addClass("red-ui-palette-module-unused"):o.known||s.addClass("red-ui-palette-module-unknown"):s.addClass("red-ui-palette-module-not-installed"),o.element=s,n=$('<div class="red-ui-palette-module-meta red-ui-palette-module-name"></div>').appendTo(s),i="fa-cube",o.installed||(i="fa-warning"),i=$('<i class="fa '+i+'"></i>').appendTo(n),o.icon=i,$("<span>").text(o.id).appendTo(n),i=$('<div class="red-ui-palette-module-meta red-ui-palette-module-version"><i class="fa fa-tag"></i></div>').appendTo(s),$("<span>").text(o.version).appendTo(i),i=$('<div class="red-ui-palette-module-meta"></div>').appendTo(s),a=$('<div class="red-ui-palette-module-button-group"></div>').appendTo(i),RED.user.hasPermission("projects.write")&&(o.installed||!1===RED.settings.get("externalModules.palette.allowInstall",!0)?o.known&&0===o.count?$('<a href="#" class="red-ui-button red-ui-button-small">'+RED._("sidebar.project.projectSettings.removeFromProject")+"</a>").appendTo(a).on("click",function(e){e.preventDefault();e=$.extend(!0,{},r.dependencies);delete e[o.id],c(0,t,e,function(e){e?console.log(e):t.fadeOut(200,function(){d.editableList("removeItem",o)})})}):o.known||$('<a href="#" class="red-ui-button red-ui-button-small">'+RED._("sidebar.project.projectSettings.addToProject")+"</a>").appendTo(a).on("click",function(e){e.preventDefault();e=$.extend(!0,{},r.dependencies);e[o.id]=b[o.id].version,c(0,t,e,function(e){e?console.log(e):(a.remove(),s.removeClass("red-ui-palette-module-unknown"))})}):$('<a href="#" class="red-ui-button red-ui-button-small">'+RED._("sidebar.project.projectSettings.install")+"</a>").appendTo(a).on("click",function(e){e.preventDefault(),RED.palette.editor.install(o,t,function(e){e||(o.installed=!0,RED.utils.addSpinnerOverlay(t,!0),setTimeout(function(){d.editableList("removeItem",o),b={},RED.nodes.eachNode(v),RED.nodes.eachConfig(v),b.hasOwnProperty(o.id)?o.count=b[o.id].count:o.count=0,d.editableList("addItem",o)},500))})})))},sort:function(e,t){return e.id.localeCompare(t.id)}}),l(r,d),t}function F(e,t,n,a,s){var r=$('<div class="red-ui-projects-file-listing-container"></div>',{style:"position: relative; min-height: 175px; height: 175px;"}).hide().appendTo(e),d=G.addSpinnerOverlay(r);return $.getJSON("projects/"+t.name+"/files",function(t){var e=(e=Object.keys(t)).filter(function(e){return!t[e].status||!/D/.test(t[e].status)}),o={},i=(e.sort(),e.forEach(function(e){e.split("/").reduce(function(e,t,o,n){if(t)return o<n.length-1?e[t]=e[t]||{}:e[t]=!0,e[t]},o)}),function(e,t,o){var n={name:e||"/",path:o+(o?"/":"")+e};return!0===t?n.type="f":(n.type="d",n.children=[],n.path=n.path,Object.keys(t).forEach(function(e){n.children.push(i(e,t[e],n.path))}),n.children.sort(function(e,t){return e.hasOwnProperty("children")&&!t.hasOwnProperty("children")?-1:!e.hasOwnProperty("children")&&t.hasOwnProperty("children")?1:e.name.localeCompare(t.name)})),n}),o=i("",o,"");!function a(e,t,s,r,d,o){o=o||"";var n=$("<ol>",{class:"red-ui-projects-dialog-file-list",style:o}).appendTo(e).editableList({addButton:!1,scrollOnAdd:!1,addItem:function(e,t,o){var n,i=$("<div></div>",{class:"red-ui-projects-dialog-file-list-entry"}).appendTo(e);o.children?($('<span class="red-ui-projects-dialog-file-list-entry-folder"><i class="fa fa-angle-right"></i> <i class="fa fa-folder-o"></i></span>').appendTo(i),0<o.children.length&&(n=$("<div></div>",{style:"padding-left: 20px;"}).appendTo(e),0===s.indexOf(o.path+"/")?i.addClass("expanded"):n.hide(),a(n,o.children,s,r,d),i.addClass("selectable"),i.on("click",function(e){$(this).hasClass("expanded")?($(this).removeClass("expanded"),n.slideUp(200)):($(this).addClass("expanded"),n.slideDown(200))}))):(e="fa-file-o",/\.json$/i.test(o.name)?e="fa-file-code-o":/\.md$/i.test(o.name)?e="fa-book":/^\.git/i.test(o.name)&&(e="fa-code-fork",i.addClass("red-ui-projects-dialog-file-list-entry-file-type-git")),$('<span class="red-ui-projects-dialog-file-list-entry-file"> <i class="fa '+e+'"></i></span>').appendTo(i),r(o)?(i.addClass("selectable"),o.path===s&&i.addClass("selected"),i.on("click",function(e){$(".red-ui-projects-dialog-file-list-entry.selected").removeClass("selected"),$(this).addClass("selected"),d(o.path,!0)}),i.on("dblclick",function(e){e.preventDefault(),d(o.path,!0)})):i.addClass("unselectable")),$('<span class="red-ui-projects-dialog-file-list-entry-name" style=""></span>').text(o.name).appendTo(i)}});o||n.parent().css("overflow-y","");t.forEach(function(e){n.editableList("addItem",e)})}(r,o.children,n,a,s,"height: 175px"),d.remove()}),r}function u(a,e){function n(){t.show(),P.hide(),l.hide(),h.show(),m.hide(),v.hide(),R.removeClass("uneditable-input"),R.css("height",""),v.removeClass("selected"),u.find(".red-ui-projects-file-listing-container").remove(),u.css("height",""),u.css("color",""),$(".red-ui-settings-row-credentials").hide(),T.hide(),x.hide(),_.removeClass("selected"),k.removeClass("selected")}var t,o=$("<h3></h3>").text(RED._("sidebar.project.projectSettings.files")).appendTo(e),i=$('<div class="red-ui-settings-section"></div>').appendTo(e),s=(RED.user.hasPermission("projects.write")&&(t=$('<button type="button" id="red-ui-project-settings-tab-settings-file-edit" class="red-ui-button red-ui-button-small" style="float: right;">'+RED._("sidebar.project.projectSettings.edit")+"</button>").appendTo(o).on("click",function(e){e.preventDefault(),P.show(),t.hide(),a.files.package||(c.find(".red-ui-projects-edit-form-sublabel-text").text(RED._("sidebar.project.projectSettings.packageCreate")),c.show()),l.show(),h.hide(),m.show(),v.show(),g(),R.addClass("uneditable-input"),$(".red-ui-settings-row-credentials").show(),R.css("height","auto"),T.hide(),x.show()})),e=$('<div class="red-ui-settings-row"></div>').appendTo(i),$('<label for=""></label>').text(RED._("sidebar.project.projectSettings.package")).appendTo(e),$('<div class="uneditable-input" style="padding:0">').appendTo(e)),r=$('<span style="display:inline-block; padding: 6px">').text(a.files.package||"package.json").appendTo(s),d=$('<input type="hidden">').val(a.files.package||"package.json").appendTo(s),l=$('<button type="button" class="red-ui-button toggle single" style="border-top-right-radius: 4px; border-bottom-right-radius: 4px; width: 36px; height: 34px; position: absolute; top: -1px; right: -1px;"><i class="fa fa-folder-open-o"></i></button>').hide().appendTo(s).on("click",function(e){var t;$(this).hasClass("selected")?($(this).removeClass("selected"),s.find(".red-ui-projects-file-listing-container").slideUp(200,function(){$(this).remove(),s.css("height","")}),s.css("color","")):($(this).addClass("selected"),s.css("color","inherit"),t=F(s,a,d.val(),function(e){return e.children||/package\.json$/.test(e.path)},function(e,t){e&&(d.val(e),r.text(e),e=e.substring(0,e.length-12),p.text(e),y.text(e),g(),c.hide()),t&&$(l).trigger("click"),D()}),s.css("height","auto"),setTimeout(function(){t.slideDown(200)},50))}),c=(RED.popover.tooltip(l,RED._("sidebar.project.projectSettings.selectFile")),$('<label style="margin-left: 110px" class="red-ui-projects-edit-form-sublabel"><small><span class="form-warning"><i class="fa fa-warning"></i> <span class="red-ui-projects-edit-form-sublabel-text"></span></small></label>').appendTo(e).hide()),o=(a.files.package||(c.find(".red-ui-projects-edit-form-sublabel-text").text(RED._("sidebar.project.projectSettings.fileNotExist")),c.show()),a.files.package||"package.json"),o=o.substring(0,o.length-12),e=$('<div class="red-ui-settings-row"></div>').appendTo(i),u=($('<label for=""></label>').text(RED._("sidebar.project.projectSettings.flow")).appendTo(e),$('<div class="uneditable-input" style="padding:0">').appendTo(e)),p=$('<span style="display:inline-block; padding: 6px 0 6px 6px">').text(o).appendTo(u),f="flows.json",h=(a.files.flow&&(f=0===a.files.flow.indexOf(o)?a.files.flow.substring(o.length):a.files.flow),$('<span style="display:inline-block; padding: 6px 6px 6px 0">').text(f).appendTo(u)),g=function(){m.css({width:"calc(100% - "+(v.width()+p.width())+"px)"})},m=$('<input type="text" style="padding-left:1px; margin-top: -2px; margin-bottom: 0;border: none;">').val(f).hide().appendTo(u),v=$('<button type="button" class="red-ui-button toggle single" style="border-top-right-radius: 4px; border-bottom-right-radius: 4px; width: 36px; height: 34px; position: absolute; top: -1px; right: -1px;"><i class="fa fa-folder-open-o"></i></button>').hide().appendTo(u).on("click",function(e){var t,o,n,i;$(this).hasClass("selected")?($(this).removeClass("selected"),u.find(".red-ui-projects-file-listing-container").slideUp(200,function(){$(this).remove(),u.css("height","")}),u.css("color","")):($(this).addClass("selected"),u.css("color","inherit"),t=d.val(),o=t.substring(0,t.length-12),n=new RegExp("^"+o+".*.json$"),i=F(u,a,m.val(),function(e){return!/package.json$/.test(e.path)&&n.test(e.path)&&!/_cred\.json$/.test(e.path)},function(e,t){e&&m.val(e.substring(o.length)),t&&$(v).trigger("click"),D()}),u.css("height","auto"),setTimeout(function(){i.slideDown(200)},50))}),b=(RED.popover.tooltip(v,RED._("sidebar.project.projectSettings.selectFile")),e=$('<div class="red-ui-settings-row"></div>').appendTo(i),$('<label for=""></label>').text(RED._("sidebar.project.projectSettings.credentials")).appendTo(e),"flows_cred.json"),f=(a.files.credentials&&(b=0===a.files.flow.indexOf(o)?a.files.credentials.substring(o.length):a.files.credentials),$('<div class="uneditable-input" style="padding:0">').appendTo(e)),y=$('<span style="display:inline-block;padding: 6px 0 6px 6px">').text(o).appendTo(f),w=$('<span style="display:inline-block; padding: 6px 6px 6px 0">').text(b).appendTo(f),E=$('<input type="hidden">').val(b).insertAfter(f),D=function(){var e=m.val(),t=/^(.+?)(\.[^.]*)?$/.exec(e),t=(t?w.text(t[1]+"_cred"+(t[2]||".json")):""===e&&w.text(""),E.val(w.text()),""===e||/\.\./.test(e)||/\/$/.test(e)),e=t||""===w.text();S.is(":visible")&&(O.toggleClass("input-error",""===O.val()),e=e||""===O.val()),I.is(":visible")&&(N.toggleClass("input-error",""===N.val()),e=e||""===N.val()),m.toggleClass("input-error",t),M.toggleClass("disabled",e),M.prop("disabled",e)},R=(m.on("change keyup paste",D),e=$('<div class="red-ui-settings-row"></div>').appendTo(i),$("<label></label>").appendTo(e),$('<span><i class="user-settings-credentials-state-icon fa"></i> <span class="user-settings-credentials-state"></span></span>').appendTo(e)),x=$('<span class="button-group" style="margin-left: -72px;">').hide().appendTo(e),_=(R.css("color","#666"),x.css("vertical-align","top"),$('<button type="button" class="red-ui-button" style="vertical-align: top; width: 36px; margin-bottom: 10px"><i class="fa fa-trash-o"></i></button>').appendTo(x).on("click",function(e){e.preventDefault(),$(this).hasClass("selected")?($(this).removeClass("selected"),T.hide()):(N.val(""),S.hide(),I.show(),$(this).addClass("selected"),k.removeClass("selected"),L.show(),A.show(),C.hide(),j.hide(),T.show()),D()})),k=(RED.popover.tooltip(_,RED._("sidebar.project.projectSettings.resetTheEncryptionKey")),$('<button type="button" class="red-ui-button" style="border-top-right-radius: 4px; border-bottom-right-radius: 4px; vertical-align: top; width: 36px; margin-bottom: 10px"><i class="fa fa-pencil"></i></button>').appendTo(x).on("click",function(e){e.preventDefault(),$(this).hasClass("selected")?($(this).removeClass("selected"),T.hide()):(O.val(""),N.val(""),a.settings.credentialSecretInvalid||!a.settings.credentialsEncrypted?(C.show(),j.hide(),S.hide()):(S.show(),C.hide(),j.show()),I.show(),k.addClass("selected"),_.removeClass("selected"),L.hide(),A.hide(),T.show()),D()})),T=(RED.popover.tooltip(k,RED._("sidebar.project.projectSettings.changeTheEncryptionKey")),$('<div class="red-ui-settings-row red-ui-settings-row-credentials"></div>').hide().appendTo(i),$("<div>",{style:"margin-top:10px"}).hide().appendTo(R)),C=$('<div style="margin: 20px 0 10px 5px;">'+RED._("sidebar.project.projectSettings.setTheEncryptionKey")+"</div>").hide().appendTo(T),j=$('<div style="margin: 20px 0 10px 5px;">'+RED._("sidebar.project.projectSettings.changeTheEncryptionKey")+"</div>").hide().appendTo(T),L=$('<div style="margin: 20px 0 10px 5px;">'+RED._("sidebar.project.projectSettings.resetTheEncryptionKey")+"</div>").hide().appendTo(T),S=$('<div class="red-ui-settings-row red-ui-settings-row-credentials"></div>').appendTo(T),O=($('<label for=""></label>').text(RED._("sidebar.project.projectSettings.currentKey")).appendTo(S),$('<input type="text">').appendTo(S).typedInput({type:"cred"}).on("change keyup paste",function(){B&&(B.close(),B=null),D()})),I=$('<div class="red-ui-settings-row red-ui-settings-row-credentials"></div>').appendTo(T),N=($('<label for=""></label>').text(RED._("sidebar.project.projectSettings.newKey")).appendTo(I),$('<input type="text">').appendTo(I).typedInput({type:"cred"}).on("change keyup paste",D)),A=$('<div class="form-tips form-warning" style="margin: 10px;"><i class="fa fa-warning"></i>'+RED._("sidebar.project.projectSettings.credentialsAlert")+"</div>").hide().appendTo(T),P=$('<span class="button-row" style="position: relative; float: right; margin-right:0;"></span>').hide().appendTo(i),M=($('<button type="button" class="red-ui-button">'+RED._("common.label.cancel")+"</button>").appendTo(P).on("click",function(e){e.preventDefault();e=a.files.package||"package.json",e=e.substring(0,e.length-12);p.text(e),y.text(e),r.text(a.files.package||"package.json"),a.files.package?c.hide():(c.find(".red-ui-projects-edit-form-sublabel-text").text(RED._("sidebar.project.projectSettings.fileNotExist")),c.show()),m.val(h.text()),w.text(b),n()}),$('<button type="button" class="red-ui-button">'+RED._("common.label.save")+"</button>").appendTo(P).on("click",function(e){e.preventDefault();function t(e){o.remove(),e?G.reportUnexpectedError(e):(h.text(m.val()),w.text(E.val()),c.hide(),n())}var o=G.addSpinnerOverlay(i),e=(e=d.val()).substring(0,e.length-12),e={files:{package:d.val(),flow:e+m.val(),credentials:e+E.val()}};_.hasClass("selected")&&(e.resetCredentialSecret=!0),(_.hasClass("selected")||k.hasClass("selected"))&&(e.credentialSecret=N.val(),S.is(":visible")&&(e.currentCredentialSecret=O.val())),RED.deploy.setDeployInflight(!0),G.sendRequest({url:"projects/"+a.name,type:"PUT",responses:{0:function(e){t(e)},200:function(e){a=e,RED.sidebar.versionControl.refresh(!0),z(),t()},400:{credentials_load_failed:function(e){t(e)},missing_current_credential_key:function(e){O.addClass("input-error"),B=RED.popover.create({target:O,direction:"right",size:"small",content:"Incorrect key",autoClose:3e3}).open(),t(e)},"*":function(e){t(e)}}}},e).always(function(){setTimeout(function(){RED.deploy.setDeployInflight(!1)},500)})})),z=function(){a.settings.credentialSecretInvalid?(R.find(".user-settings-credentials-state-icon").removeClass().addClass("user-settings-credentials-state-icon fa fa-warning"),R.find(".user-settings-credentials-state").text(RED._("sidebar.project.projectSettings.invalidEncryptionKey"))):a.settings.credentialsEncrypted?(R.find(".user-settings-credentials-state-icon").removeClass().addClass("user-settings-credentials-state-icon fa fa-lock"),R.find(".user-settings-credentials-state").text(RED._("sidebar.project.projectSettings.encryptionEnabled"))):(R.find(".user-settings-credentials-state-icon").removeClass().addClass("user-settings-credentials-state-icon fa fa-unlock"),R.find(".user-settings-credentials-state").text(RED._("sidebar.project.projectSettings.encryptionDisabled"))),_.toggleClass("disabled",!a.settings.credentialSecretInvalid&&!a.settings.credentialsEncrypted),_.prop("disabled",!a.settings.credentialSecretInvalid&&!a.settings.credentialsEncrypted)};D(),z()}function p(a,e){function n(){o.attr("disabled",!1),c.hide(),g.val(""),m.val(""),i&&(i.close(),i=null)}$("<h3></h3>").text(RED._("sidebar.project.projectSettings.versionControl")).appendTo(e),s=a,t=e,t=$('<div class="red-ui-settings-section"></div>').appendTo(t),$("<h4></h4>").text(RED._("sidebar.project.projectSettings.branches")).appendTo(t),t=$('<div class="red-ui-settings-row red-ui-projects-dialog-list"></div>').appendTo(t),r=$("<ol>").appendTo(t).editableList({height:"auto",addButton:!1,scrollOnAdd:!1,addItem:function(i,e,a){var t,o,n=$('<div class="red-ui-projects-dialog-list-entry">').appendTo(i);a.empty?(n.addClass("red-ui-search-empty"),n.text(RED._("sidebar.project.projectSettings.noBranches"))):(a.current&&n.addClass("current"),$('<span class="entry-icon"><i class="fa fa-code-fork"></i></span>').appendTo(n),o=$("<span>").appendTo(n),t=$("<div>").appendTo(o),$('<span class="entry-name">').text(a.name).appendTo(t),a.commit&&$('<span class="entry-detail">').text(a.commit.sha).appendTo(t),a.remote&&(t=$("<div>").appendTo(o),$('<span class="entry-detail entry-remote-name">').text(a.remote||"").appendTo(t),0<a.status.ahead+a.status.behind&&$('<span class="entry-detail"><i class="fa fa-long-arrow-up"></i> <span>'+a.status.ahead+'</span> <i class="fa fa-long-arrow-down"></i> <span>'+a.status.behind+"</span></span>").appendTo(t)),a.current||(o=$('<span class="entry-tools">').appendTo(n),$('<button class="red-ui-button red-ui-button-small"><i class="fa fa-trash"></i></button>').appendTo(o).on("click",function(e){e.preventDefault();var o=G.addSpinnerOverlay(i).addClass("red-ui-component-spinner-contain"),n=RED.notify(RED._("sidebar.project.projectSettings.deleteConfirm",{name:a.name}),{type:"warning",modal:!0,fixed:!0,buttons:[{text:RED._("common.label.cancel"),click:function(){o.remove(),n.close()}},{text:"Delete branch",click:function(){n.close();var t={url:"projects/"+s.name+"/branches/"+a.name,type:"DELETE",responses:{200:function(e){i.fadeOut(200,function(){r.editableList("removeItem",a),o.remove()})},400:{git_delete_branch_unmerged:function(e){n=RED.notify(RED._("sidebar.project.projectSettings.unmergedConfirm",{name:a.name}),{type:"warning",modal:!0,fixed:!0,buttons:[{text:RED._("common.label.cancel"),click:function(){o.remove(),n.close()}},{text:RED._("sidebar.project.projectSettings.deleteUnmergedBranch"),click:function(){t.url+="?force=true",n.close(),G.sendRequest(t)}}]})},"*":function(e){G.reportUnexpectedError(e),o.remove()}}}};G.sendRequest(t)}}]})})))}}),$.getJSON("projects/"+s.name+"/branches",function(e){e.branches&&(0<e.branches.length?(e.branches.sort(function(e,t){return e.current?-1:t.current?1:e.name.localeCompare(t.name)}),e.branches.forEach(function(e){r.editableList("addItem",e)})):r.editableList("addItem",{empty:!0}))});var s,r,i,t=$('<div class="red-ui-settings-section"></div>').appendTo(e),e=$("<h4></h4>").text(RED._("sidebar.project.projectSettings.gitRemotes")).appendTo(t),o=$('<button class="red-ui-button red-ui-button-small" style="float: right; margin-right: 10px;">'+RED._("sidebar.project.projectSettings.addRemote")+"</button>").appendTo(e).on("click",function(e){o.attr("disabled",!0),c.slideDown(200,function(){c[0].scrollIntoView(),l?(g.val("origin"),m.trigger("focus")):g.trigger("focus"),p()})}),d={empty:!0},l=!0,e=$('<div class="red-ui-settings-row"></div>').appendTo(t),c=$('<div class="red-ui-projects-dialog-list-dialog"></div>').hide().appendTo(e),e=$('<div class="red-ui-settings-row red-ui-projects-dialog-list"></div>').appendTo(t),u=$("<ol>").appendTo(e),p=(u.editableList({addButton:!1,height:"auto",addItem:function(n,e,i){var t,o=$('<div class="red-ui-projects-dialog-list-entry">').appendTo(n);i.empty?(o.addClass("red-ui-search-empty"),o.text(RED._("sidebar.project.projectSettings.noRemotes"))):($('<span class="entry-icon"><i class="fa fa-globe"></i></span>').appendTo(o),t=$("<span>").appendTo(o),$('<div class="entry-name">').text(i.name).appendTo(t),i.urls.fetch===i.urls.push?$('<div class="entry-detail">').text(i.urls.fetch).appendTo(t):($('<div class="entry-detail">').text("fetch: "+i.urls.fetch).appendTo(t),$('<div class="entry-detail">').text("push: "+i.urls.push).appendTo(t)),t=$('<span class="entry-tools">').appendTo(o),$('<button class="red-ui-button red-ui-button-small"><i class="fa fa-trash"></i></button>').appendTo(t).on("click",function(e){e.preventDefault();var t=G.addSpinnerOverlay(n).addClass("red-ui-component-spinner-contain"),o=RED.notify(RED._("sidebar.project.projectSettings.deleteRemoteConfrim",{name:i.name}),{type:"warning",modal:!0,fixed:!0,buttons:[{text:RED._("common.label.cancel"),click:function(){t.remove(),o.close()}},{text:RED._("sidebar.project.projectSettings.deleteRemote"),click:function(){o.close(),a.git.branches.remote&&0===a.git.branches.remote.indexOf(i.name+"/")&&delete a.git.branches.remote,a.git.branches.remoteAlt&&0===a.git.branches.remoteAlt.indexOf(i.name+"/")&&delete a.git.branches.remoteAlt;var e="projects/"+a.name+"/remotes/"+i.name;G.sendRequest({url:e,type:"DELETE",responses:{200:function(e){n.fadeOut(200,function(){u.editableList("removeItem",i),setTimeout(t.remove,100),0===e.remotes.length?(delete a.git.remotes,l=!0,u.editableList("addItem",d)):(a.git.remotes={},e.remotes.forEach(function(e){var t=e.name;delete e.name,a.git.remotes[t]=e})),delete a.git.branches.remoteAlt,RED.sidebar.versionControl.refresh()})},400:{"*":function(e){G.reportUnexpectedError(e),t.remove()}}}})}}]})}))}}),function(){var e=/^[a-zA-Z0-9\-_]+$/.test(g.val()),t=m.val(),o=0<t.length&&!/\s/.test(t);/^https?:\/\/[^/]+@/i.test(t)?(v.text(RED._("sidebar.project.projectSettings.urlRule2")),o=!1):v.text(RED._("sidebar.project.projectSettings.urlRule")),b.attr("disabled",!e||!o),g.toggleClass("input-error",f&&!e),m.toggleClass("input-error",h&&!o),i&&(i.close(),i=null)}),f=!1,h=!1,g=($('<div class="red-ui-projects-dialog-list-dialog-header">').text(RED._("sidebar.project.projectSettings.addRemote2")).appendTo(c),e=$('<div class="red-ui-settings-row"></div>').appendTo(c),$('<label for=""></label>').text(RED._("sidebar.project.projectSettings.remoteName")).appendTo(e),$('<input type="text">').appendTo(e).on("change keyup paste",function(){f=!0,p()})),m=($('<label class="red-ui-projects-edit-form-sublabel"><small>'+RED._("sidebar.project.projectSettings.nameRule")+"</small></label>").appendTo(e).find("small"),e=$('<div class="red-ui-settings-row"></div>').appendTo(c),$('<label for=""></label>').text(RED._("sidebar.project.projectSettings.url")).appendTo(e),$('<input type="text">').appendTo(e).on("change keyup paste",function(){h=!0,p()})),v=$('<label class="red-ui-projects-edit-form-sublabel"><small>'+RED._("sidebar.project.projectSettings.urlRule")+"</small></label>").appendTo(e).find("small"),t=$('<span class="button-row" style="position: relative; float: right; margin: 10px;"></span>').appendTo(c),b=($('<button class="red-ui-button">'+RED._("common.label.cancel")+"</button>").appendTo(t).on("click",function(e){e.preventDefault(),n()}),$('<button class="red-ui-button">'+RED._("sidebar.project.projectSettings.addRemote2")+"</button>").appendTo(t).on("click",function(e){e.preventDefault();function t(e){o.remove(),e||n()}var o=G.addSpinnerOverlay(c).addClass("red-ui-component-spinner-contain"),e={name:g.val(),url:m.val()};RED.deploy.setDeployInflight(!0),G.sendRequest({url:"projects/"+a.name+"/remotes",type:"POST",responses:{0:function(e){t(e)},200:function(e){a.git.remotes={},e.remotes.forEach(function(e){var t=e.name;delete e.name,a.git.remotes[t]=e}),y(),RED.sidebar.versionControl.refresh(),t()},400:{git_remote_already_exists:function(e){i=RED.popover.create({target:g,direction:"right",size:"small",content:"Remote already exists",autoClose:6e3}).open(),g.addClass("input-error"),t(e)},"*":function(e){G.reportUnexpectedError(e),t(e)}}}},e)})),y=function(){u.editableList("empty");var e=0;if(a.git.hasOwnProperty("remotes"))for(var t in a.git.remotes)a.git.remotes.hasOwnProperty(t)&&(e++,u.editableList("addItem",{name:t,urls:a.git.remotes[t]}));(l=0===e)&&u.editableList("addItem",d)};y()}function m(e){var t=$('<div id="red-ui-project-settings-tab-settings" class="red-ui-project-settings-tab-pane red-ui-help"></div>');return u(e,t),p(e,t),t}function v(e){/^subflow:/.test(e.type)||"node-red"!==(e=RED.nodes.registry.getNodeSetForType(e.type).module)&&(b.hasOwnProperty(e)||(b[e]={module:e,version:RED.nodes.registry.getModule(e).version,count:0,known:!1}),b[e].count++)}var b={};return{init:function(e){G=e,n({id:"main",title:RED._("sidebar.project.name"),get:i,close:function(){}}),n({id:"deps",title:RED._("sidebar.project.dependencies"),get:a,close:function(){}}),n({id:"settings",title:RED._("sidebar.project.settings"),get:m,close:function(){B&&(B.close(),B=null)}}),RED.events.on("nodes:add",v),RED.events.on("nodes:remove",function(e){/^subflow:/.test(e.type)||"node-red"!==(e=RED.nodes.registry.getNodeSetForType(e.type).module)&&b.hasOwnProperty(e)&&(b[e].count--,0!==b[e].count||b[e].known||delete b[e])})},show:function(a){var e;o||(RED.user.hasPermission("projects.write")?(o=!0,e={title:RED._("sidebar.project.projectSettings.title"),buttons:[{id:"node-dialog-ok",text:RED._("common.label.close"),class:"primary",click:function(){RED.tray.close()}}],resize:function(e){t=e.width},open:function(e){var t=RED.projects.getActiveProject(),e=e.find(".red-ui-tray-body"),e=$("<div></div>").appendTo(e),o=$("<div></div>",{class:"red-ui-settings-tabs-container"}).appendTo(e),n=($("<ul></ul>",{id:"user-settings-tabs"}).appendTo(o),RED.tabs.create({id:"user-settings-tabs",vertical:!0,onchange:function(e){setTimeout(function(){i.children().hide(),$("#"+e.id).show(),e.pane.focus&&e.pane.focus()},50)}})),i=$("<div></div>",{class:"red-ui-settings-tabs-content"}).appendTo(e);s.forEach(function(e){n.addTab({id:"red-ui-project-settings-tab-"+e.id,label:e.title,pane:e}),e.get(t).hide().appendTo(i)}),e.i18n(),n.activateTab("red-ui-project-settings-tab-"+(a||"main")),$("#red-ui-sidebar-shade").show()},close:function(){o=!1,s.forEach(function(e){e.close&&e.close()}),$("#red-ui-sidebar-shade").hide()},show:function(){}},null!==t&&(e.width=t),RED.tray.show(e)):RED.notify(RED._("user.errors.notAuthorized"),"error"))},switchProject:function(e){b={}}}}(),RED.projects.userSettings=function(){var a,v,b;function s(e){$("<h3></h3>").text(RED._("editor:sidebar.project.userSettings.sshKeys")).appendTo(e);function t(){var e=/^[a-zA-Z0-9\-_]+$/.test(c.val()),t=(c.toggleClass("input-error",l&&!e),u.val()),o=0===t.length||8<=t.length;u.toggleClass("input-error",!o),o?0===t.length?p.text(RED._("editor:sidebar.project.userSettings.optional")):p.text(""):p.text(RED._("editor:sidebar.project.userSettings.passphraseShort")),f.attr("disabled",!(e=e&&o)),n&&(n.close(),n=null)}function i(){a.attr("disabled",!1),s.hide(),c.val(""),l=!1,u.val(""),n&&(n.close(),n=null)}function r(e,t){var e=$('<div class="red-ui-projects-dialog-ssh-public-key">',{style:"position:relative"}).appendTo(e),o=$("<pre>",{style:"min-height: 80px"}).appendTo(e),n=b.addSpinnerOverlay(o).addClass("red-ui-component-spinner-contain"),t={url:"settings/user/keys/"+t.name,type:"GET",responses:{200:function(e){o.text(e.publickey),n.remove()},400:{unexpected_error:function(e){console.log(e),n.remove()}}}},t=(b.sendRequest(t),$('<span class="button-row" style="position: relative; float: right; margin: 10px;"></span>').appendTo(e));return $('<button class="red-ui-button red-ui-button-small">'+RED._("editor:sidebar.project.userSettings.copyPublicKey")+"</button>").appendTo(t).on("click",function(e){try{e.stopPropagation(),e.preventDefault(),document.getSelection().selectAllChildren(o[0]);document.execCommand("copy");document.getSelection().empty()}catch(e){}}),e}var n,e=$('<div class="red-ui-settings-section"></div>').appendTo(e),o=$('<div class="red-ui-settings-section-description"></div>').appendTo(e).text(RED._("editor:sidebar.project.userSettings.sshKeysTip")),a=$('<button id="user-settings-gitconfig-add-key" class="red-ui-button red-ui-button-small" style="float: right; margin-right: 10px;">'+RED._("editor:sidebar.project.userSettings.add")+"</button>").appendTo(o).on("click",function(e){a.attr("disabled",!0),f.attr("disabled",!0),s.slideDown(200),c.trigger("focus")}),o=$('<div class="red-ui-settings-row"></div>').appendTo(e),s=$('<div class="red-ui-projects-dialog-list-dialog"></div>').hide().appendTo(o),d=($('<div class="red-ui-projects-dialog-list-dialog-header">').text(RED._("editor:sidebar.project.userSettings.addSshKey")).appendTo(s),$("<div>").appendTo(s)),o=$('<div class="red-ui-settings-row"></div>').appendTo(d),l=($('<div class="red-ui-settings-section-description"></div>').appendTo(o).text(RED._("editor:sidebar.project.userSettings.addSshKeyTip")),o=$('<div class="red-ui-settings-row"></div>').appendTo(d),$('<label for=""></label>').text(RED._("editor:sidebar.project.userSettings.name")).appendTo(o),!1),c=$('<input type="text">').appendTo(o).on("change keyup paste",function(){l=!0,t()}),d=($('<label class="red-ui-projects-edit-form-sublabel"><small>'+RED._("editor:sidebar.project.userSettings.nameRule")+"</small></label>").appendTo(o).find("small"),$("<div>").appendTo(d)),u=(o=$('<div class="red-ui-settings-row"></div>').appendTo(d),$('<label for=""></label>').text(RED._("editor:sidebar.project.userSettings.passphrase")).appendTo(o),$('<input type="password">').appendTo(o).on("change keyup paste",t)),p=$('<label class="red-ui-projects-edit-form-sublabel"><small>'+RED._("editor:sidebar.project.userSettings.optional")+"</small></label>").appendTo(o).find("small"),d=$('<span class="button-row" style="position: relative; float: right; margin: 10px;"></span>').appendTo(s),f=($('<button class="red-ui-button">'+RED._("editor:sidebar.project.userSettings.cancel")+"</button>").appendTo(d).on("click",function(e){e.preventDefault(),i()}),$('<button class="red-ui-button">'+RED._("editor:sidebar.project.userSettings.generate")+"</button>").appendTo(d).on("click",function(e){e.preventDefault();function t(e){o.remove(),e||i()}var o=b.addSpinnerOverlay(s).addClass("red-ui-component-spinner-contain"),n={name:c.val(),type:"generate"};n.comment=v.val(),n.password=u.val(),n.size=4096;RED.deploy.setDeployInflight(!0),b.sendRequest({url:"settings/user/keys",type:"POST",responses:{0:function(e){t(e)},200:function(e){m(n.name),t()},400:{unexpected_error:function(e){console.log(e),t(e)}}}},n)})),h=(o=$('<div class="red-ui-settings-row red-ui-projects-dialog-list"></div>').appendTo(e),{empty:!0}),g=$('<ol class="red-ui-projects-dialog-ssh-key-list">').appendTo(o).editableList({height:"auto",addButton:!1,scrollOnAdd:!1,addItem:function(n,e,i){var t,o,a,s=$('<div class="red-ui-projects-dialog-list-entry">').appendTo(n);i.empty?(s.addClass("red-ui-search-empty"),s.text(RED._("editor:sidebar.project.userSettings.noSshKeys"))):(t=$('<div class="red-ui-projects-dialog-ssh-key-header">').appendTo(s),$('<span class="entry-icon"><i class="fa fa-key"></i></span>').appendTo(t),$('<span class="entry-name">').text(i.name).appendTo(t),o=$('<span class="button-row entry-tools">').appendTo(t),t.on("click",function(e){a?a.slideUp(200,function(){a.remove(),a=null}):a=r(s,i)}),i.system||$('<button class="red-ui-button red-ui-button-small"><i class="fa fa-trash"></i></button>').appendTo(o).on("click",function(e){e.stopPropagation();var t=b.addSpinnerOverlay(n).addClass("red-ui-component-spinner-contain"),o=RED.notify(RED._("editor:sidebar.project.userSettings.deleteConfirm",{name:i.name}),{type:"warning",modal:!0,fixed:!0,buttons:[{text:RED._("common.label.cancel"),click:function(){t.remove(),o.close()}},{text:RED._("editor:sidebar.project.userSettings.delete"),click:function(){o.close();var e="settings/user/keys/"+i.name;b.sendRequest({url:e,type:"DELETE",responses:{200:function(e){n.fadeOut(200,function(){g.editableList("removeItem",i),setTimeout(t.remove,100),0===g.editableList("length")&&g.editableList("addItem",h)})},400:{unexpected_error:function(e){console.log(e),t.remove()}}}})}}]})}),i.expand&&(a=r(s,i)))}}),m=function(t){$.getJSON("settings/user/keys",function(e){e.keys&&(e.keys.sort(function(e,t){return e.name.localeCompare(t.name)}),g.editableList("empty"),e.keys.forEach(function(e){e.name===t&&(e.expand=!0),g.editableList("addItem",e)}),0===g.editableList("length")&&g.editableList("addItem",h))})};m()}function t(e){var t,o,n,i=$('<div id="red-ui-settings-tab-gitconfig" class="project-settings-tab-pane red-ui-help"></div>');return t=i,(n=RED.settings.get("git")||{}).user=n.user||{},$("<h3></h3>").text(RED._("editor:sidebar.project.userSettings.committerDetail")).appendTo(t),t=$('<div class="red-ui-settings-section"></div>').appendTo(t),$('<div class="red-ui-settings-section-description"></div>').appendTo(t).text(RED._("editor:sidebar.project.userSettings.committerTip")),o=$('<div class="red-ui-settings-row"></div>').appendTo(t),$('<label for="user-settings-gitconfig-username"></label>').text(RED._("editor:sidebar.project.userSettings.userName")).appendTo(o),(a=$('<input type="text" id="user-settings-gitconfig-username">').appendTo(o)).val(n.user.name||""),o=$('<div class="red-ui-settings-row"></div>').appendTo(t),$('<label for="user-settings-gitconfig-email"></label>').text(RED._("editor:sidebar.project.userSettings.email")).appendTo(o),(v=$('<input type="text" id="user-settings-gitconfig-email">').appendTo(o)).val(n.user.email||""),t=i,o=RED.settings.theme("projects.workflow.mode","manual"),(n=RED.settings.get("git")||{}).workflow=n.workflow||{},n.workflow.mode=n.workflow.mode||o,$("<h3></h3>").text(RED._("editor:sidebar.project.userSettings.workflow")).appendTo(t),o=$('<div class="red-ui-settings-section"></div>').appendTo(t),$('<div class="red-ui-settings-section-description"></div>').appendTo(o).text(RED._("editor:sidebar.project.userSettings.workfowTip")),t=$('<div class="red-ui-settings-row"></div>').appendTo(o),$('<label><input type="radio" name="user-setting-gitworkflow" value="manual"> <div style="margin-left: 3px; display: inline-block"><div data-i18n="editor:sidebar.project.userSettings.workflowManual"></div><div style="color:#aaa;" data-i18n="editor:sidebar.project.userSettings.workflowManualTip"></div></div></label>').appendTo(t),t=$('<div class="red-ui-settings-row"></div>').appendTo(o),$('<label><input type="radio" name="user-setting-gitworkflow" value="auto"> <div style="margin-left: 3px; display: inline-block"><div data-i18n="editor:sidebar.project.userSettings.workflowAuto"></div><div style="color:#aaa;" data-i18n="editor:sidebar.project.userSettings.workflowAutoTip"></div></div></label>').appendTo(t),o.find('[name="user-setting-gitworkflow"][type="radio"][value="'+n.workflow.mode+'"]').prop("checked",!0),s(i),i}return{init:function(e){b=e,RED.userSettings.add({id:"gitconfig",title:RED._("editor:sidebar.project.userSettings.gitConfig"),get:t,close:function(){var e=RED.settings.get("git")||{};e.user=e.user||{},e.user.name=a.val(),e.user.email=v.val(),e.workflow=e.workflow||{},e.workflow.mode=$('[name="user-setting-gitworkflow"][type="radio"]:checked').val(),RED.settings.set("git",e)}})}}}(),RED.sidebar.versionControl=function(){var D,R,x,_,k,T,a,C,j,L,S,O,I,s,N,P,A,M={};function z(t,a,e,s){t.addClass("red-ui-sidebar-vc-change-entry");var n,i,r,o,d,l,c=$("<div>").appendTo(t);a.label?(t.addClass("red-ui-help-info-none"),c.text(a.label),a.button&&(c.css({display:"inline-block",maxWidth:"300px",textAlign:"left"}),l=$('<div style="float: right; margin: 5px; height: 50px;"></div>').appendTo(c),$('<button class="red-ui-button red-ui-button-small"></button>').text(a.button.label).appendTo(l).on("click",a.button.click))):(n=$('<i class=""></i>').appendTo(c),i=$('<a href="#">').appendTo(c).on("click",function(e){var o,n,i;e.preventDefault(),o=a,n=s,i=RED.projects.getActiveProject(),N.sendRequest({url:"projects/"+i.name+"/diff/"+("staged"===n?"index":"tree")+"/"+encodeURIComponent(o.file),type:"GET",responses:{0:function(e){console.log(e)},200:function(e){var t="unstaged"===n?RED._("sidebar.project.versionControl.unstagedChanges")+" : "+o.file:"staged"===n?RED._("sidebar.project.versionControl.stagedChanges")+" : "+o.file:RED._("sidebar.project.versionControl.resolveConflicts")+" : "+o.file,e={diff:e.diff,title:t,unmerged:"unmerged"===n,project:i};"unstaged"==n?(e.oldRevTitle=" "===o.indexStatus?RED._("sidebar.project.versionControl.head"):RED._("sidebar.project.versionControl.staged"),e.newRevTitle=RED._("sidebar.project.versionControl.unstaged"),e.oldRev=" "===o.indexStatus?"@":":0",e.newRev="_"):"staged"===n?(e.oldRevTitle=RED._("sidebar.project.versionControl.head"),e.newRevTitle=RED._("sidebar.project.versionControl.staged"),e.oldRev="@",e.newRev=":0"):(e.oldRevTitle=RED._("sidebar.project.versionControl.local"),e.newRevTitle=RED._("sidebar.project.versionControl.remote"),e.commonRev=":1",e.oldRev=":2",e.newRev=":3",e.onresolve=function(e){N.sendRequest({url:"projects/"+i.name+"/resolve/"+encodeURIComponent(o.file),type:"POST",responses:{0:function(e){console.log(e)},200:function(e){V(!0)},400:{unexpected_error:function(e){console.log(e)}}}},{resolutions:e.resolutions[o.file]})}),RED.diff.showUnifiedDiff(e)},400:{unexpected_error:function(e){console.log(e)}}}})}),r=$("<span>").appendTo(i),l=$('<div class="red-ui-sidebar-vc-change-entry-tools">').appendTo(t),"unstaged"===s&&(o=$('<span class="button-group" style="margin-right: 5px;"></span>').appendTo(l),d=$('<button class="red-ui-button red-ui-button-small"><i class="fa fa-reply"></i></button>').appendTo(o).on("click",function(e){e.preventDefault();var t=N.addSpinnerOverlay(c).addClass("red-ui-component-spinner-contain"),o=RED.notify(RED._("sidebar.project.versionControl.revert",{file:a.file}),{type:"warning",modal:!0,fixed:!0,buttons:[{text:RED._("common.label.cancel"),click:function(){t.remove(),o.close()}},{text:RED._("sidebar.project.versionControl.revertChanges"),click:function(){o.close();var e={url:"projects/"+RED.projects.getActiveProject().name+"/files/_/"+a.file,type:"DELETE",responses:{200:function(e){t.remove()},400:{unexpected_error:function(e){t.remove(),console.log(e)}}}};RED.deploy.setDeployInflight(!0),N.sendRequest(e).always(function(){setTimeout(function(){RED.deploy.setDeployInflight(!1)},500)})}}]})}),RED.popover.tooltip(d,RED._("sidebar.project.versionControl.revertChanges"))),o=$('<span class="button-group"></span>').appendTo(l),"unmerged"!==s&&(l=$('<button class="red-ui-button red-ui-button-small"><i class="fa fa-'+("unstaged"===s?"plus":"minus")+'"></i></button>').appendTo(o).on("click",function(e){e.preventDefault();e=RED.projects.getActiveProject();a.spinner=N.addSpinnerOverlay(t).addClass("projects-version-control-spinner-sidebar"),N.sendRequest({url:"projects/"+e.name+"/stage/"+encodeURIComponent(a.file),type:"unstaged"===s?"POST":"DELETE",responses:{0:function(e){console.log(e)},200:function(e){U(e)},400:{unexpected_error:function(e){console.log(e)}}}},{})}),RED.popover.tooltip(l,RED._("sidebar.project.versionControl."+("unstaged"===s?"stage":"unstage")+"Change"))),a["update"+("unstaged"===s?"Unstaged":"Staged")]=function(e,t){c.removeClass();var o="",o="A"===t?(c.addClass("red-ui-diff-state-added"),"fa-plus-square"):"?"===t?(c.addClass("red-ui-diff-state-unchanged"),"fa-question-circle-o"):"D"===t?(c.addClass("red-ui-diff-state-deleted"),"fa-minus-square"):"M"===t?(c.addClass("red-ui-diff-state-changed"),"fa-square"):"R"===t?(c.addClass("red-ui-diff-state-changed"),"fa-toggle-right"):("U"===t&&c.addClass("red-ui-diff-state-conflicted"),"fa-exclamation-triangle");r.empty(),$("<span>").text(e.file.replace(/\\(.)/g,"$1")).appendTo(r),e.oldName&&($('<i class="fa fa-long-arrow-right"></i>').prependTo(r),$("<span>").text(e.oldName.replace(/\\(.)/g,"$1")).prependTo(r)),n.removeClass(),n.addClass("fa "+o),e.spinner&&(e.spinner.remove(),delete e.spinner),d&&d.toggle("?"!==t),i.toggleClass("disabled","D"===t||"?"===t)},a["update"+("unstaged"===s?"Unstaged":"Staged")](a,e))}function B(e){var t=Date.now()/1e3-e,o=Math.floor(t/86400);if(30<o)return new Date(1e3*e).toLocaleDateString();if(0<o)return RED._("sidebar.project.versionControl.daysAgo",{count:o});e=Math.floor(t/3600);if(0<e)return RED._("sidebar.project.versionControl.hoursAgo",{count:e});o=Math.floor(t/60);return 0<o?RED._("sidebar.project.versionControl.minsAgo",{count:o}):RED._("sidebar.project.versionControl.secondsAgo")}function G(e,t){var o=RED.projects.getActiveProject(),e=((a=t?N.addSpinnerOverlay(x.parent()):N.addSpinnerOverlay(k.parent())).addClass("red-ui-component-spinner-sidebar"),t?{files:e}:void 0);N.sendRequest({url:"projects/"+o.name+"/stage",type:t?"POST":"DELETE",responses:{0:function(e){console.log(e)},200:function(e){U(e)},400:{unexpected_error:function(e){console.log(e)}}}},e)}var i=!1;function F(n,i,e,a,t){var s=N.addSpinnerOverlay(e),e=n+"?limit="+(a||20);t&&(e+="&before="+t),N.sendRequest({url:e,type:"GET",responses:{0:function(e){console.log(e)},200:function(e){e.commits.forEach(function(e){i.editableList("addItem",e),t=e.sha}),i.loadMoreItem&&(i.editableList("removeItem",i.loadMoreItem),delete i.loadMoreItem);var t,o=i.editableList("length");o<e.total&&(i.loadMoreItem={totalKnown:o,total:e.total,url:n,before:t+"~1",limit:a},i.editableList("addItem",i.loadMoreItem)),s.remove()},400:{unexpected_error:function(e){console.log(e)}}}})}function U(e){var n=e.files,e=(a&&(a.remove(),a=null),(s=!!e.merging)?(D.addClass("red-ui-sidebar-vc-merging"),C.show()):(D.removeClass("red-ui-sidebar-vc-merging"),C.hide()),x.editableList("removeItem",P),k.editableList("removeItem",P),j.editableList("removeItem",A),Object.keys(n).filter(function(e){return"f"===n[e].type})),i=(e.sort(),Date.now()+Math.floor(100*Math.random())),e=(e.forEach(function(e){var t=n[e],o=!1;t.status&&(t.file=e,t.indexStatus=t.status[0],t.treeStatus=t.status[1],("A"===t.indexStatus&&/[AU]/.test(t.treeStatus)||"U"===t.indexStatus&&/[DAU]/.test(t.treeStatus)||"D"===t.indexStatus&&/[DU]/.test(t.treeStatus))&&(t.unmerged=!0),M[e]?(M[e].unmerged&&!t.unmerged?(j.editableList("removeItem",M[e]),o=!0):!M[e].unmerged&&t.unmerged&&(x.editableList("removeItem",M[e]),k.editableList("removeItem",M[e])),M[e].status!==t.status&&(" "!==M[e].treeStatus?" "===t.treeStatus?x.editableList("removeItem",M[e]):t.treeStatus!==M[e].treeStatus&&M[e].updateUnstaged(t,t.treeStatus):o=!0," "!==M[e].indexStatus&&"?"!==M[e].indexStatus?" "===t.indexStatus||"?"===t.indexStatus?k.editableList("removeItem",M[e]):t.indexStatus!==M[e].indexStatus&&M[e].updateStaged(t,t.indexStatus):o=!0),M[e].status=t.status,M[e].indexStatus=t.indexStatus,M[e].treeStatus=t.treeStatus,M[e].oldName=t.oldName,M[e].unmerged=t.unmerged):(o=!0,M[e]=t),M[e].updateIndex=i,o&&(t.unmerged?j.editableList("addItem",M[e]):(" "!==t.treeStatus&&x.editableList("addItem",M[e])," "!==t.indexStatus&&"?"!==t.indexStatus&&k.editableList("addItem",M[e]))))}),Object.keys(M).forEach(function(e){M[e].updateIndex!==i&&(x.editableList("removeItem",M[e]),k.editableList("removeItem",M[e]),delete M[e])}),k.editableList("length")),t=x.editableList("length"),o=j.editableList("length");L.prop("disabled",s&&0<o||!s&&0===e),_.prop("disabled",0===t),T.prop("disabled",0===e),0===e&&k.editableList("addItem",P),0===t&&x.editableList("addItem",P),0===o&&j.editableList("addItem",A)}function V(e,t){var n;i||(e&&(M={},x.editableList("empty"),k.editableList("empty"),j.editableList("empty")),RED.user.hasPermission("projects.write")&&(i=!0,O.editableList("empty"),(e=RED.projects.getActiveProject())&&F("projects/"+e.name+"/commits",O,O.parent()),(n=RED.projects.getActiveProject())?(e="projects/"+n.name+"/status",t&&(e+="?remote=true"),$.getJSON(e,function(e){U(e),$("#red-ui-sidebar-vc-local-branch").text(e.branches.local),$("#red-ui-sidebar-vc-remote-branch").text(e.branches.remote||RED._("sidebar.project.versionControl.none"));var t=e.commits.ahead||0,o=e.commits.behind||0;n.git.hasOwnProperty("remotes")?e.branches.hasOwnProperty("remoteError")&&"git_remote_gone"!==e.branches.remoteError.code?($("#red-ui-sidebar-vc-repo-status-auth-issue").show(),$("#red-ui-sidebar-vc-repo-status-stats").hide(),$("#red-ui-sidebar-vc-repo-branch").prop("disabled",!0),$("#red-ui-sidebar-vc-repo-pull").prop("disabled",!0),$("#red-ui-sidebar-vc-repo-push").prop("disabled",!0),$("#red-ui-sidebar-vc-repo-toolbar-message").hide(),$("#red-ui-sidebar-vc-repo-toolbar-error-message").show()):($("#red-ui-sidebar-vc-repo-toolbar-message").show(),$("#red-ui-sidebar-vc-repo-toolbar-error-message").hide(),$("#red-ui-sidebar-vc-repo-status-auth-issue").hide(),$("#red-ui-sidebar-vc-repo-status-stats").show(),$("#red-ui-sidebar-vc-repo-branch").prop("disabled",!1),$("#red-ui-sidebar-vc-repo-status-button").show(),e.branches.hasOwnProperty("remote")?J(t,o):($("#red-ui-sidebar-vc-commits-ahead").text(""),$("#red-ui-sidebar-vc-commits-behind").text(""),$("#red-ui-sidebar-vc-repo-toolbar-message").text(RED._("sidebar.project.versionControl.notTracking")),$("#red-ui-sidebar-vc-repo-pull").prop("disabled",!0),$("#red-ui-sidebar-vc-repo-push").prop("disabled",!0))):$("#red-ui-sidebar-vc-repo-status-button").hide(),i=!1,$(".red-ui-sidebar-vc-shade").hide()}).fail(function(){i=!1})):($(".red-ui-sidebar-vc-shade").show(),x.editableList("empty"),k.editableList("empty"),j.editableList("empty"))))}function J(e,t){$("#red-ui-sidebar-vc-commits-ahead").text(e),$("#red-ui-sidebar-vc-commits-behind").text(t),s?($("#red-ui-sidebar-vc-repo-toolbar-message").text(RED._("sidebar.project.versionControl.statusUnmergedChanged")),$("#red-ui-sidebar-vc-repo-pull").prop("disabled",!0),$("#red-ui-sidebar-vc-repo-push").prop("disabled",!0)):0<e&&0===t?($("#red-ui-sidebar-vc-repo-toolbar-message").text(RED._("sidebar.project.versionControl.commitsAhead",{count:e})),$("#red-ui-sidebar-vc-repo-pull").prop("disabled",!0),$("#red-ui-sidebar-vc-repo-push").prop("disabled",!1)):0===e&&0<t?($("#red-ui-sidebar-vc-repo-toolbar-message").text(RED._("sidebar.project.versionControl.commitsBehind",{count:t})),$("#red-ui-sidebar-vc-repo-pull").prop("disabled",!1),$("#red-ui-sidebar-vc-repo-push").prop("disabled",!0)):0<e&&0<t?($("#red-ui-sidebar-vc-repo-toolbar-message").text(RED._("sidebar.project.versionControl.commitsAheadAndBehind1",{count:t})+RED._("sidebar.project.versionControl.commitsAheadAndBehind2",{count:e})+RED._("sidebar.project.versionControl.commitsAheadAndBehind3",{count:t})),$("#red-ui-sidebar-vc-repo-pull").prop("disabled",!1),$("#red-ui-sidebar-vc-repo-push").prop("disabled",!0)):0===e&&0===t&&($("#red-ui-sidebar-vc-repo-toolbar-message").text(RED._("sidebar.project.versionControl.repositoryUpToDate")),$("#red-ui-sidebar-vc-repo-pull").prop("disabled",!0),$("#red-ui-sidebar-vc-repo-push").prop("disabled",!0))}function q(){V(),RED.sidebar.show("version-control")}return{init:function(e){function i(o){o=o||{};var e=N.addSpinnerOverlay(m).addClass("red-ui-component-spinner-contain"),t=$('<div style="position: relative; bottom: 60px;"></div>').appendTo(e),n=($('<button class="red-ui-button"></button>').text(RED._("eventLog.view")).appendTo(t).on("click",function(e){e.preventDefault(),RED.actions.invoke("core:show-event-log")}),RED.projects.getActiveProject()),t=(RED.eventLog.startEvent("Pull changes"+(n.git.branches.remoteAlt?" : "+n.git.branches.remoteAlt:"")),"projects/"+n.name+"/pull");n.git.branches.remoteAlt&&(t+="/"+n.git.branches.remoteAlt),(o.setUpstream||o.allowUnrelatedHistories)&&(t+="?"),o.setUpstream&&(t+="setUpstream=true",o.allowUnrelatedHistories&&(t+="&")),o.allowUnrelatedHistories&&(t+="allowUnrelatedHistories=true"),N.sendRequest({url:t,type:"POST",responses:{0:function(e){console.log(e)},200:function(e){o.setUpstream&&n.git.branches.remoteAlt&&(n.git.branches.remote=n.git.branches.remoteAlt,delete n.git.branches.remoteAlt),V(!0),v()},400:{git_local_overwrite:function(e){RED.notify(RED._("sidebar.project.versionControl.unablePull")+'<p><a href="#" onclick="RED.sidebar.versionControl.showLocalChanges(); return false;">'+RED._("sidebar.project.versionControl.showUnstagedChanges")+"</a></p>","error",!1,1e7)},git_pull_merge_conflict:function(e){V(!0),v()},git_connection_failed:function(e){RED.notify(RED._("sidebar.project.versionControl.connectionFailed")+e.toString(),"warning")},git_pull_unrelated_history:function(e){var t=RED.notify(RED._("sidebar.project.versionControl.pullUnrelatedHistory"),{type:"error",modal:!0,fixed:!0,buttons:[{text:RED._("common.label.cancel"),click:function(){t.close()}},{text:RED._("sidebar.project.versionControl.pullChanges"),click:function(){t.close(),o.allowUnrelatedHistories=!0,i(o)}}]})},"*":function(e){N.reportUnexpectedError(e)}}}},{}).always(function(){e.remove()})}N=e,RED.actions.add("core:show-version-control-tab",q),RED.events.on("deploy",function(){var e,t=RED.projects.getActiveProject();t&&(e=RED.settings.theme("projects.workflow.mode","manual"),"auto"===(((RED.settings.get("git")||{}).workflow||{}).mode||e)?V(!0):(M={},x.editableList("empty"),k.editableList("empty"),j.editableList("empty"),$.getJSON("projects/"+t.name+"/status",function(e){U(e)})))}),RED.events.on("login",function(){V(!0)}),D=$("<div>",{class:"red-ui-sidebar-vc"});var e=$("<div>",{class:"red-ui-sidebar-vc-stack"}).appendTo(D),e=(R=RED.stack.create({container:e,fill:!0,singleExpanded:!0}),(S=R.add({title:RED._("sidebar.project.versionControl.localChanges"),collapsible:!0})).expand(),S.content.css({height:"100%"}),$('<div style="float: right"></div>').appendTo(S.header)),t=$('<button class="red-ui-button red-ui-button-small"><i class="fa fa-refresh"></i></button>').appendTo(e).on("click",function(e){e.preventDefault(),e.stopPropagation(),V(!0)}),o=(RED.popover.tooltip(t,RED._("sidebar.project.versionControl.refreshChanges")),P={label:RED._("sidebar.project.versionControl.none")},A={label:RED._("sidebar.project.versionControl.conflictResolve")},$('<div class="red-ui-sidebar-vc-change-container"></div>').appendTo(S.content)),n=$('<div class="red-ui-sidebar-vc-change-header">'+RED._("sidebar.project.versionControl.localFiles")+"</div>").appendTo(o),a=(_=$('<button class="red-ui-button red-ui-button-small" style="position: absolute; right: 5px; top: 5px;"><i class="fa fa-plus"></i> '+RED._("sidebar.project.versionControl.all")+"</button>").appendTo(n).on("click",function(e){e.preventDefault(),e.stopPropagation(),G(Object.keys(M).filter(function(e){return" "!==M[e].treeStatus}),!0)}),RED.popover.tooltip(_,RED._("sidebar.project.versionControl.stageAllChange")),(x=$("<ol>",{style:"position: absolute; top: 30px; bottom: 0; right:0; left:0;"}).appendTo(o)).editableList({addButton:!1,scrollOnAdd:!1,addItem:function(e,t,o){z(e,o,o.treeStatus,"unstaged")},sort:function(e,t){return"?"===e.treeStatus&&"?"!==t.treeStatus?1:"?"!==e.treeStatus&&"?"===t.treeStatus?-1:e.file.localeCompare(t.file)}}),C=$('<div class="red-ui-sidebar-vc-change-container"></div>').appendTo(S.content),n=$('<div class="red-ui-sidebar-vc-change-header">'+RED._("sidebar.project.versionControl.unmergedChanges")+"</div>").appendTo(C),e=$('<div style="position: absolute; right: 5px; top: 5px;"></div>').appendTo(n),$('<button class="red-ui-button red-ui-button-small" style="margin-right: 5px;">'+RED._("sidebar.project.versionControl.abortMerge")+"</button>").appendTo(e).on("click",function(e){e.preventDefault(),e.stopPropagation();var t=N.addSpinnerOverlay(C),e=RED.projects.getActiveProject();RED.deploy.setDeployInflight(!0),N.sendRequest({url:"projects/"+e.name+"/merge",type:"DELETE",responses:{0:function(e){console.log(e)},200:function(e){t.remove(),V(!0)},400:{unexpected_error:function(e){console.log(e)}}}}).always(function(){setTimeout(function(){RED.deploy.setDeployInflight(!1)},500)})})),s=((j=$("<ol>",{style:"position: absolute; top: 30px; bottom: 0; right:0; left:0;"}).appendTo(C)).editableList({addButton:!1,scrollOnAdd:!1,addItem:function(e,t,o){o===A&&(o.button={label:RED._("sidebar.project.versionControl.commit"),click:function(e){e.preventDefault(),e.stopPropagation(),r()}}),z(e,o,o.treeStatus,"unmerged")},sort:function(e,t){return"?"===e.treeStatus&&"?"!==t.treeStatus?1:"?"!==e.treeStatus&&"?"===t.treeStatus?-1:e.file.localeCompare(t.file)}}),$('<div class="red-ui-sidebar-vc-change-container"></div>').appendTo(S.content)),n=$('<div class="red-ui-sidebar-vc-change-header">'+RED._("sidebar.project.versionControl.changeToCommit")+"</div>").appendTo(s),e=$('<div style="position: absolute; right: 5px; top: 5px;"></div>').appendTo(n),r=function(){d.val(""),c.prop("disabled",!0),o.css("height","30px"),C.is(":visible")?(C.css("height","30px"),s.css("height","calc(100% - 60px - 175px)")):s.css("height","calc(100% - 30px - 175px)"),commitBox.show(),setTimeout(function(){commitBox.css("height","175px")},10),_.prop("disabled",!0),T.prop("disabled",!0),L.prop("disabled",!0),a.prop("disabled",!0),d.trigger("focus")},d=(L=$('<button class="red-ui-button red-ui-button-small" style="margin-right: 5px;">'+RED._("sidebar.project.versionControl.commit")+"</button>").appendTo(e).on("click",function(e){e.preventDefault(),e.stopPropagation(),r()}),RED.popover.tooltip(L,RED._("sidebar.project.versionControl.commitChanges")),T=$('<button class="red-ui-button red-ui-button-small"><i class="fa fa-minus"></i> '+RED._("sidebar.project.versionControl.all")+"</button>").appendTo(e).on("click",function(e){e.preventDefault(),e.stopPropagation(),G(Object.keys(M).filter(function(e){return" "!==M[e].indexStatus&&"?"!==M[e].indexStatus}),!1)}),RED.popover.tooltip(T,RED._("sidebar.project.versionControl.unstageAllChange")),(k=$("<ol>",{style:"position: absolute; top: 30px; bottom: 0; right:0; left:0;"}).appendTo(s)).editableList({addButton:!1,scrollOnAdd:!1,addItem:function(e,t,o){z(e,o,o.indexStatus,"staged")},sort:function(e,t){return e.file.localeCompare(t.file)}}),commitBox=$('<div class="red-ui-sidebar-vc-slide-box red-ui-sidebar-vc-slide-box-bottom"></div>').hide().appendTo(S.content),$("<textarea></textarea>").attr("placeholder",RED._("sidebar.project.versionControl.commitPlaceholder")).appendTo(commitBox).on("change keyup paste",function(){c.prop("disabled",""===$(this).val().trim())})),n=$('<div class="red-ui-sidebar-vc-slide-box-toolbar button-group">').appendTo(commitBox),l=$('<button class="red-ui-button">'+RED._("sidebar.project.versionControl.cancelCapital")+"</button>").appendTo(n).on("click",function(e){e.preventDefault(),d.val(""),o.css("height",""),C.css("height",""),s.css("height",""),commitBox.css("height",0),setTimeout(function(){commitBox.hide()},200),_.prop("disabled",!1),T.prop("disabled",!1),L.prop("disabled",!1),a.prop("disabled",!1)}),c=$('<button class="red-ui-button">'+RED._("sidebar.project.versionControl.commitCapital")+"</button>").appendTo(n).on("click",function(e){e.preventDefault();var t=N.addSpinnerOverlay(c).addClass("red-ui-component-spinner-sidebar"),e=RED.projects.getActiveProject();RED.deploy.setDeployInflight(!0),N.sendRequest({url:"projects/"+e.name+"/commit",type:"POST",responses:{0:function(e){console.log(e)},200:function(e){t.remove(),l.trigger("click"),V(!0)},400:{"*":function(e){N.reportUnexpectedError(e)}}}},{message:d.val()}).always(function(){setTimeout(function(){RED.deploy.setDeployInflight(!1)},500)})}),n=R.add({title:RED._("sidebar.project.versionControl.commitHistory"),collapsible:!0}),e=(e=$('<div style="float: right"></div>').appendTo(n.header),t=$('<button class="red-ui-button red-ui-button-small"><i class="fa fa-refresh"></i></button>').appendTo(e).on("click",function(e){e.preventDefault(),e.stopPropagation(),V(!0,!0)}),RED.popover.tooltip(t,RED._("sidebar.project.versionControl.refreshCommitHistory")),$('<div class="red-ui-sidebar-vc-change-header" style="text-align: right;"></div>').appendTo(n.content)),u=$('<button class="red-ui-button red-ui-button-small"><i class="fa fa-code-fork"></i> '+RED._("sidebar.project.versionControl.branch")+' <span id="red-ui-sidebar-vc-local-branch"></span></button>').appendTo(e).on("click",function(e){e.preventDefault(),$(this).hasClass("selected")?f():(v(),I.show(),$(this).addClass("selected"),e=RED.projects.getActiveProject(),g.refresh("projects/"+e.name+"/branches"),h.show(),setTimeout(function(){h.css("height","215px"),g.focus()},100))}),p=(RED.popover.tooltip(u,RED._("sidebar.project.versionControl.changeLocalBranch")),$('<button class="red-ui-button red-ui-button-small" style="margin-left: 10px;" id="red-ui-sidebar-vc-repo-status-button"><span id="red-ui-sidebar-vc-repo-status-stats"><i class="fa fa-long-arrow-up"></i> <span id="red-ui-sidebar-vc-commits-ahead"></span> <i class="fa fa-long-arrow-down"></i> <span id="red-ui-sidebar-vc-commits-behind"></span></span><span id="red-ui-sidebar-vc-repo-status-auth-issue"><i class="fa fa-warning"></i></span></button>').appendTo(e).on("click",function(e){e.preventDefault(),$(this).hasClass("selected")?v():(f(),I.show(),$(this).addClass("selected"),e=RED.projects.getActiveProject(),$("#red-ui-sidebar-vc-repo-toolbar-set-upstream-row").toggle(!!e.git.branches.remoteAlt),m.show(),setTimeout(function(){m.css("height","265px")},100))})),f=(RED.popover.tooltip(p,RED._("sidebar.project.versionControl.manageRemoteBranch")),O=$("<ol>",{style:"position: absolute; top: 30px; bottom: 0px; right:0; left:0;"}).appendTo(n.content),I=$('<div class="red-ui-shade" style="z-Index: 3"></div>').css("top","30px").hide().appendTo(n.content),O.editableList({addButton:!1,scrollOnAdd:!1,addItem:function(t,e,o){var n,i;t.addClass("red-ui-sidebar-vc-commit-entry"),o.url?(t.addClass("red-ui-sidebar-vc-commit-more"),t.text("+ "+(o.total-o.totalKnown)+RED._("sidebar.project.versionControl.moreCommits")),t.on("click",function(e){e.preventDefault(),F(o.url,O,t,o.limit,o.before)})):(t.on("click",function(e){var t=RED.projects.getActiveProject();t&&$.getJSON("projects/"+t.name+"/commits/"+o.sha,function(e){e.project=t,e.parents=o.parents,e.oldRev=o.sha+"~1",e.newRev=o.sha,e.oldRevTitle=RED._("sidebar.project.versionControl.commitCapital")+" "+o.sha.substring(0,7)+"~1",e.newRevTitle=RED._("sidebar.project.versionControl.commitCapital")+" "+o.sha.substring(0,7),e.date=B(parseInt(o.date)),RED.diff.showCommitDiff(e)})}),n=$("<div>").appendTo(t),$('<div class="red-ui-sidebar-vc-commit-subject">').text(o.subject).appendTo(n),o.refs&&(i=$('<div class="red-ui-sidebar-vc-commit-refs">').appendTo(n),o.refs.forEach(function(e){var t=e;/HEAD -> /.test(e)&&(t=e.substring(8)),$('<span class="red-ui-sidebar-vc-commit-ref">').text(t).appendTo(i)}),t.addClass("red-ui-sidebar-vc-commit-head")),$('<div class="red-ui-sidebar-vc-commit-sha">').text(o.sha.substring(0,7)).appendTo(n),$('<div class="red-ui-sidebar-vc-commit-date">').text(B(parseInt(o.date))).appendTo(n))}}),function(e){u.removeClass("selected"),h.css("height","0"),I.hide(),setTimeout(function(){h.hide(),e&&e()},200)}),h=$('<div class="red-ui-sidebar-vc-slide-box red-ui-sidebar-vc-slide-box-top" style="top:30px;"></div>').hide().appendTo(n.content),g=($('<div class="red-ui-sidebar-vc-slide-box-header"></div>').text(RED._("sidebar.project.versionControl.changeLocalBranch")).appendTo(h),N.createBranchList({placeholder:RED._("sidebar.project.versionControl.createBranchPlaceholder"),container:h,onselect:function(e){if(e.current)return f();var t=N.addSpinnerOverlay(h),o=RED.projects.getActiveProject();RED.deploy.setDeployInflight(!0),N.sendRequest({url:"projects/"+o.name+"/branches",type:"POST",requireCleanWorkspace:!0,cancel:function(){t.remove()},responses:{0:function(e){t.remove(),console.log(e)},200:function(e){f(function(){t.remove()})},400:{git_local_overwrite:function(e){t.remove(),RED.notify(RED._("sidebar.project.versionControl.localOverwrite"),{type:"error",timeout:8e3})},unexpected_error:function(e){t.remove(),console.log(e)}}}},e).always(function(){setTimeout(function(){RED.deploy.setDeployInflight(!1)},500)})}})),m=$('<div class="red-ui-sidebar-vc-slide-box red-ui-sidebar-vc-slide-box-top" style="top:30px"></div>').hide().appendTo(n.content),v=function(){$("#red-ui-sidebar-vc-repo-toolbar-set-upstream").prop("checked",!1),p.removeClass("selected"),m.css("height","0"),I.hide(),setTimeout(function(){m.hide(),b()},200)},b=function(e){y.hasClass("selected")&&(y.removeClass("selected"),w.height(0),m.css("height","265px"),setTimeout(function(){w.hide(),e&&e()},200))},t=($('<div class="red-ui-sidebar-vc-slide-box-header"></div>').text(RED._("sidebar.project.versionControl.manageRemoteBranch")).appendTo(m),$('<div style="margin-bottom: 5px;"></div>').appendTo(m)),y=$('<button id="red-ui-sidebar-vc-repo-branch" class="red-ui-sidebar-vc-repo-action red-ui-button"><i class="fa fa-code-fork"></i> '+RED._("sidebar.project.versionControl.remote")+': <span id="red-ui-sidebar-vc-remote-branch"></span></button>').appendTo(t).on("click",function(e){e.preventDefault(),$(this).hasClass("selected")?b():($(this).addClass("selected"),e=RED.projects.getActiveProject(),E.refresh("projects/"+e.name+"/branches/remote"),w.show(),setTimeout(function(){w.height(180),m.css("height","445px"),E.focus()},100))}),e=($('<div id="red-ui-sidebar-vc-repo-toolbar-message" class="red-ui-sidebar-vc-slide-box-header" style="min-height: 100px;"></div>').appendTo(m),$('<div id="red-ui-sidebar-vc-repo-toolbar-error-message" class="red-ui-sidebar-vc-slide-box-header" style="min-height: 100px;"></div>').hide().appendTo(m)),n=($('<div style="margin-top: 10px;"><i class="fa fa-warning"></i> '+RED._("sidebar.project.versionControl.unableToAccess")+"</div>").appendTo(e),$('<div style="margin: 10px 30px; text-align: center"></div>').appendTo(e)),w=($('<button class="red-ui-button" style="width: 80%;"><i class="fa fa-refresh"></i> '+RED._("sidebar.project.versionControl.retry")+"</button>").appendTo(n).on("click",function(e){e.preventDefault();var e=RED.projects.getActiveProject(),t=N.addSpinnerOverlay(m).addClass("red-ui-component-spinner-contain");N.sendRequest({url:"projects/"+e.name+"/branches/remote",type:"GET",responses:{0:function(e){console.log(e)},200:function(e){V(!0)},400:{git_connection_failed:function(e){RED.notify(e.message,"error")},git_not_a_repository:function(e){RED.notify(e.message,"error")},git_repository_not_found:function(e){RED.notify(e.message,"error")},unexpected_error:function(e){console.log(e)}}}}).always(function(){t.remove()})}),$('<div class="red-ui-sidebar-vc-slide-box-header" style="height: 20px;"><label id="red-ui-sidebar-vc-repo-toolbar-set-upstream-row" for="red-ui-sidebar-vc-repo-toolbar-set-upstream" class="hide"><input type="checkbox" id="red-ui-sidebar-vc-repo-toolbar-set-upstream"> '+RED._("sidebar.project.versionControl.setUpstreamBranch")+"</label></div>").appendTo(m),$('<div style="height: 0;overflow:hidden; transition: height 0.2s ease-in-out;"></div>').hide().appendTo(t)),E=N.createBranchList({placeholder:RED._("sidebar.project.versionControl.createRemoteBranchPlaceholder"),currentLabel:RED._("sidebar.project.versionControl.upstream"),remotes:function(){var e=RED.projects.getActiveProject();return Object.keys(e.git.remotes)},container:w,onselect:function(e){$("#red-ui-sidebar-vc-repo-toolbar-set-upstream").prop("checked",!1),$("#red-ui-sidebar-vc-repo-toolbar-set-upstream").prop("disabled",!1),$("#red-ui-sidebar-vc-remote-branch").text(e.name+(e.create?" *":""));var n=RED.projects.getActiveProject();n.git.branches.remote===e.name?delete n.git.branches.remoteAlt:n.git.branches.remoteAlt=e.name,$("#red-ui-sidebar-vc-repo-toolbar-set-upstream-row").toggle(!!n.git.branches.remoteAlt),b(function(){var t,o;e.create?(n.git.branches.remote?$("#red-ui-sidebar-vc-repo-toolbar-message").text(RED._("sidebar.project.versionControl.selectUpstreamBranch")):($("#red-ui-sidebar-vc-repo-toolbar-message").text(RED._("sidebar.project.versionControl.trackedUpstreamBranch")),$("#red-ui-sidebar-vc-repo-toolbar-set-upstream").prop("checked",!0),$("#red-ui-sidebar-vc-repo-toolbar-set-upstream").prop("disabled",!0)),$("#red-ui-sidebar-vc-repo-pull").prop("disabled",!0),$("#red-ui-sidebar-vc-repo-push").prop("disabled",!1)):(t=Date.now(),o=N.addSpinnerOverlay($("#red-ui-sidebar-vc-repo-toolbar-message")).addClass("red-ui-component-spinner-contain"),$.getJSON("projects/"+n.name+"/branches/remote/"+e.name+"/status",function(e){setTimeout(function(){J(e.commits.ahead,e.commits.behind),o.remove()},Math.max(400-(Date.now()-t),0))}))})}}),e=$('<div style="margin-bottom: 5px;"></div>').appendTo(m);$('<button id="red-ui-sidebar-vc-repo-push" class="red-ui-sidebar-vc-repo-sub-action red-ui-button"><i class="fa fa-long-arrow-up"></i> <span data-i18n="sidebar.project.versionControl.push"></span></button>').appendTo(e).on("click",function(e){e.preventDefault();var t=N.addSpinnerOverlay(m).addClass("red-ui-component-spinner-contain"),e=$('<div style="position: relative; bottom: 60px;"></div>').appendTo(t),o=($('<button class="red-ui-button"></button>').text(RED._("eventLog.view")).appendTo(e).on("click",function(e){e.preventDefault(),RED.actions.invoke("core:show-event-log")}),RED.projects.getActiveProject()),e=(RED.eventLog.startEvent("Push changes"+(o.git.branches.remoteAlt?" : "+o.git.branches.remoteAlt:"")),"projects/"+o.name+"/push"),n=(o.git.branches.remoteAlt&&(e+="/"+o.git.branches.remoteAlt),$("#red-ui-sidebar-vc-repo-toolbar-set-upstream").prop("checked"));n&&(e+="?u=true"),N.sendRequest({url:e,type:"POST",responses:{0:function(e){console.log(e)},200:function(e){n&&o.git.branches.remoteAlt&&(o.git.branches.remote=o.git.branches.remoteAlt,delete o.git.branches.remoteAlt),V(!0),v()},400:{git_push_failed:function(e){RED.notify(RED._("sidebar.project.versionControl.pushFailed"),"error")},unexpected_error:function(e){console.log(e)}}}},{}).always(function(){t.remove()})}),$('<button id="red-ui-sidebar-vc-repo-pull" class="red-ui-sidebar-vc-repo-sub-action red-ui-button"><i class="fa fa-long-arrow-down"></i> <span data-i18n="sidebar.project.versionControl.pull"></span></button>').appendTo(e).on("click",function(e){e.preventDefault(),i({setUpstream:$("#red-ui-sidebar-vc-repo-toolbar-set-upstream").prop("checked")})}),$('<div class="red-ui-shade red-ui-sidebar-vc-shade">').appendTo(D),RED.sidebar.addTab({id:"version-control",label:RED._("sidebar.project.versionControl.history"),name:RED._("sidebar.project.versionControl.projectHistory"),content:D,enableOnEdit:!1,pinned:!0,iconClass:"fa fa-code-fork",action:"core:show-version-control-tab",onchange:function(){setTimeout(function(){R.resize()},10)}})},show:q,refresh:V,showLocalChanges:function(){RED.sidebar.show("version-control"),S.expand()}}}(),RED.touch=RED.touch||{},RED.touch.radialMenu=function(){var p=null,f=!1,h=!1,g=null;return{show:function(e,a,t){f=!0;try{for(var n=(p=d3.select("body").append("div").classed("red-ui-editor-radial-menu",!0).on("touchstart",function(){u(),d3.event.preventDefault()})).append("div").style({top:a[1]-80+"px",left:a[0]-80+"px"}),s=[],o=t.length,i=Math.max(Math.PI/(o-1),Math.PI/4),r=Math.PI,d=0;d<o;d++){var l=Math.floor(80*Math.cos(r)),c=Math.floor(80*Math.sin(r));t[d].name&&!function(e,t,o){o.el=n.append("div").classed("red-ui-editor-radial-menu-opt",!0).style({top:t+80-25+"px",left:e+80-25+"px"}).classed("red-ui-editor-radial-menu-opt-disabled",!!o.disabled),o.el.html(o.name),o.x=e,o.y=t,s.push(o),o.el.on("touchstart",function(){o.el.classed("red-ui-editor-radial-menu-opt-active",!0),d3.event.preventDefault(),d3.event.stopPropagation()}),o.el.on("touchend",function(){u(),o.onselect(),d3.event.preventDefault(),d3.event.stopPropagation()})}(l,c,t[d]),r+=i}var u=function(){f=!1,g=null,p.remove(),p=null};e.on("touchend.radial",function(){if(e.on("touchend.radial",null),e.on("touchmenu.radial",null),g){try{g.onselect()}catch(e){RED._debug(e)}u()}else h&&u()}),e.on("touchmove.radial",function(){try{for(var e,t=d3.event.touches.item(0),o=[t.pageX-a[0],t.pageY-a[1]],n=0;n<s.length;n++){var i=s[n];i.disabled||(o[0]>i.x-30&&o[0]<i.x+30&&o[1]>i.y-30&&o[1]<i.y+30?i!==g&&(i.el.classed("selected",!0),g=i):(i===g&&(g=null),i.el.classed("selected",!1)))}g||(e=Math.abs(o[0]*o[0]+o[1]*o[1]),h=6400<e)}catch(e){RED._debug(e)}})}catch(e){RED._debug(e)}},active:function(){return f}}}(),RED.tourGuide=function(){var p,f,h,g,m,v,b=[],n={};function t(t,o){n[t]?o(null,n[t]):import(t).then(function(e){n[t]=e.default,o(null,n[t])}).catch(function(e){o(e)})}function y(){var e,t;m&&(v?f.css({left:$(window).width()/2+"px",top:$(window).height()/2+"px",width:"0px",height:"0px"}):(e=m[0].getBoundingClientRect(),t=Math.max(50,1.5*Math.max(e.width,e.height)),f.css({left:e.left+e.width/2+"px",top:e.top+e.height/2+"px",width:2*t+"px",height:2*t+"px"}),f[0].offsetHeight,f.addClass("transition"),f.css({width:t+"px",height:t+"px"})),h&&h.move({target:m}))}function w(e,t,o){function n(){b.forEach(function(e){"dom-event"===e.type?e.target[0].removeEventListener(e.event,e.listener,e.opts):"nr-event"===e.type&&RED.events.off(e.event,e.listener)}),b=[],setTimeout(function(){o()},0)}if(e.complete){if(0!==e.complete.length)return h&&(h.element.hide(),v||(v=!0,y())),void e.complete.call(t,function(){h&&h.element.show(),n()});e.complete.call(t)}n()}function E(e){if("string"==typeof e)return e;var t=RED.i18n.lang()||"en-US",o=Object.keys(e);return e[t]||e["en-US"]||e[o[0]]}return{load:t,run:function(e,n){n=n||function(e){e&&console.error(e)},t(e,function(e,t){var a,o,s,r;function u(e){$(window).off("resize.red-ui-tourGuide"),$(document).off("keydown.red-ui-tourGuide"),h&&h.close(),h=g=null,p.remove(),p=null,o(e)}e?console.warn("Error loading tour:",e):(a=t,o=n,p=$('<div class="red-ui-tourGuide-shade"></div>').appendTo(document.body),f=$('<div class="red-ui-tourGuide-shade-focus"></div>').appendTo(p),$(window).on("resize.red-ui-tourGuide",function(){y()}),r={index:s=0,count:a.steps.length},function e(t){if(!1===t)u(!1);else if(s===a.steps.length)u();else{r.index=s;try{d=a.steps[s++],l=r,c=e,p.fadeIn();var o=d,n=l,i=function(){var e,t=d.direction||"bottom";if(v=!1,"string"==typeof d.element?m=$(d.element):"function"==typeof d.element?m=d.element.call(l):d.element?m=d.element:(m=$(".red-ui-editor"),v=!0,t="inset"),0===m.length)throw m=null,p.hide(),new Error("Element not found");$(window).width()<400&&(m=$(".red-ui-editor"),v=!0,t="inset"),e=m.css("z-index"),v||!d.interactive&&!d.wait||m.css("z-index",2002),y(),g?g.empty():g=$('<div style="position:relative"></div>'),$('<button type="button" class="red-ui-button red-ui-button-small" style="float: right; margin-top: -4px; margin-right: -4px;"><i class="fa fa-times"></i></button>').appendTo(g).click(function(e){e.preventDefault(),w(d,l,function(){c(!1)})});var o,n,i=$('<div class="red-ui-tourGuide-popover-description"></div>').appendTo(g),i=(d.titleIcon&&$('<h2><i class="'+d.titleIcon+'"></i></h2>').appendTo(i),d.title&&$("<h2>").text(E(d.title)).appendTo(i),$("<div>").css("text-align","left").html(E(d.description)).appendTo(i),d.image&&$(`<img src="red/tours/${d.image}" />`).appendTo(i),$("<div>",{class:"red-ui-tourGuide-toolbar"}).appendTo(g)),i=($("<small>").text(l.index+1+"/"+l.count).appendTo(i),!v&&d.wait||(o=$('<button type="button" class="red-ui-button" style="position: absolute; right:0;bottom:0;"></button>').appendTo(i).one("click",function(e){e.preventDefault(),r()}),l.index===l.count-1?$("<span></span>").text(RED._("common.label.close")).appendTo(o):0===l.index?($("<span>start</span>").text(RED._("tourGuide.start")).appendTo(o),$('<span style="margin-left: 6px"><i class="fa fa-chevron-right"></i></span>').appendTo(o)):l.index<l.count-1&&($("<span></span>").text(RED._("tourGuide.next")).appendTo(o),$('<span style="margin-left: 6px"><i class="fa fa-chevron-right"></i></span>').appendTo(o))),d.width),a=(v&&(i=500),Math.min($(window).width()-10,Math.max(i||0,300))),s=(h=h||RED.popover.create({target:m,width:i||"auto",maxWidth:a+"px",direction:t,class:"red-ui-tourGuide-popover"+(v?" ":""),trigger:"manual",content:g}).open(),$(document).off("keydown.red-ui-tourGuide"),$(document).on("keydown.red-ui-tourGuide",function(e){"Escape"!==e.key&&"Esc"!==e.key||(e.preventDefault(),e.stopPropagation(),w(d,l,function(){c(!1)}))}),h.element.toggleClass("red-ui-tourGuide-popover-full",!!v),h.move({target:m,width:i||"auto",maxWidth:a+"px",direction:t}),setTimeout(function(){h.element.position().left<0&&h.element.css({left:0})},100),o&&setTimeout(function(){o.focus()},100),m[0]instanceof SVGElement),r=(d.fallback&&f.one("mouseenter",function(e){setTimeout(function(){var e=m[0].getBoundingClientRect(),e=Math.max(50,1.5*Math.max(e.width,e.height));f.css({width:4*e+"px",height:4*e+"px"}),p.fadeOut(),h.move({target:$(".red-ui-editor"),direction:d.fallback,offset:10,transition:!0})},s?0:500)}),function(){f.removeClass("transition"),m.css("z-index",e),w(d,l,c)});d.wait&&("dom-event"===d.wait.type?(i=m,d.wait.element&&("string"==typeof d.wait.element?i=$(d.wait.element):"function"==typeof d.wait.element&&(i=d.wait.element.call(l))),n={type:d.wait.type,target:i,event:d.wait.event,listener:function(){r()},opts:{once:!0}},b.push(n),i[0].addEventListener(n.event,n.listener,n.opts)):"nr-event"===d.wait.type&&(n={type:d.wait.type,event:d.wait.event,listener:function(){d.wait.filter&&!d.wait.filter.apply(l,arguments)||r()}},b.push(n),RED.events.on(n.event,n.listener)))};if(o.prepare){if(0!==o.prepare.length)return h&&(h.element.hide(),v||(v=!0,y())),void o.prepare.call(n,function(){h&&h.element.show(),i()});o.prepare.call(n)}i()}catch(e){u(e)}var d,l,c}}())})},list:function(){return[{id:"3_0",label:"3.0",path:"./tours/welcome.js"},{id:"2_2",label:"2.2",path:"./tours/2.2/welcome.js"},{id:"2_1",label:"2.1",path:"./tours/2.1/welcome.js"}]},reset:function(){RED.settings.set("editor.tours.welcome","")}}}(); \ No newline at end of file diff --git a/software/dashboard/grafana/csv/Node-RED_files/spin.svg b/software/dashboard/grafana/csv/Node-RED_files/spin.svg new file mode 100644 index 0000000..e609530 --- /dev/null +++ b/software/dashboard/grafana/csv/Node-RED_files/spin.svg @@ -0,0 +1,41 @@ +<!-- +The MIT License (MIT) + +Copyright (c) 2014 Brent Jackson + +Permission is hereby granted, free of charge, to any person obtaining a copy of +this software and associated documentation files (the "Software"), to deal in +the Software without restriction, including without limitation the rights to use, +copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the +Software, and to permit persons to whom the Software is furnished to do so, +subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS +FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR +COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER +IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN +CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. + +https://github.com/jxnblk/loading +--> +<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 32 32" width="32" height="32" fill="#999"> + <path transform="translate(2)" d="M0 12 V20 H4 V12z"> + <animate attributeName="d" values="M0 12 V20 H4 V12z; M0 4 V28 H4 V4z; M0 12 V20 H4 V12z; M0 12 V20 H4 V12z" dur="1.2s" repeatCount="indefinite" begin="0" keytimes="0;.2;.5;1" keySplines="0.2 0.2 0.4 0.8;0.2 0.6 0.4 0.8;0.2 0.8 0.4 0.8" calcMode="spline" /> + </path> + <path transform="translate(8)" d="M0 12 V20 H4 V12z"> + <animate attributeName="d" values="M0 12 V20 H4 V12z; M0 4 V28 H4 V4z; M0 12 V20 H4 V12z; M0 12 V20 H4 V12z" dur="1.2s" repeatCount="indefinite" begin="0.2" keytimes="0;.2;.5;1" keySplines="0.2 0.2 0.4 0.8;0.2 0.6 0.4 0.8;0.2 0.8 0.4 0.8" calcMode="spline" /> + </path> + <path transform="translate(14)" d="M0 12 V20 H4 V12z"> + <animate attributeName="d" values="M0 12 V20 H4 V12z; M0 4 V28 H4 V4z; M0 12 V20 H4 V12z; M0 12 V20 H4 V12z" dur="1.2s" repeatCount="indefinite" begin="0.4" keytimes="0;.2;.5;1" keySplines="0.2 0.2 0.4 0.8;0.2 0.6 0.4 0.8;0.2 0.8 0.4 0.8" calcMode="spline" /> + </path> + <path transform="translate(20)" d="M0 12 V20 H4 V12z"> + <animate attributeName="d" values="M0 12 V20 H4 V12z; M0 4 V28 H4 V4z; M0 12 V20 H4 V12z; M0 12 V20 H4 V12z" dur="1.2s" repeatCount="indefinite" begin="0.6" keytimes="0;.2;.5;1" keySplines="0.2 0.2 0.4 0.8;0.2 0.6 0.4 0.8;0.2 0.8 0.4 0.8" calcMode="spline" /> + </path> + <path transform="translate(26)" d="M0 12 V20 H4 V12z"> + <animate attributeName="d" values="M0 12 V20 H4 V12z; M0 4 V28 H4 V4z; M0 12 V20 H4 V12z; M0 12 V20 H4 V12z" dur="1.2s" repeatCount="indefinite" begin="0.8" keytimes="0;.2;.5;1" keySplines="0.2 0.2 0.4 0.8;0.2 0.6 0.4 0.8;0.2 0.8 0.4 0.8" calcMode="spline" /> + </path> +</svg> diff --git a/software/dashboard/grafana/csv/Node-RED_files/style.css b/software/dashboard/grafana/csv/Node-RED_files/style.css new file mode 100644 index 0000000..3608a4c --- /dev/null +++ b/software/dashboard/grafana/csv/Node-RED_files/style.css @@ -0,0 +1,22 @@ +/* +Some classes and styles in node-red affect the monaco editor. +This stylesheet overrides those to correct some graphical glitches +*/ + +/* unset `margin-left: 180px` of `.controls` class for hover tips */ +.monaco-editor div.phwrapper > div.controls { + margin-left: unset; +} + +/* unset some styles of `code` tag (set by node-red css) for monaco hover items */ +.monaco-editor .monaco-hover code { + font-size: unset; + color: unset; + margin: unset; +} + +/* unset some styles of `input` tag (set by node-red css) for monaco rename box */ +.monaco-editor .rename-box .rename-input { + box-sizing: unset; + height: unset; +} \ No newline at end of file diff --git a/software/dashboard/grafana/csv/Node-RED_files/style.min.css b/software/dashboard/grafana/csv/Node-RED_files/style.min.css new file mode 100644 index 0000000..aef64fb --- /dev/null +++ b/software/dashboard/grafana/csv/Node-RED_files/style.min.css @@ -0,0 +1,24 @@ +/** + * Copyright OpenJS Foundation and other contributors, https://openjsf.org/ + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + **/ +:root{--red-ui-primary-font: Helvetica Neue, Arial, Helvetica, sans-serif;--red-ui-primary-font-size: 14px;--red-ui-monospace-font: Menlo, Consolas, DejaVu Sans Mono, Courier, monospace;--red-ui-primary-background: #f3f3f3;--red-ui-secondary-background: #fff;--red-ui-secondary-background-selected: #efefef;--red-ui-secondary-background-inactive: #f0f0f0;--red-ui-secondary-background-hover: #e6e6e6;--red-ui-secondary-background-disabled: #f9f9f9;--red-ui-tertiary-background: #f7f7f7;--red-ui-shadow: rgba(0, 0, 0, 0.2);--red-ui-primary-text-color: #555;--red-ui-secondary-text-color: #888;--red-ui-secondary-text-color-focus: #666;--red-ui-secondary-text-color-hover: #666;--red-ui-secondary-text-color-active: #666;--red-ui-secondary-text-color-selected: #666;--red-ui-secondary-text-color-inactive: #666;--red-ui-secondary-text-color-disabled: #bbb;--red-ui-secondary-text-color-disabled-active: #999;--red-ui-secondary-text-color-disabled-inactive: #aaa;--red-ui-tertiary-text-color: #aaa;--red-ui-header-text-color: #444;--red-ui-text-color-error: #AD1625;--red-ui-text-color-warning: #CAB200;--red-ui-text-color-success: #3a3;--red-ui-text-color-code: #AD1625;--red-ui-text-color-link: #0088cc;--red-ui-primary-border-color: #bbbbbb;--red-ui-secondary-border-color: #dddddd;--red-ui-tertiary-border-color: #ccc;--red-ui-border-color-error: #DF2935;--red-ui-border-color-warning: #FFCF70;--red-ui-border-color-success: #4B8400;--red-ui-form-background: #fff;--red-ui-form-placeholder-color: #aaa;--red-ui-form-text-color: #555;--red-ui-form-text-color-disabled: #bbb;--red-ui-form-input-focus-color: rgba(85, 150, 230, 0.8);--red-ui-form-input-border-color: #ccc;--red-ui-form-input-border-selected-color: #aaa;--red-ui-form-input-border-error-color: rgb(214, 97, 95);--red-ui-form-input-background: #fff;--red-ui-form-input-background-disabled: #f9f9f9;--red-ui-form-button-background: #efefef;--red-ui-form-tips-background: #ffe;--red-ui-text-editor-color: #4D4D4C;--red-ui-text-editor-background: #fff;--red-ui-text-editor-color-disabled: #666;--red-ui-text-editor-background-disabled: #f9f9f9;--red-ui-text-editor-gutter-background: #f6f6f6;--red-ui-text-editor-gutter-color: #777;--red-ui-text-editor-gutter-active-line-background: #dcdcdc;--red-ui-text-editor-active-line-background: #efefef;--red-ui-text-editor-selection-background: #D6D6D6;--red-ui-event-log-background: #444;--red-ui-event-log-color: #dd9;--red-ui-event-log-active-line-background: #333;--red-ui-event-log-selection-background: #999;--red-ui-list-item-color: #555;--red-ui-list-item-secondary-color: #888;--red-ui-list-item-background: #fff;--red-ui-list-item-background-disabled: #f0f0f0;--red-ui-list-item-background-hover: #e6e6e6;--red-ui-list-item-background-selected: #ffebc7;--red-ui-list-item-border-selected: #666;--red-ui-tab-text-color-active: #444;--red-ui-tab-text-color-inactive: #666;--red-ui-tab-text-color-disabled-active: #999;--red-ui-tab-text-color-disabled-inactive: #aaa;--red-ui-tab-badge-color: #aaa;--red-ui-tab-background: #fff;--red-ui-tab-background-active: #fff;--red-ui-tab-background-active-alpha: rgba(255, 255, 255, 0.001);--red-ui-tab-background-selected: #efefef;--red-ui-tab-background-selected-alpha: rgba(239, 239, 239, 0.001);--red-ui-tab-background-inactive: #f0f0f0;--red-ui-tab-background-inactive-alpha: rgba(240, 240, 240, 0.001);--red-ui-tab-background-hover: #e6e6e6;--red-ui-tab-background-hover-alpha: rgba(230, 230, 230, 0.001);--red-ui-palette-header-background: #f3f3f3;--red-ui-palette-header-color: #444;--red-ui-palette-content-background: #fff;--red-ui-workspace-button-background: #fff;--red-ui-workspace-button-background-hover: #e6e6e6;--red-ui-workspace-button-background-active: #efefef;--red-ui-workspace-button-color: #888;--red-ui-workspace-button-color-disabled: #bbb;--red-ui-workspace-button-color-focus: #666;--red-ui-workspace-button-color-hover: #666;--red-ui-workspace-button-color-active: #666;--red-ui-workspace-button-color-selected: #666;--red-ui-workspace-button-color-primary: #eee;--red-ui-workspace-button-background-primary: #AD1625;--red-ui-workspace-button-background-primary-hover: #6E0A1E;--red-ui-workspace-button-color-focus-outline: rgba(85, 150, 230, 0.8);--red-ui-shade-color: rgba(160, 160, 160, 0.5);--red-ui-popover-background: #333;--red-ui-popover-border: #333;--red-ui-popover-color: #eee;--red-ui-popover-button-border-color: #bbb;--red-ui-popover-button-border-color-hover: #666;--red-ui-diff-text-header-color: #888;--red-ui-diff-text-header-background: #ffd;--red-ui-diff-state-color: #555;--red-ui-diff-state-prefix-color: #888;--red-ui-diff-state-added: #009900;--red-ui-diff-state-deleted: #f80000;--red-ui-diff-state-changed: #f89406;--red-ui-diff-state-changed-background: #fff2e1;--red-ui-diff-state-unchanged: #bbb;--red-ui-diff-state-unchanged-background: #fff;--red-ui-diff-state-conflicted: purple;--red-ui-diff-state-moved: #3f81b3;--red-ui-diff-state-conflict: #9b45ce;--red-ui-diff-state-conflict-background: #ffdad4;--red-ui-diff-state-added-background: #e7ffe3;--red-ui-diff-state-added-border: #b8daad;--red-ui-diff-state-added-header-background: #c0f6c0;--red-ui-diff-state-added-header-border: #aaeeaa;--red-ui-diff-state-deleted-background: #ffe1e1;--red-ui-diff-state-deleted-border: #e4bcbc;--red-ui-diff-state-deleted-header-background: #ffcccc;--red-ui-diff-state-deleted-header-border: #eebbbb;--red-ui-diff-merge-header-color: #800080;--red-ui-diff-merge-header-background: #e5f9ff;--red-ui-diff-merge-header-border-color: #b2edff;--red-ui-menuBackground: #f3f3f3;--red-ui-menuDivider: #dddddd;--red-ui-menuColor: #555;--red-ui-menuActiveColor: #666;--red-ui-menuActiveBackground: #e6e6e6;--red-ui-menuDisabledColor: #bbb;--red-ui-menuHoverColor: #666;--red-ui-menuHoverBackground: #e6e6e6;--red-ui-menuCaret: #aaa;--red-ui-view-navigator-background: rgba(245, 245, 245, 0.8);--red-ui-view-lasso-stroke: #ff7f0e;--red-ui-view-lasso-fill: rgba(20, 125, 255, 0.1);--red-ui-view-background: #fff;--red-ui-view-grid-color: #eee;--red-ui-node-label-color: #333;--red-ui-node-port-label-color: #888;--red-ui-node-border: #999;--red-ui-node-border-unknown: #f33;--red-ui-node-border-placeholder: #aaa;--red-ui-node-background-placeholder: #eee;--red-ui-node-port-background: #d9d9d9;--red-ui-node-port-background-hover: #eee;--red-ui-node-icon-color: #fff;--red-ui-node-icon-background-color: rgba(0, 0, 0, 0.05);--red-ui-node-icon-background-color-fill: #000;--red-ui-node-icon-background-color-opacity: 0.05;--red-ui-node-icon-border-color: #000;--red-ui-node-icon-border-color-opacity: 0.1;--red-ui-node-config-background: #f3f3f3;--red-ui-node-config-icon-container-disabled: #aaa;--red-ui-node-link-port-background: #eee;--red-ui-node-status-error-border: rgb(145, 16, 2);--red-ui-node-status-error-background: rgb(255, 102, 0);--red-ui-node-status-changed-border: rgb(28, 102, 140);--red-ui-node-status-changed-background: rgb(0, 188, 255);--red-ui-node-status-colors-red: #c00;--red-ui-node-status-colors-green: #5a8;--red-ui-node-status-colors-yellow: #F9DF31;--red-ui-node-status-colors-blue: #53A3F3;--red-ui-node-status-colors-grey: #d3d3d3;--red-ui-node-status-colors-gray: #d3d3d3;--red-ui-node-selected-color: #ff7f0e;--red-ui-port-selected-color: #ff7f0e;--red-ui-link-color: #999;--red-ui-link-link-color: #aaa;--red-ui-link-disabled-color: #ccc;--red-ui-link-link-active-color: #ff7f0e;--red-ui-link-unknown-color: #f00;--red-ui-clipboard-textarea-background: #F3E7E7;--red-ui-deploy-button-color: #eee;--red-ui-deploy-button-color-active: #ccc;--red-ui-deploy-button-color-disabled: #999;--red-ui-deploy-button-background: #8C101C;--red-ui-deploy-button-background-hover: #6E0A1E;--red-ui-deploy-button-background-active: #4C0A17;--red-ui-deploy-button-background-disabled: #444;--red-ui-deploy-button-background-disabled-hover: #555;--red-ui-header-background: #000;--red-ui-header-button-background-active: #121212;--red-ui-header-menu-color: #C7C7C7;--red-ui-header-menu-color-disabled: #666;--red-ui-header-menu-heading-color: #fff;--red-ui-header-menu-sublabel-color: #aeaeae;--red-ui-header-menu-background: #121212;--red-ui-header-menu-item-hover: #323232;--red-ui-header-menu-item-border-active: #777677;--red-ui-headerMenuItemDivider: #464646;--red-ui-headerMenuCaret: #C7C7C7;--red-ui-vcCommitShaColor: #c38888;--red-ui-dnd-background: rgba(0, 0, 0, 0.3);--red-ui-dnd-color: #fff;--red-ui-notification-border-default: #325C80;--red-ui-notification-border-success: #4B8400;--red-ui-notification-border-warning: #FFCF70;--red-ui-notification-border-error: #DF2935;--red-ui-debug-message-background: #fff;--red-ui-debug-message-background-hover: #efefef;--red-ui-debug-message-text-color: #333;--red-ui-debug-message-text-color-meta: #a66;--red-ui-debug-message-text-color-object-key: #792e90;--red-ui-debug-message-text-color-msg-type-other: #2033d6;--red-ui-debug-message-text-color-msg-type-string: #b72828;--red-ui-debug-message-text-color-msg-type-null: #666;--red-ui-debug-message-text-color-msg-type-meta: #666;--red-ui-debug-message-text-color-msg-type-number: #2033d6;--red-ui-debug-message-border: #eee;--red-ui-debug-message-border-hover: #999;--red-ui-debug-message-border-warning: #FFCF70;--red-ui-debug-message-border-error: #DF2935;--red-ui-group-default-fill: none;--red-ui-group-default-fill-opacity: 1;--red-ui-group-default-stroke: #999;--red-ui-group-default-stroke-opacity: 1;--red-ui-group-default-label-color: #a4a4a4;--red-ui-tourGuide-border: #c56c6c;--red-ui-tourGuide-heading-color: #c56c6c;--red-ui-grip-color: #ccc;--red-ui-icons-flow-color: #808080;--red-ui-spinner-color: #999;--red-ui-tab-icon-color: #dedede}.button-group-vertical{display:inline-block;vertical-align:middle}.button-group:not(:last-child){margin-right:10px}.red-ui-shade{position:absolute;top:0;left:0;bottom:0;right:0;background:var(--red-ui-shade-color);z-index:5}body{overflow:hidden}.red-ui-editor{font-size:var(--red-ui-primary-font-size);font-family:var(--red-ui-primary-font);padding:0;margin:0;background:var(--red-ui-primary-background);color:var(--red-ui-primary-text-color);line-height:20px}#red-ui-editor{position:absolute;top:0;left:0;bottom:0;right:0}#red-ui-editor-node-configs{display:none}#red-ui-main-container{position:absolute;top:40px;left:0;bottom:0;right:0;overflow:hidden}#red-ui-palette-shade,#red-ui-editor-shade,#red-ui-header-shade,#red-ui-sidebar-shade{position:absolute;top:0;left:0;bottom:0;right:0;background:var(--red-ui-shade-color);z-index:5;z-index:5}#red-ui-sidebar-shade{left:-8px;top:-1px;bottom:-1px}#red-ui-full-shade{position:absolute;top:0;left:0;bottom:0;right:0;background:var(--red-ui-shade-color);z-index:5;z-index:15}.red-ui-editor a,.red-ui-editor-dialog a,.red-ui-menu a,.red-ui-popover a,.red-ui-typedInput-options a,.red-ui-icon-picker a{text-decoration:none;color:var(--red-ui-primary-text-color)}.red-ui-editor a:hover,.red-ui-editor a:focus,.red-ui-editor-dialog a:hover,.red-ui-editor-dialog a:focus,.red-ui-menu a:hover,.red-ui-menu a:focus,.red-ui-popover a:hover,.red-ui-popover a:focus,.red-ui-typedInput-options a:hover,.red-ui-typedInput-options a:focus,.red-ui-icon-picker a:hover,.red-ui-icon-picker a:focus{text-decoration:none;color:var(--red-ui-primary-text-color)}.red-ui-editor a:focus,.red-ui-editor-dialog a:focus,.red-ui-menu a:focus,.red-ui-popover a:focus,.red-ui-typedInput-options a:focus,.red-ui-icon-picker a:focus{outline:1px solid var(--red-ui-form-input-focus-color)}.red-ui-editor p,.red-ui-editor-dialog p,.red-ui-menu p,.red-ui-popover p,.red-ui-typedInput-options p,.red-ui-icon-picker p{margin:0 0 10px}.red-ui-editor small,.red-ui-editor-dialog small,.red-ui-menu small,.red-ui-popover small,.red-ui-typedInput-options small,.red-ui-icon-picker small{font-size:85%}.red-ui-editor strong,.red-ui-editor-dialog strong,.red-ui-menu strong,.red-ui-popover strong,.red-ui-typedInput-options strong,.red-ui-icon-picker strong{font-weight:bold}.red-ui-editor em,.red-ui-editor-dialog em,.red-ui-menu em,.red-ui-popover em,.red-ui-typedInput-options em,.red-ui-icon-picker em{font-style:italic}.red-ui-editor cite,.red-ui-editor-dialog cite,.red-ui-menu cite,.red-ui-popover cite,.red-ui-typedInput-options cite,.red-ui-icon-picker cite{font-style:normal}.red-ui-editor ul,.red-ui-editor ol,.red-ui-editor-dialog ul,.red-ui-editor-dialog ol,.red-ui-menu ul,.red-ui-menu ol,.red-ui-popover ul,.red-ui-popover ol,.red-ui-typedInput-options ul,.red-ui-typedInput-options ol,.red-ui-icon-picker ul,.red-ui-icon-picker ol{padding:0;margin:0 0 10px 25px}.red-ui-editor ul ul,.red-ui-editor ul ol,.red-ui-editor ol ol,.red-ui-editor ol ul,.red-ui-editor-dialog ul ul,.red-ui-editor-dialog ul ol,.red-ui-editor-dialog ol ol,.red-ui-editor-dialog ol ul,.red-ui-menu ul ul,.red-ui-menu ul ol,.red-ui-menu ol ol,.red-ui-menu ol ul,.red-ui-popover ul ul,.red-ui-popover ul ol,.red-ui-popover ol ol,.red-ui-popover ol ul,.red-ui-typedInput-options ul ul,.red-ui-typedInput-options ul ol,.red-ui-typedInput-options ol ol,.red-ui-typedInput-options ol ul,.red-ui-icon-picker ul ul,.red-ui-icon-picker ul ol,.red-ui-icon-picker ol ol,.red-ui-icon-picker ol ul{margin-bottom:0}.red-ui-editor li,.red-ui-editor-dialog li,.red-ui-menu li,.red-ui-popover li,.red-ui-typedInput-options li,.red-ui-icon-picker li{line-height:20px}.red-ui-editor dl,.red-ui-editor-dialog dl,.red-ui-menu dl,.red-ui-popover dl,.red-ui-typedInput-options dl,.red-ui-icon-picker dl{margin-bottom:20px}.red-ui-editor dt,.red-ui-editor dd,.red-ui-editor-dialog dt,.red-ui-editor-dialog dd,.red-ui-menu dt,.red-ui-menu dd,.red-ui-popover dt,.red-ui-popover dd,.red-ui-typedInput-options dt,.red-ui-typedInput-options dd,.red-ui-icon-picker dt,.red-ui-icon-picker dd{line-height:20px}.red-ui-editor dt,.red-ui-editor-dialog dt,.red-ui-menu dt,.red-ui-popover dt,.red-ui-typedInput-options dt,.red-ui-icon-picker dt{font-weight:bold}.red-ui-editor dd,.red-ui-editor-dialog dd,.red-ui-menu dd,.red-ui-popover dd,.red-ui-typedInput-options dd,.red-ui-icon-picker dd{margin-left:10px}.red-ui-editor hr,.red-ui-editor-dialog hr,.red-ui-menu hr,.red-ui-popover hr,.red-ui-typedInput-options hr,.red-ui-icon-picker hr{margin:20px 0;border:0;border-top:1px solid var(--red-ui-tertiary-border-color)}.red-ui-editor i.spinner,.red-ui-editor-dialog i.spinner,.red-ui-menu i.spinner,.red-ui-popover i.spinner,.red-ui-typedInput-options i.spinner,.red-ui-icon-picker i.spinner{display:inline-block;width:14px;height:14px;line-height:14px;vertical-align:text-top;margin-top:0px;-webkit-mask-image:url(images/spin.svg);mask-image:url(images/spin.svg);-webkit-mask-size:contain;mask-size:contain;-webkit-mask-position:50% 50%;mask-position:50% 50%;-webkit-mask-repeat:no-repeat;mask-repeat:no-repeat;background-color:var(--red-ui-spinner-color)}.red-ui-editor .red-ui-font-code,.red-ui-editor-dialog .red-ui-font-code,.red-ui-menu .red-ui-font-code,.red-ui-popover .red-ui-font-code,.red-ui-typedInput-options .red-ui-font-code,.red-ui-icon-picker .red-ui-font-code{font-family:var(--red-ui-monospace-font);font-size:var(--red-ui-primary-font-size);color:var(--red-ui-text-color-code);white-space:nowrap}.red-ui-editor code,.red-ui-editor-dialog code,.red-ui-menu code,.red-ui-popover code,.red-ui-typedInput-options code,.red-ui-icon-picker code{font-family:var(--red-ui-monospace-font);font-size:var(--red-ui-primary-font-size);padding:0px;margin:1px;color:var(--red-ui-text-color-code);white-space:nowrap}.red-ui-editor pre,.red-ui-editor-dialog pre,.red-ui-menu pre,.red-ui-popover pre,.red-ui-typedInput-options pre,.red-ui-icon-picker pre{display:block;padding:9.5px;margin:0 0 10px;line-height:20px;word-break:break-all;word-wrap:break-word;white-space:pre-wrap;background-color:var(--red-ui-tertiary-background);border:1px solid var(--red-ui-tertiary-border-color);border-radius:2px}.red-ui-editor pre code,.red-ui-editor-dialog pre code,.red-ui-menu pre code,.red-ui-popover pre code,.red-ui-typedInput-options pre code,.red-ui-icon-picker pre code{padding:0;color:inherit;white-space:pre;white-space:pre-wrap;background-color:rgba(0,0,0,0);border:0}.red-ui-editor .pull-right,.red-ui-editor-dialog .pull-right,.red-ui-menu .pull-right,.red-ui-popover .pull-right,.red-ui-typedInput-options .pull-right,.red-ui-icon-picker .pull-right{float:right}.red-ui-editor .pull-left,.red-ui-editor-dialog .pull-left,.red-ui-menu .pull-left,.red-ui-popover .pull-left,.red-ui-typedInput-options .pull-left,.red-ui-icon-picker .pull-left{float:left}.red-ui-editor .hide,.red-ui-editor-dialog .hide,.red-ui-menu .hide,.red-ui-popover .hide,.red-ui-typedInput-options .hide,.red-ui-icon-picker .hide{display:none}.red-ui-editor .show,.red-ui-editor-dialog .show,.red-ui-menu .show,.red-ui-popover .show,.red-ui-typedInput-options .show,.red-ui-icon-picker .show{display:block}.red-ui-editor img,.red-ui-editor-dialog img,.red-ui-menu img,.red-ui-popover img,.red-ui-typedInput-options img,.red-ui-icon-picker img{width:auto\9 ;height:auto;max-width:100%;vertical-align:middle;border:0;-ms-interpolation-mode:bicubic}.red-ui-editor blockquote,.red-ui-editor-dialog blockquote,.red-ui-menu blockquote,.red-ui-popover blockquote,.red-ui-typedInput-options blockquote,.red-ui-icon-picker blockquote{padding:0 0 0 15px;margin:0 0 20px;border-left:4px solid var(--red-ui-secondary-border-color);color:var(--red-ui-secondary-text-color)}.red-ui-editor blockquote p,.red-ui-editor-dialog blockquote p,.red-ui-menu blockquote p,.red-ui-popover blockquote p,.red-ui-typedInput-options blockquote p,.red-ui-icon-picker blockquote p{font-size:14px;font-weight:inherit;line-height:1.25;margin-bottom:0}.red-ui-editor table,.red-ui-editor-dialog table,.red-ui-menu table,.red-ui-popover table,.red-ui-typedInput-options table,.red-ui-icon-picker table{max-width:100%;background-color:rgba(0,0,0,0);border-collapse:collapse;border-spacing:0}.red-ui-component-spinner{position:absolute;top:1px;bottom:1px;left:1px;right:1px;text-align:center;padding:40px;background:var(--red-ui-secondary-background)}.red-ui-component-spinner:before{content:"";display:inline-block;height:100%;vertical-align:middle;margin-right:-0.25em}.red-ui-component-spinner img{display:inline-block;vertical-align:middle;width:80px}.red-ui-component-spinner.red-ui-component-spinner-sidebar{background:var(--red-ui-secondary-background);padding:0}.red-ui-component-spinner.red-ui-component-spinner-sidebar img{width:40px}.red-ui-component-spinner.projects-version-control-spinner-sidebar{background:var(--red-ui-secondary-background);padding:0}.red-ui-component-spinner.projects-version-control-spinner-sidebar img{width:20px}.red-ui-component-spinner.red-ui-component-spinner-contain{padding:0}.red-ui-component-spinner.red-ui-component-spinner-contain img{width:auto;height:100%;max-height:50px}/*! +* Extracted from Bootstrap v2.3.2 +* +* Copyright 2013 Twitter, Inc +* Licensed under the Apache License v2.0 +* http://www.apache.org/licenses/LICENSE-2.0 +* +* Designed and built with all the love in the world by @mdo and @fat. +*/.red-ui-editor button,.red-ui-editor input,.red-ui-editor select,.red-ui-editor div[contenteditable=true],.red-ui-editor textarea,.red-ui-editor-dialog button,.red-ui-editor-dialog input,.red-ui-editor-dialog select,.red-ui-editor-dialog div[contenteditable=true],.red-ui-editor-dialog textarea{margin:0;font-size:100%;vertical-align:middle}.red-ui-editor button,.red-ui-editor div[contenteditable=true],.red-ui-editor input,.red-ui-editor-dialog button,.red-ui-editor-dialog div[contenteditable=true],.red-ui-editor-dialog input{*overflow:visible;line-height:normal}.red-ui-editor button::-moz-focus-inner,.red-ui-editor div[contenteditable=true]::-moz-focus-inner,.red-ui-editor input::-moz-focus-inner,.red-ui-editor-dialog button::-moz-focus-inner,.red-ui-editor-dialog div[contenteditable=true]::-moz-focus-inner,.red-ui-editor-dialog input::-moz-focus-inner{padding:0;border:0}.red-ui-editor button,.red-ui-editor html input[type=button],.red-ui-editor input[type=reset],.red-ui-editor input[type=submit],.red-ui-editor-dialog button,.red-ui-editor-dialog html input[type=button],.red-ui-editor-dialog input[type=reset],.red-ui-editor-dialog input[type=submit]{cursor:pointer;-webkit-appearance:button}.red-ui-editor label,.red-ui-editor select,.red-ui-editor button,.red-ui-editor input[type=button],.red-ui-editor input[type=reset],.red-ui-editor input[type=submit],.red-ui-editor input[type=radio],.red-ui-editor input[type=checkbox],.red-ui-editor-dialog label,.red-ui-editor-dialog select,.red-ui-editor-dialog button,.red-ui-editor-dialog input[type=button],.red-ui-editor-dialog input[type=reset],.red-ui-editor-dialog input[type=submit],.red-ui-editor-dialog input[type=radio],.red-ui-editor-dialog input[type=checkbox]{cursor:pointer}.red-ui-editor input[type=search],.red-ui-editor-dialog input[type=search]{box-sizing:content-box}.red-ui-editor input[type=search]::-webkit-search-decoration,.red-ui-editor input[type=search]::-webkit-search-cancel-button,.red-ui-editor-dialog input[type=search]::-webkit-search-decoration,.red-ui-editor-dialog input[type=search]::-webkit-search-cancel-button{-webkit-appearance:none}.red-ui-editor textarea,.red-ui-editor-dialog textarea{overflow:auto;vertical-align:top}.red-ui-editor form,.red-ui-editor-dialog form{margin:0 0 20px}.red-ui-editor fieldset,.red-ui-editor-dialog fieldset{padding:0;margin:0;border:0}.red-ui-editor legend,.red-ui-editor-dialog legend{display:block;width:100%;padding:0;margin-bottom:20px;font-size:21px;line-height:40px;color:var(--red-ui-tertiary-text-color);border:0;border-bottom:1px solid var(--red-ui-secondary-border-color)}.red-ui-editor legend small,.red-ui-editor-dialog legend small{color:var(--red-ui-tertiary-text-color)}.red-ui-editor label,.red-ui-editor input,.red-ui-editor div[contenteditable=true],.red-ui-editor button,.red-ui-editor select,.red-ui-editor textarea,.red-ui-editor-dialog label,.red-ui-editor-dialog input,.red-ui-editor-dialog div[contenteditable=true],.red-ui-editor-dialog button,.red-ui-editor-dialog select,.red-ui-editor-dialog textarea{font-size:14px;font-weight:normal;line-height:20px}.red-ui-editor input,.red-ui-editor div[contenteditable=true],.red-ui-editor button,.red-ui-editor select,.red-ui-editor textarea,.red-ui-editor-dialog input,.red-ui-editor-dialog div[contenteditable=true],.red-ui-editor-dialog button,.red-ui-editor-dialog select,.red-ui-editor-dialog textarea{font-family:var(--red-ui-primary-font)}.red-ui-editor label,.red-ui-editor-dialog label{display:block;margin-bottom:5px}.red-ui-editor select,.red-ui-editor textarea,.red-ui-editor input[type=text],.red-ui-editor input[type=password],.red-ui-editor input[type=datetime],.red-ui-editor input[type=datetime-local],.red-ui-editor input[type=date],.red-ui-editor input[type=month],.red-ui-editor input[type=time],.red-ui-editor input[type=week],.red-ui-editor input[type=number],.red-ui-editor input[type=email],.red-ui-editor input[type=url],.red-ui-editor input[type=search],.red-ui-editor input[type=tel],.red-ui-editor input[type=color],.red-ui-editor div[contenteditable=true],.red-ui-editor .uneditable-input,.red-ui-editor .placeholder-input,.red-ui-editor-dialog select,.red-ui-editor-dialog textarea,.red-ui-editor-dialog input[type=text],.red-ui-editor-dialog input[type=password],.red-ui-editor-dialog input[type=datetime],.red-ui-editor-dialog input[type=datetime-local],.red-ui-editor-dialog input[type=date],.red-ui-editor-dialog input[type=month],.red-ui-editor-dialog input[type=time],.red-ui-editor-dialog input[type=week],.red-ui-editor-dialog input[type=number],.red-ui-editor-dialog input[type=email],.red-ui-editor-dialog input[type=url],.red-ui-editor-dialog input[type=search],.red-ui-editor-dialog input[type=tel],.red-ui-editor-dialog input[type=color],.red-ui-editor-dialog div[contenteditable=true],.red-ui-editor-dialog .uneditable-input,.red-ui-editor-dialog .placeholder-input{box-sizing:border-box;display:inline-block;height:34px;padding:6px 6px;margin-bottom:10px;font-size:14px;line-height:20px;color:var(--red-ui-form-text-color);vertical-align:middle;border-radius:4px}.red-ui-editor input,.red-ui-editor textarea,.red-ui-editor div[contenteditable=true],.red-ui-editor .uneditable-input,.red-ui-editor-dialog input,.red-ui-editor-dialog textarea,.red-ui-editor-dialog div[contenteditable=true],.red-ui-editor-dialog .uneditable-input{width:206px}.red-ui-editor textarea,.red-ui-editor-dialog textarea{height:auto}.red-ui-editor textarea,.red-ui-editor input[type=text],.red-ui-editor input[type=password],.red-ui-editor input[type=datetime],.red-ui-editor input[type=datetime-local],.red-ui-editor input[type=date],.red-ui-editor input[type=month],.red-ui-editor input[type=time],.red-ui-editor input[type=week],.red-ui-editor input[type=number],.red-ui-editor input[type=email],.red-ui-editor input[type=url],.red-ui-editor input[type=search],.red-ui-editor input[type=tel],.red-ui-editor input[type=color],.red-ui-editor div[contenteditable=true],.red-ui-editor .uneditable-input,.red-ui-editor .placeholder-input,.red-ui-editor-dialog textarea,.red-ui-editor-dialog input[type=text],.red-ui-editor-dialog input[type=password],.red-ui-editor-dialog input[type=datetime],.red-ui-editor-dialog input[type=datetime-local],.red-ui-editor-dialog input[type=date],.red-ui-editor-dialog input[type=month],.red-ui-editor-dialog input[type=time],.red-ui-editor-dialog input[type=week],.red-ui-editor-dialog input[type=number],.red-ui-editor-dialog input[type=email],.red-ui-editor-dialog input[type=url],.red-ui-editor-dialog input[type=search],.red-ui-editor-dialog input[type=tel],.red-ui-editor-dialog input[type=color],.red-ui-editor-dialog div[contenteditable=true],.red-ui-editor-dialog .uneditable-input,.red-ui-editor-dialog .placeholder-input{background-color:var(--red-ui-form-input-background);border:1px solid var(--red-ui-form-input-border-color)}.red-ui-editor textarea:focus,.red-ui-editor input[type=text]:focus,.red-ui-editor input[type=password]:focus,.red-ui-editor input[type=datetime]:focus,.red-ui-editor input[type=datetime-local]:focus,.red-ui-editor input[type=date]:focus,.red-ui-editor input[type=month]:focus,.red-ui-editor input[type=time]:focus,.red-ui-editor input[type=week]:focus,.red-ui-editor input[type=number]:focus,.red-ui-editor input[type=email]:focus,.red-ui-editor input[type=url]:focus,.red-ui-editor input[type=search]:focus,.red-ui-editor input[type=tel]:focus,.red-ui-editor input[type=color]:focus,.red-ui-editor div[contenteditable=true]:focus,.red-ui-editor .uneditable-input:focus,.red-ui-editor-dialog textarea:focus,.red-ui-editor-dialog input[type=text]:focus,.red-ui-editor-dialog input[type=password]:focus,.red-ui-editor-dialog input[type=datetime]:focus,.red-ui-editor-dialog input[type=datetime-local]:focus,.red-ui-editor-dialog input[type=date]:focus,.red-ui-editor-dialog input[type=month]:focus,.red-ui-editor-dialog input[type=time]:focus,.red-ui-editor-dialog input[type=week]:focus,.red-ui-editor-dialog input[type=number]:focus,.red-ui-editor-dialog input[type=email]:focus,.red-ui-editor-dialog input[type=url]:focus,.red-ui-editor-dialog input[type=search]:focus,.red-ui-editor-dialog input[type=tel]:focus,.red-ui-editor-dialog input[type=color]:focus,.red-ui-editor-dialog div[contenteditable=true]:focus,.red-ui-editor-dialog .uneditable-input:focus{border-color:var(--red-ui-form-input-focus-color);outline:0;outline:thin dotted \9 }.red-ui-editor input[type=radio],.red-ui-editor input[type=checkbox],.red-ui-editor-dialog input[type=radio],.red-ui-editor-dialog input[type=checkbox]{margin:4px 0 0;margin-top:1px \9 ;*margin-top:0;line-height:normal}.red-ui-editor input[type=file],.red-ui-editor input[type=image],.red-ui-editor input[type=submit],.red-ui-editor input[type=reset],.red-ui-editor input[type=button],.red-ui-editor input[type=radio],.red-ui-editor input[type=checkbox],.red-ui-editor-dialog input[type=file],.red-ui-editor-dialog input[type=image],.red-ui-editor-dialog input[type=submit],.red-ui-editor-dialog input[type=reset],.red-ui-editor-dialog input[type=button],.red-ui-editor-dialog input[type=radio],.red-ui-editor-dialog input[type=checkbox]{width:auto}.red-ui-editor select,.red-ui-editor input[type=file],.red-ui-editor-dialog select,.red-ui-editor-dialog input[type=file]{height:34px;line-height:34px}.red-ui-editor select,.red-ui-editor-dialog select{width:220px;background-color:var(--red-ui-form-input-background);border:1px solid var(--red-ui-form-input-border-color)}.red-ui-editor select[multiple],.red-ui-editor select[size],.red-ui-editor-dialog select[multiple],.red-ui-editor-dialog select[size]{height:auto}.red-ui-editor select:focus,.red-ui-editor input[type=file]:focus,.red-ui-editor input[type=radio]:focus,.red-ui-editor input[type=checkbox]:focus,.red-ui-editor-dialog select:focus,.red-ui-editor-dialog input[type=file]:focus,.red-ui-editor-dialog input[type=radio]:focus,.red-ui-editor-dialog input[type=checkbox]:focus{outline:2px auto var(--red-ui-form-input-focus-color);outline-offset:-3px}.red-ui-editor .uneditable-input,.red-ui-editor .uneditable-textarea,.red-ui-editor-dialog .uneditable-input,.red-ui-editor-dialog .uneditable-textarea{color:var(--red-ui-form-text-color-disabled);cursor:not-allowed;background-color:var(--red-ui-form-input-background-disabled);border-color:var(--red-ui-form-input-border-color)}.red-ui-editor .uneditable-input,.red-ui-editor-dialog .uneditable-input{overflow:hidden;white-space:nowrap}.red-ui-editor .uneditable-textarea,.red-ui-editor-dialog .uneditable-textarea{width:auto;height:auto}.red-ui-editor input:-moz-placeholder,.red-ui-editor textarea:-moz-placeholder,.red-ui-editor-dialog input:-moz-placeholder,.red-ui-editor-dialog textarea:-moz-placeholder{color:var(--red-ui-form-placeholder-color)}.red-ui-editor input:-ms-input-placeholder,.red-ui-editor div[contenteditable=true]:-ms-input-placeholder,.red-ui-editor textarea:-ms-input-placeholder,.red-ui-editor-dialog input:-ms-input-placeholder,.red-ui-editor-dialog div[contenteditable=true]:-ms-input-placeholder,.red-ui-editor-dialog textarea:-ms-input-placeholder{color:var(--red-ui-form-placeholder-color)}.red-ui-editor input::-webkit-input-placeholder,.red-ui-editor div[contenteditable=true]::-webkit-input-placeholder,.red-ui-editor textarea::-webkit-input-placeholder,.red-ui-editor-dialog input::-webkit-input-placeholder,.red-ui-editor-dialog div[contenteditable=true]::-webkit-input-placeholder,.red-ui-editor-dialog textarea::-webkit-input-placeholder{color:var(--red-ui-form-placeholder-color)}.red-ui-editor .radio,.red-ui-editor .checkbox,.red-ui-editor-dialog .radio,.red-ui-editor-dialog .checkbox{min-height:20px;padding-left:20px}.red-ui-editor .radio input[type=radio],.red-ui-editor .checkbox input[type=checkbox],.red-ui-editor-dialog .radio input[type=radio],.red-ui-editor-dialog .checkbox input[type=checkbox]{float:left;margin-left:-20px}.red-ui-editor .controls>.radio:first-child,.red-ui-editor .controls>.checkbox:first-child,.red-ui-editor-dialog .controls>.radio:first-child,.red-ui-editor-dialog .controls>.checkbox:first-child{padding-top:5px}.red-ui-editor .radio.inline,.red-ui-editor .checkbox.inline,.red-ui-editor-dialog .radio.inline,.red-ui-editor-dialog .checkbox.inline{display:inline-block;padding-top:5px;margin-bottom:0;vertical-align:middle}.red-ui-editor .radio.inline+.radio.inline,.red-ui-editor .checkbox.inline+.checkbox.inline,.red-ui-editor-dialog .radio.inline+.radio.inline,.red-ui-editor-dialog .checkbox.inline+.checkbox.inline{margin-left:10px}.red-ui-editor .input-mini,.red-ui-editor-dialog .input-mini{width:60px}.red-ui-editor .input-small,.red-ui-editor-dialog .input-small{width:90px}.red-ui-editor .input-medium,.red-ui-editor-dialog .input-medium{width:150px}.red-ui-editor .input-large,.red-ui-editor-dialog .input-large{width:210px}.red-ui-editor .input-xlarge,.red-ui-editor-dialog .input-xlarge{width:270px}.red-ui-editor .input-xxlarge,.red-ui-editor-dialog .input-xxlarge{width:530px}.red-ui-editor input[class*=span],.red-ui-editor select[class*=span],.red-ui-editor textarea[class*=span],.red-ui-editor .uneditable-input[class*=span],.red-ui-editor .row-fluid input[class*=span],.red-ui-editor .row-fluid select[class*=span],.red-ui-editor .row-fluid textarea[class*=span],.red-ui-editor .row-fluid .uneditable-input[class*=span],.red-ui-editor-dialog input[class*=span],.red-ui-editor-dialog select[class*=span],.red-ui-editor-dialog textarea[class*=span],.red-ui-editor-dialog .uneditable-input[class*=span],.red-ui-editor-dialog .row-fluid input[class*=span],.red-ui-editor-dialog .row-fluid select[class*=span],.red-ui-editor-dialog .row-fluid textarea[class*=span],.red-ui-editor-dialog .row-fluid .uneditable-input[class*=span]{float:none;margin-left:0}.red-ui-editor .input-append input[class*=span],.red-ui-editor .input-append .uneditable-input[class*=span],.red-ui-editor .input-prepend input[class*=span],.red-ui-editor .input-prepend .uneditable-input[class*=span],.red-ui-editor .row-fluid input[class*=span],.red-ui-editor .row-fluid select[class*=span],.red-ui-editor .row-fluid textarea[class*=span],.red-ui-editor .row-fluid .uneditable-input[class*=span],.red-ui-editor .row-fluid .input-prepend [class*=span],.red-ui-editor .row-fluid .input-append [class*=span],.red-ui-editor-dialog .input-append input[class*=span],.red-ui-editor-dialog .input-append .uneditable-input[class*=span],.red-ui-editor-dialog .input-prepend input[class*=span],.red-ui-editor-dialog .input-prepend .uneditable-input[class*=span],.red-ui-editor-dialog .row-fluid input[class*=span],.red-ui-editor-dialog .row-fluid select[class*=span],.red-ui-editor-dialog .row-fluid textarea[class*=span],.red-ui-editor-dialog .row-fluid .uneditable-input[class*=span],.red-ui-editor-dialog .row-fluid .input-prepend [class*=span],.red-ui-editor-dialog .row-fluid .input-append [class*=span]{display:inline-block}.red-ui-editor input,.red-ui-editor textarea,.red-ui-editor div[contenteditable=true],.red-ui-editor .uneditable-input,.red-ui-editor-dialog input,.red-ui-editor-dialog textarea,.red-ui-editor-dialog div[contenteditable=true],.red-ui-editor-dialog .uneditable-input{margin-left:0}.red-ui-editor label.disabled,.red-ui-editor-dialog label.disabled{color:var(--red-ui-form-text-color-disabled);cursor:default}.red-ui-editor input[disabled],.red-ui-editor select[disabled],.red-ui-editor textarea[disabled],.red-ui-editor input[readonly],.red-ui-editor select[readonly],.red-ui-editor textarea[readonly],.red-ui-editor-dialog input[disabled],.red-ui-editor-dialog select[disabled],.red-ui-editor-dialog textarea[disabled],.red-ui-editor-dialog input[readonly],.red-ui-editor-dialog select[readonly],.red-ui-editor-dialog textarea[readonly]{cursor:not-allowed;color:var(--red-ui-form-text-color-disabled);background-color:var(--red-ui-form-input-background-disabled)}.red-ui-editor input[type=radio][disabled],.red-ui-editor input[type=checkbox][disabled],.red-ui-editor input[type=radio][readonly],.red-ui-editor input[type=checkbox][readonly],.red-ui-editor-dialog input[type=radio][disabled],.red-ui-editor-dialog input[type=checkbox][disabled],.red-ui-editor-dialog input[type=radio][readonly],.red-ui-editor-dialog input[type=checkbox][readonly]{background-color:rgba(0,0,0,0)}.red-ui-editor input:invalid,.red-ui-editor div[contenteditable=true]:invalid,.red-ui-editor textarea:invalid,.red-ui-editor select:invalid,.red-ui-editor-dialog input:invalid,.red-ui-editor-dialog div[contenteditable=true]:invalid,.red-ui-editor-dialog textarea:invalid,.red-ui-editor-dialog select:invalid{border-color:var(--red-ui-form-input-border-error-color)}.red-ui-editor input:focus:invalid,.red-ui-editor div[contenteditable=true]:focus:invalid,.red-ui-editor textarea:focus:invalid,.red-ui-editor select:focus:invalid,.red-ui-editor-dialog input:focus:invalid,.red-ui-editor-dialog div[contenteditable=true]:focus:invalid,.red-ui-editor-dialog textarea:focus:invalid,.red-ui-editor-dialog select:focus:invalid{border-color:var(--red-ui-form-input-border-error-color)}.red-ui-editor input:focus:invalid:focus,.red-ui-editor div[contenteditable=true]:focus:invalid:focus,.red-ui-editor textarea:focus:invalid:focus,.red-ui-editor select:focus:invalid:focus,.red-ui-editor-dialog input:focus:invalid:focus,.red-ui-editor-dialog div[contenteditable=true]:focus:invalid:focus,.red-ui-editor-dialog textarea:focus:invalid:focus,.red-ui-editor-dialog select:focus:invalid:focus{border-color:var(--red-ui-form-input-border-error-color)}.red-ui-editor .input-append,.red-ui-editor .input-prepend,.red-ui-editor-dialog .input-append,.red-ui-editor-dialog .input-prepend{display:inline-block;margin-bottom:10px;font-size:0;white-space:nowrap;vertical-align:middle}.red-ui-editor .input-append input,.red-ui-editor .input-prepend input,.red-ui-editor .input-append div[contenteditable=true],.red-ui-editor .input-prepend div[contenteditable=true],.red-ui-editor .input-append select,.red-ui-editor .input-prepend select,.red-ui-editor .input-append .uneditable-input,.red-ui-editor .input-prepend .uneditable-input,.red-ui-editor .input-append .red-ui-menu-dropdown,.red-ui-editor .input-prepend .red-ui-menu-dropdown,.red-ui-editor .input-append .popover,.red-ui-editor .input-prepend .popover,.red-ui-editor-dialog .input-append input,.red-ui-editor-dialog .input-prepend input,.red-ui-editor-dialog .input-append div[contenteditable=true],.red-ui-editor-dialog .input-prepend div[contenteditable=true],.red-ui-editor-dialog .input-append select,.red-ui-editor-dialog .input-prepend select,.red-ui-editor-dialog .input-append .uneditable-input,.red-ui-editor-dialog .input-prepend .uneditable-input,.red-ui-editor-dialog .input-append .red-ui-menu-dropdown,.red-ui-editor-dialog .input-prepend .red-ui-menu-dropdown,.red-ui-editor-dialog .input-append .popover,.red-ui-editor-dialog .input-prepend .popover{font-size:14px}.red-ui-editor .input-append input,.red-ui-editor .input-prepend input,.red-ui-editor .input-append div[contenteditable=true],.red-ui-editor .input-prepend div[contenteditable=true],.red-ui-editor .input-append select,.red-ui-editor .input-prepend select,.red-ui-editor .input-append .uneditable-input,.red-ui-editor .input-prepend .uneditable-input,.red-ui-editor-dialog .input-append input,.red-ui-editor-dialog .input-prepend input,.red-ui-editor-dialog .input-append div[contenteditable=true],.red-ui-editor-dialog .input-prepend div[contenteditable=true],.red-ui-editor-dialog .input-append select,.red-ui-editor-dialog .input-prepend select,.red-ui-editor-dialog .input-append .uneditable-input,.red-ui-editor-dialog .input-prepend .uneditable-input{position:relative;margin-bottom:0;*margin-left:0;vertical-align:top;border-radius:0 4px 4px 0}.red-ui-editor .input-append input:focus,.red-ui-editor .input-prepend input:focus,.red-ui-editor .input-append div[contenteditable=true]:focus,.red-ui-editor .input-prepend div[contenteditable=true]:focus,.red-ui-editor .input-append select:focus,.red-ui-editor .input-prepend select:focus,.red-ui-editor .input-append .uneditable-input:focus,.red-ui-editor .input-prepend .uneditable-input:focus,.red-ui-editor-dialog .input-append input:focus,.red-ui-editor-dialog .input-prepend input:focus,.red-ui-editor-dialog .input-append div[contenteditable=true]:focus,.red-ui-editor-dialog .input-prepend div[contenteditable=true]:focus,.red-ui-editor-dialog .input-append select:focus,.red-ui-editor-dialog .input-prepend select:focus,.red-ui-editor-dialog .input-append .uneditable-input:focus,.red-ui-editor-dialog .input-prepend .uneditable-input:focus{z-index:2}.red-ui-editor .input-append .add-on,.red-ui-editor .input-prepend .add-on,.red-ui-editor-dialog .input-append .add-on,.red-ui-editor-dialog .input-prepend .add-on{display:inline-block;width:auto;height:20px;min-width:16px;padding:4px 5px;font-size:14px;font-weight:normal;line-height:20px;text-align:center;background-color:var(--red-ui-form-button-background);border:1px solid var(--red-ui-form-input-border-color)}.red-ui-editor .input-append .add-on,.red-ui-editor .input-prepend .add-on,.red-ui-editor .input-append .btn,.red-ui-editor .input-prepend .btn,.red-ui-editor .input-append .btn-group>.dropdown-toggle,.red-ui-editor .input-prepend .btn-group>.dropdown-toggle,.red-ui-editor-dialog .input-append .add-on,.red-ui-editor-dialog .input-prepend .add-on,.red-ui-editor-dialog .input-append .btn,.red-ui-editor-dialog .input-prepend .btn,.red-ui-editor-dialog .input-append .btn-group>.dropdown-toggle,.red-ui-editor-dialog .input-prepend .btn-group>.dropdown-toggle{vertical-align:top;border-radius:0}.red-ui-editor .input-prepend .add-on,.red-ui-editor .input-prepend .btn,.red-ui-editor-dialog .input-prepend .add-on,.red-ui-editor-dialog .input-prepend .btn{margin-right:-1px}.red-ui-editor .input-prepend .add-on:first-child,.red-ui-editor .input-prepend .btn:first-child,.red-ui-editor-dialog .input-prepend .add-on:first-child,.red-ui-editor-dialog .input-prepend .btn:first-child{border-radius:4px 0 0 4px}.red-ui-editor .input-append input,.red-ui-editor .input-append div[contenteditable=true],.red-ui-editor .input-append select,.red-ui-editor .input-append .uneditable-input,.red-ui-editor-dialog .input-append input,.red-ui-editor-dialog .input-append div[contenteditable=true],.red-ui-editor-dialog .input-append select,.red-ui-editor-dialog .input-append .uneditable-input{border-radius:4px 0 0 4px}.red-ui-editor .input-append input+.btn-group .btn:last-child,.red-ui-editor .input-append select+.btn-group .btn:last-child,.red-ui-editor .input-append .uneditable-input+.btn-group .btn:last-child,.red-ui-editor-dialog .input-append input+.btn-group .btn:last-child,.red-ui-editor-dialog .input-append select+.btn-group .btn:last-child,.red-ui-editor-dialog .input-append .uneditable-input+.btn-group .btn:last-child{border-radius:0 4px 4px 0}.red-ui-editor .input-append .add-on,.red-ui-editor .input-append .btn,.red-ui-editor .input-append .btn-group,.red-ui-editor-dialog .input-append .add-on,.red-ui-editor-dialog .input-append .btn,.red-ui-editor-dialog .input-append .btn-group{margin-left:-1px}.red-ui-editor .input-append .add-on:last-child,.red-ui-editor .input-append .btn:last-child,.red-ui-editor .input-append .btn-group:last-child>.dropdown-toggle,.red-ui-editor-dialog .input-append .add-on:last-child,.red-ui-editor-dialog .input-append .btn:last-child,.red-ui-editor-dialog .input-append .btn-group:last-child>.dropdown-toggle{border-radius:0 4px 4px 0}.red-ui-editor .input-prepend.input-append input,.red-ui-editor .input-prepend.input-append div[contenteditable=true],.red-ui-editor .input-prepend.input-append select,.red-ui-editor .input-prepend.input-append .uneditable-input,.red-ui-editor-dialog .input-prepend.input-append input,.red-ui-editor-dialog .input-prepend.input-append div[contenteditable=true],.red-ui-editor-dialog .input-prepend.input-append select,.red-ui-editor-dialog .input-prepend.input-append .uneditable-input{border-radius:0}.red-ui-editor .input-prepend.input-append input+.btn-group .btn,.red-ui-editor .input-prepend.input-append select+.btn-group .btn,.red-ui-editor .input-prepend.input-append .uneditable-input+.btn-group .btn,.red-ui-editor-dialog .input-prepend.input-append input+.btn-group .btn,.red-ui-editor-dialog .input-prepend.input-append select+.btn-group .btn,.red-ui-editor-dialog .input-prepend.input-append .uneditable-input+.btn-group .btn{border-radius:0 4px 4px 0}.red-ui-editor .input-prepend.input-append .add-on:first-child,.red-ui-editor .input-prepend.input-append .btn:first-child,.red-ui-editor-dialog .input-prepend.input-append .add-on:first-child,.red-ui-editor-dialog .input-prepend.input-append .btn:first-child{margin-right:-1px;border-radius:4px 0 0 4px}.red-ui-editor .input-prepend.input-append .add-on:last-child,.red-ui-editor .input-prepend.input-append .btn:last-child,.red-ui-editor-dialog .input-prepend.input-append .add-on:last-child,.red-ui-editor-dialog .input-prepend.input-append .btn:last-child{margin-left:-1px;border-radius:0 4px 4px 0}.red-ui-editor .input-prepend.input-append .btn-group:first-child,.red-ui-editor-dialog .input-prepend.input-append .btn-group:first-child{margin-left:0}.red-ui-editor input.search-query,.red-ui-editor-dialog input.search-query{padding-right:14px;padding-right:4px \9 ;padding-left:14px;padding-left:4px \9 ;margin-bottom:0;border-radius:15px}.red-ui-editor .form-search .input-append .search-query,.red-ui-editor .form-search .input-prepend .search-query,.red-ui-editor-dialog .form-search .input-append .search-query,.red-ui-editor-dialog .form-search .input-prepend .search-query{border-radius:0}.red-ui-editor .form-search .input-append .search-query,.red-ui-editor-dialog .form-search .input-append .search-query{border-radius:14px 0 0 14px}.red-ui-editor .form-search .input-append .btn,.red-ui-editor-dialog .form-search .input-append .btn{border-radius:0 14px 14px 0}.red-ui-editor .form-search .input-prepend .search-query,.red-ui-editor-dialog .form-search .input-prepend .search-query{border-radius:0 14px 14px 0}.red-ui-editor .form-search .input-prepend .btn,.red-ui-editor-dialog .form-search .input-prepend .btn{border-radius:14px 0 0 14px}.red-ui-editor .form-search input,.red-ui-editor .form-inline input,.red-ui-editor .form-horizontal input,.red-ui-editor .form-search div[contenteditable=true],.red-ui-editor .form-inline div[contenteditable=true],.red-ui-editor .form-horizontal div[contenteditable=true],.red-ui-editor .form-search textarea,.red-ui-editor .form-inline textarea,.red-ui-editor .form-horizontal textarea,.red-ui-editor .form-search select,.red-ui-editor .form-inline select,.red-ui-editor .form-horizontal select,.red-ui-editor .form-search .help-inline,.red-ui-editor .form-inline .help-inline,.red-ui-editor .form-horizontal .help-inline,.red-ui-editor .form-search .uneditable-input,.red-ui-editor .form-inline .uneditable-input,.red-ui-editor .form-horizontal .uneditable-input,.red-ui-editor .form-search .input-prepend,.red-ui-editor .form-inline .input-prepend,.red-ui-editor .form-horizontal .input-prepend,.red-ui-editor .form-search .input-append,.red-ui-editor .form-inline .input-append,.red-ui-editor .form-horizontal .input-append,.red-ui-editor-dialog .form-search input,.red-ui-editor-dialog .form-inline input,.red-ui-editor-dialog .form-horizontal input,.red-ui-editor-dialog .form-search div[contenteditable=true],.red-ui-editor-dialog .form-inline div[contenteditable=true],.red-ui-editor-dialog .form-horizontal div[contenteditable=true],.red-ui-editor-dialog .form-search textarea,.red-ui-editor-dialog .form-inline textarea,.red-ui-editor-dialog .form-horizontal textarea,.red-ui-editor-dialog .form-search select,.red-ui-editor-dialog .form-inline select,.red-ui-editor-dialog .form-horizontal select,.red-ui-editor-dialog .form-search .help-inline,.red-ui-editor-dialog .form-inline .help-inline,.red-ui-editor-dialog .form-horizontal .help-inline,.red-ui-editor-dialog .form-search .uneditable-input,.red-ui-editor-dialog .form-inline .uneditable-input,.red-ui-editor-dialog .form-horizontal .uneditable-input,.red-ui-editor-dialog .form-search .input-prepend,.red-ui-editor-dialog .form-inline .input-prepend,.red-ui-editor-dialog .form-horizontal .input-prepend,.red-ui-editor-dialog .form-search .input-append,.red-ui-editor-dialog .form-inline .input-append,.red-ui-editor-dialog .form-horizontal .input-append{display:inline-block;*display:inline;margin-bottom:0;vertical-align:middle;*zoom:1}.red-ui-editor .form-search .hide,.red-ui-editor .form-inline .hide,.red-ui-editor .form-horizontal .hide,.red-ui-editor-dialog .form-search .hide,.red-ui-editor-dialog .form-inline .hide,.red-ui-editor-dialog .form-horizontal .hide{display:none}.red-ui-editor .form-search label,.red-ui-editor .form-inline label,.red-ui-editor .form-search .btn-group,.red-ui-editor .form-inline .btn-group,.red-ui-editor-dialog .form-search label,.red-ui-editor-dialog .form-inline label,.red-ui-editor-dialog .form-search .btn-group,.red-ui-editor-dialog .form-inline .btn-group{display:inline-block}.red-ui-editor .form-search .input-append,.red-ui-editor .form-inline .input-append,.red-ui-editor .form-search .input-prepend,.red-ui-editor .form-inline .input-prepend,.red-ui-editor-dialog .form-search .input-append,.red-ui-editor-dialog .form-inline .input-append,.red-ui-editor-dialog .form-search .input-prepend,.red-ui-editor-dialog .form-inline .input-prepend{margin-bottom:0}.red-ui-editor .form-search .radio,.red-ui-editor .form-search .checkbox,.red-ui-editor .form-inline .radio,.red-ui-editor .form-inline .checkbox,.red-ui-editor-dialog .form-search .radio,.red-ui-editor-dialog .form-search .checkbox,.red-ui-editor-dialog .form-inline .radio,.red-ui-editor-dialog .form-inline .checkbox{padding-left:0;margin-bottom:0;vertical-align:middle}.red-ui-editor .form-search .radio input[type=radio],.red-ui-editor .form-search .checkbox input[type=checkbox],.red-ui-editor .form-inline .radio input[type=radio],.red-ui-editor .form-inline .checkbox input[type=checkbox],.red-ui-editor-dialog .form-search .radio input[type=radio],.red-ui-editor-dialog .form-search .checkbox input[type=checkbox],.red-ui-editor-dialog .form-inline .radio input[type=radio],.red-ui-editor-dialog .form-inline .checkbox input[type=checkbox]{float:left;margin-right:3px;margin-left:0}.red-ui-editor .control-group,.red-ui-editor-dialog .control-group{margin-bottom:10px}.red-ui-editor legend+.control-group,.red-ui-editor-dialog legend+.control-group{margin-top:20px;-webkit-margin-top-collapse:separate}.red-ui-editor .form-horizontal .control-group,.red-ui-editor-dialog .form-horizontal .control-group{margin-bottom:20px;*zoom:1}.red-ui-editor .form-horizontal .control-group:before,.red-ui-editor .form-horizontal .control-group:after,.red-ui-editor-dialog .form-horizontal .control-group:before,.red-ui-editor-dialog .form-horizontal .control-group:after{display:table;line-height:0;content:""}.red-ui-editor .form-horizontal .control-group:after,.red-ui-editor-dialog .form-horizontal .control-group:after{clear:both}.red-ui-editor .form-horizontal .control-label,.red-ui-editor-dialog .form-horizontal .control-label{float:left;width:160px;padding-top:5px;text-align:right}.red-ui-editor .form-horizontal .controls,.red-ui-editor-dialog .form-horizontal .controls{*display:inline-block;*padding-left:20px;margin-left:180px;*margin-left:0}.red-ui-editor .form-horizontal .controls:first-child,.red-ui-editor-dialog .form-horizontal .controls:first-child{*padding-left:180px}.red-ui-editor .form-horizontal .help-block,.red-ui-editor-dialog .form-horizontal .help-block{margin-bottom:0}.red-ui-editor .form-horizontal input+.help-block,.red-ui-editor .form-horizontal select+.help-block,.red-ui-editor .form-horizontal textarea+.help-block,.red-ui-editor .form-horizontal .uneditable-input+.help-block,.red-ui-editor .form-horizontal .input-prepend+.help-block,.red-ui-editor .form-horizontal .input-append+.help-block,.red-ui-editor-dialog .form-horizontal input+.help-block,.red-ui-editor-dialog .form-horizontal select+.help-block,.red-ui-editor-dialog .form-horizontal textarea+.help-block,.red-ui-editor-dialog .form-horizontal .uneditable-input+.help-block,.red-ui-editor-dialog .form-horizontal .input-prepend+.help-block,.red-ui-editor-dialog .form-horizontal .input-append+.help-block{margin-top:10px}.red-ui-editor .form-horizontal .form-actions,.red-ui-editor-dialog .form-horizontal .form-actions{padding-left:180px}.red-ui-editor .form-row div[contenteditable=true],.red-ui-editor-dialog .form-row div[contenteditable=true]{white-space:nowrap;overflow:hidden}.ui-widget{font-size:14px !important;font-family:var(--red-ui-primary-font)}.ui-widget input,.ui-widget div[contenteditable=true],.ui-widget select,.ui-widget textarea,.ui-widget button{font-size:14px !important;font-family:var(--red-ui-primary-font)}.ui-widget input,.ui-widget div[contenteditable=true]{box-shadow:none}.ui-widget.ui-widget-content{border:1px solid var(--red-ui-tertiary-border-color)}.ui-widget-content{border:1px solid var(--red-ui-secondary-border-color);background:var(--red-ui-secondary-background);color:var(--red-ui-primary-text-color)}.ui-widget-header{color:var(--red-ui-header-text-color)}.ui-tabs .ui-tabs-panel{padding:0px}.ui-autocomplete{max-height:250px;overflow-x:hidden;overflow-y:scroll}.ui-dialog{border-radius:1px;background:var(--red-ui-secondary-background);padding:0;box-shadow:1px 1px 4px var(--red-ui-shadow)}.ui-dialog .ui-dialog-content{padding:25px 25px 10px 25px}.ui-dialog .ui-dialog-title{width:auto}.ui-dialog .ui-dialog-titlebar{padding:10px;background:var(--red-ui-primary-background);border:none;border-bottom:1px solid var(--red-ui-primary-border-color);border-radius:0}.ui-dialog .ui-dialog-buttonpane.ui-widget-content{background:var(--red-ui-tertiary-background)}.ui-corner-all{border-radius:1px}.ui-state-default,.ui-widget-content .ui-state-default,.ui-widget-header .ui-state-default{background:var(--red-ui-primary-background)}.ui-dialog-no-close .ui-dialog-titlebar-close{display:none}.ui-dialog-buttonset{text-align:right}.ui-dialog .ui-dialog-buttonpane .ui-dialog-buttonset{float:none}.ui-dialog-buttonset button{-webkit-user-select:none;-khtml-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;color:var(--red-ui-workspace-button-color) !important;background:var(--red-ui-workspace-button-background);text-decoration:none;box-sizing:border-box;display:inline-block;border:1px solid var(--red-ui-form-input-border-color);text-align:center;margin:0;cursor:pointer;font-size:14px;padding:6px 14px;margin-right:8px;border-radius:2px;color:var(--red-ui-workspace-button-color);background:var(--red-ui-workspace-button-background)}.ui-dialog-buttonset button.disabled,.ui-dialog-buttonset button:disabled{cursor:default;color:var(--red-ui-workspace-button-color-disabled) !important}.ui-dialog-buttonset button:hover,.ui-dialog-buttonset button:focus{text-decoration:none}.ui-dialog-buttonset button:not(.disabled):not(:disabled):hover{color:var(--red-ui-workspace-button-color-hover) !important;background:var(--red-ui-workspace-button-background-hover)}.ui-dialog-buttonset button:not(.disabled):not(:disabled):focus{color:var(--red-ui-workspace-button-color-focus) !important}.ui-dialog-buttonset button:not(.disabled):not(:disabled):active{color:var(--red-ui-workspace-button-color-active) !important;background:var(--red-ui-workspace-button-background-active);text-decoration:none}.ui-dialog-buttonset button.selected:not(.disabled):not(:disabled){color:var(--red-ui-workspace-button-color-selected) !important;background:var(--red-ui-workspace-button-background-active)}.button-group .ui-dialog-buttonset button:not(:first-child){border-left:none;border-top-left-radius:0;border-bottom-left-radius:0}.button-group .ui-dialog-buttonset button:not(:last-child){border-top-right-radius:0;border-bottom-right-radius:0}.button-group-vertical .ui-dialog-buttonset button{display:block;min-width:22px}.button-group-vertical .ui-dialog-buttonset button:not(:first-child){border-top:none;border-top-left-radius:0;border-top-right-radius:0}.button-group-vertical .ui-dialog-buttonset button:not(:last-child){border-bottom-left-radius:0;border-bottom-right-radius:0}.button-group .ui-dialog-buttonset button:focus{position:relative}.button-row .ui-dialog-buttonset button:not(:first-child){margin-left:15px}.ui-dialog-buttonset button:focus{outline:1px solid var(--red-ui-workspace-button-color-focus-outline);outline-offset:1px}.ui-dialog-buttonset button.primary{border-color:var(--red-ui-workspace-button-background-primary);color:var(--red-ui-workspace-button-color-primary) !important;background:var(--red-ui-workspace-button-background-primary)}.ui-dialog-buttonset button.primary.disabled,.ui-dialog-buttonset button.primary.ui-state-disabled{background:none;color:var(--red-ui-workspace-button-color) !important;border-color:var(--red-ui-form-input-border-color)}.ui-dialog-buttonset button.primary:not(.disabled):not(.ui-button-disabled):hover{border-color:var(--red-ui-workspace-button-background-primary-hover);background:var(--red-ui-workspace-button-background-primary-hover);color:var(--red-ui-workspace-button-color-primary) !important}.ui-dialog-buttonset button.secondary{background:none}.ui-dialog-buttonset button.secondary:not(:hover){border-color:rgba(0,0,0,0)}.ui-dialog-buttonset button.leftButton{float:left;margin-top:7px}.ui-dialog-buttonset button:not(.leftButton):not(:last-child){margin-right:16px}.ui-dialog-buttonset button.primary{border-color:var(--red-ui-workspace-button-background-primary);color:var(--red-ui-workspace-button-color-primary) !important;background:var(--red-ui-workspace-button-background-primary)}.ui-dialog-buttonset button.primary:not(.disabled):hover{border-color:var(--red-ui-workspace-button-background-primary-hover);background:var(--red-ui-workspace-button-background-primary-hover);color:var(--red-ui-workspace-button-color-primary) !important}.ui-dialog-buttonset button.primary.disabled{border-color:var(--red-ui-form-input-border-color);color:var(--red-ui-workspace-button-color-disabled) !important;background:var(--red-ui-workspace-button-background)}.ui-dialog-buttonset button.disabled{background:none}.ui-dialog-buttonset button.disabled{background:none}.ui-dialog-buttonset button.disabled:focus{outline:none}.ui-dialog-buttonset button .ui-button-text{padding:0}.ui-dialog .ui-dialog-buttonpane{padding:.3em 1em .5em 1em}.ui-spinner{border-radius:4px;padding:0;border:1px solid var(--red-ui-form-input-border-color)}.ui-spinner input{background:var(--red-ui-form-input-background);margin:0 17px 0 0;padding:6px;border:none;border-top-right-radius:0px;border-bottom-right-radius:0px}.ui-spinner input:focus{outline:none}.ui-widget-overlay{position:absolute;top:0;left:0;bottom:0;right:0;background:var(--red-ui-shade-color);z-index:5;z-index:100;opacity:1}.ui-state-default,.ui-widget-content .ui-state-default,.ui-widget-header .ui-state-default,.ui-button,html .ui-button.ui-state-disabled:hover,html .ui-button.ui-state-disabled:active{border:1px solid var(--red-ui-secondary-border-color);background:var(--red-ui-form-button-background)}.ui-state-default a,.ui-state-default a:link,.ui-state-default a:visited,a.ui-button,a:link.ui-button,a:visited.ui-button,.ui-button{color:var(--red-ui-primary-text-color)}.ui-state-hover,.ui-widget-content .ui-state-hover,.ui-widget-header .ui-state-hover,.ui-state-focus,.ui-widget-content .ui-state-focus,.ui-widget-header .ui-state-focus,.ui-button:hover,.ui-button:focus{border:1px solid var(--red-ui-secondary-border-color);background:var(--red-ui-workspace-button-background-hover);color:var(--red-ui-workspace-button-color-hover)}.ui-state-active,.ui-widget-content .ui-state-active,.ui-widget-header .ui-state-active,a.ui-button:active,.ui-button:active,.ui-button.ui-state-active:hover{border:1px solid var(--red-ui-secondary-border-color);background:var(--red-ui-workspace-button-background-active);font-weight:normal;color:var(--red-ui-workspace-button-color-active)}.ui-state-active .ui-icon,.ui-button:active .ui-icon{background-image:url(../vendor/jquery/css/base/images/ui-icons_777777_256x240.png)}.red-ui-editor .ace_read-only .ace_scroller,.red-ui-editor-dialog .ace_read-only .ace_scroller{background:var(--red-ui-text-editor-background-disabled);color:var(--red-ui-text-editor-color-disabled)}.red-ui-editor .ace_read-only .ace_cursor,.red-ui-editor-dialog .ace_read-only .ace_cursor{color:rgba(0,0,0,0) !important}.red-ui-editor .ace_gutter,.red-ui-editor-dialog .ace_gutter{background:var(--red-ui-text-editor-gutter-background);border-top-left-radius:4px;border-bottom-left-radius:4px}.red-ui-editor .ace_scroller,.red-ui-editor-dialog .ace_scroller{background:var(--red-ui-text-editor-background);border-top-right-radius:4px;border-bottom-right-radius:4px;color:var(--red-ui-text-editor-color)}.red-ui-editor .ace_marker-layer .ace_active-line,.red-ui-editor-dialog .ace_marker-layer .ace_active-line{background:var(--red-ui-text-editor-active-line-background)}.red-ui-editor .ace_marker-layer .ace_selection,.red-ui-editor-dialog .ace_marker-layer .ace_selection{background:var(--red-ui-text-editor-selection-background);border-radius:1px}.red-ui-editor .ace_gutter-cell,.red-ui-editor-dialog .ace_gutter-cell{color:var(--red-ui-text-editor-gutter-color)}.red-ui-editor .ace_gutter-active-line,.red-ui-editor-dialog .ace_gutter-active-line{background:var(--red-ui-text-editor-gutter-active-line-background)}.red-ui-editor .ace_tooltip,.red-ui-editor-dialog .ace_tooltip{font-family:var(--red-ui-primary-font);line-height:1.4em;max-width:400px;white-space:normal;background-image:none;background:var(--red-ui-popover-background);color:var(--red-ui-popover-color);border-radius:4px;box-shadow:1px 1px 4px var(--red-ui-shadow);border-color:var(--red-ui-popover-background)}.red-ui-editor .ace_content,.red-ui-editor-dialog .ace_content{line-height:1}.red-ui-editor textarea.ace_text-input,.red-ui-editor-dialog textarea.ace_text-input{overflow:hidden;padding:0px 1px !important}.red-ui-editor #red-ui-event-log-editor .ace_scroller,.red-ui-editor-dialog #red-ui-event-log-editor .ace_scroller{background:var(--red-ui-event-log-background);color:var(--red-ui-event-log-color)}.red-ui-editor #red-ui-event-log-editor .ace_marker-layer .ace_active-line,.red-ui-editor-dialog #red-ui-event-log-editor .ace_marker-layer .ace_active-line{background:var(--red-ui-event-log-active-line-background)}.red-ui-editor #red-ui-event-log-editor .ace_marker-layer .ace_selection,.red-ui-editor-dialog #red-ui-event-log-editor .ace_marker-layer .ace_selection{background:var(--red-ui-event-log-selection-background)}.red-ui-menu-dropdown{font-family:var(--red-ui-primary-font);font-size:var(--red-ui-primary-font-size);position:absolute;top:100%;width:230px;left:0;z-index:1000;display:none;float:left;margin:2px 0 0;margin-left:0px !important;padding:5px 0;list-style:none;background:var(--red-ui-menuBackground);border:1px solid var(--red-ui-secondary-border-color);box-shadow:0 5px 10px var(--red-ui-shadow)}.red-ui-menu-dropdown.pull-right{right:0;left:auto}.red-ui-menu-dropdown .red-ui-menu-divider{height:1px;margin:9px 1px;overflow:hidden;background-color:var(--red-ui-menuDivider)}.red-ui-menu-dropdown>li>a,.red-ui-menu-dropdown>li>a:focus{display:block;padding:4px 12px 4px 32px;clear:both;font-weight:normal;line-height:20px;color:var(--red-ui-menuColor);white-space:normal !important;outline:none}.red-ui-menu-dropdown>li.pull-left>a,.red-ui-menu-dropdown>li.pull-left>a:focus{padding:4px 12px 4px 32px}.red-ui-menu-dropdown.red-ui-menu-dropdown-noicons>li>a,.red-ui-menu-dropdown.red-ui-menu-dropdown-noicons>li>a:focus{padding:4px 12px 4px 12px}.red-ui-menu-dropdown.red-ui-menu-dropdown-submenus.red-ui-menu-dropdown-direction-right>li>a,.red-ui-menu-dropdown.red-ui-menu-dropdown-submenus.red-ui-menu-dropdown-direction-right>li>a:focus{padding-right:20px}.red-ui-menu-dropdown.red-ui-menu-dropdown-submenus.red-ui-menu-dropdown-direction-left>li>a,.red-ui-menu-dropdown.red-ui-menu-dropdown-submenus.red-ui-menu-dropdown-direction-left>li>a:focus{padding-left:20px}.red-ui-menu-dropdown>.active>a,.red-ui-menu-dropdown>.active>a:hover,.red-ui-menu-dropdown>.active>a:focus{color:var(--red-ui-menuActiveColor);text-decoration:none;background-color:var(--red-ui-menuActiveBackground);outline:0}.red-ui-menu-dropdown>.disabled>a,.red-ui-menu-dropdown>.disabled>a:hover,.red-ui-menu-dropdown>.disabled>a:focus{color:var(--red-ui-menuDisabledColor)}.red-ui-menu-dropdown>.disabled>a .red-ui-popover-key,.red-ui-menu-dropdown>.disabled>a:hover .red-ui-popover-key,.red-ui-menu-dropdown>.disabled>a:focus .red-ui-popover-key{color:var(--red-ui-menuDisabledColor);border-color:var(--red-ui-menuDisabledColor)}.red-ui-menu-dropdown>.disabled>a:hover,.red-ui-menu-dropdown>.disabled>a:focus{text-decoration:none;cursor:default;background-color:rgba(0,0,0,0);background-image:none}.red-ui-menu-dropdown a img{max-width:14px}.red-ui-menu-dropdown a .fa{float:left;width:20px;margin-left:-25px;margin-top:3px;text-align:center}.red-ui-menu-dropdown a .fa-check-square{display:none}.red-ui-menu-dropdown a .fa-square{display:inline-block}.red-ui-menu-dropdown a.active .fa-check-square{display:inline-block}.red-ui-menu-dropdown a.active .fa-square{display:none}.red-ui-menu-dropdown a .red-ui-menu-label{display:flex}.red-ui-menu-dropdown a .red-ui-menu-label>:first-child{flex-grow:1}.red-ui-menu-dropdown a .red-ui-popover-key{border:none;padding:0;font-size:13px;color:var(--red-ui-menuColor);border-color:var(--red-ui-menuColor)}.pull-right>.red-ui-menu-dropdown{right:0;left:auto}.red-ui-menu-dropdown>li>a:hover,.red-ui-menu-dropdown>li.open>a,.red-ui-menu-dropdown>li>a:focus,.red-ui-menu-dropdown-submenu:hover>a,.red-ui-menu-dropdown-submenu:focus>a{color:var(--red-ui-menuHoverColor);text-decoration:none;background-color:var(--red-ui-menuHoverBackground)}.red-ui-menu-dropdown-submenu{position:relative}.red-ui-menu-dropdown-submenu>.red-ui-menu-dropdown{top:0;left:calc(100% - 5px);margin-top:0;margin-left:-1px}.red-ui-menu-dropdown-submenu.open>.red-ui-menu-dropdown,.red-ui-menu-dropdown-submenu:hover>.red-ui-menu-dropdown{display:block}.red-ui-menu-dropdown-submenu>a:after{display:block;float:right;width:0;height:0;margin-top:5px;margin-right:-10px;border-color:rgba(0,0,0,0);border-left-color:var(--red-ui-menuCaret);border-style:solid;border-width:5px 0 5px 5px;content:" "}.red-ui-menu-dropdown-submenu.pull-left{float:none}.red-ui-menu-dropdown-submenu.pull-left>.red-ui-menu-dropdown{left:-100%;margin-left:10px}.red-ui-menu-dropdown-submenu.pull-left>a:after{display:none}.red-ui-menu-dropdown-submenu.pull-left>a:before{display:block;float:left;width:0;height:0;margin-top:5px;margin-left:-15px;border-color:rgba(0,0,0,0);border-right-color:var(--red-ui-menuCaret);border-style:solid;border-width:5px 5px 5px 0;content:" "}.red-ui-menu-dropdown-direction-right .red-ui-menu-dropdown-submenu>a:after{display:none}.red-ui-menu-dropdown-direction-right .red-ui-menu-dropdown-submenu>a:before{display:block;float:right;width:0;height:0;margin-top:5px;margin-right:-15px;border-color:rgba(0,0,0,0);border-left-color:var(--red-ui-menuCaret);border-style:solid;border-width:5px 0 5px 5px;content:" "}.red-ui-menu-dropdown-submenu.disabled>a:before{border-right-color:var(--red-ui-menuCaret)}ul.red-ui-menu:not(.red-ui-menu-dropdown){font-family:var(--red-ui-primary-font);font-size:12px;list-style-type:none;padding:0;margin:0}ul.red-ui-menu:not(.red-ui-menu-dropdown) li a{display:block;padding:4px 8px 4px 16px;clear:both;font-weight:normal;line-height:20px;color:var(--red-ui-menuColor);white-space:nowrap;text-decoration:none}ul.red-ui-menu:not(.red-ui-menu-dropdown) li a:hover,ul.red-ui-menu:not(.red-ui-menu-dropdown) li a:focus{color:var(--red-ui-menuHoverColor);text-decoration:none;background-color:var(--red-ui-menuHoverBackground);border:none;outline:none}ul.red-ui-menu:not(.red-ui-menu-dropdown).red-ui-menu-compact{font-size:12px}ul.red-ui-menu:not(.red-ui-menu-dropdown).red-ui-menu-compact li a{line-height:16px}.button{-webkit-user-select:none;-khtml-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none}#red-ui-header{position:absolute;top:0;left:0;width:100%;height:40px;background:var(--red-ui-header-background);box-sizing:border-box;padding:0px 0px 0px 20px;color:var(--red-ui-header-menu-color);font-size:14px}#red-ui-header span.red-ui-header-logo{float:left;margin-top:5px;font-size:30px;line-height:30px;text-decoration:none;white-space:nowrap}#red-ui-header span.red-ui-header-logo span{vertical-align:middle;font-size:16px !important}#red-ui-header span.red-ui-header-logo span:not(:first-child){margin-left:5px}#red-ui-header span.red-ui-header-logo img{height:18px}#red-ui-header span.red-ui-header-logo a{color:inherit}#red-ui-header span.red-ui-header-logo a:hover{text-decoration:none}#red-ui-header .red-ui-header-toolbar{padding:0;margin:0;list-style:none;float:right}#red-ui-header .red-ui-header-toolbar>li{display:inline-block;padding:0;margin:0;position:relative}#red-ui-header .button{min-width:20px;text-align:center;line-height:40px;display:inline-block;font-size:20px;padding:0px 12px;text-decoration:none;color:var(--red-ui-header-menu-color);margin:auto 5px;vertical-align:middle;border-left:2px solid var(--red-ui-header-background);border-right:2px solid var(--red-ui-header-background)}#red-ui-header .button:hover{border-color:var(--red-ui-header-menu-item-hover)}#red-ui-header .button:active,#red-ui-header .button.active{background:var(--red-ui-header-button-background-active)}#red-ui-header .button:focus{outline:none}#red-ui-header .button-group{display:inline-block;margin:auto 15px;vertical-align:middle;clear:both}#red-ui-header .button-group>a{display:inline-block;position:relative;float:left;line-height:22px;font-size:14px;text-decoration:none;padding:4px 8px;margin:0}#red-ui-header .red-ui-deploy-button{background:var(--red-ui-deploy-button-background);color:var(--red-ui-deploy-button-color)}#red-ui-header .red-ui-deploy-button:hover{background:var(--red-ui-deploy-button-background-hover)}#red-ui-header .red-ui-deploy-button:focus{outline:none}#red-ui-header .red-ui-deploy-button:active{background:var(--red-ui-deploy-button-background-active);color:var(--red-ui-deploy-button-color-active)}#red-ui-header .red-ui-deploy-button-spinner{position:absolute;left:0;top:0;right:0;bottom:0;text-align:center}#red-ui-header .red-ui-deploy-button-spinner img{opacity:.8;height:100%}#red-ui-header #red-ui-header-button-deploy{padding:4px 12px}#red-ui-header #red-ui-header-button-deploy.disabled{cursor:default;background:var(--red-ui-deploy-button-background-disabled);color:var(--red-ui-deploy-button-color-disabled)}#red-ui-header #red-ui-header-button-deploy.disabled .red-ui-deploy-button-content>img{opacity:.3}#red-ui-header #red-ui-header-button-deploy.disabled+#red-ui-header-button-deploy-options{background:var(--red-ui-deploy-button-background-disabled);color:var(--red-ui-deploy-button-color-active)}#red-ui-header #red-ui-header-button-deploy.disabled+#red-ui-header-button-deploy-options:hover{background:var(--red-ui-deploy-button-background-disabled-hover)}#red-ui-header #red-ui-header-button-deploy.disabled+#red-ui-header-button-deploy-options:active{background:var(--red-ui-deploy-button-background-disabled)}#red-ui-header #red-ui-header-button-deploy .red-ui-deploy-button-content>img{margin-right:8px}#red-ui-header .red-ui-deploy-button-group.open #red-ui-header-button-deploy-options{background:var(--red-ui-header-button-background-active) !important}#red-ui-header li.open .button{background:var(--red-ui-header-button-background-active);border-color:var(--red-ui-header-button-background-active)}#red-ui-header ul.red-ui-menu-dropdown{background:var(--red-ui-header-menu-background);border:1px solid var(--red-ui-header-menu-background);width:260px !important;margin-top:0}#red-ui-header ul.red-ui-menu-dropdown li a{color:var(--red-ui-header-menu-color);padding:3px 10px 3px 30px}#red-ui-header ul.red-ui-menu-dropdown li a img{max-width:100%;margin-right:10px;padding:4px;border:3px solid rgba(0,0,0,0)}#red-ui-header ul.red-ui-menu-dropdown li a .red-ui-popover-key{color:var(--red-ui-header-menu-color-disabled) !important;border-color:var(--red-ui-header-menu-color-disabled) !important}#red-ui-header ul.red-ui-menu-dropdown li a.active img{border:3px solid var(--red-ui-header-menu-item-border-active)}#red-ui-header ul.red-ui-menu-dropdown li a span.red-ui-menu-label-container{width:180px;vertical-align:top;display:inline-block;text-indent:0px}#red-ui-header ul.red-ui-menu-dropdown li a span.red-ui-menu-label{font-size:14px;text-indent:0px}#red-ui-header ul.red-ui-menu-dropdown li a span.red-ui-menu-sublabel{color:var(--red-ui-header-menu-sublabel-color);font-size:13px;display:block;text-indent:0px}#red-ui-header ul.red-ui-menu-dropdown>li>a:hover,#red-ui-header ul.red-ui-menu-dropdown>li.open>a,#red-ui-header ul.red-ui-menu-dropdown>li>a:focus,#red-ui-header ul.red-ui-menu-dropdown>li:hover>a,#red-ui-header ul.red-ui-menu-dropdown>li:focus>a{background:var(--red-ui-header-menu-item-hover) !important}#red-ui-header ul.red-ui-menu-dropdown li.red-ui-menu-divider{background:var(--red-ui-headerMenuItemDivider)}#red-ui-header ul.red-ui-menu-dropdown li.disabled a{color:var(--red-ui-header-menu-color-disabled)}#red-ui-header ul.red-ui-menu-dropdown>li.disabled>a:hover,#red-ui-header ul.red-ui-menu-dropdown>li.disabled>a:focus{background:none !important}#red-ui-header .red-ui-menu-dropdown-submenu>a:before{border-right-color:var(--red-ui-headerMenuCaret);margin-left:-25px !important}#red-ui-header ul#red-ui-header-button-deploy-options-submenu{width:300px !important}#red-ui-header ul#red-ui-header-button-deploy-options-submenu li a{padding:10px 30px;color:var(--red-ui-header-menu-heading-color)}#red-ui-header ul#red-ui-header-button-deploy-options-submenu li a span.red-ui-menu-label{font-size:16px;display:inline-block;text-indent:0px}#red-ui-header ul#red-ui-header-button-deploy-options-submenu li a>i.fa{display:none}#red-ui-header #usermenu-item-username>.red-ui-menu-label{color:var(--red-ui-header-menu-heading-color)}#red-ui-header #red-ui-header-button-user .user-profile{background-position:center center;background-repeat:no-repeat;background-size:contain;display:inline-block;width:40px;height:35px;vertical-align:middle}@media only screen and (max-width: 450px){span.red-ui-header-logo>span{display:none}}#red-ui-palette{position:absolute;top:0px;bottom:0px;left:0px;background:var(--red-ui-primary-background);width:180px;text-align:center;-webkit-user-select:none;-khtml-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;border:1px solid var(--red-ui-primary-border-color);box-sizing:border-box;transition:width .2s ease-in-out}.red-ui-palette-closed #red-ui-palette{width:8px}.red-ui-palette-closed #red-ui-palette .red-ui-component-footer{display:none}.red-ui-palette-closed #red-ui-palette-search{display:none}.red-ui-palette-closed #red-ui-palette-container{display:none}.red-ui-palette-scroll{position:absolute;top:35px;right:0;bottom:25px;left:0;padding:0;overflow-y:auto;box-sizing:border-box}#red-ui-palette>.red-ui-palette-spinner{padding-top:80px}.red-ui-palette-search{position:relative;overflow:hidden;background:var(--red-ui-secondary-background);text-align:center;height:35px;padding:3px;border-bottom:1px solid var(--red-ui-primary-border-color);box-sizing:border-box}.red-ui-palette-category{border-bottom:1px solid var(--red-ui-secondary-border-color)}.red-ui-palette-content{background:var(--red-ui-palette-content-background);padding:3px}.red-ui-palette-header{position:relative;background:var(--red-ui-palette-header-background);color:var(--red-ui-palette-header-color);cursor:pointer;text-align:left;padding:9px;font-weight:bold;padding-left:30px;overflow:hidden;user-select:none}.red-ui-palette-header:hover{background:var(--red-ui-palette-header-background) !important}.red-ui-palette-header>i{position:absolute;left:11px;top:12px;-webkit-transition:all .2s ease-in-out;-moz-transition:all .2s ease-in-out;-o-transition:all .2s ease-in-out;-webkit-transform:rotate(-90deg);-moz-transform:rotate(-90deg);-o-transform:rotate(-90deg)}.red-ui-palette-header i.expanded{-webkit-transform:rotate(0deg);-moz-transform:rotate(0deg);-o-transform:rotate(0deg)}.red-ui-palette-header span{clear:both}.red-ui-palette-label{color:var(--red-ui-node-label-color);font-size:13px;margin:4px 0 4px 32px;line-height:20px;overflow:hidden;text-align:center;-webkit-user-select:none;-khtml-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none}.red-ui-palette-label-right{margin:4px 32px 4px 0}.red-ui-palette-node{cursor:move;background:var(--red-ui-secondary-background);margin:10px auto;height:25px;border-radius:5px;border:1px solid var(--red-ui-node-border);background-position:5% 50%;background-repeat:no-repeat;width:120px;background-size:contain;position:relative;z-index:4}.red-ui-palette-node:not(.red-ui-palette-node-config):not(.red-ui-palette-node-small):first-child{margin-top:15px}.red-ui-palette-node:not(.red-ui-palette-node-config):not(.red-ui-palette-node-small):last-child{margin-bottom:15px}.red-ui-palette-node:hover{border-color:rgba(0,0,0,0);box-shadow:0 0 0 2px var(--red-ui-node-selected-color)}.red-ui-palette-port{position:absolute;top:8px;left:-5px;box-sizing:border-box;-moz-box-sizing:border-box;background:var(--red-ui-node-port-background);border-radius:3px;width:10px;height:10px;border:1px solid var(--red-ui-node-border)}.red-ui-palette-port-output{left:auto;right:-6px}.red-ui-palette-node:hover .red-ui-palette-port{background-color:var(--red-ui-node-port-background-hover)}.red-ui-palette-icon-container{position:absolute;text-align:center;top:0;bottom:0;left:0;width:30px;border-right:1px solid var(--red-ui-node-icon-background-color);border-radius:4px 0px 0px 4px;background-color:var(--red-ui-node-icon-background-color)}.red-ui-palette-icon-container-right{left:auto;right:0;border-right:none;border-left:1px solid var(--red-ui-node-icon-background-color);border-radius:0px 4px 4px 0px}.red-ui-palette-icon{display:inline-block;width:20px;height:100%;background-position:50% 50%;background-size:contain;background-repeat:no-repeat}.red-ui-search-result-node.red-ui-palette-icon-flow,.red-ui-search-result-node.red-ui-palette-icon-group,.red-ui-search-result-node.red-ui-palette-icon-junction,.red-ui-search-result-node.red-ui-palette-icon-selection{background:none;border-color:rgba(0,0,0,0)}.red-ui-search-result-node.red-ui-palette-icon-flow .red-ui-palette-icon-container,.red-ui-search-result-node.red-ui-palette-icon-group .red-ui-palette-icon-container,.red-ui-search-result-node.red-ui-palette-icon-junction .red-ui-palette-icon-container,.red-ui-search-result-node.red-ui-palette-icon-selection .red-ui-palette-icon-container{background:none}.red-ui-search-result-node.red-ui-palette-icon-flow .red-ui-palette-icon-fa,.red-ui-search-result-node.red-ui-palette-icon-group .red-ui-palette-icon-fa,.red-ui-search-result-node.red-ui-palette-icon-junction .red-ui-palette-icon-fa,.red-ui-search-result-node.red-ui-palette-icon-selection .red-ui-palette-icon-fa{color:var(--red-ui-secondary-text-color);font-size:18px}.red-ui-palette-icon-fa{color:#fff;position:absolute;top:calc(50% - 7px);left:3px}.red-ui-palette-node-small{display:inline-block;position:relative;width:18px;height:15px;margin:3px 0px;vertical-align:middle;cursor:default}.red-ui-palette-node-small .red-ui-palette-icon-container{width:18px;border-right:none}.red-ui-palette-node-small .red-ui-palette-icon{margin-left:-1px;width:15px}.red-ui-palette-node-small .red-ui-palette-icon-fa{top:2px;left:1px}.red-ui-node-list-item{display:inline-block;padding:0;font-size:13px;border:none}.red-ui-node-icon{display:inline-block;width:24px;height:20px;line-height:20px;margin-top:1px;border-radius:3px;border:1px solid var(--red-ui-node-border);background-position:5% 50%;background-repeat:no-repeat;background-size:contain;position:relative;background-color:var(--red-ui-node-icon-background-color);text-align:center}.red-ui-node-icon .red-ui-palette-icon{width:20px}.red-ui-node-icon .red-ui-palette-icon-fa{font-size:14px;position:relative;top:-1px;left:0px}.red-ui-node-icon.red-ui-palette-icon-flow,.red-ui-node-icon.red-ui-palette-icon-group,.red-ui-node-icon.red-ui-palette-icon-junction,.red-ui-node-icon.red-ui-palette-icon-selection{background:none;border-color:rgba(0,0,0,0)}.red-ui-node-icon.red-ui-palette-icon-flow .red-ui-palette-icon-container,.red-ui-node-icon.red-ui-palette-icon-group .red-ui-palette-icon-container,.red-ui-node-icon.red-ui-palette-icon-junction .red-ui-palette-icon-container,.red-ui-node-icon.red-ui-palette-icon-selection .red-ui-palette-icon-container{background:none}.red-ui-node-icon.red-ui-palette-icon-flow .red-ui-palette-icon-fa,.red-ui-node-icon.red-ui-palette-icon-group .red-ui-palette-icon-fa,.red-ui-node-icon.red-ui-palette-icon-junction .red-ui-palette-icon-fa,.red-ui-node-icon.red-ui-palette-icon-selection .red-ui-palette-icon-fa{color:var(--red-ui-secondary-text-color);font-size:16px}.red-ui-node-icon-container{display:inline-flex;align-items:center}.red-ui-node-icon-container.red-ui-node-icon-small .red-ui-node-icon{width:18px;height:15px;line-height:15px}.red-ui-node-icon-container.red-ui-node-icon-small .red-ui-node-icon .red-ui-palette-icon{width:15px}.red-ui-node-icon-container.red-ui-node-icon-small .red-ui-node-icon .red-ui-palette-icon-fa{font-size:11px}.red-ui-node-icon-container.red-ui-node-icon-small .red-ui-node-icon .red-ui-icons-flow{width:14px}.red-ui-node-icon-container.red-ui-node-icon-small .red-ui-node-icon.red-ui-palette-icon-flow{margin-top:-2px}.red-ui-node-icon-container.red-ui-node-icon-small .red-ui-node-icon.red-ui-palette-icon-junction .red-ui-palette-icon-fa,.red-ui-node-icon-container.red-ui-node-icon-small .red-ui-node-icon.red-ui-palette-icon-group .red-ui-palette-icon-fa{font-size:14px}.red-ui-node-label{white-space:nowrap;margin-left:4px;color:var(--red-ui-secondary-text-color)}#red-ui-sidebar{position:absolute;top:0px;right:0px;bottom:0px;width:315px;background:var(--red-ui-primary-background);box-sizing:border-box;z-index:10;border:1px solid var(--red-ui-primary-border-color);box-sizing:border-box}#red-ui-sidebar.closing{border-style:dashed}#red-ui-sidebar-content{position:absolute;background:var(--red-ui-secondary-background);top:35px;right:0;bottom:25px;left:0px;overflow-y:auto}#red-ui-sidebar-separator{position:absolute;top:5px;right:315px;bottom:10px;width:7px;background-color:var(--red-ui-primary-background);cursor:col-resize}#red-ui-sidebar-separator:before{content:"";display:block;width:100%;height:100%;-webkit-mask-image:url(images/grip.svg);mask-image:url(images/grip.svg);-webkit-mask-size:auto;mask-size:auto;-webkit-mask-position:50% 50%;mask-position:50% 50%;-webkit-mask-repeat:no-repeat;mask-repeat:no-repeat;background-color:var(--red-ui-grip-color)}.red-ui-sidebar-closed>#red-ui-sidebar{display:none}.red-ui-sidebar-closed>#red-ui-sidebar-separator{right:0px !important}.red-ui-sidebar-closed>#red-ui-workspace{right:7px !important}.red-ui-sidebar-closed>#red-ui-editor-stack{right:8px !important}#red-ui-sidebar .button{-webkit-user-select:none;-khtml-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;color:var(--red-ui-workspace-button-color) !important;background:var(--red-ui-workspace-button-background);text-decoration:none;box-sizing:border-box;display:inline-block;border:1px solid var(--red-ui-form-input-border-color);text-align:center;margin:0;cursor:pointer;line-height:18px;font-size:12px;margin-right:5px;padding:2px 8px}#red-ui-sidebar .button.disabled,#red-ui-sidebar .button:disabled{cursor:default;color:var(--red-ui-workspace-button-color-disabled) !important}#red-ui-sidebar .button:hover,#red-ui-sidebar .button:focus{text-decoration:none}#red-ui-sidebar .button:not(.disabled):not(:disabled):hover{color:var(--red-ui-workspace-button-color-hover) !important;background:var(--red-ui-workspace-button-background-hover)}#red-ui-sidebar .button:not(.disabled):not(:disabled):focus{color:var(--red-ui-workspace-button-color-focus) !important}#red-ui-sidebar .button:not(.disabled):not(:disabled):active{color:var(--red-ui-workspace-button-color-active) !important;background:var(--red-ui-workspace-button-background-active);text-decoration:none}#red-ui-sidebar .button.selected:not(.disabled):not(:disabled){color:var(--red-ui-workspace-button-color-selected) !important;background:var(--red-ui-workspace-button-background-active)}.button-group #red-ui-sidebar .button:not(:first-child){border-left:none;border-top-left-radius:0;border-bottom-left-radius:0}.button-group #red-ui-sidebar .button:not(:last-child){border-top-right-radius:0;border-bottom-right-radius:0}.button-group-vertical #red-ui-sidebar .button{display:block;min-width:22px}.button-group-vertical #red-ui-sidebar .button:not(:first-child){border-top:none;border-top-left-radius:0;border-top-right-radius:0}.button-group-vertical #red-ui-sidebar .button:not(:last-child){border-bottom-left-radius:0;border-bottom-right-radius:0}.button-group #red-ui-sidebar .button:focus{position:relative}.button-row #red-ui-sidebar .button:not(:first-child){margin-left:15px}#red-ui-sidebar .button:focus{outline:1px solid var(--red-ui-workspace-button-color-focus-outline);outline-offset:1px}#red-ui-sidebar .button.primary{border-color:var(--red-ui-workspace-button-background-primary);color:var(--red-ui-workspace-button-color-primary) !important;background:var(--red-ui-workspace-button-background-primary)}#red-ui-sidebar .button.primary.disabled,#red-ui-sidebar .button.primary.ui-state-disabled{background:none;color:var(--red-ui-workspace-button-color) !important;border-color:var(--red-ui-form-input-border-color)}#red-ui-sidebar .button.primary:not(.disabled):not(.ui-button-disabled):hover{border-color:var(--red-ui-workspace-button-background-primary-hover);background:var(--red-ui-workspace-button-background-primary-hover);color:var(--red-ui-workspace-button-color-primary) !important}#red-ui-sidebar .button.secondary{background:none}#red-ui-sidebar .button.secondary:not(:hover){border-color:rgba(0,0,0,0)}.sidebar-header,.red-ui-sidebar-header{color:var(--red-ui-primary-text-color);text-align:right;padding:8px 10px;background:var(--red-ui-primary-background);border-bottom:1px solid var(--red-ui-secondary-border-color);white-space:nowrap}.sidebar-footer-button{-webkit-user-select:none;-khtml-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;color:var(--red-ui-workspace-button-color) !important;background:var(--red-ui-workspace-button-background);text-decoration:none;box-sizing:border-box;display:inline-block;border:1px solid var(--red-ui-form-input-border-color);text-align:center;margin:0;cursor:pointer;font-size:12px;line-height:18px;width:19px;height:19px;padding:0}.sidebar-footer-button.disabled,.sidebar-footer-button:disabled{cursor:default;color:var(--red-ui-workspace-button-color-disabled) !important}.sidebar-footer-button:hover,.sidebar-footer-button:focus{text-decoration:none}.sidebar-footer-button:not(.disabled):not(:disabled):hover{color:var(--red-ui-workspace-button-color-hover) !important;background:var(--red-ui-workspace-button-background-hover)}.sidebar-footer-button:not(.disabled):not(:disabled):focus{color:var(--red-ui-workspace-button-color-focus) !important}.sidebar-footer-button:not(.disabled):not(:disabled):active{color:var(--red-ui-workspace-button-color-active) !important;background:var(--red-ui-workspace-button-background-active);text-decoration:none}.sidebar-footer-button.selected:not(.disabled):not(:disabled){color:var(--red-ui-workspace-button-color-selected) !important;background:var(--red-ui-workspace-button-background-active)}.button-group .sidebar-footer-button:not(:first-child){border-left:none;border-top-left-radius:0;border-bottom-left-radius:0}.button-group .sidebar-footer-button:not(:last-child){border-top-right-radius:0;border-bottom-right-radius:0}.button-group-vertical .sidebar-footer-button{display:block;min-width:22px}.button-group-vertical .sidebar-footer-button:not(:first-child){border-top:none;border-top-left-radius:0;border-top-right-radius:0}.button-group-vertical .sidebar-footer-button:not(:last-child){border-bottom-left-radius:0;border-bottom-right-radius:0}.button-group .sidebar-footer-button:focus{position:relative}.button-row .sidebar-footer-button:not(:first-child){margin-left:15px}.sidebar-footer-button:focus{outline:1px solid var(--red-ui-workspace-button-color-focus-outline);outline-offset:1px}.sidebar-footer-button.primary{border-color:var(--red-ui-workspace-button-background-primary);color:var(--red-ui-workspace-button-color-primary) !important;background:var(--red-ui-workspace-button-background-primary)}.sidebar-footer-button.primary.disabled,.sidebar-footer-button.primary.ui-state-disabled{background:none;color:var(--red-ui-workspace-button-color) !important;border-color:var(--red-ui-form-input-border-color)}.sidebar-footer-button.primary:not(.disabled):not(.ui-button-disabled):hover{border-color:var(--red-ui-workspace-button-background-primary-hover);background:var(--red-ui-workspace-button-background-primary-hover);color:var(--red-ui-workspace-button-color-primary) !important}.sidebar-footer-button.secondary{background:none}.sidebar-footer-button.secondary:not(:hover){border-color:rgba(0,0,0,0)}.sidebar-footer-button.text-button{width:auto;padding:0 5px}.sidebar-footer-button-toggle{-webkit-user-select:none;-khtml-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;color:var(--red-ui-workspace-button-color) !important;background:var(--red-ui-workspace-button-background);text-decoration:none;box-sizing:border-box;display:inline-block;border:1px solid var(--red-ui-form-input-border-color);text-align:center;margin:0;cursor:pointer;font-size:12px;line-height:18px;height:19px;width:19px;padding:0}.sidebar-footer-button-toggle.disabled,.sidebar-footer-button-toggle:disabled{cursor:default;color:var(--red-ui-workspace-button-color-disabled) !important}.sidebar-footer-button-toggle:hover,.sidebar-footer-button-toggle:focus{text-decoration:none}.sidebar-footer-button-toggle:not(.disabled):not(:disabled):hover{color:var(--red-ui-workspace-button-color-hover) !important;background:var(--red-ui-workspace-button-background-hover)}.sidebar-footer-button-toggle:not(.disabled):not(:disabled):focus{color:var(--red-ui-workspace-button-color-focus) !important}.sidebar-footer-button-toggle:not(.disabled):not(:disabled):active{color:var(--red-ui-workspace-button-color-active) !important;background:var(--red-ui-workspace-button-background-active);text-decoration:none}.sidebar-footer-button-toggle.selected:not(.disabled):not(:disabled){color:var(--red-ui-workspace-button-color-selected) !important;background:var(--red-ui-workspace-button-background-active)}.button-group .sidebar-footer-button-toggle:not(:first-child){border-left:none;border-top-left-radius:0;border-bottom-left-radius:0}.button-group .sidebar-footer-button-toggle:not(:last-child){border-top-right-radius:0;border-bottom-right-radius:0}.button-group-vertical .sidebar-footer-button-toggle{display:block;min-width:22px}.button-group-vertical .sidebar-footer-button-toggle:not(:first-child){border-top:none;border-top-left-radius:0;border-top-right-radius:0}.button-group-vertical .sidebar-footer-button-toggle:not(:last-child){border-bottom-left-radius:0;border-bottom-right-radius:0}.button-group .sidebar-footer-button-toggle:focus{position:relative}.button-row .sidebar-footer-button-toggle:not(:first-child){margin-left:15px}.sidebar-footer-button-toggle:focus{outline:1px solid var(--red-ui-workspace-button-color-focus-outline);outline-offset:1px}.sidebar-footer-button-toggle.primary{border-color:var(--red-ui-workspace-button-background-primary);color:var(--red-ui-workspace-button-color-primary) !important;background:var(--red-ui-workspace-button-background-primary)}.sidebar-footer-button-toggle.primary.disabled,.sidebar-footer-button-toggle.primary.ui-state-disabled{background:none;color:var(--red-ui-workspace-button-color) !important;border-color:var(--red-ui-form-input-border-color)}.sidebar-footer-button-toggle.primary:not(.disabled):not(.ui-button-disabled):hover{border-color:var(--red-ui-workspace-button-background-primary-hover);background:var(--red-ui-workspace-button-background-primary-hover);color:var(--red-ui-workspace-button-color-primary) !important}.sidebar-footer-button-toggle.secondary{background:none}.sidebar-footer-button-toggle.secondary:not(:hover){border-color:rgba(0,0,0,0)}.sidebar-footer-button-toggle:not(.single){margin-bottom:1px}.sidebar-footer-button-toggle:not(.single).selected:not(.disabled):not(:disabled){border-bottom-width:2px;border-bottom-color:var(--red-ui-form-input-border-selected-color);margin-bottom:0;cursor:default}.sidebar-footer-button-toggle:not(.single):not(.selected){margin-top:1px}.sidebar-footer-button-toggle.text-button{width:auto;padding:0 5px}a.sidebar-header-button,button.sidebar-header-button,a.red-ui-sidebar-header-button,button.red-ui-sidebar-header-button{-webkit-user-select:none;-khtml-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;color:var(--red-ui-workspace-button-color) !important;background:var(--red-ui-workspace-button-background);text-decoration:none;box-sizing:border-box;display:inline-block;border:1px solid var(--red-ui-form-input-border-color);text-align:center;margin:0;cursor:pointer;font-size:13px;line-height:13px;padding:5px 8px}a.sidebar-header-button.disabled,a.sidebar-header-button:disabled,button.sidebar-header-button.disabled,button.sidebar-header-button:disabled,a.red-ui-sidebar-header-button.disabled,a.red-ui-sidebar-header-button:disabled,button.red-ui-sidebar-header-button.disabled,button.red-ui-sidebar-header-button:disabled{cursor:default;color:var(--red-ui-workspace-button-color-disabled) !important}a.sidebar-header-button:hover,a.sidebar-header-button:focus,button.sidebar-header-button:hover,button.sidebar-header-button:focus,a.red-ui-sidebar-header-button:hover,a.red-ui-sidebar-header-button:focus,button.red-ui-sidebar-header-button:hover,button.red-ui-sidebar-header-button:focus{text-decoration:none}a.sidebar-header-button:not(.disabled):not(:disabled):hover,button.sidebar-header-button:not(.disabled):not(:disabled):hover,a.red-ui-sidebar-header-button:not(.disabled):not(:disabled):hover,button.red-ui-sidebar-header-button:not(.disabled):not(:disabled):hover{color:var(--red-ui-workspace-button-color-hover) !important;background:var(--red-ui-workspace-button-background-hover)}a.sidebar-header-button:not(.disabled):not(:disabled):focus,button.sidebar-header-button:not(.disabled):not(:disabled):focus,a.red-ui-sidebar-header-button:not(.disabled):not(:disabled):focus,button.red-ui-sidebar-header-button:not(.disabled):not(:disabled):focus{color:var(--red-ui-workspace-button-color-focus) !important}a.sidebar-header-button:not(.disabled):not(:disabled):active,button.sidebar-header-button:not(.disabled):not(:disabled):active,a.red-ui-sidebar-header-button:not(.disabled):not(:disabled):active,button.red-ui-sidebar-header-button:not(.disabled):not(:disabled):active{color:var(--red-ui-workspace-button-color-active) !important;background:var(--red-ui-workspace-button-background-active);text-decoration:none}a.sidebar-header-button.selected:not(.disabled):not(:disabled),button.sidebar-header-button.selected:not(.disabled):not(:disabled),a.red-ui-sidebar-header-button.selected:not(.disabled):not(:disabled),button.red-ui-sidebar-header-button.selected:not(.disabled):not(:disabled){color:var(--red-ui-workspace-button-color-selected) !important;background:var(--red-ui-workspace-button-background-active)}.button-group a.sidebar-header-button:not(:first-child),.button-group button.sidebar-header-button:not(:first-child),.button-group a.red-ui-sidebar-header-button:not(:first-child),.button-group button.red-ui-sidebar-header-button:not(:first-child){border-left:none;border-top-left-radius:0;border-bottom-left-radius:0}.button-group a.sidebar-header-button:not(:last-child),.button-group button.sidebar-header-button:not(:last-child),.button-group a.red-ui-sidebar-header-button:not(:last-child),.button-group button.red-ui-sidebar-header-button:not(:last-child){border-top-right-radius:0;border-bottom-right-radius:0}.button-group-vertical a.sidebar-header-button,.button-group-vertical button.sidebar-header-button,.button-group-vertical a.red-ui-sidebar-header-button,.button-group-vertical button.red-ui-sidebar-header-button{display:block;min-width:22px}.button-group-vertical a.sidebar-header-button:not(:first-child),.button-group-vertical button.sidebar-header-button:not(:first-child),.button-group-vertical a.red-ui-sidebar-header-button:not(:first-child),.button-group-vertical button.red-ui-sidebar-header-button:not(:first-child){border-top:none;border-top-left-radius:0;border-top-right-radius:0}.button-group-vertical a.sidebar-header-button:not(:last-child),.button-group-vertical button.sidebar-header-button:not(:last-child),.button-group-vertical a.red-ui-sidebar-header-button:not(:last-child),.button-group-vertical button.red-ui-sidebar-header-button:not(:last-child){border-bottom-left-radius:0;border-bottom-right-radius:0}.button-group a.sidebar-header-button:focus,.button-group button.sidebar-header-button:focus,.button-group a.red-ui-sidebar-header-button:focus,.button-group button.red-ui-sidebar-header-button:focus{position:relative}.button-row a.sidebar-header-button:not(:first-child),.button-row button.sidebar-header-button:not(:first-child),.button-row a.red-ui-sidebar-header-button:not(:first-child),.button-row button.red-ui-sidebar-header-button:not(:first-child){margin-left:15px}a.sidebar-header-button:focus,button.sidebar-header-button:focus,a.red-ui-sidebar-header-button:focus,button.red-ui-sidebar-header-button:focus{outline:1px solid var(--red-ui-workspace-button-color-focus-outline);outline-offset:1px}a.sidebar-header-button.primary,button.sidebar-header-button.primary,a.red-ui-sidebar-header-button.primary,button.red-ui-sidebar-header-button.primary{border-color:var(--red-ui-workspace-button-background-primary);color:var(--red-ui-workspace-button-color-primary) !important;background:var(--red-ui-workspace-button-background-primary)}a.sidebar-header-button.primary.disabled,a.sidebar-header-button.primary.ui-state-disabled,button.sidebar-header-button.primary.disabled,button.sidebar-header-button.primary.ui-state-disabled,a.red-ui-sidebar-header-button.primary.disabled,a.red-ui-sidebar-header-button.primary.ui-state-disabled,button.red-ui-sidebar-header-button.primary.disabled,button.red-ui-sidebar-header-button.primary.ui-state-disabled{background:none;color:var(--red-ui-workspace-button-color) !important;border-color:var(--red-ui-form-input-border-color)}a.sidebar-header-button.primary:not(.disabled):not(.ui-button-disabled):hover,button.sidebar-header-button.primary:not(.disabled):not(.ui-button-disabled):hover,a.red-ui-sidebar-header-button.primary:not(.disabled):not(.ui-button-disabled):hover,button.red-ui-sidebar-header-button.primary:not(.disabled):not(.ui-button-disabled):hover{border-color:var(--red-ui-workspace-button-background-primary-hover);background:var(--red-ui-workspace-button-background-primary-hover);color:var(--red-ui-workspace-button-color-primary) !important}a.sidebar-header-button.secondary,button.sidebar-header-button.secondary,a.red-ui-sidebar-header-button.secondary,button.red-ui-sidebar-header-button.secondary{background:none}a.sidebar-header-button.secondary:not(:hover),button.sidebar-header-button.secondary:not(:hover),a.red-ui-sidebar-header-button.secondary:not(:hover),button.red-ui-sidebar-header-button.secondary:not(:hover){border-color:rgba(0,0,0,0)}a.sidebar-header-button.toggle,button.sidebar-header-button.toggle,a.red-ui-sidebar-header-button.toggle,button.red-ui-sidebar-header-button.toggle{-webkit-user-select:none;-khtml-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;color:var(--red-ui-workspace-button-color) !important;background:var(--red-ui-workspace-button-background);text-decoration:none;box-sizing:border-box;display:inline-block;border:1px solid var(--red-ui-form-input-border-color);text-align:center;margin:0;cursor:pointer}a.sidebar-header-button.toggle.disabled,a.sidebar-header-button.toggle:disabled,button.sidebar-header-button.toggle.disabled,button.sidebar-header-button.toggle:disabled,a.red-ui-sidebar-header-button.toggle.disabled,a.red-ui-sidebar-header-button.toggle:disabled,button.red-ui-sidebar-header-button.toggle.disabled,button.red-ui-sidebar-header-button.toggle:disabled{cursor:default;color:var(--red-ui-workspace-button-color-disabled) !important}a.sidebar-header-button.toggle:hover,a.sidebar-header-button.toggle:focus,button.sidebar-header-button.toggle:hover,button.sidebar-header-button.toggle:focus,a.red-ui-sidebar-header-button.toggle:hover,a.red-ui-sidebar-header-button.toggle:focus,button.red-ui-sidebar-header-button.toggle:hover,button.red-ui-sidebar-header-button.toggle:focus{text-decoration:none}a.sidebar-header-button.toggle:not(.disabled):not(:disabled):hover,button.sidebar-header-button.toggle:not(.disabled):not(:disabled):hover,a.red-ui-sidebar-header-button.toggle:not(.disabled):not(:disabled):hover,button.red-ui-sidebar-header-button.toggle:not(.disabled):not(:disabled):hover{color:var(--red-ui-workspace-button-color-hover) !important;background:var(--red-ui-workspace-button-background-hover)}a.sidebar-header-button.toggle:not(.disabled):not(:disabled):focus,button.sidebar-header-button.toggle:not(.disabled):not(:disabled):focus,a.red-ui-sidebar-header-button.toggle:not(.disabled):not(:disabled):focus,button.red-ui-sidebar-header-button.toggle:not(.disabled):not(:disabled):focus{color:var(--red-ui-workspace-button-color-focus) !important}a.sidebar-header-button.toggle:not(.disabled):not(:disabled):active,button.sidebar-header-button.toggle:not(.disabled):not(:disabled):active,a.red-ui-sidebar-header-button.toggle:not(.disabled):not(:disabled):active,button.red-ui-sidebar-header-button.toggle:not(.disabled):not(:disabled):active{color:var(--red-ui-workspace-button-color-active) !important;background:var(--red-ui-workspace-button-background-active);text-decoration:none}a.sidebar-header-button.toggle.selected:not(.disabled):not(:disabled),button.sidebar-header-button.toggle.selected:not(.disabled):not(:disabled),a.red-ui-sidebar-header-button.toggle.selected:not(.disabled):not(:disabled),button.red-ui-sidebar-header-button.toggle.selected:not(.disabled):not(:disabled){color:var(--red-ui-workspace-button-color-selected) !important;background:var(--red-ui-workspace-button-background-active)}.button-group a.sidebar-header-button.toggle:not(:first-child),.button-group button.sidebar-header-button.toggle:not(:first-child),.button-group a.red-ui-sidebar-header-button.toggle:not(:first-child),.button-group button.red-ui-sidebar-header-button.toggle:not(:first-child){border-left:none;border-top-left-radius:0;border-bottom-left-radius:0}.button-group a.sidebar-header-button.toggle:not(:last-child),.button-group button.sidebar-header-button.toggle:not(:last-child),.button-group a.red-ui-sidebar-header-button.toggle:not(:last-child),.button-group button.red-ui-sidebar-header-button.toggle:not(:last-child){border-top-right-radius:0;border-bottom-right-radius:0}.button-group-vertical a.sidebar-header-button.toggle,.button-group-vertical button.sidebar-header-button.toggle,.button-group-vertical a.red-ui-sidebar-header-button.toggle,.button-group-vertical button.red-ui-sidebar-header-button.toggle{display:block;min-width:22px}.button-group-vertical a.sidebar-header-button.toggle:not(:first-child),.button-group-vertical button.sidebar-header-button.toggle:not(:first-child),.button-group-vertical a.red-ui-sidebar-header-button.toggle:not(:first-child),.button-group-vertical button.red-ui-sidebar-header-button.toggle:not(:first-child){border-top:none;border-top-left-radius:0;border-top-right-radius:0}.button-group-vertical a.sidebar-header-button.toggle:not(:last-child),.button-group-vertical button.sidebar-header-button.toggle:not(:last-child),.button-group-vertical a.red-ui-sidebar-header-button.toggle:not(:last-child),.button-group-vertical button.red-ui-sidebar-header-button.toggle:not(:last-child){border-bottom-left-radius:0;border-bottom-right-radius:0}.button-group a.sidebar-header-button.toggle:focus,.button-group button.sidebar-header-button.toggle:focus,.button-group a.red-ui-sidebar-header-button.toggle:focus,.button-group button.red-ui-sidebar-header-button.toggle:focus{position:relative}.button-row a.sidebar-header-button.toggle:not(:first-child),.button-row button.sidebar-header-button.toggle:not(:first-child),.button-row a.red-ui-sidebar-header-button.toggle:not(:first-child),.button-row button.red-ui-sidebar-header-button.toggle:not(:first-child){margin-left:15px}a.sidebar-header-button.toggle:focus,button.sidebar-header-button.toggle:focus,a.red-ui-sidebar-header-button.toggle:focus,button.red-ui-sidebar-header-button.toggle:focus{outline:1px solid var(--red-ui-workspace-button-color-focus-outline);outline-offset:1px}a.sidebar-header-button.toggle.primary,button.sidebar-header-button.toggle.primary,a.red-ui-sidebar-header-button.toggle.primary,button.red-ui-sidebar-header-button.toggle.primary{border-color:var(--red-ui-workspace-button-background-primary);color:var(--red-ui-workspace-button-color-primary) !important;background:var(--red-ui-workspace-button-background-primary)}a.sidebar-header-button.toggle.primary.disabled,a.sidebar-header-button.toggle.primary.ui-state-disabled,button.sidebar-header-button.toggle.primary.disabled,button.sidebar-header-button.toggle.primary.ui-state-disabled,a.red-ui-sidebar-header-button.toggle.primary.disabled,a.red-ui-sidebar-header-button.toggle.primary.ui-state-disabled,button.red-ui-sidebar-header-button.toggle.primary.disabled,button.red-ui-sidebar-header-button.toggle.primary.ui-state-disabled{background:none;color:var(--red-ui-workspace-button-color) !important;border-color:var(--red-ui-form-input-border-color)}a.sidebar-header-button.toggle.primary:not(.disabled):not(.ui-button-disabled):hover,button.sidebar-header-button.toggle.primary:not(.disabled):not(.ui-button-disabled):hover,a.red-ui-sidebar-header-button.toggle.primary:not(.disabled):not(.ui-button-disabled):hover,button.red-ui-sidebar-header-button.toggle.primary:not(.disabled):not(.ui-button-disabled):hover{border-color:var(--red-ui-workspace-button-background-primary-hover);background:var(--red-ui-workspace-button-background-primary-hover);color:var(--red-ui-workspace-button-color-primary) !important}a.sidebar-header-button.toggle.secondary,button.sidebar-header-button.toggle.secondary,a.red-ui-sidebar-header-button.toggle.secondary,button.red-ui-sidebar-header-button.toggle.secondary{background:none}a.sidebar-header-button.toggle.secondary:not(:hover),button.sidebar-header-button.toggle.secondary:not(:hover),a.red-ui-sidebar-header-button.toggle.secondary:not(:hover),button.red-ui-sidebar-header-button.toggle.secondary:not(:hover){border-color:rgba(0,0,0,0)}a.sidebar-header-button.toggle:not(.single),button.sidebar-header-button.toggle:not(.single),a.red-ui-sidebar-header-button.toggle:not(.single),button.red-ui-sidebar-header-button.toggle:not(.single){margin-bottom:1px}a.sidebar-header-button.toggle:not(.single).selected:not(.disabled):not(:disabled),button.sidebar-header-button.toggle:not(.single).selected:not(.disabled):not(:disabled),a.red-ui-sidebar-header-button.toggle:not(.single).selected:not(.disabled):not(:disabled),button.red-ui-sidebar-header-button.toggle:not(.single).selected:not(.disabled):not(:disabled){border-bottom-width:2px;border-bottom-color:var(--red-ui-form-input-border-selected-color);margin-bottom:0;cursor:default}a.sidebar-header-button.toggle:not(.single):not(.selected),button.sidebar-header-button.toggle:not(.single):not(.selected),a.red-ui-sidebar-header-button.toggle:not(.single):not(.selected),button.red-ui-sidebar-header-button.toggle:not(.single):not(.selected){margin-top:1px}a.sidebar-header-button-toggle,button.sidebar-header-button-toggle,a.red-ui-sidebar-header-button-toggle,button.red-ui-sidebar-header-button-toggle{-webkit-user-select:none;-khtml-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;color:var(--red-ui-workspace-button-color) !important;background:var(--red-ui-workspace-button-background);text-decoration:none;box-sizing:border-box;display:inline-block;border:1px solid var(--red-ui-form-input-border-color);text-align:center;margin:0;cursor:pointer;font-size:13px;line-height:13px;padding:5px 8px}a.sidebar-header-button-toggle.disabled,a.sidebar-header-button-toggle:disabled,button.sidebar-header-button-toggle.disabled,button.sidebar-header-button-toggle:disabled,a.red-ui-sidebar-header-button-toggle.disabled,a.red-ui-sidebar-header-button-toggle:disabled,button.red-ui-sidebar-header-button-toggle.disabled,button.red-ui-sidebar-header-button-toggle:disabled{cursor:default;color:var(--red-ui-workspace-button-color-disabled) !important}a.sidebar-header-button-toggle:hover,a.sidebar-header-button-toggle:focus,button.sidebar-header-button-toggle:hover,button.sidebar-header-button-toggle:focus,a.red-ui-sidebar-header-button-toggle:hover,a.red-ui-sidebar-header-button-toggle:focus,button.red-ui-sidebar-header-button-toggle:hover,button.red-ui-sidebar-header-button-toggle:focus{text-decoration:none}a.sidebar-header-button-toggle:not(.disabled):not(:disabled):hover,button.sidebar-header-button-toggle:not(.disabled):not(:disabled):hover,a.red-ui-sidebar-header-button-toggle:not(.disabled):not(:disabled):hover,button.red-ui-sidebar-header-button-toggle:not(.disabled):not(:disabled):hover{color:var(--red-ui-workspace-button-color-hover) !important;background:var(--red-ui-workspace-button-background-hover)}a.sidebar-header-button-toggle:not(.disabled):not(:disabled):focus,button.sidebar-header-button-toggle:not(.disabled):not(:disabled):focus,a.red-ui-sidebar-header-button-toggle:not(.disabled):not(:disabled):focus,button.red-ui-sidebar-header-button-toggle:not(.disabled):not(:disabled):focus{color:var(--red-ui-workspace-button-color-focus) !important}a.sidebar-header-button-toggle:not(.disabled):not(:disabled):active,button.sidebar-header-button-toggle:not(.disabled):not(:disabled):active,a.red-ui-sidebar-header-button-toggle:not(.disabled):not(:disabled):active,button.red-ui-sidebar-header-button-toggle:not(.disabled):not(:disabled):active{color:var(--red-ui-workspace-button-color-active) !important;background:var(--red-ui-workspace-button-background-active);text-decoration:none}a.sidebar-header-button-toggle.selected:not(.disabled):not(:disabled),button.sidebar-header-button-toggle.selected:not(.disabled):not(:disabled),a.red-ui-sidebar-header-button-toggle.selected:not(.disabled):not(:disabled),button.red-ui-sidebar-header-button-toggle.selected:not(.disabled):not(:disabled){color:var(--red-ui-workspace-button-color-selected) !important;background:var(--red-ui-workspace-button-background-active)}.button-group a.sidebar-header-button-toggle:not(:first-child),.button-group button.sidebar-header-button-toggle:not(:first-child),.button-group a.red-ui-sidebar-header-button-toggle:not(:first-child),.button-group button.red-ui-sidebar-header-button-toggle:not(:first-child){border-left:none;border-top-left-radius:0;border-bottom-left-radius:0}.button-group a.sidebar-header-button-toggle:not(:last-child),.button-group button.sidebar-header-button-toggle:not(:last-child),.button-group a.red-ui-sidebar-header-button-toggle:not(:last-child),.button-group button.red-ui-sidebar-header-button-toggle:not(:last-child){border-top-right-radius:0;border-bottom-right-radius:0}.button-group-vertical a.sidebar-header-button-toggle,.button-group-vertical button.sidebar-header-button-toggle,.button-group-vertical a.red-ui-sidebar-header-button-toggle,.button-group-vertical button.red-ui-sidebar-header-button-toggle{display:block;min-width:22px}.button-group-vertical a.sidebar-header-button-toggle:not(:first-child),.button-group-vertical button.sidebar-header-button-toggle:not(:first-child),.button-group-vertical a.red-ui-sidebar-header-button-toggle:not(:first-child),.button-group-vertical button.red-ui-sidebar-header-button-toggle:not(:first-child){border-top:none;border-top-left-radius:0;border-top-right-radius:0}.button-group-vertical a.sidebar-header-button-toggle:not(:last-child),.button-group-vertical button.sidebar-header-button-toggle:not(:last-child),.button-group-vertical a.red-ui-sidebar-header-button-toggle:not(:last-child),.button-group-vertical button.red-ui-sidebar-header-button-toggle:not(:last-child){border-bottom-left-radius:0;border-bottom-right-radius:0}.button-group a.sidebar-header-button-toggle:focus,.button-group button.sidebar-header-button-toggle:focus,.button-group a.red-ui-sidebar-header-button-toggle:focus,.button-group button.red-ui-sidebar-header-button-toggle:focus{position:relative}.button-row a.sidebar-header-button-toggle:not(:first-child),.button-row button.sidebar-header-button-toggle:not(:first-child),.button-row a.red-ui-sidebar-header-button-toggle:not(:first-child),.button-row button.red-ui-sidebar-header-button-toggle:not(:first-child){margin-left:15px}a.sidebar-header-button-toggle:focus,button.sidebar-header-button-toggle:focus,a.red-ui-sidebar-header-button-toggle:focus,button.red-ui-sidebar-header-button-toggle:focus{outline:1px solid var(--red-ui-workspace-button-color-focus-outline);outline-offset:1px}a.sidebar-header-button-toggle.primary,button.sidebar-header-button-toggle.primary,a.red-ui-sidebar-header-button-toggle.primary,button.red-ui-sidebar-header-button-toggle.primary{border-color:var(--red-ui-workspace-button-background-primary);color:var(--red-ui-workspace-button-color-primary) !important;background:var(--red-ui-workspace-button-background-primary)}a.sidebar-header-button-toggle.primary.disabled,a.sidebar-header-button-toggle.primary.ui-state-disabled,button.sidebar-header-button-toggle.primary.disabled,button.sidebar-header-button-toggle.primary.ui-state-disabled,a.red-ui-sidebar-header-button-toggle.primary.disabled,a.red-ui-sidebar-header-button-toggle.primary.ui-state-disabled,button.red-ui-sidebar-header-button-toggle.primary.disabled,button.red-ui-sidebar-header-button-toggle.primary.ui-state-disabled{background:none;color:var(--red-ui-workspace-button-color) !important;border-color:var(--red-ui-form-input-border-color)}a.sidebar-header-button-toggle.primary:not(.disabled):not(.ui-button-disabled):hover,button.sidebar-header-button-toggle.primary:not(.disabled):not(.ui-button-disabled):hover,a.red-ui-sidebar-header-button-toggle.primary:not(.disabled):not(.ui-button-disabled):hover,button.red-ui-sidebar-header-button-toggle.primary:not(.disabled):not(.ui-button-disabled):hover{border-color:var(--red-ui-workspace-button-background-primary-hover);background:var(--red-ui-workspace-button-background-primary-hover);color:var(--red-ui-workspace-button-color-primary) !important}a.sidebar-header-button-toggle.secondary,button.sidebar-header-button-toggle.secondary,a.red-ui-sidebar-header-button-toggle.secondary,button.red-ui-sidebar-header-button-toggle.secondary{background:none}a.sidebar-header-button-toggle.secondary:not(:hover),button.sidebar-header-button-toggle.secondary:not(:hover),a.red-ui-sidebar-header-button-toggle.secondary:not(:hover),button.red-ui-sidebar-header-button-toggle.secondary:not(:hover){border-color:rgba(0,0,0,0)}a.sidebar-header-button-toggle:not(.single),button.sidebar-header-button-toggle:not(.single),a.red-ui-sidebar-header-button-toggle:not(.single),button.red-ui-sidebar-header-button-toggle:not(.single){margin-bottom:1px}a.sidebar-header-button-toggle:not(.single).selected:not(.disabled):not(:disabled),button.sidebar-header-button-toggle:not(.single).selected:not(.disabled):not(:disabled),a.red-ui-sidebar-header-button-toggle:not(.single).selected:not(.disabled):not(:disabled),button.red-ui-sidebar-header-button-toggle:not(.single).selected:not(.disabled):not(:disabled){border-bottom-width:2px;border-bottom-color:var(--red-ui-form-input-border-selected-color);margin-bottom:0;cursor:default}a.sidebar-header-button-toggle:not(.single):not(.selected),button.sidebar-header-button-toggle:not(.single):not(.selected),a.red-ui-sidebar-header-button-toggle:not(.single):not(.selected),button.red-ui-sidebar-header-button-toggle:not(.single):not(.selected){margin-top:1px}.sidebar-header-button:not(:first-child),.red-ui-sidebar-header-button:not(:first-child){border-left:none}.red-ui-sidebar-shade{position:absolute;top:0;left:0;bottom:0;right:0;background:var(--red-ui-shade-color);z-index:5}.red-ui-sidebar-control-right{display:none;position:absolute;top:calc(50% - 26px);padding:15px 8px;border:1px solid var(--red-ui-primary-border-color);background:var(--red-ui-primary-background);color:var(--red-ui-secondary-text-color);text-align:center;cursor:pointer;right:100%;border-top-left-radius:5px;border-bottom-left-radius:5px;z-index:13}.red-ui-sidebar-control-left{display:none;position:absolute;top:calc(50% - 26px);padding:15px 8px;border:1px solid var(--red-ui-primary-border-color);background:var(--red-ui-primary-background);color:var(--red-ui-secondary-text-color);text-align:center;cursor:pointer;left:100%;border-top-right-radius:5px;border-bottom-right-radius:5px}#red-ui-workspace{position:absolute;margin:0;top:0px;left:179px;bottom:0px;right:322px;overflow:hidden;border:1px solid var(--red-ui-primary-border-color);box-sizing:border-box;transition:left .1s ease-in-out}#red-ui-workspace-chart{overflow:auto;position:absolute;bottom:26px;top:35px;left:0px;right:0px;box-sizing:border-box;transition:right .2s ease}#red-ui-workspace-chart:focus{outline:none}#red-ui-workspace-tabs-shade{position:absolute;top:0;left:0;bottom:0;right:0;background:var(--red-ui-shade-color);z-index:5;z-index:2;bottom:auto;height:35px}.red-ui-workspace-chart-background{fill:var(--red-ui-view-background)}.red-ui-workspace-chart-grid line{fill:none;shape-rendering:crispEdges;stroke:var(--red-ui-view-grid-color);stroke-width:1px}.red-ui-workspace-select-mode .red-ui-workspace-chart-background{opacity:.7}.red-ui-workspace-select-mode .red-ui-workspace-chart-grid line{opacity:.8}.red-ui-palette-closed #red-ui-workspace{left:7px}#red-ui-workspace-tabs:not(.red-ui-workspace-focussed){opacity:.8}.red-ui-workspace-disabled-icon{display:none}.red-ui-workspace-disabled.red-ui-tab{border-top-style:dashed;border-left-style:dashed;border-right-style:dashed}.red-ui-workspace-disabled.red-ui-tab a{font-style:italic;color:var(--red-ui-tab-text-color-disabled-inactive) !important}.red-ui-workspace-disabled.red-ui-tab.active a{font-weight:normal;color:var(--red-ui-tab-text-color-disabled-active) !important}.red-ui-workspace-disabled.red-ui-tab .red-ui-workspace-disabled-icon{display:inline}#red-ui-navigator-canvas{position:absolute;bottom:0;right:0;z-index:101;border-left:1px solid var(--red-ui-primary-border-color);border-top:1px solid var(--red-ui-primary-border-color);background:var(--red-ui-view-navigator-background);box-shadow:-1px 0 3px var(--red-ui-shadow)}.red-ui-navigator-border{stroke-dasharray:5,5;pointer-events:none;stroke:var(--red-ui-secondary-border-color);stroke-width:1;fill:var(--red-ui-view-background)}.red-ui-component-footer{border-top:1px solid var(--red-ui-primary-border-color);background:var(--red-ui-primary-background);text-align:right;position:absolute;bottom:0;left:0;right:0;height:25px;line-height:25px;padding:0 6px;user-select:none}.red-ui-component-footer .button-group:not(:last-child){margin-right:5px}.red-ui-component-footer>.button-group{display:inline-block}.red-ui-component-footer>.button-group>.red-ui-footer-button{margin-top:-1px}.red-ui-component-footer .search-counter{display:inline-block;font-size:smaller;font-weight:600;white-space:nowrap}a.red-ui-footer-button,button.red-ui-footer-button{-webkit-user-select:none;-khtml-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;color:var(--red-ui-workspace-button-color) !important;background:var(--red-ui-workspace-button-background);text-decoration:none;box-sizing:border-box;display:inline-block;border:1px solid var(--red-ui-form-input-border-color);text-align:center;margin:0;cursor:pointer;font-size:12px;line-height:18px;width:19px;height:19px;padding:0}a.red-ui-footer-button.disabled,a.red-ui-footer-button:disabled,button.red-ui-footer-button.disabled,button.red-ui-footer-button:disabled{cursor:default;color:var(--red-ui-workspace-button-color-disabled) !important}a.red-ui-footer-button:hover,a.red-ui-footer-button:focus,button.red-ui-footer-button:hover,button.red-ui-footer-button:focus{text-decoration:none}a.red-ui-footer-button:not(.disabled):not(:disabled):hover,button.red-ui-footer-button:not(.disabled):not(:disabled):hover{color:var(--red-ui-workspace-button-color-hover) !important;background:var(--red-ui-workspace-button-background-hover)}a.red-ui-footer-button:not(.disabled):not(:disabled):focus,button.red-ui-footer-button:not(.disabled):not(:disabled):focus{color:var(--red-ui-workspace-button-color-focus) !important}a.red-ui-footer-button:not(.disabled):not(:disabled):active,button.red-ui-footer-button:not(.disabled):not(:disabled):active{color:var(--red-ui-workspace-button-color-active) !important;background:var(--red-ui-workspace-button-background-active);text-decoration:none}a.red-ui-footer-button.selected:not(.disabled):not(:disabled),button.red-ui-footer-button.selected:not(.disabled):not(:disabled){color:var(--red-ui-workspace-button-color-selected) !important;background:var(--red-ui-workspace-button-background-active)}.button-group a.red-ui-footer-button:not(:first-child),.button-group button.red-ui-footer-button:not(:first-child){border-left:none;border-top-left-radius:0;border-bottom-left-radius:0}.button-group a.red-ui-footer-button:not(:last-child),.button-group button.red-ui-footer-button:not(:last-child){border-top-right-radius:0;border-bottom-right-radius:0}.button-group-vertical a.red-ui-footer-button,.button-group-vertical button.red-ui-footer-button{display:block;min-width:22px}.button-group-vertical a.red-ui-footer-button:not(:first-child),.button-group-vertical button.red-ui-footer-button:not(:first-child){border-top:none;border-top-left-radius:0;border-top-right-radius:0}.button-group-vertical a.red-ui-footer-button:not(:last-child),.button-group-vertical button.red-ui-footer-button:not(:last-child){border-bottom-left-radius:0;border-bottom-right-radius:0}.button-group a.red-ui-footer-button:focus,.button-group button.red-ui-footer-button:focus{position:relative}.button-row a.red-ui-footer-button:not(:first-child),.button-row button.red-ui-footer-button:not(:first-child){margin-left:15px}a.red-ui-footer-button:focus,button.red-ui-footer-button:focus{outline:1px solid var(--red-ui-workspace-button-color-focus-outline);outline-offset:1px}a.red-ui-footer-button.primary,button.red-ui-footer-button.primary{border-color:var(--red-ui-workspace-button-background-primary);color:var(--red-ui-workspace-button-color-primary) !important;background:var(--red-ui-workspace-button-background-primary)}a.red-ui-footer-button.primary.disabled,a.red-ui-footer-button.primary.ui-state-disabled,button.red-ui-footer-button.primary.disabled,button.red-ui-footer-button.primary.ui-state-disabled{background:none;color:var(--red-ui-workspace-button-color) !important;border-color:var(--red-ui-form-input-border-color)}a.red-ui-footer-button.primary:not(.disabled):not(.ui-button-disabled):hover,button.red-ui-footer-button.primary:not(.disabled):not(.ui-button-disabled):hover{border-color:var(--red-ui-workspace-button-background-primary-hover);background:var(--red-ui-workspace-button-background-primary-hover);color:var(--red-ui-workspace-button-color-primary) !important}a.red-ui-footer-button.secondary,button.red-ui-footer-button.secondary{background:none}a.red-ui-footer-button.secondary:not(:hover),button.red-ui-footer-button.secondary:not(:hover){border-color:rgba(0,0,0,0)}a.red-ui-footer-button.text-button,button.red-ui-footer-button.text-button{width:auto;padding:0 5px}a.red-ui-footer-button-toggle,button.red-ui-footer-button-toggle{-webkit-user-select:none;-khtml-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;color:var(--red-ui-workspace-button-color) !important;background:var(--red-ui-workspace-button-background);text-decoration:none;box-sizing:border-box;display:inline-block;border:1px solid var(--red-ui-form-input-border-color);text-align:center;margin:0;cursor:pointer;font-size:12px;line-height:18px;height:19px;width:19px;padding:0}a.red-ui-footer-button-toggle.disabled,a.red-ui-footer-button-toggle:disabled,button.red-ui-footer-button-toggle.disabled,button.red-ui-footer-button-toggle:disabled{cursor:default;color:var(--red-ui-workspace-button-color-disabled) !important}a.red-ui-footer-button-toggle:hover,a.red-ui-footer-button-toggle:focus,button.red-ui-footer-button-toggle:hover,button.red-ui-footer-button-toggle:focus{text-decoration:none}a.red-ui-footer-button-toggle:not(.disabled):not(:disabled):hover,button.red-ui-footer-button-toggle:not(.disabled):not(:disabled):hover{color:var(--red-ui-workspace-button-color-hover) !important;background:var(--red-ui-workspace-button-background-hover)}a.red-ui-footer-button-toggle:not(.disabled):not(:disabled):focus,button.red-ui-footer-button-toggle:not(.disabled):not(:disabled):focus{color:var(--red-ui-workspace-button-color-focus) !important}a.red-ui-footer-button-toggle:not(.disabled):not(:disabled):active,button.red-ui-footer-button-toggle:not(.disabled):not(:disabled):active{color:var(--red-ui-workspace-button-color-active) !important;background:var(--red-ui-workspace-button-background-active);text-decoration:none}a.red-ui-footer-button-toggle.selected:not(.disabled):not(:disabled),button.red-ui-footer-button-toggle.selected:not(.disabled):not(:disabled){color:var(--red-ui-workspace-button-color-selected) !important;background:var(--red-ui-workspace-button-background-active)}.button-group a.red-ui-footer-button-toggle:not(:first-child),.button-group button.red-ui-footer-button-toggle:not(:first-child){border-left:none;border-top-left-radius:0;border-bottom-left-radius:0}.button-group a.red-ui-footer-button-toggle:not(:last-child),.button-group button.red-ui-footer-button-toggle:not(:last-child){border-top-right-radius:0;border-bottom-right-radius:0}.button-group-vertical a.red-ui-footer-button-toggle,.button-group-vertical button.red-ui-footer-button-toggle{display:block;min-width:22px}.button-group-vertical a.red-ui-footer-button-toggle:not(:first-child),.button-group-vertical button.red-ui-footer-button-toggle:not(:first-child){border-top:none;border-top-left-radius:0;border-top-right-radius:0}.button-group-vertical a.red-ui-footer-button-toggle:not(:last-child),.button-group-vertical button.red-ui-footer-button-toggle:not(:last-child){border-bottom-left-radius:0;border-bottom-right-radius:0}.button-group a.red-ui-footer-button-toggle:focus,.button-group button.red-ui-footer-button-toggle:focus{position:relative}.button-row a.red-ui-footer-button-toggle:not(:first-child),.button-row button.red-ui-footer-button-toggle:not(:first-child){margin-left:15px}a.red-ui-footer-button-toggle:focus,button.red-ui-footer-button-toggle:focus{outline:1px solid var(--red-ui-workspace-button-color-focus-outline);outline-offset:1px}a.red-ui-footer-button-toggle.primary,button.red-ui-footer-button-toggle.primary{border-color:var(--red-ui-workspace-button-background-primary);color:var(--red-ui-workspace-button-color-primary) !important;background:var(--red-ui-workspace-button-background-primary)}a.red-ui-footer-button-toggle.primary.disabled,a.red-ui-footer-button-toggle.primary.ui-state-disabled,button.red-ui-footer-button-toggle.primary.disabled,button.red-ui-footer-button-toggle.primary.ui-state-disabled{background:none;color:var(--red-ui-workspace-button-color) !important;border-color:var(--red-ui-form-input-border-color)}a.red-ui-footer-button-toggle.primary:not(.disabled):not(.ui-button-disabled):hover,button.red-ui-footer-button-toggle.primary:not(.disabled):not(.ui-button-disabled):hover{border-color:var(--red-ui-workspace-button-background-primary-hover);background:var(--red-ui-workspace-button-background-primary-hover);color:var(--red-ui-workspace-button-color-primary) !important}a.red-ui-footer-button-toggle.secondary,button.red-ui-footer-button-toggle.secondary{background:none}a.red-ui-footer-button-toggle.secondary:not(:hover),button.red-ui-footer-button-toggle.secondary:not(:hover){border-color:rgba(0,0,0,0)}a.red-ui-footer-button-toggle:not(.single),button.red-ui-footer-button-toggle:not(.single){margin-bottom:1px}a.red-ui-footer-button-toggle:not(.single).selected:not(.disabled):not(:disabled),button.red-ui-footer-button-toggle:not(.single).selected:not(.disabled):not(:disabled){border-bottom-width:2px;border-bottom-color:var(--red-ui-form-input-border-selected-color);margin-bottom:0;cursor:default}a.red-ui-footer-button-toggle:not(.single):not(.selected),button.red-ui-footer-button-toggle:not(.single):not(.selected){margin-top:1px}a.red-ui-footer-button-toggle.text-button,button.red-ui-footer-button-toggle.text-button{width:auto;padding:0 5px}.red-ui-statusbar-widget{margin:0 2px;display:inline-block;vertical-align:middle;height:100%;line-height:20px}.red-ui-statusbar-bucket{position:absolute;top:0;bottom:0}.red-ui-statusbar-bucket-left{left:10px}.red-ui-statusbar-bucket-left .red-ui-statusbar-widget:first-child{margin-left:0}.red-ui-statusbar-bucket-right{right:10px}.red-ui-statusbar-bucket-right .red-ui-statusbar-widget:last-child{margin-right:0}#red-ui-loading-progress{position:absolute;background:var(--red-ui-primary-background);top:0;bottom:0;right:0;left:0;z-index:200}#red-ui-loading-progress>div{position:absolute;top:30%;left:50%;transform:translate(-50%, -50%);width:300px;height:80px;text-align:center;color:var(--red-ui-secondary-text-color)}.red-ui-loading-bar{box-sizing:border-box;width:300px;height:30px;border:2px solid var(--red-ui-primary-border-color);border-radius:4px}.red-ui-loading-bar>span{display:block;height:100%;background:var(--red-ui-secondary-border-color);transition:width .2s;width:10%}.red-ui-loading-bar-label{font-size:13px;margin-bottom:2px}#red-ui-workspace-toolbar{display:none;color:var(--red-ui-workspace-button-color);font-size:12px;line-height:18px;position:absolute;top:35px;left:0;right:0;padding:7px;height:40px;box-sizing:border-box;background:var(--red-ui-secondary-background);border-bottom:1px solid var(--red-ui-secondary-border-color);white-space:nowrap;transition:right .2s ease;overflow:hidden;-webkit-user-select:none;-khtml-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none}#red-ui-workspace-toolbar label{padding:1px 8px;margin:0;font-size:12px}#red-ui-workspace-toolbar input[type=checkbox]{margin:0 3px 0 0;padding:0}#red-ui-workspace-toolbar .button{-webkit-user-select:none;-khtml-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;color:var(--red-ui-workspace-button-color) !important;background:var(--red-ui-workspace-button-background);text-decoration:none;box-sizing:border-box;display:inline-block;border:1px solid var(--red-ui-form-input-border-color);text-align:center;margin:0;cursor:pointer;margin-right:10px;padding:2px 8px}#red-ui-workspace-toolbar .button.disabled,#red-ui-workspace-toolbar .button:disabled{cursor:default;color:var(--red-ui-workspace-button-color-disabled) !important}#red-ui-workspace-toolbar .button:hover,#red-ui-workspace-toolbar .button:focus{text-decoration:none}#red-ui-workspace-toolbar .button:not(.disabled):not(:disabled):hover{color:var(--red-ui-workspace-button-color-hover) !important;background:var(--red-ui-workspace-button-background-hover)}#red-ui-workspace-toolbar .button:not(.disabled):not(:disabled):focus{color:var(--red-ui-workspace-button-color-focus) !important}#red-ui-workspace-toolbar .button:not(.disabled):not(:disabled):active{color:var(--red-ui-workspace-button-color-active) !important;background:var(--red-ui-workspace-button-background-active);text-decoration:none}#red-ui-workspace-toolbar .button.selected:not(.disabled):not(:disabled){color:var(--red-ui-workspace-button-color-selected) !important;background:var(--red-ui-workspace-button-background-active)}.button-group #red-ui-workspace-toolbar .button:not(:first-child){border-left:none;border-top-left-radius:0;border-bottom-left-radius:0}.button-group #red-ui-workspace-toolbar .button:not(:last-child){border-top-right-radius:0;border-bottom-right-radius:0}.button-group-vertical #red-ui-workspace-toolbar .button{display:block;min-width:22px}.button-group-vertical #red-ui-workspace-toolbar .button:not(:first-child){border-top:none;border-top-left-radius:0;border-top-right-radius:0}.button-group-vertical #red-ui-workspace-toolbar .button:not(:last-child){border-bottom-left-radius:0;border-bottom-right-radius:0}.button-group #red-ui-workspace-toolbar .button:focus{position:relative}.button-row #red-ui-workspace-toolbar .button:not(:first-child){margin-left:15px}#red-ui-workspace-toolbar .button:focus{outline:1px solid var(--red-ui-workspace-button-color-focus-outline);outline-offset:1px}#red-ui-workspace-toolbar .button.primary{border-color:var(--red-ui-workspace-button-background-primary);color:var(--red-ui-workspace-button-color-primary) !important;background:var(--red-ui-workspace-button-background-primary)}#red-ui-workspace-toolbar .button.primary.disabled,#red-ui-workspace-toolbar .button.primary.ui-state-disabled{background:none;color:var(--red-ui-workspace-button-color) !important;border-color:var(--red-ui-form-input-border-color)}#red-ui-workspace-toolbar .button.primary:not(.disabled):not(.ui-button-disabled):hover{border-color:var(--red-ui-workspace-button-background-primary-hover);background:var(--red-ui-workspace-button-background-primary-hover);color:var(--red-ui-workspace-button-color-primary) !important}#red-ui-workspace-toolbar .button.secondary{background:none}#red-ui-workspace-toolbar .button.secondary:not(:hover){border-color:rgba(0,0,0,0)}#red-ui-workspace-toolbar .button-group{-webkit-user-select:none;-khtml-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none}#red-ui-workspace-toolbar .button-group .button:first-child{margin-right:0}#red-ui-workspace-toolbar .button-group:not(.spinner-group) .button:not(:first-child){border-left:none}#red-ui-workspace-toolbar .button-group .button.active{background:var(--red-ui-workspace-button-background-active);cursor:default}#red-ui-workspace-toolbar .spinner-value{width:25px;color:var(--red-ui-workspace-button-color);padding:0 5px;display:inline-block;text-align:center;border-top:1px solid var(--red-ui-secondary-border-color);border-bottom:1px solid var(--red-ui-secondary-border-color);margin:0;height:24px;font-size:12px;background:var(--red-ui-form-input-background);line-height:22px;box-sizing:border-box}#red-ui-notifications{z-index:100;width:500px;margin-left:-250px;left:50%;position:absolute;top:1px}.red-ui-notification{box-sizing:border-box;position:relative;padding:8px 18px 0px;margin-bottom:4px;box-shadow:0 1px 1px 1px var(--red-ui-shadow);background-color:var(--red-ui-secondary-background);color:var(--red-ui-primary-text-color);border:1px solid var(--red-ui-notification-border-default);border-left-width:16px;overflow:hidden}.red-ui-notification .ui-dialog-buttonset{margin-top:20px;margin-bottom:10px}.red-ui-notification p:first-child{font-size:1.1em;font-weight:400}.red-ui-notification a{text-decoration:none}.red-ui-notification a:hover{text-decoration:underline}.red-ui-notification-success{border-color:var(--red-ui-notification-border-success)}.red-ui-notification-warning{border-color:var(--red-ui-notification-border-warning)}.red-ui-notification-error{border-color:var(--red-ui-notification-border-error)}.red-ui-notification-compact .ui-dialog-buttonset{margin-top:0;position:absolute;top:6px;right:10px}.red-ui-notification-compact .ui-dialog-buttonset button{line-height:12px}.red-ui-notification-shake-horizontal{animation:red-ui-notification-shake-horizontal .3s steps(2, end) both}@keyframes red-ui-notification-shake-horizontal{0%,100%{-webkit-transform:translateX(0);transform:translateX(0)}10%,30%,50%,70%{-webkit-transform:translateX(-1px);transform:translateX(-1px)}20%,40%,60%{-webkit-transform:translateX(1px);transform:translateX(1px)}}#red-ui-editor-stack{position:absolute;margin:0;top:0;bottom:0px;right:323px;width:0;z-index:5}.red-ui-tray{position:absolute;margin:0;top:0;width:auto;right:-1000px;bottom:0;background:var(--red-ui-secondary-background);border-left:1px solid var(--red-ui-secondary-border-color);border-bottom:1px solid var(--red-ui-primary-border-color);box-sizing:content-box}.red-ui-tray.open{right:0}.red-ui-tray-body-wrapper{width:100%;box-sizing:border-box;overflow:auto}.red-ui-tray-body{position:relative;box-sizing:border-box;padding:.1px}.red-ui-tray-content{overflow:auto;position:relative}.red-ui-tray-content .red-ui-palette-icon-fa{top:6px;left:4px}.red-ui-tray-header{-webkit-user-select:none;-khtml-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;position:relative;box-sizing:border-box;font-weight:bold;border-bottom:1px solid var(--red-ui-secondary-border-color);background:var(--red-ui-palette-header-background)}.red-ui-tray-header:after{content:"";display:table;clear:both}.red-ui-tray-footer{border-top:1px solid var(--red-ui-primary-border-color);background:var(--red-ui-primary-background);text-align:right;position:absolute;bottom:0;left:0;right:0;height:25px;line-height:25px;padding:0 6px;user-select:none;height:35px;font-size:14px !important;line-height:35px;vertical-align:middle}.red-ui-tray-footer .button-group:not(:last-child){margin-right:5px}.red-ui-tray-footer button.red-ui-button{padding:0px 8px;height:26px;line-height:26px}.red-ui-tray-footer button.red-ui-button.toggle:not(.selected){color:var(--red-ui-workspace-button-color-selected) !important;background:var(--red-ui-workspace-button-background-active)}.red-ui-tray-footer .red-ui-tray-footer-left{display:inline-block;margin-right:20px;float:left}.red-ui-tray-footer .red-ui-tray-footer-right{float:right}.red-ui-tray-toolbar{text-align:right;padding:6px}.red-ui-tray-toolbar button{-webkit-user-select:none;-khtml-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;color:var(--red-ui-workspace-button-color) !important;background:var(--red-ui-workspace-button-background);text-decoration:none;box-sizing:border-box;display:inline-block;border:1px solid var(--red-ui-form-input-border-color);text-align:center;margin:0;cursor:pointer;font-size:14px;padding:6px 14px;margin-right:8px}.red-ui-tray-toolbar button.disabled,.red-ui-tray-toolbar button:disabled{cursor:default;color:var(--red-ui-workspace-button-color-disabled) !important}.red-ui-tray-toolbar button:hover,.red-ui-tray-toolbar button:focus{text-decoration:none}.red-ui-tray-toolbar button:not(.disabled):not(:disabled):hover{color:var(--red-ui-workspace-button-color-hover) !important;background:var(--red-ui-workspace-button-background-hover)}.red-ui-tray-toolbar button:not(.disabled):not(:disabled):focus{color:var(--red-ui-workspace-button-color-focus) !important}.red-ui-tray-toolbar button:not(.disabled):not(:disabled):active{color:var(--red-ui-workspace-button-color-active) !important;background:var(--red-ui-workspace-button-background-active);text-decoration:none}.red-ui-tray-toolbar button.selected:not(.disabled):not(:disabled){color:var(--red-ui-workspace-button-color-selected) !important;background:var(--red-ui-workspace-button-background-active)}.button-group .red-ui-tray-toolbar button:not(:first-child){border-left:none;border-top-left-radius:0;border-bottom-left-radius:0}.button-group .red-ui-tray-toolbar button:not(:last-child){border-top-right-radius:0;border-bottom-right-radius:0}.button-group-vertical .red-ui-tray-toolbar button{display:block;min-width:22px}.button-group-vertical .red-ui-tray-toolbar button:not(:first-child){border-top:none;border-top-left-radius:0;border-top-right-radius:0}.button-group-vertical .red-ui-tray-toolbar button:not(:last-child){border-bottom-left-radius:0;border-bottom-right-radius:0}.button-group .red-ui-tray-toolbar button:focus{position:relative}.button-row .red-ui-tray-toolbar button:not(:first-child){margin-left:15px}.red-ui-tray-toolbar button:focus{outline:1px solid var(--red-ui-workspace-button-color-focus-outline);outline-offset:1px}.red-ui-tray-toolbar button.primary{border-color:var(--red-ui-workspace-button-background-primary);color:var(--red-ui-workspace-button-color-primary) !important;background:var(--red-ui-workspace-button-background-primary)}.red-ui-tray-toolbar button.primary.disabled,.red-ui-tray-toolbar button.primary.ui-state-disabled{background:none;color:var(--red-ui-workspace-button-color) !important;border-color:var(--red-ui-form-input-border-color)}.red-ui-tray-toolbar button.primary:not(.disabled):not(.ui-button-disabled):hover{border-color:var(--red-ui-workspace-button-background-primary-hover);background:var(--red-ui-workspace-button-background-primary-hover);color:var(--red-ui-workspace-button-color-primary) !important}.red-ui-tray-toolbar button.secondary{background:none}.red-ui-tray-toolbar button.secondary:not(:hover){border-color:rgba(0,0,0,0)}.red-ui-tray-toolbar button.disabled{background:none}.red-ui-tray-toolbar button.disabled:focus{outline:none}.red-ui-tray-toolbar button.leftButton{float:left;margin-top:1px}.red-ui-tray-toolbar button:not(.leftButton):not(:last-child){margin-right:16px}.red-ui-tray-toolbar button.ui-state-disabled{opacity:1}.red-ui-tray-toolbar button.toggle{-webkit-user-select:none;-khtml-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;color:var(--red-ui-workspace-button-color) !important;background:var(--red-ui-workspace-button-background);text-decoration:none;box-sizing:border-box;display:inline-block;border:1px solid var(--red-ui-form-input-border-color);text-align:center;margin:0;cursor:pointer}.red-ui-tray-toolbar button.toggle.disabled,.red-ui-tray-toolbar button.toggle:disabled{cursor:default;color:var(--red-ui-workspace-button-color-disabled) !important}.red-ui-tray-toolbar button.toggle:hover,.red-ui-tray-toolbar button.toggle:focus{text-decoration:none}.red-ui-tray-toolbar button.toggle:not(.disabled):not(:disabled):hover{color:var(--red-ui-workspace-button-color-hover) !important;background:var(--red-ui-workspace-button-background-hover)}.red-ui-tray-toolbar button.toggle:not(.disabled):not(:disabled):focus{color:var(--red-ui-workspace-button-color-focus) !important}.red-ui-tray-toolbar button.toggle:not(.disabled):not(:disabled):active{color:var(--red-ui-workspace-button-color-active) !important;background:var(--red-ui-workspace-button-background-active);text-decoration:none}.red-ui-tray-toolbar button.toggle.selected:not(.disabled):not(:disabled){color:var(--red-ui-workspace-button-color-selected) !important;background:var(--red-ui-workspace-button-background-active)}.button-group .red-ui-tray-toolbar button.toggle:not(:first-child){border-left:none;border-top-left-radius:0;border-bottom-left-radius:0}.button-group .red-ui-tray-toolbar button.toggle:not(:last-child){border-top-right-radius:0;border-bottom-right-radius:0}.button-group-vertical .red-ui-tray-toolbar button.toggle{display:block;min-width:22px}.button-group-vertical .red-ui-tray-toolbar button.toggle:not(:first-child){border-top:none;border-top-left-radius:0;border-top-right-radius:0}.button-group-vertical .red-ui-tray-toolbar button.toggle:not(:last-child){border-bottom-left-radius:0;border-bottom-right-radius:0}.button-group .red-ui-tray-toolbar button.toggle:focus{position:relative}.button-row .red-ui-tray-toolbar button.toggle:not(:first-child){margin-left:15px}.red-ui-tray-toolbar button.toggle:focus{outline:1px solid var(--red-ui-workspace-button-color-focus-outline);outline-offset:1px}.red-ui-tray-toolbar button.toggle.primary{border-color:var(--red-ui-workspace-button-background-primary);color:var(--red-ui-workspace-button-color-primary) !important;background:var(--red-ui-workspace-button-background-primary)}.red-ui-tray-toolbar button.toggle.primary.disabled,.red-ui-tray-toolbar button.toggle.primary.ui-state-disabled{background:none;color:var(--red-ui-workspace-button-color) !important;border-color:var(--red-ui-form-input-border-color)}.red-ui-tray-toolbar button.toggle.primary:not(.disabled):not(.ui-button-disabled):hover{border-color:var(--red-ui-workspace-button-background-primary-hover);background:var(--red-ui-workspace-button-background-primary-hover);color:var(--red-ui-workspace-button-color-primary) !important}.red-ui-tray-toolbar button.toggle.secondary{background:none}.red-ui-tray-toolbar button.toggle.secondary:not(:hover){border-color:rgba(0,0,0,0)}.red-ui-tray-toolbar button.toggle:not(.single){margin-bottom:1px}.red-ui-tray-toolbar button.toggle:not(.single).selected:not(.disabled):not(:disabled){border-bottom-width:2px;border-bottom-color:var(--red-ui-form-input-border-selected-color);margin-bottom:0;cursor:default}.red-ui-tray-toolbar button.toggle:not(.single):not(.selected){margin-top:1px}.red-ui-tray-titlebar{color:var(--red-ui-header-text-color);border-bottom:1px solid var(--red-ui-secondary-border-color);padding:8px}.red-ui-editor ul.red-ui-tray-breadcrumbs{list-style-type:none;margin:0;padding:0}.red-ui-editor ul.red-ui-tray-breadcrumbs li{display:inline-block;padding:0;margin:0}.red-ui-editor ul.red-ui-tray-breadcrumbs li:not(:last-child){color:var(--red-ui-workspace-button-color);font-weight:normal}.red-ui-editor ul.red-ui-tray-breadcrumbs li:not(:last-child):after{display:inline-block;content:">";margin:0 5px}.red-ui-tray-resize-handle{position:absolute;top:0px;bottom:0px;width:7px;left:-9px;background-color:var(--red-ui-primary-background);cursor:col-resize;border-left:1px solid var(--red-ui-primary-border-color);box-shadow:-1px 0 6px var(--red-ui-shadow)}.red-ui-tray-resize-handle:before{content:"";display:block;width:100%;height:100%;-webkit-mask-image:url(images/grip.svg);mask-image:url(images/grip.svg);-webkit-mask-size:auto;mask-size:auto;-webkit-mask-position:50% 50%;mask-position:50% 50%;-webkit-mask-repeat:no-repeat;mask-repeat:no-repeat;background-color:var(--red-ui-grip-color)}.red-ui-tray-resize-handle.red-ui-tray-resize-maximised{background:var(--red-ui-primary-background);cursor:default}a.red-ui-tray-resize-button,button.red-ui-tray-resize-button{-webkit-user-select:none;-khtml-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;color:var(--red-ui-workspace-button-color) !important;background:var(--red-ui-workspace-button-background);text-decoration:none;box-sizing:border-box;display:inline-block;border:1px solid var(--red-ui-form-input-border-color);text-align:center;margin:0;cursor:pointer;display:block;height:37px;line-height:35px;border:none;border-bottom:1px solid var(--red-ui-secondary-border-color);margin:0;background:var(--red-ui-primary-background);color:var(--red-ui-workspace-button-color)}a.red-ui-tray-resize-button.disabled,a.red-ui-tray-resize-button:disabled,button.red-ui-tray-resize-button.disabled,button.red-ui-tray-resize-button:disabled{cursor:default;color:var(--red-ui-workspace-button-color-disabled) !important}a.red-ui-tray-resize-button:hover,a.red-ui-tray-resize-button:focus,button.red-ui-tray-resize-button:hover,button.red-ui-tray-resize-button:focus{text-decoration:none}a.red-ui-tray-resize-button:not(.disabled):not(:disabled):hover,button.red-ui-tray-resize-button:not(.disabled):not(:disabled):hover{color:var(--red-ui-workspace-button-color-hover) !important;background:var(--red-ui-workspace-button-background-hover)}a.red-ui-tray-resize-button:not(.disabled):not(:disabled):focus,button.red-ui-tray-resize-button:not(.disabled):not(:disabled):focus{color:var(--red-ui-workspace-button-color-focus) !important}a.red-ui-tray-resize-button:not(.disabled):not(:disabled):active,button.red-ui-tray-resize-button:not(.disabled):not(:disabled):active{color:var(--red-ui-workspace-button-color-active) !important;background:var(--red-ui-workspace-button-background-active);text-decoration:none}a.red-ui-tray-resize-button.selected:not(.disabled):not(:disabled),button.red-ui-tray-resize-button.selected:not(.disabled):not(:disabled){color:var(--red-ui-workspace-button-color-selected) !important;background:var(--red-ui-workspace-button-background-active)}.button-group a.red-ui-tray-resize-button:not(:first-child),.button-group button.red-ui-tray-resize-button:not(:first-child){border-left:none;border-top-left-radius:0;border-bottom-left-radius:0}.button-group a.red-ui-tray-resize-button:not(:last-child),.button-group button.red-ui-tray-resize-button:not(:last-child){border-top-right-radius:0;border-bottom-right-radius:0}.button-group-vertical a.red-ui-tray-resize-button,.button-group-vertical button.red-ui-tray-resize-button{display:block;min-width:22px}.button-group-vertical a.red-ui-tray-resize-button:not(:first-child),.button-group-vertical button.red-ui-tray-resize-button:not(:first-child){border-top:none;border-top-left-radius:0;border-top-right-radius:0}.button-group-vertical a.red-ui-tray-resize-button:not(:last-child),.button-group-vertical button.red-ui-tray-resize-button:not(:last-child){border-bottom-left-radius:0;border-bottom-right-radius:0}.button-group a.red-ui-tray-resize-button:focus,.button-group button.red-ui-tray-resize-button:focus{position:relative}.button-row a.red-ui-tray-resize-button:not(:first-child),.button-row button.red-ui-tray-resize-button:not(:first-child){margin-left:15px}a.red-ui-tray-resize-button:focus,button.red-ui-tray-resize-button:focus{outline:1px solid var(--red-ui-workspace-button-color-focus-outline);outline-offset:1px}a.red-ui-tray-resize-button.primary,button.red-ui-tray-resize-button.primary{border-color:var(--red-ui-workspace-button-background-primary);color:var(--red-ui-workspace-button-color-primary) !important;background:var(--red-ui-workspace-button-background-primary)}a.red-ui-tray-resize-button.primary.disabled,a.red-ui-tray-resize-button.primary.ui-state-disabled,button.red-ui-tray-resize-button.primary.disabled,button.red-ui-tray-resize-button.primary.ui-state-disabled{background:none;color:var(--red-ui-workspace-button-color) !important;border-color:var(--red-ui-form-input-border-color)}a.red-ui-tray-resize-button.primary:not(.disabled):not(.ui-button-disabled):hover,button.red-ui-tray-resize-button.primary:not(.disabled):not(.ui-button-disabled):hover{border-color:var(--red-ui-workspace-button-background-primary-hover);background:var(--red-ui-workspace-button-background-primary-hover);color:var(--red-ui-workspace-button-color-primary) !important}a.red-ui-tray-resize-button.secondary,button.red-ui-tray-resize-button.secondary{background:none}a.red-ui-tray-resize-button.secondary:not(:hover),button.red-ui-tray-resize-button.secondary:not(:hover){border-color:rgba(0,0,0,0)}.red-ui-editor .red-ui-tray .dialog-form,.red-ui-editor .red-ui-tray #dialog-form,.red-ui-editor .red-ui-tray #node-config-dialog-edit-form{margin:10px 20px;height:calc(100% - 20px)}.red-ui-editor .dialog-form,.red-ui-editor #dialog-form,.red-ui-editor #node-config-dialog-edit-form,.red-ui-editor-dialog .dialog-form,.red-ui-editor-dialog #dialog-form,.red-ui-editor-dialog #node-config-dialog-edit-form{margin:0;height:100%}.red-ui-editor .input-error,.red-ui-editor-dialog .input-error{border-color:var(--red-ui-form-input-border-error-color) !important}.red-ui-editor .input-updated,.red-ui-editor-dialog .input-updated{border-color:var(--red-ui-node-selected-color) !important}.red-ui-editor .form-row,.red-ui-editor-dialog .form-row{clear:both;color:var(--red-ui-form-text-color);margin-bottom:12px}.red-ui-editor .form-row label,.red-ui-editor-dialog .form-row label{display:inline-block;width:100px}.red-ui-editor .form-row input,.red-ui-editor .form-row div[contenteditable=true],.red-ui-editor-dialog .form-row input,.red-ui-editor-dialog .form-row div[contenteditable=true]{width:70%}.red-ui-editor .form-tips,.red-ui-editor-dialog .form-tips{background:var(--red-ui-form-tips-background);padding:8px;border-radius:2px;border:1px solid var(--red-ui-secondary-border-color);max-width:450px}.red-ui-editor .form-tips code,.red-ui-editor-dialog .form-tips code{border:none;padding:auto}.red-ui-editor .form-tips a,.red-ui-editor-dialog .form-tips a{text-decoration:underline}.red-ui-editor .form-warning,.red-ui-editor-dialog .form-warning{border-color:var(--red-ui-text-color-error)}.node-text-editor{position:relative}.node-text-editor .red-ui-editor-text-help{position:absolute;bottom:0px;right:1px;border-bottom-right-radius:5px;z-Index:8;border-bottom:none;border-right:none}.red-ui-editor-text-container{border:1px solid var(--red-ui-tertiary-border-color);border-radius:5px;overflow:hidden;font-size:var(--red-ui-primary-font-size !important);font-family:var(--red-ui-monospace-font !important);height:100%}.red-ui-editor-text-container.red-ui-editor-text-container-toolbar{height:calc(100% - 40px)}a.editor-button,button.editor-button,a.red-ui-button,button.red-ui-button{-webkit-user-select:none;-khtml-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;color:var(--red-ui-workspace-button-color) !important;background:var(--red-ui-workspace-button-background);text-decoration:none;box-sizing:border-box;display:inline-block;border:1px solid var(--red-ui-form-input-border-color);text-align:center;margin:0;cursor:pointer;height:34px;line-height:32px;font-size:13px;border-radius:2px;padding:0 10px;white-space:nowrap;text-overflow:ellipsis}a.editor-button.disabled,a.editor-button:disabled,button.editor-button.disabled,button.editor-button:disabled,a.red-ui-button.disabled,a.red-ui-button:disabled,button.red-ui-button.disabled,button.red-ui-button:disabled{cursor:default;color:var(--red-ui-workspace-button-color-disabled) !important}a.editor-button:hover,a.editor-button:focus,button.editor-button:hover,button.editor-button:focus,a.red-ui-button:hover,a.red-ui-button:focus,button.red-ui-button:hover,button.red-ui-button:focus{text-decoration:none}a.editor-button:not(.disabled):not(:disabled):hover,button.editor-button:not(.disabled):not(:disabled):hover,a.red-ui-button:not(.disabled):not(:disabled):hover,button.red-ui-button:not(.disabled):not(:disabled):hover{color:var(--red-ui-workspace-button-color-hover) !important;background:var(--red-ui-workspace-button-background-hover)}a.editor-button:not(.disabled):not(:disabled):focus,button.editor-button:not(.disabled):not(:disabled):focus,a.red-ui-button:not(.disabled):not(:disabled):focus,button.red-ui-button:not(.disabled):not(:disabled):focus{color:var(--red-ui-workspace-button-color-focus) !important}a.editor-button:not(.disabled):not(:disabled):active,button.editor-button:not(.disabled):not(:disabled):active,a.red-ui-button:not(.disabled):not(:disabled):active,button.red-ui-button:not(.disabled):not(:disabled):active{color:var(--red-ui-workspace-button-color-active) !important;background:var(--red-ui-workspace-button-background-active);text-decoration:none}a.editor-button.selected:not(.disabled):not(:disabled),button.editor-button.selected:not(.disabled):not(:disabled),a.red-ui-button.selected:not(.disabled):not(:disabled),button.red-ui-button.selected:not(.disabled):not(:disabled){color:var(--red-ui-workspace-button-color-selected) !important;background:var(--red-ui-workspace-button-background-active)}.button-group a.editor-button:not(:first-child),.button-group button.editor-button:not(:first-child),.button-group a.red-ui-button:not(:first-child),.button-group button.red-ui-button:not(:first-child){border-left:none;border-top-left-radius:0;border-bottom-left-radius:0}.button-group a.editor-button:not(:last-child),.button-group button.editor-button:not(:last-child),.button-group a.red-ui-button:not(:last-child),.button-group button.red-ui-button:not(:last-child){border-top-right-radius:0;border-bottom-right-radius:0}.button-group-vertical a.editor-button,.button-group-vertical button.editor-button,.button-group-vertical a.red-ui-button,.button-group-vertical button.red-ui-button{display:block;min-width:22px}.button-group-vertical a.editor-button:not(:first-child),.button-group-vertical button.editor-button:not(:first-child),.button-group-vertical a.red-ui-button:not(:first-child),.button-group-vertical button.red-ui-button:not(:first-child){border-top:none;border-top-left-radius:0;border-top-right-radius:0}.button-group-vertical a.editor-button:not(:last-child),.button-group-vertical button.editor-button:not(:last-child),.button-group-vertical a.red-ui-button:not(:last-child),.button-group-vertical button.red-ui-button:not(:last-child){border-bottom-left-radius:0;border-bottom-right-radius:0}.button-group a.editor-button:focus,.button-group button.editor-button:focus,.button-group a.red-ui-button:focus,.button-group button.red-ui-button:focus{position:relative}.button-row a.editor-button:not(:first-child),.button-row button.editor-button:not(:first-child),.button-row a.red-ui-button:not(:first-child),.button-row button.red-ui-button:not(:first-child){margin-left:15px}a.editor-button:focus,button.editor-button:focus,a.red-ui-button:focus,button.red-ui-button:focus{outline:1px solid var(--red-ui-workspace-button-color-focus-outline);outline-offset:1px}a.editor-button.primary,button.editor-button.primary,a.red-ui-button.primary,button.red-ui-button.primary{border-color:var(--red-ui-workspace-button-background-primary);color:var(--red-ui-workspace-button-color-primary) !important;background:var(--red-ui-workspace-button-background-primary)}a.editor-button.primary.disabled,a.editor-button.primary.ui-state-disabled,button.editor-button.primary.disabled,button.editor-button.primary.ui-state-disabled,a.red-ui-button.primary.disabled,a.red-ui-button.primary.ui-state-disabled,button.red-ui-button.primary.disabled,button.red-ui-button.primary.ui-state-disabled{background:none;color:var(--red-ui-workspace-button-color) !important;border-color:var(--red-ui-form-input-border-color)}a.editor-button.primary:not(.disabled):not(.ui-button-disabled):hover,button.editor-button.primary:not(.disabled):not(.ui-button-disabled):hover,a.red-ui-button.primary:not(.disabled):not(.ui-button-disabled):hover,button.red-ui-button.primary:not(.disabled):not(.ui-button-disabled):hover{border-color:var(--red-ui-workspace-button-background-primary-hover);background:var(--red-ui-workspace-button-background-primary-hover);color:var(--red-ui-workspace-button-color-primary) !important}a.editor-button.secondary,button.editor-button.secondary,a.red-ui-button.secondary,button.red-ui-button.secondary{background:none}a.editor-button.secondary:not(:hover),button.editor-button.secondary:not(:hover),a.red-ui-button.secondary:not(:hover),button.red-ui-button.secondary:not(:hover){border-color:rgba(0,0,0,0)}a.editor-button.toggle,button.editor-button.toggle,a.red-ui-button.toggle,button.red-ui-button.toggle{-webkit-user-select:none;-khtml-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;color:var(--red-ui-workspace-button-color) !important;background:var(--red-ui-workspace-button-background);text-decoration:none;box-sizing:border-box;display:inline-block;border:1px solid var(--red-ui-form-input-border-color);text-align:center;margin:0;cursor:pointer}a.editor-button.toggle.disabled,a.editor-button.toggle:disabled,button.editor-button.toggle.disabled,button.editor-button.toggle:disabled,a.red-ui-button.toggle.disabled,a.red-ui-button.toggle:disabled,button.red-ui-button.toggle.disabled,button.red-ui-button.toggle:disabled{cursor:default;color:var(--red-ui-workspace-button-color-disabled) !important}a.editor-button.toggle:hover,a.editor-button.toggle:focus,button.editor-button.toggle:hover,button.editor-button.toggle:focus,a.red-ui-button.toggle:hover,a.red-ui-button.toggle:focus,button.red-ui-button.toggle:hover,button.red-ui-button.toggle:focus{text-decoration:none}a.editor-button.toggle:not(.disabled):not(:disabled):hover,button.editor-button.toggle:not(.disabled):not(:disabled):hover,a.red-ui-button.toggle:not(.disabled):not(:disabled):hover,button.red-ui-button.toggle:not(.disabled):not(:disabled):hover{color:var(--red-ui-workspace-button-color-hover) !important;background:var(--red-ui-workspace-button-background-hover)}a.editor-button.toggle:not(.disabled):not(:disabled):focus,button.editor-button.toggle:not(.disabled):not(:disabled):focus,a.red-ui-button.toggle:not(.disabled):not(:disabled):focus,button.red-ui-button.toggle:not(.disabled):not(:disabled):focus{color:var(--red-ui-workspace-button-color-focus) !important}a.editor-button.toggle:not(.disabled):not(:disabled):active,button.editor-button.toggle:not(.disabled):not(:disabled):active,a.red-ui-button.toggle:not(.disabled):not(:disabled):active,button.red-ui-button.toggle:not(.disabled):not(:disabled):active{color:var(--red-ui-workspace-button-color-active) !important;background:var(--red-ui-workspace-button-background-active);text-decoration:none}a.editor-button.toggle.selected:not(.disabled):not(:disabled),button.editor-button.toggle.selected:not(.disabled):not(:disabled),a.red-ui-button.toggle.selected:not(.disabled):not(:disabled),button.red-ui-button.toggle.selected:not(.disabled):not(:disabled){color:var(--red-ui-workspace-button-color-selected) !important;background:var(--red-ui-workspace-button-background-active)}.button-group a.editor-button.toggle:not(:first-child),.button-group button.editor-button.toggle:not(:first-child),.button-group a.red-ui-button.toggle:not(:first-child),.button-group button.red-ui-button.toggle:not(:first-child){border-left:none;border-top-left-radius:0;border-bottom-left-radius:0}.button-group a.editor-button.toggle:not(:last-child),.button-group button.editor-button.toggle:not(:last-child),.button-group a.red-ui-button.toggle:not(:last-child),.button-group button.red-ui-button.toggle:not(:last-child){border-top-right-radius:0;border-bottom-right-radius:0}.button-group-vertical a.editor-button.toggle,.button-group-vertical button.editor-button.toggle,.button-group-vertical a.red-ui-button.toggle,.button-group-vertical button.red-ui-button.toggle{display:block;min-width:22px}.button-group-vertical a.editor-button.toggle:not(:first-child),.button-group-vertical button.editor-button.toggle:not(:first-child),.button-group-vertical a.red-ui-button.toggle:not(:first-child),.button-group-vertical button.red-ui-button.toggle:not(:first-child){border-top:none;border-top-left-radius:0;border-top-right-radius:0}.button-group-vertical a.editor-button.toggle:not(:last-child),.button-group-vertical button.editor-button.toggle:not(:last-child),.button-group-vertical a.red-ui-button.toggle:not(:last-child),.button-group-vertical button.red-ui-button.toggle:not(:last-child){border-bottom-left-radius:0;border-bottom-right-radius:0}.button-group a.editor-button.toggle:focus,.button-group button.editor-button.toggle:focus,.button-group a.red-ui-button.toggle:focus,.button-group button.red-ui-button.toggle:focus{position:relative}.button-row a.editor-button.toggle:not(:first-child),.button-row button.editor-button.toggle:not(:first-child),.button-row a.red-ui-button.toggle:not(:first-child),.button-row button.red-ui-button.toggle:not(:first-child){margin-left:15px}a.editor-button.toggle:focus,button.editor-button.toggle:focus,a.red-ui-button.toggle:focus,button.red-ui-button.toggle:focus{outline:1px solid var(--red-ui-workspace-button-color-focus-outline);outline-offset:1px}a.editor-button.toggle.primary,button.editor-button.toggle.primary,a.red-ui-button.toggle.primary,button.red-ui-button.toggle.primary{border-color:var(--red-ui-workspace-button-background-primary);color:var(--red-ui-workspace-button-color-primary) !important;background:var(--red-ui-workspace-button-background-primary)}a.editor-button.toggle.primary.disabled,a.editor-button.toggle.primary.ui-state-disabled,button.editor-button.toggle.primary.disabled,button.editor-button.toggle.primary.ui-state-disabled,a.red-ui-button.toggle.primary.disabled,a.red-ui-button.toggle.primary.ui-state-disabled,button.red-ui-button.toggle.primary.disabled,button.red-ui-button.toggle.primary.ui-state-disabled{background:none;color:var(--red-ui-workspace-button-color) !important;border-color:var(--red-ui-form-input-border-color)}a.editor-button.toggle.primary:not(.disabled):not(.ui-button-disabled):hover,button.editor-button.toggle.primary:not(.disabled):not(.ui-button-disabled):hover,a.red-ui-button.toggle.primary:not(.disabled):not(.ui-button-disabled):hover,button.red-ui-button.toggle.primary:not(.disabled):not(.ui-button-disabled):hover{border-color:var(--red-ui-workspace-button-background-primary-hover);background:var(--red-ui-workspace-button-background-primary-hover);color:var(--red-ui-workspace-button-color-primary) !important}a.editor-button.toggle.secondary,button.editor-button.toggle.secondary,a.red-ui-button.toggle.secondary,button.red-ui-button.toggle.secondary{background:none}a.editor-button.toggle.secondary:not(:hover),button.editor-button.toggle.secondary:not(:hover),a.red-ui-button.toggle.secondary:not(:hover),button.red-ui-button.toggle.secondary:not(:hover){border-color:rgba(0,0,0,0)}a.editor-button.toggle:not(.single),button.editor-button.toggle:not(.single),a.red-ui-button.toggle:not(.single),button.red-ui-button.toggle:not(.single){margin-bottom:1px}a.editor-button.toggle:not(.single).selected:not(.disabled):not(:disabled),button.editor-button.toggle:not(.single).selected:not(.disabled):not(:disabled),a.red-ui-button.toggle:not(.single).selected:not(.disabled):not(:disabled),button.red-ui-button.toggle:not(.single).selected:not(.disabled):not(:disabled){border-bottom-width:2px;border-bottom-color:var(--red-ui-form-input-border-selected-color);margin-bottom:0;cursor:default}a.editor-button.toggle:not(.single):not(.selected),button.editor-button.toggle:not(.single):not(.selected),a.red-ui-button.toggle:not(.single):not(.selected),button.red-ui-button.toggle:not(.single):not(.selected){margin-top:1px}a.editor-button-small,button.editor-button-small,a.red-ui-button-small,button.red-ui-button-small{height:20px;min-width:20px;line-height:18px;font-size:10px;border-radius:2px;padding:0 5px}#red-ui-editor-config-scope-warning{display:inline-block;margin-right:5px;color:var(--red-ui-text-color-warning);vertical-align:middle}#red-ui-editor-config-scope{margin:1px 0 0 0;padding:0;height:22px;width:200px}.red-ui-editor .red-ui-tray .red-ui-editor-type-expression #dialog-form{margin:0;height:100%}.red-ui-editor .red-ui-tray .red-ui-editor-type-expression #dialog-form .red-ui-panel:first-child{padding:20px 20px 0}.red-ui-editor-type-expression-tab-content{position:relative;padding:0 20px}#red-ui-editor-type-expression-help{position:absolute;top:35px;left:0;right:0;bottom:0;padding:0 20px;overflow:auto;box-sizing:border-box}#red-ui-editor-type-expression-panel-info>.form-row{margin:0}#red-ui-editor-type-expression-panel-info>.form-row>div:first-child{margin-top:10px}.red-ui-editor-type-expression-legacy{float:left}.red-ui-editor-type-buffer-type{text-align:right}.red-ui-editor .red-ui-tray .red-ui-editor-type-markdown-editor #dialog-form{margin:0;height:100%}.red-ui-editor .red-ui-tray .red-ui-editor-type-markdown-editor #dialog-form .red-ui-panel{padding:20px 20px 10px}.red-ui-editor .red-ui-tray .red-ui-editor-type-markdown-editor #dialog-form .red-ui-panel:last-child{padding-top:60px;background:var(--red-ui-primary-background)}.red-ui-editor-type-markdown-panel-preview{padding:10px;border:1px solid var(--red-ui-secondary-border-color);border-radius:5px;height:calc(100% - 21px);overflow-y:auto;background:var(--red-ui-secondary-background)}#red-ui-clipboard-hidden{position:absolute;top:-3000px}.form-row .red-ui-editor-node-label-form-row{margin:5px 0 0 50px}.form-row .red-ui-editor-node-label-form-row label{margin-right:20px;text-align:right;width:30px}.form-row .red-ui-editor-node-label-form-row button{margin-left:10px}.form-row .red-ui-editor-node-label-form-row input{width:calc(100% - 100px)}.form-row .red-ui-editor-node-label-form-row #red-ui-editor-node-icon-module{width:calc(55% - 50px)}.form-row .red-ui-editor-node-label-form-row #red-ui-editor-node-icon-file{width:calc(45% - 55px);margin-left:5px}.red-ui-editor-node-label-form-none span{padding-left:50px;width:100px;color:var(--red-ui-secondary-text-color)}button.red-ui-button.red-ui-editor-node-appearance-button{position:relative;height:35px !important;text-align:left;padding:0 6px 0 3px}button.red-ui-button.red-ui-editor-node-appearance-button>i{width:15px;vertical-align:middle;padding-left:2px}button.red-ui-button.red-ui-editor-node-appearance-button .red-ui-search-result-node{vertical-align:middle;float:none;position:relative;top:-1px}.red-ui-group-layout-picker{padding:5px;background:var(--red-ui-secondary-background)}.red-ui-group-layout-picker-cell-text{position:absolute;width:14px;height:2px;border-top:2px solid var(--red-ui-secondary-text-color);border-bottom:2px solid var(--red-ui-secondary-text-color);margin:2px}.red-ui-group-layout-picker-cell-text.red-ui-group-layout-text-pos-nw{top:0;left:0}.red-ui-group-layout-picker-cell-text.red-ui-group-layout-text-pos-n{top:0;left:calc(50% - 9px)}.red-ui-group-layout-picker-cell-text.red-ui-group-layout-text-pos-ne{top:0;right:0}.red-ui-group-layout-picker-cell-text.red-ui-group-layout-text-pos-sw{bottom:0;left:0}.red-ui-group-layout-picker-cell-text.red-ui-group-layout-text-pos-s{bottom:0;left:calc(50% - 9px)}.red-ui-group-layout-picker-cell-text.red-ui-group-layout-text-pos-se{bottom:0;right:0}.red-ui-group-layout-picker-cell-text.red-ui-group-layout-text-pos-{width:100%;height:100%;border-radius:5px;margin:0;background-color:#fff;background-size:100% 100%;background-position:0 0,50% 50%;background-image:linear-gradient(45deg, transparent 45%, var(--red-ui-secondary-border-color) 45%, var(--red-ui-secondary-border-color) 55%, transparent 55%, transparent),linear-gradient(-45deg, transparent 45%, var(--red-ui-secondary-border-color) 45%, var(--red-ui-secondary-border-color) 55%, transparent 55%, transparent);border:none}.red-ui-group-layout-picker button.red-ui-search-result-node{float:none;position:relative;padding:0;margin:5px;width:32px;height:27px}button.red-ui-group-layout-picker-none{width:100%}.red-ui-color-picker{background:var(--red-ui-primary-background)}.red-ui-color-picker input[type=text]{border-radius:0;width:100%;margin-bottom:0;border:none;border-bottom:1px solid var(--red-ui-form-input-border-color)}.red-ui-color-picker small{color:var(--red-ui-secondary-text-color);margin-left:5px;margin-right:4px;display:inline-block;min-width:35px;text-align:right}.red-ui-editor-node-appearance-button .red-ui-search-result-node{overflow:hidden}.red-ui-color-picker-cell{padding:0;border-style:solid;border-width:1px;border-color:var(--red-ui-secondary-border-color)}.red-ui-color-picker-swatch{position:absolute;top:-1px;right:-1px;left:-1px;bottom:-1px;border-radius:4px}.red-ui-color-picker-cell-none{height:100%;background-color:#fff;background-size:100% 100%;background-position:0 0,50% 50%;background-image:linear-gradient(45deg, transparent 45%, var(--red-ui-secondary-border-color) 45%, var(--red-ui-secondary-border-color) 55%, transparent 55%, transparent),linear-gradient(-45deg, transparent 45%, var(--red-ui-secondary-border-color) 45%, var(--red-ui-secondary-border-color) 55%, transparent 55%, transparent)}.red-ui-search-result-node .red-ui-color-picker-cell-none{border-radius:4px;background-size:50% 50%;background-image:linear-gradient(45deg, #eee 25%, transparent 25%, transparent 75%, #eee 75%, #eee),linear-gradient(45deg, #eee 25%, transparent 25%, transparent 75%, #eee 75%, #eee)}.red-ui-color-picker-opacity-slider{position:relative;vertical-align:middle;display:inline-block;width:calc(100% - 50px);height:14px;margin:6px 3px 8px;box-sizing:border-box;background-color:#fff;background-image:linear-gradient(45deg, #eee 25%, transparent 25%, transparent 75%, #eee 25%),linear-gradient(-45deg, #eee 25%, transparent 25%, transparent 75%, #eee 25%);background-size:6px 6px}.red-ui-color-picker-opacity-slider-overlay{position:absolute;top:0;right:0;left:0;bottom:0;background-image:linear-gradient(90deg, transparent 0%, #f00 100%);background-size:100% 100%;border:1px solid var(--red-ui-primary-border-color)}div.red-ui-button-small.red-ui-color-picker-opacity-slider-handle{z-Index:10;top:-4px;cursor:pointer;min-width:0;width:10px;height:22px;padding:0;border:1px solid var(--red-ui-primary-border-color);border-radius:1px;background:var(--red-ui-secondary-background);box-sizing:border-box}.red-ui-icon-picker select{box-sizing:border-box;margin:3px;width:calc(100% - 6px)}.red-ui-icon-list{width:308px;height:200px;overflow-y:auto;line-height:0px;position:relative}.red-ui-icon-list.red-ui-icon-list-dark .red-ui-palette-icon-fa{color:var(--red-ui-secondary-text-color)}.red-ui-icon-list.red-ui-icon-list-dark .red-ui-palette-icon-container{background:var(--red-ui-secondary-background);border-radius:4px}.red-ui-icon-list-icon{display:inline-block;margin:2px;padding:4px;cursor:pointer;border-radius:4px}.red-ui-icon-list-icon:hover{background:var(--red-ui-list-item-background-hover)}.red-ui-icon-list-icon.selected{background:var(--red-ui-list-item-background-selected)}.red-ui-icon-list-icon .red-ui-palette-icon-fa{top:6px;left:3px}.red-ui-icon-list-module{background:var(--red-ui-palette-header-background);font-size:.9em;padding:3px;color:var(--red-ui-secondary-text-color);clear:both}.red-ui-icon-list-module i{margin-right:5px}.red-ui-icon-meta{border-top:1px solid var(--red-ui-secondary-border-color);background:var(--red-ui-tertiary-background);height:24px}.red-ui-icon-meta span{padding:4px;color:var(--red-ui-secondary-text-color);font-size:.9em;line-height:24px}.red-ui-icon-meta button{float:right;margin:2px}.red-ui-editor input.red-ui-editor-type-json-editor-key{width:150px}.red-ui-editor-type-json-editor{height:calc(100% - 10px)}.red-ui-editor-type-json-editor .red-ui-treeList-container{background:var(--red-ui-secondary-background)}.red-ui-editor-type-json-editor .red-ui-treeList-label{padding-top:0;padding-bottom:0;white-space:nowrap;min-height:35px}.red-ui-editor-type-json-editor .red-ui-treeList-label .red-ui-treeList-icon:before{content:"";display:inline-block;height:35px;vertical-align:middle}.red-ui-editor-type-json-editor .red-ui-treeList-label>span,.red-ui-editor-type-json-editor .red-ui-treeList-label>span>span{vertical-align:middle}.red-ui-editor-type-json-editor .red-ui-treeList-label:hover,.red-ui-editor-type-json-editor .red-ui-treeList-label:hover .red-ui-treeList-sublabel-text{background:var(--red-ui-secondary-background-disabled)}.red-ui-editor-type-json-editor .red-ui-treeList-label:hover .red-ui-editor-type-json-editor-item-gutter>span,.red-ui-editor-type-json-editor .red-ui-treeList-label:hover .red-ui-editor-type-json-editor-item-gutter>button,.red-ui-editor-type-json-editor .red-ui-treeList-label:hover .red-ui-treeList-sublabel-text .red-ui-editor-type-json-editor-item-gutter>span,.red-ui-editor-type-json-editor .red-ui-treeList-label:hover .red-ui-treeList-sublabel-text .red-ui-editor-type-json-editor-item-gutter>button{display:inline-block}.red-ui-editor-type-json-editor .red-ui-treeList-label.selected .red-ui-editor-type-json-editor-item-gutter{background:var(--red-ui-secondary-background-hover)}.red-ui-editor-type-json-editor .red-ui-treeList-label.selected:hover .red-ui-editor-type-json-editor-item-gutter{background:var(--red-ui-secondary-background-selected)}.red-ui-editor-type-json-editor .red-ui-treeList-label.red-ui-editor-type-json-root-node .red-ui-editor-type-json-editor-item-gutter>span,.red-ui-editor-type-json-editor .red-ui-treeList-label.red-ui-editor-type-json-root-node .red-ui-editor-type-json-editor-item-gutter>button{display:inline-block}.red-ui-editor-type-json-editor-controls{height:34px;line-height:34px;display:none}.red-ui-editor-type-json-editor-key{width:100px}.red-ui-editor-type-json-editor-label{display:inline-block;white-space:pre-wrap}.red-ui-editor-type-json-editor-label-value{min-width:200px}.red-ui-editor-type-json-editor-label-value,.red-ui-editor-type-json-editor-label-key{display:inline-block;box-sizing:border-box;min-height:34px;line-height:30px;padding:0 2px;border:2px solid rgba(0,0,0,0);border-radius:3px}.red-ui-editor-type-json-editor-label-value:not(.red-ui-editor-type-json-editor-label-array-key):hover,.red-ui-editor-type-json-editor-label-key:not(.red-ui-editor-type-json-editor-label-array-key):hover{border-color:var(--red-ui-list-item-background-hover);border-style:dashed}.red-ui-editor-type-json-editor-label-value.readonly,.red-ui-editor-type-json-editor-label-key.readonly{cursor:pointer;pointer-events:none}.red-ui-editor-type-json-editor-item-gutter{width:48px;padding-left:4px;height:100%;line-height:35px;color:var(--red-ui-tertiary-text-color);background:var(--red-ui-secondary-background-disabled)}.red-ui-editor-type-json-editor-item-gutter>span{display:inline-block;height:35px;line-height:35px;width:20px;text-align:center}.red-ui-editor-type-json-editor-item-gutter>span,.red-ui-editor-type-json-editor-item-gutter>button{display:none}.red-ui-editor-type-json-editor-item-gutter.readonly{cursor:pointer;pointer-events:none}.red-ui-editor-type-json-editor-item-handle{cursor:move}.red-ui-editor-type-json-tab-content{position:relative;height:calc(100% - 40px)}button.red-ui-toggleButton.toggle{text-align:left}button.red-ui-toggleButton.toggle i{min-width:15px}.red-ui-editor-subflow-env-ui-row{margin-right:3px}.red-ui-editor-subflow-env-ui-row>div{display:grid;grid-template-columns:16px 40px 35% auto}.red-ui-editor-subflow-env-ui-row>div:first-child{font-size:.9em;color:var(--red-ui-tertiary-text-color);margin:3px 0 -4px}.red-ui-editor-subflow-env-ui-row>div:first-child>div{padding-left:3px}.red-ui-editor-subflow-env-ui-row>div:last-child>div{height:40px;line-height:30px;display:inline-block;box-sizing:border-box;border-right:none}.red-ui-editor-subflow-env-ui-row>div:last-child>div:not(:first-child){padding:3px}.red-ui-editor-subflow-env-ui-row>div:last-child>div .placeholder-input{position:relative;padding:0 3px;line-height:24px;opacity:.8}.red-ui-editor-subflow-env-ui-row>div:last-child>div .red-ui-typedInput-value-label select,.red-ui-editor-subflow-env-ui-row>div:last-child>div .red-ui-typedInput-value-label .placeholder-input,.red-ui-editor-subflow-env-ui-row>div:last-child>div .red-ui-typedInput-option-label select,.red-ui-editor-subflow-env-ui-row>div:last-child>div .red-ui-typedInput-option-label .placeholder-input{margin:3px;height:24px;width:calc(100% - 10px);padding-left:3px}.red-ui-editor-subflow-env-ui-row>div:last-child>div .red-ui-typedInput-value-label select,.red-ui-editor-subflow-env-ui-row>div:last-child>div .red-ui-typedInput-option-label select{padding:0 3px;font-size:11px}.red-ui-editor-subflow-env-ui-row>div:last-child>div .red-ui-typedInput-value-label .placeholder-input span:first-child,.red-ui-editor-subflow-env-ui-row>div:last-child>div .red-ui-typedInput-option-label .placeholder-input span:first-child{display:inline-block;height:100%;width:20px;text-align:center;border-right:1px solid var(--red-ui-secondary-border-color);background:var(--red-ui-tertiary-background)}.red-ui-editor-subflow-env-ui-row>div:last-child>div .red-ui-typedInput-value-label input[type=checkbox],.red-ui-editor-subflow-env-ui-row>div:last-child>div .red-ui-typedInput-option-label input[type=checkbox]{margin-left:8px;margin-top:0;height:100%}.red-ui-editor-subflow-env-ui-row>div:last-child>div:nth-child(1){border:none;padding:2px}.red-ui-editor-subflow-env-ui-row>div:last-child>div:nth-child(1) .red-ui-editableList-item-handle{position:relative;top:0px;color:var(--red-ui-tertiary-text-color)}.red-ui-editor-subflow-env-ui-row>div:last-child>div:nth-child(2){margin:4px;height:32px;border:1px dashed var(--red-ui-secondary-border-color);text-align:center}.red-ui-editor-subflow-env-ui-row>div:last-child>div:nth-child(2) a{display:block;width:100%;height:100%;line-height:32px}.red-ui-editor-subflow-env-ui-row>div:last-child>div:nth-child(2) a:hover{background:var(--red-ui-secondary-background-hover)}.red-ui-editor-subflow-env-ui-row>div:last-child>div:nth-child(2) a i{height:100%;vertical-align:middle}.red-ui-editor-subflow-env-ui-row>div:last-child>div:nth-child(3){position:relative}.red-ui-editor-subflow-env-ui-row>div:last-child>div:nth-child(3) input{width:100%}span.red-ui-editor-subflow-env-lang-icon{position:absolute;display:inline-block;background:var(--red-ui-secondary-background);opacity:.8;width:20px;line-height:32px;height:32px;text-align:center;top:4px;right:4px;border-top-right-radius:4px;border-bottom-right-radius:4px}.red-ui-editor-subflow-env-input-type{background:var(--red-ui-secondary-background);height:100%;box-sizing:border-box}.red-ui-editor-subflow-env-input-type-placeholder{color:var(--red-ui-tertiary-text-color);padding-left:4px}.red-ui-editor-subflow-ui-edit-panel{padding-bottom:3px;background:var(--red-ui-primary-background)}.red-ui-editor-subflow-ui-edit-panel .red-ui-editableList-border{border:none;border-radius:0;border-bottom:1px solid var(--red-ui-secondary-border-color)}.red-ui-editor-subflow-ui-edit-panel .red-ui-editableList-addButton{margin-left:2px}.red-ui-editor-subflow-ui-edit-panel .red-ui-editableList-header{background:var(--red-ui-primary-background);display:grid;grid-template-columns:50% 50%;color:var(--red-ui-secondary-text-color)}.red-ui-editor-subflow-ui-edit-panel .red-ui-editableList-header div:first-child{padding-left:23px}.red-ui-editor-subflow-ui-edit-panel .red-ui-editableList-header div:last-child{padding-left:3px}.red-ui-editor-subflow-ui-edit-panel .red-ui-editableList-container{padding:0 1px}.red-ui-editor-subflow-ui-edit-panel .red-ui-editableList-container li{background:var(--red-ui-secondary-background);padding:0}.red-ui-editor-subflow-ui-edit-panel .red-ui-editableList-container li .red-ui-editableList-item-content{display:grid;grid-template-columns:50% 50%}.red-ui-editor-subflow-ui-edit-panel .red-ui-editableList-container li .red-ui-editableList-item-content>div{position:relative}.red-ui-editor-subflow-ui-edit-panel .red-ui-editableList-container li input{margin-bottom:0;border:none;width:100%;border-right:1px solid var(--red-ui-secondary-border-color);border-radius:0}.red-ui-editor-subflow-ui-edit-panel .red-ui-editableList-container li input:focus{box-shadow:0 0 0 1px inset var(--red-ui-form-input-focus-color)}.red-ui-editor-subflow-ui-edit-panel .red-ui-editableList-container li input:first-child{border-left:1px solid var(--red-ui-secondary-border-color)}.red-ui-editor-subflow-ui-edit-panel .red-ui-editableList-container li button.red-ui-typedInput-type-select,.red-ui-editor-subflow-ui-edit-panel .red-ui-editableList-container li button.red-ui-typedInput-option-expand,.red-ui-editor-subflow-ui-edit-panel .red-ui-editableList-container li button.red-ui-typedInput-option-trigger{border-radius:0;height:34px}.red-ui-editor-subflow-ui-edit-panel .red-ui-editableList-container li .red-ui-typedInput-container{border-radius:0;border:none}.red-ui-editor-subflow-ui-edit-panel .red-ui-editableList-container li .red-ui-typedInput-container input.red-ui-typedInput-input{height:34px;border-right:none}.red-ui-editor-subflow-ui-edit-panel .red-ui-editableList-container li .red-ui-editor-subflow-env-lang-icon{top:1px;right:1px;border-top-right-radius:0;border-bottom-right-radius:0}.red-ui-editor-subflow-ui-edit-panel .red-ui-editableList-container li .red-ui-editableList-item-remove{right:3px}.node-input-env-locales-row{position:relative;top:-20px;float:right}.node-input-env-locales-row select{padding:2px;width:160px;height:auto;min-width:20px;line-height:18px;font-size:10px}.node-input-env-container-row{min-width:470px;position:relative}.node-input-env-container-row .red-ui-editableList-item-content label{margin-bottom:0;line-height:32px}.node-input-env-container-row .red-ui-editableList-item-content label span{display:inline-block;width:20px;text-align:center}.node-input-env-container-row .red-ui-editableList-item-content>div:first-child{display:grid;padding-left:5px;grid-template-columns:40% auto 37px}.node-input-env-container-row .red-ui-editableList-item-content>div:first-child>:first-child{width:calc(100% - 5px)}.node-input-env-container-row .red-ui-editableList-item-content>div:first-child input{width:calc(100% - 5px)}.node-input-env-container-row .red-ui-editableList-item-content.red-ui-editor-subflow-env-editable>div:first-child{padding-left:0;grid-template-columns:24px 40% auto 37px}.node-input-env-container-row .red-ui-editableList-item-content.red-ui-editor-subflow-env-editable>div:first-child>a:first-child{text-align:center;line-height:32px}.node-input-env-container-row .red-ui-editableList-item-content.red-ui-editor-subflow-env-editable>div:first-child>a:first-child i.fa-angle-right{transition:all .2s linear}.node-input-env-container-row .red-ui-editableList-item-content.red-ui-editor-subflow-env-editable>div:first-child>a:first-child.expanded i.fa-angle-right{transform:rotate(90deg)}.node-input-env-container-row .red-ui-editableList-border .red-ui-editableList-header{border-top-left-radius:4px;border-top-right-radius:4px;background:var(--red-ui-tertiary-background);padding:0}.node-input-env-container-row .red-ui-editableList-border .red-ui-editableList-header>div{display:grid;grid-template-columns:24px 40% auto 37px}.node-input-env-container-row .red-ui-editableList-border .red-ui-editableList-header>div>div{display:inline-block}.node-input-env-container-row .red-ui-editableList-container{padding:0}.node-input-env-container-row .red-ui-editableList-container .red-ui-editableList-item-handle{top:25px}.node-input-env-container-row .red-ui-editableList-container .red-ui-editableList-item-remove{top:25px;right:5px}.red-ui-clipboard-import-error pre{margin:10px 0;border:none;color:var(--red-ui-primary-text-color)}.red-ui-clipboard-import-error pre span{padding:5px 0}.red-ui-clipboard-import-error pre span.error{padding:5px;border:1px solid var(--red-ui-form-input-border-error-color);margin:0 1px}#red-ui-clipboard-dialog-export-tab-clipboard-preview .red-ui-treeList-container,#red-ui-clipboard-dialog-export-tab-clipboard-preview .red-ui-editableList-border{border:none;border-radius:0}#red-ui-clipboard-dialog-export-tab-clipboard-json{padding:10px 10px 0}#red-ui-clipboard-dialog-import-tab-clipboard{padding:10px}.red-ui-clipboard-dialog-export-tab-clipboard-tab{position:absolute;top:40px;right:0;left:0;bottom:0}.red-ui-clipboard-dialog-tab-clipboard textarea{color:var(--red-ui-secondary-text-color-active) !important;resize:none;width:100%;border-radius:4px;font-family:var(--red-ui-monospace-font !important);font-size:13px !important;height:100%;line-height:1.3em;padding:6px 10px;background:var(--red-ui-clipboard-textarea-background)}.red-ui-clipboard-dialog-tabs{position:absolute;top:0;left:0;bottom:0;width:120px}.red-ui-clipboard-dialog-tabs-content{position:absolute;top:0;left:120px;right:0;bottom:0;padding:0;background:var(--red-ui-form-input-background)}.red-ui-clipboard-dialog-tabs-content>div{height:100%;box-sizing:border-box}.red-ui-clipboard-dialog-box{height:400px;position:relative;border:1px solid var(--red-ui-primary-border-color)}#red-ui-clipboard-dialog-export-tab-library-filename{height:auto !important;margin-left:10px}#red-ui-clipboard-dialog form{margin-bottom:0}#red-ui-clipboard-dialog .form-row:last-child{margin-bottom:0}#red-ui-clipboard-dialog-tab-library-name{width:calc(100% - 120px)}.red-ui-clipboard-dialog-tabs-content>div.red-ui-clipboard-dialog-export-tab-library-browser{height:calc(100% - 60px);margin-bottom:13px;border-bottom:1px solid var(--red-ui-primary-border-color);box-sizing:border-box}#red-ui-clipboard-dialog-import-tab-library-browser{height:100%;box-sizing:border-box}.red-ui-library-browser{position:relative;height:100%}.red-ui-library-browser .red-ui-treeList-container{background:var(--red-ui-secondary-background);border:none;border-radius:0}.red-ui-library-browser .red-ui-treeList-container li{background:none}.red-ui-library-browser .red-ui-treeList-container label{white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.red-ui-library-browser .red-ui-editableList-border{border-radius:0}.red-ui-library-browser .red-ui-treeList-label input.red-ui-treeList-input{border-radius:2px;margin-top:-6px;margin-bottom:-6px}#red-ui-library-dialog-save-browser{height:calc(100% - 60px);border:1px solid var(--red-ui-primary-border-color);margin-bottom:10px}#red-ui-library-dialog-load-panes{border:1px solid var(--red-ui-primary-border-color)}#red-ui-library-dialog-load-preview{height:100%}#red-ui-library-dialog-load-preview-text{box-sizing:border-box}#red-ui-library-dialog-load-preview-details{box-sizing:border-box}#red-ui-library-dialog-load-preview-details .red-ui-help-info-row:first-child{border-top:none}.red-ui-clipboard-dialog-import-conflicts-list-container{min-height:300px;position:relative}.red-ui-clipboard-dialog-import-conflicts-item-header{background:var(--red-ui-tertiary-background)}.red-ui-clipboard-dialog-import-conflicts-item-header>span:first-child{color:var(--red-ui-header-text-color);padding-left:4px;font-size:12px}.red-ui-clipboard-dialog-import-conflicts-controls{position:absolute;top:0;bottom:0;right:0px;text-align:center;color:var(--red-ui-form-text-color)}.form-row .red-ui-clipboard-dialog-import-conflicts-controls label{padding:2px 0;line-height:23px;margin-bottom:0;width:80px;display:inline-block;position:relative;height:100%;width:80px;text-align:center;border-left:1px solid var(--red-ui-secondary-border-color)}.red-ui-clipboard-dialog-import-conflicts-controls input[type=checkbox]{display:inline-block;width:auto;margin:0}#red-ui-clipboard-dialog-import-conflicts-list .disabled .red-ui-info-outline-item{opacity:.4}.form-row label.red-ui-clipboard-dialog-import-conflicts-gutter{box-sizing:border-box;width:22px;text-align:center}.red-ui-editor-dialog .form-row label.red-ui-clipboard-dialog-import-conflicts-gutter input[type=checkbox]{width:auto;padding:0;margin:0}#red-ui-settings-tab-library-manager{box-sizing:border-box;padding:10px;position:relative;height:100%}#red-ui-settings-tab-library-manager li{padding:0}.red-ui-settings-tab-library-entry{display:flex;flex-direction:row}.red-ui-settings-tab-library-entry span:not(:nth-child(2)){-webkit-user-select:none;-khtml-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none}.red-ui-settings-tab-library-entry span{padding:8px 0}.red-ui-settings-tab-library-entry span:first-child{display:inline-block;width:20px;padding-right:8px;text-align:center;flex-grow:0}.red-ui-settings-tab-library-entry span:nth-child(2){flex-grow:1}.red-ui-settings-tab-library-entry span:nth-child(3),.red-ui-settings-tab-library-entry span:nth-child(4){flex-grow:0;padding-right:5px;color:var(--red-ui-secondary-text-color);font-size:.9em}.red-ui-search{z-index:1000;display:none;position:absolute;width:500px;left:50%;margin-left:-250px;top:0px;border:1px solid var(--red-ui-primary-border-color);box-shadow:0 0 10px var(--red-ui-shadow);background:var(--red-ui-secondary-background)}.red-ui-search .red-ui-searchBox-container{display:inline-block;margin-right:6px;width:100%}.red-ui-search:not(.red-ui-type-search) .red-ui-searchBox-container{width:calc(100% - 30px)}.red-ui-type-search{box-shadow:0 1px 6px -3px #000;background:none;width:300px;margin-left:0px;border:none}.red-ui-type-search .red-ui-search-container{border-top-left-radius:5px;border-top-right-radius:5px;border:1px dashed var(--red-ui-primary-border-color);border-bottom:none;padding:0;width:100%}.red-ui-type-search .red-ui-search-results-container{display:none;height:195px}.red-ui-type-search .red-ui-search-results-container .red-ui-editableList-container{border:1px dashed var(--red-ui-primary-border-color);border-top:1px solid var(--red-ui-secondary-border-color)}.red-ui-type-search .red-ui-search-result{padding:2px 2px 2px 5px;font-size:13px;border-left-width:3px;border-right-width:3px}.red-ui-type-search .red-ui-search-result .red-ui-palette-icon-fa{font-size:11px;position:relative;top:-3px;left:0px}.red-ui-type-search .red-ui-search-result-separator{border-bottom:3px solid var(--red-ui-secondary-border-color)}.red-ui-type-search .red-ui-search-result-node{position:relative;width:18px;height:15px;margin-top:1px}.red-ui-type-search .red-ui-search-result-node-port{position:absolute;border-radius:2px;border:1px solid var(--red-ui-node-border);width:6px;height:7px;top:4px;left:-4px;background:var(--red-ui-node-port-background);box-sizing:border-box}.red-ui-type-search .red-ui-search-result-node-output{left:16px}.red-ui-type-search .red-ui-palette-icon-container{width:18px}.red-ui-type-search .red-ui-palette-icon{width:15px;position:relative;left:-1px}.red-ui-type-search .red-ui-search-result-description{margin-left:8px}.red-ui-type-search .red-ui-search-result-node-label{color:var(--red-ui-secondary-text-color)}.red-ui-search-container{padding:3px;background:var(--red-ui-form-input-background);border-bottom:1px solid var(--red-ui-secondary-border-color)}.red-ui-search-results-container{position:relative;height:300px;padding:5px;background:var(--red-ui-primary-background)}.red-ui-search-results-container .red-ui-editableList-container{padding:0;background:var(--red-ui-primary-background)}.red-ui-search-results-container .red-ui-editableList-container li{padding:0}.red-ui-search-result{padding:8px 2px 8px 5px;display:flex;align-items:start;cursor:pointer;color:var(--red-ui-list-item-color);background:var(--red-ui-list-item-background);border-left:3px solid var(--red-ui-list-item-background);border-right:3px solid var(--red-ui-list-item-background)}li.selected .red-ui-search-result{background:var(--red-ui-list-item-background-selected);border-left-color:var(--red-ui-list-item-border-selected);border-right-color:var(--red-ui-list-item-border-selected)}.red-ui-search-result:hover{text-decoration:none;color:var(--red-ui-form-text-color);background:var(--red-ui-list-item-background-hover);border-left-color:var(--red-ui-list-item-background-hover);border-right-color:var(--red-ui-list-item-background-hover)}.red-ui-search-result:after{content:"";display:table;clear:both}.red-ui-search-result-node{display:inline-block;width:30px;float:left;height:25px;border-radius:3px;border:1px solid var(--red-ui-node-border);background-position:5% 50%;background-repeat:no-repeat;background-size:contain;position:relative}.red-ui-search-result-node .red-ui-palette-icon-container{border-right:none}.red-ui-search-result-node-description{margin-left:10px;margin-right:5px;flex-grow:1}.red-ui-search-result-node-label{color:var(--red-ui-primary-text-color)}.red-ui-search-result-node-type{font-style:italic;font-size:.9em;color:var(--red-ui-tertiary-text-color)}.red-ui-search-result-node-flow{float:right;font-size:.8em;color:var(--red-ui-tertiary-text-color)}.red-ui-search-result-node-id{display:none;font-size:.8em;color:var(--red-ui-tertiary-text-color)}.red-ui-search-empty{padding:10px;text-align:center;font-style:italic;color:var(--red-ui-form-placeholder-color)}.red-ui-search-history button{display:none;position:absolute;top:8px;right:7px}.red-ui-search-history:hover button{display:inline}.red-ui-search-historyHeader button{position:absolute;top:10px;right:7px}.red-ui-search-result-action{color:var(--red-ui-primary-text-color)}.red-ui-search-result-action-key{position:absolute;top:9px;right:0;margin-right:10px;color:var(--red-ui-tertiary-text-color)}.red-ui-panels{position:relative;overflow:hidden;display:flex;flex-direction:column}.red-ui-panels>div{box-sizing:border-box}.red-ui-panels>.red-ui-panel:first-child{flex:0 0 auto}.red-ui-panels>.red-ui-panel:last-child{flex:1 1 auto}.red-ui-panels-separator{flex:0 0 auto;border-top:1px solid var(--red-ui-secondary-border-color);border-bottom:1px solid var(--red-ui-secondary-border-color);height:7px;box-sizing:border-box;cursor:ns-resize;background-color:var(--red-ui-primary-background)}.red-ui-panels-separator:before{content:"";display:block;width:100%;height:100%;-webkit-mask-image:url(images/grip-horizontal.svg);mask-image:url(images/grip-horizontal.svg);-webkit-mask-size:contain;mask-size:contain;-webkit-mask-position:center;mask-position:center;-webkit-mask-repeat:no-repeat;mask-repeat:no-repeat;background-color:var(--red-ui-grip-color)}.red-ui-panel{overflow:auto;height:calc(50% - 4px);position:relative}.red-ui-panels.red-ui-panels-horizontal{height:100%;flex-direction:row}.red-ui-panels.red-ui-panels-horizontal>.red-ui-panel{vertical-align:top;display:inline-block;height:100%;width:calc(50% - 4px)}.red-ui-panels.red-ui-panels-horizontal>.red-ui-panels-separator{vertical-align:top;border-top:none;border-bottom:none;border-left:1px solid var(--red-ui-secondary-border-color);border-right:1px solid var(--red-ui-secondary-border-color);height:100%;width:7px;display:inline-block;cursor:ew-resize;background-color:var(--red-ui-primary-background)}.red-ui-panels.red-ui-panels-horizontal>.red-ui-panels-separator:before{content:"";display:block;width:100%;height:100%;-webkit-mask-image:url(images/grip.svg);mask-image:url(images/grip.svg);-webkit-mask-size:contain;mask-size:contain;-webkit-mask-position:50% 50%;mask-position:50% 50%;-webkit-mask-repeat:no-repeat;mask-repeat:no-repeat;background-color:var(--red-ui-grip-color)}.red-ui-tabs{position:relative;background:var(--red-ui-tab-background);overflow:hidden;height:35px;box-sizing:border-box}.red-ui-tabs .hide-tab{transition:width .1s ease-in}.red-ui-tabs .red-ui-tabs-scroll-container{height:60px;overflow-x:scroll;overflow-y:hidden}.red-ui-tabs .red-ui-tabs-scroll-container::-webkit-scrollbar{display:none}.red-ui-tabs ul{list-style-type:none;padding:0;margin:0;display:block;height:35px;box-sizing:border-box;border-bottom:1px solid var(--red-ui-primary-border-color);white-space:nowrap;-webkit-user-select:none;-khtml-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none}.red-ui-tabs ul li{box-sizing:border-box;display:inline-block;border-left:1px solid var(--red-ui-primary-border-color);border-top:1px solid var(--red-ui-primary-border-color);border-right:1px solid var(--red-ui-primary-border-color);border-bottom:1px solid var(--red-ui-primary-border-color);background:var(--red-ui-tab-background-inactive);margin:3px 3px 0 3px;height:32px;line-height:29px;max-width:200px;width:14%;overflow:hidden;white-space:nowrap;position:relative}.red-ui-tabs ul li.red-ui-tabs-closeable:hover .red-ui-tabs-badges{display:none}.red-ui-tabs ul li.red-ui-tabs-closeable:hover .red-ui-tab-close{display:block}.red-ui-tabs ul li a.red-ui-tab-label{display:block;font-size:14px;padding-left:12px;width:100%;height:100%;color:var(--red-ui-tab-text-color-inactive)}.red-ui-tabs ul li a:hover{text-decoration:none}.red-ui-tabs ul li a:focus{text-decoration:none}.red-ui-tabs ul li:not(.active) a:hover+a.red-ui-tab-close{background:var(--red-ui-tab-background-hover)}.red-ui-tabs ul li.highlighted{box-shadow:0px 0px 4px 2px var(--red-ui-node-selected-color);border:dashed 1px var(--red-ui-node-selected-color)}.red-ui-tabs ul li.active{background:var(--red-ui-tab-background-active);font-weight:bold;border-bottom:1px solid var(--red-ui-tab-background-active);z-index:2}.red-ui-tabs ul li.active a{color:var(--red-ui-tab-text-color-active)}.red-ui-tabs ul li.active a.red-ui-tab-close{color:var(--red-ui-workspace-button-color);background:var(--red-ui-tab-background-active)}.red-ui-tabs ul li.active a.red-ui-tab-close:hover{background:var(--red-ui-workspace-button-background-hover) !important;color:var(--red-ui-workspace-button-color-hover)}.red-ui-tabs ul li.active img.red-ui-tab-icon{opacity:.2}.red-ui-tabs ul li.active .red-ui-tabs-fade{background-image:linear-gradient(to right, var(--red-ui-tab-background-active-alpha), var(--red-ui-tab-background-active))}.red-ui-tabs ul li.selected{font-weight:bold}.red-ui-tabs ul li.selected:not(.active){background:var(--red-ui-tab-background-selected)}.red-ui-tabs ul li.selected:not(.active) .red-ui-tabs-fade{background-image:linear-gradient(to right, var(--red-ui-tab-background-selected-alpha), var(--red-ui-tab-background-selected))}.red-ui-tabs ul li.selected:not(.active) .red-ui-tabs-badge-selected{background:var(--red-ui-tab-background-selected)}.red-ui-tabs ul li.selected .red-ui-tabs-badge-selected{display:inline;background:var(--red-ui-tab-background)}.red-ui-tabs ul li.selected .red-ui-tabs-badge-changed{display:none}.red-ui-tabs ul li:not(.active) a:hover{color:var(--red-ui-workspace-button-color-hover);background:var(--red-ui-tab-background-hover)}.red-ui-tabs ul li:not(.active) a:hover+.red-ui-tabs-fade{background-image:linear-gradient(to right, var(--red-ui-tab-background-hover-alpha), var(--red-ui-tab-background-hover))}.red-ui-tabs.red-ui-tabs-scrollable{padding-left:21px;padding-right:21px}.red-ui-tabs.red-ui-tabs-add{padding-right:29px}.red-ui-tabs.red-ui-tabs-add.red-ui-tabs-scrollable{padding-right:53px}.red-ui-tabs.red-ui-tabs-add.red-ui-tabs-menu.red-ui-tabs-scrollable,.red-ui-tabs.red-ui-tabs-add.red-ui-tabs-search.red-ui-tabs-scrollable{padding-right:83px}.red-ui-tabs.red-ui-tabs-add.red-ui-tabs-search.red-ui-tabs-menu.red-ui-tabs-scrollable{padding-right:113px}.red-ui-tabs.red-ui-tabs-collapsible li:not(.active){display:none}.red-ui-tabs.red-ui-tabs-collapsible li:not(.active).red-ui-tab-pinned{width:32px}.red-ui-tabs.red-ui-tabs-collapsible li:not(.active).red-ui-tab-pinned a{padding-left:0;text-align:center}.red-ui-tabs.red-ui-tabs-collapsible li:not(.active).red-ui-tab-pinned span{display:none}.red-ui-tabs.red-ui-tabs-vertical{box-sizing:border-box;height:100%;border-right:1px solid var(--red-ui-primary-border-color);margin:0;background:var(--red-ui-tertiary-background);overflow:visible}.red-ui-tabs.red-ui-tabs-vertical .red-ui-tabs-scroll-container{height:auto;overflow-x:visible;overflow-y:scroll}.red-ui-tabs.red-ui-tabs-vertical ul{padding:0;height:auto;border:none;width:calc(100% + 1px)}.red-ui-tabs.red-ui-tabs-vertical ul li{width:100%;display:block;margin:0;border:none;border-right:1px solid var(--red-ui-primary-border-color);height:auto}.red-ui-tabs.red-ui-tabs-vertical ul li:not(:first-child){border-top:1px solid var(--red-ui-secondary-border-color)}.red-ui-tabs.red-ui-tabs-vertical ul li:last-child{border-bottom:1px solid var(--red-ui-secondary-border-color)}.red-ui-tabs.red-ui-tabs-vertical ul li a.red-ui-tab-label{padding:9px}.red-ui-tabs.red-ui-tabs-vertical ul li.active{border-right:1px solid var(--red-ui-tab-background-active)}.red-ui-tabs .red-ui-tabs-select{position:absolute;top:0;bottom:0;left:0;right:0;opacity:.4;background:red}.red-ui-tab-button{position:absolute;box-sizing:border-box;top:0;right:0;height:35px;background:var(--red-ui-tab-background);border-bottom:1px solid var(--red-ui-primary-border-color);z-index:2}.red-ui-tab-button a{-webkit-user-select:none;-khtml-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;color:var(--red-ui-workspace-button-color) !important;background:var(--red-ui-workspace-button-background);text-decoration:none;box-sizing:border-box;display:inline-block;border:1px solid var(--red-ui-form-input-border-color);text-align:center;margin:0;cursor:pointer;line-height:30px;height:28px;width:28px;margin-left:2px;margin-right:2px;margin-top:3px;margin-bottom:3px;border:none;z-index:2}.red-ui-tab-button a.disabled,.red-ui-tab-button a:disabled{cursor:default;color:var(--red-ui-workspace-button-color-disabled) !important}.red-ui-tab-button a:hover,.red-ui-tab-button a:focus{text-decoration:none}.red-ui-tab-button a:not(.disabled):not(:disabled):hover{color:var(--red-ui-workspace-button-color-hover) !important;background:var(--red-ui-workspace-button-background-hover)}.red-ui-tab-button a:not(.disabled):not(:disabled):focus{color:var(--red-ui-workspace-button-color-focus) !important}.red-ui-tab-button a:not(.disabled):not(:disabled):active{color:var(--red-ui-workspace-button-color-active) !important;background:var(--red-ui-workspace-button-background-active);text-decoration:none}.red-ui-tab-button a.selected:not(.disabled):not(:disabled){color:var(--red-ui-workspace-button-color-selected) !important;background:var(--red-ui-workspace-button-background-active)}.button-group .red-ui-tab-button a:not(:first-child){border-left:none;border-top-left-radius:0;border-bottom-left-radius:0}.button-group .red-ui-tab-button a:not(:last-child){border-top-right-radius:0;border-bottom-right-radius:0}.button-group-vertical .red-ui-tab-button a{display:block;min-width:22px}.button-group-vertical .red-ui-tab-button a:not(:first-child){border-top:none;border-top-left-radius:0;border-top-right-radius:0}.button-group-vertical .red-ui-tab-button a:not(:last-child){border-bottom-left-radius:0;border-bottom-right-radius:0}.button-group .red-ui-tab-button a:focus{position:relative}.button-row .red-ui-tab-button a:not(:first-child){margin-left:15px}.red-ui-tab-button a:focus{outline:1px solid var(--red-ui-workspace-button-color-focus-outline);outline-offset:1px}.red-ui-tab-button a.primary{border-color:var(--red-ui-workspace-button-background-primary);color:var(--red-ui-workspace-button-color-primary) !important;background:var(--red-ui-workspace-button-background-primary)}.red-ui-tab-button a.primary.disabled,.red-ui-tab-button a.primary.ui-state-disabled{background:none;color:var(--red-ui-workspace-button-color) !important;border-color:var(--red-ui-form-input-border-color)}.red-ui-tab-button a.primary:not(.disabled):not(.ui-button-disabled):hover{border-color:var(--red-ui-workspace-button-background-primary-hover);background:var(--red-ui-workspace-button-background-primary-hover);color:var(--red-ui-workspace-button-color-primary) !important}.red-ui-tab-button a.secondary{background:none}.red-ui-tab-button a.secondary:not(:hover){border-color:rgba(0,0,0,0)}.red-ui-tab-link-buttons{position:absolute;box-sizing:border-box;top:0;right:0;height:35px;background:var(--red-ui-tab-background);border-bottom:1px solid var(--red-ui-primary-border-color);z-index:2}.red-ui-tab-link-buttons a{-webkit-user-select:none;-khtml-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;color:var(--red-ui-workspace-button-color) !important;background:var(--red-ui-workspace-button-background);text-decoration:none;box-sizing:border-box;display:inline-block;border:1px solid var(--red-ui-form-input-border-color);text-align:center;margin:0;cursor:pointer;line-height:26px;height:28px;width:28px;margin:4px 3px 3px;z-index:2}.red-ui-tab-link-buttons a.disabled,.red-ui-tab-link-buttons a:disabled{cursor:default;color:var(--red-ui-workspace-button-color-disabled) !important}.red-ui-tab-link-buttons a:hover,.red-ui-tab-link-buttons a:focus{text-decoration:none}.red-ui-tab-link-buttons a:not(.disabled):not(:disabled):hover{color:var(--red-ui-workspace-button-color-hover) !important;background:var(--red-ui-workspace-button-background-hover)}.red-ui-tab-link-buttons a:not(.disabled):not(:disabled):focus{color:var(--red-ui-workspace-button-color-focus) !important}.red-ui-tab-link-buttons a:not(.disabled):not(:disabled):active{color:var(--red-ui-workspace-button-color-active) !important;background:var(--red-ui-workspace-button-background-active);text-decoration:none}.red-ui-tab-link-buttons a.selected:not(.disabled):not(:disabled){color:var(--red-ui-workspace-button-color-selected) !important;background:var(--red-ui-workspace-button-background-active)}.button-group .red-ui-tab-link-buttons a:not(:first-child){border-left:none;border-top-left-radius:0;border-bottom-left-radius:0}.button-group .red-ui-tab-link-buttons a:not(:last-child){border-top-right-radius:0;border-bottom-right-radius:0}.button-group-vertical .red-ui-tab-link-buttons a{display:block;min-width:22px}.button-group-vertical .red-ui-tab-link-buttons a:not(:first-child){border-top:none;border-top-left-radius:0;border-top-right-radius:0}.button-group-vertical .red-ui-tab-link-buttons a:not(:last-child){border-bottom-left-radius:0;border-bottom-right-radius:0}.button-group .red-ui-tab-link-buttons a:focus{position:relative}.button-row .red-ui-tab-link-buttons a:not(:first-child){margin-left:15px}.red-ui-tab-link-buttons a:focus{outline:1px solid var(--red-ui-workspace-button-color-focus-outline);outline-offset:1px}.red-ui-tab-link-buttons a.primary{border-color:var(--red-ui-workspace-button-background-primary);color:var(--red-ui-workspace-button-color-primary) !important;background:var(--red-ui-workspace-button-background-primary)}.red-ui-tab-link-buttons a.primary.disabled,.red-ui-tab-link-buttons a.primary.ui-state-disabled{background:none;color:var(--red-ui-workspace-button-color) !important;border-color:var(--red-ui-form-input-border-color)}.red-ui-tab-link-buttons a.primary:not(.disabled):not(.ui-button-disabled):hover{border-color:var(--red-ui-workspace-button-background-primary-hover);background:var(--red-ui-workspace-button-background-primary-hover);color:var(--red-ui-workspace-button-color-primary) !important}.red-ui-tab-link-buttons a.secondary{background:none}.red-ui-tab-link-buttons a.secondary:not(:hover){border-color:rgba(0,0,0,0)}.red-ui-tab-link-buttons a:not(.single){margin-bottom:1px}.red-ui-tab-link-buttons a:not(.single).selected:not(.disabled):not(:disabled){border-bottom-width:2px;border-bottom-color:var(--red-ui-form-input-border-selected-color);margin-bottom:0;cursor:default}.red-ui-tab-link-buttons a:not(.single):not(.selected){margin-top:1px}.red-ui-tab-link-buttons a.red-ui-tab-link-button-menu{border-color:var(--red-ui-tab-background)}.red-ui-tab-link-buttons a:not(.single):not(.selected){margin-top:4px}.red-ui-tab-scroll{width:21px;top:0}.red-ui-tab-scroll a{height:35px;width:21px;display:block;color:var(--red-ui-workspace-button-color);font-size:22px;text-align:center;margin:0;border-left:none;border-right:none;border-top:none;border-bottom:1px solid var(--red-ui-primary-border-color);line-height:34px}.red-ui-tab-scroll-left{left:0}.red-ui-tab-scroll-left a{border-right:1px solid var(--red-ui-primary-border-color)}.red-ui-tab-scroll-right{right:0px}.red-ui-tab-scroll-right a{border-left:1px solid var(--red-ui-primary-border-color)}.red-ui-tabs.red-ui-tabs-add .red-ui-tab-scroll-right{right:32px}.red-ui-tabs.red-ui-tabs-add.red-ui-tabs-menu .red-ui-tab-scroll-right,.red-ui-tabs.red-ui-tabs-add.red-ui-tabs-search .red-ui-tab-scroll-right{right:64px}.red-ui-tabs.red-ui-tabs-add.red-ui-tabs-menu .red-ui-tabs-add,.red-ui-tabs.red-ui-tabs-add.red-ui-tabs-search .red-ui-tabs-add{right:32px}.red-ui-tabs.red-ui-tabs-add.red-ui-tabs-search.red-ui-tabs-menu .red-ui-tab-scroll-right{right:96px}.red-ui-tabs.red-ui-tabs-add.red-ui-tabs-search.red-ui-tabs-menu .red-ui-tabs-add{right:64px}.red-ui-tabs.red-ui-tabs-add.red-ui-tabs-search.red-ui-tabs-menu .red-ui-tabs-search{right:32px}.red-ui-tabs-fade{position:absolute;bottom:0;top:0;right:0;width:15px;background-image:linear-gradient(to right, var(--red-ui-tab-background-inactive-alpha), var(--red-ui-tab-background-inactive));pointer-events:none}i.red-ui-tab-icon{opacity:.7;width:18px;height:20px}i.red-ui-tab-icon:not(.fa){display:inline-block;margin-left:-8px;margin-right:3px;margin-top:-2px;opacity:1;width:20px;height:20px;vertical-align:middle;-webkit-mask-size:contain;mask-size:contain;-webkit-mask-position:center;mask-position:center;-webkit-mask-repeat:no-repeat;mask-repeat:no-repeat;background-color:var(--red-ui-tab-icon-color)}.red-ui-tabs-badges{position:absolute;top:0px;right:0px;width:20px;pointer-events:none;display:block;height:30px;line-height:28px;text-align:center;padding:0px;color:var(--red-ui-tab-badge-color)}.red-ui-tabs-badges i{display:none}.red-ui-tab.node_changed img.node_changed{display:inline-block}.red-ui-tab.node_error img.node_error{display:inline-block}.red-ui-tabs-badges img{width:10px;height:10px;margin-right:2px;vertical-align:top}.red-ui-tab-hide .fa-eye-slash{display:none}.red-ui-tab-hide:hover .fa-eye-slash{display:inline}.red-ui-tab-hide:hover .fa-eye{display:none}.red-ui-tab-close{display:none;background:var(--red-ui-tab-background-inactive);opacity:.8;position:absolute;right:0px;top:0px;width:20px;height:30px;line-height:28px;text-align:center;padding:0px;color:var(--red-ui-workspace-button-color)}.red-ui-tab-close:hover{background:var(--red-ui-workspace-button-background-hover) !important;color:var(--red-ui-workspace-button-color-hover);opacity:1}.red-ui-sidebar-node-config{position:relative;background:var(--red-ui-secondary-background);height:100%;overflow-y:auto;-webkit-user-select:none;-khtml-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none}.red-ui-sidebar-node-config:focus{outline:none}ul.red-ui-sidebar-node-config-list{margin:0;padding:0;list-style-type:none}ul.red-ui-sidebar-node-config-list li{padding:0;margin:0;text-align:center}ul.red-ui-sidebar-node-config-list .red-ui-palette-node{overflow:hidden;cursor:default}ul.red-ui-sidebar-node-config-list .red-ui-palette-node.selected{border-color:rgba(0,0,0,0);box-shadow:0 0 0 2px var(--red-ui-node-selected-color)}ul.red-ui-sidebar-node-config-list .red-ui-palette-node.highlighted{border-color:rgba(0,0,0,0);outline:dashed var(--red-ui-node-selected-color) 4px}ul.red-ui-sidebar-node-config-list .red-ui-palette-label{margin-left:8px;line-height:24px;text-align:left;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}ul.red-ui-sidebar-node-config-list .red-ui-palette-label:not(:last-child){width:calc(100% - 38px)}ul.red-ui-sidebar-node-config-list .red-ui-palette-icon-container{font-size:12px;line-height:30px;background-color:var(--red-ui-node-icon-background-color);border-top-right-radius:4px;border-bottom-right-radius:4px}ul.red-ui-sidebar-node-config-list .red-ui-palette-icon-container a{position:absolute;top:0;bottom:0;left:0;right:0;color:var(--red-ui-node-port-label-color);cursor:pointer}ul.red-ui-sidebar-node-config-list .red-ui-palette-icon-container a:hover{text-decoration:none;background:var(--red-ui-node-port-background-hover)}.red-ui-palette-node-config{width:160px;height:30px;background:var(--red-ui-node-config-background);color:var(--red-ui-primary-text-color);cursor:pointer}ul.red-ui-sidebar-node-config-list li.red-ui-palette-node-config-type{color:var(--red-ui-secondary-text-color);text-align:right;padding-right:3px}ul.red-ui-sidebar-node-config-list li.red-ui-palette-node-config-type:not(:first-child){margin-top:20px}.red-ui-palette-node-config-none{color:var(--red-ui-tertiary-text-color);text-align:right;padding-right:3px}.red-ui-palette-node-config-unused,.red-ui-palette-node-config-disabled{border-color:var(--red-ui-primary-border-color);background:var(--red-ui-node-config-background);border-style:dashed;color:var(--red-ui-node-config-icon-container-disabled)}.red-ui-palette-node-config-disabled{opacity:.6;font-style:italic}.red-ui-palette-node-config-disabled i{color:var(--red-ui-node-port-label-color);margin-right:5px}.red-ui-sidebar-node-config-filter-info{position:absolute;top:0;right:0;height:38px;line-height:38px;padding:0 8px;background:var(--red-ui-palette-header-background);font-size:.8em;color:var(--red-ui-secondary-text-color);font-weight:normal}.red-ui-sidebar-context-stack{position:absolute;top:0;bottom:0;left:0;right:0;overflow-y:auto}.red-ui-sidebar-context-stack .red-ui-palette-category:not(.expanded) button{display:none}.red-ui-sidebar-context-stack .red-ui-info-table{table-layout:fixed}.red-ui-sidebar-context-stack table.red-ui-info-table tr:not(.blank) td:first-child{width:30%}.red-ui-sidebar-context-stack table.red-ui-info-table tr:not(.blank) td:last-child{vertical-align:top}.red-ui-sidebar-context-stack button.red-ui-toggleButton.toggle{text-align:center}.red-ui-sidebar-context-stack button.red-ui-toggleButton.toggle i{min-width:10px}.red-ui-sidebar-context-property{overflow-wrap:break-word;position:relative}.red-ui-sidebar-context-property .red-ui-debug-msg-tools{right:0px;margin-right:5px;display:none}.red-ui-sidebar-context-property:hover .red-ui-debug-msg-tools{display:inline-block}.red-ui-sidebar-context-updated{text-align:right;font-size:11px;color:var(--red-ui-tertiary-text-color);padding:1px 3px}.red-ui-sidebar-context-property-storename{display:block;font-size:.8em;font-style:italic;color:var(--red-ui-tertiary-text-color)}.red-ui-sidebar-info{height:100%;overflow:hidden}.red-ui-sidebar-info hr{margin:10px 0}.red-ui-info-header{padding-left:9px;line-height:21px;cursor:default;border-bottom:1px solid var(--red-ui-secondary-border-color)}.red-ui-info-header>*{vertical-align:middle}.red-ui-info-header>span{display:inline-block;margin-left:5px}table.red-ui-info-table{font-size:14px;margin:0 0 10px;width:100%}table.red-ui-info-table tr:not(.blank){border-top:1px solid var(--red-ui-secondary-border-color);border-bottom:1px solid var(--red-ui-secondary-border-color)}.red-ui-help-property-expand{font-size:.8em;text-align:right;line-height:.9em}.red-ui-help-property-expand a{padding-bottom:5px}table.red-ui-info-table tr.blank{border:none}table.red-ui-info-table tr.blank th{text-align:left;font-weight:500;color:var(--red-ui-primary-text-color);padding:6px 3px 3px}table.red-ui-info-table tr.blank>*{padding-top:8px;border:none;padding-left:0px}table.red-ui-info-table tr.blank a{display:block;color:var(--red-ui-primary-text-color)}table.red-ui-info-table tr.blank a:hover,table.red-ui-info-table tr.blank a:focus{color:var(--red-ui-primary-text-color);text-decoration:none}table.red-ui-info-table tr.blank a:not(.expanded) .red-ui-help-property-more{display:inline}table.red-ui-info-table tr.blank a:not(.expanded) .red-ui-help-property-less{display:none}table.red-ui-info-table tr.blank a i{width:10px;text-align:center;transition:transform .2s ease-in-out}table.red-ui-info-table tr.blank a.expanded .red-ui-help-property-more{display:none}table.red-ui-info-table tr.blank a.expanded .red-ui-help-property-less{display:inline}table.red-ui-info-table tr.blank a.expanded i{transform:rotate(180deg)}.red-ui-help-info-none{font-style:italic;color:var(--red-ui-tertiary-text-color)}table.red-ui-info-table tr:not(.blank) td:first-child{color:var(--red-ui-header-text-color);vertical-align:top;width:90px;padding:3px 3px 3px 6px;background:var(--red-ui-tertiary-background);border-right:1px solid var(--red-ui-secondary-border-color)}table.red-ui-info-table tr:not(.blank) td:last-child{padding:3px 3px 3px 6px;color:var(--red-ui-primary-text-color);overflow-y:hidden}div.red-ui-info-table{margin:5px}.red-ui-help{font-size:var(--red-ui-primary-font-size);line-height:1.5em}.red-ui-help a{color:var(--red-ui-text-color-link);text-decoration:none}.red-ui-help a:hover,.red-ui-help a:focus{color:var(--red-ui-text-color-link);text-decoration:underline}.red-ui-help h1{font-weight:500;font-size:1.296em;line-height:1.3em;margin:8px auto}.red-ui-help h1.red-ui-help-title{border-bottom:1px solid var(--red-ui-tertiary-border-color)}.red-ui-help h2{font-weight:500;font-size:1.215em;margin:8px auto;line-height:1.3em}.red-ui-help h3{font-weight:500;font-size:1.138em;margin:7px auto 5px;line-height:1.3em}.red-ui-help h4,.red-ui-help h5{font-weight:500;font-size:1.067em;line-height:1.3em;margin:8px auto 5px}.red-ui-help dl.message-properties{border:1px solid var(--red-ui-secondary-border-color);border-radius:2px;margin:5px auto 10px}.red-ui-help dl.message-properties>dt{padding:0px 3px 2px 3px;font-family:var(--red-ui-monospace-font);font-weight:normal;margin:5px 3px 1px;color:var(--red-ui-text-color-code);white-space:nowrap}.red-ui-help dl.message-properties>dt.optional{font-style:italic}.red-ui-help dl.message-properties>dt .property-type{font-family:var(--red-ui-primary-font);color:var(--red-ui-primary-text-color);font-style:italic;font-size:11px;float:right}.red-ui-help dl.message-properties>dt:after{content:"";display:table;clear:both}.red-ui-help dl.message-properties>dd{margin:0px 8px 2px 13px;vertical-align:top}.red-ui-help ol.node-ports{margin:0}.red-ui-help ol.node-ports li{border:1px solid var(--red-ui-secondary-border-color);border-radius:2px;list-style-position:inside;padding:3px;margin-bottom:5px}.red-ui-help ol.node-ports li dl.message-properties{border:none}.red-ui-help ol.node-ports p{display:inline}.red-ui-help .red-ui-help-info-header{color:var(--red-ui-header-text-color)}.red-ui-help .red-ui-help-info-header i{width:10px;text-align:center;transition:transform .2s ease-in-out;margin-right:4px}.red-ui-help .red-ui-help-info-header:hover,.red-ui-help .red-ui-help-info-header:focus{text-decoration:none}.red-ui-help .red-ui-help-info-header.expanded i{transform:rotate(90deg)}.red-ui-help table{border-collapse:collapse;border:1px solid var(--red-ui-secondary-border-color);margin:8px 0 8px 0;min-width:300px;overflow:hidden}.red-ui-help table thead tr{background-color:var(--red-ui-primary-background);border-bottom:1px solid var(--red-ui-secondary-border-color);color:var(--red-ui-header-text-color);text-align:left}.red-ui-help table th,.red-ui-help table td{padding:6px 8px}.red-ui-help table tbody tr:nth-of-type(even){background-color:var(--red-ui-tertiary-background)}.red-ui-sidebar-info-stack{height:100%}.red-ui-help-tips{display:none;position:absolute;left:0;right:0;bottom:0;height:0;transition:height .2s,padding .2s;box-sizing:border-box;border-top:1px solid var(--red-ui-secondary-border-color);background-color:var(--red-ui-secondary-background);padding:0;box-shadow:0 5px 20px 0px var(--red-ui-shadow);overflow-y:auto}.red-ui-sidebar-info.show-tips .red-ui-sidebar-info-stack{height:calc(100% - 150px)}.red-ui-sidebar-info.show-tips .red-ui-help-tips{display:block;height:150px;padding:20px}.red-ui-help-tips:before{content:"";display:inline-block;height:100%;vertical-align:middle;margin-right:-0.25em}.red-ui-help-tip{display:inline-block;vertical-align:middle;width:100%;font-size:16px;text-align:center;line-height:1.9em;color:var(--red-ui-tertiary-text-color);-webkit-user-select:none;-khtml-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;cursor:default}.red-ui-help-tips-buttons{position:absolute;top:4px;right:6px}.red-ui-help-tips-buttons a{color:var(--red-ui-secondary-text-color);border-color:var(--red-ui-secondary-border-color) !important;margin-left:4px}.node-info-property-config-node{border:1px solid var(--red-ui-secondary-border-color);border-radius:4px;padding:2px 4px 2px}.red-ui-info-outline,.red-ui-sidebar-help-toc{display:flex;flex-direction:column}.red-ui-info-outline .red-ui-treeList,.red-ui-sidebar-help-toc .red-ui-treeList{flex-grow:1;position:relative}.red-ui-info-outline .red-ui-treeList-container,.red-ui-sidebar-help-toc .red-ui-treeList-container{position:absolute;top:0;bottom:0}.red-ui-info-outline .red-ui-treeList-container,.red-ui-info-outline .red-ui-editableList-border,.red-ui-sidebar-help-toc .red-ui-treeList-container,.red-ui-sidebar-help-toc .red-ui-editableList-border{border:none;border-radius:0}.red-ui-info-outline .red-ui-info-outline-project,.red-ui-sidebar-help-toc .red-ui-info-outline-project{border-bottom:1px solid var(--red-ui-secondary-border-color)}.red-ui-info-outline .red-ui-info-outline-item,.red-ui-sidebar-help-toc .red-ui-info-outline-item,#red-ui-clipboard-dialog-import-conflicts-list .red-ui-info-outline-item,#red-ui-clipboard-dialog-export-tab-clipboard-preview .red-ui-info-outline-item{display:inline-flex;padding:0;font-size:13px;border:none}.red-ui-info-outline .red-ui-info-outline-item:not(.red-ui-node-list-item) .red-ui-palette-icon-fa,.red-ui-sidebar-help-toc .red-ui-info-outline-item:not(.red-ui-node-list-item) .red-ui-palette-icon-fa,#red-ui-clipboard-dialog-import-conflicts-list .red-ui-info-outline-item:not(.red-ui-node-list-item) .red-ui-palette-icon-fa,#red-ui-clipboard-dialog-export-tab-clipboard-preview .red-ui-info-outline-item:not(.red-ui-node-list-item) .red-ui-palette-icon-fa{position:relative;top:1px;left:0px}.red-ui-info-outline .red-ui-info-outline-item:hover,.red-ui-sidebar-help-toc .red-ui-info-outline-item:hover,#red-ui-clipboard-dialog-import-conflicts-list .red-ui-info-outline-item:hover,#red-ui-clipboard-dialog-export-tab-clipboard-preview .red-ui-info-outline-item:hover{background:inherit}.red-ui-info-outline .red-ui-info-outline-item.red-ui-info-outline-item-flow .red-ui-search-result-description,.red-ui-sidebar-help-toc .red-ui-info-outline-item.red-ui-info-outline-item-flow .red-ui-search-result-description,#red-ui-clipboard-dialog-import-conflicts-list .red-ui-info-outline-item.red-ui-info-outline-item-flow .red-ui-search-result-description,#red-ui-clipboard-dialog-export-tab-clipboard-preview .red-ui-info-outline-item.red-ui-info-outline-item-flow .red-ui-search-result-description{margin-left:4px}.red-ui-info-outline .red-ui-info-outline-item.red-ui-info-outline-item-group .red-ui-search-result-node,.red-ui-sidebar-help-toc .red-ui-info-outline-item.red-ui-info-outline-item-group .red-ui-search-result-node,#red-ui-clipboard-dialog-import-conflicts-list .red-ui-info-outline-item.red-ui-info-outline-item-group .red-ui-search-result-node,#red-ui-clipboard-dialog-export-tab-clipboard-preview .red-ui-info-outline-item.red-ui-info-outline-item-group .red-ui-search-result-node{background:none;border-color:rgba(0,0,0,0)}.red-ui-info-outline .red-ui-info-outline-item.red-ui-info-outline-item-group .red-ui-search-result-node .red-ui-palette-icon-container,.red-ui-sidebar-help-toc .red-ui-info-outline-item.red-ui-info-outline-item-group .red-ui-search-result-node .red-ui-palette-icon-container,#red-ui-clipboard-dialog-import-conflicts-list .red-ui-info-outline-item.red-ui-info-outline-item-group .red-ui-search-result-node .red-ui-palette-icon-container,#red-ui-clipboard-dialog-export-tab-clipboard-preview .red-ui-info-outline-item.red-ui-info-outline-item-group .red-ui-search-result-node .red-ui-palette-icon-container{background:none}.red-ui-info-outline .red-ui-info-outline-item.red-ui-info-outline-item-group .red-ui-search-result-node .red-ui-palette-icon-fa,.red-ui-sidebar-help-toc .red-ui-info-outline-item.red-ui-info-outline-item-group .red-ui-search-result-node .red-ui-palette-icon-fa,#red-ui-clipboard-dialog-import-conflicts-list .red-ui-info-outline-item.red-ui-info-outline-item-group .red-ui-search-result-node .red-ui-palette-icon-fa,#red-ui-clipboard-dialog-export-tab-clipboard-preview .red-ui-info-outline-item.red-ui-info-outline-item-group .red-ui-search-result-node .red-ui-palette-icon-fa{color:var(--red-ui-secondary-text-color);font-size:18px}.red-ui-info-outline .red-ui-info-outline-item.red-ui-info-outline-item-empty,.red-ui-sidebar-help-toc .red-ui-info-outline-item.red-ui-info-outline-item-empty,#red-ui-clipboard-dialog-import-conflicts-list .red-ui-info-outline-item.red-ui-info-outline-item-empty,#red-ui-clipboard-dialog-export-tab-clipboard-preview .red-ui-info-outline-item.red-ui-info-outline-item-empty{font-style:italic;color:var(--red-ui-form-placeholder-color)}.red-ui-info-outline .red-ui-treeList-label,.red-ui-sidebar-help-toc .red-ui-treeList-label,#red-ui-clipboard-dialog-import-conflicts-list .red-ui-treeList-label,#red-ui-clipboard-dialog-export-tab-clipboard-preview .red-ui-treeList-label{font-size:13px;padding:2px 0;overflow:hidden}.red-ui-info-outline .red-ui-search-result-node,.red-ui-sidebar-help-toc .red-ui-search-result-node,#red-ui-clipboard-dialog-import-conflicts-list .red-ui-search-result-node,#red-ui-clipboard-dialog-export-tab-clipboard-preview .red-ui-search-result-node{width:24px;height:20px;margin-top:1px}.red-ui-info-outline .red-ui-palette-icon-container,.red-ui-sidebar-help-toc .red-ui-palette-icon-container,#red-ui-clipboard-dialog-import-conflicts-list .red-ui-palette-icon-container,#red-ui-clipboard-dialog-export-tab-clipboard-preview .red-ui-palette-icon-container{width:24px}.red-ui-info-outline .red-ui-palette-icon,.red-ui-sidebar-help-toc .red-ui-palette-icon,#red-ui-clipboard-dialog-import-conflicts-list .red-ui-palette-icon,#red-ui-clipboard-dialog-export-tab-clipboard-preview .red-ui-palette-icon{width:20px}.red-ui-info-outline .red-ui-search-result-description,.red-ui-sidebar-help-toc .red-ui-search-result-description,#red-ui-clipboard-dialog-import-conflicts-list .red-ui-search-result-description,#red-ui-clipboard-dialog-export-tab-clipboard-preview .red-ui-search-result-description{margin-left:32px;line-height:22px;white-space:nowrap}.red-ui-info-outline .red-ui-search-result-node-label,.red-ui-sidebar-help-toc .red-ui-search-result-node-label,#red-ui-clipboard-dialog-import-conflicts-list .red-ui-search-result-node-label,#red-ui-clipboard-dialog-export-tab-clipboard-preview .red-ui-search-result-node-label{color:var(--red-ui-secondary-text-color)}.red-ui-info-outline-item-control-spacer{display:inline-block;width:23px}.red-ui-info-outline-gutter{display:none}.red-ui-info-outline-gutter button{position:relative;left:2px}.red-ui-treeList-label:hover .red-ui-info-outline-gutter{display:inline}.red-ui-info-outline-item-controls{position:absolute;top:1px;bottom:1px;right:1px;padding:1px 2px 0 1px;text-align:right;background:var(--red-ui-list-item-background)}.red-ui-treeList-label:hover .red-ui-info-outline-item-controls{background:var(--red-ui-list-item-background-hover)}.red-ui-treeList-label.focus .red-ui-info-outline-item-controls{background:var(--red-ui-list-item-background-hover)}.red-ui-treeList-label.selected .red-ui-info-outline-item-controls{background:var(--red-ui-list-item-background-selected)}.red-ui-info-outline-item-controls.red-ui-info-outline-item-hover-controls button{min-width:23px}.red-ui-treeList-label:not(:hover) .red-ui-info-outline-item-controls.red-ui-info-outline-item-hover-controls button{border:none;background:none}.red-ui-treeList-label:not(:hover) .red-ui-info-outline-item-controls.red-ui-info-outline-item-hover-controls .fa-circle-thin{display:none}.red-ui-treeList-label:not(:hover) .red-ui-info-outline-item-controls.red-ui-info-outline-item-hover-controls .fa-eye{display:none}.red-ui-info-outline-item-controls .red-ui-info-outline-item-control-reveal,.red-ui-info-outline-item-controls .red-ui-info-outline-item-control-action{display:none}.red-ui-treeList-label:hover .red-ui-info-outline-item-controls .red-ui-info-outline-item-control-reveal,.red-ui-treeList-label:hover .red-ui-info-outline-item-controls .red-ui-info-outline-item-control-action{display:inline-block}.red-ui-info-outline-item-controls .fa-eye-slash{display:none}.red-ui-info-outline-item.red-ui-info-outline-item-hidden .red-ui-info-outline-item-controls .fa-eye-slash{display:inline-block}.red-ui-info-outline-item.red-ui-info-outline-item-hidden .red-ui-info-outline-item-controls .fa-eye{display:none}.red-ui-info-outline-item-controls .fa-ban{display:none}.red-ui-info-outline-item.red-ui-info-outline-item-disabled .red-ui-info-outline-item-controls .fa-ban{display:inline-block}.red-ui-info-outline-item.red-ui-info-outline-item-disabled .red-ui-info-outline-item-controls .fa-circle-thin{display:none}.red-ui-info-outline-item-controls button{margin-right:3px}.red-ui-info-outline-item-disabled .red-ui-search-result-node{opacity:.4}.red-ui-info-outline-item-disabled .red-ui-info-outline-item-label{font-style:italic;color:var(--red-ui-secondary-text-color-disabled)}.red-ui-info-outline-item-disabled .red-ui-icons-flow{opacity:.4}.red-ui-icons{display:inline-block;width:18px}.red-ui-icons:before{white-space:pre;content:" "}.red-ui-icons-flow{mask-image:url(images/subflow_tab.svg);-webkit-mask-image:url(images/subflow_tab.svg);mask-position:center;-webkit-mask-position:center;mask-size:contain;-webkit-mask-size:contain;mask-repeat:no-repeat;-webkit-mask-repeat:no-repeat;background-color:var(--red-ui-icons-flow-color)}.red-ui-info-toolbar{min-height:39px;height:39px;box-sizing:border-box;text-align:left}.red-ui-info-toolbar .red-ui-searchBox-container{position:absolute;top:6px;right:8px;width:calc(100% - 130px);max-width:250px;background:var(--red-ui-palette-header-background)}.red-ui-help-search{border-bottom:1px solid var(--red-ui-secondary-border-color)}.red-ui-sidebar-help-toc .red-ui-treeList-label{font-size:13px;padding:2px 0;overflow:hidden;white-space:nowrap}#red-ui-sidebar-help-show-toc i.fa-angle-right{transition:all .2s ease-in-out}#red-ui-sidebar-help-show-toc.selected i.fa-angle-right{transform:rotate(90deg)}.red-ui-popover{display:none;position:absolute;width:auto;padding:2px;height:auto;background:var(--red-ui-popover-border);color:var(--red-ui-popover-color);border-radius:4px;z-index:1000;font-family:var(--red-ui-primary-font);font-size:14px;line-height:1.4em;box-shadow:1px 1px 4px var(--red-ui-shadow);border-color:var(--red-ui-popover-border)}.red-ui-popover-content{padding:8px;border-radius:2px;background:var(--red-ui-popover-background)}.red-ui-popover:after,.red-ui-popover:before{border:solid rgba(0,0,0,0);content:" ";height:0;width:0;position:absolute;pointer-events:none}.red-ui-popover.red-ui-popover-right:after,.red-ui-popover.red-ui-popover-right:before{top:50%;right:100%}.red-ui-popover.red-ui-popover-left:after,.red-ui-popover.red-ui-popover-left:before{top:50%;left:100%}.red-ui-popover.red-ui-popover-bottom:after,.red-ui-popover.red-ui-popover-bottom:before{bottom:100%;left:50%}.red-ui-popover.red-ui-popover-top:after,.red-ui-popover.red-ui-popover-top:before{top:100%;left:50%}.red-ui-popover.red-ui-popover-right:after{border-color:rgba(0,0,0,0);border-right-color:var(--red-ui-popover-border);border-width:10px;margin-top:-10px}.red-ui-popover.red-ui-popover-right:before{border-color:rgba(0,0,0,0);border-right-color:var(--red-ui-popover-border);border-width:11px;margin-top:-11px}.red-ui-popover.red-ui-popover-left:after{border-color:rgba(0,0,0,0);border-left-color:var(--red-ui-popover-border);border-width:10px;margin-top:-10px}.red-ui-popover.red-ui-popover-left:before{border-color:rgba(0,0,0,0);border-left-color:var(--red-ui-popover-border);border-width:11px;margin-top:-11px}.red-ui-popover.red-ui-popover-bottom:after{border-color:rgba(0,0,0,0);border-bottom-color:var(--red-ui-popover-border);border-width:10px;margin-left:-10px}.red-ui-popover.red-ui-popover-bottom:before{border-color:rgba(0,0,0,0);border-bottom-color:var(--red-ui-popover-border);border-width:11px;margin-left:-11px}.red-ui-popover.red-ui-popover-top:after{border-color:rgba(0,0,0,0);border-top-color:var(--red-ui-popover-border);border-width:10px;margin-left:-10px}.red-ui-popover.red-ui-popover-top:before{border-color:rgba(0,0,0,0);border-top-color:var(--red-ui-popover-border);border-width:11px;margin-left:-11px}.red-ui-popover-size-small{font-size:12px;line-height:1.8em}.red-ui-popover-size-small .red-ui-popover-content{padding:1px 4px}.red-ui-popover-size-small.red-ui-popover-right:after,.red-ui-popover-size-small.red-ui-popover-left:after{border-width:7px;margin-top:-7px}.red-ui-popover-size-small.red-ui-popover-right:before,.red-ui-popover-size-small.red-ui-popover-left:before{border-width:8px;margin-top:-8px}.red-ui-popover-size-small.red-ui-popover-bottom:after,.red-ui-popover-size-small.red-ui-popover-top:after{border-width:7px;margin-left:-7px}.red-ui-popover-size-small.red-ui-popover-bottom:before,.red-ui-popover-size-small.red-ui-popover-top:before{border-width:8px;margin-left:-8px}.red-ui-popover-key{font-size:11px;font-family:var(--red-ui-monospace-font);margin-left:3px;border:1px solid var(--red-ui-popover-color);border-radius:3px;padding:1px 2px}.red-ui-popover a{text-decoration:none;color:var(--red-ui-popover-color) !important}.red-ui-popover a:hover,.red-ui-popover a:focus{text-decoration:none;color:var(--red-ui-popover-color) !important}.red-ui-popover a:focus{outline:1px solid var(--red-ui-form-input-focus-color)}.red-ui-popover a.red-ui-button:not(.primary),.red-ui-popover button.red-ui-button:not(.primary){border-color:var(--red-ui-popover-button-border-color);background:var(--red-ui-popover-background);color:var(--red-ui-popover-color) !important}.red-ui-popover a.red-ui-button:not(.primary):not(.disabled):not(.ui-button-disabled):hover,.red-ui-popover button.red-ui-button:not(.primary):not(.disabled):not(.ui-button-disabled):hover{border-color:var(--red-ui-popover-button-border-color-hover)}.red-ui-popover a.red-ui-button.primary,.red-ui-popover button.red-ui-button.primary{border-color:var(--red-ui-popover-button-border-color)}.red-ui-popover a.red-ui-button.primary:not(.disabled):not(.ui-button-disabled):hover,.red-ui-popover button.red-ui-button.primary:not(.disabled):not(.ui-button-disabled):hover{border-color:var(--red-ui-popover-button-border-color-hover)}.red-ui-popover code{border:none;background:none;color:var(--red-ui-tertiary-text-color)}.red-ui-popover-panel{box-shadow:1px 1px 4px var(--red-ui-shadow);font-family:var(--red-ui-primary-font);font-size:var(--red-ui-primary-font-size);position:absolute;box-sizing:border-box;border:1px solid var(--red-ui-primary-border-color);background:var(--red-ui-secondary-background);z-index:2000}.nr-ui-view-lasso{stroke-width:1px;stroke:var(--red-ui-view-lasso-stroke);fill:var(--red-ui-view-lasso-fill);stroke-dasharray:10 5}.nr-ui-view-slice{stroke-width:1px;stroke:var(--red-ui-view-lasso-stroke);fill:none;stroke-dasharray:10 5}.node_label_italic,.red-ui-flow-node-label-italic{font-style:italic}.red-ui-flow-node-label-white{fill:var(--red-ui-view-background) !important}.red-ui-flow-node-label{stroke-width:0;fill:var(--red-ui-node-label-color);font-size:14px;pointer-events:none;-webkit-touch-callout:none;-webkit-user-select:none;-khtml-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none}.red-ui-flow-node-label .red-ui-flow-node-label-text{dominant-baseline:middle}.red-ui-flow-node-label.red-ui-flow-node-label-right .red-ui-flow-node-label-text{text-anchor:end}.red-ui-flow-port-label{stroke-width:0;fill:var(--red-ui-node-port-label-color);font-size:16px;dominant-baseline:middle;text-anchor:middle;pointer-events:none;-webkit-touch-callout:none;-webkit-user-select:none;-khtml-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none}.red-ui-flow-node{stroke:var(--red-ui-node-border);cursor:move;stroke-width:1}.red-ui-workspace-select-mode g.red-ui-flow-node.red-ui-flow-node-hovered *{cursor:pointer !important}.red-ui-workspace-select-mode g.red-ui-flow-node,.red-ui-workspace-select-mode g.red-ui-flow-link{opacity:.5}.red-ui-workspace-select-mode g.red-ui-flow-node.red-ui-flow-node-hovered:not(.red-ui-flow-node-selected){opacity:.9}.red-ui-workspace-select-mode g.red-ui-flow-node.red-ui-flow-node-hovered:not(.red-ui-flow-node-selected) .red-ui-flow-node{stroke-width:2;stroke:var(--red-ui-node-selected-color) !important;stroke-dasharray:10,4}.red-ui-flow-group.red-ui-flow-group-hovered .red-ui-flow-group-outline-select{stroke-opacity:.8 !important;stroke-dasharray:10 4 !important}.red-ui-flow-group.red-ui-flow-group-active-hovered:not(.red-ui-flow-group-hovered) .red-ui-flow-group-outline-select{stroke:var(--red-ui-link-link-color)}.red-ui-flow-group-outline{fill:none;stroke:var(--red-ui-node-selected-color);stroke-opacity:0;stroke-width:12;pointer-events:stroke}.red-ui-flow-group-outline-select{fill:none;stroke:var(--red-ui-node-selected-color);pointer-events:stroke;stroke-opacity:0;stroke-width:3}.red-ui-flow-group-outline-select.red-ui-flow-group-outline-select-background{stroke:var(--red-ui-view-background);stroke-width:6}.red-ui-flow-group-body{pointer-events:none;fill:var(--red-ui-group-default-fill);fill-opacity:var(--red-ui-group-default-fill-opacity);stroke-width:2;stroke:var(--red-ui-group-default-stroke);stroke-opacity:var(--red-ui-group-default-stroke-opacity)}.red-ui-flow-group-label{-webkit-user-select:none;-khtml-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;fill:var(--red-ui-group-default-label-color)}.red-ui-flow-node-unknown{stroke-dasharray:10,4;stroke:var(--red-ui-node-border-unknown)}.red-ui-flow-node-placeholder{stroke-dasharray:10,4;stroke:var(--red-ui-node-border-placeholder);fill:var(--red-ui-node-background-placeholder);opacity:.5;stroke-width:2}.red-ui-flow-node-icon-group text{-webkit-user-select:none;-khtml-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none}.red-ui-flow-node-icon-group .fa-lg{-webkit-user-select:none;-khtml-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;stroke:none;fill:var(--red-ui-node-icon-color);text-anchor:middle;font-family:FontAwesome}.red-ui-flow-node-icon-shade{stroke:none;fill:var(--red-ui-node-icon-background-color-fill);fill-opacity:var(--red-ui-node-icon-background-color-opacity)}.red-ui-flow-node-icon-shade-border{stroke-opacity:var(--red-ui-node-icon-border-color-opacity);stroke:var(--red-ui-node-icon-border-color);stroke-width:1}.red-ui-flow-node-button{fill:inherit}.red-ui-flow-node-button.red-ui-flow-node-button-disabled{opacity:.4}.red-ui-flow-node-button.red-ui-flow-node-button-disabled .red-ui-flow-node-button-button{cursor:default}.red-ui-flow-node-button.red-ui-flow-node-button-stopped{opacity:.4}.red-ui-flow-node-button.red-ui-flow-node-button-stopped .red-ui-flow-node-button-button{cursor:default;pointer-events:none}.red-ui-flow-node-button-button{cursor:pointer}.red-ui-flow-node-button-background{fill:var(--red-ui-node-background-placeholder)}.red-ui-flow-port{stroke:var(--red-ui-node-border);stroke-width:1;fill:var(--red-ui-node-port-background);cursor:crosshair}.red-ui-flow-node-error{fill:var(--red-ui-node-status-error-background);stroke:var(--red-ui-node-status-error-border);stroke-width:1px;cursor:default;stroke-linejoin:round;stroke-linecap:round}.red-ui-flow-node-changed{fill:var(--red-ui-node-status-changed-background);stroke:var(--red-ui-node-status-changed-border);cursor:default;stroke-width:1px;stroke-linejoin:round;stroke-linecap:round}.red-ui-workspace-select-mode g.red-ui-flow-node-selected{opacity:1}g.red-ui-flow-node-selected .red-ui-flow-node,g.red-ui-flow-node-selected .red-ui-flow-subflow-port{stroke-width:2;stroke:var(--red-ui-node-selected-color) !important}.red-ui-flow-node-highlighted{border-color:var(--red-ui-node-selected-color) !important;border-style:dashed !important;stroke:var(--red-ui-node-selected-color);stroke-width:3;stroke-dasharray:8,4}.red-ui-workspace-disabled .red-ui-flow-node{stroke-dasharray:8,3;fill-opacity:.5}.red-ui-workspace-disabled .red-ui-flow-link-line{stroke-dasharray:10,8 !important;stroke-width:2 !important;stroke:var(--red-ui-link-disabled-color)}.red-ui-workspace-disabled .red-ui-flow-port{fill-opacity:1;stroke-dasharray:none}.red-ui-workspace-disabled .red-ui-flow-group,.red-ui-workspace-disabled .red-ui-flow-group-body{stroke-dasharray:8,3}.red-ui-flow-node-disabled.red-ui-flow-node,.red-ui-flow-node-disabled .red-ui-flow-node{stroke-dasharray:8,3;fill-opacity:.5}.red-ui-flow-node-disabled.red-ui-flow-link-line{stroke-dasharray:10,8 !important;stroke-width:2 !important;stroke:var(--red-ui-link-disabled-color)}.red-ui-flow-node-disabled .red-ui-flow-port{fill-opacity:1;stroke-dasharray:none}.red-ui-flow-node-status-dot-red{fill:var(--red-ui-node-status-colors-red);stroke:var(--red-ui-node-status-colors-red)}.red-ui-flow-node-status-ring-red{fill:var(--red-ui-view-background);stroke:var(--red-ui-node-status-colors-red)}.red-ui-flow-node-status-dot-green{fill:var(--red-ui-node-status-colors-green);stroke:var(--red-ui-node-status-colors-green)}.red-ui-flow-node-status-ring-green{fill:var(--red-ui-view-background);stroke:var(--red-ui-node-status-colors-green)}.red-ui-flow-node-status-dot-yellow{fill:var(--red-ui-node-status-colors-yellow);stroke:var(--red-ui-node-status-colors-yellow)}.red-ui-flow-node-status-ring-yellow{fill:var(--red-ui-view-background);stroke:var(--red-ui-node-status-colors-yellow)}.red-ui-flow-node-status-dot-blue{fill:var(--red-ui-node-status-colors-blue);stroke:var(--red-ui-node-status-colors-blue)}.red-ui-flow-node-status-ring-blue{fill:var(--red-ui-view-background);stroke:var(--red-ui-node-status-colors-blue)}.red-ui-flow-node-status-dot-grey{fill:var(--red-ui-node-status-colors-grey);stroke:var(--red-ui-node-status-colors-grey)}.red-ui-flow-node-status-ring-grey{fill:var(--red-ui-view-background);stroke:var(--red-ui-node-status-colors-grey)}.red-ui-flow-node-status-dot-gray{fill:var(--red-ui-node-status-colors-gray);stroke:var(--red-ui-node-status-colors-gray)}.red-ui-flow-node-status-ring-gray{fill:var(--red-ui-view-background);stroke:var(--red-ui-node-status-colors-gray)}.red-ui-flow-node-status-label{-webkit-user-select:none;-khtml-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;stroke-width:0;fill:var(--red-ui-secondary-text-color);font-size:9pt;text-anchor:start}.red-ui-flow-port-hovered{stroke:var(--red-ui-port-selected-color);fill:var(--red-ui-port-selected-color)}.red-ui-flow-subflow-port{fill:var(--red-ui-node-background-placeholder);stroke:var(--red-ui-node-border)}.red-ui-flow-drag-line{stroke:var(--red-ui-node-selected-color) !important;stroke-width:3;fill:none;pointer-events:none}.red-ui-flow-link-line{stroke:var(--red-ui-link-color);stroke-width:3;fill:none;pointer-events:none}.red-ui-flow-link-link{stroke-width:2;stroke:var(--red-ui-link-link-color);fill:none;stroke-dasharray:25,4}.red-ui-flow-link-off-flow{stroke-width:2}.red-ui-flow-link-port{fill:var(--red-ui-node-link-port-background);stroke:var(--red-ui-link-link-color);stroke-width:1}.red-ui-flow-link-group-active .red-ui-flow-link-port{stroke:var(--red-ui-link-link-active-color)}.red-ui-flow-link-group:hover{cursor:pointer}.red-ui-flow-link-outline{stroke:var(--red-ui-view-background);stroke-opacity:.4;stroke-width:5;cursor:crosshair;fill:none;pointer-events:none}.red-ui-flow-link-background{stroke:var(--red-ui-view-background);opacity:0;stroke-width:20;cursor:crosshair;fill:none}.red-ui-flow-link-splice>.red-ui-flow-link-line{stroke-dasharray:15,8}g.red-ui-flow-link-selected path.red-ui-flow-link-line{stroke:var(--red-ui-node-selected-color)}g.red-ui-flow-link-unknown path.red-ui-flow-link-line{stroke:var(--red-ui-link-unknown-color);stroke-width:2;stroke-dasharray:10,4}@keyframes red-ui-flow-port-tooltip-fadeIn{from{opacity:0}to{opacity:1}}.red-ui-flow-port-tooltip{opacity:0;animation:.1s ease-in 0s 1 normal forwards red-ui-flow-port-tooltip-fadeIn;pointer-events:none}.red-ui-flow-port-tooltip path:first-child{fill:var(--red-ui-popover-background);stroke:var(--red-ui-popover-background);stroke-width:1}.red-ui-flow-port-tooltip-label{stroke-width:0;fill:var(--red-ui-popover-color);font-family:var(--red-ui-primary-font);font-size:12px;pointer-events:none;-webkit-touch-callout:none;white-space:pre;-webkit-user-select:none;-khtml-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none}.red-ui-flow-junction-dragging .red-ui-flow-junction-background{background:red !important}.red-ui-flow-junction:not(.red-ui-flow-junction-dragging):hover .red-ui-flow-junction-background{transform:scale(1.4);stroke-width:.6}.red-ui-flow-junction:not(.red-ui-flow-junction-dragging):hover .red-ui-flow-junction-port{opacity:1;pointer-events:auto}.red-ui-flow-junction:not(.red-ui-flow-junction-dragging):hover .red-ui-flow-junction-port-input{transform:translate(-10px, 0)}.red-ui-flow-junction:not(.red-ui-flow-junction-dragging):hover .red-ui-flow-junction-port-output{transform:translate(10px, 0)}.red-ui-flow-junction-port{stroke:var(--red-ui-node-border);stroke-width:1;fill:var(--red-ui-node-port-background);cursor:crosshair;transition:transform .1s;opacity:0;pointer-events:none}.red-ui-flow-junction-background{stroke:var(--red-ui-node-border);stroke-width:1;fill:var(--red-ui-node-port-background);cursor:crosshair;transform:scale(1);transition:transform .1s}.red-ui-flow-junction-hovered{stroke:var(--red-ui-port-selected-color);fill:var(--red-ui-port-selected-color)}.red-ui-flow-junction.selected .red-ui-flow-junction-background{stroke:var(--red-ui-port-selected-color)}#red-ui-settings-tab-palette{height:100%}#red-ui-palette-editor{text-align:left;position:absolute;top:0px;right:0;bottom:0;left:0;padding:0;box-sizing:border-box;background:var(--red-ui-secondary-background)}#red-ui-palette-editor .red-ui-editableList-container{border:none;border-radius:0;padding:0px}#red-ui-palette-editor .red-ui-editableList-container li{padding:0px}#red-ui-palette-editor .red-ui-editableList-container li .red-ui-button{min-width:60px}#red-ui-palette-editor .red-ui-editableList-container li .disabled .red-ui-palette-module-name{font-style:italic;color:var(--red-ui-tertiary-text-color)}#red-ui-palette-editor .red-ui-editableList-container li .disabled .red-ui-palette-module-version{color:var(--red-ui-tertiary-text-color)}#red-ui-palette-editor .red-ui-editableList-container li .disabled .red-ui-palette-module-errors .fa-warning{opacity:.5}#red-ui-palette-editor .red-ui-editableList-container li .disabled ul.red-ui-palette-module-error-list li{color:var(--red-ui-tertiary-text-color)}#red-ui-palette-editor .red-ui-editableList-container li .red-ui-editableList-item-content{padding:12px 16px}#red-ui-palette-editor .red-ui-palette-editor-tab{position:absolute;top:35px;left:0;right:0;bottom:0}#red-ui-palette-editor .red-ui-palette-editor-toolbar{background:var(--red-ui-primary-background);box-sizing:border-box;padding:8px 10px;border-bottom:1px solid var(--red-ui-primary-border-color);text-align:right}#red-ui-palette-editor .red-ui-palette-module-shade-status{color:var(--red-ui-secondary-text-color)}#red-ui-palette-editor .red-ui-palette-module-updated{margin-left:10px}#red-ui-palette-editor .red-ui-palette-module-link{margin-left:5px}#red-ui-palette-editor .red-ui-palette-module-description{margin-left:20px;font-size:.9em;color:var(--red-ui-secondary-text-color)}#red-ui-palette-editor .red-ui-palette-module-content{display:none;padding:10px 3px}#red-ui-palette-editor i.fa.red-ui-palette-module-node-chevron{width:8px;margin-right:0;transform:rotate(0deg);transition:transform .2s ease-in-out}#red-ui-palette-editor .expanded i.fa.red-ui-palette-module-node-chevron{transform:rotate(90deg)}#red-ui-palette-editor .red-ui-palette-module-set{border:1px solid var(--red-ui-secondary-border-color);border-radius:0;padding:5px;position:relative}#red-ui-palette-editor .red-ui-palette-module-set:not(:last-child){border-bottom:none}#red-ui-palette-editor .red-ui-palette-module-set:first-child{border-top-right-radius:2px;border-top-left-radius:2px}#red-ui-palette-editor .red-ui-palette-module-set:last-child{border-bottom-right-radius:2px;border-bottom-left-radius:2px}#red-ui-palette-editor .red-ui-palette-module-type{color:var(--red-ui-secondary-text-color);padding-left:5px;font-size:.9em;-webkit-user-select:auto;-khtml-user-select:auto;-moz-user-select:auto;-ms-user-select:auto;user-select:auto}#red-ui-palette-editor .red-ui-palette-module-type-swatch{display:inline-block;width:12px;height:12px;border-radius:3px;vertical-align:middle;margin-right:5px;background:var(--red-ui-primary-background);border:1px dashed var(--red-ui-secondary-border-color)}#red-ui-palette-editor .red-ui-palette-module-set-button-group{position:absolute;right:4px;top:4px}#red-ui-palette-editor .red-ui-palette-module-set-disabled{background:var(--red-ui-list-item-background-disabled)}#red-ui-palette-editor .red-ui-palette-module-set-disabled .red-ui-palette-module-type{color:var(--red-ui-secondary-text-color-disabled-active)}#red-ui-palette-editor .red-ui-palette-module-more{padding:0 !important;margin-top:10px;margin-bottom:10px;background:var(--red-ui-tab-background-inactive)}#red-ui-palette-editor .red-ui-palette-module-more a{display:block;text-align:center;padding:12px 8px;color:var(--red-ui-text-color-code)}#red-ui-palette-editor .red-ui-palette-module-more a:hover{text-decoration:none;background:var(--red-ui-tab-background-hover)}.red-ui-palette-module-meta{color:var(--red-ui-secondary-text-color);position:relative}.red-ui-palette-module-meta.disabled{color:var(--red-ui-secondary-text-color-disabled)}.red-ui-palette-module-meta .fa{width:15px;text-align:center;margin-right:5px}.red-ui-palette-module-name{color:var(--red-ui-primary-text-color);white-space:nowrap;-webkit-user-select:auto;-khtml-user-select:auto;-moz-user-select:auto;-ms-user-select:auto;user-select:auto}.red-ui-palette-module-version,.red-ui-palette-module-updated,.red-ui-palette-module-link{font-style:italic;font-size:.8em;-webkit-user-select:auto;-khtml-user-select:auto;-moz-user-select:auto;-ms-user-select:auto;user-select:auto}.red-ui-palette-module-button-group{position:absolute;right:0;bottom:0}.red-ui-palette-module-button-group a{margin-left:5px}.red-ui-palette-module-meta .fa-warning{color:var(--red-ui-text-color-warning)}ul.red-ui-palette-module-error-list{display:inline-block;list-style-type:none;margin:0;font-size:.9em}ul.red-ui-palette-module-error-list li{border:none;background:none}.red-ui-palette-module-shade{position:absolute;top:0;left:0;bottom:0;right:0;background:var(--red-ui-shade-color);z-index:5;text-align:center;padding-top:20px}#red-ui-palette-module-install-shade{padding-top:80px}button.red-ui-palette-editor-upload-button{padding:0;height:25px;margin-top:-1px}button.red-ui-palette-editor-upload-button input[type=file]{opacity:0;margin:0;height:0;width:0}.red-ui-settings-tabs-content button.red-ui-palette-editor-upload-button label{margin:0;min-width:0;padding:2px 8px}button.red-ui-palette-editor-upload-button form{width:0}.red-ui-palette-editor-upload{display:none;position:absolute;left:0;right:0;top:44px;padding:20px;background:var(--red-ui-secondary-background);border-bottom:1px var(--red-ui-secondary-border-color solid);box-shadow:1px 1px 4px var(--red-ui-shadow)}.red-ui-palette-editor-upload .placeholder-input{width:calc(100% - 180px);margin:0}.red-ui-palette-editor-upload-buttons{float:right}.red-ui-palette-editor-upload-buttons button{margin-left:10px}.red-ui-diff-panel{padding:5px;padding-top:30px;position:relative}.red-ui-diff-panel .red-ui-editableList-container{border-radius:1px;padding:0;background:var(--red-ui-tertiary-background)}.red-ui-diff-panel .red-ui-diff-list li{background:var(--red-ui-tertiary-background);padding:0px;border:none;min-height:0}.red-ui-diff-panel .red-ui-editableList-item-content{padding:5px}.red-ui-diff-container{position:absolute;top:40px;right:0;bottom:0;left:0;overflow-y:scroll}.red-ui-diff-panel-headers{position:absolute;left:232px;right:12px;top:5px;height:25px}.red-ui-diff-panel-headers div{height:25px;display:inline-block;box-sizing:border-box;padding-top:2px;overflow:hidden;white-space:nowrap;text-overflow:ellipsis;width:50%;background:var(--red-ui-tertiary-background);text-align:center;border-top:1px solid var(--red-ui-secondary-border-color);border-color:var(--red-ui-secondary-border-color);border-left:1px solid var(--red-ui-secondary-border-color)}.red-ui-diff-panel-headers div:last-child{border-right:1px solid var(--red-ui-secondary-border-color)}.red-ui-diff-dialog-toolbar{box-sizing:border-box;color:var(--red-ui-secondary-text-color);text-align:right;padding:8px 10px;background:var(--red-ui-primary-background);border-bottom:1px solid var(--red-ui-secondary-border-color);white-space:nowrap}.red-ui-diff-list-flow{background:var(--red-ui-secondary-background);border:1px solid var(--red-ui-secondary-border-color);border-radius:1px;overflow:hidden}.red-ui-diff-list-flow.collapsed .red-ui-diff-list-flow-title .red-ui-diff-list-chevron{transform:rotate(-90deg)}.red-ui-diff-list-flow.collapsed .red-ui-diff-list-node{display:none}.red-ui-diff-list-flow-stats{font-size:.9em}.red-ui-diff-list-chevron{display:inline-block;width:15px;text-align:center;margin-left:3px;transition:transform .1s ease-in-out}.red-ui-diff-list-node{margin-left:20px;font-size:.9em}.red-ui-diff-list-node:first-child{border-top:1px solid var(--red-ui-tertiary-border-color)}.red-ui-diff-list-node:not(:last-child){border-bottom:1px solid var(--red-ui-tertiary-border-color)}.red-ui-diff-list-node.collapsed .red-ui-diff-list-chevron{transform:rotate(-90deg)}.red-ui-diff-list-node.collapsed .red-ui-diff-list-node-properties{display:none}.red-ui-diff-list-node table{border-collapse:collapse;table-layout:fixed;width:calc(100% - 20px);margin-left:20px}.red-ui-diff-list-node col:first-child{width:180px}.red-ui-diff-list-node col:not(:first-child){width:100%}.red-ui-diff-list-node td,.red-ui-diff-list-node th{border-top:1px solid var(--red-ui-secondary-border-color);border-left:1px solid var(--red-ui-secondary-border-color);padding:0 0 0 3px;text-align:left;overflow-x:auto}.red-ui-diff-list-node td:first-child,.red-ui-diff-list-node th:first-child{border-left:none}.red-ui-diff-list-node tr{vertical-align:top}.red-ui-diff-list-node tr:first-child td{white-space:nowrap;overflow:hidden}.red-ui-diff-list-node tr:hover{background:var(--red-ui-secondary-background-selected)}.red-ui-diff-list-node td .red-ui-diff-status{margin-left:0}.red-ui-diff-list-node tr:not(.red-ui-diff-list-header) .red-ui-diff-status{width:12px;margin-left:0;margin-top:0;margin-bottom:0;margin-right:5px}.red-ui-diff-three-way .red-ui-diff-list-node-cell{width:calc((100% - 220px)/2)}.red-ui-diff-three-way .red-ui-diff-list-node-cell:first-child{width:220px}.red-ui-diff-three-way col:not(:first-child){width:50%}.red-ui-diff-three-way .red-ui-diff-list-node .red-ui-diff-list-node-cell{width:calc((100% + 20px - 220px)/2)}.red-ui-diff-three-way .red-ui-diff-list-node .red-ui-diff-list-node-cell:first-child{width:200px}.red-ui-diff-list-flow-title{cursor:pointer;padding:0}.red-ui-diff-list-flow-title:hover{background:var(--red-ui-secondary-background-selected)}.red-ui-diff-list-flow-title-meta{vertical-align:middle;display:inline-block;padding-top:2px}.red-ui-diff-list-node-header{cursor:pointer}.red-ui-diff-list-node-header:hover{background:var(--red-ui-secondary-background-selected)}.red-ui-diff-list-node-icon{vertical-align:middle;display:inline-block;margin:5px;width:18px;height:15px;background:var(--red-ui-form-input-background);border-radius:2px;border:1px solid var(--red-ui-node-border);background-position:5% 50%;background-repeat:no-repeat;background-size:contain;position:relative}.red-ui-diff-list-node-icon .red-ui-palette-icon{background-position:49% 50%;width:15px}.red-ui-diff-list-node-icon .red-ui-palette-icon-fa{position:relative;top:-2.5px;left:0px}.red-ui-diff-list-node-icon .red-ui-palette-icon-container{width:18px}.red-ui-diff-list-flow-empty .red-ui-diff-list-chevron i{display:none}.red-ui-diff-list-flow-empty .red-ui-diff-list-flow-title{cursor:default}.red-ui-diff-list-flow-empty .red-ui-diff-list-flow-title:hover{background:none}.red-ui-diff-status-deleted{cursor:default !important}.red-ui-diff-status-deleted .red-ui-diff-status{color:var(--red-ui-diff-state-deleted)}.red-ui-diff-status-deleted .red-ui-diff-list-node-node{opacity:.5}.red-ui-diff-status-deleted .red-ui-diff-list-node-description{opacity:.5;text-decoration:line-through}.red-ui-diff-status-added{cursor:default !important}.red-ui-diff-status-added .red-ui-diff-status{color:var(--red-ui-diff-state-added)}.red-ui-diff-status-moved .red-ui-diff-status{color:var(--red-ui-diff-state-moved)}.red-ui-diff-status-changed .red-ui-diff-status{color:var(--red-ui-diff-state-changed)}.red-ui-diff-status-unchanged .red-ui-diff-status{color:var(--red-ui-diff-state-unchanged)}.red-ui-diff-status-conflict .red-ui-diff-status{color:var(--red-ui-diff-state-conflict)}.red-ui-diff-list-node-title{display:inline-block}.red-ui-diff-list-node-title .red-ui-diff-status{margin-left:15px}.red-ui-diff-list-node-properties{margin:0;color:var(--red-ui-primary-text-color)}.red-ui-diff-status{display:inline-block;height:20px;margin-left:5px;vertical-align:top;margin-top:6px;margin-bottom:6px;text-align:center}.red-ui-diff-list-element{display:inline-block;width:calc(100% - 20px)}.red-ui-diff-list-node-description{color:var(--red-ui-form-text-color);margin-right:5px;padding-top:5px;display:inline-block}.red-ui-diff-list-node-description:after{content:"";display:table;clear:both}.red-ui-diff-state-added{color:var(--red-ui-diff-state-added)}.red-ui-diff-state-deleted{color:var(--red-ui-diff-state-deleted)}.red-ui-diff-state-changed{color:var(--red-ui-diff-state-changed)}.red-ui-diff-state-unchanged{color:var(--red-ui-diff-state-unchanged)}.red-ui-diff-state-conflicted{color:var(--red-ui-diff-state-conflicted)}.red-ui-diff-list-node-cell{display:inline-block;vertical-align:top;box-sizing:border-box;width:calc((100% - 20px)/2);height:32px;border-left:1px solid var(--red-ui-secondary-border-color);padding-top:2px;white-space:nowrap;overflow:hidden;position:relative}.red-ui-diff-empty{background:var(--red-ui-secondary-background-disabled);background:repeating-linear-gradient(20deg, var(--red-ui-secondary-background), var(--red-ui-secondary-background) 5px, var(--red-ui-secondary-background-disabled) 5px, var(--red-ui-secondary-background-disabled) 10px)}.red-ui-diff-list-node-cell:first-child{border-left:none}.red-ui-diff-list-cell-label{margin-left:20px;vertical-align:top;box-sizing:border-box;padding-left:8px;width:120px}.red-ui-diff-list-wires{display:inline-block}.red-ui-diff-list-wires .red-ui-diff-list-node-node{width:18px;height:15px}.red-ui-diff-list-wires .red-ui-palette-icon-container{width:18px}.red-ui-diff-list-wires .red-ui-palette-icon{width:15px}.red-ui-diff-list-wires ul,.red-ui-diff-list-wires li,.red-ui-diff-list-wires ol{background:none !important}.red-ui-diff-list-wires ul{vertical-align:middle;display:inline-block;margin-left:5px}.red-ui-diff-list-wires li{list-style-type:none !important}.red-ui-diff-list-wires ol{font-size:.9em;margin:0}.red-ui-diff-list-wires ol>span{vertical-align:middle;display:inline-block;width:30px;text-align:center}.red-ui-diff-list-node-props .red-ui-diff-list-node-cell:first-child{padding:6px 0px}.red-ui-diff-list-node-props .red-ui-diff-list-node-cell:first-child span:not(.red-ui-diff-list-chevron){margin-left:5px}.red-ui-diff-list-cell .red-ui-debug-msg-row:hover{background:none}.red-ui-diff-list-cell.red-ui-diff-status-changed{background:var(--red-ui-diff-state-changed-background)}.red-ui-diff-list-cell.red-ui-diff-status-conflict{background:var(--red-ui-diff-state-conflict-background)}label.red-ui-diff-selectbox{position:absolute;top:0;right:0;bottom:0;width:35px;text-align:center;border-left:1px solid var(--red-ui-secondary-border-color);margin:0}label.red-ui-diff-selectbox input[type=radio]{margin-top:8px}label.red-ui-diff-selectbox:hover{background:var(--red-ui-secondary-background-hover)}.red-ui-diff-list-node-conflict.red-ui-diff-select-remote .red-ui-diff-list-node-remote{background:var(--red-ui-diff-state-added-background)}.red-ui-diff-list-node-conflict.red-ui-diff-select-remote .red-ui-diff-list-node-remote label{border-left-color:var(--red-ui-diff-state-added-border)}.red-ui-diff-list-node-conflict.red-ui-diff-select-remote .red-ui-diff-list-node-local{background:var(--red-ui-diff-state-deleted-background)}.red-ui-diff-list-node-conflict.red-ui-diff-select-remote .red-ui-diff-list-node-local label{border-left-color:var(--red-ui-diff-state-deleted-border)}.red-ui-diff-list-node-conflict.red-ui-diff-select-local .red-ui-diff-list-node-local{background:var(--red-ui-diff-state-added-background)}.red-ui-diff-list-node-conflict.red-ui-diff-select-local .red-ui-diff-list-node-local label{border-left-color:var(--red-ui-diff-state-added-border)}.red-ui-diff-list-node-conflict.red-ui-diff-select-local .red-ui-diff-list-node-remote{background:var(--red-ui-diff-state-deleted-background)}.red-ui-diff-list-node-conflict.red-ui-diff-select-local .red-ui-diff-list-node-remote label{border-left-color:var(--red-ui-diff-state-deleted-border)}ul.red-ui-deploy-dialog-confirm-list{font-size:.9em;width:400px;margin:10px auto;text-align:left}.red-ui-deploy-dialog-confirm-conflict-row img{vertical-align:middle;height:30px;margin-right:10px}.red-ui-deploy-dialog-confirm-conflict-row i{vertical-align:middle;text-align:center;font-size:30px;width:30px;margin-right:10px}.red-ui-deploy-dialog-confirm-conflict-row i.fa-check{color:var(--red-ui-text-color-success)}.red-ui-deploy-dialog-confirm-conflict-row i.fa-exclamation{color:var(--red-ui-secondary-text-color)}.red-ui-deploy-dialog-confirm-conflict-row div{vertical-align:middle;width:calc(100% - 60px);display:inline-block}#red-ui-diff-dialog-toolbar-resolved-conflicts .red-ui-diff-status{margin:0}.red-ui-diff-text-diff-button{float:right;margin:2px 3px;line-height:14px;height:16px}.red-ui-diff-text{height:100%;overflow-y:auto}.red-ui-diff-text table.red-ui-diff-text-content{margin:10px;border:1px solid var(--red-ui-secondary-border-color);border-radius:3px;table-layout:fixed;width:calc(100% - 20px)}.red-ui-diff-text table.red-ui-diff-text-content td{vertical-align:top;word-wrap:break-word}.red-ui-diff-text table.red-ui-diff-text-content td.lineno{font-family:var(--red-ui-monospace-font);text-align:right;color:var(--red-ui-tertiary-text-color);background:var(--red-ui-tertiary-background);padding:1px 5px}.red-ui-diff-text table.red-ui-diff-text-content td.lineno.added{background:var(--red-ui-diff-state-added-header-background)}.red-ui-diff-text table.red-ui-diff-text-content td.lineno.removed{background:var(--red-ui-diff-state-deleted-header-background)}.red-ui-diff-text table.red-ui-diff-text-content td.lineno:nth-child(3){border-left:1px solid var(--red-ui-secondary-border-color)}.red-ui-diff-text table.red-ui-diff-text-content td.linetext{font-family:var(--red-ui-monospace-font);white-space:pre-wrap;padding:1px 5px;border-left:1px solid var(--red-ui-tertiary-border-color)}.red-ui-diff-text table.red-ui-diff-text-content td.linetext span.prefix{width:30px;display:inline-block;text-align:center;color:var(--red-ui-diff-state-prefix-color)}.red-ui-diff-text table.red-ui-diff-text-content td.linetext.added{border-left-color:var(--red-ui-diff-state-added-header-border)}.red-ui-diff-text table.red-ui-diff-text-content td.linetext.removed{border-left-color:var(--red-ui-diff-state-deleted-header-border)}.red-ui-diff-text table.red-ui-diff-text-content td.blank{background:var(--red-ui-tertiary-background)}.red-ui-diff-text table.red-ui-diff-text-content td.added{background:var(--red-ui-diff-state-added-background);color:var(--red-ui-diff-state-color)}.red-ui-diff-text table.red-ui-diff-text-content td.removed{background:var(--red-ui-diff-state-deleted-background);color:var(--red-ui-diff-state-color)}.red-ui-diff-text table.red-ui-diff-text-content tr.mergeHeader td{color:var(--red-ui-diff-merge-header-color);background:var(--red-ui-diff-merge-header-background);height:26px;vertical-align:middle}.red-ui-diff-text table.red-ui-diff-text-content tr.mergeHeader-separator td{color:var(--red-ui-diff-merge-header-color);background:var(--red-ui-diff-merge-header-border-color);height:0px}.red-ui-diff-text table.red-ui-diff-text-content tr.mergeHeader-ours td{border-top:2px solid var(--red-ui-diff-merge-header-border-color)}.red-ui-diff-text table.red-ui-diff-text-content tr.mergeHeader-theirs td{border-bottom:2px solid var(--red-ui-diff-merge-header-border-color)}.red-ui-diff-text table.red-ui-diff-text-content td.unchanged{background:var(--red-ui-diff-state-unchanged-background);color:var(--red-ui-diff-state-unchanged)}.red-ui-diff-text table.red-ui-diff-text-content tr.unchanged{background:var(--red-ui-diff-state-unchanged-background)}.red-ui-diff-text table.red-ui-diff-text-content tr.start-block{border-top:1px solid var(--red-ui-secondary-border-color)}.red-ui-diff-text table.red-ui-diff-text-content tr.end-block{border-bottom:1px solid var(--red-ui-secondary-border-color)}.red-ui-diff-text table.red-ui-diff-text-content tr.red-ui-diff-text-file-header td{background:var(--red-ui-primary-background);padding:5px 10px 5px 0;color:var(--red-ui-primary-text-color);cursor:pointer}.red-ui-diff-text table.red-ui-diff-text-content tr.red-ui-diff-text-file-header td .filename{font-family:var(--red-ui-monospace-font)}.red-ui-diff-text table.red-ui-diff-text-content tr.red-ui-diff-text-file-header td i.red-ui-diff-list-chevron{width:30px}.red-ui-diff-text table.red-ui-diff-text-content tr.red-ui-diff-text-file-header.collapsed td i.red-ui-diff-list-chevron{transform:rotate(-90deg)}.red-ui-diff-text table.red-ui-diff-text-content tr.red-ui-diff-text-commit-header td{background:var(--red-ui-primary-background);padding:5px 10px;color:var(--red-ui-primary-text-color)}.red-ui-diff-text table.red-ui-diff-text-content tr.red-ui-diff-text-commit-header td h3{font-size:1.4em;margin:0}.red-ui-diff-text table.red-ui-diff-text-content tr.red-ui-diff-text-commit-header td .commit-summary{border-top:1px solid var(--red-ui-secondary-border-color);padding-top:5px;color:var(--red-ui-secondary-text-color)}.red-ui-diff-text table.red-ui-diff-text-content tr.red-ui-diff-text-commit-header td .commit-body{margin-bottom:15px;white-space:pre;line-height:1.2em}.red-ui-diff-text table.red-ui-diff-text-content tr.red-ui-diff-text-header>td:not(.red-ui-diff-flow-diff){font-family:var(--red-ui-monospace-font);padding:5px 10px;text-align:left;color:var(--red-ui-diff-text-header-color);background:var(--red-ui-diff-text-header-background);height:30px;vertical-align:middle;border-top:1px solid var(--red-ui-secondary-border-color);border-bottom:1px solid var(--red-ui-secondary-border-color)}.red-ui-diff-text table.red-ui-diff-text-content tr.red-ui-diff-text-expand td{cursor:pointer}.red-ui-diff-text table.red-ui-diff-text-content tr.red-ui-diff-text-expand td:hover{background:var(--red-ui-diff-text-header-background)}.red-ui-settings-tabs-container{position:absolute;top:0;left:0;bottom:0;width:120px;background:var(--red-ui-tertiary-background)}.red-ui-settings-tabs-content{position:absolute;top:0;left:120px;right:0;bottom:0;padding:0}.red-ui-settings-tabs-content h3:not(:first-child){border-top:1px solid var(--red-ui-secondary-border-color);margin-top:15px;margin-bottom:10px;padding-top:20px}.red-ui-settings-tabs-content label{display:inline-block;min-width:100px;vertical-align:top;margin-top:5px}.red-ui-settings-tabs-content label input{vertical-align:top;padding-bottom:0}.red-ui-settings-tabs-content div.uneditable-input{position:relative}.red-ui-settings-tabs-content input[type=number]{width:60px}.red-ui-settings-tabs-content h4{margin-top:20px;margin-bottom:10px}#red-ui-settings-tab-view{position:absolute;top:0;right:0;left:0;bottom:0;padding:8px 20px 20px;overflow-y:auto}.red-ui-settings-row{padding:5px 10px 2px}.red-ui-settings-section{position:relative}.red-ui-settings-section:after{content:"";display:table;clear:both}.red-ui-settings-section .uneditable-input,.red-ui-settings-section input[type=text],.red-ui-settings-section input[type=password],.red-ui-settings-section textarea{width:calc(100% - 150px)}.red-ui-settings-section textarea{resize:none;height:10em}#red-ui-projects-dialog{padding:0}#red-ui-projects-dialog .red-ui-editableList-container{padding:0px}#red-ui-projects-dialog .red-ui-projects-dialog-box{box-sizing:border-box;overflow-y:auto;padding:25px 25px 10px 25px}#red-ui-project-settings-tab-settings{overflow-y:auto}.red-ui-sidebar-vc-shade{background:var(--red-ui-primary-background)}.red-ui-projects-edit-form form{margin:0}.red-ui-projects-edit-form form .form-row{margin-bottom:15px}.red-ui-projects-edit-form form .form-row label{color:var(--red-ui-primary-text-color);width:100%;display:block}.red-ui-projects-edit-form form .form-row label.red-ui-projects-edit-form-inline-label{font-weight:normal;color:inherit;width:auto}.red-ui-projects-edit-form form .form-row input[type=text],.red-ui-projects-edit-form form .form-row input[type=password],.red-ui-projects-edit-form form .form-row textarea{width:100%}.red-ui-projects-edit-form form .form-row input[type=checkbox],.red-ui-projects-edit-form form .form-row input[type=radio]{width:auto;vertical-align:middle}.red-ui-projects-edit-form-sublabel{color:var(--red-ui-tertiary-text-color);text-align:right;margin-bottom:-15px;font-weight:normal}.red-ui-project-settings-tab-pane * .red-ui-projects-edit-form-sublabel{margin-right:50px;margin-top:-10px !important;margin-bottom:5px}.red-ui-projects-dialog-screen-start .red-ui-projects-dialog-screen-start-hero{text-align:center;font-size:1.4em;padding:10px;min-height:40px;color:var(--red-ui-primary-text-color)}.red-ui-projects-dialog-screen-start .red-ui-projects-dialog-screen-start-body{min-height:300px;line-height:1.6em}.red-ui-projects-dialog-screen-start .red-ui-projects-dialog-screen-start-body p{font-size:1.1em;margin-bottom:20px}.red-ui-projects-dialog-screen-start .red-ui-projects-dialog-screen-start-body p:first-child{font-weight:500;font-size:1.2em}.red-ui-projects-dialog-screen-start button.red-ui-button.red-ui-projects-dialog-button{width:calc(50% - 80px);margin:10px 20px;height:auto;line-height:2em;padding:10px}.red-ui-projects-dialog-screen-start .button-group{text-align:center}.red-ui-projects-dialog-screen-create{min-height:500px}.red-ui-projects-dialog-screen-create button.red-ui-projects-dialog-screen-create-type{position:relative;height:auto;padding:10px}.red-ui-projects-dialog-screen-create .button-group{text-align:center}.red-ui-projects-dialog-screen-secret{min-height:auto}.red-ui-projects-dialog-credentials-box{width:550px}.red-ui-projects-dialog-credentials-box>div{vertical-align:top;display:inline-block}.red-ui-projects-dialog-credentials-box-right{min-height:150px;box-sizing:border-box;float:right;width:331px;margin-left:-1px;padding:15px;margin-top:-15px;border:1px solid var(--red-ui-secondary-border-color);border-radius:3px}.red-ui-projects-dialog-credentials-box-left{width:220px}.red-ui-projects-dialog-credentials-box-left>div{padding:7px 8px 3px 8px;border:1px solid var(--red-ui-secondary-border-color);border-radius:4px;border-top-right-radius:0;border-bottom-right-radius:0;border-right-color:var(--red-ui-form-background)}.red-ui-projects-dialog-credentials-box-left>div.disabled{border-color:var(--red-ui-form-background);border-right-color:var(--red-ui-secondary-border-color)}.red-ui-projects-dialog-credentials-box-left>div i{font-size:1.4em;margin-right:8px;vertical-align:middle}.red-ui-projects-dialog-credentials-box-left>div label.red-ui-projects-edit-form-inline-label{margin-left:5px}.red-ui-projects-dialog-credentials-box-left>div label.red-ui-projects-edit-form-inline-label span{vertical-align:middle}.red-ui-projects-dialog-credentials-box-left>div input[type=radio]{vertical-align:middle;margin-top:0;margin-right:10px}.red-ui-projects-dialog-project-list-container{border:1px solid var(--red-ui-secondary-border-color);border-radius:2px;display:flex;flex-direction:column}.red-ui-projects-dialog-project-list-container .red-ui-search-container{flex-grow:0}.red-ui-projects-dialog-project-list-inner-container{flex-grow:1;overflow-y:auto;position:relative}.red-ui-projects-dialog-project-list-inner-container .red-ui-editableList-border{border:none}.red-ui-projects-dialog-project-list li{padding:0 !important}.red-ui-projects-dialog-project-list-entry{padding:12px 0;color:var(--red-ui-list-item-color);background:var(--red-ui-list-item-background);border-left:3px solid var(--red-ui-list-item-background);border-right:3px solid var(--red-ui-list-item-background)}.red-ui-projects-dialog-project-list-entry.projects-list-entry-current:not(.selectable){color:var(--red-ui-form-text-color);background:var(--red-ui-list-item-background-selected);border-left-color:var(--red-ui-list-item-border-selected);border-right-color:var(--red-ui-list-item-border-selected)}.red-ui-projects-dialog-project-list-entry.projects-list-entry-current i{color:var(--red-ui-secondary-text-color)}.red-ui-projects-dialog-project-list-entry.selectable{cursor:pointer}.red-ui-projects-dialog-project-list-entry.selectable:hover:not(.selected){color:var(--red-ui-form-text-color);background:var(--red-ui-list-item-background-hover);border-left-color:var(--red-ui-list-item-background-hover);border-right-color:var(--red-ui-list-item-background-hover)}.red-ui-projects-dialog-project-list-entry .red-ui-projects-dialog-project-list-entry-icon i{color:var(--red-ui-tertiary-text-color);font-size:2em}.red-ui-projects-dialog-project-list-entry.selected{color:var(--red-ui-form-text-color);background:var(--red-ui-list-item-background-selected);border-left-color:var(--red-ui-list-item-border-selected);border-right-color:var(--red-ui-list-item-border-selected)}.red-ui-projects-dialog-project-list-entry span{display:inline-block;vertical-align:middle}.red-ui-projects-dialog-project-list-entry .red-ui-projects-dialog-project-list-entry-icon{margin:0 10px 0 5px}.red-ui-projects-dialog-project-list-entry .red-ui-projects-dialog-project-list-entry-name{font-size:1.2em}.red-ui-projects-dialog-project-list-entry .red-ui-projects-dialog-project-list-entry-current{float:right;margin-right:20px;font-size:.9em;color:var(--red-ui-secondary-text-color);padding-top:4px}.red-ui-projects-dialog-project-list-entry .red-ui-projects-dialog-project-list-entry-tools{position:absolute;top:16px;right:30px;display:none;color:var(--red-ui-secondary-text-color)}.red-ui-projects-dialog-project-list-entry:hover .red-ui-projects-dialog-project-list-entry-tools{display:block}.red-ui-projects-dialog-project-list-entry-delete-confirm{position:absolute;top:0;right:0;bottom:0;left:100%;width:1000px;overflow:hidden;padding:5px 20px;background:var(--red-ui-secondary-background);transition:left .4s;white-space:nowrap}.red-ui-projects-dialog-project-list-entry-delete-confirm>span{line-height:40px}.red-ui-projects-dialog-project-list-entry-delete-confirm button{margin-left:20px}.red-ui-projects-dialog-screen-create-type{position:relative}.red-ui-projects-dialog-screen-create-type.red-ui-button.toggle.selected:not(.disabled):not(:disabled){color:var(--red-ui-secondary-text-color-active) !important}.red-ui-projects-dialog-screen-input-status{text-align:right;position:absolute;top:2px;right:8px;width:70px;height:30px;color:var(--red-ui-secondary-text-color)}.red-ui-sidebar-vc{height:100%}.red-ui-sidebar-vc-stack{position:absolute;top:0px;bottom:0;left:0;right:0;overflow:hidden}.red-ui-sidebar-vc-stack .red-ui-palette-category:not(.expanded) button{display:none}#red-ui-project-settings-tab-deps .red-ui-editableList-container{padding:0}#red-ui-project-settings-tab-deps .red-ui-editableList-border{border-radius:0}#red-ui-project-settings-tab-deps .red-ui-editableList-item-content{padding:0px 6px}#red-ui-project-settings-tab-deps .red-ui-palette-module-header{padding:6px 4px}#red-ui-project-settings-tab-deps .red-ui-palette-module-button{float:right}#red-ui-project-settings-tab-deps .red-ui-palette-module-unused>*{color:var(--red-ui-secondary-text-color)}#red-ui-project-settings-tab-deps .red-ui-palette-module-unknown{border:1px dashed var(--red-ui-secondary-border-color);background:var(--red-ui-secondary-background-inactive)}#red-ui-project-settings-tab-deps .red-ui-palette-module-not-installed{border:1px dashed var(--red-ui-text-color-warning)}#red-ui-project-settings-tab-deps .red-ui-palette-module-not-installed i.fa-warning{color:var(--red-ui-text-color-warning)}.red-ui-project-settings-tab-pane{position:absolute;top:0;left:0;right:0;bottom:0;overflow-y:auto;padding:8px 20px 20px}.red-ui-sidebar-vc .red-ui-editableList-container{background:var(--red-ui-tertiary-background);padding:0}.red-ui-sidebar-vc .red-ui-editableList-container li{padding:0;background:var(--red-ui-secondary-background)}.red-ui-sidebar-vc .red-ui-editableList-border{border:none;border-radius:0}.red-ui-sidebar-vc-change-container{position:relative;height:50%;box-sizing:border-box;transition:height .2s ease-in-out}.red-ui-sidebar-vc-merging .red-ui-sidebar-vc-change-container{height:33%}.red-ui-sidebar-vc-slide-box{position:absolute;bottom:0;left:0;right:0;height:0;transition:height .2s ease-in-out;background:var(--red-ui-tertiary-background);box-sizing:border-box;overflow:hidden}.red-ui-sidebar-vc-slide-box.red-ui-sidebar-vc-slide-box-top{z-index:4;top:0px;left:auto;width:100%;max-width:280px;border-left:1px solid var(--red-ui-primary-border-color);border-right:1px solid var(--red-ui-primary-border-color);border-bottom:1px solid var(--red-ui-primary-border-color);box-shadow:1px 1px 4px var(--red-ui-shadow);color:var(--red-ui-primary-text-color);background:var(--red-ui-tertiary-background);padding:10px;box-sizing:border-box}.red-ui-sidebar-vc-slide-box.red-ui-sidebar-vc-slide-box-bottom{bottom:0px;border-top:1px solid var(--red-ui-secondary-border-color)}.red-ui-sidebar-vc-slide-box textarea{height:110px;margin:10px;width:calc(100% - 20px);box-sizing:border-box;border-radius:1px;resize:none}.red-ui-projects-branch-list{position:relative}.red-ui-projects-branch-list .red-ui-searchBox-container{border-top:1px solid var(--red-ui-secondary-border-color);border-left:1px solid var(--red-ui-secondary-border-color);border-right:1px solid var(--red-ui-secondary-border-color);border-top-left-radius:2px;border-top-right-radius:2px;overflow:hidden}.red-ui-projects-branch-list .red-ui-editableList{border:1px solid var(--red-ui-secondary-border-color);border-bottom-left-radius:2px;border-bottom-right-radius:2px}.red-ui-projects-branch-list .red-ui-editableList>.red-ui-editableList-border{border-radius:0;border:none}.red-ui-projects-branch-list .red-ui-editableList .red-ui-editableList-container{padding:0}.red-ui-projects-branch-list .red-ui-editableList .red-ui-editableList-container li{padding:0;background:var(--red-ui-secondary-background)}.uneditable-input .red-ui-projects-branch-list .red-ui-editableList{border-left:none;border-bottom:none;border-right:none}.uneditable-input .red-ui-projects-branch-list .red-ui-searchBox-container{border-left:none;border-right:none}.red-ui-sidebar-vc-slide-box-header{margin-bottom:10px}.red-ui-sidebar-vc-slide-box-toolbar{padding:0 20px;text-align:right}.red-ui-sidebar-vc-branch-list-entry{padding:5px 8px;margin:0 1px;color:var(--red-ui-list-item-color);background:var(--red-ui-list-item-background);border-left:2px solid var(--red-ui-list-item-background);border-right:2px solid var(--red-ui-list-item-background);cursor:pointer}.red-ui-sidebar-vc-branch-list-entry.selected{border-left-color:var(--red-ui-list-item-border-selected);border-right-color:var(--red-ui-list-item-border-selected)}.red-ui-sidebar-vc-branch-list-entry i{width:16px;text-align:center}.red-ui-sidebar-vc-branch-list-entry.input-error{cursor:default}.red-ui-sidebar-vc-branch-list-entry:not(.input-error):hover{background:var(--red-ui-list-item-background-hover);border-left-color:var(--red-ui-list-item-border-selected);border-right-color:var(--red-ui-list-item-border-selected)}.red-ui-sidebar-vc-branch-list-entry span{margin-left:5px}.red-ui-sidebar-vc-branch-list-entry span.current{float:right;font-size:.8em;color:var(--red-ui-tertiary-text-color)}.red-ui-sidebar-vc-change-entry{height:20px;padding:5px 10px;position:relative;white-space:nowrap}.red-ui-sidebar-vc-change-entry span{margin:0 6px}.red-ui-sidebar-vc-change-entry a{color:currentColor}.red-ui-sidebar-vc-change-entry a.disabled{pointer-events:none}.red-ui-sidebar-vc-change-entry .red-ui-sidebar-vc-change-entry-tools{position:absolute;top:4px;right:4px;display:none}.red-ui-sidebar-vc-change-entry .red-ui-sidebar-vc-change-entry-tools button{width:24px}.red-ui-sidebar-vc-change-entry:hover .red-ui-sidebar-vc-change-entry-tools{display:block}.red-ui-sidebar-vc-change-entry.red-ui-help-info-node{text-align:center;background:var(--red-ui-list-item-background);white-space:normal;height:auto}.red-ui-sidebar-vc-commit-entry{min-height:20px;padding:5px 10px;position:relative;white-space:nowrap;overflow:hidden;cursor:pointer}.red-ui-sidebar-vc-commit-entry:hover{background:var(--red-ui-secondary-background-hover)}.red-ui-sidebar-vc-commit-more{color:var(--red-ui-secondary-text-color);text-align:center;padding:10px;font-style:italic}.red-ui-sidebar-vc-commit-sha{float:right;font-family:var(--red-ui-monospace-font);color:var(--red-ui-vcCommitShaColor);display:inline-block;font-size:.85em;margin-left:5px}.red-ui-sidebar-vc-commit-subject{color:var(--red-ui-primary-text-color)}.red-ui-sidebar-vc-commit-refs{min-height:22px}.red-ui-sidebar-vc-commit-ref{color:var(--red-ui-tertiary-text-color);font-size:.7em;border:1px solid var(--red-ui-tertiary-border-color);border-radius:10px;padding:2px 5px;margin-right:5px}.red-ui-sidebar-vc-commit-date{color:var(--red-ui-secondary-text-color);font-size:.85em}.red-ui-sidebar-vc-commit-user{float:right;color:var(--red-ui-secondary-text-color);font-size:.85em}.red-ui-sidebar-vc-change-header{color:var(--red-ui-primary-text-color);background:var(--red-ui-tertiary-background);padding:4px 10px;height:30px;box-sizing:border-box;border-top:1px solid var(--red-ui-secondary-border-color);border-bottom:1px solid var(--red-ui-secondary-border-color)}.red-ui-sidebar-vc-change-header i{transition:all .2s ease-in-out}.red-ui-sidebar-vc-repo-toolbar{color:var(--red-ui-primary-text-color);background:var(--red-ui-tertiary-background);padding:10px;box-sizing:border-box}.red-ui-sidebar-vc-repo-count{margin-right:8px;display:none}.red-ui-sidebar-vc-repo-action{text-align:left;width:100%}.red-ui-sidebar-vc-repo-sub-action{width:calc(50% - 5px);margin-right:5px}.red-ui-sidebar-vc-repo-sub-action:not(:first-child){margin-right:0;margin-left:5px}.red-ui-projects-file-listing-container>.red-ui-editableList>.red-ui-editableList-border{border-radius:0;border:none;border-top:1px solid var(--red-ui-secondary-border-color)}.red-ui-editableList-container .red-ui-projects-dialog-file-list .red-ui-editableList-border{border:none}.red-ui-editableList-container .red-ui-projects-dialog-file-list li{padding:0 !important;border:none}.red-ui-editableList-container .red-ui-projects-dialog-file-list .red-ui-editableList-container{padding:0}.red-ui-projects-dialog-file-list-entry{padding:3px 0;border-left:2px solid var(--red-ui-list-item-background);border-right:2px solid var(--red-ui-list-item-background);background:var(--red-ui-list-item-background)}.red-ui-projects-dialog-file-list-entry.projects-list-entry-current:not(.selectable){background:var(--red-ui-list-item-background-selected)}.red-ui-projects-dialog-file-list-entry.projects-list-entry-current i{color:var(--red-ui-secondary-text-color-selected)}.red-ui-projects-dialog-file-list-entry.selectable{cursor:pointer}.red-ui-projects-dialog-file-list-entry.selectable:hover{background:var(--red-ui-list-item-background-hover);border-left-color:var(--red-ui-list-item-border-selected);border-right-color:var(--red-ui-list-item-border-selected)}.red-ui-projects-dialog-file-list-entry.unselectable{color:var(--red-ui-secondary-text-color-disabled)}.red-ui-projects-dialog-file-list-entry i{color:var(--red-ui-secondary-text-color);width:16px;text-align:center}.red-ui-projects-dialog-file-list-entry.selected{background:var(--red-ui-list-item-background-selected);border-left-color:var(--red-ui-list-item-border-selected);border-right-color:var(--red-ui-list-item-border-selected)}.red-ui-projects-dialog-file-list-entry span{display:inline-block;vertical-align:middle}.red-ui-projects-dialog-file-list-entry .red-ui-projects-dialog-file-list-entry-folder{margin:0 10px 0 0px}.red-ui-projects-dialog-file-list-entry .red-ui-projects-dialog-file-list-entry-folder .fa-angle-right{color:var(--red-ui-primary-text-color);transition:all .2s ease-in-out}.red-ui-projects-dialog-file-list-entry .red-ui-projects-dialog-file-list-entry-file{margin:0 10px 0 20px}.red-ui-projects-dialog-file-list-entry .red-ui-projects-dialog-file-list-entry-name{font-size:1em}.red-ui-projects-dialog-file-list-entry.expanded .fa-angle-right{transform:rotate(90deg)}.red-ui-projects-dialog-file-list-entry-file-type-git{color:var(--red-ui-tertiary-text-color)}.red-ui-projects-dialog-remote-list .red-ui-editableList-container{padding:0}.red-ui-projects-dialog-remote-list .red-ui-editableList-container li{padding:0;border:none;border-radius:4px;overflow:hidden}div.red-ui-projects-dialog-ssh-public-key{position:relative;padding:15px 20px 0}div.red-ui-projects-dialog-ssh-public-key pre{position:relative;word-break:break-all}div.red-ui-projects-dialog-ssh-public-key:after{content:"";display:table;clear:both}.red-ui-projects-dialog-ssh-key-list li{padding:0 !important}.red-ui-projects-dialog-ssh-key-list .red-ui-projects-dialog-ssh-key-header{padding:10px 5px;cursor:pointer}.red-ui-projects-dialog-ssh-key-list .red-ui-projects-dialog-ssh-key-header:hover{background:var(--red-ui-list-item-background-hover)}.red-ui-projects-dialog-list{position:relative}.red-ui-projects-dialog-list .red-ui-editableList-container{padding:1px;background:var(--red-ui-tertiary-background)}.red-ui-projects-dialog-list .red-ui-editableList-container li:last-child{border-bottom:none}.red-ui-projects-dialog-list-entry.red-ui-search-empty{padding:0}.red-ui-projects-dialog-list-entry span{display:inline-block}.red-ui-projects-dialog-list-entry .entry-icon{text-align:center;min-width:30px;vertical-align:top;color:var(--red-ui-secondary-text-color)}.red-ui-projects-dialog-list-entry .entry-name{min-width:250px}.red-ui-projects-dialog-list-entry.current .entry-name{font-weight:bold}.red-ui-projects-dialog-list-entry .entry-detail{color:var(--red-ui-tertiary-text-color);font-size:.9em}.red-ui-projects-dialog-list-entry .entry-remote-name{min-width:250px}.red-ui-projects-dialog-list-entry .entry-tools{float:right;margin-right:10px}.red-ui-projects-dialog-list-dialog{position:relative;margin-top:10px;margin-bottom:20px;background:var(--red-ui-secondary-background);border-radius:4px;border:1px solid var(--red-ui-secondary-border-color)}.red-ui-projects-dialog-list-dialog .red-ui-projects-edit-form-sublabel{margin-top:-8px !important;margin-right:50px;display:block !important;width:auto !important}.red-ui-projects-dialog-list-dialog:after{content:"";display:table;clear:both}.red-ui-projects-dialog-list-dialog .red-ui-projects-dialog-list-dialog-header{font-weight:bold;background:var(--red-ui-primary-background);margin-top:0 !important;padding:5px 10px;margin-bottom:10px}#red-ui-settings-tab-gitconfig{padding:8px 20px 20px}.red-ui-settings-section-description{color:var(--red-ui-secondary-text-color)}.red-ui-editableList-border{border:1px solid var(--red-ui-form-input-border-color);border-radius:4px}.red-ui-editableList-border .red-ui-editableList-header{border-bottom:1px solid var(--red-ui-form-input-border-color);padding:2px 16px 2px 4px;font-size:.9em}.red-ui-editableList-container{padding:5px;margin:0;vertical-align:middle;box-sizing:border-box}.red-ui-editableList-container .red-ui-editableList-list{list-style-type:none;margin:0}.red-ui-editableList-container .red-ui-editabelList-item-placeholder{border:2px dashed var(--red-ui-secondary-border-color) !important}.red-ui-editableList-container li{box-sizing:border-box;position:relative;background:var(--red-ui-secondary-background);margin:0;padding:8px 0px;border-bottom:1px solid var(--red-ui-secondary-border-color);min-height:20px}.red-ui-editableList-container li .red-ui-editableList-item-handle{position:absolute;top:50%;left:2px;margin-top:-7px;color:var(--red-ui-tertiary-text-color);cursor:move}.red-ui-editableList-container li .red-ui-editableList-item-remove{position:absolute;top:50%;right:0px;margin-top:-9px}.red-ui-editableList-container li.ui-sortable-helper{border-top:1px solid var(--red-ui-secondary-border-color)}.red-ui-editableList-container li.red-ui-editableList-item-sortable .red-ui-editableList-item-content{margin-left:22px}.red-ui-editableList-container li.red-ui-editableList-item-removable .red-ui-editableList-item-content{margin-right:28px}.red-ui-editableList-container li.red-ui-editableList-item-deleting{background:var(--red-ui-secondary-background-inactive)}.red-ui-searchBox-container{position:relative}.red-ui-searchBox-container i{position:absolute;top:9px;font-size:10px;color:var(--red-ui-secondary-text-color)}.red-ui-searchBox-container i.fa-search{pointer-events:none;left:8px}.red-ui-searchBox-container i.fa-caret-down{position:absolute;right:6px;font-size:12px}.red-ui-searchBox-container i.fa-times{position:absolute;right:4px}.red-ui-searchBox-container form.red-ui-searchBox-form{margin:0}.red-ui-searchBox-container a.red-ui-searchBox-opts:hover{color:var(--red-ui-workspace-button-color-hover);background:var(--red-ui-workspace-button-background-hover)}.red-ui-searchBox-container input.red-ui-searchBox-input{border-radius:0;border:none;width:100%;box-shadow:none;-webkit-box-shadow:none;padding:3px 17px 3px 22px;margin:0px;height:30px;box-sizing:border-box}.red-ui-searchBox-container input.red-ui-searchBox-input:focus{border:none;box-shadow:none;-webkit-box-shadow:none}.red-ui-searchBox-container a{position:absolute;right:0;top:0;bottom:0;width:16px}.red-ui-searchBox-container a.red-ui-searchBox-clear{display:none}.red-ui-searchBox-container .red-ui-searchBox-resultCount{position:absolute;right:18px;top:4px;background:var(--red-ui-primary-background);color:var(--red-ui-secondary-text-color);padding:1px 8px;font-size:9px;border-radius:4px}.red-ui-searchBox-container.red-ui-searchBox-has-options a.red-ui-searchBox-clear{right:16px}.red-ui-searchBox-container.red-ui-searchBox-has-options .red-ui-searchBox-resultCount{right:33px}.red-ui-searchBox-container.red-ui-searchBox-has-options input.red-ui-searchBox-input{padding-right:33px}.red-ui-searchBox-compact input:focus.red-ui-searchBox-input{outline:1px solid var(--red-ui-form-input-focus-color)}.red-ui-searchBox-compact input.red-ui-searchBox-input,.red-ui-searchBox-compact input:focus.red-ui-searchBox-input{border:1px solid var(--red-ui-secondary-border-color);border-radius:3px;font-size:12px;height:26px}.red-ui-searchBox-compact i.fa-times,.red-ui-searchBox-compact i.fa-search,.red-ui-searchBox-compact i.fa-caret-down{top:7px}.red-ui-searchBox-compact .red-ui-searchBox-resultCount{top:3px;padding:0 6px}.red-ui-typedInput-container{border:1px solid var(--red-ui-form-input-border-color);border-radius:5px;height:34px;line-height:14px;display:inline-flex;padding:0;margin:0;vertical-align:middle;box-sizing:border-box;overflow:hidden;position:relative}.red-ui-typedInput-container[disabled] input,.red-ui-typedInput-container[disabled] button{background:var(--red-ui-secondary-background-inactive);pointer-events:none;cursor:not-allowed}.red-ui-typedInput-container .red-ui-typedInput-input-wrap{flex-grow:1}.red-ui-typedInput-container input.red-ui-typedInput-input{width:100%;padding:0 0 0 3px;margin:0;height:32px;border:none;border-top-left-radius:0;border-bottom-left-radius:0;box-shadow:none;vertical-align:middle}.red-ui-typedInput-container.red-ui-typedInput-focus:not(.input-error){border-color:var(--red-ui-form-input-focus-color) !important}.red-ui-typedInput-container .red-ui-typedInput-value-label{flex-grow:1;display:inline-block;height:32px;box-sizing:border-box;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.red-ui-typedInput-container .red-ui-typedInput-value-label .red-ui-typedInput-value-label-inactive{background:var(--red-ui-secondary-background-disabled);color:var(--red-ui-secondary-text-color-disabled)}.red-ui-typedInput-options{box-shadow:1px 1px 4px var(--red-ui-shadow);font-family:var(--red-ui-primary-font);font-size:var(--red-ui-primary-font-size);position:absolute;max-height:350px;overflow-y:auto;border:1px solid var(--red-ui-primary-border-color);box-sizing:border-box;background:var(--red-ui-secondary-background);white-space:nowrap;z-index:2000}.red-ui-typedInput-options a{padding:6px 18px 6px 6px;display:flex;align-items:center;border-bottom:1px solid var(--red-ui-secondary-border-color);color:var(--red-ui-form-text-color)}.red-ui-typedInput-options a:hover{text-decoration:none;background:var(--red-ui-workspace-button-background-hover)}.red-ui-typedInput-options a:focus{text-decoration:none;background:var(--red-ui-workspace-button-background-active);outline:none}.red-ui-typedInput-options a:active{text-decoration:none;background:var(--red-ui-workspace-button-background-active)}.red-ui-typedInput-options a input[type=checkbox]{margin:0 6px 0 0}.red-ui-typedInput-options .red-ui-typedInput-icon{margin-right:6px}.red-ui-typedInput-options .red-ui-typedInput-icon:not(.fa){-webkit-mask-size:cover;mask-size:cover;-webkit-mask-position:center;mask-position:center;-webkit-mask-repeat:no-repeat;mask-repeat:no-repeat;background-color:var(--red-ui-primary-text-color);height:14px;width:12px}button.red-ui-typedInput-type-select,button.red-ui-typedInput-option-expand,button.red-ui-typedInput-option-trigger{text-align:left;border:none;flex-basis:auto;box-sizing:border-box;border-top-left-radius:4px;border-bottom-left-radius:4px;padding:0 1px 0 5px;background:var(--red-ui-form-button-background);height:32px;line-height:30px;vertical-align:middle;color:var(--red-ui-form-text-color);white-space:nowrap}button.red-ui-typedInput-type-select i.red-ui-typedInput-icon,button.red-ui-typedInput-option-expand i.red-ui-typedInput-icon,button.red-ui-typedInput-option-trigger i.red-ui-typedInput-icon{margin-left:1px;margin-right:2px;vertical-align:middle}button.red-ui-typedInput-type-select.disabled,button.red-ui-typedInput-option-expand.disabled,button.red-ui-typedInput-option-trigger.disabled{cursor:default}button.red-ui-typedInput-type-select.disabled>i.red-ui-typedInput-icon,button.red-ui-typedInput-option-expand.disabled>i.red-ui-typedInput-icon,button.red-ui-typedInput-option-trigger.disabled>i.red-ui-typedInput-icon{color:var(--red-ui-secondary-text-color-disabled)}button.red-ui-typedInput-type-select .red-ui-typedInput-type-label,button.red-ui-typedInput-type-select .red-ui-typedInput-option-label,button.red-ui-typedInput-option-expand .red-ui-typedInput-type-label,button.red-ui-typedInput-option-expand .red-ui-typedInput-option-label,button.red-ui-typedInput-option-trigger .red-ui-typedInput-type-label,button.red-ui-typedInput-option-trigger .red-ui-typedInput-option-label{display:inline-block;vertical-align:middle;height:100%;padding:0 1px 0 5px}button.red-ui-typedInput-type-select .red-ui-typedInput-type-label img,button.red-ui-typedInput-type-select .red-ui-typedInput-option-label img,button.red-ui-typedInput-option-expand .red-ui-typedInput-type-label img,button.red-ui-typedInput-option-expand .red-ui-typedInput-option-label img,button.red-ui-typedInput-option-trigger .red-ui-typedInput-type-label img,button.red-ui-typedInput-option-trigger .red-ui-typedInput-option-label img{max-width:none}button.red-ui-typedInput-type-select .red-ui-typedInput-type-label .red-ui-typedInput-icon:not(.fa),button.red-ui-typedInput-type-select .red-ui-typedInput-option-label .red-ui-typedInput-icon:not(.fa),button.red-ui-typedInput-option-expand .red-ui-typedInput-type-label .red-ui-typedInput-icon:not(.fa),button.red-ui-typedInput-option-expand .red-ui-typedInput-option-label .red-ui-typedInput-icon:not(.fa),button.red-ui-typedInput-option-trigger .red-ui-typedInput-type-label .red-ui-typedInput-icon:not(.fa),button.red-ui-typedInput-option-trigger .red-ui-typedInput-option-label .red-ui-typedInput-icon:not(.fa){display:inline-block;-webkit-mask-size:cover;mask-size:cover;-webkit-mask-position:center;mask-position:center;-webkit-mask-repeat:no-repeat;mask-repeat:no-repeat;background-color:var(--red-ui-primary-text-color)}button.red-ui-typedInput-type-select:not(.disabled):hover,button.red-ui-typedInput-option-expand:not(.disabled):hover,button.red-ui-typedInput-option-trigger:not(.disabled):hover{text-decoration:none;background:var(--red-ui-workspace-button-background-hover)}button.red-ui-typedInput-type-select:focus,button.red-ui-typedInput-option-expand:focus,button.red-ui-typedInput-option-trigger:focus{text-decoration:none;outline:none;box-shadow:inset 0 0 0 1px var(--red-ui-form-input-focus-color)}button.red-ui-typedInput-type-select:not(.disabled):active,button.red-ui-typedInput-option-expand:not(.disabled):active,button.red-ui-typedInput-option-trigger:not(.disabled):active{background:var(--red-ui-workspace-button-background-active);text-decoration:none}button.red-ui-typedInput-type-select.red-ui-typedInput-full-width,button.red-ui-typedInput-option-expand.red-ui-typedInput-full-width,button.red-ui-typedInput-option-trigger.red-ui-typedInput-full-width{flex-grow:1;border-top-right-radius:4px;border-bottom-right-radius:4px}button.red-ui-typedInput-type-select:before,button.red-ui-typedInput-option-expand:before,button.red-ui-typedInput-option-trigger:before{content:"";display:inline-block;height:100%;vertical-align:middle}button.red-ui-typedInput-option-expand{border-top-right-radius:4px;border-bottom-right-radius:4px;border-top-left-radius:0;border-bottom-left-radius:0}button.red-ui-typedInput-option-trigger{border-top-left-radius:0px;border-bottom-left-radius:0px;border-top-right-radius:4px;border-bottom-right-radius:4px;padding:0 0 0 0;position:relative;flex-grow:1;line-height:32px;display:inline-flex}button.red-ui-typedInput-option-trigger .red-ui-typedInput-option-label{background:var(--red-ui-form-button-background);color:var(--red-ui-form-text-color);flex-grow:1;padding:0 0 0 8px;display:inline-block}button.red-ui-typedInput-option-trigger .red-ui-typedInput-option-caret{flex-grow:0;display:inline-block;width:23px;text-align:center;height:100%}button.red-ui-typedInput-option-trigger .red-ui-typedInput-option-caret:before{content:"";display:inline-block;height:100%;vertical-align:middle}button.red-ui-typedInput-option-trigger:focus{box-shadow:none}button.red-ui-typedInput-option-trigger:focus .red-ui-typedInput-option-caret{box-shadow:inset 0 0 0 1px var(--red-ui-form-input-focus-color)}.red-ui-nodeList .red-ui-editableList-container{padding:0}.red-ui-nodeList .red-ui-editableList-container li{padding:2px 5px;margin:0;white-space:nowrap;border:none;background:var(--red-ui-secondary-background)}.red-ui-nodeList .red-ui-editableList-container li:hover{background:var(--red-ui-secondary-background-hover)}.red-ui-nodeList .red-ui-editableList-container li i.fa-angle-right{text-align:center;width:15px;transition:transform .1s ease-in-out}.red-ui-nodeList .red-ui-editableList-container li .expandable{cursor:pointer}.red-ui-nodeList .red-ui-editableList-container li .expanded i.fa-angle-right{transform:rotate(90deg)}.red-ui-nodeList .red-ui-editableList-container li .meta{float:right}.red-ui-nodeList .red-ui-editableList-container li .meta input[type=checkbox].red-ui-treeList-checkbox{margin:0}.red-ui-nodeList .red-ui-editableList-container li .red-ui-editableList-item-content.disabled{color:var(--red-ui-secondary-text-color-disabled)}.red-ui-nodeList .red-ui-editableList-container li.red-ui-editableList-section-header{background:var(--red-ui-primary-background)}.red-ui-nodeList .red-ui-editableList-container li.red-ui-editableList-section-header .red-ui-editableList-item-content.disabled{color:var(--red-ui-secondary-text-color-disabled)}.red-ui-nodeList .red-ui-editableList-header{text-align:left}.red-ui-nodeList .red-ui-editableList-header>span:last-child{float:right;font-size:14px}.red-ui-checkboxSet{width:15px;display:inline-block;color:var(--red-ui-secondary-text-color);cursor:pointer}.red-ui-checkboxSet input{display:none !important}.red-ui-checkboxSet.disabled{pointer-events:none;color:var(--red-ui-secondary-text-color-disabled)}.red-ui-stack{background:var(--red-ui-secondary-background)}.red-ui-stack .red-ui-palette-category{background:var(--red-ui-secondary-background)}.red-ui-stack .red-ui-palette-category:last-child{border-bottom:none}.red-ui-treeList:focus{outline:none !important}.red-ui-treeList-container{width:100%;height:100%;position:relative;background:var(--red-ui-tertiary-background);border:1px solid var(--red-ui-form-input-border-color);border-radius:4px;box-sizing:border-box}.red-ui-treeList-container .red-ui-editableList-border{border:none}.red-ui-treeList-container .red-ui-editableList-container{padding:0px}.red-ui-treeList-container .red-ui-editableList-container li{padding:0;border-bottom:none}.red-ui-treeList-container .red-ui-editableList-item-content>.red-ui-treeList-label .fa-angle-right{transition:transform .1s ease-in-out}.red-ui-treeList-container .red-ui-editableList-item-content.expanded>.red-ui-treeList-label .fa-angle-right{transform:rotate(90deg)}.red-ui-treeList-label{-webkit-user-select:none;-khtml-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;padding:6px 0;display:flex;align-items:center;color:var(--red-ui-list-item-color);text-decoration:none;cursor:pointer;vertical-align:middle;margin:0;position:relative}.red-ui-treeList-label:hover,.red-ui-treeList-label:hover .red-ui-treeList-sublabel-text{background:var(--red-ui-list-item-background-hover);color:var(--red-ui-list-item-color);text-decoration:none}.red-ui-treeList-label:focus,.red-ui-treeList-label:focus .red-ui-treeList-sublabel-text{background:var(--red-ui-list-item-background-hover);outline:none;color:var(--red-ui-list-item-color);text-decoration:none}.red-ui-treeList-label.focus,.red-ui-treeList-label.focus .red-ui-treeList-sublabel-text{background:var(--red-ui-list-item-background-hover);outline:1px solid var(--red-ui-form-input-focus-color) !important;outline-offset:-1px;color:var(--red-ui-list-item-color)}.red-ui-treeList-label.selected,.red-ui-treeList-label.selected .red-ui-treeList-sublabel-text{background:var(--red-ui-list-item-background-selected);outline:none;color:var(--red-ui-list-item-color)}.red-ui-treeList-label input.red-ui-treeList-checkbox,.red-ui-treeList-label input.red-ui-treeList-radio{margin:0}.red-ui-treeList-label-text{margin-left:4px;overflow:hidden;text-overflow:ellipsis}.red-ui-treeList-label-text:empty{min-height:20px}.red-ui-treeList-sublabel-text{top:0;bottom:0;right:0;padding:0 10px 0 5px;line-height:32px;font-size:.9em;color:var(--red-ui-list-item-secondary-color);position:absolute;background:var(--red-ui-list-item-background)}.red-ui-treeList-icon{display:inline-block;flex-shrink:0;width:20px;text-align:center}.red-ui-treeList-spinner{height:32px;-webkit-mask-image:url(images/spin.svg);mask-image:url(images/spin.svg);-webkit-mask-size:auto 20px;mask-size:auto 20px;-webkit-mask-position:50% 50%;mask-position:50% 50%;-webkit-mask-repeat:no-repeat;mask-repeat:no-repeat;background-color:var(--red-ui-spinner-color)}.red-ui-autoComplete-container.red-ui-popover-panel{border-top:none}#red-ui-drop-target{position:absolute;top:0;bottom:0;left:0;right:0;background:var(--red-ui-dnd-background);display:table;width:100%;height:100%;display:none;z-index:100}#red-ui-drop-target div{pointer-events:none;display:table-cell;vertical-align:middle;text-align:center;font-size:40px;color:var(--red-ui-dnd-color)}#red-ui-drop-target div i{pointer-events:none;font-size:80px}#red-ui-settings-tab-keyboard .red-ui-editableList-container{border-radius:0;border:none;padding:0}#red-ui-settings-tab-keyboard .keyboard-shortcut-list-header{padding:0 5px 0 5px;border-bottom:1px solid var(--red-ui-primary-border-color)}#red-ui-settings-tab-keyboard .keyboard-shortcut-list-header div{color:var(--red-ui-header-text-color) !important}#red-ui-settings-tab-keyboard .keyboard-shortcut-list-header .red-ui-searchBox-container{width:calc(100% - 20px)}#red-ui-settings-tab-keyboard .keyboard-shortcut-list-header .keyboard-shortcut-entry-scope{text-align:center}#red-ui-settings-tab-keyboard .keyboard-shortcut-list{position:absolute;top:30px;left:10px;right:10px;bottom:10px}#red-ui-settings-tab-keyboard .keyboard-shortcut-list li{padding:0}#red-ui-settings-tab-keyboard .keyboard-shortcut-list li .red-ui-editableList-item-content{padding:8px;cursor:pointer}#red-ui-settings-tab-keyboard .keyboard-shortcut-list li:hover{background:var(--red-ui-list-item-background-hover)}#red-ui-settings-tab-keyboard .keyboard-shortcut-entry div{display:inline-block}#red-ui-settings-tab-keyboard .keyboard-shortcut-entry select{margin:0;width:calc(100% - 30px);font-size:.9em;margin-right:5px}#red-ui-settings-tab-keyboard .keyboard-shortcut-entry-key{width:160px;vertical-align:middle}#red-ui-settings-tab-keyboard .keyboard-shortcut-entry-key input{margin:0;width:calc(100% - 5px)}#red-ui-settings-tab-keyboard .keyboard-shortcut-entry-text{vertical-align:middle;width:calc(100% - 160px - 100px - 10px);overflow:hidden}#red-ui-settings-tab-keyboard .keyboard-shortcut-entry-text i{color:var(--red-ui-tertiary-text-color);margin-right:5px}#red-ui-settings-tab-keyboard .keyboard-shortcut-entry-scope{width:100px;color:var(--red-ui-tertiary-text-color);vertical-align:middle;text-align:right}#red-ui-settings-tab-keyboard .keyboard-shortcut-entry:not(.keyboard-shortcut-list-header) .keyboard-shortcut-entry-scope{font-size:.8em}#red-ui-settings-tab-keyboard .keyboard-shortcut-entry-unassigned{color:var(--red-ui-tertiary-text-color)}#red-ui-settings-tab-keyboard .keyboard-shortcut-entry-unassigned .keyboard-shortcut-entry-key{font-style:italic}#red-ui-settings-tab-keyboard .keyboard-shortcut-entry-expanded{background:var(--red-ui-list-item-background-selected)}#red-ui-settings-tab-keyboard .keyboard-shortcut-entry-expanded .keyboard-shortcut-entry-key{width:150px}#red-ui-settings-tab-keyboard .keyboard-shortcut-entry-expanded .keyboard-shortcut-entry-scope{width:110px}#red-ui-settings-tab-keyboard .keyboard-shortcut-entry-expanded span{display:none}.help-key{border:1px solid var(--red-ui-tertiary-border-color);padding:4px;border-radius:3px;background:var(--red-ui-tertiary-background);font-family:var(--red-ui-monospace-font);box-shadow:var(--red-ui-shade-color 1px 1px 1px)}.help-key-block{white-space:nowrap}.red-ui-debug-window{padding:0;margin:0;background:var(--red-ui-secondary-background);line-height:20px}.red-ui-debug-window .red-ui-debug-msg-payload{font-size:14px}.red-ui-debug-content{position:absolute;top:43px;bottom:0px;left:0px;right:0px;overflow-y:auto}.red-ui-debug-filter-box{position:absolute;top:42px;left:0px;right:0px;z-index:20;background:var(--red-ui-tertiary-background);padding:10px;border-bottom:1px solid var(--red-ui-secondary-border-color);box-shadow:0 2px 6px var(--red-ui-shadow)}#red-ui-sidebar-debug-filter-node-list-row .red-ui-treeList-label.disabled{font-style:italic;color:var(--red-ui-secondary-text-color-disabled)}#red-ui-sidebar-debug-filter-node-list-row .red-ui-treeList-label.selected,#red-ui-sidebar-debug-filter-node-list-row .red-ui-treeList-label.selected .red-ui-treeList-sublabel-text{background:inherit}#red-ui-sidebar-debug-filter-node-list-row .red-ui-treeList-label.selected,#red-ui-sidebar-debug-filter-node-list-row .red-ui-treeList-label.selected .red-ui-treeList-sublabel-text{background:inherit}#red-ui-sidebar-debug-filter-node-list-row .red-ui-treeList-label.focus,#red-ui-sidebar-debug-filter-node-list-row .red-ui-treeList-label.focus .red-ui-treeList-sublabel-text{background:var(--red-ui-list-item-background-hover) !important}.red-ui-debug-msg{position:relative;border-bottom:1px solid var(--red-ui-debug-message-border);border-left:8px solid var(--red-ui-debug-message-border);border-right:8px solid var(--red-ui-debug-message-border);padding:2px}.red-ui-debug-msg>.red-ui-debug-msg-meta .red-ui-debug-msg-tools{display:none}.red-ui-debug-msg.red-ui-debug-msg-hover{border-right-color:var(--red-ui-debug-message-border-hover)}.red-ui-debug-msg.red-ui-debug-msg-hover>.red-ui-debug-msg-meta .red-ui-debug-msg-tools{display:inline-block}.red-ui-debug-msg-row .red-ui-debug-msg-tools-pin{display:none}.red-ui-debug-msg-row.red-ui-debug-msg-row-pinned .red-ui-debug-msg-tools-pin{display:inline-block}.red-ui-debug-msg-row:hover{background:var(--red-ui-debug-message-background-hover)}.red-ui-debug-msg-row:hover>.red-ui-debug-msg-tools .red-ui-debug-msg-tools-copy{display:inline-block}.red-ui-debug-msg-row:hover>.red-ui-debug-msg-tools .red-ui-debug-msg-tools-pin{display:inline-block}.red-ui-debug-msg-row:hover>.red-ui-debug-msg-tools .red-ui-debug-msg-tools-other{display:inline-block}.red-ui-debug-msg-meta .red-ui-debug-msg-tools .red-ui-button-small{font-size:11px}.red-ui-debug-msg-tools .button-group:not(:last-child){margin-right:3px}.red-ui-debug-msg-tools .red-ui-button-small{height:16px;line-height:14px;font-size:8px;border-radius:1px;padding:0 3px;min-width:18px}.red-ui-debug-msg-meta{background:var(--red-ui-debug-message-background);font-size:11px;color:var(--red-ui-secondary-text-color-inactive);overflow-wrap:anywhere}.red-ui-debug-msg-date{padding:1px 10px 1px 0px;white-space:nowrap}.red-ui-debug-msg-topic{display:block;color:var(--red-ui-debug-message-text-color-meta)}.red-ui-debug-msg-name{padding:1px 0px;color:var(--red-ui-secondary-text-color-inactive);white-space:nowrap}.red-ui-debug-msg-tools{position:absolute;top:3px;right:1px}.red-ui-debug-msg-tools .red-ui-debug-msg-tools-copy{display:none}.red-ui-debug-msg-tools .red-ui-debug-msg-tools-other{display:none}.red-ui-debug-msg-payload{display:block;padding:2px;background:var(--red-ui-debug-message-background);font-family:var(--red-ui-monospace-font);font-size:13px !important}.red-ui-debug-msg-level-log{border-left-color:var(--red-ui-debug-message-border);border-right-color:var(--red-ui-debug-message-border)}.red-ui-debug-msg-level-30{border-left-color:var(--red-ui-debug-message-border-warning);border-right-color:var(--red-ui-debug-message-border-warning)}.red-ui-debug-msg-level-20{border-left-color:var(--red-ui-debug-message-border-error);border-right-color:var(--red-ui-debug-message-border-error)}.red-ui-debug-msg-object-entry{position:relative;padding-left:15px}.red-ui-debug-msg-element{color:var(--red-ui-debug-message-text-color);line-height:1.3em;overflow-wrap:break-word}.red-ui-debug-msg-object-key{color:var(--red-ui-debug-message-text-color-object-key)}.red-ui-debug-msg-object-handle{color:var(--red-ui-secondary-text-color);font-size:1em;width:1em;text-align:center;transition:transform .1s ease-in-out;transform:rotate(90deg)}.red-ui-debug-msg-element:not(.red-ui-debug-msg-top-level)>.red-ui-debug-msg-expandable>.red-ui-debug-msg-object-handle{margin-left:-1em}.red-ui-debug-msg-object-entry>.red-ui-debug-msg-expandable>.red-ui-debug-msg-object-handle{margin-left:-1em}.red-ui-debug-msg-object-entry.collapsed>span>.red-ui-debug-msg-object-handle{transform:rotate(0deg)}.red-ui-debug-msg-element.collapsed>span>.red-ui-debug-msg-object-handle{transform:rotate(0deg)}.red-ui-debug-msg-object-entry.collapsed>.red-ui-debug-msg-object-entry{display:none}.red-ui-debug-msg-element.collapsed .red-ui-debug-msg-object-entry{display:none}.red-ui-debug-msg-element:not(.collapsed)>.red-ui-debug-msg-expandable>.red-ui-debug-msg-object-value>.red-ui-debug-msg-object-header{display:none}.red-ui-debug-msg-element.collapsed .red-ui-debug-msg-buffer-opts{display:none}.red-ui-debug-msg-element.collapsed .red-ui-debug-msg-object-type-header{display:none}.red-ui-debug-msg-object-entry pre{font-family:var(--red-ui-monospace-font);font-size:13px;line-height:1.2em;margin:0 0 0 -1em}.red-ui-debug-msg-type-other{color:var(--red-ui-debug-message-text-color-msg-type-other)}.red-ui-debug-msg-type-string{color:var(--red-ui-debug-message-text-color-msg-type-string)}.red-ui-debug-msg-type-null{color:var(--red-ui-debug-message-text-color-msg-type-null);font-style:italic}.red-ui-debug-msg-type-meta{color:var(--red-ui-debug-message-text-color-msg-type-meta);font-style:italic}.red-ui-debug-msg-type-number{color:var(--red-ui-debug-message-text-color-msg-type-number)}.red-ui-debug-msg-type-number-toggle{cursor:pointer}.red-ui-debug-msg-type-string{white-space:pre-wrap}.red-ui-debug-msg-row{display:block;padding:4px 2px 2px;position:relative}.red-ui-debug-msg-row.red-ui-debug-msg-row-pinned{background:var(--red-ui-secondary-background-selected)}.red-ui-debug-msg-expandable{cursor:pointer}.red-ui-debug-msg-expandable:hover .red-ui-debug-msg-object-handle{color:var(--red-ui-secondary-text-color-hover)}.red-ui-debug-msg-buffer-opts{margin-left:5px}.red-ui-debug-msg-buffer-raw>.red-ui-debug-msg-string-rows{display:none}.red-ui-debug-msg-buffer-string>.red-ui-debug-msg-array-rows{display:none}.red-ui-debug-msg-type-string-swatch{display:inline-block;width:1.1em;height:.9em;vertical-align:middle;border-radius:3px;margin:0 4px}.red-ui-editor-radial-menu{font-size:var(--red-ui-primary-font-size);font-family:var(--red-ui-primary-font);position:absolute;top:0;left:0;bottom:0;right:0;z-index:1000}.red-ui-editor-radial-menu>div{position:absolute;border-radius:80px;width:160px;height:160px;background:var(--red-ui-shadow);border:1px solid var(--red-ui-primary-border-color)}.red-ui-editor-radial-menu-opt{position:absolute;border-radius:20px;width:50px;height:50px;background:var(--red-ui-secondary-background);border:2px solid var(--red-ui-primary-border-color);text-align:center;line-height:50px}.red-ui-editor-radial-menu-opt.selected{background:var(--red-ui-workspace-button-background-hover)}.red-ui-editor-radial-menu-opt-disabled{border-color:var(--red-ui-tertiary-border-color);color:var(--red-ui-tertiary-border-color)}.red-ui-editor-radial-menu-opt-active{background:var(--red-ui-secondary-background-hover)}.red-ui-tourGuide-shade{position:absolute;top:0;left:0;bottom:0;right:0;z-index:2000;overflow:hidden}.red-ui-tourGuide-shade-focus{display:block;width:100px;height:100px;position:absolute;z-index:2001;transform:translate(-50%, -50%);border-radius:50%;border:2px solid var(--red-ui-tourGuide-border)}.red-ui-tourGuide-shade-focus.transition{transition:.4s ease;transition-property:width,height}.red-ui-tourGuide-shade-focus::before{content:"";position:absolute;width:100%;height:100%;border-radius:50%;border:solid 6000px var(--red-ui-shade-color);margin-left:-6000px;margin-top:-6000px;pointer-events:none}.red-ui-popover.red-ui-tourGuide-popover{z-index:2003;--red-ui-popover-background: var(--red-ui-secondary-background);--red-ui-popover-border: var(--red-ui-tourGuide-border);--red-ui-popover-color: var(--red-ui-primary-text-color)}.red-ui-popover.red-ui-tourGuide-popover .red-ui-popover-content h2{text-align:center;margin-top:0px;line-height:1.2em;color:var(--red-ui-tourGuide-heading-color)}.red-ui-popover.red-ui-tourGuide-popover .red-ui-popover-content h2 i.fa{font-size:1.5em}.red-ui-tourGuide-toolbar{min-height:36px;position:relative;display:flex;align-items:flex-end}.red-ui-tourGuide-breadcrumbs{flex-grow:1;display:flex;align-items:center;justify-content:center;font-size:6px}.red-ui-tourGuide-breadcrumbs>div{display:inline-block}.red-ui-tourGuide-breadcrumbs i{line-height:16px;margin:0 3px}.red-ui-tourGuide-popover-description{padding:10px 20px 5px}.red-ui-tourGuide-popover-description img{max-height:150px;border:1px solid var(--red-ui-tourGuide-border);border-radius:2px}.red-ui-tourGuide-popover-full .red-ui-tourGuide-popover-description{padding:20px 40px 10px;text-align:center}.red-ui-popover.red-ui-tourGuide-popover button.red-ui-button:not(.primary){background:var(--red-ui-secondary-background);color:var(--red-ui-primary-text-color) !important}.red-ui-popover.red-ui-tourGuide-popover button.red-ui-button:not(.primary):not(.disabled):not(.ui-button-disabled):hover{border-color:var(--red-ui-popover-button-border-color-hover)} \ No newline at end of file diff --git a/software/dashboard/grafana/csv/Node-RED_files/tinycolor-min.js b/software/dashboard/grafana/csv/Node-RED_files/tinycolor-min.js new file mode 100644 index 0000000..64bf76d --- /dev/null +++ b/software/dashboard/grafana/csv/Node-RED_files/tinycolor-min.js @@ -0,0 +1,4 @@ +// TinyColor v1.4.2 +// https://github.com/bgrins/TinyColor +// 2020-09-25, Brian Grinstead, MIT License +!function(a){function b(a,d){if(a=a?a:"",d=d||{},a instanceof b)return a;if(!(this instanceof b))return new b(a,d);var e=c(a);this._originalInput=a,this._r=e.r,this._g=e.g,this._b=e.b,this._a=e.a,this._roundA=P(100*this._a)/100,this._format=d.format||e.format,this._gradientType=d.gradientType,this._r<1&&(this._r=P(this._r)),this._g<1&&(this._g=P(this._g)),this._b<1&&(this._b=P(this._b)),this._ok=e.ok,this._tc_id=O++}function c(a){var b={r:0,g:0,b:0},c=1,e=null,g=null,i=null,j=!1,k=!1;return"string"==typeof a&&(a=K(a)),"object"==typeof a&&(J(a.r)&&J(a.g)&&J(a.b)?(b=d(a.r,a.g,a.b),j=!0,k="%"===String(a.r).substr(-1)?"prgb":"rgb"):J(a.h)&&J(a.s)&&J(a.v)?(e=G(a.s),g=G(a.v),b=h(a.h,e,g),j=!0,k="hsv"):J(a.h)&&J(a.s)&&J(a.l)&&(e=G(a.s),i=G(a.l),b=f(a.h,e,i),j=!0,k="hsl"),a.hasOwnProperty("a")&&(c=a.a)),c=z(c),{ok:j,format:a.format||k,r:Q(255,R(b.r,0)),g:Q(255,R(b.g,0)),b:Q(255,R(b.b,0)),a:c}}function d(a,b,c){return{r:255*A(a,255),g:255*A(b,255),b:255*A(c,255)}}function e(a,b,c){a=A(a,255),b=A(b,255),c=A(c,255);var d,e,f=R(a,b,c),g=Q(a,b,c),h=(f+g)/2;if(f==g)d=e=0;else{var i=f-g;switch(e=h>.5?i/(2-f-g):i/(f+g),f){case a:d=(b-c)/i+(c>b?6:0);break;case b:d=(c-a)/i+2;break;case c:d=(a-b)/i+4}d/=6}return{h:d,s:e,l:h}}function f(a,b,c){function d(a,b,c){return 0>c&&(c+=1),c>1&&(c-=1),1/6>c?a+6*(b-a)*c:.5>c?b:2/3>c?a+(b-a)*(2/3-c)*6:a}var e,f,g;if(a=A(a,360),b=A(b,100),c=A(c,100),0===b)e=f=g=c;else{var h=.5>c?c*(1+b):c+b-c*b,i=2*c-h;e=d(i,h,a+1/3),f=d(i,h,a),g=d(i,h,a-1/3)}return{r:255*e,g:255*f,b:255*g}}function g(a,b,c){a=A(a,255),b=A(b,255),c=A(c,255);var d,e,f=R(a,b,c),g=Q(a,b,c),h=f,i=f-g;if(e=0===f?0:i/f,f==g)d=0;else{switch(f){case a:d=(b-c)/i+(c>b?6:0);break;case b:d=(c-a)/i+2;break;case c:d=(a-b)/i+4}d/=6}return{h:d,s:e,v:h}}function h(b,c,d){b=6*A(b,360),c=A(c,100),d=A(d,100);var e=a.floor(b),f=b-e,g=d*(1-c),h=d*(1-f*c),i=d*(1-(1-f)*c),j=e%6,k=[d,h,g,g,i,d][j],l=[i,d,d,h,g,g][j],m=[g,g,i,d,d,h][j];return{r:255*k,g:255*l,b:255*m}}function i(a,b,c,d){var e=[F(P(a).toString(16)),F(P(b).toString(16)),F(P(c).toString(16))];return d&&e[0].charAt(0)==e[0].charAt(1)&&e[1].charAt(0)==e[1].charAt(1)&&e[2].charAt(0)==e[2].charAt(1)?e[0].charAt(0)+e[1].charAt(0)+e[2].charAt(0):e.join("")}function j(a,b,c,d,e){var f=[F(P(a).toString(16)),F(P(b).toString(16)),F(P(c).toString(16)),F(H(d))];return e&&f[0].charAt(0)==f[0].charAt(1)&&f[1].charAt(0)==f[1].charAt(1)&&f[2].charAt(0)==f[2].charAt(1)&&f[3].charAt(0)==f[3].charAt(1)?f[0].charAt(0)+f[1].charAt(0)+f[2].charAt(0)+f[3].charAt(0):f.join("")}function k(a,b,c,d){var e=[F(H(d)),F(P(a).toString(16)),F(P(b).toString(16)),F(P(c).toString(16))];return e.join("")}function l(a,c){c=0===c?0:c||10;var d=b(a).toHsl();return d.s-=c/100,d.s=B(d.s),b(d)}function m(a,c){c=0===c?0:c||10;var d=b(a).toHsl();return d.s+=c/100,d.s=B(d.s),b(d)}function n(a){return b(a).desaturate(100)}function o(a,c){c=0===c?0:c||10;var d=b(a).toHsl();return d.l+=c/100,d.l=B(d.l),b(d)}function p(a,c){c=0===c?0:c||10;var d=b(a).toRgb();return d.r=R(0,Q(255,d.r-P(255*-(c/100)))),d.g=R(0,Q(255,d.g-P(255*-(c/100)))),d.b=R(0,Q(255,d.b-P(255*-(c/100)))),b(d)}function q(a,c){c=0===c?0:c||10;var d=b(a).toHsl();return d.l-=c/100,d.l=B(d.l),b(d)}function r(a,c){var d=b(a).toHsl(),e=(d.h+c)%360;return d.h=0>e?360+e:e,b(d)}function s(a){var c=b(a).toHsl();return c.h=(c.h+180)%360,b(c)}function t(a){var c=b(a).toHsl(),d=c.h;return[b(a),b({h:(d+120)%360,s:c.s,l:c.l}),b({h:(d+240)%360,s:c.s,l:c.l})]}function u(a){var c=b(a).toHsl(),d=c.h;return[b(a),b({h:(d+90)%360,s:c.s,l:c.l}),b({h:(d+180)%360,s:c.s,l:c.l}),b({h:(d+270)%360,s:c.s,l:c.l})]}function v(a){var c=b(a).toHsl(),d=c.h;return[b(a),b({h:(d+72)%360,s:c.s,l:c.l}),b({h:(d+216)%360,s:c.s,l:c.l})]}function w(a,c,d){c=c||6,d=d||30;var e=b(a).toHsl(),f=360/d,g=[b(a)];for(e.h=(e.h-(f*c>>1)+720)%360;--c;)e.h=(e.h+f)%360,g.push(b(e));return g}function x(a,c){c=c||6;for(var d=b(a).toHsv(),e=d.h,f=d.s,g=d.v,h=[],i=1/c;c--;)h.push(b({h:e,s:f,v:g})),g=(g+i)%1;return h}function y(a){var b={};for(var c in a)a.hasOwnProperty(c)&&(b[a[c]]=c);return b}function z(a){return a=parseFloat(a),(isNaN(a)||0>a||a>1)&&(a=1),a}function A(b,c){D(b)&&(b="100%");var d=E(b);return b=Q(c,R(0,parseFloat(b))),d&&(b=parseInt(b*c,10)/100),a.abs(b-c)<1e-6?1:b%c/parseFloat(c)}function B(a){return Q(1,R(0,a))}function C(a){return parseInt(a,16)}function D(a){return"string"==typeof a&&-1!=a.indexOf(".")&&1===parseFloat(a)}function E(a){return"string"==typeof a&&-1!=a.indexOf("%")}function F(a){return 1==a.length?"0"+a:""+a}function G(a){return 1>=a&&(a=100*a+"%"),a}function H(b){return a.round(255*parseFloat(b)).toString(16)}function I(a){return C(a)/255}function J(a){return!!V.CSS_UNIT.exec(a)}function K(a){a=a.replace(M,"").replace(N,"").toLowerCase();var b=!1;if(T[a])a=T[a],b=!0;else if("transparent"==a)return{r:0,g:0,b:0,a:0,format:"name"};var c;return(c=V.rgb.exec(a))?{r:c[1],g:c[2],b:c[3]}:(c=V.rgba.exec(a))?{r:c[1],g:c[2],b:c[3],a:c[4]}:(c=V.hsl.exec(a))?{h:c[1],s:c[2],l:c[3]}:(c=V.hsla.exec(a))?{h:c[1],s:c[2],l:c[3],a:c[4]}:(c=V.hsv.exec(a))?{h:c[1],s:c[2],v:c[3]}:(c=V.hsva.exec(a))?{h:c[1],s:c[2],v:c[3],a:c[4]}:(c=V.hex8.exec(a))?{r:C(c[1]),g:C(c[2]),b:C(c[3]),a:I(c[4]),format:b?"name":"hex8"}:(c=V.hex6.exec(a))?{r:C(c[1]),g:C(c[2]),b:C(c[3]),format:b?"name":"hex"}:(c=V.hex4.exec(a))?{r:C(c[1]+""+c[1]),g:C(c[2]+""+c[2]),b:C(c[3]+""+c[3]),a:I(c[4]+""+c[4]),format:b?"name":"hex8"}:(c=V.hex3.exec(a))?{r:C(c[1]+""+c[1]),g:C(c[2]+""+c[2]),b:C(c[3]+""+c[3]),format:b?"name":"hex"}:!1}function L(a){var b,c;return a=a||{level:"AA",size:"small"},b=(a.level||"AA").toUpperCase(),c=(a.size||"small").toLowerCase(),"AA"!==b&&"AAA"!==b&&(b="AA"),"small"!==c&&"large"!==c&&(c="small"),{level:b,size:c}}var M=/^\s+/,N=/\s+$/,O=0,P=a.round,Q=a.min,R=a.max,S=a.random;b.prototype={isDark:function(){return this.getBrightness()<128},isLight:function(){return!this.isDark()},isValid:function(){return this._ok},getOriginalInput:function(){return this._originalInput},getFormat:function(){return this._format},getAlpha:function(){return this._a},getBrightness:function(){var a=this.toRgb();return(299*a.r+587*a.g+114*a.b)/1e3},getLuminance:function(){var b,c,d,e,f,g,h=this.toRgb();return b=h.r/255,c=h.g/255,d=h.b/255,e=.03928>=b?b/12.92:a.pow((b+.055)/1.055,2.4),f=.03928>=c?c/12.92:a.pow((c+.055)/1.055,2.4),g=.03928>=d?d/12.92:a.pow((d+.055)/1.055,2.4),.2126*e+.7152*f+.0722*g},setAlpha:function(a){return this._a=z(a),this._roundA=P(100*this._a)/100,this},toHsv:function(){var a=g(this._r,this._g,this._b);return{h:360*a.h,s:a.s,v:a.v,a:this._a}},toHsvString:function(){var a=g(this._r,this._g,this._b),b=P(360*a.h),c=P(100*a.s),d=P(100*a.v);return 1==this._a?"hsv("+b+", "+c+"%, "+d+"%)":"hsva("+b+", "+c+"%, "+d+"%, "+this._roundA+")"},toHsl:function(){var a=e(this._r,this._g,this._b);return{h:360*a.h,s:a.s,l:a.l,a:this._a}},toHslString:function(){var a=e(this._r,this._g,this._b),b=P(360*a.h),c=P(100*a.s),d=P(100*a.l);return 1==this._a?"hsl("+b+", "+c+"%, "+d+"%)":"hsla("+b+", "+c+"%, "+d+"%, "+this._roundA+")"},toHex:function(a){return i(this._r,this._g,this._b,a)},toHexString:function(a){return"#"+this.toHex(a)},toHex8:function(a){return j(this._r,this._g,this._b,this._a,a)},toHex8String:function(a){return"#"+this.toHex8(a)},toRgb:function(){return{r:P(this._r),g:P(this._g),b:P(this._b),a:this._a}},toRgbString:function(){return 1==this._a?"rgb("+P(this._r)+", "+P(this._g)+", "+P(this._b)+")":"rgba("+P(this._r)+", "+P(this._g)+", "+P(this._b)+", "+this._roundA+")"},toPercentageRgb:function(){return{r:P(100*A(this._r,255))+"%",g:P(100*A(this._g,255))+"%",b:P(100*A(this._b,255))+"%",a:this._a}},toPercentageRgbString:function(){return 1==this._a?"rgb("+P(100*A(this._r,255))+"%, "+P(100*A(this._g,255))+"%, "+P(100*A(this._b,255))+"%)":"rgba("+P(100*A(this._r,255))+"%, "+P(100*A(this._g,255))+"%, "+P(100*A(this._b,255))+"%, "+this._roundA+")"},toName:function(){return 0===this._a?"transparent":this._a<1?!1:U[i(this._r,this._g,this._b,!0)]||!1},toFilter:function(a){var c="#"+k(this._r,this._g,this._b,this._a),d=c,e=this._gradientType?"GradientType = 1, ":"";if(a){var f=b(a);d="#"+k(f._r,f._g,f._b,f._a)}return"progid:DXImageTransform.Microsoft.gradient("+e+"startColorstr="+c+",endColorstr="+d+")"},toString:function(a){var b=!!a;a=a||this._format;var c=!1,d=this._a<1&&this._a>=0,e=!b&&d&&("hex"===a||"hex6"===a||"hex3"===a||"hex4"===a||"hex8"===a||"name"===a);return e?"name"===a&&0===this._a?this.toName():this.toRgbString():("rgb"===a&&(c=this.toRgbString()),"prgb"===a&&(c=this.toPercentageRgbString()),("hex"===a||"hex6"===a)&&(c=this.toHexString()),"hex3"===a&&(c=this.toHexString(!0)),"hex4"===a&&(c=this.toHex8String(!0)),"hex8"===a&&(c=this.toHex8String()),"name"===a&&(c=this.toName()),"hsl"===a&&(c=this.toHslString()),"hsv"===a&&(c=this.toHsvString()),c||this.toHexString())},clone:function(){return b(this.toString())},_applyModification:function(a,b){var c=a.apply(null,[this].concat([].slice.call(b)));return this._r=c._r,this._g=c._g,this._b=c._b,this.setAlpha(c._a),this},lighten:function(){return this._applyModification(o,arguments)},brighten:function(){return this._applyModification(p,arguments)},darken:function(){return this._applyModification(q,arguments)},desaturate:function(){return this._applyModification(l,arguments)},saturate:function(){return this._applyModification(m,arguments)},greyscale:function(){return this._applyModification(n,arguments)},spin:function(){return this._applyModification(r,arguments)},_applyCombination:function(a,b){return a.apply(null,[this].concat([].slice.call(b)))},analogous:function(){return this._applyCombination(w,arguments)},complement:function(){return this._applyCombination(s,arguments)},monochromatic:function(){return this._applyCombination(x,arguments)},splitcomplement:function(){return this._applyCombination(v,arguments)},triad:function(){return this._applyCombination(t,arguments)},tetrad:function(){return this._applyCombination(u,arguments)}},b.fromRatio=function(a,c){if("object"==typeof a){var d={};for(var e in a)a.hasOwnProperty(e)&&("a"===e?d[e]=a[e]:d[e]=G(a[e]));a=d}return b(a,c)},b.equals=function(a,c){return a&&c?b(a).toRgbString()==b(c).toRgbString():!1},b.random=function(){return b.fromRatio({r:S(),g:S(),b:S()})},b.mix=function(a,c,d){d=0===d?0:d||50;var e=b(a).toRgb(),f=b(c).toRgb(),g=d/100,h={r:(f.r-e.r)*g+e.r,g:(f.g-e.g)*g+e.g,b:(f.b-e.b)*g+e.b,a:(f.a-e.a)*g+e.a};return b(h)},b.readability=function(c,d){var e=b(c),f=b(d);return(a.max(e.getLuminance(),f.getLuminance())+.05)/(a.min(e.getLuminance(),f.getLuminance())+.05)},b.isReadable=function(a,c,d){var e,f,g=b.readability(a,c);switch(f=!1,e=L(d),e.level+e.size){case"AAsmall":case"AAAlarge":f=g>=4.5;break;case"AAlarge":f=g>=3;break;case"AAAsmall":f=g>=7}return f},b.mostReadable=function(a,c,d){var e,f,g,h,i=null,j=0;d=d||{},f=d.includeFallbackColors,g=d.level,h=d.size;for(var k=0;k<c.length;k++)e=b.readability(a,c[k]),e>j&&(j=e,i=b(c[k]));return b.isReadable(a,i,{level:g,size:h})||!f?i:(d.includeFallbackColors=!1,b.mostReadable(a,["#fff","#000"],d))};var T=b.names={aliceblue:"f0f8ff",antiquewhite:"faebd7",aqua:"0ff",aquamarine:"7fffd4",azure:"f0ffff",beige:"f5f5dc",bisque:"ffe4c4",black:"000",blanchedalmond:"ffebcd",blue:"00f",blueviolet:"8a2be2",brown:"a52a2a",burlywood:"deb887",burntsienna:"ea7e5d",cadetblue:"5f9ea0",chartreuse:"7fff00",chocolate:"d2691e",coral:"ff7f50",cornflowerblue:"6495ed",cornsilk:"fff8dc",crimson:"dc143c",cyan:"0ff",darkblue:"00008b",darkcyan:"008b8b",darkgoldenrod:"b8860b",darkgray:"a9a9a9",darkgreen:"006400",darkgrey:"a9a9a9",darkkhaki:"bdb76b",darkmagenta:"8b008b",darkolivegreen:"556b2f",darkorange:"ff8c00",darkorchid:"9932cc",darkred:"8b0000",darksalmon:"e9967a",darkseagreen:"8fbc8f",darkslateblue:"483d8b",darkslategray:"2f4f4f",darkslategrey:"2f4f4f",darkturquoise:"00ced1",darkviolet:"9400d3",deeppink:"ff1493",deepskyblue:"00bfff",dimgray:"696969",dimgrey:"696969",dodgerblue:"1e90ff",firebrick:"b22222",floralwhite:"fffaf0",forestgreen:"228b22",fuchsia:"f0f",gainsboro:"dcdcdc",ghostwhite:"f8f8ff",gold:"ffd700",goldenrod:"daa520",gray:"808080",green:"008000",greenyellow:"adff2f",grey:"808080",honeydew:"f0fff0",hotpink:"ff69b4",indianred:"cd5c5c",indigo:"4b0082",ivory:"fffff0",khaki:"f0e68c",lavender:"e6e6fa",lavenderblush:"fff0f5",lawngreen:"7cfc00",lemonchiffon:"fffacd",lightblue:"add8e6",lightcoral:"f08080",lightcyan:"e0ffff",lightgoldenrodyellow:"fafad2",lightgray:"d3d3d3",lightgreen:"90ee90",lightgrey:"d3d3d3",lightpink:"ffb6c1",lightsalmon:"ffa07a",lightseagreen:"20b2aa",lightskyblue:"87cefa",lightslategray:"789",lightslategrey:"789",lightsteelblue:"b0c4de",lightyellow:"ffffe0",lime:"0f0",limegreen:"32cd32",linen:"faf0e6",magenta:"f0f",maroon:"800000",mediumaquamarine:"66cdaa",mediumblue:"0000cd",mediumorchid:"ba55d3",mediumpurple:"9370db",mediumseagreen:"3cb371",mediumslateblue:"7b68ee",mediumspringgreen:"00fa9a",mediumturquoise:"48d1cc",mediumvioletred:"c71585",midnightblue:"191970",mintcream:"f5fffa",mistyrose:"ffe4e1",moccasin:"ffe4b5",navajowhite:"ffdead",navy:"000080",oldlace:"fdf5e6",olive:"808000",olivedrab:"6b8e23",orange:"ffa500",orangered:"ff4500",orchid:"da70d6",palegoldenrod:"eee8aa",palegreen:"98fb98",paleturquoise:"afeeee",palevioletred:"db7093",papayawhip:"ffefd5",peachpuff:"ffdab9",peru:"cd853f",pink:"ffc0cb",plum:"dda0dd",powderblue:"b0e0e6",purple:"800080",rebeccapurple:"663399",red:"f00",rosybrown:"bc8f8f",royalblue:"4169e1",saddlebrown:"8b4513",salmon:"fa8072",sandybrown:"f4a460",seagreen:"2e8b57",seashell:"fff5ee",sienna:"a0522d",silver:"c0c0c0",skyblue:"87ceeb",slateblue:"6a5acd",slategray:"708090",slategrey:"708090",snow:"fffafa",springgreen:"00ff7f",steelblue:"4682b4",tan:"d2b48c",teal:"008080",thistle:"d8bfd8",tomato:"ff6347",turquoise:"40e0d0",violet:"ee82ee",wheat:"f5deb3",white:"fff",whitesmoke:"f5f5f5",yellow:"ff0",yellowgreen:"9acd32"},U=b.hexNames=y(T),V=function(){var a="[-\\+]?\\d+%?",b="[-\\+]?\\d*\\.\\d+%?",c="(?:"+b+")|(?:"+a+")",d="[\\s|\\(]+("+c+")[,|\\s]+("+c+")[,|\\s]+("+c+")\\s*\\)?",e="[\\s|\\(]+("+c+")[,|\\s]+("+c+")[,|\\s]+("+c+")[,|\\s]+("+c+")\\s*\\)?";return{CSS_UNIT:new RegExp(c),rgb:new RegExp("rgb"+d),rgba:new RegExp("rgba"+e),hsl:new RegExp("hsl"+d),hsla:new RegExp("hsla"+e),hsv:new RegExp("hsv"+d),hsva:new RegExp("hsva"+e),hex3:/^#?([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})$/,hex6:/^#?([0-9a-fA-F]{2})([0-9a-fA-F]{2})([0-9a-fA-F]{2})$/,hex4:/^#?([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})$/,hex8:/^#?([0-9a-fA-F]{2})([0-9a-fA-F]{2})([0-9a-fA-F]{2})([0-9a-fA-F]{2})$/}}();"undefined"!=typeof module&&module.exports?module.exports=b:"function"==typeof define&&define.amd?define(function(){return b}):window.tinycolor=b}(Math); diff --git a/software/dashboard/grafana/csv/Node-RED_files/vendor.js b/software/dashboard/grafana/csv/Node-RED_files/vendor.js new file mode 100644 index 0000000..1a9f4f7 --- /dev/null +++ b/software/dashboard/grafana/csv/Node-RED_files/vendor.js @@ -0,0 +1,298 @@ +/*! jQuery v3.5.1 | (c) JS Foundation and other contributors | jquery.org/license */ +!function(e,t){"use strict";"object"==typeof module&&"object"==typeof module.exports?module.exports=e.document?t(e,!0):function(e){if(!e.document)throw new Error("jQuery requires a window with a document");return t(e)}:t(e)}("undefined"!=typeof window?window:this,function(C,e){"use strict";var t=[],r=Object.getPrototypeOf,s=t.slice,g=t.flat?function(e){return t.flat.call(e)}:function(e){return t.concat.apply([],e)},u=t.push,i=t.indexOf,n={},o=n.toString,v=n.hasOwnProperty,a=v.toString,l=a.call(Object),y={},m=function(e){return"function"==typeof e&&"number"!=typeof e.nodeType},x=function(e){return null!=e&&e===e.window},E=C.document,c={type:!0,src:!0,nonce:!0,noModule:!0};function b(e,t,n){var r,i,o=(n=n||E).createElement("script");if(o.text=e,t)for(r in c)(i=t[r]||t.getAttribute&&t.getAttribute(r))&&o.setAttribute(r,i);n.head.appendChild(o).parentNode.removeChild(o)}function w(e){return null==e?e+"":"object"==typeof e||"function"==typeof e?n[o.call(e)]||"object":typeof e}var f="3.5.1",S=function(e,t){return new S.fn.init(e,t)};function p(e){var t=!!e&&"length"in e&&e.length,n=w(e);return!m(e)&&!x(e)&&("array"===n||0===t||"number"==typeof t&&0<t&&t-1 in e)}S.fn=S.prototype={jquery:f,constructor:S,length:0,toArray:function(){return s.call(this)},get:function(e){return null==e?s.call(this):e<0?this[e+this.length]:this[e]},pushStack:function(e){var t=S.merge(this.constructor(),e);return t.prevObject=this,t},each:function(e){return S.each(this,e)},map:function(n){return this.pushStack(S.map(this,function(e,t){return n.call(e,t,e)}))},slice:function(){return this.pushStack(s.apply(this,arguments))},first:function(){return this.eq(0)},last:function(){return this.eq(-1)},even:function(){return this.pushStack(S.grep(this,function(e,t){return(t+1)%2}))},odd:function(){return this.pushStack(S.grep(this,function(e,t){return t%2}))},eq:function(e){var t=this.length,n=+e+(e<0?t:0);return this.pushStack(0<=n&&n<t?[this[n]]:[])},end:function(){return this.prevObject||this.constructor()},push:u,sort:t.sort,splice:t.splice},S.extend=S.fn.extend=function(){var e,t,n,r,i,o,a=arguments[0]||{},s=1,u=arguments.length,l=!1;for("boolean"==typeof a&&(l=a,a=arguments[s]||{},s++),"object"==typeof a||m(a)||(a={}),s===u&&(a=this,s--);s<u;s++)if(null!=(e=arguments[s]))for(t in e)r=e[t],"__proto__"!==t&&a!==r&&(l&&r&&(S.isPlainObject(r)||(i=Array.isArray(r)))?(n=a[t],o=i&&!Array.isArray(n)?[]:i||S.isPlainObject(n)?n:{},i=!1,a[t]=S.extend(l,o,r)):void 0!==r&&(a[t]=r));return a},S.extend({expando:"jQuery"+(f+Math.random()).replace(/\D/g,""),isReady:!0,error:function(e){throw new Error(e)},noop:function(){},isPlainObject:function(e){var t,n;return!(!e||"[object Object]"!==o.call(e))&&(!(t=r(e))||"function"==typeof(n=v.call(t,"constructor")&&t.constructor)&&a.call(n)===l)},isEmptyObject:function(e){var t;for(t in e)return!1;return!0},globalEval:function(e,t,n){b(e,{nonce:t&&t.nonce},n)},each:function(e,t){var n,r=0;if(p(e)){for(n=e.length;r<n;r++)if(!1===t.call(e[r],r,e[r]))break}else for(r in e)if(!1===t.call(e[r],r,e[r]))break;return e},makeArray:function(e,t){var n=t||[];return null!=e&&(p(Object(e))?S.merge(n,"string"==typeof e?[e]:e):u.call(n,e)),n},inArray:function(e,t,n){return null==t?-1:i.call(t,e,n)},merge:function(e,t){for(var n=+t.length,r=0,i=e.length;r<n;r++)e[i++]=t[r];return e.length=i,e},grep:function(e,t,n){for(var r=[],i=0,o=e.length,a=!n;i<o;i++)!t(e[i],i)!==a&&r.push(e[i]);return r},map:function(e,t,n){var r,i,o=0,a=[];if(p(e))for(r=e.length;o<r;o++)null!=(i=t(e[o],o,n))&&a.push(i);else for(o in e)null!=(i=t(e[o],o,n))&&a.push(i);return g(a)},guid:1,support:y}),"function"==typeof Symbol&&(S.fn[Symbol.iterator]=t[Symbol.iterator]),S.each("Boolean Number String Function Array Date RegExp Object Error Symbol".split(" "),function(e,t){n["[object "+t+"]"]=t.toLowerCase()});var d=function(n){var e,d,b,o,i,h,f,g,w,u,l,T,C,a,E,v,s,c,y,S="sizzle"+1*new Date,p=n.document,k=0,r=0,m=ue(),x=ue(),A=ue(),N=ue(),D=function(e,t){return e===t&&(l=!0),0},j={}.hasOwnProperty,t=[],q=t.pop,L=t.push,H=t.push,O=t.slice,P=function(e,t){for(var n=0,r=e.length;n<r;n++)if(e[n]===t)return n;return-1},R="checked|selected|async|autofocus|autoplay|controls|defer|disabled|hidden|ismap|loop|multiple|open|readonly|required|scoped",M="[\\x20\\t\\r\\n\\f]",I="(?:\\\\[\\da-fA-F]{1,6}"+M+"?|\\\\[^\\r\\n\\f]|[\\w-]|[^\0-\\x7f])+",W="\\["+M+"*("+I+")(?:"+M+"*([*^$|!~]?=)"+M+"*(?:'((?:\\\\.|[^\\\\'])*)'|\"((?:\\\\.|[^\\\\\"])*)\"|("+I+"))|)"+M+"*\\]",F=":("+I+")(?:\\((('((?:\\\\.|[^\\\\'])*)'|\"((?:\\\\.|[^\\\\\"])*)\")|((?:\\\\.|[^\\\\()[\\]]|"+W+")*)|.*)\\)|)",B=new RegExp(M+"+","g"),$=new RegExp("^"+M+"+|((?:^|[^\\\\])(?:\\\\.)*)"+M+"+$","g"),_=new RegExp("^"+M+"*,"+M+"*"),z=new RegExp("^"+M+"*([>+~]|"+M+")"+M+"*"),U=new RegExp(M+"|>"),X=new RegExp(F),V=new RegExp("^"+I+"$"),G={ID:new RegExp("^#("+I+")"),CLASS:new RegExp("^\\.("+I+")"),TAG:new RegExp("^("+I+"|[*])"),ATTR:new RegExp("^"+W),PSEUDO:new RegExp("^"+F),CHILD:new RegExp("^:(only|first|last|nth|nth-last)-(child|of-type)(?:\\("+M+"*(even|odd|(([+-]|)(\\d*)n|)"+M+"*(?:([+-]|)"+M+"*(\\d+)|))"+M+"*\\)|)","i"),bool:new RegExp("^(?:"+R+")$","i"),needsContext:new RegExp("^"+M+"*[>+~]|:(even|odd|eq|gt|lt|nth|first|last)(?:\\("+M+"*((?:-\\d)?\\d*)"+M+"*\\)|)(?=[^-]|$)","i")},Y=/HTML$/i,Q=/^(?:input|select|textarea|button)$/i,J=/^h\d$/i,K=/^[^{]+\{\s*\[native \w/,Z=/^(?:#([\w-]+)|(\w+)|\.([\w-]+))$/,ee=/[+~]/,te=new RegExp("\\\\[\\da-fA-F]{1,6}"+M+"?|\\\\([^\\r\\n\\f])","g"),ne=function(e,t){var n="0x"+e.slice(1)-65536;return t||(n<0?String.fromCharCode(n+65536):String.fromCharCode(n>>10|55296,1023&n|56320))},re=/([\0-\x1f\x7f]|^-?\d)|^-$|[^\0-\x1f\x7f-\uFFFF\w-]/g,ie=function(e,t){return t?"\0"===e?"\ufffd":e.slice(0,-1)+"\\"+e.charCodeAt(e.length-1).toString(16)+" ":"\\"+e},oe=function(){T()},ae=be(function(e){return!0===e.disabled&&"fieldset"===e.nodeName.toLowerCase()},{dir:"parentNode",next:"legend"});try{H.apply(t=O.call(p.childNodes),p.childNodes),t[p.childNodes.length].nodeType}catch(e){H={apply:t.length?function(e,t){L.apply(e,O.call(t))}:function(e,t){var n=e.length,r=0;while(e[n++]=t[r++]);e.length=n-1}}}function se(t,e,n,r){var i,o,a,s,u,l,c,f=e&&e.ownerDocument,p=e?e.nodeType:9;if(n=n||[],"string"!=typeof t||!t||1!==p&&9!==p&&11!==p)return n;if(!r&&(T(e),e=e||C,E)){if(11!==p&&(u=Z.exec(t)))if(i=u[1]){if(9===p){if(!(a=e.getElementById(i)))return n;if(a.id===i)return n.push(a),n}else if(f&&(a=f.getElementById(i))&&y(e,a)&&a.id===i)return n.push(a),n}else{if(u[2])return H.apply(n,e.getElementsByTagName(t)),n;if((i=u[3])&&d.getElementsByClassName&&e.getElementsByClassName)return H.apply(n,e.getElementsByClassName(i)),n}if(d.qsa&&!N[t+" "]&&(!v||!v.test(t))&&(1!==p||"object"!==e.nodeName.toLowerCase())){if(c=t,f=e,1===p&&(U.test(t)||z.test(t))){(f=ee.test(t)&&ye(e.parentNode)||e)===e&&d.scope||((s=e.getAttribute("id"))?s=s.replace(re,ie):e.setAttribute("id",s=S)),o=(l=h(t)).length;while(o--)l[o]=(s?"#"+s:":scope")+" "+xe(l[o]);c=l.join(",")}try{return H.apply(n,f.querySelectorAll(c)),n}catch(e){N(t,!0)}finally{s===S&&e.removeAttribute("id")}}}return g(t.replace($,"$1"),e,n,r)}function ue(){var r=[];return function e(t,n){return r.push(t+" ")>b.cacheLength&&delete e[r.shift()],e[t+" "]=n}}function le(e){return e[S]=!0,e}function ce(e){var t=C.createElement("fieldset");try{return!!e(t)}catch(e){return!1}finally{t.parentNode&&t.parentNode.removeChild(t),t=null}}function fe(e,t){var n=e.split("|"),r=n.length;while(r--)b.attrHandle[n[r]]=t}function pe(e,t){var n=t&&e,r=n&&1===e.nodeType&&1===t.nodeType&&e.sourceIndex-t.sourceIndex;if(r)return r;if(n)while(n=n.nextSibling)if(n===t)return-1;return e?1:-1}function de(t){return function(e){return"input"===e.nodeName.toLowerCase()&&e.type===t}}function he(n){return function(e){var t=e.nodeName.toLowerCase();return("input"===t||"button"===t)&&e.type===n}}function ge(t){return function(e){return"form"in e?e.parentNode&&!1===e.disabled?"label"in e?"label"in e.parentNode?e.parentNode.disabled===t:e.disabled===t:e.isDisabled===t||e.isDisabled!==!t&&ae(e)===t:e.disabled===t:"label"in e&&e.disabled===t}}function ve(a){return le(function(o){return o=+o,le(function(e,t){var n,r=a([],e.length,o),i=r.length;while(i--)e[n=r[i]]&&(e[n]=!(t[n]=e[n]))})})}function ye(e){return e&&"undefined"!=typeof e.getElementsByTagName&&e}for(e in d=se.support={},i=se.isXML=function(e){var t=e.namespaceURI,n=(e.ownerDocument||e).documentElement;return!Y.test(t||n&&n.nodeName||"HTML")},T=se.setDocument=function(e){var t,n,r=e?e.ownerDocument||e:p;return r!=C&&9===r.nodeType&&r.documentElement&&(a=(C=r).documentElement,E=!i(C),p!=C&&(n=C.defaultView)&&n.top!==n&&(n.addEventListener?n.addEventListener("unload",oe,!1):n.attachEvent&&n.attachEvent("onunload",oe)),d.scope=ce(function(e){return a.appendChild(e).appendChild(C.createElement("div")),"undefined"!=typeof e.querySelectorAll&&!e.querySelectorAll(":scope fieldset div").length}),d.attributes=ce(function(e){return e.className="i",!e.getAttribute("className")}),d.getElementsByTagName=ce(function(e){return e.appendChild(C.createComment("")),!e.getElementsByTagName("*").length}),d.getElementsByClassName=K.test(C.getElementsByClassName),d.getById=ce(function(e){return a.appendChild(e).id=S,!C.getElementsByName||!C.getElementsByName(S).length}),d.getById?(b.filter.ID=function(e){var t=e.replace(te,ne);return function(e){return e.getAttribute("id")===t}},b.find.ID=function(e,t){if("undefined"!=typeof t.getElementById&&E){var n=t.getElementById(e);return n?[n]:[]}}):(b.filter.ID=function(e){var n=e.replace(te,ne);return function(e){var t="undefined"!=typeof e.getAttributeNode&&e.getAttributeNode("id");return t&&t.value===n}},b.find.ID=function(e,t){if("undefined"!=typeof t.getElementById&&E){var n,r,i,o=t.getElementById(e);if(o){if((n=o.getAttributeNode("id"))&&n.value===e)return[o];i=t.getElementsByName(e),r=0;while(o=i[r++])if((n=o.getAttributeNode("id"))&&n.value===e)return[o]}return[]}}),b.find.TAG=d.getElementsByTagName?function(e,t){return"undefined"!=typeof t.getElementsByTagName?t.getElementsByTagName(e):d.qsa?t.querySelectorAll(e):void 0}:function(e,t){var n,r=[],i=0,o=t.getElementsByTagName(e);if("*"===e){while(n=o[i++])1===n.nodeType&&r.push(n);return r}return o},b.find.CLASS=d.getElementsByClassName&&function(e,t){if("undefined"!=typeof t.getElementsByClassName&&E)return t.getElementsByClassName(e)},s=[],v=[],(d.qsa=K.test(C.querySelectorAll))&&(ce(function(e){var t;a.appendChild(e).innerHTML="<a id='"+S+"'></a><select id='"+S+"-\r\\' msallowcapture=''><option selected=''></option></select>",e.querySelectorAll("[msallowcapture^='']").length&&v.push("[*^$]="+M+"*(?:''|\"\")"),e.querySelectorAll("[selected]").length||v.push("\\["+M+"*(?:value|"+R+")"),e.querySelectorAll("[id~="+S+"-]").length||v.push("~="),(t=C.createElement("input")).setAttribute("name",""),e.appendChild(t),e.querySelectorAll("[name='']").length||v.push("\\["+M+"*name"+M+"*="+M+"*(?:''|\"\")"),e.querySelectorAll(":checked").length||v.push(":checked"),e.querySelectorAll("a#"+S+"+*").length||v.push(".#.+[+~]"),e.querySelectorAll("\\\f"),v.push("[\\r\\n\\f]")}),ce(function(e){e.innerHTML="<a href='' disabled='disabled'></a><select disabled='disabled'><option/></select>";var t=C.createElement("input");t.setAttribute("type","hidden"),e.appendChild(t).setAttribute("name","D"),e.querySelectorAll("[name=d]").length&&v.push("name"+M+"*[*^$|!~]?="),2!==e.querySelectorAll(":enabled").length&&v.push(":enabled",":disabled"),a.appendChild(e).disabled=!0,2!==e.querySelectorAll(":disabled").length&&v.push(":enabled",":disabled"),e.querySelectorAll("*,:x"),v.push(",.*:")})),(d.matchesSelector=K.test(c=a.matches||a.webkitMatchesSelector||a.mozMatchesSelector||a.oMatchesSelector||a.msMatchesSelector))&&ce(function(e){d.disconnectedMatch=c.call(e,"*"),c.call(e,"[s!='']:x"),s.push("!=",F)}),v=v.length&&new RegExp(v.join("|")),s=s.length&&new RegExp(s.join("|")),t=K.test(a.compareDocumentPosition),y=t||K.test(a.contains)?function(e,t){var n=9===e.nodeType?e.documentElement:e,r=t&&t.parentNode;return e===r||!(!r||1!==r.nodeType||!(n.contains?n.contains(r):e.compareDocumentPosition&&16&e.compareDocumentPosition(r)))}:function(e,t){if(t)while(t=t.parentNode)if(t===e)return!0;return!1},D=t?function(e,t){if(e===t)return l=!0,0;var n=!e.compareDocumentPosition-!t.compareDocumentPosition;return n||(1&(n=(e.ownerDocument||e)==(t.ownerDocument||t)?e.compareDocumentPosition(t):1)||!d.sortDetached&&t.compareDocumentPosition(e)===n?e==C||e.ownerDocument==p&&y(p,e)?-1:t==C||t.ownerDocument==p&&y(p,t)?1:u?P(u,e)-P(u,t):0:4&n?-1:1)}:function(e,t){if(e===t)return l=!0,0;var n,r=0,i=e.parentNode,o=t.parentNode,a=[e],s=[t];if(!i||!o)return e==C?-1:t==C?1:i?-1:o?1:u?P(u,e)-P(u,t):0;if(i===o)return pe(e,t);n=e;while(n=n.parentNode)a.unshift(n);n=t;while(n=n.parentNode)s.unshift(n);while(a[r]===s[r])r++;return r?pe(a[r],s[r]):a[r]==p?-1:s[r]==p?1:0}),C},se.matches=function(e,t){return se(e,null,null,t)},se.matchesSelector=function(e,t){if(T(e),d.matchesSelector&&E&&!N[t+" "]&&(!s||!s.test(t))&&(!v||!v.test(t)))try{var n=c.call(e,t);if(n||d.disconnectedMatch||e.document&&11!==e.document.nodeType)return n}catch(e){N(t,!0)}return 0<se(t,C,null,[e]).length},se.contains=function(e,t){return(e.ownerDocument||e)!=C&&T(e),y(e,t)},se.attr=function(e,t){(e.ownerDocument||e)!=C&&T(e);var n=b.attrHandle[t.toLowerCase()],r=n&&j.call(b.attrHandle,t.toLowerCase())?n(e,t,!E):void 0;return void 0!==r?r:d.attributes||!E?e.getAttribute(t):(r=e.getAttributeNode(t))&&r.specified?r.value:null},se.escape=function(e){return(e+"").replace(re,ie)},se.error=function(e){throw new Error("Syntax error, unrecognized expression: "+e)},se.uniqueSort=function(e){var t,n=[],r=0,i=0;if(l=!d.detectDuplicates,u=!d.sortStable&&e.slice(0),e.sort(D),l){while(t=e[i++])t===e[i]&&(r=n.push(i));while(r--)e.splice(n[r],1)}return u=null,e},o=se.getText=function(e){var t,n="",r=0,i=e.nodeType;if(i){if(1===i||9===i||11===i){if("string"==typeof e.textContent)return e.textContent;for(e=e.firstChild;e;e=e.nextSibling)n+=o(e)}else if(3===i||4===i)return e.nodeValue}else while(t=e[r++])n+=o(t);return n},(b=se.selectors={cacheLength:50,createPseudo:le,match:G,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(te,ne),e[3]=(e[3]||e[4]||e[5]||"").replace(te,ne),"~="===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]||se.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]&&se.error(e[0]),e},PSEUDO:function(e){var t,n=!e[6]&&e[2];return G.CHILD.test(e[0])?null:(e[3]?e[2]=e[4]||e[5]||"":n&&X.test(n)&&(t=h(n,!0))&&(t=n.indexOf(")",n.length-t)-n.length)&&(e[0]=e[0].slice(0,t),e[2]=n.slice(0,t)),e.slice(0,3))}},filter:{TAG:function(e){var t=e.replace(te,ne).toLowerCase();return"*"===e?function(){return!0}:function(e){return e.nodeName&&e.nodeName.toLowerCase()===t}},CLASS:function(e){var t=m[e+" "];return t||(t=new RegExp("(^|"+M+")"+e+"("+M+"|$)"))&&m(e,function(e){return t.test("string"==typeof e.className&&e.className||"undefined"!=typeof e.getAttribute&&e.getAttribute("class")||"")})},ATTR:function(n,r,i){return function(e){var t=se.attr(e,n);return null==t?"!="===r:!r||(t+="","="===r?t===i:"!="===r?t!==i:"^="===r?i&&0===t.indexOf(i):"*="===r?i&&-1<t.indexOf(i):"$="===r?i&&t.slice(-i.length)===i:"~="===r?-1<(" "+t.replace(B," ")+" ").indexOf(i):"|="===r&&(t===i||t.slice(0,i.length+1)===i+"-"))}},CHILD:function(h,e,t,g,v){var y="nth"!==h.slice(0,3),m="last"!==h.slice(-4),x="of-type"===e;return 1===g&&0===v?function(e){return!!e.parentNode}:function(e,t,n){var r,i,o,a,s,u,l=y!==m?"nextSibling":"previousSibling",c=e.parentNode,f=x&&e.nodeName.toLowerCase(),p=!n&&!x,d=!1;if(c){if(y){while(l){a=e;while(a=a[l])if(x?a.nodeName.toLowerCase()===f:1===a.nodeType)return!1;u=l="only"===h&&!u&&"nextSibling"}return!0}if(u=[m?c.firstChild:c.lastChild],m&&p){d=(s=(r=(i=(o=(a=c)[S]||(a[S]={}))[a.uniqueID]||(o[a.uniqueID]={}))[h]||[])[0]===k&&r[1])&&r[2],a=s&&c.childNodes[s];while(a=++s&&a&&a[l]||(d=s=0)||u.pop())if(1===a.nodeType&&++d&&a===e){i[h]=[k,s,d];break}}else if(p&&(d=s=(r=(i=(o=(a=e)[S]||(a[S]={}))[a.uniqueID]||(o[a.uniqueID]={}))[h]||[])[0]===k&&r[1]),!1===d)while(a=++s&&a&&a[l]||(d=s=0)||u.pop())if((x?a.nodeName.toLowerCase()===f:1===a.nodeType)&&++d&&(p&&((i=(o=a[S]||(a[S]={}))[a.uniqueID]||(o[a.uniqueID]={}))[h]=[k,d]),a===e))break;return(d-=v)===g||d%g==0&&0<=d/g}}},PSEUDO:function(e,o){var t,a=b.pseudos[e]||b.setFilters[e.toLowerCase()]||se.error("unsupported pseudo: "+e);return a[S]?a(o):1<a.length?(t=[e,e,"",o],b.setFilters.hasOwnProperty(e.toLowerCase())?le(function(e,t){var n,r=a(e,o),i=r.length;while(i--)e[n=P(e,r[i])]=!(t[n]=r[i])}):function(e){return a(e,0,t)}):a}},pseudos:{not:le(function(e){var r=[],i=[],s=f(e.replace($,"$1"));return s[S]?le(function(e,t,n,r){var i,o=s(e,null,r,[]),a=e.length;while(a--)(i=o[a])&&(e[a]=!(t[a]=i))}):function(e,t,n){return r[0]=e,s(r,null,n,i),r[0]=null,!i.pop()}}),has:le(function(t){return function(e){return 0<se(t,e).length}}),contains:le(function(t){return t=t.replace(te,ne),function(e){return-1<(e.textContent||o(e)).indexOf(t)}}),lang:le(function(n){return V.test(n||"")||se.error("unsupported lang: "+n),n=n.replace(te,ne).toLowerCase(),function(e){var t;do{if(t=E?e.lang:e.getAttribute("xml:lang")||e.getAttribute("lang"))return(t=t.toLowerCase())===n||0===t.indexOf(n+"-")}while((e=e.parentNode)&&1===e.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===a},focus:function(e){return e===C.activeElement&&(!C.hasFocus||C.hasFocus())&&!!(e.type||e.href||~e.tabIndex)},enabled:ge(!1),disabled:ge(!0),checked:function(e){var t=e.nodeName.toLowerCase();return"input"===t&&!!e.checked||"option"===t&&!!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!b.pseudos.empty(e)},header:function(e){return J.test(e.nodeName)},input:function(e){return Q.test(e.nodeName)},button:function(e){var t=e.nodeName.toLowerCase();return"input"===t&&"button"===e.type||"button"===t},text:function(e){var t;return"input"===e.nodeName.toLowerCase()&&"text"===e.type&&(null==(t=e.getAttribute("type"))||"text"===t.toLowerCase())},first:ve(function(){return[0]}),last:ve(function(e,t){return[t-1]}),eq:ve(function(e,t,n){return[n<0?n+t:n]}),even:ve(function(e,t){for(var n=0;n<t;n+=2)e.push(n);return e}),odd:ve(function(e,t){for(var n=1;n<t;n+=2)e.push(n);return e}),lt:ve(function(e,t,n){for(var r=n<0?n+t:t<n?t:n;0<=--r;)e.push(r);return e}),gt:ve(function(e,t,n){for(var r=n<0?n+t:n;++r<t;)e.push(r);return e})}}).pseudos.nth=b.pseudos.eq,{radio:!0,checkbox:!0,file:!0,password:!0,image:!0})b.pseudos[e]=de(e);for(e in{submit:!0,reset:!0})b.pseudos[e]=he(e);function me(){}function xe(e){for(var t=0,n=e.length,r="";t<n;t++)r+=e[t].value;return r}function be(s,e,t){var u=e.dir,l=e.next,c=l||u,f=t&&"parentNode"===c,p=r++;return e.first?function(e,t,n){while(e=e[u])if(1===e.nodeType||f)return s(e,t,n);return!1}:function(e,t,n){var r,i,o,a=[k,p];if(n){while(e=e[u])if((1===e.nodeType||f)&&s(e,t,n))return!0}else while(e=e[u])if(1===e.nodeType||f)if(i=(o=e[S]||(e[S]={}))[e.uniqueID]||(o[e.uniqueID]={}),l&&l===e.nodeName.toLowerCase())e=e[u]||e;else{if((r=i[c])&&r[0]===k&&r[1]===p)return a[2]=r[2];if((i[c]=a)[2]=s(e,t,n))return!0}return!1}}function we(i){return 1<i.length?function(e,t,n){var r=i.length;while(r--)if(!i[r](e,t,n))return!1;return!0}:i[0]}function Te(e,t,n,r,i){for(var o,a=[],s=0,u=e.length,l=null!=t;s<u;s++)(o=e[s])&&(n&&!n(o,r,i)||(a.push(o),l&&t.push(s)));return a}function Ce(d,h,g,v,y,e){return v&&!v[S]&&(v=Ce(v)),y&&!y[S]&&(y=Ce(y,e)),le(function(e,t,n,r){var i,o,a,s=[],u=[],l=t.length,c=e||function(e,t,n){for(var r=0,i=t.length;r<i;r++)se(e,t[r],n);return n}(h||"*",n.nodeType?[n]:n,[]),f=!d||!e&&h?c:Te(c,s,d,n,r),p=g?y||(e?d:l||v)?[]:t:f;if(g&&g(f,p,n,r),v){i=Te(p,u),v(i,[],n,r),o=i.length;while(o--)(a=i[o])&&(p[u[o]]=!(f[u[o]]=a))}if(e){if(y||d){if(y){i=[],o=p.length;while(o--)(a=p[o])&&i.push(f[o]=a);y(null,p=[],i,r)}o=p.length;while(o--)(a=p[o])&&-1<(i=y?P(e,a):s[o])&&(e[i]=!(t[i]=a))}}else p=Te(p===t?p.splice(l,p.length):p),y?y(null,t,p,r):H.apply(t,p)})}function Ee(e){for(var i,t,n,r=e.length,o=b.relative[e[0].type],a=o||b.relative[" "],s=o?1:0,u=be(function(e){return e===i},a,!0),l=be(function(e){return-1<P(i,e)},a,!0),c=[function(e,t,n){var r=!o&&(n||t!==w)||((i=t).nodeType?u(e,t,n):l(e,t,n));return i=null,r}];s<r;s++)if(t=b.relative[e[s].type])c=[be(we(c),t)];else{if((t=b.filter[e[s].type].apply(null,e[s].matches))[S]){for(n=++s;n<r;n++)if(b.relative[e[n].type])break;return Ce(1<s&&we(c),1<s&&xe(e.slice(0,s-1).concat({value:" "===e[s-2].type?"*":""})).replace($,"$1"),t,s<n&&Ee(e.slice(s,n)),n<r&&Ee(e=e.slice(n)),n<r&&xe(e))}c.push(t)}return we(c)}return me.prototype=b.filters=b.pseudos,b.setFilters=new me,h=se.tokenize=function(e,t){var n,r,i,o,a,s,u,l=x[e+" "];if(l)return t?0:l.slice(0);a=e,s=[],u=b.preFilter;while(a){for(o in n&&!(r=_.exec(a))||(r&&(a=a.slice(r[0].length)||a),s.push(i=[])),n=!1,(r=z.exec(a))&&(n=r.shift(),i.push({value:n,type:r[0].replace($," ")}),a=a.slice(n.length)),b.filter)!(r=G[o].exec(a))||u[o]&&!(r=u[o](r))||(n=r.shift(),i.push({value:n,type:o,matches:r}),a=a.slice(n.length));if(!n)break}return t?a.length:a?se.error(e):x(e,s).slice(0)},f=se.compile=function(e,t){var n,v,y,m,x,r,i=[],o=[],a=A[e+" "];if(!a){t||(t=h(e)),n=t.length;while(n--)(a=Ee(t[n]))[S]?i.push(a):o.push(a);(a=A(e,(v=o,m=0<(y=i).length,x=0<v.length,r=function(e,t,n,r,i){var o,a,s,u=0,l="0",c=e&&[],f=[],p=w,d=e||x&&b.find.TAG("*",i),h=k+=null==p?1:Math.random()||.1,g=d.length;for(i&&(w=t==C||t||i);l!==g&&null!=(o=d[l]);l++){if(x&&o){a=0,t||o.ownerDocument==C||(T(o),n=!E);while(s=v[a++])if(s(o,t||C,n)){r.push(o);break}i&&(k=h)}m&&((o=!s&&o)&&u--,e&&c.push(o))}if(u+=l,m&&l!==u){a=0;while(s=y[a++])s(c,f,t,n);if(e){if(0<u)while(l--)c[l]||f[l]||(f[l]=q.call(r));f=Te(f)}H.apply(r,f),i&&!e&&0<f.length&&1<u+y.length&&se.uniqueSort(r)}return i&&(k=h,w=p),c},m?le(r):r))).selector=e}return a},g=se.select=function(e,t,n,r){var i,o,a,s,u,l="function"==typeof e&&e,c=!r&&h(e=l.selector||e);if(n=n||[],1===c.length){if(2<(o=c[0]=c[0].slice(0)).length&&"ID"===(a=o[0]).type&&9===t.nodeType&&E&&b.relative[o[1].type]){if(!(t=(b.find.ID(a.matches[0].replace(te,ne),t)||[])[0]))return n;l&&(t=t.parentNode),e=e.slice(o.shift().value.length)}i=G.needsContext.test(e)?0:o.length;while(i--){if(a=o[i],b.relative[s=a.type])break;if((u=b.find[s])&&(r=u(a.matches[0].replace(te,ne),ee.test(o[0].type)&&ye(t.parentNode)||t))){if(o.splice(i,1),!(e=r.length&&xe(o)))return H.apply(n,r),n;break}}}return(l||f(e,c))(r,t,!E,n,!t||ee.test(e)&&ye(t.parentNode)||t),n},d.sortStable=S.split("").sort(D).join("")===S,d.detectDuplicates=!!l,T(),d.sortDetached=ce(function(e){return 1&e.compareDocumentPosition(C.createElement("fieldset"))}),ce(function(e){return e.innerHTML="<a href='#'></a>","#"===e.firstChild.getAttribute("href")})||fe("type|href|height|width",function(e,t,n){if(!n)return e.getAttribute(t,"type"===t.toLowerCase()?1:2)}),d.attributes&&ce(function(e){return e.innerHTML="<input/>",e.firstChild.setAttribute("value",""),""===e.firstChild.getAttribute("value")})||fe("value",function(e,t,n){if(!n&&"input"===e.nodeName.toLowerCase())return e.defaultValue}),ce(function(e){return null==e.getAttribute("disabled")})||fe(R,function(e,t,n){var r;if(!n)return!0===e[t]?t.toLowerCase():(r=e.getAttributeNode(t))&&r.specified?r.value:null}),se}(C);S.find=d,S.expr=d.selectors,S.expr[":"]=S.expr.pseudos,S.uniqueSort=S.unique=d.uniqueSort,S.text=d.getText,S.isXMLDoc=d.isXML,S.contains=d.contains,S.escapeSelector=d.escape;var h=function(e,t,n){var r=[],i=void 0!==n;while((e=e[t])&&9!==e.nodeType)if(1===e.nodeType){if(i&&S(e).is(n))break;r.push(e)}return r},T=function(e,t){for(var n=[];e;e=e.nextSibling)1===e.nodeType&&e!==t&&n.push(e);return n},k=S.expr.match.needsContext;function A(e,t){return e.nodeName&&e.nodeName.toLowerCase()===t.toLowerCase()}var N=/^<([a-z][^\/\0>:\x20\t\r\n\f]*)[\x20\t\r\n\f]*\/?>(?:<\/\1>|)$/i;function D(e,n,r){return m(n)?S.grep(e,function(e,t){return!!n.call(e,t,e)!==r}):n.nodeType?S.grep(e,function(e){return e===n!==r}):"string"!=typeof n?S.grep(e,function(e){return-1<i.call(n,e)!==r}):S.filter(n,e,r)}S.filter=function(e,t,n){var r=t[0];return n&&(e=":not("+e+")"),1===t.length&&1===r.nodeType?S.find.matchesSelector(r,e)?[r]:[]:S.find.matches(e,S.grep(t,function(e){return 1===e.nodeType}))},S.fn.extend({find:function(e){var t,n,r=this.length,i=this;if("string"!=typeof e)return this.pushStack(S(e).filter(function(){for(t=0;t<r;t++)if(S.contains(i[t],this))return!0}));for(n=this.pushStack([]),t=0;t<r;t++)S.find(e,i[t],n);return 1<r?S.uniqueSort(n):n},filter:function(e){return this.pushStack(D(this,e||[],!1))},not:function(e){return this.pushStack(D(this,e||[],!0))},is:function(e){return!!D(this,"string"==typeof e&&k.test(e)?S(e):e||[],!1).length}});var j,q=/^(?:\s*(<[\w\W]+>)[^>]*|#([\w-]+))$/;(S.fn.init=function(e,t,n){var r,i;if(!e)return this;if(n=n||j,"string"==typeof e){if(!(r="<"===e[0]&&">"===e[e.length-1]&&3<=e.length?[null,e,null]:q.exec(e))||!r[1]&&t)return!t||t.jquery?(t||n).find(e):this.constructor(t).find(e);if(r[1]){if(t=t instanceof S?t[0]:t,S.merge(this,S.parseHTML(r[1],t&&t.nodeType?t.ownerDocument||t:E,!0)),N.test(r[1])&&S.isPlainObject(t))for(r in t)m(this[r])?this[r](t[r]):this.attr(r,t[r]);return this}return(i=E.getElementById(r[2]))&&(this[0]=i,this.length=1),this}return e.nodeType?(this[0]=e,this.length=1,this):m(e)?void 0!==n.ready?n.ready(e):e(S):S.makeArray(e,this)}).prototype=S.fn,j=S(E);var L=/^(?:parents|prev(?:Until|All))/,H={children:!0,contents:!0,next:!0,prev:!0};function O(e,t){while((e=e[t])&&1!==e.nodeType);return e}S.fn.extend({has:function(e){var t=S(e,this),n=t.length;return this.filter(function(){for(var e=0;e<n;e++)if(S.contains(this,t[e]))return!0})},closest:function(e,t){var n,r=0,i=this.length,o=[],a="string"!=typeof e&&S(e);if(!k.test(e))for(;r<i;r++)for(n=this[r];n&&n!==t;n=n.parentNode)if(n.nodeType<11&&(a?-1<a.index(n):1===n.nodeType&&S.find.matchesSelector(n,e))){o.push(n);break}return this.pushStack(1<o.length?S.uniqueSort(o):o)},index:function(e){return e?"string"==typeof e?i.call(S(e),this[0]):i.call(this,e.jquery?e[0]:e):this[0]&&this[0].parentNode?this.first().prevAll().length:-1},add:function(e,t){return this.pushStack(S.uniqueSort(S.merge(this.get(),S(e,t))))},addBack:function(e){return this.add(null==e?this.prevObject:this.prevObject.filter(e))}}),S.each({parent:function(e){var t=e.parentNode;return t&&11!==t.nodeType?t:null},parents:function(e){return h(e,"parentNode")},parentsUntil:function(e,t,n){return h(e,"parentNode",n)},next:function(e){return O(e,"nextSibling")},prev:function(e){return O(e,"previousSibling")},nextAll:function(e){return h(e,"nextSibling")},prevAll:function(e){return h(e,"previousSibling")},nextUntil:function(e,t,n){return h(e,"nextSibling",n)},prevUntil:function(e,t,n){return h(e,"previousSibling",n)},siblings:function(e){return T((e.parentNode||{}).firstChild,e)},children:function(e){return T(e.firstChild)},contents:function(e){return null!=e.contentDocument&&r(e.contentDocument)?e.contentDocument:(A(e,"template")&&(e=e.content||e),S.merge([],e.childNodes))}},function(r,i){S.fn[r]=function(e,t){var n=S.map(this,i,e);return"Until"!==r.slice(-5)&&(t=e),t&&"string"==typeof t&&(n=S.filter(t,n)),1<this.length&&(H[r]||S.uniqueSort(n),L.test(r)&&n.reverse()),this.pushStack(n)}});var P=/[^\x20\t\r\n\f]+/g;function R(e){return e}function M(e){throw e}function I(e,t,n,r){var i;try{e&&m(i=e.promise)?i.call(e).done(t).fail(n):e&&m(i=e.then)?i.call(e,t,n):t.apply(void 0,[e].slice(r))}catch(e){n.apply(void 0,[e])}}S.Callbacks=function(r){var e,n;r="string"==typeof r?(e=r,n={},S.each(e.match(P)||[],function(e,t){n[t]=!0}),n):S.extend({},r);var i,t,o,a,s=[],u=[],l=-1,c=function(){for(a=a||r.once,o=i=!0;u.length;l=-1){t=u.shift();while(++l<s.length)!1===s[l].apply(t[0],t[1])&&r.stopOnFalse&&(l=s.length,t=!1)}r.memory||(t=!1),i=!1,a&&(s=t?[]:"")},f={add:function(){return s&&(t&&!i&&(l=s.length-1,u.push(t)),function n(e){S.each(e,function(e,t){m(t)?r.unique&&f.has(t)||s.push(t):t&&t.length&&"string"!==w(t)&&n(t)})}(arguments),t&&!i&&c()),this},remove:function(){return S.each(arguments,function(e,t){var n;while(-1<(n=S.inArray(t,s,n)))s.splice(n,1),n<=l&&l--}),this},has:function(e){return e?-1<S.inArray(e,s):0<s.length},empty:function(){return s&&(s=[]),this},disable:function(){return a=u=[],s=t="",this},disabled:function(){return!s},lock:function(){return a=u=[],t||i||(s=t=""),this},locked:function(){return!!a},fireWith:function(e,t){return a||(t=[e,(t=t||[]).slice?t.slice():t],u.push(t),i||c()),this},fire:function(){return f.fireWith(this,arguments),this},fired:function(){return!!o}};return f},S.extend({Deferred:function(e){var o=[["notify","progress",S.Callbacks("memory"),S.Callbacks("memory"),2],["resolve","done",S.Callbacks("once memory"),S.Callbacks("once memory"),0,"resolved"],["reject","fail",S.Callbacks("once memory"),S.Callbacks("once memory"),1,"rejected"]],i="pending",a={state:function(){return i},always:function(){return s.done(arguments).fail(arguments),this},"catch":function(e){return a.then(null,e)},pipe:function(){var i=arguments;return S.Deferred(function(r){S.each(o,function(e,t){var n=m(i[t[4]])&&i[t[4]];s[t[1]](function(){var e=n&&n.apply(this,arguments);e&&m(e.promise)?e.promise().progress(r.notify).done(r.resolve).fail(r.reject):r[t[0]+"With"](this,n?[e]:arguments)})}),i=null}).promise()},then:function(t,n,r){var u=0;function l(i,o,a,s){return function(){var n=this,r=arguments,e=function(){var e,t;if(!(i<u)){if((e=a.apply(n,r))===o.promise())throw new TypeError("Thenable self-resolution");t=e&&("object"==typeof e||"function"==typeof e)&&e.then,m(t)?s?t.call(e,l(u,o,R,s),l(u,o,M,s)):(u++,t.call(e,l(u,o,R,s),l(u,o,M,s),l(u,o,R,o.notifyWith))):(a!==R&&(n=void 0,r=[e]),(s||o.resolveWith)(n,r))}},t=s?e:function(){try{e()}catch(e){S.Deferred.exceptionHook&&S.Deferred.exceptionHook(e,t.stackTrace),u<=i+1&&(a!==M&&(n=void 0,r=[e]),o.rejectWith(n,r))}};i?t():(S.Deferred.getStackHook&&(t.stackTrace=S.Deferred.getStackHook()),C.setTimeout(t))}}return S.Deferred(function(e){o[0][3].add(l(0,e,m(r)?r:R,e.notifyWith)),o[1][3].add(l(0,e,m(t)?t:R)),o[2][3].add(l(0,e,m(n)?n:M))}).promise()},promise:function(e){return null!=e?S.extend(e,a):a}},s={};return S.each(o,function(e,t){var n=t[2],r=t[5];a[t[1]]=n.add,r&&n.add(function(){i=r},o[3-e][2].disable,o[3-e][3].disable,o[0][2].lock,o[0][3].lock),n.add(t[3].fire),s[t[0]]=function(){return s[t[0]+"With"](this===s?void 0:this,arguments),this},s[t[0]+"With"]=n.fireWith}),a.promise(s),e&&e.call(s,s),s},when:function(e){var n=arguments.length,t=n,r=Array(t),i=s.call(arguments),o=S.Deferred(),a=function(t){return function(e){r[t]=this,i[t]=1<arguments.length?s.call(arguments):e,--n||o.resolveWith(r,i)}};if(n<=1&&(I(e,o.done(a(t)).resolve,o.reject,!n),"pending"===o.state()||m(i[t]&&i[t].then)))return o.then();while(t--)I(i[t],a(t),o.reject);return o.promise()}});var W=/^(Eval|Internal|Range|Reference|Syntax|Type|URI)Error$/;S.Deferred.exceptionHook=function(e,t){C.console&&C.console.warn&&e&&W.test(e.name)&&C.console.warn("jQuery.Deferred exception: "+e.message,e.stack,t)},S.readyException=function(e){C.setTimeout(function(){throw e})};var F=S.Deferred();function B(){E.removeEventListener("DOMContentLoaded",B),C.removeEventListener("load",B),S.ready()}S.fn.ready=function(e){return F.then(e)["catch"](function(e){S.readyException(e)}),this},S.extend({isReady:!1,readyWait:1,ready:function(e){(!0===e?--S.readyWait:S.isReady)||(S.isReady=!0)!==e&&0<--S.readyWait||F.resolveWith(E,[S])}}),S.ready.then=F.then,"complete"===E.readyState||"loading"!==E.readyState&&!E.documentElement.doScroll?C.setTimeout(S.ready):(E.addEventListener("DOMContentLoaded",B),C.addEventListener("load",B));var $=function(e,t,n,r,i,o,a){var s=0,u=e.length,l=null==n;if("object"===w(n))for(s in i=!0,n)$(e,t,s,n[s],!0,o,a);else if(void 0!==r&&(i=!0,m(r)||(a=!0),l&&(a?(t.call(e,r),t=null):(l=t,t=function(e,t,n){return l.call(S(e),n)})),t))for(;s<u;s++)t(e[s],n,a?r:r.call(e[s],s,t(e[s],n)));return i?e:l?t.call(e):u?t(e[0],n):o},_=/^-ms-/,z=/-([a-z])/g;function U(e,t){return t.toUpperCase()}function X(e){return e.replace(_,"ms-").replace(z,U)}var V=function(e){return 1===e.nodeType||9===e.nodeType||!+e.nodeType};function G(){this.expando=S.expando+G.uid++}G.uid=1,G.prototype={cache:function(e){var t=e[this.expando];return t||(t={},V(e)&&(e.nodeType?e[this.expando]=t:Object.defineProperty(e,this.expando,{value:t,configurable:!0}))),t},set:function(e,t,n){var r,i=this.cache(e);if("string"==typeof t)i[X(t)]=n;else for(r in t)i[X(r)]=t[r];return i},get:function(e,t){return void 0===t?this.cache(e):e[this.expando]&&e[this.expando][X(t)]},access:function(e,t,n){return void 0===t||t&&"string"==typeof t&&void 0===n?this.get(e,t):(this.set(e,t,n),void 0!==n?n:t)},remove:function(e,t){var n,r=e[this.expando];if(void 0!==r){if(void 0!==t){n=(t=Array.isArray(t)?t.map(X):(t=X(t))in r?[t]:t.match(P)||[]).length;while(n--)delete r[t[n]]}(void 0===t||S.isEmptyObject(r))&&(e.nodeType?e[this.expando]=void 0:delete e[this.expando])}},hasData:function(e){var t=e[this.expando];return void 0!==t&&!S.isEmptyObject(t)}};var Y=new G,Q=new G,J=/^(?:\{[\w\W]*\}|\[[\w\W]*\])$/,K=/[A-Z]/g;function Z(e,t,n){var r,i;if(void 0===n&&1===e.nodeType)if(r="data-"+t.replace(K,"-$&").toLowerCase(),"string"==typeof(n=e.getAttribute(r))){try{n="true"===(i=n)||"false"!==i&&("null"===i?null:i===+i+""?+i:J.test(i)?JSON.parse(i):i)}catch(e){}Q.set(e,t,n)}else n=void 0;return n}S.extend({hasData:function(e){return Q.hasData(e)||Y.hasData(e)},data:function(e,t,n){return Q.access(e,t,n)},removeData:function(e,t){Q.remove(e,t)},_data:function(e,t,n){return Y.access(e,t,n)},_removeData:function(e,t){Y.remove(e,t)}}),S.fn.extend({data:function(n,e){var t,r,i,o=this[0],a=o&&o.attributes;if(void 0===n){if(this.length&&(i=Q.get(o),1===o.nodeType&&!Y.get(o,"hasDataAttrs"))){t=a.length;while(t--)a[t]&&0===(r=a[t].name).indexOf("data-")&&(r=X(r.slice(5)),Z(o,r,i[r]));Y.set(o,"hasDataAttrs",!0)}return i}return"object"==typeof n?this.each(function(){Q.set(this,n)}):$(this,function(e){var t;if(o&&void 0===e)return void 0!==(t=Q.get(o,n))?t:void 0!==(t=Z(o,n))?t:void 0;this.each(function(){Q.set(this,n,e)})},null,e,1<arguments.length,null,!0)},removeData:function(e){return this.each(function(){Q.remove(this,e)})}}),S.extend({queue:function(e,t,n){var r;if(e)return t=(t||"fx")+"queue",r=Y.get(e,t),n&&(!r||Array.isArray(n)?r=Y.access(e,t,S.makeArray(n)):r.push(n)),r||[]},dequeue:function(e,t){t=t||"fx";var n=S.queue(e,t),r=n.length,i=n.shift(),o=S._queueHooks(e,t);"inprogress"===i&&(i=n.shift(),r--),i&&("fx"===t&&n.unshift("inprogress"),delete o.stop,i.call(e,function(){S.dequeue(e,t)},o)),!r&&o&&o.empty.fire()},_queueHooks:function(e,t){var n=t+"queueHooks";return Y.get(e,n)||Y.access(e,n,{empty:S.Callbacks("once memory").add(function(){Y.remove(e,[t+"queue",n])})})}}),S.fn.extend({queue:function(t,n){var e=2;return"string"!=typeof t&&(n=t,t="fx",e--),arguments.length<e?S.queue(this[0],t):void 0===n?this:this.each(function(){var e=S.queue(this,t,n);S._queueHooks(this,t),"fx"===t&&"inprogress"!==e[0]&&S.dequeue(this,t)})},dequeue:function(e){return this.each(function(){S.dequeue(this,e)})},clearQueue:function(e){return this.queue(e||"fx",[])},promise:function(e,t){var n,r=1,i=S.Deferred(),o=this,a=this.length,s=function(){--r||i.resolveWith(o,[o])};"string"!=typeof e&&(t=e,e=void 0),e=e||"fx";while(a--)(n=Y.get(o[a],e+"queueHooks"))&&n.empty&&(r++,n.empty.add(s));return s(),i.promise(t)}});var ee=/[+-]?(?:\d*\.|)\d+(?:[eE][+-]?\d+|)/.source,te=new RegExp("^(?:([+-])=|)("+ee+")([a-z%]*)$","i"),ne=["Top","Right","Bottom","Left"],re=E.documentElement,ie=function(e){return S.contains(e.ownerDocument,e)},oe={composed:!0};re.getRootNode&&(ie=function(e){return S.contains(e.ownerDocument,e)||e.getRootNode(oe)===e.ownerDocument});var ae=function(e,t){return"none"===(e=t||e).style.display||""===e.style.display&&ie(e)&&"none"===S.css(e,"display")};function se(e,t,n,r){var i,o,a=20,s=r?function(){return r.cur()}:function(){return S.css(e,t,"")},u=s(),l=n&&n[3]||(S.cssNumber[t]?"":"px"),c=e.nodeType&&(S.cssNumber[t]||"px"!==l&&+u)&&te.exec(S.css(e,t));if(c&&c[3]!==l){u/=2,l=l||c[3],c=+u||1;while(a--)S.style(e,t,c+l),(1-o)*(1-(o=s()/u||.5))<=0&&(a=0),c/=o;c*=2,S.style(e,t,c+l),n=n||[]}return n&&(c=+c||+u||0,i=n[1]?c+(n[1]+1)*n[2]:+n[2],r&&(r.unit=l,r.start=c,r.end=i)),i}var ue={};function le(e,t){for(var n,r,i,o,a,s,u,l=[],c=0,f=e.length;c<f;c++)(r=e[c]).style&&(n=r.style.display,t?("none"===n&&(l[c]=Y.get(r,"display")||null,l[c]||(r.style.display="")),""===r.style.display&&ae(r)&&(l[c]=(u=a=o=void 0,a=(i=r).ownerDocument,s=i.nodeName,(u=ue[s])||(o=a.body.appendChild(a.createElement(s)),u=S.css(o,"display"),o.parentNode.removeChild(o),"none"===u&&(u="block"),ue[s]=u)))):"none"!==n&&(l[c]="none",Y.set(r,"display",n)));for(c=0;c<f;c++)null!=l[c]&&(e[c].style.display=l[c]);return e}S.fn.extend({show:function(){return le(this,!0)},hide:function(){return le(this)},toggle:function(e){return"boolean"==typeof e?e?this.show():this.hide():this.each(function(){ae(this)?S(this).show():S(this).hide()})}});var ce,fe,pe=/^(?:checkbox|radio)$/i,de=/<([a-z][^\/\0>\x20\t\r\n\f]*)/i,he=/^$|^module$|\/(?:java|ecma)script/i;ce=E.createDocumentFragment().appendChild(E.createElement("div")),(fe=E.createElement("input")).setAttribute("type","radio"),fe.setAttribute("checked","checked"),fe.setAttribute("name","t"),ce.appendChild(fe),y.checkClone=ce.cloneNode(!0).cloneNode(!0).lastChild.checked,ce.innerHTML="<textarea>x</textarea>",y.noCloneChecked=!!ce.cloneNode(!0).lastChild.defaultValue,ce.innerHTML="<option></option>",y.option=!!ce.lastChild;var ge={thead:[1,"<table>","</table>"],col:[2,"<table><colgroup>","</colgroup></table>"],tr:[2,"<table><tbody>","</tbody></table>"],td:[3,"<table><tbody><tr>","</tr></tbody></table>"],_default:[0,"",""]};function ve(e,t){var n;return n="undefined"!=typeof e.getElementsByTagName?e.getElementsByTagName(t||"*"):"undefined"!=typeof e.querySelectorAll?e.querySelectorAll(t||"*"):[],void 0===t||t&&A(e,t)?S.merge([e],n):n}function ye(e,t){for(var n=0,r=e.length;n<r;n++)Y.set(e[n],"globalEval",!t||Y.get(t[n],"globalEval"))}ge.tbody=ge.tfoot=ge.colgroup=ge.caption=ge.thead,ge.th=ge.td,y.option||(ge.optgroup=ge.option=[1,"<select multiple='multiple'>","</select>"]);var me=/<|&#?\w+;/;function xe(e,t,n,r,i){for(var o,a,s,u,l,c,f=t.createDocumentFragment(),p=[],d=0,h=e.length;d<h;d++)if((o=e[d])||0===o)if("object"===w(o))S.merge(p,o.nodeType?[o]:o);else if(me.test(o)){a=a||f.appendChild(t.createElement("div")),s=(de.exec(o)||["",""])[1].toLowerCase(),u=ge[s]||ge._default,a.innerHTML=u[1]+S.htmlPrefilter(o)+u[2],c=u[0];while(c--)a=a.lastChild;S.merge(p,a.childNodes),(a=f.firstChild).textContent=""}else p.push(t.createTextNode(o));f.textContent="",d=0;while(o=p[d++])if(r&&-1<S.inArray(o,r))i&&i.push(o);else if(l=ie(o),a=ve(f.appendChild(o),"script"),l&&ye(a),n){c=0;while(o=a[c++])he.test(o.type||"")&&n.push(o)}return f}var be=/^key/,we=/^(?:mouse|pointer|contextmenu|drag|drop)|click/,Te=/^([^.]*)(?:\.(.+)|)/;function Ce(){return!0}function Ee(){return!1}function Se(e,t){return e===function(){try{return E.activeElement}catch(e){}}()==("focus"===t)}function ke(e,t,n,r,i,o){var a,s;if("object"==typeof t){for(s in"string"!=typeof n&&(r=r||n,n=void 0),t)ke(e,s,n,r,t[s],o);return e}if(null==r&&null==i?(i=n,r=n=void 0):null==i&&("string"==typeof n?(i=r,r=void 0):(i=r,r=n,n=void 0)),!1===i)i=Ee;else if(!i)return e;return 1===o&&(a=i,(i=function(e){return S().off(e),a.apply(this,arguments)}).guid=a.guid||(a.guid=S.guid++)),e.each(function(){S.event.add(this,t,i,r,n)})}function Ae(e,i,o){o?(Y.set(e,i,!1),S.event.add(e,i,{namespace:!1,handler:function(e){var t,n,r=Y.get(this,i);if(1&e.isTrigger&&this[i]){if(r.length)(S.event.special[i]||{}).delegateType&&e.stopPropagation();else if(r=s.call(arguments),Y.set(this,i,r),t=o(this,i),this[i](),r!==(n=Y.get(this,i))||t?Y.set(this,i,!1):n={},r!==n)return e.stopImmediatePropagation(),e.preventDefault(),n.value}else r.length&&(Y.set(this,i,{value:S.event.trigger(S.extend(r[0],S.Event.prototype),r.slice(1),this)}),e.stopImmediatePropagation())}})):void 0===Y.get(e,i)&&S.event.add(e,i,Ce)}S.event={global:{},add:function(t,e,n,r,i){var o,a,s,u,l,c,f,p,d,h,g,v=Y.get(t);if(V(t)){n.handler&&(n=(o=n).handler,i=o.selector),i&&S.find.matchesSelector(re,i),n.guid||(n.guid=S.guid++),(u=v.events)||(u=v.events=Object.create(null)),(a=v.handle)||(a=v.handle=function(e){return"undefined"!=typeof S&&S.event.triggered!==e.type?S.event.dispatch.apply(t,arguments):void 0}),l=(e=(e||"").match(P)||[""]).length;while(l--)d=g=(s=Te.exec(e[l])||[])[1],h=(s[2]||"").split(".").sort(),d&&(f=S.event.special[d]||{},d=(i?f.delegateType:f.bindType)||d,f=S.event.special[d]||{},c=S.extend({type:d,origType:g,data:r,handler:n,guid:n.guid,selector:i,needsContext:i&&S.expr.match.needsContext.test(i),namespace:h.join(".")},o),(p=u[d])||((p=u[d]=[]).delegateCount=0,f.setup&&!1!==f.setup.call(t,r,h,a)||t.addEventListener&&t.addEventListener(d,a)),f.add&&(f.add.call(t,c),c.handler.guid||(c.handler.guid=n.guid)),i?p.splice(p.delegateCount++,0,c):p.push(c),S.event.global[d]=!0)}},remove:function(e,t,n,r,i){var o,a,s,u,l,c,f,p,d,h,g,v=Y.hasData(e)&&Y.get(e);if(v&&(u=v.events)){l=(t=(t||"").match(P)||[""]).length;while(l--)if(d=g=(s=Te.exec(t[l])||[])[1],h=(s[2]||"").split(".").sort(),d){f=S.event.special[d]||{},p=u[d=(r?f.delegateType:f.bindType)||d]||[],s=s[2]&&new RegExp("(^|\\.)"+h.join("\\.(?:.*\\.|)")+"(\\.|$)"),a=o=p.length;while(o--)c=p[o],!i&&g!==c.origType||n&&n.guid!==c.guid||s&&!s.test(c.namespace)||r&&r!==c.selector&&("**"!==r||!c.selector)||(p.splice(o,1),c.selector&&p.delegateCount--,f.remove&&f.remove.call(e,c));a&&!p.length&&(f.teardown&&!1!==f.teardown.call(e,h,v.handle)||S.removeEvent(e,d,v.handle),delete u[d])}else for(d in u)S.event.remove(e,d+t[l],n,r,!0);S.isEmptyObject(u)&&Y.remove(e,"handle events")}},dispatch:function(e){var t,n,r,i,o,a,s=new Array(arguments.length),u=S.event.fix(e),l=(Y.get(this,"events")||Object.create(null))[u.type]||[],c=S.event.special[u.type]||{};for(s[0]=u,t=1;t<arguments.length;t++)s[t]=arguments[t];if(u.delegateTarget=this,!c.preDispatch||!1!==c.preDispatch.call(this,u)){a=S.event.handlers.call(this,u,l),t=0;while((i=a[t++])&&!u.isPropagationStopped()){u.currentTarget=i.elem,n=0;while((o=i.handlers[n++])&&!u.isImmediatePropagationStopped())u.rnamespace&&!1!==o.namespace&&!u.rnamespace.test(o.namespace)||(u.handleObj=o,u.data=o.data,void 0!==(r=((S.event.special[o.origType]||{}).handle||o.handler).apply(i.elem,s))&&!1===(u.result=r)&&(u.preventDefault(),u.stopPropagation()))}return c.postDispatch&&c.postDispatch.call(this,u),u.result}},handlers:function(e,t){var n,r,i,o,a,s=[],u=t.delegateCount,l=e.target;if(u&&l.nodeType&&!("click"===e.type&&1<=e.button))for(;l!==this;l=l.parentNode||this)if(1===l.nodeType&&("click"!==e.type||!0!==l.disabled)){for(o=[],a={},n=0;n<u;n++)void 0===a[i=(r=t[n]).selector+" "]&&(a[i]=r.needsContext?-1<S(i,this).index(l):S.find(i,this,null,[l]).length),a[i]&&o.push(r);o.length&&s.push({elem:l,handlers:o})}return l=this,u<t.length&&s.push({elem:l,handlers:t.slice(u)}),s},addProp:function(t,e){Object.defineProperty(S.Event.prototype,t,{enumerable:!0,configurable:!0,get:m(e)?function(){if(this.originalEvent)return e(this.originalEvent)}:function(){if(this.originalEvent)return this.originalEvent[t]},set:function(e){Object.defineProperty(this,t,{enumerable:!0,configurable:!0,writable:!0,value:e})}})},fix:function(e){return e[S.expando]?e:new S.Event(e)},special:{load:{noBubble:!0},click:{setup:function(e){var t=this||e;return pe.test(t.type)&&t.click&&A(t,"input")&&Ae(t,"click",Ce),!1},trigger:function(e){var t=this||e;return pe.test(t.type)&&t.click&&A(t,"input")&&Ae(t,"click"),!0},_default:function(e){var t=e.target;return pe.test(t.type)&&t.click&&A(t,"input")&&Y.get(t,"click")||A(t,"a")}},beforeunload:{postDispatch:function(e){void 0!==e.result&&e.originalEvent&&(e.originalEvent.returnValue=e.result)}}}},S.removeEvent=function(e,t,n){e.removeEventListener&&e.removeEventListener(t,n)},S.Event=function(e,t){if(!(this instanceof S.Event))return new S.Event(e,t);e&&e.type?(this.originalEvent=e,this.type=e.type,this.isDefaultPrevented=e.defaultPrevented||void 0===e.defaultPrevented&&!1===e.returnValue?Ce:Ee,this.target=e.target&&3===e.target.nodeType?e.target.parentNode:e.target,this.currentTarget=e.currentTarget,this.relatedTarget=e.relatedTarget):this.type=e,t&&S.extend(this,t),this.timeStamp=e&&e.timeStamp||Date.now(),this[S.expando]=!0},S.Event.prototype={constructor:S.Event,isDefaultPrevented:Ee,isPropagationStopped:Ee,isImmediatePropagationStopped:Ee,isSimulated:!1,preventDefault:function(){var e=this.originalEvent;this.isDefaultPrevented=Ce,e&&!this.isSimulated&&e.preventDefault()},stopPropagation:function(){var e=this.originalEvent;this.isPropagationStopped=Ce,e&&!this.isSimulated&&e.stopPropagation()},stopImmediatePropagation:function(){var e=this.originalEvent;this.isImmediatePropagationStopped=Ce,e&&!this.isSimulated&&e.stopImmediatePropagation(),this.stopPropagation()}},S.each({altKey:!0,bubbles:!0,cancelable:!0,changedTouches:!0,ctrlKey:!0,detail:!0,eventPhase:!0,metaKey:!0,pageX:!0,pageY:!0,shiftKey:!0,view:!0,"char":!0,code:!0,charCode:!0,key:!0,keyCode:!0,button:!0,buttons:!0,clientX:!0,clientY:!0,offsetX:!0,offsetY:!0,pointerId:!0,pointerType:!0,screenX:!0,screenY:!0,targetTouches:!0,toElement:!0,touches:!0,which:function(e){var t=e.button;return null==e.which&&be.test(e.type)?null!=e.charCode?e.charCode:e.keyCode:!e.which&&void 0!==t&&we.test(e.type)?1&t?1:2&t?3:4&t?2:0:e.which}},S.event.addProp),S.each({focus:"focusin",blur:"focusout"},function(e,t){S.event.special[e]={setup:function(){return Ae(this,e,Se),!1},trigger:function(){return Ae(this,e),!0},delegateType:t}}),S.each({mouseenter:"mouseover",mouseleave:"mouseout",pointerenter:"pointerover",pointerleave:"pointerout"},function(e,i){S.event.special[e]={delegateType:i,bindType:i,handle:function(e){var t,n=e.relatedTarget,r=e.handleObj;return n&&(n===this||S.contains(this,n))||(e.type=r.origType,t=r.handler.apply(this,arguments),e.type=i),t}}}),S.fn.extend({on:function(e,t,n,r){return ke(this,e,t,n,r)},one:function(e,t,n,r){return ke(this,e,t,n,r,1)},off:function(e,t,n){var r,i;if(e&&e.preventDefault&&e.handleObj)return r=e.handleObj,S(e.delegateTarget).off(r.namespace?r.origType+"."+r.namespace:r.origType,r.selector,r.handler),this;if("object"==typeof e){for(i in e)this.off(i,t,e[i]);return this}return!1!==t&&"function"!=typeof t||(n=t,t=void 0),!1===n&&(n=Ee),this.each(function(){S.event.remove(this,e,n,t)})}});var Ne=/<script|<style|<link/i,De=/checked\s*(?:[^=]|=\s*.checked.)/i,je=/^\s*<!(?:\[CDATA\[|--)|(?:\]\]|--)>\s*$/g;function qe(e,t){return A(e,"table")&&A(11!==t.nodeType?t:t.firstChild,"tr")&&S(e).children("tbody")[0]||e}function Le(e){return e.type=(null!==e.getAttribute("type"))+"/"+e.type,e}function He(e){return"true/"===(e.type||"").slice(0,5)?e.type=e.type.slice(5):e.removeAttribute("type"),e}function Oe(e,t){var n,r,i,o,a,s;if(1===t.nodeType){if(Y.hasData(e)&&(s=Y.get(e).events))for(i in Y.remove(t,"handle events"),s)for(n=0,r=s[i].length;n<r;n++)S.event.add(t,i,s[i][n]);Q.hasData(e)&&(o=Q.access(e),a=S.extend({},o),Q.set(t,a))}}function Pe(n,r,i,o){r=g(r);var e,t,a,s,u,l,c=0,f=n.length,p=f-1,d=r[0],h=m(d);if(h||1<f&&"string"==typeof d&&!y.checkClone&&De.test(d))return n.each(function(e){var t=n.eq(e);h&&(r[0]=d.call(this,e,t.html())),Pe(t,r,i,o)});if(f&&(t=(e=xe(r,n[0].ownerDocument,!1,n,o)).firstChild,1===e.childNodes.length&&(e=t),t||o)){for(s=(a=S.map(ve(e,"script"),Le)).length;c<f;c++)u=e,c!==p&&(u=S.clone(u,!0,!0),s&&S.merge(a,ve(u,"script"))),i.call(n[c],u,c);if(s)for(l=a[a.length-1].ownerDocument,S.map(a,He),c=0;c<s;c++)u=a[c],he.test(u.type||"")&&!Y.access(u,"globalEval")&&S.contains(l,u)&&(u.src&&"module"!==(u.type||"").toLowerCase()?S._evalUrl&&!u.noModule&&S._evalUrl(u.src,{nonce:u.nonce||u.getAttribute("nonce")},l):b(u.textContent.replace(je,""),u,l))}return n}function Re(e,t,n){for(var r,i=t?S.filter(t,e):e,o=0;null!=(r=i[o]);o++)n||1!==r.nodeType||S.cleanData(ve(r)),r.parentNode&&(n&&ie(r)&&ye(ve(r,"script")),r.parentNode.removeChild(r));return e}S.extend({htmlPrefilter:function(e){return e},clone:function(e,t,n){var r,i,o,a,s,u,l,c=e.cloneNode(!0),f=ie(e);if(!(y.noCloneChecked||1!==e.nodeType&&11!==e.nodeType||S.isXMLDoc(e)))for(a=ve(c),r=0,i=(o=ve(e)).length;r<i;r++)s=o[r],u=a[r],void 0,"input"===(l=u.nodeName.toLowerCase())&&pe.test(s.type)?u.checked=s.checked:"input"!==l&&"textarea"!==l||(u.defaultValue=s.defaultValue);if(t)if(n)for(o=o||ve(e),a=a||ve(c),r=0,i=o.length;r<i;r++)Oe(o[r],a[r]);else Oe(e,c);return 0<(a=ve(c,"script")).length&&ye(a,!f&&ve(e,"script")),c},cleanData:function(e){for(var t,n,r,i=S.event.special,o=0;void 0!==(n=e[o]);o++)if(V(n)){if(t=n[Y.expando]){if(t.events)for(r in t.events)i[r]?S.event.remove(n,r):S.removeEvent(n,r,t.handle);n[Y.expando]=void 0}n[Q.expando]&&(n[Q.expando]=void 0)}}}),S.fn.extend({detach:function(e){return Re(this,e,!0)},remove:function(e){return Re(this,e)},text:function(e){return $(this,function(e){return void 0===e?S.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 Pe(this,arguments,function(e){1!==this.nodeType&&11!==this.nodeType&&9!==this.nodeType||qe(this,e).appendChild(e)})},prepend:function(){return Pe(this,arguments,function(e){if(1===this.nodeType||11===this.nodeType||9===this.nodeType){var t=qe(this,e);t.insertBefore(e,t.firstChild)}})},before:function(){return Pe(this,arguments,function(e){this.parentNode&&this.parentNode.insertBefore(e,this)})},after:function(){return Pe(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&&(S.cleanData(ve(e,!1)),e.textContent="");return this},clone:function(e,t){return e=null!=e&&e,t=null==t?e:t,this.map(function(){return S.clone(this,e,t)})},html:function(e){return $(this,function(e){var t=this[0]||{},n=0,r=this.length;if(void 0===e&&1===t.nodeType)return t.innerHTML;if("string"==typeof e&&!Ne.test(e)&&!ge[(de.exec(e)||["",""])[1].toLowerCase()]){e=S.htmlPrefilter(e);try{for(;n<r;n++)1===(t=this[n]||{}).nodeType&&(S.cleanData(ve(t,!1)),t.innerHTML=e);t=0}catch(e){}}t&&this.empty().append(e)},null,e,arguments.length)},replaceWith:function(){var n=[];return Pe(this,arguments,function(e){var t=this.parentNode;S.inArray(this,n)<0&&(S.cleanData(ve(this)),t&&t.replaceChild(e,this))},n)}}),S.each({appendTo:"append",prependTo:"prepend",insertBefore:"before",insertAfter:"after",replaceAll:"replaceWith"},function(e,a){S.fn[e]=function(e){for(var t,n=[],r=S(e),i=r.length-1,o=0;o<=i;o++)t=o===i?this:this.clone(!0),S(r[o])[a](t),u.apply(n,t.get());return this.pushStack(n)}});var Me=new RegExp("^("+ee+")(?!px)[a-z%]+$","i"),Ie=function(e){var t=e.ownerDocument.defaultView;return t&&t.opener||(t=C),t.getComputedStyle(e)},We=function(e,t,n){var r,i,o={};for(i in t)o[i]=e.style[i],e.style[i]=t[i];for(i in r=n.call(e),t)e.style[i]=o[i];return r},Fe=new RegExp(ne.join("|"),"i");function Be(e,t,n){var r,i,o,a,s=e.style;return(n=n||Ie(e))&&(""!==(a=n.getPropertyValue(t)||n[t])||ie(e)||(a=S.style(e,t)),!y.pixelBoxStyles()&&Me.test(a)&&Fe.test(t)&&(r=s.width,i=s.minWidth,o=s.maxWidth,s.minWidth=s.maxWidth=s.width=a,a=n.width,s.width=r,s.minWidth=i,s.maxWidth=o)),void 0!==a?a+"":a}function $e(e,t){return{get:function(){if(!e())return(this.get=t).apply(this,arguments);delete this.get}}}!function(){function e(){if(l){u.style.cssText="position:absolute;left:-11111px;width:60px;margin-top:1px;padding:0;border:0",l.style.cssText="position:relative;display:block;box-sizing:border-box;overflow:scroll;margin:auto;border:1px;padding:1px;width:60%;top:1%",re.appendChild(u).appendChild(l);var e=C.getComputedStyle(l);n="1%"!==e.top,s=12===t(e.marginLeft),l.style.right="60%",o=36===t(e.right),r=36===t(e.width),l.style.position="absolute",i=12===t(l.offsetWidth/3),re.removeChild(u),l=null}}function t(e){return Math.round(parseFloat(e))}var n,r,i,o,a,s,u=E.createElement("div"),l=E.createElement("div");l.style&&(l.style.backgroundClip="content-box",l.cloneNode(!0).style.backgroundClip="",y.clearCloneStyle="content-box"===l.style.backgroundClip,S.extend(y,{boxSizingReliable:function(){return e(),r},pixelBoxStyles:function(){return e(),o},pixelPosition:function(){return e(),n},reliableMarginLeft:function(){return e(),s},scrollboxSize:function(){return e(),i},reliableTrDimensions:function(){var e,t,n,r;return null==a&&(e=E.createElement("table"),t=E.createElement("tr"),n=E.createElement("div"),e.style.cssText="position:absolute;left:-11111px",t.style.height="1px",n.style.height="9px",re.appendChild(e).appendChild(t).appendChild(n),r=C.getComputedStyle(t),a=3<parseInt(r.height),re.removeChild(e)),a}}))}();var _e=["Webkit","Moz","ms"],ze=E.createElement("div").style,Ue={};function Xe(e){var t=S.cssProps[e]||Ue[e];return t||(e in ze?e:Ue[e]=function(e){var t=e[0].toUpperCase()+e.slice(1),n=_e.length;while(n--)if((e=_e[n]+t)in ze)return e}(e)||e)}var Ve=/^(none|table(?!-c[ea]).+)/,Ge=/^--/,Ye={position:"absolute",visibility:"hidden",display:"block"},Qe={letterSpacing:"0",fontWeight:"400"};function Je(e,t,n){var r=te.exec(t);return r?Math.max(0,r[2]-(n||0))+(r[3]||"px"):t}function Ke(e,t,n,r,i,o){var a="width"===t?1:0,s=0,u=0;if(n===(r?"border":"content"))return 0;for(;a<4;a+=2)"margin"===n&&(u+=S.css(e,n+ne[a],!0,i)),r?("content"===n&&(u-=S.css(e,"padding"+ne[a],!0,i)),"margin"!==n&&(u-=S.css(e,"border"+ne[a]+"Width",!0,i))):(u+=S.css(e,"padding"+ne[a],!0,i),"padding"!==n?u+=S.css(e,"border"+ne[a]+"Width",!0,i):s+=S.css(e,"border"+ne[a]+"Width",!0,i));return!r&&0<=o&&(u+=Math.max(0,Math.ceil(e["offset"+t[0].toUpperCase()+t.slice(1)]-o-u-s-.5))||0),u}function Ze(e,t,n){var r=Ie(e),i=(!y.boxSizingReliable()||n)&&"border-box"===S.css(e,"boxSizing",!1,r),o=i,a=Be(e,t,r),s="offset"+t[0].toUpperCase()+t.slice(1);if(Me.test(a)){if(!n)return a;a="auto"}return(!y.boxSizingReliable()&&i||!y.reliableTrDimensions()&&A(e,"tr")||"auto"===a||!parseFloat(a)&&"inline"===S.css(e,"display",!1,r))&&e.getClientRects().length&&(i="border-box"===S.css(e,"boxSizing",!1,r),(o=s in e)&&(a=e[s])),(a=parseFloat(a)||0)+Ke(e,t,n||(i?"border":"content"),o,r,a)+"px"}function et(e,t,n,r,i){return new et.prototype.init(e,t,n,r,i)}S.extend({cssHooks:{opacity:{get:function(e,t){if(t){var n=Be(e,"opacity");return""===n?"1":n}}}},cssNumber:{animationIterationCount:!0,columnCount:!0,fillOpacity:!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,widows:!0,zIndex:!0,zoom:!0},cssProps:{},style:function(e,t,n,r){if(e&&3!==e.nodeType&&8!==e.nodeType&&e.style){var i,o,a,s=X(t),u=Ge.test(t),l=e.style;if(u||(t=Xe(s)),a=S.cssHooks[t]||S.cssHooks[s],void 0===n)return a&&"get"in a&&void 0!==(i=a.get(e,!1,r))?i:l[t];"string"===(o=typeof n)&&(i=te.exec(n))&&i[1]&&(n=se(e,t,i),o="number"),null!=n&&n==n&&("number"!==o||u||(n+=i&&i[3]||(S.cssNumber[s]?"":"px")),y.clearCloneStyle||""!==n||0!==t.indexOf("background")||(l[t]="inherit"),a&&"set"in a&&void 0===(n=a.set(e,n,r))||(u?l.setProperty(t,n):l[t]=n))}},css:function(e,t,n,r){var i,o,a,s=X(t);return Ge.test(t)||(t=Xe(s)),(a=S.cssHooks[t]||S.cssHooks[s])&&"get"in a&&(i=a.get(e,!0,n)),void 0===i&&(i=Be(e,t,r)),"normal"===i&&t in Qe&&(i=Qe[t]),""===n||n?(o=parseFloat(i),!0===n||isFinite(o)?o||0:i):i}}),S.each(["height","width"],function(e,u){S.cssHooks[u]={get:function(e,t,n){if(t)return!Ve.test(S.css(e,"display"))||e.getClientRects().length&&e.getBoundingClientRect().width?Ze(e,u,n):We(e,Ye,function(){return Ze(e,u,n)})},set:function(e,t,n){var r,i=Ie(e),o=!y.scrollboxSize()&&"absolute"===i.position,a=(o||n)&&"border-box"===S.css(e,"boxSizing",!1,i),s=n?Ke(e,u,n,a,i):0;return a&&o&&(s-=Math.ceil(e["offset"+u[0].toUpperCase()+u.slice(1)]-parseFloat(i[u])-Ke(e,u,"border",!1,i)-.5)),s&&(r=te.exec(t))&&"px"!==(r[3]||"px")&&(e.style[u]=t,t=S.css(e,u)),Je(0,t,s)}}}),S.cssHooks.marginLeft=$e(y.reliableMarginLeft,function(e,t){if(t)return(parseFloat(Be(e,"marginLeft"))||e.getBoundingClientRect().left-We(e,{marginLeft:0},function(){return e.getBoundingClientRect().left}))+"px"}),S.each({margin:"",padding:"",border:"Width"},function(i,o){S.cssHooks[i+o]={expand:function(e){for(var t=0,n={},r="string"==typeof e?e.split(" "):[e];t<4;t++)n[i+ne[t]+o]=r[t]||r[t-2]||r[0];return n}},"margin"!==i&&(S.cssHooks[i+o].set=Je)}),S.fn.extend({css:function(e,t){return $(this,function(e,t,n){var r,i,o={},a=0;if(Array.isArray(t)){for(r=Ie(e),i=t.length;a<i;a++)o[t[a]]=S.css(e,t[a],!1,r);return o}return void 0!==n?S.style(e,t,n):S.css(e,t)},e,t,1<arguments.length)}}),((S.Tween=et).prototype={constructor:et,init:function(e,t,n,r,i,o){this.elem=e,this.prop=n,this.easing=i||S.easing._default,this.options=t,this.start=this.now=this.cur(),this.end=r,this.unit=o||(S.cssNumber[n]?"":"px")},cur:function(){var e=et.propHooks[this.prop];return e&&e.get?e.get(this):et.propHooks._default.get(this)},run:function(e){var t,n=et.propHooks[this.prop];return this.options.duration?this.pos=t=S.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),n&&n.set?n.set(this):et.propHooks._default.set(this),this}}).init.prototype=et.prototype,(et.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=S.css(e.elem,e.prop,""))&&"auto"!==t?t:0},set:function(e){S.fx.step[e.prop]?S.fx.step[e.prop](e):1!==e.elem.nodeType||!S.cssHooks[e.prop]&&null==e.elem.style[Xe(e.prop)]?e.elem[e.prop]=e.now:S.style(e.elem,e.prop,e.now+e.unit)}}}).scrollTop=et.propHooks.scrollLeft={set:function(e){e.elem.nodeType&&e.elem.parentNode&&(e.elem[e.prop]=e.now)}},S.easing={linear:function(e){return e},swing:function(e){return.5-Math.cos(e*Math.PI)/2},_default:"swing"},S.fx=et.prototype.init,S.fx.step={};var tt,nt,rt,it,ot=/^(?:toggle|show|hide)$/,at=/queueHooks$/;function st(){nt&&(!1===E.hidden&&C.requestAnimationFrame?C.requestAnimationFrame(st):C.setTimeout(st,S.fx.interval),S.fx.tick())}function ut(){return C.setTimeout(function(){tt=void 0}),tt=Date.now()}function lt(e,t){var n,r=0,i={height:e};for(t=t?1:0;r<4;r+=2-t)i["margin"+(n=ne[r])]=i["padding"+n]=e;return t&&(i.opacity=i.width=e),i}function ct(e,t,n){for(var r,i=(ft.tweeners[t]||[]).concat(ft.tweeners["*"]),o=0,a=i.length;o<a;o++)if(r=i[o].call(n,t,e))return r}function ft(o,e,t){var n,a,r=0,i=ft.prefilters.length,s=S.Deferred().always(function(){delete u.elem}),u=function(){if(a)return!1;for(var e=tt||ut(),t=Math.max(0,l.startTime+l.duration-e),n=1-(t/l.duration||0),r=0,i=l.tweens.length;r<i;r++)l.tweens[r].run(n);return s.notifyWith(o,[l,n,t]),n<1&&i?t:(i||s.notifyWith(o,[l,1,0]),s.resolveWith(o,[l]),!1)},l=s.promise({elem:o,props:S.extend({},e),opts:S.extend(!0,{specialEasing:{},easing:S.easing._default},t),originalProperties:e,originalOptions:t,startTime:tt||ut(),duration:t.duration,tweens:[],createTween:function(e,t){var n=S.Tween(o,l.opts,e,t,l.opts.specialEasing[e]||l.opts.easing);return l.tweens.push(n),n},stop:function(e){var t=0,n=e?l.tweens.length:0;if(a)return this;for(a=!0;t<n;t++)l.tweens[t].run(1);return e?(s.notifyWith(o,[l,1,0]),s.resolveWith(o,[l,e])):s.rejectWith(o,[l,e]),this}}),c=l.props;for(!function(e,t){var n,r,i,o,a;for(n in e)if(i=t[r=X(n)],o=e[n],Array.isArray(o)&&(i=o[1],o=e[n]=o[0]),n!==r&&(e[r]=o,delete e[n]),(a=S.cssHooks[r])&&"expand"in a)for(n in o=a.expand(o),delete e[r],o)n in e||(e[n]=o[n],t[n]=i);else t[r]=i}(c,l.opts.specialEasing);r<i;r++)if(n=ft.prefilters[r].call(l,o,c,l.opts))return m(n.stop)&&(S._queueHooks(l.elem,l.opts.queue).stop=n.stop.bind(n)),n;return S.map(c,ct,l),m(l.opts.start)&&l.opts.start.call(o,l),l.progress(l.opts.progress).done(l.opts.done,l.opts.complete).fail(l.opts.fail).always(l.opts.always),S.fx.timer(S.extend(u,{elem:o,anim:l,queue:l.opts.queue})),l}S.Animation=S.extend(ft,{tweeners:{"*":[function(e,t){var n=this.createTween(e,t);return se(n.elem,e,te.exec(t),n),n}]},tweener:function(e,t){m(e)?(t=e,e=["*"]):e=e.match(P);for(var n,r=0,i=e.length;r<i;r++)n=e[r],ft.tweeners[n]=ft.tweeners[n]||[],ft.tweeners[n].unshift(t)},prefilters:[function(e,t,n){var r,i,o,a,s,u,l,c,f="width"in t||"height"in t,p=this,d={},h=e.style,g=e.nodeType&&ae(e),v=Y.get(e,"fxshow");for(r in n.queue||(null==(a=S._queueHooks(e,"fx")).unqueued&&(a.unqueued=0,s=a.empty.fire,a.empty.fire=function(){a.unqueued||s()}),a.unqueued++,p.always(function(){p.always(function(){a.unqueued--,S.queue(e,"fx").length||a.empty.fire()})})),t)if(i=t[r],ot.test(i)){if(delete t[r],o=o||"toggle"===i,i===(g?"hide":"show")){if("show"!==i||!v||void 0===v[r])continue;g=!0}d[r]=v&&v[r]||S.style(e,r)}if((u=!S.isEmptyObject(t))||!S.isEmptyObject(d))for(r in f&&1===e.nodeType&&(n.overflow=[h.overflow,h.overflowX,h.overflowY],null==(l=v&&v.display)&&(l=Y.get(e,"display")),"none"===(c=S.css(e,"display"))&&(l?c=l:(le([e],!0),l=e.style.display||l,c=S.css(e,"display"),le([e]))),("inline"===c||"inline-block"===c&&null!=l)&&"none"===S.css(e,"float")&&(u||(p.done(function(){h.display=l}),null==l&&(c=h.display,l="none"===c?"":c)),h.display="inline-block")),n.overflow&&(h.overflow="hidden",p.always(function(){h.overflow=n.overflow[0],h.overflowX=n.overflow[1],h.overflowY=n.overflow[2]})),u=!1,d)u||(v?"hidden"in v&&(g=v.hidden):v=Y.access(e,"fxshow",{display:l}),o&&(v.hidden=!g),g&&le([e],!0),p.done(function(){for(r in g||le([e]),Y.remove(e,"fxshow"),d)S.style(e,r,d[r])})),u=ct(g?v[r]:0,r,p),r in v||(v[r]=u.start,g&&(u.end=u.start,u.start=0))}],prefilter:function(e,t){t?ft.prefilters.unshift(e):ft.prefilters.push(e)}}),S.speed=function(e,t,n){var r=e&&"object"==typeof e?S.extend({},e):{complete:n||!n&&t||m(e)&&e,duration:e,easing:n&&t||t&&!m(t)&&t};return S.fx.off?r.duration=0:"number"!=typeof r.duration&&(r.duration in S.fx.speeds?r.duration=S.fx.speeds[r.duration]:r.duration=S.fx.speeds._default),null!=r.queue&&!0!==r.queue||(r.queue="fx"),r.old=r.complete,r.complete=function(){m(r.old)&&r.old.call(this),r.queue&&S.dequeue(this,r.queue)},r},S.fn.extend({fadeTo:function(e,t,n,r){return this.filter(ae).css("opacity",0).show().end().animate({opacity:t},e,n,r)},animate:function(t,e,n,r){var i=S.isEmptyObject(t),o=S.speed(e,n,r),a=function(){var e=ft(this,S.extend({},t),o);(i||Y.get(this,"finish"))&&e.stop(!0)};return a.finish=a,i||!1===o.queue?this.each(a):this.queue(o.queue,a)},stop:function(i,e,o){var a=function(e){var t=e.stop;delete e.stop,t(o)};return"string"!=typeof i&&(o=e,e=i,i=void 0),e&&this.queue(i||"fx",[]),this.each(function(){var e=!0,t=null!=i&&i+"queueHooks",n=S.timers,r=Y.get(this);if(t)r[t]&&r[t].stop&&a(r[t]);else for(t in r)r[t]&&r[t].stop&&at.test(t)&&a(r[t]);for(t=n.length;t--;)n[t].elem!==this||null!=i&&n[t].queue!==i||(n[t].anim.stop(o),e=!1,n.splice(t,1));!e&&o||S.dequeue(this,i)})},finish:function(a){return!1!==a&&(a=a||"fx"),this.each(function(){var e,t=Y.get(this),n=t[a+"queue"],r=t[a+"queueHooks"],i=S.timers,o=n?n.length:0;for(t.finish=!0,S.queue(this,a,[]),r&&r.stop&&r.stop.call(this,!0),e=i.length;e--;)i[e].elem===this&&i[e].queue===a&&(i[e].anim.stop(!0),i.splice(e,1));for(e=0;e<o;e++)n[e]&&n[e].finish&&n[e].finish.call(this);delete t.finish})}}),S.each(["toggle","show","hide"],function(e,r){var i=S.fn[r];S.fn[r]=function(e,t,n){return null==e||"boolean"==typeof e?i.apply(this,arguments):this.animate(lt(r,!0),e,t,n)}}),S.each({slideDown:lt("show"),slideUp:lt("hide"),slideToggle:lt("toggle"),fadeIn:{opacity:"show"},fadeOut:{opacity:"hide"},fadeToggle:{opacity:"toggle"}},function(e,r){S.fn[e]=function(e,t,n){return this.animate(r,e,t,n)}}),S.timers=[],S.fx.tick=function(){var e,t=0,n=S.timers;for(tt=Date.now();t<n.length;t++)(e=n[t])()||n[t]!==e||n.splice(t--,1);n.length||S.fx.stop(),tt=void 0},S.fx.timer=function(e){S.timers.push(e),S.fx.start()},S.fx.interval=13,S.fx.start=function(){nt||(nt=!0,st())},S.fx.stop=function(){nt=null},S.fx.speeds={slow:600,fast:200,_default:400},S.fn.delay=function(r,e){return r=S.fx&&S.fx.speeds[r]||r,e=e||"fx",this.queue(e,function(e,t){var n=C.setTimeout(e,r);t.stop=function(){C.clearTimeout(n)}})},rt=E.createElement("input"),it=E.createElement("select").appendChild(E.createElement("option")),rt.type="checkbox",y.checkOn=""!==rt.value,y.optSelected=it.selected,(rt=E.createElement("input")).value="t",rt.type="radio",y.radioValue="t"===rt.value;var pt,dt=S.expr.attrHandle;S.fn.extend({attr:function(e,t){return $(this,S.attr,e,t,1<arguments.length)},removeAttr:function(e){return this.each(function(){S.removeAttr(this,e)})}}),S.extend({attr:function(e,t,n){var r,i,o=e.nodeType;if(3!==o&&8!==o&&2!==o)return"undefined"==typeof e.getAttribute?S.prop(e,t,n):(1===o&&S.isXMLDoc(e)||(i=S.attrHooks[t.toLowerCase()]||(S.expr.match.bool.test(t)?pt:void 0)),void 0!==n?null===n?void S.removeAttr(e,t):i&&"set"in i&&void 0!==(r=i.set(e,n,t))?r:(e.setAttribute(t,n+""),n):i&&"get"in i&&null!==(r=i.get(e,t))?r:null==(r=S.find.attr(e,t))?void 0:r)},attrHooks:{type:{set:function(e,t){if(!y.radioValue&&"radio"===t&&A(e,"input")){var n=e.value;return e.setAttribute("type",t),n&&(e.value=n),t}}}},removeAttr:function(e,t){var n,r=0,i=t&&t.match(P);if(i&&1===e.nodeType)while(n=i[r++])e.removeAttribute(n)}}),pt={set:function(e,t,n){return!1===t?S.removeAttr(e,n):e.setAttribute(n,n),n}},S.each(S.expr.match.bool.source.match(/\w+/g),function(e,t){var a=dt[t]||S.find.attr;dt[t]=function(e,t,n){var r,i,o=t.toLowerCase();return n||(i=dt[o],dt[o]=r,r=null!=a(e,t,n)?o:null,dt[o]=i),r}});var ht=/^(?:input|select|textarea|button)$/i,gt=/^(?:a|area)$/i;function vt(e){return(e.match(P)||[]).join(" ")}function yt(e){return e.getAttribute&&e.getAttribute("class")||""}function mt(e){return Array.isArray(e)?e:"string"==typeof e&&e.match(P)||[]}S.fn.extend({prop:function(e,t){return $(this,S.prop,e,t,1<arguments.length)},removeProp:function(e){return this.each(function(){delete this[S.propFix[e]||e]})}}),S.extend({prop:function(e,t,n){var r,i,o=e.nodeType;if(3!==o&&8!==o&&2!==o)return 1===o&&S.isXMLDoc(e)||(t=S.propFix[t]||t,i=S.propHooks[t]),void 0!==n?i&&"set"in i&&void 0!==(r=i.set(e,n,t))?r:e[t]=n:i&&"get"in i&&null!==(r=i.get(e,t))?r:e[t]},propHooks:{tabIndex:{get:function(e){var t=S.find.attr(e,"tabindex");return t?parseInt(t,10):ht.test(e.nodeName)||gt.test(e.nodeName)&&e.href?0:-1}}},propFix:{"for":"htmlFor","class":"className"}}),y.optSelected||(S.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)}}),S.each(["tabIndex","readOnly","maxLength","cellSpacing","cellPadding","rowSpan","colSpan","useMap","frameBorder","contentEditable"],function(){S.propFix[this.toLowerCase()]=this}),S.fn.extend({addClass:function(t){var e,n,r,i,o,a,s,u=0;if(m(t))return this.each(function(e){S(this).addClass(t.call(this,e,yt(this)))});if((e=mt(t)).length)while(n=this[u++])if(i=yt(n),r=1===n.nodeType&&" "+vt(i)+" "){a=0;while(o=e[a++])r.indexOf(" "+o+" ")<0&&(r+=o+" ");i!==(s=vt(r))&&n.setAttribute("class",s)}return this},removeClass:function(t){var e,n,r,i,o,a,s,u=0;if(m(t))return this.each(function(e){S(this).removeClass(t.call(this,e,yt(this)))});if(!arguments.length)return this.attr("class","");if((e=mt(t)).length)while(n=this[u++])if(i=yt(n),r=1===n.nodeType&&" "+vt(i)+" "){a=0;while(o=e[a++])while(-1<r.indexOf(" "+o+" "))r=r.replace(" "+o+" "," ");i!==(s=vt(r))&&n.setAttribute("class",s)}return this},toggleClass:function(i,t){var o=typeof i,a="string"===o||Array.isArray(i);return"boolean"==typeof t&&a?t?this.addClass(i):this.removeClass(i):m(i)?this.each(function(e){S(this).toggleClass(i.call(this,e,yt(this),t),t)}):this.each(function(){var e,t,n,r;if(a){t=0,n=S(this),r=mt(i);while(e=r[t++])n.hasClass(e)?n.removeClass(e):n.addClass(e)}else void 0!==i&&"boolean"!==o||((e=yt(this))&&Y.set(this,"__className__",e),this.setAttribute&&this.setAttribute("class",e||!1===i?"":Y.get(this,"__className__")||""))})},hasClass:function(e){var t,n,r=0;t=" "+e+" ";while(n=this[r++])if(1===n.nodeType&&-1<(" "+vt(yt(n))+" ").indexOf(t))return!0;return!1}});var xt=/\r/g;S.fn.extend({val:function(n){var r,e,i,t=this[0];return arguments.length?(i=m(n),this.each(function(e){var t;1===this.nodeType&&(null==(t=i?n.call(this,e,S(this).val()):n)?t="":"number"==typeof t?t+="":Array.isArray(t)&&(t=S.map(t,function(e){return null==e?"":e+""})),(r=S.valHooks[this.type]||S.valHooks[this.nodeName.toLowerCase()])&&"set"in r&&void 0!==r.set(this,t,"value")||(this.value=t))})):t?(r=S.valHooks[t.type]||S.valHooks[t.nodeName.toLowerCase()])&&"get"in r&&void 0!==(e=r.get(t,"value"))?e:"string"==typeof(e=t.value)?e.replace(xt,""):null==e?"":e:void 0}}),S.extend({valHooks:{option:{get:function(e){var t=S.find.attr(e,"value");return null!=t?t:vt(S.text(e))}},select:{get:function(e){var t,n,r,i=e.options,o=e.selectedIndex,a="select-one"===e.type,s=a?null:[],u=a?o+1:i.length;for(r=o<0?u:a?o:0;r<u;r++)if(((n=i[r]).selected||r===o)&&!n.disabled&&(!n.parentNode.disabled||!A(n.parentNode,"optgroup"))){if(t=S(n).val(),a)return t;s.push(t)}return s},set:function(e,t){var n,r,i=e.options,o=S.makeArray(t),a=i.length;while(a--)((r=i[a]).selected=-1<S.inArray(S.valHooks.option.get(r),o))&&(n=!0);return n||(e.selectedIndex=-1),o}}}}),S.each(["radio","checkbox"],function(){S.valHooks[this]={set:function(e,t){if(Array.isArray(t))return e.checked=-1<S.inArray(S(e).val(),t)}},y.checkOn||(S.valHooks[this].get=function(e){return null===e.getAttribute("value")?"on":e.value})}),y.focusin="onfocusin"in C;var bt=/^(?:focusinfocus|focusoutblur)$/,wt=function(e){e.stopPropagation()};S.extend(S.event,{trigger:function(e,t,n,r){var i,o,a,s,u,l,c,f,p=[n||E],d=v.call(e,"type")?e.type:e,h=v.call(e,"namespace")?e.namespace.split("."):[];if(o=f=a=n=n||E,3!==n.nodeType&&8!==n.nodeType&&!bt.test(d+S.event.triggered)&&(-1<d.indexOf(".")&&(d=(h=d.split(".")).shift(),h.sort()),u=d.indexOf(":")<0&&"on"+d,(e=e[S.expando]?e:new S.Event(d,"object"==typeof e&&e)).isTrigger=r?2:3,e.namespace=h.join("."),e.rnamespace=e.namespace?new RegExp("(^|\\.)"+h.join("\\.(?:.*\\.|)")+"(\\.|$)"):null,e.result=void 0,e.target||(e.target=n),t=null==t?[e]:S.makeArray(t,[e]),c=S.event.special[d]||{},r||!c.trigger||!1!==c.trigger.apply(n,t))){if(!r&&!c.noBubble&&!x(n)){for(s=c.delegateType||d,bt.test(s+d)||(o=o.parentNode);o;o=o.parentNode)p.push(o),a=o;a===(n.ownerDocument||E)&&p.push(a.defaultView||a.parentWindow||C)}i=0;while((o=p[i++])&&!e.isPropagationStopped())f=o,e.type=1<i?s:c.bindType||d,(l=(Y.get(o,"events")||Object.create(null))[e.type]&&Y.get(o,"handle"))&&l.apply(o,t),(l=u&&o[u])&&l.apply&&V(o)&&(e.result=l.apply(o,t),!1===e.result&&e.preventDefault());return e.type=d,r||e.isDefaultPrevented()||c._default&&!1!==c._default.apply(p.pop(),t)||!V(n)||u&&m(n[d])&&!x(n)&&((a=n[u])&&(n[u]=null),S.event.triggered=d,e.isPropagationStopped()&&f.addEventListener(d,wt),n[d](),e.isPropagationStopped()&&f.removeEventListener(d,wt),S.event.triggered=void 0,a&&(n[u]=a)),e.result}},simulate:function(e,t,n){var r=S.extend(new S.Event,n,{type:e,isSimulated:!0});S.event.trigger(r,null,t)}}),S.fn.extend({trigger:function(e,t){return this.each(function(){S.event.trigger(e,t,this)})},triggerHandler:function(e,t){var n=this[0];if(n)return S.event.trigger(e,t,n,!0)}}),y.focusin||S.each({focus:"focusin",blur:"focusout"},function(n,r){var i=function(e){S.event.simulate(r,e.target,S.event.fix(e))};S.event.special[r]={setup:function(){var e=this.ownerDocument||this.document||this,t=Y.access(e,r);t||e.addEventListener(n,i,!0),Y.access(e,r,(t||0)+1)},teardown:function(){var e=this.ownerDocument||this.document||this,t=Y.access(e,r)-1;t?Y.access(e,r,t):(e.removeEventListener(n,i,!0),Y.remove(e,r))}}});var Tt=C.location,Ct={guid:Date.now()},Et=/\?/;S.parseXML=function(e){var t;if(!e||"string"!=typeof e)return null;try{t=(new C.DOMParser).parseFromString(e,"text/xml")}catch(e){t=void 0}return t&&!t.getElementsByTagName("parsererror").length||S.error("Invalid XML: "+e),t};var St=/\[\]$/,kt=/\r?\n/g,At=/^(?:submit|button|image|reset|file)$/i,Nt=/^(?:input|select|textarea|keygen)/i;function Dt(n,e,r,i){var t;if(Array.isArray(e))S.each(e,function(e,t){r||St.test(n)?i(n,t):Dt(n+"["+("object"==typeof t&&null!=t?e:"")+"]",t,r,i)});else if(r||"object"!==w(e))i(n,e);else for(t in e)Dt(n+"["+t+"]",e[t],r,i)}S.param=function(e,t){var n,r=[],i=function(e,t){var n=m(t)?t():t;r[r.length]=encodeURIComponent(e)+"="+encodeURIComponent(null==n?"":n)};if(null==e)return"";if(Array.isArray(e)||e.jquery&&!S.isPlainObject(e))S.each(e,function(){i(this.name,this.value)});else for(n in e)Dt(n,e[n],t,i);return r.join("&")},S.fn.extend({serialize:function(){return S.param(this.serializeArray())},serializeArray:function(){return this.map(function(){var e=S.prop(this,"elements");return e?S.makeArray(e):this}).filter(function(){var e=this.type;return this.name&&!S(this).is(":disabled")&&Nt.test(this.nodeName)&&!At.test(e)&&(this.checked||!pe.test(e))}).map(function(e,t){var n=S(this).val();return null==n?null:Array.isArray(n)?S.map(n,function(e){return{name:t.name,value:e.replace(kt,"\r\n")}}):{name:t.name,value:n.replace(kt,"\r\n")}}).get()}});var jt=/%20/g,qt=/#.*$/,Lt=/([?&])_=[^&]*/,Ht=/^(.*?):[ \t]*([^\r\n]*)$/gm,Ot=/^(?:GET|HEAD)$/,Pt=/^\/\//,Rt={},Mt={},It="*/".concat("*"),Wt=E.createElement("a");function Ft(o){return function(e,t){"string"!=typeof e&&(t=e,e="*");var n,r=0,i=e.toLowerCase().match(P)||[];if(m(t))while(n=i[r++])"+"===n[0]?(n=n.slice(1)||"*",(o[n]=o[n]||[]).unshift(t)):(o[n]=o[n]||[]).push(t)}}function Bt(t,i,o,a){var s={},u=t===Mt;function l(e){var r;return s[e]=!0,S.each(t[e]||[],function(e,t){var n=t(i,o,a);return"string"!=typeof n||u||s[n]?u?!(r=n):void 0:(i.dataTypes.unshift(n),l(n),!1)}),r}return l(i.dataTypes[0])||!s["*"]&&l("*")}function $t(e,t){var n,r,i=S.ajaxSettings.flatOptions||{};for(n in t)void 0!==t[n]&&((i[n]?e:r||(r={}))[n]=t[n]);return r&&S.extend(!0,e,r),e}Wt.href=Tt.href,S.extend({active:0,lastModified:{},etag:{},ajaxSettings:{url:Tt.href,type:"GET",isLocal:/^(?:about|app|app-storage|.+-extension|file|res|widget):$/.test(Tt.protocol),global:!0,processData:!0,async:!0,contentType:"application/x-www-form-urlencoded; charset=UTF-8",accepts:{"*":It,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":S.parseXML},flatOptions:{url:!0,context:!0}},ajaxSetup:function(e,t){return t?$t($t(e,S.ajaxSettings),t):$t(S.ajaxSettings,e)},ajaxPrefilter:Ft(Rt),ajaxTransport:Ft(Mt),ajax:function(e,t){"object"==typeof e&&(t=e,e=void 0),t=t||{};var c,f,p,n,d,r,h,g,i,o,v=S.ajaxSetup({},t),y=v.context||v,m=v.context&&(y.nodeType||y.jquery)?S(y):S.event,x=S.Deferred(),b=S.Callbacks("once memory"),w=v.statusCode||{},a={},s={},u="canceled",T={readyState:0,getResponseHeader:function(e){var t;if(h){if(!n){n={};while(t=Ht.exec(p))n[t[1].toLowerCase()+" "]=(n[t[1].toLowerCase()+" "]||[]).concat(t[2])}t=n[e.toLowerCase()+" "]}return null==t?null:t.join(", ")},getAllResponseHeaders:function(){return h?p:null},setRequestHeader:function(e,t){return null==h&&(e=s[e.toLowerCase()]=s[e.toLowerCase()]||e,a[e]=t),this},overrideMimeType:function(e){return null==h&&(v.mimeType=e),this},statusCode:function(e){var t;if(e)if(h)T.always(e[T.status]);else for(t in e)w[t]=[w[t],e[t]];return this},abort:function(e){var t=e||u;return c&&c.abort(t),l(0,t),this}};if(x.promise(T),v.url=((e||v.url||Tt.href)+"").replace(Pt,Tt.protocol+"//"),v.type=t.method||t.type||v.method||v.type,v.dataTypes=(v.dataType||"*").toLowerCase().match(P)||[""],null==v.crossDomain){r=E.createElement("a");try{r.href=v.url,r.href=r.href,v.crossDomain=Wt.protocol+"//"+Wt.host!=r.protocol+"//"+r.host}catch(e){v.crossDomain=!0}}if(v.data&&v.processData&&"string"!=typeof v.data&&(v.data=S.param(v.data,v.traditional)),Bt(Rt,v,t,T),h)return T;for(i in(g=S.event&&v.global)&&0==S.active++&&S.event.trigger("ajaxStart"),v.type=v.type.toUpperCase(),v.hasContent=!Ot.test(v.type),f=v.url.replace(qt,""),v.hasContent?v.data&&v.processData&&0===(v.contentType||"").indexOf("application/x-www-form-urlencoded")&&(v.data=v.data.replace(jt,"+")):(o=v.url.slice(f.length),v.data&&(v.processData||"string"==typeof v.data)&&(f+=(Et.test(f)?"&":"?")+v.data,delete v.data),!1===v.cache&&(f=f.replace(Lt,"$1"),o=(Et.test(f)?"&":"?")+"_="+Ct.guid+++o),v.url=f+o),v.ifModified&&(S.lastModified[f]&&T.setRequestHeader("If-Modified-Since",S.lastModified[f]),S.etag[f]&&T.setRequestHeader("If-None-Match",S.etag[f])),(v.data&&v.hasContent&&!1!==v.contentType||t.contentType)&&T.setRequestHeader("Content-Type",v.contentType),T.setRequestHeader("Accept",v.dataTypes[0]&&v.accepts[v.dataTypes[0]]?v.accepts[v.dataTypes[0]]+("*"!==v.dataTypes[0]?", "+It+"; q=0.01":""):v.accepts["*"]),v.headers)T.setRequestHeader(i,v.headers[i]);if(v.beforeSend&&(!1===v.beforeSend.call(y,T,v)||h))return T.abort();if(u="abort",b.add(v.complete),T.done(v.success),T.fail(v.error),c=Bt(Mt,v,t,T)){if(T.readyState=1,g&&m.trigger("ajaxSend",[T,v]),h)return T;v.async&&0<v.timeout&&(d=C.setTimeout(function(){T.abort("timeout")},v.timeout));try{h=!1,c.send(a,l)}catch(e){if(h)throw e;l(-1,e)}}else l(-1,"No Transport");function l(e,t,n,r){var i,o,a,s,u,l=t;h||(h=!0,d&&C.clearTimeout(d),c=void 0,p=r||"",T.readyState=0<e?4:0,i=200<=e&&e<300||304===e,n&&(s=function(e,t,n){var r,i,o,a,s=e.contents,u=e.dataTypes;while("*"===u[0])u.shift(),void 0===r&&(r=e.mimeType||t.getResponseHeader("Content-Type"));if(r)for(i in s)if(s[i]&&s[i].test(r)){u.unshift(i);break}if(u[0]in n)o=u[0];else{for(i in n){if(!u[0]||e.converters[i+" "+u[0]]){o=i;break}a||(a=i)}o=o||a}if(o)return o!==u[0]&&u.unshift(o),n[o]}(v,T,n)),!i&&-1<S.inArray("script",v.dataTypes)&&(v.converters["text script"]=function(){}),s=function(e,t,n,r){var i,o,a,s,u,l={},c=e.dataTypes.slice();if(c[1])for(a in e.converters)l[a.toLowerCase()]=e.converters[a];o=c.shift();while(o)if(e.responseFields[o]&&(n[e.responseFields[o]]=t),!u&&r&&e.dataFilter&&(t=e.dataFilter(t,e.dataType)),u=o,o=c.shift())if("*"===o)o=u;else if("*"!==u&&u!==o){if(!(a=l[u+" "+o]||l["* "+o]))for(i in l)if((s=i.split(" "))[1]===o&&(a=l[u+" "+s[0]]||l["* "+s[0]])){!0===a?a=l[i]:!0!==l[i]&&(o=s[0],c.unshift(s[1]));break}if(!0!==a)if(a&&e["throws"])t=a(t);else try{t=a(t)}catch(e){return{state:"parsererror",error:a?e:"No conversion from "+u+" to "+o}}}return{state:"success",data:t}}(v,s,T,i),i?(v.ifModified&&((u=T.getResponseHeader("Last-Modified"))&&(S.lastModified[f]=u),(u=T.getResponseHeader("etag"))&&(S.etag[f]=u)),204===e||"HEAD"===v.type?l="nocontent":304===e?l="notmodified":(l=s.state,o=s.data,i=!(a=s.error))):(a=l,!e&&l||(l="error",e<0&&(e=0))),T.status=e,T.statusText=(t||l)+"",i?x.resolveWith(y,[o,l,T]):x.rejectWith(y,[T,l,a]),T.statusCode(w),w=void 0,g&&m.trigger(i?"ajaxSuccess":"ajaxError",[T,v,i?o:a]),b.fireWith(y,[T,l]),g&&(m.trigger("ajaxComplete",[T,v]),--S.active||S.event.trigger("ajaxStop")))}return T},getJSON:function(e,t,n){return S.get(e,t,n,"json")},getScript:function(e,t){return S.get(e,void 0,t,"script")}}),S.each(["get","post"],function(e,i){S[i]=function(e,t,n,r){return m(t)&&(r=r||n,n=t,t=void 0),S.ajax(S.extend({url:e,type:i,dataType:r,data:t,success:n},S.isPlainObject(e)&&e))}}),S.ajaxPrefilter(function(e){var t;for(t in e.headers)"content-type"===t.toLowerCase()&&(e.contentType=e.headers[t]||"")}),S._evalUrl=function(e,t,n){return S.ajax({url:e,type:"GET",dataType:"script",cache:!0,async:!1,global:!1,converters:{"text script":function(){}},dataFilter:function(e){S.globalEval(e,t,n)}})},S.fn.extend({wrapAll:function(e){var t;return this[0]&&(m(e)&&(e=e.call(this[0])),t=S(e,this[0].ownerDocument).eq(0).clone(!0),this[0].parentNode&&t.insertBefore(this[0]),t.map(function(){var e=this;while(e.firstElementChild)e=e.firstElementChild;return e}).append(this)),this},wrapInner:function(n){return m(n)?this.each(function(e){S(this).wrapInner(n.call(this,e))}):this.each(function(){var e=S(this),t=e.contents();t.length?t.wrapAll(n):e.append(n)})},wrap:function(t){var n=m(t);return this.each(function(e){S(this).wrapAll(n?t.call(this,e):t)})},unwrap:function(e){return this.parent(e).not("body").each(function(){S(this).replaceWith(this.childNodes)}),this}}),S.expr.pseudos.hidden=function(e){return!S.expr.pseudos.visible(e)},S.expr.pseudos.visible=function(e){return!!(e.offsetWidth||e.offsetHeight||e.getClientRects().length)},S.ajaxSettings.xhr=function(){try{return new C.XMLHttpRequest}catch(e){}};var _t={0:200,1223:204},zt=S.ajaxSettings.xhr();y.cors=!!zt&&"withCredentials"in zt,y.ajax=zt=!!zt,S.ajaxTransport(function(i){var o,a;if(y.cors||zt&&!i.crossDomain)return{send:function(e,t){var n,r=i.xhr();if(r.open(i.type,i.url,i.async,i.username,i.password),i.xhrFields)for(n in i.xhrFields)r[n]=i.xhrFields[n];for(n in i.mimeType&&r.overrideMimeType&&r.overrideMimeType(i.mimeType),i.crossDomain||e["X-Requested-With"]||(e["X-Requested-With"]="XMLHttpRequest"),e)r.setRequestHeader(n,e[n]);o=function(e){return function(){o&&(o=a=r.onload=r.onerror=r.onabort=r.ontimeout=r.onreadystatechange=null,"abort"===e?r.abort():"error"===e?"number"!=typeof r.status?t(0,"error"):t(r.status,r.statusText):t(_t[r.status]||r.status,r.statusText,"text"!==(r.responseType||"text")||"string"!=typeof r.responseText?{binary:r.response}:{text:r.responseText},r.getAllResponseHeaders()))}},r.onload=o(),a=r.onerror=r.ontimeout=o("error"),void 0!==r.onabort?r.onabort=a:r.onreadystatechange=function(){4===r.readyState&&C.setTimeout(function(){o&&a()})},o=o("abort");try{r.send(i.hasContent&&i.data||null)}catch(e){if(o)throw e}},abort:function(){o&&o()}}}),S.ajaxPrefilter(function(e){e.crossDomain&&(e.contents.script=!1)}),S.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 S.globalEval(e),e}}}),S.ajaxPrefilter("script",function(e){void 0===e.cache&&(e.cache=!1),e.crossDomain&&(e.type="GET")}),S.ajaxTransport("script",function(n){var r,i;if(n.crossDomain||n.scriptAttrs)return{send:function(e,t){r=S("<script>").attr(n.scriptAttrs||{}).prop({charset:n.scriptCharset,src:n.url}).on("load error",i=function(e){r.remove(),i=null,e&&t("error"===e.type?404:200,e.type)}),E.head.appendChild(r[0])},abort:function(){i&&i()}}});var Ut,Xt=[],Vt=/(=)\?(?=&|$)|\?\?/;S.ajaxSetup({jsonp:"callback",jsonpCallback:function(){var e=Xt.pop()||S.expando+"_"+Ct.guid++;return this[e]=!0,e}}),S.ajaxPrefilter("json jsonp",function(e,t,n){var r,i,o,a=!1!==e.jsonp&&(Vt.test(e.url)?"url":"string"==typeof e.data&&0===(e.contentType||"").indexOf("application/x-www-form-urlencoded")&&Vt.test(e.data)&&"data");if(a||"jsonp"===e.dataTypes[0])return r=e.jsonpCallback=m(e.jsonpCallback)?e.jsonpCallback():e.jsonpCallback,a?e[a]=e[a].replace(Vt,"$1"+r):!1!==e.jsonp&&(e.url+=(Et.test(e.url)?"&":"?")+e.jsonp+"="+r),e.converters["script json"]=function(){return o||S.error(r+" was not called"),o[0]},e.dataTypes[0]="json",i=C[r],C[r]=function(){o=arguments},n.always(function(){void 0===i?S(C).removeProp(r):C[r]=i,e[r]&&(e.jsonpCallback=t.jsonpCallback,Xt.push(r)),o&&m(i)&&i(o[0]),o=i=void 0}),"script"}),y.createHTMLDocument=((Ut=E.implementation.createHTMLDocument("").body).innerHTML="<form></form><form></form>",2===Ut.childNodes.length),S.parseHTML=function(e,t,n){return"string"!=typeof e?[]:("boolean"==typeof t&&(n=t,t=!1),t||(y.createHTMLDocument?((r=(t=E.implementation.createHTMLDocument("")).createElement("base")).href=E.location.href,t.head.appendChild(r)):t=E),o=!n&&[],(i=N.exec(e))?[t.createElement(i[1])]:(i=xe([e],t,o),o&&o.length&&S(o).remove(),S.merge([],i.childNodes)));var r,i,o},S.fn.load=function(e,t,n){var r,i,o,a=this,s=e.indexOf(" ");return-1<s&&(r=vt(e.slice(s)),e=e.slice(0,s)),m(t)?(n=t,t=void 0):t&&"object"==typeof t&&(i="POST"),0<a.length&&S.ajax({url:e,type:i||"GET",dataType:"html",data:t}).done(function(e){o=arguments,a.html(r?S("<div>").append(S.parseHTML(e)).find(r):e)}).always(n&&function(e,t){a.each(function(){n.apply(this,o||[e.responseText,t,e])})}),this},S.expr.pseudos.animated=function(t){return S.grep(S.timers,function(e){return t===e.elem}).length},S.offset={setOffset:function(e,t,n){var r,i,o,a,s,u,l=S.css(e,"position"),c=S(e),f={};"static"===l&&(e.style.position="relative"),s=c.offset(),o=S.css(e,"top"),u=S.css(e,"left"),("absolute"===l||"fixed"===l)&&-1<(o+u).indexOf("auto")?(a=(r=c.position()).top,i=r.left):(a=parseFloat(o)||0,i=parseFloat(u)||0),m(t)&&(t=t.call(e,n,S.extend({},s))),null!=t.top&&(f.top=t.top-s.top+a),null!=t.left&&(f.left=t.left-s.left+i),"using"in t?t.using.call(e,f):("number"==typeof f.top&&(f.top+="px"),"number"==typeof f.left&&(f.left+="px"),c.css(f))}},S.fn.extend({offset:function(t){if(arguments.length)return void 0===t?this:this.each(function(e){S.offset.setOffset(this,t,e)});var e,n,r=this[0];return r?r.getClientRects().length?(e=r.getBoundingClientRect(),n=r.ownerDocument.defaultView,{top:e.top+n.pageYOffset,left:e.left+n.pageXOffset}):{top:0,left:0}:void 0},position:function(){if(this[0]){var e,t,n,r=this[0],i={top:0,left:0};if("fixed"===S.css(r,"position"))t=r.getBoundingClientRect();else{t=this.offset(),n=r.ownerDocument,e=r.offsetParent||n.documentElement;while(e&&(e===n.body||e===n.documentElement)&&"static"===S.css(e,"position"))e=e.parentNode;e&&e!==r&&1===e.nodeType&&((i=S(e).offset()).top+=S.css(e,"borderTopWidth",!0),i.left+=S.css(e,"borderLeftWidth",!0))}return{top:t.top-i.top-S.css(r,"marginTop",!0),left:t.left-i.left-S.css(r,"marginLeft",!0)}}},offsetParent:function(){return this.map(function(){var e=this.offsetParent;while(e&&"static"===S.css(e,"position"))e=e.offsetParent;return e||re})}}),S.each({scrollLeft:"pageXOffset",scrollTop:"pageYOffset"},function(t,i){var o="pageYOffset"===i;S.fn[t]=function(e){return $(this,function(e,t,n){var r;if(x(e)?r=e:9===e.nodeType&&(r=e.defaultView),void 0===n)return r?r[i]:e[t];r?r.scrollTo(o?r.pageXOffset:n,o?n:r.pageYOffset):e[t]=n},t,e,arguments.length)}}),S.each(["top","left"],function(e,n){S.cssHooks[n]=$e(y.pixelPosition,function(e,t){if(t)return t=Be(e,n),Me.test(t)?S(e).position()[n]+"px":t})}),S.each({Height:"height",Width:"width"},function(a,s){S.each({padding:"inner"+a,content:s,"":"outer"+a},function(r,o){S.fn[o]=function(e,t){var n=arguments.length&&(r||"boolean"!=typeof e),i=r||(!0===e||!0===t?"margin":"border");return $(this,function(e,t,n){var r;return x(e)?0===o.indexOf("outer")?e["inner"+a]:e.document.documentElement["client"+a]:9===e.nodeType?(r=e.documentElement,Math.max(e.body["scroll"+a],r["scroll"+a],e.body["offset"+a],r["offset"+a],r["client"+a])):void 0===n?S.css(e,t,i):S.style(e,t,n,i)},s,n?e:void 0,n)}})}),S.each(["ajaxStart","ajaxStop","ajaxComplete","ajaxError","ajaxSuccess","ajaxSend"],function(e,t){S.fn[t]=function(e){return this.on(t,e)}}),S.fn.extend({bind:function(e,t,n){return this.on(e,null,t,n)},unbind:function(e,t){return this.off(e,null,t)},delegate:function(e,t,n,r){return this.on(t,e,n,r)},undelegate:function(e,t,n){return 1===arguments.length?this.off(e,"**"):this.off(t,e||"**",n)},hover:function(e,t){return this.mouseenter(e).mouseleave(t||e)}}),S.each("blur focus focusin focusout resize scroll click dblclick mousedown mouseup mousemove mouseover mouseout mouseenter mouseleave change select submit keydown keypress keyup contextmenu".split(" "),function(e,n){S.fn[n]=function(e,t){return 0<arguments.length?this.on(n,null,e,t):this.trigger(n)}});var Gt=/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g;S.proxy=function(e,t){var n,r,i;if("string"==typeof t&&(n=e[t],t=e,e=n),m(e))return r=s.call(arguments,2),(i=function(){return e.apply(t||this,r.concat(s.call(arguments)))}).guid=e.guid=e.guid||S.guid++,i},S.holdReady=function(e){e?S.readyWait++:S.ready(!0)},S.isArray=Array.isArray,S.parseJSON=JSON.parse,S.nodeName=A,S.isFunction=m,S.isWindow=x,S.camelCase=X,S.type=w,S.now=Date.now,S.isNumeric=function(e){var t=S.type(e);return("number"===t||"string"===t)&&!isNaN(e-parseFloat(e))},S.trim=function(e){return null==e?"":(e+"").replace(Gt,"")},"function"==typeof define&&define.amd&&define("jquery",[],function(){return S});var Yt=C.jQuery,Qt=C.$;return S.noConflict=function(e){return C.$===S&&(C.$=Qt),e&&C.jQuery===S&&(C.jQuery=Yt),S},"undefined"==typeof e&&(C.jQuery=C.$=S),S}); +;/*! jQuery Migrate v3.3.0 | (c) OpenJS Foundation and other contributors | jquery.org/license */ +"undefined"==typeof jQuery.migrateMute&&(jQuery.migrateMute=!0),function(t){"use strict";"function"==typeof define&&define.amd?define(["jquery"],function(e){return t(e,window)}):"object"==typeof module&&module.exports?module.exports=t(require("jquery"),window):t(jQuery,window)}(function(s,n){"use strict";function e(e){return 0<=function(e,t){var r,n=/^(\d+)\.(\d+)\.(\d+)/,i=n.exec(e)||[],o=n.exec(t)||[];for(r=1;r<=3;r++){if(+i[r]>+o[r])return 1;if(+i[r]<+o[r])return-1}return 0}(s.fn.jquery,e)}s.migrateVersion="3.3.0",n.console&&n.console.log&&(s&&e("3.0.0")||n.console.log("JQMIGRATE: jQuery 3.0.0+ REQUIRED"),s.migrateWarnings&&n.console.log("JQMIGRATE: Migrate plugin loaded multiple times"),n.console.log("JQMIGRATE: Migrate is installed"+(s.migrateMute?"":" with logging active")+", version "+s.migrateVersion));var r={};function u(e){var t=n.console;s.migrateDeduplicateWarnings&&r[e]||(r[e]=!0,s.migrateWarnings.push(e),t&&t.warn&&!s.migrateMute&&(t.warn("JQMIGRATE: "+e),s.migrateTrace&&t.trace&&t.trace()))}function t(e,t,r,n){Object.defineProperty(e,t,{configurable:!0,enumerable:!0,get:function(){return u(n),r},set:function(e){u(n),r=e}})}function i(e,t,r,n){e[t]=function(){return u(n),r.apply(this,arguments)}}s.migrateDeduplicateWarnings=!0,s.migrateWarnings=[],void 0===s.migrateTrace&&(s.migrateTrace=!0),s.migrateReset=function(){r={},s.migrateWarnings.length=0},"BackCompat"===n.document.compatMode&&u("jQuery is not compatible with Quirks Mode");var o,a={},c=s.fn.init,d=s.find,l=/\[(\s*[-\w]+\s*)([~|^$*]?=)\s*([-\w#]*?#[-\w#]*)\s*\]/,p=/\[(\s*[-\w]+\s*)([~|^$*]?=)\s*([-\w#]*?#[-\w#]*)\s*\]/g,f=/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g;for(o in s.fn.init=function(e){var t=Array.prototype.slice.call(arguments);return"string"==typeof e&&"#"===e&&(u("jQuery( '#' ) is not a valid selector"),t[0]=[]),c.apply(this,t)},s.fn.init.prototype=s.fn,s.find=function(t){var r=Array.prototype.slice.call(arguments);if("string"==typeof t&&l.test(t))try{n.document.querySelector(t)}catch(e){t=t.replace(p,function(e,t,r,n){return"["+t+r+'"'+n+'"]'});try{n.document.querySelector(t),u("Attribute selector with '#' must be quoted: "+r[0]),r[0]=t}catch(e){u("Attribute selector with '#' was not fixed: "+r[0])}}return d.apply(this,r)},d)Object.prototype.hasOwnProperty.call(d,o)&&(s.find[o]=d[o]);if(i(s.fn,"size",function(){return this.length},"jQuery.fn.size() is deprecated and removed; use the .length property"),i(s,"parseJSON",function(){return JSON.parse.apply(null,arguments)},"jQuery.parseJSON is deprecated; use JSON.parse"),i(s,"holdReady",s.holdReady,"jQuery.holdReady is deprecated"),i(s,"unique",s.uniqueSort,"jQuery.unique is deprecated; use jQuery.uniqueSort"),t(s.expr,"filters",s.expr.pseudos,"jQuery.expr.filters is deprecated; use jQuery.expr.pseudos"),t(s.expr,":",s.expr.pseudos,"jQuery.expr[':'] is deprecated; use jQuery.expr.pseudos"),e("3.1.1")&&i(s,"trim",function(e){return null==e?"":(e+"").replace(f,"")},"jQuery.trim is deprecated; use String.prototype.trim"),e("3.2.0")&&i(s,"nodeName",function(e,t){return e.nodeName&&e.nodeName.toLowerCase()===t.toLowerCase()},"jQuery.nodeName is deprecated"),e("3.3.0")&&(i(s,"isNumeric",function(e){var t=typeof e;return("number"==t||"string"==t)&&!isNaN(e-parseFloat(e))},"jQuery.isNumeric() is deprecated"),s.each("Boolean Number String Function Array Date RegExp Object Error Symbol".split(" "),function(e,t){a["[object "+t+"]"]=t.toLowerCase()}),i(s,"type",function(e){return null==e?e+"":"object"==typeof e||"function"==typeof e?a[Object.prototype.toString.call(e)]||"object":typeof e},"jQuery.type is deprecated"),i(s,"isFunction",function(e){return"function"==typeof e},"jQuery.isFunction() is deprecated"),i(s,"isWindow",function(e){return null!=e&&e===e.window},"jQuery.isWindow() is deprecated"),i(s,"isArray",Array.isArray,"jQuery.isArray is deprecated; use Array.isArray")),s.ajax){var y=s.ajax;s.ajax=function(){var e=y.apply(this,arguments);return e.promise&&(i(e,"success",e.done,"jQXHR.success is deprecated and removed"),i(e,"error",e.fail,"jQXHR.error is deprecated and removed"),i(e,"complete",e.always,"jQXHR.complete is deprecated and removed")),e}}var m=s.fn.removeAttr,g=s.fn.toggleClass,h=/\S+/g;function v(e){return e.replace(/-([a-z])/g,function(e,t){return t.toUpperCase()})}s.fn.removeAttr=function(e){var r=this;return s.each(e.match(h),function(e,t){s.expr.match.bool.test(t)&&(u("jQuery.fn.removeAttr no longer sets boolean properties: "+t),r.prop(t,!1))}),m.apply(this,arguments)};var j,Q=!(s.fn.toggleClass=function(t){return void 0!==t&&"boolean"!=typeof t?g.apply(this,arguments):(u("jQuery.fn.toggleClass( boolean ) is deprecated"),this.each(function(){var e=this.getAttribute&&this.getAttribute("class")||"";e&&s.data(this,"__className__",e),this.setAttribute&&this.setAttribute("class",e||!1===t?"":s.data(this,"__className__")||"")}))}),b=/^[a-z]/,w=/^(?:Border(?:Top|Right|Bottom|Left)?(?:Width|)|(?:Margin|Padding)?(?:Top|Right|Bottom|Left)?|(?:Min|Max)?(?:Width|Height))$/;s.swap&&s.each(["height","width","reliableMarginRight"],function(e,t){var r=s.cssHooks[t]&&s.cssHooks[t].get;r&&(s.cssHooks[t].get=function(){var e;return Q=!0,e=r.apply(this,arguments),Q=!1,e})}),s.swap=function(e,t,r,n){var i,o,a={};for(o in Q||u("jQuery.swap() is undocumented and deprecated"),t)a[o]=e.style[o],e.style[o]=t[o];for(o in i=r.apply(e,n||[]),t)e.style[o]=a[o];return i},e("3.4.0")&&"undefined"!=typeof Proxy&&(s.cssProps=new Proxy(s.cssProps||{},{set:function(){return u("JQMIGRATE: jQuery.cssProps is deprecated"),Reflect.set.apply(this,arguments)}})),s.cssNumber||(s.cssNumber={}),j=s.fn.css,s.fn.css=function(e,t){var r=this;return"string"!=typeof e&&s.each(e,function(e,t){s.fn.css.call(r,e,t)}),"number"!=typeof t||function(e){return b.test(e)&&w.test(e[0].toUpperCase()+e.slice(1))}(v(e))||u("Use of number-typed values is deprecated in jQuery.fn.css"),j.apply(this,arguments)};var x=s.data;if(s.data=function(e,t,r){var n,i,o;if(t&&"object"==typeof t&&2===arguments.length){for(o in n=s.hasData(e)&&x.call(this,e),i={},t)o!==v(o)?(u("jQuery.data() always sets/gets camelCased names: "+o),n[o]=t[o]):i[o]=t[o];return x.call(this,e,i),t}return t&&"string"==typeof t&&t!==v(t)&&(n=s.hasData(e)&&x.call(this,e))&&t in n?(u("jQuery.data() always sets/gets camelCased names: "+t),2<arguments.length&&(n[t]=r),n[t]):x.apply(this,arguments)},s.fx){var A,k,M=s.Tween.prototype.run,S=function(e){return e};s.Tween.prototype.run=function(){1<s.easing[this.easing].length&&(u("'jQuery.easing."+this.easing.toString()+"' should use only one argument"),s.easing[this.easing]=S),M.apply(this,arguments)},A=s.fx.interval||13,k="jQuery.fx.interval is deprecated",n.requestAnimationFrame&&Object.defineProperty(s.fx,"interval",{configurable:!0,enumerable:!0,get:function(){return n.document.hidden||u(k),A},set:function(e){u(k),A=e}})}var H=s.fn.load,R=s.event.add,N=s.event.fix;s.event.props=[],s.event.fixHooks={},t(s.event.props,"concat",s.event.props.concat,"jQuery.event.props.concat() is deprecated and removed"),s.event.fix=function(e){var t,r=e.type,n=this.fixHooks[r],i=s.event.props;if(i.length){u("jQuery.event.props are deprecated and removed: "+i.join());while(i.length)s.event.addProp(i.pop())}if(n&&!n._migrated_&&(n._migrated_=!0,u("jQuery.event.fixHooks are deprecated and removed: "+r),(i=n.props)&&i.length))while(i.length)s.event.addProp(i.pop());return t=N.call(this,e),n&&n.filter?n.filter(t,e):t},s.event.add=function(e,t){return e===n&&"load"===t&&"complete"===n.document.readyState&&u("jQuery(window).on('load'...) called after load event occurred"),R.apply(this,arguments)},s.each(["load","unload","error"],function(e,t){s.fn[t]=function(){var e=Array.prototype.slice.call(arguments,0);return"load"===t&&"string"==typeof e[0]?H.apply(this,e):(u("jQuery.fn."+t+"() is deprecated"),e.splice(0,0,t),arguments.length?this.on.apply(this,e):(this.triggerHandler.apply(this,e),this))}}),s.each("blur focus focusin focusout resize scroll click dblclick mousedown mouseup mousemove mouseover mouseout mouseenter mouseleave change select submit keydown keypress keyup contextmenu".split(" "),function(e,r){s.fn[r]=function(e,t){return u("jQuery.fn."+r+"() event shorthand is deprecated"),0<arguments.length?this.on(r,null,e,t):this.trigger(r)}}),s(function(){s(n.document).triggerHandler("ready")}),s.event.special.ready={setup:function(){this===n.document&&u("'ready' event is deprecated")}},s.fn.extend({bind:function(e,t,r){return u("jQuery.fn.bind() is deprecated"),this.on(e,null,t,r)},unbind:function(e,t){return u("jQuery.fn.unbind() is deprecated"),this.off(e,null,t)},delegate:function(e,t,r,n){return u("jQuery.fn.delegate() is deprecated"),this.on(t,e,r,n)},undelegate:function(e,t,r){return u("jQuery.fn.undelegate() is deprecated"),1===arguments.length?this.off(e,"**"):this.off(t,e||"**",r)},hover:function(e,t){return u("jQuery.fn.hover() is deprecated"),this.on("mouseenter",e).on("mouseleave",t||e)}});function C(e){var t=n.document.implementation.createHTMLDocument("");return t.body.innerHTML=e,t.body&&t.body.innerHTML}function T(e){var t=e.replace(P,"<$1></$2>");t!==e&&C(e)!==C(t)&&u("HTML tags must be properly nested and closed: "+e)}var P=/<(?!area|br|col|embed|hr|img|input|link|meta|param)(([a-z][^\/\0>\x20\t\r\n\f]*)[^>]*)\/>/gi,q=s.htmlPrefilter;s.UNSAFE_restoreLegacyHtmlPrefilter=function(){s.htmlPrefilter=function(e){return T(e),e.replace(P,"<$1></$2>")}},s.htmlPrefilter=function(e){return T(e),q(e)};var D=s.fn.offset;if(s.fn.offset=function(){var e,t=this[0];if(t&&t.nodeType)return e=(t.ownerDocument||n.document).documentElement,s.contains(e,t)?D.apply(this,arguments):(u("jQuery.fn.offset() requires an element connected to a document"),{top:0,left:0});u("jQuery.fn.offset() requires a valid DOM element")},s.ajax){var E=s.param;s.param=function(e,t){var r=s.ajaxSettings&&s.ajaxSettings.traditional;return void 0===t&&r&&(u("jQuery.param() no longer uses jQuery.ajaxSettings.traditional"),t=r),E.call(this,e,t)}}var _=s.fn.andSelf||s.fn.addBack;if(s.fn.andSelf=function(){return u("jQuery.fn.andSelf() is deprecated and removed, use jQuery.fn.addBack()"),_.apply(this,arguments)},s.Deferred){var F=s.Deferred,O=[["resolve","done",s.Callbacks("once memory"),s.Callbacks("once memory"),"resolved"],["reject","fail",s.Callbacks("once memory"),s.Callbacks("once memory"),"rejected"],["notify","progress",s.Callbacks("memory"),s.Callbacks("memory")]];s.Deferred=function(e){var o=F(),a=o.promise();return o.pipe=a.pipe=function(){var i=arguments;return u("deferred.pipe() is deprecated"),s.Deferred(function(n){s.each(O,function(e,t){var r="function"==typeof i[e]&&i[e];o[t[1]](function(){var e=r&&r.apply(this,arguments);e&&"function"==typeof e.promise?e.promise().done(n.resolve).fail(n.reject).progress(n.notify):n[t[0]+"With"](this===a?n.promise():this,r?[e]:arguments)})}),i=null}).promise()},e&&e.call(o,o),o},s.Deferred.exceptionHook=F.exceptionHook}return s}); +;/*! jQuery UI - v1.12.1 - 2016-09-14 +* http://jqueryui.com +* Includes: widget.js, position.js, data.js, disable-selection.js, effect.js, effects/effect-blind.js, effects/effect-bounce.js, effects/effect-clip.js, effects/effect-drop.js, effects/effect-explode.js, effects/effect-fade.js, effects/effect-fold.js, effects/effect-highlight.js, effects/effect-puff.js, effects/effect-pulsate.js, effects/effect-scale.js, effects/effect-shake.js, effects/effect-size.js, effects/effect-slide.js, effects/effect-transfer.js, focusable.js, form-reset-mixin.js, jquery-1-7.js, keycode.js, labels.js, scroll-parent.js, tabbable.js, unique-id.js, widgets/accordion.js, widgets/autocomplete.js, widgets/button.js, widgets/checkboxradio.js, widgets/controlgroup.js, widgets/datepicker.js, widgets/dialog.js, widgets/draggable.js, widgets/droppable.js, widgets/menu.js, widgets/mouse.js, widgets/progressbar.js, widgets/resizable.js, widgets/selectable.js, widgets/selectmenu.js, widgets/slider.js, widgets/sortable.js, widgets/spinner.js, widgets/tabs.js, widgets/tooltip.js +* Copyright jQuery Foundation and other contributors; Licensed MIT */ + +(function(t){"function"==typeof define&&define.amd?define(["jquery"],t):t(jQuery)})(function(t){function e(t){for(var e=t.css("visibility");"inherit"===e;)t=t.parent(),e=t.css("visibility");return"hidden"!==e}function i(t){for(var e,i;t.length&&t[0]!==document;){if(e=t.css("position"),("absolute"===e||"relative"===e||"fixed"===e)&&(i=parseInt(t.css("zIndex"),10),!isNaN(i)&&0!==i))return i;t=t.parent()}return 0}function s(){this._curInst=null,this._keyEvent=!1,this._disabledInputs=[],this._datepickerShowing=!1,this._inDialog=!1,this._mainDivId="ui-datepicker-div",this._inlineClass="ui-datepicker-inline",this._appendClass="ui-datepicker-append",this._triggerClass="ui-datepicker-trigger",this._dialogClass="ui-datepicker-dialog",this._disableClass="ui-datepicker-disabled",this._unselectableClass="ui-datepicker-unselectable",this._currentClass="ui-datepicker-current-day",this._dayOverClass="ui-datepicker-days-cell-over",this.regional=[],this.regional[""]={closeText:"Done",prevText:"Prev",nextText:"Next",currentText:"Today",monthNames:["January","February","March","April","May","June","July","August","September","October","November","December"],monthNamesShort:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],dayNames:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],dayNamesShort:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],dayNamesMin:["Su","Mo","Tu","We","Th","Fr","Sa"],weekHeader:"Wk",dateFormat:"mm/dd/yy",firstDay:0,isRTL:!1,showMonthAfterYear:!1,yearSuffix:""},this._defaults={showOn:"focus",showAnim:"fadeIn",showOptions:{},defaultDate:null,appendText:"",buttonText:"...",buttonImage:"",buttonImageOnly:!1,hideIfNoPrevNext:!1,navigationAsDateFormat:!1,gotoCurrent:!1,changeMonth:!1,changeYear:!1,yearRange:"c-10:c+10",showOtherMonths:!1,selectOtherMonths:!1,showWeek:!1,calculateWeek:this.iso8601Week,shortYearCutoff:"+10",minDate:null,maxDate:null,duration:"fast",beforeShowDay:null,beforeShow:null,onSelect:null,onChangeMonthYear:null,onClose:null,numberOfMonths:1,showCurrentAtPos:0,stepMonths:1,stepBigMonths:12,altField:"",altFormat:"",constrainInput:!0,showButtonPanel:!1,autoSize:!1,disabled:!1},t.extend(this._defaults,this.regional[""]),this.regional.en=t.extend(!0,{},this.regional[""]),this.regional["en-US"]=t.extend(!0,{},this.regional.en),this.dpDiv=n(t("<div id='"+this._mainDivId+"' class='ui-datepicker ui-widget ui-widget-content ui-helper-clearfix ui-corner-all'></div>"))}function n(e){var i="button, .ui-datepicker-prev, .ui-datepicker-next, .ui-datepicker-calendar td a";return e.on("mouseout",i,function(){t(this).removeClass("ui-state-hover"),-1!==this.className.indexOf("ui-datepicker-prev")&&t(this).removeClass("ui-datepicker-prev-hover"),-1!==this.className.indexOf("ui-datepicker-next")&&t(this).removeClass("ui-datepicker-next-hover")}).on("mouseover",i,o)}function o(){t.datepicker._isDisabledDatepicker(m.inline?m.dpDiv.parent()[0]:m.input[0])||(t(this).parents(".ui-datepicker-calendar").find("a").removeClass("ui-state-hover"),t(this).addClass("ui-state-hover"),-1!==this.className.indexOf("ui-datepicker-prev")&&t(this).addClass("ui-datepicker-prev-hover"),-1!==this.className.indexOf("ui-datepicker-next")&&t(this).addClass("ui-datepicker-next-hover"))}function a(e,i){t.extend(e,i);for(var s in i)null==i[s]&&(e[s]=i[s]);return e}function r(t){return function(){var e=this.element.val();t.apply(this,arguments),this._refresh(),e!==this.element.val()&&this._trigger("change")}}t.ui=t.ui||{},t.ui.version="1.12.1";var h=0,l=Array.prototype.slice;t.cleanData=function(e){return function(i){var s,n,o;for(o=0;null!=(n=i[o]);o++)try{s=t._data(n,"events"),s&&s.remove&&t(n).triggerHandler("remove")}catch(a){}e(i)}}(t.cleanData),t.widget=function(e,i,s){var n,o,a,r={},h=e.split(".")[0];e=e.split(".")[1];var l=h+"-"+e;return s||(s=i,i=t.Widget),t.isArray(s)&&(s=t.extend.apply(null,[{}].concat(s))),t.expr[":"][l.toLowerCase()]=function(e){return!!t.data(e,l)},t[h]=t[h]||{},n=t[h][e],o=t[h][e]=function(t,e){return this._createWidget?(arguments.length&&this._createWidget(t,e),void 0):new o(t,e)},t.extend(o,n,{version:s.version,_proto:t.extend({},s),_childConstructors:[]}),a=new i,a.options=t.widget.extend({},a.options),t.each(s,function(e,s){return t.isFunction(s)?(r[e]=function(){function t(){return i.prototype[e].apply(this,arguments)}function n(t){return i.prototype[e].apply(this,t)}return function(){var e,i=this._super,o=this._superApply;return this._super=t,this._superApply=n,e=s.apply(this,arguments),this._super=i,this._superApply=o,e}}(),void 0):(r[e]=s,void 0)}),o.prototype=t.widget.extend(a,{widgetEventPrefix:n?a.widgetEventPrefix||e:e},r,{constructor:o,namespace:h,widgetName:e,widgetFullName:l}),n?(t.each(n._childConstructors,function(e,i){var s=i.prototype;t.widget(s.namespace+"."+s.widgetName,o,i._proto)}),delete n._childConstructors):i._childConstructors.push(o),t.widget.bridge(e,o),o},t.widget.extend=function(e){for(var i,s,n=l.call(arguments,1),o=0,a=n.length;a>o;o++)for(i in n[o])s=n[o][i],n[o].hasOwnProperty(i)&&void 0!==s&&(e[i]=t.isPlainObject(s)?t.isPlainObject(e[i])?t.widget.extend({},e[i],s):t.widget.extend({},s):s);return e},t.widget.bridge=function(e,i){var s=i.prototype.widgetFullName||e;t.fn[e]=function(n){var o="string"==typeof n,a=l.call(arguments,1),r=this;return o?this.length||"instance"!==n?this.each(function(){var i,o=t.data(this,s);return"instance"===n?(r=o,!1):o?t.isFunction(o[n])&&"_"!==n.charAt(0)?(i=o[n].apply(o,a),i!==o&&void 0!==i?(r=i&&i.jquery?r.pushStack(i.get()):i,!1):void 0):t.error("no such method '"+n+"' for "+e+" widget instance"):t.error("cannot call methods on "+e+" prior to initialization; "+"attempted to call method '"+n+"'")}):r=void 0:(a.length&&(n=t.widget.extend.apply(null,[n].concat(a))),this.each(function(){var e=t.data(this,s);e?(e.option(n||{}),e._init&&e._init()):t.data(this,s,new i(n,this))})),r}},t.Widget=function(){},t.Widget._childConstructors=[],t.Widget.prototype={widgetName:"widget",widgetEventPrefix:"",defaultElement:"<div>",options:{classes:{},disabled:!1,create:null},_createWidget:function(e,i){i=t(i||this.defaultElement||this)[0],this.element=t(i),this.uuid=h++,this.eventNamespace="."+this.widgetName+this.uuid,this.bindings=t(),this.hoverable=t(),this.focusable=t(),this.classesElementLookup={},i!==this&&(t.data(i,this.widgetFullName,this),this._on(!0,this.element,{remove:function(t){t.target===i&&this.destroy()}}),this.document=t(i.style?i.ownerDocument:i.document||i),this.window=t(this.document[0].defaultView||this.document[0].parentWindow)),this.options=t.widget.extend({},this.options,this._getCreateOptions(),e),this._create(),this.options.disabled&&this._setOptionDisabled(this.options.disabled),this._trigger("create",null,this._getCreateEventData()),this._init()},_getCreateOptions:function(){return{}},_getCreateEventData:t.noop,_create:t.noop,_init:t.noop,destroy:function(){var e=this;this._destroy(),t.each(this.classesElementLookup,function(t,i){e._removeClass(i,t)}),this.element.off(this.eventNamespace).removeData(this.widgetFullName),this.widget().off(this.eventNamespace).removeAttr("aria-disabled"),this.bindings.off(this.eventNamespace)},_destroy:t.noop,widget:function(){return this.element},option:function(e,i){var s,n,o,a=e;if(0===arguments.length)return t.widget.extend({},this.options);if("string"==typeof e)if(a={},s=e.split("."),e=s.shift(),s.length){for(n=a[e]=t.widget.extend({},this.options[e]),o=0;s.length-1>o;o++)n[s[o]]=n[s[o]]||{},n=n[s[o]];if(e=s.pop(),1===arguments.length)return void 0===n[e]?null:n[e];n[e]=i}else{if(1===arguments.length)return void 0===this.options[e]?null:this.options[e];a[e]=i}return this._setOptions(a),this},_setOptions:function(t){var e;for(e in t)this._setOption(e,t[e]);return this},_setOption:function(t,e){return"classes"===t&&this._setOptionClasses(e),this.options[t]=e,"disabled"===t&&this._setOptionDisabled(e),this},_setOptionClasses:function(e){var i,s,n;for(i in e)n=this.classesElementLookup[i],e[i]!==this.options.classes[i]&&n&&n.length&&(s=t(n.get()),this._removeClass(n,i),s.addClass(this._classes({element:s,keys:i,classes:e,add:!0})))},_setOptionDisabled:function(t){this._toggleClass(this.widget(),this.widgetFullName+"-disabled",null,!!t),t&&(this._removeClass(this.hoverable,null,"ui-state-hover"),this._removeClass(this.focusable,null,"ui-state-focus"))},enable:function(){return this._setOptions({disabled:!1})},disable:function(){return this._setOptions({disabled:!0})},_classes:function(e){function i(i,o){var a,r;for(r=0;i.length>r;r++)a=n.classesElementLookup[i[r]]||t(),a=e.add?t(t.unique(a.get().concat(e.element.get()))):t(a.not(e.element).get()),n.classesElementLookup[i[r]]=a,s.push(i[r]),o&&e.classes[i[r]]&&s.push(e.classes[i[r]])}var s=[],n=this;return e=t.extend({element:this.element,classes:this.options.classes||{}},e),this._on(e.element,{remove:"_untrackClassesElement"}),e.keys&&i(e.keys.match(/\S+/g)||[],!0),e.extra&&i(e.extra.match(/\S+/g)||[]),s.join(" ")},_untrackClassesElement:function(e){var i=this;t.each(i.classesElementLookup,function(s,n){-1!==t.inArray(e.target,n)&&(i.classesElementLookup[s]=t(n.not(e.target).get()))})},_removeClass:function(t,e,i){return this._toggleClass(t,e,i,!1)},_addClass:function(t,e,i){return this._toggleClass(t,e,i,!0)},_toggleClass:function(t,e,i,s){s="boolean"==typeof s?s:i;var n="string"==typeof t||null===t,o={extra:n?e:i,keys:n?t:e,element:n?this.element:t,add:s};return o.element.toggleClass(this._classes(o),s),this},_on:function(e,i,s){var n,o=this;"boolean"!=typeof e&&(s=i,i=e,e=!1),s?(i=n=t(i),this.bindings=this.bindings.add(i)):(s=i,i=this.element,n=this.widget()),t.each(s,function(s,a){function r(){return e||o.options.disabled!==!0&&!t(this).hasClass("ui-state-disabled")?("string"==typeof a?o[a]:a).apply(o,arguments):void 0}"string"!=typeof a&&(r.guid=a.guid=a.guid||r.guid||t.guid++);var h=s.match(/^([\w:-]*)\s*(.*)$/),l=h[1]+o.eventNamespace,c=h[2];c?n.on(l,c,r):i.on(l,r)})},_off:function(e,i){i=(i||"").split(" ").join(this.eventNamespace+" ")+this.eventNamespace,e.off(i).off(i),this.bindings=t(this.bindings.not(e).get()),this.focusable=t(this.focusable.not(e).get()),this.hoverable=t(this.hoverable.not(e).get())},_delay:function(t,e){function i(){return("string"==typeof t?s[t]:t).apply(s,arguments)}var s=this;return setTimeout(i,e||0)},_hoverable:function(e){this.hoverable=this.hoverable.add(e),this._on(e,{mouseenter:function(e){this._addClass(t(e.currentTarget),null,"ui-state-hover")},mouseleave:function(e){this._removeClass(t(e.currentTarget),null,"ui-state-hover")}})},_focusable:function(e){this.focusable=this.focusable.add(e),this._on(e,{focusin:function(e){this._addClass(t(e.currentTarget),null,"ui-state-focus")},focusout:function(e){this._removeClass(t(e.currentTarget),null,"ui-state-focus")}})},_trigger:function(e,i,s){var n,o,a=this.options[e];if(s=s||{},i=t.Event(i),i.type=(e===this.widgetEventPrefix?e:this.widgetEventPrefix+e).toLowerCase(),i.target=this.element[0],o=i.originalEvent)for(n in o)n in i||(i[n]=o[n]);return this.element.trigger(i,s),!(t.isFunction(a)&&a.apply(this.element[0],[i].concat(s))===!1||i.isDefaultPrevented())}},t.each({show:"fadeIn",hide:"fadeOut"},function(e,i){t.Widget.prototype["_"+e]=function(s,n,o){"string"==typeof n&&(n={effect:n});var a,r=n?n===!0||"number"==typeof n?i:n.effect||i:e;n=n||{},"number"==typeof n&&(n={duration:n}),a=!t.isEmptyObject(n),n.complete=o,n.delay&&s.delay(n.delay),a&&t.effects&&t.effects.effect[r]?s[e](n):r!==e&&s[r]?s[r](n.duration,n.easing,o):s.queue(function(i){t(this)[e](),o&&o.call(s[0]),i()})}}),t.widget,function(){function e(t,e,i){return[parseFloat(t[0])*(u.test(t[0])?e/100:1),parseFloat(t[1])*(u.test(t[1])?i/100:1)]}function i(e,i){return parseInt(t.css(e,i),10)||0}function s(e){var i=e[0];return 9===i.nodeType?{width:e.width(),height:e.height(),offset:{top:0,left:0}}:t.isWindow(i)?{width:e.width(),height:e.height(),offset:{top:e.scrollTop(),left:e.scrollLeft()}}:i.preventDefault?{width:0,height:0,offset:{top:i.pageY,left:i.pageX}}:{width:e.outerWidth(),height:e.outerHeight(),offset:e.offset()}}var n,o=Math.max,a=Math.abs,r=/left|center|right/,h=/top|center|bottom/,l=/[\+\-]\d+(\.[\d]+)?%?/,c=/^\w+/,u=/%$/,d=t.fn.position;t.position={scrollbarWidth:function(){if(void 0!==n)return n;var e,i,s=t("<div style='display:block;position:absolute;width:50px;height:50px;overflow:hidden;'><div style='height:100px;width:auto;'></div></div>"),o=s.children()[0];return t("body").append(s),e=o.offsetWidth,s.css("overflow","scroll"),i=o.offsetWidth,e===i&&(i=s[0].clientWidth),s.remove(),n=e-i},getScrollInfo:function(e){var i=e.isWindow||e.isDocument?"":e.element.css("overflow-x"),s=e.isWindow||e.isDocument?"":e.element.css("overflow-y"),n="scroll"===i||"auto"===i&&e.width<e.element[0].scrollWidth,o="scroll"===s||"auto"===s&&e.height<e.element[0].scrollHeight;return{width:o?t.position.scrollbarWidth():0,height:n?t.position.scrollbarWidth():0}},getWithinInfo:function(e){var i=t(e||window),s=t.isWindow(i[0]),n=!!i[0]&&9===i[0].nodeType,o=!s&&!n;return{element:i,isWindow:s,isDocument:n,offset:o?t(e).offset():{left:0,top:0},scrollLeft:i.scrollLeft(),scrollTop:i.scrollTop(),width:i.outerWidth(),height:i.outerHeight()}}},t.fn.position=function(n){if(!n||!n.of)return d.apply(this,arguments);n=t.extend({},n);var u,p,f,g,m,_,v=t(n.of),b=t.position.getWithinInfo(n.within),y=t.position.getScrollInfo(b),w=(n.collision||"flip").split(" "),k={};return _=s(v),v[0].preventDefault&&(n.at="left top"),p=_.width,f=_.height,g=_.offset,m=t.extend({},g),t.each(["my","at"],function(){var t,e,i=(n[this]||"").split(" ");1===i.length&&(i=r.test(i[0])?i.concat(["center"]):h.test(i[0])?["center"].concat(i):["center","center"]),i[0]=r.test(i[0])?i[0]:"center",i[1]=h.test(i[1])?i[1]:"center",t=l.exec(i[0]),e=l.exec(i[1]),k[this]=[t?t[0]:0,e?e[0]:0],n[this]=[c.exec(i[0])[0],c.exec(i[1])[0]]}),1===w.length&&(w[1]=w[0]),"right"===n.at[0]?m.left+=p:"center"===n.at[0]&&(m.left+=p/2),"bottom"===n.at[1]?m.top+=f:"center"===n.at[1]&&(m.top+=f/2),u=e(k.at,p,f),m.left+=u[0],m.top+=u[1],this.each(function(){var s,r,h=t(this),l=h.outerWidth(),c=h.outerHeight(),d=i(this,"marginLeft"),_=i(this,"marginTop"),x=l+d+i(this,"marginRight")+y.width,C=c+_+i(this,"marginBottom")+y.height,D=t.extend({},m),I=e(k.my,h.outerWidth(),h.outerHeight());"right"===n.my[0]?D.left-=l:"center"===n.my[0]&&(D.left-=l/2),"bottom"===n.my[1]?D.top-=c:"center"===n.my[1]&&(D.top-=c/2),D.left+=I[0],D.top+=I[1],s={marginLeft:d,marginTop:_},t.each(["left","top"],function(e,i){t.ui.position[w[e]]&&t.ui.position[w[e]][i](D,{targetWidth:p,targetHeight:f,elemWidth:l,elemHeight:c,collisionPosition:s,collisionWidth:x,collisionHeight:C,offset:[u[0]+I[0],u[1]+I[1]],my:n.my,at:n.at,within:b,elem:h})}),n.using&&(r=function(t){var e=g.left-D.left,i=e+p-l,s=g.top-D.top,r=s+f-c,u={target:{element:v,left:g.left,top:g.top,width:p,height:f},element:{element:h,left:D.left,top:D.top,width:l,height:c},horizontal:0>i?"left":e>0?"right":"center",vertical:0>r?"top":s>0?"bottom":"middle"};l>p&&p>a(e+i)&&(u.horizontal="center"),c>f&&f>a(s+r)&&(u.vertical="middle"),u.important=o(a(e),a(i))>o(a(s),a(r))?"horizontal":"vertical",n.using.call(this,t,u)}),h.offset(t.extend(D,{using:r}))})},t.ui.position={fit:{left:function(t,e){var i,s=e.within,n=s.isWindow?s.scrollLeft:s.offset.left,a=s.width,r=t.left-e.collisionPosition.marginLeft,h=n-r,l=r+e.collisionWidth-a-n;e.collisionWidth>a?h>0&&0>=l?(i=t.left+h+e.collisionWidth-a-n,t.left+=h-i):t.left=l>0&&0>=h?n:h>l?n+a-e.collisionWidth:n:h>0?t.left+=h:l>0?t.left-=l:t.left=o(t.left-r,t.left)},top:function(t,e){var i,s=e.within,n=s.isWindow?s.scrollTop:s.offset.top,a=e.within.height,r=t.top-e.collisionPosition.marginTop,h=n-r,l=r+e.collisionHeight-a-n;e.collisionHeight>a?h>0&&0>=l?(i=t.top+h+e.collisionHeight-a-n,t.top+=h-i):t.top=l>0&&0>=h?n:h>l?n+a-e.collisionHeight:n:h>0?t.top+=h:l>0?t.top-=l:t.top=o(t.top-r,t.top)}},flip:{left:function(t,e){var i,s,n=e.within,o=n.offset.left+n.scrollLeft,r=n.width,h=n.isWindow?n.scrollLeft:n.offset.left,l=t.left-e.collisionPosition.marginLeft,c=l-h,u=l+e.collisionWidth-r-h,d="left"===e.my[0]?-e.elemWidth:"right"===e.my[0]?e.elemWidth:0,p="left"===e.at[0]?e.targetWidth:"right"===e.at[0]?-e.targetWidth:0,f=-2*e.offset[0];0>c?(i=t.left+d+p+f+e.collisionWidth-r-o,(0>i||a(c)>i)&&(t.left+=d+p+f)):u>0&&(s=t.left-e.collisionPosition.marginLeft+d+p+f-h,(s>0||u>a(s))&&(t.left+=d+p+f))},top:function(t,e){var i,s,n=e.within,o=n.offset.top+n.scrollTop,r=n.height,h=n.isWindow?n.scrollTop:n.offset.top,l=t.top-e.collisionPosition.marginTop,c=l-h,u=l+e.collisionHeight-r-h,d="top"===e.my[1],p=d?-e.elemHeight:"bottom"===e.my[1]?e.elemHeight:0,f="top"===e.at[1]?e.targetHeight:"bottom"===e.at[1]?-e.targetHeight:0,g=-2*e.offset[1];0>c?(s=t.top+p+f+g+e.collisionHeight-r-o,(0>s||a(c)>s)&&(t.top+=p+f+g)):u>0&&(i=t.top-e.collisionPosition.marginTop+p+f+g-h,(i>0||u>a(i))&&(t.top+=p+f+g))}},flipfit:{left:function(){t.ui.position.flip.left.apply(this,arguments),t.ui.position.fit.left.apply(this,arguments)},top:function(){t.ui.position.flip.top.apply(this,arguments),t.ui.position.fit.top.apply(this,arguments)}}}}(),t.ui.position,t.extend(t.expr[":"],{data:t.expr.createPseudo?t.expr.createPseudo(function(e){return function(i){return!!t.data(i,e)}}):function(e,i,s){return!!t.data(e,s[3])}}),t.fn.extend({disableSelection:function(){var t="onselectstart"in document.createElement("div")?"selectstart":"mousedown";return function(){return this.on(t+".ui-disableSelection",function(t){t.preventDefault()})}}(),enableSelection:function(){return this.off(".ui-disableSelection")}});var c="ui-effects-",u="ui-effects-style",d="ui-effects-animated",p=t;t.effects={effect:{}},function(t,e){function i(t,e,i){var s=u[e.type]||{};return null==t?i||!e.def?null:e.def:(t=s.floor?~~t:parseFloat(t),isNaN(t)?e.def:s.mod?(t+s.mod)%s.mod:0>t?0:t>s.max?s.max:t)}function s(i){var s=l(),n=s._rgba=[];return i=i.toLowerCase(),f(h,function(t,o){var a,r=o.re.exec(i),h=r&&o.parse(r),l=o.space||"rgba";return h?(a=s[l](h),s[c[l].cache]=a[c[l].cache],n=s._rgba=a._rgba,!1):e}),n.length?("0,0,0,0"===n.join()&&t.extend(n,o.transparent),s):o[i]}function n(t,e,i){return i=(i+1)%1,1>6*i?t+6*(e-t)*i:1>2*i?e:2>3*i?t+6*(e-t)*(2/3-i):t}var o,a="backgroundColor borderBottomColor borderLeftColor borderRightColor borderTopColor color columnRuleColor outlineColor textDecorationColor textEmphasisColor",r=/^([\-+])=\s*(\d+\.?\d*)/,h=[{re:/rgba?\(\s*(\d{1,3})\s*,\s*(\d{1,3})\s*,\s*(\d{1,3})\s*(?:,\s*(\d?(?:\.\d+)?)\s*)?\)/,parse:function(t){return[t[1],t[2],t[3],t[4]]}},{re:/rgba?\(\s*(\d+(?:\.\d+)?)\%\s*,\s*(\d+(?:\.\d+)?)\%\s*,\s*(\d+(?:\.\d+)?)\%\s*(?:,\s*(\d?(?:\.\d+)?)\s*)?\)/,parse:function(t){return[2.55*t[1],2.55*t[2],2.55*t[3],t[4]]}},{re:/#([a-f0-9]{2})([a-f0-9]{2})([a-f0-9]{2})/,parse:function(t){return[parseInt(t[1],16),parseInt(t[2],16),parseInt(t[3],16)]}},{re:/#([a-f0-9])([a-f0-9])([a-f0-9])/,parse:function(t){return[parseInt(t[1]+t[1],16),parseInt(t[2]+t[2],16),parseInt(t[3]+t[3],16)]}},{re:/hsla?\(\s*(\d+(?:\.\d+)?)\s*,\s*(\d+(?:\.\d+)?)\%\s*,\s*(\d+(?:\.\d+)?)\%\s*(?:,\s*(\d?(?:\.\d+)?)\s*)?\)/,space:"hsla",parse:function(t){return[t[1],t[2]/100,t[3]/100,t[4]]}}],l=t.Color=function(e,i,s,n){return new t.Color.fn.parse(e,i,s,n)},c={rgba:{props:{red:{idx:0,type:"byte"},green:{idx:1,type:"byte"},blue:{idx:2,type:"byte"}}},hsla:{props:{hue:{idx:0,type:"degrees"},saturation:{idx:1,type:"percent"},lightness:{idx:2,type:"percent"}}}},u={"byte":{floor:!0,max:255},percent:{max:1},degrees:{mod:360,floor:!0}},d=l.support={},p=t("<p>")[0],f=t.each;p.style.cssText="background-color:rgba(1,1,1,.5)",d.rgba=p.style.backgroundColor.indexOf("rgba")>-1,f(c,function(t,e){e.cache="_"+t,e.props.alpha={idx:3,type:"percent",def:1}}),l.fn=t.extend(l.prototype,{parse:function(n,a,r,h){if(n===e)return this._rgba=[null,null,null,null],this;(n.jquery||n.nodeType)&&(n=t(n).css(a),a=e);var u=this,d=t.type(n),p=this._rgba=[];return a!==e&&(n=[n,a,r,h],d="array"),"string"===d?this.parse(s(n)||o._default):"array"===d?(f(c.rgba.props,function(t,e){p[e.idx]=i(n[e.idx],e)}),this):"object"===d?(n instanceof l?f(c,function(t,e){n[e.cache]&&(u[e.cache]=n[e.cache].slice())}):f(c,function(e,s){var o=s.cache;f(s.props,function(t,e){if(!u[o]&&s.to){if("alpha"===t||null==n[t])return;u[o]=s.to(u._rgba)}u[o][e.idx]=i(n[t],e,!0)}),u[o]&&0>t.inArray(null,u[o].slice(0,3))&&(u[o][3]=1,s.from&&(u._rgba=s.from(u[o])))}),this):e},is:function(t){var i=l(t),s=!0,n=this;return f(c,function(t,o){var a,r=i[o.cache];return r&&(a=n[o.cache]||o.to&&o.to(n._rgba)||[],f(o.props,function(t,i){return null!=r[i.idx]?s=r[i.idx]===a[i.idx]:e})),s}),s},_space:function(){var t=[],e=this;return f(c,function(i,s){e[s.cache]&&t.push(i)}),t.pop()},transition:function(t,e){var s=l(t),n=s._space(),o=c[n],a=0===this.alpha()?l("transparent"):this,r=a[o.cache]||o.to(a._rgba),h=r.slice();return s=s[o.cache],f(o.props,function(t,n){var o=n.idx,a=r[o],l=s[o],c=u[n.type]||{};null!==l&&(null===a?h[o]=l:(c.mod&&(l-a>c.mod/2?a+=c.mod:a-l>c.mod/2&&(a-=c.mod)),h[o]=i((l-a)*e+a,n)))}),this[n](h)},blend:function(e){if(1===this._rgba[3])return this;var i=this._rgba.slice(),s=i.pop(),n=l(e)._rgba;return l(t.map(i,function(t,e){return(1-s)*n[e]+s*t}))},toRgbaString:function(){var e="rgba(",i=t.map(this._rgba,function(t,e){return null==t?e>2?1:0:t});return 1===i[3]&&(i.pop(),e="rgb("),e+i.join()+")"},toHslaString:function(){var e="hsla(",i=t.map(this.hsla(),function(t,e){return null==t&&(t=e>2?1:0),e&&3>e&&(t=Math.round(100*t)+"%"),t});return 1===i[3]&&(i.pop(),e="hsl("),e+i.join()+")"},toHexString:function(e){var i=this._rgba.slice(),s=i.pop();return e&&i.push(~~(255*s)),"#"+t.map(i,function(t){return t=(t||0).toString(16),1===t.length?"0"+t:t}).join("")},toString:function(){return 0===this._rgba[3]?"transparent":this.toRgbaString()}}),l.fn.parse.prototype=l.fn,c.hsla.to=function(t){if(null==t[0]||null==t[1]||null==t[2])return[null,null,null,t[3]];var e,i,s=t[0]/255,n=t[1]/255,o=t[2]/255,a=t[3],r=Math.max(s,n,o),h=Math.min(s,n,o),l=r-h,c=r+h,u=.5*c;return e=h===r?0:s===r?60*(n-o)/l+360:n===r?60*(o-s)/l+120:60*(s-n)/l+240,i=0===l?0:.5>=u?l/c:l/(2-c),[Math.round(e)%360,i,u,null==a?1:a]},c.hsla.from=function(t){if(null==t[0]||null==t[1]||null==t[2])return[null,null,null,t[3]];var e=t[0]/360,i=t[1],s=t[2],o=t[3],a=.5>=s?s*(1+i):s+i-s*i,r=2*s-a;return[Math.round(255*n(r,a,e+1/3)),Math.round(255*n(r,a,e)),Math.round(255*n(r,a,e-1/3)),o]},f(c,function(s,n){var o=n.props,a=n.cache,h=n.to,c=n.from;l.fn[s]=function(s){if(h&&!this[a]&&(this[a]=h(this._rgba)),s===e)return this[a].slice();var n,r=t.type(s),u="array"===r||"object"===r?s:arguments,d=this[a].slice();return f(o,function(t,e){var s=u["object"===r?t:e.idx];null==s&&(s=d[e.idx]),d[e.idx]=i(s,e)}),c?(n=l(c(d)),n[a]=d,n):l(d)},f(o,function(e,i){l.fn[e]||(l.fn[e]=function(n){var o,a=t.type(n),h="alpha"===e?this._hsla?"hsla":"rgba":s,l=this[h](),c=l[i.idx];return"undefined"===a?c:("function"===a&&(n=n.call(this,c),a=t.type(n)),null==n&&i.empty?this:("string"===a&&(o=r.exec(n),o&&(n=c+parseFloat(o[2])*("+"===o[1]?1:-1))),l[i.idx]=n,this[h](l)))})})}),l.hook=function(e){var i=e.split(" ");f(i,function(e,i){t.cssHooks[i]={set:function(e,n){var o,a,r="";if("transparent"!==n&&("string"!==t.type(n)||(o=s(n)))){if(n=l(o||n),!d.rgba&&1!==n._rgba[3]){for(a="backgroundColor"===i?e.parentNode:e;(""===r||"transparent"===r)&&a&&a.style;)try{r=t.css(a,"backgroundColor"),a=a.parentNode}catch(h){}n=n.blend(r&&"transparent"!==r?r:"_default")}n=n.toRgbaString()}try{e.style[i]=n}catch(h){}}},t.fx.step[i]=function(e){e.colorInit||(e.start=l(e.elem,i),e.end=l(e.end),e.colorInit=!0),t.cssHooks[i].set(e.elem,e.start.transition(e.end,e.pos))}})},l.hook(a),t.cssHooks.borderColor={expand:function(t){var e={};return f(["Top","Right","Bottom","Left"],function(i,s){e["border"+s+"Color"]=t}),e}},o=t.Color.names={aqua:"#00ffff",black:"#000000",blue:"#0000ff",fuchsia:"#ff00ff",gray:"#808080",green:"#008000",lime:"#00ff00",maroon:"#800000",navy:"#000080",olive:"#808000",purple:"#800080",red:"#ff0000",silver:"#c0c0c0",teal:"#008080",white:"#ffffff",yellow:"#ffff00",transparent:[null,null,null,0],_default:"#ffffff"}}(p),function(){function e(e){var i,s,n=e.ownerDocument.defaultView?e.ownerDocument.defaultView.getComputedStyle(e,null):e.currentStyle,o={};if(n&&n.length&&n[0]&&n[n[0]])for(s=n.length;s--;)i=n[s],"string"==typeof n[i]&&(o[t.camelCase(i)]=n[i]);else for(i in n)"string"==typeof n[i]&&(o[i]=n[i]);return o}function i(e,i){var s,o,a={};for(s in i)o=i[s],e[s]!==o&&(n[s]||(t.fx.step[s]||!isNaN(parseFloat(o)))&&(a[s]=o));return a}var s=["add","remove","toggle"],n={border:1,borderBottom:1,borderColor:1,borderLeft:1,borderRight:1,borderTop:1,borderWidth:1,margin:1,padding:1};t.each(["borderLeftStyle","borderRightStyle","borderBottomStyle","borderTopStyle"],function(e,i){t.fx.step[i]=function(t){("none"!==t.end&&!t.setAttr||1===t.pos&&!t.setAttr)&&(p.style(t.elem,i,t.end),t.setAttr=!0)}}),t.fn.addBack||(t.fn.addBack=function(t){return this.add(null==t?this.prevObject:this.prevObject.filter(t))}),t.effects.animateClass=function(n,o,a,r){var h=t.speed(o,a,r);return this.queue(function(){var o,a=t(this),r=a.attr("class")||"",l=h.children?a.find("*").addBack():a;l=l.map(function(){var i=t(this);return{el:i,start:e(this)}}),o=function(){t.each(s,function(t,e){n[e]&&a[e+"Class"](n[e])})},o(),l=l.map(function(){return this.end=e(this.el[0]),this.diff=i(this.start,this.end),this}),a.attr("class",r),l=l.map(function(){var e=this,i=t.Deferred(),s=t.extend({},h,{queue:!1,complete:function(){i.resolve(e)}});return this.el.animate(this.diff,s),i.promise()}),t.when.apply(t,l.get()).done(function(){o(),t.each(arguments,function(){var e=this.el;t.each(this.diff,function(t){e.css(t,"")})}),h.complete.call(a[0])})})},t.fn.extend({addClass:function(e){return function(i,s,n,o){return s?t.effects.animateClass.call(this,{add:i},s,n,o):e.apply(this,arguments)}}(t.fn.addClass),removeClass:function(e){return function(i,s,n,o){return arguments.length>1?t.effects.animateClass.call(this,{remove:i},s,n,o):e.apply(this,arguments)}}(t.fn.removeClass),toggleClass:function(e){return function(i,s,n,o,a){return"boolean"==typeof s||void 0===s?n?t.effects.animateClass.call(this,s?{add:i}:{remove:i},n,o,a):e.apply(this,arguments):t.effects.animateClass.call(this,{toggle:i},s,n,o)}}(t.fn.toggleClass),switchClass:function(e,i,s,n,o){return t.effects.animateClass.call(this,{add:i,remove:e},s,n,o)}})}(),function(){function e(e,i,s,n){return t.isPlainObject(e)&&(i=e,e=e.effect),e={effect:e},null==i&&(i={}),t.isFunction(i)&&(n=i,s=null,i={}),("number"==typeof i||t.fx.speeds[i])&&(n=s,s=i,i={}),t.isFunction(s)&&(n=s,s=null),i&&t.extend(e,i),s=s||i.duration,e.duration=t.fx.off?0:"number"==typeof s?s:s in t.fx.speeds?t.fx.speeds[s]:t.fx.speeds._default,e.complete=n||i.complete,e}function i(e){return!e||"number"==typeof e||t.fx.speeds[e]?!0:"string"!=typeof e||t.effects.effect[e]?t.isFunction(e)?!0:"object"!=typeof e||e.effect?!1:!0:!0}function s(t,e){var i=e.outerWidth(),s=e.outerHeight(),n=/^rect\((-?\d*\.?\d*px|-?\d+%|auto),?\s*(-?\d*\.?\d*px|-?\d+%|auto),?\s*(-?\d*\.?\d*px|-?\d+%|auto),?\s*(-?\d*\.?\d*px|-?\d+%|auto)\)$/,o=n.exec(t)||["",0,i,s,0];return{top:parseFloat(o[1])||0,right:"auto"===o[2]?i:parseFloat(o[2]),bottom:"auto"===o[3]?s:parseFloat(o[3]),left:parseFloat(o[4])||0}}t.expr&&t.expr.filters&&t.expr.filters.animated&&(t.expr.filters.animated=function(e){return function(i){return!!t(i).data(d)||e(i)}}(t.expr.filters.animated)),t.uiBackCompat!==!1&&t.extend(t.effects,{save:function(t,e){for(var i=0,s=e.length;s>i;i++)null!==e[i]&&t.data(c+e[i],t[0].style[e[i]])},restore:function(t,e){for(var i,s=0,n=e.length;n>s;s++)null!==e[s]&&(i=t.data(c+e[s]),t.css(e[s],i))},setMode:function(t,e){return"toggle"===e&&(e=t.is(":hidden")?"show":"hide"),e},createWrapper:function(e){if(e.parent().is(".ui-effects-wrapper"))return e.parent();var i={width:e.outerWidth(!0),height:e.outerHeight(!0),"float":e.css("float")},s=t("<div></div>").addClass("ui-effects-wrapper").css({fontSize:"100%",background:"transparent",border:"none",margin:0,padding:0}),n={width:e.width(),height:e.height()},o=document.activeElement;try{o.id}catch(a){o=document.body}return e.wrap(s),(e[0]===o||t.contains(e[0],o))&&t(o).trigger("focus"),s=e.parent(),"static"===e.css("position")?(s.css({position:"relative"}),e.css({position:"relative"})):(t.extend(i,{position:e.css("position"),zIndex:e.css("z-index")}),t.each(["top","left","bottom","right"],function(t,s){i[s]=e.css(s),isNaN(parseInt(i[s],10))&&(i[s]="auto")}),e.css({position:"relative",top:0,left:0,right:"auto",bottom:"auto"})),e.css(n),s.css(i).show()},removeWrapper:function(e){var i=document.activeElement;return e.parent().is(".ui-effects-wrapper")&&(e.parent().replaceWith(e),(e[0]===i||t.contains(e[0],i))&&t(i).trigger("focus")),e}}),t.extend(t.effects,{version:"1.12.1",define:function(e,i,s){return s||(s=i,i="effect"),t.effects.effect[e]=s,t.effects.effect[e].mode=i,s},scaledDimensions:function(t,e,i){if(0===e)return{height:0,width:0,outerHeight:0,outerWidth:0};var s="horizontal"!==i?(e||100)/100:1,n="vertical"!==i?(e||100)/100:1;return{height:t.height()*n,width:t.width()*s,outerHeight:t.outerHeight()*n,outerWidth:t.outerWidth()*s}},clipToBox:function(t){return{width:t.clip.right-t.clip.left,height:t.clip.bottom-t.clip.top,left:t.clip.left,top:t.clip.top}},unshift:function(t,e,i){var s=t.queue();e>1&&s.splice.apply(s,[1,0].concat(s.splice(e,i))),t.dequeue()},saveStyle:function(t){t.data(u,t[0].style.cssText)},restoreStyle:function(t){t[0].style.cssText=t.data(u)||"",t.removeData(u)},mode:function(t,e){var i=t.is(":hidden");return"toggle"===e&&(e=i?"show":"hide"),(i?"hide"===e:"show"===e)&&(e="none"),e},getBaseline:function(t,e){var i,s;switch(t[0]){case"top":i=0;break;case"middle":i=.5;break;case"bottom":i=1;break;default:i=t[0]/e.height}switch(t[1]){case"left":s=0;break;case"center":s=.5;break;case"right":s=1;break;default:s=t[1]/e.width}return{x:s,y:i}},createPlaceholder:function(e){var i,s=e.css("position"),n=e.position();return e.css({marginTop:e.css("marginTop"),marginBottom:e.css("marginBottom"),marginLeft:e.css("marginLeft"),marginRight:e.css("marginRight")}).outerWidth(e.outerWidth()).outerHeight(e.outerHeight()),/^(static|relative)/.test(s)&&(s="absolute",i=t("<"+e[0].nodeName+">").insertAfter(e).css({display:/^(inline|ruby)/.test(e.css("display"))?"inline-block":"block",visibility:"hidden",marginTop:e.css("marginTop"),marginBottom:e.css("marginBottom"),marginLeft:e.css("marginLeft"),marginRight:e.css("marginRight"),"float":e.css("float")}).outerWidth(e.outerWidth()).outerHeight(e.outerHeight()).addClass("ui-effects-placeholder"),e.data(c+"placeholder",i)),e.css({position:s,left:n.left,top:n.top}),i},removePlaceholder:function(t){var e=c+"placeholder",i=t.data(e);i&&(i.remove(),t.removeData(e))},cleanUp:function(e){t.effects.restoreStyle(e),t.effects.removePlaceholder(e)},setTransition:function(e,i,s,n){return n=n||{},t.each(i,function(t,i){var o=e.cssUnit(i);o[0]>0&&(n[i]=o[0]*s+o[1])}),n}}),t.fn.extend({effect:function(){function i(e){function i(){r.removeData(d),t.effects.cleanUp(r),"hide"===s.mode&&r.hide(),a()}function a(){t.isFunction(h)&&h.call(r[0]),t.isFunction(e)&&e()}var r=t(this);s.mode=c.shift(),t.uiBackCompat===!1||o?"none"===s.mode?(r[l](),a()):n.call(r[0],s,i):(r.is(":hidden")?"hide"===l:"show"===l)?(r[l](),a()):n.call(r[0],s,a)}var s=e.apply(this,arguments),n=t.effects.effect[s.effect],o=n.mode,a=s.queue,r=a||"fx",h=s.complete,l=s.mode,c=[],u=function(e){var i=t(this),s=t.effects.mode(i,l)||o;i.data(d,!0),c.push(s),o&&("show"===s||s===o&&"hide"===s)&&i.show(),o&&"none"===s||t.effects.saveStyle(i),t.isFunction(e)&&e()};return t.fx.off||!n?l?this[l](s.duration,h):this.each(function(){h&&h.call(this)}):a===!1?this.each(u).each(i):this.queue(r,u).queue(r,i)},show:function(t){return function(s){if(i(s))return t.apply(this,arguments);var n=e.apply(this,arguments);return n.mode="show",this.effect.call(this,n) +}}(t.fn.show),hide:function(t){return function(s){if(i(s))return t.apply(this,arguments);var n=e.apply(this,arguments);return n.mode="hide",this.effect.call(this,n)}}(t.fn.hide),toggle:function(t){return function(s){if(i(s)||"boolean"==typeof s)return t.apply(this,arguments);var n=e.apply(this,arguments);return n.mode="toggle",this.effect.call(this,n)}}(t.fn.toggle),cssUnit:function(e){var i=this.css(e),s=[];return t.each(["em","px","%","pt"],function(t,e){i.indexOf(e)>0&&(s=[parseFloat(i),e])}),s},cssClip:function(t){return t?this.css("clip","rect("+t.top+"px "+t.right+"px "+t.bottom+"px "+t.left+"px)"):s(this.css("clip"),this)},transfer:function(e,i){var s=t(this),n=t(e.to),o="fixed"===n.css("position"),a=t("body"),r=o?a.scrollTop():0,h=o?a.scrollLeft():0,l=n.offset(),c={top:l.top-r,left:l.left-h,height:n.innerHeight(),width:n.innerWidth()},u=s.offset(),d=t("<div class='ui-effects-transfer'></div>").appendTo("body").addClass(e.className).css({top:u.top-r,left:u.left-h,height:s.innerHeight(),width:s.innerWidth(),position:o?"fixed":"absolute"}).animate(c,e.duration,e.easing,function(){d.remove(),t.isFunction(i)&&i()})}}),t.fx.step.clip=function(e){e.clipInit||(e.start=t(e.elem).cssClip(),"string"==typeof e.end&&(e.end=s(e.end,e.elem)),e.clipInit=!0),t(e.elem).cssClip({top:e.pos*(e.end.top-e.start.top)+e.start.top,right:e.pos*(e.end.right-e.start.right)+e.start.right,bottom:e.pos*(e.end.bottom-e.start.bottom)+e.start.bottom,left:e.pos*(e.end.left-e.start.left)+e.start.left})}}(),function(){var e={};t.each(["Quad","Cubic","Quart","Quint","Expo"],function(t,i){e[i]=function(e){return Math.pow(e,t+2)}}),t.extend(e,{Sine:function(t){return 1-Math.cos(t*Math.PI/2)},Circ:function(t){return 1-Math.sqrt(1-t*t)},Elastic:function(t){return 0===t||1===t?t:-Math.pow(2,8*(t-1))*Math.sin((80*(t-1)-7.5)*Math.PI/15)},Back:function(t){return t*t*(3*t-2)},Bounce:function(t){for(var e,i=4;((e=Math.pow(2,--i))-1)/11>t;);return 1/Math.pow(4,3-i)-7.5625*Math.pow((3*e-2)/22-t,2)}}),t.each(e,function(e,i){t.easing["easeIn"+e]=i,t.easing["easeOut"+e]=function(t){return 1-i(1-t)},t.easing["easeInOut"+e]=function(t){return.5>t?i(2*t)/2:1-i(-2*t+2)/2}})}();var f=t.effects;t.effects.define("blind","hide",function(e,i){var s={up:["bottom","top"],vertical:["bottom","top"],down:["top","bottom"],left:["right","left"],horizontal:["right","left"],right:["left","right"]},n=t(this),o=e.direction||"up",a=n.cssClip(),r={clip:t.extend({},a)},h=t.effects.createPlaceholder(n);r.clip[s[o][0]]=r.clip[s[o][1]],"show"===e.mode&&(n.cssClip(r.clip),h&&h.css(t.effects.clipToBox(r)),r.clip=a),h&&h.animate(t.effects.clipToBox(r),e.duration,e.easing),n.animate(r,{queue:!1,duration:e.duration,easing:e.easing,complete:i})}),t.effects.define("bounce",function(e,i){var s,n,o,a=t(this),r=e.mode,h="hide"===r,l="show"===r,c=e.direction||"up",u=e.distance,d=e.times||5,p=2*d+(l||h?1:0),f=e.duration/p,g=e.easing,m="up"===c||"down"===c?"top":"left",_="up"===c||"left"===c,v=0,b=a.queue().length;for(t.effects.createPlaceholder(a),o=a.css(m),u||(u=a["top"===m?"outerHeight":"outerWidth"]()/3),l&&(n={opacity:1},n[m]=o,a.css("opacity",0).css(m,_?2*-u:2*u).animate(n,f,g)),h&&(u/=Math.pow(2,d-1)),n={},n[m]=o;d>v;v++)s={},s[m]=(_?"-=":"+=")+u,a.animate(s,f,g).animate(n,f,g),u=h?2*u:u/2;h&&(s={opacity:0},s[m]=(_?"-=":"+=")+u,a.animate(s,f,g)),a.queue(i),t.effects.unshift(a,b,p+1)}),t.effects.define("clip","hide",function(e,i){var s,n={},o=t(this),a=e.direction||"vertical",r="both"===a,h=r||"horizontal"===a,l=r||"vertical"===a;s=o.cssClip(),n.clip={top:l?(s.bottom-s.top)/2:s.top,right:h?(s.right-s.left)/2:s.right,bottom:l?(s.bottom-s.top)/2:s.bottom,left:h?(s.right-s.left)/2:s.left},t.effects.createPlaceholder(o),"show"===e.mode&&(o.cssClip(n.clip),n.clip=s),o.animate(n,{queue:!1,duration:e.duration,easing:e.easing,complete:i})}),t.effects.define("drop","hide",function(e,i){var s,n=t(this),o=e.mode,a="show"===o,r=e.direction||"left",h="up"===r||"down"===r?"top":"left",l="up"===r||"left"===r?"-=":"+=",c="+="===l?"-=":"+=",u={opacity:0};t.effects.createPlaceholder(n),s=e.distance||n["top"===h?"outerHeight":"outerWidth"](!0)/2,u[h]=l+s,a&&(n.css(u),u[h]=c+s,u.opacity=1),n.animate(u,{queue:!1,duration:e.duration,easing:e.easing,complete:i})}),t.effects.define("explode","hide",function(e,i){function s(){b.push(this),b.length===u*d&&n()}function n(){p.css({visibility:"visible"}),t(b).remove(),i()}var o,a,r,h,l,c,u=e.pieces?Math.round(Math.sqrt(e.pieces)):3,d=u,p=t(this),f=e.mode,g="show"===f,m=p.show().css("visibility","hidden").offset(),_=Math.ceil(p.outerWidth()/d),v=Math.ceil(p.outerHeight()/u),b=[];for(o=0;u>o;o++)for(h=m.top+o*v,c=o-(u-1)/2,a=0;d>a;a++)r=m.left+a*_,l=a-(d-1)/2,p.clone().appendTo("body").wrap("<div></div>").css({position:"absolute",visibility:"visible",left:-a*_,top:-o*v}).parent().addClass("ui-effects-explode").css({position:"absolute",overflow:"hidden",width:_,height:v,left:r+(g?l*_:0),top:h+(g?c*v:0),opacity:g?0:1}).animate({left:r+(g?0:l*_),top:h+(g?0:c*v),opacity:g?1:0},e.duration||500,e.easing,s)}),t.effects.define("fade","toggle",function(e,i){var s="show"===e.mode;t(this).css("opacity",s?0:1).animate({opacity:s?1:0},{queue:!1,duration:e.duration,easing:e.easing,complete:i})}),t.effects.define("fold","hide",function(e,i){var s=t(this),n=e.mode,o="show"===n,a="hide"===n,r=e.size||15,h=/([0-9]+)%/.exec(r),l=!!e.horizFirst,c=l?["right","bottom"]:["bottom","right"],u=e.duration/2,d=t.effects.createPlaceholder(s),p=s.cssClip(),f={clip:t.extend({},p)},g={clip:t.extend({},p)},m=[p[c[0]],p[c[1]]],_=s.queue().length;h&&(r=parseInt(h[1],10)/100*m[a?0:1]),f.clip[c[0]]=r,g.clip[c[0]]=r,g.clip[c[1]]=0,o&&(s.cssClip(g.clip),d&&d.css(t.effects.clipToBox(g)),g.clip=p),s.queue(function(i){d&&d.animate(t.effects.clipToBox(f),u,e.easing).animate(t.effects.clipToBox(g),u,e.easing),i()}).animate(f,u,e.easing).animate(g,u,e.easing).queue(i),t.effects.unshift(s,_,4)}),t.effects.define("highlight","show",function(e,i){var s=t(this),n={backgroundColor:s.css("backgroundColor")};"hide"===e.mode&&(n.opacity=0),t.effects.saveStyle(s),s.css({backgroundImage:"none",backgroundColor:e.color||"#ffff99"}).animate(n,{queue:!1,duration:e.duration,easing:e.easing,complete:i})}),t.effects.define("size",function(e,i){var s,n,o,a=t(this),r=["fontSize"],h=["borderTopWidth","borderBottomWidth","paddingTop","paddingBottom"],l=["borderLeftWidth","borderRightWidth","paddingLeft","paddingRight"],c=e.mode,u="effect"!==c,d=e.scale||"both",p=e.origin||["middle","center"],f=a.css("position"),g=a.position(),m=t.effects.scaledDimensions(a),_=e.from||m,v=e.to||t.effects.scaledDimensions(a,0);t.effects.createPlaceholder(a),"show"===c&&(o=_,_=v,v=o),n={from:{y:_.height/m.height,x:_.width/m.width},to:{y:v.height/m.height,x:v.width/m.width}},("box"===d||"both"===d)&&(n.from.y!==n.to.y&&(_=t.effects.setTransition(a,h,n.from.y,_),v=t.effects.setTransition(a,h,n.to.y,v)),n.from.x!==n.to.x&&(_=t.effects.setTransition(a,l,n.from.x,_),v=t.effects.setTransition(a,l,n.to.x,v))),("content"===d||"both"===d)&&n.from.y!==n.to.y&&(_=t.effects.setTransition(a,r,n.from.y,_),v=t.effects.setTransition(a,r,n.to.y,v)),p&&(s=t.effects.getBaseline(p,m),_.top=(m.outerHeight-_.outerHeight)*s.y+g.top,_.left=(m.outerWidth-_.outerWidth)*s.x+g.left,v.top=(m.outerHeight-v.outerHeight)*s.y+g.top,v.left=(m.outerWidth-v.outerWidth)*s.x+g.left),a.css(_),("content"===d||"both"===d)&&(h=h.concat(["marginTop","marginBottom"]).concat(r),l=l.concat(["marginLeft","marginRight"]),a.find("*[width]").each(function(){var i=t(this),s=t.effects.scaledDimensions(i),o={height:s.height*n.from.y,width:s.width*n.from.x,outerHeight:s.outerHeight*n.from.y,outerWidth:s.outerWidth*n.from.x},a={height:s.height*n.to.y,width:s.width*n.to.x,outerHeight:s.height*n.to.y,outerWidth:s.width*n.to.x};n.from.y!==n.to.y&&(o=t.effects.setTransition(i,h,n.from.y,o),a=t.effects.setTransition(i,h,n.to.y,a)),n.from.x!==n.to.x&&(o=t.effects.setTransition(i,l,n.from.x,o),a=t.effects.setTransition(i,l,n.to.x,a)),u&&t.effects.saveStyle(i),i.css(o),i.animate(a,e.duration,e.easing,function(){u&&t.effects.restoreStyle(i)})})),a.animate(v,{queue:!1,duration:e.duration,easing:e.easing,complete:function(){var e=a.offset();0===v.opacity&&a.css("opacity",_.opacity),u||(a.css("position","static"===f?"relative":f).offset(e),t.effects.saveStyle(a)),i()}})}),t.effects.define("scale",function(e,i){var s=t(this),n=e.mode,o=parseInt(e.percent,10)||(0===parseInt(e.percent,10)?0:"effect"!==n?0:100),a=t.extend(!0,{from:t.effects.scaledDimensions(s),to:t.effects.scaledDimensions(s,o,e.direction||"both"),origin:e.origin||["middle","center"]},e);e.fade&&(a.from.opacity=1,a.to.opacity=0),t.effects.effect.size.call(this,a,i)}),t.effects.define("puff","hide",function(e,i){var s=t.extend(!0,{},e,{fade:!0,percent:parseInt(e.percent,10)||150});t.effects.effect.scale.call(this,s,i)}),t.effects.define("pulsate","show",function(e,i){var s=t(this),n=e.mode,o="show"===n,a="hide"===n,r=o||a,h=2*(e.times||5)+(r?1:0),l=e.duration/h,c=0,u=1,d=s.queue().length;for((o||!s.is(":visible"))&&(s.css("opacity",0).show(),c=1);h>u;u++)s.animate({opacity:c},l,e.easing),c=1-c;s.animate({opacity:c},l,e.easing),s.queue(i),t.effects.unshift(s,d,h+1)}),t.effects.define("shake",function(e,i){var s=1,n=t(this),o=e.direction||"left",a=e.distance||20,r=e.times||3,h=2*r+1,l=Math.round(e.duration/h),c="up"===o||"down"===o?"top":"left",u="up"===o||"left"===o,d={},p={},f={},g=n.queue().length;for(t.effects.createPlaceholder(n),d[c]=(u?"-=":"+=")+a,p[c]=(u?"+=":"-=")+2*a,f[c]=(u?"-=":"+=")+2*a,n.animate(d,l,e.easing);r>s;s++)n.animate(p,l,e.easing).animate(f,l,e.easing);n.animate(p,l,e.easing).animate(d,l/2,e.easing).queue(i),t.effects.unshift(n,g,h+1)}),t.effects.define("slide","show",function(e,i){var s,n,o=t(this),a={up:["bottom","top"],down:["top","bottom"],left:["right","left"],right:["left","right"]},r=e.mode,h=e.direction||"left",l="up"===h||"down"===h?"top":"left",c="up"===h||"left"===h,u=e.distance||o["top"===l?"outerHeight":"outerWidth"](!0),d={};t.effects.createPlaceholder(o),s=o.cssClip(),n=o.position()[l],d[l]=(c?-1:1)*u+n,d.clip=o.cssClip(),d.clip[a[h][1]]=d.clip[a[h][0]],"show"===r&&(o.cssClip(d.clip),o.css(l,d[l]),d.clip=s,d[l]=n),o.animate(d,{queue:!1,duration:e.duration,easing:e.easing,complete:i})});var f;t.uiBackCompat!==!1&&(f=t.effects.define("transfer",function(e,i){t(this).transfer(e,i)})),t.ui.focusable=function(i,s){var n,o,a,r,h,l=i.nodeName.toLowerCase();return"area"===l?(n=i.parentNode,o=n.name,i.href&&o&&"map"===n.nodeName.toLowerCase()?(a=t("img[usemap='#"+o+"']"),a.length>0&&a.is(":visible")):!1):(/^(input|select|textarea|button|object)$/.test(l)?(r=!i.disabled,r&&(h=t(i).closest("fieldset")[0],h&&(r=!h.disabled))):r="a"===l?i.href||s:s,r&&t(i).is(":visible")&&e(t(i)))},t.extend(t.expr[":"],{focusable:function(e){return t.ui.focusable(e,null!=t.attr(e,"tabindex"))}}),t.ui.focusable,t.fn.form=function(){return"string"==typeof this[0].form?this.closest("form"):t(this[0].form)},t.ui.formResetMixin={_formResetHandler:function(){var e=t(this);setTimeout(function(){var i=e.data("ui-form-reset-instances");t.each(i,function(){this.refresh()})})},_bindFormResetHandler:function(){if(this.form=this.element.form(),this.form.length){var t=this.form.data("ui-form-reset-instances")||[];t.length||this.form.on("reset.ui-form-reset",this._formResetHandler),t.push(this),this.form.data("ui-form-reset-instances",t)}},_unbindFormResetHandler:function(){if(this.form.length){var e=this.form.data("ui-form-reset-instances");e.splice(t.inArray(this,e),1),e.length?this.form.data("ui-form-reset-instances",e):this.form.removeData("ui-form-reset-instances").off("reset.ui-form-reset")}}},"1.7"===t.fn.jquery.substring(0,3)&&(t.each(["Width","Height"],function(e,i){function s(e,i,s,o){return t.each(n,function(){i-=parseFloat(t.css(e,"padding"+this))||0,s&&(i-=parseFloat(t.css(e,"border"+this+"Width"))||0),o&&(i-=parseFloat(t.css(e,"margin"+this))||0)}),i}var n="Width"===i?["Left","Right"]:["Top","Bottom"],o=i.toLowerCase(),a={innerWidth:t.fn.innerWidth,innerHeight:t.fn.innerHeight,outerWidth:t.fn.outerWidth,outerHeight:t.fn.outerHeight};t.fn["inner"+i]=function(e){return void 0===e?a["inner"+i].call(this):this.each(function(){t(this).css(o,s(this,e)+"px")})},t.fn["outer"+i]=function(e,n){return"number"!=typeof e?a["outer"+i].call(this,e):this.each(function(){t(this).css(o,s(this,e,!0,n)+"px")})}}),t.fn.addBack=function(t){return this.add(null==t?this.prevObject:this.prevObject.filter(t))}),t.ui.keyCode={BACKSPACE:8,COMMA:188,DELETE:46,DOWN:40,END:35,ENTER:13,ESCAPE:27,HOME:36,LEFT:37,PAGE_DOWN:34,PAGE_UP:33,PERIOD:190,RIGHT:39,SPACE:32,TAB:9,UP:38},t.ui.escapeSelector=function(){var t=/([!"#$%&'()*+,.\/:;<=>?@[\]^`{|}~])/g;return function(e){return e.replace(t,"\\$1")}}(),t.fn.labels=function(){var e,i,s,n,o;return this[0].labels&&this[0].labels.length?this.pushStack(this[0].labels):(n=this.eq(0).parents("label"),s=this.attr("id"),s&&(e=this.eq(0).parents().last(),o=e.add(e.length?e.siblings():this.siblings()),i="label[for='"+t.ui.escapeSelector(s)+"']",n=n.add(o.find(i).addBack(i))),this.pushStack(n))},t.fn.scrollParent=function(e){var i=this.css("position"),s="absolute"===i,n=e?/(auto|scroll|hidden)/:/(auto|scroll)/,o=this.parents().filter(function(){var e=t(this);return s&&"static"===e.css("position")?!1:n.test(e.css("overflow")+e.css("overflow-y")+e.css("overflow-x"))}).eq(0);return"fixed"!==i&&o.length?o:t(this[0].ownerDocument||document)},t.extend(t.expr[":"],{tabbable:function(e){var i=t.attr(e,"tabindex"),s=null!=i;return(!s||i>=0)&&t.ui.focusable(e,s)}}),t.fn.extend({uniqueId:function(){var t=0;return function(){return this.each(function(){this.id||(this.id="ui-id-"+ ++t)})}}(),removeUniqueId:function(){return this.each(function(){/^ui-id-\d+$/.test(this.id)&&t(this).removeAttr("id")})}}),t.widget("ui.accordion",{version:"1.12.1",options:{active:0,animate:{},classes:{"ui-accordion-header":"ui-corner-top","ui-accordion-header-collapsed":"ui-corner-all","ui-accordion-content":"ui-corner-bottom"},collapsible:!1,event:"click",header:"> li > :first-child, > :not(li):even",heightStyle:"auto",icons:{activeHeader:"ui-icon-triangle-1-s",header:"ui-icon-triangle-1-e"},activate:null,beforeActivate:null},hideProps:{borderTopWidth:"hide",borderBottomWidth:"hide",paddingTop:"hide",paddingBottom:"hide",height:"hide"},showProps:{borderTopWidth:"show",borderBottomWidth:"show",paddingTop:"show",paddingBottom:"show",height:"show"},_create:function(){var e=this.options;this.prevShow=this.prevHide=t(),this._addClass("ui-accordion","ui-widget ui-helper-reset"),this.element.attr("role","tablist"),e.collapsible||e.active!==!1&&null!=e.active||(e.active=0),this._processPanels(),0>e.active&&(e.active+=this.headers.length),this._refresh()},_getCreateEventData:function(){return{header:this.active,panel:this.active.length?this.active.next():t()}},_createIcons:function(){var e,i,s=this.options.icons;s&&(e=t("<span>"),this._addClass(e,"ui-accordion-header-icon","ui-icon "+s.header),e.prependTo(this.headers),i=this.active.children(".ui-accordion-header-icon"),this._removeClass(i,s.header)._addClass(i,null,s.activeHeader)._addClass(this.headers,"ui-accordion-icons"))},_destroyIcons:function(){this._removeClass(this.headers,"ui-accordion-icons"),this.headers.children(".ui-accordion-header-icon").remove()},_destroy:function(){var t;this.element.removeAttr("role"),this.headers.removeAttr("role aria-expanded aria-selected aria-controls tabIndex").removeUniqueId(),this._destroyIcons(),t=this.headers.next().css("display","").removeAttr("role aria-hidden aria-labelledby").removeUniqueId(),"content"!==this.options.heightStyle&&t.css("height","")},_setOption:function(t,e){return"active"===t?(this._activate(e),void 0):("event"===t&&(this.options.event&&this._off(this.headers,this.options.event),this._setupEvents(e)),this._super(t,e),"collapsible"!==t||e||this.options.active!==!1||this._activate(0),"icons"===t&&(this._destroyIcons(),e&&this._createIcons()),void 0)},_setOptionDisabled:function(t){this._super(t),this.element.attr("aria-disabled",t),this._toggleClass(null,"ui-state-disabled",!!t),this._toggleClass(this.headers.add(this.headers.next()),null,"ui-state-disabled",!!t)},_keydown:function(e){if(!e.altKey&&!e.ctrlKey){var i=t.ui.keyCode,s=this.headers.length,n=this.headers.index(e.target),o=!1;switch(e.keyCode){case i.RIGHT:case i.DOWN:o=this.headers[(n+1)%s];break;case i.LEFT:case i.UP:o=this.headers[(n-1+s)%s];break;case i.SPACE:case i.ENTER:this._eventHandler(e);break;case i.HOME:o=this.headers[0];break;case i.END:o=this.headers[s-1]}o&&(t(e.target).attr("tabIndex",-1),t(o).attr("tabIndex",0),t(o).trigger("focus"),e.preventDefault())}},_panelKeyDown:function(e){e.keyCode===t.ui.keyCode.UP&&e.ctrlKey&&t(e.currentTarget).prev().trigger("focus")},refresh:function(){var e=this.options;this._processPanels(),e.active===!1&&e.collapsible===!0||!this.headers.length?(e.active=!1,this.active=t()):e.active===!1?this._activate(0):this.active.length&&!t.contains(this.element[0],this.active[0])?this.headers.length===this.headers.find(".ui-state-disabled").length?(e.active=!1,this.active=t()):this._activate(Math.max(0,e.active-1)):e.active=this.headers.index(this.active),this._destroyIcons(),this._refresh()},_processPanels:function(){var t=this.headers,e=this.panels;this.headers=this.element.find(this.options.header),this._addClass(this.headers,"ui-accordion-header ui-accordion-header-collapsed","ui-state-default"),this.panels=this.headers.next().filter(":not(.ui-accordion-content-active)").hide(),this._addClass(this.panels,"ui-accordion-content","ui-helper-reset ui-widget-content"),e&&(this._off(t.not(this.headers)),this._off(e.not(this.panels)))},_refresh:function(){var e,i=this.options,s=i.heightStyle,n=this.element.parent();this.active=this._findActive(i.active),this._addClass(this.active,"ui-accordion-header-active","ui-state-active")._removeClass(this.active,"ui-accordion-header-collapsed"),this._addClass(this.active.next(),"ui-accordion-content-active"),this.active.next().show(),this.headers.attr("role","tab").each(function(){var e=t(this),i=e.uniqueId().attr("id"),s=e.next(),n=s.uniqueId().attr("id");e.attr("aria-controls",n),s.attr("aria-labelledby",i)}).next().attr("role","tabpanel"),this.headers.not(this.active).attr({"aria-selected":"false","aria-expanded":"false",tabIndex:-1}).next().attr({"aria-hidden":"true"}).hide(),this.active.length?this.active.attr({"aria-selected":"true","aria-expanded":"true",tabIndex:0}).next().attr({"aria-hidden":"false"}):this.headers.eq(0).attr("tabIndex",0),this._createIcons(),this._setupEvents(i.event),"fill"===s?(e=n.height(),this.element.siblings(":visible").each(function(){var i=t(this),s=i.css("position");"absolute"!==s&&"fixed"!==s&&(e-=i.outerHeight(!0))}),this.headers.each(function(){e-=t(this).outerHeight(!0)}),this.headers.next().each(function(){t(this).height(Math.max(0,e-t(this).innerHeight()+t(this).height()))}).css("overflow","auto")):"auto"===s&&(e=0,this.headers.next().each(function(){var i=t(this).is(":visible");i||t(this).show(),e=Math.max(e,t(this).css("height","").height()),i||t(this).hide()}).height(e))},_activate:function(e){var i=this._findActive(e)[0];i!==this.active[0]&&(i=i||this.active[0],this._eventHandler({target:i,currentTarget:i,preventDefault:t.noop}))},_findActive:function(e){return"number"==typeof e?this.headers.eq(e):t()},_setupEvents:function(e){var i={keydown:"_keydown"};e&&t.each(e.split(" "),function(t,e){i[e]="_eventHandler"}),this._off(this.headers.add(this.headers.next())),this._on(this.headers,i),this._on(this.headers.next(),{keydown:"_panelKeyDown"}),this._hoverable(this.headers),this._focusable(this.headers)},_eventHandler:function(e){var i,s,n=this.options,o=this.active,a=t(e.currentTarget),r=a[0]===o[0],h=r&&n.collapsible,l=h?t():a.next(),c=o.next(),u={oldHeader:o,oldPanel:c,newHeader:h?t():a,newPanel:l};e.preventDefault(),r&&!n.collapsible||this._trigger("beforeActivate",e,u)===!1||(n.active=h?!1:this.headers.index(a),this.active=r?t():a,this._toggle(u),this._removeClass(o,"ui-accordion-header-active","ui-state-active"),n.icons&&(i=o.children(".ui-accordion-header-icon"),this._removeClass(i,null,n.icons.activeHeader)._addClass(i,null,n.icons.header)),r||(this._removeClass(a,"ui-accordion-header-collapsed")._addClass(a,"ui-accordion-header-active","ui-state-active"),n.icons&&(s=a.children(".ui-accordion-header-icon"),this._removeClass(s,null,n.icons.header)._addClass(s,null,n.icons.activeHeader)),this._addClass(a.next(),"ui-accordion-content-active")))},_toggle:function(e){var i=e.newPanel,s=this.prevShow.length?this.prevShow:e.oldPanel;this.prevShow.add(this.prevHide).stop(!0,!0),this.prevShow=i,this.prevHide=s,this.options.animate?this._animate(i,s,e):(s.hide(),i.show(),this._toggleComplete(e)),s.attr({"aria-hidden":"true"}),s.prev().attr({"aria-selected":"false","aria-expanded":"false"}),i.length&&s.length?s.prev().attr({tabIndex:-1,"aria-expanded":"false"}):i.length&&this.headers.filter(function(){return 0===parseInt(t(this).attr("tabIndex"),10)}).attr("tabIndex",-1),i.attr("aria-hidden","false").prev().attr({"aria-selected":"true","aria-expanded":"true",tabIndex:0})},_animate:function(t,e,i){var s,n,o,a=this,r=0,h=t.css("box-sizing"),l=t.length&&(!e.length||t.index()<e.index()),c=this.options.animate||{},u=l&&c.down||c,d=function(){a._toggleComplete(i)};return"number"==typeof u&&(o=u),"string"==typeof u&&(n=u),n=n||u.easing||c.easing,o=o||u.duration||c.duration,e.length?t.length?(s=t.show().outerHeight(),e.animate(this.hideProps,{duration:o,easing:n,step:function(t,e){e.now=Math.round(t)}}),t.hide().animate(this.showProps,{duration:o,easing:n,complete:d,step:function(t,i){i.now=Math.round(t),"height"!==i.prop?"content-box"===h&&(r+=i.now):"content"!==a.options.heightStyle&&(i.now=Math.round(s-e.outerHeight()-r),r=0)}}),void 0):e.animate(this.hideProps,o,n,d):t.animate(this.showProps,o,n,d)},_toggleComplete:function(t){var e=t.oldPanel,i=e.prev();this._removeClass(e,"ui-accordion-content-active"),this._removeClass(i,"ui-accordion-header-active")._addClass(i,"ui-accordion-header-collapsed"),e.length&&(e.parent()[0].className=e.parent()[0].className),this._trigger("activate",null,t)}}),t.ui.safeActiveElement=function(t){var e;try{e=t.activeElement}catch(i){e=t.body}return e||(e=t.body),e.nodeName||(e=t.body),e},t.widget("ui.menu",{version:"1.12.1",defaultElement:"<ul>",delay:300,options:{icons:{submenu:"ui-icon-caret-1-e"},items:"> *",menus:"ul",position:{my:"left top",at:"right top"},role:"menu",blur:null,focus:null,select:null},_create:function(){this.activeMenu=this.element,this.mouseHandled=!1,this.element.uniqueId().attr({role:this.options.role,tabIndex:0}),this._addClass("ui-menu","ui-widget ui-widget-content"),this._on({"mousedown .ui-menu-item":function(t){t.preventDefault()},"click .ui-menu-item":function(e){var i=t(e.target),s=t(t.ui.safeActiveElement(this.document[0]));!this.mouseHandled&&i.not(".ui-state-disabled").length&&(this.select(e),e.isPropagationStopped()||(this.mouseHandled=!0),i.has(".ui-menu").length?this.expand(e):!this.element.is(":focus")&&s.closest(".ui-menu").length&&(this.element.trigger("focus",[!0]),this.active&&1===this.active.parents(".ui-menu").length&&clearTimeout(this.timer)))},"mouseenter .ui-menu-item":function(e){if(!this.previousFilter){var i=t(e.target).closest(".ui-menu-item"),s=t(e.currentTarget);i[0]===s[0]&&(this._removeClass(s.siblings().children(".ui-state-active"),null,"ui-state-active"),this.focus(e,s))}},mouseleave:"collapseAll","mouseleave .ui-menu":"collapseAll",focus:function(t,e){var i=this.active||this.element.find(this.options.items).eq(0);e||this.focus(t,i)},blur:function(e){this._delay(function(){var i=!t.contains(this.element[0],t.ui.safeActiveElement(this.document[0]));i&&this.collapseAll(e)})},keydown:"_keydown"}),this.refresh(),this._on(this.document,{click:function(t){this._closeOnDocumentClick(t)&&this.collapseAll(t),this.mouseHandled=!1}})},_destroy:function(){var e=this.element.find(".ui-menu-item").removeAttr("role aria-disabled"),i=e.children(".ui-menu-item-wrapper").removeUniqueId().removeAttr("tabIndex role aria-haspopup");this.element.removeAttr("aria-activedescendant").find(".ui-menu").addBack().removeAttr("role aria-labelledby aria-expanded aria-hidden aria-disabled tabIndex").removeUniqueId().show(),i.children().each(function(){var e=t(this);e.data("ui-menu-submenu-caret")&&e.remove()})},_keydown:function(e){var i,s,n,o,a=!0;switch(e.keyCode){case t.ui.keyCode.PAGE_UP:this.previousPage(e);break;case t.ui.keyCode.PAGE_DOWN:this.nextPage(e);break;case t.ui.keyCode.HOME:this._move("first","first",e);break;case t.ui.keyCode.END:this._move("last","last",e);break;case t.ui.keyCode.UP:this.previous(e);break;case t.ui.keyCode.DOWN:this.next(e);break;case t.ui.keyCode.LEFT:this.collapse(e);break;case t.ui.keyCode.RIGHT:this.active&&!this.active.is(".ui-state-disabled")&&this.expand(e);break;case t.ui.keyCode.ENTER:case t.ui.keyCode.SPACE:this._activate(e);break;case t.ui.keyCode.ESCAPE:this.collapse(e);break;default:a=!1,s=this.previousFilter||"",o=!1,n=e.keyCode>=96&&105>=e.keyCode?""+(e.keyCode-96):String.fromCharCode(e.keyCode),clearTimeout(this.filterTimer),n===s?o=!0:n=s+n,i=this._filterMenuItems(n),i=o&&-1!==i.index(this.active.next())?this.active.nextAll(".ui-menu-item"):i,i.length||(n=String.fromCharCode(e.keyCode),i=this._filterMenuItems(n)),i.length?(this.focus(e,i),this.previousFilter=n,this.filterTimer=this._delay(function(){delete this.previousFilter},1e3)):delete this.previousFilter}a&&e.preventDefault()},_activate:function(t){this.active&&!this.active.is(".ui-state-disabled")&&(this.active.children("[aria-haspopup='true']").length?this.expand(t):this.select(t))},refresh:function(){var e,i,s,n,o,a=this,r=this.options.icons.submenu,h=this.element.find(this.options.menus);this._toggleClass("ui-menu-icons",null,!!this.element.find(".ui-icon").length),s=h.filter(":not(.ui-menu)").hide().attr({role:this.options.role,"aria-hidden":"true","aria-expanded":"false"}).each(function(){var e=t(this),i=e.prev(),s=t("<span>").data("ui-menu-submenu-caret",!0);a._addClass(s,"ui-menu-icon","ui-icon "+r),i.attr("aria-haspopup","true").prepend(s),e.attr("aria-labelledby",i.attr("id"))}),this._addClass(s,"ui-menu","ui-widget ui-widget-content ui-front"),e=h.add(this.element),i=e.find(this.options.items),i.not(".ui-menu-item").each(function(){var e=t(this);a._isDivider(e)&&a._addClass(e,"ui-menu-divider","ui-widget-content")}),n=i.not(".ui-menu-item, .ui-menu-divider"),o=n.children().not(".ui-menu").uniqueId().attr({tabIndex:-1,role:this._itemRole()}),this._addClass(n,"ui-menu-item")._addClass(o,"ui-menu-item-wrapper"),i.filter(".ui-state-disabled").attr("aria-disabled","true"),this.active&&!t.contains(this.element[0],this.active[0])&&this.blur()},_itemRole:function(){return{menu:"menuitem",listbox:"option"}[this.options.role]},_setOption:function(t,e){if("icons"===t){var i=this.element.find(".ui-menu-icon");this._removeClass(i,null,this.options.icons.submenu)._addClass(i,null,e.submenu)}this._super(t,e)},_setOptionDisabled:function(t){this._super(t),this.element.attr("aria-disabled",t+""),this._toggleClass(null,"ui-state-disabled",!!t)},focus:function(t,e){var i,s,n;this.blur(t,t&&"focus"===t.type),this._scrollIntoView(e),this.active=e.first(),s=this.active.children(".ui-menu-item-wrapper"),this._addClass(s,null,"ui-state-active"),this.options.role&&this.element.attr("aria-activedescendant",s.attr("id")),n=this.active.parent().closest(".ui-menu-item").children(".ui-menu-item-wrapper"),this._addClass(n,null,"ui-state-active"),t&&"keydown"===t.type?this._close():this.timer=this._delay(function(){this._close()},this.delay),i=e.children(".ui-menu"),i.length&&t&&/^mouse/.test(t.type)&&this._startOpening(i),this.activeMenu=e.parent(),this._trigger("focus",t,{item:e})},_scrollIntoView:function(e){var i,s,n,o,a,r;this._hasScroll()&&(i=parseFloat(t.css(this.activeMenu[0],"borderTopWidth"))||0,s=parseFloat(t.css(this.activeMenu[0],"paddingTop"))||0,n=e.offset().top-this.activeMenu.offset().top-i-s,o=this.activeMenu.scrollTop(),a=this.activeMenu.height(),r=e.outerHeight(),0>n?this.activeMenu.scrollTop(o+n):n+r>a&&this.activeMenu.scrollTop(o+n-a+r))},blur:function(t,e){e||clearTimeout(this.timer),this.active&&(this._removeClass(this.active.children(".ui-menu-item-wrapper"),null,"ui-state-active"),this._trigger("blur",t,{item:this.active}),this.active=null)},_startOpening:function(t){clearTimeout(this.timer),"true"===t.attr("aria-hidden")&&(this.timer=this._delay(function(){this._close(),this._open(t)},this.delay))},_open:function(e){var i=t.extend({of:this.active},this.options.position);clearTimeout(this.timer),this.element.find(".ui-menu").not(e.parents(".ui-menu")).hide().attr("aria-hidden","true"),e.show().removeAttr("aria-hidden").attr("aria-expanded","true").position(i)},collapseAll:function(e,i){clearTimeout(this.timer),this.timer=this._delay(function(){var s=i?this.element:t(e&&e.target).closest(this.element.find(".ui-menu"));s.length||(s=this.element),this._close(s),this.blur(e),this._removeClass(s.find(".ui-state-active"),null,"ui-state-active"),this.activeMenu=s},this.delay)},_close:function(t){t||(t=this.active?this.active.parent():this.element),t.find(".ui-menu").hide().attr("aria-hidden","true").attr("aria-expanded","false")},_closeOnDocumentClick:function(e){return!t(e.target).closest(".ui-menu").length},_isDivider:function(t){return!/[^\-\u2014\u2013\s]/.test(t.text())},collapse:function(t){var e=this.active&&this.active.parent().closest(".ui-menu-item",this.element);e&&e.length&&(this._close(),this.focus(t,e))},expand:function(t){var e=this.active&&this.active.children(".ui-menu ").find(this.options.items).first();e&&e.length&&(this._open(e.parent()),this._delay(function(){this.focus(t,e)}))},next:function(t){this._move("next","first",t)},previous:function(t){this._move("prev","last",t)},isFirstItem:function(){return this.active&&!this.active.prevAll(".ui-menu-item").length},isLastItem:function(){return this.active&&!this.active.nextAll(".ui-menu-item").length},_move:function(t,e,i){var s;this.active&&(s="first"===t||"last"===t?this.active["first"===t?"prevAll":"nextAll"](".ui-menu-item").eq(-1):this.active[t+"All"](".ui-menu-item").eq(0)),s&&s.length&&this.active||(s=this.activeMenu.find(this.options.items)[e]()),this.focus(i,s)},nextPage:function(e){var i,s,n;return this.active?(this.isLastItem()||(this._hasScroll()?(s=this.active.offset().top,n=this.element.height(),this.active.nextAll(".ui-menu-item").each(function(){return i=t(this),0>i.offset().top-s-n}),this.focus(e,i)):this.focus(e,this.activeMenu.find(this.options.items)[this.active?"last":"first"]())),void 0):(this.next(e),void 0)},previousPage:function(e){var i,s,n;return this.active?(this.isFirstItem()||(this._hasScroll()?(s=this.active.offset().top,n=this.element.height(),this.active.prevAll(".ui-menu-item").each(function(){return i=t(this),i.offset().top-s+n>0}),this.focus(e,i)):this.focus(e,this.activeMenu.find(this.options.items).first())),void 0):(this.next(e),void 0)},_hasScroll:function(){return this.element.outerHeight()<this.element.prop("scrollHeight")},select:function(e){this.active=this.active||t(e.target).closest(".ui-menu-item");var i={item:this.active};this.active.has(".ui-menu").length||this.collapseAll(e,!0),this._trigger("select",e,i)},_filterMenuItems:function(e){var i=e.replace(/[\-\[\]{}()*+?.,\\\^$|#\s]/g,"\\$&"),s=RegExp("^"+i,"i");return this.activeMenu.find(this.options.items).filter(".ui-menu-item").filter(function(){return s.test(t.trim(t(this).children(".ui-menu-item-wrapper").text()))})}}),t.widget("ui.autocomplete",{version:"1.12.1",defaultElement:"<input>",options:{appendTo:null,autoFocus:!1,delay:300,minLength:1,position:{my:"left top",at:"left bottom",collision:"none"},source:null,change:null,close:null,focus:null,open:null,response:null,search:null,select:null},requestIndex:0,pending:0,_create:function(){var e,i,s,n=this.element[0].nodeName.toLowerCase(),o="textarea"===n,a="input"===n; +this.isMultiLine=o||!a&&this._isContentEditable(this.element),this.valueMethod=this.element[o||a?"val":"text"],this.isNewMenu=!0,this._addClass("ui-autocomplete-input"),this.element.attr("autocomplete","off"),this._on(this.element,{keydown:function(n){if(this.element.prop("readOnly"))return e=!0,s=!0,i=!0,void 0;e=!1,s=!1,i=!1;var o=t.ui.keyCode;switch(n.keyCode){case o.PAGE_UP:e=!0,this._move("previousPage",n);break;case o.PAGE_DOWN:e=!0,this._move("nextPage",n);break;case o.UP:e=!0,this._keyEvent("previous",n);break;case o.DOWN:e=!0,this._keyEvent("next",n);break;case o.ENTER:this.menu.active&&(e=!0,n.preventDefault(),this.menu.select(n));break;case o.TAB:this.menu.active&&this.menu.select(n);break;case o.ESCAPE:this.menu.element.is(":visible")&&(this.isMultiLine||this._value(this.term),this.close(n),n.preventDefault());break;default:i=!0,this._searchTimeout(n)}},keypress:function(s){if(e)return e=!1,(!this.isMultiLine||this.menu.element.is(":visible"))&&s.preventDefault(),void 0;if(!i){var n=t.ui.keyCode;switch(s.keyCode){case n.PAGE_UP:this._move("previousPage",s);break;case n.PAGE_DOWN:this._move("nextPage",s);break;case n.UP:this._keyEvent("previous",s);break;case n.DOWN:this._keyEvent("next",s)}}},input:function(t){return s?(s=!1,t.preventDefault(),void 0):(this._searchTimeout(t),void 0)},focus:function(){this.selectedItem=null,this.previous=this._value()},blur:function(t){return this.cancelBlur?(delete this.cancelBlur,void 0):(clearTimeout(this.searching),this.close(t),this._change(t),void 0)}}),this._initSource(),this.menu=t("<ul>").appendTo(this._appendTo()).menu({role:null}).hide().menu("instance"),this._addClass(this.menu.element,"ui-autocomplete","ui-front"),this._on(this.menu.element,{mousedown:function(e){e.preventDefault(),this.cancelBlur=!0,this._delay(function(){delete this.cancelBlur,this.element[0]!==t.ui.safeActiveElement(this.document[0])&&this.element.trigger("focus")})},menufocus:function(e,i){var s,n;return this.isNewMenu&&(this.isNewMenu=!1,e.originalEvent&&/^mouse/.test(e.originalEvent.type))?(this.menu.blur(),this.document.one("mousemove",function(){t(e.target).trigger(e.originalEvent)}),void 0):(n=i.item.data("ui-autocomplete-item"),!1!==this._trigger("focus",e,{item:n})&&e.originalEvent&&/^key/.test(e.originalEvent.type)&&this._value(n.value),s=i.item.attr("aria-label")||n.value,s&&t.trim(s).length&&(this.liveRegion.children().hide(),t("<div>").text(s).appendTo(this.liveRegion)),void 0)},menuselect:function(e,i){var s=i.item.data("ui-autocomplete-item"),n=this.previous;this.element[0]!==t.ui.safeActiveElement(this.document[0])&&(this.element.trigger("focus"),this.previous=n,this._delay(function(){this.previous=n,this.selectedItem=s})),!1!==this._trigger("select",e,{item:s})&&this._value(s.value),this.term=this._value(),this.close(e),this.selectedItem=s}}),this.liveRegion=t("<div>",{role:"status","aria-live":"assertive","aria-relevant":"additions"}).appendTo(this.document[0].body),this._addClass(this.liveRegion,null,"ui-helper-hidden-accessible"),this._on(this.window,{beforeunload:function(){this.element.removeAttr("autocomplete")}})},_destroy:function(){clearTimeout(this.searching),this.element.removeAttr("autocomplete"),this.menu.element.remove(),this.liveRegion.remove()},_setOption:function(t,e){this._super(t,e),"source"===t&&this._initSource(),"appendTo"===t&&this.menu.element.appendTo(this._appendTo()),"disabled"===t&&e&&this.xhr&&this.xhr.abort()},_isEventTargetInWidget:function(e){var i=this.menu.element[0];return e.target===this.element[0]||e.target===i||t.contains(i,e.target)},_closeOnClickOutside:function(t){this._isEventTargetInWidget(t)||this.close()},_appendTo:function(){var e=this.options.appendTo;return e&&(e=e.jquery||e.nodeType?t(e):this.document.find(e).eq(0)),e&&e[0]||(e=this.element.closest(".ui-front, dialog")),e.length||(e=this.document[0].body),e},_initSource:function(){var e,i,s=this;t.isArray(this.options.source)?(e=this.options.source,this.source=function(i,s){s(t.ui.autocomplete.filter(e,i.term))}):"string"==typeof this.options.source?(i=this.options.source,this.source=function(e,n){s.xhr&&s.xhr.abort(),s.xhr=t.ajax({url:i,data:e,dataType:"json",success:function(t){n(t)},error:function(){n([])}})}):this.source=this.options.source},_searchTimeout:function(t){clearTimeout(this.searching),this.searching=this._delay(function(){var e=this.term===this._value(),i=this.menu.element.is(":visible"),s=t.altKey||t.ctrlKey||t.metaKey||t.shiftKey;(!e||e&&!i&&!s)&&(this.selectedItem=null,this.search(null,t))},this.options.delay)},search:function(t,e){return t=null!=t?t:this._value(),this.term=this._value(),t.length<this.options.minLength?this.close(e):this._trigger("search",e)!==!1?this._search(t):void 0},_search:function(t){this.pending++,this._addClass("ui-autocomplete-loading"),this.cancelSearch=!1,this.source({term:t},this._response())},_response:function(){var e=++this.requestIndex;return t.proxy(function(t){e===this.requestIndex&&this.__response(t),this.pending--,this.pending||this._removeClass("ui-autocomplete-loading")},this)},__response:function(t){t&&(t=this._normalize(t)),this._trigger("response",null,{content:t}),!this.options.disabled&&t&&t.length&&!this.cancelSearch?(this._suggest(t),this._trigger("open")):this._close()},close:function(t){this.cancelSearch=!0,this._close(t)},_close:function(t){this._off(this.document,"mousedown"),this.menu.element.is(":visible")&&(this.menu.element.hide(),this.menu.blur(),this.isNewMenu=!0,this._trigger("close",t))},_change:function(t){this.previous!==this._value()&&this._trigger("change",t,{item:this.selectedItem})},_normalize:function(e){return e.length&&e[0].label&&e[0].value?e:t.map(e,function(e){return"string"==typeof e?{label:e,value:e}:t.extend({},e,{label:e.label||e.value,value:e.value||e.label})})},_suggest:function(e){var i=this.menu.element.empty();this._renderMenu(i,e),this.isNewMenu=!0,this.menu.refresh(),i.show(),this._resizeMenu(),i.position(t.extend({of:this.element},this.options.position)),this.options.autoFocus&&this.menu.next(),this._on(this.document,{mousedown:"_closeOnClickOutside"})},_resizeMenu:function(){var t=this.menu.element;t.outerWidth(Math.max(t.width("").outerWidth()+1,this.element.outerWidth()))},_renderMenu:function(e,i){var s=this;t.each(i,function(t,i){s._renderItemData(e,i)})},_renderItemData:function(t,e){return this._renderItem(t,e).data("ui-autocomplete-item",e)},_renderItem:function(e,i){return t("<li>").append(t("<div>").text(i.label)).appendTo(e)},_move:function(t,e){return this.menu.element.is(":visible")?this.menu.isFirstItem()&&/^previous/.test(t)||this.menu.isLastItem()&&/^next/.test(t)?(this.isMultiLine||this._value(this.term),this.menu.blur(),void 0):(this.menu[t](e),void 0):(this.search(null,e),void 0)},widget:function(){return this.menu.element},_value:function(){return this.valueMethod.apply(this.element,arguments)},_keyEvent:function(t,e){(!this.isMultiLine||this.menu.element.is(":visible"))&&(this._move(t,e),e.preventDefault())},_isContentEditable:function(t){if(!t.length)return!1;var e=t.prop("contentEditable");return"inherit"===e?this._isContentEditable(t.parent()):"true"===e}}),t.extend(t.ui.autocomplete,{escapeRegex:function(t){return t.replace(/[\-\[\]{}()*+?.,\\\^$|#\s]/g,"\\$&")},filter:function(e,i){var s=RegExp(t.ui.autocomplete.escapeRegex(i),"i");return t.grep(e,function(t){return s.test(t.label||t.value||t)})}}),t.widget("ui.autocomplete",t.ui.autocomplete,{options:{messages:{noResults:"No search results.",results:function(t){return t+(t>1?" results are":" result is")+" available, use up and down arrow keys to navigate."}}},__response:function(e){var i;this._superApply(arguments),this.options.disabled||this.cancelSearch||(i=e&&e.length?this.options.messages.results(e.length):this.options.messages.noResults,this.liveRegion.children().hide(),t("<div>").text(i).appendTo(this.liveRegion))}}),t.ui.autocomplete;var g=/ui-corner-([a-z]){2,6}/g;t.widget("ui.controlgroup",{version:"1.12.1",defaultElement:"<div>",options:{direction:"horizontal",disabled:null,onlyVisible:!0,items:{button:"input[type=button], input[type=submit], input[type=reset], button, a",controlgroupLabel:".ui-controlgroup-label",checkboxradio:"input[type='checkbox'], input[type='radio']",selectmenu:"select",spinner:".ui-spinner-input"}},_create:function(){this._enhance()},_enhance:function(){this.element.attr("role","toolbar"),this.refresh()},_destroy:function(){this._callChildMethod("destroy"),this.childWidgets.removeData("ui-controlgroup-data"),this.element.removeAttr("role"),this.options.items.controlgroupLabel&&this.element.find(this.options.items.controlgroupLabel).find(".ui-controlgroup-label-contents").contents().unwrap()},_initWidgets:function(){var e=this,i=[];t.each(this.options.items,function(s,n){var o,a={};return n?"controlgroupLabel"===s?(o=e.element.find(n),o.each(function(){var e=t(this);e.children(".ui-controlgroup-label-contents").length||e.contents().wrapAll("<span class='ui-controlgroup-label-contents'></span>")}),e._addClass(o,null,"ui-widget ui-widget-content ui-state-default"),i=i.concat(o.get()),void 0):(t.fn[s]&&(a=e["_"+s+"Options"]?e["_"+s+"Options"]("middle"):{classes:{}},e.element.find(n).each(function(){var n=t(this),o=n[s]("instance"),r=t.widget.extend({},a);if("button"!==s||!n.parent(".ui-spinner").length){o||(o=n[s]()[s]("instance")),o&&(r.classes=e._resolveClassesValues(r.classes,o)),n[s](r);var h=n[s]("widget");t.data(h[0],"ui-controlgroup-data",o?o:n[s]("instance")),i.push(h[0])}})),void 0):void 0}),this.childWidgets=t(t.unique(i)),this._addClass(this.childWidgets,"ui-controlgroup-item")},_callChildMethod:function(e){this.childWidgets.each(function(){var i=t(this),s=i.data("ui-controlgroup-data");s&&s[e]&&s[e]()})},_updateCornerClass:function(t,e){var i="ui-corner-top ui-corner-bottom ui-corner-left ui-corner-right ui-corner-all",s=this._buildSimpleOptions(e,"label").classes.label;this._removeClass(t,null,i),this._addClass(t,null,s)},_buildSimpleOptions:function(t,e){var i="vertical"===this.options.direction,s={classes:{}};return s.classes[e]={middle:"",first:"ui-corner-"+(i?"top":"left"),last:"ui-corner-"+(i?"bottom":"right"),only:"ui-corner-all"}[t],s},_spinnerOptions:function(t){var e=this._buildSimpleOptions(t,"ui-spinner");return e.classes["ui-spinner-up"]="",e.classes["ui-spinner-down"]="",e},_buttonOptions:function(t){return this._buildSimpleOptions(t,"ui-button")},_checkboxradioOptions:function(t){return this._buildSimpleOptions(t,"ui-checkboxradio-label")},_selectmenuOptions:function(t){var e="vertical"===this.options.direction;return{width:e?"auto":!1,classes:{middle:{"ui-selectmenu-button-open":"","ui-selectmenu-button-closed":""},first:{"ui-selectmenu-button-open":"ui-corner-"+(e?"top":"tl"),"ui-selectmenu-button-closed":"ui-corner-"+(e?"top":"left")},last:{"ui-selectmenu-button-open":e?"":"ui-corner-tr","ui-selectmenu-button-closed":"ui-corner-"+(e?"bottom":"right")},only:{"ui-selectmenu-button-open":"ui-corner-top","ui-selectmenu-button-closed":"ui-corner-all"}}[t]}},_resolveClassesValues:function(e,i){var s={};return t.each(e,function(n){var o=i.options.classes[n]||"";o=t.trim(o.replace(g,"")),s[n]=(o+" "+e[n]).replace(/\s+/g," ")}),s},_setOption:function(t,e){return"direction"===t&&this._removeClass("ui-controlgroup-"+this.options.direction),this._super(t,e),"disabled"===t?(this._callChildMethod(e?"disable":"enable"),void 0):(this.refresh(),void 0)},refresh:function(){var e,i=this;this._addClass("ui-controlgroup ui-controlgroup-"+this.options.direction),"horizontal"===this.options.direction&&this._addClass(null,"ui-helper-clearfix"),this._initWidgets(),e=this.childWidgets,this.options.onlyVisible&&(e=e.filter(":visible")),e.length&&(t.each(["first","last"],function(t,s){var n=e[s]().data("ui-controlgroup-data");if(n&&i["_"+n.widgetName+"Options"]){var o=i["_"+n.widgetName+"Options"](1===e.length?"only":s);o.classes=i._resolveClassesValues(o.classes,n),n.element[n.widgetName](o)}else i._updateCornerClass(e[s](),s)}),this._callChildMethod("refresh"))}}),t.widget("ui.checkboxradio",[t.ui.formResetMixin,{version:"1.12.1",options:{disabled:null,label:null,icon:!0,classes:{"ui-checkboxradio-label":"ui-corner-all","ui-checkboxradio-icon":"ui-corner-all"}},_getCreateOptions:function(){var e,i,s=this,n=this._super()||{};return this._readType(),i=this.element.labels(),this.label=t(i[i.length-1]),this.label.length||t.error("No label found for checkboxradio widget"),this.originalLabel="",this.label.contents().not(this.element[0]).each(function(){s.originalLabel+=3===this.nodeType?t(this).text():this.outerHTML}),this.originalLabel&&(n.label=this.originalLabel),e=this.element[0].disabled,null!=e&&(n.disabled=e),n},_create:function(){var t=this.element[0].checked;this._bindFormResetHandler(),null==this.options.disabled&&(this.options.disabled=this.element[0].disabled),this._setOption("disabled",this.options.disabled),this._addClass("ui-checkboxradio","ui-helper-hidden-accessible"),this._addClass(this.label,"ui-checkboxradio-label","ui-button ui-widget"),"radio"===this.type&&this._addClass(this.label,"ui-checkboxradio-radio-label"),this.options.label&&this.options.label!==this.originalLabel?this._updateLabel():this.originalLabel&&(this.options.label=this.originalLabel),this._enhance(),t&&(this._addClass(this.label,"ui-checkboxradio-checked","ui-state-active"),this.icon&&this._addClass(this.icon,null,"ui-state-hover")),this._on({change:"_toggleClasses",focus:function(){this._addClass(this.label,null,"ui-state-focus ui-visual-focus")},blur:function(){this._removeClass(this.label,null,"ui-state-focus ui-visual-focus")}})},_readType:function(){var e=this.element[0].nodeName.toLowerCase();this.type=this.element[0].type,"input"===e&&/radio|checkbox/.test(this.type)||t.error("Can't create checkboxradio on element.nodeName="+e+" and element.type="+this.type)},_enhance:function(){this._updateIcon(this.element[0].checked)},widget:function(){return this.label},_getRadioGroup:function(){var e,i=this.element[0].name,s="input[name='"+t.ui.escapeSelector(i)+"']";return i?(e=this.form.length?t(this.form[0].elements).filter(s):t(s).filter(function(){return 0===t(this).form().length}),e.not(this.element)):t([])},_toggleClasses:function(){var e=this.element[0].checked;this._toggleClass(this.label,"ui-checkboxradio-checked","ui-state-active",e),this.options.icon&&"checkbox"===this.type&&this._toggleClass(this.icon,null,"ui-icon-check ui-state-checked",e)._toggleClass(this.icon,null,"ui-icon-blank",!e),"radio"===this.type&&this._getRadioGroup().each(function(){var e=t(this).checkboxradio("instance");e&&e._removeClass(e.label,"ui-checkboxradio-checked","ui-state-active")})},_destroy:function(){this._unbindFormResetHandler(),this.icon&&(this.icon.remove(),this.iconSpace.remove())},_setOption:function(t,e){return"label"!==t||e?(this._super(t,e),"disabled"===t?(this._toggleClass(this.label,null,"ui-state-disabled",e),this.element[0].disabled=e,void 0):(this.refresh(),void 0)):void 0},_updateIcon:function(e){var i="ui-icon ui-icon-background ";this.options.icon?(this.icon||(this.icon=t("<span>"),this.iconSpace=t("<span> </span>"),this._addClass(this.iconSpace,"ui-checkboxradio-icon-space")),"checkbox"===this.type?(i+=e?"ui-icon-check ui-state-checked":"ui-icon-blank",this._removeClass(this.icon,null,e?"ui-icon-blank":"ui-icon-check")):i+="ui-icon-blank",this._addClass(this.icon,"ui-checkboxradio-icon",i),e||this._removeClass(this.icon,null,"ui-icon-check ui-state-checked"),this.icon.prependTo(this.label).after(this.iconSpace)):void 0!==this.icon&&(this.icon.remove(),this.iconSpace.remove(),delete this.icon)},_updateLabel:function(){var t=this.label.contents().not(this.element[0]);this.icon&&(t=t.not(this.icon[0])),this.iconSpace&&(t=t.not(this.iconSpace[0])),t.remove(),this.label.append(this.options.label)},refresh:function(){var t=this.element[0].checked,e=this.element[0].disabled;this._updateIcon(t),this._toggleClass(this.label,"ui-checkboxradio-checked","ui-state-active",t),null!==this.options.label&&this._updateLabel(),e!==this.options.disabled&&this._setOptions({disabled:e})}}]),t.ui.checkboxradio,t.widget("ui.button",{version:"1.12.1",defaultElement:"<button>",options:{classes:{"ui-button":"ui-corner-all"},disabled:null,icon:null,iconPosition:"beginning",label:null,showLabel:!0},_getCreateOptions:function(){var t,e=this._super()||{};return this.isInput=this.element.is("input"),t=this.element[0].disabled,null!=t&&(e.disabled=t),this.originalLabel=this.isInput?this.element.val():this.element.html(),this.originalLabel&&(e.label=this.originalLabel),e},_create:function(){!this.option.showLabel&!this.options.icon&&(this.options.showLabel=!0),null==this.options.disabled&&(this.options.disabled=this.element[0].disabled||!1),this.hasTitle=!!this.element.attr("title"),this.options.label&&this.options.label!==this.originalLabel&&(this.isInput?this.element.val(this.options.label):this.element.html(this.options.label)),this._addClass("ui-button","ui-widget"),this._setOption("disabled",this.options.disabled),this._enhance(),this.element.is("a")&&this._on({keyup:function(e){e.keyCode===t.ui.keyCode.SPACE&&(e.preventDefault(),this.element[0].click?this.element[0].click():this.element.trigger("click"))}})},_enhance:function(){this.element.is("button")||this.element.attr("role","button"),this.options.icon&&(this._updateIcon("icon",this.options.icon),this._updateTooltip())},_updateTooltip:function(){this.title=this.element.attr("title"),this.options.showLabel||this.title||this.element.attr("title",this.options.label)},_updateIcon:function(e,i){var s="iconPosition"!==e,n=s?this.options.iconPosition:i,o="top"===n||"bottom"===n;this.icon?s&&this._removeClass(this.icon,null,this.options.icon):(this.icon=t("<span>"),this._addClass(this.icon,"ui-button-icon","ui-icon"),this.options.showLabel||this._addClass("ui-button-icon-only")),s&&this._addClass(this.icon,null,i),this._attachIcon(n),o?(this._addClass(this.icon,null,"ui-widget-icon-block"),this.iconSpace&&this.iconSpace.remove()):(this.iconSpace||(this.iconSpace=t("<span> </span>"),this._addClass(this.iconSpace,"ui-button-icon-space")),this._removeClass(this.icon,null,"ui-wiget-icon-block"),this._attachIconSpace(n))},_destroy:function(){this.element.removeAttr("role"),this.icon&&this.icon.remove(),this.iconSpace&&this.iconSpace.remove(),this.hasTitle||this.element.removeAttr("title")},_attachIconSpace:function(t){this.icon[/^(?:end|bottom)/.test(t)?"before":"after"](this.iconSpace)},_attachIcon:function(t){this.element[/^(?:end|bottom)/.test(t)?"append":"prepend"](this.icon)},_setOptions:function(t){var e=void 0===t.showLabel?this.options.showLabel:t.showLabel,i=void 0===t.icon?this.options.icon:t.icon;e||i||(t.showLabel=!0),this._super(t)},_setOption:function(t,e){"icon"===t&&(e?this._updateIcon(t,e):this.icon&&(this.icon.remove(),this.iconSpace&&this.iconSpace.remove())),"iconPosition"===t&&this._updateIcon(t,e),"showLabel"===t&&(this._toggleClass("ui-button-icon-only",null,!e),this._updateTooltip()),"label"===t&&(this.isInput?this.element.val(e):(this.element.html(e),this.icon&&(this._attachIcon(this.options.iconPosition),this._attachIconSpace(this.options.iconPosition)))),this._super(t,e),"disabled"===t&&(this._toggleClass(null,"ui-state-disabled",e),this.element[0].disabled=e,e&&this.element.blur())},refresh:function(){var t=this.element.is("input, button")?this.element[0].disabled:this.element.hasClass("ui-button-disabled");t!==this.options.disabled&&this._setOptions({disabled:t}),this._updateTooltip()}}),t.uiBackCompat!==!1&&(t.widget("ui.button",t.ui.button,{options:{text:!0,icons:{primary:null,secondary:null}},_create:function(){this.options.showLabel&&!this.options.text&&(this.options.showLabel=this.options.text),!this.options.showLabel&&this.options.text&&(this.options.text=this.options.showLabel),this.options.icon||!this.options.icons.primary&&!this.options.icons.secondary?this.options.icon&&(this.options.icons.primary=this.options.icon):this.options.icons.primary?this.options.icon=this.options.icons.primary:(this.options.icon=this.options.icons.secondary,this.options.iconPosition="end"),this._super()},_setOption:function(t,e){return"text"===t?(this._super("showLabel",e),void 0):("showLabel"===t&&(this.options.text=e),"icon"===t&&(this.options.icons.primary=e),"icons"===t&&(e.primary?(this._super("icon",e.primary),this._super("iconPosition","beginning")):e.secondary&&(this._super("icon",e.secondary),this._super("iconPosition","end"))),this._superApply(arguments),void 0)}}),t.fn.button=function(e){return function(){return!this.length||this.length&&"INPUT"!==this[0].tagName||this.length&&"INPUT"===this[0].tagName&&"checkbox"!==this.attr("type")&&"radio"!==this.attr("type")?e.apply(this,arguments):(t.ui.checkboxradio||t.error("Checkboxradio widget missing"),0===arguments.length?this.checkboxradio({icon:!1}):this.checkboxradio.apply(this,arguments))}}(t.fn.button),t.fn.buttonset=function(){return t.ui.controlgroup||t.error("Controlgroup widget missing"),"option"===arguments[0]&&"items"===arguments[1]&&arguments[2]?this.controlgroup.apply(this,[arguments[0],"items.button",arguments[2]]):"option"===arguments[0]&&"items"===arguments[1]?this.controlgroup.apply(this,[arguments[0],"items.button"]):("object"==typeof arguments[0]&&arguments[0].items&&(arguments[0].items={button:arguments[0].items}),this.controlgroup.apply(this,arguments))}),t.ui.button,t.extend(t.ui,{datepicker:{version:"1.12.1"}});var m;t.extend(s.prototype,{markerClassName:"hasDatepicker",maxRows:4,_widgetDatepicker:function(){return this.dpDiv},setDefaults:function(t){return a(this._defaults,t||{}),this},_attachDatepicker:function(e,i){var s,n,o;s=e.nodeName.toLowerCase(),n="div"===s||"span"===s,e.id||(this.uuid+=1,e.id="dp"+this.uuid),o=this._newInst(t(e),n),o.settings=t.extend({},i||{}),"input"===s?this._connectDatepicker(e,o):n&&this._inlineDatepicker(e,o)},_newInst:function(e,i){var s=e[0].id.replace(/([^A-Za-z0-9_\-])/g,"\\\\$1");return{id:s,input:e,selectedDay:0,selectedMonth:0,selectedYear:0,drawMonth:0,drawYear:0,inline:i,dpDiv:i?n(t("<div class='"+this._inlineClass+" ui-datepicker ui-widget ui-widget-content ui-helper-clearfix ui-corner-all'></div>")):this.dpDiv}},_connectDatepicker:function(e,i){var s=t(e);i.append=t([]),i.trigger=t([]),s.hasClass(this.markerClassName)||(this._attachments(s,i),s.addClass(this.markerClassName).on("keydown",this._doKeyDown).on("keypress",this._doKeyPress).on("keyup",this._doKeyUp),this._autoSize(i),t.data(e,"datepicker",i),i.settings.disabled&&this._disableDatepicker(e))},_attachments:function(e,i){var s,n,o,a=this._get(i,"appendText"),r=this._get(i,"isRTL");i.append&&i.append.remove(),a&&(i.append=t("<span class='"+this._appendClass+"'>"+a+"</span>"),e[r?"before":"after"](i.append)),e.off("focus",this._showDatepicker),i.trigger&&i.trigger.remove(),s=this._get(i,"showOn"),("focus"===s||"both"===s)&&e.on("focus",this._showDatepicker),("button"===s||"both"===s)&&(n=this._get(i,"buttonText"),o=this._get(i,"buttonImage"),i.trigger=t(this._get(i,"buttonImageOnly")?t("<img/>").addClass(this._triggerClass).attr({src:o,alt:n,title:n}):t("<button type='button'></button>").addClass(this._triggerClass).html(o?t("<img/>").attr({src:o,alt:n,title:n}):n)),e[r?"before":"after"](i.trigger),i.trigger.on("click",function(){return t.datepicker._datepickerShowing&&t.datepicker._lastInput===e[0]?t.datepicker._hideDatepicker():t.datepicker._datepickerShowing&&t.datepicker._lastInput!==e[0]?(t.datepicker._hideDatepicker(),t.datepicker._showDatepicker(e[0])):t.datepicker._showDatepicker(e[0]),!1}))},_autoSize:function(t){if(this._get(t,"autoSize")&&!t.inline){var e,i,s,n,o=new Date(2009,11,20),a=this._get(t,"dateFormat");a.match(/[DM]/)&&(e=function(t){for(i=0,s=0,n=0;t.length>n;n++)t[n].length>i&&(i=t[n].length,s=n);return s},o.setMonth(e(this._get(t,a.match(/MM/)?"monthNames":"monthNamesShort"))),o.setDate(e(this._get(t,a.match(/DD/)?"dayNames":"dayNamesShort"))+20-o.getDay())),t.input.attr("size",this._formatDate(t,o).length)}},_inlineDatepicker:function(e,i){var s=t(e);s.hasClass(this.markerClassName)||(s.addClass(this.markerClassName).append(i.dpDiv),t.data(e,"datepicker",i),this._setDate(i,this._getDefaultDate(i),!0),this._updateDatepicker(i),this._updateAlternate(i),i.settings.disabled&&this._disableDatepicker(e),i.dpDiv.css("display","block"))},_dialogDatepicker:function(e,i,s,n,o){var r,h,l,c,u,d=this._dialogInst;return d||(this.uuid+=1,r="dp"+this.uuid,this._dialogInput=t("<input type='text' id='"+r+"' style='position: absolute; top: -100px; width: 0px;'/>"),this._dialogInput.on("keydown",this._doKeyDown),t("body").append(this._dialogInput),d=this._dialogInst=this._newInst(this._dialogInput,!1),d.settings={},t.data(this._dialogInput[0],"datepicker",d)),a(d.settings,n||{}),i=i&&i.constructor===Date?this._formatDate(d,i):i,this._dialogInput.val(i),this._pos=o?o.length?o:[o.pageX,o.pageY]:null,this._pos||(h=document.documentElement.clientWidth,l=document.documentElement.clientHeight,c=document.documentElement.scrollLeft||document.body.scrollLeft,u=document.documentElement.scrollTop||document.body.scrollTop,this._pos=[h/2-100+c,l/2-150+u]),this._dialogInput.css("left",this._pos[0]+20+"px").css("top",this._pos[1]+"px"),d.settings.onSelect=s,this._inDialog=!0,this.dpDiv.addClass(this._dialogClass),this._showDatepicker(this._dialogInput[0]),t.blockUI&&t.blockUI(this.dpDiv),t.data(this._dialogInput[0],"datepicker",d),this},_destroyDatepicker:function(e){var i,s=t(e),n=t.data(e,"datepicker");s.hasClass(this.markerClassName)&&(i=e.nodeName.toLowerCase(),t.removeData(e,"datepicker"),"input"===i?(n.append.remove(),n.trigger.remove(),s.removeClass(this.markerClassName).off("focus",this._showDatepicker).off("keydown",this._doKeyDown).off("keypress",this._doKeyPress).off("keyup",this._doKeyUp)):("div"===i||"span"===i)&&s.removeClass(this.markerClassName).empty(),m===n&&(m=null))},_enableDatepicker:function(e){var i,s,n=t(e),o=t.data(e,"datepicker");n.hasClass(this.markerClassName)&&(i=e.nodeName.toLowerCase(),"input"===i?(e.disabled=!1,o.trigger.filter("button").each(function(){this.disabled=!1}).end().filter("img").css({opacity:"1.0",cursor:""})):("div"===i||"span"===i)&&(s=n.children("."+this._inlineClass),s.children().removeClass("ui-state-disabled"),s.find("select.ui-datepicker-month, select.ui-datepicker-year").prop("disabled",!1)),this._disabledInputs=t.map(this._disabledInputs,function(t){return t===e?null:t}))},_disableDatepicker:function(e){var i,s,n=t(e),o=t.data(e,"datepicker");n.hasClass(this.markerClassName)&&(i=e.nodeName.toLowerCase(),"input"===i?(e.disabled=!0,o.trigger.filter("button").each(function(){this.disabled=!0}).end().filter("img").css({opacity:"0.5",cursor:"default"})):("div"===i||"span"===i)&&(s=n.children("."+this._inlineClass),s.children().addClass("ui-state-disabled"),s.find("select.ui-datepicker-month, select.ui-datepicker-year").prop("disabled",!0)),this._disabledInputs=t.map(this._disabledInputs,function(t){return t===e?null:t}),this._disabledInputs[this._disabledInputs.length]=e)},_isDisabledDatepicker:function(t){if(!t)return!1;for(var e=0;this._disabledInputs.length>e;e++)if(this._disabledInputs[e]===t)return!0;return!1},_getInst:function(e){try{return t.data(e,"datepicker")}catch(i){throw"Missing instance data for this datepicker"}},_optionDatepicker:function(e,i,s){var n,o,r,h,l=this._getInst(e);return 2===arguments.length&&"string"==typeof i?"defaults"===i?t.extend({},t.datepicker._defaults):l?"all"===i?t.extend({},l.settings):this._get(l,i):null:(n=i||{},"string"==typeof i&&(n={},n[i]=s),l&&(this._curInst===l&&this._hideDatepicker(),o=this._getDateDatepicker(e,!0),r=this._getMinMaxDate(l,"min"),h=this._getMinMaxDate(l,"max"),a(l.settings,n),null!==r&&void 0!==n.dateFormat&&void 0===n.minDate&&(l.settings.minDate=this._formatDate(l,r)),null!==h&&void 0!==n.dateFormat&&void 0===n.maxDate&&(l.settings.maxDate=this._formatDate(l,h)),"disabled"in n&&(n.disabled?this._disableDatepicker(e):this._enableDatepicker(e)),this._attachments(t(e),l),this._autoSize(l),this._setDate(l,o),this._updateAlternate(l),this._updateDatepicker(l)),void 0)},_changeDatepicker:function(t,e,i){this._optionDatepicker(t,e,i)},_refreshDatepicker:function(t){var e=this._getInst(t);e&&this._updateDatepicker(e)},_setDateDatepicker:function(t,e){var i=this._getInst(t);i&&(this._setDate(i,e),this._updateDatepicker(i),this._updateAlternate(i))},_getDateDatepicker:function(t,e){var i=this._getInst(t);return i&&!i.inline&&this._setDateFromField(i,e),i?this._getDate(i):null},_doKeyDown:function(e){var i,s,n,o=t.datepicker._getInst(e.target),a=!0,r=o.dpDiv.is(".ui-datepicker-rtl");if(o._keyEvent=!0,t.datepicker._datepickerShowing)switch(e.keyCode){case 9:t.datepicker._hideDatepicker(),a=!1;break;case 13:return n=t("td."+t.datepicker._dayOverClass+":not(."+t.datepicker._currentClass+")",o.dpDiv),n[0]&&t.datepicker._selectDay(e.target,o.selectedMonth,o.selectedYear,n[0]),i=t.datepicker._get(o,"onSelect"),i?(s=t.datepicker._formatDate(o),i.apply(o.input?o.input[0]:null,[s,o])):t.datepicker._hideDatepicker(),!1;case 27:t.datepicker._hideDatepicker();break;case 33:t.datepicker._adjustDate(e.target,e.ctrlKey?-t.datepicker._get(o,"stepBigMonths"):-t.datepicker._get(o,"stepMonths"),"M");break;case 34:t.datepicker._adjustDate(e.target,e.ctrlKey?+t.datepicker._get(o,"stepBigMonths"):+t.datepicker._get(o,"stepMonths"),"M");break;case 35:(e.ctrlKey||e.metaKey)&&t.datepicker._clearDate(e.target),a=e.ctrlKey||e.metaKey;break;case 36:(e.ctrlKey||e.metaKey)&&t.datepicker._gotoToday(e.target),a=e.ctrlKey||e.metaKey;break;case 37:(e.ctrlKey||e.metaKey)&&t.datepicker._adjustDate(e.target,r?1:-1,"D"),a=e.ctrlKey||e.metaKey,e.originalEvent.altKey&&t.datepicker._adjustDate(e.target,e.ctrlKey?-t.datepicker._get(o,"stepBigMonths"):-t.datepicker._get(o,"stepMonths"),"M");break;case 38:(e.ctrlKey||e.metaKey)&&t.datepicker._adjustDate(e.target,-7,"D"),a=e.ctrlKey||e.metaKey;break;case 39:(e.ctrlKey||e.metaKey)&&t.datepicker._adjustDate(e.target,r?-1:1,"D"),a=e.ctrlKey||e.metaKey,e.originalEvent.altKey&&t.datepicker._adjustDate(e.target,e.ctrlKey?+t.datepicker._get(o,"stepBigMonths"):+t.datepicker._get(o,"stepMonths"),"M");break;case 40:(e.ctrlKey||e.metaKey)&&t.datepicker._adjustDate(e.target,7,"D"),a=e.ctrlKey||e.metaKey;break;default:a=!1}else 36===e.keyCode&&e.ctrlKey?t.datepicker._showDatepicker(this):a=!1;a&&(e.preventDefault(),e.stopPropagation())},_doKeyPress:function(e){var i,s,n=t.datepicker._getInst(e.target);return t.datepicker._get(n,"constrainInput")?(i=t.datepicker._possibleChars(t.datepicker._get(n,"dateFormat")),s=String.fromCharCode(null==e.charCode?e.keyCode:e.charCode),e.ctrlKey||e.metaKey||" ">s||!i||i.indexOf(s)>-1):void 0},_doKeyUp:function(e){var i,s=t.datepicker._getInst(e.target);if(s.input.val()!==s.lastVal)try{i=t.datepicker.parseDate(t.datepicker._get(s,"dateFormat"),s.input?s.input.val():null,t.datepicker._getFormatConfig(s)),i&&(t.datepicker._setDateFromField(s),t.datepicker._updateAlternate(s),t.datepicker._updateDatepicker(s))}catch(n){}return!0},_showDatepicker:function(e){if(e=e.target||e,"input"!==e.nodeName.toLowerCase()&&(e=t("input",e.parentNode)[0]),!t.datepicker._isDisabledDatepicker(e)&&t.datepicker._lastInput!==e){var s,n,o,r,h,l,c;s=t.datepicker._getInst(e),t.datepicker._curInst&&t.datepicker._curInst!==s&&(t.datepicker._curInst.dpDiv.stop(!0,!0),s&&t.datepicker._datepickerShowing&&t.datepicker._hideDatepicker(t.datepicker._curInst.input[0])),n=t.datepicker._get(s,"beforeShow"),o=n?n.apply(e,[e,s]):{},o!==!1&&(a(s.settings,o),s.lastVal=null,t.datepicker._lastInput=e,t.datepicker._setDateFromField(s),t.datepicker._inDialog&&(e.value=""),t.datepicker._pos||(t.datepicker._pos=t.datepicker._findPos(e),t.datepicker._pos[1]+=e.offsetHeight),r=!1,t(e).parents().each(function(){return r|="fixed"===t(this).css("position"),!r}),h={left:t.datepicker._pos[0],top:t.datepicker._pos[1]},t.datepicker._pos=null,s.dpDiv.empty(),s.dpDiv.css({position:"absolute",display:"block",top:"-1000px"}),t.datepicker._updateDatepicker(s),h=t.datepicker._checkOffset(s,h,r),s.dpDiv.css({position:t.datepicker._inDialog&&t.blockUI?"static":r?"fixed":"absolute",display:"none",left:h.left+"px",top:h.top+"px"}),s.inline||(l=t.datepicker._get(s,"showAnim"),c=t.datepicker._get(s,"duration"),s.dpDiv.css("z-index",i(t(e))+1),t.datepicker._datepickerShowing=!0,t.effects&&t.effects.effect[l]?s.dpDiv.show(l,t.datepicker._get(s,"showOptions"),c):s.dpDiv[l||"show"](l?c:null),t.datepicker._shouldFocusInput(s)&&s.input.trigger("focus"),t.datepicker._curInst=s)) +}},_updateDatepicker:function(e){this.maxRows=4,m=e,e.dpDiv.empty().append(this._generateHTML(e)),this._attachHandlers(e);var i,s=this._getNumberOfMonths(e),n=s[1],a=17,r=e.dpDiv.find("."+this._dayOverClass+" a");r.length>0&&o.apply(r.get(0)),e.dpDiv.removeClass("ui-datepicker-multi-2 ui-datepicker-multi-3 ui-datepicker-multi-4").width(""),n>1&&e.dpDiv.addClass("ui-datepicker-multi-"+n).css("width",a*n+"em"),e.dpDiv[(1!==s[0]||1!==s[1]?"add":"remove")+"Class"]("ui-datepicker-multi"),e.dpDiv[(this._get(e,"isRTL")?"add":"remove")+"Class"]("ui-datepicker-rtl"),e===t.datepicker._curInst&&t.datepicker._datepickerShowing&&t.datepicker._shouldFocusInput(e)&&e.input.trigger("focus"),e.yearshtml&&(i=e.yearshtml,setTimeout(function(){i===e.yearshtml&&e.yearshtml&&e.dpDiv.find("select.ui-datepicker-year:first").replaceWith(e.yearshtml),i=e.yearshtml=null},0))},_shouldFocusInput:function(t){return t.input&&t.input.is(":visible")&&!t.input.is(":disabled")&&!t.input.is(":focus")},_checkOffset:function(e,i,s){var n=e.dpDiv.outerWidth(),o=e.dpDiv.outerHeight(),a=e.input?e.input.outerWidth():0,r=e.input?e.input.outerHeight():0,h=document.documentElement.clientWidth+(s?0:t(document).scrollLeft()),l=document.documentElement.clientHeight+(s?0:t(document).scrollTop());return i.left-=this._get(e,"isRTL")?n-a:0,i.left-=s&&i.left===e.input.offset().left?t(document).scrollLeft():0,i.top-=s&&i.top===e.input.offset().top+r?t(document).scrollTop():0,i.left-=Math.min(i.left,i.left+n>h&&h>n?Math.abs(i.left+n-h):0),i.top-=Math.min(i.top,i.top+o>l&&l>o?Math.abs(o+r):0),i},_findPos:function(e){for(var i,s=this._getInst(e),n=this._get(s,"isRTL");e&&("hidden"===e.type||1!==e.nodeType||t.expr.filters.hidden(e));)e=e[n?"previousSibling":"nextSibling"];return i=t(e).offset(),[i.left,i.top]},_hideDatepicker:function(e){var i,s,n,o,a=this._curInst;!a||e&&a!==t.data(e,"datepicker")||this._datepickerShowing&&(i=this._get(a,"showAnim"),s=this._get(a,"duration"),n=function(){t.datepicker._tidyDialog(a)},t.effects&&(t.effects.effect[i]||t.effects[i])?a.dpDiv.hide(i,t.datepicker._get(a,"showOptions"),s,n):a.dpDiv["slideDown"===i?"slideUp":"fadeIn"===i?"fadeOut":"hide"](i?s:null,n),i||n(),this._datepickerShowing=!1,o=this._get(a,"onClose"),o&&o.apply(a.input?a.input[0]:null,[a.input?a.input.val():"",a]),this._lastInput=null,this._inDialog&&(this._dialogInput.css({position:"absolute",left:"0",top:"-100px"}),t.blockUI&&(t.unblockUI(),t("body").append(this.dpDiv))),this._inDialog=!1)},_tidyDialog:function(t){t.dpDiv.removeClass(this._dialogClass).off(".ui-datepicker-calendar")},_checkExternalClick:function(e){if(t.datepicker._curInst){var i=t(e.target),s=t.datepicker._getInst(i[0]);(i[0].id!==t.datepicker._mainDivId&&0===i.parents("#"+t.datepicker._mainDivId).length&&!i.hasClass(t.datepicker.markerClassName)&&!i.closest("."+t.datepicker._triggerClass).length&&t.datepicker._datepickerShowing&&(!t.datepicker._inDialog||!t.blockUI)||i.hasClass(t.datepicker.markerClassName)&&t.datepicker._curInst!==s)&&t.datepicker._hideDatepicker()}},_adjustDate:function(e,i,s){var n=t(e),o=this._getInst(n[0]);this._isDisabledDatepicker(n[0])||(this._adjustInstDate(o,i+("M"===s?this._get(o,"showCurrentAtPos"):0),s),this._updateDatepicker(o))},_gotoToday:function(e){var i,s=t(e),n=this._getInst(s[0]);this._get(n,"gotoCurrent")&&n.currentDay?(n.selectedDay=n.currentDay,n.drawMonth=n.selectedMonth=n.currentMonth,n.drawYear=n.selectedYear=n.currentYear):(i=new Date,n.selectedDay=i.getDate(),n.drawMonth=n.selectedMonth=i.getMonth(),n.drawYear=n.selectedYear=i.getFullYear()),this._notifyChange(n),this._adjustDate(s)},_selectMonthYear:function(e,i,s){var n=t(e),o=this._getInst(n[0]);o["selected"+("M"===s?"Month":"Year")]=o["draw"+("M"===s?"Month":"Year")]=parseInt(i.options[i.selectedIndex].value,10),this._notifyChange(o),this._adjustDate(n)},_selectDay:function(e,i,s,n){var o,a=t(e);t(n).hasClass(this._unselectableClass)||this._isDisabledDatepicker(a[0])||(o=this._getInst(a[0]),o.selectedDay=o.currentDay=t("a",n).html(),o.selectedMonth=o.currentMonth=i,o.selectedYear=o.currentYear=s,this._selectDate(e,this._formatDate(o,o.currentDay,o.currentMonth,o.currentYear)))},_clearDate:function(e){var i=t(e);this._selectDate(i,"")},_selectDate:function(e,i){var s,n=t(e),o=this._getInst(n[0]);i=null!=i?i:this._formatDate(o),o.input&&o.input.val(i),this._updateAlternate(o),s=this._get(o,"onSelect"),s?s.apply(o.input?o.input[0]:null,[i,o]):o.input&&o.input.trigger("change"),o.inline?this._updateDatepicker(o):(this._hideDatepicker(),this._lastInput=o.input[0],"object"!=typeof o.input[0]&&o.input.trigger("focus"),this._lastInput=null)},_updateAlternate:function(e){var i,s,n,o=this._get(e,"altField");o&&(i=this._get(e,"altFormat")||this._get(e,"dateFormat"),s=this._getDate(e),n=this.formatDate(i,s,this._getFormatConfig(e)),t(o).val(n))},noWeekends:function(t){var e=t.getDay();return[e>0&&6>e,""]},iso8601Week:function(t){var e,i=new Date(t.getTime());return i.setDate(i.getDate()+4-(i.getDay()||7)),e=i.getTime(),i.setMonth(0),i.setDate(1),Math.floor(Math.round((e-i)/864e5)/7)+1},parseDate:function(e,i,s){if(null==e||null==i)throw"Invalid arguments";if(i="object"==typeof i?""+i:i+"",""===i)return null;var n,o,a,r,h=0,l=(s?s.shortYearCutoff:null)||this._defaults.shortYearCutoff,c="string"!=typeof l?l:(new Date).getFullYear()%100+parseInt(l,10),u=(s?s.dayNamesShort:null)||this._defaults.dayNamesShort,d=(s?s.dayNames:null)||this._defaults.dayNames,p=(s?s.monthNamesShort:null)||this._defaults.monthNamesShort,f=(s?s.monthNames:null)||this._defaults.monthNames,g=-1,m=-1,_=-1,v=-1,b=!1,y=function(t){var i=e.length>n+1&&e.charAt(n+1)===t;return i&&n++,i},w=function(t){var e=y(t),s="@"===t?14:"!"===t?20:"y"===t&&e?4:"o"===t?3:2,n="y"===t?s:1,o=RegExp("^\\d{"+n+","+s+"}"),a=i.substring(h).match(o);if(!a)throw"Missing number at position "+h;return h+=a[0].length,parseInt(a[0],10)},k=function(e,s,n){var o=-1,a=t.map(y(e)?n:s,function(t,e){return[[e,t]]}).sort(function(t,e){return-(t[1].length-e[1].length)});if(t.each(a,function(t,e){var s=e[1];return i.substr(h,s.length).toLowerCase()===s.toLowerCase()?(o=e[0],h+=s.length,!1):void 0}),-1!==o)return o+1;throw"Unknown name at position "+h},x=function(){if(i.charAt(h)!==e.charAt(n))throw"Unexpected literal at position "+h;h++};for(n=0;e.length>n;n++)if(b)"'"!==e.charAt(n)||y("'")?x():b=!1;else switch(e.charAt(n)){case"d":_=w("d");break;case"D":k("D",u,d);break;case"o":v=w("o");break;case"m":m=w("m");break;case"M":m=k("M",p,f);break;case"y":g=w("y");break;case"@":r=new Date(w("@")),g=r.getFullYear(),m=r.getMonth()+1,_=r.getDate();break;case"!":r=new Date((w("!")-this._ticksTo1970)/1e4),g=r.getFullYear(),m=r.getMonth()+1,_=r.getDate();break;case"'":y("'")?x():b=!0;break;default:x()}if(i.length>h&&(a=i.substr(h),!/^\s+/.test(a)))throw"Extra/unparsed characters found in date: "+a;if(-1===g?g=(new Date).getFullYear():100>g&&(g+=(new Date).getFullYear()-(new Date).getFullYear()%100+(c>=g?0:-100)),v>-1)for(m=1,_=v;;){if(o=this._getDaysInMonth(g,m-1),o>=_)break;m++,_-=o}if(r=this._daylightSavingAdjust(new Date(g,m-1,_)),r.getFullYear()!==g||r.getMonth()+1!==m||r.getDate()!==_)throw"Invalid date";return r},ATOM:"yy-mm-dd",COOKIE:"D, dd M yy",ISO_8601:"yy-mm-dd",RFC_822:"D, d M y",RFC_850:"DD, dd-M-y",RFC_1036:"D, d M y",RFC_1123:"D, d M yy",RFC_2822:"D, d M yy",RSS:"D, d M y",TICKS:"!",TIMESTAMP:"@",W3C:"yy-mm-dd",_ticksTo1970:1e7*60*60*24*(718685+Math.floor(492.5)-Math.floor(19.7)+Math.floor(4.925)),formatDate:function(t,e,i){if(!e)return"";var s,n=(i?i.dayNamesShort:null)||this._defaults.dayNamesShort,o=(i?i.dayNames:null)||this._defaults.dayNames,a=(i?i.monthNamesShort:null)||this._defaults.monthNamesShort,r=(i?i.monthNames:null)||this._defaults.monthNames,h=function(e){var i=t.length>s+1&&t.charAt(s+1)===e;return i&&s++,i},l=function(t,e,i){var s=""+e;if(h(t))for(;i>s.length;)s="0"+s;return s},c=function(t,e,i,s){return h(t)?s[e]:i[e]},u="",d=!1;if(e)for(s=0;t.length>s;s++)if(d)"'"!==t.charAt(s)||h("'")?u+=t.charAt(s):d=!1;else switch(t.charAt(s)){case"d":u+=l("d",e.getDate(),2);break;case"D":u+=c("D",e.getDay(),n,o);break;case"o":u+=l("o",Math.round((new Date(e.getFullYear(),e.getMonth(),e.getDate()).getTime()-new Date(e.getFullYear(),0,0).getTime())/864e5),3);break;case"m":u+=l("m",e.getMonth()+1,2);break;case"M":u+=c("M",e.getMonth(),a,r);break;case"y":u+=h("y")?e.getFullYear():(10>e.getFullYear()%100?"0":"")+e.getFullYear()%100;break;case"@":u+=e.getTime();break;case"!":u+=1e4*e.getTime()+this._ticksTo1970;break;case"'":h("'")?u+="'":d=!0;break;default:u+=t.charAt(s)}return u},_possibleChars:function(t){var e,i="",s=!1,n=function(i){var s=t.length>e+1&&t.charAt(e+1)===i;return s&&e++,s};for(e=0;t.length>e;e++)if(s)"'"!==t.charAt(e)||n("'")?i+=t.charAt(e):s=!1;else switch(t.charAt(e)){case"d":case"m":case"y":case"@":i+="0123456789";break;case"D":case"M":return null;case"'":n("'")?i+="'":s=!0;break;default:i+=t.charAt(e)}return i},_get:function(t,e){return void 0!==t.settings[e]?t.settings[e]:this._defaults[e]},_setDateFromField:function(t,e){if(t.input.val()!==t.lastVal){var i=this._get(t,"dateFormat"),s=t.lastVal=t.input?t.input.val():null,n=this._getDefaultDate(t),o=n,a=this._getFormatConfig(t);try{o=this.parseDate(i,s,a)||n}catch(r){s=e?"":s}t.selectedDay=o.getDate(),t.drawMonth=t.selectedMonth=o.getMonth(),t.drawYear=t.selectedYear=o.getFullYear(),t.currentDay=s?o.getDate():0,t.currentMonth=s?o.getMonth():0,t.currentYear=s?o.getFullYear():0,this._adjustInstDate(t)}},_getDefaultDate:function(t){return this._restrictMinMax(t,this._determineDate(t,this._get(t,"defaultDate"),new Date))},_determineDate:function(e,i,s){var n=function(t){var e=new Date;return e.setDate(e.getDate()+t),e},o=function(i){try{return t.datepicker.parseDate(t.datepicker._get(e,"dateFormat"),i,t.datepicker._getFormatConfig(e))}catch(s){}for(var n=(i.toLowerCase().match(/^c/)?t.datepicker._getDate(e):null)||new Date,o=n.getFullYear(),a=n.getMonth(),r=n.getDate(),h=/([+\-]?[0-9]+)\s*(d|D|w|W|m|M|y|Y)?/g,l=h.exec(i);l;){switch(l[2]||"d"){case"d":case"D":r+=parseInt(l[1],10);break;case"w":case"W":r+=7*parseInt(l[1],10);break;case"m":case"M":a+=parseInt(l[1],10),r=Math.min(r,t.datepicker._getDaysInMonth(o,a));break;case"y":case"Y":o+=parseInt(l[1],10),r=Math.min(r,t.datepicker._getDaysInMonth(o,a))}l=h.exec(i)}return new Date(o,a,r)},a=null==i||""===i?s:"string"==typeof i?o(i):"number"==typeof i?isNaN(i)?s:n(i):new Date(i.getTime());return a=a&&"Invalid Date"==""+a?s:a,a&&(a.setHours(0),a.setMinutes(0),a.setSeconds(0),a.setMilliseconds(0)),this._daylightSavingAdjust(a)},_daylightSavingAdjust:function(t){return t?(t.setHours(t.getHours()>12?t.getHours()+2:0),t):null},_setDate:function(t,e,i){var s=!e,n=t.selectedMonth,o=t.selectedYear,a=this._restrictMinMax(t,this._determineDate(t,e,new Date));t.selectedDay=t.currentDay=a.getDate(),t.drawMonth=t.selectedMonth=t.currentMonth=a.getMonth(),t.drawYear=t.selectedYear=t.currentYear=a.getFullYear(),n===t.selectedMonth&&o===t.selectedYear||i||this._notifyChange(t),this._adjustInstDate(t),t.input&&t.input.val(s?"":this._formatDate(t))},_getDate:function(t){var e=!t.currentYear||t.input&&""===t.input.val()?null:this._daylightSavingAdjust(new Date(t.currentYear,t.currentMonth,t.currentDay));return e},_attachHandlers:function(e){var i=this._get(e,"stepMonths"),s="#"+e.id.replace(/\\\\/g,"\\");e.dpDiv.find("[data-handler]").map(function(){var e={prev:function(){t.datepicker._adjustDate(s,-i,"M")},next:function(){t.datepicker._adjustDate(s,+i,"M")},hide:function(){t.datepicker._hideDatepicker()},today:function(){t.datepicker._gotoToday(s)},selectDay:function(){return t.datepicker._selectDay(s,+this.getAttribute("data-month"),+this.getAttribute("data-year"),this),!1},selectMonth:function(){return t.datepicker._selectMonthYear(s,this,"M"),!1},selectYear:function(){return t.datepicker._selectMonthYear(s,this,"Y"),!1}};t(this).on(this.getAttribute("data-event"),e[this.getAttribute("data-handler")])})},_generateHTML:function(t){var e,i,s,n,o,a,r,h,l,c,u,d,p,f,g,m,_,v,b,y,w,k,x,C,D,I,T,P,M,S,H,z,O,A,N,W,E,F,L,R=new Date,B=this._daylightSavingAdjust(new Date(R.getFullYear(),R.getMonth(),R.getDate())),Y=this._get(t,"isRTL"),j=this._get(t,"showButtonPanel"),q=this._get(t,"hideIfNoPrevNext"),K=this._get(t,"navigationAsDateFormat"),U=this._getNumberOfMonths(t),V=this._get(t,"showCurrentAtPos"),$=this._get(t,"stepMonths"),X=1!==U[0]||1!==U[1],G=this._daylightSavingAdjust(t.currentDay?new Date(t.currentYear,t.currentMonth,t.currentDay):new Date(9999,9,9)),Q=this._getMinMaxDate(t,"min"),J=this._getMinMaxDate(t,"max"),Z=t.drawMonth-V,te=t.drawYear;if(0>Z&&(Z+=12,te--),J)for(e=this._daylightSavingAdjust(new Date(J.getFullYear(),J.getMonth()-U[0]*U[1]+1,J.getDate())),e=Q&&Q>e?Q:e;this._daylightSavingAdjust(new Date(te,Z,1))>e;)Z--,0>Z&&(Z=11,te--);for(t.drawMonth=Z,t.drawYear=te,i=this._get(t,"prevText"),i=K?this.formatDate(i,this._daylightSavingAdjust(new Date(te,Z-$,1)),this._getFormatConfig(t)):i,s=this._canAdjustMonth(t,-1,te,Z)?"<a class='ui-datepicker-prev ui-corner-all' data-handler='prev' data-event='click' title='"+i+"'><span class='ui-icon ui-icon-circle-triangle-"+(Y?"e":"w")+"'>"+i+"</span></a>":q?"":"<a class='ui-datepicker-prev ui-corner-all ui-state-disabled' title='"+i+"'><span class='ui-icon ui-icon-circle-triangle-"+(Y?"e":"w")+"'>"+i+"</span></a>",n=this._get(t,"nextText"),n=K?this.formatDate(n,this._daylightSavingAdjust(new Date(te,Z+$,1)),this._getFormatConfig(t)):n,o=this._canAdjustMonth(t,1,te,Z)?"<a class='ui-datepicker-next ui-corner-all' data-handler='next' data-event='click' title='"+n+"'><span class='ui-icon ui-icon-circle-triangle-"+(Y?"w":"e")+"'>"+n+"</span></a>":q?"":"<a class='ui-datepicker-next ui-corner-all ui-state-disabled' title='"+n+"'><span class='ui-icon ui-icon-circle-triangle-"+(Y?"w":"e")+"'>"+n+"</span></a>",a=this._get(t,"currentText"),r=this._get(t,"gotoCurrent")&&t.currentDay?G:B,a=K?this.formatDate(a,r,this._getFormatConfig(t)):a,h=t.inline?"":"<button type='button' class='ui-datepicker-close ui-state-default ui-priority-primary ui-corner-all' data-handler='hide' data-event='click'>"+this._get(t,"closeText")+"</button>",l=j?"<div class='ui-datepicker-buttonpane ui-widget-content'>"+(Y?h:"")+(this._isInRange(t,r)?"<button type='button' class='ui-datepicker-current ui-state-default ui-priority-secondary ui-corner-all' data-handler='today' data-event='click'>"+a+"</button>":"")+(Y?"":h)+"</div>":"",c=parseInt(this._get(t,"firstDay"),10),c=isNaN(c)?0:c,u=this._get(t,"showWeek"),d=this._get(t,"dayNames"),p=this._get(t,"dayNamesMin"),f=this._get(t,"monthNames"),g=this._get(t,"monthNamesShort"),m=this._get(t,"beforeShowDay"),_=this._get(t,"showOtherMonths"),v=this._get(t,"selectOtherMonths"),b=this._getDefaultDate(t),y="",k=0;U[0]>k;k++){for(x="",this.maxRows=4,C=0;U[1]>C;C++){if(D=this._daylightSavingAdjust(new Date(te,Z,t.selectedDay)),I=" ui-corner-all",T="",X){if(T+="<div class='ui-datepicker-group",U[1]>1)switch(C){case 0:T+=" ui-datepicker-group-first",I=" ui-corner-"+(Y?"right":"left");break;case U[1]-1:T+=" ui-datepicker-group-last",I=" ui-corner-"+(Y?"left":"right");break;default:T+=" ui-datepicker-group-middle",I=""}T+="'>"}for(T+="<div class='ui-datepicker-header ui-widget-header ui-helper-clearfix"+I+"'>"+(/all|left/.test(I)&&0===k?Y?o:s:"")+(/all|right/.test(I)&&0===k?Y?s:o:"")+this._generateMonthYearHeader(t,Z,te,Q,J,k>0||C>0,f,g)+"</div><table class='ui-datepicker-calendar'><thead>"+"<tr>",P=u?"<th class='ui-datepicker-week-col'>"+this._get(t,"weekHeader")+"</th>":"",w=0;7>w;w++)M=(w+c)%7,P+="<th scope='col'"+((w+c+6)%7>=5?" class='ui-datepicker-week-end'":"")+">"+"<span title='"+d[M]+"'>"+p[M]+"</span></th>";for(T+=P+"</tr></thead><tbody>",S=this._getDaysInMonth(te,Z),te===t.selectedYear&&Z===t.selectedMonth&&(t.selectedDay=Math.min(t.selectedDay,S)),H=(this._getFirstDayOfMonth(te,Z)-c+7)%7,z=Math.ceil((H+S)/7),O=X?this.maxRows>z?this.maxRows:z:z,this.maxRows=O,A=this._daylightSavingAdjust(new Date(te,Z,1-H)),N=0;O>N;N++){for(T+="<tr>",W=u?"<td class='ui-datepicker-week-col'>"+this._get(t,"calculateWeek")(A)+"</td>":"",w=0;7>w;w++)E=m?m.apply(t.input?t.input[0]:null,[A]):[!0,""],F=A.getMonth()!==Z,L=F&&!v||!E[0]||Q&&Q>A||J&&A>J,W+="<td class='"+((w+c+6)%7>=5?" ui-datepicker-week-end":"")+(F?" ui-datepicker-other-month":"")+(A.getTime()===D.getTime()&&Z===t.selectedMonth&&t._keyEvent||b.getTime()===A.getTime()&&b.getTime()===D.getTime()?" "+this._dayOverClass:"")+(L?" "+this._unselectableClass+" ui-state-disabled":"")+(F&&!_?"":" "+E[1]+(A.getTime()===G.getTime()?" "+this._currentClass:"")+(A.getTime()===B.getTime()?" ui-datepicker-today":""))+"'"+(F&&!_||!E[2]?"":" title='"+E[2].replace(/'/g,"&#39;")+"'")+(L?"":" data-handler='selectDay' data-event='click' data-month='"+A.getMonth()+"' data-year='"+A.getFullYear()+"'")+">"+(F&&!_?"&#xa0;":L?"<span class='ui-state-default'>"+A.getDate()+"</span>":"<a class='ui-state-default"+(A.getTime()===B.getTime()?" ui-state-highlight":"")+(A.getTime()===G.getTime()?" ui-state-active":"")+(F?" ui-priority-secondary":"")+"' href='#'>"+A.getDate()+"</a>")+"</td>",A.setDate(A.getDate()+1),A=this._daylightSavingAdjust(A);T+=W+"</tr>"}Z++,Z>11&&(Z=0,te++),T+="</tbody></table>"+(X?"</div>"+(U[0]>0&&C===U[1]-1?"<div class='ui-datepicker-row-break'></div>":""):""),x+=T}y+=x}return y+=l,t._keyEvent=!1,y},_generateMonthYearHeader:function(t,e,i,s,n,o,a,r){var h,l,c,u,d,p,f,g,m=this._get(t,"changeMonth"),_=this._get(t,"changeYear"),v=this._get(t,"showMonthAfterYear"),b="<div class='ui-datepicker-title'>",y="";if(o||!m)y+="<span class='ui-datepicker-month'>"+a[e]+"</span>";else{for(h=s&&s.getFullYear()===i,l=n&&n.getFullYear()===i,y+="<select class='ui-datepicker-month' data-handler='selectMonth' data-event='change'>",c=0;12>c;c++)(!h||c>=s.getMonth())&&(!l||n.getMonth()>=c)&&(y+="<option value='"+c+"'"+(c===e?" selected='selected'":"")+">"+r[c]+"</option>");y+="</select>"}if(v||(b+=y+(!o&&m&&_?"":"&#xa0;")),!t.yearshtml)if(t.yearshtml="",o||!_)b+="<span class='ui-datepicker-year'>"+i+"</span>";else{for(u=this._get(t,"yearRange").split(":"),d=(new Date).getFullYear(),p=function(t){var e=t.match(/c[+\-].*/)?i+parseInt(t.substring(1),10):t.match(/[+\-].*/)?d+parseInt(t,10):parseInt(t,10);return isNaN(e)?d:e},f=p(u[0]),g=Math.max(f,p(u[1]||"")),f=s?Math.max(f,s.getFullYear()):f,g=n?Math.min(g,n.getFullYear()):g,t.yearshtml+="<select class='ui-datepicker-year' data-handler='selectYear' data-event='change'>";g>=f;f++)t.yearshtml+="<option value='"+f+"'"+(f===i?" selected='selected'":"")+">"+f+"</option>";t.yearshtml+="</select>",b+=t.yearshtml,t.yearshtml=null}return b+=this._get(t,"yearSuffix"),v&&(b+=(!o&&m&&_?"":"&#xa0;")+y),b+="</div>"},_adjustInstDate:function(t,e,i){var s=t.selectedYear+("Y"===i?e:0),n=t.selectedMonth+("M"===i?e:0),o=Math.min(t.selectedDay,this._getDaysInMonth(s,n))+("D"===i?e:0),a=this._restrictMinMax(t,this._daylightSavingAdjust(new Date(s,n,o)));t.selectedDay=a.getDate(),t.drawMonth=t.selectedMonth=a.getMonth(),t.drawYear=t.selectedYear=a.getFullYear(),("M"===i||"Y"===i)&&this._notifyChange(t)},_restrictMinMax:function(t,e){var i=this._getMinMaxDate(t,"min"),s=this._getMinMaxDate(t,"max"),n=i&&i>e?i:e;return s&&n>s?s:n},_notifyChange:function(t){var e=this._get(t,"onChangeMonthYear");e&&e.apply(t.input?t.input[0]:null,[t.selectedYear,t.selectedMonth+1,t])},_getNumberOfMonths:function(t){var e=this._get(t,"numberOfMonths");return null==e?[1,1]:"number"==typeof e?[1,e]:e},_getMinMaxDate:function(t,e){return this._determineDate(t,this._get(t,e+"Date"),null)},_getDaysInMonth:function(t,e){return 32-this._daylightSavingAdjust(new Date(t,e,32)).getDate()},_getFirstDayOfMonth:function(t,e){return new Date(t,e,1).getDay()},_canAdjustMonth:function(t,e,i,s){var n=this._getNumberOfMonths(t),o=this._daylightSavingAdjust(new Date(i,s+(0>e?e:n[0]*n[1]),1));return 0>e&&o.setDate(this._getDaysInMonth(o.getFullYear(),o.getMonth())),this._isInRange(t,o)},_isInRange:function(t,e){var i,s,n=this._getMinMaxDate(t,"min"),o=this._getMinMaxDate(t,"max"),a=null,r=null,h=this._get(t,"yearRange");return h&&(i=h.split(":"),s=(new Date).getFullYear(),a=parseInt(i[0],10),r=parseInt(i[1],10),i[0].match(/[+\-].*/)&&(a+=s),i[1].match(/[+\-].*/)&&(r+=s)),(!n||e.getTime()>=n.getTime())&&(!o||e.getTime()<=o.getTime())&&(!a||e.getFullYear()>=a)&&(!r||r>=e.getFullYear())},_getFormatConfig:function(t){var e=this._get(t,"shortYearCutoff");return e="string"!=typeof e?e:(new Date).getFullYear()%100+parseInt(e,10),{shortYearCutoff:e,dayNamesShort:this._get(t,"dayNamesShort"),dayNames:this._get(t,"dayNames"),monthNamesShort:this._get(t,"monthNamesShort"),monthNames:this._get(t,"monthNames")}},_formatDate:function(t,e,i,s){e||(t.currentDay=t.selectedDay,t.currentMonth=t.selectedMonth,t.currentYear=t.selectedYear);var n=e?"object"==typeof e?e:this._daylightSavingAdjust(new Date(s,i,e)):this._daylightSavingAdjust(new Date(t.currentYear,t.currentMonth,t.currentDay));return this.formatDate(this._get(t,"dateFormat"),n,this._getFormatConfig(t))}}),t.fn.datepicker=function(e){if(!this.length)return this;t.datepicker.initialized||(t(document).on("mousedown",t.datepicker._checkExternalClick),t.datepicker.initialized=!0),0===t("#"+t.datepicker._mainDivId).length&&t("body").append(t.datepicker.dpDiv);var i=Array.prototype.slice.call(arguments,1);return"string"!=typeof e||"isDisabled"!==e&&"getDate"!==e&&"widget"!==e?"option"===e&&2===arguments.length&&"string"==typeof arguments[1]?t.datepicker["_"+e+"Datepicker"].apply(t.datepicker,[this[0]].concat(i)):this.each(function(){"string"==typeof e?t.datepicker["_"+e+"Datepicker"].apply(t.datepicker,[this].concat(i)):t.datepicker._attachDatepicker(this,e)}):t.datepicker["_"+e+"Datepicker"].apply(t.datepicker,[this[0]].concat(i))},t.datepicker=new s,t.datepicker.initialized=!1,t.datepicker.uuid=(new Date).getTime(),t.datepicker.version="1.12.1",t.datepicker,t.ui.ie=!!/msie [\w.]+/.exec(navigator.userAgent.toLowerCase());var _=!1;t(document).on("mouseup",function(){_=!1}),t.widget("ui.mouse",{version:"1.12.1",options:{cancel:"input, textarea, button, select, option",distance:1,delay:0},_mouseInit:function(){var e=this;this.element.on("mousedown."+this.widgetName,function(t){return e._mouseDown(t)}).on("click."+this.widgetName,function(i){return!0===t.data(i.target,e.widgetName+".preventClickEvent")?(t.removeData(i.target,e.widgetName+".preventClickEvent"),i.stopImmediatePropagation(),!1):void 0}),this.started=!1},_mouseDestroy:function(){this.element.off("."+this.widgetName),this._mouseMoveDelegate&&this.document.off("mousemove."+this.widgetName,this._mouseMoveDelegate).off("mouseup."+this.widgetName,this._mouseUpDelegate)},_mouseDown:function(e){if(!_){this._mouseMoved=!1,this._mouseStarted&&this._mouseUp(e),this._mouseDownEvent=e;var i=this,s=1===e.which,n="string"==typeof this.options.cancel&&e.target.nodeName?t(e.target).closest(this.options.cancel).length:!1;return s&&!n&&this._mouseCapture(e)?(this.mouseDelayMet=!this.options.delay,this.mouseDelayMet||(this._mouseDelayTimer=setTimeout(function(){i.mouseDelayMet=!0},this.options.delay)),this._mouseDistanceMet(e)&&this._mouseDelayMet(e)&&(this._mouseStarted=this._mouseStart(e)!==!1,!this._mouseStarted)?(e.preventDefault(),!0):(!0===t.data(e.target,this.widgetName+".preventClickEvent")&&t.removeData(e.target,this.widgetName+".preventClickEvent"),this._mouseMoveDelegate=function(t){return i._mouseMove(t)},this._mouseUpDelegate=function(t){return i._mouseUp(t)},this.document.on("mousemove."+this.widgetName,this._mouseMoveDelegate).on("mouseup."+this.widgetName,this._mouseUpDelegate),e.preventDefault(),_=!0,!0)):!0}},_mouseMove:function(e){if(this._mouseMoved){if(t.ui.ie&&(!document.documentMode||9>document.documentMode)&&!e.button)return this._mouseUp(e);if(!e.which)if(e.originalEvent.altKey||e.originalEvent.ctrlKey||e.originalEvent.metaKey||e.originalEvent.shiftKey)this.ignoreMissingWhich=!0;else if(!this.ignoreMissingWhich)return this._mouseUp(e)}return(e.which||e.button)&&(this._mouseMoved=!0),this._mouseStarted?(this._mouseDrag(e),e.preventDefault()):(this._mouseDistanceMet(e)&&this._mouseDelayMet(e)&&(this._mouseStarted=this._mouseStart(this._mouseDownEvent,e)!==!1,this._mouseStarted?this._mouseDrag(e):this._mouseUp(e)),!this._mouseStarted)},_mouseUp:function(e){this.document.off("mousemove."+this.widgetName,this._mouseMoveDelegate).off("mouseup."+this.widgetName,this._mouseUpDelegate),this._mouseStarted&&(this._mouseStarted=!1,e.target===this._mouseDownEvent.target&&t.data(e.target,this.widgetName+".preventClickEvent",!0),this._mouseStop(e)),this._mouseDelayTimer&&(clearTimeout(this._mouseDelayTimer),delete this._mouseDelayTimer),this.ignoreMissingWhich=!1,_=!1,e.preventDefault()},_mouseDistanceMet:function(t){return Math.max(Math.abs(this._mouseDownEvent.pageX-t.pageX),Math.abs(this._mouseDownEvent.pageY-t.pageY))>=this.options.distance},_mouseDelayMet:function(){return this.mouseDelayMet},_mouseStart:function(){},_mouseDrag:function(){},_mouseStop:function(){},_mouseCapture:function(){return!0}}),t.ui.plugin={add:function(e,i,s){var n,o=t.ui[e].prototype;for(n in s)o.plugins[n]=o.plugins[n]||[],o.plugins[n].push([i,s[n]])},call:function(t,e,i,s){var n,o=t.plugins[e];if(o&&(s||t.element[0].parentNode&&11!==t.element[0].parentNode.nodeType))for(n=0;o.length>n;n++)t.options[o[n][0]]&&o[n][1].apply(t.element,i)}},t.ui.safeBlur=function(e){e&&"body"!==e.nodeName.toLowerCase()&&t(e).trigger("blur")},t.widget("ui.draggable",t.ui.mouse,{version:"1.12.1",widgetEventPrefix:"drag",options:{addClasses:!0,appendTo:"parent",axis:!1,connectToSortable:!1,containment:!1,cursor:"auto",cursorAt:!1,grid:!1,handle:!1,helper:"original",iframeFix:!1,opacity:!1,refreshPositions:!1,revert:!1,revertDuration:500,scope:"default",scroll:!0,scrollSensitivity:20,scrollSpeed:20,snap:!1,snapMode:"both",snapTolerance:20,stack:!1,zIndex:!1,drag:null,start:null,stop:null},_create:function(){"original"===this.options.helper&&this._setPositionRelative(),this.options.addClasses&&this._addClass("ui-draggable"),this._setHandleClassName(),this._mouseInit()},_setOption:function(t,e){this._super(t,e),"handle"===t&&(this._removeHandleClassName(),this._setHandleClassName())},_destroy:function(){return(this.helper||this.element).is(".ui-draggable-dragging")?(this.destroyOnClear=!0,void 0):(this._removeHandleClassName(),this._mouseDestroy(),void 0)},_mouseCapture:function(e){var i=this.options;return this.helper||i.disabled||t(e.target).closest(".ui-resizable-handle").length>0?!1:(this.handle=this._getHandle(e),this.handle?(this._blurActiveElement(e),this._blockFrames(i.iframeFix===!0?"iframe":i.iframeFix),!0):!1)},_blockFrames:function(e){this.iframeBlocks=this.document.find(e).map(function(){var e=t(this);return t("<div>").css("position","absolute").appendTo(e.parent()).outerWidth(e.outerWidth()).outerHeight(e.outerHeight()).offset(e.offset())[0]})},_unblockFrames:function(){this.iframeBlocks&&(this.iframeBlocks.remove(),delete this.iframeBlocks)},_blurActiveElement:function(e){var i=t.ui.safeActiveElement(this.document[0]),s=t(e.target);s.closest(i).length||t.ui.safeBlur(i)},_mouseStart:function(e){var i=this.options;return this.helper=this._createHelper(e),this._addClass(this.helper,"ui-draggable-dragging"),this._cacheHelperProportions(),t.ui.ddmanager&&(t.ui.ddmanager.current=this),this._cacheMargins(),this.cssPosition=this.helper.css("position"),this.scrollParent=this.helper.scrollParent(!0),this.offsetParent=this.helper.offsetParent(),this.hasFixedAncestor=this.helper.parents().filter(function(){return"fixed"===t(this).css("position")}).length>0,this.positionAbs=this.element.offset(),this._refreshOffsets(e),this.originalPosition=this.position=this._generatePosition(e,!1),this.originalPageX=e.pageX,this.originalPageY=e.pageY,i.cursorAt&&this._adjustOffsetFromHelper(i.cursorAt),this._setContainment(),this._trigger("start",e)===!1?(this._clear(),!1):(this._cacheHelperProportions(),t.ui.ddmanager&&!i.dropBehaviour&&t.ui.ddmanager.prepareOffsets(this,e),this._mouseDrag(e,!0),t.ui.ddmanager&&t.ui.ddmanager.dragStart(this,e),!0)},_refreshOffsets:function(t){this.offset={top:this.positionAbs.top-this.margins.top,left:this.positionAbs.left-this.margins.left,scroll:!1,parent:this._getParentOffset(),relative:this._getRelativeOffset()},this.offset.click={left:t.pageX-this.offset.left,top:t.pageY-this.offset.top}},_mouseDrag:function(e,i){if(this.hasFixedAncestor&&(this.offset.parent=this._getParentOffset()),this.position=this._generatePosition(e,!0),this.positionAbs=this._convertPositionTo("absolute"),!i){var s=this._uiHash();if(this._trigger("drag",e,s)===!1)return this._mouseUp(new t.Event("mouseup",e)),!1;this.position=s.position}return this.helper[0].style.left=this.position.left+"px",this.helper[0].style.top=this.position.top+"px",t.ui.ddmanager&&t.ui.ddmanager.drag(this,e),!1},_mouseStop:function(e){var i=this,s=!1;return t.ui.ddmanager&&!this.options.dropBehaviour&&(s=t.ui.ddmanager.drop(this,e)),this.dropped&&(s=this.dropped,this.dropped=!1),"invalid"===this.options.revert&&!s||"valid"===this.options.revert&&s||this.options.revert===!0||t.isFunction(this.options.revert)&&this.options.revert.call(this.element,s)?t(this.helper).animate(this.originalPosition,parseInt(this.options.revertDuration,10),function(){i._trigger("stop",e)!==!1&&i._clear()}):this._trigger("stop",e)!==!1&&this._clear(),!1},_mouseUp:function(e){return this._unblockFrames(),t.ui.ddmanager&&t.ui.ddmanager.dragStop(this,e),this.handleElement.is(e.target)&&this.element.trigger("focus"),t.ui.mouse.prototype._mouseUp.call(this,e)},cancel:function(){return this.helper.is(".ui-draggable-dragging")?this._mouseUp(new t.Event("mouseup",{target:this.element[0]})):this._clear(),this},_getHandle:function(e){return this.options.handle?!!t(e.target).closest(this.element.find(this.options.handle)).length:!0},_setHandleClassName:function(){this.handleElement=this.options.handle?this.element.find(this.options.handle):this.element,this._addClass(this.handleElement,"ui-draggable-handle")},_removeHandleClassName:function(){this._removeClass(this.handleElement,"ui-draggable-handle")},_createHelper:function(e){var i=this.options,s=t.isFunction(i.helper),n=s?t(i.helper.apply(this.element[0],[e])):"clone"===i.helper?this.element.clone().removeAttr("id"):this.element;return n.parents("body").length||n.appendTo("parent"===i.appendTo?this.element[0].parentNode:i.appendTo),s&&n[0]===this.element[0]&&this._setPositionRelative(),n[0]===this.element[0]||/(fixed|absolute)/.test(n.css("position"))||n.css("position","absolute"),n},_setPositionRelative:function(){/^(?:r|a|f)/.test(this.element.css("position"))||(this.element[0].style.position="relative")},_adjustOffsetFromHelper:function(e){"string"==typeof e&&(e=e.split(" ")),t.isArray(e)&&(e={left:+e[0],top:+e[1]||0}),"left"in e&&(this.offset.click.left=e.left+this.margins.left),"right"in e&&(this.offset.click.left=this.helperProportions.width-e.right+this.margins.left),"top"in e&&(this.offset.click.top=e.top+this.margins.top),"bottom"in e&&(this.offset.click.top=this.helperProportions.height-e.bottom+this.margins.top)},_isRootNode:function(t){return/(html|body)/i.test(t.tagName)||t===this.document[0]},_getParentOffset:function(){var e=this.offsetParent.offset(),i=this.document[0];return"absolute"===this.cssPosition&&this.scrollParent[0]!==i&&t.contains(this.scrollParent[0],this.offsetParent[0])&&(e.left+=this.scrollParent.scrollLeft(),e.top+=this.scrollParent.scrollTop()),this._isRootNode(this.offsetParent[0])&&(e={top:0,left:0}),{top:e.top+(parseInt(this.offsetParent.css("borderTopWidth"),10)||0),left:e.left+(parseInt(this.offsetParent.css("borderLeftWidth"),10)||0)}},_getRelativeOffset:function(){if("relative"!==this.cssPosition)return{top:0,left:0};var t=this.element.position(),e=this._isRootNode(this.scrollParent[0]);return{top:t.top-(parseInt(this.helper.css("top"),10)||0)+(e?0:this.scrollParent.scrollTop()),left:t.left-(parseInt(this.helper.css("left"),10)||0)+(e?0:this.scrollParent.scrollLeft())} +},_cacheMargins:function(){this.margins={left:parseInt(this.element.css("marginLeft"),10)||0,top:parseInt(this.element.css("marginTop"),10)||0,right:parseInt(this.element.css("marginRight"),10)||0,bottom:parseInt(this.element.css("marginBottom"),10)||0}},_cacheHelperProportions:function(){this.helperProportions={width:this.helper.outerWidth(),height:this.helper.outerHeight()}},_setContainment:function(){var e,i,s,n=this.options,o=this.document[0];return this.relativeContainer=null,n.containment?"window"===n.containment?(this.containment=[t(window).scrollLeft()-this.offset.relative.left-this.offset.parent.left,t(window).scrollTop()-this.offset.relative.top-this.offset.parent.top,t(window).scrollLeft()+t(window).width()-this.helperProportions.width-this.margins.left,t(window).scrollTop()+(t(window).height()||o.body.parentNode.scrollHeight)-this.helperProportions.height-this.margins.top],void 0):"document"===n.containment?(this.containment=[0,0,t(o).width()-this.helperProportions.width-this.margins.left,(t(o).height()||o.body.parentNode.scrollHeight)-this.helperProportions.height-this.margins.top],void 0):n.containment.constructor===Array?(this.containment=n.containment,void 0):("parent"===n.containment&&(n.containment=this.helper[0].parentNode),i=t(n.containment),s=i[0],s&&(e=/(scroll|auto)/.test(i.css("overflow")),this.containment=[(parseInt(i.css("borderLeftWidth"),10)||0)+(parseInt(i.css("paddingLeft"),10)||0),(parseInt(i.css("borderTopWidth"),10)||0)+(parseInt(i.css("paddingTop"),10)||0),(e?Math.max(s.scrollWidth,s.offsetWidth):s.offsetWidth)-(parseInt(i.css("borderRightWidth"),10)||0)-(parseInt(i.css("paddingRight"),10)||0)-this.helperProportions.width-this.margins.left-this.margins.right,(e?Math.max(s.scrollHeight,s.offsetHeight):s.offsetHeight)-(parseInt(i.css("borderBottomWidth"),10)||0)-(parseInt(i.css("paddingBottom"),10)||0)-this.helperProportions.height-this.margins.top-this.margins.bottom],this.relativeContainer=i),void 0):(this.containment=null,void 0)},_convertPositionTo:function(t,e){e||(e=this.position);var i="absolute"===t?1:-1,s=this._isRootNode(this.scrollParent[0]);return{top:e.top+this.offset.relative.top*i+this.offset.parent.top*i-("fixed"===this.cssPosition?-this.offset.scroll.top:s?0:this.offset.scroll.top)*i,left:e.left+this.offset.relative.left*i+this.offset.parent.left*i-("fixed"===this.cssPosition?-this.offset.scroll.left:s?0:this.offset.scroll.left)*i}},_generatePosition:function(t,e){var i,s,n,o,a=this.options,r=this._isRootNode(this.scrollParent[0]),h=t.pageX,l=t.pageY;return r&&this.offset.scroll||(this.offset.scroll={top:this.scrollParent.scrollTop(),left:this.scrollParent.scrollLeft()}),e&&(this.containment&&(this.relativeContainer?(s=this.relativeContainer.offset(),i=[this.containment[0]+s.left,this.containment[1]+s.top,this.containment[2]+s.left,this.containment[3]+s.top]):i=this.containment,t.pageX-this.offset.click.left<i[0]&&(h=i[0]+this.offset.click.left),t.pageY-this.offset.click.top<i[1]&&(l=i[1]+this.offset.click.top),t.pageX-this.offset.click.left>i[2]&&(h=i[2]+this.offset.click.left),t.pageY-this.offset.click.top>i[3]&&(l=i[3]+this.offset.click.top)),a.grid&&(n=a.grid[1]?this.originalPageY+Math.round((l-this.originalPageY)/a.grid[1])*a.grid[1]:this.originalPageY,l=i?n-this.offset.click.top>=i[1]||n-this.offset.click.top>i[3]?n:n-this.offset.click.top>=i[1]?n-a.grid[1]:n+a.grid[1]:n,o=a.grid[0]?this.originalPageX+Math.round((h-this.originalPageX)/a.grid[0])*a.grid[0]:this.originalPageX,h=i?o-this.offset.click.left>=i[0]||o-this.offset.click.left>i[2]?o:o-this.offset.click.left>=i[0]?o-a.grid[0]:o+a.grid[0]:o),"y"===a.axis&&(h=this.originalPageX),"x"===a.axis&&(l=this.originalPageY)),{top:l-this.offset.click.top-this.offset.relative.top-this.offset.parent.top+("fixed"===this.cssPosition?-this.offset.scroll.top:r?0:this.offset.scroll.top),left:h-this.offset.click.left-this.offset.relative.left-this.offset.parent.left+("fixed"===this.cssPosition?-this.offset.scroll.left:r?0:this.offset.scroll.left)}},_clear:function(){this._removeClass(this.helper,"ui-draggable-dragging"),this.helper[0]===this.element[0]||this.cancelHelperRemoval||this.helper.remove(),this.helper=null,this.cancelHelperRemoval=!1,this.destroyOnClear&&this.destroy()},_trigger:function(e,i,s){return s=s||this._uiHash(),t.ui.plugin.call(this,e,[i,s,this],!0),/^(drag|start|stop)/.test(e)&&(this.positionAbs=this._convertPositionTo("absolute"),s.offset=this.positionAbs),t.Widget.prototype._trigger.call(this,e,i,s)},plugins:{},_uiHash:function(){return{helper:this.helper,position:this.position,originalPosition:this.originalPosition,offset:this.positionAbs}}}),t.ui.plugin.add("draggable","connectToSortable",{start:function(e,i,s){var n=t.extend({},i,{item:s.element});s.sortables=[],t(s.options.connectToSortable).each(function(){var i=t(this).sortable("instance");i&&!i.options.disabled&&(s.sortables.push(i),i.refreshPositions(),i._trigger("activate",e,n))})},stop:function(e,i,s){var n=t.extend({},i,{item:s.element});s.cancelHelperRemoval=!1,t.each(s.sortables,function(){var t=this;t.isOver?(t.isOver=0,s.cancelHelperRemoval=!0,t.cancelHelperRemoval=!1,t._storedCSS={position:t.placeholder.css("position"),top:t.placeholder.css("top"),left:t.placeholder.css("left")},t._mouseStop(e),t.options.helper=t.options._helper):(t.cancelHelperRemoval=!0,t._trigger("deactivate",e,n))})},drag:function(e,i,s){t.each(s.sortables,function(){var n=!1,o=this;o.positionAbs=s.positionAbs,o.helperProportions=s.helperProportions,o.offset.click=s.offset.click,o._intersectsWith(o.containerCache)&&(n=!0,t.each(s.sortables,function(){return this.positionAbs=s.positionAbs,this.helperProportions=s.helperProportions,this.offset.click=s.offset.click,this!==o&&this._intersectsWith(this.containerCache)&&t.contains(o.element[0],this.element[0])&&(n=!1),n})),n?(o.isOver||(o.isOver=1,s._parent=i.helper.parent(),o.currentItem=i.helper.appendTo(o.element).data("ui-sortable-item",!0),o.options._helper=o.options.helper,o.options.helper=function(){return i.helper[0]},e.target=o.currentItem[0],o._mouseCapture(e,!0),o._mouseStart(e,!0,!0),o.offset.click.top=s.offset.click.top,o.offset.click.left=s.offset.click.left,o.offset.parent.left-=s.offset.parent.left-o.offset.parent.left,o.offset.parent.top-=s.offset.parent.top-o.offset.parent.top,s._trigger("toSortable",e),s.dropped=o.element,t.each(s.sortables,function(){this.refreshPositions()}),s.currentItem=s.element,o.fromOutside=s),o.currentItem&&(o._mouseDrag(e),i.position=o.position)):o.isOver&&(o.isOver=0,o.cancelHelperRemoval=!0,o.options._revert=o.options.revert,o.options.revert=!1,o._trigger("out",e,o._uiHash(o)),o._mouseStop(e,!0),o.options.revert=o.options._revert,o.options.helper=o.options._helper,o.placeholder&&o.placeholder.remove(),i.helper.appendTo(s._parent),s._refreshOffsets(e),i.position=s._generatePosition(e,!0),s._trigger("fromSortable",e),s.dropped=!1,t.each(s.sortables,function(){this.refreshPositions()}))})}}),t.ui.plugin.add("draggable","cursor",{start:function(e,i,s){var n=t("body"),o=s.options;n.css("cursor")&&(o._cursor=n.css("cursor")),n.css("cursor",o.cursor)},stop:function(e,i,s){var n=s.options;n._cursor&&t("body").css("cursor",n._cursor)}}),t.ui.plugin.add("draggable","opacity",{start:function(e,i,s){var n=t(i.helper),o=s.options;n.css("opacity")&&(o._opacity=n.css("opacity")),n.css("opacity",o.opacity)},stop:function(e,i,s){var n=s.options;n._opacity&&t(i.helper).css("opacity",n._opacity)}}),t.ui.plugin.add("draggable","scroll",{start:function(t,e,i){i.scrollParentNotHidden||(i.scrollParentNotHidden=i.helper.scrollParent(!1)),i.scrollParentNotHidden[0]!==i.document[0]&&"HTML"!==i.scrollParentNotHidden[0].tagName&&(i.overflowOffset=i.scrollParentNotHidden.offset())},drag:function(e,i,s){var n=s.options,o=!1,a=s.scrollParentNotHidden[0],r=s.document[0];a!==r&&"HTML"!==a.tagName?(n.axis&&"x"===n.axis||(s.overflowOffset.top+a.offsetHeight-e.pageY<n.scrollSensitivity?a.scrollTop=o=a.scrollTop+n.scrollSpeed:e.pageY-s.overflowOffset.top<n.scrollSensitivity&&(a.scrollTop=o=a.scrollTop-n.scrollSpeed)),n.axis&&"y"===n.axis||(s.overflowOffset.left+a.offsetWidth-e.pageX<n.scrollSensitivity?a.scrollLeft=o=a.scrollLeft+n.scrollSpeed:e.pageX-s.overflowOffset.left<n.scrollSensitivity&&(a.scrollLeft=o=a.scrollLeft-n.scrollSpeed))):(n.axis&&"x"===n.axis||(e.pageY-t(r).scrollTop()<n.scrollSensitivity?o=t(r).scrollTop(t(r).scrollTop()-n.scrollSpeed):t(window).height()-(e.pageY-t(r).scrollTop())<n.scrollSensitivity&&(o=t(r).scrollTop(t(r).scrollTop()+n.scrollSpeed))),n.axis&&"y"===n.axis||(e.pageX-t(r).scrollLeft()<n.scrollSensitivity?o=t(r).scrollLeft(t(r).scrollLeft()-n.scrollSpeed):t(window).width()-(e.pageX-t(r).scrollLeft())<n.scrollSensitivity&&(o=t(r).scrollLeft(t(r).scrollLeft()+n.scrollSpeed)))),o!==!1&&t.ui.ddmanager&&!n.dropBehaviour&&t.ui.ddmanager.prepareOffsets(s,e)}}),t.ui.plugin.add("draggable","snap",{start:function(e,i,s){var n=s.options;s.snapElements=[],t(n.snap.constructor!==String?n.snap.items||":data(ui-draggable)":n.snap).each(function(){var e=t(this),i=e.offset();this!==s.element[0]&&s.snapElements.push({item:this,width:e.outerWidth(),height:e.outerHeight(),top:i.top,left:i.left})})},drag:function(e,i,s){var n,o,a,r,h,l,c,u,d,p,f=s.options,g=f.snapTolerance,m=i.offset.left,_=m+s.helperProportions.width,v=i.offset.top,b=v+s.helperProportions.height;for(d=s.snapElements.length-1;d>=0;d--)h=s.snapElements[d].left-s.margins.left,l=h+s.snapElements[d].width,c=s.snapElements[d].top-s.margins.top,u=c+s.snapElements[d].height,h-g>_||m>l+g||c-g>b||v>u+g||!t.contains(s.snapElements[d].item.ownerDocument,s.snapElements[d].item)?(s.snapElements[d].snapping&&s.options.snap.release&&s.options.snap.release.call(s.element,e,t.extend(s._uiHash(),{snapItem:s.snapElements[d].item})),s.snapElements[d].snapping=!1):("inner"!==f.snapMode&&(n=g>=Math.abs(c-b),o=g>=Math.abs(u-v),a=g>=Math.abs(h-_),r=g>=Math.abs(l-m),n&&(i.position.top=s._convertPositionTo("relative",{top:c-s.helperProportions.height,left:0}).top),o&&(i.position.top=s._convertPositionTo("relative",{top:u,left:0}).top),a&&(i.position.left=s._convertPositionTo("relative",{top:0,left:h-s.helperProportions.width}).left),r&&(i.position.left=s._convertPositionTo("relative",{top:0,left:l}).left)),p=n||o||a||r,"outer"!==f.snapMode&&(n=g>=Math.abs(c-v),o=g>=Math.abs(u-b),a=g>=Math.abs(h-m),r=g>=Math.abs(l-_),n&&(i.position.top=s._convertPositionTo("relative",{top:c,left:0}).top),o&&(i.position.top=s._convertPositionTo("relative",{top:u-s.helperProportions.height,left:0}).top),a&&(i.position.left=s._convertPositionTo("relative",{top:0,left:h}).left),r&&(i.position.left=s._convertPositionTo("relative",{top:0,left:l-s.helperProportions.width}).left)),!s.snapElements[d].snapping&&(n||o||a||r||p)&&s.options.snap.snap&&s.options.snap.snap.call(s.element,e,t.extend(s._uiHash(),{snapItem:s.snapElements[d].item})),s.snapElements[d].snapping=n||o||a||r||p)}}),t.ui.plugin.add("draggable","stack",{start:function(e,i,s){var n,o=s.options,a=t.makeArray(t(o.stack)).sort(function(e,i){return(parseInt(t(e).css("zIndex"),10)||0)-(parseInt(t(i).css("zIndex"),10)||0)});a.length&&(n=parseInt(t(a[0]).css("zIndex"),10)||0,t(a).each(function(e){t(this).css("zIndex",n+e)}),this.css("zIndex",n+a.length))}}),t.ui.plugin.add("draggable","zIndex",{start:function(e,i,s){var n=t(i.helper),o=s.options;n.css("zIndex")&&(o._zIndex=n.css("zIndex")),n.css("zIndex",o.zIndex)},stop:function(e,i,s){var n=s.options;n._zIndex&&t(i.helper).css("zIndex",n._zIndex)}}),t.ui.draggable,t.widget("ui.resizable",t.ui.mouse,{version:"1.12.1",widgetEventPrefix:"resize",options:{alsoResize:!1,animate:!1,animateDuration:"slow",animateEasing:"swing",aspectRatio:!1,autoHide:!1,classes:{"ui-resizable-se":"ui-icon ui-icon-gripsmall-diagonal-se"},containment:!1,ghost:!1,grid:!1,handles:"e,s,se",helper:!1,maxHeight:null,maxWidth:null,minHeight:10,minWidth:10,zIndex:90,resize:null,start:null,stop:null},_num:function(t){return parseFloat(t)||0},_isNumber:function(t){return!isNaN(parseFloat(t))},_hasScroll:function(e,i){if("hidden"===t(e).css("overflow"))return!1;var s=i&&"left"===i?"scrollLeft":"scrollTop",n=!1;return e[s]>0?!0:(e[s]=1,n=e[s]>0,e[s]=0,n)},_create:function(){var e,i=this.options,s=this;this._addClass("ui-resizable"),t.extend(this,{_aspectRatio:!!i.aspectRatio,aspectRatio:i.aspectRatio,originalElement:this.element,_proportionallyResizeElements:[],_helper:i.helper||i.ghost||i.animate?i.helper||"ui-resizable-helper":null}),this.element[0].nodeName.match(/^(canvas|textarea|input|select|button|img)$/i)&&(this.element.wrap(t("<div class='ui-wrapper' style='overflow: hidden;'></div>").css({position:this.element.css("position"),width:this.element.outerWidth(),height:this.element.outerHeight(),top:this.element.css("top"),left:this.element.css("left")})),this.element=this.element.parent().data("ui-resizable",this.element.resizable("instance")),this.elementIsWrapper=!0,e={marginTop:this.originalElement.css("marginTop"),marginRight:this.originalElement.css("marginRight"),marginBottom:this.originalElement.css("marginBottom"),marginLeft:this.originalElement.css("marginLeft")},this.element.css(e),this.originalElement.css("margin",0),this.originalResizeStyle=this.originalElement.css("resize"),this.originalElement.css("resize","none"),this._proportionallyResizeElements.push(this.originalElement.css({position:"static",zoom:1,display:"block"})),this.originalElement.css(e),this._proportionallyResize()),this._setupHandles(),i.autoHide&&t(this.element).on("mouseenter",function(){i.disabled||(s._removeClass("ui-resizable-autohide"),s._handles.show())}).on("mouseleave",function(){i.disabled||s.resizing||(s._addClass("ui-resizable-autohide"),s._handles.hide())}),this._mouseInit()},_destroy:function(){this._mouseDestroy();var e,i=function(e){t(e).removeData("resizable").removeData("ui-resizable").off(".resizable").find(".ui-resizable-handle").remove()};return this.elementIsWrapper&&(i(this.element),e=this.element,this.originalElement.css({position:e.css("position"),width:e.outerWidth(),height:e.outerHeight(),top:e.css("top"),left:e.css("left")}).insertAfter(e),e.remove()),this.originalElement.css("resize",this.originalResizeStyle),i(this.originalElement),this},_setOption:function(t,e){switch(this._super(t,e),t){case"handles":this._removeHandles(),this._setupHandles();break;default:}},_setupHandles:function(){var e,i,s,n,o,a=this.options,r=this;if(this.handles=a.handles||(t(".ui-resizable-handle",this.element).length?{n:".ui-resizable-n",e:".ui-resizable-e",s:".ui-resizable-s",w:".ui-resizable-w",se:".ui-resizable-se",sw:".ui-resizable-sw",ne:".ui-resizable-ne",nw:".ui-resizable-nw"}:"e,s,se"),this._handles=t(),this.handles.constructor===String)for("all"===this.handles&&(this.handles="n,e,s,w,se,sw,ne,nw"),s=this.handles.split(","),this.handles={},i=0;s.length>i;i++)e=t.trim(s[i]),n="ui-resizable-"+e,o=t("<div>"),this._addClass(o,"ui-resizable-handle "+n),o.css({zIndex:a.zIndex}),this.handles[e]=".ui-resizable-"+e,this.element.append(o);this._renderAxis=function(e){var i,s,n,o;e=e||this.element;for(i in this.handles)this.handles[i].constructor===String?this.handles[i]=this.element.children(this.handles[i]).first().show():(this.handles[i].jquery||this.handles[i].nodeType)&&(this.handles[i]=t(this.handles[i]),this._on(this.handles[i],{mousedown:r._mouseDown})),this.elementIsWrapper&&this.originalElement[0].nodeName.match(/^(textarea|input|select|button)$/i)&&(s=t(this.handles[i],this.element),o=/sw|ne|nw|se|n|s/.test(i)?s.outerHeight():s.outerWidth(),n=["padding",/ne|nw|n/.test(i)?"Top":/se|sw|s/.test(i)?"Bottom":/^e$/.test(i)?"Right":"Left"].join(""),e.css(n,o),this._proportionallyResize()),this._handles=this._handles.add(this.handles[i])},this._renderAxis(this.element),this._handles=this._handles.add(this.element.find(".ui-resizable-handle")),this._handles.disableSelection(),this._handles.on("mouseover",function(){r.resizing||(this.className&&(o=this.className.match(/ui-resizable-(se|sw|ne|nw|n|e|s|w)/i)),r.axis=o&&o[1]?o[1]:"se")}),a.autoHide&&(this._handles.hide(),this._addClass("ui-resizable-autohide"))},_removeHandles:function(){this._handles.remove()},_mouseCapture:function(e){var i,s,n=!1;for(i in this.handles)s=t(this.handles[i])[0],(s===e.target||t.contains(s,e.target))&&(n=!0);return!this.options.disabled&&n},_mouseStart:function(e){var i,s,n,o=this.options,a=this.element;return this.resizing=!0,this._renderProxy(),i=this._num(this.helper.css("left")),s=this._num(this.helper.css("top")),o.containment&&(i+=t(o.containment).scrollLeft()||0,s+=t(o.containment).scrollTop()||0),this.offset=this.helper.offset(),this.position={left:i,top:s},this.size=this._helper?{width:this.helper.width(),height:this.helper.height()}:{width:a.width(),height:a.height()},this.originalSize=this._helper?{width:a.outerWidth(),height:a.outerHeight()}:{width:a.width(),height:a.height()},this.sizeDiff={width:a.outerWidth()-a.width(),height:a.outerHeight()-a.height()},this.originalPosition={left:i,top:s},this.originalMousePosition={left:e.pageX,top:e.pageY},this.aspectRatio="number"==typeof o.aspectRatio?o.aspectRatio:this.originalSize.width/this.originalSize.height||1,n=t(".ui-resizable-"+this.axis).css("cursor"),t("body").css("cursor","auto"===n?this.axis+"-resize":n),this._addClass("ui-resizable-resizing"),this._propagate("start",e),!0},_mouseDrag:function(e){var i,s,n=this.originalMousePosition,o=this.axis,a=e.pageX-n.left||0,r=e.pageY-n.top||0,h=this._change[o];return this._updatePrevProperties(),h?(i=h.apply(this,[e,a,r]),this._updateVirtualBoundaries(e.shiftKey),(this._aspectRatio||e.shiftKey)&&(i=this._updateRatio(i,e)),i=this._respectSize(i,e),this._updateCache(i),this._propagate("resize",e),s=this._applyChanges(),!this._helper&&this._proportionallyResizeElements.length&&this._proportionallyResize(),t.isEmptyObject(s)||(this._updatePrevProperties(),this._trigger("resize",e,this.ui()),this._applyChanges()),!1):!1},_mouseStop:function(e){this.resizing=!1;var i,s,n,o,a,r,h,l=this.options,c=this;return this._helper&&(i=this._proportionallyResizeElements,s=i.length&&/textarea/i.test(i[0].nodeName),n=s&&this._hasScroll(i[0],"left")?0:c.sizeDiff.height,o=s?0:c.sizeDiff.width,a={width:c.helper.width()-o,height:c.helper.height()-n},r=parseFloat(c.element.css("left"))+(c.position.left-c.originalPosition.left)||null,h=parseFloat(c.element.css("top"))+(c.position.top-c.originalPosition.top)||null,l.animate||this.element.css(t.extend(a,{top:h,left:r})),c.helper.height(c.size.height),c.helper.width(c.size.width),this._helper&&!l.animate&&this._proportionallyResize()),t("body").css("cursor","auto"),this._removeClass("ui-resizable-resizing"),this._propagate("stop",e),this._helper&&this.helper.remove(),!1},_updatePrevProperties:function(){this.prevPosition={top:this.position.top,left:this.position.left},this.prevSize={width:this.size.width,height:this.size.height}},_applyChanges:function(){var t={};return this.position.top!==this.prevPosition.top&&(t.top=this.position.top+"px"),this.position.left!==this.prevPosition.left&&(t.left=this.position.left+"px"),this.size.width!==this.prevSize.width&&(t.width=this.size.width+"px"),this.size.height!==this.prevSize.height&&(t.height=this.size.height+"px"),this.helper.css(t),t},_updateVirtualBoundaries:function(t){var e,i,s,n,o,a=this.options;o={minWidth:this._isNumber(a.minWidth)?a.minWidth:0,maxWidth:this._isNumber(a.maxWidth)?a.maxWidth:1/0,minHeight:this._isNumber(a.minHeight)?a.minHeight:0,maxHeight:this._isNumber(a.maxHeight)?a.maxHeight:1/0},(this._aspectRatio||t)&&(e=o.minHeight*this.aspectRatio,s=o.minWidth/this.aspectRatio,i=o.maxHeight*this.aspectRatio,n=o.maxWidth/this.aspectRatio,e>o.minWidth&&(o.minWidth=e),s>o.minHeight&&(o.minHeight=s),o.maxWidth>i&&(o.maxWidth=i),o.maxHeight>n&&(o.maxHeight=n)),this._vBoundaries=o},_updateCache:function(t){this.offset=this.helper.offset(),this._isNumber(t.left)&&(this.position.left=t.left),this._isNumber(t.top)&&(this.position.top=t.top),this._isNumber(t.height)&&(this.size.height=t.height),this._isNumber(t.width)&&(this.size.width=t.width)},_updateRatio:function(t){var e=this.position,i=this.size,s=this.axis;return this._isNumber(t.height)?t.width=t.height*this.aspectRatio:this._isNumber(t.width)&&(t.height=t.width/this.aspectRatio),"sw"===s&&(t.left=e.left+(i.width-t.width),t.top=null),"nw"===s&&(t.top=e.top+(i.height-t.height),t.left=e.left+(i.width-t.width)),t},_respectSize:function(t){var e=this._vBoundaries,i=this.axis,s=this._isNumber(t.width)&&e.maxWidth&&e.maxWidth<t.width,n=this._isNumber(t.height)&&e.maxHeight&&e.maxHeight<t.height,o=this._isNumber(t.width)&&e.minWidth&&e.minWidth>t.width,a=this._isNumber(t.height)&&e.minHeight&&e.minHeight>t.height,r=this.originalPosition.left+this.originalSize.width,h=this.originalPosition.top+this.originalSize.height,l=/sw|nw|w/.test(i),c=/nw|ne|n/.test(i);return o&&(t.width=e.minWidth),a&&(t.height=e.minHeight),s&&(t.width=e.maxWidth),n&&(t.height=e.maxHeight),o&&l&&(t.left=r-e.minWidth),s&&l&&(t.left=r-e.maxWidth),a&&c&&(t.top=h-e.minHeight),n&&c&&(t.top=h-e.maxHeight),t.width||t.height||t.left||!t.top?t.width||t.height||t.top||!t.left||(t.left=null):t.top=null,t},_getPaddingPlusBorderDimensions:function(t){for(var e=0,i=[],s=[t.css("borderTopWidth"),t.css("borderRightWidth"),t.css("borderBottomWidth"),t.css("borderLeftWidth")],n=[t.css("paddingTop"),t.css("paddingRight"),t.css("paddingBottom"),t.css("paddingLeft")];4>e;e++)i[e]=parseFloat(s[e])||0,i[e]+=parseFloat(n[e])||0;return{height:i[0]+i[2],width:i[1]+i[3]}},_proportionallyResize:function(){if(this._proportionallyResizeElements.length)for(var t,e=0,i=this.helper||this.element;this._proportionallyResizeElements.length>e;e++)t=this._proportionallyResizeElements[e],this.outerDimensions||(this.outerDimensions=this._getPaddingPlusBorderDimensions(t)),t.css({height:i.height()-this.outerDimensions.height||0,width:i.width()-this.outerDimensions.width||0})},_renderProxy:function(){var e=this.element,i=this.options;this.elementOffset=e.offset(),this._helper?(this.helper=this.helper||t("<div style='overflow:hidden;'></div>"),this._addClass(this.helper,this._helper),this.helper.css({width:this.element.outerWidth(),height:this.element.outerHeight(),position:"absolute",left:this.elementOffset.left+"px",top:this.elementOffset.top+"px",zIndex:++i.zIndex}),this.helper.appendTo("body").disableSelection()):this.helper=this.element},_change:{e:function(t,e){return{width:this.originalSize.width+e}},w:function(t,e){var i=this.originalSize,s=this.originalPosition;return{left:s.left+e,width:i.width-e}},n:function(t,e,i){var s=this.originalSize,n=this.originalPosition;return{top:n.top+i,height:s.height-i}},s:function(t,e,i){return{height:this.originalSize.height+i}},se:function(e,i,s){return t.extend(this._change.s.apply(this,arguments),this._change.e.apply(this,[e,i,s]))},sw:function(e,i,s){return t.extend(this._change.s.apply(this,arguments),this._change.w.apply(this,[e,i,s]))},ne:function(e,i,s){return t.extend(this._change.n.apply(this,arguments),this._change.e.apply(this,[e,i,s]))},nw:function(e,i,s){return t.extend(this._change.n.apply(this,arguments),this._change.w.apply(this,[e,i,s]))}},_propagate:function(e,i){t.ui.plugin.call(this,e,[i,this.ui()]),"resize"!==e&&this._trigger(e,i,this.ui())},plugins:{},ui:function(){return{originalElement:this.originalElement,element:this.element,helper:this.helper,position:this.position,size:this.size,originalSize:this.originalSize,originalPosition:this.originalPosition}}}),t.ui.plugin.add("resizable","animate",{stop:function(e){var i=t(this).resizable("instance"),s=i.options,n=i._proportionallyResizeElements,o=n.length&&/textarea/i.test(n[0].nodeName),a=o&&i._hasScroll(n[0],"left")?0:i.sizeDiff.height,r=o?0:i.sizeDiff.width,h={width:i.size.width-r,height:i.size.height-a},l=parseFloat(i.element.css("left"))+(i.position.left-i.originalPosition.left)||null,c=parseFloat(i.element.css("top"))+(i.position.top-i.originalPosition.top)||null;i.element.animate(t.extend(h,c&&l?{top:c,left:l}:{}),{duration:s.animateDuration,easing:s.animateEasing,step:function(){var s={width:parseFloat(i.element.css("width")),height:parseFloat(i.element.css("height")),top:parseFloat(i.element.css("top")),left:parseFloat(i.element.css("left"))};n&&n.length&&t(n[0]).css({width:s.width,height:s.height}),i._updateCache(s),i._propagate("resize",e)}})}}),t.ui.plugin.add("resizable","containment",{start:function(){var e,i,s,n,o,a,r,h=t(this).resizable("instance"),l=h.options,c=h.element,u=l.containment,d=u instanceof t?u.get(0):/parent/.test(u)?c.parent().get(0):u;d&&(h.containerElement=t(d),/document/.test(u)||u===document?(h.containerOffset={left:0,top:0},h.containerPosition={left:0,top:0},h.parentData={element:t(document),left:0,top:0,width:t(document).width(),height:t(document).height()||document.body.parentNode.scrollHeight}):(e=t(d),i=[],t(["Top","Right","Left","Bottom"]).each(function(t,s){i[t]=h._num(e.css("padding"+s))}),h.containerOffset=e.offset(),h.containerPosition=e.position(),h.containerSize={height:e.innerHeight()-i[3],width:e.innerWidth()-i[1]},s=h.containerOffset,n=h.containerSize.height,o=h.containerSize.width,a=h._hasScroll(d,"left")?d.scrollWidth:o,r=h._hasScroll(d)?d.scrollHeight:n,h.parentData={element:d,left:s.left,top:s.top,width:a,height:r}))},resize:function(e){var i,s,n,o,a=t(this).resizable("instance"),r=a.options,h=a.containerOffset,l=a.position,c=a._aspectRatio||e.shiftKey,u={top:0,left:0},d=a.containerElement,p=!0;d[0]!==document&&/static/.test(d.css("position"))&&(u=h),l.left<(a._helper?h.left:0)&&(a.size.width=a.size.width+(a._helper?a.position.left-h.left:a.position.left-u.left),c&&(a.size.height=a.size.width/a.aspectRatio,p=!1),a.position.left=r.helper?h.left:0),l.top<(a._helper?h.top:0)&&(a.size.height=a.size.height+(a._helper?a.position.top-h.top:a.position.top),c&&(a.size.width=a.size.height*a.aspectRatio,p=!1),a.position.top=a._helper?h.top:0),n=a.containerElement.get(0)===a.element.parent().get(0),o=/relative|absolute/.test(a.containerElement.css("position")),n&&o?(a.offset.left=a.parentData.left+a.position.left,a.offset.top=a.parentData.top+a.position.top):(a.offset.left=a.element.offset().left,a.offset.top=a.element.offset().top),i=Math.abs(a.sizeDiff.width+(a._helper?a.offset.left-u.left:a.offset.left-h.left)),s=Math.abs(a.sizeDiff.height+(a._helper?a.offset.top-u.top:a.offset.top-h.top)),i+a.size.width>=a.parentData.width&&(a.size.width=a.parentData.width-i,c&&(a.size.height=a.size.width/a.aspectRatio,p=!1)),s+a.size.height>=a.parentData.height&&(a.size.height=a.parentData.height-s,c&&(a.size.width=a.size.height*a.aspectRatio,p=!1)),p||(a.position.left=a.prevPosition.left,a.position.top=a.prevPosition.top,a.size.width=a.prevSize.width,a.size.height=a.prevSize.height)},stop:function(){var e=t(this).resizable("instance"),i=e.options,s=e.containerOffset,n=e.containerPosition,o=e.containerElement,a=t(e.helper),r=a.offset(),h=a.outerWidth()-e.sizeDiff.width,l=a.outerHeight()-e.sizeDiff.height;e._helper&&!i.animate&&/relative/.test(o.css("position"))&&t(this).css({left:r.left-n.left-s.left,width:h,height:l}),e._helper&&!i.animate&&/static/.test(o.css("position"))&&t(this).css({left:r.left-n.left-s.left,width:h,height:l})}}),t.ui.plugin.add("resizable","alsoResize",{start:function(){var e=t(this).resizable("instance"),i=e.options;t(i.alsoResize).each(function(){var e=t(this);e.data("ui-resizable-alsoresize",{width:parseFloat(e.width()),height:parseFloat(e.height()),left:parseFloat(e.css("left")),top:parseFloat(e.css("top"))})})},resize:function(e,i){var s=t(this).resizable("instance"),n=s.options,o=s.originalSize,a=s.originalPosition,r={height:s.size.height-o.height||0,width:s.size.width-o.width||0,top:s.position.top-a.top||0,left:s.position.left-a.left||0};t(n.alsoResize).each(function(){var e=t(this),s=t(this).data("ui-resizable-alsoresize"),n={},o=e.parents(i.originalElement[0]).length?["width","height"]:["width","height","top","left"];t.each(o,function(t,e){var i=(s[e]||0)+(r[e]||0);i&&i>=0&&(n[e]=i||null)}),e.css(n)})},stop:function(){t(this).removeData("ui-resizable-alsoresize")}}),t.ui.plugin.add("resizable","ghost",{start:function(){var e=t(this).resizable("instance"),i=e.size;e.ghost=e.originalElement.clone(),e.ghost.css({opacity:.25,display:"block",position:"relative",height:i.height,width:i.width,margin:0,left:0,top:0}),e._addClass(e.ghost,"ui-resizable-ghost"),t.uiBackCompat!==!1&&"string"==typeof e.options.ghost&&e.ghost.addClass(this.options.ghost),e.ghost.appendTo(e.helper)},resize:function(){var e=t(this).resizable("instance");e.ghost&&e.ghost.css({position:"relative",height:e.size.height,width:e.size.width})},stop:function(){var e=t(this).resizable("instance");e.ghost&&e.helper&&e.helper.get(0).removeChild(e.ghost.get(0))}}),t.ui.plugin.add("resizable","grid",{resize:function(){var e,i=t(this).resizable("instance"),s=i.options,n=i.size,o=i.originalSize,a=i.originalPosition,r=i.axis,h="number"==typeof s.grid?[s.grid,s.grid]:s.grid,l=h[0]||1,c=h[1]||1,u=Math.round((n.width-o.width)/l)*l,d=Math.round((n.height-o.height)/c)*c,p=o.width+u,f=o.height+d,g=s.maxWidth&&p>s.maxWidth,m=s.maxHeight&&f>s.maxHeight,_=s.minWidth&&s.minWidth>p,v=s.minHeight&&s.minHeight>f;s.grid=h,_&&(p+=l),v&&(f+=c),g&&(p-=l),m&&(f-=c),/^(se|s|e)$/.test(r)?(i.size.width=p,i.size.height=f):/^(ne)$/.test(r)?(i.size.width=p,i.size.height=f,i.position.top=a.top-d):/^(sw)$/.test(r)?(i.size.width=p,i.size.height=f,i.position.left=a.left-u):((0>=f-c||0>=p-l)&&(e=i._getPaddingPlusBorderDimensions(this)),f-c>0?(i.size.height=f,i.position.top=a.top-d):(f=c-e.height,i.size.height=f,i.position.top=a.top+o.height-f),p-l>0?(i.size.width=p,i.position.left=a.left-u):(p=l-e.width,i.size.width=p,i.position.left=a.left+o.width-p))}}),t.ui.resizable,t.widget("ui.dialog",{version:"1.12.1",options:{appendTo:"body",autoOpen:!0,buttons:[],classes:{"ui-dialog":"ui-corner-all","ui-dialog-titlebar":"ui-corner-all"},closeOnEscape:!0,closeText:"Close",draggable:!0,hide:null,height:"auto",maxHeight:null,maxWidth:null,minHeight:150,minWidth:150,modal:!1,position:{my:"center",at:"center",of:window,collision:"fit",using:function(e){var i=t(this).css(e).offset().top;0>i&&t(this).css("top",e.top-i)}},resizable:!0,show:null,title:null,width:300,beforeClose:null,close:null,drag:null,dragStart:null,dragStop:null,focus:null,open:null,resize:null,resizeStart:null,resizeStop:null},sizeRelatedOptions:{buttons:!0,height:!0,maxHeight:!0,maxWidth:!0,minHeight:!0,minWidth:!0,width:!0},resizableRelatedOptions:{maxHeight:!0,maxWidth:!0,minHeight:!0,minWidth:!0},_create:function(){this.originalCss={display:this.element[0].style.display,width:this.element[0].style.width,minHeight:this.element[0].style.minHeight,maxHeight:this.element[0].style.maxHeight,height:this.element[0].style.height},this.originalPosition={parent:this.element.parent(),index:this.element.parent().children().index(this.element)},this.originalTitle=this.element.attr("title"),null==this.options.title&&null!=this.originalTitle&&(this.options.title=this.originalTitle),this.options.disabled&&(this.options.disabled=!1),this._createWrapper(),this.element.show().removeAttr("title").appendTo(this.uiDialog),this._addClass("ui-dialog-content","ui-widget-content"),this._createTitlebar(),this._createButtonPane(),this.options.draggable&&t.fn.draggable&&this._makeDraggable(),this.options.resizable&&t.fn.resizable&&this._makeResizable(),this._isOpen=!1,this._trackFocus()},_init:function(){this.options.autoOpen&&this.open()},_appendTo:function(){var e=this.options.appendTo;return e&&(e.jquery||e.nodeType)?t(e):this.document.find(e||"body").eq(0)},_destroy:function(){var t,e=this.originalPosition;this._untrackInstance(),this._destroyOverlay(),this.element.removeUniqueId().css(this.originalCss).detach(),this.uiDialog.remove(),this.originalTitle&&this.element.attr("title",this.originalTitle),t=e.parent.children().eq(e.index),t.length&&t[0]!==this.element[0]?t.before(this.element):e.parent.append(this.element)},widget:function(){return this.uiDialog +},disable:t.noop,enable:t.noop,close:function(e){var i=this;this._isOpen&&this._trigger("beforeClose",e)!==!1&&(this._isOpen=!1,this._focusedElement=null,this._destroyOverlay(),this._untrackInstance(),this.opener.filter(":focusable").trigger("focus").length||t.ui.safeBlur(t.ui.safeActiveElement(this.document[0])),this._hide(this.uiDialog,this.options.hide,function(){i._trigger("close",e)}))},isOpen:function(){return this._isOpen},moveToTop:function(){this._moveToTop()},_moveToTop:function(e,i){var s=!1,n=this.uiDialog.siblings(".ui-front:visible").map(function(){return+t(this).css("z-index")}).get(),o=Math.max.apply(null,n);return o>=+this.uiDialog.css("z-index")&&(this.uiDialog.css("z-index",o+1),s=!0),s&&!i&&this._trigger("focus",e),s},open:function(){var e=this;return this._isOpen?(this._moveToTop()&&this._focusTabbable(),void 0):(this._isOpen=!0,this.opener=t(t.ui.safeActiveElement(this.document[0])),this._size(),this._position(),this._createOverlay(),this._moveToTop(null,!0),this.overlay&&this.overlay.css("z-index",this.uiDialog.css("z-index")-1),this._show(this.uiDialog,this.options.show,function(){e._focusTabbable(),e._trigger("focus")}),this._makeFocusTarget(),this._trigger("open"),void 0)},_focusTabbable:function(){var t=this._focusedElement;t||(t=this.element.find("[autofocus]")),t.length||(t=this.element.find(":tabbable")),t.length||(t=this.uiDialogButtonPane.find(":tabbable")),t.length||(t=this.uiDialogTitlebarClose.filter(":tabbable")),t.length||(t=this.uiDialog),t.eq(0).trigger("focus")},_keepFocus:function(e){function i(){var e=t.ui.safeActiveElement(this.document[0]),i=this.uiDialog[0]===e||t.contains(this.uiDialog[0],e);i||this._focusTabbable()}e.preventDefault(),i.call(this),this._delay(i)},_createWrapper:function(){this.uiDialog=t("<div>").hide().attr({tabIndex:-1,role:"dialog"}).appendTo(this._appendTo()),this._addClass(this.uiDialog,"ui-dialog","ui-widget ui-widget-content ui-front"),this._on(this.uiDialog,{keydown:function(e){if(this.options.closeOnEscape&&!e.isDefaultPrevented()&&e.keyCode&&e.keyCode===t.ui.keyCode.ESCAPE)return e.preventDefault(),this.close(e),void 0;if(e.keyCode===t.ui.keyCode.TAB&&!e.isDefaultPrevented()){var i=this.uiDialog.find(":tabbable"),s=i.filter(":first"),n=i.filter(":last");e.target!==n[0]&&e.target!==this.uiDialog[0]||e.shiftKey?e.target!==s[0]&&e.target!==this.uiDialog[0]||!e.shiftKey||(this._delay(function(){n.trigger("focus")}),e.preventDefault()):(this._delay(function(){s.trigger("focus")}),e.preventDefault())}},mousedown:function(t){this._moveToTop(t)&&this._focusTabbable()}}),this.element.find("[aria-describedby]").length||this.uiDialog.attr({"aria-describedby":this.element.uniqueId().attr("id")})},_createTitlebar:function(){var e;this.uiDialogTitlebar=t("<div>"),this._addClass(this.uiDialogTitlebar,"ui-dialog-titlebar","ui-widget-header ui-helper-clearfix"),this._on(this.uiDialogTitlebar,{mousedown:function(e){t(e.target).closest(".ui-dialog-titlebar-close")||this.uiDialog.trigger("focus")}}),this.uiDialogTitlebarClose=t("<button type='button'></button>").button({label:t("<a>").text(this.options.closeText).html(),icon:"ui-icon-closethick",showLabel:!1}).appendTo(this.uiDialogTitlebar),this._addClass(this.uiDialogTitlebarClose,"ui-dialog-titlebar-close"),this._on(this.uiDialogTitlebarClose,{click:function(t){t.preventDefault(),this.close(t)}}),e=t("<span>").uniqueId().prependTo(this.uiDialogTitlebar),this._addClass(e,"ui-dialog-title"),this._title(e),this.uiDialogTitlebar.prependTo(this.uiDialog),this.uiDialog.attr({"aria-labelledby":e.attr("id")})},_title:function(t){this.options.title?t.text(this.options.title):t.html("&#160;")},_createButtonPane:function(){this.uiDialogButtonPane=t("<div>"),this._addClass(this.uiDialogButtonPane,"ui-dialog-buttonpane","ui-widget-content ui-helper-clearfix"),this.uiButtonSet=t("<div>").appendTo(this.uiDialogButtonPane),this._addClass(this.uiButtonSet,"ui-dialog-buttonset"),this._createButtons()},_createButtons:function(){var e=this,i=this.options.buttons;return this.uiDialogButtonPane.remove(),this.uiButtonSet.empty(),t.isEmptyObject(i)||t.isArray(i)&&!i.length?(this._removeClass(this.uiDialog,"ui-dialog-buttons"),void 0):(t.each(i,function(i,s){var n,o;s=t.isFunction(s)?{click:s,text:i}:s,s=t.extend({type:"button"},s),n=s.click,o={icon:s.icon,iconPosition:s.iconPosition,showLabel:s.showLabel,icons:s.icons,text:s.text},delete s.click,delete s.icon,delete s.iconPosition,delete s.showLabel,delete s.icons,"boolean"==typeof s.text&&delete s.text,t("<button></button>",s).button(o).appendTo(e.uiButtonSet).on("click",function(){n.apply(e.element[0],arguments)})}),this._addClass(this.uiDialog,"ui-dialog-buttons"),this.uiDialogButtonPane.appendTo(this.uiDialog),void 0)},_makeDraggable:function(){function e(t){return{position:t.position,offset:t.offset}}var i=this,s=this.options;this.uiDialog.draggable({cancel:".ui-dialog-content, .ui-dialog-titlebar-close",handle:".ui-dialog-titlebar",containment:"document",start:function(s,n){i._addClass(t(this),"ui-dialog-dragging"),i._blockFrames(),i._trigger("dragStart",s,e(n))},drag:function(t,s){i._trigger("drag",t,e(s))},stop:function(n,o){var a=o.offset.left-i.document.scrollLeft(),r=o.offset.top-i.document.scrollTop();s.position={my:"left top",at:"left"+(a>=0?"+":"")+a+" "+"top"+(r>=0?"+":"")+r,of:i.window},i._removeClass(t(this),"ui-dialog-dragging"),i._unblockFrames(),i._trigger("dragStop",n,e(o))}})},_makeResizable:function(){function e(t){return{originalPosition:t.originalPosition,originalSize:t.originalSize,position:t.position,size:t.size}}var i=this,s=this.options,n=s.resizable,o=this.uiDialog.css("position"),a="string"==typeof n?n:"n,e,s,w,se,sw,ne,nw";this.uiDialog.resizable({cancel:".ui-dialog-content",containment:"document",alsoResize:this.element,maxWidth:s.maxWidth,maxHeight:s.maxHeight,minWidth:s.minWidth,minHeight:this._minHeight(),handles:a,start:function(s,n){i._addClass(t(this),"ui-dialog-resizing"),i._blockFrames(),i._trigger("resizeStart",s,e(n))},resize:function(t,s){i._trigger("resize",t,e(s))},stop:function(n,o){var a=i.uiDialog.offset(),r=a.left-i.document.scrollLeft(),h=a.top-i.document.scrollTop();s.height=i.uiDialog.height(),s.width=i.uiDialog.width(),s.position={my:"left top",at:"left"+(r>=0?"+":"")+r+" "+"top"+(h>=0?"+":"")+h,of:i.window},i._removeClass(t(this),"ui-dialog-resizing"),i._unblockFrames(),i._trigger("resizeStop",n,e(o))}}).css("position",o)},_trackFocus:function(){this._on(this.widget(),{focusin:function(e){this._makeFocusTarget(),this._focusedElement=t(e.target)}})},_makeFocusTarget:function(){this._untrackInstance(),this._trackingInstances().unshift(this)},_untrackInstance:function(){var e=this._trackingInstances(),i=t.inArray(this,e);-1!==i&&e.splice(i,1)},_trackingInstances:function(){var t=this.document.data("ui-dialog-instances");return t||(t=[],this.document.data("ui-dialog-instances",t)),t},_minHeight:function(){var t=this.options;return"auto"===t.height?t.minHeight:Math.min(t.minHeight,t.height)},_position:function(){var t=this.uiDialog.is(":visible");t||this.uiDialog.show(),this.uiDialog.position(this.options.position),t||this.uiDialog.hide()},_setOptions:function(e){var i=this,s=!1,n={};t.each(e,function(t,e){i._setOption(t,e),t in i.sizeRelatedOptions&&(s=!0),t in i.resizableRelatedOptions&&(n[t]=e)}),s&&(this._size(),this._position()),this.uiDialog.is(":data(ui-resizable)")&&this.uiDialog.resizable("option",n)},_setOption:function(e,i){var s,n,o=this.uiDialog;"disabled"!==e&&(this._super(e,i),"appendTo"===e&&this.uiDialog.appendTo(this._appendTo()),"buttons"===e&&this._createButtons(),"closeText"===e&&this.uiDialogTitlebarClose.button({label:t("<a>").text(""+this.options.closeText).html()}),"draggable"===e&&(s=o.is(":data(ui-draggable)"),s&&!i&&o.draggable("destroy"),!s&&i&&this._makeDraggable()),"position"===e&&this._position(),"resizable"===e&&(n=o.is(":data(ui-resizable)"),n&&!i&&o.resizable("destroy"),n&&"string"==typeof i&&o.resizable("option","handles",i),n||i===!1||this._makeResizable()),"title"===e&&this._title(this.uiDialogTitlebar.find(".ui-dialog-title")))},_size:function(){var t,e,i,s=this.options;this.element.show().css({width:"auto",minHeight:0,maxHeight:"none",height:0}),s.minWidth>s.width&&(s.width=s.minWidth),t=this.uiDialog.css({height:"auto",width:s.width}).outerHeight(),e=Math.max(0,s.minHeight-t),i="number"==typeof s.maxHeight?Math.max(0,s.maxHeight-t):"none","auto"===s.height?this.element.css({minHeight:e,maxHeight:i,height:"auto"}):this.element.height(Math.max(0,s.height-t)),this.uiDialog.is(":data(ui-resizable)")&&this.uiDialog.resizable("option","minHeight",this._minHeight())},_blockFrames:function(){this.iframeBlocks=this.document.find("iframe").map(function(){var e=t(this);return t("<div>").css({position:"absolute",width:e.outerWidth(),height:e.outerHeight()}).appendTo(e.parent()).offset(e.offset())[0]})},_unblockFrames:function(){this.iframeBlocks&&(this.iframeBlocks.remove(),delete this.iframeBlocks)},_allowInteraction:function(e){return t(e.target).closest(".ui-dialog").length?!0:!!t(e.target).closest(".ui-datepicker").length},_createOverlay:function(){if(this.options.modal){var e=!0;this._delay(function(){e=!1}),this.document.data("ui-dialog-overlays")||this._on(this.document,{focusin:function(t){e||this._allowInteraction(t)||(t.preventDefault(),this._trackingInstances()[0]._focusTabbable())}}),this.overlay=t("<div>").appendTo(this._appendTo()),this._addClass(this.overlay,null,"ui-widget-overlay ui-front"),this._on(this.overlay,{mousedown:"_keepFocus"}),this.document.data("ui-dialog-overlays",(this.document.data("ui-dialog-overlays")||0)+1)}},_destroyOverlay:function(){if(this.options.modal&&this.overlay){var t=this.document.data("ui-dialog-overlays")-1;t?this.document.data("ui-dialog-overlays",t):(this._off(this.document,"focusin"),this.document.removeData("ui-dialog-overlays")),this.overlay.remove(),this.overlay=null}}}),t.uiBackCompat!==!1&&t.widget("ui.dialog",t.ui.dialog,{options:{dialogClass:""},_createWrapper:function(){this._super(),this.uiDialog.addClass(this.options.dialogClass)},_setOption:function(t,e){"dialogClass"===t&&this.uiDialog.removeClass(this.options.dialogClass).addClass(e),this._superApply(arguments)}}),t.ui.dialog,t.widget("ui.droppable",{version:"1.12.1",widgetEventPrefix:"drop",options:{accept:"*",addClasses:!0,greedy:!1,scope:"default",tolerance:"intersect",activate:null,deactivate:null,drop:null,out:null,over:null},_create:function(){var e,i=this.options,s=i.accept;this.isover=!1,this.isout=!0,this.accept=t.isFunction(s)?s:function(t){return t.is(s)},this.proportions=function(){return arguments.length?(e=arguments[0],void 0):e?e:e={width:this.element[0].offsetWidth,height:this.element[0].offsetHeight}},this._addToManager(i.scope),i.addClasses&&this._addClass("ui-droppable")},_addToManager:function(e){t.ui.ddmanager.droppables[e]=t.ui.ddmanager.droppables[e]||[],t.ui.ddmanager.droppables[e].push(this)},_splice:function(t){for(var e=0;t.length>e;e++)t[e]===this&&t.splice(e,1)},_destroy:function(){var e=t.ui.ddmanager.droppables[this.options.scope];this._splice(e)},_setOption:function(e,i){if("accept"===e)this.accept=t.isFunction(i)?i:function(t){return t.is(i)};else if("scope"===e){var s=t.ui.ddmanager.droppables[this.options.scope];this._splice(s),this._addToManager(i)}this._super(e,i)},_activate:function(e){var i=t.ui.ddmanager.current;this._addActiveClass(),i&&this._trigger("activate",e,this.ui(i))},_deactivate:function(e){var i=t.ui.ddmanager.current;this._removeActiveClass(),i&&this._trigger("deactivate",e,this.ui(i))},_over:function(e){var i=t.ui.ddmanager.current;i&&(i.currentItem||i.element)[0]!==this.element[0]&&this.accept.call(this.element[0],i.currentItem||i.element)&&(this._addHoverClass(),this._trigger("over",e,this.ui(i)))},_out:function(e){var i=t.ui.ddmanager.current;i&&(i.currentItem||i.element)[0]!==this.element[0]&&this.accept.call(this.element[0],i.currentItem||i.element)&&(this._removeHoverClass(),this._trigger("out",e,this.ui(i)))},_drop:function(e,i){var s=i||t.ui.ddmanager.current,n=!1;return s&&(s.currentItem||s.element)[0]!==this.element[0]?(this.element.find(":data(ui-droppable)").not(".ui-draggable-dragging").each(function(){var i=t(this).droppable("instance");return i.options.greedy&&!i.options.disabled&&i.options.scope===s.options.scope&&i.accept.call(i.element[0],s.currentItem||s.element)&&v(s,t.extend(i,{offset:i.element.offset()}),i.options.tolerance,e)?(n=!0,!1):void 0}),n?!1:this.accept.call(this.element[0],s.currentItem||s.element)?(this._removeActiveClass(),this._removeHoverClass(),this._trigger("drop",e,this.ui(s)),this.element):!1):!1},ui:function(t){return{draggable:t.currentItem||t.element,helper:t.helper,position:t.position,offset:t.positionAbs}},_addHoverClass:function(){this._addClass("ui-droppable-hover")},_removeHoverClass:function(){this._removeClass("ui-droppable-hover")},_addActiveClass:function(){this._addClass("ui-droppable-active")},_removeActiveClass:function(){this._removeClass("ui-droppable-active")}});var v=t.ui.intersect=function(){function t(t,e,i){return t>=e&&e+i>t}return function(e,i,s,n){if(!i.offset)return!1;var o=(e.positionAbs||e.position.absolute).left+e.margins.left,a=(e.positionAbs||e.position.absolute).top+e.margins.top,r=o+e.helperProportions.width,h=a+e.helperProportions.height,l=i.offset.left,c=i.offset.top,u=l+i.proportions().width,d=c+i.proportions().height;switch(s){case"fit":return o>=l&&u>=r&&a>=c&&d>=h;case"intersect":return o+e.helperProportions.width/2>l&&u>r-e.helperProportions.width/2&&a+e.helperProportions.height/2>c&&d>h-e.helperProportions.height/2;case"pointer":return t(n.pageY,c,i.proportions().height)&&t(n.pageX,l,i.proportions().width);case"touch":return(a>=c&&d>=a||h>=c&&d>=h||c>a&&h>d)&&(o>=l&&u>=o||r>=l&&u>=r||l>o&&r>u);default:return!1}}}();t.ui.ddmanager={current:null,droppables:{"default":[]},prepareOffsets:function(e,i){var s,n,o=t.ui.ddmanager.droppables[e.options.scope]||[],a=i?i.type:null,r=(e.currentItem||e.element).find(":data(ui-droppable)").addBack();t:for(s=0;o.length>s;s++)if(!(o[s].options.disabled||e&&!o[s].accept.call(o[s].element[0],e.currentItem||e.element))){for(n=0;r.length>n;n++)if(r[n]===o[s].element[0]){o[s].proportions().height=0;continue t}o[s].visible="none"!==o[s].element.css("display"),o[s].visible&&("mousedown"===a&&o[s]._activate.call(o[s],i),o[s].offset=o[s].element.offset(),o[s].proportions({width:o[s].element[0].offsetWidth,height:o[s].element[0].offsetHeight}))}},drop:function(e,i){var s=!1;return t.each((t.ui.ddmanager.droppables[e.options.scope]||[]).slice(),function(){this.options&&(!this.options.disabled&&this.visible&&v(e,this,this.options.tolerance,i)&&(s=this._drop.call(this,i)||s),!this.options.disabled&&this.visible&&this.accept.call(this.element[0],e.currentItem||e.element)&&(this.isout=!0,this.isover=!1,this._deactivate.call(this,i)))}),s},dragStart:function(e,i){e.element.parentsUntil("body").on("scroll.droppable",function(){e.options.refreshPositions||t.ui.ddmanager.prepareOffsets(e,i)})},drag:function(e,i){e.options.refreshPositions&&t.ui.ddmanager.prepareOffsets(e,i),t.each(t.ui.ddmanager.droppables[e.options.scope]||[],function(){if(!this.options.disabled&&!this.greedyChild&&this.visible){var s,n,o,a=v(e,this,this.options.tolerance,i),r=!a&&this.isover?"isout":a&&!this.isover?"isover":null;r&&(this.options.greedy&&(n=this.options.scope,o=this.element.parents(":data(ui-droppable)").filter(function(){return t(this).droppable("instance").options.scope===n}),o.length&&(s=t(o[0]).droppable("instance"),s.greedyChild="isover"===r)),s&&"isover"===r&&(s.isover=!1,s.isout=!0,s._out.call(s,i)),this[r]=!0,this["isout"===r?"isover":"isout"]=!1,this["isover"===r?"_over":"_out"].call(this,i),s&&"isout"===r&&(s.isout=!1,s.isover=!0,s._over.call(s,i)))}})},dragStop:function(e,i){e.element.parentsUntil("body").off("scroll.droppable"),e.options.refreshPositions||t.ui.ddmanager.prepareOffsets(e,i)}},t.uiBackCompat!==!1&&t.widget("ui.droppable",t.ui.droppable,{options:{hoverClass:!1,activeClass:!1},_addActiveClass:function(){this._super(),this.options.activeClass&&this.element.addClass(this.options.activeClass)},_removeActiveClass:function(){this._super(),this.options.activeClass&&this.element.removeClass(this.options.activeClass)},_addHoverClass:function(){this._super(),this.options.hoverClass&&this.element.addClass(this.options.hoverClass)},_removeHoverClass:function(){this._super(),this.options.hoverClass&&this.element.removeClass(this.options.hoverClass)}}),t.ui.droppable,t.widget("ui.progressbar",{version:"1.12.1",options:{classes:{"ui-progressbar":"ui-corner-all","ui-progressbar-value":"ui-corner-left","ui-progressbar-complete":"ui-corner-right"},max:100,value:0,change:null,complete:null},min:0,_create:function(){this.oldValue=this.options.value=this._constrainedValue(),this.element.attr({role:"progressbar","aria-valuemin":this.min}),this._addClass("ui-progressbar","ui-widget ui-widget-content"),this.valueDiv=t("<div>").appendTo(this.element),this._addClass(this.valueDiv,"ui-progressbar-value","ui-widget-header"),this._refreshValue()},_destroy:function(){this.element.removeAttr("role aria-valuemin aria-valuemax aria-valuenow"),this.valueDiv.remove()},value:function(t){return void 0===t?this.options.value:(this.options.value=this._constrainedValue(t),this._refreshValue(),void 0)},_constrainedValue:function(t){return void 0===t&&(t=this.options.value),this.indeterminate=t===!1,"number"!=typeof t&&(t=0),this.indeterminate?!1:Math.min(this.options.max,Math.max(this.min,t))},_setOptions:function(t){var e=t.value;delete t.value,this._super(t),this.options.value=this._constrainedValue(e),this._refreshValue()},_setOption:function(t,e){"max"===t&&(e=Math.max(this.min,e)),this._super(t,e)},_setOptionDisabled:function(t){this._super(t),this.element.attr("aria-disabled",t),this._toggleClass(null,"ui-state-disabled",!!t)},_percentage:function(){return this.indeterminate?100:100*(this.options.value-this.min)/(this.options.max-this.min)},_refreshValue:function(){var e=this.options.value,i=this._percentage();this.valueDiv.toggle(this.indeterminate||e>this.min).width(i.toFixed(0)+"%"),this._toggleClass(this.valueDiv,"ui-progressbar-complete",null,e===this.options.max)._toggleClass("ui-progressbar-indeterminate",null,this.indeterminate),this.indeterminate?(this.element.removeAttr("aria-valuenow"),this.overlayDiv||(this.overlayDiv=t("<div>").appendTo(this.valueDiv),this._addClass(this.overlayDiv,"ui-progressbar-overlay"))):(this.element.attr({"aria-valuemax":this.options.max,"aria-valuenow":e}),this.overlayDiv&&(this.overlayDiv.remove(),this.overlayDiv=null)),this.oldValue!==e&&(this.oldValue=e,this._trigger("change")),e===this.options.max&&this._trigger("complete")}}),t.widget("ui.selectable",t.ui.mouse,{version:"1.12.1",options:{appendTo:"body",autoRefresh:!0,distance:0,filter:"*",tolerance:"touch",selected:null,selecting:null,start:null,stop:null,unselected:null,unselecting:null},_create:function(){var e=this;this._addClass("ui-selectable"),this.dragged=!1,this.refresh=function(){e.elementPos=t(e.element[0]).offset(),e.selectees=t(e.options.filter,e.element[0]),e._addClass(e.selectees,"ui-selectee"),e.selectees.each(function(){var i=t(this),s=i.offset(),n={left:s.left-e.elementPos.left,top:s.top-e.elementPos.top};t.data(this,"selectable-item",{element:this,$element:i,left:n.left,top:n.top,right:n.left+i.outerWidth(),bottom:n.top+i.outerHeight(),startselected:!1,selected:i.hasClass("ui-selected"),selecting:i.hasClass("ui-selecting"),unselecting:i.hasClass("ui-unselecting")})})},this.refresh(),this._mouseInit(),this.helper=t("<div>"),this._addClass(this.helper,"ui-selectable-helper")},_destroy:function(){this.selectees.removeData("selectable-item"),this._mouseDestroy()},_mouseStart:function(e){var i=this,s=this.options;this.opos=[e.pageX,e.pageY],this.elementPos=t(this.element[0]).offset(),this.options.disabled||(this.selectees=t(s.filter,this.element[0]),this._trigger("start",e),t(s.appendTo).append(this.helper),this.helper.css({left:e.pageX,top:e.pageY,width:0,height:0}),s.autoRefresh&&this.refresh(),this.selectees.filter(".ui-selected").each(function(){var s=t.data(this,"selectable-item");s.startselected=!0,e.metaKey||e.ctrlKey||(i._removeClass(s.$element,"ui-selected"),s.selected=!1,i._addClass(s.$element,"ui-unselecting"),s.unselecting=!0,i._trigger("unselecting",e,{unselecting:s.element}))}),t(e.target).parents().addBack().each(function(){var s,n=t.data(this,"selectable-item");return n?(s=!e.metaKey&&!e.ctrlKey||!n.$element.hasClass("ui-selected"),i._removeClass(n.$element,s?"ui-unselecting":"ui-selected")._addClass(n.$element,s?"ui-selecting":"ui-unselecting"),n.unselecting=!s,n.selecting=s,n.selected=s,s?i._trigger("selecting",e,{selecting:n.element}):i._trigger("unselecting",e,{unselecting:n.element}),!1):void 0}))},_mouseDrag:function(e){if(this.dragged=!0,!this.options.disabled){var i,s=this,n=this.options,o=this.opos[0],a=this.opos[1],r=e.pageX,h=e.pageY;return o>r&&(i=r,r=o,o=i),a>h&&(i=h,h=a,a=i),this.helper.css({left:o,top:a,width:r-o,height:h-a}),this.selectees.each(function(){var i=t.data(this,"selectable-item"),l=!1,c={};i&&i.element!==s.element[0]&&(c.left=i.left+s.elementPos.left,c.right=i.right+s.elementPos.left,c.top=i.top+s.elementPos.top,c.bottom=i.bottom+s.elementPos.top,"touch"===n.tolerance?l=!(c.left>r||o>c.right||c.top>h||a>c.bottom):"fit"===n.tolerance&&(l=c.left>o&&r>c.right&&c.top>a&&h>c.bottom),l?(i.selected&&(s._removeClass(i.$element,"ui-selected"),i.selected=!1),i.unselecting&&(s._removeClass(i.$element,"ui-unselecting"),i.unselecting=!1),i.selecting||(s._addClass(i.$element,"ui-selecting"),i.selecting=!0,s._trigger("selecting",e,{selecting:i.element}))):(i.selecting&&((e.metaKey||e.ctrlKey)&&i.startselected?(s._removeClass(i.$element,"ui-selecting"),i.selecting=!1,s._addClass(i.$element,"ui-selected"),i.selected=!0):(s._removeClass(i.$element,"ui-selecting"),i.selecting=!1,i.startselected&&(s._addClass(i.$element,"ui-unselecting"),i.unselecting=!0),s._trigger("unselecting",e,{unselecting:i.element}))),i.selected&&(e.metaKey||e.ctrlKey||i.startselected||(s._removeClass(i.$element,"ui-selected"),i.selected=!1,s._addClass(i.$element,"ui-unselecting"),i.unselecting=!0,s._trigger("unselecting",e,{unselecting:i.element})))))}),!1}},_mouseStop:function(e){var i=this;return this.dragged=!1,t(".ui-unselecting",this.element[0]).each(function(){var s=t.data(this,"selectable-item");i._removeClass(s.$element,"ui-unselecting"),s.unselecting=!1,s.startselected=!1,i._trigger("unselected",e,{unselected:s.element})}),t(".ui-selecting",this.element[0]).each(function(){var s=t.data(this,"selectable-item");i._removeClass(s.$element,"ui-selecting")._addClass(s.$element,"ui-selected"),s.selecting=!1,s.selected=!0,s.startselected=!0,i._trigger("selected",e,{selected:s.element})}),this._trigger("stop",e),this.helper.remove(),!1}}),t.widget("ui.selectmenu",[t.ui.formResetMixin,{version:"1.12.1",defaultElement:"<select>",options:{appendTo:null,classes:{"ui-selectmenu-button-open":"ui-corner-top","ui-selectmenu-button-closed":"ui-corner-all"},disabled:null,icons:{button:"ui-icon-triangle-1-s"},position:{my:"left top",at:"left bottom",collision:"none"},width:!1,change:null,close:null,focus:null,open:null,select:null},_create:function(){var e=this.element.uniqueId().attr("id");this.ids={element:e,button:e+"-button",menu:e+"-menu"},this._drawButton(),this._drawMenu(),this._bindFormResetHandler(),this._rendered=!1,this.menuItems=t()},_drawButton:function(){var e,i=this,s=this._parseOption(this.element.find("option:selected"),this.element[0].selectedIndex);this.labels=this.element.labels().attr("for",this.ids.button),this._on(this.labels,{click:function(t){this.button.focus(),t.preventDefault()}}),this.element.hide(),this.button=t("<span>",{tabindex:this.options.disabled?-1:0,id:this.ids.button,role:"combobox","aria-expanded":"false","aria-autocomplete":"list","aria-owns":this.ids.menu,"aria-haspopup":"true",title:this.element.attr("title")}).insertAfter(this.element),this._addClass(this.button,"ui-selectmenu-button ui-selectmenu-button-closed","ui-button ui-widget"),e=t("<span>").appendTo(this.button),this._addClass(e,"ui-selectmenu-icon","ui-icon "+this.options.icons.button),this.buttonItem=this._renderButtonItem(s).appendTo(this.button),this.options.width!==!1&&this._resizeButton(),this._on(this.button,this._buttonEvents),this.button.one("focusin",function(){i._rendered||i._refreshMenu()})},_drawMenu:function(){var e=this;this.menu=t("<ul>",{"aria-hidden":"true","aria-labelledby":this.ids.button,id:this.ids.menu}),this.menuWrap=t("<div>").append(this.menu),this._addClass(this.menuWrap,"ui-selectmenu-menu","ui-front"),this.menuWrap.appendTo(this._appendTo()),this.menuInstance=this.menu.menu({classes:{"ui-menu":"ui-corner-bottom"},role:"listbox",select:function(t,i){t.preventDefault(),e._setSelection(),e._select(i.item.data("ui-selectmenu-item"),t)},focus:function(t,i){var s=i.item.data("ui-selectmenu-item");null!=e.focusIndex&&s.index!==e.focusIndex&&(e._trigger("focus",t,{item:s}),e.isOpen||e._select(s,t)),e.focusIndex=s.index,e.button.attr("aria-activedescendant",e.menuItems.eq(s.index).attr("id"))}}).menu("instance"),this.menuInstance._off(this.menu,"mouseleave"),this.menuInstance._closeOnDocumentClick=function(){return!1},this.menuInstance._isDivider=function(){return!1}},refresh:function(){this._refreshMenu(),this.buttonItem.replaceWith(this.buttonItem=this._renderButtonItem(this._getSelectedItem().data("ui-selectmenu-item")||{})),null===this.options.width&&this._resizeButton()},_refreshMenu:function(){var t,e=this.element.find("option");this.menu.empty(),this._parseOptions(e),this._renderMenu(this.menu,this.items),this.menuInstance.refresh(),this.menuItems=this.menu.find("li").not(".ui-selectmenu-optgroup").find(".ui-menu-item-wrapper"),this._rendered=!0,e.length&&(t=this._getSelectedItem(),this.menuInstance.focus(null,t),this._setAria(t.data("ui-selectmenu-item")),this._setOption("disabled",this.element.prop("disabled")))},open:function(t){this.options.disabled||(this._rendered?(this._removeClass(this.menu.find(".ui-state-active"),null,"ui-state-active"),this.menuInstance.focus(null,this._getSelectedItem())):this._refreshMenu(),this.menuItems.length&&(this.isOpen=!0,this._toggleAttr(),this._resizeMenu(),this._position(),this._on(this.document,this._documentClick),this._trigger("open",t)))},_position:function(){this.menuWrap.position(t.extend({of:this.button},this.options.position))},close:function(t){this.isOpen&&(this.isOpen=!1,this._toggleAttr(),this.range=null,this._off(this.document),this._trigger("close",t))},widget:function(){return this.button},menuWidget:function(){return this.menu},_renderButtonItem:function(e){var i=t("<span>");return this._setText(i,e.label),this._addClass(i,"ui-selectmenu-text"),i},_renderMenu:function(e,i){var s=this,n="";t.each(i,function(i,o){var a;o.optgroup!==n&&(a=t("<li>",{text:o.optgroup}),s._addClass(a,"ui-selectmenu-optgroup","ui-menu-divider"+(o.element.parent("optgroup").prop("disabled")?" ui-state-disabled":"")),a.appendTo(e),n=o.optgroup),s._renderItemData(e,o)})},_renderItemData:function(t,e){return this._renderItem(t,e).data("ui-selectmenu-item",e)},_renderItem:function(e,i){var s=t("<li>"),n=t("<div>",{title:i.element.attr("title")});return i.disabled&&this._addClass(s,null,"ui-state-disabled"),this._setText(n,i.label),s.append(n).appendTo(e)},_setText:function(t,e){e?t.text(e):t.html("&#160;")},_move:function(t,e){var i,s,n=".ui-menu-item";this.isOpen?i=this.menuItems.eq(this.focusIndex).parent("li"):(i=this.menuItems.eq(this.element[0].selectedIndex).parent("li"),n+=":not(.ui-state-disabled)"),s="first"===t||"last"===t?i["first"===t?"prevAll":"nextAll"](n).eq(-1):i[t+"All"](n).eq(0),s.length&&this.menuInstance.focus(e,s)},_getSelectedItem:function(){return this.menuItems.eq(this.element[0].selectedIndex).parent("li")},_toggle:function(t){this[this.isOpen?"close":"open"](t)},_setSelection:function(){var t;this.range&&(window.getSelection?(t=window.getSelection(),t.removeAllRanges(),t.addRange(this.range)):this.range.select(),this.button.focus())},_documentClick:{mousedown:function(e){this.isOpen&&(t(e.target).closest(".ui-selectmenu-menu, #"+t.ui.escapeSelector(this.ids.button)).length||this.close(e))}},_buttonEvents:{mousedown:function(){var t;window.getSelection?(t=window.getSelection(),t.rangeCount&&(this.range=t.getRangeAt(0))):this.range=document.selection.createRange()},click:function(t){this._setSelection(),this._toggle(t)},keydown:function(e){var i=!0;switch(e.keyCode){case t.ui.keyCode.TAB:case t.ui.keyCode.ESCAPE:this.close(e),i=!1;break;case t.ui.keyCode.ENTER:this.isOpen&&this._selectFocusedItem(e);break;case t.ui.keyCode.UP:e.altKey?this._toggle(e):this._move("prev",e);break;case t.ui.keyCode.DOWN:e.altKey?this._toggle(e):this._move("next",e);break;case t.ui.keyCode.SPACE:this.isOpen?this._selectFocusedItem(e):this._toggle(e);break;case t.ui.keyCode.LEFT:this._move("prev",e);break;case t.ui.keyCode.RIGHT:this._move("next",e);break;case t.ui.keyCode.HOME:case t.ui.keyCode.PAGE_UP:this._move("first",e);break;case t.ui.keyCode.END:case t.ui.keyCode.PAGE_DOWN:this._move("last",e);break;default:this.menu.trigger(e),i=!1}i&&e.preventDefault()}},_selectFocusedItem:function(t){var e=this.menuItems.eq(this.focusIndex).parent("li");e.hasClass("ui-state-disabled")||this._select(e.data("ui-selectmenu-item"),t)},_select:function(t,e){var i=this.element[0].selectedIndex;this.element[0].selectedIndex=t.index,this.buttonItem.replaceWith(this.buttonItem=this._renderButtonItem(t)),this._setAria(t),this._trigger("select",e,{item:t}),t.index!==i&&this._trigger("change",e,{item:t}),this.close(e)},_setAria:function(t){var e=this.menuItems.eq(t.index).attr("id");this.button.attr({"aria-labelledby":e,"aria-activedescendant":e}),this.menu.attr("aria-activedescendant",e)},_setOption:function(t,e){if("icons"===t){var i=this.button.find("span.ui-icon");this._removeClass(i,null,this.options.icons.button)._addClass(i,null,e.button)}this._super(t,e),"appendTo"===t&&this.menuWrap.appendTo(this._appendTo()),"width"===t&&this._resizeButton()},_setOptionDisabled:function(t){this._super(t),this.menuInstance.option("disabled",t),this.button.attr("aria-disabled",t),this._toggleClass(this.button,null,"ui-state-disabled",t),this.element.prop("disabled",t),t?(this.button.attr("tabindex",-1),this.close()):this.button.attr("tabindex",0)},_appendTo:function(){var e=this.options.appendTo;return e&&(e=e.jquery||e.nodeType?t(e):this.document.find(e).eq(0)),e&&e[0]||(e=this.element.closest(".ui-front, dialog")),e.length||(e=this.document[0].body),e},_toggleAttr:function(){this.button.attr("aria-expanded",this.isOpen),this._removeClass(this.button,"ui-selectmenu-button-"+(this.isOpen?"closed":"open"))._addClass(this.button,"ui-selectmenu-button-"+(this.isOpen?"open":"closed"))._toggleClass(this.menuWrap,"ui-selectmenu-open",null,this.isOpen),this.menu.attr("aria-hidden",!this.isOpen)},_resizeButton:function(){var t=this.options.width;return t===!1?(this.button.css("width",""),void 0):(null===t&&(t=this.element.show().outerWidth(),this.element.hide()),this.button.outerWidth(t),void 0)},_resizeMenu:function(){this.menu.outerWidth(Math.max(this.button.outerWidth(),this.menu.width("").outerWidth()+1))},_getCreateOptions:function(){var t=this._super();return t.disabled=this.element.prop("disabled"),t},_parseOptions:function(e){var i=this,s=[];e.each(function(e,n){s.push(i._parseOption(t(n),e))}),this.items=s},_parseOption:function(t,e){var i=t.parent("optgroup");return{element:t,index:e,value:t.val(),label:t.text(),optgroup:i.attr("label")||"",disabled:i.prop("disabled")||t.prop("disabled")}},_destroy:function(){this._unbindFormResetHandler(),this.menuWrap.remove(),this.button.remove(),this.element.show(),this.element.removeUniqueId(),this.labels.attr("for",this.ids.element)}}]),t.widget("ui.slider",t.ui.mouse,{version:"1.12.1",widgetEventPrefix:"slide",options:{animate:!1,classes:{"ui-slider":"ui-corner-all","ui-slider-handle":"ui-corner-all","ui-slider-range":"ui-corner-all ui-widget-header"},distance:0,max:100,min:0,orientation:"horizontal",range:!1,step:1,value:0,values:null,change:null,slide:null,start:null,stop:null},numPages:5,_create:function(){this._keySliding=!1,this._mouseSliding=!1,this._animateOff=!0,this._handleIndex=null,this._detectOrientation(),this._mouseInit(),this._calculateNewMax(),this._addClass("ui-slider ui-slider-"+this.orientation,"ui-widget ui-widget-content"),this._refresh(),this._animateOff=!1 +},_refresh:function(){this._createRange(),this._createHandles(),this._setupEvents(),this._refreshValue()},_createHandles:function(){var e,i,s=this.options,n=this.element.find(".ui-slider-handle"),o="<span tabindex='0'></span>",a=[];for(i=s.values&&s.values.length||1,n.length>i&&(n.slice(i).remove(),n=n.slice(0,i)),e=n.length;i>e;e++)a.push(o);this.handles=n.add(t(a.join("")).appendTo(this.element)),this._addClass(this.handles,"ui-slider-handle","ui-state-default"),this.handle=this.handles.eq(0),this.handles.each(function(e){t(this).data("ui-slider-handle-index",e).attr("tabIndex",0)})},_createRange:function(){var e=this.options;e.range?(e.range===!0&&(e.values?e.values.length&&2!==e.values.length?e.values=[e.values[0],e.values[0]]:t.isArray(e.values)&&(e.values=e.values.slice(0)):e.values=[this._valueMin(),this._valueMin()]),this.range&&this.range.length?(this._removeClass(this.range,"ui-slider-range-min ui-slider-range-max"),this.range.css({left:"",bottom:""})):(this.range=t("<div>").appendTo(this.element),this._addClass(this.range,"ui-slider-range")),("min"===e.range||"max"===e.range)&&this._addClass(this.range,"ui-slider-range-"+e.range)):(this.range&&this.range.remove(),this.range=null)},_setupEvents:function(){this._off(this.handles),this._on(this.handles,this._handleEvents),this._hoverable(this.handles),this._focusable(this.handles)},_destroy:function(){this.handles.remove(),this.range&&this.range.remove(),this._mouseDestroy()},_mouseCapture:function(e){var i,s,n,o,a,r,h,l,c=this,u=this.options;return u.disabled?!1:(this.elementSize={width:this.element.outerWidth(),height:this.element.outerHeight()},this.elementOffset=this.element.offset(),i={x:e.pageX,y:e.pageY},s=this._normValueFromMouse(i),n=this._valueMax()-this._valueMin()+1,this.handles.each(function(e){var i=Math.abs(s-c.values(e));(n>i||n===i&&(e===c._lastChangedValue||c.values(e)===u.min))&&(n=i,o=t(this),a=e)}),r=this._start(e,a),r===!1?!1:(this._mouseSliding=!0,this._handleIndex=a,this._addClass(o,null,"ui-state-active"),o.trigger("focus"),h=o.offset(),l=!t(e.target).parents().addBack().is(".ui-slider-handle"),this._clickOffset=l?{left:0,top:0}:{left:e.pageX-h.left-o.width()/2,top:e.pageY-h.top-o.height()/2-(parseInt(o.css("borderTopWidth"),10)||0)-(parseInt(o.css("borderBottomWidth"),10)||0)+(parseInt(o.css("marginTop"),10)||0)},this.handles.hasClass("ui-state-hover")||this._slide(e,a,s),this._animateOff=!0,!0))},_mouseStart:function(){return!0},_mouseDrag:function(t){var e={x:t.pageX,y:t.pageY},i=this._normValueFromMouse(e);return this._slide(t,this._handleIndex,i),!1},_mouseStop:function(t){return this._removeClass(this.handles,null,"ui-state-active"),this._mouseSliding=!1,this._stop(t,this._handleIndex),this._change(t,this._handleIndex),this._handleIndex=null,this._clickOffset=null,this._animateOff=!1,!1},_detectOrientation:function(){this.orientation="vertical"===this.options.orientation?"vertical":"horizontal"},_normValueFromMouse:function(t){var e,i,s,n,o;return"horizontal"===this.orientation?(e=this.elementSize.width,i=t.x-this.elementOffset.left-(this._clickOffset?this._clickOffset.left:0)):(e=this.elementSize.height,i=t.y-this.elementOffset.top-(this._clickOffset?this._clickOffset.top:0)),s=i/e,s>1&&(s=1),0>s&&(s=0),"vertical"===this.orientation&&(s=1-s),n=this._valueMax()-this._valueMin(),o=this._valueMin()+s*n,this._trimAlignValue(o)},_uiHash:function(t,e,i){var s={handle:this.handles[t],handleIndex:t,value:void 0!==e?e:this.value()};return this._hasMultipleValues()&&(s.value=void 0!==e?e:this.values(t),s.values=i||this.values()),s},_hasMultipleValues:function(){return this.options.values&&this.options.values.length},_start:function(t,e){return this._trigger("start",t,this._uiHash(e))},_slide:function(t,e,i){var s,n,o=this.value(),a=this.values();this._hasMultipleValues()&&(n=this.values(e?0:1),o=this.values(e),2===this.options.values.length&&this.options.range===!0&&(i=0===e?Math.min(n,i):Math.max(n,i)),a[e]=i),i!==o&&(s=this._trigger("slide",t,this._uiHash(e,i,a)),s!==!1&&(this._hasMultipleValues()?this.values(e,i):this.value(i)))},_stop:function(t,e){this._trigger("stop",t,this._uiHash(e))},_change:function(t,e){this._keySliding||this._mouseSliding||(this._lastChangedValue=e,this._trigger("change",t,this._uiHash(e)))},value:function(t){return arguments.length?(this.options.value=this._trimAlignValue(t),this._refreshValue(),this._change(null,0),void 0):this._value()},values:function(e,i){var s,n,o;if(arguments.length>1)return this.options.values[e]=this._trimAlignValue(i),this._refreshValue(),this._change(null,e),void 0;if(!arguments.length)return this._values();if(!t.isArray(arguments[0]))return this._hasMultipleValues()?this._values(e):this.value();for(s=this.options.values,n=arguments[0],o=0;s.length>o;o+=1)s[o]=this._trimAlignValue(n[o]),this._change(null,o);this._refreshValue()},_setOption:function(e,i){var s,n=0;switch("range"===e&&this.options.range===!0&&("min"===i?(this.options.value=this._values(0),this.options.values=null):"max"===i&&(this.options.value=this._values(this.options.values.length-1),this.options.values=null)),t.isArray(this.options.values)&&(n=this.options.values.length),this._super(e,i),e){case"orientation":this._detectOrientation(),this._removeClass("ui-slider-horizontal ui-slider-vertical")._addClass("ui-slider-"+this.orientation),this._refreshValue(),this.options.range&&this._refreshRange(i),this.handles.css("horizontal"===i?"bottom":"left","");break;case"value":this._animateOff=!0,this._refreshValue(),this._change(null,0),this._animateOff=!1;break;case"values":for(this._animateOff=!0,this._refreshValue(),s=n-1;s>=0;s--)this._change(null,s);this._animateOff=!1;break;case"step":case"min":case"max":this._animateOff=!0,this._calculateNewMax(),this._refreshValue(),this._animateOff=!1;break;case"range":this._animateOff=!0,this._refresh(),this._animateOff=!1}},_setOptionDisabled:function(t){this._super(t),this._toggleClass(null,"ui-state-disabled",!!t)},_value:function(){var t=this.options.value;return t=this._trimAlignValue(t)},_values:function(t){var e,i,s;if(arguments.length)return e=this.options.values[t],e=this._trimAlignValue(e);if(this._hasMultipleValues()){for(i=this.options.values.slice(),s=0;i.length>s;s+=1)i[s]=this._trimAlignValue(i[s]);return i}return[]},_trimAlignValue:function(t){if(this._valueMin()>=t)return this._valueMin();if(t>=this._valueMax())return this._valueMax();var e=this.options.step>0?this.options.step:1,i=(t-this._valueMin())%e,s=t-i;return 2*Math.abs(i)>=e&&(s+=i>0?e:-e),parseFloat(s.toFixed(5))},_calculateNewMax:function(){var t=this.options.max,e=this._valueMin(),i=this.options.step,s=Math.round((t-e)/i)*i;t=s+e,t>this.options.max&&(t-=i),this.max=parseFloat(t.toFixed(this._precision()))},_precision:function(){var t=this._precisionOf(this.options.step);return null!==this.options.min&&(t=Math.max(t,this._precisionOf(this.options.min))),t},_precisionOf:function(t){var e=""+t,i=e.indexOf(".");return-1===i?0:e.length-i-1},_valueMin:function(){return this.options.min},_valueMax:function(){return this.max},_refreshRange:function(t){"vertical"===t&&this.range.css({width:"",left:""}),"horizontal"===t&&this.range.css({height:"",bottom:""})},_refreshValue:function(){var e,i,s,n,o,a=this.options.range,r=this.options,h=this,l=this._animateOff?!1:r.animate,c={};this._hasMultipleValues()?this.handles.each(function(s){i=100*((h.values(s)-h._valueMin())/(h._valueMax()-h._valueMin())),c["horizontal"===h.orientation?"left":"bottom"]=i+"%",t(this).stop(1,1)[l?"animate":"css"](c,r.animate),h.options.range===!0&&("horizontal"===h.orientation?(0===s&&h.range.stop(1,1)[l?"animate":"css"]({left:i+"%"},r.animate),1===s&&h.range[l?"animate":"css"]({width:i-e+"%"},{queue:!1,duration:r.animate})):(0===s&&h.range.stop(1,1)[l?"animate":"css"]({bottom:i+"%"},r.animate),1===s&&h.range[l?"animate":"css"]({height:i-e+"%"},{queue:!1,duration:r.animate}))),e=i}):(s=this.value(),n=this._valueMin(),o=this._valueMax(),i=o!==n?100*((s-n)/(o-n)):0,c["horizontal"===this.orientation?"left":"bottom"]=i+"%",this.handle.stop(1,1)[l?"animate":"css"](c,r.animate),"min"===a&&"horizontal"===this.orientation&&this.range.stop(1,1)[l?"animate":"css"]({width:i+"%"},r.animate),"max"===a&&"horizontal"===this.orientation&&this.range.stop(1,1)[l?"animate":"css"]({width:100-i+"%"},r.animate),"min"===a&&"vertical"===this.orientation&&this.range.stop(1,1)[l?"animate":"css"]({height:i+"%"},r.animate),"max"===a&&"vertical"===this.orientation&&this.range.stop(1,1)[l?"animate":"css"]({height:100-i+"%"},r.animate))},_handleEvents:{keydown:function(e){var i,s,n,o,a=t(e.target).data("ui-slider-handle-index");switch(e.keyCode){case t.ui.keyCode.HOME:case t.ui.keyCode.END:case t.ui.keyCode.PAGE_UP:case t.ui.keyCode.PAGE_DOWN:case t.ui.keyCode.UP:case t.ui.keyCode.RIGHT:case t.ui.keyCode.DOWN:case t.ui.keyCode.LEFT:if(e.preventDefault(),!this._keySliding&&(this._keySliding=!0,this._addClass(t(e.target),null,"ui-state-active"),i=this._start(e,a),i===!1))return}switch(o=this.options.step,s=n=this._hasMultipleValues()?this.values(a):this.value(),e.keyCode){case t.ui.keyCode.HOME:n=this._valueMin();break;case t.ui.keyCode.END:n=this._valueMax();break;case t.ui.keyCode.PAGE_UP:n=this._trimAlignValue(s+(this._valueMax()-this._valueMin())/this.numPages);break;case t.ui.keyCode.PAGE_DOWN:n=this._trimAlignValue(s-(this._valueMax()-this._valueMin())/this.numPages);break;case t.ui.keyCode.UP:case t.ui.keyCode.RIGHT:if(s===this._valueMax())return;n=this._trimAlignValue(s+o);break;case t.ui.keyCode.DOWN:case t.ui.keyCode.LEFT:if(s===this._valueMin())return;n=this._trimAlignValue(s-o)}this._slide(e,a,n)},keyup:function(e){var i=t(e.target).data("ui-slider-handle-index");this._keySliding&&(this._keySliding=!1,this._stop(e,i),this._change(e,i),this._removeClass(t(e.target),null,"ui-state-active"))}}}),t.widget("ui.sortable",t.ui.mouse,{version:"1.12.1",widgetEventPrefix:"sort",ready:!1,options:{appendTo:"parent",axis:!1,connectWith:!1,containment:!1,cursor:"auto",cursorAt:!1,dropOnEmpty:!0,forcePlaceholderSize:!1,forceHelperSize:!1,grid:!1,handle:!1,helper:"original",items:"> *",opacity:!1,placeholder:!1,revert:!1,scroll:!0,scrollSensitivity:20,scrollSpeed:20,scope:"default",tolerance:"intersect",zIndex:1e3,activate:null,beforeStop:null,change:null,deactivate:null,out:null,over:null,receive:null,remove:null,sort:null,start:null,stop:null,update:null},_isOverAxis:function(t,e,i){return t>=e&&e+i>t},_isFloating:function(t){return/left|right/.test(t.css("float"))||/inline|table-cell/.test(t.css("display"))},_create:function(){this.containerCache={},this._addClass("ui-sortable"),this.refresh(),this.offset=this.element.offset(),this._mouseInit(),this._setHandleClassName(),this.ready=!0},_setOption:function(t,e){this._super(t,e),"handle"===t&&this._setHandleClassName()},_setHandleClassName:function(){var e=this;this._removeClass(this.element.find(".ui-sortable-handle"),"ui-sortable-handle"),t.each(this.items,function(){e._addClass(this.instance.options.handle?this.item.find(this.instance.options.handle):this.item,"ui-sortable-handle")})},_destroy:function(){this._mouseDestroy();for(var t=this.items.length-1;t>=0;t--)this.items[t].item.removeData(this.widgetName+"-item");return this},_mouseCapture:function(e,i){var s=null,n=!1,o=this;return this.reverting?!1:this.options.disabled||"static"===this.options.type?!1:(this._refreshItems(e),t(e.target).parents().each(function(){return t.data(this,o.widgetName+"-item")===o?(s=t(this),!1):void 0}),t.data(e.target,o.widgetName+"-item")===o&&(s=t(e.target)),s?!this.options.handle||i||(t(this.options.handle,s).find("*").addBack().each(function(){this===e.target&&(n=!0)}),n)?(this.currentItem=s,this._removeCurrentsFromItems(),!0):!1:!1)},_mouseStart:function(e,i,s){var n,o,a=this.options;if(this.currentContainer=this,this.refreshPositions(),this.helper=this._createHelper(e),this._cacheHelperProportions(),this._cacheMargins(),this.scrollParent=this.helper.scrollParent(),this.offset=this.currentItem.offset(),this.offset={top:this.offset.top-this.margins.top,left:this.offset.left-this.margins.left},t.extend(this.offset,{click:{left:e.pageX-this.offset.left,top:e.pageY-this.offset.top},parent:this._getParentOffset(),relative:this._getRelativeOffset()}),this.helper.css("position","absolute"),this.cssPosition=this.helper.css("position"),this.originalPosition=this._generatePosition(e),this.originalPageX=e.pageX,this.originalPageY=e.pageY,a.cursorAt&&this._adjustOffsetFromHelper(a.cursorAt),this.domPosition={prev:this.currentItem.prev()[0],parent:this.currentItem.parent()[0]},this.helper[0]!==this.currentItem[0]&&this.currentItem.hide(),this._createPlaceholder(),a.containment&&this._setContainment(),a.cursor&&"auto"!==a.cursor&&(o=this.document.find("body"),this.storedCursor=o.css("cursor"),o.css("cursor",a.cursor),this.storedStylesheet=t("<style>*{ cursor: "+a.cursor+" !important; }</style>").appendTo(o)),a.opacity&&(this.helper.css("opacity")&&(this._storedOpacity=this.helper.css("opacity")),this.helper.css("opacity",a.opacity)),a.zIndex&&(this.helper.css("zIndex")&&(this._storedZIndex=this.helper.css("zIndex")),this.helper.css("zIndex",a.zIndex)),this.scrollParent[0]!==this.document[0]&&"HTML"!==this.scrollParent[0].tagName&&(this.overflowOffset=this.scrollParent.offset()),this._trigger("start",e,this._uiHash()),this._preserveHelperProportions||this._cacheHelperProportions(),!s)for(n=this.containers.length-1;n>=0;n--)this.containers[n]._trigger("activate",e,this._uiHash(this));return t.ui.ddmanager&&(t.ui.ddmanager.current=this),t.ui.ddmanager&&!a.dropBehaviour&&t.ui.ddmanager.prepareOffsets(this,e),this.dragging=!0,this._addClass(this.helper,"ui-sortable-helper"),this._mouseDrag(e),!0},_mouseDrag:function(e){var i,s,n,o,a=this.options,r=!1;for(this.position=this._generatePosition(e),this.positionAbs=this._convertPositionTo("absolute"),this.lastPositionAbs||(this.lastPositionAbs=this.positionAbs),this.options.scroll&&(this.scrollParent[0]!==this.document[0]&&"HTML"!==this.scrollParent[0].tagName?(this.overflowOffset.top+this.scrollParent[0].offsetHeight-e.pageY<a.scrollSensitivity?this.scrollParent[0].scrollTop=r=this.scrollParent[0].scrollTop+a.scrollSpeed:e.pageY-this.overflowOffset.top<a.scrollSensitivity&&(this.scrollParent[0].scrollTop=r=this.scrollParent[0].scrollTop-a.scrollSpeed),this.overflowOffset.left+this.scrollParent[0].offsetWidth-e.pageX<a.scrollSensitivity?this.scrollParent[0].scrollLeft=r=this.scrollParent[0].scrollLeft+a.scrollSpeed:e.pageX-this.overflowOffset.left<a.scrollSensitivity&&(this.scrollParent[0].scrollLeft=r=this.scrollParent[0].scrollLeft-a.scrollSpeed)):(e.pageY-this.document.scrollTop()<a.scrollSensitivity?r=this.document.scrollTop(this.document.scrollTop()-a.scrollSpeed):this.window.height()-(e.pageY-this.document.scrollTop())<a.scrollSensitivity&&(r=this.document.scrollTop(this.document.scrollTop()+a.scrollSpeed)),e.pageX-this.document.scrollLeft()<a.scrollSensitivity?r=this.document.scrollLeft(this.document.scrollLeft()-a.scrollSpeed):this.window.width()-(e.pageX-this.document.scrollLeft())<a.scrollSensitivity&&(r=this.document.scrollLeft(this.document.scrollLeft()+a.scrollSpeed))),r!==!1&&t.ui.ddmanager&&!a.dropBehaviour&&t.ui.ddmanager.prepareOffsets(this,e)),this.positionAbs=this._convertPositionTo("absolute"),this.options.axis&&"y"===this.options.axis||(this.helper[0].style.left=this.position.left+"px"),this.options.axis&&"x"===this.options.axis||(this.helper[0].style.top=this.position.top+"px"),i=this.items.length-1;i>=0;i--)if(s=this.items[i],n=s.item[0],o=this._intersectsWithPointer(s),o&&s.instance===this.currentContainer&&n!==this.currentItem[0]&&this.placeholder[1===o?"next":"prev"]()[0]!==n&&!t.contains(this.placeholder[0],n)&&("semi-dynamic"===this.options.type?!t.contains(this.element[0],n):!0)){if(this.direction=1===o?"down":"up","pointer"!==this.options.tolerance&&!this._intersectsWithSides(s))break;this._rearrange(e,s),this._trigger("change",e,this._uiHash());break}return this._contactContainers(e),t.ui.ddmanager&&t.ui.ddmanager.drag(this,e),this._trigger("sort",e,this._uiHash()),this.lastPositionAbs=this.positionAbs,!1},_mouseStop:function(e,i){if(e){if(t.ui.ddmanager&&!this.options.dropBehaviour&&t.ui.ddmanager.drop(this,e),this.options.revert){var s=this,n=this.placeholder.offset(),o=this.options.axis,a={};o&&"x"!==o||(a.left=n.left-this.offset.parent.left-this.margins.left+(this.offsetParent[0]===this.document[0].body?0:this.offsetParent[0].scrollLeft)),o&&"y"!==o||(a.top=n.top-this.offset.parent.top-this.margins.top+(this.offsetParent[0]===this.document[0].body?0:this.offsetParent[0].scrollTop)),this.reverting=!0,t(this.helper).animate(a,parseInt(this.options.revert,10)||500,function(){s._clear(e)})}else this._clear(e,i);return!1}},cancel:function(){if(this.dragging){this._mouseUp(new t.Event("mouseup",{target:null})),"original"===this.options.helper?(this.currentItem.css(this._storedCSS),this._removeClass(this.currentItem,"ui-sortable-helper")):this.currentItem.show();for(var e=this.containers.length-1;e>=0;e--)this.containers[e]._trigger("deactivate",null,this._uiHash(this)),this.containers[e].containerCache.over&&(this.containers[e]._trigger("out",null,this._uiHash(this)),this.containers[e].containerCache.over=0)}return this.placeholder&&(this.placeholder[0].parentNode&&this.placeholder[0].parentNode.removeChild(this.placeholder[0]),"original"!==this.options.helper&&this.helper&&this.helper[0].parentNode&&this.helper.remove(),t.extend(this,{helper:null,dragging:!1,reverting:!1,_noFinalSort:null}),this.domPosition.prev?t(this.domPosition.prev).after(this.currentItem):t(this.domPosition.parent).prepend(this.currentItem)),this},serialize:function(e){var i=this._getItemsAsjQuery(e&&e.connected),s=[];return e=e||{},t(i).each(function(){var i=(t(e.item||this).attr(e.attribute||"id")||"").match(e.expression||/(.+)[\-=_](.+)/);i&&s.push((e.key||i[1]+"[]")+"="+(e.key&&e.expression?i[1]:i[2]))}),!s.length&&e.key&&s.push(e.key+"="),s.join("&")},toArray:function(e){var i=this._getItemsAsjQuery(e&&e.connected),s=[];return e=e||{},i.each(function(){s.push(t(e.item||this).attr(e.attribute||"id")||"")}),s},_intersectsWith:function(t){var e=this.positionAbs.left,i=e+this.helperProportions.width,s=this.positionAbs.top,n=s+this.helperProportions.height,o=t.left,a=o+t.width,r=t.top,h=r+t.height,l=this.offset.click.top,c=this.offset.click.left,u="x"===this.options.axis||s+l>r&&h>s+l,d="y"===this.options.axis||e+c>o&&a>e+c,p=u&&d;return"pointer"===this.options.tolerance||this.options.forcePointerForContainers||"pointer"!==this.options.tolerance&&this.helperProportions[this.floating?"width":"height"]>t[this.floating?"width":"height"]?p:e+this.helperProportions.width/2>o&&a>i-this.helperProportions.width/2&&s+this.helperProportions.height/2>r&&h>n-this.helperProportions.height/2},_intersectsWithPointer:function(t){var e,i,s="x"===this.options.axis||this._isOverAxis(this.positionAbs.top+this.offset.click.top,t.top,t.height),n="y"===this.options.axis||this._isOverAxis(this.positionAbs.left+this.offset.click.left,t.left,t.width),o=s&&n;return o?(e=this._getDragVerticalDirection(),i=this._getDragHorizontalDirection(),this.floating?"right"===i||"down"===e?2:1:e&&("down"===e?2:1)):!1},_intersectsWithSides:function(t){var e=this._isOverAxis(this.positionAbs.top+this.offset.click.top,t.top+t.height/2,t.height),i=this._isOverAxis(this.positionAbs.left+this.offset.click.left,t.left+t.width/2,t.width),s=this._getDragVerticalDirection(),n=this._getDragHorizontalDirection();return this.floating&&n?"right"===n&&i||"left"===n&&!i:s&&("down"===s&&e||"up"===s&&!e)},_getDragVerticalDirection:function(){var t=this.positionAbs.top-this.lastPositionAbs.top;return 0!==t&&(t>0?"down":"up")},_getDragHorizontalDirection:function(){var t=this.positionAbs.left-this.lastPositionAbs.left;return 0!==t&&(t>0?"right":"left")},refresh:function(t){return this._refreshItems(t),this._setHandleClassName(),this.refreshPositions(),this},_connectWith:function(){var t=this.options;return t.connectWith.constructor===String?[t.connectWith]:t.connectWith},_getItemsAsjQuery:function(e){function i(){r.push(this)}var s,n,o,a,r=[],h=[],l=this._connectWith();if(l&&e)for(s=l.length-1;s>=0;s--)for(o=t(l[s],this.document[0]),n=o.length-1;n>=0;n--)a=t.data(o[n],this.widgetFullName),a&&a!==this&&!a.options.disabled&&h.push([t.isFunction(a.options.items)?a.options.items.call(a.element):t(a.options.items,a.element).not(".ui-sortable-helper").not(".ui-sortable-placeholder"),a]);for(h.push([t.isFunction(this.options.items)?this.options.items.call(this.element,null,{options:this.options,item:this.currentItem}):t(this.options.items,this.element).not(".ui-sortable-helper").not(".ui-sortable-placeholder"),this]),s=h.length-1;s>=0;s--)h[s][0].each(i);return t(r)},_removeCurrentsFromItems:function(){var e=this.currentItem.find(":data("+this.widgetName+"-item)");this.items=t.grep(this.items,function(t){for(var i=0;e.length>i;i++)if(e[i]===t.item[0])return!1;return!0})},_refreshItems:function(e){this.items=[],this.containers=[this];var i,s,n,o,a,r,h,l,c=this.items,u=[[t.isFunction(this.options.items)?this.options.items.call(this.element[0],e,{item:this.currentItem}):t(this.options.items,this.element),this]],d=this._connectWith();if(d&&this.ready)for(i=d.length-1;i>=0;i--)for(n=t(d[i],this.document[0]),s=n.length-1;s>=0;s--)o=t.data(n[s],this.widgetFullName),o&&o!==this&&!o.options.disabled&&(u.push([t.isFunction(o.options.items)?o.options.items.call(o.element[0],e,{item:this.currentItem}):t(o.options.items,o.element),o]),this.containers.push(o));for(i=u.length-1;i>=0;i--)for(a=u[i][1],r=u[i][0],s=0,l=r.length;l>s;s++)h=t(r[s]),h.data(this.widgetName+"-item",a),c.push({item:h,instance:a,width:0,height:0,left:0,top:0})},refreshPositions:function(e){this.floating=this.items.length?"x"===this.options.axis||this._isFloating(this.items[0].item):!1,this.offsetParent&&this.helper&&(this.offset.parent=this._getParentOffset());var i,s,n,o;for(i=this.items.length-1;i>=0;i--)s=this.items[i],s.instance!==this.currentContainer&&this.currentContainer&&s.item[0]!==this.currentItem[0]||(n=this.options.toleranceElement?t(this.options.toleranceElement,s.item):s.item,e||(s.width=n.outerWidth(),s.height=n.outerHeight()),o=n.offset(),s.left=o.left,s.top=o.top);if(this.options.custom&&this.options.custom.refreshContainers)this.options.custom.refreshContainers.call(this);else for(i=this.containers.length-1;i>=0;i--)o=this.containers[i].element.offset(),this.containers[i].containerCache.left=o.left,this.containers[i].containerCache.top=o.top,this.containers[i].containerCache.width=this.containers[i].element.outerWidth(),this.containers[i].containerCache.height=this.containers[i].element.outerHeight();return this},_createPlaceholder:function(e){e=e||this;var i,s=e.options;s.placeholder&&s.placeholder.constructor!==String||(i=s.placeholder,s.placeholder={element:function(){var s=e.currentItem[0].nodeName.toLowerCase(),n=t("<"+s+">",e.document[0]);return e._addClass(n,"ui-sortable-placeholder",i||e.currentItem[0].className)._removeClass(n,"ui-sortable-helper"),"tbody"===s?e._createTrPlaceholder(e.currentItem.find("tr").eq(0),t("<tr>",e.document[0]).appendTo(n)):"tr"===s?e._createTrPlaceholder(e.currentItem,n):"img"===s&&n.attr("src",e.currentItem.attr("src")),i||n.css("visibility","hidden"),n},update:function(t,n){(!i||s.forcePlaceholderSize)&&(n.height()||n.height(e.currentItem.innerHeight()-parseInt(e.currentItem.css("paddingTop")||0,10)-parseInt(e.currentItem.css("paddingBottom")||0,10)),n.width()||n.width(e.currentItem.innerWidth()-parseInt(e.currentItem.css("paddingLeft")||0,10)-parseInt(e.currentItem.css("paddingRight")||0,10)))}}),e.placeholder=t(s.placeholder.element.call(e.element,e.currentItem)),e.currentItem.after(e.placeholder),s.placeholder.update(e,e.placeholder)},_createTrPlaceholder:function(e,i){var s=this;e.children().each(function(){t("<td>&#160;</td>",s.document[0]).attr("colspan",t(this).attr("colspan")||1).appendTo(i)})},_contactContainers:function(e){var i,s,n,o,a,r,h,l,c,u,d=null,p=null;for(i=this.containers.length-1;i>=0;i--)if(!t.contains(this.currentItem[0],this.containers[i].element[0]))if(this._intersectsWith(this.containers[i].containerCache)){if(d&&t.contains(this.containers[i].element[0],d.element[0]))continue;d=this.containers[i],p=i}else this.containers[i].containerCache.over&&(this.containers[i]._trigger("out",e,this._uiHash(this)),this.containers[i].containerCache.over=0);if(d)if(1===this.containers.length)this.containers[p].containerCache.over||(this.containers[p]._trigger("over",e,this._uiHash(this)),this.containers[p].containerCache.over=1);else{for(n=1e4,o=null,c=d.floating||this._isFloating(this.currentItem),a=c?"left":"top",r=c?"width":"height",u=c?"pageX":"pageY",s=this.items.length-1;s>=0;s--)t.contains(this.containers[p].element[0],this.items[s].item[0])&&this.items[s].item[0]!==this.currentItem[0]&&(h=this.items[s].item.offset()[a],l=!1,e[u]-h>this.items[s][r]/2&&(l=!0),n>Math.abs(e[u]-h)&&(n=Math.abs(e[u]-h),o=this.items[s],this.direction=l?"up":"down"));if(!o&&!this.options.dropOnEmpty)return;if(this.currentContainer===this.containers[p])return this.currentContainer.containerCache.over||(this.containers[p]._trigger("over",e,this._uiHash()),this.currentContainer.containerCache.over=1),void 0;o?this._rearrange(e,o,null,!0):this._rearrange(e,null,this.containers[p].element,!0),this._trigger("change",e,this._uiHash()),this.containers[p]._trigger("change",e,this._uiHash(this)),this.currentContainer=this.containers[p],this.options.placeholder.update(this.currentContainer,this.placeholder),this.containers[p]._trigger("over",e,this._uiHash(this)),this.containers[p].containerCache.over=1}},_createHelper:function(e){var i=this.options,s=t.isFunction(i.helper)?t(i.helper.apply(this.element[0],[e,this.currentItem])):"clone"===i.helper?this.currentItem.clone():this.currentItem;return s.parents("body").length||t("parent"!==i.appendTo?i.appendTo:this.currentItem[0].parentNode)[0].appendChild(s[0]),s[0]===this.currentItem[0]&&(this._storedCSS={width:this.currentItem[0].style.width,height:this.currentItem[0].style.height,position:this.currentItem.css("position"),top:this.currentItem.css("top"),left:this.currentItem.css("left")}),(!s[0].style.width||i.forceHelperSize)&&s.width(this.currentItem.width()),(!s[0].style.height||i.forceHelperSize)&&s.height(this.currentItem.height()),s},_adjustOffsetFromHelper:function(e){"string"==typeof e&&(e=e.split(" ")),t.isArray(e)&&(e={left:+e[0],top:+e[1]||0}),"left"in e&&(this.offset.click.left=e.left+this.margins.left),"right"in e&&(this.offset.click.left=this.helperProportions.width-e.right+this.margins.left),"top"in e&&(this.offset.click.top=e.top+this.margins.top),"bottom"in e&&(this.offset.click.top=this.helperProportions.height-e.bottom+this.margins.top)},_getParentOffset:function(){this.offsetParent=this.helper.offsetParent();var e=this.offsetParent.offset();return"absolute"===this.cssPosition&&this.scrollParent[0]!==this.document[0]&&t.contains(this.scrollParent[0],this.offsetParent[0])&&(e.left+=this.scrollParent.scrollLeft(),e.top+=this.scrollParent.scrollTop()),(this.offsetParent[0]===this.document[0].body||this.offsetParent[0].tagName&&"html"===this.offsetParent[0].tagName.toLowerCase()&&t.ui.ie)&&(e={top:0,left:0}),{top:e.top+(parseInt(this.offsetParent.css("borderTopWidth"),10)||0),left:e.left+(parseInt(this.offsetParent.css("borderLeftWidth"),10)||0)}},_getRelativeOffset:function(){if("relative"===this.cssPosition){var t=this.currentItem.position();return{top:t.top-(parseInt(this.helper.css("top"),10)||0)+this.scrollParent.scrollTop(),left:t.left-(parseInt(this.helper.css("left"),10)||0)+this.scrollParent.scrollLeft()}}return{top:0,left:0}},_cacheMargins:function(){this.margins={left:parseInt(this.currentItem.css("marginLeft"),10)||0,top:parseInt(this.currentItem.css("marginTop"),10)||0}},_cacheHelperProportions:function(){this.helperProportions={width:this.helper.outerWidth(),height:this.helper.outerHeight()}},_setContainment:function(){var e,i,s,n=this.options;"parent"===n.containment&&(n.containment=this.helper[0].parentNode),("document"===n.containment||"window"===n.containment)&&(this.containment=[0-this.offset.relative.left-this.offset.parent.left,0-this.offset.relative.top-this.offset.parent.top,"document"===n.containment?this.document.width():this.window.width()-this.helperProportions.width-this.margins.left,("document"===n.containment?this.document.height()||document.body.parentNode.scrollHeight:this.window.height()||this.document[0].body.parentNode.scrollHeight)-this.helperProportions.height-this.margins.top]),/^(document|window|parent)$/.test(n.containment)||(e=t(n.containment)[0],i=t(n.containment).offset(),s="hidden"!==t(e).css("overflow"),this.containment=[i.left+(parseInt(t(e).css("borderLeftWidth"),10)||0)+(parseInt(t(e).css("paddingLeft"),10)||0)-this.margins.left,i.top+(parseInt(t(e).css("borderTopWidth"),10)||0)+(parseInt(t(e).css("paddingTop"),10)||0)-this.margins.top,i.left+(s?Math.max(e.scrollWidth,e.offsetWidth):e.offsetWidth)-(parseInt(t(e).css("borderLeftWidth"),10)||0)-(parseInt(t(e).css("paddingRight"),10)||0)-this.helperProportions.width-this.margins.left,i.top+(s?Math.max(e.scrollHeight,e.offsetHeight):e.offsetHeight)-(parseInt(t(e).css("borderTopWidth"),10)||0)-(parseInt(t(e).css("paddingBottom"),10)||0)-this.helperProportions.height-this.margins.top])},_convertPositionTo:function(e,i){i||(i=this.position);var s="absolute"===e?1:-1,n="absolute"!==this.cssPosition||this.scrollParent[0]!==this.document[0]&&t.contains(this.scrollParent[0],this.offsetParent[0])?this.scrollParent:this.offsetParent,o=/(html|body)/i.test(n[0].tagName);return{top:i.top+this.offset.relative.top*s+this.offset.parent.top*s-("fixed"===this.cssPosition?-this.scrollParent.scrollTop():o?0:n.scrollTop())*s,left:i.left+this.offset.relative.left*s+this.offset.parent.left*s-("fixed"===this.cssPosition?-this.scrollParent.scrollLeft():o?0:n.scrollLeft())*s}},_generatePosition:function(e){var i,s,n=this.options,o=e.pageX,a=e.pageY,r="absolute"!==this.cssPosition||this.scrollParent[0]!==this.document[0]&&t.contains(this.scrollParent[0],this.offsetParent[0])?this.scrollParent:this.offsetParent,h=/(html|body)/i.test(r[0].tagName);return"relative"!==this.cssPosition||this.scrollParent[0]!==this.document[0]&&this.scrollParent[0]!==this.offsetParent[0]||(this.offset.relative=this._getRelativeOffset()),this.originalPosition&&(this.containment&&(e.pageX-this.offset.click.left<this.containment[0]&&(o=this.containment[0]+this.offset.click.left),e.pageY-this.offset.click.top<this.containment[1]&&(a=this.containment[1]+this.offset.click.top),e.pageX-this.offset.click.left>this.containment[2]&&(o=this.containment[2]+this.offset.click.left),e.pageY-this.offset.click.top>this.containment[3]&&(a=this.containment[3]+this.offset.click.top)),n.grid&&(i=this.originalPageY+Math.round((a-this.originalPageY)/n.grid[1])*n.grid[1],a=this.containment?i-this.offset.click.top>=this.containment[1]&&i-this.offset.click.top<=this.containment[3]?i:i-this.offset.click.top>=this.containment[1]?i-n.grid[1]:i+n.grid[1]:i,s=this.originalPageX+Math.round((o-this.originalPageX)/n.grid[0])*n.grid[0],o=this.containment?s-this.offset.click.left>=this.containment[0]&&s-this.offset.click.left<=this.containment[2]?s:s-this.offset.click.left>=this.containment[0]?s-n.grid[0]:s+n.grid[0]:s)),{top:a-this.offset.click.top-this.offset.relative.top-this.offset.parent.top+("fixed"===this.cssPosition?-this.scrollParent.scrollTop():h?0:r.scrollTop()),left:o-this.offset.click.left-this.offset.relative.left-this.offset.parent.left+("fixed"===this.cssPosition?-this.scrollParent.scrollLeft():h?0:r.scrollLeft())}},_rearrange:function(t,e,i,s){i?i[0].appendChild(this.placeholder[0]):e.item[0].parentNode.insertBefore(this.placeholder[0],"down"===this.direction?e.item[0]:e.item[0].nextSibling),this.counter=this.counter?++this.counter:1;var n=this.counter; +this._delay(function(){n===this.counter&&this.refreshPositions(!s)})},_clear:function(t,e){function i(t,e,i){return function(s){i._trigger(t,s,e._uiHash(e))}}this.reverting=!1;var s,n=[];if(!this._noFinalSort&&this.currentItem.parent().length&&this.placeholder.before(this.currentItem),this._noFinalSort=null,this.helper[0]===this.currentItem[0]){for(s in this._storedCSS)("auto"===this._storedCSS[s]||"static"===this._storedCSS[s])&&(this._storedCSS[s]="");this.currentItem.css(this._storedCSS),this._removeClass(this.currentItem,"ui-sortable-helper")}else this.currentItem.show();for(this.fromOutside&&!e&&n.push(function(t){this._trigger("receive",t,this._uiHash(this.fromOutside))}),!this.fromOutside&&this.domPosition.prev===this.currentItem.prev().not(".ui-sortable-helper")[0]&&this.domPosition.parent===this.currentItem.parent()[0]||e||n.push(function(t){this._trigger("update",t,this._uiHash())}),this!==this.currentContainer&&(e||(n.push(function(t){this._trigger("remove",t,this._uiHash())}),n.push(function(t){return function(e){t._trigger("receive",e,this._uiHash(this))}}.call(this,this.currentContainer)),n.push(function(t){return function(e){t._trigger("update",e,this._uiHash(this))}}.call(this,this.currentContainer)))),s=this.containers.length-1;s>=0;s--)e||n.push(i("deactivate",this,this.containers[s])),this.containers[s].containerCache.over&&(n.push(i("out",this,this.containers[s])),this.containers[s].containerCache.over=0);if(this.storedCursor&&(this.document.find("body").css("cursor",this.storedCursor),this.storedStylesheet.remove()),this._storedOpacity&&this.helper.css("opacity",this._storedOpacity),this._storedZIndex&&this.helper.css("zIndex","auto"===this._storedZIndex?"":this._storedZIndex),this.dragging=!1,e||this._trigger("beforeStop",t,this._uiHash()),this.placeholder[0].parentNode.removeChild(this.placeholder[0]),this.cancelHelperRemoval||(this.helper[0]!==this.currentItem[0]&&this.helper.remove(),this.helper=null),!e){for(s=0;n.length>s;s++)n[s].call(this,t);this._trigger("stop",t,this._uiHash())}return this.fromOutside=!1,!this.cancelHelperRemoval},_trigger:function(){t.Widget.prototype._trigger.apply(this,arguments)===!1&&this.cancel()},_uiHash:function(e){var i=e||this;return{helper:i.helper,placeholder:i.placeholder||t([]),position:i.position,originalPosition:i.originalPosition,offset:i.positionAbs,item:i.currentItem,sender:e?e.element:null}}}),t.widget("ui.spinner",{version:"1.12.1",defaultElement:"<input>",widgetEventPrefix:"spin",options:{classes:{"ui-spinner":"ui-corner-all","ui-spinner-down":"ui-corner-br","ui-spinner-up":"ui-corner-tr"},culture:null,icons:{down:"ui-icon-triangle-1-s",up:"ui-icon-triangle-1-n"},incremental:!0,max:null,min:null,numberFormat:null,page:10,step:1,change:null,spin:null,start:null,stop:null},_create:function(){this._setOption("max",this.options.max),this._setOption("min",this.options.min),this._setOption("step",this.options.step),""!==this.value()&&this._value(this.element.val(),!0),this._draw(),this._on(this._events),this._refresh(),this._on(this.window,{beforeunload:function(){this.element.removeAttr("autocomplete")}})},_getCreateOptions:function(){var e=this._super(),i=this.element;return t.each(["min","max","step"],function(t,s){var n=i.attr(s);null!=n&&n.length&&(e[s]=n)}),e},_events:{keydown:function(t){this._start(t)&&this._keydown(t)&&t.preventDefault()},keyup:"_stop",focus:function(){this.previous=this.element.val()},blur:function(t){return this.cancelBlur?(delete this.cancelBlur,void 0):(this._stop(),this._refresh(),this.previous!==this.element.val()&&this._trigger("change",t),void 0)},mousewheel:function(t,e){if(e){if(!this.spinning&&!this._start(t))return!1;this._spin((e>0?1:-1)*this.options.step,t),clearTimeout(this.mousewheelTimer),this.mousewheelTimer=this._delay(function(){this.spinning&&this._stop(t)},100),t.preventDefault()}},"mousedown .ui-spinner-button":function(e){function i(){var e=this.element[0]===t.ui.safeActiveElement(this.document[0]);e||(this.element.trigger("focus"),this.previous=s,this._delay(function(){this.previous=s}))}var s;s=this.element[0]===t.ui.safeActiveElement(this.document[0])?this.previous:this.element.val(),e.preventDefault(),i.call(this),this.cancelBlur=!0,this._delay(function(){delete this.cancelBlur,i.call(this)}),this._start(e)!==!1&&this._repeat(null,t(e.currentTarget).hasClass("ui-spinner-up")?1:-1,e)},"mouseup .ui-spinner-button":"_stop","mouseenter .ui-spinner-button":function(e){return t(e.currentTarget).hasClass("ui-state-active")?this._start(e)===!1?!1:(this._repeat(null,t(e.currentTarget).hasClass("ui-spinner-up")?1:-1,e),void 0):void 0},"mouseleave .ui-spinner-button":"_stop"},_enhance:function(){this.uiSpinner=this.element.attr("autocomplete","off").wrap("<span>").parent().append("<a></a><a></a>")},_draw:function(){this._enhance(),this._addClass(this.uiSpinner,"ui-spinner","ui-widget ui-widget-content"),this._addClass("ui-spinner-input"),this.element.attr("role","spinbutton"),this.buttons=this.uiSpinner.children("a").attr("tabIndex",-1).attr("aria-hidden",!0).button({classes:{"ui-button":""}}),this._removeClass(this.buttons,"ui-corner-all"),this._addClass(this.buttons.first(),"ui-spinner-button ui-spinner-up"),this._addClass(this.buttons.last(),"ui-spinner-button ui-spinner-down"),this.buttons.first().button({icon:this.options.icons.up,showLabel:!1}),this.buttons.last().button({icon:this.options.icons.down,showLabel:!1}),this.buttons.height()>Math.ceil(.5*this.uiSpinner.height())&&this.uiSpinner.height()>0&&this.uiSpinner.height(this.uiSpinner.height())},_keydown:function(e){var i=this.options,s=t.ui.keyCode;switch(e.keyCode){case s.UP:return this._repeat(null,1,e),!0;case s.DOWN:return this._repeat(null,-1,e),!0;case s.PAGE_UP:return this._repeat(null,i.page,e),!0;case s.PAGE_DOWN:return this._repeat(null,-i.page,e),!0}return!1},_start:function(t){return this.spinning||this._trigger("start",t)!==!1?(this.counter||(this.counter=1),this.spinning=!0,!0):!1},_repeat:function(t,e,i){t=t||500,clearTimeout(this.timer),this.timer=this._delay(function(){this._repeat(40,e,i)},t),this._spin(e*this.options.step,i)},_spin:function(t,e){var i=this.value()||0;this.counter||(this.counter=1),i=this._adjustValue(i+t*this._increment(this.counter)),this.spinning&&this._trigger("spin",e,{value:i})===!1||(this._value(i),this.counter++)},_increment:function(e){var i=this.options.incremental;return i?t.isFunction(i)?i(e):Math.floor(e*e*e/5e4-e*e/500+17*e/200+1):1},_precision:function(){var t=this._precisionOf(this.options.step);return null!==this.options.min&&(t=Math.max(t,this._precisionOf(this.options.min))),t},_precisionOf:function(t){var e=""+t,i=e.indexOf(".");return-1===i?0:e.length-i-1},_adjustValue:function(t){var e,i,s=this.options;return e=null!==s.min?s.min:0,i=t-e,i=Math.round(i/s.step)*s.step,t=e+i,t=parseFloat(t.toFixed(this._precision())),null!==s.max&&t>s.max?s.max:null!==s.min&&s.min>t?s.min:t},_stop:function(t){this.spinning&&(clearTimeout(this.timer),clearTimeout(this.mousewheelTimer),this.counter=0,this.spinning=!1,this._trigger("stop",t))},_setOption:function(t,e){var i,s,n;return"culture"===t||"numberFormat"===t?(i=this._parse(this.element.val()),this.options[t]=e,this.element.val(this._format(i)),void 0):(("max"===t||"min"===t||"step"===t)&&"string"==typeof e&&(e=this._parse(e)),"icons"===t&&(s=this.buttons.first().find(".ui-icon"),this._removeClass(s,null,this.options.icons.up),this._addClass(s,null,e.up),n=this.buttons.last().find(".ui-icon"),this._removeClass(n,null,this.options.icons.down),this._addClass(n,null,e.down)),this._super(t,e),void 0)},_setOptionDisabled:function(t){this._super(t),this._toggleClass(this.uiSpinner,null,"ui-state-disabled",!!t),this.element.prop("disabled",!!t),this.buttons.button(t?"disable":"enable")},_setOptions:r(function(t){this._super(t)}),_parse:function(t){return"string"==typeof t&&""!==t&&(t=window.Globalize&&this.options.numberFormat?Globalize.parseFloat(t,10,this.options.culture):+t),""===t||isNaN(t)?null:t},_format:function(t){return""===t?"":window.Globalize&&this.options.numberFormat?Globalize.format(t,this.options.numberFormat,this.options.culture):t},_refresh:function(){this.element.attr({"aria-valuemin":this.options.min,"aria-valuemax":this.options.max,"aria-valuenow":this._parse(this.element.val())})},isValid:function(){var t=this.value();return null===t?!1:t===this._adjustValue(t)},_value:function(t,e){var i;""!==t&&(i=this._parse(t),null!==i&&(e||(i=this._adjustValue(i)),t=this._format(i))),this.element.val(t),this._refresh()},_destroy:function(){this.element.prop("disabled",!1).removeAttr("autocomplete role aria-valuemin aria-valuemax aria-valuenow"),this.uiSpinner.replaceWith(this.element)},stepUp:r(function(t){this._stepUp(t)}),_stepUp:function(t){this._start()&&(this._spin((t||1)*this.options.step),this._stop())},stepDown:r(function(t){this._stepDown(t)}),_stepDown:function(t){this._start()&&(this._spin((t||1)*-this.options.step),this._stop())},pageUp:r(function(t){this._stepUp((t||1)*this.options.page)}),pageDown:r(function(t){this._stepDown((t||1)*this.options.page)}),value:function(t){return arguments.length?(r(this._value).call(this,t),void 0):this._parse(this.element.val())},widget:function(){return this.uiSpinner}}),t.uiBackCompat!==!1&&t.widget("ui.spinner",t.ui.spinner,{_enhance:function(){this.uiSpinner=this.element.attr("autocomplete","off").wrap(this._uiSpinnerHtml()).parent().append(this._buttonHtml())},_uiSpinnerHtml:function(){return"<span>"},_buttonHtml:function(){return"<a></a><a></a>"}}),t.ui.spinner,t.widget("ui.tabs",{version:"1.12.1",delay:300,options:{active:null,classes:{"ui-tabs":"ui-corner-all","ui-tabs-nav":"ui-corner-all","ui-tabs-panel":"ui-corner-bottom","ui-tabs-tab":"ui-corner-top"},collapsible:!1,event:"click",heightStyle:"content",hide:null,show:null,activate:null,beforeActivate:null,beforeLoad:null,load:null},_isLocal:function(){var t=/#.*$/;return function(e){var i,s;i=e.href.replace(t,""),s=location.href.replace(t,"");try{i=decodeURIComponent(i)}catch(n){}try{s=decodeURIComponent(s)}catch(n){}return e.hash.length>1&&i===s}}(),_create:function(){var e=this,i=this.options;this.running=!1,this._addClass("ui-tabs","ui-widget ui-widget-content"),this._toggleClass("ui-tabs-collapsible",null,i.collapsible),this._processTabs(),i.active=this._initialActive(),t.isArray(i.disabled)&&(i.disabled=t.unique(i.disabled.concat(t.map(this.tabs.filter(".ui-state-disabled"),function(t){return e.tabs.index(t)}))).sort()),this.active=this.options.active!==!1&&this.anchors.length?this._findActive(i.active):t(),this._refresh(),this.active.length&&this.load(i.active)},_initialActive:function(){var e=this.options.active,i=this.options.collapsible,s=location.hash.substring(1);return null===e&&(s&&this.tabs.each(function(i,n){return t(n).attr("aria-controls")===s?(e=i,!1):void 0}),null===e&&(e=this.tabs.index(this.tabs.filter(".ui-tabs-active"))),(null===e||-1===e)&&(e=this.tabs.length?0:!1)),e!==!1&&(e=this.tabs.index(this.tabs.eq(e)),-1===e&&(e=i?!1:0)),!i&&e===!1&&this.anchors.length&&(e=0),e},_getCreateEventData:function(){return{tab:this.active,panel:this.active.length?this._getPanelForTab(this.active):t()}},_tabKeydown:function(e){var i=t(t.ui.safeActiveElement(this.document[0])).closest("li"),s=this.tabs.index(i),n=!0;if(!this._handlePageNav(e)){switch(e.keyCode){case t.ui.keyCode.RIGHT:case t.ui.keyCode.DOWN:s++;break;case t.ui.keyCode.UP:case t.ui.keyCode.LEFT:n=!1,s--;break;case t.ui.keyCode.END:s=this.anchors.length-1;break;case t.ui.keyCode.HOME:s=0;break;case t.ui.keyCode.SPACE:return e.preventDefault(),clearTimeout(this.activating),this._activate(s),void 0;case t.ui.keyCode.ENTER:return e.preventDefault(),clearTimeout(this.activating),this._activate(s===this.options.active?!1:s),void 0;default:return}e.preventDefault(),clearTimeout(this.activating),s=this._focusNextTab(s,n),e.ctrlKey||e.metaKey||(i.attr("aria-selected","false"),this.tabs.eq(s).attr("aria-selected","true"),this.activating=this._delay(function(){this.option("active",s)},this.delay))}},_panelKeydown:function(e){this._handlePageNav(e)||e.ctrlKey&&e.keyCode===t.ui.keyCode.UP&&(e.preventDefault(),this.active.trigger("focus"))},_handlePageNav:function(e){return e.altKey&&e.keyCode===t.ui.keyCode.PAGE_UP?(this._activate(this._focusNextTab(this.options.active-1,!1)),!0):e.altKey&&e.keyCode===t.ui.keyCode.PAGE_DOWN?(this._activate(this._focusNextTab(this.options.active+1,!0)),!0):void 0},_findNextTab:function(e,i){function s(){return e>n&&(e=0),0>e&&(e=n),e}for(var n=this.tabs.length-1;-1!==t.inArray(s(),this.options.disabled);)e=i?e+1:e-1;return e},_focusNextTab:function(t,e){return t=this._findNextTab(t,e),this.tabs.eq(t).trigger("focus"),t},_setOption:function(t,e){return"active"===t?(this._activate(e),void 0):(this._super(t,e),"collapsible"===t&&(this._toggleClass("ui-tabs-collapsible",null,e),e||this.options.active!==!1||this._activate(0)),"event"===t&&this._setupEvents(e),"heightStyle"===t&&this._setupHeightStyle(e),void 0)},_sanitizeSelector:function(t){return t?t.replace(/[!"$%&'()*+,.\/:;<=>?@\[\]\^`{|}~]/g,"\\$&"):""},refresh:function(){var e=this.options,i=this.tablist.children(":has(a[href])");e.disabled=t.map(i.filter(".ui-state-disabled"),function(t){return i.index(t)}),this._processTabs(),e.active!==!1&&this.anchors.length?this.active.length&&!t.contains(this.tablist[0],this.active[0])?this.tabs.length===e.disabled.length?(e.active=!1,this.active=t()):this._activate(this._findNextTab(Math.max(0,e.active-1),!1)):e.active=this.tabs.index(this.active):(e.active=!1,this.active=t()),this._refresh()},_refresh:function(){this._setOptionDisabled(this.options.disabled),this._setupEvents(this.options.event),this._setupHeightStyle(this.options.heightStyle),this.tabs.not(this.active).attr({"aria-selected":"false","aria-expanded":"false",tabIndex:-1}),this.panels.not(this._getPanelForTab(this.active)).hide().attr({"aria-hidden":"true"}),this.active.length?(this.active.attr({"aria-selected":"true","aria-expanded":"true",tabIndex:0}),this._addClass(this.active,"ui-tabs-active","ui-state-active"),this._getPanelForTab(this.active).show().attr({"aria-hidden":"false"})):this.tabs.eq(0).attr("tabIndex",0)},_processTabs:function(){var e=this,i=this.tabs,s=this.anchors,n=this.panels;this.tablist=this._getList().attr("role","tablist"),this._addClass(this.tablist,"ui-tabs-nav","ui-helper-reset ui-helper-clearfix ui-widget-header"),this.tablist.on("mousedown"+this.eventNamespace,"> li",function(e){t(this).is(".ui-state-disabled")&&e.preventDefault()}).on("focus"+this.eventNamespace,".ui-tabs-anchor",function(){t(this).closest("li").is(".ui-state-disabled")&&this.blur()}),this.tabs=this.tablist.find("> li:has(a[href])").attr({role:"tab",tabIndex:-1}),this._addClass(this.tabs,"ui-tabs-tab","ui-state-default"),this.anchors=this.tabs.map(function(){return t("a",this)[0]}).attr({role:"presentation",tabIndex:-1}),this._addClass(this.anchors,"ui-tabs-anchor"),this.panels=t(),this.anchors.each(function(i,s){var n,o,a,r=t(s).uniqueId().attr("id"),h=t(s).closest("li"),l=h.attr("aria-controls");e._isLocal(s)?(n=s.hash,a=n.substring(1),o=e.element.find(e._sanitizeSelector(n))):(a=h.attr("aria-controls")||t({}).uniqueId()[0].id,n="#"+a,o=e.element.find(n),o.length||(o=e._createPanel(a),o.insertAfter(e.panels[i-1]||e.tablist)),o.attr("aria-live","polite")),o.length&&(e.panels=e.panels.add(o)),l&&h.data("ui-tabs-aria-controls",l),h.attr({"aria-controls":a,"aria-labelledby":r}),o.attr("aria-labelledby",r)}),this.panels.attr("role","tabpanel"),this._addClass(this.panels,"ui-tabs-panel","ui-widget-content"),i&&(this._off(i.not(this.tabs)),this._off(s.not(this.anchors)),this._off(n.not(this.panels)))},_getList:function(){return this.tablist||this.element.find("ol, ul").eq(0)},_createPanel:function(e){return t("<div>").attr("id",e).data("ui-tabs-destroy",!0)},_setOptionDisabled:function(e){var i,s,n;for(t.isArray(e)&&(e.length?e.length===this.anchors.length&&(e=!0):e=!1),n=0;s=this.tabs[n];n++)i=t(s),e===!0||-1!==t.inArray(n,e)?(i.attr("aria-disabled","true"),this._addClass(i,null,"ui-state-disabled")):(i.removeAttr("aria-disabled"),this._removeClass(i,null,"ui-state-disabled"));this.options.disabled=e,this._toggleClass(this.widget(),this.widgetFullName+"-disabled",null,e===!0)},_setupEvents:function(e){var i={};e&&t.each(e.split(" "),function(t,e){i[e]="_eventHandler"}),this._off(this.anchors.add(this.tabs).add(this.panels)),this._on(!0,this.anchors,{click:function(t){t.preventDefault()}}),this._on(this.anchors,i),this._on(this.tabs,{keydown:"_tabKeydown"}),this._on(this.panels,{keydown:"_panelKeydown"}),this._focusable(this.tabs),this._hoverable(this.tabs)},_setupHeightStyle:function(e){var i,s=this.element.parent();"fill"===e?(i=s.height(),i-=this.element.outerHeight()-this.element.height(),this.element.siblings(":visible").each(function(){var e=t(this),s=e.css("position");"absolute"!==s&&"fixed"!==s&&(i-=e.outerHeight(!0))}),this.element.children().not(this.panels).each(function(){i-=t(this).outerHeight(!0)}),this.panels.each(function(){t(this).height(Math.max(0,i-t(this).innerHeight()+t(this).height()))}).css("overflow","auto")):"auto"===e&&(i=0,this.panels.each(function(){i=Math.max(i,t(this).height("").height())}).height(i))},_eventHandler:function(e){var i=this.options,s=this.active,n=t(e.currentTarget),o=n.closest("li"),a=o[0]===s[0],r=a&&i.collapsible,h=r?t():this._getPanelForTab(o),l=s.length?this._getPanelForTab(s):t(),c={oldTab:s,oldPanel:l,newTab:r?t():o,newPanel:h};e.preventDefault(),o.hasClass("ui-state-disabled")||o.hasClass("ui-tabs-loading")||this.running||a&&!i.collapsible||this._trigger("beforeActivate",e,c)===!1||(i.active=r?!1:this.tabs.index(o),this.active=a?t():o,this.xhr&&this.xhr.abort(),l.length||h.length||t.error("jQuery UI Tabs: Mismatching fragment identifier."),h.length&&this.load(this.tabs.index(o),e),this._toggle(e,c))},_toggle:function(e,i){function s(){o.running=!1,o._trigger("activate",e,i)}function n(){o._addClass(i.newTab.closest("li"),"ui-tabs-active","ui-state-active"),a.length&&o.options.show?o._show(a,o.options.show,s):(a.show(),s())}var o=this,a=i.newPanel,r=i.oldPanel;this.running=!0,r.length&&this.options.hide?this._hide(r,this.options.hide,function(){o._removeClass(i.oldTab.closest("li"),"ui-tabs-active","ui-state-active"),n()}):(this._removeClass(i.oldTab.closest("li"),"ui-tabs-active","ui-state-active"),r.hide(),n()),r.attr("aria-hidden","true"),i.oldTab.attr({"aria-selected":"false","aria-expanded":"false"}),a.length&&r.length?i.oldTab.attr("tabIndex",-1):a.length&&this.tabs.filter(function(){return 0===t(this).attr("tabIndex")}).attr("tabIndex",-1),a.attr("aria-hidden","false"),i.newTab.attr({"aria-selected":"true","aria-expanded":"true",tabIndex:0})},_activate:function(e){var i,s=this._findActive(e);s[0]!==this.active[0]&&(s.length||(s=this.active),i=s.find(".ui-tabs-anchor")[0],this._eventHandler({target:i,currentTarget:i,preventDefault:t.noop}))},_findActive:function(e){return e===!1?t():this.tabs.eq(e)},_getIndex:function(e){return"string"==typeof e&&(e=this.anchors.index(this.anchors.filter("[href$='"+t.ui.escapeSelector(e)+"']"))),e},_destroy:function(){this.xhr&&this.xhr.abort(),this.tablist.removeAttr("role").off(this.eventNamespace),this.anchors.removeAttr("role tabIndex").removeUniqueId(),this.tabs.add(this.panels).each(function(){t.data(this,"ui-tabs-destroy")?t(this).remove():t(this).removeAttr("role tabIndex aria-live aria-busy aria-selected aria-labelledby aria-hidden aria-expanded")}),this.tabs.each(function(){var e=t(this),i=e.data("ui-tabs-aria-controls");i?e.attr("aria-controls",i).removeData("ui-tabs-aria-controls"):e.removeAttr("aria-controls")}),this.panels.show(),"content"!==this.options.heightStyle&&this.panels.css("height","")},enable:function(e){var i=this.options.disabled;i!==!1&&(void 0===e?i=!1:(e=this._getIndex(e),i=t.isArray(i)?t.map(i,function(t){return t!==e?t:null}):t.map(this.tabs,function(t,i){return i!==e?i:null})),this._setOptionDisabled(i))},disable:function(e){var i=this.options.disabled;if(i!==!0){if(void 0===e)i=!0;else{if(e=this._getIndex(e),-1!==t.inArray(e,i))return;i=t.isArray(i)?t.merge([e],i).sort():[e]}this._setOptionDisabled(i)}},load:function(e,i){e=this._getIndex(e);var s=this,n=this.tabs.eq(e),o=n.find(".ui-tabs-anchor"),a=this._getPanelForTab(n),r={tab:n,panel:a},h=function(t,e){"abort"===e&&s.panels.stop(!1,!0),s._removeClass(n,"ui-tabs-loading"),a.removeAttr("aria-busy"),t===s.xhr&&delete s.xhr};this._isLocal(o[0])||(this.xhr=t.ajax(this._ajaxSettings(o,i,r)),this.xhr&&"canceled"!==this.xhr.statusText&&(this._addClass(n,"ui-tabs-loading"),a.attr("aria-busy","true"),this.xhr.done(function(t,e,n){setTimeout(function(){a.html(t),s._trigger("load",i,r),h(n,e)},1)}).fail(function(t,e){setTimeout(function(){h(t,e)},1)})))},_ajaxSettings:function(e,i,s){var n=this;return{url:e.attr("href").replace(/#.*$/,""),beforeSend:function(e,o){return n._trigger("beforeLoad",i,t.extend({jqXHR:e,ajaxSettings:o},s))}}},_getPanelForTab:function(e){var i=t(e).attr("aria-controls");return this.element.find(this._sanitizeSelector("#"+i))}}),t.uiBackCompat!==!1&&t.widget("ui.tabs",t.ui.tabs,{_processTabs:function(){this._superApply(arguments),this._addClass(this.tabs,"ui-tab")}}),t.ui.tabs,t.widget("ui.tooltip",{version:"1.12.1",options:{classes:{"ui-tooltip":"ui-corner-all ui-widget-shadow"},content:function(){var e=t(this).attr("title")||"";return t("<a>").text(e).html()},hide:!0,items:"[title]:not([disabled])",position:{my:"left top+15",at:"left bottom",collision:"flipfit flip"},show:!0,track:!1,close:null,open:null},_addDescribedBy:function(e,i){var s=(e.attr("aria-describedby")||"").split(/\s+/);s.push(i),e.data("ui-tooltip-id",i).attr("aria-describedby",t.trim(s.join(" ")))},_removeDescribedBy:function(e){var i=e.data("ui-tooltip-id"),s=(e.attr("aria-describedby")||"").split(/\s+/),n=t.inArray(i,s);-1!==n&&s.splice(n,1),e.removeData("ui-tooltip-id"),s=t.trim(s.join(" ")),s?e.attr("aria-describedby",s):e.removeAttr("aria-describedby")},_create:function(){this._on({mouseover:"open",focusin:"open"}),this.tooltips={},this.parents={},this.liveRegion=t("<div>").attr({role:"log","aria-live":"assertive","aria-relevant":"additions"}).appendTo(this.document[0].body),this._addClass(this.liveRegion,null,"ui-helper-hidden-accessible"),this.disabledTitles=t([])},_setOption:function(e,i){var s=this;this._super(e,i),"content"===e&&t.each(this.tooltips,function(t,e){s._updateContent(e.element)})},_setOptionDisabled:function(t){this[t?"_disable":"_enable"]()},_disable:function(){var e=this;t.each(this.tooltips,function(i,s){var n=t.Event("blur");n.target=n.currentTarget=s.element[0],e.close(n,!0)}),this.disabledTitles=this.disabledTitles.add(this.element.find(this.options.items).addBack().filter(function(){var e=t(this);return e.is("[title]")?e.data("ui-tooltip-title",e.attr("title")).removeAttr("title"):void 0}))},_enable:function(){this.disabledTitles.each(function(){var e=t(this);e.data("ui-tooltip-title")&&e.attr("title",e.data("ui-tooltip-title"))}),this.disabledTitles=t([])},open:function(e){var i=this,s=t(e?e.target:this.element).closest(this.options.items);s.length&&!s.data("ui-tooltip-id")&&(s.attr("title")&&s.data("ui-tooltip-title",s.attr("title")),s.data("ui-tooltip-open",!0),e&&"mouseover"===e.type&&s.parents().each(function(){var e,s=t(this);s.data("ui-tooltip-open")&&(e=t.Event("blur"),e.target=e.currentTarget=this,i.close(e,!0)),s.attr("title")&&(s.uniqueId(),i.parents[this.id]={element:this,title:s.attr("title")},s.attr("title",""))}),this._registerCloseHandlers(e,s),this._updateContent(s,e))},_updateContent:function(t,e){var i,s=this.options.content,n=this,o=e?e.type:null;return"string"==typeof s||s.nodeType||s.jquery?this._open(e,t,s):(i=s.call(t[0],function(i){n._delay(function(){t.data("ui-tooltip-open")&&(e&&(e.type=o),this._open(e,t,i))})}),i&&this._open(e,t,i),void 0)},_open:function(e,i,s){function n(t){l.of=t,a.is(":hidden")||a.position(l)}var o,a,r,h,l=t.extend({},this.options.position);if(s){if(o=this._find(i))return o.tooltip.find(".ui-tooltip-content").html(s),void 0;i.is("[title]")&&(e&&"mouseover"===e.type?i.attr("title",""):i.removeAttr("title")),o=this._tooltip(i),a=o.tooltip,this._addDescribedBy(i,a.attr("id")),a.find(".ui-tooltip-content").html(s),this.liveRegion.children().hide(),h=t("<div>").html(a.find(".ui-tooltip-content").html()),h.removeAttr("name").find("[name]").removeAttr("name"),h.removeAttr("id").find("[id]").removeAttr("id"),h.appendTo(this.liveRegion),this.options.track&&e&&/^mouse/.test(e.type)?(this._on(this.document,{mousemove:n}),n(e)):a.position(t.extend({of:i},this.options.position)),a.hide(),this._show(a,this.options.show),this.options.track&&this.options.show&&this.options.show.delay&&(r=this.delayedShow=setInterval(function(){a.is(":visible")&&(n(l.of),clearInterval(r))},t.fx.interval)),this._trigger("open",e,{tooltip:a})}},_registerCloseHandlers:function(e,i){var s={keyup:function(e){if(e.keyCode===t.ui.keyCode.ESCAPE){var s=t.Event(e);s.currentTarget=i[0],this.close(s,!0)}}};i[0]!==this.element[0]&&(s.remove=function(){this._removeTooltip(this._find(i).tooltip)}),e&&"mouseover"!==e.type||(s.mouseleave="close"),e&&"focusin"!==e.type||(s.focusout="close"),this._on(!0,i,s)},close:function(e){var i,s=this,n=t(e?e.currentTarget:this.element),o=this._find(n);return o?(i=o.tooltip,o.closing||(clearInterval(this.delayedShow),n.data("ui-tooltip-title")&&!n.attr("title")&&n.attr("title",n.data("ui-tooltip-title")),this._removeDescribedBy(n),o.hiding=!0,i.stop(!0),this._hide(i,this.options.hide,function(){s._removeTooltip(t(this))}),n.removeData("ui-tooltip-open"),this._off(n,"mouseleave focusout keyup"),n[0]!==this.element[0]&&this._off(n,"remove"),this._off(this.document,"mousemove"),e&&"mouseleave"===e.type&&t.each(this.parents,function(e,i){t(i.element).attr("title",i.title),delete s.parents[e]}),o.closing=!0,this._trigger("close",e,{tooltip:i}),o.hiding||(o.closing=!1)),void 0):(n.removeData("ui-tooltip-open"),void 0)},_tooltip:function(e){var i=t("<div>").attr("role","tooltip"),s=t("<div>").appendTo(i),n=i.uniqueId().attr("id");return this._addClass(s,"ui-tooltip-content"),this._addClass(i,"ui-tooltip","ui-widget ui-widget-content"),i.appendTo(this._appendTo(e)),this.tooltips[n]={element:e,tooltip:i}},_find:function(t){var e=t.data("ui-tooltip-id");return e?this.tooltips[e]:null},_removeTooltip:function(t){t.remove(),delete this.tooltips[t.attr("id")]},_appendTo:function(t){var e=t.closest(".ui-front, dialog");return e.length||(e=this.document[0].body),e},_destroy:function(){var e=this;t.each(this.tooltips,function(i,s){var n=t.Event("blur"),o=s.element;n.target=n.currentTarget=o[0],e.close(n,!0),t("#"+i).remove(),o.data("ui-tooltip-title")&&(o.attr("title")||o.attr("title",o.data("ui-tooltip-title")),o.removeData("ui-tooltip-title"))}),this.liveRegion.remove()}}),t.uiBackCompat!==!1&&t.widget("ui.tooltip",t.ui.tooltip,{options:{tooltipClass:null},_tooltip:function(){var t=this._superApply(arguments);return this.options.tooltipClass&&t.tooltip.addClass(this.options.tooltipClass),t}}),t.ui.tooltip});;/*! + * jQuery UI Touch Punch 0.2.3 + * + * Copyright 2011–2014, Dave Furfero + * Dual licensed under the MIT or GPL Version 2 licenses. + * + * Depends: + * jquery.ui.widget.js + * jquery.ui.mouse.js + */ +!function(a){function f(a,b){if(!(a.originalEvent.touches.length>1)){a.preventDefault();var c=a.originalEvent.changedTouches[0],d=document.createEvent("MouseEvents");d.initMouseEvent(b,!0,!0,window,1,c.screenX,c.screenY,c.clientX,c.clientY,!1,!1,!1,!1,0,null),a.target.dispatchEvent(d)}}if(a.support.touch="ontouchend"in document,a.support.touch){var e,b=a.ui.mouse.prototype,c=b._mouseInit,d=b._mouseDestroy;b._touchStart=function(a){var b=this;!e&&b._mouseCapture(a.originalEvent.changedTouches[0])&&(e=!0,b._touchMoved=!1,f(a,"mouseover"),f(a,"mousemove"),f(a,"mousedown"))},b._touchMove=function(a){e&&(this._touchMoved=!0,f(a,"mousemove"))},b._touchEnd=function(a){e&&(f(a,"mouseup"),f(a,"mouseout"),this._touchMoved||f(a,"click"),e=!1)},b._mouseInit=function(){var b=this;b.element.bind({touchstart:a.proxy(b,"_touchStart"),touchmove:a.proxy(b,"_touchMove"),touchend:a.proxy(b,"_touchEnd")}),c.call(b)},b._mouseDestroy=function(){var b=this;b.element.unbind({touchstart:a.proxy(b,"_touchStart"),touchmove:a.proxy(b,"_touchMove"),touchend:a.proxy(b,"_touchEnd")}),d.call(b)}}}(jQuery);;/** + * marked - a markdown parser + * Copyright (c) 2011-2022, Christopher Jeffrey. (MIT Licensed) + * https://github.com/markedjs/marked + */ +!function(e,t){"object"==typeof exports&&"undefined"!=typeof module?t(exports):"function"==typeof define&&define.amd?define(["exports"],t):t((e="undefined"!=typeof globalThis?globalThis:e||self).marked={})}(this,function(r){"use strict";function i(e,t){for(var u=0;u<t.length;u++){var n=t[u];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}function s(e,t){(null==t||t>e.length)&&(t=e.length);for(var u=0,n=new Array(t);u<t;u++)n[u]=e[u];return n}function B(e,t){var u,n="undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(n)return(n=n.call(e)).next.bind(n);if(Array.isArray(e)||(n=function(e,t){if(e){if("string"==typeof e)return s(e,t);var u=Object.prototype.toString.call(e).slice(8,-1);return"Map"===(u="Object"===u&&e.constructor?e.constructor.name:u)||"Set"===u?Array.from(e):"Arguments"===u||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(u)?s(e,t):void 0}}(e))||t&&e&&"number"==typeof e.length)return n&&(e=n),u=0,function(){return u>=e.length?{done:!0}:{done:!1,value:e[u++]}};throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}function e(){return{baseUrl:null,breaks:!1,extensions:null,gfm:!0,headerIds:!0,headerPrefix:"",highlight:null,langPrefix:"language-",mangle:!0,pedantic:!1,renderer:null,sanitize:!1,sanitizer:null,silent:!1,smartLists:!1,smartypants:!1,tokenizer:null,walkTokens:null,xhtml:!1}}r.defaults=e();function u(e){return t[e]}var n=/[&<>"']/,l=/[&<>"']/g,a=/[<>"']|&(?!#?\w+;)/,o=/[<>"']|&(?!#?\w+;)/g,t={"&":"&amp;","<":"&lt;",">":"&gt;",'"':"&quot;","'":"&#39;"};function D(e,t){if(t){if(n.test(e))return e.replace(l,u)}else if(a.test(e))return e.replace(o,u);return e}var c=/&(#(?:\d+)|(?:#x[0-9A-Fa-f]+)|(?:\w+));?/gi;function x(e){return e.replace(c,function(e,t){return"colon"===(t=t.toLowerCase())?":":"#"===t.charAt(0)?"x"===t.charAt(1)?String.fromCharCode(parseInt(t.substring(2),16)):String.fromCharCode(+t.substring(1)):""})}var h=/(^|[^\[])\^/g;function p(u,e){u="string"==typeof u?u:u.source,e=e||"";var n={replace:function(e,t){return t=(t=t.source||t).replace(h,"$1"),u=u.replace(e,t),n},getRegex:function(){return new RegExp(u,e)}};return n}var f=/[^\w:]/g,Z=/^$|^[a-z][a-z0-9+.-]*:|^[?#]/i;function g(e,t,u){if(e){try{n=decodeURIComponent(x(u)).replace(f,"").toLowerCase()}catch(e){return null}if(0===n.indexOf("javascript:")||0===n.indexOf("vbscript:")||0===n.indexOf("data:"))return null}var n;t&&!Z.test(u)&&(e=u,F[" "+(n=t)]||(O.test(n)?F[" "+n]=n+"/":F[" "+n]=k(n,"/",!0)),t=-1===(n=F[" "+n]).indexOf(":"),u="//"===e.substring(0,2)?t?e:n.replace(q,"$1")+e:"/"===e.charAt(0)?t?e:n.replace(L,"$1")+e:n+e);try{u=encodeURI(u).replace(/%25/g,"%")}catch(e){return null}return u}var F={},O=/^[^:]+:\/*[^/]*$/,q=/^([^:]+:)[\s\S]*$/,L=/^([^:]+:\/*[^/]*)[\s\S]*$/;var A={exec:function(){}};function d(e){for(var t,u,n=1;n<arguments.length;n++)for(u in t=arguments[n])Object.prototype.hasOwnProperty.call(t,u)&&(e[u]=t[u]);return e}function C(e,t){var u=e.replace(/\|/g,function(e,t,u){for(var n=!1,r=t;0<=--r&&"\\"===u[r];)n=!n;return n?"|":" |"}).split(/ \|/),n=0;if(u[0].trim()||u.shift(),0<u.length&&!u[u.length-1].trim()&&u.pop(),u.length>t)u.splice(t);else for(;u.length<t;)u.push("");for(;n<u.length;n++)u[n]=u[n].trim().replace(/\\\|/g,"|");return u}function k(e,t,u){var n=e.length;if(0===n)return"";for(var r=0;r<n;){var i=e.charAt(n-r-1);if(i!==t||u){if(i===t||!u)break;r++}else r++}return e.slice(0,n-r)}function E(e){e&&e.sanitize&&!e.silent&&console.warn("marked(): sanitize and sanitizer parameters are deprecated since version 0.7.0, should not be used and will be removed in the future. Read more here: https://marked.js.org/#/USING_ADVANCED.md#options")}function m(e,t){if(t<1)return"";for(var u="";1<t;)1&t&&(u+=e),t>>=1,e+=e;return u+e}function b(e,t,u,n){var r=t.href,t=t.title?D(t.title):null,i=e[1].replace(/\\([\[\]])/g,"$1");return"!"!==e[0].charAt(0)?(n.state.inLink=!0,e={type:"link",raw:u,href:r,title:t,text:i,tokens:n.inlineTokens(i,[])},n.state.inLink=!1,e):{type:"image",raw:u,href:r,title:t,text:D(i)}}var w=function(){function e(e){this.options=e||r.defaults}var t=e.prototype;return t.space=function(e){e=this.rules.block.newline.exec(e);if(e&&0<e[0].length)return{type:"space",raw:e[0]}},t.code=function(e){var t,e=this.rules.block.code.exec(e);if(e)return t=e[0].replace(/^ {1,4}/gm,""),{type:"code",raw:e[0],codeBlockStyle:"indented",text:this.options.pedantic?t:k(t,"\n")}},t.fences=function(e){var t,u,e=this.rules.block.fences.exec(e);if(e)return u=function(e,t){if(null===(e=e.match(/^(\s+)(?:```)/)))return t;var u=e[1];return t.split("\n").map(function(e){var t=e.match(/^\s+/);return null!==t&&t[0].length>=u.length?e.slice(u.length):e}).join("\n")}(t=e[0],e[3]||""),{type:"code",raw:t,lang:e[2]&&e[2].trim(),text:u}},t.heading=function(e){var t,u,e=this.rules.block.heading.exec(e);if(e)return t=e[2].trim(),/#$/.test(t)&&(u=k(t,"#"),!this.options.pedantic&&u&&!/ $/.test(u)||(t=u.trim())),u={type:"heading",raw:e[0],depth:e[1].length,text:t,tokens:[]},this.lexer.inline(u.text,u.tokens),u},t.hr=function(e){e=this.rules.block.hr.exec(e);if(e)return{type:"hr",raw:e[0]}},t.blockquote=function(e){var t,e=this.rules.block.blockquote.exec(e);if(e)return t=e[0].replace(/^ *>[ \t]?/gm,""),{type:"blockquote",raw:e[0],tokens:this.lexer.blockTokens(t,[]),text:t}},t.list=function(e){var t=this.rules.block.list.exec(e);if(t){var u,n,r,i,s,l,a,o,D,c,h,p=1<(g=t[1].trim()).length,f={type:"list",raw:"",ordered:p,start:p?+g.slice(0,-1):"",loose:!1,items:[]},g=p?"\\d{1,9}\\"+g.slice(-1):"\\"+g;this.options.pedantic&&(g=p?g:"[*+-]");for(var F=new RegExp("^( {0,3}"+g+")((?:[\t ][^\\n]*)?(?:\\n|$))");e&&(h=!1,t=F.exec(e))&&!this.rules.block.hr.test(e);){if(u=t[0],e=e.substring(u.length),a=t[2].split("\n",1)[0],o=e.split("\n",1)[0],this.options.pedantic?(i=2,c=a.trimLeft()):(i=t[2].search(/[^ ]/),c=a.slice(i=4<i?1:i),i+=t[1].length),s=!1,!a&&/^ *$/.test(o)&&(u+=o+"\n",e=e.substring(o.length+1),h=!0),!h)for(var A=new RegExp("^ {0,"+Math.min(3,i-1)+"}(?:[*+-]|\\d{1,9}[.)])((?: [^\\n]*)?(?:\\n|$))"),d=new RegExp("^ {0,"+Math.min(3,i-1)+"}((?:- *){3,}|(?:_ *){3,}|(?:\\* *){3,})(?:\\n+|$)"),C=new RegExp("^ {0,"+Math.min(3,i-1)+"}(?:```|~~~)"),k=new RegExp("^ {0,"+Math.min(3,i-1)+"}#");e&&(a=D=e.split("\n",1)[0],this.options.pedantic&&(a=a.replace(/^ {1,4}(?=( {4})*[^ ])/g," ")),!C.test(a))&&!k.test(a)&&!A.test(a)&&!d.test(e);){if(a.search(/[^ ]/)>=i||!a.trim())c+="\n"+a.slice(i);else{if(s)break;c+="\n"+a}s||a.trim()||(s=!0),u+=D+"\n",e=e.substring(D.length+1)}f.loose||(l?f.loose=!0:/\n *\n *$/.test(u)&&(l=!0)),this.options.gfm&&(n=/^\[[ xX]\] /.exec(c))&&(r="[ ] "!==n[0],c=c.replace(/^\[[ xX]\] +/,"")),f.items.push({type:"list_item",raw:u,task:!!n,checked:r,loose:!1,text:c}),f.raw+=u}f.items[f.items.length-1].raw=u.trimRight(),f.items[f.items.length-1].text=c.trimRight(),f.raw=f.raw.trimRight();for(var E=f.items.length,x=0;x<E;x++){this.lexer.state.top=!1,f.items[x].tokens=this.lexer.blockTokens(f.items[x].text,[]);var m=f.items[x].tokens.filter(function(e){return"space"===e.type}),b=m.every(function(e){for(var t,u=0,n=B(e.raw.split(""));!(t=n()).done;)if("\n"===t.value&&(u+=1),1<u)return!0;return!1});!f.loose&&m.length&&b&&(f.loose=!0,f.items[x].loose=!0)}return f}},t.html=function(e){var t,e=this.rules.block.html.exec(e);if(e)return t={type:"html",raw:e[0],pre:!this.options.sanitizer&&("pre"===e[1]||"script"===e[1]||"style"===e[1]),text:e[0]},this.options.sanitize&&(t.type="paragraph",t.text=this.options.sanitizer?this.options.sanitizer(e[0]):D(e[0]),t.tokens=[],this.lexer.inline(t.text,t.tokens)),t},t.def=function(e){e=this.rules.block.def.exec(e);if(e)return e[3]&&(e[3]=e[3].substring(1,e[3].length-1)),{type:"def",tag:e[1].toLowerCase().replace(/\s+/g," "),raw:e[0],href:e[2],title:e[3]}},t.table=function(e){e=this.rules.block.table.exec(e);if(e){var t={type:"table",header:C(e[1]).map(function(e){return{text:e}}),align:e[2].replace(/^ *|\| *$/g,"").split(/ *\| */),rows:e[3]&&e[3].trim()?e[3].replace(/\n[ \t]*$/,"").split("\n"):[]};if(t.header.length===t.align.length){t.raw=e[0];for(var u,n,r,i=t.align.length,s=0;s<i;s++)/^ *-+: *$/.test(t.align[s])?t.align[s]="right":/^ *:-+: *$/.test(t.align[s])?t.align[s]="center":/^ *:-+ *$/.test(t.align[s])?t.align[s]="left":t.align[s]=null;for(i=t.rows.length,s=0;s<i;s++)t.rows[s]=C(t.rows[s],t.header.length).map(function(e){return{text:e}});for(i=t.header.length,u=0;u<i;u++)t.header[u].tokens=[],this.lexer.inline(t.header[u].text,t.header[u].tokens);for(i=t.rows.length,u=0;u<i;u++)for(r=t.rows[u],n=0;n<r.length;n++)r[n].tokens=[],this.lexer.inline(r[n].text,r[n].tokens);return t}}},t.lheading=function(e){var e=this.rules.block.lheading.exec(e);if(e)return e={type:"heading",raw:e[0],depth:"="===e[2].charAt(0)?1:2,text:e[1],tokens:[]},this.lexer.inline(e.text,e.tokens),e},t.paragraph=function(e){var e=this.rules.block.paragraph.exec(e);if(e)return e={type:"paragraph",raw:e[0],text:"\n"===e[1].charAt(e[1].length-1)?e[1].slice(0,-1):e[1],tokens:[]},this.lexer.inline(e.text,e.tokens),e},t.text=function(e){var e=this.rules.block.text.exec(e);if(e)return e={type:"text",raw:e[0],text:e[0],tokens:[]},this.lexer.inline(e.text,e.tokens),e},t.escape=function(e){e=this.rules.inline.escape.exec(e);if(e)return{type:"escape",raw:e[0],text:D(e[1])}},t.tag=function(e){e=this.rules.inline.tag.exec(e);if(e)return!this.lexer.state.inLink&&/^<a /i.test(e[0])?this.lexer.state.inLink=!0:this.lexer.state.inLink&&/^<\/a>/i.test(e[0])&&(this.lexer.state.inLink=!1),!this.lexer.state.inRawBlock&&/^<(pre|code|kbd|script)(\s|>)/i.test(e[0])?this.lexer.state.inRawBlock=!0:this.lexer.state.inRawBlock&&/^<\/(pre|code|kbd|script)(\s|>)/i.test(e[0])&&(this.lexer.state.inRawBlock=!1),{type:this.options.sanitize?"text":"html",raw:e[0],inLink:this.lexer.state.inLink,inRawBlock:this.lexer.state.inRawBlock,text:this.options.sanitize?this.options.sanitizer?this.options.sanitizer(e[0]):D(e[0]):e[0]}},t.link=function(e){e=this.rules.inline.link.exec(e);if(e){var t=e[2].trim();if(!this.options.pedantic&&/^</.test(t)){if(!/>$/.test(t))return;var u=k(t.slice(0,-1),"\\");if((t.length-u.length)%2==0)return}else{u=function(e,t){if(-1!==e.indexOf(t[1]))for(var u=e.length,n=0,r=0;r<u;r++)if("\\"===e[r])r++;else if(e[r]===t[0])n++;else if(e[r]===t[1]&&--n<0)return r;return-1}(e[2],"()");-1<u&&(r=(0===e[0].indexOf("!")?5:4)+e[1].length+u,e[2]=e[2].substring(0,u),e[0]=e[0].substring(0,r).trim(),e[3]="")}var n,u=e[2],r="";return this.options.pedantic?(n=/^([^'"]*[^\s])\s+(['"])(.*)\2/.exec(u))&&(u=n[1],r=n[3]):r=e[3]?e[3].slice(1,-1):"",u=u.trim(),b(e,{href:(u=/^</.test(u)?this.options.pedantic&&!/>$/.test(t)?u.slice(1):u.slice(1,-1):u)&&u.replace(this.rules.inline._escapes,"$1"),title:r&&r.replace(this.rules.inline._escapes,"$1")},e[0],this.lexer)}},t.reflink=function(e,t){var u;if((u=this.rules.inline.reflink.exec(e))||(u=this.rules.inline.nolink.exec(e)))return(e=t[(e=(u[2]||u[1]).replace(/\s+/g," ")).toLowerCase()])&&e.href?b(u,e,u[0],this.lexer):{type:"text",raw:t=u[0].charAt(0),text:t}},t.emStrong=function(e,t,u){void 0===u&&(u="");var n=this.rules.inline.emStrong.lDelim.exec(e);if(n&&(!n[3]||!u.match(/(?:[0-9A-Za-z\xAA\xB2\xB3\xB5\xB9\xBA\xBC-\xBE\xC0-\xD6\xD8-\xF6\xF8-\u02C1\u02C6-\u02D1\u02E0-\u02E4\u02EC\u02EE\u0370-\u0374\u0376\u0377\u037A-\u037D\u037F\u0386\u0388-\u038A\u038C\u038E-\u03A1\u03A3-\u03F5\u03F7-\u0481\u048A-\u052F\u0531-\u0556\u0559\u0560-\u0588\u05D0-\u05EA\u05EF-\u05F2\u0620-\u064A\u0660-\u0669\u066E\u066F\u0671-\u06D3\u06D5\u06E5\u06E6\u06EE-\u06FC\u06FF\u0710\u0712-\u072F\u074D-\u07A5\u07B1\u07C0-\u07EA\u07F4\u07F5\u07FA\u0800-\u0815\u081A\u0824\u0828\u0840-\u0858\u0860-\u086A\u0870-\u0887\u0889-\u088E\u08A0-\u08C9\u0904-\u0939\u093D\u0950\u0958-\u0961\u0966-\u096F\u0971-\u0980\u0985-\u098C\u098F\u0990\u0993-\u09A8\u09AA-\u09B0\u09B2\u09B6-\u09B9\u09BD\u09CE\u09DC\u09DD\u09DF-\u09E1\u09E6-\u09F1\u09F4-\u09F9\u09FC\u0A05-\u0A0A\u0A0F\u0A10\u0A13-\u0A28\u0A2A-\u0A30\u0A32\u0A33\u0A35\u0A36\u0A38\u0A39\u0A59-\u0A5C\u0A5E\u0A66-\u0A6F\u0A72-\u0A74\u0A85-\u0A8D\u0A8F-\u0A91\u0A93-\u0AA8\u0AAA-\u0AB0\u0AB2\u0AB3\u0AB5-\u0AB9\u0ABD\u0AD0\u0AE0\u0AE1\u0AE6-\u0AEF\u0AF9\u0B05-\u0B0C\u0B0F\u0B10\u0B13-\u0B28\u0B2A-\u0B30\u0B32\u0B33\u0B35-\u0B39\u0B3D\u0B5C\u0B5D\u0B5F-\u0B61\u0B66-\u0B6F\u0B71-\u0B77\u0B83\u0B85-\u0B8A\u0B8E-\u0B90\u0B92-\u0B95\u0B99\u0B9A\u0B9C\u0B9E\u0B9F\u0BA3\u0BA4\u0BA8-\u0BAA\u0BAE-\u0BB9\u0BD0\u0BE6-\u0BF2\u0C05-\u0C0C\u0C0E-\u0C10\u0C12-\u0C28\u0C2A-\u0C39\u0C3D\u0C58-\u0C5A\u0C5D\u0C60\u0C61\u0C66-\u0C6F\u0C78-\u0C7E\u0C80\u0C85-\u0C8C\u0C8E-\u0C90\u0C92-\u0CA8\u0CAA-\u0CB3\u0CB5-\u0CB9\u0CBD\u0CDD\u0CDE\u0CE0\u0CE1\u0CE6-\u0CEF\u0CF1\u0CF2\u0D04-\u0D0C\u0D0E-\u0D10\u0D12-\u0D3A\u0D3D\u0D4E\u0D54-\u0D56\u0D58-\u0D61\u0D66-\u0D78\u0D7A-\u0D7F\u0D85-\u0D96\u0D9A-\u0DB1\u0DB3-\u0DBB\u0DBD\u0DC0-\u0DC6\u0DE6-\u0DEF\u0E01-\u0E30\u0E32\u0E33\u0E40-\u0E46\u0E50-\u0E59\u0E81\u0E82\u0E84\u0E86-\u0E8A\u0E8C-\u0EA3\u0EA5\u0EA7-\u0EB0\u0EB2\u0EB3\u0EBD\u0EC0-\u0EC4\u0EC6\u0ED0-\u0ED9\u0EDC-\u0EDF\u0F00\u0F20-\u0F33\u0F40-\u0F47\u0F49-\u0F6C\u0F88-\u0F8C\u1000-\u102A\u103F-\u1049\u1050-\u1055\u105A-\u105D\u1061\u1065\u1066\u106E-\u1070\u1075-\u1081\u108E\u1090-\u1099\u10A0-\u10C5\u10C7\u10CD\u10D0-\u10FA\u10FC-\u1248\u124A-\u124D\u1250-\u1256\u1258\u125A-\u125D\u1260-\u1288\u128A-\u128D\u1290-\u12B0\u12B2-\u12B5\u12B8-\u12BE\u12C0\u12C2-\u12C5\u12C8-\u12D6\u12D8-\u1310\u1312-\u1315\u1318-\u135A\u1369-\u137C\u1380-\u138F\u13A0-\u13F5\u13F8-\u13FD\u1401-\u166C\u166F-\u167F\u1681-\u169A\u16A0-\u16EA\u16EE-\u16F8\u1700-\u1711\u171F-\u1731\u1740-\u1751\u1760-\u176C\u176E-\u1770\u1780-\u17B3\u17D7\u17DC\u17E0-\u17E9\u17F0-\u17F9\u1810-\u1819\u1820-\u1878\u1880-\u1884\u1887-\u18A8\u18AA\u18B0-\u18F5\u1900-\u191E\u1946-\u196D\u1970-\u1974\u1980-\u19AB\u19B0-\u19C9\u19D0-\u19DA\u1A00-\u1A16\u1A20-\u1A54\u1A80-\u1A89\u1A90-\u1A99\u1AA7\u1B05-\u1B33\u1B45-\u1B4C\u1B50-\u1B59\u1B83-\u1BA0\u1BAE-\u1BE5\u1C00-\u1C23\u1C40-\u1C49\u1C4D-\u1C7D\u1C80-\u1C88\u1C90-\u1CBA\u1CBD-\u1CBF\u1CE9-\u1CEC\u1CEE-\u1CF3\u1CF5\u1CF6\u1CFA\u1D00-\u1DBF\u1E00-\u1F15\u1F18-\u1F1D\u1F20-\u1F45\u1F48-\u1F4D\u1F50-\u1F57\u1F59\u1F5B\u1F5D\u1F5F-\u1F7D\u1F80-\u1FB4\u1FB6-\u1FBC\u1FBE\u1FC2-\u1FC4\u1FC6-\u1FCC\u1FD0-\u1FD3\u1FD6-\u1FDB\u1FE0-\u1FEC\u1FF2-\u1FF4\u1FF6-\u1FFC\u2070\u2071\u2074-\u2079\u207F-\u2089\u2090-\u209C\u2102\u2107\u210A-\u2113\u2115\u2119-\u211D\u2124\u2126\u2128\u212A-\u212D\u212F-\u2139\u213C-\u213F\u2145-\u2149\u214E\u2150-\u2189\u2460-\u249B\u24EA-\u24FF\u2776-\u2793\u2C00-\u2CE4\u2CEB-\u2CEE\u2CF2\u2CF3\u2CFD\u2D00-\u2D25\u2D27\u2D2D\u2D30-\u2D67\u2D6F\u2D80-\u2D96\u2DA0-\u2DA6\u2DA8-\u2DAE\u2DB0-\u2DB6\u2DB8-\u2DBE\u2DC0-\u2DC6\u2DC8-\u2DCE\u2DD0-\u2DD6\u2DD8-\u2DDE\u2E2F\u3005-\u3007\u3021-\u3029\u3031-\u3035\u3038-\u303C\u3041-\u3096\u309D-\u309F\u30A1-\u30FA\u30FC-\u30FF\u3105-\u312F\u3131-\u318E\u3192-\u3195\u31A0-\u31BF\u31F0-\u31FF\u3220-\u3229\u3248-\u324F\u3251-\u325F\u3280-\u3289\u32B1-\u32BF\u3400-\u4DBF\u4E00-\uA48C\uA4D0-\uA4FD\uA500-\uA60C\uA610-\uA62B\uA640-\uA66E\uA67F-\uA69D\uA6A0-\uA6EF\uA717-\uA71F\uA722-\uA788\uA78B-\uA7CA\uA7D0\uA7D1\uA7D3\uA7D5-\uA7D9\uA7F2-\uA801\uA803-\uA805\uA807-\uA80A\uA80C-\uA822\uA830-\uA835\uA840-\uA873\uA882-\uA8B3\uA8D0-\uA8D9\uA8F2-\uA8F7\uA8FB\uA8FD\uA8FE\uA900-\uA925\uA930-\uA946\uA960-\uA97C\uA984-\uA9B2\uA9CF-\uA9D9\uA9E0-\uA9E4\uA9E6-\uA9FE\uAA00-\uAA28\uAA40-\uAA42\uAA44-\uAA4B\uAA50-\uAA59\uAA60-\uAA76\uAA7A\uAA7E-\uAAAF\uAAB1\uAAB5\uAAB6\uAAB9-\uAABD\uAAC0\uAAC2\uAADB-\uAADD\uAAE0-\uAAEA\uAAF2-\uAAF4\uAB01-\uAB06\uAB09-\uAB0E\uAB11-\uAB16\uAB20-\uAB26\uAB28-\uAB2E\uAB30-\uAB5A\uAB5C-\uAB69\uAB70-\uABE2\uABF0-\uABF9\uAC00-\uD7A3\uD7B0-\uD7C6\uD7CB-\uD7FB\uF900-\uFA6D\uFA70-\uFAD9\uFB00-\uFB06\uFB13-\uFB17\uFB1D\uFB1F-\uFB28\uFB2A-\uFB36\uFB38-\uFB3C\uFB3E\uFB40\uFB41\uFB43\uFB44\uFB46-\uFBB1\uFBD3-\uFD3D\uFD50-\uFD8F\uFD92-\uFDC7\uFDF0-\uFDFB\uFE70-\uFE74\uFE76-\uFEFC\uFF10-\uFF19\uFF21-\uFF3A\uFF41-\uFF5A\uFF66-\uFFBE\uFFC2-\uFFC7\uFFCA-\uFFCF\uFFD2-\uFFD7\uFFDA-\uFFDC]|\uD800[\uDC00-\uDC0B\uDC0D-\uDC26\uDC28-\uDC3A\uDC3C\uDC3D\uDC3F-\uDC4D\uDC50-\uDC5D\uDC80-\uDCFA\uDD07-\uDD33\uDD40-\uDD78\uDD8A\uDD8B\uDE80-\uDE9C\uDEA0-\uDED0\uDEE1-\uDEFB\uDF00-\uDF23\uDF2D-\uDF4A\uDF50-\uDF75\uDF80-\uDF9D\uDFA0-\uDFC3\uDFC8-\uDFCF\uDFD1-\uDFD5]|\uD801[\uDC00-\uDC9D\uDCA0-\uDCA9\uDCB0-\uDCD3\uDCD8-\uDCFB\uDD00-\uDD27\uDD30-\uDD63\uDD70-\uDD7A\uDD7C-\uDD8A\uDD8C-\uDD92\uDD94\uDD95\uDD97-\uDDA1\uDDA3-\uDDB1\uDDB3-\uDDB9\uDDBB\uDDBC\uDE00-\uDF36\uDF40-\uDF55\uDF60-\uDF67\uDF80-\uDF85\uDF87-\uDFB0\uDFB2-\uDFBA]|\uD802[\uDC00-\uDC05\uDC08\uDC0A-\uDC35\uDC37\uDC38\uDC3C\uDC3F-\uDC55\uDC58-\uDC76\uDC79-\uDC9E\uDCA7-\uDCAF\uDCE0-\uDCF2\uDCF4\uDCF5\uDCFB-\uDD1B\uDD20-\uDD39\uDD80-\uDDB7\uDDBC-\uDDCF\uDDD2-\uDE00\uDE10-\uDE13\uDE15-\uDE17\uDE19-\uDE35\uDE40-\uDE48\uDE60-\uDE7E\uDE80-\uDE9F\uDEC0-\uDEC7\uDEC9-\uDEE4\uDEEB-\uDEEF\uDF00-\uDF35\uDF40-\uDF55\uDF58-\uDF72\uDF78-\uDF91\uDFA9-\uDFAF]|\uD803[\uDC00-\uDC48\uDC80-\uDCB2\uDCC0-\uDCF2\uDCFA-\uDD23\uDD30-\uDD39\uDE60-\uDE7E\uDE80-\uDEA9\uDEB0\uDEB1\uDF00-\uDF27\uDF30-\uDF45\uDF51-\uDF54\uDF70-\uDF81\uDFB0-\uDFCB\uDFE0-\uDFF6]|\uD804[\uDC03-\uDC37\uDC52-\uDC6F\uDC71\uDC72\uDC75\uDC83-\uDCAF\uDCD0-\uDCE8\uDCF0-\uDCF9\uDD03-\uDD26\uDD36-\uDD3F\uDD44\uDD47\uDD50-\uDD72\uDD76\uDD83-\uDDB2\uDDC1-\uDDC4\uDDD0-\uDDDA\uDDDC\uDDE1-\uDDF4\uDE00-\uDE11\uDE13-\uDE2B\uDE80-\uDE86\uDE88\uDE8A-\uDE8D\uDE8F-\uDE9D\uDE9F-\uDEA8\uDEB0-\uDEDE\uDEF0-\uDEF9\uDF05-\uDF0C\uDF0F\uDF10\uDF13-\uDF28\uDF2A-\uDF30\uDF32\uDF33\uDF35-\uDF39\uDF3D\uDF50\uDF5D-\uDF61]|\uD805[\uDC00-\uDC34\uDC47-\uDC4A\uDC50-\uDC59\uDC5F-\uDC61\uDC80-\uDCAF\uDCC4\uDCC5\uDCC7\uDCD0-\uDCD9\uDD80-\uDDAE\uDDD8-\uDDDB\uDE00-\uDE2F\uDE44\uDE50-\uDE59\uDE80-\uDEAA\uDEB8\uDEC0-\uDEC9\uDF00-\uDF1A\uDF30-\uDF3B\uDF40-\uDF46]|\uD806[\uDC00-\uDC2B\uDCA0-\uDCF2\uDCFF-\uDD06\uDD09\uDD0C-\uDD13\uDD15\uDD16\uDD18-\uDD2F\uDD3F\uDD41\uDD50-\uDD59\uDDA0-\uDDA7\uDDAA-\uDDD0\uDDE1\uDDE3\uDE00\uDE0B-\uDE32\uDE3A\uDE50\uDE5C-\uDE89\uDE9D\uDEB0-\uDEF8]|\uD807[\uDC00-\uDC08\uDC0A-\uDC2E\uDC40\uDC50-\uDC6C\uDC72-\uDC8F\uDD00-\uDD06\uDD08\uDD09\uDD0B-\uDD30\uDD46\uDD50-\uDD59\uDD60-\uDD65\uDD67\uDD68\uDD6A-\uDD89\uDD98\uDDA0-\uDDA9\uDEE0-\uDEF2\uDFB0\uDFC0-\uDFD4]|\uD808[\uDC00-\uDF99]|\uD809[\uDC00-\uDC6E\uDC80-\uDD43]|\uD80B[\uDF90-\uDFF0]|[\uD80C\uD81C-\uD820\uD822\uD840-\uD868\uD86A-\uD86C\uD86F-\uD872\uD874-\uD879\uD880-\uD883][\uDC00-\uDFFF]|\uD80D[\uDC00-\uDC2E]|\uD811[\uDC00-\uDE46]|\uD81A[\uDC00-\uDE38\uDE40-\uDE5E\uDE60-\uDE69\uDE70-\uDEBE\uDEC0-\uDEC9\uDED0-\uDEED\uDF00-\uDF2F\uDF40-\uDF43\uDF50-\uDF59\uDF5B-\uDF61\uDF63-\uDF77\uDF7D-\uDF8F]|\uD81B[\uDE40-\uDE96\uDF00-\uDF4A\uDF50\uDF93-\uDF9F\uDFE0\uDFE1\uDFE3]|\uD821[\uDC00-\uDFF7]|\uD823[\uDC00-\uDCD5\uDD00-\uDD08]|\uD82B[\uDFF0-\uDFF3\uDFF5-\uDFFB\uDFFD\uDFFE]|\uD82C[\uDC00-\uDD22\uDD50-\uDD52\uDD64-\uDD67\uDD70-\uDEFB]|\uD82F[\uDC00-\uDC6A\uDC70-\uDC7C\uDC80-\uDC88\uDC90-\uDC99]|\uD834[\uDEE0-\uDEF3\uDF60-\uDF78]|\uD835[\uDC00-\uDC54\uDC56-\uDC9C\uDC9E\uDC9F\uDCA2\uDCA5\uDCA6\uDCA9-\uDCAC\uDCAE-\uDCB9\uDCBB\uDCBD-\uDCC3\uDCC5-\uDD05\uDD07-\uDD0A\uDD0D-\uDD14\uDD16-\uDD1C\uDD1E-\uDD39\uDD3B-\uDD3E\uDD40-\uDD44\uDD46\uDD4A-\uDD50\uDD52-\uDEA5\uDEA8-\uDEC0\uDEC2-\uDEDA\uDEDC-\uDEFA\uDEFC-\uDF14\uDF16-\uDF34\uDF36-\uDF4E\uDF50-\uDF6E\uDF70-\uDF88\uDF8A-\uDFA8\uDFAA-\uDFC2\uDFC4-\uDFCB\uDFCE-\uDFFF]|\uD837[\uDF00-\uDF1E]|\uD838[\uDD00-\uDD2C\uDD37-\uDD3D\uDD40-\uDD49\uDD4E\uDE90-\uDEAD\uDEC0-\uDEEB\uDEF0-\uDEF9]|\uD839[\uDFE0-\uDFE6\uDFE8-\uDFEB\uDFED\uDFEE\uDFF0-\uDFFE]|\uD83A[\uDC00-\uDCC4\uDCC7-\uDCCF\uDD00-\uDD43\uDD4B\uDD50-\uDD59]|\uD83B[\uDC71-\uDCAB\uDCAD-\uDCAF\uDCB1-\uDCB4\uDD01-\uDD2D\uDD2F-\uDD3D\uDE00-\uDE03\uDE05-\uDE1F\uDE21\uDE22\uDE24\uDE27\uDE29-\uDE32\uDE34-\uDE37\uDE39\uDE3B\uDE42\uDE47\uDE49\uDE4B\uDE4D-\uDE4F\uDE51\uDE52\uDE54\uDE57\uDE59\uDE5B\uDE5D\uDE5F\uDE61\uDE62\uDE64\uDE67-\uDE6A\uDE6C-\uDE72\uDE74-\uDE77\uDE79-\uDE7C\uDE7E\uDE80-\uDE89\uDE8B-\uDE9B\uDEA1-\uDEA3\uDEA5-\uDEA9\uDEAB-\uDEBB]|\uD83C[\uDD00-\uDD0C]|\uD83E[\uDFF0-\uDFF9]|\uD869[\uDC00-\uDEDF\uDF00-\uDFFF]|\uD86D[\uDC00-\uDF38\uDF40-\uDFFF]|\uD86E[\uDC00-\uDC1D\uDC20-\uDFFF]|\uD873[\uDC00-\uDEA1\uDEB0-\uDFFF]|\uD87A[\uDC00-\uDFE0]|\uD87E[\uDC00-\uDE1D]|\uD884[\uDC00-\uDF4A])/))){var r=n[1]||n[2]||"";if(!r||""===u||this.rules.inline.punctuation.exec(u)){var i=n[0].length-1,s=i,l=0,a="*"===n[0][0]?this.rules.inline.emStrong.rDelimAst:this.rules.inline.emStrong.rDelimUnd;for(a.lastIndex=0,t=t.slice(-1*e.length+i);null!=(n=a.exec(t));)if(o=n[1]||n[2]||n[3]||n[4]||n[5]||n[6])if(o=o.length,n[3]||n[4])s+=o;else if((n[5]||n[6])&&i%3&&!((i+o)%3))l+=o;else if(!(0<(s-=o))){var o=Math.min(o,o+s+l);if(Math.min(i,o)%2)return D=e.slice(1,i+n.index+o),{type:"em",raw:e.slice(0,i+n.index+o+1),text:D,tokens:this.lexer.inlineTokens(D,[])};var D=e.slice(2,i+n.index+o-1);return{type:"strong",raw:e.slice(0,i+n.index+o+1),text:D,tokens:this.lexer.inlineTokens(D,[])}}}}},t.codespan=function(e){var t,u,n,e=this.rules.inline.code.exec(e);if(e)return n=e[2].replace(/\n/g," "),t=/[^ ]/.test(n),u=/^ /.test(n)&&/ $/.test(n),n=D(n=t&&u?n.substring(1,n.length-1):n,!0),{type:"codespan",raw:e[0],text:n}},t.br=function(e){e=this.rules.inline.br.exec(e);if(e)return{type:"br",raw:e[0]}},t.del=function(e){e=this.rules.inline.del.exec(e);if(e)return{type:"del",raw:e[0],text:e[2],tokens:this.lexer.inlineTokens(e[2],[])}},t.autolink=function(e,t){var u,e=this.rules.inline.autolink.exec(e);if(e)return t="@"===e[2]?"mailto:"+(u=D(this.options.mangle?t(e[1]):e[1])):u=D(e[1]),{type:"link",raw:e[0],text:u,href:t,tokens:[{type:"text",raw:u,text:u}]}},t.url=function(e,t){var u,n,r,i;if(u=this.rules.inline.url.exec(e)){if("@"===u[2])r="mailto:"+(n=D(this.options.mangle?t(u[0]):u[0]));else{for(;i=u[0],u[0]=this.rules.inline._backpedal.exec(u[0])[0],i!==u[0];);n=D(u[0]),r="www."===u[1]?"http://"+n:n}return{type:"link",raw:u[0],text:n,href:r,tokens:[{type:"text",raw:n,text:n}]}}},t.inlineText=function(e,t){e=this.rules.inline.text.exec(e);if(e)return t=this.lexer.state.inRawBlock?this.options.sanitize?this.options.sanitizer?this.options.sanitizer(e[0]):D(e[0]):e[0]:D(this.options.smartypants?t(e[0]):e[0]),{type:"text",raw:e[0],text:t}},e}(),y={newline:/^(?: *(?:\n|$))+/,code:/^( {4}[^\n]+(?:\n(?: *(?:\n|$))*)?)+/,fences:/^ {0,3}(`{3,}(?=[^`\n]*\n)|~{3,})([^\n]*)\n(?:|([\s\S]*?)\n)(?: {0,3}\1[~`]* *(?=\n|$)|$)/,hr:/^ {0,3}((?:-[\t ]*){3,}|(?:_[ \t]*){3,}|(?:\*[ \t]*){3,})(?:\n+|$)/,heading:/^ {0,3}(#{1,6})(?=\s|$)(.*)(?:\n+|$)/,blockquote:/^( {0,3}> ?(paragraph|[^\n]*)(?:\n|$))+/,list:/^( {0,3}bull)([ \t][^\n]+?)?(?:\n|$)/,html:"^ {0,3}(?:<(script|pre|style|textarea)[\\s>][\\s\\S]*?(?:</\\1>[^\\n]*\\n+|$)|comment[^\\n]*(\\n+|$)|<\\?[\\s\\S]*?(?:\\?>\\n*|$)|<![A-Z][\\s\\S]*?(?:>\\n*|$)|<!\\[CDATA\\[[\\s\\S]*?(?:\\]\\]>\\n*|$)|</?(tag)(?: +|\\n|/?>)[\\s\\S]*?(?:(?:\\n *)+\\n|$)|<(?!script|pre|style|textarea)([a-z][\\w-]*)(?:attribute)*? */?>(?=[ \\t]*(?:\\n|$))[\\s\\S]*?(?:(?:\\n *)+\\n|$)|</(?!script|pre|style|textarea)[a-z][\\w-]*\\s*>(?=[ \\t]*(?:\\n|$))[\\s\\S]*?(?:(?:\\n *)+\\n|$))",def:/^ {0,3}\[(label)\]: *(?:\n *)?<?([^\s>]+)>?(?:(?: +(?:\n *)?| *\n *)(title))? *(?:\n+|$)/,table:A,lheading:/^([^\n]+)\n {0,3}(=+|-+) *(?:\n+|$)/,_paragraph:/^([^\n]+(?:\n(?!hr|heading|lheading|blockquote|fences|list|html|table| +\n)[^\n]+)*)/,text:/^[^\n]+/,_label:/(?!\s*\])(?:\\.|[^\[\]\\])+/,_title:/(?:"(?:\\"?|[^"\\])*"|'[^'\n]*(?:\n[^'\n]+)*\n?'|\([^()]*\))/},v=(y.def=p(y.def).replace("label",y._label).replace("title",y._title).getRegex(),y.bullet=/(?:[*+-]|\d{1,9}[.)])/,y.listItemStart=p(/^( *)(bull) */).replace("bull",y.bullet).getRegex(),y.list=p(y.list).replace(/bull/g,y.bullet).replace("hr","\\n+(?=\\1?(?:(?:- *){3,}|(?:_ *){3,}|(?:\\* *){3,})(?:\\n+|$))").replace("def","\\n+(?="+y.def.source+")").getRegex(),y._tag="address|article|aside|base|basefont|blockquote|body|caption|center|col|colgroup|dd|details|dialog|dir|div|dl|dt|fieldset|figcaption|figure|footer|form|frame|frameset|h[1-6]|head|header|hr|html|iframe|legend|li|link|main|menu|menuitem|meta|nav|noframes|ol|optgroup|option|p|param|section|source|summary|table|tbody|td|tfoot|th|thead|title|tr|track|ul",y._comment=/<!--(?!-?>)[\s\S]*?(?:-->|$)/,y.html=p(y.html,"i").replace("comment",y._comment).replace("tag",y._tag).replace("attribute",/ +[a-zA-Z:_][\w.:-]*(?: *= *"[^"\n]*"| *= *'[^'\n]*'| *= *[^\s"'=<>`]+)?/).getRegex(),y.paragraph=p(y._paragraph).replace("hr",y.hr).replace("heading"," {0,3}#{1,6} ").replace("|lheading","").replace("|table","").replace("blockquote"," {0,3}>").replace("fences"," {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list"," {0,3}(?:[*+-]|1[.)]) ").replace("html","</?(?:tag)(?: +|\\n|/?>)|<(?:script|pre|style|textarea|!--)").replace("tag",y._tag).getRegex(),y.blockquote=p(y.blockquote).replace("paragraph",y.paragraph).getRegex(),y.normal=d({},y),y.gfm=d({},y.normal,{table:"^ *([^\\n ].*\\|.*)\\n {0,3}(?:\\| *)?(:?-+:? *(?:\\| *:?-+:? *)*)(?:\\| *)?(?:\\n((?:(?! *\\n|hr|heading|blockquote|code|fences|list|html).*(?:\\n|$))*)\\n*|$)"}),y.gfm.table=p(y.gfm.table).replace("hr",y.hr).replace("heading"," {0,3}#{1,6} ").replace("blockquote"," {0,3}>").replace("code"," {4}[^\\n]").replace("fences"," {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list"," {0,3}(?:[*+-]|1[.)]) ").replace("html","</?(?:tag)(?: +|\\n|/?>)|<(?:script|pre|style|textarea|!--)").replace("tag",y._tag).getRegex(),y.gfm.paragraph=p(y._paragraph).replace("hr",y.hr).replace("heading"," {0,3}#{1,6} ").replace("|lheading","").replace("table",y.gfm.table).replace("blockquote"," {0,3}>").replace("fences"," {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list"," {0,3}(?:[*+-]|1[.)]) ").replace("html","</?(?:tag)(?: +|\\n|/?>)|<(?:script|pre|style|textarea|!--)").replace("tag",y._tag).getRegex(),y.pedantic=d({},y.normal,{html:p("^ *(?:comment *(?:\\n|\\s*$)|<(tag)[\\s\\S]+?</\\1> *(?:\\n{2,}|\\s*$)|<tag(?:\"[^\"]*\"|'[^']*'|\\s[^'\"/>\\s]*)*?/?> *(?:\\n{2,}|\\s*$))").replace("comment",y._comment).replace(/tag/g,"(?!(?:a|em|strong|small|s|cite|q|dfn|abbr|data|time|code|var|samp|kbd|sub|sup|i|b|u|mark|ruby|rt|rp|bdi|bdo|span|br|wbr|ins|del|img)\\b)\\w+(?!:|[^\\w\\s@]*@)\\b").getRegex(),def:/^ *\[([^\]]+)\]: *<?([^\s>]+)>?(?: +(["(][^\n]+[")]))? *(?:\n+|$)/,heading:/^(#{1,6})(.*)(?:\n+|$)/,fences:A,paragraph:p(y.normal._paragraph).replace("hr",y.hr).replace("heading"," *#{1,6} *[^\n]").replace("lheading",y.lheading).replace("blockquote"," {0,3}>").replace("|fences","").replace("|list","").replace("|html","").getRegex()}),{escape:/^\\([!"#$%&'()*+,\-./:;<=>?@\[\]\\^_`{|}~])/,autolink:/^<(scheme:[^\s\x00-\x1f<>]*|email)>/,url:A,tag:"^comment|^</[a-zA-Z][\\w:-]*\\s*>|^<[a-zA-Z][\\w-]*(?:attribute)*?\\s*/?>|^<\\?[\\s\\S]*?\\?>|^<![a-zA-Z]+\\s[\\s\\S]*?>|^<!\\[CDATA\\[[\\s\\S]*?\\]\\]>",link:/^!?\[(label)\]\(\s*(href)(?:\s+(title))?\s*\)/,reflink:/^!?\[(label)\]\[(ref)\]/,nolink:/^!?\[(ref)\](?:\[\])?/,reflinkSearch:"reflink|nolink(?!\\()",emStrong:{lDelim:/^(?:\*+(?:([punct_])|[^\s*]))|^_+(?:([punct*])|([^\s_]))/,rDelimAst:/^[^_*]*?\_\_[^_*]*?\*[^_*]*?(?=\_\_)|[^*]+(?=[^*])|[punct_](\*+)(?=[\s]|$)|[^punct*_\s](\*+)(?=[punct_\s]|$)|[punct_\s](\*+)(?=[^punct*_\s])|[\s](\*+)(?=[punct_])|[punct_](\*+)(?=[punct_])|[^punct*_\s](\*+)(?=[^punct*_\s])/,rDelimUnd:/^[^_*]*?\*\*[^_*]*?\_[^_*]*?(?=\*\*)|[^_]+(?=[^_])|[punct*](\_+)(?=[\s]|$)|[^punct*_\s](\_+)(?=[punct*\s]|$)|[punct*\s](\_+)(?=[^punct*_\s])|[\s](\_+)(?=[punct*])|[punct*](\_+)(?=[punct*])/},code:/^(`+)([^`]|[^`][\s\S]*?[^`])\1(?!`)/,br:/^( {2,}|\\)\n(?!\s*$)/,del:A,text:/^(`+|[^`])(?:(?= {2,}\n)|[\s\S]*?(?:(?=[\\<!\[`*_]|\b_|$)|[^ ](?= {2,}\n)))/,punctuation:/^([\spunctuation])/});function j(e){return e.replace(/---/g,"—").replace(/--/g,"–").replace(/(^|[-\u2014/(\[{"\s])'/g,"$1‘").replace(/'/g,"’").replace(/(^|[-\u2014/(\[{\u2018\s])"/g,"$1“").replace(/"/g,"”").replace(/\.{3}/g,"…")}function _(e){for(var t,u="",n=e.length,r=0;r<n;r++)t=e.charCodeAt(r),u+="&#"+(t=.5<Math.random()?"x"+t.toString(16):t)+";";return u}v._punctuation="!\"#$%&'()+\\-.,/:;<=>?@\\[\\]`^{|}~",v.punctuation=p(v.punctuation).replace(/punctuation/g,v._punctuation).getRegex(),v.blockSkip=/\[[^\]]*?\]\([^\)]*?\)|`[^`]*?`|<[^>]*?>/g,v.escapedEmSt=/\\\*|\\_/g,v._comment=p(y._comment).replace("(?:--\x3e|$)","--\x3e").getRegex(),v.emStrong.lDelim=p(v.emStrong.lDelim).replace(/punct/g,v._punctuation).getRegex(),v.emStrong.rDelimAst=p(v.emStrong.rDelimAst,"g").replace(/punct/g,v._punctuation).getRegex(),v.emStrong.rDelimUnd=p(v.emStrong.rDelimUnd,"g").replace(/punct/g,v._punctuation).getRegex(),v._escapes=/\\([!"#$%&'()*+,\-./:;<=>?@\[\]\\^_`{|}~])/g,v._scheme=/[a-zA-Z][a-zA-Z0-9+.-]{1,31}/,v._email=/[a-zA-Z0-9.!#$%&'*+/=?^_`{|}~-]+(@)[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?(?:\.[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?)+(?![-_])/,v.autolink=p(v.autolink).replace("scheme",v._scheme).replace("email",v._email).getRegex(),v._attribute=/\s+[a-zA-Z:_][\w.:-]*(?:\s*=\s*"[^"]*"|\s*=\s*'[^']*'|\s*=\s*[^\s"'=<>`]+)?/,v.tag=p(v.tag).replace("comment",v._comment).replace("attribute",v._attribute).getRegex(),v._label=/(?:\[(?:\\.|[^\[\]\\])*\]|\\.|`[^`]*`|[^\[\]\\`])*?/,v._href=/<(?:\\.|[^\n<>\\])+>|[^\s\x00-\x1f]*/,v._title=/"(?:\\"?|[^"\\])*"|'(?:\\'?|[^'\\])*'|\((?:\\\)?|[^)\\])*\)/,v.link=p(v.link).replace("label",v._label).replace("href",v._href).replace("title",v._title).getRegex(),v.reflink=p(v.reflink).replace("label",v._label).replace("ref",y._label).getRegex(),v.nolink=p(v.nolink).replace("ref",y._label).getRegex(),v.reflinkSearch=p(v.reflinkSearch,"g").replace("reflink",v.reflink).replace("nolink",v.nolink).getRegex(),v.normal=d({},v),v.pedantic=d({},v.normal,{strong:{start:/^__|\*\*/,middle:/^__(?=\S)([\s\S]*?\S)__(?!_)|^\*\*(?=\S)([\s\S]*?\S)\*\*(?!\*)/,endAst:/\*\*(?!\*)/g,endUnd:/__(?!_)/g},em:{start:/^_|\*/,middle:/^()\*(?=\S)([\s\S]*?\S)\*(?!\*)|^_(?=\S)([\s\S]*?\S)_(?!_)/,endAst:/\*(?!\*)/g,endUnd:/_(?!_)/g},link:p(/^!?\[(label)\]\((.*?)\)/).replace("label",v._label).getRegex(),reflink:p(/^!?\[(label)\]\s*\[([^\]]*)\]/).replace("label",v._label).getRegex()}),v.gfm=d({},v.normal,{escape:p(v.escape).replace("])","~|])").getRegex(),_extended_email:/[A-Za-z0-9._+-]+(@)[a-zA-Z0-9-_]+(?:\.[a-zA-Z0-9-_]*[a-zA-Z0-9])+(?![-_])/,url:/^((?:ftp|https?):\/\/|www\.)(?:[a-zA-Z0-9\-]+\.?)+[^\s<]*|^email/,_backpedal:/(?:[^?!.,:;*_~()&]+|\([^)]*\)|&(?![a-zA-Z0-9]+;$)|[?!.,:;*_~)]+(?!$))+/,del:/^(~~?)(?=[^\s~])([\s\S]*?[^\s~])\1(?=[^~]|$)/,text:/^([`~]+|[^`~])(?:(?= {2,}\n)|(?=[a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-]+@)|[\s\S]*?(?:(?=[\\<!\[`*~_]|\b_|https?:\/\/|ftp:\/\/|www\.|$)|[^ ](?= {2,}\n)|[^a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-](?=[a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-]+@)))/}),v.gfm.url=p(v.gfm.url,"i").replace("email",v.gfm._extended_email).getRegex(),v.breaks=d({},v.gfm,{br:p(v.br).replace("{2,}","*").getRegex(),text:p(v.gfm.text).replace("\\b_","\\b_| {2,}\\n").replace(/\{2,\}/g,"*").getRegex()});var z=function(){function u(e){this.tokens=[],this.tokens.links=Object.create(null),this.options=e||r.defaults,this.options.tokenizer=this.options.tokenizer||new w,this.tokenizer=this.options.tokenizer,this.tokenizer.options=this.options,(this.tokenizer.lexer=this).inlineQueue=[],this.state={inLink:!1,inRawBlock:!1,top:!0};e={block:y.normal,inline:v.normal};this.options.pedantic?(e.block=y.pedantic,e.inline=v.pedantic):this.options.gfm&&(e.block=y.gfm,this.options.breaks?e.inline=v.breaks:e.inline=v.gfm),this.tokenizer.rules=e}u.lex=function(e,t){return new u(t).lex(e)},u.lexInline=function(e,t){return new u(t).inlineTokens(e)};var e,t,n=u.prototype;return n.lex=function(e){var t;for(e=e.replace(/\r\n|\r/g,"\n"),this.blockTokens(e,this.tokens);t=this.inlineQueue.shift();)this.inlineTokens(t.src,t.tokens);return this.tokens},n.blockTokens=function(r,t){var u,e,i,n,s=this;for(void 0===t&&(t=[]),r=this.options.pedantic?r.replace(/\t/g," ").replace(/^ +$/gm,""):r.replace(/^( *)(\t+)/gm,function(e,t,u){return t+" ".repeat(u.length)});r;)if(!(this.options.extensions&&this.options.extensions.block&&this.options.extensions.block.some(function(e){return!!(u=e.call({lexer:s},r,t))&&(r=r.substring(u.raw.length),t.push(u),!0)})))if(u=this.tokenizer.space(r))r=r.substring(u.raw.length),1===u.raw.length&&0<t.length?t[t.length-1].raw+="\n":t.push(u);else if(u=this.tokenizer.code(r))r=r.substring(u.raw.length),!(e=t[t.length-1])||"paragraph"!==e.type&&"text"!==e.type?t.push(u):(e.raw+="\n"+u.raw,e.text+="\n"+u.text,this.inlineQueue[this.inlineQueue.length-1].src=e.text);else if(u=this.tokenizer.fences(r))r=r.substring(u.raw.length),t.push(u);else if(u=this.tokenizer.heading(r))r=r.substring(u.raw.length),t.push(u);else if(u=this.tokenizer.hr(r))r=r.substring(u.raw.length),t.push(u);else if(u=this.tokenizer.blockquote(r))r=r.substring(u.raw.length),t.push(u);else if(u=this.tokenizer.list(r))r=r.substring(u.raw.length),t.push(u);else if(u=this.tokenizer.html(r))r=r.substring(u.raw.length),t.push(u);else if(u=this.tokenizer.def(r))r=r.substring(u.raw.length),!(e=t[t.length-1])||"paragraph"!==e.type&&"text"!==e.type?this.tokens.links[u.tag]||(this.tokens.links[u.tag]={href:u.href,title:u.title}):(e.raw+="\n"+u.raw,e.text+="\n"+u.raw,this.inlineQueue[this.inlineQueue.length-1].src=e.text);else if(u=this.tokenizer.table(r))r=r.substring(u.raw.length),t.push(u);else if(u=this.tokenizer.lheading(r))r=r.substring(u.raw.length),t.push(u);else if(i=r,this.options.extensions&&this.options.extensions.startBlock&&!function(){var t=1/0,u=r.slice(1),n=void 0;s.options.extensions.startBlock.forEach(function(e){"number"==typeof(n=e.call({lexer:this},u))&&0<=n&&(t=Math.min(t,n))}),t<1/0&&0<=t&&(i=r.substring(0,t+1))}(),this.state.top&&(u=this.tokenizer.paragraph(i)))e=t[t.length-1],n&&"paragraph"===e.type?(e.raw+="\n"+u.raw,e.text+="\n"+u.text,this.inlineQueue.pop(),this.inlineQueue[this.inlineQueue.length-1].src=e.text):t.push(u),n=i.length!==r.length,r=r.substring(u.raw.length);else if(u=this.tokenizer.text(r))r=r.substring(u.raw.length),(e=t[t.length-1])&&"text"===e.type?(e.raw+="\n"+u.raw,e.text+="\n"+u.text,this.inlineQueue.pop(),this.inlineQueue[this.inlineQueue.length-1].src=e.text):t.push(u);else if(r){var l="Infinite loop on byte: "+r.charCodeAt(0);if(this.options.silent){console.error(l);break}throw new Error(l)}return this.state.top=!0,t},n.inline=function(e,t){this.inlineQueue.push({src:e,tokens:t})},n.inlineTokens=function(r,t){var u,e,i,n,s,l,a=this,o=(void 0===t&&(t=[]),r);if(this.tokens.links){var D=Object.keys(this.tokens.links);if(0<D.length)for(;null!=(n=this.tokenizer.rules.inline.reflinkSearch.exec(o));)D.includes(n[0].slice(n[0].lastIndexOf("[")+1,-1))&&(o=o.slice(0,n.index)+"["+m("a",n[0].length-2)+"]"+o.slice(this.tokenizer.rules.inline.reflinkSearch.lastIndex))}for(;null!=(n=this.tokenizer.rules.inline.blockSkip.exec(o));)o=o.slice(0,n.index)+"["+m("a",n[0].length-2)+"]"+o.slice(this.tokenizer.rules.inline.blockSkip.lastIndex);for(;null!=(n=this.tokenizer.rules.inline.escapedEmSt.exec(o));)o=o.slice(0,n.index)+"++"+o.slice(this.tokenizer.rules.inline.escapedEmSt.lastIndex);for(;r;)if(s||(l=""),s=!1,!(this.options.extensions&&this.options.extensions.inline&&this.options.extensions.inline.some(function(e){return!!(u=e.call({lexer:a},r,t))&&(r=r.substring(u.raw.length),t.push(u),!0)})))if(u=this.tokenizer.escape(r))r=r.substring(u.raw.length),t.push(u);else if(u=this.tokenizer.tag(r))r=r.substring(u.raw.length),(e=t[t.length-1])&&"text"===u.type&&"text"===e.type?(e.raw+=u.raw,e.text+=u.text):t.push(u);else if(u=this.tokenizer.link(r))r=r.substring(u.raw.length),t.push(u);else if(u=this.tokenizer.reflink(r,this.tokens.links))r=r.substring(u.raw.length),(e=t[t.length-1])&&"text"===u.type&&"text"===e.type?(e.raw+=u.raw,e.text+=u.text):t.push(u);else if(u=this.tokenizer.emStrong(r,o,l))r=r.substring(u.raw.length),t.push(u);else if(u=this.tokenizer.codespan(r))r=r.substring(u.raw.length),t.push(u);else if(u=this.tokenizer.br(r))r=r.substring(u.raw.length),t.push(u);else if(u=this.tokenizer.del(r))r=r.substring(u.raw.length),t.push(u);else if(u=this.tokenizer.autolink(r,_))r=r.substring(u.raw.length),t.push(u);else if(!this.state.inLink&&(u=this.tokenizer.url(r,_)))r=r.substring(u.raw.length),t.push(u);else if(i=r,this.options.extensions&&this.options.extensions.startInline&&!function(){var t=1/0,u=r.slice(1),n=void 0;a.options.extensions.startInline.forEach(function(e){"number"==typeof(n=e.call({lexer:this},u))&&0<=n&&(t=Math.min(t,n))}),t<1/0&&0<=t&&(i=r.substring(0,t+1))}(),u=this.tokenizer.inlineText(i,j))r=r.substring(u.raw.length),"_"!==u.raw.slice(-1)&&(l=u.raw.slice(-1)),s=!0,(e=t[t.length-1])&&"text"===e.type?(e.raw+=u.raw,e.text+=u.text):t.push(u);else if(r){var c="Infinite loop on byte: "+r.charCodeAt(0);if(this.options.silent){console.error(c);break}throw new Error(c)}return t},n=u,t=[{key:"rules",get:function(){return{block:y,inline:v}}}],(e=null)&&i(n.prototype,e),t&&i(n,t),Object.defineProperty(n,"prototype",{writable:!1}),u}(),$=function(){function e(e){this.options=e||r.defaults}var t=e.prototype;return t.code=function(e,t,u){var n,t=(t||"").match(/\S*/)[0];return this.options.highlight&&null!=(n=this.options.highlight(e,t))&&n!==e&&(u=!0,e=n),e=e.replace(/\n$/,"")+"\n",t?'<pre><code class="'+this.options.langPrefix+D(t,!0)+'">'+(u?e:D(e,!0))+"</code></pre>\n":"<pre><code>"+(u?e:D(e,!0))+"</code></pre>\n"},t.blockquote=function(e){return"<blockquote>\n"+e+"</blockquote>\n"},t.html=function(e){return e},t.heading=function(e,t,u,n){return this.options.headerIds?"<h"+t+' id="'+(this.options.headerPrefix+n.slug(u))+'">'+e+"</h"+t+">\n":"<h"+t+">"+e+"</h"+t+">\n"},t.hr=function(){return this.options.xhtml?"<hr/>\n":"<hr>\n"},t.list=function(e,t,u){var n=t?"ol":"ul";return"<"+n+(t&&1!==u?' start="'+u+'"':"")+">\n"+e+"</"+n+">\n"},t.listitem=function(e){return"<li>"+e+"</li>\n"},t.checkbox=function(e){return"<input "+(e?'checked="" ':"")+'disabled="" type="checkbox"'+(this.options.xhtml?" /":"")+"> "},t.paragraph=function(e){return"<p>"+e+"</p>\n"},t.table=function(e,t){return"<table>\n<thead>\n"+e+"</thead>\n"+(t=t&&"<tbody>"+t+"</tbody>")+"</table>\n"},t.tablerow=function(e){return"<tr>\n"+e+"</tr>\n"},t.tablecell=function(e,t){var u=t.header?"th":"td";return(t.align?"<"+u+' align="'+t.align+'">':"<"+u+">")+e+"</"+u+">\n"},t.strong=function(e){return"<strong>"+e+"</strong>"},t.em=function(e){return"<em>"+e+"</em>"},t.codespan=function(e){return"<code>"+e+"</code>"},t.br=function(){return this.options.xhtml?"<br/>":"<br>"},t.del=function(e){return"<del>"+e+"</del>"},t.link=function(e,t,u){if(null===(e=g(this.options.sanitize,this.options.baseUrl,e)))return u;e='<a href="'+D(e)+'"';return t&&(e+=' title="'+t+'"'),e+=">"+u+"</a>"},t.image=function(e,t,u){if(null===(e=g(this.options.sanitize,this.options.baseUrl,e)))return u;e='<img src="'+e+'" alt="'+u+'"';return t&&(e+=' title="'+t+'"'),e+=this.options.xhtml?"/>":">"},t.text=function(e){return e},e}(),S=function(){function e(){}var t=e.prototype;return t.strong=function(e){return e},t.em=function(e){return e},t.codespan=function(e){return e},t.del=function(e){return e},t.html=function(e){return e},t.text=function(e){return e},t.link=function(e,t,u){return""+u},t.image=function(e,t,u){return""+u},t.br=function(){return""},e}(),T=function(){function e(){this.seen={}}var t=e.prototype;return t.serialize=function(e){return e.toLowerCase().trim().replace(/<[!\/a-z].*?>/gi,"").replace(/[\u2000-\u206F\u2E00-\u2E7F\\'!"#$%&()*+,./:;<=>?@[\]^`{|}~]/g,"").replace(/\s/g,"-")},t.getNextSafeSlug=function(e,t){var u=e,n=0;if(this.seen.hasOwnProperty(u))for(n=this.seen[e];u=e+"-"+ ++n,this.seen.hasOwnProperty(u););return t||(this.seen[e]=n,this.seen[u]=0),u},t.slug=function(e,t){void 0===t&&(t={});e=this.serialize(e);return this.getNextSafeSlug(e,t.dryrun)},e}(),R=function(){function u(e){this.options=e||r.defaults,this.options.renderer=this.options.renderer||new $,this.renderer=this.options.renderer,this.renderer.options=this.options,this.textRenderer=new S,this.slugger=new T}u.parse=function(e,t){return new u(t).parse(e)},u.parseInline=function(e,t){return new u(t).parseInline(e)};var e=u.prototype;return e.parse=function(e,t){void 0===t&&(t=!0);for(var u,n,r,i,s,l,a,o,D,c,h,p,f,g,F,A,d="",C=e.length,k=0;k<C;k++)if(o=e[k],this.options.extensions&&this.options.extensions.renderers&&this.options.extensions.renderers[o.type]&&(!1!==(A=this.options.extensions.renderers[o.type].call({parser:this},o))||!["space","hr","heading","code","table","blockquote","list","html","paragraph","text"].includes(o.type)))d+=A||"";else switch(o.type){case"space":continue;case"hr":d+=this.renderer.hr();continue;case"heading":d+=this.renderer.heading(this.parseInline(o.tokens),o.depth,x(this.parseInline(o.tokens,this.textRenderer)),this.slugger);continue;case"code":d+=this.renderer.code(o.text,o.lang,o.escaped);continue;case"table":for(l=D="",r=o.header.length,u=0;u<r;u++)l+=this.renderer.tablecell(this.parseInline(o.header[u].tokens),{header:!0,align:o.align[u]});for(D+=this.renderer.tablerow(l),a="",r=o.rows.length,u=0;u<r;u++){for(l="",i=(s=o.rows[u]).length,n=0;n<i;n++)l+=this.renderer.tablecell(this.parseInline(s[n].tokens),{header:!1,align:o.align[n]});a+=this.renderer.tablerow(l)}d+=this.renderer.table(D,a);continue;case"blockquote":a=this.parse(o.tokens),d+=this.renderer.blockquote(a);continue;case"list":for(D=o.ordered,E=o.start,c=o.loose,r=o.items.length,a="",u=0;u<r;u++)f=(p=o.items[u]).checked,g=p.task,h="",p.task&&(F=this.renderer.checkbox(f),c?0<p.tokens.length&&"paragraph"===p.tokens[0].type?(p.tokens[0].text=F+" "+p.tokens[0].text,p.tokens[0].tokens&&0<p.tokens[0].tokens.length&&"text"===p.tokens[0].tokens[0].type&&(p.tokens[0].tokens[0].text=F+" "+p.tokens[0].tokens[0].text)):p.tokens.unshift({type:"text",text:F}):h+=F),h+=this.parse(p.tokens,c),a+=this.renderer.listitem(h,g,f);d+=this.renderer.list(a,D,E);continue;case"html":d+=this.renderer.html(o.text);continue;case"paragraph":d+=this.renderer.paragraph(this.parseInline(o.tokens));continue;case"text":for(a=o.tokens?this.parseInline(o.tokens):o.text;k+1<C&&"text"===e[k+1].type;)a+="\n"+((o=e[++k]).tokens?this.parseInline(o.tokens):o.text);d+=t?this.renderer.paragraph(a):a;continue;default:var E='Token with "'+o.type+'" type was not found.';if(this.options.silent)return void console.error(E);throw new Error(E)}return d},e.parseInline=function(e,t){t=t||this.renderer;for(var u,n,r="",i=e.length,s=0;s<i;s++)if(u=e[s],this.options.extensions&&this.options.extensions.renderers&&this.options.extensions.renderers[u.type]&&(!1!==(n=this.options.extensions.renderers[u.type].call({parser:this},u))||!["escape","html","link","image","strong","em","codespan","br","del","text"].includes(u.type)))r+=n||"";else switch(u.type){case"escape":r+=t.text(u.text);break;case"html":r+=t.html(u.text);break;case"link":r+=t.link(u.href,u.title,this.parseInline(u.tokens,t));break;case"image":r+=t.image(u.href,u.title,u.text);break;case"strong":r+=t.strong(this.parseInline(u.tokens,t));break;case"em":r+=t.em(this.parseInline(u.tokens,t));break;case"codespan":r+=t.codespan(u.text);break;case"br":r+=t.br();break;case"del":r+=t.del(this.parseInline(u.tokens,t));break;case"text":r+=t.text(u.text);break;default:var l='Token with "'+u.type+'" type was not found.';if(this.options.silent)return void console.error(l);throw new Error(l)}return r},u}();function I(e,u,n){if(null==e)throw new Error("marked(): input parameter is undefined or null");if("string"!=typeof e)throw new Error("marked(): input parameter is of type "+Object.prototype.toString.call(e)+", string expected");if("function"==typeof u&&(n=u,u=null),E(u=d({},I.defaults,u||{})),n){var r,i=u.highlight;try{r=z.lex(e,u)}catch(e){return n(e)}var s=function(t){var e;if(!t)try{u.walkTokens&&I.walkTokens(r,u.walkTokens),e=R.parse(r,u)}catch(e){t=e}return u.highlight=i,t?n(t):n(null,e)};if(!i||i.length<3)return s();if(delete u.highlight,!r.length)return s();var l=0;return I.walkTokens(r,function(u){"code"===u.type&&(l++,setTimeout(function(){i(u.text,u.lang,function(e,t){if(e)return s(e);null!=t&&t!==u.text&&(u.text=t,u.escaped=!0),0===--l&&s()})},0))}),void(0===l&&s())}try{var t=z.lex(e,u);return u.walkTokens&&I.walkTokens(t,u.walkTokens),R.parse(t,u)}catch(e){if(e.message+="\nPlease report this to https://github.com/markedjs/marked.",u.silent)return"<p>An error occurred:</p><pre>"+D(e.message+"",!0)+"</pre>";throw e}}I.options=I.setOptions=function(e){return d(I.defaults,e),e=I.defaults,r.defaults=e,I},I.getDefaults=e,I.defaults=r.defaults,I.use=function(){for(var e=arguments.length,t=new Array(e),u=0;u<e;u++)t[u]=arguments[u];var n,r=d.apply(void 0,[{}].concat(t)),o=I.defaults.extensions||{renderers:{},childTokens:{}};t.forEach(function(s){if(s.extensions&&(n=!0,s.extensions.forEach(function(r){if(!r.name)throw new Error("extension name required");var i;if(r.renderer&&(i=o.renderers?o.renderers[r.name]:null,o.renderers[r.name]=i?function(){for(var e=arguments.length,t=new Array(e),u=0;u<e;u++)t[u]=arguments[u];var n=r.renderer.apply(this,t);return n=!1===n?i.apply(this,t):n}:r.renderer),r.tokenizer){if(!r.level||"block"!==r.level&&"inline"!==r.level)throw new Error("extension level must be 'block' or 'inline'");o[r.level]?o[r.level].unshift(r.tokenizer):o[r.level]=[r.tokenizer],r.start&&("block"===r.level?o.startBlock?o.startBlock.push(r.start):o.startBlock=[r.start]:"inline"===r.level&&(o.startInline?o.startInline.push(r.start):o.startInline=[r.start]))}r.childTokens&&(o.childTokens[r.name]=r.childTokens)})),s.renderer){var e,l=I.defaults.renderer||new $;for(e in s.renderer)!function(r){var i=l[r];l[r]=function(){for(var e=arguments.length,t=new Array(e),u=0;u<e;u++)t[u]=arguments[u];var n=s.renderer[r].apply(l,t);return n=!1===n?i.apply(l,t):n}}(e);r.renderer=l}if(s.tokenizer){var t,a=I.defaults.tokenizer||new w;for(t in s.tokenizer)!function(r){var i=a[r];a[r]=function(){for(var e=arguments.length,t=new Array(e),u=0;u<e;u++)t[u]=arguments[u];var n=s.tokenizer[r].apply(a,t);return n=!1===n?i.apply(a,t):n}}(t);r.tokenizer=a}var u;s.walkTokens&&(u=I.defaults.walkTokens,r.walkTokens=function(e){s.walkTokens.call(this,e),u&&u.call(this,e)}),n&&(r.extensions=o),I.setOptions(r)})},I.walkTokens=function(e,l){for(var a,t=B(e);!(a=t()).done;)!function(){var t=a.value;switch(l.call(I,t),t.type){case"table":for(var e=B(t.header);!(u=e()).done;){var u=u.value;I.walkTokens(u.tokens,l)}for(var n,r=B(t.rows);!(n=r()).done;)for(var i=B(n.value);!(s=i()).done;){var s=s.value;I.walkTokens(s.tokens,l)}break;case"list":I.walkTokens(t.items,l);break;default:I.defaults.extensions&&I.defaults.extensions.childTokens&&I.defaults.extensions.childTokens[t.type]?I.defaults.extensions.childTokens[t.type].forEach(function(e){I.walkTokens(t[e],l)}):t.tokens&&I.walkTokens(t.tokens,l)}}()},I.parseInline=function(e,t){if(null==e)throw new Error("marked.parseInline(): input parameter is undefined or null");if("string"!=typeof e)throw new Error("marked.parseInline(): input parameter is of type "+Object.prototype.toString.call(e)+", string expected");E(t=d({},I.defaults,t||{}));try{var u=z.lexInline(e,t);return t.walkTokens&&I.walkTokens(u,t.walkTokens),R.parseInline(u,t)}catch(e){if(e.message+="\nPlease report this to https://github.com/markedjs/marked.",t.silent)return"<p>An error occurred:</p><pre>"+D(e.message+"",!0)+"</pre>";throw e}},I.Parser=R,I.parser=R.parse,I.Renderer=$,I.TextRenderer=S,I.Lexer=z,I.lexer=z.lex,I.Tokenizer=w,I.Slugger=T;var A=(I.parse=I).options,P=I.setOptions,Q=I.use,U=I.walkTokens,M=I.parseInline,N=I,X=R.parse,G=z.lex;r.Lexer=z,r.Parser=R,r.Renderer=$,r.Slugger=T,r.TextRenderer=S,r.Tokenizer=w,r.getDefaults=e,r.lexer=G,r.marked=I,r.options=A,r.parse=N,r.parseInline=M,r.parser=X,r.setOptions=P,r.use=Q,r.walkTokens=U,Object.defineProperty(r,"__esModule",{value:!0})});;/*! @license DOMPurify 2.3.10 | (c) Cure53 and other contributors | Released under the Apache license 2.0 and Mozilla Public License 2.0 | github.com/cure53/DOMPurify/blob/2.3.10/LICENSE */ +!function(e,t){"object"==typeof exports&&"undefined"!=typeof module?module.exports=t():"function"==typeof define&&define.amd?define(t):(e="undefined"!=typeof globalThis?globalThis:e||self).DOMPurify=t()}(this,(function(){"use strict";function e(t){return(e="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(t)}function t(e,n){return(t=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,n)}function n(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}function r(e,o,a){return(r=n()?Reflect.construct:function(e,n,r){var o=[null];o.push.apply(o,n);var a=new(Function.bind.apply(e,o));return r&&t(a,r.prototype),a}).apply(null,arguments)}function o(e){return function(e){if(Array.isArray(e))return a(e)}(e)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||function(e,t){if(!e)return;if("string"==typeof e)return a(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);"Object"===n&&e.constructor&&(n=e.constructor.name);if("Map"===n||"Set"===n)return Array.from(e);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return a(e,t)}(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function a(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}var i=Object.hasOwnProperty,l=Object.setPrototypeOf,c=Object.isFrozen,u=Object.getPrototypeOf,s=Object.getOwnPropertyDescriptor,m=Object.freeze,f=Object.seal,p=Object.create,d="undefined"!=typeof Reflect&&Reflect,h=d.apply,g=d.construct;h||(h=function(e,t,n){return e.apply(t,n)}),m||(m=function(e){return e}),f||(f=function(e){return e}),g||(g=function(e,t){return r(e,o(t))});var y,b=_(Array.prototype.forEach),v=_(Array.prototype.pop),T=_(Array.prototype.push),N=_(String.prototype.toLowerCase),A=_(String.prototype.match),E=_(String.prototype.replace),w=_(String.prototype.indexOf),x=_(String.prototype.trim),S=_(RegExp.prototype.test),k=(y=TypeError,function(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];return g(y,t)});function _(e){return function(t){for(var n=arguments.length,r=new Array(n>1?n-1:0),o=1;o<n;o++)r[o-1]=arguments[o];return h(e,t,r)}}function O(e,t,n){n=n||N,l&&l(e,null);for(var r=t.length;r--;){var o=t[r];if("string"==typeof o){var a=n(o);a!==o&&(c(t)||(t[r]=a),o=a)}e[o]=!0}return e}function D(e){var t,n=p(null);for(t in e)h(i,e,[t])&&(n[t]=e[t]);return n}function R(e,t){for(;null!==e;){var n=s(e,t);if(n){if(n.get)return _(n.get);if("function"==typeof n.value)return _(n.value)}e=u(e)}return function(e){return console.warn("fallback value for",e),null}}var L=m(["a","abbr","acronym","address","area","article","aside","audio","b","bdi","bdo","big","blink","blockquote","body","br","button","canvas","caption","center","cite","code","col","colgroup","content","data","datalist","dd","decorator","del","details","dfn","dialog","dir","div","dl","dt","element","em","fieldset","figcaption","figure","font","footer","form","h1","h2","h3","h4","h5","h6","head","header","hgroup","hr","html","i","img","input","ins","kbd","label","legend","li","main","map","mark","marquee","menu","menuitem","meter","nav","nobr","ol","optgroup","option","output","p","picture","pre","progress","q","rp","rt","ruby","s","samp","section","select","shadow","small","source","spacer","span","strike","strong","style","sub","summary","sup","table","tbody","td","template","textarea","tfoot","th","thead","time","tr","track","tt","u","ul","var","video","wbr"]),M=m(["svg","a","altglyph","altglyphdef","altglyphitem","animatecolor","animatemotion","animatetransform","circle","clippath","defs","desc","ellipse","filter","font","g","glyph","glyphref","hkern","image","line","lineargradient","marker","mask","metadata","mpath","path","pattern","polygon","polyline","radialgradient","rect","stop","style","switch","symbol","text","textpath","title","tref","tspan","view","vkern"]),C=m(["feBlend","feColorMatrix","feComponentTransfer","feComposite","feConvolveMatrix","feDiffuseLighting","feDisplacementMap","feDistantLight","feFlood","feFuncA","feFuncB","feFuncG","feFuncR","feGaussianBlur","feImage","feMerge","feMergeNode","feMorphology","feOffset","fePointLight","feSpecularLighting","feSpotLight","feTile","feTurbulence"]),I=m(["animate","color-profile","cursor","discard","fedropshadow","font-face","font-face-format","font-face-name","font-face-src","font-face-uri","foreignobject","hatch","hatchpath","mesh","meshgradient","meshpatch","meshrow","missing-glyph","script","set","solidcolor","unknown","use"]),F=m(["math","menclose","merror","mfenced","mfrac","mglyph","mi","mlabeledtr","mmultiscripts","mn","mo","mover","mpadded","mphantom","mroot","mrow","ms","mspace","msqrt","mstyle","msub","msup","msubsup","mtable","mtd","mtext","mtr","munder","munderover"]),H=m(["maction","maligngroup","malignmark","mlongdiv","mscarries","mscarry","msgroup","mstack","msline","msrow","semantics","annotation","annotation-xml","mprescripts","none"]),U=m(["#text"]),z=m(["accept","action","align","alt","autocapitalize","autocomplete","autopictureinpicture","autoplay","background","bgcolor","border","capture","cellpadding","cellspacing","checked","cite","class","clear","color","cols","colspan","controls","controlslist","coords","crossorigin","datetime","decoding","default","dir","disabled","disablepictureinpicture","disableremoteplayback","download","draggable","enctype","enterkeyhint","face","for","headers","height","hidden","high","href","hreflang","id","inputmode","integrity","ismap","kind","label","lang","list","loading","loop","low","max","maxlength","media","method","min","minlength","multiple","muted","name","nonce","noshade","novalidate","nowrap","open","optimum","pattern","placeholder","playsinline","poster","preload","pubdate","radiogroup","readonly","rel","required","rev","reversed","role","rows","rowspan","spellcheck","scope","selected","shape","size","sizes","span","srclang","start","src","srcset","step","style","summary","tabindex","title","translate","type","usemap","valign","value","width","xmlns","slot"]),j=m(["accent-height","accumulate","additive","alignment-baseline","ascent","attributename","attributetype","azimuth","basefrequency","baseline-shift","begin","bias","by","class","clip","clippathunits","clip-path","clip-rule","color","color-interpolation","color-interpolation-filters","color-profile","color-rendering","cx","cy","d","dx","dy","diffuseconstant","direction","display","divisor","dur","edgemode","elevation","end","fill","fill-opacity","fill-rule","filter","filterunits","flood-color","flood-opacity","font-family","font-size","font-size-adjust","font-stretch","font-style","font-variant","font-weight","fx","fy","g1","g2","glyph-name","glyphref","gradientunits","gradienttransform","height","href","id","image-rendering","in","in2","k","k1","k2","k3","k4","kerning","keypoints","keysplines","keytimes","lang","lengthadjust","letter-spacing","kernelmatrix","kernelunitlength","lighting-color","local","marker-end","marker-mid","marker-start","markerheight","markerunits","markerwidth","maskcontentunits","maskunits","max","mask","media","method","mode","min","name","numoctaves","offset","operator","opacity","order","orient","orientation","origin","overflow","paint-order","path","pathlength","patterncontentunits","patterntransform","patternunits","points","preservealpha","preserveaspectratio","primitiveunits","r","rx","ry","radius","refx","refy","repeatcount","repeatdur","restart","result","rotate","scale","seed","shape-rendering","specularconstant","specularexponent","spreadmethod","startoffset","stddeviation","stitchtiles","stop-color","stop-opacity","stroke-dasharray","stroke-dashoffset","stroke-linecap","stroke-linejoin","stroke-miterlimit","stroke-opacity","stroke","stroke-width","style","surfacescale","systemlanguage","tabindex","targetx","targety","transform","transform-origin","text-anchor","text-decoration","text-rendering","textlength","type","u1","u2","unicode","values","viewbox","visibility","version","vert-adv-y","vert-origin-x","vert-origin-y","width","word-spacing","wrap","writing-mode","xchannelselector","ychannelselector","x","x1","x2","xmlns","y","y1","y2","z","zoomandpan"]),B=m(["accent","accentunder","align","bevelled","close","columnsalign","columnlines","columnspan","denomalign","depth","dir","display","displaystyle","encoding","fence","frame","height","href","id","largeop","length","linethickness","lspace","lquote","mathbackground","mathcolor","mathsize","mathvariant","maxsize","minsize","movablelimits","notation","numalign","open","rowalign","rowlines","rowspacing","rowspan","rspace","rquote","scriptlevel","scriptminsize","scriptsizemultiplier","selection","separator","separators","stretchy","subscriptshift","supscriptshift","symmetric","voffset","width","xmlns"]),P=m(["xlink:href","xml:id","xlink:title","xml:space","xmlns:xlink"]),G=f(/\{\{[\w\W]*|[\w\W]*\}\}/gm),W=f(/<%[\w\W]*|[\w\W]*%>/gm),q=f(/^data-[\-\w.\u00B7-\uFFFF]/),Y=f(/^aria-[\-\w]+$/),K=f(/^(?:(?:(?:f|ht)tps?|mailto|tel|callto|cid|xmpp):|[^a-z]|[a-z+.\-]+(?:[^a-z+.\-:]|$))/i),V=f(/^(?:\w+script|data):/i),$=f(/[\u0000-\u0020\u00A0\u1680\u180E\u2000-\u2029\u205F\u3000]/g),X=f(/^html$/i),Z=function(){return"undefined"==typeof window?null:window},J=function(t,n){if("object"!==e(t)||"function"!=typeof t.createPolicy)return null;var r=null,o="data-tt-policy-suffix";n.currentScript&&n.currentScript.hasAttribute(o)&&(r=n.currentScript.getAttribute(o));var a="dompurify"+(r?"#"+r:"");try{return t.createPolicy(a,{createHTML:function(e){return e},createScriptURL:function(e){return e}})}catch(e){return console.warn("TrustedTypes policy "+a+" could not be created."),null}};return function t(){var n=arguments.length>0&&void 0!==arguments[0]?arguments[0]:Z(),r=function(e){return t(e)};if(r.version="2.3.10",r.removed=[],!n||!n.document||9!==n.document.nodeType)return r.isSupported=!1,r;var a=n.document,i=n.document,l=n.DocumentFragment,c=n.HTMLTemplateElement,u=n.Node,s=n.Element,f=n.NodeFilter,p=n.NamedNodeMap,d=void 0===p?n.NamedNodeMap||n.MozNamedAttrMap:p,h=n.HTMLFormElement,g=n.DOMParser,y=n.trustedTypes,_=s.prototype,Q=R(_,"cloneNode"),ee=R(_,"nextSibling"),te=R(_,"childNodes"),ne=R(_,"parentNode");if("function"==typeof c){var re=i.createElement("template");re.content&&re.content.ownerDocument&&(i=re.content.ownerDocument)}var oe=J(y,a),ae=oe?oe.createHTML(""):"",ie=i,le=ie.implementation,ce=ie.createNodeIterator,ue=ie.createDocumentFragment,se=ie.getElementsByTagName,me=a.importNode,fe={};try{fe=D(i).documentMode?i.documentMode:{}}catch(e){}var pe={};r.isSupported="function"==typeof ne&&le&&void 0!==le.createHTMLDocument&&9!==fe;var de,he,ge=G,ye=W,be=q,ve=Y,Te=V,Ne=$,Ae=K,Ee=null,we=O({},[].concat(o(L),o(M),o(C),o(F),o(U))),xe=null,Se=O({},[].concat(o(z),o(j),o(B),o(P))),ke=Object.seal(Object.create(null,{tagNameCheck:{writable:!0,configurable:!1,enumerable:!0,value:null},attributeNameCheck:{writable:!0,configurable:!1,enumerable:!0,value:null},allowCustomizedBuiltInElements:{writable:!0,configurable:!1,enumerable:!0,value:!1}})),_e=null,Oe=null,De=!0,Re=!0,Le=!1,Me=!1,Ce=!1,Ie=!1,Fe=!1,He=!1,Ue=!1,ze=!1,je=!0,Be=!0,Pe=!1,Ge={},We=null,qe=O({},["annotation-xml","audio","colgroup","desc","foreignobject","head","iframe","math","mi","mn","mo","ms","mtext","noembed","noframes","noscript","plaintext","script","style","svg","template","thead","title","video","xmp"]),Ye=null,Ke=O({},["audio","video","img","source","image","track"]),Ve=null,$e=O({},["alt","class","for","id","label","name","pattern","placeholder","role","summary","title","value","style","xmlns"]),Xe="http://www.w3.org/1998/Math/MathML",Ze="http://www.w3.org/2000/svg",Je="http://www.w3.org/1999/xhtml",Qe=Je,et=!1,tt=["application/xhtml+xml","text/html"],nt="text/html",rt=null,ot=i.createElement("form"),at=function(e){return e instanceof RegExp||e instanceof Function},it=function(t){rt&&rt===t||(t&&"object"===e(t)||(t={}),t=D(t),de=de=-1===tt.indexOf(t.PARSER_MEDIA_TYPE)?nt:t.PARSER_MEDIA_TYPE,he="application/xhtml+xml"===de?function(e){return e}:N,Ee="ALLOWED_TAGS"in t?O({},t.ALLOWED_TAGS,he):we,xe="ALLOWED_ATTR"in t?O({},t.ALLOWED_ATTR,he):Se,Ve="ADD_URI_SAFE_ATTR"in t?O(D($e),t.ADD_URI_SAFE_ATTR,he):$e,Ye="ADD_DATA_URI_TAGS"in t?O(D(Ke),t.ADD_DATA_URI_TAGS,he):Ke,We="FORBID_CONTENTS"in t?O({},t.FORBID_CONTENTS,he):qe,_e="FORBID_TAGS"in t?O({},t.FORBID_TAGS,he):{},Oe="FORBID_ATTR"in t?O({},t.FORBID_ATTR,he):{},Ge="USE_PROFILES"in t&&t.USE_PROFILES,De=!1!==t.ALLOW_ARIA_ATTR,Re=!1!==t.ALLOW_DATA_ATTR,Le=t.ALLOW_UNKNOWN_PROTOCOLS||!1,Me=t.SAFE_FOR_TEMPLATES||!1,Ce=t.WHOLE_DOCUMENT||!1,He=t.RETURN_DOM||!1,Ue=t.RETURN_DOM_FRAGMENT||!1,ze=t.RETURN_TRUSTED_TYPE||!1,Fe=t.FORCE_BODY||!1,je=!1!==t.SANITIZE_DOM,Be=!1!==t.KEEP_CONTENT,Pe=t.IN_PLACE||!1,Ae=t.ALLOWED_URI_REGEXP||Ae,Qe=t.NAMESPACE||Je,t.CUSTOM_ELEMENT_HANDLING&&at(t.CUSTOM_ELEMENT_HANDLING.tagNameCheck)&&(ke.tagNameCheck=t.CUSTOM_ELEMENT_HANDLING.tagNameCheck),t.CUSTOM_ELEMENT_HANDLING&&at(t.CUSTOM_ELEMENT_HANDLING.attributeNameCheck)&&(ke.attributeNameCheck=t.CUSTOM_ELEMENT_HANDLING.attributeNameCheck),t.CUSTOM_ELEMENT_HANDLING&&"boolean"==typeof t.CUSTOM_ELEMENT_HANDLING.allowCustomizedBuiltInElements&&(ke.allowCustomizedBuiltInElements=t.CUSTOM_ELEMENT_HANDLING.allowCustomizedBuiltInElements),Me&&(Re=!1),Ue&&(He=!0),Ge&&(Ee=O({},o(U)),xe=[],!0===Ge.html&&(O(Ee,L),O(xe,z)),!0===Ge.svg&&(O(Ee,M),O(xe,j),O(xe,P)),!0===Ge.svgFilters&&(O(Ee,C),O(xe,j),O(xe,P)),!0===Ge.mathMl&&(O(Ee,F),O(xe,B),O(xe,P))),t.ADD_TAGS&&(Ee===we&&(Ee=D(Ee)),O(Ee,t.ADD_TAGS,he)),t.ADD_ATTR&&(xe===Se&&(xe=D(xe)),O(xe,t.ADD_ATTR,he)),t.ADD_URI_SAFE_ATTR&&O(Ve,t.ADD_URI_SAFE_ATTR,he),t.FORBID_CONTENTS&&(We===qe&&(We=D(We)),O(We,t.FORBID_CONTENTS,he)),Be&&(Ee["#text"]=!0),Ce&&O(Ee,["html","head","body"]),Ee.table&&(O(Ee,["tbody"]),delete _e.tbody),m&&m(t),rt=t)},lt=O({},["mi","mo","mn","ms","mtext"]),ct=O({},["foreignobject","desc","title","annotation-xml"]),ut=O({},["title","style","font","a","script"]),st=O({},M);O(st,C),O(st,I);var mt=O({},F);O(mt,H);var ft=function(e){var t=ne(e);t&&t.tagName||(t={namespaceURI:Je,tagName:"template"});var n=N(e.tagName),r=N(t.tagName);return e.namespaceURI===Ze?t.namespaceURI===Je?"svg"===n:t.namespaceURI===Xe?"svg"===n&&("annotation-xml"===r||lt[r]):Boolean(st[n]):e.namespaceURI===Xe?t.namespaceURI===Je?"math"===n:t.namespaceURI===Ze?"math"===n&&ct[r]:Boolean(mt[n]):e.namespaceURI===Je&&(!(t.namespaceURI===Ze&&!ct[r])&&(!(t.namespaceURI===Xe&&!lt[r])&&(!mt[n]&&(ut[n]||!st[n]))))},pt=function(e){T(r.removed,{element:e});try{e.parentNode.removeChild(e)}catch(t){try{e.outerHTML=ae}catch(t){e.remove()}}},dt=function(e,t){try{T(r.removed,{attribute:t.getAttributeNode(e),from:t})}catch(e){T(r.removed,{attribute:null,from:t})}if(t.removeAttribute(e),"is"===e&&!xe[e])if(He||Ue)try{pt(t)}catch(e){}else try{t.setAttribute(e,"")}catch(e){}},ht=function(e){var t,n;if(Fe)e="<remove></remove>"+e;else{var r=A(e,/^[\r\n\t ]+/);n=r&&r[0]}"application/xhtml+xml"===de&&(e='<html xmlns="http://www.w3.org/1999/xhtml"><head></head><body>'+e+"</body></html>");var o=oe?oe.createHTML(e):e;if(Qe===Je)try{t=(new g).parseFromString(o,de)}catch(e){}if(!t||!t.documentElement){t=le.createDocument(Qe,"template",null);try{t.documentElement.innerHTML=et?"":o}catch(e){}}var a=t.body||t.documentElement;return e&&n&&a.insertBefore(i.createTextNode(n),a.childNodes[0]||null),Qe===Je?se.call(t,Ce?"html":"body")[0]:Ce?t.documentElement:a},gt=function(e){return ce.call(e.ownerDocument||e,e,f.SHOW_ELEMENT|f.SHOW_COMMENT|f.SHOW_TEXT,null,!1)},yt=function(e){return e instanceof h&&("string"!=typeof e.nodeName||"string"!=typeof e.textContent||"function"!=typeof e.removeChild||!(e.attributes instanceof d)||"function"!=typeof e.removeAttribute||"function"!=typeof e.setAttribute||"string"!=typeof e.namespaceURI||"function"!=typeof e.insertBefore)},bt=function(t){return"object"===e(u)?t instanceof u:t&&"object"===e(t)&&"number"==typeof t.nodeType&&"string"==typeof t.nodeName},vt=function(e,t,n){pe[e]&&b(pe[e],(function(e){e.call(r,t,n,rt)}))},Tt=function(e){var t;if(vt("beforeSanitizeElements",e,null),yt(e))return pt(e),!0;if(S(/[\u0080-\uFFFF]/,e.nodeName))return pt(e),!0;var n=he(e.nodeName);if(vt("uponSanitizeElement",e,{tagName:n,allowedTags:Ee}),e.hasChildNodes()&&!bt(e.firstElementChild)&&(!bt(e.content)||!bt(e.content.firstElementChild))&&S(/<[/\w]/g,e.innerHTML)&&S(/<[/\w]/g,e.textContent))return pt(e),!0;if("select"===n&&S(/<template/i,e.innerHTML))return pt(e),!0;if(!Ee[n]||_e[n]){if(!_e[n]&&At(n)){if(ke.tagNameCheck instanceof RegExp&&S(ke.tagNameCheck,n))return!1;if(ke.tagNameCheck instanceof Function&&ke.tagNameCheck(n))return!1}if(Be&&!We[n]){var o=ne(e)||e.parentNode,a=te(e)||e.childNodes;if(a&&o)for(var i=a.length-1;i>=0;--i)o.insertBefore(Q(a[i],!0),ee(e))}return pt(e),!0}return e instanceof s&&!ft(e)?(pt(e),!0):"noscript"!==n&&"noembed"!==n||!S(/<\/no(script|embed)/i,e.innerHTML)?(Me&&3===e.nodeType&&(t=e.textContent,t=E(t,ge," "),t=E(t,ye," "),e.textContent!==t&&(T(r.removed,{element:e.cloneNode()}),e.textContent=t)),vt("afterSanitizeElements",e,null),!1):(pt(e),!0)},Nt=function(e,t,n){if(je&&("id"===t||"name"===t)&&(n in i||n in ot))return!1;if(Re&&!Oe[t]&&S(be,t));else if(De&&S(ve,t));else if(!xe[t]||Oe[t]){if(!(At(e)&&(ke.tagNameCheck instanceof RegExp&&S(ke.tagNameCheck,e)||ke.tagNameCheck instanceof Function&&ke.tagNameCheck(e))&&(ke.attributeNameCheck instanceof RegExp&&S(ke.attributeNameCheck,t)||ke.attributeNameCheck instanceof Function&&ke.attributeNameCheck(t))||"is"===t&&ke.allowCustomizedBuiltInElements&&(ke.tagNameCheck instanceof RegExp&&S(ke.tagNameCheck,n)||ke.tagNameCheck instanceof Function&&ke.tagNameCheck(n))))return!1}else if(Ve[t]);else if(S(Ae,E(n,Ne,"")));else if("src"!==t&&"xlink:href"!==t&&"href"!==t||"script"===e||0!==w(n,"data:")||!Ye[e]){if(Le&&!S(Te,E(n,Ne,"")));else if(n)return!1}else;return!0},At=function(e){return e.indexOf("-")>0},Et=function(t){var n,o,a,i;vt("beforeSanitizeAttributes",t,null);var l=t.attributes;if(l){var c={attrName:"",attrValue:"",keepAttr:!0,allowedAttributes:xe};for(i=l.length;i--;){var u=n=l[i],s=u.name,m=u.namespaceURI;if(o="value"===s?n.value:x(n.value),a=he(s),c.attrName=a,c.attrValue=o,c.keepAttr=!0,c.forceKeepAttr=void 0,vt("uponSanitizeAttribute",t,c),o=c.attrValue,!c.forceKeepAttr&&(dt(s,t),c.keepAttr))if(S(/\/>/i,o))dt(s,t);else{Me&&(o=E(o,ge," "),o=E(o,ye," "));var f=he(t.nodeName);if(Nt(f,a,o)){if(oe&&"object"===e(y)&&"function"==typeof y.getAttributeType)if(m);else switch(y.getAttributeType(f,a)){case"TrustedHTML":o=oe.createHTML(o);break;case"TrustedScriptURL":o=oe.createScriptURL(o)}try{m?t.setAttributeNS(m,s,o):t.setAttribute(s,o),v(r.removed)}catch(e){}}}}vt("afterSanitizeAttributes",t,null)}},wt=function e(t){var n,r=gt(t);for(vt("beforeSanitizeShadowDOM",t,null);n=r.nextNode();)vt("uponSanitizeShadowNode",n,null),Tt(n)||(n.content instanceof l&&e(n.content),Et(n));vt("afterSanitizeShadowDOM",t,null)};return r.sanitize=function(t,o){var i,c,s,m,f;if((et=!t)&&(t="\x3c!--\x3e"),"string"!=typeof t&&!bt(t)){if("function"!=typeof t.toString)throw k("toString is not a function");if("string"!=typeof(t=t.toString()))throw k("dirty is not a string, aborting")}if(!r.isSupported){if("object"===e(n.toStaticHTML)||"function"==typeof n.toStaticHTML){if("string"==typeof t)return n.toStaticHTML(t);if(bt(t))return n.toStaticHTML(t.outerHTML)}return t}if(Ie||it(o),r.removed=[],"string"==typeof t&&(Pe=!1),Pe){if(t.nodeName){var p=he(t.nodeName);if(!Ee[p]||_e[p])throw k("root node is forbidden and cannot be sanitized in-place")}}else if(t instanceof u)1===(c=(i=ht("\x3c!----\x3e")).ownerDocument.importNode(t,!0)).nodeType&&"BODY"===c.nodeName||"HTML"===c.nodeName?i=c:i.appendChild(c);else{if(!He&&!Me&&!Ce&&-1===t.indexOf("<"))return oe&&ze?oe.createHTML(t):t;if(!(i=ht(t)))return He?null:ze?ae:""}i&&Fe&&pt(i.firstChild);for(var d=gt(Pe?t:i);s=d.nextNode();)3===s.nodeType&&s===m||Tt(s)||(s.content instanceof l&&wt(s.content),Et(s),m=s);if(m=null,Pe)return t;if(He){if(Ue)for(f=ue.call(i.ownerDocument);i.firstChild;)f.appendChild(i.firstChild);else f=i;return xe.shadowroot&&(f=me.call(a,f,!0)),f}var h=Ce?i.outerHTML:i.innerHTML;return Ce&&Ee["!doctype"]&&i.ownerDocument&&i.ownerDocument.doctype&&i.ownerDocument.doctype.name&&S(X,i.ownerDocument.doctype.name)&&(h="<!DOCTYPE "+i.ownerDocument.doctype.name+">\n"+h),Me&&(h=E(h,ge," "),h=E(h,ye," ")),oe&&ze?oe.createHTML(h):h},r.setConfig=function(e){it(e),Ie=!0},r.clearConfig=function(){rt=null,Ie=!1},r.isValidAttribute=function(e,t,n){rt||it({});var r=he(e),o=he(t);return Nt(r,o,n)},r.addHook=function(e,t){"function"==typeof t&&(pe[e]=pe[e]||[],T(pe[e],t))},r.removeHook=function(e){if(pe[e])return v(pe[e])},r.removeHooks=function(e){pe[e]&&(pe[e]=[])},r.removeAllHooks=function(){pe={}},r}()})); +//# sourceMappingURL=purify.min.js.map +;(function(){function t(t){return t.target}function n(t){return t.source}function e(t,n){try{for(var e in n)Object.defineProperty(t.prototype,e,{value:n[e],enumerable:!1})}catch(r){t.prototype=n}}function r(t){for(var n=-1,e=t.length,r=[];e>++n;)r.push(t[n]);return r}function i(t){return Array.prototype.slice.call(t)}function u(){}function a(t){return t}function o(){return!0}function c(t){return"function"==typeof t?t:function(){return t}}function l(t,n,e){return function(){var r=e.apply(n,arguments);return arguments.length?t:r}}function s(t){return null!=t&&!isNaN(t)}function f(t){return t.length}function h(t){return t.trim().replace(/\s+/g," ")}function d(t){for(var n=1;t*n%1;)n*=10;return n}function g(t){return 1===t.length?function(n,e){t(null==n?e:null)}:t}function p(t){return t.responseText}function m(t){return JSON.parse(t.responseText)}function v(t){var n=document.createRange();return n.selectNode(document.body),n.createContextualFragment(t.responseText)}function y(t){return t.responseXML}function M(){}function b(t){function n(){for(var n,r=e,i=-1,u=r.length;u>++i;)(n=r[i].on)&&n.apply(this,arguments);return t}var e=[],r=new u;return n.on=function(n,i){var u,a=r.get(n);return 2>arguments.length?a&&a.on:(a&&(a.on=null,e=e.slice(0,u=e.indexOf(a)).concat(e.slice(u+1)),r.remove(n)),i&&e.push(r.set(n,{on:i})),t)},n}function x(t,n){return n-(t?1+Math.floor(Math.log(t+Math.pow(10,1+Math.floor(Math.log(t)/Math.LN10)-n))/Math.LN10):1)}function _(t){return t+""}function w(t,n){var e=Math.pow(10,3*Math.abs(8-n));return{scale:n>8?function(t){return t/e}:function(t){return t*e},symbol:t}}function S(t){return function(n){return 0>=n?0:n>=1?1:t(n)}}function k(t){return function(n){return 1-t(1-n)}}function E(t){return function(n){return.5*(.5>n?t(2*n):2-t(2-2*n))}}function A(t){return t*t}function N(t){return t*t*t}function T(t){if(0>=t)return 0;if(t>=1)return 1;var n=t*t,e=n*t;return 4*(.5>t?e:3*(t-n)+e-.75)}function q(t){return function(n){return Math.pow(n,t)}}function C(t){return 1-Math.cos(t*Ru/2)}function z(t){return Math.pow(2,10*(t-1))}function D(t){return 1-Math.sqrt(1-t*t)}function L(t,n){var e;return 2>arguments.length&&(n=.45),arguments.length?e=n/(2*Ru)*Math.asin(1/t):(t=1,e=n/4),function(r){return 1+t*Math.pow(2,10*-r)*Math.sin(2*(r-e)*Ru/n)}}function F(t){return t||(t=1.70158),function(n){return n*n*((t+1)*n-t)}}function H(t){return 1/2.75>t?7.5625*t*t:2/2.75>t?7.5625*(t-=1.5/2.75)*t+.75:2.5/2.75>t?7.5625*(t-=2.25/2.75)*t+.9375:7.5625*(t-=2.625/2.75)*t+.984375}function R(){d3.event.stopPropagation(),d3.event.preventDefault()}function P(){for(var t,n=d3.event;t=n.sourceEvent;)n=t;return n}function j(t){for(var n=new M,e=0,r=arguments.length;r>++e;)n[arguments[e]]=b(n);return n.of=function(e,r){return function(i){try{var u=i.sourceEvent=d3.event;i.target=t,d3.event=i,n[i.type].apply(e,r)}finally{d3.event=u}}},n}function O(t){var n=[t.a,t.b],e=[t.c,t.d],r=U(n),i=Y(n,e),u=U(I(e,n,-i))||0;n[0]*e[1]<e[0]*n[1]&&(n[0]*=-1,n[1]*=-1,r*=-1,i*=-1),this.rotate=(r?Math.atan2(n[1],n[0]):Math.atan2(-e[0],e[1]))*Ou,this.translate=[t.e,t.f],this.scale=[r,u],this.skew=u?Math.atan2(i,u)*Ou:0}function Y(t,n){return t[0]*n[0]+t[1]*n[1]}function U(t){var n=Math.sqrt(Y(t,t));return n&&(t[0]/=n,t[1]/=n),n}function I(t,n,e){return t[0]+=e*n[0],t[1]+=e*n[1],t}function V(t){return"transform"==t?d3.interpolateTransform:d3.interpolate}function X(t,n){return n=n-(t=+t)?1/(n-t):0,function(e){return(e-t)*n}}function Z(t,n){return n=n-(t=+t)?1/(n-t):0,function(e){return Math.max(0,Math.min(1,(e-t)*n))}}function B(){}function $(t,n,e){return new J(t,n,e)}function J(t,n,e){this.r=t,this.g=n,this.b=e}function G(t){return 16>t?"0"+Math.max(0,t).toString(16):Math.min(255,t).toString(16)}function K(t,n,e){var r,i,u,a=0,o=0,c=0;if(r=/([a-z]+)\((.*)\)/i.exec(t))switch(i=r[2].split(","),r[1]){case"hsl":return e(parseFloat(i[0]),parseFloat(i[1])/100,parseFloat(i[2])/100);case"rgb":return n(nn(i[0]),nn(i[1]),nn(i[2]))}return(u=aa.get(t))?n(u.r,u.g,u.b):(null!=t&&"#"===t.charAt(0)&&(4===t.length?(a=t.charAt(1),a+=a,o=t.charAt(2),o+=o,c=t.charAt(3),c+=c):7===t.length&&(a=t.substring(1,3),o=t.substring(3,5),c=t.substring(5,7)),a=parseInt(a,16),o=parseInt(o,16),c=parseInt(c,16)),n(a,o,c))}function W(t,n,e){var r,i,u=Math.min(t/=255,n/=255,e/=255),a=Math.max(t,n,e),o=a-u,c=(a+u)/2;return o?(i=.5>c?o/(a+u):o/(2-a-u),r=t==a?(n-e)/o+(e>n?6:0):n==a?(e-t)/o+2:(t-n)/o+4,r*=60):i=r=0,en(r,i,c)}function Q(t,n,e){t=tn(t),n=tn(n),e=tn(e);var r=gn((.4124564*t+.3575761*n+.1804375*e)/sa),i=gn((.2126729*t+.7151522*n+.072175*e)/fa),u=gn((.0193339*t+.119192*n+.9503041*e)/ha);return ln(116*i-16,500*(r-i),200*(i-u))}function tn(t){return.04045>=(t/=255)?t/12.92:Math.pow((t+.055)/1.055,2.4)}function nn(t){var n=parseFloat(t);return"%"===t.charAt(t.length-1)?Math.round(2.55*n):n}function en(t,n,e){return new rn(t,n,e)}function rn(t,n,e){this.h=t,this.s=n,this.l=e}function un(t,n,e){function r(t){return t>360?t-=360:0>t&&(t+=360),60>t?u+(a-u)*t/60:180>t?a:240>t?u+(a-u)*(240-t)/60:u}function i(t){return Math.round(255*r(t))}var u,a;return t%=360,0>t&&(t+=360),n=0>n?0:n>1?1:n,e=0>e?0:e>1?1:e,a=.5>=e?e*(1+n):e+n-e*n,u=2*e-a,$(i(t+120),i(t),i(t-120))}function an(t,n,e){return new on(t,n,e)}function on(t,n,e){this.h=t,this.c=n,this.l=e}function cn(t,n,e){return ln(e,Math.cos(t*=ju)*n,Math.sin(t)*n)}function ln(t,n,e){return new sn(t,n,e)}function sn(t,n,e){this.l=t,this.a=n,this.b=e}function fn(t,n,e){var r=(t+16)/116,i=r+n/500,u=r-e/200;return i=dn(i)*sa,r=dn(r)*fa,u=dn(u)*ha,$(pn(3.2404542*i-1.5371385*r-.4985314*u),pn(-.969266*i+1.8760108*r+.041556*u),pn(.0556434*i-.2040259*r+1.0572252*u))}function hn(t,n,e){return an(180*(Math.atan2(e,n)/Ru),Math.sqrt(n*n+e*e),t)}function dn(t){return t>.206893034?t*t*t:(t-4/29)/7.787037}function gn(t){return t>.008856?Math.pow(t,1/3):7.787037*t+4/29}function pn(t){return Math.round(255*(.00304>=t?12.92*t:1.055*Math.pow(t,1/2.4)-.055))}function mn(t){return Iu(t,Ma),t}function vn(t){return function(){return ga(t,this)}}function yn(t){return function(){return pa(t,this)}}function Mn(t,n){function e(){this.removeAttribute(t)}function r(){this.removeAttributeNS(t.space,t.local)}function i(){this.setAttribute(t,n)}function u(){this.setAttributeNS(t.space,t.local,n)}function a(){var e=n.apply(this,arguments);null==e?this.removeAttribute(t):this.setAttribute(t,e)}function o(){var e=n.apply(this,arguments);null==e?this.removeAttributeNS(t.space,t.local):this.setAttributeNS(t.space,t.local,e)}return t=d3.ns.qualify(t),null==n?t.local?r:e:"function"==typeof n?t.local?o:a:t.local?u:i}function bn(t){return RegExp("(?:^|\\s+)"+d3.requote(t)+"(?:\\s+|$)","g")}function xn(t,n){function e(){for(var e=-1;i>++e;)t[e](this,n)}function r(){for(var e=-1,r=n.apply(this,arguments);i>++e;)t[e](this,r)}t=t.trim().split(/\s+/).map(_n);var i=t.length;return"function"==typeof n?r:e}function _n(t){var n=bn(t);return function(e,r){if(i=e.classList)return r?i.add(t):i.remove(t);var i=e.className,u=null!=i.baseVal,a=u?i.baseVal:i;r?(n.lastIndex=0,n.test(a)||(a=h(a+" "+t),u?i.baseVal=a:e.className=a)):a&&(a=h(a.replace(n," ")),u?i.baseVal=a:e.className=a)}}function wn(t,n,e){function r(){this.style.removeProperty(t)}function i(){this.style.setProperty(t,n,e)}function u(){var r=n.apply(this,arguments);null==r?this.style.removeProperty(t):this.style.setProperty(t,r,e)}return null==n?r:"function"==typeof n?u:i}function Sn(t,n){function e(){delete this[t]}function r(){this[t]=n}function i(){var e=n.apply(this,arguments);null==e?delete this[t]:this[t]=e}return null==n?e:"function"==typeof n?i:r}function kn(t){return{__data__:t}}function En(t){return function(){return ya(this,t)}}function An(t){return arguments.length||(t=d3.ascending),function(n,e){return t(n&&n.__data__,e&&e.__data__)}}function Nn(t,n,e){function r(){var n=this[u];n&&(this.removeEventListener(t,n,n.$),delete this[u])}function i(){function i(t){var e=d3.event;d3.event=t,o[0]=a.__data__;try{n.apply(a,o)}finally{d3.event=e}}var a=this,o=Yu(arguments);r.call(this),this.addEventListener(t,this[u]=i,i.$=e),i._=n}var u="__on"+t,a=t.indexOf(".");return a>0&&(t=t.substring(0,a)),n?i:r}function Tn(t,n){for(var e=0,r=t.length;r>e;e++)for(var i,u=t[e],a=0,o=u.length;o>a;a++)(i=u[a])&&n(i,a,e);return t}function qn(t){return Iu(t,xa),t}function Cn(t,n){return Iu(t,wa),t.id=n,t}function zn(t,n,e,r){var i=t.__transition__||(t.__transition__={active:0,count:0}),a=i[e];if(!a){var o=r.time;return a=i[e]={tween:new u,event:d3.dispatch("start","end"),time:o,ease:r.ease,delay:r.delay,duration:r.duration},++i.count,d3.timer(function(r){function u(r){return i.active>e?l():(i.active=e,h.start.call(t,s,n),a.tween.forEach(function(e,r){(r=r.call(t,s,n))&&p.push(r)}),c(r)||d3.timer(c,0,o),1)}function c(r){if(i.active!==e)return l();for(var u=(r-d)/g,a=f(u),o=p.length;o>0;)p[--o].call(t,a);return u>=1?(l(),h.end.call(t,s,n),1):void 0}function l(){return--i.count?delete i[e]:delete t.__transition__,1}var s=t.__data__,f=a.ease,h=a.event,d=a.delay,g=a.duration,p=[];return r>=d?u(r):d3.timer(u,d,o),1},0,o),a}}function Dn(t){return null==t&&(t=""),function(){this.textContent=t}}function Ln(t,n,e,r){var i=t.id;return Tn(t,"function"==typeof e?function(t,u,a){t.__transition__[i].tween.set(n,r(e.call(t,t.__data__,u,a)))}:(e=r(e),function(t){t.__transition__[i].tween.set(n,e)}))}function Fn(){for(var t,n=Date.now(),e=qa;e;)t=n-e.then,t>=e.delay&&(e.flush=e.callback(t)),e=e.next;var r=Hn()-n;r>24?(isFinite(r)&&(clearTimeout(Aa),Aa=setTimeout(Fn,r)),Ea=0):(Ea=1,Ca(Fn))}function Hn(){for(var t=null,n=qa,e=1/0;n;)n.flush?(delete Ta[n.callback.id],n=t?t.next=n.next:qa=n.next):(e=Math.min(e,n.then+n.delay),n=(t=n).next);return e}function Rn(t,n){var e=t.ownerSVGElement||t;if(e.createSVGPoint){var r=e.createSVGPoint();if(0>za&&(window.scrollX||window.scrollY)){e=d3.select(document.body).append("svg").style("position","absolute").style("top",0).style("left",0);var i=e[0][0].getScreenCTM();za=!(i.f||i.e),e.remove()}return za?(r.x=n.pageX,r.y=n.pageY):(r.x=n.clientX,r.y=n.clientY),r=r.matrixTransform(t.getScreenCTM().inverse()),[r.x,r.y]}var u=t.getBoundingClientRect();return[n.clientX-u.left-t.clientLeft,n.clientY-u.top-t.clientTop]}function Pn(){}function jn(t){var n=t[0],e=t[t.length-1];return e>n?[n,e]:[e,n]}function On(t){return t.rangeExtent?t.rangeExtent():jn(t.range())}function Yn(t,n){var e,r=0,i=t.length-1,u=t[r],a=t[i];return u>a&&(e=r,r=i,i=e,e=u,u=a,a=e),(n=n(a-u))&&(t[r]=n.floor(u),t[i]=n.ceil(a)),t}function Un(){return Math}function In(t,n,e,r){function i(){var i=Math.min(t.length,n.length)>2?Gn:Jn,c=r?Z:X;return a=i(t,n,c,e),o=i(n,t,c,d3.interpolate),u}function u(t){return a(t)}var a,o;return u.invert=function(t){return o(t)},u.domain=function(n){return arguments.length?(t=n.map(Number),i()):t},u.range=function(t){return arguments.length?(n=t,i()):n},u.rangeRound=function(t){return u.range(t).interpolate(d3.interpolateRound)},u.clamp=function(t){return arguments.length?(r=t,i()):r},u.interpolate=function(t){return arguments.length?(e=t,i()):e},u.ticks=function(n){return Bn(t,n)},u.tickFormat=function(n){return $n(t,n)},u.nice=function(){return Yn(t,Xn),i()},u.copy=function(){return In(t,n,e,r)},i()}function Vn(t,n){return d3.rebind(t,n,"range","rangeRound","interpolate","clamp")}function Xn(t){return t=Math.pow(10,Math.round(Math.log(t)/Math.LN10)-1),t&&{floor:function(n){return Math.floor(n/t)*t},ceil:function(n){return Math.ceil(n/t)*t}}}function Zn(t,n){var e=jn(t),r=e[1]-e[0],i=Math.pow(10,Math.floor(Math.log(r/n)/Math.LN10)),u=n/r*i;return.15>=u?i*=10:.35>=u?i*=5:.75>=u&&(i*=2),e[0]=Math.ceil(e[0]/i)*i,e[1]=Math.floor(e[1]/i)*i+.5*i,e[2]=i,e}function Bn(t,n){return d3.range.apply(d3,Zn(t,n))}function $n(t,n){return d3.format(",."+Math.max(0,-Math.floor(Math.log(Zn(t,n)[2])/Math.LN10+.01))+"f")}function Jn(t,n,e,r){var i=e(t[0],t[1]),u=r(n[0],n[1]);return function(t){return u(i(t))}}function Gn(t,n,e,r){var i=[],u=[],a=0,o=Math.min(t.length,n.length)-1;for(t[o]<t[0]&&(t=t.slice().reverse(),n=n.slice().reverse());o>=++a;)i.push(e(t[a-1],t[a])),u.push(r(n[a-1],n[a]));return function(n){var e=d3.bisect(t,n,1,o)-1;return u[e](i[e](n))}}function Kn(t,n){function e(e){return t(n(e))}var r=n.pow;return e.invert=function(n){return r(t.invert(n))},e.domain=function(i){return arguments.length?(n=0>i[0]?Qn:Wn,r=n.pow,t.domain(i.map(n)),e):t.domain().map(r)},e.nice=function(){return t.domain(Yn(t.domain(),Un)),e},e.ticks=function(){var e=jn(t.domain()),i=[];if(e.every(isFinite)){var u=Math.floor(e[0]),a=Math.ceil(e[1]),o=r(e[0]),c=r(e[1]);if(n===Qn)for(i.push(r(u));a>u++;)for(var l=9;l>0;l--)i.push(r(u)*l);else{for(;a>u;u++)for(var l=1;10>l;l++)i.push(r(u)*l);i.push(r(u))}for(u=0;o>i[u];u++);for(a=i.length;i[a-1]>c;a--);i=i.slice(u,a)}return i},e.tickFormat=function(t,i){if(2>arguments.length&&(i=Da),!arguments.length)return i;var u,a=Math.max(.1,t/e.ticks().length),o=n===Qn?(u=-1e-12,Math.floor):(u=1e-12,Math.ceil);return function(t){return a>=t/r(o(n(t)+u))?i(t):""}},e.copy=function(){return Kn(t.copy(),n)},Vn(e,t)}function Wn(t){return Math.log(0>t?0:t)/Math.LN10}function Qn(t){return-Math.log(t>0?0:-t)/Math.LN10}function te(t,n){function e(n){return t(r(n))}var r=ne(n),i=ne(1/n);return e.invert=function(n){return i(t.invert(n))},e.domain=function(n){return arguments.length?(t.domain(n.map(r)),e):t.domain().map(i)},e.ticks=function(t){return Bn(e.domain(),t)},e.tickFormat=function(t){return $n(e.domain(),t)},e.nice=function(){return e.domain(Yn(e.domain(),Xn))},e.exponent=function(t){if(!arguments.length)return n;var u=e.domain();return r=ne(n=t),i=ne(1/n),e.domain(u)},e.copy=function(){return te(t.copy(),n)},Vn(e,t)}function ne(t){return function(n){return 0>n?-Math.pow(-n,t):Math.pow(n,t)}}function ee(t,n){function e(n){return a[((i.get(n)||i.set(n,t.push(n)))-1)%a.length]}function r(n,e){return d3.range(t.length).map(function(t){return n+e*t})}var i,a,o;return e.domain=function(r){if(!arguments.length)return t;t=[],i=new u;for(var a,o=-1,c=r.length;c>++o;)i.has(a=r[o])||i.set(a,t.push(a));return e[n.t].apply(e,n.a)},e.range=function(t){return arguments.length?(a=t,o=0,n={t:"range",a:arguments},e):a},e.rangePoints=function(i,u){2>arguments.length&&(u=0);var c=i[0],l=i[1],s=(l-c)/(Math.max(1,t.length-1)+u);return a=r(2>t.length?(c+l)/2:c+s*u/2,s),o=0,n={t:"rangePoints",a:arguments},e},e.rangeBands=function(i,u,c){2>arguments.length&&(u=0),3>arguments.length&&(c=u);var l=i[1]<i[0],s=i[l-0],f=i[1-l],h=(f-s)/(t.length-u+2*c);return a=r(s+h*c,h),l&&a.reverse(),o=h*(1-u),n={t:"rangeBands",a:arguments},e},e.rangeRoundBands=function(i,u,c){2>arguments.length&&(u=0),3>arguments.length&&(c=u);var l=i[1]<i[0],s=i[l-0],f=i[1-l],h=Math.floor((f-s)/(t.length-u+2*c)),d=f-s-(t.length-u)*h;return a=r(s+Math.round(d/2),h),l&&a.reverse(),o=Math.round(h*(1-u)),n={t:"rangeRoundBands",a:arguments},e},e.rangeBand=function(){return o},e.rangeExtent=function(){return jn(n.a[0])},e.copy=function(){return ee(t,n)},e.domain(t)}function re(t,n){function e(){var e=0,u=n.length;for(i=[];u>++e;)i[e-1]=d3.quantile(t,e/u);return r}function r(t){return isNaN(t=+t)?0/0:n[d3.bisect(i,t)]}var i;return r.domain=function(n){return arguments.length?(t=n.filter(function(t){return!isNaN(t)}).sort(d3.ascending),e()):t},r.range=function(t){return arguments.length?(n=t,e()):n},r.quantiles=function(){return i},r.copy=function(){return re(t,n)},e()}function ie(t,n,e){function r(n){return e[Math.max(0,Math.min(a,Math.floor(u*(n-t))))]}function i(){return u=e.length/(n-t),a=e.length-1,r}var u,a;return r.domain=function(e){return arguments.length?(t=+e[0],n=+e[e.length-1],i()):[t,n]},r.range=function(t){return arguments.length?(e=t,i()):e},r.copy=function(){return ie(t,n,e)},i()}function ue(t,n){function e(e){return n[d3.bisect(t,e)]}return e.domain=function(n){return arguments.length?(t=n,e):t},e.range=function(t){return arguments.length?(n=t,e):n},e.copy=function(){return ue(t,n)},e}function ae(t){function n(t){return+t}return n.invert=n,n.domain=n.range=function(e){return arguments.length?(t=e.map(n),n):t},n.ticks=function(n){return Bn(t,n)},n.tickFormat=function(n){return $n(t,n)},n.copy=function(){return ae(t)},n}function oe(t){return t.innerRadius}function ce(t){return t.outerRadius}function le(t){return t.startAngle}function se(t){return t.endAngle}function fe(t){function n(n){function a(){s.push("M",u(t(f),l))}for(var o,s=[],f=[],h=-1,d=n.length,g=c(e),p=c(r);d>++h;)i.call(this,o=n[h],h)?f.push([+g.call(this,o,h),+p.call(this,o,h)]):f.length&&(a(),f=[]);return f.length&&a(),s.length?s.join(""):null}var e=he,r=de,i=o,u=ge,a=u.key,l=.7;return n.x=function(t){return arguments.length?(e=t,n):e},n.y=function(t){return arguments.length?(r=t,n):r},n.defined=function(t){return arguments.length?(i=t,n):i},n.interpolate=function(t){return arguments.length?(a="function"==typeof t?u=t:(u=Oa.get(t)||ge).key,n):a},n.tension=function(t){return arguments.length?(l=t,n):l},n}function he(t){return t[0]}function de(t){return t[1]}function ge(t){return t.join("L")}function pe(t){return ge(t)+"Z"}function me(t){for(var n=0,e=t.length,r=t[0],i=[r[0],",",r[1]];e>++n;)i.push("V",(r=t[n])[1],"H",r[0]);return i.join("")}function ve(t){for(var n=0,e=t.length,r=t[0],i=[r[0],",",r[1]];e>++n;)i.push("H",(r=t[n])[0],"V",r[1]);return i.join("")}function ye(t,n){return 4>t.length?ge(t):t[1]+xe(t.slice(1,t.length-1),_e(t,n))}function Me(t,n){return 3>t.length?ge(t):t[0]+xe((t.push(t[0]),t),_e([t[t.length-2]].concat(t,[t[1]]),n))}function be(t,n){return 3>t.length?ge(t):t[0]+xe(t,_e(t,n))}function xe(t,n){if(1>n.length||t.length!=n.length&&t.length!=n.length+2)return ge(t);var e=t.length!=n.length,r="",i=t[0],u=t[1],a=n[0],o=a,c=1;if(e&&(r+="Q"+(u[0]-2*a[0]/3)+","+(u[1]-2*a[1]/3)+","+u[0]+","+u[1],i=t[1],c=2),n.length>1){o=n[1],u=t[c],c++,r+="C"+(i[0]+a[0])+","+(i[1]+a[1])+","+(u[0]-o[0])+","+(u[1]-o[1])+","+u[0]+","+u[1];for(var l=2;n.length>l;l++,c++)u=t[c],o=n[l],r+="S"+(u[0]-o[0])+","+(u[1]-o[1])+","+u[0]+","+u[1]}if(e){var s=t[c];r+="Q"+(u[0]+2*o[0]/3)+","+(u[1]+2*o[1]/3)+","+s[0]+","+s[1]}return r}function _e(t,n){for(var e,r=[],i=(1-n)/2,u=t[0],a=t[1],o=1,c=t.length;c>++o;)e=u,u=a,a=t[o],r.push([i*(a[0]-e[0]),i*(a[1]-e[1])]);return r}function we(t){if(3>t.length)return ge(t);var n=1,e=t.length,r=t[0],i=r[0],u=r[1],a=[i,i,i,(r=t[1])[0]],o=[u,u,u,r[1]],c=[i,",",u];for(Ne(c,a,o);e>++n;)r=t[n],a.shift(),a.push(r[0]),o.shift(),o.push(r[1]),Ne(c,a,o);for(n=-1;2>++n;)a.shift(),a.push(r[0]),o.shift(),o.push(r[1]),Ne(c,a,o);return c.join("")}function Se(t){if(4>t.length)return ge(t);for(var n,e=[],r=-1,i=t.length,u=[0],a=[0];3>++r;)n=t[r],u.push(n[0]),a.push(n[1]);for(e.push(Ae(Ia,u)+","+Ae(Ia,a)),--r;i>++r;)n=t[r],u.shift(),u.push(n[0]),a.shift(),a.push(n[1]),Ne(e,u,a);return e.join("")}function ke(t){for(var n,e,r=-1,i=t.length,u=i+4,a=[],o=[];4>++r;)e=t[r%i],a.push(e[0]),o.push(e[1]);for(n=[Ae(Ia,a),",",Ae(Ia,o)],--r;u>++r;)e=t[r%i],a.shift(),a.push(e[0]),o.shift(),o.push(e[1]),Ne(n,a,o);return n.join("")}function Ee(t,n){var e=t.length-1;if(e)for(var r,i,u=t[0][0],a=t[0][1],o=t[e][0]-u,c=t[e][1]-a,l=-1;e>=++l;)r=t[l],i=l/e,r[0]=n*r[0]+(1-n)*(u+i*o),r[1]=n*r[1]+(1-n)*(a+i*c);return we(t)}function Ae(t,n){return t[0]*n[0]+t[1]*n[1]+t[2]*n[2]+t[3]*n[3]}function Ne(t,n,e){t.push("C",Ae(Ya,n),",",Ae(Ya,e),",",Ae(Ua,n),",",Ae(Ua,e),",",Ae(Ia,n),",",Ae(Ia,e))}function Te(t,n){return(n[1]-t[1])/(n[0]-t[0])}function qe(t){for(var n=0,e=t.length-1,r=[],i=t[0],u=t[1],a=r[0]=Te(i,u);e>++n;)r[n]=(a+(a=Te(i=u,u=t[n+1])))/2;return r[n]=a,r}function Ce(t){for(var n,e,r,i,u=[],a=qe(t),o=-1,c=t.length-1;c>++o;)n=Te(t[o],t[o+1]),1e-6>Math.abs(n)?a[o]=a[o+1]=0:(e=a[o]/n,r=a[o+1]/n,i=e*e+r*r,i>9&&(i=3*n/Math.sqrt(i),a[o]=i*e,a[o+1]=i*r));for(o=-1;c>=++o;)i=(t[Math.min(c,o+1)][0]-t[Math.max(0,o-1)][0])/(6*(1+a[o]*a[o])),u.push([i||0,a[o]*i||0]);return u}function ze(t){return 3>t.length?ge(t):t[0]+xe(t,Ce(t))}function De(t){for(var n,e,r,i=-1,u=t.length;u>++i;)n=t[i],e=n[0],r=n[1]+Pa,n[0]=e*Math.cos(r),n[1]=e*Math.sin(r);return t}function Le(t){function n(n){function o(){m.push("M",l(t(y),d),h,f(t(v.reverse()),d),"Z")}for(var s,g,p,m=[],v=[],y=[],M=-1,b=n.length,x=c(e),_=c(i),w=e===r?function(){return g}:c(r),S=i===u?function(){return p}:c(u);b>++M;)a.call(this,s=n[M],M)?(v.push([g=+x.call(this,s,M),p=+_.call(this,s,M)]),y.push([+w.call(this,s,M),+S.call(this,s,M)])):v.length&&(o(),v=[],y=[]);return v.length&&o(),m.length?m.join(""):null}var e=he,r=he,i=0,u=de,a=o,l=ge,s=l.key,f=l,h="L",d=.7;return n.x=function(t){return arguments.length?(e=r=t,n):r},n.x0=function(t){return arguments.length?(e=t,n):e},n.x1=function(t){return arguments.length?(r=t,n):r},n.y=function(t){return arguments.length?(i=u=t,n):u},n.y0=function(t){return arguments.length?(i=t,n):i},n.y1=function(t){return arguments.length?(u=t,n):u},n.defined=function(t){return arguments.length?(a=t,n):a},n.interpolate=function(t){return arguments.length?(s="function"==typeof t?l=t:(l=Oa.get(t)||ge).key,f=l.reverse||l,h=l.closed?"M":"L",n):s},n.tension=function(t){return arguments.length?(d=t,n):d},n}function Fe(t){return t.radius}function He(t){return[t.x,t.y]}function Re(t){return function(){var n=t.apply(this,arguments),e=n[0],r=n[1]+Pa;return[e*Math.cos(r),e*Math.sin(r)]}}function Pe(){return 64}function je(){return"circle"}function Oe(t){var n=Math.sqrt(t/Ru);return"M0,"+n+"A"+n+","+n+" 0 1,1 0,"+-n+"A"+n+","+n+" 0 1,1 0,"+n+"Z"}function Ye(t,n){t.attr("transform",function(t){return"translate("+n(t)+",0)"})}function Ue(t,n){t.attr("transform",function(t){return"translate(0,"+n(t)+")"})}function Ie(t,n,e){if(r=[],e&&n.length>1){for(var r,i,u,a=jn(t.domain()),o=-1,c=n.length,l=(n[1]-n[0])/++e;c>++o;)for(i=e;--i>0;)(u=+n[o]-i*l)>=a[0]&&r.push(u);for(--o,i=0;e>++i&&(u=+n[o]+i*l)<a[1];)r.push(u)}return r}function Ve(){Ja||(Ja=d3.select("body").append("div").style("visibility","hidden").style("top",0).style("height",0).style("width",0).style("overflow-y","scroll").append("div").style("height","2000px").node().parentNode);var t,n=d3.event;try{Ja.scrollTop=1e3,Ja.dispatchEvent(n),t=1e3-Ja.scrollTop}catch(e){t=n.wheelDelta||5*-n.detail}return t}function Xe(t){for(var n=t.source,e=t.target,r=Be(n,e),i=[n];n!==r;)n=n.parent,i.push(n);for(var u=i.length;e!==r;)i.splice(u,0,e),e=e.parent;return i}function Ze(t){for(var n=[],e=t.parent;null!=e;)n.push(t),t=e,e=e.parent;return n.push(t),n}function Be(t,n){if(t===n)return t;for(var e=Ze(t),r=Ze(n),i=e.pop(),u=r.pop(),a=null;i===u;)a=i,i=e.pop(),u=r.pop();return a}function $e(t){t.fixed|=2}function Je(t){t.fixed&=1}function Ge(t){t.fixed|=4,t.px=t.x,t.py=t.y}function Ke(t){t.fixed&=3}function We(t,n,e){var r=0,i=0;if(t.charge=0,!t.leaf)for(var u,a=t.nodes,o=a.length,c=-1;o>++c;)u=a[c],null!=u&&(We(u,n,e),t.charge+=u.charge,r+=u.charge*u.cx,i+=u.charge*u.cy);if(t.point){t.leaf||(t.point.x+=Math.random()-.5,t.point.y+=Math.random()-.5);var l=n*e[t.point.index];t.charge+=t.pointCharge=l,r+=l*t.point.x,i+=l*t.point.y}t.cx=r/t.charge,t.cy=i/t.charge}function Qe(){return 20}function tr(){return 1}function nr(t){return t.x}function er(t){return t.y}function rr(t,n,e){t.y0=n,t.y=e}function ir(t){return d3.range(t.length)}function ur(t){for(var n=-1,e=t[0].length,r=[];e>++n;)r[n]=0;return r}function ar(t){for(var n,e=1,r=0,i=t[0][1],u=t.length;u>e;++e)(n=t[e][1])>i&&(r=e,i=n);return r}function or(t){return t.reduce(cr,0)}function cr(t,n){return t+n[1]}function lr(t,n){return sr(t,Math.ceil(Math.log(n.length)/Math.LN2+1))}function sr(t,n){for(var e=-1,r=+t[0],i=(t[1]-r)/n,u=[];n>=++e;)u[e]=i*e+r;return u}function fr(t){return[d3.min(t),d3.max(t)]}function hr(t,n){return d3.rebind(t,n,"sort","children","value"),t.nodes=t,t.links=mr,t}function dr(t){return t.children}function gr(t){return t.value}function pr(t,n){return n.value-t.value}function mr(t){return d3.merge(t.map(function(t){return(t.children||[]).map(function(n){return{source:t,target:n}})}))}function vr(t,n){return t.value-n.value}function yr(t,n){var e=t._pack_next;t._pack_next=n,n._pack_prev=t,n._pack_next=e,e._pack_prev=n}function Mr(t,n){t._pack_next=n,n._pack_prev=t}function br(t,n){var e=n.x-t.x,r=n.y-t.y,i=t.r+n.r;return i*i-e*e-r*r>.001}function xr(t){function n(t){s=Math.min(t.x-t.r,s),f=Math.max(t.x+t.r,f),h=Math.min(t.y-t.r,h),d=Math.max(t.y+t.r,d)}if((e=t.children)&&(l=e.length)){var e,r,i,u,a,o,c,l,s=1/0,f=-1/0,h=1/0,d=-1/0;if(e.forEach(_r),r=e[0],r.x=-r.r,r.y=0,n(r),l>1&&(i=e[1],i.x=i.r,i.y=0,n(i),l>2))for(u=e[2],kr(r,i,u),n(u),yr(r,u),r._pack_prev=u,yr(u,i),i=r._pack_next,a=3;l>a;a++){kr(r,i,u=e[a]);var g=0,p=1,m=1;for(o=i._pack_next;o!==i;o=o._pack_next,p++)if(br(o,u)){g=1;break}if(1==g)for(c=r._pack_prev;c!==o._pack_prev&&!br(c,u);c=c._pack_prev,m++);g?(m>p||p==m&&i.r<r.r?Mr(r,i=o):Mr(r=c,i),a--):(yr(r,u),i=u,n(u))}var v=(s+f)/2,y=(h+d)/2,M=0;for(a=0;l>a;a++)u=e[a],u.x-=v,u.y-=y,M=Math.max(M,u.r+Math.sqrt(u.x*u.x+u.y*u.y));t.r=M,e.forEach(wr)}}function _r(t){t._pack_next=t._pack_prev=t}function wr(t){delete t._pack_next,delete t._pack_prev}function Sr(t,n,e,r){var i=t.children;if(t.x=n+=r*t.x,t.y=e+=r*t.y,t.r*=r,i)for(var u=-1,a=i.length;a>++u;)Sr(i[u],n,e,r)}function kr(t,n,e){var r=t.r+e.r,i=n.x-t.x,u=n.y-t.y;if(r&&(i||u)){var a=n.r+e.r,o=i*i+u*u;a*=a,r*=r;var c=.5+(r-a)/(2*o),l=Math.sqrt(Math.max(0,2*a*(r+o)-(r-=o)*r-a*a))/(2*o);e.x=t.x+c*i+l*u,e.y=t.y+c*u-l*i}else e.x=t.x+r,e.y=t.y}function Er(t){return 1+d3.max(t,function(t){return t.y})}function Ar(t){return t.reduce(function(t,n){return t+n.x},0)/t.length}function Nr(t){var n=t.children;return n&&n.length?Nr(n[0]):t}function Tr(t){var n,e=t.children;return e&&(n=e.length)?Tr(e[n-1]):t}function qr(t,n){return t.parent==n.parent?1:2}function Cr(t){var n=t.children;return n&&n.length?n[0]:t._tree.thread}function zr(t){var n,e=t.children;return e&&(n=e.length)?e[n-1]:t._tree.thread}function Dr(t,n){var e=t.children;if(e&&(i=e.length))for(var r,i,u=-1;i>++u;)n(r=Dr(e[u],n),t)>0&&(t=r);return t}function Lr(t,n){return t.x-n.x}function Fr(t,n){return n.x-t.x}function Hr(t,n){return t.depth-n.depth}function Rr(t,n){function e(t,r){var i=t.children;if(i&&(a=i.length))for(var u,a,o=null,c=-1;a>++c;)u=i[c],e(u,o),o=u;n(t,r)}e(t,null)}function Pr(t){for(var n,e=0,r=0,i=t.children,u=i.length;--u>=0;)n=i[u]._tree,n.prelim+=e,n.mod+=e,e+=n.shift+(r+=n.change)}function jr(t,n,e){t=t._tree,n=n._tree;var r=e/(n.number-t.number);t.change+=r,n.change-=r,n.shift+=e,n.prelim+=e,n.mod+=e}function Or(t,n,e){return t._tree.ancestor.parent==n.parent?t._tree.ancestor:e}function Yr(t){return{x:t.x,y:t.y,dx:t.dx,dy:t.dy}}function Ur(t,n){var e=t.x+n[3],r=t.y+n[0],i=t.dx-n[1]-n[3],u=t.dy-n[0]-n[2];return 0>i&&(e+=i/2,i=0),0>u&&(r+=u/2,u=0),{x:e,y:r,dx:i,dy:u}}function Ir(t,n){function e(t,e){return d3.xhr(t,n,e).response(r)}function r(t){return e.parse(t.responseText)}function i(n){return n.map(u).join(t)}function u(t){return a.test(t)?'"'+t.replace(/\"/g,'""')+'"':t}var a=RegExp('["'+t+"\n]"),o=t.charCodeAt(0);return e.parse=function(t){var n;return e.parseRows(t,function(t){return n?n(t):(n=Function("d","return {"+t.map(function(t,n){return JSON.stringify(t)+": d["+n+"]"}).join(",")+"}"),void 0)})},e.parseRows=function(t,n){function e(){if(s>=l)return a;if(i)return i=!1,u;var n=s;if(34===t.charCodeAt(n)){for(var e=n;l>e++;)if(34===t.charCodeAt(e)){if(34!==t.charCodeAt(e+1))break;++e}s=e+2;var r=t.charCodeAt(e+1);return 13===r?(i=!0,10===t.charCodeAt(e+2)&&++s):10===r&&(i=!0),t.substring(n+1,e).replace(/""/g,'"')}for(;l>s;){var r=t.charCodeAt(s++),c=1;if(10===r)i=!0;else if(13===r)i=!0,10===t.charCodeAt(s)&&(++s,++c);else if(r!==o)continue;return t.substring(n,s-c)}return t.substring(n)}for(var r,i,u={},a={},c=[],l=t.length,s=0,f=0;(r=e())!==a;){for(var h=[];r!==u&&r!==a;)h.push(r),r=e();(!n||(h=n(h,f++)))&&c.push(h)}return c},e.format=function(t){return t.map(i).join("\n")},e}function Vr(t,n){no.hasOwnProperty(t.type)&&no[t.type](t,n)}function Xr(t,n,e){var r,i=-1,u=t.length-e;for(n.lineStart();u>++i;)r=t[i],n.point(r[0],r[1]);n.lineEnd()}function Zr(t,n){var e=-1,r=t.length;for(n.polygonStart();r>++e;)Xr(t[e],n,1);n.polygonEnd()}function Br(t){return[Math.atan2(t[1],t[0]),Math.asin(Math.max(-1,Math.min(1,t[2])))]}function $r(t,n){return Pu>Math.abs(t[0]-n[0])&&Pu>Math.abs(t[1]-n[1])}function Jr(t){var n=t[0],e=t[1],r=Math.cos(e);return[r*Math.cos(n),r*Math.sin(n),Math.sin(e)]}function Gr(t,n){return t[0]*n[0]+t[1]*n[1]+t[2]*n[2]}function Kr(t,n){return[t[1]*n[2]-t[2]*n[1],t[2]*n[0]-t[0]*n[2],t[0]*n[1]-t[1]*n[0]]}function Wr(t,n){t[0]+=n[0],t[1]+=n[1],t[2]+=n[2]}function Qr(t,n){return[t[0]*n,t[1]*n,t[2]*n]}function ti(t){var n=Math.sqrt(t[0]*t[0]+t[1]*t[1]+t[2]*t[2]);t[0]/=n,t[1]/=n,t[2]/=n}function ni(t){function n(n){function r(e,r){e=t(e,r),n.point(e[0],e[1])}function u(){s=0/0,p.point=a,n.lineStart()}function a(r,u){var a=Jr([r,u]),o=t(r,u);e(s,f,l,h,d,g,s=o[0],f=o[1],l=r,h=a[0],d=a[1],g=a[2],i,n),n.point(s,f)}function o(){p.point=r,n.lineEnd()}function c(){var t,r,c,m,v,y,M;u(),p.point=function(n,e){a(t=n,r=e),c=s,m=f,v=h,y=d,M=g,p.point=a},p.lineEnd=function(){e(s,f,l,h,d,g,c,m,t,v,y,M,i,n),p.lineEnd=o,o()}}var l,s,f,h,d,g,p={point:r,lineStart:u,lineEnd:o,polygonStart:function(){n.polygonStart(),p.lineStart=c},polygonEnd:function(){n.polygonEnd(),p.lineStart=u}};return p}function e(n,i,u,a,o,c,l,s,f,h,d,g,p,m){var v=l-n,y=s-i,M=v*v+y*y;if(M>4*r&&p--){var b=a+h,x=o+d,_=c+g,w=Math.sqrt(b*b+x*x+_*_),S=Math.asin(_/=w),k=Pu>Math.abs(Math.abs(_)-1)?(u+f)/2:Math.atan2(x,b),E=t(k,S),A=E[0],N=E[1],T=A-n,q=N-i,C=y*T-v*q;(C*C/M>r||Math.abs((v*T+y*q)/M-.5)>.3)&&(e(n,i,u,a,o,c,A,N,k,b/=w,x/=w,_,p,m),m.point(A,N),e(A,N,k,b,x,_,l,s,f,h,d,g,p,m))}}var r=.5,i=16;return n.precision=function(t){return arguments.length?(i=(r=t*t)>0&&16,n):Math.sqrt(r)},n}function ei(t,n){function e(t,n){var e=Math.sqrt(u-2*i*Math.sin(n))/i;return[e*Math.sin(t*=i),a-e*Math.cos(t)]}var r=Math.sin(t),i=(r+Math.sin(n))/2,u=1+r*(2*i-r),a=Math.sqrt(u)/i;return e.invert=function(t,n){var e=a-n;return[Math.atan2(t,e)/i,Math.asin((u-(t*t+e*e)*i*i)/(2*i))]},e}function ri(t){function n(t,n){r>t&&(r=t),t>u&&(u=t),i>n&&(i=n),n>a&&(a=n)}function e(){o.point=o.lineEnd=Pn}var r,i,u,a,o={point:n,lineStart:Pn,lineEnd:Pn,polygonStart:function(){o.lineEnd=e},polygonEnd:function(){o.point=n}};return function(n){return a=u=-(r=i=1/0),d3.geo.stream(n,t(o)),[[r,i],[u,a]]}}function ii(t,n){if(!io){++uo,t*=ju;var e=Math.cos(n*=ju);ao+=(e*Math.cos(t)-ao)/uo,oo+=(e*Math.sin(t)-oo)/uo,co+=(Math.sin(n)-co)/uo}}function ui(){var t,n;io=1,ai(),io=2;var e=lo.point;lo.point=function(r,i){e(t=r,n=i)},lo.lineEnd=function(){lo.point(t,n),oi(),lo.lineEnd=oi}}function ai(){function t(t,i){t*=ju;var u=Math.cos(i*=ju),a=u*Math.cos(t),o=u*Math.sin(t),c=Math.sin(i),l=Math.atan2(Math.sqrt((l=e*c-r*o)*l+(l=r*a-n*c)*l+(l=n*o-e*a)*l),n*a+e*o+r*c);uo+=l,ao+=l*(n+(n=a)),oo+=l*(e+(e=o)),co+=l*(r+(r=c))}var n,e,r;io>1||(1>io&&(io=1,uo=ao=oo=co=0),lo.point=function(i,u){i*=ju;var a=Math.cos(u*=ju);n=a*Math.cos(i),e=a*Math.sin(i),r=Math.sin(u),lo.point=t})}function oi(){lo.point=ii}function ci(t,n){var e=Math.cos(t),r=Math.sin(t);return function(i,u,a,o){null!=i?(i=li(e,i),u=li(e,u),(a>0?u>i:i>u)&&(i+=2*a*Ru)):(i=t+2*a*Ru,u=t);for(var c,l=a*n,s=i;a>0?s>u:u>s;s-=l)o.point((c=Br([e,-r*Math.cos(s),-r*Math.sin(s)]))[0],c[1])}}function li(t,n){var e=Jr(n);e[0]-=t,ti(e);var r=Math.acos(Math.max(-1,Math.min(1,-e[1])));return((0>-e[2]?-r:r)+2*Math.PI-Pu)%(2*Math.PI)}function si(t,n,e){return function(r){function i(n,e){t(n,e)&&r.point(n,e)}function u(t,n){m.point(t,n)}function a(){v.point=u,m.lineStart()}function o(){v.point=i,m.lineEnd()}function c(t,n){M.point(t,n),p.push([t,n])}function l(){M.lineStart(),p=[]}function s(){c(p[0][0],p[0][1]),M.lineEnd();var t,n=M.clean(),e=y.buffer(),i=e.length;if(!i)return g=!0,d+=mi(p,-1),p=null,void 0;if(p=null,1&n){t=e[0],h+=mi(t,1);var u,i=t.length-1,a=-1;for(r.lineStart();i>++a;)r.point((u=t[a])[0],u[1]);return r.lineEnd(),void 0}i>1&&2&n&&e.push(e.pop().concat(e.shift())),f.push(e.filter(gi))}var f,h,d,g,p,m=n(r),v={point:i,lineStart:a,lineEnd:o,polygonStart:function(){v.point=c,v.lineStart=l,v.lineEnd=s,g=!1,d=h=0,f=[],r.polygonStart() +},polygonEnd:function(){v.point=i,v.lineStart=a,v.lineEnd=o,f=d3.merge(f),f.length?fi(f,e,r):(-Pu>h||g&&-Pu>d)&&(r.lineStart(),e(null,null,1,r),r.lineEnd()),r.polygonEnd(),f=null},sphere:function(){r.polygonStart(),r.lineStart(),e(null,null,1,r),r.lineEnd(),r.polygonEnd()}},y=pi(),M=n(y);return v}}function fi(t,n,e){var r=[],i=[];if(t.forEach(function(t){var n=t.length;if(!(1>=n)){var e=t[0],u=t[n-1],a={point:e,points:t,other:null,visited:!1,entry:!0,subject:!0},o={point:e,points:[e],other:a,visited:!1,entry:!1,subject:!1};a.other=o,r.push(a),i.push(o),a={point:u,points:[u],other:null,visited:!1,entry:!1,subject:!0},o={point:u,points:[u],other:a,visited:!1,entry:!0,subject:!1},a.other=o,r.push(a),i.push(o)}}),i.sort(di),hi(r),hi(i),r.length)for(var u,a,o,c=r[0];;){for(u=c;u.visited;)if((u=u.next)===c)return;a=u.points,e.lineStart();do{if(u.visited=u.other.visited=!0,u.entry){if(u.subject)for(var l=0;a.length>l;l++)e.point((o=a[l])[0],o[1]);else n(u.point,u.next.point,1,e);u=u.next}else{if(u.subject){a=u.prev.points;for(var l=a.length;--l>=0;)e.point((o=a[l])[0],o[1])}else n(u.point,u.prev.point,-1,e);u=u.prev}u=u.other,a=u.points}while(!u.visited);e.lineEnd()}}function hi(t){if(n=t.length){for(var n,e,r=0,i=t[0];n>++r;)i.next=e=t[r],e.prev=i,i=e;i.next=e=t[0],e.prev=i}}function di(t,n){return(0>(t=t.point)[0]?t[1]-Ru/2-Pu:Ru/2-t[1])-(0>(n=n.point)[0]?n[1]-Ru/2-Pu:Ru/2-n[1])}function gi(t){return t.length>1}function pi(){var t,n=[];return{lineStart:function(){n.push(t=[])},point:function(n,e){t.push([n,e])},lineEnd:Pn,buffer:function(){var e=n;return n=[],t=null,e}}}function mi(t,n){if(!(e=t.length))return 0;for(var e,r,i,u=0,a=0,o=t[0],c=o[0],l=o[1],s=Math.cos(l),f=Math.atan2(n*Math.sin(c)*s,Math.sin(l)),h=1-n*Math.cos(c)*s,d=f;e>++u;)o=t[u],s=Math.cos(l=o[1]),r=Math.atan2(n*Math.sin(c=o[0])*s,Math.sin(l)),i=1-n*Math.cos(c)*s,Pu>Math.abs(h-2)&&Pu>Math.abs(i-2)||(Pu>Math.abs(i)||Pu>Math.abs(h)||(Pu>Math.abs(Math.abs(r-f)-Ru)?i+h>2&&(a+=4*(r-f)):a+=Pu>Math.abs(h-2)?4*(r-d):((3*Ru+r-f)%(2*Ru)-Ru)*(h+i)),d=f,f=r,h=i);return a}function vi(t){var n,e=0/0,r=0/0,i=0/0;return{lineStart:function(){t.lineStart(),n=1},point:function(u,a){var o=u>0?Ru:-Ru,c=Math.abs(u-e);Pu>Math.abs(c-Ru)?(t.point(e,r=(r+a)/2>0?Ru/2:-Ru/2),t.point(i,r),t.lineEnd(),t.lineStart(),t.point(o,r),t.point(u,r),n=0):i!==o&&c>=Ru&&(Pu>Math.abs(e-i)&&(e-=i*Pu),Pu>Math.abs(u-o)&&(u-=o*Pu),r=yi(e,r,u,a),t.point(i,r),t.lineEnd(),t.lineStart(),t.point(o,r),n=0),t.point(e=u,r=a),i=o},lineEnd:function(){t.lineEnd(),e=r=0/0},clean:function(){return 2-n}}}function yi(t,n,e,r){var i,u,a=Math.sin(t-e);return Math.abs(a)>Pu?Math.atan((Math.sin(n)*(u=Math.cos(r))*Math.sin(e)-Math.sin(r)*(i=Math.cos(n))*Math.sin(t))/(i*u*a)):(n+r)/2}function Mi(t,n,e,r){var i;if(null==t)i=e*Ru/2,r.point(-Ru,i),r.point(0,i),r.point(Ru,i),r.point(Ru,0),r.point(Ru,-i),r.point(0,-i),r.point(-Ru,-i),r.point(-Ru,0),r.point(-Ru,i);else if(Math.abs(t[0]-n[0])>Pu){var u=(t[0]<n[0]?1:-1)*Ru;i=e*u/2,r.point(-u,i),r.point(0,i),r.point(u,i)}else r.point(n[0],n[1])}function bi(t){function n(t,n){return Math.cos(t)*Math.cos(n)>u}function e(t){var e,i,u,a;return{lineStart:function(){u=i=!1,a=1},point:function(o,c){var l,s=[o,c],f=n(o,c);!e&&(u=i=f)&&t.lineStart(),f!==i&&(l=r(e,s),($r(e,l)||$r(s,l))&&(s[0]+=Pu,s[1]+=Pu,f=n(s[0],s[1]))),f!==i&&(a=0,(i=f)?(t.lineStart(),l=r(s,e),t.point(l[0],l[1])):(l=r(e,s),t.point(l[0],l[1]),t.lineEnd()),e=l),!f||e&&$r(e,s)||t.point(s[0],s[1]),e=s},lineEnd:function(){i&&t.lineEnd(),e=null},clean:function(){return a|(u&&i)<<1}}}function r(t,n){var e=Jr(t,0),r=Jr(n,0),i=[1,0,0],a=Kr(e,r),o=Gr(a,a),c=a[0],l=o-c*c;if(!l)return t;var s=u*o/l,f=-u*c/l,h=Kr(i,a),d=Qr(i,s),g=Qr(a,f);Wr(d,g);var p=h,m=Gr(d,p),v=Gr(p,p),y=Math.sqrt(m*m-v*(Gr(d,d)-1)),M=Qr(p,(-m-y)/v);return Wr(M,d),Br(M)}var i=t*ju,u=Math.cos(i),a=ci(i,6*ju);return si(n,e,a)}function xi(t,n){function e(e,r){return e=t(e,r),n(e[0],e[1])}return t.invert&&n.invert&&(e.invert=function(e,r){return e=n.invert(e,r),e&&t.invert(e[0],e[1])}),e}function _i(t,n){return[t,n]}function wi(t,n,e){var r=d3.range(t,n-Pu,e).concat(n);return function(t){return r.map(function(n){return[t,n]})}}function Si(t,n,e){var r=d3.range(t,n-Pu,e).concat(n);return function(t){return r.map(function(n){return[n,t]})}}function ki(t,n,e,r){function i(t){var n=Math.sin(t*=d)*g,e=Math.sin(d-t)*g,r=e*l+n*f,i=e*s+n*h,u=e*a+n*c;return[Math.atan2(i,r)/ju,Math.atan2(u,Math.sqrt(r*r+i*i))/ju]}var u=Math.cos(n),a=Math.sin(n),o=Math.cos(r),c=Math.sin(r),l=u*Math.cos(t),s=u*Math.sin(t),f=o*Math.cos(e),h=o*Math.sin(e),d=Math.acos(Math.max(-1,Math.min(1,a*c+u*o*Math.cos(e-t)))),g=1/Math.sin(d);return i.distance=d,i}function Ei(t,n){return[t/(2*Ru),Math.max(-.5,Math.min(.5,Math.log(Math.tan(Ru/4+n/2))/(2*Ru)))]}function Ai(t){return"m0,"+t+"a"+t+","+t+" 0 1,1 0,"+-2*t+"a"+t+","+t+" 0 1,1 0,"+2*t+"z"}function Ni(t){var n=ni(function(n,e){return t([n*Ou,e*Ou])});return function(t){return t=n(t),{point:function(n,e){t.point(n*ju,e*ju)},sphere:function(){t.sphere()},lineStart:function(){t.lineStart()},lineEnd:function(){t.lineEnd()},polygonStart:function(){t.polygonStart()},polygonEnd:function(){t.polygonEnd()}}}}function Ti(){function t(t,n){a.push("M",t,",",n,u)}function n(t,n){a.push("M",t,",",n),o.point=e}function e(t,n){a.push("L",t,",",n)}function r(){o.point=t}function i(){a.push("Z")}var u=Ai(4.5),a=[],o={point:t,lineStart:function(){o.point=n},lineEnd:r,polygonStart:function(){o.lineEnd=i},polygonEnd:function(){o.lineEnd=r,o.point=t},pointRadius:function(t){return u=Ai(t),o},result:function(){if(a.length){var t=a.join("");return a=[],t}}};return o}function qi(t){function n(n,e){t.moveTo(n,e),t.arc(n,e,a,0,2*Ru)}function e(n,e){t.moveTo(n,e),o.point=r}function r(n,e){t.lineTo(n,e)}function i(){o.point=n}function u(){t.closePath()}var a=4.5,o={point:n,lineStart:function(){o.point=e},lineEnd:i,polygonStart:function(){o.lineEnd=u},polygonEnd:function(){o.lineEnd=i,o.point=n},pointRadius:function(t){return a=t,o},result:Pn};return o}function Ci(){function t(t,n){po+=i*t-r*n,r=t,i=n}var n,e,r,i;mo.point=function(u,a){mo.point=t,n=r=u,e=i=a},mo.lineEnd=function(){t(n,e)}}function zi(t,n){io||(ao+=t,oo+=n,++co)}function Di(){function t(t,r){var i=t-n,u=r-e,a=Math.sqrt(i*i+u*u);ao+=a*(n+t)/2,oo+=a*(e+r)/2,co+=a,n=t,e=r}var n,e;if(1!==io){if(!(1>io))return;io=1,ao=oo=co=0}vo.point=function(r,i){vo.point=t,n=r,e=i}}function Li(){vo.point=zi}function Fi(){function t(t,n){var e=i*t-r*n;ao+=e*(r+t),oo+=e*(i+n),co+=3*e,r=t,i=n}var n,e,r,i;2>io&&(io=2,ao=oo=co=0),vo.point=function(u,a){vo.point=t,n=r=u,e=i=a},vo.lineEnd=function(){t(n,e)}}function Hi(){function t(t,n){if(t*=ju,n*=ju,!(Pu>Math.abs(Math.abs(u)-Ru/2)&&Pu>Math.abs(Math.abs(n)-Ru/2))){var e=Math.cos(n),c=Math.sin(n);if(Pu>Math.abs(u-Ru/2))Mo+=2*(t-r);else{var l=t-i,s=Math.cos(l),f=Math.atan2(Math.sqrt((f=e*Math.sin(l))*f+(f=a*c-o*e*s)*f),o*c+a*e*s),h=(f+Ru+u+n)/4;Mo+=(0>l&&l>-Ru||l>Ru?-4:4)*Math.atan(Math.sqrt(Math.abs(Math.tan(h)*Math.tan(h-f/2)*Math.tan(h-Ru/4-u/2)*Math.tan(h-Ru/4-n/2))))}r=i,i=t,u=n,a=e,o=c}}var n,e,r,i,u,a,o;bo.point=function(c,l){bo.point=t,r=i=(n=c)*ju,u=(e=l)*ju,a=Math.cos(u),o=Math.sin(u)},bo.lineEnd=function(){t(n,e)}}function Ri(t){return Pi(function(){return t})()}function Pi(t){function n(t){return t=a(t[0]*ju,t[1]*ju),[t[0]*s+o,c-t[1]*s]}function e(t){return t=a.invert((t[0]-o)/s,(c-t[1])/s),t&&[t[0]*Ou,t[1]*Ou]}function r(){a=xi(u=Oi(p,m,v),i);var t=i(d,g);return o=f-t[0]*s,c=h+t[1]*s,n}var i,u,a,o,c,l=ni(function(t,n){return t=i(t,n),[t[0]*s+o,c-t[1]*s]}),s=150,f=480,h=250,d=0,g=0,p=0,m=0,v=0,y=so,M=null;return n.stream=function(t){return ji(u,y(l(t)))},n.clipAngle=function(t){return arguments.length?(y=null==t?(M=t,so):bi(M=+t),n):M},n.scale=function(t){return arguments.length?(s=+t,r()):s},n.translate=function(t){return arguments.length?(f=+t[0],h=+t[1],r()):[f,h]},n.center=function(t){return arguments.length?(d=t[0]%360*ju,g=t[1]%360*ju,r()):[d*Ou,g*Ou]},n.rotate=function(t){return arguments.length?(p=t[0]%360*ju,m=t[1]%360*ju,v=t.length>2?t[2]%360*ju:0,r()):[p*Ou,m*Ou,v*Ou]},d3.rebind(n,l,"precision"),function(){return i=t.apply(this,arguments),n.invert=i.invert&&e,r()}}function ji(t,n){return{point:function(e,r){r=t(e*ju,r*ju),e=r[0],n.point(e>Ru?e-2*Ru:-Ru>e?e+2*Ru:e,r[1])},sphere:function(){n.sphere()},lineStart:function(){n.lineStart()},lineEnd:function(){n.lineEnd()},polygonStart:function(){n.polygonStart()},polygonEnd:function(){n.polygonEnd()}}}function Oi(t,n,e){return t?n||e?xi(Ui(t),Ii(n,e)):Ui(t):n||e?Ii(n,e):_i}function Yi(t){return function(n,e){return n+=t,[n>Ru?n-2*Ru:-Ru>n?n+2*Ru:n,e]}}function Ui(t){var n=Yi(t);return n.invert=Yi(-t),n}function Ii(t,n){function e(t,n){var e=Math.cos(n),o=Math.cos(t)*e,c=Math.sin(t)*e,l=Math.sin(n),s=l*r+o*i;return[Math.atan2(c*u-s*a,o*r-l*i),Math.asin(Math.max(-1,Math.min(1,s*u+c*a)))]}var r=Math.cos(t),i=Math.sin(t),u=Math.cos(n),a=Math.sin(n);return e.invert=function(t,n){var e=Math.cos(n),o=Math.cos(t)*e,c=Math.sin(t)*e,l=Math.sin(n),s=l*u-c*a;return[Math.atan2(c*u+l*a,o*r+s*i),Math.asin(Math.max(-1,Math.min(1,s*r-o*i)))]},e}function Vi(t,n){function e(n,e){var r=Math.cos(n),i=Math.cos(e),u=t(r*i);return[u*i*Math.sin(n),u*Math.sin(e)]}return e.invert=function(t,e){var r=Math.sqrt(t*t+e*e),i=n(r),u=Math.sin(i),a=Math.cos(i);return[Math.atan2(t*u,r*a),Math.asin(r&&e*u/r)]},e}function Xi(t,n,e,r){var i,u,a,o,c,l,s;return i=r[t],u=i[0],a=i[1],i=r[n],o=i[0],c=i[1],i=r[e],l=i[0],s=i[1],(s-a)*(o-u)-(c-a)*(l-u)>0}function Zi(t,n,e){return(e[0]-n[0])*(t[1]-n[1])<(e[1]-n[1])*(t[0]-n[0])}function Bi(t,n,e,r){var i=t[0],u=e[0],a=n[0]-i,o=r[0]-u,c=t[1],l=e[1],s=n[1]-c,f=r[1]-l,h=(o*(c-l)-f*(i-u))/(f*a-o*s);return[i+h*a,c+h*s]}function $i(t,n){var e={list:t.map(function(t,n){return{index:n,x:t[0],y:t[1]}}).sort(function(t,n){return t.y<n.y?-1:t.y>n.y?1:t.x<n.x?-1:t.x>n.x?1:0}),bottomSite:null},r={list:[],leftEnd:null,rightEnd:null,init:function(){r.leftEnd=r.createHalfEdge(null,"l"),r.rightEnd=r.createHalfEdge(null,"l"),r.leftEnd.r=r.rightEnd,r.rightEnd.l=r.leftEnd,r.list.unshift(r.leftEnd,r.rightEnd)},createHalfEdge:function(t,n){return{edge:t,side:n,vertex:null,l:null,r:null}},insert:function(t,n){n.l=t,n.r=t.r,t.r.l=n,t.r=n},leftBound:function(t){var n=r.leftEnd;do n=n.r;while(n!=r.rightEnd&&i.rightOf(n,t));return n=n.l},del:function(t){t.l.r=t.r,t.r.l=t.l,t.edge=null},right:function(t){return t.r},left:function(t){return t.l},leftRegion:function(t){return null==t.edge?e.bottomSite:t.edge.region[t.side]},rightRegion:function(t){return null==t.edge?e.bottomSite:t.edge.region[_o[t.side]]}},i={bisect:function(t,n){var e={region:{l:t,r:n},ep:{l:null,r:null}},r=n.x-t.x,i=n.y-t.y,u=r>0?r:-r,a=i>0?i:-i;return e.c=t.x*r+t.y*i+.5*(r*r+i*i),u>a?(e.a=1,e.b=i/r,e.c/=r):(e.b=1,e.a=r/i,e.c/=i),e},intersect:function(t,n){var e=t.edge,r=n.edge;if(!e||!r||e.region.r==r.region.r)return null;var i=e.a*r.b-e.b*r.a;if(1e-10>Math.abs(i))return null;var u,a,o=(e.c*r.b-r.c*e.b)/i,c=(r.c*e.a-e.c*r.a)/i,l=e.region.r,s=r.region.r;l.y<s.y||l.y==s.y&&l.x<s.x?(u=t,a=e):(u=n,a=r);var f=o>=a.region.r.x;return f&&"l"===u.side||!f&&"r"===u.side?null:{x:o,y:c}},rightOf:function(t,n){var e=t.edge,r=e.region.r,i=n.x>r.x;if(i&&"l"===t.side)return 1;if(!i&&"r"===t.side)return 0;if(1===e.a){var u=n.y-r.y,a=n.x-r.x,o=0,c=0;if(!i&&0>e.b||i&&e.b>=0?c=o=u>=e.b*a:(c=n.x+n.y*e.b>e.c,0>e.b&&(c=!c),c||(o=1)),!o){var l=r.x-e.region.l.x;c=e.b*(a*a-u*u)<l*u*(1+2*a/l+e.b*e.b),0>e.b&&(c=!c)}}else{var s=e.c-e.a*n.x,f=n.y-s,h=n.x-r.x,d=s-r.y;c=f*f>h*h+d*d}return"l"===t.side?c:!c},endPoint:function(t,e,r){t.ep[e]=r,t.ep[_o[e]]&&n(t)},distance:function(t,n){var e=t.x-n.x,r=t.y-n.y;return Math.sqrt(e*e+r*r)}},u={list:[],insert:function(t,n,e){t.vertex=n,t.ystar=n.y+e;for(var r=0,i=u.list,a=i.length;a>r;r++){var o=i[r];if(!(t.ystar>o.ystar||t.ystar==o.ystar&&n.x>o.vertex.x))break}i.splice(r,0,t)},del:function(t){for(var n=0,e=u.list,r=e.length;r>n&&e[n]!=t;++n);e.splice(n,1)},empty:function(){return 0===u.list.length},nextEvent:function(t){for(var n=0,e=u.list,r=e.length;r>n;++n)if(e[n]==t)return e[n+1];return null},min:function(){var t=u.list[0];return{x:t.vertex.x,y:t.ystar}},extractMin:function(){return u.list.shift()}};r.init(),e.bottomSite=e.list.shift();for(var a,o,c,l,s,f,h,d,g,p,m,v,y,M=e.list.shift();;)if(u.empty()||(a=u.min()),M&&(u.empty()||M.y<a.y||M.y==a.y&&M.x<a.x))o=r.leftBound(M),c=r.right(o),h=r.rightRegion(o),v=i.bisect(h,M),f=r.createHalfEdge(v,"l"),r.insert(o,f),p=i.intersect(o,f),p&&(u.del(o),u.insert(o,p,i.distance(p,M))),o=f,f=r.createHalfEdge(v,"r"),r.insert(o,f),p=i.intersect(f,c),p&&u.insert(f,p,i.distance(p,M)),M=e.list.shift();else{if(u.empty())break;o=u.extractMin(),l=r.left(o),c=r.right(o),s=r.right(c),h=r.leftRegion(o),d=r.rightRegion(c),m=o.vertex,i.endPoint(o.edge,o.side,m),i.endPoint(c.edge,c.side,m),r.del(o),u.del(c),r.del(c),y="l",h.y>d.y&&(g=h,h=d,d=g,y="r"),v=i.bisect(h,d),f=r.createHalfEdge(v,y),r.insert(l,f),i.endPoint(v,_o[y],m),p=i.intersect(l,f),p&&(u.del(l),u.insert(l,p,i.distance(p,h))),p=i.intersect(f,s),p&&u.insert(f,p,i.distance(p,h))}for(o=r.right(r.leftEnd);o!=r.rightEnd;o=r.right(o))n(o.edge)}function Ji(){return{leaf:!0,nodes:[],point:null}}function Gi(t,n,e,r,i,u){if(!t(n,e,r,i,u)){var a=.5*(e+i),o=.5*(r+u),c=n.nodes;c[0]&&Gi(t,c[0],e,r,a,o),c[1]&&Gi(t,c[1],a,r,i,o),c[2]&&Gi(t,c[2],e,o,a,u),c[3]&&Gi(t,c[3],a,o,i,u)}}function Ki(){this._=new Date(arguments.length>1?Date.UTC.apply(this,arguments):arguments[0])}function Wi(t,n,e,r){for(var i,u,a=0,o=n.length,c=e.length;o>a;){if(r>=c)return-1;if(i=n.charCodeAt(a++),37===i){if(u=Yo[n.charAt(a++)],!u||0>(r=u(t,e,r)))return-1}else if(i!=e.charCodeAt(r++))return-1}return r}function Qi(t){return RegExp("^(?:"+t.map(d3.requote).join("|")+")","i")}function tu(t){for(var n=new u,e=-1,r=t.length;r>++e;)n.set(t[e].toLowerCase(),e);return n}function nu(t,n,e){t+="";var r=t.length;return e>r?Array(e-r+1).join(n)+t:t}function eu(t,n,e){Lo.lastIndex=0;var r=Lo.exec(n.substring(e));return r?e+=r[0].length:-1}function ru(t,n,e){Do.lastIndex=0;var r=Do.exec(n.substring(e));return r?e+=r[0].length:-1}function iu(t,n,e){Ro.lastIndex=0;var r=Ro.exec(n.substring(e));return r?(t.m=Po.get(r[0].toLowerCase()),e+=r[0].length):-1}function uu(t,n,e){Fo.lastIndex=0;var r=Fo.exec(n.substring(e));return r?(t.m=Ho.get(r[0].toLowerCase()),e+=r[0].length):-1}function au(t,n,e){return Wi(t,""+Oo.c,n,e)}function ou(t,n,e){return Wi(t,""+Oo.x,n,e)}function cu(t,n,e){return Wi(t,""+Oo.X,n,e)}function lu(t,n,e){Uo.lastIndex=0;var r=Uo.exec(n.substring(e,e+4));return r?(t.y=+r[0],e+=r[0].length):-1}function su(t,n,e){Uo.lastIndex=0;var r=Uo.exec(n.substring(e,e+2));return r?(t.y=fu(+r[0]),e+=r[0].length):-1}function fu(t){return t+(t>68?1900:2e3)}function hu(t,n,e){Uo.lastIndex=0;var r=Uo.exec(n.substring(e,e+2));return r?(t.m=r[0]-1,e+=r[0].length):-1}function du(t,n,e){Uo.lastIndex=0;var r=Uo.exec(n.substring(e,e+2));return r?(t.d=+r[0],e+=r[0].length):-1}function gu(t,n,e){Uo.lastIndex=0;var r=Uo.exec(n.substring(e,e+2));return r?(t.H=+r[0],e+=r[0].length):-1}function pu(t,n,e){Uo.lastIndex=0;var r=Uo.exec(n.substring(e,e+2));return r?(t.M=+r[0],e+=r[0].length):-1}function mu(t,n,e){Uo.lastIndex=0;var r=Uo.exec(n.substring(e,e+2));return r?(t.S=+r[0],e+=r[0].length):-1}function vu(t,n,e){Uo.lastIndex=0;var r=Uo.exec(n.substring(e,e+3));return r?(t.L=+r[0],e+=r[0].length):-1}function yu(t,n,e){var r=Io.get(n.substring(e,e+=2).toLowerCase());return null==r?-1:(t.p=r,e)}function Mu(t){var n=t.getTimezoneOffset(),e=n>0?"-":"+",r=~~(Math.abs(n)/60),i=Math.abs(n)%60;return e+nu(r,"0",2)+nu(i,"0",2)}function bu(t){return t.toISOString()}function xu(t,n,e){function r(n){var e=t(n),r=u(e,1);return r-n>n-e?e:r}function i(e){return n(e=t(new wo(e-1)),1),e}function u(t,e){return n(t=new wo(+t),e),t}function a(t,r,u){var a=i(t),o=[];if(u>1)for(;r>a;)e(a)%u||o.push(new Date(+a)),n(a,1);else for(;r>a;)o.push(new Date(+a)),n(a,1);return o}function o(t,n,e){try{wo=Ki;var r=new Ki;return r._=t,a(r,n,e)}finally{wo=Date}}t.floor=t,t.round=r,t.ceil=i,t.offset=u,t.range=a;var c=t.utc=_u(t);return c.floor=c,c.round=_u(r),c.ceil=_u(i),c.offset=_u(u),c.range=o,t}function _u(t){return function(n,e){try{wo=Ki;var r=new Ki;return r._=n,t(r,e)._}finally{wo=Date}}}function wu(t,n,e){function r(n){return t(n)}return r.invert=function(n){return ku(t.invert(n))},r.domain=function(n){return arguments.length?(t.domain(n),r):t.domain().map(ku)},r.nice=function(t){return r.domain(Yn(r.domain(),function(){return t}))},r.ticks=function(e,i){var u=Su(r.domain());if("function"!=typeof e){var a=u[1]-u[0],o=a/e,c=d3.bisect(Xo,o);if(c==Xo.length)return n.year(u,e);if(!c)return t.ticks(e).map(ku);Math.log(o/Xo[c-1])<Math.log(Xo[c]/o)&&--c,e=n[c],i=e[1],e=e[0].range}return e(u[0],new Date(+u[1]+1),i)},r.tickFormat=function(){return e},r.copy=function(){return wu(t.copy(),n,e)},d3.rebind(r,t,"range","rangeRound","interpolate","clamp")}function Su(t){var n=t[0],e=t[t.length-1];return e>n?[n,e]:[e,n]}function ku(t){return new Date(t)}function Eu(t){return function(n){for(var e=t.length-1,r=t[e];!r[1](n);)r=t[--e];return r[0](n)}}function Au(t){var n=new Date(t,0,1);return n.setFullYear(t),n}function Nu(t){var n=t.getFullYear(),e=Au(n),r=Au(n+1);return n+(t-e)/(r-e)}function Tu(t){var n=new Date(Date.UTC(t,0,1));return n.setUTCFullYear(t),n}function qu(t){var n=t.getUTCFullYear(),e=Tu(n),r=Tu(n+1);return n+(t-e)/(r-e)}var Cu=".",zu=",",Du=[3,3];Date.now||(Date.now=function(){return+new Date});try{document.createElement("div").style.setProperty("opacity",0,"")}catch(Lu){var Fu=CSSStyleDeclaration.prototype,Hu=Fu.setProperty;Fu.setProperty=function(t,n,e){Hu.call(this,t,n+"",e)}}d3={version:"3.0.3"};var Ru=Math.PI,Pu=1e-6,ju=Ru/180,Ou=180/Ru,Yu=i;try{Yu(document.documentElement.childNodes)[0].nodeType}catch(Uu){Yu=r}var Iu=[].__proto__?function(t,n){t.__proto__=n}:function(t,n){for(var e in n)t[e]=n[e]};d3.map=function(t){var n=new u;for(var e in t)n.set(e,t[e]);return n},e(u,{has:function(t){return Vu+t in this},get:function(t){return this[Vu+t]},set:function(t,n){return this[Vu+t]=n},remove:function(t){return t=Vu+t,t in this&&delete this[t]},keys:function(){var t=[];return this.forEach(function(n){t.push(n)}),t},values:function(){var t=[];return this.forEach(function(n,e){t.push(e)}),t},entries:function(){var t=[];return this.forEach(function(n,e){t.push({key:n,value:e})}),t},forEach:function(t){for(var n in this)n.charCodeAt(0)===Xu&&t.call(this,n.substring(1),this[n])}});var Vu="\0",Xu=Vu.charCodeAt(0);d3.functor=c,d3.rebind=function(t,n){for(var e,r=1,i=arguments.length;i>++r;)t[e=arguments[r]]=l(t,n,n[e]);return t},d3.ascending=function(t,n){return n>t?-1:t>n?1:t>=n?0:0/0},d3.descending=function(t,n){return t>n?-1:n>t?1:n>=t?0:0/0},d3.mean=function(t,n){var e,r=t.length,i=0,u=-1,a=0;if(1===arguments.length)for(;r>++u;)s(e=t[u])&&(i+=(e-i)/++a);else for(;r>++u;)s(e=n.call(t,t[u],u))&&(i+=(e-i)/++a);return a?i:void 0},d3.median=function(t,n){return arguments.length>1&&(t=t.map(n)),t=t.filter(s),t.length?d3.quantile(t.sort(d3.ascending),.5):void 0},d3.min=function(t,n){var e,r,i=-1,u=t.length;if(1===arguments.length){for(;u>++i&&(null==(e=t[i])||e!=e);)e=void 0;for(;u>++i;)null!=(r=t[i])&&e>r&&(e=r)}else{for(;u>++i&&(null==(e=n.call(t,t[i],i))||e!=e);)e=void 0;for(;u>++i;)null!=(r=n.call(t,t[i],i))&&e>r&&(e=r)}return e},d3.max=function(t,n){var e,r,i=-1,u=t.length;if(1===arguments.length){for(;u>++i&&(null==(e=t[i])||e!=e);)e=void 0;for(;u>++i;)null!=(r=t[i])&&r>e&&(e=r)}else{for(;u>++i&&(null==(e=n.call(t,t[i],i))||e!=e);)e=void 0;for(;u>++i;)null!=(r=n.call(t,t[i],i))&&r>e&&(e=r)}return e},d3.extent=function(t,n){var e,r,i,u=-1,a=t.length;if(1===arguments.length){for(;a>++u&&(null==(e=i=t[u])||e!=e);)e=i=void 0;for(;a>++u;)null!=(r=t[u])&&(e>r&&(e=r),r>i&&(i=r))}else{for(;a>++u&&(null==(e=i=n.call(t,t[u],u))||e!=e);)e=void 0;for(;a>++u;)null!=(r=n.call(t,t[u],u))&&(e>r&&(e=r),r>i&&(i=r))}return[e,i]},d3.random={normal:function(t,n){var e=arguments.length;return 2>e&&(n=1),1>e&&(t=0),function(){var e,r,i;do e=2*Math.random()-1,r=2*Math.random()-1,i=e*e+r*r;while(!i||i>1);return t+n*e*Math.sqrt(-2*Math.log(i)/i)}},logNormal:function(t,n){var e=arguments.length;2>e&&(n=1),1>e&&(t=0);var r=d3.random.normal();return function(){return Math.exp(t+n*r())}},irwinHall:function(t){return function(){for(var n=0,e=0;t>e;e++)n+=Math.random();return n/t}}},d3.sum=function(t,n){var e,r=0,i=t.length,u=-1;if(1===arguments.length)for(;i>++u;)isNaN(e=+t[u])||(r+=e);else for(;i>++u;)isNaN(e=+n.call(t,t[u],u))||(r+=e);return r},d3.quantile=function(t,n){var e=(t.length-1)*n+1,r=Math.floor(e),i=+t[r-1],u=e-r;return u?i+u*(t[r]-i):i},d3.shuffle=function(t){for(var n,e,r=t.length;r;)e=0|Math.random()*r--,n=t[r],t[r]=t[e],t[e]=n;return t},d3.transpose=function(t){return d3.zip.apply(d3,t)},d3.zip=function(){if(!(r=arguments.length))return[];for(var t=-1,n=d3.min(arguments,f),e=Array(n);n>++t;)for(var r,i=-1,u=e[t]=Array(r);r>++i;)u[i]=arguments[i][t];return e},d3.bisector=function(t){return{left:function(n,e,r,i){for(3>arguments.length&&(r=0),4>arguments.length&&(i=n.length);i>r;){var u=r+i>>>1;e>t.call(n,n[u],u)?r=u+1:i=u}return r},right:function(n,e,r,i){for(3>arguments.length&&(r=0),4>arguments.length&&(i=n.length);i>r;){var u=r+i>>>1;t.call(n,n[u],u)>e?i=u:r=u+1}return r}}};var Zu=d3.bisector(function(t){return t});d3.bisectLeft=Zu.left,d3.bisect=d3.bisectRight=Zu.right,d3.nest=function(){function t(n,o){if(o>=a.length)return r?r.call(i,n):e?n.sort(e):n;for(var c,l,s,f=-1,h=n.length,d=a[o++],g=new u,p={};h>++f;)(s=g.get(c=d(l=n[f])))?s.push(l):g.set(c,[l]);return g.forEach(function(n,e){p[n]=t(e,o)}),p}function n(t,e){if(e>=a.length)return t;var r,i=[],u=o[e++];for(r in t)i.push({key:r,values:n(t[r],e)});return u&&i.sort(function(t,n){return u(t.key,n.key)}),i}var e,r,i={},a=[],o=[];return i.map=function(n){return t(n,0)},i.entries=function(e){return n(t(e,0),0)},i.key=function(t){return a.push(t),i},i.sortKeys=function(t){return o[a.length-1]=t,i},i.sortValues=function(t){return e=t,i},i.rollup=function(t){return r=t,i},i},d3.keys=function(t){var n=[];for(var e in t)n.push(e);return n},d3.values=function(t){var n=[];for(var e in t)n.push(t[e]);return n},d3.entries=function(t){var n=[];for(var e in t)n.push({key:e,value:t[e]});return n},d3.permute=function(t,n){for(var e=[],r=-1,i=n.length;i>++r;)e[r]=t[n[r]];return e},d3.merge=function(t){return Array.prototype.concat.apply([],t)},d3.range=function(t,n,e){if(3>arguments.length&&(e=1,2>arguments.length&&(n=t,t=0)),1/0===(n-t)/e)throw Error("infinite range");var r,i=[],u=d(Math.abs(e)),a=-1;if(t*=u,n*=u,e*=u,0>e)for(;(r=t+e*++a)>n;)i.push(r/u);else for(;n>(r=t+e*++a);)i.push(r/u);return i},d3.requote=function(t){return t.replace(Bu,"\\$&")};var Bu=/[\\\^\$\*\+\?\|\[\]\(\)\.\{\}]/g;d3.round=function(t,n){return n?Math.round(t*(n=Math.pow(10,n)))/n:Math.round(t)},d3.xhr=function(t,n,e){function r(){var t=l.status;!t&&l.responseText||t>=200&&300>t||304===t?u.load.call(i,c.call(i,l)):u.error.call(i,l)}var i={},u=d3.dispatch("progress","load","error"),o={},c=a,l=new(window.XDomainRequest&&/^(http(s)?:)?\/\//.test(t)?XDomainRequest:XMLHttpRequest);return"onload"in l?l.onload=l.onerror=r:l.onreadystatechange=function(){l.readyState>3&&r()},l.onprogress=function(t){var n=d3.event;d3.event=t;try{u.progress.call(i,l)}finally{d3.event=n}},i.header=function(t,n){return t=(t+"").toLowerCase(),2>arguments.length?o[t]:(null==n?delete o[t]:o[t]=n+"",i)},i.mimeType=function(t){return arguments.length?(n=null==t?null:t+"",i):n},i.response=function(t){return c=t,i},["get","post"].forEach(function(t){i[t]=function(){return i.send.apply(i,[t].concat(Yu(arguments)))}}),i.send=function(e,r,u){if(2===arguments.length&&"function"==typeof r&&(u=r,r=null),l.open(e,t,!0),null==n||"accept"in o||(o.accept=n+",*/*"),l.setRequestHeader)for(var a in o)l.setRequestHeader(a,o[a]);return null!=n&&l.overrideMimeType&&l.overrideMimeType(n),null!=u&&i.on("error",u).on("load",function(t){u(null,t)}),l.send(null==r?null:r),i},i.abort=function(){return l.abort(),i},d3.rebind(i,u,"on"),2===arguments.length&&"function"==typeof n&&(e=n,n=null),null==e?i:i.get(g(e))},d3.text=function(){return d3.xhr.apply(d3,arguments).response(p)},d3.json=function(t,n){return d3.xhr(t,"application/json",n).response(m)},d3.html=function(t,n){return d3.xhr(t,"text/html",n).response(v)},d3.xml=function(){return d3.xhr.apply(d3,arguments).response(y)};var $u={svg:"http://www.w3.org/2000/svg",xhtml:"http://www.w3.org/1999/xhtml",xlink:"http://www.w3.org/1999/xlink",xml:"http://www.w3.org/XML/1998/namespace",xmlns:"http://www.w3.org/2000/xmlns/"};d3.ns={prefix:$u,qualify:function(t){var n=t.indexOf(":"),e=t;return n>=0&&(e=t.substring(0,n),t=t.substring(n+1)),$u.hasOwnProperty(e)?{space:$u[e],local:t}:t}},d3.dispatch=function(){for(var t=new M,n=-1,e=arguments.length;e>++n;)t[arguments[n]]=b(t);return t},M.prototype.on=function(t,n){var e=t.indexOf("."),r="";return e>0&&(r=t.substring(e+1),t=t.substring(0,e)),2>arguments.length?this[t].on(r):this[t].on(r,n)},d3.format=function(t){var n=Ju.exec(t),e=n[1]||" ",r=n[2]||">",i=n[3]||"",u=n[4]||"",a=n[5],o=+n[6],c=n[7],l=n[8],s=n[9],f=1,h="",d=!1;switch(l&&(l=+l.substring(1)),(a||"0"===e&&"="===r)&&(a=e="0",r="=",c&&(o-=Math.floor((o-1)/4))),s){case"n":c=!0,s="g";break;case"%":f=100,h="%",s="f";break;case"p":f=100,h="%",s="r";break;case"b":case"o":case"x":case"X":u&&(u="0"+s.toLowerCase());case"c":case"d":d=!0,l=0;break;case"s":f=-1,s="r"}"#"===u&&(u=""),"r"!=s||l||(s="g"),s=Gu.get(s)||_;var g=a&&c;return function(t){if(d&&t%1)return"";var n=0>t||0===t&&0>1/t?(t=-t,"-"):i;if(0>f){var p=d3.formatPrefix(t,l);t=p.scale(t),h=p.symbol}else t*=f;t=s(t,l),!a&&c&&(t=Ku(t));var m=u.length+t.length+(g?0:n.length),v=o>m?Array(m=o-m+1).join(e):"";return g&&(t=Ku(v+t)),Cu&&t.replace(".",Cu),n+=u,("<"===r?n+t+v:">"===r?v+n+t:"^"===r?v.substring(0,m>>=1)+n+t+v.substring(m):n+(g?t:v+t))+h}};var Ju=/(?:([^{])?([<>=^]))?([+\- ])?(#)?(0)?([0-9]+)?(,)?(\.[0-9]+)?([a-zA-Z%])?/,Gu=d3.map({b:function(t){return t.toString(2)},c:function(t){return String.fromCharCode(t)},o:function(t){return t.toString(8)},x:function(t){return t.toString(16)},X:function(t){return t.toString(16).toUpperCase()},g:function(t,n){return t.toPrecision(n)},e:function(t,n){return t.toExponential(n)},f:function(t,n){return t.toFixed(n)},r:function(t,n){return d3.round(t,n=x(t,n)).toFixed(Math.max(0,Math.min(20,n)))}}),Ku=a;if(Du){var Wu=Du.length;Ku=function(t){for(var n=t.lastIndexOf("."),e=n>=0?"."+t.substring(n+1):(n=t.length,""),r=[],i=0,u=Du[0];n>0&&u>0;)r.push(t.substring(n-=u,n+u)),u=Du[i=(i+1)%Wu];return r.reverse().join(zu||"")+e}}var Qu=["y","z","a","f","p","n","μ","m","","k","M","G","T","P","E","Z","Y"].map(w);d3.formatPrefix=function(t,n){var e=0;return t&&(0>t&&(t*=-1),n&&(t=d3.round(t,x(t,n))),e=1+Math.floor(1e-12+Math.log(t)/Math.LN10),e=Math.max(-24,Math.min(24,3*Math.floor((0>=e?e+1:e-1)/3)))),Qu[8+e/3]};var ta=function(){return a},na=d3.map({linear:ta,poly:q,quad:function(){return A},cubic:function(){return N},sin:function(){return C},exp:function(){return z},circle:function(){return D},elastic:L,back:F,bounce:function(){return H}}),ea=d3.map({"in":a,out:k,"in-out":E,"out-in":function(t){return E(k(t))}});d3.ease=function(t){var n=t.indexOf("-"),e=n>=0?t.substring(0,n):t,r=n>=0?t.substring(n+1):"in";return e=na.get(e)||ta,r=ea.get(r)||a,S(r(e.apply(null,Array.prototype.slice.call(arguments,1))))},d3.event=null,d3.transform=function(t){var n=document.createElementNS(d3.ns.prefix.svg,"g");return(d3.transform=function(t){n.setAttribute("transform",t);var e=n.transform.baseVal.consolidate();return new O(e?e.matrix:ra)})(t)},O.prototype.toString=function(){return"translate("+this.translate+")rotate("+this.rotate+")skewX("+this.skew+")scale("+this.scale+")"};var ra={a:1,b:0,c:0,d:1,e:0,f:0};d3.interpolate=function(t,n){for(var e,r=d3.interpolators.length;--r>=0&&!(e=d3.interpolators[r](t,n)););return e},d3.interpolateNumber=function(t,n){return n-=t,function(e){return t+n*e}},d3.interpolateRound=function(t,n){return n-=t,function(e){return Math.round(t+n*e)}},d3.interpolateString=function(t,n){var e,r,i,u,a,o=0,c=0,l=[],s=[];for(ia.lastIndex=0,r=0;e=ia.exec(n);++r)e.index&&l.push(n.substring(o,c=e.index)),s.push({i:l.length,x:e[0]}),l.push(null),o=ia.lastIndex;for(n.length>o&&l.push(n.substring(o)),r=0,u=s.length;(e=ia.exec(t))&&u>r;++r)if(a=s[r],a.x==e[0]){if(a.i)if(null==l[a.i+1])for(l[a.i-1]+=a.x,l.splice(a.i,1),i=r+1;u>i;++i)s[i].i--;else for(l[a.i-1]+=a.x+l[a.i+1],l.splice(a.i,2),i=r+1;u>i;++i)s[i].i-=2;else if(null==l[a.i+1])l[a.i]=a.x;else for(l[a.i]=a.x+l[a.i+1],l.splice(a.i+1,1),i=r+1;u>i;++i)s[i].i--;s.splice(r,1),u--,r--}else a.x=d3.interpolateNumber(parseFloat(e[0]),parseFloat(a.x));for(;u>r;)a=s.pop(),null==l[a.i+1]?l[a.i]=a.x:(l[a.i]=a.x+l[a.i+1],l.splice(a.i+1,1)),u--;return 1===l.length?null==l[0]?s[0].x:function(){return n}:function(t){for(r=0;u>r;++r)l[(a=s[r]).i]=a.x(t);return l.join("")}},d3.interpolateTransform=function(t,n){var e,r=[],i=[],u=d3.transform(t),a=d3.transform(n),o=u.translate,c=a.translate,l=u.rotate,s=a.rotate,f=u.skew,h=a.skew,d=u.scale,g=a.scale;return o[0]!=c[0]||o[1]!=c[1]?(r.push("translate(",null,",",null,")"),i.push({i:1,x:d3.interpolateNumber(o[0],c[0])},{i:3,x:d3.interpolateNumber(o[1],c[1])})):c[0]||c[1]?r.push("translate("+c+")"):r.push(""),l!=s?(l-s>180?s+=360:s-l>180&&(l+=360),i.push({i:r.push(r.pop()+"rotate(",null,")")-2,x:d3.interpolateNumber(l,s)})):s&&r.push(r.pop()+"rotate("+s+")"),f!=h?i.push({i:r.push(r.pop()+"skewX(",null,")")-2,x:d3.interpolateNumber(f,h)}):h&&r.push(r.pop()+"skewX("+h+")"),d[0]!=g[0]||d[1]!=g[1]?(e=r.push(r.pop()+"scale(",null,",",null,")"),i.push({i:e-4,x:d3.interpolateNumber(d[0],g[0])},{i:e-2,x:d3.interpolateNumber(d[1],g[1])})):(1!=g[0]||1!=g[1])&&r.push(r.pop()+"scale("+g+")"),e=i.length,function(t){for(var n,u=-1;e>++u;)r[(n=i[u]).i]=n.x(t);return r.join("")}},d3.interpolateRgb=function(t,n){t=d3.rgb(t),n=d3.rgb(n);var e=t.r,r=t.g,i=t.b,u=n.r-e,a=n.g-r,o=n.b-i;return function(t){return"#"+G(Math.round(e+u*t))+G(Math.round(r+a*t))+G(Math.round(i+o*t))}},d3.interpolateHsl=function(t,n){t=d3.hsl(t),n=d3.hsl(n);var e=t.h,r=t.s,i=t.l,u=n.h-e,a=n.s-r,o=n.l-i;return u>180?u-=360:-180>u&&(u+=360),function(t){return un(e+u*t,r+a*t,i+o*t)+""}},d3.interpolateLab=function(t,n){t=d3.lab(t),n=d3.lab(n);var e=t.l,r=t.a,i=t.b,u=n.l-e,a=n.a-r,o=n.b-i;return function(t){return fn(e+u*t,r+a*t,i+o*t)+""}},d3.interpolateHcl=function(t,n){t=d3.hcl(t),n=d3.hcl(n);var e=t.h,r=t.c,i=t.l,u=n.h-e,a=n.c-r,o=n.l-i;return u>180?u-=360:-180>u&&(u+=360),function(t){return cn(e+u*t,r+a*t,i+o*t)+""}},d3.interpolateArray=function(t,n){var e,r=[],i=[],u=t.length,a=n.length,o=Math.min(t.length,n.length);for(e=0;o>e;++e)r.push(d3.interpolate(t[e],n[e]));for(;u>e;++e)i[e]=t[e];for(;a>e;++e)i[e]=n[e];return function(t){for(e=0;o>e;++e)i[e]=r[e](t);return i}},d3.interpolateObject=function(t,n){var e,r={},i={};for(e in t)e in n?r[e]=V(e)(t[e],n[e]):i[e]=t[e];for(e in n)e in t||(i[e]=n[e]);return function(t){for(e in r)i[e]=r[e](t);return i}};var ia=/[-+]?(?:\d+\.?\d*|\.?\d+)(?:[eE][-+]?\d+)?/g;d3.interpolators=[d3.interpolateObject,function(t,n){return n instanceof Array&&d3.interpolateArray(t,n)},function(t,n){return("string"==typeof t||"string"==typeof n)&&d3.interpolateString(t+"",n+"")},function(t,n){return("string"==typeof n?aa.has(n)||/^(#|rgb\(|hsl\()/.test(n):n instanceof B)&&d3.interpolateRgb(t,n)},function(t,n){return!isNaN(t=+t)&&!isNaN(n=+n)&&d3.interpolateNumber(t,n)}],B.prototype.toString=function(){return this.rgb()+""},d3.rgb=function(t,n,e){return 1===arguments.length?t instanceof J?$(t.r,t.g,t.b):K(""+t,$,un):$(~~t,~~n,~~e)};var ua=J.prototype=new B;ua.brighter=function(t){t=Math.pow(.7,arguments.length?t:1);var n=this.r,e=this.g,r=this.b,i=30;return n||e||r?(n&&i>n&&(n=i),e&&i>e&&(e=i),r&&i>r&&(r=i),$(Math.min(255,Math.floor(n/t)),Math.min(255,Math.floor(e/t)),Math.min(255,Math.floor(r/t)))):$(i,i,i)},ua.darker=function(t){return t=Math.pow(.7,arguments.length?t:1),$(Math.floor(t*this.r),Math.floor(t*this.g),Math.floor(t*this.b)) +},ua.hsl=function(){return W(this.r,this.g,this.b)},ua.toString=function(){return"#"+G(this.r)+G(this.g)+G(this.b)};var aa=d3.map({aliceblue:"#f0f8ff",antiquewhite:"#faebd7",aqua:"#00ffff",aquamarine:"#7fffd4",azure:"#f0ffff",beige:"#f5f5dc",bisque:"#ffe4c4",black:"#000000",blanchedalmond:"#ffebcd",blue:"#0000ff",blueviolet:"#8a2be2",brown:"#a52a2a",burlywood:"#deb887",cadetblue:"#5f9ea0",chartreuse:"#7fff00",chocolate:"#d2691e",coral:"#ff7f50",cornflowerblue:"#6495ed",cornsilk:"#fff8dc",crimson:"#dc143c",cyan:"#00ffff",darkblue:"#00008b",darkcyan:"#008b8b",darkgoldenrod:"#b8860b",darkgray:"#a9a9a9",darkgreen:"#006400",darkgrey:"#a9a9a9",darkkhaki:"#bdb76b",darkmagenta:"#8b008b",darkolivegreen:"#556b2f",darkorange:"#ff8c00",darkorchid:"#9932cc",darkred:"#8b0000",darksalmon:"#e9967a",darkseagreen:"#8fbc8f",darkslateblue:"#483d8b",darkslategray:"#2f4f4f",darkslategrey:"#2f4f4f",darkturquoise:"#00ced1",darkviolet:"#9400d3",deeppink:"#ff1493",deepskyblue:"#00bfff",dimgray:"#696969",dimgrey:"#696969",dodgerblue:"#1e90ff",firebrick:"#b22222",floralwhite:"#fffaf0",forestgreen:"#228b22",fuchsia:"#ff00ff",gainsboro:"#dcdcdc",ghostwhite:"#f8f8ff",gold:"#ffd700",goldenrod:"#daa520",gray:"#808080",green:"#008000",greenyellow:"#adff2f",grey:"#808080",honeydew:"#f0fff0",hotpink:"#ff69b4",indianred:"#cd5c5c",indigo:"#4b0082",ivory:"#fffff0",khaki:"#f0e68c",lavender:"#e6e6fa",lavenderblush:"#fff0f5",lawngreen:"#7cfc00",lemonchiffon:"#fffacd",lightblue:"#add8e6",lightcoral:"#f08080",lightcyan:"#e0ffff",lightgoldenrodyellow:"#fafad2",lightgray:"#d3d3d3",lightgreen:"#90ee90",lightgrey:"#d3d3d3",lightpink:"#ffb6c1",lightsalmon:"#ffa07a",lightseagreen:"#20b2aa",lightskyblue:"#87cefa",lightslategray:"#778899",lightslategrey:"#778899",lightsteelblue:"#b0c4de",lightyellow:"#ffffe0",lime:"#00ff00",limegreen:"#32cd32",linen:"#faf0e6",magenta:"#ff00ff",maroon:"#800000",mediumaquamarine:"#66cdaa",mediumblue:"#0000cd",mediumorchid:"#ba55d3",mediumpurple:"#9370db",mediumseagreen:"#3cb371",mediumslateblue:"#7b68ee",mediumspringgreen:"#00fa9a",mediumturquoise:"#48d1cc",mediumvioletred:"#c71585",midnightblue:"#191970",mintcream:"#f5fffa",mistyrose:"#ffe4e1",moccasin:"#ffe4b5",navajowhite:"#ffdead",navy:"#000080",oldlace:"#fdf5e6",olive:"#808000",olivedrab:"#6b8e23",orange:"#ffa500",orangered:"#ff4500",orchid:"#da70d6",palegoldenrod:"#eee8aa",palegreen:"#98fb98",paleturquoise:"#afeeee",palevioletred:"#db7093",papayawhip:"#ffefd5",peachpuff:"#ffdab9",peru:"#cd853f",pink:"#ffc0cb",plum:"#dda0dd",powderblue:"#b0e0e6",purple:"#800080",red:"#ff0000",rosybrown:"#bc8f8f",royalblue:"#4169e1",saddlebrown:"#8b4513",salmon:"#fa8072",sandybrown:"#f4a460",seagreen:"#2e8b57",seashell:"#fff5ee",sienna:"#a0522d",silver:"#c0c0c0",skyblue:"#87ceeb",slateblue:"#6a5acd",slategray:"#708090",slategrey:"#708090",snow:"#fffafa",springgreen:"#00ff7f",steelblue:"#4682b4",tan:"#d2b48c",teal:"#008080",thistle:"#d8bfd8",tomato:"#ff6347",turquoise:"#40e0d0",violet:"#ee82ee",wheat:"#f5deb3",white:"#ffffff",whitesmoke:"#f5f5f5",yellow:"#ffff00",yellowgreen:"#9acd32"});aa.forEach(function(t,n){aa.set(t,K(n,$,un))}),d3.hsl=function(t,n,e){return 1===arguments.length?t instanceof rn?en(t.h,t.s,t.l):K(""+t,W,en):en(+t,+n,+e)};var oa=rn.prototype=new B;oa.brighter=function(t){return t=Math.pow(.7,arguments.length?t:1),en(this.h,this.s,this.l/t)},oa.darker=function(t){return t=Math.pow(.7,arguments.length?t:1),en(this.h,this.s,t*this.l)},oa.rgb=function(){return un(this.h,this.s,this.l)},d3.hcl=function(t,n,e){return 1===arguments.length?t instanceof on?an(t.h,t.c,t.l):t instanceof sn?hn(t.l,t.a,t.b):hn((t=Q((t=d3.rgb(t)).r,t.g,t.b)).l,t.a,t.b):an(+t,+n,+e)};var ca=on.prototype=new B;ca.brighter=function(t){return an(this.h,this.c,Math.min(100,this.l+la*(arguments.length?t:1)))},ca.darker=function(t){return an(this.h,this.c,Math.max(0,this.l-la*(arguments.length?t:1)))},ca.rgb=function(){return cn(this.h,this.c,this.l).rgb()},d3.lab=function(t,n,e){return 1===arguments.length?t instanceof sn?ln(t.l,t.a,t.b):t instanceof on?cn(t.l,t.c,t.h):Q((t=d3.rgb(t)).r,t.g,t.b):ln(+t,+n,+e)};var la=18,sa=.95047,fa=1,ha=1.08883,da=sn.prototype=new B;da.brighter=function(t){return ln(Math.min(100,this.l+la*(arguments.length?t:1)),this.a,this.b)},da.darker=function(t){return ln(Math.max(0,this.l-la*(arguments.length?t:1)),this.a,this.b)},da.rgb=function(){return fn(this.l,this.a,this.b)};var ga=function(t,n){return n.querySelector(t)},pa=function(t,n){return n.querySelectorAll(t)},ma=document.documentElement,va=ma.matchesSelector||ma.webkitMatchesSelector||ma.mozMatchesSelector||ma.msMatchesSelector||ma.oMatchesSelector,ya=function(t,n){return va.call(t,n)};"function"==typeof Sizzle&&(ga=function(t,n){return Sizzle(t,n)[0]||null},pa=function(t,n){return Sizzle.uniqueSort(Sizzle(t,n))},ya=Sizzle.matchesSelector);var Ma=[];d3.selection=function(){return ba},d3.selection.prototype=Ma,Ma.select=function(t){var n,e,r,i,u=[];"function"!=typeof t&&(t=vn(t));for(var a=-1,o=this.length;o>++a;){u.push(n=[]),n.parentNode=(r=this[a]).parentNode;for(var c=-1,l=r.length;l>++c;)(i=r[c])?(n.push(e=t.call(i,i.__data__,c)),e&&"__data__"in i&&(e.__data__=i.__data__)):n.push(null)}return mn(u)},Ma.selectAll=function(t){var n,e,r=[];"function"!=typeof t&&(t=yn(t));for(var i=-1,u=this.length;u>++i;)for(var a=this[i],o=-1,c=a.length;c>++o;)(e=a[o])&&(r.push(n=Yu(t.call(e,e.__data__,o))),n.parentNode=e);return mn(r)},Ma.attr=function(t,n){if(2>arguments.length){if("string"==typeof t){var e=this.node();return t=d3.ns.qualify(t),t.local?e.getAttributeNS(t.space,t.local):e.getAttribute(t)}for(n in t)this.each(Mn(n,t[n]));return this}return this.each(Mn(t,n))},Ma.classed=function(t,n){if(2>arguments.length){if("string"==typeof t){var e=this.node(),r=(t=t.trim().split(/^|\s+/g)).length,i=-1;if(n=e.classList){for(;r>++i;)if(!n.contains(t[i]))return!1}else for(n=e.className,null!=n.baseVal&&(n=n.baseVal);r>++i;)if(!bn(t[i]).test(n))return!1;return!0}for(n in t)this.each(xn(n,t[n]));return this}return this.each(xn(t,n))},Ma.style=function(t,n,e){var r=arguments.length;if(3>r){if("string"!=typeof t){2>r&&(n="");for(e in t)this.each(wn(e,t[e],n));return this}if(2>r)return getComputedStyle(this.node(),null).getPropertyValue(t);e=""}return this.each(wn(t,n,e))},Ma.property=function(t,n){if(2>arguments.length){if("string"==typeof t)return this.node()[t];for(n in t)this.each(Sn(n,t[n]));return this}return this.each(Sn(t,n))},Ma.text=function(t){return arguments.length?this.each("function"==typeof t?function(){var n=t.apply(this,arguments);this.textContent=null==n?"":n}:null==t?function(){this.textContent=""}:function(){this.textContent=t}):this.node().textContent},Ma.html=function(t){return arguments.length?this.each("function"==typeof t?function(){var n=t.apply(this,arguments);this.innerHTML=null==n?"":n}:null==t?function(){this.innerHTML=""}:function(){this.innerHTML=t}):this.node().innerHTML},Ma.append=function(t){function n(){return this.appendChild(document.createElementNS(this.namespaceURI,t))}function e(){return this.appendChild(document.createElementNS(t.space,t.local))}return t=d3.ns.qualify(t),this.select(t.local?e:n)},Ma.insert=function(t,n){function e(){return this.insertBefore(document.createElementNS(this.namespaceURI,t),ga(n,this))}function r(){return this.insertBefore(document.createElementNS(t.space,t.local),ga(n,this))}return t=d3.ns.qualify(t),this.select(t.local?r:e)},Ma.remove=function(){return this.each(function(){var t=this.parentNode;t&&t.removeChild(this)})},Ma.data=function(t,n){function e(t,e){var r,i,a,o=t.length,f=e.length,h=Math.min(o,f),d=Array(f),g=Array(f),p=Array(o);if(n){var m,v=new u,y=new u,M=[];for(r=-1;o>++r;)m=n.call(i=t[r],i.__data__,r),v.has(m)?p[r]=i:v.set(m,i),M.push(m);for(r=-1;f>++r;)m=n.call(e,a=e[r],r),(i=v.get(m))?(d[r]=i,i.__data__=a):y.has(m)||(g[r]=kn(a)),y.set(m,a),v.remove(m);for(r=-1;o>++r;)v.has(M[r])&&(p[r]=t[r])}else{for(r=-1;h>++r;)i=t[r],a=e[r],i?(i.__data__=a,d[r]=i):g[r]=kn(a);for(;f>r;++r)g[r]=kn(e[r]);for(;o>r;++r)p[r]=t[r]}g.update=d,g.parentNode=d.parentNode=p.parentNode=t.parentNode,c.push(g),l.push(d),s.push(p)}var r,i,a=-1,o=this.length;if(!arguments.length){for(t=Array(o=(r=this[0]).length);o>++a;)(i=r[a])&&(t[a]=i.__data__);return t}var c=qn([]),l=mn([]),s=mn([]);if("function"==typeof t)for(;o>++a;)e(r=this[a],t.call(r,r.parentNode.__data__,a));else for(;o>++a;)e(r=this[a],t);return l.enter=function(){return c},l.exit=function(){return s},l},Ma.datum=function(t){return arguments.length?this.property("__data__",t):this.property("__data__")},Ma.filter=function(t){var n,e,r,i=[];"function"!=typeof t&&(t=En(t));for(var u=0,a=this.length;a>u;u++){i.push(n=[]),n.parentNode=(e=this[u]).parentNode;for(var o=0,c=e.length;c>o;o++)(r=e[o])&&t.call(r,r.__data__,o)&&n.push(r)}return mn(i)},Ma.order=function(){for(var t=-1,n=this.length;n>++t;)for(var e,r=this[t],i=r.length-1,u=r[i];--i>=0;)(e=r[i])&&(u&&u!==e.nextSibling&&u.parentNode.insertBefore(e,u),u=e);return this},Ma.sort=function(t){t=An.apply(this,arguments);for(var n=-1,e=this.length;e>++n;)this[n].sort(t);return this.order()},Ma.on=function(t,n,e){var r=arguments.length;if(3>r){if("string"!=typeof t){2>r&&(n=!1);for(e in t)this.each(Nn(e,t[e],n));return this}if(2>r)return(r=this.node()["__on"+t])&&r._;e=!1}return this.each(Nn(t,n,e))},Ma.each=function(t){return Tn(this,function(n,e,r){t.call(n,n.__data__,e,r)})},Ma.call=function(t){var n=Yu(arguments);return t.apply(n[0]=this,n),this},Ma.empty=function(){return!this.node()},Ma.node=function(){for(var t=0,n=this.length;n>t;t++)for(var e=this[t],r=0,i=e.length;i>r;r++){var u=e[r];if(u)return u}return null},Ma.transition=function(){var t,n,e=_a||++Sa,r=[],i=Object.create(ka);i.time=Date.now();for(var u=-1,a=this.length;a>++u;){r.push(t=[]);for(var o=this[u],c=-1,l=o.length;l>++c;)(n=o[c])&&zn(n,c,e,i),t.push(n)}return Cn(r,e)};var ba=mn([[document]]);ba[0].parentNode=ma,d3.select=function(t){return"string"==typeof t?ba.select(t):mn([[t]])},d3.selectAll=function(t){return"string"==typeof t?ba.selectAll(t):mn([Yu(t)])};var xa=[];d3.selection.enter=qn,d3.selection.enter.prototype=xa,xa.append=Ma.append,xa.insert=Ma.insert,xa.empty=Ma.empty,xa.node=Ma.node,xa.select=function(t){for(var n,e,r,i,u,a=[],o=-1,c=this.length;c>++o;){r=(i=this[o]).update,a.push(n=[]),n.parentNode=i.parentNode;for(var l=-1,s=i.length;s>++l;)(u=i[l])?(n.push(r[l]=e=t.call(i.parentNode,u.__data__,l)),e.__data__=u.__data__):n.push(null)}return mn(a)};var _a,wa=[],Sa=0,ka={ease:T,delay:0,duration:250};wa.call=Ma.call,wa.empty=Ma.empty,wa.node=Ma.node,d3.transition=function(t){return arguments.length?_a?t.transition():t:ba.transition()},d3.transition.prototype=wa,wa.select=function(t){var n,e,r,i=this.id,u=[];"function"!=typeof t&&(t=vn(t));for(var a=-1,o=this.length;o>++a;){u.push(n=[]);for(var c=this[a],l=-1,s=c.length;s>++l;)(r=c[l])&&(e=t.call(r,r.__data__,l))?("__data__"in r&&(e.__data__=r.__data__),zn(e,l,i,r.__transition__[i]),n.push(e)):n.push(null)}return Cn(u,i)},wa.selectAll=function(t){var n,e,r,i,u,a=this.id,o=[];"function"!=typeof t&&(t=yn(t));for(var c=-1,l=this.length;l>++c;)for(var s=this[c],f=-1,h=s.length;h>++f;)if(r=s[f]){u=r.__transition__[a],e=t.call(r,r.__data__,f),o.push(n=[]);for(var d=-1,g=e.length;g>++d;)zn(i=e[d],d,a,u),n.push(i)}return Cn(o,a)},wa.filter=function(t){var n,e,r,i=[];"function"!=typeof t&&(t=En(t));for(var u=0,a=this.length;a>u;u++){i.push(n=[]);for(var e=this[u],o=0,c=e.length;c>o;o++)(r=e[o])&&t.call(r,r.__data__,o)&&n.push(r)}return Cn(i,this.id,this.time).ease(this.ease())},wa.attr=function(t,n){function e(){this.removeAttribute(u)}function r(){this.removeAttributeNS(u.space,u.local)}if(2>arguments.length){for(n in t)this.attr(n,t[n]);return this}var i=V(t),u=d3.ns.qualify(t);return Ln(this,"attr."+t,n,function(t){function n(){var n,e=this.getAttribute(u);return e!==t&&(n=i(e,t),function(t){this.setAttribute(u,n(t))})}function a(){var n,e=this.getAttributeNS(u.space,u.local);return e!==t&&(n=i(e,t),function(t){this.setAttributeNS(u.space,u.local,n(t))})}return null==t?u.local?r:e:(t+="",u.local?a:n)})},wa.attrTween=function(t,n){function e(t,e){var r=n.call(this,t,e,this.getAttribute(i));return r&&function(t){this.setAttribute(i,r(t))}}function r(t,e){var r=n.call(this,t,e,this.getAttributeNS(i.space,i.local));return r&&function(t){this.setAttributeNS(i.space,i.local,r(t))}}var i=d3.ns.qualify(t);return this.tween("attr."+t,i.local?r:e)},wa.style=function(t,n,e){function r(){this.style.removeProperty(t)}var i=arguments.length;if(3>i){if("string"!=typeof t){2>i&&(n="");for(e in t)this.style(e,t[e],n);return this}e=""}var u=V(t);return Ln(this,"style."+t,n,function(n){function i(){var r,i=getComputedStyle(this,null).getPropertyValue(t);return i!==n&&(r=u(i,n),function(n){this.style.setProperty(t,r(n),e)})}return null==n?r:(n+="",i)})},wa.styleTween=function(t,n,e){return 3>arguments.length&&(e=""),this.tween("style."+t,function(r,i){var u=n.call(this,r,i,getComputedStyle(this,null).getPropertyValue(t));return u&&function(n){this.style.setProperty(t,u(n),e)}})},wa.text=function(t){return Ln(this,"text",t,Dn)},wa.remove=function(){return this.each("end.transition",function(){var t;!this.__transition__&&(t=this.parentNode)&&t.removeChild(this)})},wa.ease=function(t){var n=this.id;return 1>arguments.length?this.node().__transition__[n].ease:("function"!=typeof t&&(t=d3.ease.apply(d3,arguments)),Tn(this,function(e){e.__transition__[n].ease=t}))},wa.delay=function(t){var n=this.id;return Tn(this,"function"==typeof t?function(e,r,i){e.__transition__[n].delay=0|t.call(e,e.__data__,r,i)}:(t|=0,function(e){e.__transition__[n].delay=t}))},wa.duration=function(t){var n=this.id;return Tn(this,"function"==typeof t?function(e,r,i){e.__transition__[n].duration=Math.max(1,0|t.call(e,e.__data__,r,i))}:(t=Math.max(1,0|t),function(e){e.__transition__[n].duration=t}))},wa.each=function(t,n){var e=this.id;if(2>arguments.length){var r=ka,i=_a;_a=e,Tn(this,function(n,r,i){ka=n.__transition__[e],t.call(n,n.__data__,r,i)}),ka=r,_a=i}else Tn(this,function(r){r.__transition__[e].event.on(t,n)});return this},wa.transition=function(){for(var t,n,e,r,i=this.id,u=++Sa,a=[],o=0,c=this.length;c>o;o++){a.push(t=[]);for(var n=this[o],l=0,s=n.length;s>l;l++)(e=n[l])&&(r=Object.create(e.__transition__[i]),r.delay+=r.duration,zn(e,l,u,r)),t.push(e)}return Cn(a,u)},wa.tween=function(t,n){var e=this.id;return 2>arguments.length?this.node().__transition__[e].tween.get(t):Tn(this,null==n?function(n){n.__transition__[e].tween.remove(t)}:function(r){r.__transition__[e].tween.set(t,n)})};var Ea,Aa,Na=0,Ta={},qa=null;d3.timer=function(t,n,e){if(3>arguments.length){if(2>arguments.length)n=0;else if(!isFinite(n))return;e=Date.now()}var r=Ta[t.id];r&&r.callback===t?(r.then=e,r.delay=n):Ta[t.id=++Na]=qa={callback:t,then:e,delay:n,next:qa},Ea||(Aa=clearTimeout(Aa),Ea=1,Ca(Fn))},d3.timer.flush=function(){for(var t,n=Date.now(),e=qa;e;)t=n-e.then,e.delay||(e.flush=e.callback(t)),e=e.next;Hn()};var Ca=window.requestAnimationFrame||window.webkitRequestAnimationFrame||window.mozRequestAnimationFrame||window.oRequestAnimationFrame||window.msRequestAnimationFrame||function(t){setTimeout(t,17)};d3.mouse=function(t){return Rn(t,P())};var za=/WebKit/.test(navigator.userAgent)?-1:0;d3.touches=function(t,n){return 2>arguments.length&&(n=P().touches),n?Yu(n).map(function(n){var e=Rn(t,n);return e.identifier=n.identifier,e}):[]},d3.scale={},d3.scale.linear=function(){return In([0,1],[0,1],d3.interpolate,!1)},d3.scale.log=function(){return Kn(d3.scale.linear(),Wn)};var Da=d3.format(".0e");Wn.pow=function(t){return Math.pow(10,t)},Qn.pow=function(t){return-Math.pow(10,-t)},d3.scale.pow=function(){return te(d3.scale.linear(),1)},d3.scale.sqrt=function(){return d3.scale.pow().exponent(.5)},d3.scale.ordinal=function(){return ee([],{t:"range",a:[[]]})},d3.scale.category10=function(){return d3.scale.ordinal().range(La)},d3.scale.category20=function(){return d3.scale.ordinal().range(Fa)},d3.scale.category20b=function(){return d3.scale.ordinal().range(Ha)},d3.scale.category20c=function(){return d3.scale.ordinal().range(Ra)};var La=["#1f77b4","#ff7f0e","#2ca02c","#d62728","#9467bd","#8c564b","#e377c2","#7f7f7f","#bcbd22","#17becf"],Fa=["#1f77b4","#aec7e8","#ff7f0e","#ffbb78","#2ca02c","#98df8a","#d62728","#ff9896","#9467bd","#c5b0d5","#8c564b","#c49c94","#e377c2","#f7b6d2","#7f7f7f","#c7c7c7","#bcbd22","#dbdb8d","#17becf","#9edae5"],Ha=["#393b79","#5254a3","#6b6ecf","#9c9ede","#637939","#8ca252","#b5cf6b","#cedb9c","#8c6d31","#bd9e39","#e7ba52","#e7cb94","#843c39","#ad494a","#d6616b","#e7969c","#7b4173","#a55194","#ce6dbd","#de9ed6"],Ra=["#3182bd","#6baed6","#9ecae1","#c6dbef","#e6550d","#fd8d3c","#fdae6b","#fdd0a2","#31a354","#74c476","#a1d99b","#c7e9c0","#756bb1","#9e9ac8","#bcbddc","#dadaeb","#636363","#969696","#bdbdbd","#d9d9d9"];d3.scale.quantile=function(){return re([],[])},d3.scale.quantize=function(){return ie(0,1,[0,1])},d3.scale.threshold=function(){return ue([.5],[0,1])},d3.scale.identity=function(){return ae([0,1])},d3.svg={},d3.svg.arc=function(){function t(){var t=n.apply(this,arguments),u=e.apply(this,arguments),a=r.apply(this,arguments)+Pa,o=i.apply(this,arguments)+Pa,c=(a>o&&(c=a,a=o,o=c),o-a),l=Ru>c?"0":"1",s=Math.cos(a),f=Math.sin(a),h=Math.cos(o),d=Math.sin(o);return c>=ja?t?"M0,"+u+"A"+u+","+u+" 0 1,1 0,"+-u+"A"+u+","+u+" 0 1,1 0,"+u+"M0,"+t+"A"+t+","+t+" 0 1,0 0,"+-t+"A"+t+","+t+" 0 1,0 0,"+t+"Z":"M0,"+u+"A"+u+","+u+" 0 1,1 0,"+-u+"A"+u+","+u+" 0 1,1 0,"+u+"Z":t?"M"+u*s+","+u*f+"A"+u+","+u+" 0 "+l+",1 "+u*h+","+u*d+"L"+t*h+","+t*d+"A"+t+","+t+" 0 "+l+",0 "+t*s+","+t*f+"Z":"M"+u*s+","+u*f+"A"+u+","+u+" 0 "+l+",1 "+u*h+","+u*d+"L0,0"+"Z"}var n=oe,e=ce,r=le,i=se;return t.innerRadius=function(e){return arguments.length?(n=c(e),t):n},t.outerRadius=function(n){return arguments.length?(e=c(n),t):e},t.startAngle=function(n){return arguments.length?(r=c(n),t):r},t.endAngle=function(n){return arguments.length?(i=c(n),t):i},t.centroid=function(){var t=(n.apply(this,arguments)+e.apply(this,arguments))/2,u=(r.apply(this,arguments)+i.apply(this,arguments))/2+Pa;return[Math.cos(u)*t,Math.sin(u)*t]},t};var Pa=-Ru/2,ja=2*Ru-1e-6;d3.svg.line=function(){return fe(a)};var Oa=d3.map({linear:ge,"linear-closed":pe,"step-before":me,"step-after":ve,basis:we,"basis-open":Se,"basis-closed":ke,bundle:Ee,cardinal:be,"cardinal-open":ye,"cardinal-closed":Me,monotone:ze});Oa.forEach(function(t,n){n.key=t,n.closed=/-closed$/.test(t)});var Ya=[0,2/3,1/3,0],Ua=[0,1/3,2/3,0],Ia=[0,1/6,2/3,1/6];d3.svg.line.radial=function(){var t=fe(De);return t.radius=t.x,delete t.x,t.angle=t.y,delete t.y,t},me.reverse=ve,ve.reverse=me,d3.svg.area=function(){return Le(a)},d3.svg.area.radial=function(){var t=Le(De);return t.radius=t.x,delete t.x,t.innerRadius=t.x0,delete t.x0,t.outerRadius=t.x1,delete t.x1,t.angle=t.y,delete t.y,t.startAngle=t.y0,delete t.y0,t.endAngle=t.y1,delete t.y1,t},d3.svg.chord=function(){function e(t,n){var e=r(this,o,t,n),c=r(this,l,t,n);return"M"+e.p0+u(e.r,e.p1,e.a1-e.a0)+(i(e,c)?a(e.r,e.p1,e.r,e.p0):a(e.r,e.p1,c.r,c.p0)+u(c.r,c.p1,c.a1-c.a0)+a(c.r,c.p1,e.r,e.p0))+"Z"}function r(t,n,e,r){var i=n.call(t,e,r),u=s.call(t,i,r),a=f.call(t,i,r)+Pa,o=h.call(t,i,r)+Pa;return{r:u,a0:a,a1:o,p0:[u*Math.cos(a),u*Math.sin(a)],p1:[u*Math.cos(o),u*Math.sin(o)]}}function i(t,n){return t.a0==n.a0&&t.a1==n.a1}function u(t,n,e){return"A"+t+","+t+" 0 "+ +(e>Ru)+",1 "+n}function a(t,n,e,r){return"Q 0,0 "+r}var o=n,l=t,s=Fe,f=le,h=se;return e.radius=function(t){return arguments.length?(s=c(t),e):s},e.source=function(t){return arguments.length?(o=c(t),e):o},e.target=function(t){return arguments.length?(l=c(t),e):l},e.startAngle=function(t){return arguments.length?(f=c(t),e):f},e.endAngle=function(t){return arguments.length?(h=c(t),e):h},e},d3.svg.diagonal=function(){function e(t,n){var e=r.call(this,t,n),a=i.call(this,t,n),o=(e.y+a.y)/2,c=[e,{x:e.x,y:o},{x:a.x,y:o},a];return c=c.map(u),"M"+c[0]+"C"+c[1]+" "+c[2]+" "+c[3]}var r=n,i=t,u=He;return e.source=function(t){return arguments.length?(r=c(t),e):r},e.target=function(t){return arguments.length?(i=c(t),e):i},e.projection=function(t){return arguments.length?(u=t,e):u},e},d3.svg.diagonal.radial=function(){var t=d3.svg.diagonal(),n=He,e=t.projection;return t.projection=function(t){return arguments.length?e(Re(n=t)):n},t},d3.svg.symbol=function(){function t(t,r){return(Va.get(n.call(this,t,r))||Oe)(e.call(this,t,r))}var n=je,e=Pe;return t.type=function(e){return arguments.length?(n=c(e),t):n},t.size=function(n){return arguments.length?(e=c(n),t):e},t};var Va=d3.map({circle:Oe,cross:function(t){var n=Math.sqrt(t/5)/2;return"M"+-3*n+","+-n+"H"+-n+"V"+-3*n+"H"+n+"V"+-n+"H"+3*n+"V"+n+"H"+n+"V"+3*n+"H"+-n+"V"+n+"H"+-3*n+"Z"},diamond:function(t){var n=Math.sqrt(t/(2*Za)),e=n*Za;return"M0,"+-n+"L"+e+",0"+" 0,"+n+" "+-e+",0"+"Z"},square:function(t){var n=Math.sqrt(t)/2;return"M"+-n+","+-n+"L"+n+","+-n+" "+n+","+n+" "+-n+","+n+"Z"},"triangle-down":function(t){var n=Math.sqrt(t/Xa),e=n*Xa/2;return"M0,"+e+"L"+n+","+-e+" "+-n+","+-e+"Z"},"triangle-up":function(t){var n=Math.sqrt(t/Xa),e=n*Xa/2;return"M0,"+-e+"L"+n+","+e+" "+-n+","+e+"Z"}});d3.svg.symbolTypes=Va.keys();var Xa=Math.sqrt(3),Za=Math.tan(30*ju);d3.svg.axis=function(){function t(t){t.each(function(){var t,f=d3.select(this),h=null==l?e.ticks?e.ticks.apply(e,c):e.domain():l,d=null==n?e.tickFormat?e.tickFormat.apply(e,c):String:n,g=Ie(e,h,s),p=f.selectAll(".minor").data(g,String),m=p.enter().insert("line","g").attr("class","tick minor").style("opacity",1e-6),v=d3.transition(p.exit()).style("opacity",1e-6).remove(),y=d3.transition(p).style("opacity",1),M=f.selectAll("g").data(h,String),b=M.enter().insert("g","path").style("opacity",1e-6),x=d3.transition(M.exit()).style("opacity",1e-6).remove(),_=d3.transition(M).style("opacity",1),w=On(e),S=f.selectAll(".domain").data([0]),k=d3.transition(S),E=e.copy(),A=this.__chart__||E;this.__chart__=E,S.enter().append("path").attr("class","domain"),b.append("line").attr("class","tick"),b.append("text");var N=b.select("line"),T=_.select("line"),q=M.select("text").text(d),C=b.select("text"),z=_.select("text");switch(r){case"bottom":t=Ye,m.attr("y2",u),y.attr("x2",0).attr("y2",u),N.attr("y2",i),C.attr("y",Math.max(i,0)+o),T.attr("x2",0).attr("y2",i),z.attr("x",0).attr("y",Math.max(i,0)+o),q.attr("dy",".71em").style("text-anchor","middle"),k.attr("d","M"+w[0]+","+a+"V0H"+w[1]+"V"+a);break;case"top":t=Ye,m.attr("y2",-u),y.attr("x2",0).attr("y2",-u),N.attr("y2",-i),C.attr("y",-(Math.max(i,0)+o)),T.attr("x2",0).attr("y2",-i),z.attr("x",0).attr("y",-(Math.max(i,0)+o)),q.attr("dy","0em").style("text-anchor","middle"),k.attr("d","M"+w[0]+","+-a+"V0H"+w[1]+"V"+-a);break;case"left":t=Ue,m.attr("x2",-u),y.attr("x2",-u).attr("y2",0),N.attr("x2",-i),C.attr("x",-(Math.max(i,0)+o)),T.attr("x2",-i).attr("y2",0),z.attr("x",-(Math.max(i,0)+o)).attr("y",0),q.attr("dy",".32em").style("text-anchor","end"),k.attr("d","M"+-a+","+w[0]+"H0V"+w[1]+"H"+-a);break;case"right":t=Ue,m.attr("x2",u),y.attr("x2",u).attr("y2",0),N.attr("x2",i),C.attr("x",Math.max(i,0)+o),T.attr("x2",i).attr("y2",0),z.attr("x",Math.max(i,0)+o).attr("y",0),q.attr("dy",".32em").style("text-anchor","start"),k.attr("d","M"+a+","+w[0]+"H0V"+w[1]+"H"+a)}if(e.ticks)b.call(t,A),_.call(t,E),x.call(t,E),m.call(t,A),y.call(t,E),v.call(t,E);else{var D=E.rangeBand()/2,L=function(t){return E(t)+D};b.call(t,L),_.call(t,L)}})}var n,e=d3.scale.linear(),r="bottom",i=6,u=6,a=6,o=3,c=[10],l=null,s=0;return t.scale=function(n){return arguments.length?(e=n,t):e},t.orient=function(n){return arguments.length?(r=n,t):r},t.ticks=function(){return arguments.length?(c=arguments,t):c},t.tickValues=function(n){return arguments.length?(l=n,t):l},t.tickFormat=function(e){return arguments.length?(n=e,t):n},t.tickSize=function(n,e){if(!arguments.length)return i;var r=arguments.length-1;return i=+n,u=r>1?+e:i,a=r>0?+arguments[r]:i,t},t.tickPadding=function(n){return arguments.length?(o=+n,t):o},t.tickSubdivide=function(n){return arguments.length?(s=+n,t):s},t},d3.svg.brush=function(){function t(u){u.each(function(){var u,a=d3.select(this),s=a.selectAll(".background").data([0]),f=a.selectAll(".extent").data([0]),h=a.selectAll(".resize").data(l,String);a.style("pointer-events","all").on("mousedown.brush",i).on("touchstart.brush",i),s.enter().append("rect").attr("class","background").style("visibility","hidden").style("cursor","crosshair"),f.enter().append("rect").attr("class","extent").style("cursor","move"),h.enter().append("g").attr("class",function(t){return"resize "+t}).style("cursor",function(t){return Ba[t]}).append("rect").attr("x",function(t){return/[ew]$/.test(t)?-3:null}).attr("y",function(t){return/^[ns]/.test(t)?-3:null}).attr("width",6).attr("height",6).style("visibility","hidden"),h.style("display",t.empty()?"none":null),h.exit().remove(),o&&(u=On(o),s.attr("x",u[0]).attr("width",u[1]-u[0]),e(a)),c&&(u=On(c),s.attr("y",u[0]).attr("height",u[1]-u[0]),r(a)),n(a)})}function n(t){t.selectAll(".resize").attr("transform",function(t){return"translate("+s[+/e$/.test(t)][0]+","+s[+/^s/.test(t)][1]+")"})}function e(t){t.select(".extent").attr("x",s[0][0]),t.selectAll(".extent,.n>rect,.s>rect").attr("width",s[1][0]-s[0][0])}function r(t){t.select(".extent").attr("y",s[0][1]),t.selectAll(".extent,.e>rect,.w>rect").attr("height",s[1][1]-s[0][1])}function i(){function i(){var t=d3.event.changedTouches;return t?d3.touches(v,t)[0]:d3.mouse(v)}function l(){32==d3.event.keyCode&&(S||(p=null,k[0]-=s[1][0],k[1]-=s[1][1],S=2),R())}function f(){32==d3.event.keyCode&&2==S&&(k[0]+=s[1][0],k[1]+=s[1][1],S=0,R())}function h(){var t=i(),u=!1;m&&(t[0]+=m[0],t[1]+=m[1]),S||(d3.event.altKey?(p||(p=[(s[0][0]+s[1][0])/2,(s[0][1]+s[1][1])/2]),k[0]=s[+(t[0]<p[0])][0],k[1]=s[+(t[1]<p[1])][1]):p=null),_&&d(t,o,0)&&(e(b),u=!0),w&&d(t,c,1)&&(r(b),u=!0),u&&(n(b),M({type:"brush",mode:S?"move":"resize"}))}function d(t,n,e){var r,i,a=On(n),o=a[0],c=a[1],l=k[e],f=s[1][e]-s[0][e];return S&&(o-=l,c-=f+l),r=Math.max(o,Math.min(c,t[e])),S?i=(r+=l)+f:(p&&(l=Math.max(o,Math.min(c,2*p[e]-r))),r>l?(i=r,r=l):i=l),s[0][e]!==r||s[1][e]!==i?(u=null,s[0][e]=r,s[1][e]=i,!0):void 0}function g(){h(),b.style("pointer-events","all").selectAll(".resize").style("display",t.empty()?"none":null),d3.select("body").style("cursor",null),E.on("mousemove.brush",null).on("mouseup.brush",null).on("touchmove.brush",null).on("touchend.brush",null).on("keydown.brush",null).on("keyup.brush",null),M({type:"brushend"}),R()}var p,m,v=this,y=d3.select(d3.event.target),M=a.of(v,arguments),b=d3.select(v),x=y.datum(),_=!/^(n|s)$/.test(x)&&o,w=!/^(e|w)$/.test(x)&&c,S=y.classed("extent"),k=i(),E=d3.select(window).on("mousemove.brush",h).on("mouseup.brush",g).on("touchmove.brush",h).on("touchend.brush",g).on("keydown.brush",l).on("keyup.brush",f);if(S)k[0]=s[0][0]-k[0],k[1]=s[0][1]-k[1];else if(x){var A=+/w$/.test(x),N=+/^n/.test(x);m=[s[1-A][0]-k[0],s[1-N][1]-k[1]],k[0]=s[A][0],k[1]=s[N][1]}else d3.event.altKey&&(p=k.slice());b.style("pointer-events","none").selectAll(".resize").style("display",null),d3.select("body").style("cursor",y.style("cursor")),M({type:"brushstart"}),h(),R()}var u,a=j(t,"brushstart","brush","brushend"),o=null,c=null,l=$a[0],s=[[0,0],[0,0]];return t.x=function(n){return arguments.length?(o=n,l=$a[!o<<1|!c],t):o},t.y=function(n){return arguments.length?(c=n,l=$a[!o<<1|!c],t):c},t.extent=function(n){var e,r,i,a,l;return arguments.length?(u=[[0,0],[0,0]],o&&(e=n[0],r=n[1],c&&(e=e[0],r=r[0]),u[0][0]=e,u[1][0]=r,o.invert&&(e=o(e),r=o(r)),e>r&&(l=e,e=r,r=l),s[0][0]=0|e,s[1][0]=0|r),c&&(i=n[0],a=n[1],o&&(i=i[1],a=a[1]),u[0][1]=i,u[1][1]=a,c.invert&&(i=c(i),a=c(a)),i>a&&(l=i,i=a,a=l),s[0][1]=0|i,s[1][1]=0|a),t):(n=u||s,o&&(e=n[0][0],r=n[1][0],u||(e=s[0][0],r=s[1][0],o.invert&&(e=o.invert(e),r=o.invert(r)),e>r&&(l=e,e=r,r=l))),c&&(i=n[0][1],a=n[1][1],u||(i=s[0][1],a=s[1][1],c.invert&&(i=c.invert(i),a=c.invert(a)),i>a&&(l=i,i=a,a=l))),o&&c?[[e,i],[r,a]]:o?[e,r]:c&&[i,a])},t.clear=function(){return u=null,s[0][0]=s[0][1]=s[1][0]=s[1][1]=0,t},t.empty=function(){return o&&s[0][0]===s[1][0]||c&&s[0][1]===s[1][1]},d3.rebind(t,a,"on")};var Ba={n:"ns-resize",e:"ew-resize",s:"ns-resize",w:"ew-resize",nw:"nwse-resize",ne:"nesw-resize",se:"nwse-resize",sw:"nesw-resize"},$a=[["n","e","s","w","nw","ne","se","sw"],["e","w"],["n","s"],[]];d3.behavior={},d3.behavior.drag=function(){function t(){this.on("mousedown.drag",n).on("touchstart.drag",n)}function n(){function t(){var t=o.parentNode;return null!=s?d3.touches(t).filter(function(t){return t.identifier===s})[0]:d3.mouse(t)}function n(){if(!o.parentNode)return i();var n=t(),e=n[0]-f[0],r=n[1]-f[1];h|=e|r,f=n,R(),c({type:"drag",x:n[0]+a[0],y:n[1]+a[1],dx:e,dy:r})}function i(){c({type:"dragend"}),h&&(R(),d3.event.target===l&&d.on("click.drag",u,!0)),d.on(null!=s?"touchmove.drag-"+s:"mousemove.drag",null).on(null!=s?"touchend.drag-"+s:"mouseup.drag",null)}function u(){R(),d.on("click.drag",null)}var a,o=this,c=e.of(o,arguments),l=d3.event.target,s=d3.event.touches?d3.event.changedTouches[0].identifier:null,f=t(),h=0,d=d3.select(window).on(null!=s?"touchmove.drag-"+s:"mousemove.drag",n).on(null!=s?"touchend.drag-"+s:"mouseup.drag",i,!0);r?(a=r.apply(o,arguments),a=[a.x-f[0],a.y-f[1]]):a=[0,0],null==s&&R(),c({type:"dragstart"})}var e=j(t,"drag","dragstart","dragend"),r=null;return t.origin=function(n){return arguments.length?(r=n,t):r},d3.rebind(t,e,"on")},d3.behavior.zoom=function(){function t(){this.on("mousedown.zoom",o).on("mousewheel.zoom",c).on("mousemove.zoom",l).on("DOMMouseScroll.zoom",c).on("dblclick.zoom",s).on("touchstart.zoom",f).on("touchmove.zoom",h).on("touchend.zoom",f)}function n(t){return[(t[0]-b[0])/x,(t[1]-b[1])/x]}function e(t){return[t[0]*x+b[0],t[1]*x+b[1]]}function r(t){x=Math.max(_[0],Math.min(_[1],t))}function i(t,n){n=e(n),b[0]+=t[0]-n[0],b[1]+=t[1]-n[1]}function u(){m&&m.domain(p.range().map(function(t){return(t-b[0])/x}).map(p.invert)),y&&y.domain(v.range().map(function(t){return(t-b[1])/x}).map(v.invert))}function a(t){u(),d3.event.preventDefault(),t({type:"zoom",scale:x,translate:b})}function o(){function t(){l=1,i(d3.mouse(u),f),a(o)}function e(){l&&R(),s.on("mousemove.zoom",null).on("mouseup.zoom",null),l&&d3.event.target===c&&s.on("click.zoom",r,!0)}function r(){R(),s.on("click.zoom",null)}var u=this,o=w.of(u,arguments),c=d3.event.target,l=0,s=d3.select(window).on("mousemove.zoom",t).on("mouseup.zoom",e),f=n(d3.mouse(u));window.focus(),R()}function c(){d||(d=n(d3.mouse(this))),r(Math.pow(2,.002*Ve())*x),i(d3.mouse(this),d),a(w.of(this,arguments))}function l(){d=null}function s(){var t=d3.mouse(this),e=n(t),u=Math.log(x)/Math.LN2;r(Math.pow(2,d3.event.shiftKey?Math.ceil(u)-1:Math.floor(u)+1)),i(t,e),a(w.of(this,arguments))}function f(){var t=d3.touches(this),e=Date.now();if(g=x,d={},t.forEach(function(t){d[t.identifier]=n(t)}),R(),1===t.length){if(500>e-M){var u=t[0],o=n(t[0]);r(2*x),i(u,o),a(w.of(this,arguments))}M=e}}function h(){var t=d3.touches(this),n=t[0],e=d[n.identifier];if(u=t[1]){var u,o=d[u.identifier];n=[(n[0]+u[0])/2,(n[1]+u[1])/2],e=[(e[0]+o[0])/2,(e[1]+o[1])/2],r(d3.event.scale*g)}i(n,e),M=null,a(w.of(this,arguments))}var d,g,p,m,v,y,M,b=[0,0],x=1,_=Ga,w=j(t,"zoom");return t.translate=function(n){return arguments.length?(b=n.map(Number),u(),t):b},t.scale=function(n){return arguments.length?(x=+n,u(),t):x},t.scaleExtent=function(n){return arguments.length?(_=null==n?Ga:n.map(Number),t):_},t.x=function(n){return arguments.length?(m=n,p=n.copy(),b=[0,0],x=1,t):m},t.y=function(n){return arguments.length?(y=n,v=n.copy(),b=[0,0],x=1,t):y},d3.rebind(t,w,"on")};var Ja,Ga=[0,1/0];d3.layout={},d3.layout.bundle=function(){return function(t){for(var n=[],e=-1,r=t.length;r>++e;)n.push(Xe(t[e]));return n}},d3.layout.chord=function(){function t(){var t,l,f,h,d,g={},p=[],m=d3.range(u),v=[];for(e=[],r=[],t=0,h=-1;u>++h;){for(l=0,d=-1;u>++d;)l+=i[h][d];p.push(l),v.push(d3.range(u)),t+=l}for(a&&m.sort(function(t,n){return a(p[t],p[n])}),o&&v.forEach(function(t,n){t.sort(function(t,e){return o(i[n][t],i[n][e]) +})}),t=(2*Ru-s*u)/t,l=0,h=-1;u>++h;){for(f=l,d=-1;u>++d;){var y=m[h],M=v[y][d],b=i[y][M],x=l,_=l+=b*t;g[y+"-"+M]={index:y,subindex:M,startAngle:x,endAngle:_,value:b}}r[y]={index:y,startAngle:f,endAngle:l,value:(l-f)/t},l+=s}for(h=-1;u>++h;)for(d=h-1;u>++d;){var w=g[h+"-"+d],S=g[d+"-"+h];(w.value||S.value)&&e.push(w.value<S.value?{source:S,target:w}:{source:w,target:S})}c&&n()}function n(){e.sort(function(t,n){return c((t.source.value+t.target.value)/2,(n.source.value+n.target.value)/2)})}var e,r,i,u,a,o,c,l={},s=0;return l.matrix=function(t){return arguments.length?(u=(i=t)&&i.length,e=r=null,l):i},l.padding=function(t){return arguments.length?(s=t,e=r=null,l):s},l.sortGroups=function(t){return arguments.length?(a=t,e=r=null,l):a},l.sortSubgroups=function(t){return arguments.length?(o=t,e=null,l):o},l.sortChords=function(t){return arguments.length?(c=t,e&&n(),l):c},l.chords=function(){return e||t(),e},l.groups=function(){return r||t(),r},l},d3.layout.force=function(){function t(t){return function(n,e,r,i){if(n.point!==t){var u=n.cx-t.x,a=n.cy-t.y,o=1/Math.sqrt(u*u+a*a);if(v>(i-e)*o){var c=n.charge*o*o;return t.px-=u*c,t.py-=a*c,!0}if(n.point&&isFinite(o)){var c=n.pointCharge*o*o;t.px-=u*c,t.py-=a*c}}return!n.charge}}function n(t){t.px=d3.event.x,t.py=d3.event.y,l.resume()}var e,r,i,u,o,l={},s=d3.dispatch("start","tick","end"),f=[1,1],h=.9,d=Qe,g=tr,p=-30,m=.1,v=.8,y=[],M=[];return l.tick=function(){if(.005>(r*=.99))return s.end({type:"end",alpha:r=0}),!0;var n,e,a,c,l,d,g,v,b,x=y.length,_=M.length;for(e=0;_>e;++e)a=M[e],c=a.source,l=a.target,v=l.x-c.x,b=l.y-c.y,(d=v*v+b*b)&&(d=r*u[e]*((d=Math.sqrt(d))-i[e])/d,v*=d,b*=d,l.x-=v*(g=c.weight/(l.weight+c.weight)),l.y-=b*g,c.x+=v*(g=1-g),c.y+=b*g);if((g=r*m)&&(v=f[0]/2,b=f[1]/2,e=-1,g))for(;x>++e;)a=y[e],a.x+=(v-a.x)*g,a.y+=(b-a.y)*g;if(p)for(We(n=d3.geom.quadtree(y),r,o),e=-1;x>++e;)(a=y[e]).fixed||n.visit(t(a));for(e=-1;x>++e;)a=y[e],a.fixed?(a.x=a.px,a.y=a.py):(a.x-=(a.px-(a.px=a.x))*h,a.y-=(a.py-(a.py=a.y))*h);s.tick({type:"tick",alpha:r})},l.nodes=function(t){return arguments.length?(y=t,l):y},l.links=function(t){return arguments.length?(M=t,l):M},l.size=function(t){return arguments.length?(f=t,l):f},l.linkDistance=function(t){return arguments.length?(d=c(t),l):d},l.distance=l.linkDistance,l.linkStrength=function(t){return arguments.length?(g=c(t),l):g},l.friction=function(t){return arguments.length?(h=t,l):h},l.charge=function(t){return arguments.length?(p="function"==typeof t?t:+t,l):p},l.gravity=function(t){return arguments.length?(m=t,l):m},l.theta=function(t){return arguments.length?(v=t,l):v},l.alpha=function(t){return arguments.length?(r?r=t>0?t:0:t>0&&(s.start({type:"start",alpha:r=t}),d3.timer(l.tick)),l):r},l.start=function(){function t(t,r){for(var i,u=n(e),a=-1,o=u.length;o>++a;)if(!isNaN(i=u[a][t]))return i;return Math.random()*r}function n(){if(!a){for(a=[],r=0;s>r;++r)a[r]=[];for(r=0;h>r;++r){var t=M[r];a[t.source.index].push(t.target),a[t.target.index].push(t.source)}}return a[e]}var e,r,a,c,s=y.length,h=M.length,m=f[0],v=f[1];for(e=0;s>e;++e)(c=y[e]).index=e,c.weight=0;for(i=[],u=[],e=0;h>e;++e)c=M[e],"number"==typeof c.source&&(c.source=y[c.source]),"number"==typeof c.target&&(c.target=y[c.target]),i[e]=d.call(this,c,e),u[e]=g.call(this,c,e),++c.source.weight,++c.target.weight;for(e=0;s>e;++e)c=y[e],isNaN(c.x)&&(c.x=t("x",m)),isNaN(c.y)&&(c.y=t("y",v)),isNaN(c.px)&&(c.px=c.x),isNaN(c.py)&&(c.py=c.y);if(o=[],"function"==typeof p)for(e=0;s>e;++e)o[e]=+p.call(this,y[e],e);else for(e=0;s>e;++e)o[e]=p;return l.resume()},l.resume=function(){return l.alpha(.1)},l.stop=function(){return l.alpha(0)},l.drag=function(){e||(e=d3.behavior.drag().origin(a).on("dragstart",$e).on("drag",n).on("dragend",Je)),this.on("mouseover.force",Ge).on("mouseout.force",Ke).call(e)},d3.rebind(l,s,"on")},d3.layout.partition=function(){function t(n,e,r,i){var u=n.children;if(n.x=e,n.y=n.depth*i,n.dx=r,n.dy=i,u&&(a=u.length)){var a,o,c,l=-1;for(r=n.value?r/n.value:0;a>++l;)t(o=u[l],e,c=o.value*r,i),e+=c}}function n(t){var e=t.children,r=0;if(e&&(i=e.length))for(var i,u=-1;i>++u;)r=Math.max(r,n(e[u]));return 1+r}function e(e,u){var a=r.call(this,e,u);return t(a[0],0,i[0],i[1]/n(a[0])),a}var r=d3.layout.hierarchy(),i=[1,1];return e.size=function(t){return arguments.length?(i=t,e):i},hr(e,r)},d3.layout.pie=function(){function t(u){var a=u.map(function(e,r){return+n.call(t,e,r)}),o=+("function"==typeof r?r.apply(this,arguments):r),c=(("function"==typeof i?i.apply(this,arguments):i)-r)/d3.sum(a),l=d3.range(u.length);null!=e&&l.sort(e===Ka?function(t,n){return a[n]-a[t]}:function(t,n){return e(u[t],u[n])});var s=[];return l.forEach(function(t){var n;s[t]={data:u[t],value:n=a[t],startAngle:o,endAngle:o+=n*c}}),s}var n=Number,e=Ka,r=0,i=2*Ru;return t.value=function(e){return arguments.length?(n=e,t):n},t.sort=function(n){return arguments.length?(e=n,t):e},t.startAngle=function(n){return arguments.length?(r=n,t):r},t.endAngle=function(n){return arguments.length?(i=n,t):i},t};var Ka={};d3.layout.stack=function(){function t(a,c){var l=a.map(function(e,r){return n.call(t,e,r)}),s=l.map(function(n){return n.map(function(n,e){return[u.call(t,n,e),o.call(t,n,e)]})}),f=e.call(t,s,c);l=d3.permute(l,f),s=d3.permute(s,f);var h,d,g,p=r.call(t,s,c),m=l.length,v=l[0].length;for(d=0;v>d;++d)for(i.call(t,l[0][d],g=p[d],s[0][d][1]),h=1;m>h;++h)i.call(t,l[h][d],g+=s[h-1][d][1],s[h][d][1]);return a}var n=a,e=ir,r=ur,i=rr,u=nr,o=er;return t.values=function(e){return arguments.length?(n=e,t):n},t.order=function(n){return arguments.length?(e="function"==typeof n?n:Wa.get(n)||ir,t):e},t.offset=function(n){return arguments.length?(r="function"==typeof n?n:Qa.get(n)||ur,t):r},t.x=function(n){return arguments.length?(u=n,t):u},t.y=function(n){return arguments.length?(o=n,t):o},t.out=function(n){return arguments.length?(i=n,t):i},t};var Wa=d3.map({"inside-out":function(t){var n,e,r=t.length,i=t.map(ar),u=t.map(or),a=d3.range(r).sort(function(t,n){return i[t]-i[n]}),o=0,c=0,l=[],s=[];for(n=0;r>n;++n)e=a[n],c>o?(o+=u[e],l.push(e)):(c+=u[e],s.push(e));return s.reverse().concat(l)},reverse:function(t){return d3.range(t.length).reverse()},"default":ir}),Qa=d3.map({silhouette:function(t){var n,e,r,i=t.length,u=t[0].length,a=[],o=0,c=[];for(e=0;u>e;++e){for(n=0,r=0;i>n;n++)r+=t[n][e][1];r>o&&(o=r),a.push(r)}for(e=0;u>e;++e)c[e]=(o-a[e])/2;return c},wiggle:function(t){var n,e,r,i,u,a,o,c,l,s=t.length,f=t[0],h=f.length,d=[];for(d[0]=c=l=0,e=1;h>e;++e){for(n=0,i=0;s>n;++n)i+=t[n][e][1];for(n=0,u=0,o=f[e][0]-f[e-1][0];s>n;++n){for(r=0,a=(t[n][e][1]-t[n][e-1][1])/(2*o);n>r;++r)a+=(t[r][e][1]-t[r][e-1][1])/o;u+=a*t[n][e][1]}d[e]=c-=i?u/i*o:0,l>c&&(l=c)}for(e=0;h>e;++e)d[e]-=l;return d},expand:function(t){var n,e,r,i=t.length,u=t[0].length,a=1/i,o=[];for(e=0;u>e;++e){for(n=0,r=0;i>n;n++)r+=t[n][e][1];if(r)for(n=0;i>n;n++)t[n][e][1]/=r;else for(n=0;i>n;n++)t[n][e][1]=a}for(e=0;u>e;++e)o[e]=0;return o},zero:ur});d3.layout.histogram=function(){function t(t,u){for(var a,o,c=[],l=t.map(e,this),s=r.call(this,l,u),f=i.call(this,s,l,u),u=-1,h=l.length,d=f.length-1,g=n?1:1/h;d>++u;)a=c[u]=[],a.dx=f[u+1]-(a.x=f[u]),a.y=0;if(d>0)for(u=-1;h>++u;)o=l[u],o>=s[0]&&s[1]>=o&&(a=c[d3.bisect(f,o,1,d)-1],a.y+=g,a.push(t[u]));return c}var n=!0,e=Number,r=fr,i=lr;return t.value=function(n){return arguments.length?(e=n,t):e},t.range=function(n){return arguments.length?(r=c(n),t):r},t.bins=function(n){return arguments.length?(i="number"==typeof n?function(t){return sr(t,n)}:c(n),t):i},t.frequency=function(e){return arguments.length?(n=!!e,t):n},t},d3.layout.hierarchy=function(){function t(n,a,o){var c=i.call(e,n,a);if(n.depth=a,o.push(n),c&&(l=c.length)){for(var l,s,f=-1,h=n.children=[],d=0,g=a+1;l>++f;)s=t(c[f],g,o),s.parent=n,h.push(s),d+=s.value;r&&h.sort(r),u&&(n.value=d)}else u&&(n.value=+u.call(e,n,a)||0);return n}function n(t,r){var i=t.children,a=0;if(i&&(o=i.length))for(var o,c=-1,l=r+1;o>++c;)a+=n(i[c],l);else u&&(a=+u.call(e,t,r)||0);return u&&(t.value=a),a}function e(n){var e=[];return t(n,0,e),e}var r=pr,i=dr,u=gr;return e.sort=function(t){return arguments.length?(r=t,e):r},e.children=function(t){return arguments.length?(i=t,e):i},e.value=function(t){return arguments.length?(u=t,e):u},e.revalue=function(t){return n(t,0),t},e},d3.layout.pack=function(){function t(t,i){var u=n.call(this,t,i),a=u[0];a.x=0,a.y=0,Rr(a,function(t){t.r=Math.sqrt(t.value)}),Rr(a,xr);var o=r[0],c=r[1],l=Math.max(2*a.r/o,2*a.r/c);if(e>0){var s=e*l/2;Rr(a,function(t){t.r+=s}),Rr(a,xr),Rr(a,function(t){t.r-=s}),l=Math.max(2*a.r/o,2*a.r/c)}return Sr(a,o/2,c/2,1/l),u}var n=d3.layout.hierarchy().sort(vr),e=0,r=[1,1];return t.size=function(n){return arguments.length?(r=n,t):r},t.padding=function(n){return arguments.length?(e=+n,t):e},hr(t,n)},d3.layout.cluster=function(){function t(t,i){var u,a=n.call(this,t,i),o=a[0],c=0;Rr(o,function(t){var n=t.children;n&&n.length?(t.x=Ar(n),t.y=Er(n)):(t.x=u?c+=e(t,u):0,t.y=0,u=t)});var l=Nr(o),s=Tr(o),f=l.x-e(l,s)/2,h=s.x+e(s,l)/2;return Rr(o,function(t){t.x=(t.x-f)/(h-f)*r[0],t.y=(1-(o.y?t.y/o.y:1))*r[1]}),a}var n=d3.layout.hierarchy().sort(null).value(null),e=qr,r=[1,1];return t.separation=function(n){return arguments.length?(e=n,t):e},t.size=function(n){return arguments.length?(r=n,t):r},hr(t,n)},d3.layout.tree=function(){function t(t,i){function u(t,n){var r=t.children,i=t._tree;if(r&&(a=r.length)){for(var a,c,l,s=r[0],f=s,h=-1;a>++h;)l=r[h],u(l,c),f=o(l,c,f),c=l;Pr(t);var d=.5*(s._tree.prelim+l._tree.prelim);n?(i.prelim=n._tree.prelim+e(t,n),i.mod=i.prelim-d):i.prelim=d}else n&&(i.prelim=n._tree.prelim+e(t,n))}function a(t,n){t.x=t._tree.prelim+n;var e=t.children;if(e&&(r=e.length)){var r,i=-1;for(n+=t._tree.mod;r>++i;)a(e[i],n)}}function o(t,n,r){if(n){for(var i,u=t,a=t,o=n,c=t.parent.children[0],l=u._tree.mod,s=a._tree.mod,f=o._tree.mod,h=c._tree.mod;o=zr(o),u=Cr(u),o&&u;)c=Cr(c),a=zr(a),a._tree.ancestor=t,i=o._tree.prelim+f-u._tree.prelim-l+e(o,u),i>0&&(jr(Or(o,t,r),t,i),l+=i,s+=i),f+=o._tree.mod,l+=u._tree.mod,h+=c._tree.mod,s+=a._tree.mod;o&&!zr(a)&&(a._tree.thread=o,a._tree.mod+=f-s),u&&!Cr(c)&&(c._tree.thread=u,c._tree.mod+=l-h,r=t)}return r}var c=n.call(this,t,i),l=c[0];Rr(l,function(t,n){t._tree={ancestor:t,prelim:0,mod:0,change:0,shift:0,number:n?n._tree.number+1:0}}),u(l),a(l,-l._tree.prelim);var s=Dr(l,Fr),f=Dr(l,Lr),h=Dr(l,Hr),d=s.x-e(s,f)/2,g=f.x+e(f,s)/2,p=h.depth||1;return Rr(l,function(t){t.x=(t.x-d)/(g-d)*r[0],t.y=t.depth/p*r[1],delete t._tree}),c}var n=d3.layout.hierarchy().sort(null).value(null),e=qr,r=[1,1];return t.separation=function(n){return arguments.length?(e=n,t):e},t.size=function(n){return arguments.length?(r=n,t):r},hr(t,n)},d3.layout.treemap=function(){function t(t,n){for(var e,r,i=-1,u=t.length;u>++i;)r=(e=t[i]).value*(0>n?0:n),e.area=isNaN(r)||0>=r?0:r}function n(e){var u=e.children;if(u&&u.length){var a,o,c,l=f(e),s=[],h=u.slice(),g=1/0,p="slice"===d?l.dx:"dice"===d?l.dy:"slice-dice"===d?1&e.depth?l.dy:l.dx:Math.min(l.dx,l.dy);for(t(h,l.dx*l.dy/e.value),s.area=0;(c=h.length)>0;)s.push(a=h[c-1]),s.area+=a.area,"squarify"!==d||g>=(o=r(s,p))?(h.pop(),g=o):(s.area-=s.pop().area,i(s,p,l,!1),p=Math.min(l.dx,l.dy),s.length=s.area=0,g=1/0);s.length&&(i(s,p,l,!0),s.length=s.area=0),u.forEach(n)}}function e(n){var r=n.children;if(r&&r.length){var u,a=f(n),o=r.slice(),c=[];for(t(o,a.dx*a.dy/n.value),c.area=0;u=o.pop();)c.push(u),c.area+=u.area,null!=u.z&&(i(c,u.z?a.dx:a.dy,a,!o.length),c.length=c.area=0);r.forEach(e)}}function r(t,n){for(var e,r=t.area,i=0,u=1/0,a=-1,o=t.length;o>++a;)(e=t[a].area)&&(u>e&&(u=e),e>i&&(i=e));return r*=r,n*=n,r?Math.max(n*i*g/r,r/(n*u*g)):1/0}function i(t,n,e,r){var i,u=-1,a=t.length,o=e.x,l=e.y,s=n?c(t.area/n):0;if(n==e.dx){for((r||s>e.dy)&&(s=e.dy);a>++u;)i=t[u],i.x=o,i.y=l,i.dy=s,o+=i.dx=Math.min(e.x+e.dx-o,s?c(i.area/s):0);i.z=!0,i.dx+=e.x+e.dx-o,e.y+=s,e.dy-=s}else{for((r||s>e.dx)&&(s=e.dx);a>++u;)i=t[u],i.x=o,i.y=l,i.dx=s,l+=i.dy=Math.min(e.y+e.dy-l,s?c(i.area/s):0);i.z=!1,i.dy+=e.y+e.dy-l,e.x+=s,e.dx-=s}}function u(r){var i=a||o(r),u=i[0];return u.x=0,u.y=0,u.dx=l[0],u.dy=l[1],a&&o.revalue(u),t([u],u.dx*u.dy/u.value),(a?e:n)(u),h&&(a=i),i}var a,o=d3.layout.hierarchy(),c=Math.round,l=[1,1],s=null,f=Yr,h=!1,d="squarify",g=.5*(1+Math.sqrt(5));return u.size=function(t){return arguments.length?(l=t,u):l},u.padding=function(t){function n(n){var e=t.call(u,n,n.depth);return null==e?Yr(n):Ur(n,"number"==typeof e?[e,e,e,e]:e)}function e(n){return Ur(n,t)}if(!arguments.length)return s;var r;return f=null==(s=t)?Yr:"function"==(r=typeof t)?n:"number"===r?(t=[t,t,t,t],e):e,u},u.round=function(t){return arguments.length?(c=t?Math.round:Number,u):c!=Number},u.sticky=function(t){return arguments.length?(h=t,a=null,u):h},u.ratio=function(t){return arguments.length?(g=t,u):g},u.mode=function(t){return arguments.length?(d=t+"",u):d},hr(u,o)},d3.csv=Ir(",","text/csv"),d3.tsv=Ir(" ","text/tab-separated-values"),d3.geo={},d3.geo.stream=function(t,n){to.hasOwnProperty(t.type)?to[t.type](t,n):Vr(t,n)};var to={Feature:function(t,n){Vr(t.geometry,n)},FeatureCollection:function(t,n){for(var e=t.features,r=-1,i=e.length;i>++r;)Vr(e[r].geometry,n)}},no={Sphere:function(t,n){n.sphere()},Point:function(t,n){var e=t.coordinates;n.point(e[0],e[1])},MultiPoint:function(t,n){for(var e,r=t.coordinates,i=-1,u=r.length;u>++i;)e=r[i],n.point(e[0],e[1])},LineString:function(t,n){Xr(t.coordinates,n,0)},MultiLineString:function(t,n){for(var e=t.coordinates,r=-1,i=e.length;i>++r;)Xr(e[r],n,0)},Polygon:function(t,n){Zr(t.coordinates,n)},MultiPolygon:function(t,n){for(var e=t.coordinates,r=-1,i=e.length;i>++r;)Zr(e[r],n)},GeometryCollection:function(t,n){for(var e=t.geometries,r=-1,i=e.length;i>++r;)Vr(e[r],n)}};d3.geo.albersUsa=function(){function t(t){return n(t)(t)}function n(t){var n=t[0],a=t[1];return a>50?r:-140>n?i:21>a?u:e}var e=d3.geo.albers(),r=d3.geo.albers().rotate([160,0]).center([0,60]).parallels([55,65]),i=d3.geo.albers().rotate([160,0]).center([0,20]).parallels([8,18]),u=d3.geo.albers().rotate([60,0]).center([0,10]).parallels([8,18]);return t.scale=function(n){return arguments.length?(e.scale(n),r.scale(.6*n),i.scale(n),u.scale(1.5*n),t.translate(e.translate())):e.scale()},t.translate=function(n){if(!arguments.length)return e.translate();var a=e.scale(),o=n[0],c=n[1];return e.translate(n),r.translate([o-.4*a,c+.17*a]),i.translate([o-.19*a,c+.2*a]),u.translate([o+.58*a,c+.43*a]),t},t.scale(e.scale())},(d3.geo.albers=function(){var t=29.5*ju,n=45.5*ju,e=Pi(ei),r=e(t,n);return r.parallels=function(r){return arguments.length?e(t=r[0]*ju,n=r[1]*ju):[t*Ou,n*Ou]},r.rotate([98,0]).center([0,38]).scale(1e3)}).raw=ei;var eo=Vi(function(t){return Math.sqrt(2/(1+t))},function(t){return 2*Math.asin(t/2)});(d3.geo.azimuthalEqualArea=function(){return Ri(eo)}).raw=eo;var ro=Vi(function(t){var n=Math.acos(t);return n&&n/Math.sin(n)},a);(d3.geo.azimuthalEquidistant=function(){return Ri(ro)}).raw=ro,d3.geo.bounds=ri(a),d3.geo.centroid=function(t){io=uo=ao=oo=co=0,d3.geo.stream(t,lo);var n;return uo&&Math.abs(n=Math.sqrt(ao*ao+oo*oo+co*co))>Pu?[Math.atan2(oo,ao)*Ou,Math.asin(Math.max(-1,Math.min(1,co/n)))*Ou]:void 0};var io,uo,ao,oo,co,lo={sphere:function(){2>io&&(io=2,uo=ao=oo=co=0)},point:ii,lineStart:ai,lineEnd:oi,polygonStart:function(){2>io&&(io=2,uo=ao=oo=co=0),lo.lineStart=ui},polygonEnd:function(){lo.lineStart=ai}};d3.geo.circle=function(){function t(){var t="function"==typeof r?r.apply(this,arguments):r,n=Oi(-t[0]*ju,-t[1]*ju,0).invert,i=[];return e(null,null,1,{point:function(t,e){i.push(t=n(t,e)),t[0]*=Ou,t[1]*=Ou}}),{type:"Polygon",coordinates:[i]}}var n,e,r=[0,0],i=6;return t.origin=function(n){return arguments.length?(r=n,t):r},t.angle=function(r){return arguments.length?(e=ci((n=+r)*ju,i*ju),t):n},t.precision=function(r){return arguments.length?(e=ci(n*ju,(i=+r)*ju),t):i},t.angle(90)};var so=si(o,vi,Mi);(d3.geo.equirectangular=function(){return Ri(_i).scale(250/Ru)}).raw=_i.invert=_i;var fo=Vi(function(t){return 1/t},Math.atan);(d3.geo.gnomonic=function(){return Ri(fo)}).raw=fo,d3.geo.graticule=function(){function t(){return{type:"MultiLineString",coordinates:n()}}function n(){return d3.range(Math.ceil(r/c)*c,e,c).map(a).concat(d3.range(Math.ceil(u/l)*l,i,l).map(o))}var e,r,i,u,a,o,c=22.5,l=c,s=2.5;return t.lines=function(){return n().map(function(t){return{type:"LineString",coordinates:t}})},t.outline=function(){return{type:"Polygon",coordinates:[a(r).concat(o(i).slice(1),a(e).reverse().slice(1),o(u).reverse().slice(1))]}},t.extent=function(n){return arguments.length?(r=+n[0][0],e=+n[1][0],u=+n[0][1],i=+n[1][1],r>e&&(n=r,r=e,e=n),u>i&&(n=u,u=i,i=n),t.precision(s)):[[r,u],[e,i]]},t.step=function(n){return arguments.length?(c=+n[0],l=+n[1],t):[c,l]},t.precision=function(n){return arguments.length?(s=+n,a=wi(u,i,s),o=Si(r,e,s),t):s},t.extent([[-180+Pu,-90+Pu],[180-Pu,90-Pu]])},d3.geo.interpolate=function(t,n){return ki(t[0]*ju,t[1]*ju,n[0]*ju,n[1]*ju)},d3.geo.greatArc=function(){function e(){for(var t=r||a.apply(this,arguments),n=i||o.apply(this,arguments),e=u||d3.geo.interpolate(t,n),i=0,l=c/e.distance,s=[t];1>(i+=l);)s.push(e(i));return s.push(n),{type:"LineString",coordinates:s}}var r,i,u,a=n,o=t,c=6*ju;return e.distance=function(){return(u||d3.geo.interpolate(r||a.apply(this,arguments),i||o.apply(this,arguments))).distance},e.source=function(t){return arguments.length?(a=t,r="function"==typeof t?null:t,u=r&&i?d3.geo.interpolate(r,i):null,e):a},e.target=function(t){return arguments.length?(o=t,i="function"==typeof t?null:t,u=r&&i?d3.geo.interpolate(r,i):null,e):o},e.precision=function(t){return arguments.length?(c=t*ju,e):c/ju},e},Ei.invert=function(t,n){return[2*Ru*t,2*Math.atan(Math.exp(2*Ru*n))-Ru/2]},(d3.geo.mercator=function(){return Ri(Ei).scale(500)}).raw=Ei;var ho=Vi(function(){return 1},Math.asin);(d3.geo.orthographic=function(){return Ri(ho)}).raw=ho,d3.geo.path=function(){function t(t){return t&&d3.geo.stream(t,r(i.pointRadius("function"==typeof u?+u.apply(this,arguments):u))),i.result()}var n,e,r,i,u=4.5;return t.area=function(t){return go=0,d3.geo.stream(t,r(mo)),go},t.centroid=function(t){return io=ao=oo=co=0,d3.geo.stream(t,r(vo)),co?[ao/co,oo/co]:void 0},t.bounds=function(t){return ri(r)(t)},t.projection=function(e){return arguments.length?(r=(n=e)?e.stream||Ni(e):a,t):n},t.context=function(n){return arguments.length?(i=null==(e=n)?new Ti:new qi(n),t):e},t.pointRadius=function(n){return arguments.length?(u="function"==typeof n?n:+n,t):u},t.projection(d3.geo.albersUsa()).context(null)};var go,po,mo={point:Pn,lineStart:Pn,lineEnd:Pn,polygonStart:function(){po=0,mo.lineStart=Ci},polygonEnd:function(){mo.lineStart=mo.lineEnd=mo.point=Pn,go+=Math.abs(po/2)}},vo={point:zi,lineStart:Di,lineEnd:Li,polygonStart:function(){vo.lineStart=Fi},polygonEnd:function(){vo.point=zi,vo.lineStart=Di,vo.lineEnd=Li}};d3.geo.area=function(t){return yo=0,d3.geo.stream(t,bo),yo};var yo,Mo,bo={sphere:function(){yo+=4*Ru},point:Pn,lineStart:Pn,lineEnd:Pn,polygonStart:function(){Mo=0,bo.lineStart=Hi},polygonEnd:function(){yo+=0>Mo?4*Ru+Mo:Mo,bo.lineStart=bo.lineEnd=bo.point=Pn}};d3.geo.projection=Ri,d3.geo.projectionMutator=Pi;var xo=Vi(function(t){return 1/(1+t)},function(t){return 2*Math.atan(t)});(d3.geo.stereographic=function(){return Ri(xo)}).raw=xo,d3.geom={},d3.geom.hull=function(t){if(3>t.length)return[];var n,e,r,i,u,a,o,c,l,s,f=t.length,h=f-1,d=[],g=[],p=0;for(n=1;f>n;++n)t[n][1]<t[p][1]?p=n:t[n][1]==t[p][1]&&(p=t[n][0]<t[p][0]?n:p);for(n=0;f>n;++n)n!==p&&(i=t[n][1]-t[p][1],r=t[n][0]-t[p][0],d.push({angle:Math.atan2(i,r),index:n}));for(d.sort(function(t,n){return t.angle-n.angle}),l=d[0].angle,c=d[0].index,o=0,n=1;h>n;++n)e=d[n].index,l==d[n].angle?(r=t[c][0]-t[p][0],i=t[c][1]-t[p][1],u=t[e][0]-t[p][0],a=t[e][1]-t[p][1],r*r+i*i>=u*u+a*a?d[n].index=-1:(d[o].index=-1,l=d[n].angle,o=n,c=e)):(l=d[n].angle,o=n,c=e);for(g.push(p),n=0,e=0;2>n;++e)-1!==d[e].index&&(g.push(d[e].index),n++);for(s=g.length;h>e;++e)if(-1!==d[e].index){for(;!Xi(g[s-2],g[s-1],d[e].index,t);)--s;g[s++]=d[e].index}var m=[];for(n=0;s>n;++n)m.push(t[g[n]]);return m},d3.geom.polygon=function(t){return t.area=function(){for(var n=0,e=t.length,r=t[e-1][1]*t[0][0]-t[e-1][0]*t[0][1];e>++n;)r+=t[n-1][1]*t[n][0]-t[n-1][0]*t[n][1];return.5*r},t.centroid=function(n){var e,r,i=-1,u=t.length,a=0,o=0,c=t[u-1];for(arguments.length||(n=-1/(6*t.area()));u>++i;)e=c,c=t[i],r=e[0]*c[1]-c[0]*e[1],a+=(e[0]+c[0])*r,o+=(e[1]+c[1])*r;return[a*n,o*n]},t.clip=function(n){for(var e,r,i,u,a,o,c=-1,l=t.length,s=t[l-1];l>++c;){for(e=n.slice(),n.length=0,u=t[c],a=e[(i=e.length)-1],r=-1;i>++r;)o=e[r],Zi(o,s,u)?(Zi(a,s,u)||n.push(Bi(a,o,s,u)),n.push(o)):Zi(a,s,u)&&n.push(Bi(a,o,s,u)),a=o;s=u}return n},t},d3.geom.voronoi=function(t){var n=t.map(function(){return[]}),e=1e6;return $i(t,function(t){var r,i,u,a,o,c;1===t.a&&t.b>=0?(r=t.ep.r,i=t.ep.l):(r=t.ep.l,i=t.ep.r),1===t.a?(o=r?r.y:-e,u=t.c-t.b*o,c=i?i.y:e,a=t.c-t.b*c):(u=r?r.x:-e,o=t.c-t.a*u,a=i?i.x:e,c=t.c-t.a*a);var l=[u,o],s=[a,c];n[t.region.l.index].push(l,s),n[t.region.r.index].push(l,s)}),n=n.map(function(n,e){var r=t[e][0],i=t[e][1],u=n.map(function(t){return Math.atan2(t[0]-r,t[1]-i)});return d3.range(n.length).sort(function(t,n){return u[t]-u[n]}).filter(function(t,n,e){return!n||u[t]-u[e[n-1]]>Pu}).map(function(t){return n[t]})}),n.forEach(function(n,r){var i=n.length;if(!i)return n.push([-e,-e],[-e,e],[e,e],[e,-e]);if(!(i>2)){var u=t[r],a=n[0],o=n[1],c=u[0],l=u[1],s=a[0],f=a[1],h=o[0],d=o[1],g=Math.abs(h-s),p=d-f;if(Pu>Math.abs(p)){var m=f>l?-e:e;n.push([-e,m],[e,m])}else if(Pu>g){var v=s>c?-e:e;n.push([v,-e],[v,e])}else{var m=(s-c)*(d-f)>(h-s)*(f-l)?e:-e,y=Math.abs(p)-g;Pu>Math.abs(y)?n.push([0>p?m:-m,m]):(y>0&&(m*=-1),n.push([-e,m],[e,m]))}}}),n};var _o={l:"r",r:"l"};d3.geom.delaunay=function(t){var n=t.map(function(){return[]}),e=[];return $i(t,function(e){n[e.region.l.index].push(t[e.region.r.index])}),n.forEach(function(n,r){var i=t[r],u=i[0],a=i[1];n.forEach(function(t){t.angle=Math.atan2(t[0]-u,t[1]-a)}),n.sort(function(t,n){return t.angle-n.angle});for(var o=0,c=n.length-1;c>o;o++)e.push([i,n[o],n[o+1]])}),e},d3.geom.quadtree=function(t,n,e,r,i){function u(t,n,e,r,i,u){if(!isNaN(n.x)&&!isNaN(n.y))if(t.leaf){var o=t.point;o?.01>Math.abs(o.x-n.x)+Math.abs(o.y-n.y)?a(t,n,e,r,i,u):(t.point=null,a(t,o,e,r,i,u),a(t,n,e,r,i,u)):t.point=n}else a(t,n,e,r,i,u)}function a(t,n,e,r,i,a){var o=.5*(e+i),c=.5*(r+a),l=n.x>=o,s=n.y>=c,f=(s<<1)+l;t.leaf=!1,t=t.nodes[f]||(t.nodes[f]=Ji()),l?e=o:i=o,s?r=c:a=c,u(t,n,e,r,i,a)}var o,c=-1,l=t.length;if(5>arguments.length)if(3===arguments.length)i=e,r=n,e=n=0;else for(n=e=1/0,r=i=-1/0;l>++c;)o=t[c],n>o.x&&(n=o.x),e>o.y&&(e=o.y),o.x>r&&(r=o.x),o.y>i&&(i=o.y);var s=r-n,f=i-e;s>f?i=e+s:r=n+f;var h=Ji();return h.add=function(t){u(h,t,n,e,r,i)},h.visit=function(t){Gi(t,h,n,e,r,i)},t.forEach(h.add),h},d3.time={};var wo=Date,So=["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"];Ki.prototype={getDate:function(){return this._.getUTCDate()},getDay:function(){return this._.getUTCDay()},getFullYear:function(){return this._.getUTCFullYear()},getHours:function(){return this._.getUTCHours()},getMilliseconds:function(){return this._.getUTCMilliseconds()},getMinutes:function(){return this._.getUTCMinutes()},getMonth:function(){return this._.getUTCMonth()},getSeconds:function(){return this._.getUTCSeconds()},getTime:function(){return this._.getTime()},getTimezoneOffset:function(){return 0},valueOf:function(){return this._.valueOf()},setDate:function(){ko.setUTCDate.apply(this._,arguments)},setDay:function(){ko.setUTCDay.apply(this._,arguments)},setFullYear:function(){ko.setUTCFullYear.apply(this._,arguments)},setHours:function(){ko.setUTCHours.apply(this._,arguments)},setMilliseconds:function(){ko.setUTCMilliseconds.apply(this._,arguments)},setMinutes:function(){ko.setUTCMinutes.apply(this._,arguments)},setMonth:function(){ko.setUTCMonth.apply(this._,arguments)},setSeconds:function(){ko.setUTCSeconds.apply(this._,arguments)},setTime:function(){ko.setTime.apply(this._,arguments)}};var ko=Date.prototype,Eo="%a %b %e %X %Y",Ao="%m/%d/%Y",No="%H:%M:%S",To=["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],qo=["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],Co=["January","February","March","April","May","June","July","August","September","October","November","December"],zo=["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"];d3.time.format=function(t){function n(n){for(var r,i,u,a=[],o=-1,c=0;e>++o;)37===t.charCodeAt(o)&&(a.push(t.substring(c,o)),null!=(i=jo[r=t.charAt(++o)])&&(r=t.charAt(++o)),(u=Oo[r])&&(r=u(n,null==i?"e"===r?" ":"0":i)),a.push(r),c=o+1);return a.push(t.substring(c,o)),a.join("")}var e=t.length;return n.parse=function(n){var e={y:1900,m:0,d:1,H:0,M:0,S:0,L:0},r=Wi(e,t,n,0);if(r!=n.length)return null;"p"in e&&(e.H=e.H%12+12*e.p);var i=new wo;return i.setFullYear(e.y,e.m,e.d),i.setHours(e.H,e.M,e.S,e.L),i},n.toString=function(){return t},n};var Do=Qi(To),Lo=Qi(qo),Fo=Qi(Co),Ho=tu(Co),Ro=Qi(zo),Po=tu(zo),jo={"-":"",_:" ",0:"0"},Oo={a:function(t){return qo[t.getDay()]},A:function(t){return To[t.getDay()]},b:function(t){return zo[t.getMonth()]},B:function(t){return Co[t.getMonth()]},c:d3.time.format(Eo),d:function(t,n){return nu(t.getDate(),n,2)},e:function(t,n){return nu(t.getDate(),n,2)},H:function(t,n){return nu(t.getHours(),n,2)},I:function(t,n){return nu(t.getHours()%12||12,n,2)},j:function(t,n){return nu(1+d3.time.dayOfYear(t),n,3)},L:function(t,n){return nu(t.getMilliseconds(),n,3)},m:function(t,n){return nu(t.getMonth()+1,n,2)},M:function(t,n){return nu(t.getMinutes(),n,2)},p:function(t){return t.getHours()>=12?"PM":"AM"},S:function(t,n){return nu(t.getSeconds(),n,2)},U:function(t,n){return nu(d3.time.sundayOfYear(t),n,2)},w:function(t){return t.getDay()},W:function(t,n){return nu(d3.time.mondayOfYear(t),n,2)},x:d3.time.format(Ao),X:d3.time.format(No),y:function(t,n){return nu(t.getFullYear()%100,n,2)},Y:function(t,n){return nu(t.getFullYear()%1e4,n,4)},Z:Mu,"%":function(){return"%"}},Yo={a:eu,A:ru,b:iu,B:uu,c:au,d:du,e:du,H:gu,I:gu,L:vu,m:hu,M:pu,p:yu,S:mu,x:ou,X:cu,y:su,Y:lu},Uo=/^\s*\d+/,Io=d3.map({am:0,pm:1});d3.time.format.utc=function(t){function n(t){try{wo=Ki;var n=new wo;return n._=t,e(n)}finally{wo=Date}}var e=d3.time.format(t);return n.parse=function(t){try{wo=Ki;var n=e.parse(t);return n&&n._}finally{wo=Date}},n.toString=e.toString,n};var Vo=d3.time.format.utc("%Y-%m-%dT%H:%M:%S.%LZ");d3.time.format.iso=Date.prototype.toISOString?bu:Vo,bu.parse=function(t){var n=new Date(t);return isNaN(n)?null:n},bu.toString=Vo.toString,d3.time.second=xu(function(t){return new wo(1e3*Math.floor(t/1e3))},function(t,n){t.setTime(t.getTime()+1e3*Math.floor(n))},function(t){return t.getSeconds()}),d3.time.seconds=d3.time.second.range,d3.time.seconds.utc=d3.time.second.utc.range,d3.time.minute=xu(function(t){return new wo(6e4*Math.floor(t/6e4))},function(t,n){t.setTime(t.getTime()+6e4*Math.floor(n))},function(t){return t.getMinutes()}),d3.time.minutes=d3.time.minute.range,d3.time.minutes.utc=d3.time.minute.utc.range,d3.time.hour=xu(function(t){var n=t.getTimezoneOffset()/60;return new wo(36e5*(Math.floor(t/36e5-n)+n))},function(t,n){t.setTime(t.getTime()+36e5*Math.floor(n))},function(t){return t.getHours()}),d3.time.hours=d3.time.hour.range,d3.time.hours.utc=d3.time.hour.utc.range,d3.time.day=xu(function(t){var n=new wo(1970,0);return n.setFullYear(t.getFullYear(),t.getMonth(),t.getDate()),n},function(t,n){t.setDate(t.getDate()+n)},function(t){return t.getDate()-1}),d3.time.days=d3.time.day.range,d3.time.days.utc=d3.time.day.utc.range,d3.time.dayOfYear=function(t){var n=d3.time.year(t);return Math.floor((t-n-6e4*(t.getTimezoneOffset()-n.getTimezoneOffset()))/864e5)},So.forEach(function(t,n){t=t.toLowerCase(),n=7-n;var e=d3.time[t]=xu(function(t){return(t=d3.time.day(t)).setDate(t.getDate()-(t.getDay()+n)%7),t},function(t,n){t.setDate(t.getDate()+7*Math.floor(n))},function(t){var e=d3.time.year(t).getDay();return Math.floor((d3.time.dayOfYear(t)+(e+n)%7)/7)-(e!==n)});d3.time[t+"s"]=e.range,d3.time[t+"s"].utc=e.utc.range,d3.time[t+"OfYear"]=function(t){var e=d3.time.year(t).getDay();return Math.floor((d3.time.dayOfYear(t)+(e+n)%7)/7)}}),d3.time.week=d3.time.sunday,d3.time.weeks=d3.time.sunday.range,d3.time.weeks.utc=d3.time.sunday.utc.range,d3.time.weekOfYear=d3.time.sundayOfYear,d3.time.month=xu(function(t){return t=d3.time.day(t),t.setDate(1),t},function(t,n){t.setMonth(t.getMonth()+n)},function(t){return t.getMonth()}),d3.time.months=d3.time.month.range,d3.time.months.utc=d3.time.month.utc.range,d3.time.year=xu(function(t){return t=d3.time.day(t),t.setMonth(0,1),t},function(t,n){t.setFullYear(t.getFullYear()+n)},function(t){return t.getFullYear()}),d3.time.years=d3.time.year.range,d3.time.years.utc=d3.time.year.utc.range;var Xo=[1e3,5e3,15e3,3e4,6e4,3e5,9e5,18e5,36e5,108e5,216e5,432e5,864e5,1728e5,6048e5,2592e6,7776e6,31536e6],Zo=[[d3.time.second,1],[d3.time.second,5],[d3.time.second,15],[d3.time.second,30],[d3.time.minute,1],[d3.time.minute,5],[d3.time.minute,15],[d3.time.minute,30],[d3.time.hour,1],[d3.time.hour,3],[d3.time.hour,6],[d3.time.hour,12],[d3.time.day,1],[d3.time.day,2],[d3.time.week,1],[d3.time.month,1],[d3.time.month,3],[d3.time.year,1]],Bo=[[d3.time.format("%Y"),o],[d3.time.format("%B"),function(t){return t.getMonth()}],[d3.time.format("%b %d"),function(t){return 1!=t.getDate()}],[d3.time.format("%a %d"),function(t){return t.getDay()&&1!=t.getDate()}],[d3.time.format("%I %p"),function(t){return t.getHours()}],[d3.time.format("%I:%M"),function(t){return t.getMinutes()}],[d3.time.format(":%S"),function(t){return t.getSeconds()}],[d3.time.format(".%L"),function(t){return t.getMilliseconds()}]],$o=d3.scale.linear(),Jo=Eu(Bo);Zo.year=function(t,n){return $o.domain(t.map(Nu)).ticks(n).map(Au)},d3.time.scale=function(){return wu(d3.scale.linear(),Zo,Jo)};var Go=Zo.map(function(t){return[t[0].utc,t[1]]}),Ko=[[d3.time.format.utc("%Y"),o],[d3.time.format.utc("%B"),function(t){return t.getUTCMonth()}],[d3.time.format.utc("%b %d"),function(t){return 1!=t.getUTCDate()}],[d3.time.format.utc("%a %d"),function(t){return t.getUTCDay()&&1!=t.getUTCDate()}],[d3.time.format.utc("%I %p"),function(t){return t.getUTCHours()}],[d3.time.format.utc("%I:%M"),function(t){return t.getUTCMinutes()}],[d3.time.format.utc(":%S"),function(t){return t.getUTCSeconds()}],[d3.time.format.utc(".%L"),function(t){return t.getUTCMilliseconds()}]],Wo=Eu(Ko);Go.year=function(t,n){return $o.domain(t.map(qu)).ticks(n).map(Tu)},d3.time.scale.utc=function(){return wu(d3.scale.linear(),Go,Wo)}})();;!function(e,t){"object"==typeof exports&&"undefined"!=typeof module?module.exports=t():"function"==typeof define&&define.amd?define(t):(e="undefined"!=typeof globalThis?globalThis:e||self).i18next=t()}(this,function(){"use strict";function e(t){return(e="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(t)}function t(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function n(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function r(e,t,r){return t&&n(e.prototype,t),r&&n(e,r),Object.defineProperty(e,"prototype",{writable:!1}),e}function o(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function i(e,t){return(i=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function a(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&i(e,t)}function s(t,n){if(n&&("object"===e(n)||"function"==typeof n))return n;if(void 0!==n)throw new TypeError("Derived constructors may only return object or undefined");return o(t)}function u(e){return(u=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}function c(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function l(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,r)}return n}function f(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?l(Object(n),!0).forEach(function(t){c(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):l(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}var p={type:"logger",log:function(e){this.output("log",e)},warn:function(e){this.output("warn",e)},error:function(e){this.output("error",e)},output:function(e,t){console&&console[e]&&console[e].apply(console,t)}},g=new(function(){function e(n){var r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};t(this,e),this.init(n,r)}return r(e,[{key:"init",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};this.prefix=t.prefix||"i18next:",this.logger=e||p,this.options=t,this.debug=t.debug}},{key:"setDebug",value:function(e){this.debug=e}},{key:"log",value:function(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];return this.forward(t,"log","",!0)}},{key:"warn",value:function(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];return this.forward(t,"warn","",!0)}},{key:"error",value:function(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];return this.forward(t,"error","")}},{key:"deprecate",value:function(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];return this.forward(t,"warn","WARNING DEPRECATED: ",!0)}},{key:"forward",value:function(e,t,n,r){return r&&!this.debug?null:("string"==typeof e[0]&&(e[0]="".concat(n).concat(this.prefix," ").concat(e[0])),this.logger[t](e))}},{key:"create",value:function(t){return new e(this.logger,f(f({},{prefix:"".concat(this.prefix,":").concat(t,":")}),this.options))}}]),e}()),h=function(){function e(){t(this,e),this.observers={}}return r(e,[{key:"on",value:function(e,t){var n=this;return e.split(" ").forEach(function(e){n.observers[e]=n.observers[e]||[],n.observers[e].push(t)}),this}},{key:"off",value:function(e,t){this.observers[e]&&(t?this.observers[e]=this.observers[e].filter(function(e){return e!==t}):delete this.observers[e])}},{key:"emit",value:function(e){for(var t=arguments.length,n=new Array(t>1?t-1:0),r=1;r<t;r++)n[r-1]=arguments[r];this.observers[e]&&[].concat(this.observers[e]).forEach(function(e){e.apply(void 0,n)});this.observers["*"]&&[].concat(this.observers["*"]).forEach(function(t){t.apply(t,[e].concat(n))})}}]),e}();function d(){var e,t,n=new Promise(function(n,r){e=n,t=r});return n.resolve=e,n.reject=t,n}function v(e){return null==e?"":""+e}function y(e,t,n){function r(e){return e&&e.indexOf("###")>-1?e.replace(/###/g,"."):e}function o(){return!e||"string"==typeof e}for(var i="string"!=typeof t?[].concat(t):t.split(".");i.length>1;){if(o())return{};var a=r(i.shift());!e[a]&&n&&(e[a]=new n),e=Object.prototype.hasOwnProperty.call(e,a)?e[a]:{}}return o()?{}:{obj:e,k:r(i.shift())}}function m(e,t,n){var r=y(e,t,Object);r.obj[r.k]=n}function b(e,t){var n=y(e,t),r=n.obj,o=n.k;if(r)return r[o]}function O(e,t,n){var r=b(e,n);return void 0!==r?r:b(t,n)}function k(e){return e.replace(/[\-\[\]\/\{\}\(\)\*\+\?\.\\\^\$\|]/g,"\\$&")}var w={"&":"&amp;","<":"&lt;",">":"&gt;",'"':"&quot;","'":"&#39;","/":"&#x2F;"};function x(e){return"string"==typeof e?e.replace(/[&<>"'\/]/g,function(e){return w[e]}):e}var S="undefined"!=typeof window&&window.navigator&&void 0===window.navigator.userAgentData&&window.navigator.userAgent&&window.navigator.userAgent.indexOf("MSIE")>-1,j=[" ",",","?","!",";"];function P(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,r)}return n}function L(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?P(Object(n),!0).forEach(function(t){c(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):P(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}function R(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch(e){return!1}}();return function(){var n,r=u(e);if(t){var o=u(this).constructor;n=Reflect.construct(r,arguments,o)}else n=r.apply(this,arguments);return s(this,n)}}var N=function(e){a(i,h);var n=R(i);function i(e){var r,a=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{ns:["translation"],defaultNS:"translation"};return t(this,i),r=n.call(this),S&&h.call(o(r)),r.data=e||{},r.options=a,void 0===r.options.keySeparator&&(r.options.keySeparator="."),void 0===r.options.ignoreJSONStructure&&(r.options.ignoreJSONStructure=!0),r}return r(i,[{key:"addNamespaces",value:function(e){this.options.ns.indexOf(e)<0&&this.options.ns.push(e)}},{key:"removeNamespaces",value:function(e){var t=this.options.ns.indexOf(e);t>-1&&this.options.ns.splice(t,1)}},{key:"getResource",value:function(e,t,n){var r=arguments.length>3&&void 0!==arguments[3]?arguments[3]:{},o=void 0!==r.keySeparator?r.keySeparator:this.options.keySeparator,i=void 0!==r.ignoreJSONStructure?r.ignoreJSONStructure:this.options.ignoreJSONStructure,a=[e,t];n&&"string"!=typeof n&&(a=a.concat(n)),n&&"string"==typeof n&&(a=a.concat(o?n.split(o):n)),e.indexOf(".")>-1&&(a=e.split("."));var s=b(this.data,a);return s||!i||"string"!=typeof n?s:function e(t,n){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:".";if(t){if(t[n])return t[n];for(var o=n.split(r),i=t,a=0;a<o.length;++a){if(!i)return;if("string"==typeof i[o[a]]&&a+1<o.length)return;if(void 0===i[o[a]]){for(var s=2,u=o.slice(a,a+s).join(r),c=i[u];void 0===c&&o.length>a+s;)s++,c=i[u=o.slice(a,a+s).join(r)];if(void 0===c)return;if(null===c)return null;if(n.endsWith(u)){if("string"==typeof c)return c;if(u&&"string"==typeof c[u])return c[u]}var l=o.slice(a+s).join(r);return l?e(c,l,r):void 0}i=i[o[a]]}return i}}(this.data&&this.data[e]&&this.data[e][t],n,o)}},{key:"addResource",value:function(e,t,n,r){var o=arguments.length>4&&void 0!==arguments[4]?arguments[4]:{silent:!1},i=this.options.keySeparator;void 0===i&&(i=".");var a=[e,t];n&&(a=a.concat(i?n.split(i):n)),e.indexOf(".")>-1&&(r=t,t=(a=e.split("."))[1]),this.addNamespaces(t),m(this.data,a,r),o.silent||this.emit("added",e,t,n,r)}},{key:"addResources",value:function(e,t,n){var r=arguments.length>3&&void 0!==arguments[3]?arguments[3]:{silent:!1};for(var o in n)"string"!=typeof n[o]&&"[object Array]"!==Object.prototype.toString.apply(n[o])||this.addResource(e,t,o,n[o],{silent:!0});r.silent||this.emit("added",e,t,n)}},{key:"addResourceBundle",value:function(e,t,n,r,o){var i=arguments.length>5&&void 0!==arguments[5]?arguments[5]:{silent:!1},a=[e,t];e.indexOf(".")>-1&&(r=n,n=t,t=(a=e.split("."))[1]),this.addNamespaces(t);var s=b(this.data,a)||{};r?function e(t,n,r){for(var o in n)"__proto__"!==o&&"constructor"!==o&&(o in t?"string"==typeof t[o]||t[o]instanceof String||"string"==typeof n[o]||n[o]instanceof String?r&&(t[o]=n[o]):e(t[o],n[o],r):t[o]=n[o]);return t}(s,n,o):s=L(L({},s),n),m(this.data,a,s),i.silent||this.emit("added",e,t,n)}},{key:"removeResourceBundle",value:function(e,t){this.hasResourceBundle(e,t)&&delete this.data[e][t],this.removeNamespaces(t),this.emit("removed",e,t)}},{key:"hasResourceBundle",value:function(e,t){return void 0!==this.getResource(e,t)}},{key:"getResourceBundle",value:function(e,t){return t||(t=this.options.defaultNS),"v1"===this.options.compatibilityAPI?L(L({},{}),this.getResource(e,t)):this.getResource(e,t)}},{key:"getDataByLanguage",value:function(e){return this.data[e]}},{key:"hasLanguageSomeTranslations",value:function(e){var t=this.getDataByLanguage(e);return!!(t&&Object.keys(t)||[]).find(function(e){return t[e]&&Object.keys(t[e]).length>0})}},{key:"toJSON",value:function(){return this.data}}]),i}(),C={processors:{},addPostProcessor:function(e){this.processors[e.name]=e},handle:function(e,t,n,r,o){var i=this;return e.forEach(function(e){i.processors[e]&&(t=i.processors[e].process(t,n,r,o))}),t}};function E(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,r)}return n}function D(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?E(Object(n),!0).forEach(function(t){c(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):E(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}function F(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch(e){return!1}}();return function(){var n,r=u(e);if(t){var o=u(this).constructor;n=Reflect.construct(r,arguments,o)}else n=r.apply(this,arguments);return s(this,n)}}var I={},A=function(n){a(s,h);var i=F(s);function s(e){var n,r,a,u,c=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return t(this,s),n=i.call(this),S&&h.call(o(n)),r=["resourceStore","languageUtils","pluralResolver","interpolator","backendConnector","i18nFormat","utils"],a=e,u=o(n),r.forEach(function(e){a[e]&&(u[e]=a[e])}),n.options=c,void 0===n.options.keySeparator&&(n.options.keySeparator="."),n.logger=g.create("translator"),n}return r(s,[{key:"changeLanguage",value:function(e){e&&(this.language=e)}},{key:"exists",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{interpolation:{}};if(null==e)return!1;var n=this.resolve(e,t);return n&&void 0!==n.res}},{key:"extractFromKey",value:function(e,t){var n=void 0!==t.nsSeparator?t.nsSeparator:this.options.nsSeparator;void 0===n&&(n=":");var r=void 0!==t.keySeparator?t.keySeparator:this.options.keySeparator,o=t.ns||this.options.defaultNS||[],i=n&&e.indexOf(n)>-1,a=!(this.options.userDefinedKeySeparator||t.keySeparator||this.options.userDefinedNsSeparator||t.nsSeparator||function(e,t,n){t=t||"",n=n||"";var r=j.filter(function(e){return t.indexOf(e)<0&&n.indexOf(e)<0});if(0===r.length)return!0;var o=new RegExp("(".concat(r.map(function(e){return"?"===e?"\\?":e}).join("|"),")")),i=!o.test(e);if(!i){var a=e.indexOf(n);a>0&&!o.test(e.substring(0,a))&&(i=!0)}return i}(e,n,r));if(i&&!a){var s=e.match(this.interpolator.nestingRegexp);if(s&&s.length>0)return{key:e,namespaces:o};var u=e.split(n);(n!==r||n===r&&this.options.ns.indexOf(u[0])>-1)&&(o=u.shift()),e=u.join(r)}return"string"==typeof o&&(o=[o]),{key:e,namespaces:o}}},{key:"translate",value:function(t,n,r){var o=this;if("object"!==e(n)&&this.options.overloadTranslationOptionHandler&&(n=this.options.overloadTranslationOptionHandler(arguments)),n||(n={}),null==t)return"";Array.isArray(t)||(t=[String(t)]);var i=void 0!==n.returnDetails?n.returnDetails:this.options.returnDetails,a=void 0!==n.keySeparator?n.keySeparator:this.options.keySeparator,u=this.extractFromKey(t[t.length-1],n),c=u.key,l=u.namespaces,f=l[l.length-1],p=n.lng||this.language,g=n.appendNamespaceToCIMode||this.options.appendNamespaceToCIMode;if(p&&"cimode"===p.toLowerCase()){if(g){var h=n.nsSeparator||this.options.nsSeparator;return i?(d.res="".concat(f).concat(h).concat(c),d):"".concat(f).concat(h).concat(c)}return i?(d.res=c,d):c}var d=this.resolve(t,n),v=d&&d.res,y=d&&d.usedKey||c,m=d&&d.exactUsedKey||c,b=Object.prototype.toString.apply(v),O=void 0!==n.joinArrays?n.joinArrays:this.options.joinArrays,k=!this.i18nFormat||this.i18nFormat.handleAsObject;if(k&&v&&("string"!=typeof v&&"boolean"!=typeof v&&"number"!=typeof v)&&["[object Number]","[object Function]","[object RegExp]"].indexOf(b)<0&&("string"!=typeof O||"[object Array]"!==b)){if(!n.returnObjects&&!this.options.returnObjects){this.options.returnedObjectHandler||this.logger.warn("accessing an object - but returnObjects options is not enabled!");var w=this.options.returnedObjectHandler?this.options.returnedObjectHandler(y,v,D(D({},n),{},{ns:l})):"key '".concat(c," (").concat(this.language,")' returned an object instead of string.");return i?(d.res=w,d):w}if(a){var x="[object Array]"===b,S=x?[]:{},j=x?m:y;for(var P in v)if(Object.prototype.hasOwnProperty.call(v,P)){var L="".concat(j).concat(a).concat(P);S[P]=this.translate(L,D(D({},n),{joinArrays:!1,ns:l})),S[P]===L&&(S[P]=v[P])}v=S}}else if(k&&"string"==typeof O&&"[object Array]"===b)(v=v.join(O))&&(v=this.extendTranslation(v,t,n,r));else{var R=!1,N=!1,C=void 0!==n.count&&"string"!=typeof n.count,E=s.hasDefaultValue(n),F=C?this.pluralResolver.getSuffix(p,n.count,n):"",I=n["defaultValue".concat(F)]||n.defaultValue;!this.isValidLookup(v)&&E&&(R=!0,v=I),this.isValidLookup(v)||(N=!0,v=c);var A=(n.missingKeyNoValueFallbackToKey||this.options.missingKeyNoValueFallbackToKey)&&N?void 0:v,T=E&&I!==v&&this.options.updateMissing;if(N||R||T){if(this.logger.log(T?"updateKey":"missingKey",p,f,c,T?I:v),a){var V=this.resolve(c,D(D({},n),{},{keySeparator:!1}));V&&V.res&&this.logger.warn("Seems the loaded translations were in flat JSON format instead of nested. Either set keySeparator: false on init or make sure your translations are published in nested format.")}var U=[],K=this.languageUtils.getFallbackCodes(this.options.fallbackLng,n.lng||this.language);if("fallback"===this.options.saveMissingTo&&K&&K[0])for(var B=0;B<K.length;B++)U.push(K[B]);else"all"===this.options.saveMissingTo?U=this.languageUtils.toResolveHierarchy(n.lng||this.language):U.push(n.lng||this.language);var M=function(e,t,r){var i=E&&r!==v?r:A;o.options.missingKeyHandler?o.options.missingKeyHandler(e,f,t,i,T,n):o.backendConnector&&o.backendConnector.saveMissing&&o.backendConnector.saveMissing(e,f,t,i,T,n),o.emit("missingKey",e,f,t,v)};this.options.saveMissing&&(this.options.saveMissingPlurals&&C?U.forEach(function(e){o.pluralResolver.getSuffixes(e,n).forEach(function(t){M([e],c+t,n["defaultValue".concat(t)]||I)})}):M(U,c,I))}v=this.extendTranslation(v,t,n,d,r),N&&v===c&&this.options.appendNamespaceToMissingKey&&(v="".concat(f,":").concat(c)),(N||R)&&this.options.parseMissingKeyHandler&&(v="v1"!==this.options.compatibilityAPI?this.options.parseMissingKeyHandler(this.options.appendNamespaceToMissingKey?"".concat(f,":").concat(c):c,R?v:void 0):this.options.parseMissingKeyHandler(v))}return i?(d.res=v,d):v}},{key:"extendTranslation",value:function(e,t,n,r,o){var i=this;if(this.i18nFormat&&this.i18nFormat.parse)e=this.i18nFormat.parse(e,D(D({},this.options.interpolation.defaultVariables),n),r.usedLng,r.usedNS,r.usedKey,{resolved:r});else if(!n.skipInterpolation){n.interpolation&&this.interpolator.init(D(D({},n),{interpolation:D(D({},this.options.interpolation),n.interpolation)}));var a,s="string"==typeof e&&(n&&n.interpolation&&void 0!==n.interpolation.skipOnVariables?n.interpolation.skipOnVariables:this.options.interpolation.skipOnVariables);if(s){var u=e.match(this.interpolator.nestingRegexp);a=u&&u.length}var c=n.replace&&"string"!=typeof n.replace?n.replace:n;if(this.options.interpolation.defaultVariables&&(c=D(D({},this.options.interpolation.defaultVariables),c)),e=this.interpolator.interpolate(e,c,n.lng||this.language,n),s){var l=e.match(this.interpolator.nestingRegexp);a<(l&&l.length)&&(n.nest=!1)}!1!==n.nest&&(e=this.interpolator.nest(e,function(){for(var e=arguments.length,r=new Array(e),a=0;a<e;a++)r[a]=arguments[a];return o&&o[0]===r[0]&&!n.context?(i.logger.warn("It seems you are nesting recursively key: ".concat(r[0]," in key: ").concat(t[0])),null):i.translate.apply(i,r.concat([t]))},n)),n.interpolation&&this.interpolator.reset()}var f=n.postProcess||this.options.postProcess,p="string"==typeof f?[f]:f;return null!=e&&p&&p.length&&!1!==n.applyPostProcessor&&(e=C.handle(p,e,t,this.options&&this.options.postProcessPassResolved?D({i18nResolved:r},n):n,this)),e}},{key:"resolve",value:function(e){var t,n,r,o,i,a=this,s=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return"string"==typeof e&&(e=[e]),e.forEach(function(e){if(!a.isValidLookup(t)){var u=a.extractFromKey(e,s),c=u.key;n=c;var l=u.namespaces;a.options.fallbackNS&&(l=l.concat(a.options.fallbackNS));var f=void 0!==s.count&&"string"!=typeof s.count,p=f&&!s.ordinal&&0===s.count&&a.pluralResolver.shouldUseIntlApi(),g=void 0!==s.context&&("string"==typeof s.context||"number"==typeof s.context)&&""!==s.context,h=s.lngs?s.lngs:a.languageUtils.toResolveHierarchy(s.lng||a.language,s.fallbackLng);l.forEach(function(e){a.isValidLookup(t)||(i=e,!I["".concat(h[0],"-").concat(e)]&&a.utils&&a.utils.hasLoadedNamespace&&!a.utils.hasLoadedNamespace(i)&&(I["".concat(h[0],"-").concat(e)]=!0,a.logger.warn('key "'.concat(n,'" for languages "').concat(h.join(", "),'" won\'t get resolved as namespace "').concat(i,'" was not yet loaded'),"This means something IS WRONG in your setup. You access the t function before i18next.init / i18next.loadNamespace / i18next.changeLanguage was done. Wait for the callback or Promise to resolve before accessing it!!!")),h.forEach(function(n){if(!a.isValidLookup(t)){o=n;var i,u=[c];if(a.i18nFormat&&a.i18nFormat.addLookupKeys)a.i18nFormat.addLookupKeys(u,c,n,e,s);else{var l;f&&(l=a.pluralResolver.getSuffix(n,s.count,s));var h="".concat(a.options.pluralSeparator,"zero");if(f&&(u.push(c+l),p&&u.push(c+h)),g){var d="".concat(c).concat(a.options.contextSeparator).concat(s.context);u.push(d),f&&(u.push(d+l),p&&u.push(d+h))}}for(;i=u.pop();)a.isValidLookup(t)||(r=i,t=a.getResource(n,e,i,s))}}))})}}),{res:t,usedKey:n,exactUsedKey:r,usedLng:o,usedNS:i}}},{key:"isValidLookup",value:function(e){return!(void 0===e||!this.options.returnNull&&null===e||!this.options.returnEmptyString&&""===e)}},{key:"getResource",value:function(e,t,n){var r=arguments.length>3&&void 0!==arguments[3]?arguments[3]:{};return this.i18nFormat&&this.i18nFormat.getResource?this.i18nFormat.getResource(e,t,n,r):this.resourceStore.getResource(e,t,n,r)}}],[{key:"hasDefaultValue",value:function(e){for(var t in e)if(Object.prototype.hasOwnProperty.call(e,t)&&"defaultValue"===t.substring(0,"defaultValue".length)&&void 0!==e[t])return!0;return!1}}]),s}();function T(e){return e.charAt(0).toUpperCase()+e.slice(1)}var V=function(){function e(n){t(this,e),this.options=n,this.supportedLngs=this.options.supportedLngs||!1,this.logger=g.create("languageUtils")}return r(e,[{key:"getScriptPartFromCode",value:function(e){if(!e||e.indexOf("-")<0)return null;var t=e.split("-");return 2===t.length?null:(t.pop(),"x"===t[t.length-1].toLowerCase()?null:this.formatLanguageCode(t.join("-")))}},{key:"getLanguagePartFromCode",value:function(e){if(!e||e.indexOf("-")<0)return e;var t=e.split("-");return this.formatLanguageCode(t[0])}},{key:"formatLanguageCode",value:function(e){if("string"==typeof e&&e.indexOf("-")>-1){var t=["hans","hant","latn","cyrl","cans","mong","arab"],n=e.split("-");return this.options.lowerCaseLng?n=n.map(function(e){return e.toLowerCase()}):2===n.length?(n[0]=n[0].toLowerCase(),n[1]=n[1].toUpperCase(),t.indexOf(n[1].toLowerCase())>-1&&(n[1]=T(n[1].toLowerCase()))):3===n.length&&(n[0]=n[0].toLowerCase(),2===n[1].length&&(n[1]=n[1].toUpperCase()),"sgn"!==n[0]&&2===n[2].length&&(n[2]=n[2].toUpperCase()),t.indexOf(n[1].toLowerCase())>-1&&(n[1]=T(n[1].toLowerCase())),t.indexOf(n[2].toLowerCase())>-1&&(n[2]=T(n[2].toLowerCase()))),n.join("-")}return this.options.cleanCode||this.options.lowerCaseLng?e.toLowerCase():e}},{key:"isSupportedCode",value:function(e){return("languageOnly"===this.options.load||this.options.nonExplicitSupportedLngs)&&(e=this.getLanguagePartFromCode(e)),!this.supportedLngs||!this.supportedLngs.length||this.supportedLngs.indexOf(e)>-1}},{key:"getBestMatchFromCodes",value:function(e){var t,n=this;return e?(e.forEach(function(e){if(!t){var r=n.formatLanguageCode(e);n.options.supportedLngs&&!n.isSupportedCode(r)||(t=r)}}),!t&&this.options.supportedLngs&&e.forEach(function(e){if(!t){var r=n.getLanguagePartFromCode(e);if(n.isSupportedCode(r))return t=r;t=n.options.supportedLngs.find(function(e){if(0===e.indexOf(r))return e})}}),t||(t=this.getFallbackCodes(this.options.fallbackLng)[0]),t):null}},{key:"getFallbackCodes",value:function(e,t){if(!e)return[];if("function"==typeof e&&(e=e(t)),"string"==typeof e&&(e=[e]),"[object Array]"===Object.prototype.toString.apply(e))return e;if(!t)return e.default||[];var n=e[t];return n||(n=e[this.getScriptPartFromCode(t)]),n||(n=e[this.formatLanguageCode(t)]),n||(n=e[this.getLanguagePartFromCode(t)]),n||(n=e.default),n||[]}},{key:"toResolveHierarchy",value:function(e,t){var n=this,r=this.getFallbackCodes(t||this.options.fallbackLng||[],e),o=[],i=function(e){e&&(n.isSupportedCode(e)?o.push(e):n.logger.warn("rejecting language code not found in supportedLngs: ".concat(e)))};return"string"==typeof e&&e.indexOf("-")>-1?("languageOnly"!==this.options.load&&i(this.formatLanguageCode(e)),"languageOnly"!==this.options.load&&"currentOnly"!==this.options.load&&i(this.getScriptPartFromCode(e)),"currentOnly"!==this.options.load&&i(this.getLanguagePartFromCode(e))):"string"==typeof e&&i(this.formatLanguageCode(e)),r.forEach(function(e){o.indexOf(e)<0&&i(n.formatLanguageCode(e))}),o}}]),e}(),U=[{lngs:["ach","ak","am","arn","br","fil","gun","ln","mfe","mg","mi","oc","pt","pt-BR","tg","tl","ti","tr","uz","wa"],nr:[1,2],fc:1},{lngs:["af","an","ast","az","bg","bn","ca","da","de","dev","el","en","eo","es","et","eu","fi","fo","fur","fy","gl","gu","ha","hi","hu","hy","ia","it","kk","kn","ku","lb","mai","ml","mn","mr","nah","nap","nb","ne","nl","nn","no","nso","pa","pap","pms","ps","pt-PT","rm","sco","se","si","so","son","sq","sv","sw","ta","te","tk","ur","yo"],nr:[1,2],fc:2},{lngs:["ay","bo","cgg","fa","ht","id","ja","jbo","ka","km","ko","ky","lo","ms","sah","su","th","tt","ug","vi","wo","zh"],nr:[1],fc:3},{lngs:["be","bs","cnr","dz","hr","ru","sr","uk"],nr:[1,2,5],fc:4},{lngs:["ar"],nr:[0,1,2,3,11,100],fc:5},{lngs:["cs","sk"],nr:[1,2,5],fc:6},{lngs:["csb","pl"],nr:[1,2,5],fc:7},{lngs:["cy"],nr:[1,2,3,8],fc:8},{lngs:["fr"],nr:[1,2],fc:9},{lngs:["ga"],nr:[1,2,3,7,11],fc:10},{lngs:["gd"],nr:[1,2,3,20],fc:11},{lngs:["is"],nr:[1,2],fc:12},{lngs:["jv"],nr:[0,1],fc:13},{lngs:["kw"],nr:[1,2,3,4],fc:14},{lngs:["lt"],nr:[1,2,10],fc:15},{lngs:["lv"],nr:[1,2,0],fc:16},{lngs:["mk"],nr:[1,2],fc:17},{lngs:["mnk"],nr:[0,1,2],fc:18},{lngs:["mt"],nr:[1,2,11,20],fc:19},{lngs:["or"],nr:[2,1],fc:2},{lngs:["ro"],nr:[1,2,20],fc:20},{lngs:["sl"],nr:[5,1,2,3],fc:21},{lngs:["he","iw"],nr:[1,2,20,21],fc:22}],K={1:function(e){return Number(e>1)},2:function(e){return Number(1!=e)},3:function(e){return 0},4:function(e){return Number(e%10==1&&e%100!=11?0:e%10>=2&&e%10<=4&&(e%100<10||e%100>=20)?1:2)},5:function(e){return Number(0==e?0:1==e?1:2==e?2:e%100>=3&&e%100<=10?3:e%100>=11?4:5)},6:function(e){return Number(1==e?0:e>=2&&e<=4?1:2)},7:function(e){return Number(1==e?0:e%10>=2&&e%10<=4&&(e%100<10||e%100>=20)?1:2)},8:function(e){return Number(1==e?0:2==e?1:8!=e&&11!=e?2:3)},9:function(e){return Number(e>=2)},10:function(e){return Number(1==e?0:2==e?1:e<7?2:e<11?3:4)},11:function(e){return Number(1==e||11==e?0:2==e||12==e?1:e>2&&e<20?2:3)},12:function(e){return Number(e%10!=1||e%100==11)},13:function(e){return Number(0!==e)},14:function(e){return Number(1==e?0:2==e?1:3==e?2:3)},15:function(e){return Number(e%10==1&&e%100!=11?0:e%10>=2&&(e%100<10||e%100>=20)?1:2)},16:function(e){return Number(e%10==1&&e%100!=11?0:0!==e?1:2)},17:function(e){return Number(1==e||e%10==1&&e%100!=11?0:1)},18:function(e){return Number(0==e?0:1==e?1:2)},19:function(e){return Number(1==e?0:0==e||e%100>1&&e%100<11?1:e%100>10&&e%100<20?2:3)},20:function(e){return Number(1==e?0:0==e||e%100>0&&e%100<20?1:2)},21:function(e){return Number(e%100==1?1:e%100==2?2:e%100==3||e%100==4?3:0)},22:function(e){return Number(1==e?0:2==e?1:(e<0||e>10)&&e%10==0?2:3)}},B=["v1","v2","v3"],M={zero:0,one:1,two:2,few:3,many:4,other:5};var H=function(){function e(n){var r,o=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};t(this,e),this.languageUtils=n,this.options=o,this.logger=g.create("pluralResolver"),this.options.compatibilityJSON&&"v4"!==this.options.compatibilityJSON||"undefined"!=typeof Intl&&Intl.PluralRules||(this.options.compatibilityJSON="v3",this.logger.error("Your environment seems not to be Intl API compatible, use an Intl.PluralRules polyfill. Will fallback to the compatibilityJSON v3 format handling.")),this.rules=(r={},U.forEach(function(e){e.lngs.forEach(function(t){r[t]={numbers:e.nr,plurals:K[e.fc]}})}),r)}return r(e,[{key:"addRule",value:function(e,t){this.rules[e]=t}},{key:"getRule",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};if(this.shouldUseIntlApi())try{return new Intl.PluralRules(e,{type:t.ordinal?"ordinal":"cardinal"})}catch(e){return}return this.rules[e]||this.rules[this.languageUtils.getLanguagePartFromCode(e)]}},{key:"needsPlural",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=this.getRule(e,t);return this.shouldUseIntlApi()?n&&n.resolvedOptions().pluralCategories.length>1:n&&n.numbers.length>1}},{key:"getPluralFormsOfKey",value:function(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};return this.getSuffixes(e,n).map(function(e){return"".concat(t).concat(e)})}},{key:"getSuffixes",value:function(e){var t=this,n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},r=this.getRule(e,n);return r?this.shouldUseIntlApi()?r.resolvedOptions().pluralCategories.sort(function(e,t){return M[e]-M[t]}).map(function(e){return"".concat(t.options.prepend).concat(e)}):r.numbers.map(function(r){return t.getSuffix(e,r,n)}):[]}},{key:"getSuffix",value:function(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},r=this.getRule(e,n);return r?this.shouldUseIntlApi()?"".concat(this.options.prepend).concat(r.select(t)):this.getSuffixRetroCompatible(r,t):(this.logger.warn("no plural rule found for: ".concat(e)),"")}},{key:"getSuffixRetroCompatible",value:function(e,t){var n=this,r=e.noAbs?e.plurals(t):e.plurals(Math.abs(t)),o=e.numbers[r];this.options.simplifyPluralSuffix&&2===e.numbers.length&&1===e.numbers[0]&&(2===o?o="plural":1===o&&(o=""));var i=function(){return n.options.prepend&&o.toString()?n.options.prepend+o.toString():o.toString()};return"v1"===this.options.compatibilityJSON?1===o?"":"number"==typeof o?"_plural_".concat(o.toString()):i():"v2"===this.options.compatibilityJSON?i():this.options.simplifyPluralSuffix&&2===e.numbers.length&&1===e.numbers[0]?i():this.options.prepend&&r.toString()?this.options.prepend+r.toString():r.toString()}},{key:"shouldUseIntlApi",value:function(){return!B.includes(this.options.compatibilityJSON)}}]),e}();function z(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,r)}return n}function J(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?z(Object(n),!0).forEach(function(t){c(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):z(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}var _=function(){function e(){var n=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};t(this,e),this.logger=g.create("interpolator"),this.options=n,this.format=n.interpolation&&n.interpolation.format||function(e){return e},this.init(n)}return r(e,[{key:"init",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};e.interpolation||(e.interpolation={escapeValue:!0});var t=e.interpolation;this.escape=void 0!==t.escape?t.escape:x,this.escapeValue=void 0===t.escapeValue||t.escapeValue,this.useRawValueToEscape=void 0!==t.useRawValueToEscape&&t.useRawValueToEscape,this.prefix=t.prefix?k(t.prefix):t.prefixEscaped||"{{",this.suffix=t.suffix?k(t.suffix):t.suffixEscaped||"}}",this.formatSeparator=t.formatSeparator?t.formatSeparator:t.formatSeparator||",",this.unescapePrefix=t.unescapeSuffix?"":t.unescapePrefix||"-",this.unescapeSuffix=this.unescapePrefix?"":t.unescapeSuffix||"",this.nestingPrefix=t.nestingPrefix?k(t.nestingPrefix):t.nestingPrefixEscaped||k("$t("),this.nestingSuffix=t.nestingSuffix?k(t.nestingSuffix):t.nestingSuffixEscaped||k(")"),this.nestingOptionsSeparator=t.nestingOptionsSeparator?t.nestingOptionsSeparator:t.nestingOptionsSeparator||",",this.maxReplaces=t.maxReplaces?t.maxReplaces:1e3,this.alwaysFormat=void 0!==t.alwaysFormat&&t.alwaysFormat,this.resetRegExp()}},{key:"reset",value:function(){this.options&&this.init(this.options)}},{key:"resetRegExp",value:function(){var e="".concat(this.prefix,"(.+?)").concat(this.suffix);this.regexp=new RegExp(e,"g");var t="".concat(this.prefix).concat(this.unescapePrefix,"(.+?)").concat(this.unescapeSuffix).concat(this.suffix);this.regexpUnescape=new RegExp(t,"g");var n="".concat(this.nestingPrefix,"(.+?)").concat(this.nestingSuffix);this.nestingRegexp=new RegExp(n,"g")}},{key:"interpolate",value:function(e,t,n,r){var o,i,a,s=this,u=this.options&&this.options.interpolation&&this.options.interpolation.defaultVariables||{};function c(e){return e.replace(/\$/g,"$$$$")}var l=function(e){if(e.indexOf(s.formatSeparator)<0){var o=O(t,u,e);return s.alwaysFormat?s.format(o,void 0,n,J(J(J({},r),t),{},{interpolationkey:e})):o}var i=e.split(s.formatSeparator),a=i.shift().trim(),c=i.join(s.formatSeparator).trim();return s.format(O(t,u,a),c,n,J(J(J({},r),t),{},{interpolationkey:a}))};this.resetRegExp();var f=r&&r.missingInterpolationHandler||this.options.missingInterpolationHandler,p=r&&r.interpolation&&void 0!==r.interpolation.skipOnVariables?r.interpolation.skipOnVariables:this.options.interpolation.skipOnVariables;return[{regex:this.regexpUnescape,safeValue:function(e){return c(e)}},{regex:this.regexp,safeValue:function(e){return s.escapeValue?c(s.escape(e)):c(e)}}].forEach(function(t){for(a=0;o=t.regex.exec(e);){var n=o[1].trim();if(void 0===(i=l(n)))if("function"==typeof f){var u=f(e,o,r);i="string"==typeof u?u:""}else if(r&&r.hasOwnProperty(n))i="";else{if(p){i=o[0];continue}s.logger.warn("missed to pass in variable ".concat(n," for interpolating ").concat(e)),i=""}else"string"==typeof i||s.useRawValueToEscape||(i=v(i));var c=t.safeValue(i);if(e=e.replace(o[0],c),p?(t.regex.lastIndex+=i.length,t.regex.lastIndex-=o[0].length):t.regex.lastIndex=0,++a>=s.maxReplaces)break}}),e}},{key:"nest",value:function(e,t){var n,r,o=this,i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},a=J({},i);function s(e,t){var n=this.nestingOptionsSeparator;if(e.indexOf(n)<0)return e;var r=e.split(new RegExp("".concat(n,"[ ]*{"))),o="{".concat(r[1]);e=r[0],o=(o=this.interpolate(o,a)).replace(/'/g,'"');try{a=JSON.parse(o),t&&(a=J(J({},t),a))}catch(t){return this.logger.warn("failed parsing options string in nesting for key ".concat(e),t),"".concat(e).concat(n).concat(o)}return delete a.defaultValue,e}for(a.applyPostProcessor=!1,delete a.defaultValue;n=this.nestingRegexp.exec(e);){var u=[],c=!1;if(-1!==n[0].indexOf(this.formatSeparator)&&!/{.*}/.test(n[1])){var l=n[1].split(this.formatSeparator).map(function(e){return e.trim()});n[1]=l.shift(),u=l,c=!0}if((r=t(s.call(this,n[1].trim(),a),a))&&n[0]===e&&"string"!=typeof r)return r;"string"!=typeof r&&(r=v(r)),r||(this.logger.warn("missed to resolve ".concat(n[1]," for nesting ").concat(e)),r=""),c&&(r=u.reduce(function(e,t){return o.format(e,t,i.lng,J(J({},i),{},{interpolationkey:n[1].trim()}))},r.trim())),e=e.replace(n[0],r),this.regexp.lastIndex=0}return e}}]),e}();function q(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function $(e){return function(e){if(Array.isArray(e))return e}(e)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||function(e,t){if(e){if("string"==typeof e)return q(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?q(e,t):void 0}}(e)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function W(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,r)}return n}function Y(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?W(Object(n),!0).forEach(function(t){c(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):W(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}var G=function(){function e(){var n=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};t(this,e),this.logger=g.create("formatter"),this.options=n,this.formats={number:function(e,t,n){return new Intl.NumberFormat(t,n).format(e)},currency:function(e,t,n){return new Intl.NumberFormat(t,Y(Y({},n),{},{style:"currency"})).format(e)},datetime:function(e,t,n){return new Intl.DateTimeFormat(t,Y({},n)).format(e)},relativetime:function(e,t,n){return new Intl.RelativeTimeFormat(t,Y({},n)).format(e,n.range||"day")},list:function(e,t,n){return new Intl.ListFormat(t,Y({},n)).format(e)}},this.init(n)}return r(e,[{key:"init",value:function(e){var t=(arguments.length>1&&void 0!==arguments[1]?arguments[1]:{interpolation:{}}).interpolation;this.formatSeparator=t.formatSeparator?t.formatSeparator:t.formatSeparator||","}},{key:"add",value:function(e,t){this.formats[e.toLowerCase().trim()]=t}},{key:"format",value:function(e,t,n,r){var o=this;return t.split(this.formatSeparator).reduce(function(e,t){var i=function(e){var t=e.toLowerCase().trim(),n={};if(e.indexOf("(")>-1){var r=e.split("(");t=r[0].toLowerCase().trim();var o=r[1].substring(0,r[1].length-1);"currency"===t&&o.indexOf(":")<0?n.currency||(n.currency=o.trim()):"relativetime"===t&&o.indexOf(":")<0?n.range||(n.range=o.trim()):o.split(";").forEach(function(e){if(e){var t=$(e.split(":")),r=t[0],o=t.slice(1).join(":").trim().replace(/^'+|'+$/g,"");n[r.trim()]||(n[r.trim()]=o),"false"===o&&(n[r.trim()]=!1),"true"===o&&(n[r.trim()]=!0),isNaN(o)||(n[r.trim()]=parseInt(o,10))}})}return{formatName:t,formatOptions:n}}(t),a=i.formatName,s=i.formatOptions;if(o.formats[a]){var u=e;try{var c=r&&r.formatParams&&r.formatParams[r.interpolationkey]||{},l=c.locale||c.lng||r.locale||r.lng||n;u=o.formats[a](e,l,Y(Y(Y({},s),r),c))}catch(e){o.logger.warn(e)}return u}return o.logger.warn("there was no format function for ".concat(a)),e},e)}}]),e}();function Q(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,r)}return n}function X(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Q(Object(n),!0).forEach(function(t){c(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Q(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}function Z(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch(e){return!1}}();return function(){var n,r=u(e);if(t){var o=u(this).constructor;n=Reflect.construct(r,arguments,o)}else n=r.apply(this,arguments);return s(this,n)}}var ee=function(e){a(i,h);var n=Z(i);function i(e,r,a){var s,u=arguments.length>3&&void 0!==arguments[3]?arguments[3]:{};return t(this,i),s=n.call(this),S&&h.call(o(s)),s.backend=e,s.store=r,s.services=a,s.languageUtils=a.languageUtils,s.options=u,s.logger=g.create("backendConnector"),s.waitingReads=[],s.maxParallelReads=u.maxParallelReads||10,s.readingCalls=0,s.state={},s.queue=[],s.backend&&s.backend.init&&s.backend.init(a,u.backend,u),s}return r(i,[{key:"queueLoad",value:function(e,t,n,r){var o=this,i={},a={},s={},u={};return e.forEach(function(e){var r=!0;t.forEach(function(t){var s="".concat(e,"|").concat(t);!n.reload&&o.store.hasResourceBundle(e,t)?o.state[s]=2:o.state[s]<0||(1===o.state[s]?void 0===a[s]&&(a[s]=!0):(o.state[s]=1,r=!1,void 0===a[s]&&(a[s]=!0),void 0===i[s]&&(i[s]=!0),void 0===u[t]&&(u[t]=!0)))}),r||(s[e]=!0)}),(Object.keys(i).length||Object.keys(a).length)&&this.queue.push({pending:a,pendingCount:Object.keys(a).length,loaded:{},errors:[],callback:r}),{toLoad:Object.keys(i),pending:Object.keys(a),toLoadLanguages:Object.keys(s),toLoadNamespaces:Object.keys(u)}}},{key:"loaded",value:function(e,t,n){var r=e.split("|"),o=r[0],i=r[1];t&&this.emit("failedLoading",o,i,t),n&&this.store.addResourceBundle(o,i,n),this.state[e]=t?-1:2;var a={};this.queue.forEach(function(n){var r,s,u,c,l,f;r=n.loaded,s=i,c=y(r,[o],Object),l=c.obj,f=c.k,l[f]=l[f]||[],u&&(l[f]=l[f].concat(s)),u||l[f].push(s),function(e,t){void 0!==e.pending[t]&&(delete e.pending[t],e.pendingCount--)}(n,e),t&&n.errors.push(t),0!==n.pendingCount||n.done||(Object.keys(n.loaded).forEach(function(e){a[e]||(a[e]={});var t=n.loaded[e];t.length&&t.forEach(function(t){void 0===a[e][t]&&(a[e][t]=!0)})}),n.done=!0,n.errors.length?n.callback(n.errors):n.callback())}),this.emit("loaded",a),this.queue=this.queue.filter(function(e){return!e.done})}},{key:"read",value:function(e,t,n){var r=this,o=arguments.length>3&&void 0!==arguments[3]?arguments[3]:0,i=arguments.length>4&&void 0!==arguments[4]?arguments[4]:350,a=arguments.length>5?arguments[5]:void 0;return e.length?this.readingCalls>=this.maxParallelReads?void this.waitingReads.push({lng:e,ns:t,fcName:n,tried:o,wait:i,callback:a}):(this.readingCalls++,this.backend[n](e,t,function(s,u){if(r.readingCalls--,r.waitingReads.length>0){var c=r.waitingReads.shift();r.read(c.lng,c.ns,c.fcName,c.tried,c.wait,c.callback)}s&&u&&o<5?setTimeout(function(){r.read.call(r,e,t,n,o+1,2*i,a)},i):a(s,u)})):a(null,{})}},{key:"prepareLoading",value:function(e,t){var n=this,r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},o=arguments.length>3?arguments[3]:void 0;if(!this.backend)return this.logger.warn("No backend was added via i18next.use. Will not load resources."),o&&o();"string"==typeof e&&(e=this.languageUtils.toResolveHierarchy(e)),"string"==typeof t&&(t=[t]);var i=this.queueLoad(e,t,r,o);if(!i.toLoad.length)return i.pending.length||o(),null;i.toLoad.forEach(function(e){n.loadOne(e)})}},{key:"load",value:function(e,t,n){this.prepareLoading(e,t,{},n)}},{key:"reload",value:function(e,t,n){this.prepareLoading(e,t,{reload:!0},n)}},{key:"loadOne",value:function(e){var t=this,n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"",r=e.split("|"),o=r[0],i=r[1];this.read(o,i,"read",void 0,void 0,function(r,a){r&&t.logger.warn("".concat(n,"loading namespace ").concat(i," for language ").concat(o," failed"),r),!r&&a&&t.logger.log("".concat(n,"loaded namespace ").concat(i," for language ").concat(o),a),t.loaded(e,r,a)})}},{key:"saveMissing",value:function(e,t,n,r,o){var i=arguments.length>5&&void 0!==arguments[5]?arguments[5]:{};this.services.utils&&this.services.utils.hasLoadedNamespace&&!this.services.utils.hasLoadedNamespace(t)?this.logger.warn('did not save key "'.concat(n,'" as the namespace "').concat(t,'" was not yet loaded'),"This means something IS WRONG in your setup. You access the t function before i18next.init / i18next.loadNamespace / i18next.changeLanguage was done. Wait for the callback or Promise to resolve before accessing it!!!"):null!=n&&""!==n&&(this.backend&&this.backend.create&&this.backend.create(e,t,n,r,null,X(X({},i),{},{isUpdate:o})),e&&e[0]&&this.store.addResource(e[0],t,n,r))}}]),i}();function te(e){return"string"==typeof e.ns&&(e.ns=[e.ns]),"string"==typeof e.fallbackLng&&(e.fallbackLng=[e.fallbackLng]),"string"==typeof e.fallbackNS&&(e.fallbackNS=[e.fallbackNS]),e.supportedLngs&&e.supportedLngs.indexOf("cimode")<0&&(e.supportedLngs=e.supportedLngs.concat(["cimode"])),e}function ne(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,r)}return n}function re(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?ne(Object(n),!0).forEach(function(t){c(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):ne(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}function oe(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch(e){return!1}}();return function(){var n,r=u(e);if(t){var o=u(this).constructor;n=Reflect.construct(r,arguments,o)}else n=r.apply(this,arguments);return s(this,n)}}function ie(){}var ae=function(n){a(u,h);var i=oe(u);function u(){var e,n,r=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},a=arguments.length>1?arguments[1]:void 0;if(t(this,u),e=i.call(this),S&&h.call(o(e)),e.options=te(r),e.services={},e.logger=g,e.modules={external:[]},n=o(e),Object.getOwnPropertyNames(Object.getPrototypeOf(n)).forEach(function(e){"function"==typeof n[e]&&(n[e]=n[e].bind(n))}),a&&!e.isInitialized&&!r.isClone){if(!e.options.initImmediate)return e.init(r,a),s(e,o(e));setTimeout(function(){e.init(r,a)},0)}return e}return r(u,[{key:"init",value:function(){var t=this,n=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},r=arguments.length>1?arguments[1]:void 0;"function"==typeof n&&(r=n,n={}),!n.defaultNS&&n.ns&&("string"==typeof n.ns?n.defaultNS=n.ns:n.ns.indexOf("translation")<0&&(n.defaultNS=n.ns[0]));var o={debug:!1,initImmediate:!0,ns:["translation"],defaultNS:["translation"],fallbackLng:["dev"],fallbackNS:!1,supportedLngs:!1,nonExplicitSupportedLngs:!1,load:"all",preload:!1,simplifyPluralSuffix:!0,keySeparator:".",nsSeparator:":",pluralSeparator:"_",contextSeparator:"_",partialBundledLanguages:!1,saveMissing:!1,updateMissing:!1,saveMissingTo:"fallback",saveMissingPlurals:!0,missingKeyHandler:!1,missingInterpolationHandler:!1,postProcess:!1,postProcessPassResolved:!1,returnNull:!0,returnEmptyString:!0,returnObjects:!1,joinArrays:!1,returnedObjectHandler:!1,parseMissingKeyHandler:!1,appendNamespaceToMissingKey:!1,appendNamespaceToCIMode:!1,overloadTranslationOptionHandler:function(t){var n={};if("object"===e(t[1])&&(n=t[1]),"string"==typeof t[1]&&(n.defaultValue=t[1]),"string"==typeof t[2]&&(n.tDescription=t[2]),"object"===e(t[2])||"object"===e(t[3])){var r=t[3]||t[2];Object.keys(r).forEach(function(e){n[e]=r[e]})}return n},interpolation:{escapeValue:!0,format:function(e,t,n,r){return e},prefix:"{{",suffix:"}}",formatSeparator:",",unescapePrefix:"-",nestingPrefix:"$t(",nestingSuffix:")",nestingOptionsSeparator:",",maxReplaces:1e3,skipOnVariables:!0}};function i(e){return e?"function"==typeof e?new e:e:null}if(this.options=re(re(re({},o),this.options),te(n)),"v1"!==this.options.compatibilityAPI&&(this.options.interpolation=re(re({},o.interpolation),this.options.interpolation)),void 0!==n.keySeparator&&(this.options.userDefinedKeySeparator=n.keySeparator),void 0!==n.nsSeparator&&(this.options.userDefinedNsSeparator=n.nsSeparator),!this.options.isClone){var a;this.modules.logger?g.init(i(this.modules.logger),this.options):g.init(null,this.options),this.modules.formatter?a=this.modules.formatter:"undefined"!=typeof Intl&&(a=G);var s=new V(this.options);this.store=new N(this.options.resources,this.options);var u=this.services;u.logger=g,u.resourceStore=this.store,u.languageUtils=s,u.pluralResolver=new H(s,{prepend:this.options.pluralSeparator,compatibilityJSON:this.options.compatibilityJSON,simplifyPluralSuffix:this.options.simplifyPluralSuffix}),!a||this.options.interpolation.format&&this.options.interpolation.format!==o.interpolation.format||(u.formatter=i(a),u.formatter.init(u,this.options),this.options.interpolation.format=u.formatter.format.bind(u.formatter)),u.interpolator=new _(this.options),u.utils={hasLoadedNamespace:this.hasLoadedNamespace.bind(this)},u.backendConnector=new ee(i(this.modules.backend),u.resourceStore,u,this.options),u.backendConnector.on("*",function(e){for(var n=arguments.length,r=new Array(n>1?n-1:0),o=1;o<n;o++)r[o-1]=arguments[o];t.emit.apply(t,[e].concat(r))}),this.modules.languageDetector&&(u.languageDetector=i(this.modules.languageDetector),u.languageDetector.init(u,this.options.detection,this.options)),this.modules.i18nFormat&&(u.i18nFormat=i(this.modules.i18nFormat),u.i18nFormat.init&&u.i18nFormat.init(this)),this.translator=new A(this.services,this.options),this.translator.on("*",function(e){for(var n=arguments.length,r=new Array(n>1?n-1:0),o=1;o<n;o++)r[o-1]=arguments[o];t.emit.apply(t,[e].concat(r))}),this.modules.external.forEach(function(e){e.init&&e.init(t)})}if(this.format=this.options.interpolation.format,r||(r=ie),this.options.fallbackLng&&!this.services.languageDetector&&!this.options.lng){var c=this.services.languageUtils.getFallbackCodes(this.options.fallbackLng);c.length>0&&"dev"!==c[0]&&(this.options.lng=c[0])}this.services.languageDetector||this.options.lng||this.logger.warn("init: no languageDetector is used and no lng is defined");["getResource","hasResourceBundle","getResourceBundle","getDataByLanguage"].forEach(function(e){t[e]=function(){var n;return(n=t.store)[e].apply(n,arguments)}});["addResource","addResources","addResourceBundle","removeResourceBundle"].forEach(function(e){t[e]=function(){var n;return(n=t.store)[e].apply(n,arguments),t}});var l=d(),f=function(){var e=function(e,n){t.isInitialized&&!t.initializedStoreOnce&&t.logger.warn("init: i18next is already initialized. You should call init just once!"),t.isInitialized=!0,t.options.isClone||t.logger.log("initialized",t.options),t.emit("initialized",t.options),l.resolve(n),r(e,n)};if(t.languages&&"v1"!==t.options.compatibilityAPI&&!t.isInitialized)return e(null,t.t.bind(t));t.changeLanguage(t.options.lng,e)};return this.options.resources||!this.options.initImmediate?f():setTimeout(f,0),l}},{key:"loadResources",value:function(e){var t=this,n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:ie,r="string"==typeof e?e:this.language;if("function"==typeof e&&(n=e),!this.options.resources||this.options.partialBundledLanguages){if(r&&"cimode"===r.toLowerCase())return n();var o=[],i=function(e){e&&t.services.languageUtils.toResolveHierarchy(e).forEach(function(e){o.indexOf(e)<0&&o.push(e)})};if(r)i(r);else this.services.languageUtils.getFallbackCodes(this.options.fallbackLng).forEach(function(e){return i(e)});this.options.preload&&this.options.preload.forEach(function(e){return i(e)}),this.services.backendConnector.load(o,this.options.ns,function(e){e||t.resolvedLanguage||!t.language||t.setResolvedLanguage(t.language),n(e)})}else n(null)}},{key:"reloadResources",value:function(e,t,n){var r=d();return e||(e=this.languages),t||(t=this.options.ns),n||(n=ie),this.services.backendConnector.reload(e,t,function(e){r.resolve(),n(e)}),r}},{key:"use",value:function(e){if(!e)throw new Error("You are passing an undefined module! Please check the object you are passing to i18next.use()");if(!e.type)throw new Error("You are passing a wrong module! Please check the object you are passing to i18next.use()");return"backend"===e.type&&(this.modules.backend=e),("logger"===e.type||e.log&&e.warn&&e.error)&&(this.modules.logger=e),"languageDetector"===e.type&&(this.modules.languageDetector=e),"i18nFormat"===e.type&&(this.modules.i18nFormat=e),"postProcessor"===e.type&&C.addPostProcessor(e),"formatter"===e.type&&(this.modules.formatter=e),"3rdParty"===e.type&&this.modules.external.push(e),this}},{key:"setResolvedLanguage",value:function(e){if(e&&this.languages&&!(["cimode","dev"].indexOf(e)>-1))for(var t=0;t<this.languages.length;t++){var n=this.languages[t];if(!(["cimode","dev"].indexOf(n)>-1)&&this.store.hasLanguageSomeTranslations(n)){this.resolvedLanguage=n;break}}}},{key:"changeLanguage",value:function(e,t){var n=this;this.isLanguageChangingTo=e;var r=d();this.emit("languageChanging",e);var o=function(e){n.language=e,n.languages=n.services.languageUtils.toResolveHierarchy(e),n.resolvedLanguage=void 0,n.setResolvedLanguage(e)},i=function(i){e||i||!n.services.languageDetector||(i=[]);var a="string"==typeof i?i:n.services.languageUtils.getBestMatchFromCodes(i);a&&(n.language||o(a),n.translator.language||n.translator.changeLanguage(a),n.services.languageDetector&&n.services.languageDetector.cacheUserLanguage(a)),n.loadResources(a,function(e){!function(e,i){i?(o(i),n.translator.changeLanguage(i),n.isLanguageChangingTo=void 0,n.emit("languageChanged",i),n.logger.log("languageChanged",i)):n.isLanguageChangingTo=void 0,r.resolve(function(){return n.t.apply(n,arguments)}),t&&t(e,function(){return n.t.apply(n,arguments)})}(e,a)})};return e||!this.services.languageDetector||this.services.languageDetector.async?!e&&this.services.languageDetector&&this.services.languageDetector.async?this.services.languageDetector.detect(i):i(e):i(this.services.languageDetector.detect()),r}},{key:"getFixedT",value:function(t,n,r){var o=this,i=function t(n,i){var a;if("object"!==e(i)){for(var s=arguments.length,u=new Array(s>2?s-2:0),c=2;c<s;c++)u[c-2]=arguments[c];a=o.options.overloadTranslationOptionHandler([n,i].concat(u))}else a=re({},i);a.lng=a.lng||t.lng,a.lngs=a.lngs||t.lngs,a.ns=a.ns||t.ns,a.keyPrefix=a.keyPrefix||r||t.keyPrefix;var l=o.options.keySeparator||".",f=a.keyPrefix?"".concat(a.keyPrefix).concat(l).concat(n):n;return o.t(f,a)};return"string"==typeof t?i.lng=t:i.lngs=t,i.ns=n,i.keyPrefix=r,i}},{key:"t",value:function(){var e;return this.translator&&(e=this.translator).translate.apply(e,arguments)}},{key:"exists",value:function(){var e;return this.translator&&(e=this.translator).exists.apply(e,arguments)}},{key:"setDefaultNamespace",value:function(e){this.options.defaultNS=e}},{key:"hasLoadedNamespace",value:function(e){var t=this,n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};if(!this.isInitialized)return this.logger.warn("hasLoadedNamespace: i18next was not initialized",this.languages),!1;if(!this.languages||!this.languages.length)return this.logger.warn("hasLoadedNamespace: i18n.languages were undefined or empty",this.languages),!1;var r=this.resolvedLanguage||this.languages[0],o=!!this.options&&this.options.fallbackLng,i=this.languages[this.languages.length-1];if("cimode"===r.toLowerCase())return!0;var a=function(e,n){var r=t.services.backendConnector.state["".concat(e,"|").concat(n)];return-1===r||2===r};if(n.precheck){var s=n.precheck(this,a);if(void 0!==s)return s}return!!this.hasResourceBundle(r,e)||(!(this.services.backendConnector.backend&&(!this.options.resources||this.options.partialBundledLanguages))||!(!a(r,e)||o&&!a(i,e)))}},{key:"loadNamespaces",value:function(e,t){var n=this,r=d();return this.options.ns?("string"==typeof e&&(e=[e]),e.forEach(function(e){n.options.ns.indexOf(e)<0&&n.options.ns.push(e)}),this.loadResources(function(e){r.resolve(),t&&t(e)}),r):(t&&t(),Promise.resolve())}},{key:"loadLanguages",value:function(e,t){var n=d();"string"==typeof e&&(e=[e]);var r=this.options.preload||[],o=e.filter(function(e){return r.indexOf(e)<0});return o.length?(this.options.preload=r.concat(o),this.loadResources(function(e){n.resolve(),t&&t(e)}),n):(t&&t(),Promise.resolve())}},{key:"dir",value:function(e){if(e||(e=this.resolvedLanguage||(this.languages&&this.languages.length>0?this.languages[0]:this.language)),!e)return"rtl";return["ar","shu","sqr","ssh","xaa","yhd","yud","aao","abh","abv","acm","acq","acw","acx","acy","adf","ads","aeb","aec","afb","ajp","apc","apd","arb","arq","ars","ary","arz","auz","avl","ayh","ayl","ayn","ayp","bbz","pga","he","iw","ps","pbt","pbu","pst","prp","prd","ug","ur","ydd","yds","yih","ji","yi","hbo","men","xmn","fa","jpr","peo","pes","prs","dv","sam","ckb"].indexOf(this.services.languageUtils.getLanguagePartFromCode(e))>-1||e.toLowerCase().indexOf("-arab")>1?"rtl":"ltr"}},{key:"cloneInstance",value:function(){var e=this,t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:ie,r=re(re(re({},this.options),t),{isClone:!0}),o=new u(r);return["store","services","language"].forEach(function(t){o[t]=e[t]}),o.services=re({},this.services),o.services.utils={hasLoadedNamespace:o.hasLoadedNamespace.bind(o)},o.translator=new A(o.services,o.options),o.translator.on("*",function(e){for(var t=arguments.length,n=new Array(t>1?t-1:0),r=1;r<t;r++)n[r-1]=arguments[r];o.emit.apply(o,[e].concat(n))}),o.init(r,n),o.translator.options=o.options,o.translator.backendConnector.services.utils={hasLoadedNamespace:o.hasLoadedNamespace.bind(o)},o}},{key:"toJSON",value:function(){return{options:this.options,store:this.store,language:this.language,languages:this.languages,resolvedLanguage:this.resolvedLanguage}}}]),u}();c(ae,"createInstance",function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=arguments.length>1?arguments[1]:void 0;return new ae(e,t)});var se=ae.createInstance();return se.createInstance=ae.createInstance,se}); +;!function(e){"object"==typeof exports&&"undefined"!=typeof module?module.exports=e():"function"==typeof define&&define.amd?define([],e):("undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self?self:this).i18nextHttpBackend=e()}(function(){return function o(i,r,a){function s(t,e){if(!r[t]){if(!i[t]){var n="function"==typeof require&&require;if(!e&&n)return n(t,!0);if(u)return u(t,!0);throw(n=new Error("Cannot find module '"+t+"'")).code="MODULE_NOT_FOUND",n}n=r[t]={exports:{}},i[t][0].call(n.exports,function(e){return s(i[t][1][e]||e)},n,n.exports,o,i,r,a)}return r[t].exports}for(var u="function"==typeof require&&require,e=0;e<a.length;e++)s(a[e]);return s}({1:[function(n,o,i){!function(t){!function(){var e;"function"==typeof fetch&&(void 0!==t&&t.fetch?e=t.fetch:"undefined"!=typeof window&&window.fetch&&(e=window.fetch)),void 0===n||"undefined"!=typeof window&&void 0!==window.document||((e=e||n("cross-fetch")).default&&(e=e.default),i.default=e,o.exports=i.default)}.call(this)}.call(this,"undefined"!=typeof global?global:"undefined"!=typeof self?self:"undefined"!=typeof window?window:{})},{"cross-fetch":5}],2:[function(e,t,n){"use strict";Object.defineProperty(n,"__esModule",{value:!0}),n.default=void 0;var s=e("./utils.js"),o=(a=e("./request.js"))&&a.__esModule?a:{default:a};function i(e,t){for(var n=0;n<t.length;n++){var o=t[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,o.key,o)}}function r(){return{loadPath:"/locales/{{lng}}/{{ns}}.json",addPath:"/locales/add/{{lng}}/{{ns}}",allowMultiLoading:!1,parse:function(e){return JSON.parse(e)},stringify:JSON.stringify,parsePayload:function(e,t,n){return o=n||"",(n=t)in(t={})?Object.defineProperty(t,n,{value:o,enumerable:!0,configurable:!0,writable:!0}):t[n]=o,t;var o},request:o.default,reloadInterval:"undefined"==typeof window&&36e5,customHeaders:{},queryStringParams:{},crossDomain:!1,withCredentials:!1,overrideMimeType:!1,requestOptions:{mode:"cors",credentials:"same-origin",cache:"default"}}}var a,u,e=(e=f,(a=[{key:"init",value:function(e){var t=this,n=1<arguments.length&&void 0!==arguments[1]?arguments[1]:{},o=2<arguments.length&&void 0!==arguments[2]?arguments[2]:{};this.services=e,this.options=(0,s.defaults)(n,this.options||{},r()),this.allOptions=o,this.services&&this.options.reloadInterval&&setInterval(function(){return t.reload()},this.options.reloadInterval)}},{key:"readMulti",value:function(e,t,n){this._readAny(e,e,t,t,n)}},{key:"read",value:function(e,t,n){this._readAny([e],e,[t],t,n)}},{key:"_readAny",value:function(t,n,o,i,r){var a=this,e=this.options.loadPath;"function"==typeof this.options.loadPath&&(e=this.options.loadPath(t,o)),(e=(0,s.makePromise)(e)).then(function(e){if(!e)return r(null,{});e=a.services.interpolator.interpolate(e,{lng:t.join("+"),ns:o.join("+")});a.loadUrl(e,r,n,i)})}},{key:"loadUrl",value:function(i,r,a,s){var u=this;this.options.request(this.options,i,void 0,function(e,t){if(t&&(500<=t.status&&t.status<600||!t.status))return r("failed loading "+i+"; status code: "+t.status,!0);if(t&&400<=t.status&&t.status<500)return r("failed loading "+i+"; status code: "+t.status,!1);if(!t&&e&&e.message&&-1<e.message.indexOf("Failed to fetch"))return r("failed loading "+i+": "+e.message,!0);if(e)return r(e,!1);var n,o;try{n="string"==typeof t.data?u.options.parse(t.data,a,s):t.data}catch(e){o="failed parsing "+i+" to json"}if(o)return r(o,!1);r(null,n)})}},{key:"create",value:function(n,o,e,t,i){var r,a,s,u,f=this;this.options.addPath&&("string"==typeof n&&(n=[n]),r=this.options.parsePayload(o,e,t),a=0,s=[],u=[],n.forEach(function(e){var t=f.options.addPath;"function"==typeof f.options.addPath&&(t=f.options.addPath(e,o));e=f.services.interpolator.interpolate(t,{lng:e,ns:o});f.options.request(f.options,e,r,function(e,t){a+=1,s.push(e),u.push(t),a===n.length&&i&&i(s,u)})}))}},{key:"reload",value:function(){var t,e=this,n=this.services,i=n.backendConnector,o=n.languageUtils,r=n.logger,a=i.language;a&&"cimode"===a.toLowerCase()||(t=[],(n=function(e){o.toResolveHierarchy(e).forEach(function(e){t.indexOf(e)<0&&t.push(e)})})(a),this.allOptions.preload&&this.allOptions.preload.forEach(n),t.forEach(function(o){e.allOptions.ns.forEach(function(n){i.read(o,n,"read",null,null,function(e,t){e&&r.warn("loading namespace ".concat(n," for language ").concat(o," failed"),e),!e&&t&&r.log("loaded namespace ".concat(n," for language ").concat(o),t),i.loaded("".concat(o,"|").concat(n),e,t)})})}))}}])&&i(e.prototype,a),u&&i(e,u),Object.defineProperty(e,"prototype",{writable:!1}),f);function f(e){var t=1<arguments.length&&void 0!==arguments[1]?arguments[1]:{},n=2<arguments.length&&void 0!==arguments[2]?arguments[2]:{};!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,f),this.services=e,this.options=t,this.allOptions=n,this.type="backend",this.init(e,t,n)}e.type="backend",n.default=e,t.exports=n.default},{"./request.js":3,"./utils.js":4}],3:[function(n,o,i){!function(t){!function(){"use strict";Object.defineProperty(i,"__esModule",{value:!0}),i.default=void 0;var r,s,u,a=n("./utils.js"),e=function(e,t){if(!t&&e&&e.__esModule)return e;if(null===e||"object"!==c(e)&&"function"!=typeof e)return{default:e};t=f(t);if(t&&t.has(e))return t.get(e);var n,o={},i=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(n in e){var r;"default"!==n&&Object.prototype.hasOwnProperty.call(e,n)&&((r=i?Object.getOwnPropertyDescriptor(e,n):null)&&(r.get||r.set)?Object.defineProperty(o,n,r):o[n]=e[n])}o.default=e,t&&t.set(e,o);return o}(n("./getFetch.js"));function f(e){if("function"!=typeof WeakMap)return null;var t=new WeakMap,n=new WeakMap;return(f=function(e){return e?n:t})(e)}function c(e){return(c="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}"function"==typeof fetch&&(void 0!==t&&t.fetch?r=t.fetch:"undefined"!=typeof window&&window.fetch&&(r=window.fetch)),(0,a.hasXMLHttpRequest)()&&(void 0!==t&&t.XMLHttpRequest?s=t.XMLHttpRequest:"undefined"!=typeof window&&window.XMLHttpRequest&&(s=window.XMLHttpRequest)),"function"==typeof ActiveXObject&&(void 0!==t&&t.ActiveXObject?u=t.ActiveXObject:"undefined"!=typeof window&&window.ActiveXObject&&(u=window.ActiveXObject)),"function"!=typeof(r=!r&&e&&!s&&!u?e.default||e:r)&&(r=void 0);var d=function(e,t){if(t&&"object"===c(t)){var n,o="";for(n in t)o+="&"+encodeURIComponent(n)+"="+encodeURIComponent(t[n]);if(!o)return e;e=e+(-1!==e.indexOf("?")?"&":"?")+o.slice(1)}return e};i.default=function(e,t,n,o){return"function"==typeof n&&(o=n,n=void 0),o=o||function(){},r?function(e,t,n,o){e.queryStringParams&&(t=d(t,e.queryStringParams));var i=(0,a.defaults)({},"function"==typeof e.customHeaders?e.customHeaders():e.customHeaders);n&&(i["Content-Type"]="application/json"),r(t,(0,a.defaults)({method:n?"POST":"GET",body:n?e.stringify(n):void 0,headers:i},"function"==typeof e.requestOptions?e.requestOptions(n):e.requestOptions)).then(function(t){return t.ok?void t.text().then(function(e){o(null,{status:t.status,data:e})}).catch(o):o(t.statusText||"Error",{status:t.status})}).catch(o)}(e,t,n,o):(0,a.hasXMLHttpRequest)()||"function"==typeof ActiveXObject?function(e,t,n,o){n&&"object"===c(n)&&(n=d("",n).slice(1)),e.queryStringParams&&(t=d(t,e.queryStringParams));try{var i=s?new s:new u("MSXML2.XMLHTTP.3.0");i.open(n?"POST":"GET",t,1),e.crossDomain||i.setRequestHeader("X-Requested-With","XMLHttpRequest"),i.withCredentials=!!e.withCredentials,n&&i.setRequestHeader("Content-Type","application/x-www-form-urlencoded"),i.overrideMimeType&&i.overrideMimeType("application/json");var r=e.customHeaders;if(r="function"==typeof r?r():r)for(var a in r)i.setRequestHeader(a,r[a]);i.onreadystatechange=function(){3<i.readyState&&o(400<=i.status?i.statusText:null,{status:i.status,data:i.responseText})},i.send(n)}catch(e){console&&console.log(e)}}(e,t,n,o):void 0},o.exports=i.default}.call(this)}.call(this,"undefined"!=typeof global?global:"undefined"!=typeof self?self:"undefined"!=typeof window?window:{})},{"./getFetch.js":1,"./utils.js":4}],4:[function(e,t,n){"use strict";function o(e){return(o="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}Object.defineProperty(n,"__esModule",{value:!0}),n.defaults=function(n){return i.call(r.call(arguments,1),function(e){if(e)for(var t in e)void 0===n[t]&&(n[t]=e[t])}),n},n.hasXMLHttpRequest=function(){return"function"==typeof XMLHttpRequest||"object"===("undefined"==typeof XMLHttpRequest?"undefined":o(XMLHttpRequest))},n.makePromise=function(e){if(function(e){return!!e&&"function"==typeof e.then}(e))return e;return Promise.resolve(e)};var n=[],i=n.forEach,r=n.slice},{}],5:[function(e,t,n){},{}]},{},[2])(2)});;!function(t,e){"object"==typeof exports&&"undefined"!=typeof module?module.exports=e():"function"==typeof define&&define.amd?define(e):t.jqueryI18next=e()}(this,function(){"use strict";function t(t,a){function i(n,a,i){function r(t,n){return f.parseDefaultValueFromContent?e({},t,{defaultValue:n}):t}if(0!==a.length){var o="text";if(0===a.indexOf("[")){var l=a.split("]");a=l[1],o=l[0].substr(1,l[0].length-1)}if(a.indexOf(";")===a.length-1&&(a=a.substr(0,a.length-2)),"html"===o)n.html(t.t(a,r(i,n.html())));else if("text"===o)n.text(t.t(a,r(i,n.text())));else if("prepend"===o)n.prepend(t.t(a,r(i,n.html())));else if("append"===o)n.append(t.t(a,r(i,n.html())));else if(0===o.indexOf("data-")){var s=o.substr("data-".length),d=t.t(a,r(i,n.data(s)));n.data(s,d),n.attr(o,d)}else n.attr(o,t.t(a,r(i,n.attr(o))))}}function r(t,n){var r=t.attr(f.selectorAttr);if(r||void 0===r||!1===r||(r=t.text()||t.val()),r){var o=t,l=t.data(f.targetAttr);if(l&&(o=t.find(l)||t),n||!0!==f.useOptionsAttr||(n=t.data(f.optionsAttr)),n=n||{},r.indexOf(";")>=0){var s=r.split(";");a.each(s,function(t,e){""!==e&&i(o,e.trim(),n)})}else i(o,r,n);if(!0===f.useOptionsAttr){var d={};d=e({clone:d},n),delete d.lng,t.data(f.optionsAttr,d)}}}function o(t){return this.each(function(){r(a(this),t),a(this).find("["+f.selectorAttr+"]").each(function(){r(a(this),t)})})}var f=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};f=e({},n,f),a[f.tName]=t.t.bind(t),a[f.i18nName]=t,a.fn[f.handleName]=o}var e=Object.assign||function(t){for(var e=1;e<arguments.length;e++){var n=arguments[e];for(var a in n)Object.prototype.hasOwnProperty.call(n,a)&&(t[a]=n[a])}return t},n={tName:"t",i18nName:"i18n",handleName:"localize",selectorAttr:"data-i18n",targetAttr:"i18n-target",optionsAttr:"i18n-options",useOptionsAttr:!1,parseDefaultValueFromContent:!0};return{init:t}});;var runtime=function(e){"use strict";var t,r=Object.prototype,n=r.hasOwnProperty,a="function"==typeof Symbol?Symbol:{},i=a.iterator||"@@iterator",o=a.asyncIterator||"@@asyncIterator",s=a.toStringTag||"@@toStringTag";function u(e,t,r){return Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}),e[t]}try{u({},"")}catch(e){u=function(e,t,r){return e[t]=r}}function c(e,t,r,n){var a=t&&t.prototype instanceof v?t:v,i=Object.create(a.prototype),o=new O(n||[]);return i._invoke=function(e,t,r){var n=f;return function(a,i){if(n===d)throw new Error("Generator is already running");if(n===h){if("throw"===a)throw i;return Y()}for(r.method=a,r.arg=i;;){var o=r.delegate;if(o){var s=S(o,r);if(s){if(s===g)continue;return s}}if("next"===r.method)r.sent=r._sent=r.arg;else if("throw"===r.method){if(n===f)throw n=h,r.arg;r.dispatchException(r.arg)}else"return"===r.method&&r.abrupt("return",r.arg);n=d;var u=p(e,t,r);if("normal"===u.type){if(n=r.done?h:l,u.arg===g)continue;return{value:u.arg,done:r.done}}"throw"===u.type&&(n=h,r.method="throw",r.arg=u.arg)}}}(e,r,o),i}function p(e,t,r){try{return{type:"normal",arg:e.call(t,r)}}catch(e){return{type:"throw",arg:e}}}e.wrap=c;var f="suspendedStart",l="suspendedYield",d="executing",h="completed",g={};function v(){}function b(){}function m(){}var y={};u(y,i,function(){return this});var k=Object.getPrototypeOf,x=k&&k(k(R([])));x&&x!==r&&n.call(x,i)&&(y=x);var w=m.prototype=v.prototype=Object.create(y);function E(e){["next","throw","return"].forEach(function(t){u(e,t,function(e){return this._invoke(t,e)})})}function A(e,t){var r;this._invoke=function(a,i){function o(){return new t(function(r,o){!function r(a,i,o,s){var u=p(e[a],e,i);if("throw"!==u.type){var c=u.arg,f=c.value;return f&&"object"==typeof f&&n.call(f,"__await")?t.resolve(f.__await).then(function(e){r("next",e,o,s)},function(e){r("throw",e,o,s)}):t.resolve(f).then(function(e){c.value=e,o(c)},function(e){return r("throw",e,o,s)})}s(u.arg)}(a,i,r,o)})}return r=r?r.then(o,o):o()}}function S(e,r){var n=e.iterator[r.method];if(n===t){if(r.delegate=null,"throw"===r.method){if(e.iterator.return&&(r.method="return",r.arg=t,S(e,r),"throw"===r.method))return g;r.method="throw",r.arg=new TypeError("The iterator does not provide a 'throw' method")}return g}var a=p(n,e.iterator,r.arg);if("throw"===a.type)return r.method="throw",r.arg=a.arg,r.delegate=null,g;var i=a.arg;return i?i.done?(r[e.resultName]=i.value,r.next=e.nextLoc,"return"!==r.method&&(r.method="next",r.arg=t),r.delegate=null,g):i:(r.method="throw",r.arg=new TypeError("iterator result is not an object"),r.delegate=null,g)}function T(e){var t={tryLoc:e[0]};1 in e&&(t.catchLoc=e[1]),2 in e&&(t.finallyLoc=e[2],t.afterLoc=e[3]),this.tryEntries.push(t)}function D(e){var t=e.completion||{};t.type="normal",delete t.arg,e.completion=t}function O(e){this.tryEntries=[{tryLoc:"root"}],e.forEach(T,this),this.reset(!0)}function R(e){if(e){var r=e[i];if(r)return r.call(e);if("function"==typeof e.next)return e;if(!isNaN(e.length)){var a=-1,o=function r(){for(;++a<e.length;)if(n.call(e,a))return r.value=e[a],r.done=!1,r;return r.value=t,r.done=!0,r};return o.next=o}}return{next:Y}}function Y(){return{value:t,done:!0}}return b.prototype=m,u(w,"constructor",m),u(m,"constructor",b),b.displayName=u(m,s,"GeneratorFunction"),e.isGeneratorFunction=function(e){var t="function"==typeof e&&e.constructor;return!!t&&(t===b||"GeneratorFunction"===(t.displayName||t.name))},e.mark=function(e){return Object.setPrototypeOf?Object.setPrototypeOf(e,m):(e.__proto__=m,u(e,s,"GeneratorFunction")),e.prototype=Object.create(w),e},e.awrap=function(e){return{__await:e}},E(A.prototype),u(A.prototype,o,function(){return this}),e.AsyncIterator=A,e.async=function(t,r,n,a,i){void 0===i&&(i=Promise);var o=new A(c(t,r,n,a),i);return e.isGeneratorFunction(r)?o:o.next().then(function(e){return e.done?e.value:o.next()})},E(w),u(w,s,"Generator"),u(w,i,function(){return this}),u(w,"toString",function(){return"[object Generator]"}),e.keys=function(e){var t=[];for(var r in e)t.push(r);return t.reverse(),function r(){for(;t.length;){var n=t.pop();if(n in e)return r.value=n,r.done=!1,r}return r.done=!0,r}},e.values=R,O.prototype={constructor:O,reset:function(e){if(this.prev=0,this.next=0,this.sent=this._sent=t,this.done=!1,this.delegate=null,this.method="next",this.arg=t,this.tryEntries.forEach(D),!e)for(var r in this)"t"===r.charAt(0)&&n.call(this,r)&&!isNaN(+r.slice(1))&&(this[r]=t)},stop:function(){this.done=!0;var e=this.tryEntries[0].completion;if("throw"===e.type)throw e.arg;return this.rval},dispatchException:function(e){if(this.done)throw e;var r=this;function a(n,a){return s.type="throw",s.arg=e,r.next=n,a&&(r.method="next",r.arg=t),!!a}for(var i=this.tryEntries.length-1;i>=0;--i){var o=this.tryEntries[i],s=o.completion;if("root"===o.tryLoc)return a("end");if(o.tryLoc<=this.prev){var u=n.call(o,"catchLoc"),c=n.call(o,"finallyLoc");if(u&&c){if(this.prev<o.catchLoc)return a(o.catchLoc,!0);if(this.prev<o.finallyLoc)return a(o.finallyLoc)}else if(u){if(this.prev<o.catchLoc)return a(o.catchLoc,!0)}else{if(!c)throw new Error("try statement without catch or finally");if(this.prev<o.finallyLoc)return a(o.finallyLoc)}}}},abrupt:function(e,t){for(var r=this.tryEntries.length-1;r>=0;--r){var a=this.tryEntries[r];if(a.tryLoc<=this.prev&&n.call(a,"finallyLoc")&&this.prev<a.finallyLoc){var i=a;break}}i&&("break"===e||"continue"===e)&&i.tryLoc<=t&&t<=i.finallyLoc&&(i=null);var o=i?i.completion:{};return o.type=e,o.arg=t,i?(this.method="next",this.next=i.finallyLoc,g):this.complete(o)},complete:function(e,t){if("throw"===e.type)throw e.arg;return"break"===e.type||"continue"===e.type?this.next=e.arg:"return"===e.type?(this.rval=this.arg=e.arg,this.method="return",this.next="end"):"normal"===e.type&&t&&(this.next=t),g},finish:function(e){for(var t=this.tryEntries.length-1;t>=0;--t){var r=this.tryEntries[t];if(r.finallyLoc===e)return this.complete(r.completion,r.afterLoc),D(r),g}},catch:function(e){for(var t=this.tryEntries.length-1;t>=0;--t){var r=this.tryEntries[t];if(r.tryLoc===e){var n=r.completion;if("throw"===n.type){var a=n.arg;D(r)}return a}}throw new Error("illegal catch attempt")},delegateYield:function(e,r,n){return this.delegate={iterator:R(e),resultName:r,nextLoc:n},"next"===this.method&&(this.arg=t),g}},e}("object"==typeof module?module.exports:{});try{regeneratorRuntime=runtime}catch(e){"object"==typeof globalThis?globalThis.regeneratorRuntime=runtime:Function("r","regeneratorRuntime = r")(runtime)}Number.isInteger=Number.isInteger||function(e){return"number"==typeof e&&isFinite(e)&&Math.floor(e)===e},String.fromCodePoint||function(e){var t=function(t){for(var r=[],n=0,a="",i=0,o=arguments.length;i!==o;++i){var s=+arguments[i];if(!(s<1114111&&s>>>0===s))throw RangeError("Invalid code point: "+s);s<=65535?n=r.push(s):(s-=65536,n=r.push(55296+(s>>10),s%1024+56320)),n>=16383&&(a+=e.apply(null,r),r.length=0)}return a+e.apply(null,r)};try{Object.defineProperty(String,"fromCodePoint",{value:t,configurable:!0,writable:!0})}catch(e){String.fromCodePoint=t}}(String.fromCharCode),Object.is||(Object.is=function(e,t){return e===t?0!==e||1/e==1/t:e!=e&&t!=t}),String.prototype.codePointAt||function(){"use strict";var e=function(){try{var e={},t=Object.defineProperty,r=t(e,e,e)&&t}catch(e){}return r}(),t=function(e){if(null==this)throw TypeError();var t=String(this),r=t.length,n=e?Number(e):0;if(n!=n&&(n=0),!(n<0||n>=r)){var a,i=t.charCodeAt(n);return i>=55296&&i<=56319&&r>n+1&&(a=t.charCodeAt(n+1))>=56320&&a<=57343?1024*(i-55296)+a-56320+65536:i}};e?e(String.prototype,"codePointAt",{value:t,configurable:!0,writable:!0}):String.prototype.codePointAt=t}(),Math.log10=Math.log10||function(e){return Math.log(e)*Math.LOG10E},function(e){if("object"==typeof exports&&"undefined"!=typeof module)module.exports=e();else if("function"==typeof define&&define.amd)define([],e);else{("undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self?self:this).jsonata=e()}}(function(){return function(){return function e(t,r,n){function a(o,s){if(!r[o]){if(!t[o]){var u="function"==typeof require&&require;if(!s&&u)return u(o,!0);if(i)return i(o,!0);var c=new Error("Cannot find module '"+o+"'");throw c.code="MODULE_NOT_FOUND",c}var p=r[o]={exports:{}};t[o][0].call(p.exports,function(e){return a(t[o][1][e]||e)},p,p.exports,e,t,r,n)}return r[o].exports}for(var i="function"==typeof require&&require,o=0;o<n.length;o++)a(n[o]);return a}}()({1:[function(e,t,r){"use strict";var n=e("./utils"),a=function(){var e=n.stringToArray,t=["Zero","One","Two","Three","Four","Five","Six","Seven","Eight","Nine","Ten","Eleven","Twelve","Thirteen","Fourteen","Fifteen","Sixteen","Seventeen","Eighteen","Nineteen"],r=["Zeroth","First","Second","Third","Fourth","Fifth","Sixth","Seventh","Eighth","Ninth","Tenth","Eleventh","Twelfth","Thirteenth","Fourteenth","Fifteenth","Sixteenth","Seventeenth","Eighteenth","Nineteenth"],a=["Twenty","Thirty","Forty","Fifty","Sixty","Seventy","Eighty","Ninety","Hundred"],i=["Thousand","Million","Billion","Trillion"];var o={};t.forEach(function(e,t){o[e.toLowerCase()]=t}),r.forEach(function(e,t){o[e.toLowerCase()]=t}),a.forEach(function(e,t){var r=e.toLowerCase();o[r]=10*(t+2),o[r.substring(0,e.length-1)+"ieth"]=o[r]}),o.hundredth=100,i.forEach(function(e,t){var r=e.toLowerCase(),n=Math.pow(10,3*(t+1));o[r]=n,o[r+"th"]=n});var s=[[1e3,"m"],[900,"cm"],[500,"d"],[400,"cd"],[100,"c"],[90,"xc"],[50,"l"],[40,"xl"],[10,"x"],[9,"ix"],[5,"v"],[4,"iv"],[1,"i"]],u={M:1e3,D:500,C:100,L:50,X:10,V:5,I:1};function c(e,t){if(void 0!==e)return l(e=Math.floor(e),h(t))}var p={DECIMAL:"decimal",LETTERS:"letters",ROMAN:"roman",WORDS:"words",SEQUENCE:"sequence"},f={UPPER:"upper",LOWER:"lower",TITLE:"title"};function l(n,o){var u,c=n<0;switch(n=Math.abs(n),o.primary){case p.LETTERS:u=function(e,t){for(var r=[],n=t.charCodeAt(0);e>0;)r.unshift(String.fromCharCode((e-1)%26+n)),e=Math.floor((e-1)/26);return r.join("")}(n,o.case===f.UPPER?"A":"a");break;case p.ROMAN:u=function e(t){for(var r=0;r<s.length;r++){var n=s[r];if(t>=n[0])return n[1]+e(t-n[0])}return""}(n),o.case===f.UPPER&&(u=u.toUpperCase());break;case p.WORDS:u=function(e,n){return function e(n,o,s){var u="";if(n<=19)u=(o?" and ":"")+(s?r[n]:t[n]);else if(n<100){var c=Math.floor(n/10),p=n%10;u=(o?" and ":"")+a[c-2],p>0?u+="-"+e(p,!1,s):s&&(u=u.substring(0,u.length-1)+"ieth")}else if(n<1e3){var f=Math.floor(n/100),l=n%100;u=(o?", ":"")+t[f]+" Hundred",l>0?u+=e(l,!0,s):s&&(u+="th")}else{var d=Math.floor(Math.log10(n)/3);d>i.length&&(d=i.length);var h=Math.pow(10,3*d),g=Math.floor(n/h),v=n-g*h;u=(o?", ":"")+e(g,!1,!1)+" "+i[d-1],v>0?u+=e(v,!0,s):s&&(u+="th")}return u}(e,!1,n)}(n,o.ordinal),o.case===f.UPPER?u=u.toUpperCase():o.case===f.LOWER&&(u=u.toLowerCase());break;case p.DECIMAL:u=""+n;var l=o.mandatoryDigits-u.length;if(l>0){var d=new Array(l+1).join("0");u=d+u}if(48!==o.zeroCode&&(u=e(u).map(function(e){return String.fromCodePoint(e.codePointAt(0)+o.zeroCode-48)}).join("")),o.regular)for(var h=Math.floor((u.length-1)/o.groupingSeparators.position);h>0;h--){var g=u.length-h*o.groupingSeparators.position;u=u.substr(0,g)+o.groupingSeparators.character+u.substr(g)}else o.groupingSeparators.reverse().forEach(function(e){var t=u.length-e.position;u=u.substr(0,t)+e.character+u.substr(t)});if(o.ordinal){var v={1:"st",2:"nd",3:"rd"}[u[u.length-1]];(!v||u.length>1&&"1"===u[u.length-2])&&(v="th"),u+=v}break;case p.SEQUENCE:throw{code:"D3130",value:o.token}}return c&&(u="-"+u),u}var d=[48,1632,1776,1984,2406,2534,2662,2790,2918,3046,3174,3302,3430,3558,3664,3792,3872,4160,4240,6112,6160,6470,6608,6784,6800,6992,7088,7232,7248,42528,43216,43264,43472,43504,43600,44016,65296];function h(t){var r,n={type:"integer",primary:p.DECIMAL,case:f.LOWER,ordinal:!1},a=t.lastIndexOf(";");switch(-1===a?r=t:(r=t.substring(0,a),"o"===t.substring(a+1)[0]&&(n.ordinal=!0)),r){case"A":n.case=f.UPPER;case"a":n.primary=p.LETTERS;break;case"I":n.case=f.UPPER;case"i":n.primary=p.ROMAN;break;case"W":n.case=f.UPPER,n.primary=p.WORDS;break;case"Ww":n.case=f.TITLE,n.primary=p.WORDS;break;case"w":n.primary=p.WORDS;break;default:var i=null,o=0,s=0,u=[],c=0;if(e(r).map(function(e){return e.codePointAt(0)}).reverse().forEach(function(e){for(var t=!1,r=0;r<d.length;r++){var n=d[r];if(e>=n&&e<=n+9){if(t=!0,o++,c++,null===i)i=n;else if(n!==i)throw{code:"D3131"};break}}t||(35===e?(c++,s++):u.push({position:c,character:String.fromCodePoint(e)}))}),o>0){n.primary=p.DECIMAL,n.zeroCode=i,n.mandatoryDigits=o,n.optionalDigits=s;var l=function(e){if(0===e.length)return 0;for(var t=e[0].character,r=1;r<e.length;r++)if(e[r].character!==t)return 0;for(var n=e.map(function(e){return e.position}),a=n.reduce(function e(t,r){return 0===r?t:e(r,t%r)}),i=1;i<=n.length;i++)if(-1===n.indexOf(i*a))return 0;return a}(u);l>0?(n.regular=!0,n.groupingSeparators={position:l,character:u[0].character}):(n.regular=!1,n.groupingSeparators=u)}else n.primary=p.SEQUENCE,n.token=r}return n}var g={Y:"1",M:"1",D:"1",d:"1",F:"n",W:"1",w:"1",X:"1",x:"1",H:"1",h:"1",P:"n",m:"01",s:"01",f:"1",Z:"01:01",z:"01:01",C:"n",E:"n"};function v(e){for(var t=[],r={type:"datetime",parts:t},n=function(r,n){if(n>r){var a=e.substring(r,n);a=a.split("]]").join("]"),t.push({type:"literal",value:a})}},a=0,i=0;i<e.length;){if("["===e.charAt(i)){if("["===e.charAt(i+1)){n(a,i),t.push({type:"literal",value:"["}),a=i+=2;continue}if(n(a,i),a=i,-1===(i=e.indexOf("]",a)))throw{code:"D3135"};var o,s=e.substring(a+1,i),u={type:"marker",component:(s=s.split(/\s+/).join("")).charAt(0)},c=s.lastIndexOf(",");if(-1!==c){var p=s.substring(c+1),l=p.indexOf("-"),d=void 0,v=void 0,b=function(e){return void 0===e||"*"===e?void 0:parseInt(e)};-1===l?d=p:(d=p.substring(0,l),v=p.substring(l+1));var m={min:b(d),max:b(v)};u.width=m,o=s.substring(1,c)}else o=s.substring(1);if(1===o.length)u.presentation1=o;else if(o.length>1){var y=o.charAt(o.length-1);-1!=="atco".indexOf(y)?(u.presentation2=y,"o"===y&&(u.ordinal=!0),u.presentation1=o.substring(0,o.length-1)):u.presentation1=o}else u.presentation1=g[u.component];if(void 0===u.presentation1)throw{code:"D3132",value:u.component};if("n"===u.presentation1[0])u.names=f.LOWER;else if("N"===u.presentation1[0])"n"===u.presentation1[1]?u.names=f.TITLE:u.names=f.UPPER;else if(-1!=="YMDdFWwXxHhmsf".indexOf(u.component)){var k=u.presentation1;if(u.presentation2&&(k+=";"+u.presentation2),u.integerFormat=h(k),u.width&&void 0!==u.width.min&&u.integerFormat.mandatoryDigits<u.width.min&&(u.integerFormat.mandatoryDigits=u.width.min),-1!=="YMD".indexOf(u.component))if(u.n=-1,u.width&&void 0!==u.width.max)u.n=u.width.max,u.integerFormat.mandatoryDigits=u.n;else{var x=u.integerFormat.mandatoryDigits+u.integerFormat.optionalDigits;x>=2&&(u.n=x)}}"Z"!==u.component&&"z"!==u.component||(u.integerFormat=h(u.presentation1)),t.push(u),a=i+1}i++}return n(a,i),r}var b=["","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday","Sunday"],m=["January","February","March","April","May","June","July","August","September","October","November","December"],y=function(e){var t=Date.UTC(e.year,e.month),r=new Date(t).getUTCDay();return 0===r&&(r=7),r>4?t+864e5*(8-r):t-864e5*(r-1)},k=function e(t,r){return{year:t,month:r,nextMonth:function(){return 11===r?e(t+1,0):e(t,r+1)},previousMonth:function(){return 0===r?e(t-1,11):e(t,r-1)},nextYear:function(){return e(t+1,r)},previousYear:function(){return e(t-1,r)}}},x=function(e,t){return(t-e)/6048e5+1},w=function(e,t){var r;switch(t){case"Y":r=e.getUTCFullYear();break;case"M":r=e.getUTCMonth()+1;break;case"D":r=e.getUTCDate();break;case"d":r=(Date.UTC(e.getUTCFullYear(),e.getUTCMonth(),e.getUTCDate())-Date.UTC(e.getUTCFullYear(),0))/864e5+1;break;case"F":0===(r=e.getUTCDay())&&(r=7);break;case"W":var n=k(e.getUTCFullYear(),0),a=y(n),i=Date.UTC(n.year,e.getUTCMonth(),e.getUTCDate()),o=x(a,i);if(o>52)i>=y(n.nextYear())&&(o=1);else if(o<1){var s=y(n.previousYear());o=x(s,i)}r=Math.floor(o);break;case"w":var u=k(e.getUTCFullYear(),e.getUTCMonth()),c=y(u),p=Date.UTC(u.year,u.month,e.getUTCDate()),f=x(c,p);if(f>4)p>=y(u.nextMonth())&&(f=1);else if(f<1){var l=y(u.previousMonth());f=x(l,p)}r=Math.floor(f);break;case"X":var d=k(e.getUTCFullYear(),0),h=y(d),g=y(d.nextYear()),v=e.getTime();r=v<h?d.year-1:v>=g?d.year+1:d.year;break;case"x":var b=k(e.getUTCFullYear(),e.getUTCMonth()),m=y(b),w=b.nextMonth(),E=y(w),A=e.getTime();r=A<m?b.previousMonth().month+1:A>=E?w.month+1:b.month+1;break;case"H":r=e.getUTCHours();break;case"h":r=e.getUTCHours(),0===(r%=12)&&(r=12);break;case"P":r=e.getUTCHours()>=12?"pm":"am";break;case"m":r=e.getUTCMinutes();break;case"s":r=e.getUTCSeconds();break;case"f":r=e.getUTCMilliseconds();break;case"Z":case"z":break;case"C":case"E":r="ISO"}return r},E=null;function A(e,t,r){var n=0,a=0;if(void 0!==r){var i=parseInt(r);n=Math.floor(i/100),a=i%100}var o;void 0===t?(null===E&&(E=v("[Y0001]-[M01]-[D01]T[H01]:[m01]:[s01].[f001][Z01:01t]")),o=E):o=v(t);var s=new Date(e+60*(60*n+a)*1e3),u="";return o.parts.forEach(function(e){"literal"===e.type?u+=e.value:u+=function(e,t){var r=w(e,t.component);if(-1!=="YMDdFWwXxHhms".indexOf(t.component))if("Y"===t.component&&-1!==t.n&&(r%=Math.pow(10,t.n)),t.names){if("M"===t.component||"x"===t.component)r=m[r-1];else{if("F"!==t.component)throw{code:"D3133",value:t.component};r=b[r]}t.names===f.UPPER?r=r.toUpperCase():t.names===f.LOWER&&(r=r.toLowerCase()),t.width&&r.length>t.width.max&&(r=r.substring(0,t.width.max))}else r=l(r,t.integerFormat);else if("f"===t.component)r=l(r,t.integerFormat);else if("Z"===t.component||"z"===t.component){var i=100*n+a;if(t.integerFormat.regular)r=l(i,t.integerFormat);else{var o=t.integerFormat.mandatoryDigits;if(1===o||2===o)r=l(n,t.integerFormat),0!==a&&(r+=":"+c(a,"00"));else{if(3!==o&&4!==o)throw{code:"D3134",value:o};r=l(i,t.integerFormat)}}i>=0&&(r="+"+r),"z"===t.component&&(r="GMT"+r),0===i&&"t"===t.presentation2&&(r="Z")}return r}(s,e)}),u}function S(e){var t={};if("datetime"===e.type)t.type="datetime",t.parts=e.parts.map(function(e){var t={};if("literal"===e.type)t.regex=e.value.replace(/[.*+?^${}()|[\]\\]/g,"\\$&");else if("Z"===e.component||"z"===e.component){var r;Array.isArray(e.integerFormat.groupingSeparators)||(r=e.integerFormat.groupingSeparators),t.regex="","z"===e.component&&(t.regex="GMT"),t.regex+="[-+][0-9]+",r&&(t.regex+=r.character+"[0-9]+"),t.parse=function(t){"z"===e.component&&(t=t.substring(3));var n=0,a=0;r?(n=Number.parseInt(t.substring(0,t.indexOf(r.character))),a=Number.parseInt(t.substring(t.indexOf(r.character)+1))):t.length-1<=2?n=Number.parseInt(t):(n=Number.parseInt(t.substring(0,3)),a=Number.parseInt(t.substring(3)));return 60*n+a}}else if(e.integerFormat)e.integerFormat.n=e.n,t=S(e.integerFormat);else{t.regex="[a-zA-Z]+";var n={};if("M"===e.component||"x"===e.component)m.forEach(function(t,r){e.width&&e.width.max?n[t.substring(0,e.width.max)]=r+1:n[t]=r+1});else if("F"===e.component)b.forEach(function(t,r){r>0&&(e.width&&e.width.max?n[t.substring(0,e.width.max)]=r:n[t]=r)});else{if("P"!==e.component)throw{code:"D3133",value:e.component};n={am:0,AM:0,pm:1,PM:1}}t.parse=function(e){return n[e]}}return t.component=e.component,t});else{t.type="integer";var r,n=e.case===f.UPPER;switch(r=e.n&&e.n>0?0===e.optionalDigits?"{".concat(e.n,"}"):"{".concat(e.n-e.optionalDigits,",").concat(e.n,"}"):"+",e.primary){case p.LETTERS:t.regex=n?"[A-Z]+":"[a-z]+",t.parse=function(e){return function(e,t){for(var r=t.charCodeAt(0),n=0,a=0;a<e.length;a++)n+=(e.charCodeAt(e.length-a-1)-r+1)*Math.pow(26,a);return n}(e,n?"A":"a")};break;case p.ROMAN:t.regex=n?"[MDCLXVI]+":"[mdclxvi]+",t.parse=function(e){return function(e){for(var t=0,r=1,n=e.length-1;n>=0;n--){var a=e[n],i=u[a];i<r?t-=i:(r=i,t+=i)}return t}(n?e:e.toUpperCase())};break;case p.WORDS:t.regex="(?:"+Object.keys(o).concat("and","[\\-, ]").join("|")+")+",t.parse=function(e){return t=e.toLowerCase(),r=t.split(/,\s|\sand\s|[\s\\-]/).map(function(e){return o[e]}),n=[0],r.forEach(function(e){if(e<100){var t=n.pop();t>=1e3&&(n.push(t),t=0),n.push(t+e)}else n.push(n.pop()*e)}),n.reduce(function(e,t){return e+t},0);var t,r,n};break;case p.DECIMAL:t.regex="[0-9]".concat(r),e.ordinal&&(t.regex+="(?:th|st|nd|rd)"),t.parse=function(t){var r=t;return e.ordinal&&(r=t.substring(0,t.length-2)),e.regular?r=r.split(",").join(""):e.groupingSeparators.forEach(function(e){r=r.split(e.character).join("")}),48!==e.zeroCode&&(r=r.split("").map(function(t){return String.fromCodePoint(t.codePointAt(0)-e.zeroCode+48)}).join("")),parseInt(r)};break;case p.SEQUENCE:throw{code:"D3130",value:e.token}}}return t}var T=new RegExp("^\\d{4}(-[01]\\d)*(-[0-3]\\d)*(T[0-2]\\d:[0-5]\\d:[0-5]\\d)*(\\.\\d+)?([+-][0-2]\\d:?[0-5]\\d|Z)?$");return{formatInteger:c,parseInteger:function(e,t){if(void 0!==e)return S(h(t)).parse(e)},fromMillis:function(e,t,r){if(void 0!==e)return A.call(this,e,t,r)},toMillis:function(e,t){if(void 0!==e){if(void 0===t){if(!T.test(e))throw{stack:(new Error).stack,code:"D3110",value:e};return Date.parse(e)}return function(e,t){var r=S(v(t)),n="^"+r.parts.map(function(e){return"("+e.regex+")"}).join("")+"$",a=new RegExp(n,"i").exec(e);if(null!==a){for(var i={},o=1;o<a.length;o++){var s=r.parts[o-1];s.parse&&(i[s.component]=s.parse(a[o]))}if(0===Object.getOwnPropertyNames(i).length)return;var u=0,c=function(e){u<<=1,u+=e?1:0},p=function(e){return!(~e&u||!(e&u))};"YXMxWwdD".split("").forEach(function(e){return c(i[e])});var f=!p(161)&&p(130),l=p(84),d=!l&&p(72);u=0,"PHhmsf".split("").forEach(function(e){return c(i[e])});var h=!p(23)&&p(47),g=(f?"YD":l?"XxwF":d?"XWF":"YMD")+(h?"Phmsf":"Hmsf"),b=this.environment.timestamp,m=!1,y=!1;if(g.split("").forEach(function(e){if(void 0===i[e])m?(i[e]=-1!=="MDd".indexOf(e)?1:0,y=!0):i[e]=w(b,e);else if(m=!0,y)throw{code:"D3136"}}),i.M>0?i.M-=1:i.M=0,f){var k=Date.UTC(i.Y,0),x=1e3*(i.d-1)*60*60*24,E=new Date(k+x);i.M=E.getUTCMonth(),i.D=E.getUTCDate()}if(l)throw{code:"D3136"};if(d)throw{code:"D3136"};h&&(i.H=12===i.h?0:i.h,1===i.P&&(i.H+=12));var A=Date.UTC(i.Y,i.M,i.D,i.H,i.m,i.s,i.f);return(i.Z||i.z)&&(A-=60*(i.Z||i.z)*1e3),A}}.call(this,e,t)}}}}();t.exports=a},{"./utils":6}],2:[function(e,t,r){(function(r){(function(){"use strict";function n(e){"@babel/helpers - typeof";return(n="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}var a=e("./utils"),i=function(){var e=regeneratorRuntime.mark(O),t=regeneratorRuntime.mark(R),i=regeneratorRuntime.mark(Y),o=regeneratorRuntime.mark(P),s=regeneratorRuntime.mark(M),u=regeneratorRuntime.mark(U),c=regeneratorRuntime.mark(N),p=regeneratorRuntime.mark(I),f=regeneratorRuntime.mark(L),l=regeneratorRuntime.mark(z),d=regeneratorRuntime.mark($),h=regeneratorRuntime.mark(q),g=a.isNumeric,v=a.isArrayOfStrings,b=a.isArrayOfNumbers,m=a.createSequence,y=a.isSequence,k=a.isFunction,x=a.isLambda,w=a.isIterable,E=a.getFunctionArity,A=a.isDeepEqual,S=a.stringToArray;function T(e,t,r){if(void 0!==e){var n=S(e),a=n.length;if(a+t<0&&(t=0),void 0!==r){if(r<=0)return"";var i=t>=0?t+r:a+t+r;return n.slice(t,i).join("")}return n.slice(t).join("")}}function D(e){if(void 0!==e)return S(e).length}function O(t,r){var n;return regeneratorRuntime.wrap(function(e){for(;;)switch(e.prev=e.next){case 0:if(n=t.apply(this,[r]),!w(n)){e.next=4;break}return e.delegateYield(n,"t0",3);case 3:n=e.t0;case 4:if(!n||"number"==typeof n.start||"number"===n.end||Array.isArray(n.groups)||k(n.next)){e.next=6;break}throw{code:"T1010",stack:(new Error).stack};case 6:return e.abrupt("return",n);case 7:case"end":return e.stop()}},e,this)}function R(e,r){var n,a;return regeneratorRuntime.wrap(function(t){for(;;)switch(t.prev=t.next){case 0:if(void 0!==e){t.next=2;break}return t.abrupt("return",void 0);case 2:if("string"!=typeof r){t.next=6;break}n=-1!==e.indexOf(r),t.next=9;break;case 6:return t.delegateYield(O(r,e),"t0",7);case 7:a=t.t0,n=void 0!==a;case 9:return t.abrupt("return",n);case 10:case"end":return t.stop()}},t)}function Y(e,t,r){var n,a,o;return regeneratorRuntime.wrap(function(i){for(;;)switch(i.prev=i.next){case 0:if(void 0!==e){i.next=2;break}return i.abrupt("return",void 0);case 2:if(!(r<0)){i.next=4;break}throw{stack:(new Error).stack,value:r,code:"D3040",index:3};case 4:if(n=m(),!(void 0===r||r>0)){i.next=17;break}return a=0,i.delegateYield(O(t,e),"t0",8);case 8:if(void 0===(o=i.t0)){i.next=17;break}case 10:if(void 0===o||!(void 0===r||a<r)){i.next=17;break}return n.push({match:o.match,index:o.start,groups:o.groups}),i.delegateYield(O(o.next),"t1",13);case 13:o=i.t1,a++,i.next=10;break;case 17:return i.abrupt("return",n);case 18:case"end":return i.stop()}},i)}function P(e,t,r,n){var a,i,s,u,c,p,f,l;return regeneratorRuntime.wrap(function(o){for(;;)switch(o.prev=o.next){case 0:if(void 0!==e){o.next=2;break}return o.abrupt("return",void 0);case 2:if(a=this,""!==t){o.next=5;break}throw{code:"D3010",stack:(new Error).stack,value:t,index:2};case 5:if(!(n<0)){o.next=7;break}throw{code:"D3011",stack:(new Error).stack,value:n,index:4};case 7:if(i="string"==typeof r?function(e){for(var t="",n=0,a=r.indexOf("$",n);-1!==a&&n<r.length;){t+=r.substring(n,a),n=a+1;var i=r.charAt(n);if("$"===i)t+="$",n++;else if("0"===i)t+=e.match,n++;else{var o;if(o=0===e.groups.length?1:Math.floor(Math.log(e.groups.length)*Math.LOG10E)+1,a=parseInt(r.substring(n,n+o),10),o>1&&a>e.groups.length&&(a=parseInt(r.substring(n,n+o-1),10)),isNaN(a))t+="$";else{if(e.groups.length>0){var s=e.groups[a-1];void 0!==s&&(t+=s)}n+=a.toString().length}}a=r.indexOf("$",n)}return t+=r.substring(n)}:r,s="",u=0,!(void 0===n||n>0)){o.next=44;break}if(c=0,"string"!=typeof t){o.next=18;break}for(p=e.indexOf(t,u);-1!==p&&(void 0===n||c<n);)s+=e.substring(u,p),s+=r,u=p+t.length,c++,p=e.indexOf(t,u);s+=e.substring(u),o.next=42;break;case 18:return o.delegateYield(O(t,e),"t0",19);case 19:if(void 0===(f=o.t0)){o.next=41;break}case 21:if(void 0===f||!(void 0===n||c<n)){o.next=38;break}if(s+=e.substring(u,f.start),l=i.apply(a,[f]),!w(l)){o.next=27;break}return o.delegateYield(l,"t1",26);case 26:l=o.t1;case 27:if("string"!=typeof l){o.next=31;break}s+=l,o.next=32;break;case 31:throw{code:"D3012",stack:(new Error).stack,value:l};case 32:return u=f.start+f.match.length,c++,o.delegateYield(O(f.next),"t2",35);case 35:f=o.t2,o.next=21;break;case 38:s+=e.substring(u),o.next=42;break;case 41:s=e;case 42:o.next=45;break;case 44:s=e;case 45:return o.abrupt("return",s);case 46:case"end":return o.stop()}},o,this)}function M(e,t,r){var n,a,i,o;return regeneratorRuntime.wrap(function(s){for(;;)switch(s.prev=s.next){case 0:if(void 0!==e){s.next=2;break}return s.abrupt("return",void 0);case 2:if(!(r<0)){s.next=4;break}throw{code:"D3020",stack:(new Error).stack,value:r,index:3};case 4:if(n=[],!(void 0===r||r>0)){s.next=27;break}if("string"!=typeof t){s.next=10;break}n=e.split(t,r),s.next=27;break;case 10:return a=0,s.delegateYield(O(t,e),"t0",12);case 12:if(void 0===(i=s.t0)){s.next=26;break}o=0;case 15:if(void 0===i||!(void 0===r||a<r)){s.next=23;break}return n.push(e.substring(o,i.start)),o=i.end,s.delegateYield(O(i.next),"t1",19);case 19:i=s.t1,a++,s.next=15;break;case 23:(void 0===r||a<r)&&n.push(e.substring(o)),s.next=27;break;case 26:n.push(e);case 27:return s.abrupt("return",n);case 28:case"end":return s.stop()}},s)}function j(e,t){var r;if(void 0!==e){if(t){var n=e.toString().split("e");e=+(n[0]+"e"+(n[1]?+n[1]+t:t))}var a=(r=Math.round(e))-e;return.5===Math.abs(a)&&1===Math.abs(r%2)&&(r-=1),t&&(r=+((n=r.toString().split("e"))[0]+"e"+(n[1]?+n[1]-t:-t))),Object.is(r,-0)&&(r=0),r}}function C(e){if(void 0!==e){var t=!1;if(Array.isArray(e)){if(1===e.length)t=C(e[0]);else if(e.length>1){t=e.filter(function(e){return C(e)}).length>0}}else"string"==typeof e?e.length>0&&(t=!0):g(e)?0!==e&&(t=!0):null!==e&&"object"===n(e)?Object.keys(e).length>0&&(t=!0):"boolean"==typeof e&&!0===e&&(t=!0);return t}}function F(e,t,r,n){var a=[t],i=E(e);return i>=2&&a.push(r),i>=3&&a.push(n),a}function U(e,t){var r,n,a,i;return regeneratorRuntime.wrap(function(o){for(;;)switch(o.prev=o.next){case 0:if(void 0!==e){o.next=2;break}return o.abrupt("return",void 0);case 2:r=m(),n=0;case 4:if(!(n<e.length)){o.next=12;break}return a=F(t,e[n],n,e),o.delegateYield(t.apply(this,a),"t0",7);case 7:void 0!==(i=o.t0)&&r.push(i);case 9:n++,o.next=4;break;case 12:return o.abrupt("return",r);case 13:case"end":return o.stop()}},u,this)}function N(e,t){var r,n,a,i;return regeneratorRuntime.wrap(function(o){for(;;)switch(o.prev=o.next){case 0:if(void 0!==e){o.next=2;break}return o.abrupt("return",void 0);case 2:r=m(),n=0;case 4:if(!(n<e.length)){o.next=13;break}return a=e[n],i=F(t,a,n,e),o.delegateYield(t.apply(this,i),"t0",8);case 8:C(o.t0)&&r.push(a);case 10:n++,o.next=4;break;case 13:return o.abrupt("return",r);case 14:case"end":return o.stop()}},c,this)}function I(e,t){var r,n,a,i,o,s,u;return regeneratorRuntime.wrap(function(c){for(;;)switch(c.prev=c.next){case 0:if(void 0!==e){c.next=2;break}return c.abrupt("return",void 0);case 2:r=!1,a=0;case 4:if(!(a<e.length)){c.next=22;break}if(i=e[a],o=!0,void 0===t){c.next=12;break}return s=F(t,i,a,e),c.delegateYield(t.apply(this,s),"t0",10);case 10:u=c.t0,o=C(u);case 12:if(!o){c.next=19;break}if(r){c.next=18;break}n=i,r=!0,c.next=19;break;case 18:throw{stack:(new Error).stack,code:"D3138",index:a};case 19:a++,c.next=4;break;case 22:if(r){c.next=24;break}throw{stack:(new Error).stack,code:"D3139"};case 24:return c.abrupt("return",n);case 25:case"end":return c.stop()}},p,this)}function L(e,t,r){var n,a,i,o;return regeneratorRuntime.wrap(function(s){for(;;)switch(s.prev=s.next){case 0:if(void 0!==e){s.next=2;break}return s.abrupt("return",void 0);case 2:if(!((a=E(t))<2)){s.next=5;break}throw{stack:(new Error).stack,code:"D3050",index:1};case 5:void 0===r&&e.length>0?(n=e[0],i=1):(n=r,i=0);case 6:if(!(i<e.length)){s.next=15;break}return o=[n,e[i]],a>=3&&o.push(i),a>=4&&o.push(e),s.delegateYield(t.apply(this,o),"t0",11);case 11:n=s.t0,i++,s.next=6;break;case 15:return s.abrupt("return",n);case 16:case"end":return s.stop()}},f,this)}function _(e,t){return void 0===e?t:void 0===t?e:(Array.isArray(e)||(e=m(e)),Array.isArray(t)||(t=[t]),e.concat(t))}function z(e,t){var r,n,a,i;return regeneratorRuntime.wrap(function(o){for(;;)switch(o.prev=o.next){case 0:r=m(),o.t0=regeneratorRuntime.keys(e);case 2:if((o.t1=o.t0()).done){o.next=10;break}return n=o.t1.value,a=F(t,e[n],n,e),o.delegateYield(t.apply(this,a),"t2",6);case 6:void 0!==(i=o.t2)&&r.push(i),o.next=2;break;case 10:return o.abrupt("return",r);case 11:case"end":return o.stop()}},l,this)}function $(e,t){var r,n,a,i;return regeneratorRuntime.wrap(function(o){for(;;)switch(o.prev=o.next){case 0:if(void 0!==e){o.next=2;break}return o.abrupt("return",void 0);case 2:if(!(e.length<=1)){o.next=4;break}return o.abrupt("return",e);case 4:if(void 0!==t){o.next=10;break}if(b(e)||v(e)){o.next=7;break}throw{stack:(new Error).stack,code:"D3070",index:1};case 7:r=regeneratorRuntime.mark(function e(t,r){return regeneratorRuntime.wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return e.abrupt("return",t>r);case 1:case"end":return e.stop()}},e)}),o.next=11;break;case 10:r=t;case 11:return n=regeneratorRuntime.mark(function e(t,n){var a,i;return regeneratorRuntime.wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return a=regeneratorRuntime.mark(function e(t,n,a){return regeneratorRuntime.wrap(function(i){for(;;)switch(i.prev=i.next){case 0:if(0!==n.length){i.next=4;break}Array.prototype.push.apply(t,a),i.next=16;break;case 4:if(0!==a.length){i.next=8;break}Array.prototype.push.apply(t,n),i.next=16;break;case 8:return i.delegateYield(r(n[0],a[0]),"t0",9);case 9:if(!i.t0){i.next=14;break}return t.push(a[0]),i.delegateYield(e(t,n,a.slice(1)),"t1",12);case 12:i.next=16;break;case 14:return t.push(n[0]),i.delegateYield(e(t,n.slice(1),a),"t2",16);case 16:case"end":return i.stop()}},e)}),i=[],e.delegateYield(a(i,t,n),"t0",3);case 3:return e.abrupt("return",i);case 4:case"end":return e.stop()}},e)}),a=regeneratorRuntime.mark(function e(t){var r,a,i;return regeneratorRuntime.wrap(function(o){for(;;)switch(o.prev=o.next){case 0:if(Array.isArray(t)&&!(t.length<=1)){o.next=4;break}return o.abrupt("return",t);case 4:return r=Math.floor(t.length/2),a=t.slice(0,r),i=t.slice(r),o.delegateYield(e(a),"t0",8);case 8:return a=o.t0,o.delegateYield(e(i),"t1",10);case 10:return i=o.t1,o.delegateYield(n(a,i),"t2",12);case 12:return o.abrupt("return",o.t2);case 13:case"end":return o.stop()}},e)}),o.delegateYield(a(e),"t0",14);case 14:return i=o.t0,o.abrupt("return",i);case 16:case"end":return o.stop()}},d)}function q(e,t){var r,n,a,i;return regeneratorRuntime.wrap(function(o){for(;;)switch(o.prev=o.next){case 0:r={},o.t0=regeneratorRuntime.keys(e);case 2:if((o.t1=o.t0()).done){o.next=11;break}return n=o.t1.value,a=e[n],i=F(t,a,n,e),o.delegateYield(t.apply(this,i),"t2",7);case 7:C(o.t2)&&(r[n]=a),o.next=2;break;case 11:return 0===Object.keys(r).length&&(r=void 0),o.abrupt("return",r);case 13:case"end":return o.stop()}},h,this)}return{sum:function(e){if(void 0!==e){var t=0;return e.forEach(function(e){t+=e}),t}},count:function(e){return void 0===e?0:e.length},max:function(e){if(void 0!==e&&0!==e.length)return Math.max.apply(Math,e)},min:function(e){if(void 0!==e&&0!==e.length)return Math.min.apply(Math,e)},average:function(e){if(void 0!==e&&0!==e.length){var t=0;return e.forEach(function(e){t+=e}),t/e.length}},string:function(e){var t=arguments.length>1&&void 0!==arguments[1]&&arguments[1];if(void 0!==e){var r;if("string"==typeof e)r=e;else if(k(e))r="";else{if("number"==typeof e&&!isFinite(e))throw{code:"D3001",value:e,stack:(new Error).stack};var n=t?2:0;Array.isArray(e)&&e.outerWrapper&&(e=e[0]),r=JSON.stringify(e,function(e,t){return null!=t&&t.toPrecision&&g(t)?Number(t.toPrecision(15)):t&&k(t)?"":t},n)}return r}},substring:T,substringBefore:function(e,t){if(void 0!==e){var r=e.indexOf(t);return r>-1?e.substr(0,r):e}},substringAfter:function(e,t){if(void 0!==e){var r=e.indexOf(t);return r>-1?e.substr(r+t.length):e}},lowercase:function(e){if(void 0!==e)return e.toLowerCase()},uppercase:function(e){if(void 0!==e)return e.toUpperCase()},length:D,trim:function(e){if(void 0!==e){var t=e.replace(/[ \t\n\r]+/gm," ");return" "===t.charAt(0)&&(t=t.substring(1))," "===t.charAt(t.length-1)&&(t=t.substring(0,t.length-1)),t}},pad:function(e,t,r){if(void 0!==e){var n;void 0!==r&&0!==r.length||(r=" ");var a=Math.abs(t)-D(e);if(a>0){var i=new Array(a+1).join(r);r.length>1&&(i=T(i,0,a)),n=t>0?e+i:i+e}else n=e;return n}},match:Y,contains:R,replace:P,split:M,join:function(e,t){if(void 0!==e)return void 0===t&&(t=""),e.join(t)},formatNumber:function(e,t,r){if(void 0!==e){var n={"decimal-separator":".","grouping-separator":",","exponent-separator":"e",infinity:"Infinity","minus-sign":"-",NaN:"NaN",percent:"%","per-mille":"‰","zero-digit":"0",digit:"#","pattern-separator":";"};void 0!==r&&Object.keys(r).forEach(function(e){n[e]=r[e]});for(var a=[],i=n["zero-digit"].charCodeAt(0),o=i;o<i+10;o++)a.push(String.fromCharCode(o));var s=a.concat([n["decimal-separator"],n["exponent-separator"],n["grouping-separator"],n.digit,n["pattern-separator"]]),u=t.split(n["pattern-separator"]);if(u.length>2)throw{code:"D3080",stack:(new Error).stack};var c=u.map(function(e){var t,r,a,i,o=function(){for(var t,r=0;r<e.length;r++)if(t=e.charAt(r),-1!==s.indexOf(t)&&t!==n["exponent-separator"])return e.substring(0,r)}(),u=function(){for(var t,r=e.length-1;r>=0;r--)if(t=e.charAt(r),-1!==s.indexOf(t)&&t!==n["exponent-separator"])return e.substring(r+1)}(),c=e.substring(o.length,e.length-u.length),p=e.indexOf(n["exponent-separator"],o.length);-1===p||p>e.length-u.length?(t=c,r=void 0):(t=c.substring(0,p),r=c.substring(p+1));var f=t.indexOf(n["decimal-separator"]);return-1===f?(a=t,i=u):(a=t.substring(0,f),i=t.substring(f+1)),{prefix:o,suffix:u,activePart:c,mantissaPart:t,exponentPart:r,integerPart:a,fractionalPart:i,subpicture:e}});c.forEach(function(e){var t,r,i=e.subpicture,o=i.indexOf(n["decimal-separator"]);o!==i.lastIndexOf(n["decimal-separator"])&&(t="D3081"),i.indexOf(n.percent)!==i.lastIndexOf(n.percent)&&(t="D3082"),i.indexOf(n["per-mille"])!==i.lastIndexOf(n["per-mille"])&&(t="D3083"),-1!==i.indexOf(n.percent)&&-1!==i.indexOf(n["per-mille"])&&(t="D3084");var u=!1;for(r=0;r<e.mantissaPart.length;r++){var c=e.mantissaPart.charAt(r);if(-1!==a.indexOf(c)||c===n.digit){u=!0;break}}u||(t="D3085"),-1!==e.activePart.split("").map(function(e){return-1===s.indexOf(e)?"p":"a"}).join("").indexOf("p")&&(t="D3086"),-1!==o?i.charAt(o-1)!==n["grouping-separator"]&&i.charAt(o+1)!==n["grouping-separator"]||(t="D3087"):e.integerPart.charAt(e.integerPart.length-1)===n["grouping-separator"]&&(t="D3088"),-1!==i.indexOf(n["grouping-separator"]+n["grouping-separator"])&&(t="D3089");var p=e.integerPart.indexOf(n.digit);-1!==p&&e.integerPart.substring(0,p).split("").filter(function(e){return a.indexOf(e)>-1}).length>0&&(t="D3090"),-1!==(p=e.fractionalPart.lastIndexOf(n.digit))&&e.fractionalPart.substring(p).split("").filter(function(e){return a.indexOf(e)>-1}).length>0&&(t="D3091");var f="string"==typeof e.exponentPart;if(f&&e.exponentPart.length>0&&(-1!==i.indexOf(n.percent)||-1!==i.indexOf(n["per-mille"]))&&(t="D3092"),f&&(0===e.exponentPart.length||e.exponentPart.split("").filter(function(e){return-1===a.indexOf(e)}).length>0)&&(t="D3093"),t)throw{code:t,stack:(new Error).stack}});var p,f,l,d,h=c.map(function(e){var t=function(t,r){for(var i=[],o=t.indexOf(n["grouping-separator"]);-1!==o;){var s=(r?t.substring(0,o):t.substring(o)).split("").filter(function(e){return-1!==a.indexOf(e)||e===n.digit}).length;i.push(s),o=e.integerPart.indexOf(n["grouping-separator"],o+1)}return i},r=t(e.integerPart),i=function(e){if(0===e.length)return 0;for(var t=e.reduce(function e(t,r){return 0===r?t:e(r,t%r)}),r=1;r<=e.length;r++)if(-1===e.indexOf(r*t))return 0;return t}(r),o=t(e.fractionalPart,!0),s=e.integerPart.split("").filter(function(e){return-1!==a.indexOf(e)}).length,u=s,c=e.fractionalPart.split(""),p=c.filter(function(e){return-1!==a.indexOf(e)}).length,f=c.filter(function(e){return-1!==a.indexOf(e)||e===n.digit}).length,l="string"==typeof e.exponentPart;0===s&&0===f&&(l?(p=1,f=1):s=1),l&&0===s&&-1!==e.integerPart.indexOf(n.digit)&&(s=1),0===s&&0===p&&(p=1);var d=0;return l&&(d=e.exponentPart.split("").filter(function(e){return-1!==a.indexOf(e)}).length),{integerPartGroupingPositions:r,regularGrouping:i,minimumIntegerPartSize:s,scalingFactor:u,prefix:e.prefix,fractionalPartGroupingPositions:o,minimumFactionalPartSize:p,maximumFactionalPartSize:f,minimumExponentSize:d,suffix:e.suffix,picture:e.subpicture}}),g=n["minus-sign"],v=n["zero-digit"],b=n["decimal-separator"],m=n["grouping-separator"];if(1===h.length&&(h.push(JSON.parse(JSON.stringify(h[0]))),h[1].prefix=g+h[1].prefix),f=-1!==(p=e>=0?h[0]:h[1]).picture.indexOf(n.percent)?100*e:-1!==p.picture.indexOf(n["per-mille"])?1e3*e:e,0===p.minimumExponentSize)l=f;else{var y=Math.pow(10,p.scalingFactor),k=Math.pow(10,p.scalingFactor-1);for(l=f,d=0;l<k;)l*=10,d-=1;for(;l>y;)l/=10,d+=1}var x=function(e,t){var r=Math.abs(e).toFixed(t);return"0"!==v&&(r=r.split("").map(function(e){return e>="0"&&e<="9"?a[e.charCodeAt(0)-48]:e}).join("")),r},w=x(j(l,p.maximumFactionalPartSize),p.maximumFactionalPartSize),E=w.indexOf(".");for(-1===E?w+=b:w=w.replace(".",b);w.charAt(0)===v;)w=w.substring(1);for(;w.charAt(w.length-1)===v;)w=w.substring(0,w.length-1);E=w.indexOf(b);var A=p.minimumIntegerPartSize-E,S=p.minimumFactionalPartSize-(w.length-E-1);if(w=(A>0?new Array(A+1).join(v):"")+w,w+=S>0?new Array(S+1).join(v):"",E=w.indexOf(b),p.regularGrouping>0)for(var T=Math.floor((E-1)/p.regularGrouping),D=1;D<=T;D++)w=[w.slice(0,E-D*p.regularGrouping),m,w.slice(E-D*p.regularGrouping)].join("");else p.integerPartGroupingPositions.forEach(function(e){w=[w.slice(0,E-e),m,w.slice(E-e)].join(""),E++});if(E=w.indexOf(b),p.fractionalPartGroupingPositions.forEach(function(e){w=[w.slice(0,e+E+1),m,w.slice(e+E+1)].join("")}),E=w.indexOf(b),-1!==p.picture.indexOf(b)&&E!==w.length-1||(w=w.substring(0,w.length-1)),void 0!==d){var O=x(d,0);(A=p.minimumExponentSize-O.length)>0&&(O=new Array(A+1).join(v)+O),w=w+n["exponent-separator"]+(d<0?g:"")+O}return w=p.prefix+w+p.suffix}},formatBase:function(e,t){if(void 0!==e){if(e=j(e),(t=void 0===t?10:j(t))<2||t>36)throw{code:"D3100",stack:(new Error).stack,value:t};return e.toString(t)}},number:function(e){var t;if(void 0!==e){if("number"==typeof e)t=e;else if("string"==typeof e&&/^-?[0-9]+(\.[0-9]+)?([Ee][-+]?[0-9]+)?$/.test(e)&&!isNaN(parseFloat(e))&&isFinite(e))t=parseFloat(e);else if(!0===e)t=1;else{if(!1!==e)throw{code:"D3030",value:e,stack:(new Error).stack,index:1};t=0}return t}},floor:function(e){if(void 0!==e)return Math.floor(e)},ceil:function(e){if(void 0!==e)return Math.ceil(e)},round:j,abs:function(e){if(void 0!==e)return Math.abs(e)},sqrt:function(e){if(void 0!==e){if(e<0)throw{stack:(new Error).stack,code:"D3060",index:1,value:e};return Math.sqrt(e)}},power:function(e,t){var r;if(void 0!==e){if(r=Math.pow(e,t),!isFinite(r))throw{stack:(new Error).stack,code:"D3061",index:1,value:e,exp:t};return r}},random:function(){return Math.random()},boolean:C,not:function(e){if(void 0!==e)return!C(e)},map:U,zip:function(){for(var e=[],t=Array.prototype.slice.call(arguments),r=Math.min.apply(Math,t.map(function(e){return Array.isArray(e)?e.length:0})),n=0;n<r;n++){var a=t.map(function(e){return e[n]});e.push(a)}return e},filter:N,single:I,foldLeft:L,sift:q,keys:function e(t){var r=m();if(Array.isArray(t)){var a={};t.forEach(function(t){e(t).forEach(function(e){a[e]=!0})}),r=e(a)}else null===t||"object"!==n(t)||x(t)||Object.keys(t).forEach(function(e){return r.push(e)});return r},lookup:function e(t,r){var a;if(Array.isArray(t)){a=m();for(var i=0;i<t.length;i++){var o=e(t[i],r);void 0!==o&&(Array.isArray(o)?o.forEach(function(e){return a.push(e)}):a.push(o))}}else null!==t&&"object"===n(t)&&(a=t[r]);return a},append:_,exists:function(e){return void 0!==e},spread:function e(t){var r=m();if(Array.isArray(t))t.forEach(function(t){r=_(r,e(t))});else if(null===t||"object"!==n(t)||x(t))r=t;else for(var a in t){var i={};i[a]=t[a],r.push(i)}return r},merge:function(e){if(void 0!==e){var t={};return e.forEach(function(e){for(var r in e)t[r]=e[r]}),t}},reverse:function(e){if(void 0!==e){if(e.length<=1)return e;for(var t=e.length,r=new Array(t),n=0;n<t;n++)r[t-n-1]=e[n];return r}},each:z,error:function(e){throw{code:"D3137",stack:(new Error).stack,message:e||"$error() function evaluated"}},assert:function(e,t){if(!e)throw{code:"D3141",stack:(new Error).stack,message:t||"$assert() statement failed"}},type:function(e){if(void 0!==e)return null===e?"null":g(e)?"number":"string"==typeof e?"string":"boolean"==typeof e?"boolean":Array.isArray(e)?"array":k(e)?"function":"object"},sort:$,shuffle:function(e){if(void 0!==e){if(e.length<=1)return e;for(var t=new Array(e.length),r=0;r<e.length;r++){var n=Math.floor(Math.random()*(r+1));r!==n&&(t[r]=t[n]),t[n]=e[r]}return t}},distinct:function(e){if(void 0!==e){if(!Array.isArray(e)||e.length<=1)return e;for(var t=y(e)?m():[],r=0;r<e.length;r++){for(var n=e[r],a=!1,i=0;i<t.length;i++)if(A(n,t[i])){a=!0;break}a||t.push(n)}return t}},base64encode:function(e){if(void 0!==e)return("undefined"!=typeof window?window.btoa:function(e){return new r.Buffer.from(e,"binary").toString("base64")})(e)},base64decode:function(e){if(void 0!==e)return("undefined"!=typeof window?window.atob:function(e){return new r.Buffer.from(e,"base64").toString("binary")})(e)},encodeUrlComponent:function(e){if(void 0!==e){var t;try{t=encodeURIComponent(e)}catch(t){throw{code:"D3140",stack:(new Error).stack,value:e,functionName:"encodeUrlComponent"}}return t}},encodeUrl:function(e){if(void 0!==e){var t;try{t=encodeURI(e)}catch(t){throw{code:"D3140",stack:(new Error).stack,value:e,functionName:"encodeUrl"}}return t}},decodeUrlComponent:function(e){if(void 0!==e){var t;try{t=decodeURIComponent(e)}catch(t){throw{code:"D3140",stack:(new Error).stack,value:e,functionName:"decodeUrlComponent"}}return t}},decodeUrl:function(e){if(void 0!==e){var t;try{t=decodeURI(e)}catch(t){throw{code:"D3140",stack:(new Error).stack,value:e,functionName:"decodeUrl"}}return t}}}}();t.exports=i}).call(this)}).call(this,"undefined"!=typeof global?global:"undefined"!=typeof self?self:"undefined"!=typeof window?window:{})},{"./utils":6}],3:[function(e,t,r){"use strict";function n(e){"@babel/helpers - typeof";return(n="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}var a=e("./datetime"),i=e("./functions"),o=e("./utils"),s=e("./parser"),u=e("./signature"),c=function(){var e=regeneratorRuntime.mark(L),t=regeneratorRuntime.mark(_),r=regeneratorRuntime.mark($),c=regeneratorRuntime.mark(q),p=regeneratorRuntime.mark(W),f=regeneratorRuntime.mark(G),l=regeneratorRuntime.mark(H),d=regeneratorRuntime.mark(Z),h=regeneratorRuntime.mark(re),g=regeneratorRuntime.mark(ie),v=regeneratorRuntime.mark(ue),b=regeneratorRuntime.mark(ce),m=regeneratorRuntime.mark(pe),y=regeneratorRuntime.mark(de),k=regeneratorRuntime.mark(ve),x=regeneratorRuntime.mark(be),w=regeneratorRuntime.mark(me),E=regeneratorRuntime.mark(ye),A=regeneratorRuntime.mark(xe),S=regeneratorRuntime.mark(Ee),T=regeneratorRuntime.mark(Te),D=regeneratorRuntime.mark(Re),O=o.isNumeric,R=o.isArrayOfStrings,Y=o.isArrayOfNumbers,P=o.createSequence,M=o.isSequence,j=o.isFunction,C=o.isLambda,F=o.isIterable,U=o.getFunctionArity,N=o.isDeepEqual,I=Ye(null);function L(t,r,n){var a,i,o,s;return regeneratorRuntime.wrap(function(e){for(;;)switch(e.prev=e.next){case 0:(i=n.lookup("__evaluate_entry"))&&i(t,r,n),e.t0=t.type,e.next="path"===e.t0?5:"binary"===e.t0?8:"unary"===e.t0?11:"name"===e.t0?14:"string"===e.t0?16:"number"===e.t0?16:"value"===e.t0?16:"wildcard"===e.t0?18:"descendant"===e.t0?20:"parent"===e.t0?22:"condition"===e.t0?24:"block"===e.t0?27:"bind"===e.t0?30:"regex"===e.t0?33:"function"===e.t0?35:"variable"===e.t0?38:"lambda"===e.t0?40:"partial"===e.t0?42:"apply"===e.t0?45:"transform"===e.t0?48:50;break;case 5:return e.delegateYield(_(t,r,n),"t1",6);case 6:return a=e.t1,e.abrupt("break",50);case 8:return e.delegateYield(H(t,r,n),"t2",9);case 9:return a=e.t2,e.abrupt("break",50);case 11:return e.delegateYield(Z(t,r,n),"t3",12);case 12:return a=e.t3,e.abrupt("break",50);case 14:return a=B(t,r,n),e.abrupt("break",50);case 16:return a=J(t),e.abrupt("break",50);case 18:return a=X(t,r),e.abrupt("break",50);case 20:return a=Q(t,r),e.abrupt("break",50);case 22:return a=n.lookup(t.slot.label),e.abrupt("break",50);case 24:return e.delegateYield(ce(t,r,n),"t4",25);case 25:return a=e.t4,e.abrupt("break",50);case 27:return e.delegateYield(pe(t,r,n),"t5",28);case 28:return a=e.t5,e.abrupt("break",50);case 30:return e.delegateYield(ue(t,r,n),"t6",31);case 31:return a=e.t6,e.abrupt("break",50);case 33:return a=fe(t),e.abrupt("break",50);case 35:return e.delegateYield(be(t,r,n),"t7",36);case 36:return a=e.t7,e.abrupt("break",50);case 38:return a=le(t,r,n),e.abrupt("break",50);case 40:return a=ke(t,r,n),e.abrupt("break",50);case 42:return e.delegateYield(xe(t,r,n),"t8",43);case 43:return a=e.t8,e.abrupt("break",50);case 45:return e.delegateYield(ve(t,r,n),"t9",46);case 46:return a=e.t9,e.abrupt("break",50);case 48:return a=he(t,r,n),e.abrupt("break",50);case 50:if(!n.async||null!=a&&"function"==typeof a.then||(a=Promise.resolve(a)),!n.async||"function"!=typeof a.then||!t.nextFunction||"function"!=typeof a[t.nextFunction]){e.next=54;break}e.next=57;break;case 54:return e.next=56,a;case 56:a=e.sent;case 57:if(!Object.prototype.hasOwnProperty.call(t,"predicate")){e.next=65;break}o=0;case 59:if(!(o<t.predicate.length)){e.next=65;break}return e.delegateYield(G(t.predicate[o].expr,a,n),"t10",61);case 61:a=e.t10;case 62:o++,e.next=59;break;case 65:if("path"===t.type||!Object.prototype.hasOwnProperty.call(t,"group")){e.next=68;break}return e.delegateYield(ie(t.group,a,n),"t11",67);case 67:a=e.t11;case 68:return(s=n.lookup("__evaluate_exit"))&&s(t,r,n,a),a&&M(a)&&!a.tupleStream&&(t.keepArray&&(a.keepSingleton=!0),0===a.length?a=void 0:1===a.length&&(a=a.keepSingleton?a:a[0])),e.abrupt("return",a);case 72:case"end":return e.stop()}},e)}function _(e,r,n){var a,i,o,s,u,c;return regeneratorRuntime.wrap(function(t){for(;;)switch(t.prev=t.next){case 0:a=Array.isArray(r)&&"variable"!==e.steps[0].type?r:P(r),o=!1,s=void 0,u=0;case 4:if(!(u<e.steps.length)){t.next=25;break}if((c=e.steps[u]).tuple&&(o=!0),0!==u||!c.consarray){t.next=12;break}return t.delegateYield(L(c,a,n),"t0",9);case 9:i=t.t0,t.next=19;break;case 12:if(!o){t.next=17;break}return t.delegateYield(W(c,a,s,n),"t1",14);case 14:s=t.t1,t.next=19;break;case 17:return t.delegateYield($(c,a,n,u===e.steps.length-1),"t2",18);case 18:i=t.t2;case 19:if(o||void 0!==i&&0!==i.length){t.next=21;break}return t.abrupt("break",25);case 21:void 0===c.focus&&(a=i);case 22:u++,t.next=4;break;case 25:if(o)if(e.tuple)i=s;else for(i=P(),u=0;u<s.length;u++)i.push(s[u]["@"]);if(e.keepSingletonArray&&(Array.isArray(i)&&i.cons&&!i.sequence&&(i=P(i)),i.keepSingleton=!0),!e.hasOwnProperty("group")){t.next=30;break}return t.delegateYield(ie(e.group,o?s:i,n),"t3",29);case 29:i=t.t3;case 30:return t.abrupt("return",i);case 31:case"end":return t.stop()}},t)}function z(e,t){var r=Ye(e);for(var n in t)r.bind(n,t[n]);return r}function $(e,t,n,a){var i,o,s,u,c;return regeneratorRuntime.wrap(function(r){for(;;)switch(r.prev=r.next){case 0:if("sort"!==e.type){r.next=7;break}return r.delegateYield(de(e,t,n),"t0",2);case 2:if(i=r.t0,!e.stages){r.next=6;break}return r.delegateYield(q(e.stages,i,n),"t1",5);case 5:i=r.t1;case 6:return r.abrupt("return",i);case 7:i=P(),o=0;case 9:if(!(o<t.length)){r.next=24;break}return r.delegateYield(L(e,t[o],n),"t2",11);case 11:if(s=r.t2,!e.stages){r.next=20;break}u=0;case 14:if(!(u<e.stages.length)){r.next=20;break}return r.delegateYield(G(e.stages[u].expr,s,n),"t3",16);case 16:s=r.t3;case 17:u++,r.next=14;break;case 20:void 0!==s&&i.push(s);case 21:o++,r.next=9;break;case 24:return c=P(),a&&1===i.length&&Array.isArray(i[0])&&!M(i[0])?c=i[0]:i.forEach(function(e){!Array.isArray(e)||e.cons?c.push(e):e.forEach(function(e){return c.push(e)})}),r.abrupt("return",c);case 27:case"end":return r.stop()}},r)}function q(e,t,r){var n,a,i,o;return regeneratorRuntime.wrap(function(s){for(;;)switch(s.prev=s.next){case 0:n=t,a=0;case 2:if(!(a<e.length)){s.next=15;break}i=e[a],s.t0=i.type,s.next="filter"===s.t0?7:"index"===s.t0?10:12;break;case 7:return s.delegateYield(G(i.expr,n,r),"t1",8);case 8:return n=s.t1,s.abrupt("break",12);case 10:for(o=0;o<n.length;o++)n[o][i.value]=o;return s.abrupt("break",12);case 12:a++,s.next=2;break;case 15:return s.abrupt("return",n);case 16:case"end":return s.stop()}},c)}function W(e,t,r,n){var a,i,o,s,u,c,f,l;return regeneratorRuntime.wrap(function(p){for(;;)switch(p.prev=p.next){case 0:if("sort"!==e.type){p.next=15;break}if(!r){p.next=6;break}return p.delegateYield(de(e,r,n),"t0",3);case 3:a=p.t0,p.next=11;break;case 6:return p.delegateYield(de(e,t,n),"t1",7);case 7:for(i=p.t1,(a=P()).tupleStream=!0,o=0;o<i.length;o++)(s={"@":i[o]})[e.index]=o,a.push(s);case 11:if(!e.stages){p.next=14;break}return p.delegateYield(q(e.stages,a,n),"t2",13);case 13:a=p.t2;case 14:return p.abrupt("return",a);case 15:(a=P()).tupleStream=!0,u=n,void 0===r&&(r=t.map(function(e){return{"@":e}})),c=0;case 20:if(!(c<r.length)){p.next=28;break}return u=z(n,r[c]),p.delegateYield(L(e,r[c]["@"],u),"t3",23);case 23:if(void 0!==(f=p.t3))for(Array.isArray(f)||(f=[f]),l=0;l<f.length;l++)s={},Object.assign(s,r[c]),f.tupleStream?Object.assign(s,f[l]):(e.focus?(s[e.focus]=f[l],s["@"]=r[c]["@"]):s["@"]=f[l],e.index&&(s[e.index]=l),e.ancestor&&(s[e.ancestor.label]=r[c]["@"])),a.push(s);case 25:c++,p.next=20;break;case 28:if(!e.stages){p.next=31;break}return p.delegateYield(q(e.stages,a,n),"t4",30);case 30:a=p.t4;case 31:return p.abrupt("return",a);case 32:case"end":return p.stop()}},p)}function G(e,t,r){var n,a,o,s,u,c;return regeneratorRuntime.wrap(function(p){for(;;)switch(p.prev=p.next){case 0:if(n=P(),t&&t.tupleStream&&(n.tupleStream=!0),Array.isArray(t)||(t=P(t)),"number"!==e.type){p.next=10;break}(a=Math.floor(e.value))<0&&(a=t.length+a),void 0!==(o=t[a])&&(Array.isArray(o)?n=o:n.push(o)),p.next=23;break;case 10:a=0;case 11:if(!(a<t.length)){p.next=23;break}return o=t[a],s=o,u=r,t.tupleStream&&(s=o["@"],u=z(r,o)),p.delegateYield(L(e,s,u),"t0",17);case 17:c=p.t0,O(c)&&(c=[c]),Y(c)?c.forEach(function(e){var r=Math.floor(e);r<0&&(r=t.length+r),r===a&&n.push(o)}):i.boolean(c)&&n.push(o);case 20:a++,p.next=11;break;case 23:return p.abrupt("return",n);case 24:case"end":return p.stop()}},f)}function H(e,t,r){var n,a,i,o,s;return regeneratorRuntime.wrap(function(u){for(;;)switch(u.prev=u.next){case 0:return u.delegateYield(L(e.lhs,t,r),"t0",1);case 1:if(a=u.t0,i=e.value,o=regeneratorRuntime.mark(function n(){return regeneratorRuntime.wrap(function(n){for(;;)switch(n.prev=n.next){case 0:return n.delegateYield(L(e.rhs,t,r),"t0",1);case 1:return n.abrupt("return",n.t0);case 2:case"end":return n.stop()}},n)}),"and"!==i&&"or"!==i){u.next=15;break}return u.prev=5,u.delegateYield(re(a,o,i),"t1",7);case 7:return u.abrupt("return",u.t1);case 10:throw u.prev=10,u.t2=u.catch(5),u.t2.position=e.position,u.t2.token=i,u.t2;case 15:return u.delegateYield(o(),"t3",16);case 16:s=u.t3,u.prev=17,u.t4=i,u.next="+"===u.t4?21:"-"===u.t4?21:"*"===u.t4?21:"/"===u.t4?21:"%"===u.t4?21:"="===u.t4?23:"!="===u.t4?23:"<"===u.t4?25:"<="===u.t4?25:">"===u.t4?25:">="===u.t4?25:"&"===u.t4?27:".."===u.t4?29:"in"===u.t4?31:33;break;case 21:return n=V(a,s,i),u.abrupt("break",33);case 23:return n=K(a,s,i),u.abrupt("break",33);case 25:return n=ee(a,s,i),u.abrupt("break",33);case 27:return n=ae(a,s),u.abrupt("break",33);case 29:return n=se(a,s),u.abrupt("break",33);case 31:return n=te(a,s),u.abrupt("break",33);case 33:u.next=40;break;case 35:throw u.prev=35,u.t5=u.catch(17),u.t5.position=e.position,u.t5.token=i,u.t5;case 40:return u.abrupt("return",n);case 41:case"end":return u.stop()}},l,null,[[5,10],[17,35]])}function Z(e,t,r){var n,a,o,s;return regeneratorRuntime.wrap(function(u){for(;;)switch(u.prev=u.next){case 0:u.t0=e.value,u.next="-"===u.t0?3:"["===u.t0?15:"{"===u.t0?27:30;break;case 3:return u.delegateYield(L(e.expression,t,r),"t1",4);case 4:if(void 0!==(n=u.t1)){u.next=9;break}n=void 0,u.next=14;break;case 9:if(!O(n)){u.next=13;break}n=-n,u.next=14;break;case 13:throw{code:"D1002",stack:(new Error).stack,position:e.position,token:e.value,value:n};case 14:return u.abrupt("break",30);case 15:n=[],a=0;case 17:if(!(a<e.expressions.length)){u.next=25;break}return o=e.expressions[a],u.delegateYield(L(o,t,r),"t2",20);case 20:void 0!==(s=u.t2)&&("["===o.value?n.push(s):n=i.append(n,s));case 22:a++,u.next=17;break;case 25:return e.consarray&&Object.defineProperty(n,"cons",{enumerable:!1,configurable:!1,value:!0}),u.abrupt("break",30);case 27:return u.delegateYield(ie(e,t,r),"t3",28);case 28:return n=u.t3,u.abrupt("break",30);case 30:return u.abrupt("return",n);case 31:case"end":return u.stop()}},d)}function B(e,t,r){return i.lookup(t,e.value)}function J(e){return e.value}function X(e,t){var r=P();return Array.isArray(t)&&t.outerWrapper&&t.length>0&&(t=t[0]),null!==t&&"object"===n(t)&&Object.keys(t).forEach(function(e){var n=t[e];Array.isArray(n)?(n=function e(t,r){void 0===r&&(r=[]);Array.isArray(t)?t.forEach(function(t){e(t,r)}):r.push(t);return r}(n),r=i.append(r,n)):r.push(n)}),r}function Q(e,t){var r,a=P();return void 0!==t&&(!function e(t,r){Array.isArray(t)||r.push(t);Array.isArray(t)?t.forEach(function(t){e(t,r)}):null!==t&&"object"===n(t)&&Object.keys(t).forEach(function(n){e(t[n],r)})}(t,a),r=1===a.length?a[0]:a),r}function V(e,t,r){var n;if(void 0!==e&&!O(e))throw{code:"T2001",stack:(new Error).stack,value:e};if(void 0!==t&&!O(t))throw{code:"T2002",stack:(new Error).stack,value:t};if(void 0===e||void 0===t)return n;switch(r){case"+":n=e+t;break;case"-":n=e-t;break;case"*":n=e*t;break;case"/":n=e/t;break;case"%":n=e%t}return n}function K(e,t,r){var a,i=n(e),o=n(t);if("undefined"===i||"undefined"===o)return!1;switch(r){case"=":a=N(e,t);break;case"!=":a=!N(e,t)}return a}function ee(e,t,r){var a,i=n(e),o=n(t);if(!("undefined"===i||"string"===i||"number"===i)||!("undefined"===o||"string"===o||"number"===o))throw{code:"T2010",stack:(new Error).stack,value:"string"!==i&&"number"!==i?e:t};if("undefined"!==i&&"undefined"!==o){if(i!==o)throw{code:"T2009",stack:(new Error).stack,value:e,value2:t};switch(r){case"<":a=e<t;break;case"<=":a=e<=t;break;case">":a=e>t;break;case">=":a=e>=t}return a}}function te(e,t){var r=!1;if(void 0===e||void 0===t)return!1;Array.isArray(t)||(t=[t]);for(var n=0;n<t.length;n++)if(t[n]===e){r=!0;break}return r}function re(e,t,r){var n,a;return regeneratorRuntime.wrap(function(i){for(;;)switch(i.prev=i.next){case 0:a=ne(e),i.t0=r,i.next="and"===i.t0?4:"or"===i.t0?12:20;break;case 4:if(i.t1=a,!i.t1){i.next=10;break}return i.t2=ne,i.delegateYield(t(),"t3",8);case 8:i.t4=i.t3,i.t1=(0,i.t2)(i.t4);case 10:return n=i.t1,i.abrupt("break",20);case 12:if(i.t5=a,i.t5){i.next=18;break}return i.t6=ne,i.delegateYield(t(),"t7",16);case 16:i.t8=i.t7,i.t5=(0,i.t6)(i.t8);case 18:return n=i.t5,i.abrupt("break",20);case 20:return i.abrupt("return",n);case 21:case"end":return i.stop()}},h)}function ne(e){var t=i.boolean(e);return void 0!==t&&t}function ae(e,t){var r="",n="";return void 0!==e&&(r=i.string(e)),void 0!==t&&(n=i.string(t)),r.concat(n)}function ie(e,t,r){var n,a,o,s,u,c,p,f,l,d,h,v,b;return regeneratorRuntime.wrap(function(g){for(;;)switch(g.prev=g.next){case 0:n={},a={},o=!(!t||!t.tupleStream),Array.isArray(t)||(t=P(t)),0===t.length&&t.push(void 0),s=0;case 6:if(!(s<t.length)){g.next=31;break}u=t[s],c=o?z(r,u):r,p=0;case 10:if(!(p<e.lhs.length)){g.next=28;break}return f=e.lhs[p],g.delegateYield(L(f[0],o?u["@"]:u,c),"t0",13);case 13:if("string"==typeof(l=g.t0)||void 0===l){g.next=16;break}throw{code:"T1003",stack:(new Error).stack,position:e.position,value:l};case 16:if(void 0===l){g.next=25;break}if(d={data:u,exprIndex:p},!a.hasOwnProperty(l)){g.next=24;break}if(a[l].exprIndex===p){g.next=21;break}throw{code:"D1009",stack:(new Error).stack,position:e.position,value:l};case 21:a[l].data=i.append(a[l].data,u),g.next=25;break;case 24:a[l]=d;case 25:p++,g.next=10;break;case 28:s++,g.next=6;break;case 31:g.t1=regeneratorRuntime.keys(a);case 32:if((g.t2=g.t1()).done){g.next=43;break}return l=g.t2.value,d=a[l],h=d.data,c=r,o&&(v=oe(d.data),h=v["@"],delete v["@"],c=z(r,v)),g.delegateYield(L(e.lhs[d.exprIndex][1],h,c),"t3",39);case 39:void 0!==(b=g.t3)&&(n[l]=b),g.next=32;break;case 43:return g.abrupt("return",n);case 44:case"end":return g.stop()}},g)}function oe(e){if(!Array.isArray(e))return e;var t={};Object.assign(t,e[0]);for(var r=1;r<e.length;r++)for(var n in e[r])t[n]=i.append(t[n],e[r][n]);return t}function se(e,t){var r;if(void 0!==e&&!Number.isInteger(e))throw{code:"T2003",stack:(new Error).stack,value:e};if(void 0!==t&&!Number.isInteger(t))throw{code:"T2004",stack:(new Error).stack,value:t};if(void 0===e||void 0===t)return r;if(e>t)return r;var n=t-e+1;if(n>1e7)throw{code:"D2014",stack:(new Error).stack,value:n};r=new Array(n);for(var a=e,i=0;a<=t;a++,i++)r[i]=a;return r.sequence=!0,r}function ue(e,t,r){var n;return regeneratorRuntime.wrap(function(a){for(;;)switch(a.prev=a.next){case 0:return a.delegateYield(L(e.rhs,t,r),"t0",1);case 1:return n=a.t0,r.bind(e.lhs.value,n),a.abrupt("return",n);case 4:case"end":return a.stop()}},v)}function ce(e,t,r){var n,a;return regeneratorRuntime.wrap(function(o){for(;;)switch(o.prev=o.next){case 0:return o.delegateYield(L(e.condition,t,r),"t0",1);case 1:if(a=o.t0,!i.boolean(a)){o.next=7;break}return o.delegateYield(L(e.then,t,r),"t1",4);case 4:n=o.t1,o.next=10;break;case 7:if(void 0===e.else){o.next=10;break}return o.delegateYield(L(e.else,t,r),"t2",9);case 9:n=o.t2;case 10:return o.abrupt("return",n);case 11:case"end":return o.stop()}},b)}function pe(e,t,r){var n,a,i;return regeneratorRuntime.wrap(function(o){for(;;)switch(o.prev=o.next){case 0:a=Ye(r),i=0;case 2:if(!(i<e.expressions.length)){o.next=8;break}return o.delegateYield(L(e.expressions[i],t,a),"t0",4);case 4:n=o.t0;case 5:i++,o.next=2;break;case 8:return o.abrupt("return",n);case 9:case"end":return o.stop()}},m)}function fe(e){var t=new je.RegexEngine(e.value);return function r(n,a){var i;t.lastIndex=a||0;var o=t.exec(n);if(null!==o){if(i={match:o[0],start:o.index,end:o.index+o[0].length,groups:[]},o.length>1)for(var s=1;s<o.length;s++)i.groups.push(o[s]);i.next=function(){if(!(t.lastIndex>=n.length)){var a=r(n,t.lastIndex);if(a&&""===a.match)throw{code:"D1004",stack:(new Error).stack,position:e.position,value:e.value.source};return a}}}return i}}function le(e,t,r){return""===e.value?t&&t.outerWrapper?t[0]:t:r.lookup(e.value)}function de(e,t,r){var a,o,s,u,c;return regeneratorRuntime.wrap(function(p){for(;;)switch(p.prev=p.next){case 0:return o=t,s=!!t.tupleStream,u=regeneratorRuntime.mark(function t(a,i){var o,u,c,p,f,l,d,h,g;return regeneratorRuntime.wrap(function(t){for(;;)switch(t.prev=t.next){case 0:o=0,u=0;case 2:if(!(0===o&&u<e.terms.length)){t.next=35;break}return c=e.terms[u],p=a,f=r,s&&(p=a["@"],f=z(r,a)),t.delegateYield(L(c.expression,p,f),"t0",8);case 8:return l=t.t0,p=i,f=r,s&&(p=i["@"],f=z(r,i)),t.delegateYield(L(c.expression,p,f),"t1",13);case 13:if(d=t.t1,h=n(l),g=n(d),"undefined"!==h){t.next=19;break}return o="undefined"===g?0:1,t.abrupt("continue",32);case 19:if("undefined"!==g){t.next=22;break}return o=-1,t.abrupt("continue",32);case 22:if(!("string"!==h&&"number"!==h||"string"!==g&&"number"!==g)){t.next=24;break}throw{code:"T2008",stack:(new Error).stack,position:e.position,value:"string"!==h&&"number"!==h?l:d};case 24:if(h===g){t.next=26;break}throw{code:"T2007",stack:(new Error).stack,position:e.position,value:l,value2:d};case 26:if(l!==d){t.next=30;break}return t.abrupt("continue",32);case 30:o=l<d?-1:1;case 31:!0===c.descending&&(o=-o);case 32:u++,t.next=2;break;case 35:return t.abrupt("return",1===o);case 36:case"end":return t.stop()}},t)}),c={environment:r,input:t},p.delegateYield(i.sort.apply(c,[o,u]),"t0",5);case 5:return a=p.t0,p.abrupt("return",a);case 7:case"end":return p.stop()}},y)}function he(e,t,r){return Oe(regeneratorRuntime.mark(function t(a){var i,o,s,u,c,p,f,l,d,h,g;return regeneratorRuntime.wrap(function(t){for(;;)switch(t.prev=t.next){case 0:if(void 0!==a){t.next=2;break}return t.abrupt("return",void 0);case 2:if(i=r.lookup("clone"),j(i)){t.next=5;break}throw{code:"T2013",stack:(new Error).stack,position:e.position};case 5:return t.delegateYield(me(i,[a],null,r),"t0",6);case 6:return o=t.t0,t.delegateYield(L(e.pattern,o,r),"t1",8);case 8:if(void 0===(s=t.t1)){t.next=33;break}Array.isArray(s)||(s=[s]),u=0;case 12:if(!(u<s.length)){t.next=33;break}return c=s[u],t.delegateYield(L(e.update,c,r),"t2",15);case 15:if(p=t.t2,"undefined"===(f=n(p))){t.next=21;break}if("object"===f&&null!==p&&!Array.isArray(p)){t.next=20;break}throw{code:"T2011",stack:(new Error).stack,position:e.update.position,value:p};case 20:for(l in p)c[l]=p[l];case 21:if(void 0===e.delete){t.next=30;break}return t.delegateYield(L(e.delete,c,r),"t3",23);case 23:if(void 0===(d=t.t3)){t.next=30;break}if(h=d,Array.isArray(d)||(d=[d]),R(d)){t.next=29;break}throw{code:"T2012",stack:(new Error).stack,position:e.delete.position,value:h};case 29:for(g=0;g<d.length;g++)"object"===n(c)&&null!==c&&delete c[d[g]];case 30:u++,t.next=12;break;case 33:return t.abrupt("return",o);case 34:case"end":return t.stop()}},t)}),"<(oa):o>")}var ge=s("function($f, $g) { function($x){ $g($f($x)) } }");function ve(e,t,r){var n,a,i,o;return regeneratorRuntime.wrap(function(s){for(;;)switch(s.prev=s.next){case 0:return s.delegateYield(L(e.lhs,t,r),"t0",1);case 1:if(a=s.t0,"function"!==e.rhs.type){s.next=7;break}return s.delegateYield(be(e.rhs,t,r,{context:a}),"t1",4);case 4:n=s.t1,s.next=20;break;case 7:return s.delegateYield(L(e.rhs,t,r),"t2",8);case 8:if(i=s.t2,j(i)){s.next=11;break}throw{code:"T2006",stack:(new Error).stack,position:e.position,value:i};case 11:if(!j(a)){s.next=18;break}return s.delegateYield(L(ge,null,r),"t3",13);case 13:return o=s.t3,s.delegateYield(me(o,[a,i],null,r),"t4",15);case 15:n=s.t4,s.next=20;break;case 18:return s.delegateYield(me(i,[a],null,r),"t5",19);case 19:n=s.t5;case 20:return s.abrupt("return",n);case 21:case"end":return s.stop()}},k)}function be(e,t,r,a){var i,o,s,u,c,p;return regeneratorRuntime.wrap(function(f){for(;;)switch(f.prev=f.next){case 0:return f.delegateYield(L(e.procedure,t,r),"t0",1);case 1:if(void 0!==(o=f.t0)||"path"!==e.procedure.type||!r.lookup(e.procedure.steps[0].value)){f.next=4;break}throw{code:"T1005",stack:(new Error).stack,position:e.position,token:e.procedure.steps[0].value};case 4:s=[],void 0!==a&&s.push(a.context),u=regeneratorRuntime.mark(function n(){var a,i;return regeneratorRuntime.wrap(function(n){for(;;)switch(n.prev=n.next){case 0:return n.delegateYield(L(e.arguments[c],t,r),"t0",1);case 1:a=n.t0,j(a)?((i=regeneratorRuntime.mark(function e(){var t,n,i,o=arguments;return regeneratorRuntime.wrap(function(e){for(;;)switch(e.prev=e.next){case 0:for(t=o.length,n=new Array(t),i=0;i<t;i++)n[i]=o[i];return e.delegateYield(me(a,n,null,r),"t0",2);case 2:return e.abrupt("return",e.t0);case 3:case"end":return e.stop()}},e)})).arity=U(a),s.push(i)):s.push(a);case 3:case"end":return n.stop()}},n)}),c=0;case 8:if(!(c<e.arguments.length)){f.next=13;break}return f.delegateYield(u(),"t1",10);case 10:c++,f.next=8;break;case 13:return p="path"===e.procedure.type?e.procedure.steps[0].value:e.procedure.value,f.prev=14,"object"===n(o)&&(o.token=p,o.position=e.position),f.delegateYield(me(o,s,t,r),"t2",17);case 17:i=f.t2,f.next=25;break;case 20:throw f.prev=20,f.t3=f.catch(14),f.t3.position||(f.t3.position=e.position),f.t3.token||(f.t3.token=p),f.t3;case 25:return f.abrupt("return",i);case 26:case"end":return f.stop()}},x,null,[[14,20]])}function me(e,t,r,n){var a,i,o,s;return regeneratorRuntime.wrap(function(u){for(;;)switch(u.prev=u.next){case 0:return u.delegateYield(ye(e,t,r,n),"t0",1);case 1:a=u.t0;case 2:if(!C(a)||!0!==a.thunk){u.next=21;break}return u.delegateYield(L(a.body.procedure,a.input,a.environment),"t1",4);case 4:i=u.t1,"variable"===a.body.procedure.type&&(i.token=a.body.procedure.value),i.position=a.body.procedure.position,o=[],s=0;case 9:if(!(s<a.body.arguments.length)){u.next=17;break}return u.t2=o,u.delegateYield(L(a.body.arguments[s],a.input,a.environment),"t3",12);case 12:u.t4=u.t3,u.t2.push.call(u.t2,u.t4);case 14:s++,u.next=9;break;case 17:return u.delegateYield(ye(i,o,r,n),"t5",18);case 18:a=u.t5,u.next=2;break;case 21:return u.abrupt("return",a);case 22:case"end":return u.stop()}},w)}function ye(e,t,r,n){var a,i,o;return regeneratorRuntime.wrap(function(s){for(;;)switch(s.prev=s.next){case 0:if(s.prev=0,i=t,e&&(i=we(e.signature,t,r)),!C(e)){s.next=8;break}return s.delegateYield(Ee(e,i),"t0",5);case 5:a=s.t0,s.next=24;break;case 8:if(!e||!0!==e._jsonata_function){s.next=16;break}if(o={environment:n,input:r},a=e.implementation.apply(o,i),!F(a)){s.next=14;break}return s.delegateYield(a,"t1",13);case 13:a=s.t1;case 14:s.next=24;break;case 16:if("function"!=typeof e){s.next=23;break}if(a=e.apply(r,i),!F(a)){s.next=21;break}return s.delegateYield(a,"t2",20);case 20:a=s.t2;case 21:s.next=24;break;case 23:throw{code:"T1006",stack:(new Error).stack};case 24:s.next=30;break;case 26:throw s.prev=26,s.t3=s.catch(0),e&&(void 0===s.t3.token&&void 0!==e.token&&(s.t3.token=e.token),s.t3.position=e.position),s.t3;case 30:return s.abrupt("return",a);case 31:case"end":return s.stop()}},E,null,[[0,26]])}function ke(e,t,r){var n={_jsonata_lambda:!0,input:t,environment:r,arguments:e.arguments,signature:e.signature,body:e.body};return!0===e.thunk&&(n.thunk=!0),n.apply=regeneratorRuntime.mark(function e(r,a){return regeneratorRuntime.wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return e.delegateYield(me(n,a,t,r.environment),"t0",1);case 1:return e.abrupt("return",e.t0);case 2:case"end":return e.stop()}},e)}),n}function xe(e,t,r){var n,a,i,o,s;return regeneratorRuntime.wrap(function(u){for(;;)switch(u.prev=u.next){case 0:a=[],i=0;case 2:if(!(i<e.arguments.length)){u.next=15;break}if("operator"!==(o=e.arguments[i]).type||"?"!==o.value){u.next=8;break}a.push(o),u.next=12;break;case 8:return u.t0=a,u.delegateYield(L(o,t,r),"t1",10);case 10:u.t2=u.t1,u.t0.push.call(u.t0,u.t2);case 12:i++,u.next=2;break;case 15:return u.delegateYield(L(e.procedure,t,r),"t3",16);case 16:if(void 0!==(s=u.t3)||"path"!==e.procedure.type||!r.lookup(e.procedure.steps[0].value)){u.next=19;break}throw{code:"T1007",stack:(new Error).stack,position:e.position,token:e.procedure.steps[0].value};case 19:if(!C(s)){u.next=23;break}n=Ae(s,a),u.next=32;break;case 23:if(!s||!0!==s._jsonata_function){u.next=27;break}n=Se(s.implementation,a),u.next=32;break;case 27:if("function"!=typeof s){u.next=31;break}n=Se(s,a),u.next=32;break;case 31:throw{code:"T1008",stack:(new Error).stack,position:e.position,token:"path"===e.procedure.type?e.procedure.steps[0].value:e.procedure.value};case 32:return u.abrupt("return",n);case 33:case"end":return u.stop()}},A)}function we(e,t,r){return void 0===e?t:e.validate(t,r)}function Ee(e,t){var r,n;return regeneratorRuntime.wrap(function(a){for(;;)switch(a.prev=a.next){case 0:if(n=Ye(e.environment),e.arguments.forEach(function(e,r){n.bind(e.value,t[r])}),"function"!=typeof e.body){a.next=7;break}return a.delegateYield(Te(e.body,n),"t0",4);case 4:r=a.t0,a.next=9;break;case 7:return a.delegateYield(L(e.body,e.input,n),"t1",8);case 8:r=a.t1;case 9:return a.abrupt("return",r);case 10:case"end":return a.stop()}},S)}function Ae(e,t){var r=Ye(e.environment),n=[];return e.arguments.forEach(function(e,a){var i=t[a];i&&"operator"===i.type&&"?"===i.value?n.push(e):r.bind(e.value,i)}),{_jsonata_lambda:!0,input:e.input,environment:r,arguments:n,body:e.body}}function Se(e,t){var r=De(e),n="function("+(r=r.map(function(e){return"$"+e.trim()})).join(", ")+"){ _ }",a=s(n);return a.body=e,Ae(a,t)}function Te(e,t){var r,n,a,i;return regeneratorRuntime.wrap(function(o){for(;;)switch(o.prev=o.next){case 0:if(r=De(e),n=r.map(function(e){return t.lookup(e.trim())}),a={environment:t},i=e.apply(a,n),!F(i)){o.next=7;break}return o.delegateYield(i,"t0",6);case 6:i=o.t0;case 7:return o.abrupt("return",i);case 8:case"end":return o.stop()}},T)}function De(e){var t=e.toString();return/\(([^)]*)\)/.exec(t)[1].split(",")}function Oe(e,t){var r={_jsonata_function:!0,implementation:e};return void 0!==t&&(r.signature=u(t)),r}function Re(e,t){var r,n,a;return regeneratorRuntime.wrap(function(i){for(;;)switch(i.prev=i.next){case 0:if(void 0!==e){i.next=2;break}return i.abrupt("return",void 0);case 2:r=this.input,void 0!==t&&(r=t,Array.isArray(r)&&!M(r)&&((r=P(r)).outerWrapper=!0)),i.prev=4,n=s(e,!1),i.next=12;break;case 8:throw i.prev=8,i.t0=i.catch(4),Me(i.t0),{stack:(new Error).stack,code:"D3120",value:i.t0.message,error:i.t0};case 12:return i.prev=12,i.delegateYield(L(n,r,this.environment),"t1",14);case 14:a=i.t1,i.next=21;break;case 17:throw i.prev=17,i.t2=i.catch(12),Me(i.t2),{stack:(new Error).stack,code:"D3121",value:i.t2.message,error:i.t2};case 21:return i.abrupt("return",a);case 22:case"end":return i.stop()}},D,this,[[4,8],[12,17]])}function Ye(e){var t={};return{bind:function(e,r){t[e]=r},lookup:function(r){var n;return t.hasOwnProperty(r)?n=t[r]:e&&(n=e.lookup(r)),n},timestamp:e?e.timestamp:null,async:!!e&&e.async,global:e?e.global:{ancestry:[null]}}}I.bind("sum",Oe(i.sum,"<a<n>:n>")),I.bind("count",Oe(i.count,"<a:n>")),I.bind("max",Oe(i.max,"<a<n>:n>")),I.bind("min",Oe(i.min,"<a<n>:n>")),I.bind("average",Oe(i.average,"<a<n>:n>")),I.bind("string",Oe(i.string,"<x-b?:s>")),I.bind("substring",Oe(i.substring,"<s-nn?:s>")),I.bind("substringBefore",Oe(i.substringBefore,"<s-s:s>")),I.bind("substringAfter",Oe(i.substringAfter,"<s-s:s>")),I.bind("lowercase",Oe(i.lowercase,"<s-:s>")),I.bind("uppercase",Oe(i.uppercase,"<s-:s>")),I.bind("length",Oe(i.length,"<s-:n>")),I.bind("trim",Oe(i.trim,"<s-:s>")),I.bind("pad",Oe(i.pad,"<s-ns?:s>")),I.bind("match",Oe(i.match,"<s-f<s:o>n?:a<o>>")),I.bind("contains",Oe(i.contains,"<s-(sf):b>")),I.bind("replace",Oe(i.replace,"<s-(sf)(sf)n?:s>")),I.bind("split",Oe(i.split,"<s-(sf)n?:a<s>>")),I.bind("join",Oe(i.join,"<a<s>s?:s>")),I.bind("formatNumber",Oe(i.formatNumber,"<n-so?:s>")),I.bind("formatBase",Oe(i.formatBase,"<n-n?:s>")),I.bind("formatInteger",Oe(a.formatInteger,"<n-s:s>")),I.bind("parseInteger",Oe(a.parseInteger,"<s-s:n>")),I.bind("number",Oe(i.number,"<(nsb)-:n>")),I.bind("floor",Oe(i.floor,"<n-:n>")),I.bind("ceil",Oe(i.ceil,"<n-:n>")),I.bind("round",Oe(i.round,"<n-n?:n>")),I.bind("abs",Oe(i.abs,"<n-:n>")),I.bind("sqrt",Oe(i.sqrt,"<n-:n>")),I.bind("power",Oe(i.power,"<n-n:n>")),I.bind("random",Oe(i.random,"<:n>")),I.bind("boolean",Oe(i.boolean,"<x-:b>")),I.bind("not",Oe(i.not,"<x-:b>")),I.bind("map",Oe(i.map,"<af>")),I.bind("zip",Oe(i.zip,"<a+>")),I.bind("filter",Oe(i.filter,"<af>")),I.bind("single",Oe(i.single,"<af?>")),I.bind("reduce",Oe(i.foldLeft,"<afj?:j>")),I.bind("sift",Oe(i.sift,"<o-f?:o>")),I.bind("keys",Oe(i.keys,"<x-:a<s>>")),I.bind("lookup",Oe(i.lookup,"<x-s:x>")),I.bind("append",Oe(i.append,"<xx:a>")),I.bind("exists",Oe(i.exists,"<x:b>")),I.bind("spread",Oe(i.spread,"<x-:a<o>>")),I.bind("merge",Oe(i.merge,"<a<o>:o>")),I.bind("reverse",Oe(i.reverse,"<a:a>")),I.bind("each",Oe(i.each,"<o-f:a>")),I.bind("error",Oe(i.error,"<s?:x>")),I.bind("assert",Oe(i.assert,"<bs?:x>")),I.bind("type",Oe(i.type,"<x:s>")),I.bind("sort",Oe(i.sort,"<af?:a>")),I.bind("shuffle",Oe(i.shuffle,"<a:a>")),I.bind("distinct",Oe(i.distinct,"<x:x>")),I.bind("base64encode",Oe(i.base64encode,"<s-:s>")),I.bind("base64decode",Oe(i.base64decode,"<s-:s>")),I.bind("encodeUrlComponent",Oe(i.encodeUrlComponent,"<s-:s>")),I.bind("encodeUrl",Oe(i.encodeUrl,"<s-:s>")),I.bind("decodeUrlComponent",Oe(i.decodeUrlComponent,"<s-:s>")),I.bind("decodeUrl",Oe(i.decodeUrl,"<s-:s>")),I.bind("eval",Oe(Re,"<sx?:x>")),I.bind("toMillis",Oe(a.toMillis,"<s-s?:n>")),I.bind("fromMillis",Oe(a.fromMillis,"<n-s?s?:s>")),I.bind("clone",Oe(function(e){if(void 0!==e)return JSON.parse(i.string(e))},"<(oa)-:o>"));var Pe={S0101:"String literal must be terminated by a matching quote",S0102:"Number out of range: {{token}}",S0103:"Unsupported escape sequence: \\{{token}}",S0104:"The escape sequence \\u must be followed by 4 hex digits",S0105:"Quoted property name must be terminated with a backquote (`)",S0106:"Comment has no closing tag",S0201:"Syntax error: {{token}}",S0202:"Expected {{value}}, got {{token}}",S0203:"Expected {{value}} before end of expression",S0204:"Unknown operator: {{token}}",S0205:"Unexpected token: {{token}}",S0206:"Unknown expression type: {{token}}",S0207:"Unexpected end of expression",S0208:"Parameter {{value}} of function definition must be a variable name (start with $)",S0209:"A predicate cannot follow a grouping expression in a step",S0210:"Each step can only have one grouping expression",S0211:"The symbol {{token}} cannot be used as a unary operator",S0212:"The left side of := must be a variable name (start with $)",S0213:"The literal value {{value}} cannot be used as a step within a path expression",S0214:"The right side of {{token}} must be a variable name (start with $)",S0215:"A context variable binding must precede any predicates on a step",S0216:"A context variable binding must precede the 'order-by' clause on a step",S0217:"The object representing the 'parent' cannot be derived from this expression",S0301:"Empty regular expressions are not allowed",S0302:"No terminating / in regular expression",S0402:"Choice groups containing parameterized types are not supported",S0401:"Type parameters can only be applied to functions and arrays",S0500:"Attempted to evaluate an expression containing syntax error(s)",T0410:"Argument {{index}} of function {{token}} does not match function signature",T0411:"Context value is not a compatible type with argument {{index}} of function {{token}}",T0412:"Argument {{index}} of function {{token}} must be an array of {{type}}",D1001:"Number out of range: {{value}}",D1002:"Cannot negate a non-numeric value: {{value}}",T1003:"Key in object structure must evaluate to a string; got: {{value}}",D1004:"Regular expression matches zero length string",T1005:"Attempted to invoke a non-function. Did you mean ${{{token}}}?",T1006:"Attempted to invoke a non-function",T1007:"Attempted to partially apply a non-function. Did you mean ${{{token}}}?",T1008:"Attempted to partially apply a non-function",D1009:"Multiple key definitions evaluate to same key: {{value}}",T1010:"The matcher function argument passed to function {{token}} does not return the correct object structure",T2001:"The left side of the {{token}} operator must evaluate to a number",T2002:"The right side of the {{token}} operator must evaluate to a number",T2003:"The left side of the range operator (..) must evaluate to an integer",T2004:"The right side of the range operator (..) must evaluate to an integer",D2005:"The left side of := must be a variable name (start with $)",T2006:"The right side of the function application operator ~> must be a function",T2007:"Type mismatch when comparing values {{value}} and {{value2}} in order-by clause",T2008:"The expressions within an order-by clause must evaluate to numeric or string values",T2009:"The values {{value}} and {{value2}} either side of operator {{token}} must be of the same data type",T2010:"The expressions either side of operator {{token}} must evaluate to numeric or string values",T2011:"The insert/update clause of the transform expression must evaluate to an object: {{value}}",T2012:"The delete clause of the transform expression must evaluate to a string or array of strings: {{value}}",T2013:"The transform expression clones the input object using the $clone() function. This has been overridden in the current scope by a non-function.",D2014:"The size of the sequence allocated by the range operator (..) must not exceed 1e6. Attempted to allocate {{value}}.",D3001:"Attempting to invoke string function on Infinity or NaN",D3010:"Second argument of replace function cannot be an empty string",D3011:"Fourth argument of replace function must evaluate to a positive number",D3012:"Attempted to replace a matched string with a non-string value",D3020:"Third argument of split function must evaluate to a positive number",D3030:"Unable to cast value to a number: {{value}}",D3040:"Third argument of match function must evaluate to a positive number",D3050:"The second argument of reduce function must be a function with at least two arguments",D3060:"The sqrt function cannot be applied to a negative number: {{value}}",D3061:"The power function has resulted in a value that cannot be represented as a JSON number: base={{value}}, exponent={{exp}}",D3070:"The single argument form of the sort function can only be applied to an array of strings or an array of numbers. Use the second argument to specify a comparison function",D3080:"The picture string must only contain a maximum of two sub-pictures",D3081:"The sub-picture must not contain more than one instance of the 'decimal-separator' character",D3082:"The sub-picture must not contain more than one instance of the 'percent' character",D3083:"The sub-picture must not contain more than one instance of the 'per-mille' character",D3084:"The sub-picture must not contain both a 'percent' and a 'per-mille' character",D3085:"The mantissa part of a sub-picture must contain at least one character that is either an 'optional digit character' or a member of the 'decimal digit family'",D3086:"The sub-picture must not contain a passive character that is preceded by an active character and that is followed by another active character",D3087:"The sub-picture must not contain a 'grouping-separator' character that appears adjacent to a 'decimal-separator' character",D3088:"The sub-picture must not contain a 'grouping-separator' at the end of the integer part",D3089:"The sub-picture must not contain two adjacent instances of the 'grouping-separator' character",D3090:"The integer part of the sub-picture must not contain a member of the 'decimal digit family' that is followed by an instance of the 'optional digit character'",D3091:"The fractional part of the sub-picture must not contain an instance of the 'optional digit character' that is followed by a member of the 'decimal digit family'",D3092:"A sub-picture that contains a 'percent' or 'per-mille' character must not contain a character treated as an 'exponent-separator'",D3093:"The exponent part of the sub-picture must comprise only of one or more characters that are members of the 'decimal digit family'",D3100:"The radix of the formatBase function must be between 2 and 36. It was given {{value}}",D3110:"The argument of the toMillis function must be an ISO 8601 formatted timestamp. Given {{value}}",D3120:"Syntax error in expression passed to function eval: {{value}}",D3121:"Dynamic error evaluating the expression passed to function eval: {{value}}",D3130:"Formatting or parsing an integer as a sequence starting with {{value}} is not supported by this implementation",D3131:"In a decimal digit pattern, all digits must be from the same decimal group",D3132:"Unknown component specifier {{value}} in date/time picture string",D3133:"The 'name' modifier can only be applied to months and days in the date/time picture string, not {{value}}",D3134:"The timezone integer format specifier cannot have more than four digits",D3135:"No matching closing bracket ']' in date/time picture string",D3136:"The date/time picture string is missing specifiers required to parse the timestamp",D3137:"{{{message}}}",D3138:"The $single() function expected exactly 1 matching result. Instead it matched more.",D3139:"The $single() function expected exactly 1 matching result. Instead it matched 0.",D3140:"Malformed URL passed to ${{{functionName}}}(): {{value}}",D3141:"{{{message}}}"};function Me(e){var t=Pe[e.code];if(void 0!==t){var r=t.replace(/\{\{\{([^}]+)}}}/g,function(){return e[arguments[1]]});r=r.replace(/\{\{([^}]+)}}/g,function(){return JSON.stringify(e[arguments[1]])}),e.message=r}}function je(e,t){var r,n;try{r=s(e,t&&t.recover),n=r.errors,delete r.errors}catch(e){throw Me(e),e}var i=Ye(I),o=new Date;return i.bind("now",Oe(function(e,t){return a.fromMillis(o.getTime(),e,t)},"<s?s?:s>")),i.bind("millis",Oe(function(){return o.getTime()},"<:n>")),t&&t.RegexEngine?je.RegexEngine=t.RegexEngine:je.RegexEngine=RegExp,{evaluate:function(e,t,a){if(void 0!==n){var s={code:"S0500",position:0};throw Me(s),s}var u,c,p;if(void 0!==t)for(var f in u=Ye(i),t)u.bind(f,t[f]);else u=i;if(u.bind("$",e),o=new Date,u.timestamp=o,Array.isArray(e)&&!M(e)&&((e=P(e)).outerWrapper=!0),"function"==typeof a){u.async=!0;var l=function(e){Me(e),a(e,null)};p=L(r,e,u),(c=p.next()).value.then(function e(t){(c=p.next(t)).done?a(null,c.value):c.value.then(e).catch(l)}).catch(l)}else try{for(p=L(r,e,u),c=p.next();!c.done;)c=p.next(c.value);return c.value}catch(s){throw Me(s),s}},assign:function(e,t){i.bind(e,t)},registerFunction:function(e,t,r){var n=Oe(t,r);i.bind(e,n)},ast:function(){return r},errors:function(){return n}}}return je.parser=s,je}();t.exports=c},{"./datetime":1,"./functions":2,"./parser":4,"./signature":5,"./utils":6}],4:[function(e,t,r){"use strict";var n,a,i,o=e("./signature"),s=(n={".":75,"[":80,"]":0,"{":70,"}":0,"(":80,")":0,",":0,"@":80,"#":80,";":80,":":80,"?":20,"+":50,"-":50,"*":60,"/":60,"%":60,"|":20,"=":40,"<":40,">":40,"^":40,"**":60,"..":20,":=":10,"!=":40,"<=":40,">=":40,"~>":40,and:30,or:25,in:40,"&":50,"!":0,"~":0},a={'"':'"',"\\":"\\","/":"/",b:"\b",f:"\f",n:"\n",r:"\r",t:"\t"},i=function(e){var t=0,r=e.length,i=function(e,r){return{type:e,value:r,position:t}};return function o(s){if(t>=r)return null;for(var u=e.charAt(t);t<r&&" \t\n\r\v".indexOf(u)>-1;)t++,u=e.charAt(t);if("/"===u&&"*"===e.charAt(t+1)){var c=t;for(t+=2,u=e.charAt(t);"*"!==u||"/"!==e.charAt(t+1);)if(u=e.charAt(++t),t>=r)throw{code:"S0106",stack:(new Error).stack,position:c};return t+=2,u=e.charAt(t),o(s)}if(!0!==s&&"/"===u)return t++,i("regex",function(){for(var n,a,i=t,o=0;t<r;){var s=e.charAt(t);if("/"===s&&"\\"!==e.charAt(t-1)&&0===o){if(""===(n=e.substring(i,t)))throw{code:"S0301",stack:(new Error).stack,position:t};for(t++,s=e.charAt(t),i=t;"i"===s||"m"===s;)t++,s=e.charAt(t);return a=e.substring(i,t)+"g",new RegExp(n,a)}"("!==s&&"["!==s&&"{"!==s||"\\"===e.charAt(t-1)||o++,")"!==s&&"]"!==s&&"}"!==s||"\\"===e.charAt(t-1)||o--,t++}throw{code:"S0302",stack:(new Error).stack,position:t}}());if("."===u&&"."===e.charAt(t+1))return t+=2,i("operator","..");if(":"===u&&"="===e.charAt(t+1))return t+=2,i("operator",":=");if("!"===u&&"="===e.charAt(t+1))return t+=2,i("operator","!=");if(">"===u&&"="===e.charAt(t+1))return t+=2,i("operator",">=");if("<"===u&&"="===e.charAt(t+1))return t+=2,i("operator","<=");if("*"===u&&"*"===e.charAt(t+1))return t+=2,i("operator","**");if("~"===u&&">"===e.charAt(t+1))return t+=2,i("operator","~>");if(Object.prototype.hasOwnProperty.call(n,u))return t++,i("operator",u);if('"'===u||"'"===u){var p=u;t++;for(var f="";t<r;){if("\\"===(u=e.charAt(t)))if(t++,u=e.charAt(t),Object.prototype.hasOwnProperty.call(a,u))f+=a[u];else{if("u"!==u)throw{code:"S0103",stack:(new Error).stack,position:t,token:u};var l=e.substr(t+1,4);if(!/^[0-9a-fA-F]+$/.test(l))throw{code:"S0104",stack:(new Error).stack,position:t};var d=parseInt(l,16);f+=String.fromCharCode(d),t+=4}else{if(u===p)return t++,i("string",f);f+=u}t++}throw{code:"S0101",stack:(new Error).stack,position:t}}var h,g=/^-?(0|([1-9][0-9]*))(\.[0-9]+)?([Ee][-+]?[0-9]+)?/.exec(e.substring(t));if(null!==g){var v=parseFloat(g[0]);if(!isNaN(v)&&isFinite(v))return t+=g[0].length,i("number",v);throw{code:"S0102",stack:(new Error).stack,position:t,token:g[0]}}if("`"===u){t++;var b=e.indexOf("`",t);if(-1!==b)return h=e.substring(t,b),t=b+1,i("name",h);throw t=r,{code:"S0105",stack:(new Error).stack,position:t}}for(var m,y=t;;)if(m=e.charAt(y),y===r||" \t\n\r\v".indexOf(m)>-1||Object.prototype.hasOwnProperty.call(n,m)){if("$"===e.charAt(t))return h=e.substring(t+1,y),t=y,i("variable",h);switch(h=e.substring(t,y),t=y,h){case"or":case"in":case"and":return i("operator",h);case"true":return i("value",!0);case"false":return i("value",!1);case"null":return i("value",null);default:return t===r&&""===h?null:i("name",h)}}else y++}},function(e,t){var r,a,s={},u=[],c=function(){var e=[];"(end)"!==r.id&&e.push({type:r.type,value:r.value,position:r.position});for(var t=a();null!==t;)e.push(t),t=a();return e},p={nud:function(){var e={code:"S0211",token:this.value,position:this.position};if(t)return e.remaining=c(),e.type="error",u.push(e),e;throw e.stack=(new Error).stack,e}},f=function(e,t){var r=s[e];return t=t||0,r?t>=r.lbp&&(r.lbp=t):((r=Object.create(p)).id=r.value=e,r.lbp=t,s[e]=r),r},l=function(e){if(t){e.remaining=c(),u.push(e);var n=s["(error)"];return(r=Object.create(n)).error=e,r.type="(error)",r}throw e.stack=(new Error).stack,e},d=function(t,n){if(t&&r.id!==t){var i={code:"(end)"===r.id?"S0203":"S0202",position:r.position,token:r.value,value:t};return l(i)}var o=a(n);if(null===o)return(r=s["(end)"]).position=e.length,r;var u,c=o.value,p=o.type;switch(p){case"name":case"variable":u=s["(name)"];break;case"operator":if(!(u=s[c]))return l({code:"S0204",stack:(new Error).stack,position:o.position,token:c});break;case"string":case"number":case"value":u=s["(literal)"];break;case"regex":p="regex",u=s["(regex)"];break;default:return l({code:"S0205",stack:(new Error).stack,position:o.position,token:c})}return(r=Object.create(u)).value=c,r.type=p,r.position=o.position,r},h=function(e){var t,n=r;for(d(null,!0),t=n.nud();e<r.lbp;)n=r,d(),t=n.led(t);return t},g=function(e){f(e,0).nud=function(){return this}},v=function(e,t,r){var a=t||n[e],i=f(e,a);return i.led=r||function(e){return this.lhs=e,this.rhs=h(a),this.type="binary",this},i},b=function(e,t,r){var n=f(e,t);return n.led=r,n},m=function(e,t){var r=f(e);return r.nud=t||function(){return this.expression=h(70),this.type="unary",this},r};g("(end)"),g("(name)"),g("(literal)"),g("(regex)"),f(":"),f(";"),f(","),f(")"),f("]"),f("}"),f(".."),v("."),v("+"),v("-"),v("*"),v("/"),v("%"),v("="),v("<"),v(">"),v("!="),v("<="),v(">="),v("&"),v("and"),v("or"),v("in"),g("and"),g("or"),g("in"),m("-"),v("~>"),b("(error)",10,function(e){return this.lhs=e,this.error=r.error,this.remaining=c(),this.type="error",this}),m("*",function(){return this.type="wildcard",this}),m("**",function(){return this.type="descendant",this}),m("%",function(){return this.type="parent",this}),v("(",n["("],function(e){if(this.procedure=e,this.type="function",this.arguments=[],")"!==r.id)for(;"operator"===r.type&&"?"===r.id?(this.type="partial",this.arguments.push(r),d("?")):this.arguments.push(h(0)),","===r.id;)d(",");if(d(")",!0),"name"===e.type&&("function"===e.value||"λ"===e.value)){if(this.arguments.forEach(function(e,t){if("variable"!==e.type)return l({code:"S0208",stack:(new Error).stack,position:e.position,token:e.value,value:t+1})}),this.type="lambda","<"===r.id){for(var t=r.position,n=1,a="<";n>0&&"{"!==r.id&&"(end)"!==r.id;){var i=d();">"===i.id?n--:"<"===i.id&&n++,a+=i.value}d(">");try{this.signature=o(a)}catch(e){return e.position=t+e.offset,l(e)}}d("{"),this.body=h(0),d("}")}return this}),m("(",function(){for(var e=[];")"!==r.id&&(e.push(h(0)),";"===r.id);)d(";");return d(")",!0),this.type="block",this.expressions=e,this}),m("[",function(){var e=[];if("]"!==r.id)for(;;){var t=h(0);if(".."===r.id){var n={type:"binary",value:"..",position:r.position,lhs:t};d(".."),n.rhs=h(0),t=n}if(e.push(t),","!==r.id)break;d(",")}return d("]",!0),this.expressions=e,this.type="unary",this}),v("[",n["["],function(e){if("]"===r.id){for(var t=e;t&&"binary"===t.type&&"["===t.value;)t=t.lhs;return t.keepArray=!0,d("]"),e}return this.lhs=e,this.rhs=h(n["]"]),this.type="binary",d("]",!0),this}),v("^",n["^"],function(e){d("(");for(var t=[];;){var n={descending:!1};if("<"===r.id?d("<"):">"===r.id&&(n.descending=!0,d(">")),n.expression=h(0),t.push(n),","!==r.id)break;d(",")}return d(")"),this.lhs=e,this.rhs=t,this.type="binary",this});var y=function(e){var t=[];if("}"!==r.id)for(;;){var n=h(0);d(":");var a=h(0);if(t.push([n,a]),","!==r.id)break;d(",")}return d("}",!0),void 0===e?(this.lhs=t,this.type="unary"):(this.lhs=e,this.rhs=t,this.type="binary"),this};m("{",y),v("{",n["{"],y),b(":=",n[":="],function(e){return"variable"!==e.type?l({code:"S0212",stack:(new Error).stack,position:e.position,token:e.value}):(this.lhs=e,this.rhs=h(n[":="]-1),this.type="binary",this)}),v("@",n["@"],function(e){return this.lhs=e,this.rhs=h(n["@"]),"variable"!==this.rhs.type?l({code:"S0214",stack:(new Error).stack,position:this.rhs.position,token:"@"}):(this.type="binary",this)}),v("#",n["#"],function(e){return this.lhs=e,this.rhs=h(n["#"]),"variable"!==this.rhs.type?l({code:"S0214",stack:(new Error).stack,position:this.rhs.position,token:"#"}):(this.type="binary",this)}),v("?",n["?"],function(e){return this.type="condition",this.condition=e,this.then=h(0),":"===r.id&&(d(":"),this.else=h(0)),this}),m("|",function(){return this.type="transform",this.pattern=h(0),d("|"),this.update=h(0),","===r.id&&(d(","),this.delete=h(0)),d("|"),this});var k=0,x=0,w=[],E=function e(t,r){switch(t.type){case"name":case"wildcard":r.level--,0===r.level&&(void 0===t.ancestor?t.ancestor=r:(w[r.index].slot.label=t.ancestor.label,t.ancestor=r),t.tuple=!0);break;case"parent":r.level++;break;case"block":t.expressions.length>0&&(t.tuple=!0,r=e(t.expressions[t.expressions.length-1],r));break;case"path":t.tuple=!0;var n=t.steps.length-1;for(r=e(t.steps[n--],r);r.level>0&&n>=0;)r=e(t.steps[n--],r);break;default:throw{code:"S0217",token:t.type,position:t.position}}return r},A=function(e,t){if(void 0!==t.seekingParent||"parent"===t.type){var r=void 0!==t.seekingParent?t.seekingParent:[];"parent"===t.type&&r.push(t.slot),void 0===e.seekingParent?e.seekingParent=r:Array.prototype.push.apply(e.seekingParent,r)}},S=function(e){var t=e.steps.length-1,r=e.steps[t],n=void 0!==r.seekingParent?r.seekingParent:[];"parent"===r.type&&n.push(r.slot);for(var a=0;a<n.length;a++){var i=n[a];for(t=e.steps.length-2;i.level>0;){if(t<0){void 0===e.seekingParent?e.seekingParent=[i]:e.seekingParent.push(i);break}for(var o=e.steps[t--];t>=0&&o.focus&&e.steps[t].focus;)o=e.steps[t--];i=E(o,i)}}};a=i(e),d();var T=h(0);if("(end)"!==r.id){var D={code:"S0201",position:r.position,token:r.value};l(D)}if("parent"===(T=function e(r){var n;switch(r.type){case"binary":switch(r.value){case".":var a=e(r.lhs);n="path"===a.type?a:{type:"path",steps:[a]},"parent"===a.type&&(n.seekingParent=[a.slot]);var i=e(r.rhs);"function"===i.type&&"path"===i.procedure.type&&1===i.procedure.steps.length&&"name"===i.procedure.steps[0].type&&"function"===n.steps[n.steps.length-1].type&&(n.steps[n.steps.length-1].nextFunction=i.procedure.steps[0].value),"path"===i.type?Array.prototype.push.apply(n.steps,i.steps):(void 0!==i.predicate&&(i.stages=i.predicate,delete i.predicate),n.steps.push(i)),n.steps.filter(function(e){if("number"===e.type||"value"===e.type)throw{code:"S0213",stack:(new Error).stack,position:e.position,value:e.value};return"string"===e.type}).forEach(function(e){e.type="name"}),n.steps.filter(function(e){return!0===e.keepArray}).length>0&&(n.keepSingletonArray=!0);var o=n.steps[0];"unary"===o.type&&"["===o.value&&(o.consarray=!0);var s=n.steps[n.steps.length-1];"unary"===s.type&&"["===s.value&&(s.consarray=!0),S(n);break;case"[":var c=n=e(r.lhs),p="predicate";if("path"===n.type&&(c=n.steps[n.steps.length-1],p="stages"),void 0!==c.group)throw{code:"S0209",stack:(new Error).stack,position:r.position};void 0===c[p]&&(c[p]=[]);var f=e(r.rhs);void 0!==f.seekingParent&&(f.seekingParent.forEach(function(e){1===e.level?E(c,e):e.level--}),A(c,f)),c[p].push({type:"filter",expr:f,position:r.position});break;case"{":if(void 0!==(n=e(r.lhs)).group)throw{code:"S0210",stack:(new Error).stack,position:r.position};n.group={lhs:r.rhs.map(function(t){return[e(t[0]),e(t[1])]}),position:r.position};break;case"^":"path"!==(n=e(r.lhs)).type&&(n={type:"path",steps:[n]});var l={type:"sort",position:r.position};l.terms=r.rhs.map(function(t){var r=e(t.expression);return A(l,r),{descending:t.descending,expression:r}}),n.steps.push(l),S(n);break;case":=":(n={type:"bind",value:r.value,position:r.position}).lhs=e(r.lhs),n.rhs=e(r.rhs),A(n,n.rhs);break;case"@":if(n=e(r.lhs),c=n,"path"===n.type&&(c=n.steps[n.steps.length-1]),void 0!==c.stages||void 0!==c.predicate)throw{code:"S0215",stack:(new Error).stack,position:r.position};if("sort"===c.type)throw{code:"S0216",stack:(new Error).stack,position:r.position};r.keepArray&&(c.keepArray=!0),c.focus=r.rhs.value,c.tuple=!0;break;case"#":n=e(r.lhs),c=n,"path"===n.type?c=n.steps[n.steps.length-1]:(n={type:"path",steps:[n]},void 0!==c.predicate&&(c.stages=c.predicate,delete c.predicate)),void 0===c.stages?c.index=r.rhs.value:c.stages.push({type:"index",value:r.rhs.value,position:r.position}),c.tuple=!0;break;case"~>":(n={type:"apply",value:r.value,position:r.position}).lhs=e(r.lhs),n.rhs=e(r.rhs);break;default:(n={type:r.type,value:r.value,position:r.position}).lhs=e(r.lhs),n.rhs=e(r.rhs),A(n,n.lhs),A(n,n.rhs)}break;case"unary":n={type:r.type,value:r.value,position:r.position},"["===r.value?n.expressions=r.expressions.map(function(t){var r=e(t);return A(n,r),r}):"{"===r.value?n.lhs=r.lhs.map(function(t){var r=e(t[0]);A(n,r);var a=e(t[1]);return A(n,a),[r,a]}):(n.expression=e(r.expression),"-"===r.value&&"number"===n.expression.type?(n=n.expression).value=-n.value:A(n,n.expression));break;case"function":case"partial":(n={type:r.type,name:r.name,value:r.value,position:r.position}).arguments=r.arguments.map(function(t){var r=e(t);return A(n,r),r}),n.procedure=e(r.procedure);break;case"lambda":n={type:r.type,arguments:r.arguments,signature:r.signature,position:r.position};var d=e(r.body);n.body=function e(t){var r;if("function"!==t.type||t.predicate)if("condition"===t.type)t.then=e(t.then),void 0!==t.else&&(t.else=e(t.else)),r=t;else if("block"===t.type){var n=t.expressions.length;n>0&&(t.expressions[n-1]=e(t.expressions[n-1])),r=t}else r=t;else{var a={type:"lambda",thunk:!0,arguments:[],position:t.position};a.body=t,r=a}return r}(d);break;case"condition":(n={type:r.type,position:r.position}).condition=e(r.condition),A(n,n.condition),n.then=e(r.then),A(n,n.then),void 0!==r.else&&(n.else=e(r.else),A(n,n.else));break;case"transform":(n={type:r.type,position:r.position}).pattern=e(r.pattern),n.update=e(r.update),void 0!==r.delete&&(n.delete=e(r.delete));break;case"block":(n={type:r.type,position:r.position}).expressions=r.expressions.map(function(t){var r=e(t);return A(n,r),(r.consarray||"path"===r.type&&r.steps[0].consarray)&&(n.consarray=!0),r});break;case"name":n={type:"path",steps:[r]},r.keepArray&&(n.keepSingletonArray=!0);break;case"parent":n={type:"parent",slot:{label:"!"+k++,level:1,index:x++}},w.push(n);break;case"string":case"number":case"value":case"wildcard":case"descendant":case"variable":case"regex":n=r;break;case"operator":if("and"===r.value||"or"===r.value||"in"===r.value)r.type="name",n=e(r);else{if("?"!==r.value)throw{code:"S0201",stack:(new Error).stack,position:r.position,token:r.value};n=r}break;case"error":n=r,r.lhs&&(n=e(r.lhs));break;default:var h="S0206";"(end)"===r.id&&(h="S0207");var g={code:h,position:r.position,token:r.value};if(t)return u.push(g),{type:"error",error:g};throw g.stack=(new Error).stack,g}return r.keepArray&&(n.keepArray=!0),n}(T)).type||void 0!==T.seekingParent)throw{code:"S0217",token:T.type,position:T.position};return u.length>0&&(T.errors=u),T});t.exports=s},{"./signature":5}],5:[function(e,t,r){"use strict";function n(e){"@babel/helpers - typeof";return(n="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}var a=e("./utils"),i=function(){var e={a:"arrays",b:"booleans",f:"functions",n:"numbers",o:"objects",s:"strings"};return function(t){for(var r=1,i=[],o={},s=o;r<t.length;){var u=t.charAt(r);if(":"===u)break;var c=function(){i.push(o),s=o,o={}},p=function(e,t,r,n){for(var a=1,i=t;i<e.length;)if(i++,(u=e.charAt(i))===n){if(0==--a)break}else u===r&&a++;return i};switch(u){case"s":case"n":case"b":case"l":case"o":o.regex="["+u+"m]",o.type=u,c();break;case"a":o.regex="[asnblfom]",o.type=u,o.array=!0,c();break;case"f":o.regex="f",o.type=u,c();break;case"j":o.regex="[asnblom]",o.type=u,c();break;case"x":o.regex="[asnblfom]",o.type=u,c();break;case"-":s.context=!0,s.contextRegex=new RegExp(s.regex),s.regex+="?";break;case"?":case"+":s.regex+=u;break;case"(":var f=p(t,r,"(",")"),l=t.substring(r+1,f);if(-1!==l.indexOf("<"))throw{code:"S0402",stack:(new Error).stack,value:l,offset:r};o.regex="["+l+"m]",o.type="("+l+")",r=f,c();break;case"<":if("a"!==s.type&&"f"!==s.type)throw{code:"S0401",stack:(new Error).stack,value:s.type,offset:r};var d=p(t,r,"<",">");s.subtype=t.substring(r+1,d),r=d}r++}var h="^"+i.map(function(e){return"("+e.regex+")"}).join("")+"$",g=new RegExp(h),v=function(e){var t;if(a.isFunction(e))t="f";else switch(n(e)){case"string":t="s";break;case"number":t="n";break;case"boolean":t="b";break;case"object":t=null===e?"l":Array.isArray(e)?"a":"o";break;case"undefined":default:t="m"}return t};return{definition:t,validate:function(t,r){var n="";t.forEach(function(e){n+=v(e)});var a=g.exec(n);if(a){var o=[],s=0;return i.forEach(function(n,i){var u=t[s],c=a[i+1];if(""===c)if(n.context&&n.contextRegex){var p=v(r);if(!n.contextRegex.test(p))throw{code:"T0411",stack:(new Error).stack,value:r,index:s+1};o.push(r)}else o.push(u),s++;else c.split("").forEach(function(r){if("a"===n.type){if("m"===r)u=void 0;else{u=t[s];var a=!0;if(void 0!==n.subtype)if("a"!==r&&c!==n.subtype)a=!1;else if("a"===r&&u.length>0){var i=v(u[0]);a=i===n.subtype.charAt(0)&&0===u.filter(function(e){return v(e)!==i}).length}if(!a)throw{code:"T0412",stack:(new Error).stack,value:u,index:s+1,type:e[n.subtype]};"a"!==r&&(u=[u])}o.push(u),s++}else o.push(u),s++})}),o}!function(e,t){for(var r="^",n=0,a=0;a<i.length;a++){r+=i[a].regex;var o=t.match(r);if(null===o)throw{code:"T0410",stack:(new Error).stack,value:e[n],index:n+1};n=o[0].length}throw{code:"T0410",stack:(new Error).stack,value:e[n],index:n+1}}(t,n)}}}}();t.exports=i},{"./utils":6}],6:[function(e,t,r){"use strict";function n(e,t){var r="undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(!r){if(Array.isArray(e)||(r=function(e,t){if(!e)return;if("string"==typeof e)return a(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);"Object"===r&&e.constructor&&(r=e.constructor.name);if("Map"===r||"Set"===r)return Array.from(e);if("Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return a(e,t)}(e))||t&&e&&"number"==typeof e.length){r&&(e=r);var n=0,i=function(){};return{s:i,n:function(){return n>=e.length?{done:!0}:{done:!1,value:e[n++]}},e:function(e){throw e},f:i}}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,s=!0,u=!1;return{s:function(){r=r.call(e)},n:function(){var e=r.next();return s=e.done,e},e:function(e){u=!0,o=e},f:function(){try{s||null==r.return||r.return()}finally{if(u)throw o}}}}function a(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=new Array(t);r<t;r++)n[r]=e[r];return n}function i(e){"@babel/helpers - typeof";return(i="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}var o=function(){function e(e){var t=!1;if("number"==typeof e&&(t=!isNaN(e))&&!isFinite(e))throw{code:"D1001",value:e,stack:(new Error).stack};return t}var t=("function"==typeof Symbol?Symbol:{}).iterator||"@@iterator";return{isNumeric:e,isArrayOfStrings:function(e){var t=!1;return Array.isArray(e)&&(t=0===e.filter(function(e){return"string"!=typeof e}).length),t},isArrayOfNumbers:function(t){var r=!1;return Array.isArray(t)&&(r=0===t.filter(function(t){return!e(t)}).length),r},createSequence:function(){var e=[];return e.sequence=!0,1===arguments.length&&e.push(arguments[0]),e},isSequence:function(e){return!0===e.sequence&&Array.isArray(e)},isFunction:function(e){return e&&(!0===e._jsonata_function||!0===e._jsonata_lambda)||"function"==typeof e},isLambda:function(e){return e&&!0===e._jsonata_lambda},isIterable:function(e){return"object"===i(e)&&null!==e&&t in e&&"next"in e&&"function"==typeof e.next},getFunctionArity:function(e){return"number"==typeof e.arity?e.arity:"function"==typeof e.implementation?e.implementation.length:"number"==typeof e.length?e.length:e.arguments.length},isDeepEqual:function e(t,r){if(t===r)return!0;if("object"===i(t)&&"object"===i(r)&&null!==t&&null!==r){if(Array.isArray(t)&&Array.isArray(r)){if(t.length!==r.length)return!1;for(var n=0;n<t.length;n++)if(!e(t[n],r[n]))return!1;return!0}var a=Object.getOwnPropertyNames(t),o=Object.getOwnPropertyNames(r);if(a.length!==o.length)return!1;for(a=a.sort(),o=o.sort(),n=0;n<a.length;n++)if(a[n]!==o[n])return!1;for(n=0;n<a.length;n++){var s=a[n];if(!e(t[s],r[s]))return!1}return!0}return!1},stringToArray:function(e){var t,r=[],a=n(e);try{for(a.s();!(t=a.n()).done;){var i=t.value;r.push(i)}}catch(e){a.e(e)}finally{a.f()}return r}}}();t.exports=o},{}]},{},[3])(3)});;(function() { + function indentLine(str,length) { + if (length <= 0) { + return str; + } + var i = (new Array(length)).join(" "); + str = str.replace(/^\s*/,i); + return str; + } + function formatExpression(str) { + var length = str.length; + var start = 0; + var inString = false; + var inRegex = false; + var inBox = false; + var quoteChar; + var list = []; + var stack = []; + var frame; + var v; + var matchingBrackets = { + "(":")", + "[":"]", + "{":"}" + } + for (var i=0;i<length;i++) { + var c = str[i]; + if (!inString && !inRegex) { + if (c === "/") { + inRegex = true; + frame = {type:"regex",pos:i}; + list.push(frame); + stack.push(frame); + } else if (c === "'" || c === '"') { + inString = true; + quoteChar = c; + frame = {type:"string",pos:i}; + list.push(frame); + stack.push(frame); + } else if (c === ";") { + frame = {type:";",pos:i}; + list.push(frame); + } else if (c === ",") { + frame = {type:",",pos:i}; + list.push(frame); + } else if (c === "&") { + frame = {type:"&",pos:i}; + list.push(frame); + } else if (/[\(\[\{]/.test(c)) { + frame = {type:"open-block",char:c,pos:i}; + list.push(frame); + stack.push(frame); + } else if (/[\}\)\]]/.test(c)) { + var oldFrame = stack.pop(); + if (matchingBrackets[oldFrame.char] !== c) { + // console.log("Stack frame mismatch",c,"at",i,"expected",matchingBrackets[oldFrame.char],"from",oldFrame.pos); + // console.log(list); + return str; + } + //console.log("Closing",c,"at",i,"compare",oldFrame.type,oldFrame.pos); + oldFrame.width = i-oldFrame.pos; + frame = {type:"close-block",pos:i,char:c,width:oldFrame.width} + list.push(frame); + } + } else { + if (c === "\\") { + // an escaped char - stay in current mode and skip the next char + i++; + } + if (inString) { + if (c === quoteChar) { + // Next char must be a ] + inString = false; + var f = stack.pop(); + f.end = i; + } + } else if (inRegex) { + if (c === "/") { + inRegex = false; + var f = stack.pop(); + f.end = i; + } + } + } + } + // console.log("list",list); + + var result = str; + var indent = 0; + var offset = 0; + var pre,post,indented,hasNewline; + var longStack = []; + list.forEach(function(f) { + if (f.type === ";" || f.type === ",") { + if (longStack[longStack.length-1]) { + pre = result.substring(0,offset+f.pos+1); + post = result.substring(offset+f.pos+1); + indented = indentLine(post,indent); + hasNewline = /\n$/.test(pre); + // console.log("A§"+pre+"§\n§"+indented+"§",hasNewline); + result = pre+(hasNewline?"":"\n")+indented; + offset += indented.length-post.length+(hasNewline?0:1); + } + } else if (f.type === "&") { + pre = result.substring(0,offset+f.pos+1); + var lastLineBreak = pre.lastIndexOf("\n"); + var lineLength = pre.length - lastLineBreak; + if (lineLength > 70) { + post = result.substring(offset+f.pos+1); + if (!/^\n/.test(post)) { + indented = indentLine(post,indent); + hasNewline = /\n$/.test(pre); + result = pre+(hasNewline?"":"\n")+indented; + offset += indented.length-post.length+(hasNewline?0:1); + } + } + + } else if (f.type === "open-block") { + if (f.width > 40) { + longStack.push(true); + indent += 4; + pre = result.substring(0,offset+f.pos+1); + post = result.substring(offset+f.pos+1); + hasNewline = /\n$/.test(pre); + indented = indentLine(post,indent); + result = pre+(hasNewline?"":"\n")+indented; + offset += indented.length-post.length+(hasNewline?0:1); + } else { + longStack.push(false); + } + } else if (f.type === "close-block") { + if (f.width > 40) { + indent -= 4; + pre = result.substring(0,offset+f.pos); + post = result.substring(offset+f.pos); + indented = indentLine(post,indent); + hasNewline = /\n *$/.test(pre); + if (hasNewline) { + result = pre + post; + } else { + result = pre+"\n"+indented; + offset += indented.length-post.length+1; + } + } + longStack.pop(); + } + }) + //console.log(result); + return result; + } + + jsonata.format = formatExpression; + jsonata.functions = + { + '$abs':{ args:[ 'number' ]}, + '$append':{ args:[ 'array1', 'array2' ]}, + '$assert':{ args: [ 'arg', 'str' ]}, + '$average':{ args:[ 'array' ]}, + '$base64decode':{ args:[ ]}, + '$base64encode':{ args:[ ]}, + '$boolean':{ args:[ 'arg' ]}, + '$ceil':{ args:[ 'number' ]}, + '$contains':{ args:[ 'str', 'pattern' ]}, + '$count':{ args:[ 'array' ]}, + '$decodeUrl':{ args:[ 'str' ]}, + '$decodeUrlComponent':{ args:[ 'str' ]}, + '$distinct':{ args:[ 'array' ]}, + '$each':{ args:[ 'object', 'function' ]}, + '$encodeUrl':{ args: ['str'] }, + '$encodeUrlComponent':{ args:[ 'str' ]}, + '$env': { args:[ 'arg' ]}, + '$error':{ args:[ 'str' ]}, + '$eval': { args: ['expr', 'context']}, + '$exists':{ args:[ 'arg' ]}, + '$filter':{ args:[ 'array', 'function' ]}, + '$floor':{ args:[ 'number' ]}, + '$flowContext': {args:['string']}, + '$formatBase': {args:['number','radix']}, + '$formatInteger': {args:['number', 'picture']}, + '$formatNumber': {args:['number', 'picture', 'options']}, + '$fromMillis': {args:['number']}, + '$globalContext': {args:['string']}, + '$join':{ args:[ 'array', 'separator' ]}, + '$keys':{ args:[ 'object' ]}, + '$length':{ args:[ 'str' ]}, + '$lookup':{ args:[ 'object', 'key' ]}, + '$lowercase':{ args:[ 'str' ]}, + '$map':{ args:[ 'array', 'function' ]}, + '$match':{ args:[ 'str', 'pattern', 'limit' ]}, + '$max':{ args:[ 'array' ]}, + '$merge':{ args:[ 'array' ]}, + '$millis':{ args:[ ]}, + '$min':{ args:[ 'array' ]}, + '$moment':{ args:[ ]}, + '$not':{ args:[ 'arg' ]}, + '$now':{ args:[ ]}, + '$number':{ args:[ 'arg' ]}, + '$pad': {args:['str', 'width','char']}, + '$parseInteger': {args:['string', 'picture']}, + '$power':{ args:[ 'base', 'exponent' ]}, + '$random':{ args:[ ]}, + '$reduce':{ args:[ 'array', 'function' , 'init' ]}, + '$replace':{ args:[ 'str', 'pattern', 'replacement', 'limit' ]}, + '$reverse':{ args:[ 'array' ]}, + '$round':{ args:[ 'number', 'precision' ]}, + '$shuffle':{ args:[ 'array' ]}, + '$sift':{ args: ['object', 'function'] }, + '$single':{ args: ['array', 'function'] }, + '$sort':{ args:[ 'array', 'function' ]}, + '$split':{ args:[ 'str', 'separator', 'limit' ]}, + '$spread':{ args:[ 'object' ]}, + '$sqrt':{ args:[ 'number' ]}, + '$string':{ args:[ 'arg', 'prettify' ]}, + '$substring':{ args:[ 'str', 'start', 'length' ]}, + '$substringAfter':{ args:[ 'str', 'chars' ]}, + '$substringBefore':{ args:[ 'str', 'chars' ]}, + '$sum':{ args:[ 'array' ]}, + '$toMillis':{args:['timestamp']}, // <------------- + '$trim':{ args:[ 'str' ]}, + '$type':{ args:['value']}, + '$uppercase':{ args:[ 'str' ]}, + '$zip':{ args:[ 'array1' ]} + } + jsonata.getFunctionSnippet = function(fn) { + var snippetText = ""; + if (jsonata.functions.hasOwnProperty(fn)) { + var def = jsonata.functions[fn]; + snippetText = "\\"+fn+"("; + if (def.args) { + snippetText += def.args.map(function(a,i) { return "${"+(i+1)+":"+a+"}"}).join(", "); + } + snippetText += ")\n" + } + return snippetText; + } +})(); +;(function(){function o(n){var i=e;n&&(e[n]||(e[n]={}),i=e[n]);if(!i.define||!i.define.packaged)t.original=i.define,i.define=t,i.define.packaged=!0;if(!i.require||!i.require.packaged)r.original=i.require,i.require=r,i.require.packaged=!0}var ACE_NAMESPACE = "ace",e=function(){return this}();!e&&typeof window!="undefined"&&(e=window);if(!ACE_NAMESPACE&&typeof requirejs!="undefined")return;var t=function(e,n,r){if(typeof e!="string"){t.original?t.original.apply(this,arguments):(console.error("dropping module because define wasn't a string."),console.trace());return}arguments.length==2&&(r=n),t.modules[e]||(t.payloads[e]=r,t.modules[e]=null)};t.modules={},t.payloads={};var n=function(e,t,n){if(typeof t=="string"){var i=s(e,t);if(i!=undefined)return n&&n(),i}else if(Object.prototype.toString.call(t)==="[object Array]"){var o=[];for(var u=0,a=t.length;u<a;++u){var f=s(e,t[u]);if(f==undefined&&r.original)return;o.push(f)}return n&&n.apply(null,o)||!0}},r=function(e,t){var i=n("",e,t);return i==undefined&&r.original?r.original.apply(this,arguments):i},i=function(e,t){if(t.indexOf("!")!==-1){var n=t.split("!");return i(e,n[0])+"!"+i(e,n[1])}if(t.charAt(0)=="."){var r=e.split("/").slice(0,-1).join("/");t=r+"/"+t;while(t.indexOf(".")!==-1&&s!=t){var s=t;t=t.replace(/\/\.\//,"/").replace(/[^\/]+\/\.\.\//,"")}}return t},s=function(e,r){r=i(e,r);var s=t.modules[r];if(!s){s=t.payloads[r];if(typeof s=="function"){var o={},u={id:r,uri:"",exports:o,packaged:!0},a=function(e,t){return n(r,e,t)},f=s(a,o,u);o=f||u.exports,t.modules[r]=o,delete t.payloads[r]}s=t.modules[r]=o||s}return s};o(ACE_NAMESPACE)})(),ace.define("ace/lib/fixoldbrowsers",["require","exports","module"],function(e,t,n){"use strict";typeof Element!="undefined"&&!Element.prototype.remove&&Object.defineProperty(Element.prototype,"remove",{enumerable:!1,writable:!0,configurable:!0,value:function(){this.parentNode&&this.parentNode.removeChild(this)}})}),ace.define("ace/lib/useragent",["require","exports","module"],function(e,t,n){"use strict";t.OS={LINUX:"LINUX",MAC:"MAC",WINDOWS:"WINDOWS"},t.getOS=function(){return t.isMac?t.OS.MAC:t.isLinux?t.OS.LINUX:t.OS.WINDOWS};var r=typeof navigator=="object"?navigator:{},i=(/mac|win|linux/i.exec(r.platform)||["other"])[0].toLowerCase(),s=r.userAgent||"",o=r.appName||"";t.isWin=i=="win",t.isMac=i=="mac",t.isLinux=i=="linux",t.isIE=o=="Microsoft Internet Explorer"||o.indexOf("MSAppHost")>=0?parseFloat((s.match(/(?:MSIE |Trident\/[0-9]+[\.0-9]+;.*rv:)([0-9]+[\.0-9]+)/)||[])[1]):parseFloat((s.match(/(?:Trident\/[0-9]+[\.0-9]+;.*rv:)([0-9]+[\.0-9]+)/)||[])[1]),t.isOldIE=t.isIE&&t.isIE<9,t.isGecko=t.isMozilla=s.match(/ Gecko\/\d+/),t.isOpera=typeof opera=="object"&&Object.prototype.toString.call(window.opera)=="[object Opera]",t.isWebKit=parseFloat(s.split("WebKit/")[1])||undefined,t.isChrome=parseFloat(s.split(" Chrome/")[1])||undefined,t.isEdge=parseFloat(s.split(" Edge/")[1])||undefined,t.isAIR=s.indexOf("AdobeAIR")>=0,t.isAndroid=s.indexOf("Android")>=0,t.isChromeOS=s.indexOf(" CrOS ")>=0,t.isIOS=/iPad|iPhone|iPod/.test(s)&&!window.MSStream,t.isIOS&&(t.isMac=!0),t.isMobile=t.isIOS||t.isAndroid}),ace.define("ace/lib/dom",["require","exports","module","ace/lib/useragent"],function(e,t,n){"use strict";var r=e("./useragent"),i="http://www.w3.org/1999/xhtml";t.buildDom=function o(e,t,n){if(typeof e=="string"&&e){var r=document.createTextNode(e);return t&&t.appendChild(r),r}if(!Array.isArray(e))return e&&e.appendChild&&t&&t.appendChild(e),e;if(typeof e[0]!="string"||!e[0]){var i=[];for(var s=0;s<e.length;s++){var u=o(e[s],t,n);u&&i.push(u)}return i}var a=document.createElement(e[0]),f=e[1],l=1;f&&typeof f=="object"&&!Array.isArray(f)&&(l=2);for(var s=l;s<e.length;s++)o(e[s],a,n);return l==2&&Object.keys(f).forEach(function(e){var t=f[e];e==="class"?a.className=Array.isArray(t)?t.join(" "):t:typeof t=="function"||e=="value"||e[0]=="$"?a[e]=t:e==="ref"?n&&(n[t]=a):t!=null&&a.setAttribute(e,t)}),t&&t.appendChild(a),a},t.getDocumentHead=function(e){return e||(e=document),e.head||e.getElementsByTagName("head")[0]||e.documentElement},t.createElement=function(e,t){return document.createElementNS?document.createElementNS(t||i,e):document.createElement(e)},t.removeChildren=function(e){e.innerHTML=""},t.createTextNode=function(e,t){var n=t?t.ownerDocument:document;return n.createTextNode(e)},t.createFragment=function(e){var t=e?e.ownerDocument:document;return t.createDocumentFragment()},t.hasCssClass=function(e,t){var n=(e.className+"").split(/\s+/g);return n.indexOf(t)!==-1},t.addCssClass=function(e,n){t.hasCssClass(e,n)||(e.className+=" "+n)},t.removeCssClass=function(e,t){var n=e.className.split(/\s+/g);for(;;){var r=n.indexOf(t);if(r==-1)break;n.splice(r,1)}e.className=n.join(" ")},t.toggleCssClass=function(e,t){var n=e.className.split(/\s+/g),r=!0;for(;;){var i=n.indexOf(t);if(i==-1)break;r=!1,n.splice(i,1)}return r&&n.push(t),e.className=n.join(" "),r},t.setCssClass=function(e,n,r){r?t.addCssClass(e,n):t.removeCssClass(e,n)},t.hasCssString=function(e,t){var n=0,r;t=t||document;if(r=t.querySelectorAll("style"))while(n<r.length)if(r[n++].id===e)return!0},t.importCssString=function(n,r,i){var s=i;if(!i||!i.getRootNode)s=document;else{s=i.getRootNode();if(!s||s==i)s=document}var o=s.ownerDocument||s;if(r&&t.hasCssString(r,s))return null;r&&(n+="\n/*# sourceURL=ace/css/"+r+" */");var u=t.createElement("style");u.appendChild(o.createTextNode(n)),r&&(u.id=r),s==o&&(s=t.getDocumentHead(o)),s.insertBefore(u,s.firstChild)},t.importCssStylsheet=function(e,n){t.buildDom(["link",{rel:"stylesheet",href:e}],t.getDocumentHead(n))},t.scrollbarWidth=function(e){var n=t.createElement("ace_inner");n.style.width="100%",n.style.minWidth="0px",n.style.height="200px",n.style.display="block";var r=t.createElement("ace_outer"),i=r.style;i.position="absolute",i.left="-10000px",i.overflow="hidden",i.width="200px",i.minWidth="0px",i.height="150px",i.display="block",r.appendChild(n);var s=e.documentElement;s.appendChild(r);var o=n.offsetWidth;i.overflow="scroll";var u=n.offsetWidth;return o==u&&(u=r.clientWidth),s.removeChild(r),o-u},typeof document=="undefined"&&(t.importCssString=function(){}),t.computedStyle=function(e,t){return window.getComputedStyle(e,"")||{}},t.setStyle=function(e,t,n){e[t]!==n&&(e[t]=n)},t.HAS_CSS_ANIMATION=!1,t.HAS_CSS_TRANSFORMS=!1,t.HI_DPI=r.isWin?typeof window!="undefined"&&window.devicePixelRatio>=1.5:!0;if(typeof document!="undefined"){var s=document.createElement("div");t.HI_DPI&&s.style.transform!==undefined&&(t.HAS_CSS_TRANSFORMS=!0),!r.isEdge&&typeof s.style.animationName!="undefined"&&(t.HAS_CSS_ANIMATION=!0),s=null}t.HAS_CSS_TRANSFORMS?t.translate=function(e,t,n){e.style.transform="translate("+Math.round(t)+"px, "+Math.round(n)+"px)"}:t.translate=function(e,t,n){e.style.top=Math.round(n)+"px",e.style.left=Math.round(t)+"px"}}),ace.define("ace/lib/oop",["require","exports","module"],function(e,t,n){"use strict";t.inherits=function(e,t){e.super_=t,e.prototype=Object.create(t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}})},t.mixin=function(e,t){for(var n in t)e[n]=t[n];return e},t.implement=function(e,n){t.mixin(e,n)}}),ace.define("ace/lib/keys",["require","exports","module","ace/lib/oop"],function(e,t,n){"use strict";var r=e("./oop"),i=function(){var e={MODIFIER_KEYS:{16:"Shift",17:"Ctrl",18:"Alt",224:"Meta",91:"MetaLeft",92:"MetaRight",93:"ContextMenu"},KEY_MODS:{ctrl:1,alt:2,option:2,shift:4,"super":8,meta:8,command:8,cmd:8,control:1},FUNCTION_KEYS:{8:"Backspace",9:"Tab",13:"Return",19:"Pause",27:"Esc",32:"Space",33:"PageUp",34:"PageDown",35:"End",36:"Home",37:"Left",38:"Up",39:"Right",40:"Down",44:"Print",45:"Insert",46:"Delete",96:"Numpad0",97:"Numpad1",98:"Numpad2",99:"Numpad3",100:"Numpad4",101:"Numpad5",102:"Numpad6",103:"Numpad7",104:"Numpad8",105:"Numpad9","-13":"NumpadEnter",112:"F1",113:"F2",114:"F3",115:"F4",116:"F5",117:"F6",118:"F7",119:"F8",120:"F9",121:"F10",122:"F11",123:"F12",144:"Numlock",145:"Scrolllock"},PRINTABLE_KEYS:{32:" ",48:"0",49:"1",50:"2",51:"3",52:"4",53:"5",54:"6",55:"7",56:"8",57:"9",59:";",61:"=",65:"a",66:"b",67:"c",68:"d",69:"e",70:"f",71:"g",72:"h",73:"i",74:"j",75:"k",76:"l",77:"m",78:"n",79:"o",80:"p",81:"q",82:"r",83:"s",84:"t",85:"u",86:"v",87:"w",88:"x",89:"y",90:"z",107:"+",109:"-",110:".",186:";",187:"=",188:",",189:"-",190:".",191:"/",192:"`",219:"[",220:"\\",221:"]",222:"'",111:"/",106:"*"}},t,n;for(n in e.FUNCTION_KEYS)t=e.FUNCTION_KEYS[n].toLowerCase(),e[t]=parseInt(n,10);for(n in e.PRINTABLE_KEYS)t=e.PRINTABLE_KEYS[n].toLowerCase(),e[t]=parseInt(n,10);return r.mixin(e,e.MODIFIER_KEYS),r.mixin(e,e.PRINTABLE_KEYS),r.mixin(e,e.FUNCTION_KEYS),e.enter=e["return"],e.escape=e.esc,e.del=e["delete"],e[173]="-",function(){var t=["cmd","ctrl","alt","shift"];for(var n=Math.pow(2,t.length);n--;)e.KEY_MODS[n]=t.filter(function(t){return n&e.KEY_MODS[t]}).join("-")+"-"}(),e.KEY_MODS[0]="",e.KEY_MODS[-1]="input-",e}();r.mixin(t,i),t.keyCodeToString=function(e){var t=i[e];return typeof t!="string"&&(t=String.fromCharCode(e)),t.toLowerCase()}}),ace.define("ace/lib/event",["require","exports","module","ace/lib/keys","ace/lib/useragent"],function(e,t,n){"use strict";function a(){u=!1;try{document.createComment("").addEventListener("test",function(){},{get passive(){u={passive:!1}}})}catch(e){}}function f(){return u==undefined&&a(),u}function l(e,t,n){this.elem=e,this.type=t,this.callback=n}function d(e,t,n){var u=p(t);if(!i.isMac&&s){t.getModifierState&&(t.getModifierState("OS")||t.getModifierState("Win"))&&(u|=8);if(s.altGr){if((3&u)==3)return;s.altGr=0}if(n===18||n===17){var a="location"in t?t.location:t.keyLocation;if(n===17&&a===1)s[n]==1&&(o=t.timeStamp);else if(n===18&&u===3&&a===2){var f=t.timeStamp-o;f<50&&(s.altGr=!0)}}}n in r.MODIFIER_KEYS&&(n=-1);if(!u&&n===13){var a="location"in t?t.location:t.keyLocation;if(a===3){e(t,u,-n);if(t.defaultPrevented)return}}if(i.isChromeOS&&u&8){e(t,u,n);if(t.defaultPrevented)return;u&=-9}return!!u||n in r.FUNCTION_KEYS||n in r.PRINTABLE_KEYS?e(t,u,n):!1}function v(){s=Object.create(null)}var r=e("./keys"),i=e("./useragent"),s=null,o=0,u;l.prototype.destroy=function(){h(this.elem,this.type,this.callback),this.elem=this.type=this.callback=undefined};var c=t.addListener=function(e,t,n,r){e.addEventListener(t,n,f()),r&&r.$toDestroy.push(new l(e,t,n))},h=t.removeListener=function(e,t,n){e.removeEventListener(t,n,f())};t.stopEvent=function(e){return t.stopPropagation(e),t.preventDefault(e),!1},t.stopPropagation=function(e){e.stopPropagation&&e.stopPropagation()},t.preventDefault=function(e){e.preventDefault&&e.preventDefault()},t.getButton=function(e){return e.type=="dblclick"?0:e.type=="contextmenu"||i.isMac&&e.ctrlKey&&!e.altKey&&!e.shiftKey?2:e.button},t.capture=function(e,t,n){function i(e){t&&t(e),n&&n(e),h(r,"mousemove",t),h(r,"mouseup",i),h(r,"dragstart",i)}var r=e&&e.ownerDocument||document;return c(r,"mousemove",t),c(r,"mouseup",i),c(r,"dragstart",i),i},t.addMouseWheelListener=function(e,t,n){"onmousewheel"in e?c(e,"mousewheel",function(e){var n=8;e.wheelDeltaX!==undefined?(e.wheelX=-e.wheelDeltaX/n,e.wheelY=-e.wheelDeltaY/n):(e.wheelX=0,e.wheelY=-e.wheelDelta/n),t(e)},n):"onwheel"in e?c(e,"wheel",function(e){var n=.35;switch(e.deltaMode){case e.DOM_DELTA_PIXEL:e.wheelX=e.deltaX*n||0,e.wheelY=e.deltaY*n||0;break;case e.DOM_DELTA_LINE:case e.DOM_DELTA_PAGE:e.wheelX=(e.deltaX||0)*5,e.wheelY=(e.deltaY||0)*5}t(e)},n):c(e,"DOMMouseScroll",function(e){e.axis&&e.axis==e.HORIZONTAL_AXIS?(e.wheelX=(e.detail||0)*5,e.wheelY=0):(e.wheelX=0,e.wheelY=(e.detail||0)*5),t(e)},n)},t.addMultiMouseDownListener=function(e,n,r,s,o){function p(e){t.getButton(e)!==0?u=0:e.detail>1?(u++,u>4&&(u=1)):u=1;if(i.isIE){var o=Math.abs(e.clientX-a)>5||Math.abs(e.clientY-f)>5;if(!l||o)u=1;l&&clearTimeout(l),l=setTimeout(function(){l=null},n[u-1]||600),u==1&&(a=e.clientX,f=e.clientY)}e._clicks=u,r[s]("mousedown",e);if(u>4)u=0;else if(u>1)return r[s](h[u],e)}var u=0,a,f,l,h={2:"dblclick",3:"tripleclick",4:"quadclick"};Array.isArray(e)||(e=[e]),e.forEach(function(e){c(e,"mousedown",p,o)})};var p=function(e){return 0|(e.ctrlKey?1:0)|(e.altKey?2:0)|(e.shiftKey?4:0)|(e.metaKey?8:0)};t.getModifierString=function(e){return r.KEY_MODS[p(e)]},t.addCommandKeyListener=function(e,n,r){if(i.isOldGecko||i.isOpera&&!("KeyboardEvent"in window)){var o=null;c(e,"keydown",function(e){o=e.keyCode},r),c(e,"keypress",function(e){return d(n,e,o)},r)}else{var u=null;c(e,"keydown",function(e){s[e.keyCode]=(s[e.keyCode]||0)+1;var t=d(n,e,e.keyCode);return u=e.defaultPrevented,t},r),c(e,"keypress",function(e){u&&(e.ctrlKey||e.altKey||e.shiftKey||e.metaKey)&&(t.stopEvent(e),u=null)},r),c(e,"keyup",function(e){s[e.keyCode]=null},r),s||(v(),c(window,"focus",v))}};if(typeof window=="object"&&window.postMessage&&!i.isOldIE){var m=1;t.nextTick=function(e,n){n=n||window;var r="zero-timeout-message-"+m++,i=function(s){s.data==r&&(t.stopPropagation(s),h(n,"message",i),e())};c(n,"message",i),n.postMessage(r,"*")}}t.$idleBlocked=!1,t.onIdle=function(e,n){return setTimeout(function r(){t.$idleBlocked?setTimeout(r,100):e()},n)},t.$idleBlockId=null,t.blockIdle=function(e){t.$idleBlockId&&clearTimeout(t.$idleBlockId),t.$idleBlocked=!0,t.$idleBlockId=setTimeout(function(){t.$idleBlocked=!1},e||100)},t.nextFrame=typeof window=="object"&&(window.requestAnimationFrame||window.mozRequestAnimationFrame||window.webkitRequestAnimationFrame||window.msRequestAnimationFrame||window.oRequestAnimationFrame),t.nextFrame?t.nextFrame=t.nextFrame.bind(window):t.nextFrame=function(e){setTimeout(e,17)}}),ace.define("ace/range",["require","exports","module"],function(e,t,n){"use strict";var r=function(e,t){return e.row-t.row||e.column-t.column},i=function(e,t,n,r){this.start={row:e,column:t},this.end={row:n,column:r}};(function(){this.isEqual=function(e){return this.start.row===e.start.row&&this.end.row===e.end.row&&this.start.column===e.start.column&&this.end.column===e.end.column},this.toString=function(){return"Range: ["+this.start.row+"/"+this.start.column+"] -> ["+this.end.row+"/"+this.end.column+"]"},this.contains=function(e,t){return this.compare(e,t)==0},this.compareRange=function(e){var t,n=e.end,r=e.start;return t=this.compare(n.row,n.column),t==1?(t=this.compare(r.row,r.column),t==1?2:t==0?1:0):t==-1?-2:(t=this.compare(r.row,r.column),t==-1?-1:t==1?42:0)},this.comparePoint=function(e){return this.compare(e.row,e.column)},this.containsRange=function(e){return this.comparePoint(e.start)==0&&this.comparePoint(e.end)==0},this.intersects=function(e){var t=this.compareRange(e);return t==-1||t==0||t==1},this.isEnd=function(e,t){return this.end.row==e&&this.end.column==t},this.isStart=function(e,t){return this.start.row==e&&this.start.column==t},this.setStart=function(e,t){typeof e=="object"?(this.start.column=e.column,this.start.row=e.row):(this.start.row=e,this.start.column=t)},this.setEnd=function(e,t){typeof e=="object"?(this.end.column=e.column,this.end.row=e.row):(this.end.row=e,this.end.column=t)},this.inside=function(e,t){return this.compare(e,t)==0?this.isEnd(e,t)||this.isStart(e,t)?!1:!0:!1},this.insideStart=function(e,t){return this.compare(e,t)==0?this.isEnd(e,t)?!1:!0:!1},this.insideEnd=function(e,t){return this.compare(e,t)==0?this.isStart(e,t)?!1:!0:!1},this.compare=function(e,t){return!this.isMultiLine()&&e===this.start.row?t<this.start.column?-1:t>this.end.column?1:0:e<this.start.row?-1:e>this.end.row?1:this.start.row===e?t>=this.start.column?0:-1:this.end.row===e?t<=this.end.column?0:1:0},this.compareStart=function(e,t){return this.start.row==e&&this.start.column==t?-1:this.compare(e,t)},this.compareEnd=function(e,t){return this.end.row==e&&this.end.column==t?1:this.compare(e,t)},this.compareInside=function(e,t){return this.end.row==e&&this.end.column==t?1:this.start.row==e&&this.start.column==t?-1:this.compare(e,t)},this.clipRows=function(e,t){if(this.end.row>t)var n={row:t+1,column:0};else if(this.end.row<e)var n={row:e,column:0};if(this.start.row>t)var r={row:t+1,column:0};else if(this.start.row<e)var r={row:e,column:0};return i.fromPoints(r||this.start,n||this.end)},this.extend=function(e,t){var n=this.compare(e,t);if(n==0)return this;if(n==-1)var r={row:e,column:t};else var s={row:e,column:t};return i.fromPoints(r||this.start,s||this.end)},this.isEmpty=function(){return this.start.row===this.end.row&&this.start.column===this.end.column},this.isMultiLine=function(){return this.start.row!==this.end.row},this.clone=function(){return i.fromPoints(this.start,this.end)},this.collapseRows=function(){return this.end.column==0?new i(this.start.row,0,Math.max(this.start.row,this.end.row-1),0):new i(this.start.row,0,this.end.row,0)},this.toScreenRange=function(e){var t=e.documentToScreenPosition(this.start),n=e.documentToScreenPosition(this.end);return new i(t.row,t.column,n.row,n.column)},this.moveBy=function(e,t){this.start.row+=e,this.start.column+=t,this.end.row+=e,this.end.column+=t}}).call(i.prototype),i.fromPoints=function(e,t){return new i(e.row,e.column,t.row,t.column)},i.comparePoints=r,i.comparePoints=function(e,t){return e.row-t.row||e.column-t.column},t.Range=i}),ace.define("ace/lib/lang",["require","exports","module"],function(e,t,n){"use strict";t.last=function(e){return e[e.length-1]},t.stringReverse=function(e){return e.split("").reverse().join("")},t.stringRepeat=function(e,t){var n="";while(t>0){t&1&&(n+=e);if(t>>=1)e+=e}return n};var r=/^\s\s*/,i=/\s\s*$/;t.stringTrimLeft=function(e){return e.replace(r,"")},t.stringTrimRight=function(e){return e.replace(i,"")},t.copyObject=function(e){var t={};for(var n in e)t[n]=e[n];return t},t.copyArray=function(e){var t=[];for(var n=0,r=e.length;n<r;n++)e[n]&&typeof e[n]=="object"?t[n]=this.copyObject(e[n]):t[n]=e[n];return t},t.deepCopy=function s(e){if(typeof e!="object"||!e)return e;var t;if(Array.isArray(e)){t=[];for(var n=0;n<e.length;n++)t[n]=s(e[n]);return t}if(Object.prototype.toString.call(e)!=="[object Object]")return e;t={};for(var n in e)t[n]=s(e[n]);return t},t.arrayToMap=function(e){var t={};for(var n=0;n<e.length;n++)t[e[n]]=1;return t},t.createMap=function(e){var t=Object.create(null);for(var n in e)t[n]=e[n];return t},t.arrayRemove=function(e,t){for(var n=0;n<=e.length;n++)t===e[n]&&e.splice(n,1)},t.escapeRegExp=function(e){return e.replace(/([.*+?^${}()|[\]\/\\])/g,"\\$1")},t.escapeHTML=function(e){return(""+e).replace(/&/g,"&#38;").replace(/"/g,"&#34;").replace(/'/g,"&#39;").replace(/</g,"&#60;")},t.getMatchOffsets=function(e,t){var n=[];return e.replace(t,function(e){n.push({offset:arguments[arguments.length-2],length:e.length})}),n},t.deferredCall=function(e){var t=null,n=function(){t=null,e()},r=function(e){return r.cancel(),t=setTimeout(n,e||0),r};return r.schedule=r,r.call=function(){return this.cancel(),e(),r},r.cancel=function(){return clearTimeout(t),t=null,r},r.isPending=function(){return t},r},t.delayedCall=function(e,t){var n=null,r=function(){n=null,e()},i=function(e){n==null&&(n=setTimeout(r,e||t))};return i.delay=function(e){n&&clearTimeout(n),n=setTimeout(r,e||t)},i.schedule=i,i.call=function(){this.cancel(),e()},i.cancel=function(){n&&clearTimeout(n),n=null},i.isPending=function(){return n},i}}),ace.define("ace/clipboard",["require","exports","module"],function(e,t,n){"use strict";var r;n.exports={lineMode:!1,pasteCancelled:function(){return r&&r>Date.now()-50?!0:r=!1},cancel:function(){r=Date.now()}}}),ace.define("ace/keyboard/textinput",["require","exports","module","ace/lib/event","ace/lib/useragent","ace/lib/dom","ace/lib/lang","ace/clipboard","ace/lib/keys"],function(e,t,n){"use strict";var r=e("../lib/event"),i=e("../lib/useragent"),s=e("../lib/dom"),o=e("../lib/lang"),u=e("../clipboard"),a=i.isChrome<18,f=i.isIE,l=i.isChrome>63,c=400,h=e("../lib/keys"),p=h.KEY_MODS,d=i.isIOS,v=d?/\s/:/\n/,m=i.isMobile,g=function(e,t){function X(){x=!0,n.blur(),n.focus(),x=!1}function $(e){e.keyCode==27&&n.value.length<n.selectionStart&&(b||(T=n.value),N=C=-1,O()),V()}function K(){clearTimeout(J),J=setTimeout(function(){E&&(n.style.cssText=E,E=""),t.renderer.$isMousePressed=!1,t.renderer.$keepTextAreaAtCursor&&t.renderer.$moveTextAreaToCursor()},0)}function G(e,t,n){var r=null,i=!1;n.addEventListener("keydown",function(e){r&&clearTimeout(r),i=!0},!0),n.addEventListener("keyup",function(e){r=setTimeout(function(){i=!1},100)},!0);var s=function(e){if(document.activeElement!==n)return;if(i||b||t.$mouseHandler.isMousePressed)return;if(g)return;var r=n.selectionStart,s=n.selectionEnd,o=null,u=0;if(r==0)o=h.up;else if(r==1)o=h.home;else if(s>C&&T[s]=="\n")o=h.end;else if(r<N&&T[r-1]==" ")o=h.left,u=p.option;else if(r<N||r==N&&C!=N&&r==s)o=h.left;else if(s>C&&T.slice(0,s).split("\n").length>2)o=h.down;else if(s>C&&T[s-1]==" ")o=h.right,u=p.option;else if(s>C||s==C&&C!=N&&r==s)o=h.right;r!==s&&(u|=p.shift);if(o){var a=t.onCommandKey({},u,o);if(!a&&t.commands){o=h.keyCodeToString(o);var f=t.commands.findKeyCommand(u,o);f&&t.execCommand(f)}N=r,C=s,O("")}};document.addEventListener("selectionchange",s),t.on("destroy",function(){document.removeEventListener("selectionchange",s)})}var n=s.createElement("textarea");n.className="ace_text-input",n.setAttribute("wrap","off"),n.setAttribute("autocorrect","off"),n.setAttribute("autocapitalize","off"),n.setAttribute("spellcheck",!1),n.style.opacity="0",e.insertBefore(n,e.firstChild);var g=!1,y=!1,b=!1,w=!1,E="";m||(n.style.fontSize="1px");var S=!1,x=!1,T="",N=0,C=0,k=0;try{var L=document.activeElement===n}catch(A){}r.addListener(n,"blur",function(e){if(x)return;t.onBlur(e),L=!1},t),r.addListener(n,"focus",function(e){if(x)return;L=!0;if(i.isEdge)try{if(!document.hasFocus())return}catch(e){}t.onFocus(e),i.isEdge?setTimeout(O):O()},t),this.$focusScroll=!1,this.focus=function(){if(E||l||this.$focusScroll=="browser")return n.focus({preventScroll:!0});var e=n.style.top;n.style.position="fixed",n.style.top="0px";try{var t=n.getBoundingClientRect().top!=0}catch(r){return}var i=[];if(t){var s=n.parentElement;while(s&&s.nodeType==1)i.push(s),s.setAttribute("ace_nocontext",!0),!s.parentElement&&s.getRootNode?s=s.getRootNode().host:s=s.parentElement}n.focus({preventScroll:!0}),t&&i.forEach(function(e){e.removeAttribute("ace_nocontext")}),setTimeout(function(){n.style.position="",n.style.top=="0px"&&(n.style.top=e)},0)},this.blur=function(){n.blur()},this.isFocused=function(){return L},t.on("beforeEndOperation",function(){var e=t.curOp,r=e&&e.command&&e.command.name;if(r=="insertstring")return;var i=r&&(e.docChanged||e.selectionChanged);b&&i&&(T=n.value="",W()),O()});var O=d?function(e){if(!L||g&&!e||w)return;e||(e="");var r="\n ab"+e+"cde fg\n";r!=n.value&&(n.value=T=r);var i=4,s=4+(e.length||(t.selection.isEmpty()?0:1));(N!=i||C!=s)&&n.setSelectionRange(i,s),N=i,C=s}:function(){if(b||w)return;if(!L&&!P)return;b=!0;var e=0,r=0,i="";if(t.session){var s=t.selection,o=s.getRange(),u=s.cursor.row;e=o.start.column,r=o.end.column,i=t.session.getLine(u);if(o.start.row!=u){var a=t.session.getLine(u-1);e=o.start.row<u-1?0:e,r+=a.length+1,i=a+"\n"+i}else if(o.end.row!=u){var f=t.session.getLine(u+1);r=o.end.row>u+1?f.length:r,r+=i.length+1,i=i+"\n"+f}else m&&u>0&&(i="\n"+i,r+=1,e+=1);i.length>c&&(e<c&&r<c?i=i.slice(0,c):(i="\n",e==r?e=r=0:(e=0,r=1)))}var l=i+"\n\n";l!=T&&(n.value=T=l,N=C=l.length),P&&(N=n.selectionStart,C=n.selectionEnd);if(C!=r||N!=e||n.selectionEnd!=C)try{n.setSelectionRange(e,r),N=e,C=r}catch(h){}b=!1};this.resetSelection=O,L&&t.onFocus();var M=function(e){return e.selectionStart===0&&e.selectionEnd>=T.length&&e.value===T&&T&&e.selectionEnd!==C},_=function(e){if(b)return;g?g=!1:M(n)?(t.selectAll(),O()):m&&n.selectionStart!=N&&O()},D=null;this.setInputHandler=function(e){D=e},this.getInputHandler=function(){return D};var P=!1,H=function(e,r){P&&(P=!1);if(y)return O(),e&&t.onPaste(e),y=!1,"";var s=n.selectionStart,o=n.selectionEnd,u=N,a=T.length-C,f=e,l=e.length-s,c=e.length-o,h=0;while(u>0&&T[h]==e[h])h++,u--;f=f.slice(h),h=1;while(a>0&&T.length-h>N-1&&T[T.length-h]==e[e.length-h])h++,a--;l-=h-1,c-=h-1;var p=f.length-h+1;p<0&&(u=-p,p=0),f=f.slice(0,p);if(!r&&!f&&!l&&!u&&!a&&!c)return"";w=!0;var d=!1;return i.isAndroid&&f==". "&&(f=" ",d=!0),f&&!u&&!a&&!l&&!c||S?t.onTextInput(f):t.onTextInput(f,{extendLeft:u,extendRight:a,restoreStart:l,restoreEnd:c}),w=!1,T=e,N=s,C=o,k=c,d?"\n":f},B=function(e){if(b)return z();if(e&&e.inputType){if(e.inputType=="historyUndo")return t.execCommand("undo");if(e.inputType=="historyRedo")return t.execCommand("redo")}var r=n.value,i=H(r,!0);(r.length>c+100||v.test(i)||m&&N<1&&N==C)&&O()},j=function(e,t,n){var r=e.clipboardData||window.clipboardData;if(!r||a)return;var i=f||n?"Text":"text/plain";try{return t?r.setData(i,t)!==!1:r.getData(i)}catch(e){if(!n)return j(e,t,!0)}},F=function(e,i){var s=t.getCopyText();if(!s)return r.preventDefault(e);j(e,s)?(d&&(O(s),g=s,setTimeout(function(){g=!1},10)),i?t.onCut():t.onCopy(),r.preventDefault(e)):(g=!0,n.value=s,n.select(),setTimeout(function(){g=!1,O(),i?t.onCut():t.onCopy()}))},I=function(e){F(e,!0)},q=function(e){F(e,!1)},R=function(e){var s=j(e);if(u.pasteCancelled())return;typeof s=="string"?(s&&t.onPaste(s,e),i.isIE&&setTimeout(O),r.preventDefault(e)):(n.value="",y=!0)};r.addCommandKeyListener(n,t.onCommandKey.bind(t),t),r.addListener(n,"select",_,t),r.addListener(n,"input",B,t),r.addListener(n,"cut",I,t),r.addListener(n,"copy",q,t),r.addListener(n,"paste",R,t),(!("oncut"in n)||!("oncopy"in n)||!("onpaste"in n))&&r.addListener(e,"keydown",function(e){if(i.isMac&&!e.metaKey||!e.ctrlKey)return;switch(e.keyCode){case 67:q(e);break;case 86:R(e);break;case 88:I(e)}},t);var U=function(e){if(b||!t.onCompositionStart||t.$readOnly)return;b={};if(S)return;e.data&&(b.useTextareaForIME=!1),setTimeout(z,0),t._signal("compositionStart"),t.on("mousedown",X);var r=t.getSelectionRange();r.end.row=r.start.row,r.end.column=r.start.column,b.markerRange=r,b.selectionStart=N,t.onCompositionStart(b),b.useTextareaForIME?(T=n.value="",N=0,C=0):(n.msGetInputContext&&(b.context=n.msGetInputContext()),n.getInputContext&&(b.context=n.getInputContext()))},z=function(){if(!b||!t.onCompositionUpdate||t.$readOnly)return;if(S)return X();if(b.useTextareaForIME)t.onCompositionUpdate(n.value);else{var e=n.value;H(e),b.markerRange&&(b.context&&(b.markerRange.start.column=b.selectionStart=b.context.compositionStartOffset),b.markerRange.end.column=b.markerRange.start.column+C-b.selectionStart+k)}},W=function(e){if(!t.onCompositionEnd||t.$readOnly)return;b=!1,t.onCompositionEnd(),t.off("mousedown",X),e&&B()},V=o.delayedCall(z,50).schedule.bind(null,null);r.addListener(n,"compositionstart",U,t),r.addListener(n,"compositionupdate",z,t),r.addListener(n,"keyup",$,t),r.addListener(n,"keydown",V,t),r.addListener(n,"compositionend",W,t),this.getElement=function(){return n},this.setCommandMode=function(e){S=e,n.readOnly=!1},this.setReadOnly=function(e){S||(n.readOnly=e)},this.setCopyWithEmptySelection=function(e){},this.onContextMenu=function(e){P=!0,O(),t._emit("nativecontextmenu",{target:t,domEvent:e}),this.moveToMouse(e,!0)},this.moveToMouse=function(e,o){E||(E=n.style.cssText),n.style.cssText=(o?"z-index:100000;":"")+(i.isIE?"opacity:0.1;":"")+"text-indent: -"+(N+C)*t.renderer.characterWidth*.5+"px;";var u=t.container.getBoundingClientRect(),a=s.computedStyle(t.container),f=u.top+(parseInt(a.borderTopWidth)||0),l=u.left+(parseInt(u.borderLeftWidth)||0),c=u.bottom-f-n.clientHeight-2,h=function(e){s.translate(n,e.clientX-l-2,Math.min(e.clientY-f-2,c))};h(e);if(e.type!="mousedown")return;t.renderer.$isMousePressed=!0,clearTimeout(J),i.isWin&&r.capture(t.container,h,K)},this.onContextMenuClose=K;var J,Q=function(e){t.textInput.onContextMenu(e),K()};r.addListener(n,"mouseup",Q,t),r.addListener(n,"mousedown",function(e){e.preventDefault(),K()},t),r.addListener(t.renderer.scroller,"contextmenu",Q,t),r.addListener(n,"contextmenu",Q,t),d&&G(e,t,n)};t.TextInput=g,t.$setUserAgentForTests=function(e,t){m=e,d=t}}),ace.define("ace/mouse/default_handlers",["require","exports","module","ace/lib/useragent"],function(e,t,n){"use strict";function o(e){e.$clickSelection=null;var t=e.editor;t.setDefaultHandler("mousedown",this.onMouseDown.bind(e)),t.setDefaultHandler("dblclick",this.onDoubleClick.bind(e)),t.setDefaultHandler("tripleclick",this.onTripleClick.bind(e)),t.setDefaultHandler("quadclick",this.onQuadClick.bind(e)),t.setDefaultHandler("mousewheel",this.onMouseWheel.bind(e));var n=["select","startSelect","selectEnd","selectAllEnd","selectByWordsEnd","selectByLinesEnd","dragWait","dragWaitEnd","focusWait"];n.forEach(function(t){e[t]=this[t]},this),e.selectByLines=this.extendSelectionBy.bind(e,"getLineRange"),e.selectByWords=this.extendSelectionBy.bind(e,"getWordRange")}function u(e,t,n,r){return Math.sqrt(Math.pow(n-e,2)+Math.pow(r-t,2))}function a(e,t){if(e.start.row==e.end.row)var n=2*t.column-e.start.column-e.end.column;else if(e.start.row==e.end.row-1&&!e.start.column&&!e.end.column)var n=t.column-4;else var n=2*t.row-e.start.row-e.end.row;return n<0?{cursor:e.start,anchor:e.end}:{cursor:e.end,anchor:e.start}}var r=e("../lib/useragent"),i=0,s=550;(function(){this.onMouseDown=function(e){var t=e.inSelection(),n=e.getDocumentPosition();this.mousedownEvent=e;var i=this.editor,s=e.getButton();if(s!==0){var o=i.getSelectionRange(),u=o.isEmpty();(u||s==1)&&i.selection.moveToPosition(n),s==2&&(i.textInput.onContextMenu(e.domEvent),r.isMozilla||e.preventDefault());return}this.mousedownEvent.time=Date.now();if(t&&!i.isFocused()){i.focus();if(this.$focusTimeout&&!this.$clickSelection&&!i.inMultiSelectMode){this.setState("focusWait"),this.captureMouse(e);return}}return this.captureMouse(e),this.startSelect(n,e.domEvent._clicks>1),e.preventDefault()},this.startSelect=function(e,t){e=e||this.editor.renderer.screenToTextCoordinates(this.x,this.y);var n=this.editor;if(!this.mousedownEvent)return;this.mousedownEvent.getShiftKey()?n.selection.selectToPosition(e):t||n.selection.moveToPosition(e),t||this.select(),n.renderer.scroller.setCapture&&n.renderer.scroller.setCapture(),n.setStyle("ace_selecting"),this.setState("select")},this.select=function(){var e,t=this.editor,n=t.renderer.screenToTextCoordinates(this.x,this.y);if(this.$clickSelection){var r=this.$clickSelection.comparePoint(n);if(r==-1)e=this.$clickSelection.end;else if(r==1)e=this.$clickSelection.start;else{var i=a(this.$clickSelection,n);n=i.cursor,e=i.anchor}t.selection.setSelectionAnchor(e.row,e.column)}t.selection.selectToPosition(n),t.renderer.scrollCursorIntoView()},this.extendSelectionBy=function(e){var t,n=this.editor,r=n.renderer.screenToTextCoordinates(this.x,this.y),i=n.selection[e](r.row,r.column);if(this.$clickSelection){var s=this.$clickSelection.comparePoint(i.start),o=this.$clickSelection.comparePoint(i.end);if(s==-1&&o<=0){t=this.$clickSelection.end;if(i.end.row!=r.row||i.end.column!=r.column)r=i.start}else if(o==1&&s>=0){t=this.$clickSelection.start;if(i.start.row!=r.row||i.start.column!=r.column)r=i.end}else if(s==-1&&o==1)r=i.end,t=i.start;else{var u=a(this.$clickSelection,r);r=u.cursor,t=u.anchor}n.selection.setSelectionAnchor(t.row,t.column)}n.selection.selectToPosition(r),n.renderer.scrollCursorIntoView()},this.selectEnd=this.selectAllEnd=this.selectByWordsEnd=this.selectByLinesEnd=function(){this.$clickSelection=null,this.editor.unsetStyle("ace_selecting"),this.editor.renderer.scroller.releaseCapture&&this.editor.renderer.scroller.releaseCapture()},this.focusWait=function(){var e=u(this.mousedownEvent.x,this.mousedownEvent.y,this.x,this.y),t=Date.now();(e>i||t-this.mousedownEvent.time>this.$focusTimeout)&&this.startSelect(this.mousedownEvent.getDocumentPosition())},this.onDoubleClick=function(e){var t=e.getDocumentPosition(),n=this.editor,r=n.session,i=r.getBracketRange(t);i?(i.isEmpty()&&(i.start.column--,i.end.column++),this.setState("select")):(i=n.selection.getWordRange(t.row,t.column),this.setState("selectByWords")),this.$clickSelection=i,this.select()},this.onTripleClick=function(e){var t=e.getDocumentPosition(),n=this.editor;this.setState("selectByLines");var r=n.getSelectionRange();r.isMultiLine()&&r.contains(t.row,t.column)?(this.$clickSelection=n.selection.getLineRange(r.start.row),this.$clickSelection.end=n.selection.getLineRange(r.end.row).end):this.$clickSelection=n.selection.getLineRange(t.row),this.select()},this.onQuadClick=function(e){var t=this.editor;t.selectAll(),this.$clickSelection=t.getSelectionRange(),this.setState("selectAll")},this.onMouseWheel=function(e){if(e.getAccelKey())return;e.getShiftKey()&&e.wheelY&&!e.wheelX&&(e.wheelX=e.wheelY,e.wheelY=0);var t=this.editor;this.$lastScroll||(this.$lastScroll={t:0,vx:0,vy:0,allowed:0});var n=this.$lastScroll,r=e.domEvent.timeStamp,i=r-n.t,o=i?e.wheelX/i:n.vx,u=i?e.wheelY/i:n.vy;i<s&&(o=(o+n.vx)/2,u=(u+n.vy)/2);var a=Math.abs(o/u),f=!1;a>=1&&t.renderer.isScrollableBy(e.wheelX*e.speed,0)&&(f=!0),a<=1&&t.renderer.isScrollableBy(0,e.wheelY*e.speed)&&(f=!0);if(f)n.allowed=r;else if(r-n.allowed<s){var l=Math.abs(o)<=1.5*Math.abs(n.vx)&&Math.abs(u)<=1.5*Math.abs(n.vy);l?(f=!0,n.allowed=r):n.allowed=0}n.t=r,n.vx=o,n.vy=u;if(f)return t.renderer.scrollBy(e.wheelX*e.speed,e.wheelY*e.speed),e.stop()}}).call(o.prototype),t.DefaultHandlers=o}),ace.define("ace/tooltip",["require","exports","module","ace/lib/oop","ace/lib/dom"],function(e,t,n){"use strict";function s(e){this.isOpen=!1,this.$element=null,this.$parentNode=e}var r=e("./lib/oop"),i=e("./lib/dom");(function(){this.$init=function(){return this.$element=i.createElement("div"),this.$element.className="ace_tooltip",this.$element.style.display="none",this.$parentNode.appendChild(this.$element),this.$element},this.getElement=function(){return this.$element||this.$init()},this.setText=function(e){this.getElement().textContent=e},this.setHtml=function(e){this.getElement().innerHTML=e},this.setPosition=function(e,t){this.getElement().style.left=e+"px",this.getElement().style.top=t+"px"},this.setClassName=function(e){i.addCssClass(this.getElement(),e)},this.show=function(e,t,n){e!=null&&this.setText(e),t!=null&&n!=null&&this.setPosition(t,n),this.isOpen||(this.getElement().style.display="block",this.isOpen=!0)},this.hide=function(){this.isOpen&&(this.getElement().style.display="none",this.isOpen=!1)},this.getHeight=function(){return this.getElement().offsetHeight},this.getWidth=function(){return this.getElement().offsetWidth},this.destroy=function(){this.isOpen=!1,this.$element&&this.$element.parentNode&&this.$element.parentNode.removeChild(this.$element)}}).call(s.prototype),t.Tooltip=s}),ace.define("ace/mouse/default_gutter_handler",["require","exports","module","ace/lib/dom","ace/lib/oop","ace/lib/event","ace/tooltip"],function(e,t,n){"use strict";function u(e){function l(){var r=u.getDocumentPosition().row,s=n.$annotations[r];if(!s)return c();var o=t.session.getLength();if(r==o){var a=t.renderer.pixelToScreenCoordinates(0,u.y).row,l=u.$pos;if(a>t.session.documentToScreenRow(l.row,l.column))return c()}if(f==s)return;f=s.text.join("<br/>"),i.setHtml(f),i.show(),t._signal("showGutterTooltip",i),t.on("mousewheel",c);if(e.$tooltipFollowsMouse)h(u);else{var p=u.domEvent.target,d=p.getBoundingClientRect(),v=i.getElement().style;v.left=d.right+"px",v.top=d.bottom+"px"}}function c(){o&&(o=clearTimeout(o)),f&&(i.hide(),f=null,t._signal("hideGutterTooltip",i),t.off("mousewheel",c))}function h(e){i.setPosition(e.x,e.y)}var t=e.editor,n=t.renderer.$gutterLayer,i=new a(t.container);e.editor.setDefaultHandler("guttermousedown",function(r){if(!t.isFocused()||r.getButton()!=0)return;var i=n.getRegion(r);if(i=="foldWidgets")return;var s=r.getDocumentPosition().row,o=t.session.selection;if(r.getShiftKey())o.selectTo(s,0);else{if(r.domEvent.detail==2)return t.selectAll(),r.preventDefault();e.$clickSelection=t.selection.getLineRange(s)}return e.setState("selectByLines"),e.captureMouse(r),r.preventDefault()});var o,u,f;e.editor.setDefaultHandler("guttermousemove",function(t){var n=t.domEvent.target||t.domEvent.srcElement;if(r.hasCssClass(n,"ace_fold-widget"))return c();f&&e.$tooltipFollowsMouse&&h(t),u=t;if(o)return;o=setTimeout(function(){o=null,u&&!e.isMousePressed?l():c()},50)}),s.addListener(t.renderer.$gutter,"mouseout",function(e){u=null;if(!f||o)return;o=setTimeout(function(){o=null,c()},50)},t),t.on("changeSession",c)}function a(e){o.call(this,e)}var r=e("../lib/dom"),i=e("../lib/oop"),s=e("../lib/event"),o=e("../tooltip").Tooltip;i.inherits(a,o),function(){this.setPosition=function(e,t){var n=window.innerWidth||document.documentElement.clientWidth,r=window.innerHeight||document.documentElement.clientHeight,i=this.getWidth(),s=this.getHeight();e+=15,t+=15,e+i>n&&(e-=e+i-n),t+s>r&&(t-=20+s),o.prototype.setPosition.call(this,e,t)}}.call(a.prototype),t.GutterHandler=u}),ace.define("ace/mouse/mouse_event",["require","exports","module","ace/lib/event","ace/lib/useragent"],function(e,t,n){"use strict";var r=e("../lib/event"),i=e("../lib/useragent"),s=t.MouseEvent=function(e,t){this.domEvent=e,this.editor=t,this.x=this.clientX=e.clientX,this.y=this.clientY=e.clientY,this.$pos=null,this.$inSelection=null,this.propagationStopped=!1,this.defaultPrevented=!1};(function(){this.stopPropagation=function(){r.stopPropagation(this.domEvent),this.propagationStopped=!0},this.preventDefault=function(){r.preventDefault(this.domEvent),this.defaultPrevented=!0},this.stop=function(){this.stopPropagation(),this.preventDefault()},this.getDocumentPosition=function(){return this.$pos?this.$pos:(this.$pos=this.editor.renderer.screenToTextCoordinates(this.clientX,this.clientY),this.$pos)},this.inSelection=function(){if(this.$inSelection!==null)return this.$inSelection;var e=this.editor,t=e.getSelectionRange();if(t.isEmpty())this.$inSelection=!1;else{var n=this.getDocumentPosition();this.$inSelection=t.contains(n.row,n.column)}return this.$inSelection},this.getButton=function(){return r.getButton(this.domEvent)},this.getShiftKey=function(){return this.domEvent.shiftKey},this.getAccelKey=i.isMac?function(){return this.domEvent.metaKey}:function(){return this.domEvent.ctrlKey}}).call(s.prototype)}),ace.define("ace/mouse/dragdrop_handler",["require","exports","module","ace/lib/dom","ace/lib/event","ace/lib/useragent"],function(e,t,n){"use strict";function f(e){function T(e,n){var r=Date.now(),i=!n||e.row!=n.row,s=!n||e.column!=n.column;if(!S||i||s)t.moveCursorToPosition(e),S=r,x={x:p,y:d};else{var o=l(x.x,x.y,p,d);o>a?S=null:r-S>=u&&(t.renderer.scrollCursorIntoView(),S=null)}}function N(e,n){var r=Date.now(),i=t.renderer.layerConfig.lineHeight,s=t.renderer.layerConfig.characterWidth,u=t.renderer.scroller.getBoundingClientRect(),a={x:{left:p-u.left,right:u.right-p},y:{top:d-u.top,bottom:u.bottom-d}},f=Math.min(a.x.left,a.x.right),l=Math.min(a.y.top,a.y.bottom),c={row:e.row,column:e.column};f/s<=2&&(c.column+=a.x.left<a.x.right?-3:2),l/i<=1&&(c.row+=a.y.top<a.y.bottom?-1:1);var h=e.row!=c.row,v=e.column!=c.column,m=!n||e.row!=n.row;h||v&&!m?E?r-E>=o&&t.renderer.scrollCursorIntoView(c):E=r:E=null}function C(){var e=g;g=t.renderer.screenToTextCoordinates(p,d),T(g,e),N(g,e)}function k(){m=t.selection.toOrientedRange(),h=t.session.addMarker(m,"ace_selection",t.getSelectionStyle()),t.clearSelection(),t.isFocused()&&t.renderer.$cursorLayer.setBlinking(!1),clearInterval(v),C(),v=setInterval(C,20),y=0,i.addListener(document,"mousemove",O)}function L(){clearInterval(v),t.session.removeMarker(h),h=null,t.selection.fromOrientedRange(m),t.isFocused()&&!w&&t.$resetCursorStyle(),m=null,g=null,y=0,E=null,S=null,i.removeListener(document,"mousemove",O)}function O(){A==null&&(A=setTimeout(function(){A!=null&&h&&L()},20))}function M(e){var t=e.types;return!t||Array.prototype.some.call(t,function(e){return e=="text/plain"||e=="Text"})}function _(e){var t=["copy","copymove","all","uninitialized"],n=["move","copymove","linkmove","all","uninitialized"],r=s.isMac?e.altKey:e.ctrlKey,i="uninitialized";try{i=e.dataTransfer.effectAllowed.toLowerCase()}catch(e){}var o="none";return r&&t.indexOf(i)>=0?o="copy":n.indexOf(i)>=0?o="move":t.indexOf(i)>=0&&(o="copy"),o}var t=e.editor,n=r.createElement("img");n.src="data:image/gif;base64,R0lGODlhAQABAAAAACH5BAEKAAEALAAAAAABAAEAAAICTAEAOw==",s.isOpera&&(n.style.cssText="width:1px;height:1px;position:fixed;top:0;left:0;z-index:2147483647;opacity:0;");var f=["dragWait","dragWaitEnd","startDrag","dragReadyEnd","onMouseDrag"];f.forEach(function(t){e[t]=this[t]},this),t.on("mousedown",this.onMouseDown.bind(e));var c=t.container,h,p,d,v,m,g,y=0,b,w,E,S,x;this.onDragStart=function(e){if(this.cancelDrag||!c.draggable){var r=this;return setTimeout(function(){r.startSelect(),r.captureMouse(e)},0),e.preventDefault()}m=t.getSelectionRange();var i=e.dataTransfer;i.effectAllowed=t.getReadOnly()?"copy":"copyMove",s.isOpera&&(t.container.appendChild(n),n.scrollTop=0),i.setDragImage&&i.setDragImage(n,0,0),s.isOpera&&t.container.removeChild(n),i.clearData(),i.setData("Text",t.session.getTextRange()),w=!0,this.setState("drag")},this.onDragEnd=function(e){c.draggable=!1,w=!1,this.setState(null);if(!t.getReadOnly()){var n=e.dataTransfer.dropEffect;!b&&n=="move"&&t.session.remove(t.getSelectionRange()),t.$resetCursorStyle()}this.editor.unsetStyle("ace_dragging"),this.editor.renderer.setCursorStyle("")},this.onDragEnter=function(e){if(t.getReadOnly()||!M(e.dataTransfer))return;return p=e.clientX,d=e.clientY,h||k(),y++,e.dataTransfer.dropEffect=b=_(e),i.preventDefault(e)},this.onDragOver=function(e){if(t.getReadOnly()||!M(e.dataTransfer))return;return p=e.clientX,d=e.clientY,h||(k(),y++),A!==null&&(A=null),e.dataTransfer.dropEffect=b=_(e),i.preventDefault(e)},this.onDragLeave=function(e){y--;if(y<=0&&h)return L(),b=null,i.preventDefault(e)},this.onDrop=function(e){if(!g)return;var n=e.dataTransfer;if(w)switch(b){case"move":m.contains(g.row,g.column)?m={start:g,end:g}:m=t.moveText(m,g);break;case"copy":m=t.moveText(m,g,!0)}else{var r=n.getData("Text");m={start:g,end:t.session.insert(g,r)},t.focus(),b=null}return L(),i.preventDefault(e)},i.addListener(c,"dragstart",this.onDragStart.bind(e),t),i.addListener(c,"dragend",this.onDragEnd.bind(e),t),i.addListener(c,"dragenter",this.onDragEnter.bind(e),t),i.addListener(c,"dragover",this.onDragOver.bind(e),t),i.addListener(c,"dragleave",this.onDragLeave.bind(e),t),i.addListener(c,"drop",this.onDrop.bind(e),t);var A=null}function l(e,t,n,r){return Math.sqrt(Math.pow(n-e,2)+Math.pow(r-t,2))}var r=e("../lib/dom"),i=e("../lib/event"),s=e("../lib/useragent"),o=200,u=200,a=5;(function(){this.dragWait=function(){var e=Date.now()-this.mousedownEvent.time;e>this.editor.getDragDelay()&&this.startDrag()},this.dragWaitEnd=function(){var e=this.editor.container;e.draggable=!1,this.startSelect(this.mousedownEvent.getDocumentPosition()),this.selectEnd()},this.dragReadyEnd=function(e){this.editor.$resetCursorStyle(),this.editor.unsetStyle("ace_dragging"),this.editor.renderer.setCursorStyle(""),this.dragWaitEnd()},this.startDrag=function(){this.cancelDrag=!1;var e=this.editor,t=e.container;t.draggable=!0,e.renderer.$cursorLayer.setBlinking(!1),e.setStyle("ace_dragging");var n=s.isWin?"default":"move";e.renderer.setCursorStyle(n),this.setState("dragReady")},this.onMouseDrag=function(e){var t=this.editor.container;if(s.isIE&&this.state=="dragReady"){var n=l(this.mousedownEvent.x,this.mousedownEvent.y,this.x,this.y);n>3&&t.dragDrop()}if(this.state==="dragWait"){var n=l(this.mousedownEvent.x,this.mousedownEvent.y,this.x,this.y);n>0&&(t.draggable=!1,this.startSelect(this.mousedownEvent.getDocumentPosition()))}},this.onMouseDown=function(e){if(!this.$dragEnabled)return;this.mousedownEvent=e;var t=this.editor,n=e.inSelection(),r=e.getButton(),i=e.domEvent.detail||1;if(i===1&&r===0&&n){if(e.editor.inMultiSelectMode&&(e.getAccelKey()||e.getShiftKey()))return;this.mousedownEvent.time=Date.now();var o=e.domEvent.target||e.domEvent.srcElement;"unselectable"in o&&(o.unselectable="on");if(t.getDragDelay()){if(s.isWebKit){this.cancelDrag=!0;var u=t.container;u.draggable=!0}this.setState("dragWait")}else this.startDrag();this.captureMouse(e,this.onMouseDrag.bind(this)),e.defaultPrevented=!0}}}).call(f.prototype),t.DragdropHandler=f}),ace.define("ace/mouse/touch_handler",["require","exports","module","ace/mouse/mouse_event","ace/lib/event","ace/lib/dom"],function(e,t,n){"use strict";var r=e("./mouse_event").MouseEvent,i=e("../lib/event"),s=e("../lib/dom");t.addTouchListeners=function(e,t){function b(){var e=window.navigator&&window.navigator.clipboard,r=!1,i=function(){var n=t.getCopyText(),i=t.session.getUndoManager().hasUndo();y.replaceChild(s.buildDom(r?["span",!n&&["span",{"class":"ace_mobile-button",action:"selectall"},"Select All"],n&&["span",{"class":"ace_mobile-button",action:"copy"},"Copy"],n&&["span",{"class":"ace_mobile-button",action:"cut"},"Cut"],e&&["span",{"class":"ace_mobile-button",action:"paste"},"Paste"],i&&["span",{"class":"ace_mobile-button",action:"undo"},"Undo"],["span",{"class":"ace_mobile-button",action:"find"},"Find"],["span",{"class":"ace_mobile-button",action:"openCommandPallete"},"Pallete"]]:["span"]),y.firstChild)},o=function(n){var s=n.target.getAttribute("action");if(s=="more"||!r)return r=!r,i();if(s=="paste")e.readText().then(function(e){t.execCommand(s,e)});else if(s){if(s=="cut"||s=="copy")e?e.writeText(t.getCopyText()):document.execCommand("copy");t.execCommand(s)}y.firstChild.style.display="none",r=!1,s!="openCommandPallete"&&t.focus()};y=s.buildDom(["div",{"class":"ace_mobile-menu",ontouchstart:function(e){n="menu",e.stopPropagation(),e.preventDefault(),t.textInput.focus()},ontouchend:function(e){e.stopPropagation(),e.preventDefault(),o(e)},onclick:o},["span"],["span",{"class":"ace_mobile-button",action:"more"},"..."]],t.container)}function w(){y||b();var e=t.selection.cursor,n=t.renderer.textToScreenCoordinates(e.row,e.column),r=t.renderer.textToScreenCoordinates(0,0).pageX,i=t.renderer.scrollLeft,s=t.container.getBoundingClientRect();y.style.top=n.pageY-s.top-3+"px",n.pageX-s.left<s.width-70?(y.style.left="",y.style.right="10px"):(y.style.right="",y.style.left=r+i-s.left+"px"),y.style.display="",y.firstChild.style.display="none",t.on("input",E)}function E(e){y&&(y.style.display="none"),t.off("input",E)}function S(){l=null,clearTimeout(l);var e=t.selection.getRange(),r=e.contains(p.row,p.column);if(e.isEmpty()||!r)t.selection.moveToPosition(p),t.selection.selectWord();n="wait",w()}function x(){l=null,clearTimeout(l),t.selection.moveToPosition(p);var e=d>=2?t.selection.getLineRange(p.row):t.session.getBracketRange(p);e&&!e.isEmpty()?t.selection.setRange(e):t.selection.selectWord(),n="wait"}function T(){h+=60,c=setInterval(function(){h--<=0&&(clearInterval(c),c=null),Math.abs(v)<.01&&(v=0),Math.abs(m)<.01&&(m=0),h<20&&(v=.9*v),h<20&&(m=.9*m);var e=t.session.getScrollTop();t.renderer.scrollBy(10*v,10*m),e==t.session.getScrollTop()&&(h=0)},10)}var n="scroll",o,u,a,f,l,c,h=0,p,d=0,v=0,m=0,g,y;i.addListener(e,"contextmenu",function(e){if(!g)return;var n=t.textInput.getElement();n.focus()},t),i.addListener(e,"touchstart",function(e){var i=e.touches;if(l||i.length>1){clearTimeout(l),l=null,a=-1,n="zoom";return}g=t.$mouseHandler.isMousePressed=!0;var s=t.renderer.layerConfig.lineHeight,c=t.renderer.layerConfig.lineHeight,y=e.timeStamp;f=y;var b=i[0],w=b.clientX,E=b.clientY;Math.abs(o-w)+Math.abs(u-E)>s&&(a=-1),o=e.clientX=w,u=e.clientY=E,v=m=0;var T=new r(e,t);p=T.getDocumentPosition();if(y-a<500&&i.length==1&&!h)d++,e.preventDefault(),e.button=0,x();else{d=0;var N=t.selection.cursor,C=t.selection.isEmpty()?N:t.selection.anchor,k=t.renderer.$cursorLayer.getPixelPosition(N,!0),L=t.renderer.$cursorLayer.getPixelPosition(C,!0),A=t.renderer.scroller.getBoundingClientRect(),O=t.renderer.layerConfig.offset,M=t.renderer.scrollLeft,_=function(e,t){return e/=c,t=t/s-.75,e*e+t*t};if(e.clientX<A.left){n="zoom";return}var D=_(e.clientX-A.left-k.left+M,e.clientY-A.top-k.top+O),P=_(e.clientX-A.left-L.left+M,e.clientY-A.top-L.top+O);D<3.5&&P<3.5&&(n=D>P?"cursor":"anchor"),P<3.5?n="anchor":D<3.5?n="cursor":n="scroll",l=setTimeout(S,450)}a=y},t),i.addListener(e,"touchend",function(e){g=t.$mouseHandler.isMousePressed=!1,c&&clearInterval(c),n=="zoom"?(n="",h=0):l?(t.selection.moveToPosition(p),h=0,w()):n=="scroll"?(T(),E()):w(),clearTimeout(l),l=null},t),i.addListener(e,"touchmove",function(e){l&&(clearTimeout(l),l=null);var i=e.touches;if(i.length>1||n=="zoom")return;var s=i[0],a=o-s.clientX,c=u-s.clientY;if(n=="wait"){if(!(a*a+c*c>4))return e.preventDefault();n="cursor"}o=s.clientX,u=s.clientY,e.clientX=s.clientX,e.clientY=s.clientY;var h=e.timeStamp,p=h-f;f=h;if(n=="scroll"){var d=new r(e,t);d.speed=1,d.wheelX=a,d.wheelY=c,10*Math.abs(a)<Math.abs(c)&&(a=0),10*Math.abs(c)<Math.abs(a)&&(c=0),p!=0&&(v=a/p,m=c/p),t._emit("mousewheel",d),d.propagationStopped||(v=m=0)}else{var g=new r(e,t),y=g.getDocumentPosition();n=="cursor"?t.selection.moveCursorToPosition(y):n=="anchor"&&t.selection.setSelectionAnchor(y.row,y.column),t.renderer.scrollCursorIntoView(y),e.preventDefault()}},t)}}),ace.define("ace/lib/net",["require","exports","module","ace/lib/dom"],function(e,t,n){"use strict";var r=e("./dom");t.get=function(e,t){var n=new XMLHttpRequest;n.open("GET",e,!0),n.onreadystatechange=function(){n.readyState===4&&t(n.responseText)},n.send(null)},t.loadScript=function(e,t){var n=r.getDocumentHead(),i=document.createElement("script");i.src=e,n.appendChild(i),i.onload=i.onreadystatechange=function(e,n){if(n||!i.readyState||i.readyState=="loaded"||i.readyState=="complete")i=i.onload=i.onreadystatechange=null,n||t()}},t.qualifyURL=function(e){var t=document.createElement("a");return t.href=e,t.href}}),ace.define("ace/lib/event_emitter",["require","exports","module"],function(e,t,n){"use strict";var r={},i=function(){this.propagationStopped=!0},s=function(){this.defaultPrevented=!0};r._emit=r._dispatchEvent=function(e,t){this._eventRegistry||(this._eventRegistry={}),this._defaultHandlers||(this._defaultHandlers={});var n=this._eventRegistry[e]||[],r=this._defaultHandlers[e];if(!n.length&&!r)return;if(typeof t!="object"||!t)t={};t.type||(t.type=e),t.stopPropagation||(t.stopPropagation=i),t.preventDefault||(t.preventDefault=s),n=n.slice();for(var o=0;o<n.length;o++){n[o](t,this);if(t.propagationStopped)break}if(r&&!t.defaultPrevented)return r(t,this)},r._signal=function(e,t){var n=(this._eventRegistry||{})[e];if(!n)return;n=n.slice();for(var r=0;r<n.length;r++)n[r](t,this)},r.once=function(e,t){var n=this;this.on(e,function r(){n.off(e,r),t.apply(null,arguments)});if(!t)return new Promise(function(e){t=e})},r.setDefaultHandler=function(e,t){var n=this._defaultHandlers;n||(n=this._defaultHandlers={_disabled_:{}});if(n[e]){var r=n[e],i=n._disabled_[e];i||(n._disabled_[e]=i=[]),i.push(r);var s=i.indexOf(t);s!=-1&&i.splice(s,1)}n[e]=t},r.removeDefaultHandler=function(e,t){var n=this._defaultHandlers;if(!n)return;var r=n._disabled_[e];if(n[e]==t)r&&this.setDefaultHandler(e,r.pop());else if(r){var i=r.indexOf(t);i!=-1&&r.splice(i,1)}},r.on=r.addEventListener=function(e,t,n){this._eventRegistry=this._eventRegistry||{};var r=this._eventRegistry[e];return r||(r=this._eventRegistry[e]=[]),r.indexOf(t)==-1&&r[n?"unshift":"push"](t),t},r.off=r.removeListener=r.removeEventListener=function(e,t){this._eventRegistry=this._eventRegistry||{};var n=this._eventRegistry[e];if(!n)return;var r=n.indexOf(t);r!==-1&&n.splice(r,1)},r.removeAllListeners=function(e){e||(this._eventRegistry=this._defaultHandlers=undefined),this._eventRegistry&&(this._eventRegistry[e]=undefined),this._defaultHandlers&&(this._defaultHandlers[e]=undefined)},t.EventEmitter=r}),ace.define("ace/lib/app_config",["require","exports","module","ace/lib/oop","ace/lib/event_emitter"],function(e,t,n){"no use strict";function o(e){typeof console!="undefined"&&console.warn&&console.warn.apply(console,arguments)}function u(e,t){var n=new Error(e);n.data=t,typeof console=="object"&&console.error&&console.error(n),setTimeout(function(){throw n})}var r=e("./oop"),i=e("./event_emitter").EventEmitter,s={setOptions:function(e){Object.keys(e).forEach(function(t){this.setOption(t,e[t])},this)},getOptions:function(e){var t={};if(!e){var n=this.$options;e=Object.keys(n).filter(function(e){return!n[e].hidden})}else Array.isArray(e)||(t=e,e=Object.keys(t));return e.forEach(function(e){t[e]=this.getOption(e)},this),t},setOption:function(e,t){if(this["$"+e]===t)return;var n=this.$options[e];if(!n)return o('misspelled option "'+e+'"');if(n.forwardTo)return this[n.forwardTo]&&this[n.forwardTo].setOption(e,t);n.handlesSet||(this["$"+e]=t),n&&n.set&&n.set.call(this,t)},getOption:function(e){var t=this.$options[e];return t?t.forwardTo?this[t.forwardTo]&&this[t.forwardTo].getOption(e):t&&t.get?t.get.call(this):this["$"+e]:o('misspelled option "'+e+'"')}},a=function(){this.$defaultOptions={}};(function(){r.implement(this,i),this.defineOptions=function(e,t,n){return e.$options||(this.$defaultOptions[t]=e.$options={}),Object.keys(n).forEach(function(t){var r=n[t];typeof r=="string"&&(r={forwardTo:r}),r.name||(r.name=t),e.$options[r.name]=r,"initialValue"in r&&(e["$"+r.name]=r.initialValue)}),r.implement(e,s),this},this.resetOptions=function(e){Object.keys(e.$options).forEach(function(t){var n=e.$options[t];"value"in n&&e.setOption(t,n.value)})},this.setDefaultValue=function(e,t,n){if(!e){for(e in this.$defaultOptions)if(this.$defaultOptions[e][t])break;if(!this.$defaultOptions[e][t])return!1}var r=this.$defaultOptions[e]||(this.$defaultOptions[e]={});r[t]&&(r.forwardTo?this.setDefaultValue(r.forwardTo,t,n):r[t].value=n)},this.setDefaultValues=function(e,t){Object.keys(t).forEach(function(n){this.setDefaultValue(e,n,t[n])},this)},this.warn=o,this.reportError=u}).call(a.prototype),t.AppConfig=a}),ace.define("ace/config",["require","exports","module","ace/lib/lang","ace/lib/oop","ace/lib/net","ace/lib/app_config"],function(e,t,n){"no use strict";function l(r){if(!u||!u.document)return;a.packaged=r||e.packaged||n.packaged||u.define&&define.packaged;var i={},s="",o=document.currentScript||document._currentScript,f=o&&o.ownerDocument||document,l=f.getElementsByTagName("script");for(var h=0;h<l.length;h++){var p=l[h],d=p.src||p.getAttribute("src");if(!d)continue;var v=p.attributes;for(var m=0,g=v.length;m<g;m++){var y=v[m];y.name.indexOf("data-ace-")===0&&(i[c(y.name.replace(/^data-ace-/,""))]=y.value)}var b=d.match(/^(.*)\/ace(\-\w+)?\.js(\?|$)/);b&&(s=b[1])}s&&(i.base=i.base||s,i.packaged=!0),i.basePath=i.base,i.workerPath=i.workerPath||i.base,i.modePath=i.modePath||i.base,i.themePath=i.themePath||i.base,delete i.base;for(var w in i)typeof i[w]!="undefined"&&t.set(w,i[w])}function c(e){return e.replace(/-(.)/g,function(e,t){return t.toUpperCase()})}var r=e("./lib/lang"),i=e("./lib/oop"),s=e("./lib/net"),o=e("./lib/app_config").AppConfig;n.exports=t=new o;var u=function(){return this||typeof window!="undefined"&&window}(),a={packaged:!1,workerPath:null,modePath:null,themePath:null,basePath:"",suffix:".js",$moduleUrls:{},loadWorkerFromBlob:!0,sharedPopups:!1};t.get=function(e){if(!a.hasOwnProperty(e))throw new Error("Unknown config key: "+e);return a[e]},t.set=function(e,t){if(a.hasOwnProperty(e))a[e]=t;else if(this.setDefaultValue("",e,t)==0)throw new Error("Unknown config key: "+e)},t.all=function(){return r.copyObject(a)},t.$modes={},t.moduleUrl=function(e,t){if(a.$moduleUrls[e])return a.$moduleUrls[e];var n=e.split("/");t=t||n[n.length-2]||"";var r=t=="snippets"?"/":"-",i=n[n.length-1];if(t=="worker"&&r=="-"){var s=new RegExp("^"+t+"[\\-_]|[\\-_]"+t+"$","g");i=i.replace(s,"")}(!i||i==t)&&n.length>1&&(i=n[n.length-2]);var o=a[t+"Path"];return o==null?o=a.basePath:r=="/"&&(t=r=""),o&&o.slice(-1)!="/"&&(o+="/"),o+t+r+i+this.get("suffix")},t.setModuleUrl=function(e,t){return a.$moduleUrls[e]=t},t.$loading={},t.loadModule=function(n,r){var i,o;Array.isArray(n)&&(o=n[0],n=n[1]);try{i=e(n)}catch(u){}if(i&&!t.$loading[n])return r&&r(i);t.$loading[n]||(t.$loading[n]=[]),t.$loading[n].push(r);if(t.$loading[n].length>1)return;var a=function(){e([n],function(e){t._emit("load.module",{name:n,module:e});var r=t.$loading[n];t.$loading[n]=null,r.forEach(function(t){t&&t(e)})})};if(!t.get("packaged"))return a();s.loadScript(t.moduleUrl(n,o),a),f()};var f=function(){!a.basePath&&!a.workerPath&&!a.modePath&&!a.themePath&&!Object.keys(a.$moduleUrls).length&&(console.error("Unable to infer path to ace from script src,","use ace.config.set('basePath', 'path') to enable dynamic loading of modes and themes","or with webpack use ace/webpack-resolver"),f=function(){})};t.init=l,t.version="1.4.12"}),ace.define("ace/mouse/mouse_handler",["require","exports","module","ace/lib/event","ace/lib/useragent","ace/mouse/default_handlers","ace/mouse/default_gutter_handler","ace/mouse/mouse_event","ace/mouse/dragdrop_handler","ace/mouse/touch_handler","ace/config"],function(e,t,n){"use strict";var r=e("../lib/event"),i=e("../lib/useragent"),s=e("./default_handlers").DefaultHandlers,o=e("./default_gutter_handler").GutterHandler,u=e("./mouse_event").MouseEvent,a=e("./dragdrop_handler").DragdropHandler,f=e("./touch_handler").addTouchListeners,l=e("../config"),c=function(e){var t=this;this.editor=e,new s(this),new o(this),new a(this);var n=function(t){var n=!document.hasFocus||!document.hasFocus()||!e.isFocused()&&document.activeElement==(e.textInput&&e.textInput.getElement());n&&window.focus(),e.focus()},u=e.renderer.getMouseEventTarget();r.addListener(u,"click",this.onMouseEvent.bind(this,"click"),e),r.addListener(u,"mousemove",this.onMouseMove.bind(this,"mousemove"),e),r.addMultiMouseDownListener([u,e.renderer.scrollBarV&&e.renderer.scrollBarV.inner,e.renderer.scrollBarH&&e.renderer.scrollBarH.inner,e.textInput&&e.textInput.getElement()].filter(Boolean),[400,300,250],this,"onMouseEvent",e),r.addMouseWheelListener(e.container,this.onMouseWheel.bind(this,"mousewheel"),e),f(e.container,e);var l=e.renderer.$gutter;r.addListener(l,"mousedown",this.onMouseEvent.bind(this,"guttermousedown"),e),r.addListener(l,"click",this.onMouseEvent.bind(this,"gutterclick"),e),r.addListener(l,"dblclick",this.onMouseEvent.bind(this,"gutterdblclick"),e),r.addListener(l,"mousemove",this.onMouseEvent.bind(this,"guttermousemove"),e),r.addListener(u,"mousedown",n,e),r.addListener(l,"mousedown",n,e),i.isIE&&e.renderer.scrollBarV&&(r.addListener(e.renderer.scrollBarV.element,"mousedown",n,e),r.addListener(e.renderer.scrollBarH.element,"mousedown",n,e)),e.on("mousemove",function(n){if(t.state||t.$dragDelay||!t.$dragEnabled)return;var r=e.renderer.screenToTextCoordinates(n.x,n.y),i=e.session.selection.getRange(),s=e.renderer;!i.isEmpty()&&i.insideStart(r.row,r.column)?s.setCursorStyle("default"):s.setCursorStyle("")},e)};(function(){this.onMouseEvent=function(e,t){this.editor._emit(e,new u(t,this.editor))},this.onMouseMove=function(e,t){var n=this.editor._eventRegistry&&this.editor._eventRegistry.mousemove;if(!n||!n.length)return;this.editor._emit(e,new u(t,this.editor))},this.onMouseWheel=function(e,t){var n=new u(t,this.editor);n.speed=this.$scrollSpeed*2,n.wheelX=t.wheelX,n.wheelY=t.wheelY,this.editor._emit(e,n)},this.setState=function(e){this.state=e},this.captureMouse=function(e,t){this.x=e.x,this.y=e.y,this.isMousePressed=!0;var n=this.editor,s=this.editor.renderer;s.$isMousePressed=!0;var o=this,a=function(e){if(!e)return;if(i.isWebKit&&!e.which&&o.releaseMouse)return o.releaseMouse();o.x=e.clientX,o.y=e.clientY,t&&t(e),o.mouseEvent=new u(e,o.editor),o.$mouseMoved=!0},f=function(e){n.off("beforeEndOperation",c),clearInterval(h),l(),o[o.state+"End"]&&o[o.state+"End"](e),o.state="",o.isMousePressed=s.$isMousePressed=!1,s.$keepTextAreaAtCursor&&s.$moveTextAreaToCursor(),o.$onCaptureMouseMove=o.releaseMouse=null,e&&o.onMouseEvent("mouseup",e),n.endOperation()},l=function(){o[o.state]&&o[o.state](),o.$mouseMoved=!1};if(i.isOldIE&&e.domEvent.type=="dblclick")return setTimeout(function(){f(e)});var c=function(e){if(!o.releaseMouse)return;n.curOp.command.name&&n.curOp.selectionChanged&&(o[o.state+"End"]&&o[o.state+"End"](),o.state="",o.releaseMouse())};n.on("beforeEndOperation",c),n.startOperation({command:{name:"mouse"}}),o.$onCaptureMouseMove=a,o.releaseMouse=r.capture(this.editor.container,a,f);var h=setInterval(l,20)},this.releaseMouse=null,this.cancelContextMenu=function(){var e=function(t){if(t&&t.domEvent&&t.domEvent.type!="contextmenu")return;this.editor.off("nativecontextmenu",e),t&&t.domEvent&&r.stopEvent(t.domEvent)}.bind(this);setTimeout(e,10),this.editor.on("nativecontextmenu",e)},this.destroy=function(){this.releaseMouse&&this.releaseMouse()}}).call(c.prototype),l.defineOptions(c.prototype,"mouseHandler",{scrollSpeed:{initialValue:2},dragDelay:{initialValue:i.isMac?150:0},dragEnabled:{initialValue:!0},focusTimeout:{initialValue:0},tooltipFollowsMouse:{initialValue:!0}}),t.MouseHandler=c}),ace.define("ace/mouse/fold_handler",["require","exports","module","ace/lib/dom"],function(e,t,n){"use strict";function i(e){e.on("click",function(t){var n=t.getDocumentPosition(),i=e.session,s=i.getFoldAt(n.row,n.column,1);s&&(t.getAccelKey()?i.removeFold(s):i.expandFold(s),t.stop());var o=t.domEvent&&t.domEvent.target;o&&r.hasCssClass(o,"ace_inline_button")&&r.hasCssClass(o,"ace_toggle_wrap")&&(i.setOption("wrap",!i.getUseWrapMode()),e.renderer.scrollCursorIntoView())}),e.on("gutterclick",function(t){var n=e.renderer.$gutterLayer.getRegion(t);if(n=="foldWidgets"){var r=t.getDocumentPosition().row,i=e.session;i.foldWidgets&&i.foldWidgets[r]&&e.session.onFoldWidgetClick(r,t),e.isFocused()||e.focus(),t.stop()}}),e.on("gutterdblclick",function(t){var n=e.renderer.$gutterLayer.getRegion(t);if(n=="foldWidgets"){var r=t.getDocumentPosition().row,i=e.session,s=i.getParentFoldRangeData(r,!0),o=s.range||s.firstRange;if(o){r=o.start.row;var u=i.getFoldAt(r,i.getLine(r).length,1);u?i.removeFold(u):(i.addFold("...",o),e.renderer.scrollCursorIntoView({row:o.start.row,column:0}))}t.stop()}})}var r=e("../lib/dom");t.FoldHandler=i}),ace.define("ace/keyboard/keybinding",["require","exports","module","ace/lib/keys","ace/lib/event"],function(e,t,n){"use strict";var r=e("../lib/keys"),i=e("../lib/event"),s=function(e){this.$editor=e,this.$data={editor:e},this.$handlers=[],this.setDefaultHandler(e.commands)};(function(){this.setDefaultHandler=function(e){this.removeKeyboardHandler(this.$defaultHandler),this.$defaultHandler=e,this.addKeyboardHandler(e,0)},this.setKeyboardHandler=function(e){var t=this.$handlers;if(t[t.length-1]==e)return;while(t[t.length-1]&&t[t.length-1]!=this.$defaultHandler)this.removeKeyboardHandler(t[t.length-1]);this.addKeyboardHandler(e,1)},this.addKeyboardHandler=function(e,t){if(!e)return;typeof e=="function"&&!e.handleKeyboard&&(e.handleKeyboard=e);var n=this.$handlers.indexOf(e);n!=-1&&this.$handlers.splice(n,1),t==undefined?this.$handlers.push(e):this.$handlers.splice(t,0,e),n==-1&&e.attach&&e.attach(this.$editor)},this.removeKeyboardHandler=function(e){var t=this.$handlers.indexOf(e);return t==-1?!1:(this.$handlers.splice(t,1),e.detach&&e.detach(this.$editor),!0)},this.getKeyboardHandler=function(){return this.$handlers[this.$handlers.length-1]},this.getStatusText=function(){var e=this.$data,t=e.editor;return this.$handlers.map(function(n){return n.getStatusText&&n.getStatusText(t,e)||""}).filter(Boolean).join(" ")},this.$callKeyboardHandlers=function(e,t,n,r){var s,o=!1,u=this.$editor.commands;for(var a=this.$handlers.length;a--;){s=this.$handlers[a].handleKeyboard(this.$data,e,t,n,r);if(!s||!s.command)continue;s.command=="null"?o=!0:o=u.exec(s.command,this.$editor,s.args,r),o&&r&&e!=-1&&s.passEvent!=1&&s.command.passEvent!=1&&i.stopEvent(r);if(o)break}return!o&&e==-1&&(s={command:"insertstring"},o=u.exec("insertstring",this.$editor,t)),o&&this.$editor._signal&&this.$editor._signal("keyboardActivity",s),o},this.onCommandKey=function(e,t,n){var i=r.keyCodeToString(n);return this.$callKeyboardHandlers(t,i,n,e)},this.onTextInput=function(e){return this.$callKeyboardHandlers(-1,e)}}).call(s.prototype),t.KeyBinding=s}),ace.define("ace/lib/bidiutil",["require","exports","module"],function(e,t,n){"use strict";function F(e,t,n,r){var i=s?d:p,c=null,h=null,v=null,m=0,g=null,y=null,b=-1,w=null,E=null,T=[];if(!r)for(w=0,r=[];w<n;w++)r[w]=R(e[w]);o=s,u=!1,a=!1,f=!1,l=!1;for(E=0;E<n;E++){c=m,T[E]=h=q(e,r,T,E),m=i[c][h],g=m&240,m&=15,t[E]=v=i[m][5];if(g>0)if(g==16){for(w=b;w<E;w++)t[w]=1;b=-1}else b=-1;y=i[m][6];if(y)b==-1&&(b=E);else if(b>-1){for(w=b;w<E;w++)t[w]=v;b=-1}r[E]==S&&(t[E]=0),o|=v}if(l)for(w=0;w<n;w++)if(r[w]==x){t[w]=s;for(var C=w-1;C>=0;C--){if(r[C]!=N)break;t[C]=s}}}function I(e,t,n){if(o<e)return;if(e==1&&s==m&&!f){n.reverse();return}var r=n.length,i=0,u,a,l,c;while(i<r){if(t[i]>=e){u=i+1;while(u<r&&t[u]>=e)u++;for(a=i,l=u-1;a<l;a++,l--)c=n[a],n[a]=n[l],n[l]=c;i=u}i++}}function q(e,t,n,r){var i=t[r],o,c,h,p;switch(i){case g:case y:u=!1;case E:case w:return i;case b:return u?w:b;case T:return u=!0,a=!0,y;case N:return E;case C:if(r<1||r+1>=t.length||(o=n[r-1])!=b&&o!=w||(c=t[r+1])!=b&&c!=w)return E;return u&&(c=w),c==o?c:E;case k:o=r>0?n[r-1]:S;if(o==b&&r+1<t.length&&t[r+1]==b)return b;return E;case L:if(r>0&&n[r-1]==b)return b;if(u)return E;p=r+1,h=t.length;while(p<h&&t[p]==L)p++;if(p<h&&t[p]==b)return b;return E;case A:h=t.length,p=r+1;while(p<h&&t[p]==A)p++;if(p<h){var d=e[r],v=d>=1425&&d<=2303||d==64286;o=t[p];if(v&&(o==y||o==T))return y}if(r<1||(o=t[r-1])==S)return E;return n[r-1];case S:return u=!1,f=!0,s;case x:return l=!0,E;case O:case M:case D:case P:case _:u=!1;case H:return E}}function R(e){var t=e.charCodeAt(0),n=t>>8;return n==0?t>191?g:B[t]:n==5?/[\u0591-\u05f4]/.test(e)?y:g:n==6?/[\u0610-\u061a\u064b-\u065f\u06d6-\u06e4\u06e7-\u06ed]/.test(e)?A:/[\u0660-\u0669\u066b-\u066c]/.test(e)?w:t==1642?L:/[\u06f0-\u06f9]/.test(e)?b:T:n==32&&t<=8287?j[t&255]:n==254?t>=65136?T:E:E}function U(e){return e>="\u064b"&&e<="\u0655"}var r=["\u0621","\u0641"],i=["\u063a","\u064a"],s=0,o=0,u=!1,a=!1,f=!1,l=!1,c=!1,h=!1,p=[[0,3,0,1,0,0,0],[0,3,0,1,2,2,0],[0,3,0,17,2,0,1],[0,3,5,5,4,1,0],[0,3,21,21,4,0,1],[0,3,5,5,4,2,0]],d=[[2,0,1,1,0,1,0],[2,0,1,1,0,2,0],[2,0,2,1,3,2,0],[2,0,2,33,3,1,1]],v=0,m=1,g=0,y=1,b=2,w=3,E=4,S=5,x=6,T=7,N=8,C=9,k=10,L=11,A=12,O=13,M=14,_=15,D=16,P=17,H=18,B=[H,H,H,H,H,H,H,H,H,x,S,x,N,S,H,H,H,H,H,H,H,H,H,H,H,H,H,H,S,S,S,x,N,E,E,L,L,L,E,E,E,E,E,k,C,k,C,C,b,b,b,b,b,b,b,b,b,b,C,E,E,E,E,E,E,g,g,g,g,g,g,g,g,g,g,g,g,g,g,g,g,g,g,g,g,g,g,g,g,g,g,E,E,E,E,E,E,g,g,g,g,g,g,g,g,g,g,g,g,g,g,g,g,g,g,g,g,g,g,g,g,g,g,E,E,E,E,H,H,H,H,H,H,S,H,H,H,H,H,H,H,H,H,H,H,H,H,H,H,H,H,H,H,H,H,H,H,H,H,H,C,E,L,L,L,L,E,E,E,E,g,E,E,H,E,E,L,L,b,b,E,g,E,E,E,b,g,E,E,E,E,E],j=[N,N,N,N,N,N,N,N,N,N,N,H,H,H,g,y,E,E,E,E,E,E,E,E,E,E,E,E,E,E,E,E,E,E,E,E,E,E,E,E,N,S,O,M,_,D,P,C,L,L,L,L,L,E,E,E,E,E,E,E,E,E,E,E,E,E,E,E,C,E,E,E,E,E,E,E,E,E,E,E,E,E,E,E,E,E,E,E,E,E,E,E,E,E,E,N];t.L=g,t.R=y,t.EN=b,t.ON_R=3,t.AN=4,t.R_H=5,t.B=6,t.RLE=7,t.DOT="\u00b7",t.doBidiReorder=function(e,n,r){if(e.length<2)return{};var i=e.split(""),o=new Array(i.length),u=new Array(i.length),a=[];s=r?m:v,F(i,a,i.length,n);for(var f=0;f<o.length;o[f]=f,f++);I(2,a,o),I(1,a,o);for(var f=0;f<o.length-1;f++)n[f]===w?a[f]=t.AN:a[f]===y&&(n[f]>T&&n[f]<O||n[f]===E||n[f]===H)?a[f]=t.ON_R:f>0&&i[f-1]==="\u0644"&&/\u0622|\u0623|\u0625|\u0627/.test(i[f])&&(a[f-1]=a[f]=t.R_H,f++);i[i.length-1]===t.DOT&&(a[i.length-1]=t.B),i[0]==="\u202b"&&(a[0]=t.RLE);for(var f=0;f<o.length;f++)u[f]=a[o[f]];return{logicalFromVisual:o,bidiLevels:u}},t.hasBidiCharacters=function(e,t){var n=!1;for(var r=0;r<e.length;r++)t[r]=R(e.charAt(r)),!n&&(t[r]==y||t[r]==T||t[r]==w)&&(n=!0);return n},t.getVisualFromLogicalIdx=function(e,t){for(var n=0;n<t.logicalFromVisual.length;n++)if(t.logicalFromVisual[n]==e)return n;return 0}}),ace.define("ace/bidihandler",["require","exports","module","ace/lib/bidiutil","ace/lib/lang"],function(e,t,n){"use strict";var r=e("./lib/bidiutil"),i=e("./lib/lang"),s=/[\u0590-\u05f4\u0600-\u06ff\u0700-\u08ac\u202B]/,o=function(e){this.session=e,this.bidiMap={},this.currentRow=null,this.bidiUtil=r,this.charWidths=[],this.EOL="\u00ac",this.showInvisibles=!0,this.isRtlDir=!1,this.$isRtl=!1,this.line="",this.wrapIndent=0,this.EOF="\u00b6",this.RLE="\u202b",this.contentWidth=0,this.fontMetrics=null,this.rtlLineOffset=0,this.wrapOffset=0,this.isMoveLeftOperation=!1,this.seenBidi=s.test(e.getValue())};(function(){this.isBidiRow=function(e,t,n){return this.seenBidi?(e!==this.currentRow&&(this.currentRow=e,this.updateRowLine(t,n),this.updateBidiMap()),this.bidiMap.bidiLevels):!1},this.onChange=function(e){this.seenBidi?this.currentRow=null:e.action=="insert"&&s.test(e.lines.join("\n"))&&(this.seenBidi=!0,this.currentRow=null)},this.getDocumentRow=function(){var e=0,t=this.session.$screenRowCache;if(t.length){var n=this.session.$getRowCacheIndex(t,this.currentRow);n>=0&&(e=this.session.$docRowCache[n])}return e},this.getSplitIndex=function(){var e=0,t=this.session.$screenRowCache;if(t.length){var n,r=this.session.$getRowCacheIndex(t,this.currentRow);while(this.currentRow-e>0){n=this.session.$getRowCacheIndex(t,this.currentRow-e-1);if(n!==r)break;r=n,e++}}else e=this.currentRow;return e},this.updateRowLine=function(e,t){e===undefined&&(e=this.getDocumentRow());var n=e===this.session.getLength()-1,s=n?this.EOF:this.EOL;this.wrapIndent=0,this.line=this.session.getLine(e),this.isRtlDir=this.$isRtl||this.line.charAt(0)===this.RLE;if(this.session.$useWrapMode){var o=this.session.$wrapData[e];o&&(t===undefined&&(t=this.getSplitIndex()),t>0&&o.length?(this.wrapIndent=o.indent,this.wrapOffset=this.wrapIndent*this.charWidths[r.L],this.line=t<o.length?this.line.substring(o[t-1],o[t]):this.line.substring(o[o.length-1])):this.line=this.line.substring(0,o[t])),t==o.length&&(this.line+=this.showInvisibles?s:r.DOT)}else this.line+=this.showInvisibles?s:r.DOT;var u=this.session,a=0,f;this.line=this.line.replace(/\t|[\u1100-\u2029, \u202F-\uFFE6]/g,function(e,t){return e===" "||u.isFullWidth(e.charCodeAt(0))?(f=e===" "?u.getScreenTabSize(t+a):2,a+=f-1,i.stringRepeat(r.DOT,f)):e}),this.isRtlDir&&(this.fontMetrics.$main.textContent=this.line.charAt(this.line.length-1)==r.DOT?this.line.substr(0,this.line.length-1):this.line,this.rtlLineOffset=this.contentWidth-this.fontMetrics.$main.getBoundingClientRect().width)},this.updateBidiMap=function(){var e=[];r.hasBidiCharacters(this.line,e)||this.isRtlDir?this.bidiMap=r.doBidiReorder(this.line,e,this.isRtlDir):this.bidiMap={}},this.markAsDirty=function(){this.currentRow=null},this.updateCharacterWidths=function(e){if(this.characterWidth===e.$characterSize.width)return;this.fontMetrics=e;var t=this.characterWidth=e.$characterSize.width,n=e.$measureCharWidth("\u05d4");this.charWidths[r.L]=this.charWidths[r.EN]=this.charWidths[r.ON_R]=t,this.charWidths[r.R]=this.charWidths[r.AN]=n,this.charWidths[r.R_H]=n*.45,this.charWidths[r.B]=this.charWidths[r.RLE]=0,this.currentRow=null},this.setShowInvisibles=function(e){this.showInvisibles=e,this.currentRow=null},this.setEolChar=function(e){this.EOL=e},this.setContentWidth=function(e){this.contentWidth=e},this.isRtlLine=function(e){return this.$isRtl?!0:e!=undefined?this.session.getLine(e).charAt(0)==this.RLE:this.isRtlDir},this.setRtlDirection=function(e,t){var n=e.getCursorPosition();for(var r=e.selection.getSelectionAnchor().row;r<=n.row;r++)!t&&e.session.getLine(r).charAt(0)===e.session.$bidiHandler.RLE?e.session.doc.removeInLine(r,0,1):t&&e.session.getLine(r).charAt(0)!==e.session.$bidiHandler.RLE&&e.session.doc.insert({column:0,row:r},e.session.$bidiHandler.RLE)},this.getPosLeft=function(e){e-=this.wrapIndent;var t=this.line.charAt(0)===this.RLE?1:0,n=e>t?this.session.getOverwrite()?e:e-1:t,i=r.getVisualFromLogicalIdx(n,this.bidiMap),s=this.bidiMap.bidiLevels,o=0;!this.session.getOverwrite()&&e<=t&&s[i]%2!==0&&i++;for(var u=0;u<i;u++)o+=this.charWidths[s[u]];return!this.session.getOverwrite()&&e>t&&s[i]%2===0&&(o+=this.charWidths[s[i]]),this.wrapIndent&&(o+=this.isRtlDir?-1*this.wrapOffset:this.wrapOffset),this.isRtlDir&&(o+=this.rtlLineOffset),o},this.getSelections=function(e,t){var n=this.bidiMap,r=n.bidiLevels,i,s=[],o=0,u=Math.min(e,t)-this.wrapIndent,a=Math.max(e,t)-this.wrapIndent,f=!1,l=!1,c=0;this.wrapIndent&&(o+=this.isRtlDir?-1*this.wrapOffset:this.wrapOffset);for(var h,p=0;p<r.length;p++)h=n.logicalFromVisual[p],i=r[p],f=h>=u&&h<a,f&&!l?c=o:!f&&l&&s.push({left:c,width:o-c}),o+=this.charWidths[i],l=f;f&&p===r.length&&s.push({left:c,width:o-c});if(this.isRtlDir)for(var d=0;d<s.length;d++)s[d].left+=this.rtlLineOffset;return s},this.offsetToCol=function(e){this.isRtlDir&&(e-=this.rtlLineOffset);var t=0,e=Math.max(e,0),n=0,r=0,i=this.bidiMap.bidiLevels,s=this.charWidths[i[r]];this.wrapIndent&&(e-=this.isRtlDir?-1*this.wrapOffset:this.wrapOffset);while(e>n+s/2){n+=s;if(r===i.length-1){s=0;break}s=this.charWidths[i[++r]]}return r>0&&i[r-1]%2!==0&&i[r]%2===0?(e<n&&r--,t=this.bidiMap.logicalFromVisual[r]):r>0&&i[r-1]%2===0&&i[r]%2!==0?t=1+(e>n?this.bidiMap.logicalFromVisual[r]:this.bidiMap.logicalFromVisual[r-1]):this.isRtlDir&&r===i.length-1&&s===0&&i[r-1]%2===0||!this.isRtlDir&&r===0&&i[r]%2!==0?t=1+this.bidiMap.logicalFromVisual[r]:(r>0&&i[r-1]%2!==0&&s!==0&&r--,t=this.bidiMap.logicalFromVisual[r]),t===0&&this.isRtlDir&&t++,t+this.wrapIndent}}).call(o.prototype),t.BidiHandler=o}),ace.define("ace/selection",["require","exports","module","ace/lib/oop","ace/lib/lang","ace/lib/event_emitter","ace/range"],function(e,t,n){"use strict";var r=e("./lib/oop"),i=e("./lib/lang"),s=e("./lib/event_emitter").EventEmitter,o=e("./range").Range,u=function(e){this.session=e,this.doc=e.getDocument(),this.clearSelection(),this.cursor=this.lead=this.doc.createAnchor(0,0),this.anchor=this.doc.createAnchor(0,0),this.$silent=!1;var t=this;this.cursor.on("change",function(e){t.$cursorChanged=!0,t.$silent||t._emit("changeCursor"),!t.$isEmpty&&!t.$silent&&t._emit("changeSelection"),!t.$keepDesiredColumnOnChange&&e.old.column!=e.value.column&&(t.$desiredColumn=null)}),this.anchor.on("change",function(){t.$anchorChanged=!0,!t.$isEmpty&&!t.$silent&&t._emit("changeSelection")})};(function(){r.implement(this,s),this.isEmpty=function(){return this.$isEmpty||this.anchor.row==this.lead.row&&this.anchor.column==this.lead.column},this.isMultiLine=function(){return!this.$isEmpty&&this.anchor.row!=this.cursor.row},this.getCursor=function(){return this.lead.getPosition()},this.setSelectionAnchor=function(e,t){this.$isEmpty=!1,this.anchor.setPosition(e,t)},this.getAnchor=this.getSelectionAnchor=function(){return this.$isEmpty?this.getSelectionLead():this.anchor.getPosition()},this.getSelectionLead=function(){return this.lead.getPosition()},this.isBackwards=function(){var e=this.anchor,t=this.lead;return e.row>t.row||e.row==t.row&&e.column>t.column},this.getRange=function(){var e=this.anchor,t=this.lead;return this.$isEmpty?o.fromPoints(t,t):this.isBackwards()?o.fromPoints(t,e):o.fromPoints(e,t)},this.clearSelection=function(){this.$isEmpty||(this.$isEmpty=!0,this._emit("changeSelection"))},this.selectAll=function(){this.$setSelection(0,0,Number.MAX_VALUE,Number.MAX_VALUE)},this.setRange=this.setSelectionRange=function(e,t){var n=t?e.end:e.start,r=t?e.start:e.end;this.$setSelection(n.row,n.column,r.row,r.column)},this.$setSelection=function(e,t,n,r){if(this.$silent)return;var i=this.$isEmpty,s=this.inMultiSelectMode;this.$silent=!0,this.$cursorChanged=this.$anchorChanged=!1,this.anchor.setPosition(e,t),this.cursor.setPosition(n,r),this.$isEmpty=!o.comparePoints(this.anchor,this.cursor),this.$silent=!1,this.$cursorChanged&&this._emit("changeCursor"),(this.$cursorChanged||this.$anchorChanged||i!=this.$isEmpty||s)&&this._emit("changeSelection")},this.$moveSelection=function(e){var t=this.lead;this.$isEmpty&&this.setSelectionAnchor(t.row,t.column),e.call(this)},this.selectTo=function(e,t){this.$moveSelection(function(){this.moveCursorTo(e,t)})},this.selectToPosition=function(e){this.$moveSelection(function(){this.moveCursorToPosition(e)})},this.moveTo=function(e,t){this.clearSelection(),this.moveCursorTo(e,t)},this.moveToPosition=function(e){this.clearSelection(),this.moveCursorToPosition(e)},this.selectUp=function(){this.$moveSelection(this.moveCursorUp)},this.selectDown=function(){this.$moveSelection(this.moveCursorDown)},this.selectRight=function(){this.$moveSelection(this.moveCursorRight)},this.selectLeft=function(){this.$moveSelection(this.moveCursorLeft)},this.selectLineStart=function(){this.$moveSelection(this.moveCursorLineStart)},this.selectLineEnd=function(){this.$moveSelection(this.moveCursorLineEnd)},this.selectFileEnd=function(){this.$moveSelection(this.moveCursorFileEnd)},this.selectFileStart=function(){this.$moveSelection(this.moveCursorFileStart)},this.selectWordRight=function(){this.$moveSelection(this.moveCursorWordRight)},this.selectWordLeft=function(){this.$moveSelection(this.moveCursorWordLeft)},this.getWordRange=function(e,t){if(typeof t=="undefined"){var n=e||this.lead;e=n.row,t=n.column}return this.session.getWordRange(e,t)},this.selectWord=function(){this.setSelectionRange(this.getWordRange())},this.selectAWord=function(){var e=this.getCursor(),t=this.session.getAWordRange(e.row,e.column);this.setSelectionRange(t)},this.getLineRange=function(e,t){var n=typeof e=="number"?e:this.lead.row,r,i=this.session.getFoldLine(n);return i?(n=i.start.row,r=i.end.row):r=n,t===!0?new o(n,0,r,this.session.getLine(r).length):new o(n,0,r+1,0)},this.selectLine=function(){this.setSelectionRange(this.getLineRange())},this.moveCursorUp=function(){this.moveCursorBy(-1,0)},this.moveCursorDown=function(){this.moveCursorBy(1,0)},this.wouldMoveIntoSoftTab=function(e,t,n){var r=e.column,i=e.column+t;return n<0&&(r=e.column-t,i=e.column),this.session.isTabStop(e)&&this.doc.getLine(e.row).slice(r,i).split(" ").length-1==t},this.moveCursorLeft=function(){var e=this.lead.getPosition(),t;if(t=this.session.getFoldAt(e.row,e.column,-1))this.moveCursorTo(t.start.row,t.start.column);else if(e.column===0)e.row>0&&this.moveCursorTo(e.row-1,this.doc.getLine(e.row-1).length);else{var n=this.session.getTabSize();this.wouldMoveIntoSoftTab(e,n,-1)&&!this.session.getNavigateWithinSoftTabs()?this.moveCursorBy(0,-n):this.moveCursorBy(0,-1)}},this.moveCursorRight=function(){var e=this.lead.getPosition(),t;if(t=this.session.getFoldAt(e.row,e.column,1))this.moveCursorTo(t.end.row,t.end.column);else if(this.lead.column==this.doc.getLine(this.lead.row).length)this.lead.row<this.doc.getLength()-1&&this.moveCursorTo(this.lead.row+1,0);else{var n=this.session.getTabSize(),e=this.lead;this.wouldMoveIntoSoftTab(e,n,1)&&!this.session.getNavigateWithinSoftTabs()?this.moveCursorBy(0,n):this.moveCursorBy(0,1)}},this.moveCursorLineStart=function(){var e=this.lead.row,t=this.lead.column,n=this.session.documentToScreenRow(e,t),r=this.session.screenToDocumentPosition(n,0),i=this.session.getDisplayLine(e,null,r.row,r.column),s=i.match(/^\s*/);s[0].length!=t&&!this.session.$useEmacsStyleLineStart&&(r.column+=s[0].length),this.moveCursorToPosition(r)},this.moveCursorLineEnd=function(){var e=this.lead,t=this.session.getDocumentLastRowColumnPosition(e.row,e.column);if(this.lead.column==t.column){var n=this.session.getLine(t.row);if(t.column==n.length){var r=n.search(/\s+$/);r>0&&(t.column=r)}}this.moveCursorTo(t.row,t.column)},this.moveCursorFileEnd=function(){var e=this.doc.getLength()-1,t=this.doc.getLine(e).length;this.moveCursorTo(e,t)},this.moveCursorFileStart=function(){this.moveCursorTo(0,0)},this.moveCursorLongWordRight=function(){var e=this.lead.row,t=this.lead.column,n=this.doc.getLine(e),r=n.substring(t);this.session.nonTokenRe.lastIndex=0,this.session.tokenRe.lastIndex=0;var i=this.session.getFoldAt(e,t,1);if(i){this.moveCursorTo(i.end.row,i.end.column);return}this.session.nonTokenRe.exec(r)&&(t+=this.session.nonTokenRe.lastIndex,this.session.nonTokenRe.lastIndex=0,r=n.substring(t));if(t>=n.length){this.moveCursorTo(e,n.length),this.moveCursorRight(),e<this.doc.getLength()-1&&this.moveCursorWordRight();return}this.session.tokenRe.exec(r)&&(t+=this.session.tokenRe.lastIndex,this.session.tokenRe.lastIndex=0),this.moveCursorTo(e,t)},this.moveCursorLongWordLeft=function(){var e=this.lead.row,t=this.lead.column,n;if(n=this.session.getFoldAt(e,t,-1)){this.moveCursorTo(n.start.row,n.start.column);return}var r=this.session.getFoldStringAt(e,t,-1);r==null&&(r=this.doc.getLine(e).substring(0,t));var s=i.stringReverse(r);this.session.nonTokenRe.lastIndex=0,this.session.tokenRe.lastIndex=0,this.session.nonTokenRe.exec(s)&&(t-=this.session.nonTokenRe.lastIndex,s=s.slice(this.session.nonTokenRe.lastIndex),this.session.nonTokenRe.lastIndex=0);if(t<=0){this.moveCursorTo(e,0),this.moveCursorLeft(),e>0&&this.moveCursorWordLeft();return}this.session.tokenRe.exec(s)&&(t-=this.session.tokenRe.lastIndex,this.session.tokenRe.lastIndex=0),this.moveCursorTo(e,t)},this.$shortWordEndIndex=function(e){var t=0,n,r=/\s/,i=this.session.tokenRe;i.lastIndex=0;if(this.session.tokenRe.exec(e))t=this.session.tokenRe.lastIndex;else{while((n=e[t])&&r.test(n))t++;if(t<1){i.lastIndex=0;while((n=e[t])&&!i.test(n)){i.lastIndex=0,t++;if(r.test(n)){if(t>2){t--;break}while((n=e[t])&&r.test(n))t++;if(t>2)break}}}}return i.lastIndex=0,t},this.moveCursorShortWordRight=function(){var e=this.lead.row,t=this.lead.column,n=this.doc.getLine(e),r=n.substring(t),i=this.session.getFoldAt(e,t,1);if(i)return this.moveCursorTo(i.end.row,i.end.column);if(t==n.length){var s=this.doc.getLength();do e++,r=this.doc.getLine(e);while(e<s&&/^\s*$/.test(r));/^\s+/.test(r)||(r=""),t=0}var o=this.$shortWordEndIndex(r);this.moveCursorTo(e,t+o)},this.moveCursorShortWordLeft=function(){var e=this.lead.row,t=this.lead.column,n;if(n=this.session.getFoldAt(e,t,-1))return this.moveCursorTo(n.start.row,n.start.column);var r=this.session.getLine(e).substring(0,t);if(t===0){do e--,r=this.doc.getLine(e);while(e>0&&/^\s*$/.test(r));t=r.length,/\s+$/.test(r)||(r="")}var s=i.stringReverse(r),o=this.$shortWordEndIndex(s);return this.moveCursorTo(e,t-o)},this.moveCursorWordRight=function(){this.session.$selectLongWords?this.moveCursorLongWordRight():this.moveCursorShortWordRight()},this.moveCursorWordLeft=function(){this.session.$selectLongWords?this.moveCursorLongWordLeft():this.moveCursorShortWordLeft()},this.moveCursorBy=function(e,t){var n=this.session.documentToScreenPosition(this.lead.row,this.lead.column),r;t===0&&(e!==0&&(this.session.$bidiHandler.isBidiRow(n.row,this.lead.row)?(r=this.session.$bidiHandler.getPosLeft(n.column),n.column=Math.round(r/this.session.$bidiHandler.charWidths[0])):r=n.column*this.session.$bidiHandler.charWidths[0]),this.$desiredColumn?n.column=this.$desiredColumn:this.$desiredColumn=n.column);if(e!=0&&this.session.lineWidgets&&this.session.lineWidgets[this.lead.row]){var i=this.session.lineWidgets[this.lead.row];e<0?e-=i.rowsAbove||0:e>0&&(e+=i.rowCount-(i.rowsAbove||0))}var s=this.session.screenToDocumentPosition(n.row+e,n.column,r);e!==0&&t===0&&s.row===this.lead.row&&s.column===this.lead.column,this.moveCursorTo(s.row,s.column+t,t===0)},this.moveCursorToPosition=function(e){this.moveCursorTo(e.row,e.column)},this.moveCursorTo=function(e,t,n){var r=this.session.getFoldAt(e,t,1);r&&(e=r.start.row,t=r.start.column),this.$keepDesiredColumnOnChange=!0;var i=this.session.getLine(e);/[\uDC00-\uDFFF]/.test(i.charAt(t))&&i.charAt(t-1)&&(this.lead.row==e&&this.lead.column==t+1?t-=1:t+=1),this.lead.setPosition(e,t),this.$keepDesiredColumnOnChange=!1,n||(this.$desiredColumn=null)},this.moveCursorToScreen=function(e,t,n){var r=this.session.screenToDocumentPosition(e,t);this.moveCursorTo(r.row,r.column,n)},this.detach=function(){this.lead.detach(),this.anchor.detach(),this.session=this.doc=null},this.fromOrientedRange=function(e){this.setSelectionRange(e,e.cursor==e.start),this.$desiredColumn=e.desiredColumn||this.$desiredColumn},this.toOrientedRange=function(e){var t=this.getRange();return e?(e.start.column=t.start.column,e.start.row=t.start.row,e.end.column=t.end.column,e.end.row=t.end.row):e=t,e.cursor=this.isBackwards()?e.start:e.end,e.desiredColumn=this.$desiredColumn,e},this.getRangeOfMovements=function(e){var t=this.getCursor();try{e(this);var n=this.getCursor();return o.fromPoints(t,n)}catch(r){return o.fromPoints(t,t)}finally{this.moveCursorToPosition(t)}},this.toJSON=function(){if(this.rangeCount)var e=this.ranges.map(function(e){var t=e.clone();return t.isBackwards=e.cursor==e.start,t});else{var e=this.getRange();e.isBackwards=this.isBackwards()}return e},this.fromJSON=function(e){if(e.start==undefined){if(this.rangeList&&e.length>1){this.toSingleRange(e[0]);for(var t=e.length;t--;){var n=o.fromPoints(e[t].start,e[t].end);e[t].isBackwards&&(n.cursor=n.start),this.addRange(n,!0)}return}e=e[0]}this.rangeList&&this.toSingleRange(e),this.setSelectionRange(e,e.isBackwards)},this.isEqual=function(e){if((e.length||this.rangeCount)&&e.length!=this.rangeCount)return!1;if(!e.length||!this.ranges)return this.getRange().isEqual(e);for(var t=this.ranges.length;t--;)if(!this.ranges[t].isEqual(e[t]))return!1;return!0}}).call(u.prototype),t.Selection=u}),ace.define("ace/tokenizer",["require","exports","module","ace/config"],function(e,t,n){"use strict";var r=e("./config"),i=2e3,s=function(e){this.states=e,this.regExps={},this.matchMappings={};for(var t in this.states){var n=this.states[t],r=[],i=0,s=this.matchMappings[t]={defaultToken:"text"},o="g",u=[];for(var a=0;a<n.length;a++){var f=n[a];f.defaultToken&&(s.defaultToken=f.defaultToken),f.caseInsensitive&&(o="gi");if(f.regex==null)continue;f.regex instanceof RegExp&&(f.regex=f.regex.toString().slice(1,-1));var l=f.regex,c=(new RegExp("(?:("+l+")|(.))")).exec("a").length-2;Array.isArray(f.token)?f.token.length==1||c==1?f.token=f.token[0]:c-1!=f.token.length?(this.reportError("number of classes and regexp groups doesn't match",{rule:f,groupCount:c-1}),f.token=f.token[0]):(f.tokenArray=f.token,f.token=null,f.onMatch=this.$arrayTokens):typeof f.token=="function"&&!f.onMatch&&(c>1?f.onMatch=this.$applyToken:f.onMatch=f.token),c>1&&(/\\\d/.test(f.regex)?l=f.regex.replace(/\\([0-9]+)/g,function(e,t){return"\\"+(parseInt(t,10)+i+1)}):(c=1,l=this.removeCapturingGroups(f.regex)),!f.splitRegex&&typeof f.token!="string"&&u.push(f)),s[i]=a,i+=c,r.push(l),f.onMatch||(f.onMatch=null)}r.length||(s[0]=0,r.push("$")),u.forEach(function(e){e.splitRegex=this.createSplitterRegexp(e.regex,o)},this),this.regExps[t]=new RegExp("("+r.join(")|(")+")|($)",o)}};(function(){this.$setMaxTokenCount=function(e){i=e|0},this.$applyToken=function(e){var t=this.splitRegex.exec(e).slice(1),n=this.token.apply(this,t);if(typeof n=="string")return[{type:n,value:e}];var r=[];for(var i=0,s=n.length;i<s;i++)t[i]&&(r[r.length]={type:n[i],value:t[i]});return r},this.$arrayTokens=function(e){if(!e)return[];var t=this.splitRegex.exec(e);if(!t)return"text";var n=[],r=this.tokenArray;for(var i=0,s=r.length;i<s;i++)t[i+1]&&(n[n.length]={type:r[i],value:t[i+1]});return n},this.removeCapturingGroups=function(e){var t=e.replace(/\\.|\[(?:\\.|[^\\\]])*|\(\?[:=!]|(\()/g,function(e,t){return t?"(?:":e});return t},this.createSplitterRegexp=function(e,t){if(e.indexOf("(?=")!=-1){var n=0,r=!1,i={};e.replace(/(\\.)|(\((?:\?[=!])?)|(\))|([\[\]])/g,function(e,t,s,o,u,a){return r?r=u!="]":u?r=!0:o?(n==i.stack&&(i.end=a+1,i.stack=-1),n--):s&&(n++,s.length!=1&&(i.stack=n,i.start=a)),e}),i.end!=null&&/^\)*$/.test(e.substr(i.end))&&(e=e.substring(0,i.start)+e.substr(i.end))}return e.charAt(0)!="^"&&(e="^"+e),e.charAt(e.length-1)!="$"&&(e+="$"),new RegExp(e,(t||"").replace("g",""))},this.getLineTokens=function(e,t){if(t&&typeof t!="string"){var n=t.slice(0);t=n[0],t==="#tmp"&&(n.shift(),t=n.shift())}else var n=[];var r=t||"start",s=this.states[r];s||(r="start",s=this.states[r]);var o=this.matchMappings[r],u=this.regExps[r];u.lastIndex=0;var a,f=[],l=0,c=0,h={type:null,value:""};while(a=u.exec(e)){var p=o.defaultToken,d=null,v=a[0],m=u.lastIndex;if(m-v.length>l){var g=e.substring(l,m-v.length);h.type==p?h.value+=g:(h.type&&f.push(h),h={type:p,value:g})}for(var y=0;y<a.length-2;y++){if(a[y+1]===undefined)continue;d=s[o[y]],d.onMatch?p=d.onMatch(v,r,n,e):p=d.token,d.next&&(typeof d.next=="string"?r=d.next:r=d.next(r,n),s=this.states[r],s||(this.reportError("state doesn't exist",r),r="start",s=this.states[r]),o=this.matchMappings[r],l=m,u=this.regExps[r],u.lastIndex=m),d.consumeLineEnd&&(l=m);break}if(v)if(typeof p=="string")!!d&&d.merge===!1||h.type!==p?(h.type&&f.push(h),h={type:p,value:v}):h.value+=v;else if(p){h.type&&f.push(h),h={type:null,value:""};for(var y=0;y<p.length;y++)f.push(p[y])}if(l==e.length)break;l=m;if(c++>i){c>2*e.length&&this.reportError("infinite loop with in ace tokenizer",{startState:t,line:e});while(l<e.length)h.type&&f.push(h),h={value:e.substring(l,l+=500),type:"overflow"};r="start",n=[];break}}return h.type&&f.push(h),n.length>1&&n[0]!==r&&n.unshift("#tmp",r),{tokens:f,state:n.length?n:r}},this.reportError=r.reportError}).call(s.prototype),t.Tokenizer=s}),ace.define("ace/mode/text_highlight_rules",["require","exports","module","ace/lib/lang"],function(e,t,n){"use strict";var r=e("../lib/lang"),i=function(){this.$rules={start:[{token:"empty_line",regex:"^$"},{defaultToken:"text"}]}};(function(){this.addRules=function(e,t){if(!t){for(var n in e)this.$rules[n]=e[n];return}for(var n in e){var r=e[n];for(var i=0;i<r.length;i++){var s=r[i];if(s.next||s.onMatch)typeof s.next=="string"&&s.next.indexOf(t)!==0&&(s.next=t+s.next),s.nextState&&s.nextState.indexOf(t)!==0&&(s.nextState=t+s.nextState)}this.$rules[t+n]=r}},this.getRules=function(){return this.$rules},this.embedRules=function(e,t,n,i,s){var o=typeof e=="function"?(new e).getRules():e;if(i)for(var u=0;u<i.length;u++)i[u]=t+i[u];else{i=[];for(var a in o)i.push(t+a)}this.addRules(o,t);if(n){var f=Array.prototype[s?"push":"unshift"];for(var u=0;u<i.length;u++)f.apply(this.$rules[i[u]],r.deepCopy(n))}this.$embeds||(this.$embeds=[]),this.$embeds.push(t)},this.getEmbeds=function(){return this.$embeds};var e=function(e,t){return(e!="start"||t.length)&&t.unshift(this.nextState,e),this.nextState},t=function(e,t){return t.shift(),t.shift()||"start"};this.normalizeRules=function(){function i(s){var o=r[s];o.processed=!0;for(var u=0;u<o.length;u++){var a=o[u],f=null;Array.isArray(a)&&(f=a,a={}),!a.regex&&a.start&&(a.regex=a.start,a.next||(a.next=[]),a.next.push({defaultToken:a.token},{token:a.token+".end",regex:a.end||a.start,next:"pop"}),a.token=a.token+".start",a.push=!0);var l=a.next||a.push;if(l&&Array.isArray(l)){var c=a.stateName;c||(c=a.token,typeof c!="string"&&(c=c[0]||""),r[c]&&(c+=n++)),r[c]=l,a.next=c,i(c)}else l=="pop"&&(a.next=t);a.push&&(a.nextState=a.next||a.push,a.next=e,delete a.push);if(a.rules)for(var h in a.rules)r[h]?r[h].push&&r[h].push.apply(r[h],a.rules[h]):r[h]=a.rules[h];var p=typeof a=="string"?a:a.include;p&&(Array.isArray(p)?f=p.map(function(e){return r[e]}):f=r[p]);if(f){var d=[u,1].concat(f);a.noEscape&&(d=d.filter(function(e){return!e.next})),o.splice.apply(o,d),u--}a.keywordMap&&(a.token=this.createKeywordMapper(a.keywordMap,a.defaultToken||"text",a.caseInsensitive),delete a.defaultToken)}}var n=0,r=this.$rules;Object.keys(r).forEach(i,this)},this.createKeywordMapper=function(e,t,n,r){var i=Object.create(null);return this.$keywordList=[],Object.keys(e).forEach(function(t){var s=e[t],o=s.split(r||"|");for(var u=o.length;u--;){var a=o[u];this.$keywordList.push(a),n&&(a=a.toLowerCase()),i[a]=t}},this),e=null,n?function(e){return i[e.toLowerCase()]||t}:function(e){return i[e]||t}},this.getKeywords=function(){return this.$keywords}}).call(i.prototype),t.TextHighlightRules=i}),ace.define("ace/mode/behaviour",["require","exports","module"],function(e,t,n){"use strict";var r=function(){this.$behaviours={}};(function(){this.add=function(e,t,n){switch(undefined){case this.$behaviours:this.$behaviours={};case this.$behaviours[e]:this.$behaviours[e]={}}this.$behaviours[e][t]=n},this.addBehaviours=function(e){for(var t in e)for(var n in e[t])this.add(t,n,e[t][n])},this.remove=function(e){this.$behaviours&&this.$behaviours[e]&&delete this.$behaviours[e]},this.inherit=function(e,t){if(typeof e=="function")var n=(new e).getBehaviours(t);else var n=e.getBehaviours(t);this.addBehaviours(n)},this.getBehaviours=function(e){if(!e)return this.$behaviours;var t={};for(var n=0;n<e.length;n++)this.$behaviours[e[n]]&&(t[e[n]]=this.$behaviours[e[n]]);return t}}).call(r.prototype),t.Behaviour=r}),ace.define("ace/token_iterator",["require","exports","module","ace/range"],function(e,t,n){"use strict";var r=e("./range").Range,i=function(e,t,n){this.$session=e,this.$row=t,this.$rowTokens=e.getTokens(t);var r=e.getTokenAt(t,n);this.$tokenIndex=r?r.index:-1};(function(){this.stepBackward=function(){this.$tokenIndex-=1;while(this.$tokenIndex<0){this.$row-=1;if(this.$row<0)return this.$row=0,null;this.$rowTokens=this.$session.getTokens(this.$row),this.$tokenIndex=this.$rowTokens.length-1}return this.$rowTokens[this.$tokenIndex]},this.stepForward=function(){this.$tokenIndex+=1;var e;while(this.$tokenIndex>=this.$rowTokens.length){this.$row+=1,e||(e=this.$session.getLength());if(this.$row>=e)return this.$row=e-1,null;this.$rowTokens=this.$session.getTokens(this.$row),this.$tokenIndex=0}return this.$rowTokens[this.$tokenIndex]},this.getCurrentToken=function(){return this.$rowTokens[this.$tokenIndex]},this.getCurrentTokenRow=function(){return this.$row},this.getCurrentTokenColumn=function(){var e=this.$rowTokens,t=this.$tokenIndex,n=e[t].start;if(n!==undefined)return n;n=0;while(t>0)t-=1,n+=e[t].value.length;return n},this.getCurrentTokenPosition=function(){return{row:this.$row,column:this.getCurrentTokenColumn()}},this.getCurrentTokenRange=function(){var e=this.$rowTokens[this.$tokenIndex],t=this.getCurrentTokenColumn();return new r(this.$row,t,this.$row,t+e.value.length)}}).call(i.prototype),t.TokenIterator=i}),ace.define("ace/mode/behaviour/cstyle",["require","exports","module","ace/lib/oop","ace/mode/behaviour","ace/token_iterator","ace/lib/lang"],function(e,t,n){"use strict";var r=e("../../lib/oop"),i=e("../behaviour").Behaviour,s=e("../../token_iterator").TokenIterator,o=e("../../lib/lang"),u=["text","paren.rparen","rparen","paren","punctuation.operator"],a=["text","paren.rparen","rparen","paren","punctuation.operator","comment"],f,l={},c={'"':'"',"'":"'"},h=function(e){var t=-1;e.multiSelect&&(t=e.selection.index,l.rangeCount!=e.multiSelect.rangeCount&&(l={rangeCount:e.multiSelect.rangeCount}));if(l[t])return f=l[t];f=l[t]={autoInsertedBrackets:0,autoInsertedRow:-1,autoInsertedLineEnd:"",maybeInsertedBrackets:0,maybeInsertedRow:-1,maybeInsertedLineStart:"",maybeInsertedLineEnd:""}},p=function(e,t,n,r){var i=e.end.row-e.start.row;return{text:n+t+r,selection:[0,e.start.column+1,i,e.end.column+(i?0:1)]}},d=function(e){this.add("braces","insertion",function(t,n,r,i,s){var u=r.getCursorPosition(),a=i.doc.getLine(u.row);if(s=="{"){h(r);var l=r.getSelectionRange(),c=i.doc.getTextRange(l);if(c!==""&&c!=="{"&&r.getWrapBehavioursEnabled())return p(l,c,"{","}");if(d.isSaneInsertion(r,i))return/[\]\}\)]/.test(a[u.column])||r.inMultiSelectMode||e&&e.braces?(d.recordAutoInsert(r,i,"}"),{text:"{}",selection:[1,1]}):(d.recordMaybeInsert(r,i,"{"),{text:"{",selection:[1,1]})}else if(s=="}"){h(r);var v=a.substring(u.column,u.column+1);if(v=="}"){var m=i.$findOpeningBracket("}",{column:u.column+1,row:u.row});if(m!==null&&d.isAutoInsertedClosing(u,a,s))return d.popAutoInsertedClosing(),{text:"",selection:[1,1]}}}else{if(s=="\n"||s=="\r\n"){h(r);var g="";d.isMaybeInsertedClosing(u,a)&&(g=o.stringRepeat("}",f.maybeInsertedBrackets),d.clearMaybeInsertedClosing());var v=a.substring(u.column,u.column+1);if(v==="}"){var y=i.findMatchingBracket({row:u.row,column:u.column+1},"}");if(!y)return null;var b=this.$getIndent(i.getLine(y.row))}else{if(!g){d.clearMaybeInsertedClosing();return}var b=this.$getIndent(a)}var w=b+i.getTabString();return{text:"\n"+w+"\n"+b+g,selection:[1,w.length,1,w.length]}}d.clearMaybeInsertedClosing()}}),this.add("braces","deletion",function(e,t,n,r,i){var s=r.doc.getTextRange(i);if(!i.isMultiLine()&&s=="{"){h(n);var o=r.doc.getLine(i.start.row),u=o.substring(i.end.column,i.end.column+1);if(u=="}")return i.end.column++,i;f.maybeInsertedBrackets--}}),this.add("parens","insertion",function(e,t,n,r,i){if(i=="("){h(n);var s=n.getSelectionRange(),o=r.doc.getTextRange(s);if(o!==""&&n.getWrapBehavioursEnabled())return p(s,o,"(",")");if(d.isSaneInsertion(n,r))return d.recordAutoInsert(n,r,")"),{text:"()",selection:[1,1]}}else if(i==")"){h(n);var u=n.getCursorPosition(),a=r.doc.getLine(u.row),f=a.substring(u.column,u.column+1);if(f==")"){var l=r.$findOpeningBracket(")",{column:u.column+1,row:u.row});if(l!==null&&d.isAutoInsertedClosing(u,a,i))return d.popAutoInsertedClosing(),{text:"",selection:[1,1]}}}}),this.add("parens","deletion",function(e,t,n,r,i){var s=r.doc.getTextRange(i);if(!i.isMultiLine()&&s=="("){h(n);var o=r.doc.getLine(i.start.row),u=o.substring(i.start.column+1,i.start.column+2);if(u==")")return i.end.column++,i}}),this.add("brackets","insertion",function(e,t,n,r,i){if(i=="["){h(n);var s=n.getSelectionRange(),o=r.doc.getTextRange(s);if(o!==""&&n.getWrapBehavioursEnabled())return p(s,o,"[","]");if(d.isSaneInsertion(n,r))return d.recordAutoInsert(n,r,"]"),{text:"[]",selection:[1,1]}}else if(i=="]"){h(n);var u=n.getCursorPosition(),a=r.doc.getLine(u.row),f=a.substring(u.column,u.column+1);if(f=="]"){var l=r.$findOpeningBracket("]",{column:u.column+1,row:u.row});if(l!==null&&d.isAutoInsertedClosing(u,a,i))return d.popAutoInsertedClosing(),{text:"",selection:[1,1]}}}}),this.add("brackets","deletion",function(e,t,n,r,i){var s=r.doc.getTextRange(i);if(!i.isMultiLine()&&s=="["){h(n);var o=r.doc.getLine(i.start.row),u=o.substring(i.start.column+1,i.start.column+2);if(u=="]")return i.end.column++,i}}),this.add("string_dquotes","insertion",function(e,t,n,r,i){var s=r.$mode.$quotes||c;if(i.length==1&&s[i]){if(this.lineCommentStart&&this.lineCommentStart.indexOf(i)!=-1)return;h(n);var o=i,u=n.getSelectionRange(),a=r.doc.getTextRange(u);if(a!==""&&(a.length!=1||!s[a])&&n.getWrapBehavioursEnabled())return p(u,a,o,o);if(!a){var f=n.getCursorPosition(),l=r.doc.getLine(f.row),d=l.substring(f.column-1,f.column),v=l.substring(f.column,f.column+1),m=r.getTokenAt(f.row,f.column),g=r.getTokenAt(f.row,f.column+1);if(d=="\\"&&m&&/escape/.test(m.type))return null;var y=m&&/string|escape/.test(m.type),b=!g||/string|escape/.test(g.type),w;if(v==o)w=y!==b,w&&/string\.end/.test(g.type)&&(w=!1);else{if(y&&!b)return null;if(y&&b)return null;var E=r.$mode.tokenRe;E.lastIndex=0;var S=E.test(d);E.lastIndex=0;var x=E.test(d);if(S||x)return null;if(v&&!/[\s;,.})\]\\]/.test(v))return null;var T=l[f.column-2];if(!(d!=o||T!=o&&!E.test(T)))return null;w=!0}return{text:w?o+o:"",selection:[1,1]}}}}),this.add("string_dquotes","deletion",function(e,t,n,r,i){var s=r.$mode.$quotes||c,o=r.doc.getTextRange(i);if(!i.isMultiLine()&&s.hasOwnProperty(o)){h(n);var u=r.doc.getLine(i.start.row),a=u.substring(i.start.column+1,i.start.column+2);if(a==o)return i.end.column++,i}})};d.isSaneInsertion=function(e,t){var n=e.getCursorPosition(),r=new s(t,n.row,n.column);if(!this.$matchTokenType(r.getCurrentToken()||"text",u)){if(/[)}\]]/.test(e.session.getLine(n.row)[n.column]))return!0;var i=new s(t,n.row,n.column+1);if(!this.$matchTokenType(i.getCurrentToken()||"text",u))return!1}return r.stepForward(),r.getCurrentTokenRow()!==n.row||this.$matchTokenType(r.getCurrentToken()||"text",a)},d.$matchTokenType=function(e,t){return t.indexOf(e.type||e)>-1},d.recordAutoInsert=function(e,t,n){var r=e.getCursorPosition(),i=t.doc.getLine(r.row);this.isAutoInsertedClosing(r,i,f.autoInsertedLineEnd[0])||(f.autoInsertedBrackets=0),f.autoInsertedRow=r.row,f.autoInsertedLineEnd=n+i.substr(r.column),f.autoInsertedBrackets++},d.recordMaybeInsert=function(e,t,n){var r=e.getCursorPosition(),i=t.doc.getLine(r.row);this.isMaybeInsertedClosing(r,i)||(f.maybeInsertedBrackets=0),f.maybeInsertedRow=r.row,f.maybeInsertedLineStart=i.substr(0,r.column)+n,f.maybeInsertedLineEnd=i.substr(r.column),f.maybeInsertedBrackets++},d.isAutoInsertedClosing=function(e,t,n){return f.autoInsertedBrackets>0&&e.row===f.autoInsertedRow&&n===f.autoInsertedLineEnd[0]&&t.substr(e.column)===f.autoInsertedLineEnd},d.isMaybeInsertedClosing=function(e,t){return f.maybeInsertedBrackets>0&&e.row===f.maybeInsertedRow&&t.substr(e.column)===f.maybeInsertedLineEnd&&t.substr(0,e.column)==f.maybeInsertedLineStart},d.popAutoInsertedClosing=function(){f.autoInsertedLineEnd=f.autoInsertedLineEnd.substr(1),f.autoInsertedBrackets--},d.clearMaybeInsertedClosing=function(){f&&(f.maybeInsertedBrackets=0,f.maybeInsertedRow=-1)},r.inherits(d,i),t.CstyleBehaviour=d}),ace.define("ace/unicode",["require","exports","module"],function(e,t,n){"use strict";var r=[48,9,8,25,5,0,2,25,48,0,11,0,5,0,6,22,2,30,2,457,5,11,15,4,8,0,2,0,18,116,2,1,3,3,9,0,2,2,2,0,2,19,2,82,2,138,2,4,3,155,12,37,3,0,8,38,10,44,2,0,2,1,2,1,2,0,9,26,6,2,30,10,7,61,2,9,5,101,2,7,3,9,2,18,3,0,17,58,3,100,15,53,5,0,6,45,211,57,3,18,2,5,3,11,3,9,2,1,7,6,2,2,2,7,3,1,3,21,2,6,2,0,4,3,3,8,3,1,3,3,9,0,5,1,2,4,3,11,16,2,2,5,5,1,3,21,2,6,2,1,2,1,2,1,3,0,2,4,5,1,3,2,4,0,8,3,2,0,8,15,12,2,2,8,2,2,2,21,2,6,2,1,2,4,3,9,2,2,2,2,3,0,16,3,3,9,18,2,2,7,3,1,3,21,2,6,2,1,2,4,3,8,3,1,3,2,9,1,5,1,2,4,3,9,2,0,17,1,2,5,4,2,2,3,4,1,2,0,2,1,4,1,4,2,4,11,5,4,4,2,2,3,3,0,7,0,15,9,18,2,2,7,2,2,2,22,2,9,2,4,4,7,2,2,2,3,8,1,2,1,7,3,3,9,19,1,2,7,2,2,2,22,2,9,2,4,3,8,2,2,2,3,8,1,8,0,2,3,3,9,19,1,2,7,2,2,2,22,2,15,4,7,2,2,2,3,10,0,9,3,3,9,11,5,3,1,2,17,4,23,2,8,2,0,3,6,4,0,5,5,2,0,2,7,19,1,14,57,6,14,2,9,40,1,2,0,3,1,2,0,3,0,7,3,2,6,2,2,2,0,2,0,3,1,2,12,2,2,3,4,2,0,2,5,3,9,3,1,35,0,24,1,7,9,12,0,2,0,2,0,5,9,2,35,5,19,2,5,5,7,2,35,10,0,58,73,7,77,3,37,11,42,2,0,4,328,2,3,3,6,2,0,2,3,3,40,2,3,3,32,2,3,3,6,2,0,2,3,3,14,2,56,2,3,3,66,5,0,33,15,17,84,13,619,3,16,2,25,6,74,22,12,2,6,12,20,12,19,13,12,2,2,2,1,13,51,3,29,4,0,5,1,3,9,34,2,3,9,7,87,9,42,6,69,11,28,4,11,5,11,11,39,3,4,12,43,5,25,7,10,38,27,5,62,2,28,3,10,7,9,14,0,89,75,5,9,18,8,13,42,4,11,71,55,9,9,4,48,83,2,2,30,14,230,23,280,3,5,3,37,3,5,3,7,2,0,2,0,2,0,2,30,3,52,2,6,2,0,4,2,2,6,4,3,3,5,5,12,6,2,2,6,67,1,20,0,29,0,14,0,17,4,60,12,5,0,4,11,18,0,5,0,3,9,2,0,4,4,7,0,2,0,2,0,2,3,2,10,3,3,6,4,5,0,53,1,2684,46,2,46,2,132,7,6,15,37,11,53,10,0,17,22,10,6,2,6,2,6,2,6,2,6,2,6,2,6,2,6,2,31,48,0,470,1,36,5,2,4,6,1,5,85,3,1,3,2,2,89,2,3,6,40,4,93,18,23,57,15,513,6581,75,20939,53,1164,68,45,3,268,4,27,21,31,3,13,13,1,2,24,9,69,11,1,38,8,3,102,3,1,111,44,25,51,13,68,12,9,7,23,4,0,5,45,3,35,13,28,4,64,15,10,39,54,10,13,3,9,7,22,4,1,5,66,25,2,227,42,2,1,3,9,7,11171,13,22,5,48,8453,301,3,61,3,105,39,6,13,4,6,11,2,12,2,4,2,0,2,1,2,1,2,107,34,362,19,63,3,53,41,11,5,15,17,6,13,1,25,2,33,4,2,134,20,9,8,25,5,0,2,25,12,88,4,5,3,5,3,5,3,2],i=0,s=[];for(var o=0;o<r.length;o+=2)s.push(i+=r[o]),r[o+1]&&s.push(45,i+=r[o+1]);t.wordChars=String.fromCharCode.apply(null,s)}),ace.define("ace/mode/text",["require","exports","module","ace/config","ace/tokenizer","ace/mode/text_highlight_rules","ace/mode/behaviour/cstyle","ace/unicode","ace/lib/lang","ace/token_iterator","ace/range"],function(e,t,n){"use strict";var r=e("../config"),i=e("../tokenizer").Tokenizer,s=e("./text_highlight_rules").TextHighlightRules,o=e("./behaviour/cstyle").CstyleBehaviour,u=e("../unicode"),a=e("../lib/lang"),f=e("../token_iterator").TokenIterator,l=e("../range").Range,c=function(){this.HighlightRules=s};(function(){this.$defaultBehaviour=new o,this.tokenRe=new RegExp("^["+u.wordChars+"\\$_]+","g"),this.nonTokenRe=new RegExp("^(?:[^"+u.wordChars+"\\$_]|\\s])+","g"),this.getTokenizer=function(){return this.$tokenizer||(this.$highlightRules=this.$highlightRules||new this.HighlightRules(this.$highlightRuleConfig),this.$tokenizer=new i(this.$highlightRules.getRules())),this.$tokenizer},this.lineCommentStart="",this.blockComment="",this.toggleCommentLines=function(e,t,n,r){function w(e){for(var t=n;t<=r;t++)e(i.getLine(t),t)}var i=t.doc,s=!0,o=!0,u=Infinity,f=t.getTabSize(),l=!1;if(!this.lineCommentStart){if(!this.blockComment)return!1;var c=this.blockComment.start,h=this.blockComment.end,p=new RegExp("^(\\s*)(?:"+a.escapeRegExp(c)+")"),d=new RegExp("(?:"+a.escapeRegExp(h)+")\\s*$"),v=function(e,t){if(g(e,t))return;if(!s||/\S/.test(e))i.insertInLine({row:t,column:e.length},h),i.insertInLine({row:t,column:u},c)},m=function(e,t){var n;(n=e.match(d))&&i.removeInLine(t,e.length-n[0].length,e.length),(n=e.match(p))&&i.removeInLine(t,n[1].length,n[0].length)},g=function(e,n){if(p.test(e))return!0;var r=t.getTokens(n);for(var i=0;i<r.length;i++)if(r[i].type==="comment")return!0}}else{if(Array.isArray(this.lineCommentStart))var p=this.lineCommentStart.map(a.escapeRegExp).join("|"),c=this.lineCommentStart[0];else var p=a.escapeRegExp(this.lineCommentStart),c=this.lineCommentStart;p=new RegExp("^(\\s*)(?:"+p+") ?"),l=t.getUseSoftTabs();var m=function(e,t){var n=e.match(p);if(!n)return;var r=n[1].length,s=n[0].length;!b(e,r,s)&&n[0][s-1]==" "&&s--,i.removeInLine(t,r,s)},y=c+" ",v=function(e,t){if(!s||/\S/.test(e))b(e,u,u)?i.insertInLine({row:t,column:u},y):i.insertInLine({row:t,column:u},c)},g=function(e,t){return p.test(e)},b=function(e,t,n){var r=0;while(t--&&e.charAt(t)==" ")r++;if(r%f!=0)return!1;var r=0;while(e.charAt(n++)==" ")r++;return f>2?r%f!=f-1:r%f==0}}var E=Infinity;w(function(e,t){var n=e.search(/\S/);n!==-1?(n<u&&(u=n),o&&!g(e,t)&&(o=!1)):E>e.length&&(E=e.length)}),u==Infinity&&(u=E,s=!1,o=!1),l&&u%f!=0&&(u=Math.floor(u/f)*f),w(o?m:v)},this.toggleBlockComment=function(e,t,n,r){var i=this.blockComment;if(!i)return;!i.start&&i[0]&&(i=i[0]);var s=new f(t,r.row,r.column),o=s.getCurrentToken(),u=t.selection,a=t.selection.toOrientedRange(),c,h;if(o&&/comment/.test(o.type)){var p,d;while(o&&/comment/.test(o.type)){var v=o.value.indexOf(i.start);if(v!=-1){var m=s.getCurrentTokenRow(),g=s.getCurrentTokenColumn()+v;p=new l(m,g,m,g+i.start.length);break}o=s.stepBackward()}var s=new f(t,r.row,r.column),o=s.getCurrentToken();while(o&&/comment/.test(o.type)){var v=o.value.indexOf(i.end);if(v!=-1){var m=s.getCurrentTokenRow(),g=s.getCurrentTokenColumn()+v;d=new l(m,g,m,g+i.end.length);break}o=s.stepForward()}d&&t.remove(d),p&&(t.remove(p),c=p.start.row,h=-i.start.length)}else h=i.start.length,c=n.start.row,t.insert(n.end,i.end),t.insert(n.start,i.start);a.start.row==c&&(a.start.column+=h),a.end.row==c&&(a.end.column+=h),t.selection.fromOrientedRange(a)},this.getNextLineIndent=function(e,t,n){return this.$getIndent(t)},this.checkOutdent=function(e,t,n){return!1},this.autoOutdent=function(e,t,n){},this.$getIndent=function(e){return e.match(/^\s*/)[0]},this.createWorker=function(e){return null},this.createModeDelegates=function(e){this.$embeds=[],this.$modes={};for(var t in e)if(e[t]){var n=e[t],i=n.prototype.$id,s=r.$modes[i];s||(r.$modes[i]=s=new n),r.$modes[t]||(r.$modes[t]=s),this.$embeds.push(t),this.$modes[t]=s}var o=["toggleBlockComment","toggleCommentLines","getNextLineIndent","checkOutdent","autoOutdent","transformAction","getCompletions"];for(var t=0;t<o.length;t++)(function(e){var n=o[t],r=e[n];e[o[t]]=function(){return this.$delegator(n,arguments,r)}})(this)},this.$delegator=function(e,t,n){var r=t[0]||"start";if(typeof r!="string"){if(Array.isArray(r[2])){var i=r[2][r[2].length-1],s=this.$modes[i];if(s)return s[e].apply(s,[r[1]].concat([].slice.call(t,1)))}r=r[0]||"start"}for(var o=0;o<this.$embeds.length;o++){if(!this.$modes[this.$embeds[o]])continue;var u=r.split(this.$embeds[o]);if(!u[0]&&u[1]){t[0]=u[1];var s=this.$modes[this.$embeds[o]];return s[e].apply(s,t)}}var a=n.apply(this,t);return n?a:undefined},this.transformAction=function(e,t,n,r,i){if(this.$behaviour){var s=this.$behaviour.getBehaviours();for(var o in s)if(s[o][t]){var u=s[o][t].apply(this,arguments);if(u)return u}}},this.getKeywords=function(e){if(!this.completionKeywords){var t=this.$tokenizer.rules,n=[];for(var r in t){var i=t[r];for(var s=0,o=i.length;s<o;s++)if(typeof i[s].token=="string")/keyword|support|storage/.test(i[s].token)&&n.push(i[s].regex);else if(typeof i[s].token=="object")for(var u=0,a=i[s].token.length;u<a;u++)if(/keyword|support|storage/.test(i[s].token[u])){var r=i[s].regex.match(/\(.+?\)/g)[u];n.push(r.substr(1,r.length-2))}}this.completionKeywords=n}return e?n.concat(this.$keywordList||[]):this.$keywordList},this.$createKeywordList=function(){return this.$highlightRules||this.getTokenizer(),this.$keywordList=this.$highlightRules.$keywordList||[]},this.getCompletions=function(e,t,n,r){var i=this.$keywordList||this.$createKeywordList();return i.map(function(e){return{name:e,value:e,score:0,meta:"keyword"}})},this.$id="ace/mode/text"}).call(c.prototype),t.Mode=c}),ace.define("ace/apply_delta",["require","exports","module"],function(e,t,n){"use strict";function r(e,t){throw console.log("Invalid Delta:",e),"Invalid Delta: "+t}function i(e,t){return t.row>=0&&t.row<e.length&&t.column>=0&&t.column<=e[t.row].length}function s(e,t){t.action!="insert"&&t.action!="remove"&&r(t,"delta.action must be 'insert' or 'remove'"),t.lines instanceof Array||r(t,"delta.lines must be an Array"),(!t.start||!t.end)&&r(t,"delta.start/end must be an present");var n=t.start;i(e,t.start)||r(t,"delta.start must be contained in document");var s=t.end;t.action=="remove"&&!i(e,s)&&r(t,"delta.end must contained in document for 'remove' actions");var o=s.row-n.row,u=s.column-(o==0?n.column:0);(o!=t.lines.length-1||t.lines[o].length!=u)&&r(t,"delta.range must match delta lines")}t.applyDelta=function(e,t,n){var r=t.start.row,i=t.start.column,s=e[r]||"";switch(t.action){case"insert":var o=t.lines;if(o.length===1)e[r]=s.substring(0,i)+t.lines[0]+s.substring(i);else{var u=[r,1].concat(t.lines);e.splice.apply(e,u),e[r]=s.substring(0,i)+e[r],e[r+t.lines.length-1]+=s.substring(i)}break;case"remove":var a=t.end.column,f=t.end.row;r===f?e[r]=s.substring(0,i)+s.substring(a):e.splice(r,f-r+1,s.substring(0,i)+e[f].substring(a))}}}),ace.define("ace/anchor",["require","exports","module","ace/lib/oop","ace/lib/event_emitter"],function(e,t,n){"use strict";var r=e("./lib/oop"),i=e("./lib/event_emitter").EventEmitter,s=t.Anchor=function(e,t,n){this.$onChange=this.onChange.bind(this),this.attach(e),typeof n=="undefined"?this.setPosition(t.row,t.column):this.setPosition(t,n)};(function(){function e(e,t,n){var r=n?e.column<=t.column:e.column<t.column;return e.row<t.row||e.row==t.row&&r}function t(t,n,r){var i=t.action=="insert",s=(i?1:-1)*(t.end.row-t.start.row),o=(i?1:-1)*(t.end.column-t.start.column),u=t.start,a=i?u:t.end;return e(n,u,r)?{row:n.row,column:n.column}:e(a,n,!r)?{row:n.row+s,column:n.column+(n.row==a.row?o:0)}:{row:u.row,column:u.column}}r.implement(this,i),this.getPosition=function(){return this.$clipPositionToDocument(this.row,this.column)},this.getDocument=function(){return this.document},this.$insertRight=!1,this.onChange=function(e){if(e.start.row==e.end.row&&e.start.row!=this.row)return;if(e.start.row>this.row)return;var n=t(e,{row:this.row,column:this.column},this.$insertRight);this.setPosition(n.row,n.column,!0)},this.setPosition=function(e,t,n){var r;n?r={row:e,column:t}:r=this.$clipPositionToDocument(e,t);if(this.row==r.row&&this.column==r.column)return;var i={row:this.row,column:this.column};this.row=r.row,this.column=r.column,this._signal("change",{old:i,value:r})},this.detach=function(){this.document.off("change",this.$onChange)},this.attach=function(e){this.document=e||this.document,this.document.on("change",this.$onChange)},this.$clipPositionToDocument=function(e,t){var n={};return e>=this.document.getLength()?(n.row=Math.max(0,this.document.getLength()-1),n.column=this.document.getLine(n.row).length):e<0?(n.row=0,n.column=0):(n.row=e,n.column=Math.min(this.document.getLine(n.row).length,Math.max(0,t))),t<0&&(n.column=0),n}}).call(s.prototype)}),ace.define("ace/document",["require","exports","module","ace/lib/oop","ace/apply_delta","ace/lib/event_emitter","ace/range","ace/anchor"],function(e,t,n){"use strict";var r=e("./lib/oop"),i=e("./apply_delta").applyDelta,s=e("./lib/event_emitter").EventEmitter,o=e("./range").Range,u=e("./anchor").Anchor,a=function(e){this.$lines=[""],e.length===0?this.$lines=[""]:Array.isArray(e)?this.insertMergedLines({row:0,column:0},e):this.insert({row:0,column:0},e)};(function(){r.implement(this,s),this.setValue=function(e){var t=this.getLength()-1;this.remove(new o(0,0,t,this.getLine(t).length)),this.insert({row:0,column:0},e)},this.getValue=function(){return this.getAllLines().join(this.getNewLineCharacter())},this.createAnchor=function(e,t){return new u(this,e,t)},"aaa".split(/a/).length===0?this.$split=function(e){return e.replace(/\r\n|\r/g,"\n").split("\n")}:this.$split=function(e){return e.split(/\r\n|\r|\n/)},this.$detectNewLine=function(e){var t=e.match(/^.*?(\r\n|\r|\n)/m);this.$autoNewLine=t?t[1]:"\n",this._signal("changeNewLineMode")},this.getNewLineCharacter=function(){switch(this.$newLineMode){case"windows":return"\r\n";case"unix":return"\n";default:return this.$autoNewLine||"\n"}},this.$autoNewLine="",this.$newLineMode="auto",this.setNewLineMode=function(e){if(this.$newLineMode===e)return;this.$newLineMode=e,this._signal("changeNewLineMode")},this.getNewLineMode=function(){return this.$newLineMode},this.isNewLine=function(e){return e=="\r\n"||e=="\r"||e=="\n"},this.getLine=function(e){return this.$lines[e]||""},this.getLines=function(e,t){return this.$lines.slice(e,t+1)},this.getAllLines=function(){return this.getLines(0,this.getLength())},this.getLength=function(){return this.$lines.length},this.getTextRange=function(e){return this.getLinesForRange(e).join(this.getNewLineCharacter())},this.getLinesForRange=function(e){var t;if(e.start.row===e.end.row)t=[this.getLine(e.start.row).substring(e.start.column,e.end.column)];else{t=this.getLines(e.start.row,e.end.row),t[0]=(t[0]||"").substring(e.start.column);var n=t.length-1;e.end.row-e.start.row==n&&(t[n]=t[n].substring(0,e.end.column))}return t},this.insertLines=function(e,t){return console.warn("Use of document.insertLines is deprecated. Use the insertFullLines method instead."),this.insertFullLines(e,t)},this.removeLines=function(e,t){return console.warn("Use of document.removeLines is deprecated. Use the removeFullLines method instead."),this.removeFullLines(e,t)},this.insertNewLine=function(e){return console.warn("Use of document.insertNewLine is deprecated. Use insertMergedLines(position, ['', '']) instead."),this.insertMergedLines(e,["",""])},this.insert=function(e,t){return this.getLength()<=1&&this.$detectNewLine(t),this.insertMergedLines(e,this.$split(t))},this.insertInLine=function(e,t){var n=this.clippedPos(e.row,e.column),r=this.pos(e.row,e.column+t.length);return this.applyDelta({start:n,end:r,action:"insert",lines:[t]},!0),this.clonePos(r)},this.clippedPos=function(e,t){var n=this.getLength();e===undefined?e=n:e<0?e=0:e>=n&&(e=n-1,t=undefined);var r=this.getLine(e);return t==undefined&&(t=r.length),t=Math.min(Math.max(t,0),r.length),{row:e,column:t}},this.clonePos=function(e){return{row:e.row,column:e.column}},this.pos=function(e,t){return{row:e,column:t}},this.$clipPosition=function(e){var t=this.getLength();return e.row>=t?(e.row=Math.max(0,t-1),e.column=this.getLine(t-1).length):(e.row=Math.max(0,e.row),e.column=Math.min(Math.max(e.column,0),this.getLine(e.row).length)),e},this.insertFullLines=function(e,t){e=Math.min(Math.max(e,0),this.getLength());var n=0;e<this.getLength()?(t=t.concat([""]),n=0):(t=[""].concat(t),e--,n=this.$lines[e].length),this.insertMergedLines({row:e,column:n},t)},this.insertMergedLines=function(e,t){var n=this.clippedPos(e.row,e.column),r={row:n.row+t.length-1,column:(t.length==1?n.column:0)+t[t.length-1].length};return this.applyDelta({start:n,end:r,action:"insert",lines:t}),this.clonePos(r)},this.remove=function(e){var t=this.clippedPos(e.start.row,e.start.column),n=this.clippedPos(e.end.row,e.end.column);return this.applyDelta({start:t,end:n,action:"remove",lines:this.getLinesForRange({start:t,end:n})}),this.clonePos(t)},this.removeInLine=function(e,t,n){var r=this.clippedPos(e,t),i=this.clippedPos(e,n);return this.applyDelta({start:r,end:i,action:"remove",lines:this.getLinesForRange({start:r,end:i})},!0),this.clonePos(r)},this.removeFullLines=function(e,t){e=Math.min(Math.max(0,e),this.getLength()-1),t=Math.min(Math.max(0,t),this.getLength()-1);var n=t==this.getLength()-1&&e>0,r=t<this.getLength()-1,i=n?e-1:e,s=n?this.getLine(i).length:0,u=r?t+1:t,a=r?0:this.getLine(u).length,f=new o(i,s,u,a),l=this.$lines.slice(e,t+1);return this.applyDelta({start:f.start,end:f.end,action:"remove",lines:this.getLinesForRange(f)}),l},this.removeNewLine=function(e){e<this.getLength()-1&&e>=0&&this.applyDelta({start:this.pos(e,this.getLine(e).length),end:this.pos(e+1,0),action:"remove",lines:["",""]})},this.replace=function(e,t){e instanceof o||(e=o.fromPoints(e.start,e.end));if(t.length===0&&e.isEmpty())return e.start;if(t==this.getTextRange(e))return e.end;this.remove(e);var n;return t?n=this.insert(e.start,t):n=e.start,n},this.applyDeltas=function(e){for(var t=0;t<e.length;t++)this.applyDelta(e[t])},this.revertDeltas=function(e){for(var t=e.length-1;t>=0;t--)this.revertDelta(e[t])},this.applyDelta=function(e,t){var n=e.action=="insert";if(n?e.lines.length<=1&&!e.lines[0]:!o.comparePoints(e.start,e.end))return;n&&e.lines.length>2e4?this.$splitAndapplyLargeDelta(e,2e4):(i(this.$lines,e,t),this._signal("change",e))},this.$safeApplyDelta=function(e){var t=this.$lines.length;(e.action=="remove"&&e.start.row<t&&e.end.row<t||e.action=="insert"&&e.start.row<=t)&&this.applyDelta(e)},this.$splitAndapplyLargeDelta=function(e,t){var n=e.lines,r=n.length-t+1,i=e.start.row,s=e.start.column;for(var o=0,u=0;o<r;o=u){u+=t-1;var a=n.slice(o,u);a.push(""),this.applyDelta({start:this.pos(i+o,s),end:this.pos(i+u,s=0),action:e.action,lines:a},!0)}e.lines=n.slice(o),e.start.row=i+o,e.start.column=s,this.applyDelta(e,!0)},this.revertDelta=function(e){this.$safeApplyDelta({start:this.clonePos(e.start),end:this.clonePos(e.end),action:e.action=="insert"?"remove":"insert",lines:e.lines.slice()})},this.indexToPosition=function(e,t){var n=this.$lines||this.getAllLines(),r=this.getNewLineCharacter().length;for(var i=t||0,s=n.length;i<s;i++){e-=n[i].length+r;if(e<0)return{row:i,column:e+n[i].length+r}}return{row:s-1,column:e+n[s-1].length+r}},this.positionToIndex=function(e,t){var n=this.$lines||this.getAllLines(),r=this.getNewLineCharacter().length,i=0,s=Math.min(e.row,n.length);for(var o=t||0;o<s;++o)i+=n[o].length+r;return i+e.column}}).call(a.prototype),t.Document=a}),ace.define("ace/background_tokenizer",["require","exports","module","ace/lib/oop","ace/lib/event_emitter"],function(e,t,n){"use strict";var r=e("./lib/oop"),i=e("./lib/event_emitter").EventEmitter,s=function(e,t){this.running=!1,this.lines=[],this.states=[],this.currentLine=0,this.tokenizer=e;var n=this;this.$worker=function(){if(!n.running)return;var e=new Date,t=n.currentLine,r=-1,i=n.doc,s=t;while(n.lines[t])t++;var o=i.getLength(),u=0;n.running=!1;while(t<o){n.$tokenizeRow(t),r=t;do t++;while(n.lines[t]);u++;if(u%5===0&&new Date-e>20){n.running=setTimeout(n.$worker,20);break}}n.currentLine=t,r==-1&&(r=t),s<=r&&n.fireUpdateEvent(s,r)}};(function(){r.implement(this,i),this.setTokenizer=function(e){this.tokenizer=e,this.lines=[],this.states=[],this.start(0)},this.setDocument=function(e){this.doc=e,this.lines=[],this.states=[],this.stop()},this.fireUpdateEvent=function(e,t){var n={first:e,last:t};this._signal("update",{data:n})},this.start=function(e){this.currentLine=Math.min(e||0,this.currentLine,this.doc.getLength()),this.lines.splice(this.currentLine,this.lines.length),this.states.splice(this.currentLine,this.states.length),this.stop(),this.running=setTimeout(this.$worker,700)},this.scheduleStart=function(){this.running||(this.running=setTimeout(this.$worker,700))},this.$updateOnChange=function(e){var t=e.start.row,n=e.end.row-t;if(n===0)this.lines[t]=null;else if(e.action=="remove")this.lines.splice(t,n+1,null),this.states.splice(t,n+1,null);else{var r=Array(n+1);r.unshift(t,1),this.lines.splice.apply(this.lines,r),this.states.splice.apply(this.states,r)}this.currentLine=Math.min(t,this.currentLine,this.doc.getLength()),this.stop()},this.stop=function(){this.running&&clearTimeout(this.running),this.running=!1},this.getTokens=function(e){return this.lines[e]||this.$tokenizeRow(e)},this.getState=function(e){return this.currentLine==e&&this.$tokenizeRow(e),this.states[e]||"start"},this.$tokenizeRow=function(e){var t=this.doc.getLine(e),n=this.states[e-1],r=this.tokenizer.getLineTokens(t,n,e);return this.states[e]+""!=r.state+""?(this.states[e]=r.state,this.lines[e+1]=null,this.currentLine>e+1&&(this.currentLine=e+1)):this.currentLine==e&&(this.currentLine=e+1),this.lines[e]=r.tokens}}).call(s.prototype),t.BackgroundTokenizer=s}),ace.define("ace/search_highlight",["require","exports","module","ace/lib/lang","ace/lib/oop","ace/range"],function(e,t,n){"use strict";var r=e("./lib/lang"),i=e("./lib/oop"),s=e("./range").Range,o=function(e,t,n){this.setRegexp(e),this.clazz=t,this.type=n||"text"};(function(){this.MAX_RANGES=500,this.setRegexp=function(e){if(this.regExp+""==e+"")return;this.regExp=e,this.cache=[]},this.update=function(e,t,n,i){if(!this.regExp)return;var o=i.firstRow,u=i.lastRow;for(var a=o;a<=u;a++){var f=this.cache[a];f==null&&(f=r.getMatchOffsets(n.getLine(a),this.regExp),f.length>this.MAX_RANGES&&(f=f.slice(0,this.MAX_RANGES)),f=f.map(function(e){return new s(a,e.offset,a,e.offset+e.length)}),this.cache[a]=f.length?f:"");for(var l=f.length;l--;)t.drawSingleLineMarker(e,f[l].toScreenRange(n),this.clazz,i)}}}).call(o.prototype),t.SearchHighlight=o}),ace.define("ace/edit_session/fold_line",["require","exports","module","ace/range"],function(e,t,n){"use strict";function i(e,t){this.foldData=e,Array.isArray(t)?this.folds=t:t=this.folds=[t];var n=t[t.length-1];this.range=new r(t[0].start.row,t[0].start.column,n.end.row,n.end.column),this.start=this.range.start,this.end=this.range.end,this.folds.forEach(function(e){e.setFoldLine(this)},this)}var r=e("../range").Range;(function(){this.shiftRow=function(e){this.start.row+=e,this.end.row+=e,this.folds.forEach(function(t){t.start.row+=e,t.end.row+=e})},this.addFold=function(e){if(e.sameRow){if(e.start.row<this.startRow||e.endRow>this.endRow)throw new Error("Can't add a fold to this FoldLine as it has no connection");this.folds.push(e),this.folds.sort(function(e,t){return-e.range.compareEnd(t.start.row,t.start.column)}),this.range.compareEnd(e.start.row,e.start.column)>0?(this.end.row=e.end.row,this.end.column=e.end.column):this.range.compareStart(e.end.row,e.end.column)<0&&(this.start.row=e.start.row,this.start.column=e.start.column)}else if(e.start.row==this.end.row)this.folds.push(e),this.end.row=e.end.row,this.end.column=e.end.column;else{if(e.end.row!=this.start.row)throw new Error("Trying to add fold to FoldRow that doesn't have a matching row");this.folds.unshift(e),this.start.row=e.start.row,this.start.column=e.start.column}e.foldLine=this},this.containsRow=function(e){return e>=this.start.row&&e<=this.end.row},this.walk=function(e,t,n){var r=0,i=this.folds,s,o,u,a=!0;t==null&&(t=this.end.row,n=this.end.column);for(var f=0;f<i.length;f++){s=i[f],o=s.range.compareStart(t,n);if(o==-1){e(null,t,n,r,a);return}u=e(null,s.start.row,s.start.column,r,a),u=!u&&e(s.placeholder,s.start.row,s.start.column,r);if(u||o===0)return;a=!s.sameRow,r=s.end.column}e(null,t,n,r,a)},this.getNextFoldTo=function(e,t){var n,r;for(var i=0;i<this.folds.length;i++){n=this.folds[i],r=n.range.compareEnd(e,t);if(r==-1)return{fold:n,kind:"after"};if(r===0)return{fold:n,kind:"inside"}}return null},this.addRemoveChars=function(e,t,n){var r=this.getNextFoldTo(e,t),i,s;if(r){i=r.fold;if(r.kind=="inside"&&i.start.column!=t&&i.start.row!=e)window.console&&window.console.log(e,t,i);else if(i.start.row==e){s=this.folds;var o=s.indexOf(i);o===0&&(this.start.column+=n);for(o;o<s.length;o++){i=s[o],i.start.column+=n;if(!i.sameRow)return;i.end.column+=n}this.end.column+=n}}},this.split=function(e,t){var n=this.getNextFoldTo(e,t);if(!n||n.kind=="inside")return null;var r=n.fold,s=this.folds,o=this.foldData,u=s.indexOf(r),a=s[u-1];this.end.row=a.end.row,this.end.column=a.end.column,s=s.splice(u,s.length-u);var f=new i(o,s);return o.splice(o.indexOf(this)+1,0,f),f},this.merge=function(e){var t=e.folds;for(var n=0;n<t.length;n++)this.addFold(t[n]);var r=this.foldData;r.splice(r.indexOf(e),1)},this.toString=function(){var e=[this.range.toString()+": ["];return this.folds.forEach(function(t){e.push(" "+t.toString())}),e.push("]"),e.join("\n")},this.idxToPosition=function(e){var t=0;for(var n=0;n<this.folds.length;n++){var r=this.folds[n];e-=r.start.column-t;if(e<0)return{row:r.start.row,column:r.start.column+e};e-=r.placeholder.length;if(e<0)return r.start;t=r.end.column}return{row:this.end.row,column:this.end.column+e}}}).call(i.prototype),t.FoldLine=i}),ace.define("ace/range_list",["require","exports","module","ace/range"],function(e,t,n){"use strict";var r=e("./range").Range,i=r.comparePoints,s=function(){this.ranges=[],this.$bias=1};(function(){this.comparePoints=i,this.pointIndex=function(e,t,n){var r=this.ranges;for(var s=n||0;s<r.length;s++){var o=r[s],u=i(e,o.end);if(u>0)continue;var a=i(e,o.start);return u===0?t&&a!==0?-s-2:s:a>0||a===0&&!t?s:-s-1}return-s-1},this.add=function(e){var t=!e.isEmpty(),n=this.pointIndex(e.start,t);n<0&&(n=-n-1);var r=this.pointIndex(e.end,t,n);return r<0?r=-r-1:r++,this.ranges.splice(n,r-n,e)},this.addList=function(e){var t=[];for(var n=e.length;n--;)t.push.apply(t,this.add(e[n]));return t},this.substractPoint=function(e){var t=this.pointIndex(e);if(t>=0)return this.ranges.splice(t,1)},this.merge=function(){var e=[],t=this.ranges;t=t.sort(function(e,t){return i(e.start,t.start)});var n=t[0],r;for(var s=1;s<t.length;s++){r=n,n=t[s];var o=i(r.end,n.start);if(o<0)continue;if(o==0&&!r.isEmpty()&&!n.isEmpty())continue;i(r.end,n.end)<0&&(r.end.row=n.end.row,r.end.column=n.end.column),t.splice(s,1),e.push(n),n=r,s--}return this.ranges=t,e},this.contains=function(e,t){return this.pointIndex({row:e,column:t})>=0},this.containsPoint=function(e){return this.pointIndex(e)>=0},this.rangeAtPoint=function(e){var t=this.pointIndex(e);if(t>=0)return this.ranges[t]},this.clipRows=function(e,t){var n=this.ranges;if(n[0].start.row>t||n[n.length-1].start.row<e)return[];var r=this.pointIndex({row:e,column:0});r<0&&(r=-r-1);var i=this.pointIndex({row:t,column:0},r);i<0&&(i=-i-1);var s=[];for(var o=r;o<i;o++)s.push(n[o]);return s},this.removeAll=function(){return this.ranges.splice(0,this.ranges.length)},this.attach=function(e){this.session&&this.detach(),this.session=e,this.onChange=this.$onChange.bind(this),this.session.on("change",this.onChange)},this.detach=function(){if(!this.session)return;this.session.removeListener("change",this.onChange),this.session=null},this.$onChange=function(e){var t=e.start,n=e.end,r=t.row,i=n.row,s=this.ranges;for(var o=0,u=s.length;o<u;o++){var a=s[o];if(a.end.row>=r)break}if(e.action=="insert"){var f=i-r,l=-t.column+n.column;for(;o<u;o++){var a=s[o];if(a.start.row>r)break;a.start.row==r&&a.start.column>=t.column&&(a.start.column==t.column&&this.$bias<=0||(a.start.column+=l,a.start.row+=f));if(a.end.row==r&&a.end.column>=t.column){if(a.end.column==t.column&&this.$bias<0)continue;a.end.column==t.column&&l>0&&o<u-1&&a.end.column>a.start.column&&a.end.column==s[o+1].start.column&&(a.end.column-=l),a.end.column+=l,a.end.row+=f}}}else{var f=r-i,l=t.column-n.column;for(;o<u;o++){var a=s[o];if(a.start.row>i)break;if(a.end.row<i&&(r<a.end.row||r==a.end.row&&t.column<a.end.column))a.end.row=r,a.end.column=t.column;else if(a.end.row==i)if(a.end.column<=n.column){if(f||a.end.column>t.column)a.end.column=t.column,a.end.row=t.row}else a.end.column+=l,a.end.row+=f;else a.end.row>i&&(a.end.row+=f);if(a.start.row<i&&(r<a.start.row||r==a.start.row&&t.column<a.start.column))a.start.row=r,a.start.column=t.column;else if(a.start.row==i)if(a.start.column<=n.column){if(f||a.start.column>t.column)a.start.column=t.column,a.start.row=t.row}else a.start.column+=l,a.start.row+=f;else a.start.row>i&&(a.start.row+=f)}}if(f!=0&&o<u)for(;o<u;o++){var a=s[o];a.start.row+=f,a.end.row+=f}}}).call(s.prototype),t.RangeList=s}),ace.define("ace/edit_session/fold",["require","exports","module","ace/range_list","ace/lib/oop"],function(e,t,n){"use strict";function o(e,t){e.row-=t.row,e.row==0&&(e.column-=t.column)}function u(e,t){o(e.start,t),o(e.end,t)}function a(e,t){e.row==0&&(e.column+=t.column),e.row+=t.row}function f(e,t){a(e.start,t),a(e.end,t)}var r=e("../range_list").RangeList,i=e("../lib/oop"),s=t.Fold=function(e,t){this.foldLine=null,this.placeholder=t,this.range=e,this.start=e.start,this.end=e.end,this.sameRow=e.start.row==e.end.row,this.subFolds=this.ranges=[]};i.inherits(s,r),function(){this.toString=function(){return'"'+this.placeholder+'" '+this.range.toString()},this.setFoldLine=function(e){this.foldLine=e,this.subFolds.forEach(function(t){t.setFoldLine(e)})},this.clone=function(){var e=this.range.clone(),t=new s(e,this.placeholder);return this.subFolds.forEach(function(e){t.subFolds.push(e.clone())}),t.collapseChildren=this.collapseChildren,t},this.addSubFold=function(e){if(this.range.isEqual(e))return;u(e,this.start);var t=e.start.row,n=e.start.column;for(var r=0,i=-1;r<this.subFolds.length;r++){i=this.subFolds[r].range.compare(t,n);if(i!=1)break}var s=this.subFolds[r],o=0;if(i==0){if(s.range.containsRange(e))return s.addSubFold(e);o=1}var t=e.range.end.row,n=e.range.end.column;for(var a=r,i=-1;a<this.subFolds.length;a++){i=this.subFolds[a].range.compare(t,n);if(i!=1)break}i==0&&a++;var f=this.subFolds.splice(r,a-r,e),l=i==0?f.length-1:f.length;for(var c=o;c<l;c++)e.addSubFold(f[c]);return e.setFoldLine(this.foldLine),e},this.restoreRange=function(e){return f(e,this.start)}}.call(s.prototype)}),ace.define("ace/edit_session/folding",["require","exports","module","ace/range","ace/edit_session/fold_line","ace/edit_session/fold","ace/token_iterator"],function(e,t,n){"use strict";function u(){this.getFoldAt=function(e,t,n){var r=this.getFoldLine(e);if(!r)return null;var i=r.folds;for(var s=0;s<i.length;s++){var o=i[s].range;if(o.contains(e,t)){if(n==1&&o.isEnd(e,t)&&!o.isEmpty())continue;if(n==-1&&o.isStart(e,t)&&!o.isEmpty())continue;return i[s]}}},this.getFoldsInRange=function(e){var t=e.start,n=e.end,r=this.$foldData,i=[];t.column+=1,n.column-=1;for(var s=0;s<r.length;s++){var o=r[s].range.compareRange(e);if(o==2)continue;if(o==-2)break;var u=r[s].folds;for(var a=0;a<u.length;a++){var f=u[a];o=f.range.compareRange(e);if(o==-2)break;if(o==2)continue;if(o==42)break;i.push(f)}}return t.column-=1,n.column+=1,i},this.getFoldsInRangeList=function(e){if(Array.isArray(e)){var t=[];e.forEach(function(e){t=t.concat(this.getFoldsInRange(e))},this)}else var t=this.getFoldsInRange(e);return t},this.getAllFolds=function(){var e=[],t=this.$foldData;for(var n=0;n<t.length;n++)for(var r=0;r<t[n].folds.length;r++)e.push(t[n].folds[r]);return e},this.getFoldStringAt=function(e,t,n,r){r=r||this.getFoldLine(e);if(!r)return null;var i={end:{column:0}},s,o;for(var u=0;u<r.folds.length;u++){o=r.folds[u];var a=o.range.compareEnd(e,t);if(a==-1){s=this.getLine(o.start.row).substring(i.end.column,o.start.column);break}if(a===0)return null;i=o}return s||(s=this.getLine(o.start.row).substring(i.end.column)),n==-1?s.substring(0,t-i.end.column):n==1?s.substring(t-i.end.column):s},this.getFoldLine=function(e,t){var n=this.$foldData,r=0;t&&(r=n.indexOf(t)),r==-1&&(r=0);for(r;r<n.length;r++){var i=n[r];if(i.start.row<=e&&i.end.row>=e)return i;if(i.end.row>e)return null}return null},this.getNextFoldLine=function(e,t){var n=this.$foldData,r=0;t&&(r=n.indexOf(t)),r==-1&&(r=0);for(r;r<n.length;r++){var i=n[r];if(i.end.row>=e)return i}return null},this.getFoldedRowCount=function(e,t){var n=this.$foldData,r=t-e+1;for(var i=0;i<n.length;i++){var s=n[i],o=s.end.row,u=s.start.row;if(o>=t){u<t&&(u>=e?r-=t-u:r=0);break}o>=e&&(u>=e?r-=o-u:r-=o-e+1)}return r},this.$addFoldLine=function(e){return this.$foldData.push(e),this.$foldData.sort(function(e,t){return e.start.row-t.start.row}),e},this.addFold=function(e,t){var n=this.$foldData,r=!1,o;e instanceof s?o=e:(o=new s(t,e),o.collapseChildren=t.collapseChildren),this.$clipRangeToDocument(o.range);var u=o.start.row,a=o.start.column,f=o.end.row,l=o.end.column,c=this.getFoldAt(u,a,1),h=this.getFoldAt(f,l,-1);if(c&&h==c)return c.addSubFold(o);c&&!c.range.isStart(u,a)&&this.removeFold(c),h&&!h.range.isEnd(f,l)&&this.removeFold(h);var p=this.getFoldsInRange(o.range);p.length>0&&(this.removeFolds(p),o.collapseChildren||p.forEach(function(e){o.addSubFold(e)}));for(var d=0;d<n.length;d++){var v=n[d];if(f==v.start.row){v.addFold(o),r=!0;break}if(u==v.end.row){v.addFold(o),r=!0;if(!o.sameRow){var m=n[d+1];if(m&&m.start.row==f){v.merge(m);break}}break}if(f<=v.start.row)break}return r||(v=this.$addFoldLine(new i(this.$foldData,o))),this.$useWrapMode?this.$updateWrapData(v.start.row,v.start.row):this.$updateRowLengthCache(v.start.row,v.start.row),this.$modified=!0,this._signal("changeFold",{data:o,action:"add"}),o},this.addFolds=function(e){e.forEach(function(e){this.addFold(e)},this)},this.removeFold=function(e){var t=e.foldLine,n=t.start.row,r=t.end.row,i=this.$foldData,s=t.folds;if(s.length==1)i.splice(i.indexOf(t),1);else if(t.range.isEnd(e.end.row,e.end.column))s.pop(),t.end.row=s[s.length-1].end.row,t.end.column=s[s.length-1].end.column;else if(t.range.isStart(e.start.row,e.start.column))s.shift(),t.start.row=s[0].start.row,t.start.column=s[0].start.column;else if(e.sameRow)s.splice(s.indexOf(e),1);else{var o=t.split(e.start.row,e.start.column);s=o.folds,s.shift(),o.start.row=s[0].start.row,o.start.column=s[0].start.column}this.$updating||(this.$useWrapMode?this.$updateWrapData(n,r):this.$updateRowLengthCache(n,r)),this.$modified=!0,this._signal("changeFold",{data:e,action:"remove"})},this.removeFolds=function(e){var t=[];for(var n=0;n<e.length;n++)t.push(e[n]);t.forEach(function(e){this.removeFold(e)},this),this.$modified=!0},this.expandFold=function(e){this.removeFold(e),e.subFolds.forEach(function(t){e.restoreRange(t),this.addFold(t)},this),e.collapseChildren>0&&this.foldAll(e.start.row+1,e.end.row,e.collapseChildren-1),e.subFolds=[]},this.expandFolds=function(e){e.forEach(function(e){this.expandFold(e)},this)},this.unfold=function(e,t){var n,i;e==null?(n=new r(0,0,this.getLength(),0),t==null&&(t=!0)):typeof e=="number"?n=new r(e,0,e,this.getLine(e).length):"row"in e?n=r.fromPoints(e,e):n=e,i=this.getFoldsInRangeList(n),t!=0?this.removeFolds(i):this.expandFolds(i);if(i.length)return i},this.isRowFolded=function(e,t){return!!this.getFoldLine(e,t)},this.getRowFoldEnd=function(e,t){var n=this.getFoldLine(e,t);return n?n.end.row:e},this.getRowFoldStart=function(e,t){var n=this.getFoldLine(e,t);return n?n.start.row:e},this.getFoldDisplayLine=function(e,t,n,r,i){r==null&&(r=e.start.row),i==null&&(i=0),t==null&&(t=e.end.row),n==null&&(n=this.getLine(t).length);var s=this.doc,o="";return e.walk(function(e,t,n,u){if(t<r)return;if(t==r){if(n<i)return;u=Math.max(i,u)}e!=null?o+=e:o+=s.getLine(t).substring(u,n)},t,n),o},this.getDisplayLine=function(e,t,n,r){var i=this.getFoldLine(e);if(!i){var s;return s=this.doc.getLine(e),s.substring(r||0,t||s.length)}return this.getFoldDisplayLine(i,e,t,n,r)},this.$cloneFoldData=function(){var e=[];return e=this.$foldData.map(function(t){var n=t.folds.map(function(e){return e.clone()});return new i(e,n)}),e},this.toggleFold=function(e){var t=this.selection,n=t.getRange(),r,i;if(n.isEmpty()){var s=n.start;r=this.getFoldAt(s.row,s.column);if(r){this.expandFold(r);return}(i=this.findMatchingBracket(s))?n.comparePoint(i)==1?n.end=i:(n.start=i,n.start.column++,n.end.column--):(i=this.findMatchingBracket({row:s.row,column:s.column+1}))?(n.comparePoint(i)==1?n.end=i:n.start=i,n.start.column++):n=this.getCommentFoldRange(s.row,s.column)||n}else{var o=this.getFoldsInRange(n);if(e&&o.length){this.expandFolds(o);return}o.length==1&&(r=o[0])}r||(r=this.getFoldAt(n.start.row,n.start.column));if(r&&r.range.toString()==n.toString()){this.expandFold(r);return}var u="...";if(!n.isMultiLine()){u=this.getTextRange(n);if(u.length<4)return;u=u.trim().substring(0,2)+".."}this.addFold(u,n)},this.getCommentFoldRange=function(e,t,n){var i=new o(this,e,t),s=i.getCurrentToken(),u=s&&s.type;if(s&&/^comment|string/.test(u)){u=u.match(/comment|string/)[0],u=="comment"&&(u+="|doc-start");var a=new RegExp(u),f=new r;if(n!=1){do s=i.stepBackward();while(s&&a.test(s.type));i.stepForward()}f.start.row=i.getCurrentTokenRow(),f.start.column=i.getCurrentTokenColumn()+2,i=new o(this,e,t);if(n!=-1){var l=-1;do{s=i.stepForward();if(l==-1){var c=this.getState(i.$row);a.test(c)||(l=i.$row)}else if(i.$row>l)break}while(s&&a.test(s.type));s=i.stepBackward()}else s=i.getCurrentToken();return f.end.row=i.getCurrentTokenRow(),f.end.column=i.getCurrentTokenColumn()+s.value.length-2,f}},this.foldAll=function(e,t,n,r){n==undefined&&(n=1e5);var i=this.foldWidgets;if(!i)return;t=t||this.getLength(),e=e||0;for(var s=e;s<t;s++){i[s]==null&&(i[s]=this.getFoldWidget(s));if(i[s]!="start")continue;if(r&&!r(s))continue;var o=this.getFoldWidgetRange(s);o&&o.isMultiLine()&&o.end.row<=t&&o.start.row>=e&&(s=o.end.row,o.collapseChildren=n,this.addFold("...",o))}},this.foldToLevel=function(e){this.foldAll();while(e-->0)this.unfold(null,!1)},this.foldAllComments=function(){var e=this;this.foldAll(null,null,null,function(t){var n=e.getTokens(t);for(var r=0;r<n.length;r++){var i=n[r];if(i.type=="text"&&/^\s+$/.test(i.value))continue;return/comment/.test(i.type)?!0:!1}})},this.$foldStyles={manual:1,markbegin:1,markbeginend:1},this.$foldStyle="markbegin",this.setFoldStyle=function(e){if(!this.$foldStyles[e])throw new Error("invalid fold style: "+e+"["+Object.keys(this.$foldStyles).join(", ")+"]");if(this.$foldStyle==e)return;this.$foldStyle=e,e=="manual"&&this.unfold();var t=this.$foldMode;this.$setFolding(null),this.$setFolding(t)},this.$setFolding=function(e){if(this.$foldMode==e)return;this.$foldMode=e,this.off("change",this.$updateFoldWidgets),this.off("tokenizerUpdate",this.$tokenizerUpdateFoldWidgets),this._signal("changeAnnotation");if(!e||this.$foldStyle=="manual"){this.foldWidgets=null;return}this.foldWidgets=[],this.getFoldWidget=e.getFoldWidget.bind(e,this,this.$foldStyle),this.getFoldWidgetRange=e.getFoldWidgetRange.bind(e,this,this.$foldStyle),this.$updateFoldWidgets=this.updateFoldWidgets.bind(this),this.$tokenizerUpdateFoldWidgets=this.tokenizerUpdateFoldWidgets.bind(this),this.on("change",this.$updateFoldWidgets),this.on("tokenizerUpdate",this.$tokenizerUpdateFoldWidgets)},this.getParentFoldRangeData=function(e,t){var n=this.foldWidgets;if(!n||t&&n[e])return{};var r=e-1,i;while(r>=0){var s=n[r];s==null&&(s=n[r]=this.getFoldWidget(r));if(s=="start"){var o=this.getFoldWidgetRange(r);i||(i=o);if(o&&o.end.row>=e)break}r--}return{range:r!==-1&&o,firstRange:i}},this.onFoldWidgetClick=function(e,t){t=t.domEvent;var n={children:t.shiftKey,all:t.ctrlKey||t.metaKey,siblings:t.altKey},r=this.$toggleFoldWidget(e,n);if(!r){var i=t.target||t.srcElement;i&&/ace_fold-widget/.test(i.className)&&(i.className+=" ace_invalid")}},this.$toggleFoldWidget=function(e,t){if(!this.getFoldWidget)return;var n=this.getFoldWidget(e),r=this.getLine(e),i=n==="end"?-1:1,s=this.getFoldAt(e,i===-1?0:r.length,i);if(s)return t.children||t.all?this.removeFold(s):this.expandFold(s),s;var o=this.getFoldWidgetRange(e,!0);if(o&&!o.isMultiLine()){s=this.getFoldAt(o.start.row,o.start.column,1);if(s&&o.isEqual(s.range))return this.removeFold(s),s}if(t.siblings){var u=this.getParentFoldRangeData(e);if(u.range)var a=u.range.start.row+1,f=u.range.end.row;this.foldAll(a,f,t.all?1e4:0)}else t.children?(f=o?o.end.row:this.getLength(),this.foldAll(e+1,f,t.all?1e4:0)):o&&(t.all&&(o.collapseChildren=1e4),this.addFold("...",o));return o},this.toggleFoldWidget=function(e){var t=this.selection.getCursor().row;t=this.getRowFoldStart(t);var n=this.$toggleFoldWidget(t,{});if(n)return;var r=this.getParentFoldRangeData(t,!0);n=r.range||r.firstRange;if(n){t=n.start.row;var i=this.getFoldAt(t,this.getLine(t).length,1);i?this.removeFold(i):this.addFold("...",n)}},this.updateFoldWidgets=function(e){var t=e.start.row,n=e.end.row-t;if(n===0)this.foldWidgets[t]=null;else if(e.action=="remove")this.foldWidgets.splice(t,n+1,null);else{var r=Array(n+1);r.unshift(t,1),this.foldWidgets.splice.apply(this.foldWidgets,r)}},this.tokenizerUpdateFoldWidgets=function(e){var t=e.data;t.first!=t.last&&this.foldWidgets.length>t.first&&this.foldWidgets.splice(t.first,this.foldWidgets.length)}}var r=e("../range").Range,i=e("./fold_line").FoldLine,s=e("./fold").Fold,o=e("../token_iterator").TokenIterator;t.Folding=u}),ace.define("ace/edit_session/bracket_match",["require","exports","module","ace/token_iterator","ace/range"],function(e,t,n){"use strict";function s(){this.findMatchingBracket=function(e,t){if(e.column==0)return null;var n=t||this.getLine(e.row).charAt(e.column-1);if(n=="")return null;var r=n.match(/([\(\[\{])|([\)\]\}])/);return r?r[1]?this.$findClosingBracket(r[1],e):this.$findOpeningBracket(r[2],e):null},this.getBracketRange=function(e){var t=this.getLine(e.row),n=!0,r,s=t.charAt(e.column-1),o=s&&s.match(/([\(\[\{])|([\)\]\}])/);o||(s=t.charAt(e.column),e={row:e.row,column:e.column+1},o=s&&s.match(/([\(\[\{])|([\)\]\}])/),n=!1);if(!o)return null;if(o[1]){var u=this.$findClosingBracket(o[1],e);if(!u)return null;r=i.fromPoints(e,u),n||(r.end.column++,r.start.column--),r.cursor=r.end}else{var u=this.$findOpeningBracket(o[2],e);if(!u)return null;r=i.fromPoints(u,e),n||(r.start.column++,r.end.column--),r.cursor=r.start}return r},this.getMatchingBracketRanges=function(e){var t=this.getLine(e.row),n=t.charAt(e.column-1),r=n&&n.match(/([\(\[\{])|([\)\]\}])/);r||(n=t.charAt(e.column),e={row:e.row,column:e.column+1},r=n&&n.match(/([\(\[\{])|([\)\]\}])/));if(!r)return null;var s=new i(e.row,e.column-1,e.row,e.column),o=r[1]?this.$findClosingBracket(r[1],e):this.$findOpeningBracket(r[2],e);if(!o)return[s];var u=new i(o.row,o.column,o.row,o.column+1);return[s,u]},this.$brackets={")":"(","(":")","]":"[","[":"]","{":"}","}":"{","<":">",">":"<"},this.$findOpeningBracket=function(e,t,n){var i=this.$brackets[e],s=1,o=new r(this,t.row,t.column),u=o.getCurrentToken();u||(u=o.stepForward());if(!u)return;n||(n=new RegExp("(\\.?"+u.type.replace(".","\\.").replace("rparen",".paren").replace(/\b(?:end)\b/,"(?:start|begin|end)")+")+"));var a=t.column-o.getCurrentTokenColumn()-2,f=u.value;for(;;){while(a>=0){var l=f.charAt(a);if(l==i){s-=1;if(s==0)return{row:o.getCurrentTokenRow(),column:a+o.getCurrentTokenColumn()}}else l==e&&(s+=1);a-=1}do u=o.stepBackward();while(u&&!n.test(u.type));if(u==null)break;f=u.value,a=f.length-1}return null},this.$findClosingBracket=function(e,t,n){var i=this.$brackets[e],s=1,o=new r(this,t.row,t.column),u=o.getCurrentToken();u||(u=o.stepForward());if(!u)return;n||(n=new RegExp("(\\.?"+u.type.replace(".","\\.").replace("lparen",".paren").replace(/\b(?:start|begin)\b/,"(?:start|begin|end)")+")+"));var a=t.column-o.getCurrentTokenColumn();for(;;){var f=u.value,l=f.length;while(a<l){var c=f.charAt(a);if(c==i){s-=1;if(s==0)return{row:o.getCurrentTokenRow(),column:a+o.getCurrentTokenColumn()}}else c==e&&(s+=1);a+=1}do u=o.stepForward();while(u&&!n.test(u.type));if(u==null)break;a=0}return null}}var r=e("../token_iterator").TokenIterator,i=e("../range").Range;t.BracketMatch=s}),ace.define("ace/edit_session",["require","exports","module","ace/lib/oop","ace/lib/lang","ace/bidihandler","ace/config","ace/lib/event_emitter","ace/selection","ace/mode/text","ace/range","ace/document","ace/background_tokenizer","ace/search_highlight","ace/edit_session/folding","ace/edit_session/bracket_match"],function(e,t,n){"use strict";var r=e("./lib/oop"),i=e("./lib/lang"),s=e("./bidihandler").BidiHandler,o=e("./config"),u=e("./lib/event_emitter").EventEmitter,a=e("./selection").Selection,f=e("./mode/text").Mode,l=e("./range").Range,c=e("./document").Document,h=e("./background_tokenizer").BackgroundTokenizer,p=e("./search_highlight").SearchHighlight,d=function(e,t){this.$breakpoints=[],this.$decorations=[],this.$frontMarkers={},this.$backMarkers={},this.$markerId=1,this.$undoSelect=!0,this.$foldData=[],this.id="session"+ ++d.$uid,this.$foldData.toString=function(){return this.join("\n")},this.on("changeFold",this.onChangeFold.bind(this)),this.$onChange=this.onChange.bind(this);if(typeof e!="object"||!e.getLine)e=new c(e);this.setDocument(e),this.selection=new a(this),this.$bidiHandler=new s(this),o.resetOptions(this),this.setMode(t),o._signal("session",this)};d.$uid=0,function(){function m(e){return e<4352?!1:e>=4352&&e<=4447||e>=4515&&e<=4519||e>=4602&&e<=4607||e>=9001&&e<=9002||e>=11904&&e<=11929||e>=11931&&e<=12019||e>=12032&&e<=12245||e>=12272&&e<=12283||e>=12288&&e<=12350||e>=12353&&e<=12438||e>=12441&&e<=12543||e>=12549&&e<=12589||e>=12593&&e<=12686||e>=12688&&e<=12730||e>=12736&&e<=12771||e>=12784&&e<=12830||e>=12832&&e<=12871||e>=12880&&e<=13054||e>=13056&&e<=19903||e>=19968&&e<=42124||e>=42128&&e<=42182||e>=43360&&e<=43388||e>=44032&&e<=55203||e>=55216&&e<=55238||e>=55243&&e<=55291||e>=63744&&e<=64255||e>=65040&&e<=65049||e>=65072&&e<=65106||e>=65108&&e<=65126||e>=65128&&e<=65131||e>=65281&&e<=65376||e>=65504&&e<=65510}r.implement(this,u),this.setDocument=function(e){this.doc&&this.doc.removeListener("change",this.$onChange),this.doc=e,e.on("change",this.$onChange),this.bgTokenizer&&this.bgTokenizer.setDocument(this.getDocument()),this.resetCaches()},this.getDocument=function(){return this.doc},this.$resetRowCache=function(e){if(!e){this.$docRowCache=[],this.$screenRowCache=[];return}var t=this.$docRowCache.length,n=this.$getRowCacheIndex(this.$docRowCache,e)+1;t>n&&(this.$docRowCache.splice(n,t),this.$screenRowCache.splice(n,t))},this.$getRowCacheIndex=function(e,t){var n=0,r=e.length-1;while(n<=r){var i=n+r>>1,s=e[i];if(t>s)n=i+1;else{if(!(t<s))return i;r=i-1}}return n-1},this.resetCaches=function(){this.$modified=!0,this.$wrapData=[],this.$rowLengthCache=[],this.$resetRowCache(0),this.bgTokenizer&&this.bgTokenizer.start(0)},this.onChangeFold=function(e){var t=e.data;this.$resetRowCache(t.start.row)},this.onChange=function(e){this.$modified=!0,this.$bidiHandler.onChange(e),this.$resetRowCache(e.start.row);var t=this.$updateInternalDataOnChange(e);!this.$fromUndo&&this.$undoManager&&(t&&t.length&&(this.$undoManager.add({action:"removeFolds",folds:t},this.mergeUndoDeltas),this.mergeUndoDeltas=!0),this.$undoManager.add(e,this.mergeUndoDeltas),this.mergeUndoDeltas=!0,this.$informUndoManager.schedule()),this.bgTokenizer&&this.bgTokenizer.$updateOnChange(e),this._signal("change",e)},this.setValue=function(e){this.doc.setValue(e),this.selection.moveTo(0,0),this.$resetRowCache(0),this.setUndoManager(this.$undoManager),this.getUndoManager().reset()},this.getValue=this.toString=function(){return this.doc.getValue()},this.getSelection=function(){return this.selection},this.getState=function(e){return this.bgTokenizer.getState(e)},this.getTokens=function(e){return this.bgTokenizer.getTokens(e)},this.getTokenAt=function(e,t){var n=this.bgTokenizer.getTokens(e),r,i=0;if(t==null){var s=n.length-1;i=this.getLine(e).length}else for(var s=0;s<n.length;s++){i+=n[s].value.length;if(i>=t)break}return r=n[s],r?(r.index=s,r.start=i-r.value.length,r):null},this.setUndoManager=function(e){this.$undoManager=e,this.$informUndoManager&&this.$informUndoManager.cancel();if(e){var t=this;e.addSession(this),this.$syncInformUndoManager=function(){t.$informUndoManager.cancel(),t.mergeUndoDeltas=!1},this.$informUndoManager=i.delayedCall(this.$syncInformUndoManager)}else this.$syncInformUndoManager=function(){}},this.markUndoGroup=function(){this.$syncInformUndoManager&&this.$syncInformUndoManager()},this.$defaultUndoManager={undo:function(){},redo:function(){},hasUndo:function(){},hasRedo:function(){},reset:function(){},add:function(){},addSelection:function(){},startNewGroup:function(){},addSession:function(){}},this.getUndoManager=function(){return this.$undoManager||this.$defaultUndoManager},this.getTabString=function(){return this.getUseSoftTabs()?i.stringRepeat(" ",this.getTabSize()):" "},this.setUseSoftTabs=function(e){this.setOption("useSoftTabs",e)},this.getUseSoftTabs=function(){return this.$useSoftTabs&&!this.$mode.$indentWithTabs},this.setTabSize=function(e){this.setOption("tabSize",e)},this.getTabSize=function(){return this.$tabSize},this.isTabStop=function(e){return this.$useSoftTabs&&e.column%this.$tabSize===0},this.setNavigateWithinSoftTabs=function(e){this.setOption("navigateWithinSoftTabs",e)},this.getNavigateWithinSoftTabs=function(){return this.$navigateWithinSoftTabs},this.$overwrite=!1,this.setOverwrite=function(e){this.setOption("overwrite",e)},this.getOverwrite=function(){return this.$overwrite},this.toggleOverwrite=function(){this.setOverwrite(!this.$overwrite)},this.addGutterDecoration=function(e,t){this.$decorations[e]||(this.$decorations[e]=""),this.$decorations[e]+=" "+t,this._signal("changeBreakpoint",{})},this.removeGutterDecoration=function(e,t){this.$decorations[e]=(this.$decorations[e]||"").replace(" "+t,""),this._signal("changeBreakpoint",{})},this.getBreakpoints=function(){return this.$breakpoints},this.setBreakpoints=function(e){this.$breakpoints=[];for(var t=0;t<e.length;t++)this.$breakpoints[e[t]]="ace_breakpoint";this._signal("changeBreakpoint",{})},this.clearBreakpoints=function(){this.$breakpoints=[],this._signal("changeBreakpoint",{})},this.setBreakpoint=function(e,t){t===undefined&&(t="ace_breakpoint"),t?this.$breakpoints[e]=t:delete this.$breakpoints[e],this._signal("changeBreakpoint",{})},this.clearBreakpoint=function(e){delete this.$breakpoints[e],this._signal("changeBreakpoint",{})},this.addMarker=function(e,t,n,r){var i=this.$markerId++,s={range:e,type:n||"line",renderer:typeof n=="function"?n:null,clazz:t,inFront:!!r,id:i};return r?(this.$frontMarkers[i]=s,this._signal("changeFrontMarker")):(this.$backMarkers[i]=s,this._signal("changeBackMarker")),i},this.addDynamicMarker=function(e,t){if(!e.update)return;var n=this.$markerId++;return e.id=n,e.inFront=!!t,t?(this.$frontMarkers[n]=e,this._signal("changeFrontMarker")):(this.$backMarkers[n]=e,this._signal("changeBackMarker")),e},this.removeMarker=function(e){var t=this.$frontMarkers[e]||this.$backMarkers[e];if(!t)return;var n=t.inFront?this.$frontMarkers:this.$backMarkers;delete n[e],this._signal(t.inFront?"changeFrontMarker":"changeBackMarker")},this.getMarkers=function(e){return e?this.$frontMarkers:this.$backMarkers},this.highlight=function(e){if(!this.$searchHighlight){var t=new p(null,"ace_selected-word","text");this.$searchHighlight=this.addDynamicMarker(t)}this.$searchHighlight.setRegexp(e)},this.highlightLines=function(e,t,n,r){typeof t!="number"&&(n=t,t=e),n||(n="ace_step");var i=new l(e,0,t,Infinity);return i.id=this.addMarker(i,n,"fullLine",r),i},this.setAnnotations=function(e){this.$annotations=e,this._signal("changeAnnotation",{})},this.getAnnotations=function(){return this.$annotations||[]},this.clearAnnotations=function(){this.setAnnotations([])},this.$detectNewLine=function(e){var t=e.match(/^.*?(\r?\n)/m);t?this.$autoNewLine=t[1]:this.$autoNewLine="\n"},this.getWordRange=function(e,t){var n=this.getLine(e),r=!1;t>0&&(r=!!n.charAt(t-1).match(this.tokenRe)),r||(r=!!n.charAt(t).match(this.tokenRe));if(r)var i=this.tokenRe;else if(/^\s+$/.test(n.slice(t-1,t+1)))var i=/\s/;else var i=this.nonTokenRe;var s=t;if(s>0){do s--;while(s>=0&&n.charAt(s).match(i));s++}var o=t;while(o<n.length&&n.charAt(o).match(i))o++;return new l(e,s,e,o)},this.getAWordRange=function(e,t){var n=this.getWordRange(e,t),r=this.getLine(n.end.row);while(r.charAt(n.end.column).match(/[ \t]/))n.end.column+=1;return n},this.setNewLineMode=function(e){this.doc.setNewLineMode(e)},this.getNewLineMode=function(){return this.doc.getNewLineMode()},this.setUseWorker=function(e){this.setOption("useWorker",e)},this.getUseWorker=function(){return this.$useWorker},this.onReloadTokenizer=function(e){var t=e.data;this.bgTokenizer.start(t.first),this._signal("tokenizerUpdate",e)},this.$modes=o.$modes,this.$mode=null,this.$modeId=null,this.setMode=function(e,t){if(e&&typeof e=="object"){if(e.getTokenizer)return this.$onChangeMode(e);var n=e,r=n.path}else r=e||"ace/mode/text";this.$modes["ace/mode/text"]||(this.$modes["ace/mode/text"]=new f);if(this.$modes[r]&&!n){this.$onChangeMode(this.$modes[r]),t&&t();return}this.$modeId=r,o.loadModule(["mode",r],function(e){if(this.$modeId!==r)return t&&t();this.$modes[r]&&!n?this.$onChangeMode(this.$modes[r]):e&&e.Mode&&(e=new e.Mode(n),n||(this.$modes[r]=e,e.$id=r),this.$onChangeMode(e)),t&&t()}.bind(this)),this.$mode||this.$onChangeMode(this.$modes["ace/mode/text"],!0)},this.$onChangeMode=function(e,t){t||(this.$modeId=e.$id);if(this.$mode===e)return;var n=this.$mode;this.$mode=e,this.$stopWorker(),this.$useWorker&&this.$startWorker();var r=e.getTokenizer();if(r.on!==undefined){var i=this.onReloadTokenizer.bind(this);r.on("update",i)}if(!this.bgTokenizer){this.bgTokenizer=new h(r);var s=this;this.bgTokenizer.on("update",function(e){s._signal("tokenizerUpdate",e)})}else this.bgTokenizer.setTokenizer(r);this.bgTokenizer.setDocument(this.getDocument()),this.tokenRe=e.tokenRe,this.nonTokenRe=e.nonTokenRe,t||(e.attachToSession&&e.attachToSession(this),this.$options.wrapMethod.set.call(this,this.$wrapMethod),this.$setFolding(e.foldingRules),this.bgTokenizer.start(0),this._emit("changeMode",{oldMode:n,mode:e}))},this.$stopWorker=function(){this.$worker&&(this.$worker.terminate(),this.$worker=null)},this.$startWorker=function(){try{this.$worker=this.$mode.createWorker(this)}catch(e){o.warn("Could not load worker",e),this.$worker=null}},this.getMode=function(){return this.$mode},this.$scrollTop=0,this.setScrollTop=function(e){if(this.$scrollTop===e||isNaN(e))return;this.$scrollTop=e,this._signal("changeScrollTop",e)},this.getScrollTop=function(){return this.$scrollTop},this.$scrollLeft=0,this.setScrollLeft=function(e){if(this.$scrollLeft===e||isNaN(e))return;this.$scrollLeft=e,this._signal("changeScrollLeft",e)},this.getScrollLeft=function(){return this.$scrollLeft},this.getScreenWidth=function(){return this.$computeWidth(),this.lineWidgets?Math.max(this.getLineWidgetMaxWidth(),this.screenWidth):this.screenWidth},this.getLineWidgetMaxWidth=function(){if(this.lineWidgetsWidth!=null)return this.lineWidgetsWidth;var e=0;return this.lineWidgets.forEach(function(t){t&&t.screenWidth>e&&(e=t.screenWidth)}),this.lineWidgetWidth=e},this.$computeWidth=function(e){if(this.$modified||e){this.$modified=!1;if(this.$useWrapMode)return this.screenWidth=this.$wrapLimit;var t=this.doc.getAllLines(),n=this.$rowLengthCache,r=0,i=0,s=this.$foldData[i],o=s?s.start.row:Infinity,u=t.length;for(var a=0;a<u;a++){if(a>o){a=s.end.row+1;if(a>=u)break;s=this.$foldData[i++],o=s?s.start.row:Infinity}n[a]==null&&(n[a]=this.$getStringScreenWidth(t[a])[0]),n[a]>r&&(r=n[a])}this.screenWidth=r}},this.getLine=function(e){return this.doc.getLine(e)},this.getLines=function(e,t){return this.doc.getLines(e,t)},this.getLength=function(){return this.doc.getLength()},this.getTextRange=function(e){return this.doc.getTextRange(e||this.selection.getRange())},this.insert=function(e,t){return this.doc.insert(e,t)},this.remove=function(e){return this.doc.remove(e)},this.removeFullLines=function(e,t){return this.doc.removeFullLines(e,t)},this.undoChanges=function(e,t){if(!e.length)return;this.$fromUndo=!0;for(var n=e.length-1;n!=-1;n--){var r=e[n];r.action=="insert"||r.action=="remove"?this.doc.revertDelta(r):r.folds&&this.addFolds(r.folds)}!t&&this.$undoSelect&&(e.selectionBefore?this.selection.fromJSON(e.selectionBefore):this.selection.setRange(this.$getUndoSelection(e,!0))),this.$fromUndo=!1},this.redoChanges=function(e,t){if(!e.length)return;this.$fromUndo=!0;for(var n=0;n<e.length;n++){var r=e[n];(r.action=="insert"||r.action=="remove")&&this.doc.$safeApplyDelta(r)}!t&&this.$undoSelect&&(e.selectionAfter?this.selection.fromJSON(e.selectionAfter):this.selection.setRange(this.$getUndoSelection(e,!1))),this.$fromUndo=!1},this.setUndoSelect=function(e){this.$undoSelect=e},this.$getUndoSelection=function(e,t){function n(e){return t?e.action!=="insert":e.action==="insert"}var r,i;for(var s=0;s<e.length;s++){var o=e[s];if(!o.start)continue;if(!r){n(o)?r=l.fromPoints(o.start,o.end):r=l.fromPoints(o.start,o.start);continue}n(o)?(i=o.start,r.compare(i.row,i.column)==-1&&r.setStart(i),i=o.end,r.compare(i.row,i.column)==1&&r.setEnd(i)):(i=o.start,r.compare(i.row,i.column)==-1&&(r=l.fromPoints(o.start,o.start)))}return r},this.replace=function(e,t){return this.doc.replace(e,t)},this.moveText=function(e,t,n){var r=this.getTextRange(e),i=this.getFoldsInRange(e),s=l.fromPoints(t,t);if(!n){this.remove(e);var o=e.start.row-e.end.row,u=o?-e.end.column:e.start.column-e.end.column;u&&(s.start.row==e.end.row&&s.start.column>e.end.column&&(s.start.column+=u),s.end.row==e.end.row&&s.end.column>e.end.column&&(s.end.column+=u)),o&&s.start.row>=e.end.row&&(s.start.row+=o,s.end.row+=o)}s.end=this.insert(s.start,r);if(i.length){var a=e.start,f=s.start,o=f.row-a.row,u=f.column-a.column;this.addFolds(i.map(function(e){return e=e.clone(),e.start.row==a.row&&(e.start.column+=u),e.end.row==a.row&&(e.end.column+=u),e.start.row+=o,e.end.row+=o,e}))}return s},this.indentRows=function(e,t,n){n=n.replace(/\t/g,this.getTabString());for(var r=e;r<=t;r++)this.doc.insertInLine({row:r,column:0},n)},this.outdentRows=function(e){var t=e.collapseRows(),n=new l(0,0,0,0),r=this.getTabSize();for(var i=t.start.row;i<=t.end.row;++i){var s=this.getLine(i);n.start.row=i,n.end.row=i;for(var o=0;o<r;++o)if(s.charAt(o)!=" ")break;o<r&&s.charAt(o)==" "?(n.start.column=o,n.end.column=o+1):(n.start.column=0,n.end.column=o),this.remove(n)}},this.$moveLines=function(e,t,n){e=this.getRowFoldStart(e),t=this.getRowFoldEnd(t);if(n<0){var r=this.getRowFoldStart(e+n);if(r<0)return 0;var i=r-e}else if(n>0){var r=this.getRowFoldEnd(t+n);if(r>this.doc.getLength()-1)return 0;var i=r-t}else{e=this.$clipRowToDocument(e),t=this.$clipRowToDocument(t);var i=t-e+1}var s=new l(e,0,t,Number.MAX_VALUE),o=this.getFoldsInRange(s).map(function(e){return e=e.clone(),e.start.row+=i,e.end.row+=i,e}),u=n==0?this.doc.getLines(e,t):this.doc.removeFullLines(e,t);return this.doc.insertFullLines(e+i,u),o.length&&this.addFolds(o),i},this.moveLinesUp=function(e,t){return this.$moveLines(e,t,-1)},this.moveLinesDown=function(e,t){return this.$moveLines(e,t,1)},this.duplicateLines=function(e,t){return this.$moveLines(e,t,0)},this.$clipRowToDocument=function(e){return Math.max(0,Math.min(e,this.doc.getLength()-1))},this.$clipColumnToRow=function(e,t){return t<0?0:Math.min(this.doc.getLine(e).length,t)},this.$clipPositionToDocument=function(e,t){t=Math.max(0,t);if(e<0)e=0,t=0;else{var n=this.doc.getLength();e>=n?(e=n-1,t=this.doc.getLine(n-1).length):t=Math.min(this.doc.getLine(e).length,t)}return{row:e,column:t}},this.$clipRangeToDocument=function(e){e.start.row<0?(e.start.row=0,e.start.column=0):e.start.column=this.$clipColumnToRow(e.start.row,e.start.column);var t=this.doc.getLength()-1;return e.end.row>t?(e.end.row=t,e.end.column=this.doc.getLine(t).length):e.end.column=this.$clipColumnToRow(e.end.row,e.end.column),e},this.$wrapLimit=80,this.$useWrapMode=!1,this.$wrapLimitRange={min:null,max:null},this.setUseWrapMode=function(e){if(e!=this.$useWrapMode){this.$useWrapMode=e,this.$modified=!0,this.$resetRowCache(0);if(e){var t=this.getLength();this.$wrapData=Array(t),this.$updateWrapData(0,t-1)}this._signal("changeWrapMode")}},this.getUseWrapMode=function(){return this.$useWrapMode},this.setWrapLimitRange=function(e,t){if(this.$wrapLimitRange.min!==e||this.$wrapLimitRange.max!==t)this.$wrapLimitRange={min:e,max:t},this.$modified=!0,this.$bidiHandler.markAsDirty(),this.$useWrapMode&&this._signal("changeWrapMode")},this.adjustWrapLimit=function(e,t){var n=this.$wrapLimitRange;n.max<0&&(n={min:t,max:t});var r=this.$constrainWrapLimit(e,n.min,n.max);return r!=this.$wrapLimit&&r>1?(this.$wrapLimit=r,this.$modified=!0,this.$useWrapMode&&(this.$updateWrapData(0,this.getLength()-1),this.$resetRowCache(0),this._signal("changeWrapLimit")),!0):!1},this.$constrainWrapLimit=function(e,t,n){return t&&(e=Math.max(t,e)),n&&(e=Math.min(n,e)),e},this.getWrapLimit=function(){return this.$wrapLimit},this.setWrapLimit=function(e){this.setWrapLimitRange(e,e)},this.getWrapLimitRange=function(){return{min:this.$wrapLimitRange.min,max:this.$wrapLimitRange.max}},this.$updateInternalDataOnChange=function(e){var t=this.$useWrapMode,n=e.action,r=e.start,i=e.end,s=r.row,o=i.row,u=o-s,a=null;this.$updating=!0;if(u!=0)if(n==="remove"){this[t?"$wrapData":"$rowLengthCache"].splice(s,u);var f=this.$foldData;a=this.getFoldsInRange(e),this.removeFolds(a);var l=this.getFoldLine(i.row),c=0;if(l){l.addRemoveChars(i.row,i.column,r.column-i.column),l.shiftRow(-u);var h=this.getFoldLine(s);h&&h!==l&&(h.merge(l),l=h),c=f.indexOf(l)+1}for(c;c<f.length;c++){var l=f[c];l.start.row>=i.row&&l.shiftRow(-u)}o=s}else{var p=Array(u);p.unshift(s,0);var d=t?this.$wrapData:this.$rowLengthCache;d.splice.apply(d,p);var f=this.$foldData,l=this.getFoldLine(s),c=0;if(l){var v=l.range.compareInside(r.row,r.column);v==0?(l=l.split(r.row,r.column),l&&(l.shiftRow(u),l.addRemoveChars(o,0,i.column-r.column))):v==-1&&(l.addRemoveChars(s,0,i.column-r.column),l.shiftRow(u)),c=f.indexOf(l)+1}for(c;c<f.length;c++){var l=f[c];l.start.row>=s&&l.shiftRow(u)}}else{u=Math.abs(e.start.column-e.end.column),n==="remove"&&(a=this.getFoldsInRange(e),this.removeFolds(a),u=-u);var l=this.getFoldLine(s);l&&l.addRemoveChars(s,r.column,u)}return t&&this.$wrapData.length!=this.doc.getLength()&&console.error("doc.getLength() and $wrapData.length have to be the same!"),this.$updating=!1,t?this.$updateWrapData(s,o):this.$updateRowLengthCache(s,o),a},this.$updateRowLengthCache=function(e,t,n){this.$rowLengthCache[e]=null,this.$rowLengthCache[t]=null},this.$updateWrapData=function(e,t){var r=this.doc.getAllLines(),i=this.getTabSize(),o=this.$wrapData,u=this.$wrapLimit,a,f,l=e;t=Math.min(t,r.length-1);while(l<=t)f=this.getFoldLine(l,f),f?(a=[],f.walk(function(e,t,i,o){var u;if(e!=null){u=this.$getDisplayTokens(e,a.length),u[0]=n;for(var f=1;f<u.length;f++)u[f]=s}else u=this.$getDisplayTokens(r[t].substring(o,i),a.length);a=a.concat(u)}.bind(this),f.end.row,r[f.end.row].length+1),o[f.start.row]=this.$computeWrapSplits(a,u,i),l=f.end.row+1):(a=this.$getDisplayTokens(r[l]),o[l]=this.$computeWrapSplits(a,u,i),l++)};var e=1,t=2,n=3,s=4,a=9,c=10,d=11,v=12;this.$computeWrapSplits=function(e,r,i){function g(){var t=0;if(m===0)return t;if(p)for(var n=0;n<e.length;n++){var r=e[n];if(r==c)t+=1;else{if(r!=d){if(r==v)continue;break}t+=i}}return h&&p!==!1&&(t+=i),Math.min(t,m)}function y(t){var n=t-f;for(var r=f;r<t;r++){var i=e[r];if(i===12||i===2)n-=1}o.length||(b=g(),o.indent=b),l+=n,o.push(l),f=t}if(e.length==0)return[];var o=[],u=e.length,f=0,l=0,h=this.$wrapAsCode,p=this.$indentedSoftWrap,m=r<=Math.max(2*i,8)||p===!1?0:Math.floor(r/2),b=0;while(u-f>r-b){var w=f+r-b;if(e[w-1]>=c&&e[w]>=c){y(w);continue}if(e[w]==n||e[w]==s){for(w;w!=f-1;w--)if(e[w]==n)break;if(w>f){y(w);continue}w=f+r;for(w;w<e.length;w++)if(e[w]!=s)break;if(w==e.length)break;y(w);continue}var E=Math.max(w-(r-(r>>2)),f-1);while(w>E&&e[w]<n)w--;if(h){while(w>E&&e[w]<n)w--;while(w>E&&e[w]==a)w--}else while(w>E&&e[w]<c)w--;if(w>E){y(++w);continue}w=f+r,e[w]==t&&w--,y(w-b)}return o},this.$getDisplayTokens=function(n,r){var i=[],s;r=r||0;for(var o=0;o<n.length;o++){var u=n.charCodeAt(o);if(u==9){s=this.getScreenTabSize(i.length+r),i.push(d);for(var f=1;f<s;f++)i.push(v)}else u==32?i.push(c):u>39&&u<48||u>57&&u<64?i.push(a):u>=4352&&m(u)?i.push(e,t):i.push(e)}return i},this.$getStringScreenWidth=function(e,t,n){if(t==0)return[0,0];t==null&&(t=Infinity),n=n||0;var r,i;for(i=0;i<e.length;i++){r=e.charCodeAt(i),r==9?n+=this.getScreenTabSize(n):r>=4352&&m(r)?n+=2:n+=1;if(n>t)break}return[n,i]},this.lineWidgets=null,this.getRowLength=function(e){var t=1;return this.lineWidgets&&(t+=this.lineWidgets[e]&&this.lineWidgets[e].rowCount||0),!this.$useWrapMode||!this.$wrapData[e]?t:this.$wrapData[e].length+t},this.getRowLineCount=function(e){return!this.$useWrapMode||!this.$wrapData[e]?1:this.$wrapData[e].length+1},this.getRowWrapIndent=function(e){if(this.$useWrapMode){var t=this.screenToDocumentPosition(e,Number.MAX_VALUE),n=this.$wrapData[t.row];return n.length&&n[0]<t.column?n.indent:0}return 0},this.getScreenLastRowColumn=function(e){var t=this.screenToDocumentPosition(e,Number.MAX_VALUE);return this.documentToScreenColumn(t.row,t.column)},this.getDocumentLastRowColumn=function(e,t){var n=this.documentToScreenRow(e,t);return this.getScreenLastRowColumn(n)},this.getDocumentLastRowColumnPosition=function(e,t){var n=this.documentToScreenRow(e,t);return this.screenToDocumentPosition(n,Number.MAX_VALUE/10)},this.getRowSplitData=function(e){return this.$useWrapMode?this.$wrapData[e]:undefined},this.getScreenTabSize=function(e){return this.$tabSize-(e%this.$tabSize|0)},this.screenToDocumentRow=function(e,t){return this.screenToDocumentPosition(e,t).row},this.screenToDocumentColumn=function(e,t){return this.screenToDocumentPosition(e,t).column},this.screenToDocumentPosition=function(e,t,n){if(e<0)return{row:0,column:0};var r,i=0,s=0,o,u=0,a=0,f=this.$screenRowCache,l=this.$getRowCacheIndex(f,e),c=f.length;if(c&&l>=0)var u=f[l],i=this.$docRowCache[l],h=e>f[c-1];else var h=!c;var p=this.getLength()-1,d=this.getNextFoldLine(i),v=d?d.start.row:Infinity;while(u<=e){a=this.getRowLength(i);if(u+a>e||i>=p)break;u+=a,i++,i>v&&(i=d.end.row+1,d=this.getNextFoldLine(i,d),v=d?d.start.row:Infinity),h&&(this.$docRowCache.push(i),this.$screenRowCache.push(u))}if(d&&d.start.row<=i)r=this.getFoldDisplayLine(d),i=d.start.row;else{if(u+a<=e||i>p)return{row:p,column:this.getLine(p).length};r=this.getLine(i),d=null}var m=0,g=Math.floor(e-u);if(this.$useWrapMode){var y=this.$wrapData[i];y&&(o=y[g],g>0&&y.length&&(m=y.indent,s=y[g-1]||y[y.length-1],r=r.substring(s)))}return n!==undefined&&this.$bidiHandler.isBidiRow(u+g,i,g)&&(t=this.$bidiHandler.offsetToCol(n)),s+=this.$getStringScreenWidth(r,t-m)[1],this.$useWrapMode&&s>=o&&(s=o-1),d?d.idxToPosition(s):{row:i,column:s}},this.documentToScreenPosition=function(e,t){if(typeof t=="undefined")var n=this.$clipPositionToDocument(e.row,e.column);else n=this.$clipPositionToDocument(e,t);e=n.row,t=n.column;var r=0,i=null,s=null;s=this.getFoldAt(e,t,1),s&&(e=s.start.row,t=s.start.column);var o,u=0,a=this.$docRowCache,f=this.$getRowCacheIndex(a,e),l=a.length;if(l&&f>=0)var u=a[f],r=this.$screenRowCache[f],c=e>a[l-1];else var c=!l;var h=this.getNextFoldLine(u),p=h?h.start.row:Infinity;while(u<e){if(u>=p){o=h.end.row+1;if(o>e)break;h=this.getNextFoldLine(o,h),p=h?h.start.row:Infinity}else o=u+1;r+=this.getRowLength(u),u=o,c&&(this.$docRowCache.push(u),this.$screenRowCache.push(r))}var d="";h&&u>=p?(d=this.getFoldDisplayLine(h,e,t),i=h.start.row):(d=this.getLine(e).substring(0,t),i=e);var v=0;if(this.$useWrapMode){var m=this.$wrapData[i];if(m){var g=0;while(d.length>=m[g])r++,g++;d=d.substring(m[g-1]||0,d.length),v=g>0?m.indent:0}}return this.lineWidgets&&this.lineWidgets[u]&&this.lineWidgets[u].rowsAbove&&(r+=this.lineWidgets[u].rowsAbove),{row:r,column:v+this.$getStringScreenWidth(d)[0]}},this.documentToScreenColumn=function(e,t){return this.documentToScreenPosition(e,t).column},this.documentToScreenRow=function(e,t){return this.documentToScreenPosition(e,t).row},this.getScreenLength=function(){var e=0,t=null;if(!this.$useWrapMode){e=this.getLength();var n=this.$foldData;for(var r=0;r<n.length;r++)t=n[r],e-=t.end.row-t.start.row}else{var i=this.$wrapData.length,s=0,r=0,t=this.$foldData[r++],o=t?t.start.row:Infinity;while(s<i){var u=this.$wrapData[s];e+=u?u.length+1:1,s++,s>o&&(s=t.end.row+1,t=this.$foldData[r++],o=t?t.start.row:Infinity)}}return this.lineWidgets&&(e+=this.$getWidgetScreenLength()),e},this.$setFontMetrics=function(e){if(!this.$enableVarChar)return;this.$getStringScreenWidth=function(t,n,r){if(n===0)return[0,0];n||(n=Infinity),r=r||0;var i,s;for(s=0;s<t.length;s++){i=t.charAt(s),i===" "?r+=this.getScreenTabSize(r):r+=e.getCharacterWidth(i);if(r>n)break}return[r,s]}},this.destroy=function(){this.bgTokenizer&&(this.bgTokenizer.setDocument(null),this.bgTokenizer=null),this.$stopWorker(),this.removeAllListeners(),this.selection.detach()},this.isFullWidth=m}.call(d.prototype),e("./edit_session/folding").Folding.call(d.prototype),e("./edit_session/bracket_match").BracketMatch.call(d.prototype),o.defineOptions(d.prototype,"session",{wrap:{set:function(e){!e||e=="off"?e=!1:e=="free"?e=!0:e=="printMargin"?e=-1:typeof e=="string"&&(e=parseInt(e,10)||!1);if(this.$wrap==e)return;this.$wrap=e;if(!e)this.setUseWrapMode(!1);else{var t=typeof e=="number"?e:null;this.setWrapLimitRange(t,t),this.setUseWrapMode(!0)}},get:function(){return this.getUseWrapMode()?this.$wrap==-1?"printMargin":this.getWrapLimitRange().min?this.$wrap:"free":"off"},handlesSet:!0},wrapMethod:{set:function(e){e=e=="auto"?this.$mode.type!="text":e!="text",e!=this.$wrapAsCode&&(this.$wrapAsCode=e,this.$useWrapMode&&(this.$useWrapMode=!1,this.setUseWrapMode(!0)))},initialValue:"auto"},indentedSoftWrap:{set:function(){this.$useWrapMode&&(this.$useWrapMode=!1,this.setUseWrapMode(!0))},initialValue:!0},firstLineNumber:{set:function(){this._signal("changeBreakpoint")},initialValue:1},useWorker:{set:function(e){this.$useWorker=e,this.$stopWorker(),e&&this.$startWorker()},initialValue:!0},useSoftTabs:{initialValue:!0},tabSize:{set:function(e){e=parseInt(e),e>0&&this.$tabSize!==e&&(this.$modified=!0,this.$rowLengthCache=[],this.$tabSize=e,this._signal("changeTabSize"))},initialValue:4,handlesSet:!0},navigateWithinSoftTabs:{initialValue:!1},foldStyle:{set:function(e){this.setFoldStyle(e)},handlesSet:!0},overwrite:{set:function(e){this._signal("changeOverwrite")},initialValue:!1},newLineMode:{set:function(e){this.doc.setNewLineMode(e)},get:function(){return this.doc.getNewLineMode()},handlesSet:!0},mode:{set:function(e){this.setMode(e)},get:function(){return this.$modeId},handlesSet:!0}}),t.EditSession=d}),ace.define("ace/search",["require","exports","module","ace/lib/lang","ace/lib/oop","ace/range"],function(e,t,n){"use strict";function u(e,t){function n(e){return/\w/.test(e)||t.regExp?"\\b":""}return n(e[0])+e+n(e[e.length-1])}var r=e("./lib/lang"),i=e("./lib/oop"),s=e("./range").Range,o=function(){this.$options={}};(function(){this.set=function(e){return i.mixin(this.$options,e),this},this.getOptions=function(){return r.copyObject(this.$options)},this.setOptions=function(e){this.$options=e},this.find=function(e){var t=this.$options,n=this.$matchIterator(e,t);if(!n)return!1;var r=null;return n.forEach(function(e,n,i,o){return r=new s(e,n,i,o),n==o&&t.start&&t.start.start&&t.skipCurrent!=0&&r.isEqual(t.start)?(r=null,!1):!0}),r},this.findAll=function(e){var t=this.$options;if(!t.needle)return[];this.$assembleRegExp(t);var n=t.range,i=n?e.getLines(n.start.row,n.end.row):e.doc.getAllLines(),o=[],u=t.re;if(t.$isMultiLine){var a=u.length,f=i.length-a,l;e:for(var c=u.offset||0;c<=f;c++){for(var h=0;h<a;h++)if(i[c+h].search(u[h])==-1)continue e;var p=i[c],d=i[c+a-1],v=p.length-p.match(u[0])[0].length,m=d.match(u[a-1])[0].length;if(l&&l.end.row===c&&l.end.column>v)continue;o.push(l=new s(c,v,c+a-1,m)),a>2&&(c=c+a-2)}}else for(var g=0;g<i.length;g++){var y=r.getMatchOffsets(i[g],u);for(var h=0;h<y.length;h++){var b=y[h];o.push(new s(g,b.offset,g,b.offset+b.length))}}if(n){var w=n.start.column,E=n.start.column,g=0,h=o.length-1;while(g<h&&o[g].start.column<w&&o[g].start.row==n.start.row)g++;while(g<h&&o[h].end.column>E&&o[h].end.row==n.end.row)h--;o=o.slice(g,h+1);for(g=0,h=o.length;g<h;g++)o[g].start.row+=n.start.row,o[g].end.row+=n.start.row}return o},this.replace=function(e,t){var n=this.$options,r=this.$assembleRegExp(n);if(n.$isMultiLine)return t;if(!r)return;var i=r.exec(e);if(!i||i[0].length!=e.length)return null;t=e.replace(r,t);if(n.preserveCase){t=t.split("");for(var s=Math.min(e.length,e.length);s--;){var o=e[s];o&&o.toLowerCase()!=o?t[s]=t[s].toUpperCase():t[s]=t[s].toLowerCase()}t=t.join("")}return t},this.$assembleRegExp=function(e,t){if(e.needle instanceof RegExp)return e.re=e.needle;var n=e.needle;if(!e.needle)return e.re=!1;e.regExp||(n=r.escapeRegExp(n)),e.wholeWord&&(n=u(n,e));var i=e.caseSensitive?"gm":"gmi";e.$isMultiLine=!t&&/[\n\r]/.test(n);if(e.$isMultiLine)return e.re=this.$assembleMultilineRegExp(n,i);try{var s=new RegExp(n,i)}catch(o){s=!1}return e.re=s},this.$assembleMultilineRegExp=function(e,t){var n=e.replace(/\r\n|\r|\n/g,"$\n^").split("\n"),r=[];for(var i=0;i<n.length;i++)try{r.push(new RegExp(n[i],t))}catch(s){return!1}return r},this.$matchIterator=function(e,t){var n=this.$assembleRegExp(t);if(!n)return!1;var r=t.backwards==1,i=t.skipCurrent!=0,s=t.range,o=t.start;o||(o=s?s[r?"end":"start"]:e.selection.getRange()),o.start&&(o=o[i!=r?"end":"start"]);var u=s?s.start.row:0,a=s?s.end.row:e.getLength()-1;if(r)var f=function(e){var n=o.row;if(c(n,o.column,e))return;for(n--;n>=u;n--)if(c(n,Number.MAX_VALUE,e))return;if(t.wrap==0)return;for(n=a,u=o.row;n>=u;n--)if(c(n,Number.MAX_VALUE,e))return};else var f=function(e){var n=o.row;if(c(n,o.column,e))return;for(n+=1;n<=a;n++)if(c(n,0,e))return;if(t.wrap==0)return;for(n=u,a=o.row;n<=a;n++)if(c(n,0,e))return};if(t.$isMultiLine)var l=n.length,c=function(t,i,s){var o=r?t-l+1:t;if(o<0)return;var u=e.getLine(o),a=u.search(n[0]);if(!r&&a<i||a===-1)return;for(var f=1;f<l;f++){u=e.getLine(o+f);if(u.search(n[f])==-1)return}var c=u.match(n[l-1])[0].length;if(r&&c>i)return;if(s(o,a,o+l-1,c))return!0};else if(r)var c=function(t,r,i){var s=e.getLine(t),o=[],u,a=0;n.lastIndex=0;while(u=n.exec(s)){var f=u[0].length;a=u.index;if(!f){if(a>=s.length)break;n.lastIndex=a+=1}if(u.index+f>r)break;o.push(u.index,f)}for(var l=o.length-1;l>=0;l-=2){var c=o[l-1],f=o[l];if(i(t,c,t,c+f))return!0}};else var c=function(t,r,i){var s=e.getLine(t),o,u;n.lastIndex=r;while(u=n.exec(s)){var a=u[0].length;o=u.index;if(i(t,o,t,o+a))return!0;if(!a){n.lastIndex=o+=1;if(o>=s.length)return!1}}};return{forEach:f}}}).call(o.prototype),t.Search=o}),ace.define("ace/keyboard/hash_handler",["require","exports","module","ace/lib/keys","ace/lib/useragent"],function(e,t,n){"use strict";function o(e,t){this.platform=t||(i.isMac?"mac":"win"),this.commands={},this.commandKeyBinding={},this.addCommands(e),this.$singleCommand=!0}function u(e,t){o.call(this,e,t),this.$singleCommand=!1}var r=e("../lib/keys"),i=e("../lib/useragent"),s=r.KEY_MODS;u.prototype=o.prototype,function(){function e(e){return typeof e=="object"&&e.bindKey&&e.bindKey.position||(e.isDefault?-100:0)}this.addCommand=function(e){this.commands[e.name]&&this.removeCommand(e),this.commands[e.name]=e,e.bindKey&&this._buildKeyHash(e)},this.removeCommand=function(e,t){var n=e&&(typeof e=="string"?e:e.name);e=this.commands[n],t||delete this.commands[n];var r=this.commandKeyBinding;for(var i in r){var s=r[i];if(s==e)delete r[i];else if(Array.isArray(s)){var o=s.indexOf(e);o!=-1&&(s.splice(o,1),s.length==1&&(r[i]=s[0]))}}},this.bindKey=function(e,t,n){typeof e=="object"&&e&&(n==undefined&&(n=e.position),e=e[this.platform]);if(!e)return;if(typeof t=="function")return this.addCommand({exec:t,bindKey:e,name:t.name||e});e.split("|").forEach(function(e){var r="";if(e.indexOf(" ")!=-1){var i=e.split(/\s+/);e=i.pop(),i.forEach(function(e){var t=this.parseKeys(e),n=s[t.hashId]+t.key;r+=(r?" ":"")+n,this._addCommandToBinding(r,"chainKeys")},this),r+=" "}var o=this.parseKeys(e),u=s[o.hashId]+o.key;this._addCommandToBinding(r+u,t,n)},this)},this._addCommandToBinding=function(t,n,r){var i=this.commandKeyBinding,s;if(!n)delete i[t];else if(!i[t]||this.$singleCommand)i[t]=n;else{Array.isArray(i[t])?(s=i[t].indexOf(n))!=-1&&i[t].splice(s,1):i[t]=[i[t]],typeof r!="number"&&(r=e(n));var o=i[t];for(s=0;s<o.length;s++){var u=o[s],a=e(u);if(a>r)break}o.splice(s,0,n)}},this.addCommands=function(e){e&&Object.keys(e).forEach(function(t){var n=e[t];if(!n)return;if(typeof n=="string")return this.bindKey(n,t);typeof n=="function"&&(n={exec:n});if(typeof n!="object")return;n.name||(n.name=t),this.addCommand(n)},this)},this.removeCommands=function(e){Object.keys(e).forEach(function(t){this.removeCommand(e[t])},this)},this.bindKeys=function(e){Object.keys(e).forEach(function(t){this.bindKey(t,e[t])},this)},this._buildKeyHash=function(e){this.bindKey(e.bindKey,e)},this.parseKeys=function(e){var t=e.toLowerCase().split(/[\-\+]([\-\+])?/).filter(function(e){return e}),n=t.pop(),i=r[n];if(r.FUNCTION_KEYS[i])n=r.FUNCTION_KEYS[i].toLowerCase();else{if(!t.length)return{key:n,hashId:-1};if(t.length==1&&t[0]=="shift")return{key:n.toUpperCase(),hashId:-1}}var s=0;for(var o=t.length;o--;){var u=r.KEY_MODS[t[o]];if(u==null)return typeof console!="undefined"&&console.error("invalid modifier "+t[o]+" in "+e),!1;s|=u}return{key:n,hashId:s}},this.findKeyCommand=function(t,n){var r=s[t]+n;return this.commandKeyBinding[r]},this.handleKeyboard=function(e,t,n,r){if(r<0)return;var i=s[t]+n,o=this.commandKeyBinding[i];e.$keyChain&&(e.$keyChain+=" "+i,o=this.commandKeyBinding[e.$keyChain]||o);if(o)if(o=="chainKeys"||o[o.length-1]=="chainKeys")return e.$keyChain=e.$keyChain||i,{command:"null"};if(e.$keyChain)if(!!t&&t!=4||n.length!=1){if(t==-1||r>0)e.$keyChain=""}else e.$keyChain=e.$keyChain.slice(0,-i.length-1);return{command:o}},this.getStatusText=function(e,t){return t.$keyChain||""}}.call(o.prototype),t.HashHandler=o,t.MultiHashHandler=u}),ace.define("ace/commands/command_manager",["require","exports","module","ace/lib/oop","ace/keyboard/hash_handler","ace/lib/event_emitter"],function(e,t,n){"use strict";var r=e("../lib/oop"),i=e("../keyboard/hash_handler").MultiHashHandler,s=e("../lib/event_emitter").EventEmitter,o=function(e,t){i.call(this,t,e),this.byName=this.commands,this.setDefaultHandler("exec",function(e){return e.command.exec(e.editor,e.args||{})})};r.inherits(o,i),function(){r.implement(this,s),this.exec=function(e,t,n){if(Array.isArray(e)){for(var r=e.length;r--;)if(this.exec(e[r],t,n))return!0;return!1}typeof e=="string"&&(e=this.commands[e]);if(!e)return!1;if(t&&t.$readOnly&&!e.readOnly)return!1;if(this.$checkCommandState!=0&&e.isAvailable&&!e.isAvailable(t))return!1;var i={editor:t,command:e,args:n};return i.returnValue=this._emit("exec",i),this._signal("afterExec",i),i.returnValue===!1?!1:!0},this.toggleRecording=function(e){if(this.$inReplay)return;return e&&e._emit("changeStatus"),this.recording?(this.macro.pop(),this.off("exec",this.$addCommandToMacro),this.macro.length||(this.macro=this.oldMacro),this.recording=!1):(this.$addCommandToMacro||(this.$addCommandToMacro=function(e){this.macro.push([e.command,e.args])}.bind(this)),this.oldMacro=this.macro,this.macro=[],this.on("exec",this.$addCommandToMacro),this.recording=!0)},this.replay=function(e){if(this.$inReplay||!this.macro)return;if(this.recording)return this.toggleRecording(e);try{this.$inReplay=!0,this.macro.forEach(function(t){typeof t=="string"?this.exec(t,e):this.exec(t[0],e,t[1])},this)}finally{this.$inReplay=!1}},this.trimMacro=function(e){return e.map(function(e){return typeof e[0]!="string"&&(e[0]=e[0].name),e[1]||(e=e[0]),e})}}.call(o.prototype),t.CommandManager=o}),ace.define("ace/commands/default_commands",["require","exports","module","ace/lib/lang","ace/config","ace/range"],function(e,t,n){"use strict";function o(e,t){return{win:e,mac:t}}var r=e("../lib/lang"),i=e("../config"),s=e("../range").Range;t.commands=[{name:"showSettingsMenu",bindKey:o("Ctrl-,","Command-,"),exec:function(e){i.loadModule("ace/ext/settings_menu",function(t){t.init(e),e.showSettingsMenu()})},readOnly:!0},{name:"goToNextError",bindKey:o("Alt-E","F4"),exec:function(e){i.loadModule("./ext/error_marker",function(t){t.showErrorMarker(e,1)})},scrollIntoView:"animate",readOnly:!0},{name:"goToPreviousError",bindKey:o("Alt-Shift-E","Shift-F4"),exec:function(e){i.loadModule("./ext/error_marker",function(t){t.showErrorMarker(e,-1)})},scrollIntoView:"animate",readOnly:!0},{name:"selectall",description:"Select all",bindKey:o("Ctrl-A","Command-A"),exec:function(e){e.selectAll()},readOnly:!0},{name:"centerselection",description:"Center selection",bindKey:o(null,"Ctrl-L"),exec:function(e){e.centerSelection()},readOnly:!0},{name:"gotoline",description:"Go to line...",bindKey:o("Ctrl-L","Command-L"),exec:function(e,t){typeof t=="number"&&!isNaN(t)&&e.gotoLine(t),e.prompt({$type:"gotoLine"})},readOnly:!0},{name:"fold",bindKey:o("Alt-L|Ctrl-F1","Command-Alt-L|Command-F1"),exec:function(e){e.session.toggleFold(!1)},multiSelectAction:"forEach",scrollIntoView:"center",readOnly:!0},{name:"unfold",bindKey:o("Alt-Shift-L|Ctrl-Shift-F1","Command-Alt-Shift-L|Command-Shift-F1"),exec:function(e){e.session.toggleFold(!0)},multiSelectAction:"forEach",scrollIntoView:"center",readOnly:!0},{name:"toggleFoldWidget",bindKey:o("F2","F2"),exec:function(e){e.session.toggleFoldWidget()},multiSelectAction:"forEach",scrollIntoView:"center",readOnly:!0},{name:"toggleParentFoldWidget",bindKey:o("Alt-F2","Alt-F2"),exec:function(e){e.session.toggleFoldWidget(!0)},multiSelectAction:"forEach",scrollIntoView:"center",readOnly:!0},{name:"foldall",description:"Fold all",bindKey:o(null,"Ctrl-Command-Option-0"),exec:function(e){e.session.foldAll()},scrollIntoView:"center",readOnly:!0},{name:"foldAllComments",description:"Fold all comments",bindKey:o(null,"Ctrl-Command-Option-0"),exec:function(e){e.session.foldAllComments()},scrollIntoView:"center",readOnly:!0},{name:"foldOther",description:"Fold other",bindKey:o("Alt-0","Command-Option-0"),exec:function(e){e.session.foldAll(),e.session.unfold(e.selection.getAllRanges())},scrollIntoView:"center",readOnly:!0},{name:"unfoldall",description:"Unfold all",bindKey:o("Alt-Shift-0","Command-Option-Shift-0"),exec:function(e){e.session.unfold()},scrollIntoView:"center",readOnly:!0},{name:"findnext",description:"Find next",bindKey:o("Ctrl-K","Command-G"),exec:function(e){e.findNext()},multiSelectAction:"forEach",scrollIntoView:"center",readOnly:!0},{name:"findprevious",description:"Find previous",bindKey:o("Ctrl-Shift-K","Command-Shift-G"),exec:function(e){e.findPrevious()},multiSelectAction:"forEach",scrollIntoView:"center",readOnly:!0},{name:"selectOrFindNext",description:"Select or find next",bindKey:o("Alt-K","Ctrl-G"),exec:function(e){e.selection.isEmpty()?e.selection.selectWord():e.findNext()},readOnly:!0},{name:"selectOrFindPrevious",description:"Select or find previous",bindKey:o("Alt-Shift-K","Ctrl-Shift-G"),exec:function(e){e.selection.isEmpty()?e.selection.selectWord():e.findPrevious()},readOnly:!0},{name:"find",description:"Find",bindKey:o("Ctrl-F","Command-F"),exec:function(e){i.loadModule("ace/ext/searchbox",function(t){t.Search(e)})},readOnly:!0},{name:"overwrite",description:"Overwrite",bindKey:"Insert",exec:function(e){e.toggleOverwrite()},readOnly:!0},{name:"selecttostart",description:"Select to start",bindKey:o("Ctrl-Shift-Home","Command-Shift-Home|Command-Shift-Up"),exec:function(e){e.getSelection().selectFileStart()},multiSelectAction:"forEach",readOnly:!0,scrollIntoView:"animate",aceCommandGroup:"fileJump"},{name:"gotostart",description:"Go to start",bindKey:o("Ctrl-Home","Command-Home|Command-Up"),exec:function(e){e.navigateFileStart()},multiSelectAction:"forEach",readOnly:!0,scrollIntoView:"animate",aceCommandGroup:"fileJump"},{name:"selectup",description:"Select up",bindKey:o("Shift-Up","Shift-Up|Ctrl-Shift-P"),exec:function(e){e.getSelection().selectUp()},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"golineup",description:"Go line up",bindKey:o("Up","Up|Ctrl-P"),exec:function(e,t){e.navigateUp(t.times)},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"selecttoend",description:"Select to end",bindKey:o("Ctrl-Shift-End","Command-Shift-End|Command-Shift-Down"),exec:function(e){e.getSelection().selectFileEnd()},multiSelectAction:"forEach",readOnly:!0,scrollIntoView:"animate",aceCommandGroup:"fileJump"},{name:"gotoend",description:"Go to end",bindKey:o("Ctrl-End","Command-End|Command-Down"),exec:function(e){e.navigateFileEnd()},multiSelectAction:"forEach",readOnly:!0,scrollIntoView:"animate",aceCommandGroup:"fileJump"},{name:"selectdown",description:"Select down",bindKey:o("Shift-Down","Shift-Down|Ctrl-Shift-N"),exec:function(e){e.getSelection().selectDown()},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"golinedown",description:"Go line down",bindKey:o("Down","Down|Ctrl-N"),exec:function(e,t){e.navigateDown(t.times)},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"selectwordleft",description:"Select word left",bindKey:o("Ctrl-Shift-Left","Option-Shift-Left"),exec:function(e){e.getSelection().selectWordLeft()},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"gotowordleft",description:"Go to word left",bindKey:o("Ctrl-Left","Option-Left"),exec:function(e){e.navigateWordLeft()},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"selecttolinestart",description:"Select to line start",bindKey:o("Alt-Shift-Left","Command-Shift-Left|Ctrl-Shift-A"),exec:function(e){e.getSelection().selectLineStart()},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"gotolinestart",description:"Go to line start",bindKey:o("Alt-Left|Home","Command-Left|Home|Ctrl-A"),exec:function(e){e.navigateLineStart()},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"selectleft",description:"Select left",bindKey:o("Shift-Left","Shift-Left|Ctrl-Shift-B"),exec:function(e){e.getSelection().selectLeft()},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"gotoleft",description:"Go to left",bindKey:o("Left","Left|Ctrl-B"),exec:function(e,t){e.navigateLeft(t.times)},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"selectwordright",description:"Select word right",bindKey:o("Ctrl-Shift-Right","Option-Shift-Right"),exec:function(e){e.getSelection().selectWordRight()},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"gotowordright",description:"Go to word right",bindKey:o("Ctrl-Right","Option-Right"),exec:function(e){e.navigateWordRight()},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"selecttolineend",description:"Select to line end",bindKey:o("Alt-Shift-Right","Command-Shift-Right|Shift-End|Ctrl-Shift-E"),exec:function(e){e.getSelection().selectLineEnd()},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"gotolineend",description:"Go to line end",bindKey:o("Alt-Right|End","Command-Right|End|Ctrl-E"),exec:function(e){e.navigateLineEnd()},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"selectright",description:"Select right",bindKey:o("Shift-Right","Shift-Right"),exec:function(e){e.getSelection().selectRight()},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"gotoright",description:"Go to right",bindKey:o("Right","Right|Ctrl-F"),exec:function(e,t){e.navigateRight(t.times)},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"selectpagedown",description:"Select page down",bindKey:"Shift-PageDown",exec:function(e){e.selectPageDown()},readOnly:!0},{name:"pagedown",description:"Page down",bindKey:o(null,"Option-PageDown"),exec:function(e){e.scrollPageDown()},readOnly:!0},{name:"gotopagedown",description:"Go to page down",bindKey:o("PageDown","PageDown|Ctrl-V"),exec:function(e){e.gotoPageDown()},readOnly:!0},{name:"selectpageup",description:"Select page up",bindKey:"Shift-PageUp",exec:function(e){e.selectPageUp()},readOnly:!0},{name:"pageup",description:"Page up",bindKey:o(null,"Option-PageUp"),exec:function(e){e.scrollPageUp()},readOnly:!0},{name:"gotopageup",description:"Go to page up",bindKey:"PageUp",exec:function(e){e.gotoPageUp()},readOnly:!0},{name:"scrollup",description:"Scroll up",bindKey:o("Ctrl-Up",null),exec:function(e){e.renderer.scrollBy(0,-2*e.renderer.layerConfig.lineHeight)},readOnly:!0},{name:"scrolldown",description:"Scroll down",bindKey:o("Ctrl-Down",null),exec:function(e){e.renderer.scrollBy(0,2*e.renderer.layerConfig.lineHeight)},readOnly:!0},{name:"selectlinestart",description:"Select line start",bindKey:"Shift-Home",exec:function(e){e.getSelection().selectLineStart()},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"selectlineend",description:"Select line end",bindKey:"Shift-End",exec:function(e){e.getSelection().selectLineEnd()},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"togglerecording",description:"Toggle recording",bindKey:o("Ctrl-Alt-E","Command-Option-E"),exec:function(e){e.commands.toggleRecording(e)},readOnly:!0},{name:"replaymacro",description:"Replay macro",bindKey:o("Ctrl-Shift-E","Command-Shift-E"),exec:function(e){e.commands.replay(e)},readOnly:!0},{name:"jumptomatching",description:"Jump to matching",bindKey:o("Ctrl-\\|Ctrl-P","Command-\\"),exec:function(e){e.jumpToMatching()},multiSelectAction:"forEach",scrollIntoView:"animate",readOnly:!0},{name:"selecttomatching",description:"Select to matching",bindKey:o("Ctrl-Shift-\\|Ctrl-Shift-P","Command-Shift-\\"),exec:function(e){e.jumpToMatching(!0)},multiSelectAction:"forEach",scrollIntoView:"animate",readOnly:!0},{name:"expandToMatching",description:"Expand to matching",bindKey:o("Ctrl-Shift-M","Ctrl-Shift-M"),exec:function(e){e.jumpToMatching(!0,!0)},multiSelectAction:"forEach",scrollIntoView:"animate",readOnly:!0},{name:"passKeysToBrowser",description:"Pass keys to browser",bindKey:o(null,null),exec:function(){},passEvent:!0,readOnly:!0},{name:"copy",description:"Copy",exec:function(e){},readOnly:!0},{name:"cut",description:"Cut",exec:function(e){var t=e.$copyWithEmptySelection&&e.selection.isEmpty(),n=t?e.selection.getLineRange():e.selection.getRange();e._emit("cut",n),n.isEmpty()||e.session.remove(n),e.clearSelection()},scrollIntoView:"cursor",multiSelectAction:"forEach"},{name:"paste",description:"Paste",exec:function(e,t){e.$handlePaste(t)},scrollIntoView:"cursor"},{name:"removeline",description:"Remove line",bindKey:o("Ctrl-D","Command-D"),exec:function(e){e.removeLines()},scrollIntoView:"cursor",multiSelectAction:"forEachLine"},{name:"duplicateSelection",description:"Duplicate selection",bindKey:o("Ctrl-Shift-D","Command-Shift-D"),exec:function(e){e.duplicateSelection()},scrollIntoView:"cursor",multiSelectAction:"forEach"},{name:"sortlines",description:"Sort lines",bindKey:o("Ctrl-Alt-S","Command-Alt-S"),exec:function(e){e.sortLines()},scrollIntoView:"selection",multiSelectAction:"forEachLine"},{name:"togglecomment",description:"Toggle comment",bindKey:o("Ctrl-/","Command-/"),exec:function(e){e.toggleCommentLines()},multiSelectAction:"forEachLine",scrollIntoView:"selectionPart"},{name:"toggleBlockComment",description:"Toggle block comment",bindKey:o("Ctrl-Shift-/","Command-Shift-/"),exec:function(e){e.toggleBlockComment()},multiSelectAction:"forEach",scrollIntoView:"selectionPart"},{name:"modifyNumberUp",description:"Modify number up",bindKey:o("Ctrl-Shift-Up","Alt-Shift-Up"),exec:function(e){e.modifyNumber(1)},scrollIntoView:"cursor",multiSelectAction:"forEach"},{name:"modifyNumberDown",description:"Modify number down",bindKey:o("Ctrl-Shift-Down","Alt-Shift-Down"),exec:function(e){e.modifyNumber(-1)},scrollIntoView:"cursor",multiSelectAction:"forEach"},{name:"replace",description:"Replace",bindKey:o("Ctrl-H","Command-Option-F"),exec:function(e){i.loadModule("ace/ext/searchbox",function(t){t.Search(e,!0)})}},{name:"undo",description:"Undo",bindKey:o("Ctrl-Z","Command-Z"),exec:function(e){e.undo()}},{name:"redo",description:"Redo",bindKey:o("Ctrl-Shift-Z|Ctrl-Y","Command-Shift-Z|Command-Y"),exec:function(e){e.redo()}},{name:"copylinesup",description:"Copy lines up",bindKey:o("Alt-Shift-Up","Command-Option-Up"),exec:function(e){e.copyLinesUp()},scrollIntoView:"cursor"},{name:"movelinesup",description:"Move lines up",bindKey:o("Alt-Up","Option-Up"),exec:function(e){e.moveLinesUp()},scrollIntoView:"cursor"},{name:"copylinesdown",description:"Copy lines down",bindKey:o("Alt-Shift-Down","Command-Option-Down"),exec:function(e){e.copyLinesDown()},scrollIntoView:"cursor"},{name:"movelinesdown",description:"Move lines down",bindKey:o("Alt-Down","Option-Down"),exec:function(e){e.moveLinesDown()},scrollIntoView:"cursor"},{name:"del",description:"Delete",bindKey:o("Delete","Delete|Ctrl-D|Shift-Delete"),exec:function(e){e.remove("right")},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"backspace",description:"Backspace",bindKey:o("Shift-Backspace|Backspace","Ctrl-Backspace|Shift-Backspace|Backspace|Ctrl-H"),exec:function(e){e.remove("left")},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"cut_or_delete",description:"Cut or delete",bindKey:o("Shift-Delete",null),exec:function(e){if(!e.selection.isEmpty())return!1;e.remove("left")},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"removetolinestart",description:"Remove to line start",bindKey:o("Alt-Backspace","Command-Backspace"),exec:function(e){e.removeToLineStart()},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"removetolineend",description:"Remove to line end",bindKey:o("Alt-Delete","Ctrl-K|Command-Delete"),exec:function(e){e.removeToLineEnd()},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"removetolinestarthard",description:"Remove to line start hard",bindKey:o("Ctrl-Shift-Backspace",null),exec:function(e){var t=e.selection.getRange();t.start.column=0,e.session.remove(t)},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"removetolineendhard",description:"Remove to line end hard",bindKey:o("Ctrl-Shift-Delete",null),exec:function(e){var t=e.selection.getRange();t.end.column=Number.MAX_VALUE,e.session.remove(t)},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"removewordleft",description:"Remove word left",bindKey:o("Ctrl-Backspace","Alt-Backspace|Ctrl-Alt-Backspace"),exec:function(e){e.removeWordLeft()},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"removewordright",description:"Remove word right",bindKey:o("Ctrl-Delete","Alt-Delete"),exec:function(e){e.removeWordRight()},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"outdent",description:"Outdent",bindKey:o("Shift-Tab","Shift-Tab"),exec:function(e){e.blockOutdent()},multiSelectAction:"forEach",scrollIntoView:"selectionPart"},{name:"indent",description:"Indent",bindKey:o("Tab","Tab"),exec:function(e){e.indent()},multiSelectAction:"forEach",scrollIntoView:"selectionPart"},{name:"blockoutdent",description:"Block outdent",bindKey:o("Ctrl-[","Ctrl-["),exec:function(e){e.blockOutdent()},multiSelectAction:"forEachLine",scrollIntoView:"selectionPart"},{name:"blockindent",description:"Block indent",bindKey:o("Ctrl-]","Ctrl-]"),exec:function(e){e.blockIndent()},multiSelectAction:"forEachLine",scrollIntoView:"selectionPart"},{name:"insertstring",description:"Insert string",exec:function(e,t){e.insert(t)},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"inserttext",description:"Insert text",exec:function(e,t){e.insert(r.stringRepeat(t.text||"",t.times||1))},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"splitline",description:"Split line",bindKey:o(null,"Ctrl-O"),exec:function(e){e.splitLine()},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"transposeletters",description:"Transpose letters",bindKey:o("Alt-Shift-X","Ctrl-T"),exec:function(e){e.transposeLetters()},multiSelectAction:function(e){e.transposeSelections(1)},scrollIntoView:"cursor"},{name:"touppercase",description:"To uppercase",bindKey:o("Ctrl-U","Ctrl-U"),exec:function(e){e.toUpperCase()},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"tolowercase",description:"To lowercase",bindKey:o("Ctrl-Shift-U","Ctrl-Shift-U"),exec:function(e){e.toLowerCase()},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"autoindent",description:"Auto Indent",bindKey:o(null,null),exec:function(e){e.autoIndent()},multiSelectAction:"forEachLine",scrollIntoView:"animate"},{name:"expandtoline",description:"Expand to line",bindKey:o("Ctrl-Shift-L","Command-Shift-L"),exec:function(e){var t=e.selection.getRange();t.start.column=t.end.column=0,t.end.row++,e.selection.setRange(t,!1)},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"joinlines",description:"Join lines",bindKey:o(null,null),exec:function(e){var t=e.selection.isBackwards(),n=t?e.selection.getSelectionLead():e.selection.getSelectionAnchor(),i=t?e.selection.getSelectionAnchor():e.selection.getSelectionLead(),o=e.session.doc.getLine(n.row).length,u=e.session.doc.getTextRange(e.selection.getRange()),a=u.replace(/\n\s*/," ").length,f=e.session.doc.getLine(n.row);for(var l=n.row+1;l<=i.row+1;l++){var c=r.stringTrimLeft(r.stringTrimRight(e.session.doc.getLine(l)));c.length!==0&&(c=" "+c),f+=c}i.row+1<e.session.doc.getLength()-1&&(f+=e.session.doc.getNewLineCharacter()),e.clearSelection(),e.session.doc.replace(new s(n.row,0,i.row+2,0),f),a>0?(e.selection.moveCursorTo(n.row,n.column),e.selection.selectTo(n.row,n.column+a)):(o=e.session.doc.getLine(n.row).length>o?o+1:o,e.selection.moveCursorTo(n.row,o))},multiSelectAction:"forEach",readOnly:!0},{name:"invertSelection",description:"Invert selection",bindKey:o(null,null),exec:function(e){var t=e.session.doc.getLength()-1,n=e.session.doc.getLine(t).length,r=e.selection.rangeList.ranges,i=[];r.length<1&&(r=[e.selection.getRange()]);for(var o=0;o<r.length;o++)o==r.length-1&&(r[o].end.row!==t||r[o].end.column!==n)&&i.push(new s(r[o].end.row,r[o].end.column,t,n)),o===0?(r[o].start.row!==0||r[o].start.column!==0)&&i.push(new s(0,0,r[o].start.row,r[o].start.column)):i.push(new s(r[o-1].end.row,r[o-1].end.column,r[o].start.row,r[o].start.column));e.exitMultiSelectMode(),e.clearSelection();for(var o=0;o<i.length;o++)e.selection.addRange(i[o],!1)},readOnly:!0,scrollIntoView:"none"},{name:"addLineAfter",exec:function(e){e.selection.clearSelection(),e.navigateLineEnd(),e.insert("\n")},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"addLineBefore",exec:function(e){e.selection.clearSelection();var t=e.getCursorPosition();e.selection.moveTo(t.row-1,Number.MAX_VALUE),e.insert("\n"),t.row===0&&e.navigateUp()},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"openCommandPallete",description:"Open command pallete",bindKey:o("F1","F1"),exec:function(e){e.prompt({$type:"commands"})},readOnly:!0},{name:"modeSelect",description:"Change language mode...",bindKey:o(null,null),exec:function(e){e.prompt({$type:"modes"})},readOnly:!0}];for(var u=1;u<9;u++)t.commands.push({name:"foldToLevel"+u,description:"Fold To Level "+u,level:u,exec:function(e){e.session.foldToLevel(this.level)},scrollIntoView:"center",readOnly:!0})}),ace.define("ace/editor",["require","exports","module","ace/lib/fixoldbrowsers","ace/lib/oop","ace/lib/dom","ace/lib/lang","ace/lib/useragent","ace/keyboard/textinput","ace/mouse/mouse_handler","ace/mouse/fold_handler","ace/keyboard/keybinding","ace/edit_session","ace/search","ace/range","ace/lib/event_emitter","ace/commands/command_manager","ace/commands/default_commands","ace/config","ace/token_iterator","ace/clipboard"],function(e,t,n){"use strict";e("./lib/fixoldbrowsers");var r=e("./lib/oop"),i=e("./lib/dom"),s=e("./lib/lang"),o=e("./lib/useragent"),u=e("./keyboard/textinput").TextInput,a=e("./mouse/mouse_handler").MouseHandler,f=e("./mouse/fold_handler").FoldHandler,l=e("./keyboard/keybinding").KeyBinding,c=e("./edit_session").EditSession,h=e("./search").Search,p=e("./range").Range,d=e("./lib/event_emitter").EventEmitter,v=e("./commands/command_manager").CommandManager,m=e("./commands/default_commands").commands,g=e("./config"),y=e("./token_iterator").TokenIterator,b=e("./clipboard"),w=function(e,t,n){this.$toDestroy=[];var r=e.getContainerElement();this.container=r,this.renderer=e,this.id="editor"+ ++w.$uid,this.commands=new v(o.isMac?"mac":"win",m),typeof document=="object"&&(this.textInput=new u(e.getTextAreaContainer(),this),this.renderer.textarea=this.textInput.getElement(),this.$mouseHandler=new a(this),new f(this)),this.keyBinding=new l(this),this.$search=(new h).set({wrap:!0}),this.$historyTracker=this.$historyTracker.bind(this),this.commands.on("exec",this.$historyTracker),this.$initOperationListeners(),this._$emitInputEvent=s.delayedCall(function(){this._signal("input",{}),this.session&&this.session.bgTokenizer&&this.session.bgTokenizer.scheduleStart()}.bind(this)),this.on("change",function(e,t){t._$emitInputEvent.schedule(31)}),this.setSession(t||n&&n.session||new c("")),g.resetOptions(this),n&&this.setOptions(n),g._signal("editor",this)};w.$uid=0,function(){r.implement(this,d),this.$initOperationListeners=function(){this.commands.on("exec",this.startOperation.bind(this),!0),this.commands.on("afterExec",this.endOperation.bind(this),!0),this.$opResetTimer=s.delayedCall(this.endOperation.bind(this,!0)),this.on("change",function(){this.curOp||(this.startOperation(),this.curOp.selectionBefore=this.$lastSel),this.curOp.docChanged=!0}.bind(this),!0),this.on("changeSelection",function(){this.curOp||(this.startOperation(),this.curOp.selectionBefore=this.$lastSel),this.curOp.selectionChanged=!0}.bind(this),!0)},this.curOp=null,this.prevOp={},this.startOperation=function(e){if(this.curOp){if(!e||this.curOp.command)return;this.prevOp=this.curOp}e||(this.previousCommand=null,e={}),this.$opResetTimer.schedule(),this.curOp=this.session.curOp={command:e.command||{},args:e.args,scrollTop:this.renderer.scrollTop},this.curOp.selectionBefore=this.selection.toJSON()},this.endOperation=function(e){if(this.curOp&&this.session){if(e&&e.returnValue===!1||!this.session)return this.curOp=null;if(e==1&&this.curOp.command&&this.curOp.command.name=="mouse")return;this._signal("beforeEndOperation");if(!this.curOp)return;var t=this.curOp.command,n=t&&t.scrollIntoView;if(n){switch(n){case"center-animate":n="animate";case"center":this.renderer.scrollCursorIntoView(null,.5);break;case"animate":case"cursor":this.renderer.scrollCursorIntoView();break;case"selectionPart":var r=this.selection.getRange(),i=this.renderer.layerConfig;(r.start.row>=i.lastRow||r.end.row<=i.firstRow)&&this.renderer.scrollSelectionIntoView(this.selection.anchor,this.selection.lead);break;default:}n=="animate"&&this.renderer.animateScrolling(this.curOp.scrollTop)}var s=this.selection.toJSON();this.curOp.selectionAfter=s,this.$lastSel=this.selection.toJSON(),this.session.getUndoManager().addSelection(s),this.prevOp=this.curOp,this.curOp=null}},this.$mergeableCommands=["backspace","del","insertstring"],this.$historyTracker=function(e){if(!this.$mergeUndoDeltas)return;var t=this.prevOp,n=this.$mergeableCommands,r=t.command&&e.command.name==t.command.name;if(e.command.name=="insertstring"){var i=e.args;this.mergeNextCommand===undefined&&(this.mergeNextCommand=!0),r=r&&this.mergeNextCommand&&(!/\s/.test(i)||/\s/.test(t.args)),this.mergeNextCommand=!0}else r=r&&n.indexOf(e.command.name)!==-1;this.$mergeUndoDeltas!="always"&&Date.now()-this.sequenceStartTime>2e3&&(r=!1),r?this.session.mergeUndoDeltas=!0:n.indexOf(e.command.name)!==-1&&(this.sequenceStartTime=Date.now())},this.setKeyboardHandler=function(e,t){if(e&&typeof e=="string"&&e!="ace"){this.$keybindingId=e;var n=this;g.loadModule(["keybinding",e],function(r){n.$keybindingId==e&&n.keyBinding.setKeyboardHandler(r&&r.handler),t&&t()})}else this.$keybindingId=null,this.keyBinding.setKeyboardHandler(e),t&&t()},this.getKeyboardHandler=function(){return this.keyBinding.getKeyboardHandler()},this.setSession=function(e){if(this.session==e)return;this.curOp&&this.endOperation(),this.curOp={};var t=this.session;if(t){this.session.off("change",this.$onDocumentChange),this.session.off("changeMode",this.$onChangeMode),this.session.off("tokenizerUpdate",this.$onTokenizerUpdate),this.session.off("changeTabSize",this.$onChangeTabSize),this.session.off("changeWrapLimit",this.$onChangeWrapLimit),this.session.off("changeWrapMode",this.$onChangeWrapMode),this.session.off("changeFold",this.$onChangeFold),this.session.off("changeFrontMarker",this.$onChangeFrontMarker),this.session.off("changeBackMarker",this.$onChangeBackMarker),this.session.off("changeBreakpoint",this.$onChangeBreakpoint),this.session.off("changeAnnotation",this.$onChangeAnnotation),this.session.off("changeOverwrite",this.$onCursorChange),this.session.off("changeScrollTop",this.$onScrollTopChange),this.session.off("changeScrollLeft",this.$onScrollLeftChange);var n=this.session.getSelection();n.off("changeCursor",this.$onCursorChange),n.off("changeSelection",this.$onSelectionChange)}this.session=e,e?(this.$onDocumentChange=this.onDocumentChange.bind(this),e.on("change",this.$onDocumentChange),this.renderer.setSession(e),this.$onChangeMode=this.onChangeMode.bind(this),e.on("changeMode",this.$onChangeMode),this.$onTokenizerUpdate=this.onTokenizerUpdate.bind(this),e.on("tokenizerUpdate",this.$onTokenizerUpdate),this.$onChangeTabSize=this.renderer.onChangeTabSize.bind(this.renderer),e.on("changeTabSize",this.$onChangeTabSize),this.$onChangeWrapLimit=this.onChangeWrapLimit.bind(this),e.on("changeWrapLimit",this.$onChangeWrapLimit),this.$onChangeWrapMode=this.onChangeWrapMode.bind(this),e.on("changeWrapMode",this.$onChangeWrapMode),this.$onChangeFold=this.onChangeFold.bind(this),e.on("changeFold",this.$onChangeFold),this.$onChangeFrontMarker=this.onChangeFrontMarker.bind(this),this.session.on("changeFrontMarker",this.$onChangeFrontMarker),this.$onChangeBackMarker=this.onChangeBackMarker.bind(this),this.session.on("changeBackMarker",this.$onChangeBackMarker),this.$onChangeBreakpoint=this.onChangeBreakpoint.bind(this),this.session.on("changeBreakpoint",this.$onChangeBreakpoint),this.$onChangeAnnotation=this.onChangeAnnotation.bind(this),this.session.on("changeAnnotation",this.$onChangeAnnotation),this.$onCursorChange=this.onCursorChange.bind(this),this.session.on("changeOverwrite",this.$onCursorChange),this.$onScrollTopChange=this.onScrollTopChange.bind(this),this.session.on("changeScrollTop",this.$onScrollTopChange),this.$onScrollLeftChange=this.onScrollLeftChange.bind(this),this.session.on("changeScrollLeft",this.$onScrollLeftChange),this.selection=e.getSelection(),this.selection.on("changeCursor",this.$onCursorChange),this.$onSelectionChange=this.onSelectionChange.bind(this),this.selection.on("changeSelection",this.$onSelectionChange),this.onChangeMode(),this.onCursorChange(),this.onScrollTopChange(),this.onScrollLeftChange(),this.onSelectionChange(),this.onChangeFrontMarker(),this.onChangeBackMarker(),this.onChangeBreakpoint(),this.onChangeAnnotation(),this.session.getUseWrapMode()&&this.renderer.adjustWrapLimit(),this.renderer.updateFull()):(this.selection=null,this.renderer.setSession(e)),this._signal("changeSession",{session:e,oldSession:t}),this.curOp=null,t&&t._signal("changeEditor",{oldEditor:this}),e&&e._signal("changeEditor",{editor:this}),e&&e.bgTokenizer&&e.bgTokenizer.scheduleStart()},this.getSession=function(){return this.session},this.setValue=function(e,t){return this.session.doc.setValue(e),t?t==1?this.navigateFileEnd():t==-1&&this.navigateFileStart():this.selectAll(),e},this.getValue=function(){return this.session.getValue()},this.getSelection=function(){return this.selection},this.resize=function(e){this.renderer.onResize(e)},this.setTheme=function(e,t){this.renderer.setTheme(e,t)},this.getTheme=function(){return this.renderer.getTheme()},this.setStyle=function(e){this.renderer.setStyle(e)},this.unsetStyle=function(e){this.renderer.unsetStyle(e)},this.getFontSize=function(){return this.getOption("fontSize")||i.computedStyle(this.container).fontSize},this.setFontSize=function(e){this.setOption("fontSize",e)},this.$highlightBrackets=function(){if(this.$highlightPending)return;var e=this;this.$highlightPending=!0,setTimeout(function(){e.$highlightPending=!1;var t=e.session;if(!t||!t.bgTokenizer)return;t.$bracketHighlight&&(t.$bracketHighlight.markerIds.forEach(function(e){t.removeMarker(e)}),t.$bracketHighlight=null);var n=t.getMatchingBracketRanges(e.getCursorPosition());!n&&t.$mode.getMatching&&(n=t.$mode.getMatching(e.session));if(!n)return;var r="ace_bracket";Array.isArray(n)?n.length==1&&(r="ace_error_bracket"):n=[n],n.length==2&&(p.comparePoints(n[0].end,n[1].start)==0?n=[p.fromPoints(n[0].start,n[1].end)]:p.comparePoints(n[0].start,n[1].end)==0&&(n=[p.fromPoints(n[1].start,n[0].end)])),t.$bracketHighlight={ranges:n,markerIds:n.map(function(e){return t.addMarker(e,r,"text")})}},50)},this.$highlightTags=function(){if(this.$highlightTagPending)return;var e=this;this.$highlightTagPending=!0,setTimeout(function(){e.$highlightTagPending=!1;var t=e.session;if(!t||!t.bgTokenizer)return;var n=e.getCursorPosition(),r=new y(e.session,n.row,n.column),i=r.getCurrentToken();if(!i||!/\b(?:tag-open|tag-name)/.test(i.type)){t.removeMarker(t.$tagHighlight),t.$tagHighlight=null;return}if(i.type.indexOf("tag-open")!==-1){i=r.stepForward();if(!i)return}var s=i.value,o=i.value,u=0,a=r.stepBackward();if(a.value==="<"){do a=i,i=r.stepForward(),i&&(i.type.indexOf("tag-name")!==-1?(o=i.value,s===o&&(a.value==="<"?u++:a.value==="</"&&u--)):s===o&&i.value==="/>"&&u--);while(i&&u>=0)}else{do{i=a,a=r.stepBackward();if(i)if(i.type.indexOf("tag-name")!==-1)s===i.value&&(a.value==="<"?u++:a.value==="</"&&u--);else if(i.value==="/>"){var f=0,l=a;while(l){if(l.type.indexOf("tag-name")!==-1&&l.value===s){u--;break}if(l.value==="<")break;l=r.stepBackward(),f++}for(var c=0;c<f;c++)r.stepForward()}}while(a&&u<=0);r.stepForward()}if(!i){t.removeMarker(t.$tagHighlight),t.$tagHighlight=null;return}var h=r.getCurrentTokenRow(),d=r.getCurrentTokenColumn(),v=new p(h,d,h,d+i.value.length),m=t.$backMarkers[t.$tagHighlight];t.$tagHighlight&&m!=undefined&&v.compareRange(m.range)!==0&&(t.removeMarker(t.$tagHighlight),t.$tagHighlight=null),t.$tagHighlight||(t.$tagHighlight=t.addMarker(v,"ace_bracket","text"))},50)},this.focus=function(){var e=this;setTimeout(function(){e.isFocused()||e.textInput.focus()}),this.textInput.focus()},this.isFocused=function(){return this.textInput.isFocused()},this.blur=function(){this.textInput.blur()},this.onFocus=function(e){if(this.$isFocused)return;this.$isFocused=!0,this.renderer.showCursor(),this.renderer.visualizeFocus(),this._emit("focus",e)},this.onBlur=function(e){if(!this.$isFocused)return;this.$isFocused=!1,this.renderer.hideCursor(),this.renderer.visualizeBlur(),this._emit("blur",e)},this.$cursorChange=function(){this.renderer.updateCursor(),this.$highlightBrackets(),this.$highlightTags(),this.$updateHighlightActiveLine()},this.onDocumentChange=function(e){var t=this.session.$useWrapMode,n=e.start.row==e.end.row?e.end.row:Infinity;this.renderer.updateLines(e.start.row,n,t),this._signal("change",e),this.$cursorChange()},this.onTokenizerUpdate=function(e){var t=e.data;this.renderer.updateLines(t.first,t.last)},this.onScrollTopChange=function(){this.renderer.scrollToY(this.session.getScrollTop())},this.onScrollLeftChange=function(){this.renderer.scrollToX(this.session.getScrollLeft())},this.onCursorChange=function(){this.$cursorChange(),this._signal("changeSelection")},this.$updateHighlightActiveLine=function(){var e=this.getSession(),t;if(this.$highlightActiveLine){if(this.$selectionStyle!="line"||!this.selection.isMultiLine())t=this.getCursorPosition();this.renderer.theme&&this.renderer.theme.$selectionColorConflict&&!this.selection.isEmpty()&&(t=!1),this.renderer.$maxLines&&this.session.getLength()===1&&!(this.renderer.$minLines>1)&&(t=!1)}if(e.$highlightLineMarker&&!t)e.removeMarker(e.$highlightLineMarker.id),e.$highlightLineMarker=null;else if(!e.$highlightLineMarker&&t){var n=new p(t.row,t.column,t.row,Infinity);n.id=e.addMarker(n,"ace_active-line","screenLine"),e.$highlightLineMarker=n}else t&&(e.$highlightLineMarker.start.row=t.row,e.$highlightLineMarker.end.row=t.row,e.$highlightLineMarker.start.column=t.column,e._signal("changeBackMarker"))},this.onSelectionChange=function(e){var t=this.session;t.$selectionMarker&&t.removeMarker(t.$selectionMarker),t.$selectionMarker=null;if(!this.selection.isEmpty()){var n=this.selection.getRange(),r=this.getSelectionStyle();t.$selectionMarker=t.addMarker(n,"ace_selection",r)}else this.$updateHighlightActiveLine();var i=this.$highlightSelectedWord&&this.$getSelectionHighLightRegexp();this.session.highlight(i),this._signal("changeSelection")},this.$getSelectionHighLightRegexp=function(){var e=this.session,t=this.getSelectionRange();if(t.isEmpty()||t.isMultiLine())return;var n=t.start.column,r=t.end.column,i=e.getLine(t.start.row),s=i.substring(n,r);if(s.length>5e3||!/[\w\d]/.test(s))return;var o=this.$search.$assembleRegExp({wholeWord:!0,caseSensitive:!0,needle:s}),u=i.substring(n-1,r+1);if(!o.test(u))return;return o},this.onChangeFrontMarker=function(){this.renderer.updateFrontMarkers()},this.onChangeBackMarker=function(){this.renderer.updateBackMarkers()},this.onChangeBreakpoint=function(){this.renderer.updateBreakpoints()},this.onChangeAnnotation=function(){this.renderer.setAnnotations(this.session.getAnnotations())},this.onChangeMode=function(e){this.renderer.updateText(),this._emit("changeMode",e)},this.onChangeWrapLimit=function(){this.renderer.updateFull()},this.onChangeWrapMode=function(){this.renderer.onResize(!0)},this.onChangeFold=function(){this.$updateHighlightActiveLine(),this.renderer.updateFull()},this.getSelectedText=function(){return this.session.getTextRange(this.getSelectionRange())},this.getCopyText=function(){var e=this.getSelectedText(),t=this.session.doc.getNewLineCharacter(),n=!1;if(!e&&this.$copyWithEmptySelection){n=!0;var r=this.selection.getAllRanges();for(var i=0;i<r.length;i++){var s=r[i];if(i&&r[i-1].start.row==s.start.row)continue;e+=this.session.getLine(s.start.row)+t}}var o={text:e};return this._signal("copy",o),b.lineMode=n?o.text:"",o.text},this.onCopy=function(){this.commands.exec("copy",this)},this.onCut=function(){this.commands.exec("cut",this)},this.onPaste=function(e,t){var n={text:e,event:t};this.commands.exec("paste",this,n)},this.$handlePaste=function(e){typeof e=="string"&&(e={text:e}),this._signal("paste",e);var t=e.text,n=t==b.lineMode,r=this.session;if(!this.inMultiSelectMode||this.inVirtualSelectionMode)n?r.insert({row:this.selection.lead.row,column:0},t):this.insert(t);else if(n)this.selection.rangeList.ranges.forEach(function(e){r.insert({row:e.start.row,column:0},t)});else{var i=t.split(/\r\n|\r|\n/),s=this.selection.rangeList.ranges,o=i.length==2&&(!i[0]||!i[1]);if(i.length!=s.length||o)return this.commands.exec("insertstring",this,t);for(var u=s.length;u--;){var a=s[u];a.isEmpty()||r.remove(a),r.insert(a.start,i[u])}}},this.execCommand=function(e,t){return this.commands.exec(e,this,t)},this.insert=function(e,t){var n=this.session,r=n.getMode(),i=this.getCursorPosition();if(this.getBehavioursEnabled()&&!t){var s=r.transformAction(n.getState(i.row),"insertion",this,n,e);s&&(e!==s.text&&(this.inVirtualSelectionMode||(this.session.mergeUndoDeltas=!1,this.mergeNextCommand=!1)),e=s.text)}e==" "&&(e=this.session.getTabString());if(!this.selection.isEmpty()){var o=this.getSelectionRange();i=this.session.remove(o),this.clearSelection()}else if(this.session.getOverwrite()&&e.indexOf("\n")==-1){var o=new p.fromPoints(i,i);o.end.column+=e.length,this.session.remove(o)}if(e=="\n"||e=="\r\n"){var u=n.getLine(i.row);if(i.column>u.search(/\S|$/)){var a=u.substr(i.column).search(/\S|$/);n.doc.removeInLine(i.row,i.column,i.column+a)}}this.clearSelection();var f=i.column,l=n.getState(i.row),u=n.getLine(i.row),c=r.checkOutdent(l,u,e);n.insert(i,e),s&&s.selection&&(s.selection.length==2?this.selection.setSelectionRange(new p(i.row,f+s.selection[0],i.row,f+s.selection[1])):this.selection.setSelectionRange(new p(i.row+s.selection[0],s.selection[1],i.row+s.selection[2],s.selection[3])));if(this.$enableAutoIndent){if(n.getDocument().isNewLine(e)){var h=r.getNextLineIndent(l,u.slice(0,i.column),n.getTabString());n.insert({row:i.row+1,column:0},h)}c&&r.autoOutdent(l,n,i.row)}},this.autoIndent=function(){var e=this.session,t=e.getMode(),n,r;if(this.selection.isEmpty())n=0,r=e.doc.getLength()-1;else{var i=this.getSelectionRange();n=i.start.row,r=i.end.row}var s="",o="",u="",a,f,l,c=e.getTabString();for(var h=n;h<=r;h++)h>0&&(s=e.getState(h-1),o=e.getLine(h-1),u=t.getNextLineIndent(s,o,c)),a=e.getLine(h),f=t.$getIndent(a),u!==f&&(f.length>0&&(l=new p(h,0,h,f.length),e.remove(l)),u.length>0&&e.insert({row:h,column:0},u)),t.autoOutdent(s,e,h)},this.onTextInput=function(e,t){if(!t)return this.keyBinding.onTextInput(e);this.startOperation({command:{name:"insertstring"}});var n=this.applyComposition.bind(this,e,t);this.selection.rangeCount?this.forEachSelection(n):n(),this.endOperation()},this.applyComposition=function(e,t){if(t.extendLeft||t.extendRight){var n=this.selection.getRange();n.start.column-=t.extendLeft,n.end.column+=t.extendRight,n.start.column<0&&(n.start.row--,n.start.column+=this.session.getLine(n.start.row).length+1),this.selection.setRange(n),!e&&!n.isEmpty()&&this.remove()}(e||!this.selection.isEmpty())&&this.insert(e,!0);if(t.restoreStart||t.restoreEnd){var n=this.selection.getRange();n.start.column-=t.restoreStart,n.end.column-=t.restoreEnd,this.selection.setRange(n)}},this.onCommandKey=function(e,t,n){return this.keyBinding.onCommandKey(e,t,n)},this.setOverwrite=function(e){this.session.setOverwrite(e)},this.getOverwrite=function(){return this.session.getOverwrite()},this.toggleOverwrite=function(){this.session.toggleOverwrite()},this.setScrollSpeed=function(e){this.setOption("scrollSpeed",e)},this.getScrollSpeed=function(){return this.getOption("scrollSpeed")},this.setDragDelay=function(e){this.setOption("dragDelay",e)},this.getDragDelay=function(){return this.getOption("dragDelay")},this.setSelectionStyle=function(e){this.setOption("selectionStyle",e)},this.getSelectionStyle=function(){return this.getOption("selectionStyle")},this.setHighlightActiveLine=function(e){this.setOption("highlightActiveLine",e)},this.getHighlightActiveLine=function(){return this.getOption("highlightActiveLine")},this.setHighlightGutterLine=function(e){this.setOption("highlightGutterLine",e)},this.getHighlightGutterLine=function(){return this.getOption("highlightGutterLine")},this.setHighlightSelectedWord=function(e){this.setOption("highlightSelectedWord",e)},this.getHighlightSelectedWord=function(){return this.$highlightSelectedWord},this.setAnimatedScroll=function(e){this.renderer.setAnimatedScroll(e)},this.getAnimatedScroll=function(){return this.renderer.getAnimatedScroll()},this.setShowInvisibles=function(e){this.renderer.setShowInvisibles(e)},this.getShowInvisibles=function(){return this.renderer.getShowInvisibles()},this.setDisplayIndentGuides=function(e){this.renderer.setDisplayIndentGuides(e)},this.getDisplayIndentGuides=function(){return this.renderer.getDisplayIndentGuides()},this.setShowPrintMargin=function(e){this.renderer.setShowPrintMargin(e)},this.getShowPrintMargin=function(){return this.renderer.getShowPrintMargin()},this.setPrintMarginColumn=function(e){this.renderer.setPrintMarginColumn(e)},this.getPrintMarginColumn=function(){return this.renderer.getPrintMarginColumn()},this.setReadOnly=function(e){this.setOption("readOnly",e)},this.getReadOnly=function(){return this.getOption("readOnly")},this.setBehavioursEnabled=function(e){this.setOption("behavioursEnabled",e)},this.getBehavioursEnabled=function(){return this.getOption("behavioursEnabled")},this.setWrapBehavioursEnabled=function(e){this.setOption("wrapBehavioursEnabled",e)},this.getWrapBehavioursEnabled=function(){return this.getOption("wrapBehavioursEnabled")},this.setShowFoldWidgets=function(e){this.setOption("showFoldWidgets",e)},this.getShowFoldWidgets=function(){return this.getOption("showFoldWidgets")},this.setFadeFoldWidgets=function(e){this.setOption("fadeFoldWidgets",e)},this.getFadeFoldWidgets=function(){return this.getOption("fadeFoldWidgets")},this.remove=function(e){this.selection.isEmpty()&&(e=="left"?this.selection.selectLeft():this.selection.selectRight());var t=this.getSelectionRange();if(this.getBehavioursEnabled()){var n=this.session,r=n.getState(t.start.row),i=n.getMode().transformAction(r,"deletion",this,n,t);if(t.end.column===0){var s=n.getTextRange(t);if(s[s.length-1]=="\n"){var o=n.getLine(t.end.row);/^\s+$/.test(o)&&(t.end.column=o.length)}}i&&(t=i)}this.session.remove(t),this.clearSelection()},this.removeWordRight=function(){this.selection.isEmpty()&&this.selection.selectWordRight(),this.session.remove(this.getSelectionRange()),this.clearSelection()},this.removeWordLeft=function(){this.selection.isEmpty()&&this.selection.selectWordLeft(),this.session.remove(this.getSelectionRange()),this.clearSelection()},this.removeToLineStart=function(){this.selection.isEmpty()&&this.selection.selectLineStart(),this.selection.isEmpty()&&this.selection.selectLeft(),this.session.remove(this.getSelectionRange()),this.clearSelection()},this.removeToLineEnd=function(){this.selection.isEmpty()&&this.selection.selectLineEnd();var e=this.getSelectionRange();e.start.column==e.end.column&&e.start.row==e.end.row&&(e.end.column=0,e.end.row++),this.session.remove(e),this.clearSelection()},this.splitLine=function(){this.selection.isEmpty()||(this.session.remove(this.getSelectionRange()),this.clearSelection());var e=this.getCursorPosition();this.insert("\n"),this.moveCursorToPosition(e)},this.transposeLetters=function(){if(!this.selection.isEmpty())return;var e=this.getCursorPosition(),t=e.column;if(t===0)return;var n=this.session.getLine(e.row),r,i;t<n.length?(r=n.charAt(t)+n.charAt(t-1),i=new p(e.row,t-1,e.row,t+1)):(r=n.charAt(t-1)+n.charAt(t-2),i=new p(e.row,t-2,e.row,t)),this.session.replace(i,r),this.session.selection.moveToPosition(i.end)},this.toLowerCase=function(){var e=this.getSelectionRange();this.selection.isEmpty()&&this.selection.selectWord();var t=this.getSelectionRange(),n=this.session.getTextRange(t);this.session.replace(t,n.toLowerCase()),this.selection.setSelectionRange(e)},this.toUpperCase=function(){var e=this.getSelectionRange();this.selection.isEmpty()&&this.selection.selectWord();var t=this.getSelectionRange(),n=this.session.getTextRange(t);this.session.replace(t,n.toUpperCase()),this.selection.setSelectionRange(e)},this.indent=function(){var e=this.session,t=this.getSelectionRange();if(t.start.row<t.end.row){var n=this.$getSelectedRows();e.indentRows(n.first,n.last," ");return}if(t.start.column<t.end.column){var r=e.getTextRange(t);if(!/^\s+$/.test(r)){var n=this.$getSelectedRows();e.indentRows(n.first,n.last," ");return}}var i=e.getLine(t.start.row),o=t.start,u=e.getTabSize(),a=e.documentToScreenColumn(o.row,o.column);if(this.session.getUseSoftTabs())var f=u-a%u,l=s.stringRepeat(" ",f);else{var f=a%u;while(i[t.start.column-1]==" "&&f)t.start.column--,f--;this.selection.setSelectionRange(t),l=" "}return this.insert(l)},this.blockIndent=function(){var e=this.$getSelectedRows();this.session.indentRows(e.first,e.last," ")},this.blockOutdent=function(){var e=this.session.getSelection();this.session.outdentRows(e.getRange())},this.sortLines=function(){var e=this.$getSelectedRows(),t=this.session,n=[];for(var r=e.first;r<=e.last;r++)n.push(t.getLine(r));n.sort(function(e,t){return e.toLowerCase()<t.toLowerCase()?-1:e.toLowerCase()>t.toLowerCase()?1:0});var i=new p(0,0,0,0);for(var r=e.first;r<=e.last;r++){var s=t.getLine(r);i.start.row=r,i.end.row=r,i.end.column=s.length,t.replace(i,n[r-e.first])}},this.toggleCommentLines=function(){var e=this.session.getState(this.getCursorPosition().row),t=this.$getSelectedRows();this.session.getMode().toggleCommentLines(e,this.session,t.first,t.last)},this.toggleBlockComment=function(){var e=this.getCursorPosition(),t=this.session.getState(e.row),n=this.getSelectionRange();this.session.getMode().toggleBlockComment(t,this.session,n,e)},this.getNumberAt=function(e,t){var n=/[\-]?[0-9]+(?:\.[0-9]+)?/g;n.lastIndex=0;var r=this.session.getLine(e);while(n.lastIndex<t){var i=n.exec(r);if(i.index<=t&&i.index+i[0].length>=t){var s={value:i[0],start:i.index,end:i.index+i[0].length};return s}}return null},this.modifyNumber=function(e){var t=this.selection.getCursor().row,n=this.selection.getCursor().column,r=new p(t,n-1,t,n),i=this.session.getTextRange(r);if(!isNaN(parseFloat(i))&&isFinite(i)){var s=this.getNumberAt(t,n);if(s){var o=s.value.indexOf(".")>=0?s.start+s.value.indexOf(".")+1:s.end,u=s.start+s.value.length-o,a=parseFloat(s.value);a*=Math.pow(10,u),o!==s.end&&n<o?e*=Math.pow(10,s.end-n-1):e*=Math.pow(10,s.end-n),a+=e,a/=Math.pow(10,u);var f=a.toFixed(u),l=new p(t,s.start,t,s.end);this.session.replace(l,f),this.moveCursorTo(t,Math.max(s.start+1,n+f.length-s.value.length))}}else this.toggleWord()},this.$toggleWordPairs=[["first","last"],["true","false"],["yes","no"],["width","height"],["top","bottom"],["right","left"],["on","off"],["x","y"],["get","set"],["max","min"],["horizontal","vertical"],["show","hide"],["add","remove"],["up","down"],["before","after"],["even","odd"],["in","out"],["inside","outside"],["next","previous"],["increase","decrease"],["attach","detach"],["&&","||"],["==","!="]],this.toggleWord=function(){var e=this.selection.getCursor().row,t=this.selection.getCursor().column;this.selection.selectWord();var n=this.getSelectedText(),r=this.selection.getWordRange().start.column,i=n.replace(/([a-z]+|[A-Z]+)(?=[A-Z_]|$)/g,"$1 ").split(/\s/),o=t-r-1;o<0&&(o=0);var u=0,a=0,f=this;n.match(/[A-Za-z0-9_]+/)&&i.forEach(function(t,i){a=u+t.length,o>=u&&o<=a&&(n=t,f.selection.clearSelection(),f.moveCursorTo(e,u+r),f.selection.selectTo(e,a+r)),u=a});var l=this.$toggleWordPairs,c;for(var h=0;h<l.length;h++){var p=l[h];for(var d=0;d<=1;d++){var v=+!d,m=n.match(new RegExp("^\\s?_?("+s.escapeRegExp(p[d])+")\\s?$","i"));if(m){var g=n.match(new RegExp("([_]|^|\\s)("+s.escapeRegExp(m[1])+")($|\\s)","g"));g&&(c=n.replace(new RegExp(s.escapeRegExp(p[d]),"i"),function(e){var t=p[v];return e.toUpperCase()==e?t=t.toUpperCase():e.charAt(0).toUpperCase()==e.charAt(0)&&(t=t.substr(0,0)+p[v].charAt(0).toUpperCase()+t.substr(1)),t}),this.insert(c),c="")}}}},this.removeLines=function(){var e=this.$getSelectedRows();this.session.removeFullLines(e.first,e.last),this.clearSelection()},this.duplicateSelection=function(){var e=this.selection,t=this.session,n=e.getRange(),r=e.isBackwards();if(n.isEmpty()){var i=n.start.row;t.duplicateLines(i,i)}else{var s=r?n.start:n.end,o=t.insert(s,t.getTextRange(n),!1);n.start=s,n.end=o,e.setSelectionRange(n,r)}},this.moveLinesDown=function(){this.$moveLines(1,!1)},this.moveLinesUp=function(){this.$moveLines(-1,!1)},this.moveText=function(e,t,n){return this.session.moveText(e,t,n)},this.copyLinesUp=function(){this.$moveLines(-1,!0)},this.copyLinesDown=function(){this.$moveLines(1,!0)},this.$moveLines=function(e,t){var n,r,i=this.selection;if(!i.inMultiSelectMode||this.inVirtualSelectionMode){var s=i.toOrientedRange();n=this.$getSelectedRows(s),r=this.session.$moveLines(n.first,n.last,t?0:e),t&&e==-1&&(r=0),s.moveBy(r,0),i.fromOrientedRange(s)}else{var o=i.rangeList.ranges;i.rangeList.detach(this.session),this.inVirtualSelectionMode=!0;var u=0,a=0,f=o.length;for(var l=0;l<f;l++){var c=l;o[l].moveBy(u,0),n=this.$getSelectedRows(o[l]);var h=n.first,p=n.last;while(++l<f){a&&o[l].moveBy(a,0);var d=this.$getSelectedRows(o[l]);if(t&&d.first!=p)break;if(!t&&d.first>p+1)break;p=d.last}l--,u=this.session.$moveLines(h,p,t?0:e),t&&e==-1&&(c=l+1);while(c<=l)o[c].moveBy(u,0),c++;t||(u=0),a+=u}i.fromOrientedRange(i.ranges[0]),i.rangeList.attach(this.session),this.inVirtualSelectionMode=!1}},this.$getSelectedRows=function(e){return e=(e||this.getSelectionRange()).collapseRows(),{first:this.session.getRowFoldStart(e.start.row),last:this.session.getRowFoldEnd(e.end.row)}},this.onCompositionStart=function(e){this.renderer.showComposition(e)},this.onCompositionUpdate=function(e){this.renderer.setCompositionText(e)},this.onCompositionEnd=function(){this.renderer.hideComposition()},this.getFirstVisibleRow=function(){return this.renderer.getFirstVisibleRow()},this.getLastVisibleRow=function(){return this.renderer.getLastVisibleRow()},this.isRowVisible=function(e){return e>=this.getFirstVisibleRow()&&e<=this.getLastVisibleRow()},this.isRowFullyVisible=function(e){return e>=this.renderer.getFirstFullyVisibleRow()&&e<=this.renderer.getLastFullyVisibleRow()},this.$getVisibleRowCount=function(){return this.renderer.getScrollBottomRow()-this.renderer.getScrollTopRow()+1},this.$moveByPage=function(e,t){var n=this.renderer,r=this.renderer.layerConfig,i=e*Math.floor(r.height/r.lineHeight);t===!0?this.selection.$moveSelection(function(){this.moveCursorBy(i,0)}):t===!1&&(this.selection.moveCursorBy(i,0),this.selection.clearSelection());var s=n.scrollTop;n.scrollBy(0,i*r.lineHeight),t!=null&&n.scrollCursorIntoView(null,.5),n.animateScrolling(s)},this.selectPageDown=function(){this.$moveByPage(1,!0)},this.selectPageUp=function(){this.$moveByPage(-1,!0)},this.gotoPageDown=function(){this.$moveByPage(1,!1)},this.gotoPageUp=function(){this.$moveByPage(-1,!1)},this.scrollPageDown=function(){this.$moveByPage(1)},this.scrollPageUp=function(){this.$moveByPage(-1)},this.scrollToRow=function(e){this.renderer.scrollToRow(e)},this.scrollToLine=function(e,t,n,r){this.renderer.scrollToLine(e,t,n,r)},this.centerSelection=function(){var e=this.getSelectionRange(),t={row:Math.floor(e.start.row+(e.end.row-e.start.row)/2),column:Math.floor(e.start.column+(e.end.column-e.start.column)/2)};this.renderer.alignCursor(t,.5)},this.getCursorPosition=function(){return this.selection.getCursor()},this.getCursorPositionScreen=function(){return this.session.documentToScreenPosition(this.getCursorPosition())},this.getSelectionRange=function(){return this.selection.getRange()},this.selectAll=function(){this.selection.selectAll()},this.clearSelection=function(){this.selection.clearSelection()},this.moveCursorTo=function(e,t){this.selection.moveCursorTo(e,t)},this.moveCursorToPosition=function(e){this.selection.moveCursorToPosition(e)},this.jumpToMatching=function(e,t){var n=this.getCursorPosition(),r=new y(this.session,n.row,n.column),i=r.getCurrentToken(),s=i||r.stepForward();if(!s)return;var o,u=!1,a={},f=n.column-s.start,l,c={")":"(","(":"(","]":"[","[":"[","{":"{","}":"{"};do{if(s.value.match(/[{}()\[\]]/g))for(;f<s.value.length&&!u;f++){if(!c[s.value[f]])continue;l=c[s.value[f]]+"."+s.type.replace("rparen","lparen"),isNaN(a[l])&&(a[l]=0);switch(s.value[f]){case"(":case"[":case"{":a[l]++;break;case")":case"]":case"}":a[l]--,a[l]===-1&&(o="bracket",u=!0)}}else s.type.indexOf("tag-name")!==-1&&(isNaN(a[s.value])&&(a[s.value]=0),i.value==="<"?a[s.value]++:i.value==="</"&&a[s.value]--,a[s.value]===-1&&(o="tag",u=!0));u||(i=s,s=r.stepForward(),f=0)}while(s&&!u);if(!o)return;var h,d;if(o==="bracket"){h=this.session.getBracketRange(n);if(!h){h=new p(r.getCurrentTokenRow(),r.getCurrentTokenColumn()+f-1,r.getCurrentTokenRow(),r.getCurrentTokenColumn()+f-1),d=h.start;if(t||d.row===n.row&&Math.abs(d.column-n.column)<2)h=this.session.getBracketRange(d)}}else if(o==="tag"){if(!s||s.type.indexOf("tag-name")===-1)return;var v=s.value;h=new p(r.getCurrentTokenRow(),r.getCurrentTokenColumn()-2,r.getCurrentTokenRow(),r.getCurrentTokenColumn()-2);if(h.compare(n.row,n.column)===0){u=!1;do s=i,i=r.stepBackward(),i&&(i.type.indexOf("tag-close")!==-1&&h.setEnd(r.getCurrentTokenRow(),r.getCurrentTokenColumn()+1),s.value===v&&s.type.indexOf("tag-name")!==-1&&(i.value==="<"?a[v]++:i.value==="</"&&a[v]--,a[v]===0&&(u=!0)));while(i&&!u)}s&&s.type.indexOf("tag-name")&&(d=h.start,d.row==n.row&&Math.abs(d.column-n.column)<2&&(d=h.end))}d=h&&h.cursor||d,d&&(e?h&&t?this.selection.setRange(h):h&&h.isEqual(this.getSelectionRange())?this.clearSelection():this.selection.selectTo(d.row,d.column):this.selection.moveTo(d.row,d.column))},this.gotoLine=function(e,t,n){this.selection.clearSelection(),this.session.unfold({row:e-1,column:t||0}),this.exitMultiSelectMode&&this.exitMultiSelectMode(),this.moveCursorTo(e-1,t||0),this.isRowFullyVisible(e-1)||this.scrollToLine(e-1,!0,n)},this.navigateTo=function(e,t){this.selection.moveTo(e,t)},this.navigateUp=function(e){if(this.selection.isMultiLine()&&!this.selection.isBackwards()){var t=this.selection.anchor.getPosition();return this.moveCursorToPosition(t)}this.selection.clearSelection(),this.selection.moveCursorBy(-e||-1,0)},this.navigateDown=function(e){if(this.selection.isMultiLine()&&this.selection.isBackwards()){var t=this.selection.anchor.getPosition();return this.moveCursorToPosition(t)}this.selection.clearSelection(),this.selection.moveCursorBy(e||1,0)},this.navigateLeft=function(e){if(!this.selection.isEmpty()){var t=this.getSelectionRange().start;this.moveCursorToPosition(t)}else{e=e||1;while(e--)this.selection.moveCursorLeft()}this.clearSelection()},this.navigateRight=function(e){if(!this.selection.isEmpty()){var t=this.getSelectionRange().end;this.moveCursorToPosition(t)}else{e=e||1;while(e--)this.selection.moveCursorRight()}this.clearSelection()},this.navigateLineStart=function(){this.selection.moveCursorLineStart(),this.clearSelection()},this.navigateLineEnd=function(){this.selection.moveCursorLineEnd(),this.clearSelection()},this.navigateFileEnd=function(){this.selection.moveCursorFileEnd(),this.clearSelection()},this.navigateFileStart=function(){this.selection.moveCursorFileStart(),this.clearSelection()},this.navigateWordRight=function(){this.selection.moveCursorWordRight(),this.clearSelection()},this.navigateWordLeft=function(){this.selection.moveCursorWordLeft(),this.clearSelection()},this.replace=function(e,t){t&&this.$search.set(t);var n=this.$search.find(this.session),r=0;return n?(this.$tryReplace(n,e)&&(r=1),this.selection.setSelectionRange(n),this.renderer.scrollSelectionIntoView(n.start,n.end),r):r},this.replaceAll=function(e,t){t&&this.$search.set(t);var n=this.$search.findAll(this.session),r=0;if(!n.length)return r;var i=this.getSelectionRange();this.selection.moveTo(0,0);for(var s=n.length-1;s>=0;--s)this.$tryReplace(n[s],e)&&r++;return this.selection.setSelectionRange(i),r},this.$tryReplace=function(e,t){var n=this.session.getTextRange(e);return t=this.$search.replace(n,t),t!==null?(e.end=this.session.replace(e,t),e):null},this.getLastSearchOptions=function(){return this.$search.getOptions()},this.find=function(e,t,n){t||(t={}),typeof e=="string"||e instanceof RegExp?t.needle=e:typeof e=="object"&&r.mixin(t,e);var i=this.selection.getRange();t.needle==null&&(e=this.session.getTextRange(i)||this.$search.$options.needle,e||(i=this.session.getWordRange(i.start.row,i.start.column),e=this.session.getTextRange(i)),this.$search.set({needle:e})),this.$search.set(t),t.start||this.$search.set({start:i});var s=this.$search.find(this.session);if(t.preventScroll)return s;if(s)return this.revealRange(s,n),s;t.backwards?i.start=i.end:i.end=i.start,this.selection.setRange(i)},this.findNext=function(e,t){this.find({skipCurrent:!0,backwards:!1},e,t)},this.findPrevious=function(e,t){this.find(e,{skipCurrent:!0,backwards:!0},t)},this.revealRange=function(e,t){this.session.unfold(e),this.selection.setSelectionRange(e);var n=this.renderer.scrollTop;this.renderer.scrollSelectionIntoView(e.start,e.end,.5),t!==!1&&this.renderer.animateScrolling(n)},this.undo=function(){this.session.getUndoManager().undo(this.session),this.renderer.scrollCursorIntoView(null,.5)},this.redo=function(){this.session.getUndoManager().redo(this.session),this.renderer.scrollCursorIntoView(null,.5)},this.destroy=function(){this.$toDestroy&&(this.$toDestroy.forEach(function(e){e.destroy()}),this.$toDestroy=null),this.$mouseHandler&&this.$mouseHandler.destroy(),this.renderer.destroy(),this._signal("destroy",this),this.session&&this.session.destroy(),this._$emitInputEvent&&this._$emitInputEvent.cancel(),this.removeAllListeners()},this.setAutoScrollEditorIntoView=function(e){if(!e)return;var t,n=this,r=!1;this.$scrollAnchor||(this.$scrollAnchor=document.createElement("div"));var i=this.$scrollAnchor;i.style.cssText="position:absolute",this.container.insertBefore(i,this.container.firstChild);var s=this.on("changeSelection",function(){r=!0}),o=this.renderer.on("beforeRender",function(){r&&(t=n.renderer.container.getBoundingClientRect())}),u=this.renderer.on("afterRender",function(){if(r&&t&&(n.isFocused()||n.searchBox&&n.searchBox.isFocused())){var e=n.renderer,s=e.$cursorLayer.$pixelPos,o=e.layerConfig,u=s.top-o.offset;s.top>=0&&u+t.top<0?r=!0:s.top<o.height&&s.top+t.top+o.lineHeight>window.innerHeight?r=!1:r=null,r!=null&&(i.style.top=u+"px",i.style.left=s.left+"px",i.style.height=o.lineHeight+"px",i.scrollIntoView(r)),r=t=null}});this.setAutoScrollEditorIntoView=function(e){if(e)return;delete this.setAutoScrollEditorIntoView,this.off("changeSelection",s),this.renderer.off("afterRender",u),this.renderer.off("beforeRender",o)}},this.$resetCursorStyle=function(){var e=this.$cursorStyle||"ace",t=this.renderer.$cursorLayer;if(!t)return;t.setSmoothBlinking(/smooth/.test(e)),t.isBlinking=!this.$readOnly&&e!="wide",i.setCssClass(t.element,"ace_slim-cursors",/slim/.test(e))},this.prompt=function(e,t,n){var r=this;g.loadModule("./ext/prompt",function(i){i.prompt(r,e,t,n)})}}.call(w.prototype),g.defineOptions(w.prototype,"editor",{selectionStyle:{set:function(e){this.onSelectionChange(),this._signal("changeSelectionStyle",{data:e})},initialValue:"line"},highlightActiveLine:{set:function(){this.$updateHighlightActiveLine()},initialValue:!0},highlightSelectedWord:{set:function(e){this.$onSelectionChange()},initialValue:!0},readOnly:{set:function(e){this.textInput.setReadOnly(e),this.$resetCursorStyle()},initialValue:!1},copyWithEmptySelection:{set:function(e){this.textInput.setCopyWithEmptySelection(e)},initialValue:!1},cursorStyle:{set:function(e){this.$resetCursorStyle()},values:["ace","slim","smooth","wide"],initialValue:"ace"},mergeUndoDeltas:{values:[!1,!0,"always"],initialValue:!0},behavioursEnabled:{initialValue:!0},wrapBehavioursEnabled:{initialValue:!0},enableAutoIndent:{initialValue:!0},autoScrollEditorIntoView:{set:function(e){this.setAutoScrollEditorIntoView(e)}},keyboardHandler:{set:function(e){this.setKeyboardHandler(e)},get:function(){return this.$keybindingId},handlesSet:!0},value:{set:function(e){this.session.setValue(e)},get:function(){return this.getValue()},handlesSet:!0,hidden:!0},session:{set:function(e){this.setSession(e)},get:function(){return this.session},handlesSet:!0,hidden:!0},showLineNumbers:{set:function(e){this.renderer.$gutterLayer.setShowLineNumbers(e),this.renderer.$loop.schedule(this.renderer.CHANGE_GUTTER),e&&this.$relativeLineNumbers?E.attach(this):E.detach(this)},initialValue:!0},relativeLineNumbers:{set:function(e){this.$showLineNumbers&&e?E.attach(this):E.detach(this)}},placeholder:{set:function(e){this.$updatePlaceholder||(this.$updatePlaceholder=function(){var e=this.session&&(this.renderer.$composition||this.getValue());if(e&&this.renderer.placeholderNode)this.renderer.off("afterRender",this.$updatePlaceholder),i.removeCssClass(this.container,"ace_hasPlaceholder"),this.renderer.placeholderNode.remove(),this.renderer.placeholderNode=null;else if(!e&&!this.renderer.placeholderNode){this.renderer.on("afterRender",this.$updatePlaceholder),i.addCssClass(this.container,"ace_hasPlaceholder");var t=i.createElement("div");t.className="ace_placeholder",t.textContent=this.$placeholder||"",this.renderer.placeholderNode=t,this.renderer.content.appendChild(this.renderer.placeholderNode)}else!e&&this.renderer.placeholderNode&&(this.renderer.placeholderNode.textContent=this.$placeholder||"")}.bind(this),this.on("input",this.$updatePlaceholder)),this.$updatePlaceholder()}},hScrollBarAlwaysVisible:"renderer",vScrollBarAlwaysVisible:"renderer",highlightGutterLine:"renderer",animatedScroll:"renderer",showInvisibles:"renderer",showPrintMargin:"renderer",printMarginColumn:"renderer",printMargin:"renderer",fadeFoldWidgets:"renderer",showFoldWidgets:"renderer",displayIndentGuides:"renderer",showGutter:"renderer",fontSize:"renderer",fontFamily:"renderer",maxLines:"renderer",minLines:"renderer",scrollPastEnd:"renderer",fixedWidthGutter:"renderer",theme:"renderer",hasCssTransforms:"renderer",maxPixelHeight:"renderer",useTextareaForIME:"renderer",scrollSpeed:"$mouseHandler",dragDelay:"$mouseHandler",dragEnabled:"$mouseHandler",focusTimeout:"$mouseHandler",tooltipFollowsMouse:"$mouseHandler",firstLineNumber:"session",overwrite:"session",newLineMode:"session",useWorker:"session",useSoftTabs:"session",navigateWithinSoftTabs:"session",tabSize:"session",wrap:"session",indentedSoftWrap:"session",foldStyle:"session",mode:"session"});var E={getText:function(e,t){return(Math.abs(e.selection.lead.row-t)||t+1+(t<9?"\u00b7":""))+""},getWidth:function(e,t,n){return Math.max(t.toString().length,(n.lastRow+1).toString().length,2)*n.characterWidth},update:function(e,t){t.renderer.$loop.schedule(t.renderer.CHANGE_GUTTER)},attach:function(e){e.renderer.$gutterLayer.$renderer=this,e.on("changeSelection",this.update),this.update(null,e)},detach:function(e){e.renderer.$gutterLayer.$renderer==this&&(e.renderer.$gutterLayer.$renderer=null),e.off("changeSelection",this.update),this.update(null,e)}};t.Editor=w}),ace.define("ace/undomanager",["require","exports","module","ace/range"],function(e,t,n){"use strict";function i(e,t){for(var n=t;n--;){var r=e[n];if(r&&!r[0].ignore){while(n<t-1){var i=d(e[n],e[n+1]);e[n]=i[0],e[n+1]=i[1],n++}return!0}}}function a(e){var t=e.action=="insert",n=e.start,r=e.end,i=(r.row-n.row)*(t?1:-1),s=(r.column-n.column)*(t?1:-1);t&&(r=n);for(var o in this.marks){var a=this.marks[o],f=u(a,n);if(f<0)continue;if(f===0&&t){if(a.bias!=1){a.bias==-1;continue}f=1}var l=t?f:u(a,r);if(l>0){a.row+=i,a.column+=a.row==r.row?s:0;continue}!t&&l<=0&&(a.row=n.row,a.column=n.column,l===0&&(a.bias=1))}}function f(e){return{row:e.row,column:e.column}}function l(e){return{start:f(e.start),end:f(e.end),action:e.action,lines:e.lines.slice()}}function c(e){e=e||this;if(Array.isArray(e))return e.map(c).join("\n");var t="";e.action?(t=e.action=="insert"?"+":"-",t+="["+e.lines+"]"):e.value&&(Array.isArray(e.value)?t=e.value.map(h).join("\n"):t=h(e.value)),e.start&&(t+=h(e));if(e.id||e.rev)t+=" ("+(e.id||e.rev)+")";return t}function h(e){return e.start.row+":"+e.start.column+"=>"+e.end.row+":"+e.end.column}function p(e,t){var n=e.action=="insert",r=t.action=="insert";if(n&&r)if(o(t.start,e.end)>=0)m(t,e,-1);else{if(!(o(t.start,e.start)<=0))return null;m(e,t,1)}else if(n&&!r)if(o(t.start,e.end)>=0)m(t,e,-1);else{if(!(o(t.end,e.start)<=0))return null;m(e,t,-1)}else if(!n&&r)if(o(t.start,e.start)>=0)m(t,e,1);else{if(!(o(t.start,e.start)<=0))return null;m(e,t,1)}else if(!n&&!r)if(o(t.start,e.start)>=0)m(t,e,1);else{if(!(o(t.end,e.start)<=0))return null;m(e,t,-1)}return[t,e]}function d(e,t){for(var n=e.length;n--;)for(var r=0;r<t.length;r++)if(!p(e[n],t[r])){while(n<e.length){while(r--)p(t[r],e[n]);r=t.length,n++}return[e,t]}return e.selectionBefore=t.selectionBefore=e.selectionAfter=t.selectionAfter=null,[t,e]}function v(e,t){var n=e.action=="insert",r=t.action=="insert";if(n&&r)o(e.start,t.start)<0?m(t,e,1):m(e,t,1);else if(n&&!r)o(e.start,t.end)>=0?m(e,t,-1):o(e.start,t.start)<=0?m(t,e,1):(m(e,s.fromPoints(t.start,e.start),-1),m(t,e,1));else if(!n&&r)o(t.start,e.end)>=0?m(t,e,-1):o(t.start,e.start)<=0?m(e,t,1):(m(t,s.fromPoints(e.start,t.start),-1),m(e,t,1));else if(!n&&!r)if(o(t.start,e.end)>=0)m(t,e,-1);else{if(!(o(t.end,e.start)<=0)){var i,u;return o(e.start,t.start)<0&&(i=e,e=y(e,t.start)),o(e.end,t.end)>0&&(u=y(e,t.end)),g(t.end,e.start,e.end,-1),u&&!i&&(e.lines=u.lines,e.start=u.start,e.end=u.end,u=e),[t,i,u].filter(Boolean)}m(e,t,-1)}return[t,e]}function m(e,t,n){g(e.start,t.start,t.end,n),g(e.end,t.start,t.end,n)}function g(e,t,n,r){e.row==(r==1?t:n).row&&(e.column+=r*(n.column-t.column)),e.row+=r*(n.row-t.row)}function y(e,t){var n=e.lines,r=e.end;e.end=f(t);var i=e.end.row-e.start.row,s=n.splice(i,n.length),o=i?t.column:t.column-e.start.column;n.push(s[0].substring(0,o)),s[0]=s[0].substr(o);var u={start:f(t),end:r,lines:s,action:e.action};return u}function b(e,t){t=l(t);for(var n=e.length;n--;){var r=e[n];for(var i=0;i<r.length;i++){var s=r[i],o=v(s,t);t=o[0],o.length!=2&&(o[2]?(r.splice(i+1,1,o[1],o[2]),i++):o[1]||(r.splice(i,1),i--))}r.length||e.splice(n,1)}return e}function w(e,t){for(var n=0;n<t.length;n++){var r=t[n];for(var i=0;i<r.length;i++)b(e,r[i])}}var r=function(){this.$maxRev=0,this.$fromUndo=!1,this.reset()};(function(){this.addSession=function(e){this.$session=e},this.add=function(e,t,n){if(this.$fromUndo)return;if(e==this.$lastDelta)return;this.$keepRedoStack||(this.$redoStack.length=0);if(t===!1||!this.lastDeltas)this.lastDeltas=[],this.$undoStack.push(this.lastDeltas),e.id=this.$rev=++this.$maxRev;if(e.action=="remove"||e.action=="insert")this.$lastDelta=e;this.lastDeltas.push(e)},this.addSelection=function(e,t){this.selections.push({value:e,rev:t||this.$rev})},this.startNewGroup=function(){return this.lastDeltas=null,this.$rev},this.markIgnored=function(e,t){t==null&&(t=this.$rev+1);var n=this.$undoStack;for(var r=n.length;r--;){var i=n[r][0];if(i.id<=e)break;i.id<t&&(i.ignore=!0)}this.lastDeltas=null},this.getSelection=function(e,t){var n=this.selections;for(var r=n.length;r--;){var i=n[r];if(i.rev<e)return t&&(i=n[r+1]),i}},this.getRevision=function(){return this.$rev},this.getDeltas=function(e,t){t==null&&(t=this.$rev+1);var n=this.$undoStack,r=null,i=0;for(var s=n.length;s--;){var o=n[s][0];o.id<t&&!r&&(r=s+1);if(o.id<=e){i=s+1;break}}return n.slice(i,r)},this.getChangedRanges=function(e,t){t==null&&(t=this.$rev+1)},this.getChangedLines=function(e,t){t==null&&(t=this.$rev+1)},this.undo=function(e,t){this.lastDeltas=null;var n=this.$undoStack;if(!i(n,n.length))return;e||(e=this.$session),this.$redoStackBaseRev!==this.$rev&&this.$redoStack.length&&(this.$redoStack=[]),this.$fromUndo=!0;var r=n.pop(),s=null;return r&&(s=e.undoChanges(r,t),this.$redoStack.push(r),this.$syncRev()),this.$fromUndo=!1,s},this.redo=function(e,t){this.lastDeltas=null,e||(e=this.$session),this.$fromUndo=!0;if(this.$redoStackBaseRev!=this.$rev){var n=this.getDeltas(this.$redoStackBaseRev,this.$rev+1);w(this.$redoStack,n),this.$redoStackBaseRev=this.$rev,this.$redoStack.forEach(function(e){e[0].id=++this.$maxRev},this)}var r=this.$redoStack.pop(),i=null;return r&&(i=e.redoChanges(r,t),this.$undoStack.push(r),this.$syncRev()),this.$fromUndo=!1,i},this.$syncRev=function(){var e=this.$undoStack,t=e[e.length-1],n=t&&t[0].id||0;this.$redoStackBaseRev=n,this.$rev=n},this.reset=function(){this.lastDeltas=null,this.$lastDelta=null,this.$undoStack=[],this.$redoStack=[],this.$rev=0,this.mark=0,this.$redoStackBaseRev=this.$rev,this.selections=[]},this.canUndo=function(){return this.$undoStack.length>0},this.canRedo=function(){return this.$redoStack.length>0},this.bookmark=function(e){e==undefined&&(e=this.$rev),this.mark=e},this.isAtBookmark=function(){return this.$rev===this.mark},this.toJSON=function(){},this.fromJSON=function(){},this.hasUndo=this.canUndo,this.hasRedo=this.canRedo,this.isClean=this.isAtBookmark,this.markClean=this.bookmark,this.$prettyPrint=function(e){return e?c(e):c(this.$undoStack)+"\n---\n"+c(this.$redoStack)}}).call(r.prototype);var s=e("./range").Range,o=s.comparePoints,u=s.comparePoints;t.UndoManager=r}),ace.define("ace/layer/lines",["require","exports","module","ace/lib/dom"],function(e,t,n){"use strict";var r=e("../lib/dom"),i=function(e,t){this.element=e,this.canvasHeight=t||5e5,this.element.style.height=this.canvasHeight*2+"px",this.cells=[],this.cellCache=[],this.$offsetCoefficient=0};(function(){this.moveContainer=function(e){r.translate(this.element,0,-(e.firstRowScreen*e.lineHeight%this.canvasHeight)-e.offset*this.$offsetCoefficient)},this.pageChanged=function(e,t){return Math.floor(e.firstRowScreen*e.lineHeight/this.canvasHeight)!==Math.floor(t.firstRowScreen*t.lineHeight/this.canvasHeight)},this.computeLineTop=function(e,t,n){var r=t.firstRowScreen*t.lineHeight,i=Math.floor(r/this.canvasHeight),s=n.documentToScreenRow(e,0)*t.lineHeight;return s-i*this.canvasHeight},this.computeLineHeight=function(e,t,n){return t.lineHeight*n.getRowLineCount(e)},this.getLength=function(){return this.cells.length},this.get=function(e){return this.cells[e]},this.shift=function(){this.$cacheCell(this.cells.shift())},this.pop=function(){this.$cacheCell(this.cells.pop())},this.push=function(e){if(Array.isArray(e)){this.cells.push.apply(this.cells,e);var t=r.createFragment(this.element);for(var n=0;n<e.length;n++)t.appendChild(e[n].element);this.element.appendChild(t)}else this.cells.push(e),this.element.appendChild(e.element)},this.unshift=function(e){if(Array.isArray(e)){this.cells.unshift.apply(this.cells,e);var t=r.createFragment(this.element);for(var n=0;n<e.length;n++)t.appendChild(e[n].element);this.element.firstChild?this.element.insertBefore(t,this.element.firstChild):this.element.appendChild(t)}else this.cells.unshift(e),this.element.insertAdjacentElement("afterbegin",e.element)},this.last=function(){return this.cells.length?this.cells[this.cells.length-1]:null},this.$cacheCell=function(e){if(!e)return;e.element.remove(),this.cellCache.push(e)},this.createCell=function(e,t,n,i){var s=this.cellCache.pop();if(!s){var o=r.createElement("div");i&&i(o),this.element.appendChild(o),s={element:o,text:"",row:e}}return s.row=e,s}}).call(i.prototype),t.Lines=i}),ace.define("ace/layer/gutter",["require","exports","module","ace/lib/dom","ace/lib/oop","ace/lib/lang","ace/lib/event_emitter","ace/layer/lines"],function(e,t,n){"use strict";function f(e){var t=document.createTextNode("");e.appendChild(t);var n=r.createElement("span");return e.appendChild(n),e}var r=e("../lib/dom"),i=e("../lib/oop"),s=e("../lib/lang"),o=e("../lib/event_emitter").EventEmitter,u=e("./lines").Lines,a=function(e){this.element=r.createElement("div"),this.element.className="ace_layer ace_gutter-layer",e.appendChild(this.element),this.setShowFoldWidgets(this.$showFoldWidgets),this.gutterWidth=0,this.$annotations=[],this.$updateAnnotations=this.$updateAnnotations.bind(this),this.$lines=new u(this.element),this.$lines.$offsetCoefficient=1};(function(){i.implement(this,o),this.setSession=function(e){this.session&&this.session.off("change",this.$updateAnnotations),this.session=e,e&&e.on("change",this.$updateAnnotations)},this.addGutterDecoration=function(e,t){window.console&&console.warn&&console.warn("deprecated use session.addGutterDecoration"),this.session.addGutterDecoration(e,t)},this.removeGutterDecoration=function(e,t){window.console&&console.warn&&console.warn("deprecated use session.removeGutterDecoration"),this.session.removeGutterDecoration(e,t)},this.setAnnotations=function(e){this.$annotations=[];for(var t=0;t<e.length;t++){var n=e[t],r=n.row,i=this.$annotations[r];i||(i=this.$annotations[r]={text:[]});var o=n.text;o=o?s.escapeHTML(o):n.html||"",i.text.indexOf(o)===-1&&i.text.push(o);var u=n.type;u=="error"?i.className=" ace_error":u=="warning"&&i.className!=" ace_error"?i.className=" ace_warning":u=="info"&&!i.className&&(i.className=" ace_info")}},this.$updateAnnotations=function(e){if(!this.$annotations.length)return;var t=e.start.row,n=e.end.row-t;if(n!==0)if(e.action=="remove")this.$annotations.splice(t,n+1,null);else{var r=new Array(n+1);r.unshift(t,1),this.$annotations.splice.apply(this.$annotations,r)}},this.update=function(e){this.config=e;var t=this.session,n=e.firstRow,r=Math.min(e.lastRow+e.gutterOffset,t.getLength()-1);this.oldLastRow=r,this.config=e,this.$lines.moveContainer(e),this.$updateCursorRow();var i=t.getNextFoldLine(n),s=i?i.start.row:Infinity,o=null,u=-1,a=n;for(;;){a>s&&(a=i.end.row+1,i=t.getNextFoldLine(a,i),s=i?i.start.row:Infinity);if(a>r){while(this.$lines.getLength()>u+1)this.$lines.pop();break}o=this.$lines.get(++u),o?o.row=a:(o=this.$lines.createCell(a,e,this.session,f),this.$lines.push(o)),this.$renderCell(o,e,i,a),a++}this._signal("afterRender"),this.$updateGutterWidth(e)},this.$updateGutterWidth=function(e){var t=this.session,n=t.gutterRenderer||this.$renderer,r=t.$firstLineNumber,i=this.$lines.last()?this.$lines.last().text:"";if(this.$fixedWidth||t.$useWrapMode)i=t.getLength()+r-1;var s=n?n.getWidth(t,i,e):i.toString().length*e.characterWidth,o=this.$padding||this.$computePadding();s+=o.left+o.right,s!==this.gutterWidth&&!isNaN(s)&&(this.gutterWidth=s,this.element.parentNode.style.width=this.element.style.width=Math.ceil(this.gutterWidth)+"px",this._signal("changeGutterWidth",s))},this.$updateCursorRow=function(){if(!this.$highlightGutterLine)return;var e=this.session.selection.getCursor();if(this.$cursorRow===e.row)return;this.$cursorRow=e.row},this.updateLineHighlight=function(){if(!this.$highlightGutterLine)return;var e=this.session.selection.cursor.row;this.$cursorRow=e;if(this.$cursorCell&&this.$cursorCell.row==e)return;this.$cursorCell&&(this.$cursorCell.element.className=this.$cursorCell.element.className.replace("ace_gutter-active-line ",""));var t=this.$lines.cells;this.$cursorCell=null;for(var n=0;n<t.length;n++){var r=t[n];if(r.row>=this.$cursorRow){if(r.row>this.$cursorRow){var i=this.session.getFoldLine(this.$cursorRow);if(!(n>0&&i&&i.start.row==t[n-1].row))break;r=t[n-1]}r.element.className="ace_gutter-active-line "+r.element.className,this.$cursorCell=r;break}}},this.scrollLines=function(e){var t=this.config;this.config=e,this.$updateCursorRow();if(this.$lines.pageChanged(t,e))return this.update(e);this.$lines.moveContainer(e);var n=Math.min(e.lastRow+e.gutterOffset,this.session.getLength()-1),r=this.oldLastRow;this.oldLastRow=n;if(!t||r<e.firstRow)return this.update(e);if(n<t.firstRow)return this.update(e);if(t.firstRow<e.firstRow)for(var i=this.session.getFoldedRowCount(t.firstRow,e.firstRow-1);i>0;i--)this.$lines.shift();if(r>n)for(var i=this.session.getFoldedRowCount(n+1,r);i>0;i--)this.$lines.pop();e.firstRow<t.firstRow&&this.$lines.unshift(this.$renderLines(e,e.firstRow,t.firstRow-1)),n>r&&this.$lines.push(this.$renderLines(e,r+1,n)),this.updateLineHighlight(),this._signal("afterRender"),this.$updateGutterWidth(e)},this.$renderLines=function(e,t,n){var r=[],i=t,s=this.session.getNextFoldLine(i),o=s?s.start.row:Infinity;for(;;){i>o&&(i=s.end.row+1,s=this.session.getNextFoldLine(i,s),o=s?s.start.row:Infinity);if(i>n)break;var u=this.$lines.createCell(i,e,this.session,f);this.$renderCell(u,e,s,i),r.push(u),i++}return r},this.$renderCell=function(e,t,n,i){var s=e.element,o=this.session,u=s.childNodes[0],a=s.childNodes[1],f=o.$firstLineNumber,l=o.$breakpoints,c=o.$decorations,h=o.gutterRenderer||this.$renderer,p=this.$showFoldWidgets&&o.foldWidgets,d=n?n.start.row:Number.MAX_VALUE,v="ace_gutter-cell ";this.$highlightGutterLine&&(i==this.$cursorRow||n&&i<this.$cursorRow&&i>=d&&this.$cursorRow<=n.end.row)&&(v+="ace_gutter-active-line ",this.$cursorCell!=e&&(this.$cursorCell&&(this.$cursorCell.element.className=this.$cursorCell.element.className.replace("ace_gutter-active-line ","")),this.$cursorCell=e)),l[i]&&(v+=l[i]),c[i]&&(v+=c[i]),this.$annotations[i]&&(v+=this.$annotations[i].className),s.className!=v&&(s.className=v);if(p){var m=p[i];m==null&&(m=p[i]=o.getFoldWidget(i))}if(m){var v="ace_fold-widget ace_"+m;m=="start"&&i==d&&i<n.end.row?v+=" ace_closed":v+=" ace_open",a.className!=v&&(a.className=v);var g=t.lineHeight+"px";r.setStyle(a.style,"height",g),r.setStyle(a.style,"display","inline-block")}else a&&r.setStyle(a.style,"display","none");var y=(h?h.getText(o,i):i+f).toString();return y!==u.data&&(u.data=y),r.setStyle(e.element.style,"height",this.$lines.computeLineHeight(i,t,o)+"px"),r.setStyle(e.element.style,"top",this.$lines.computeLineTop(i,t,o)+"px"),e.text=y,e},this.$fixedWidth=!1,this.$highlightGutterLine=!0,this.$renderer="",this.setHighlightGutterLine=function(e){this.$highlightGutterLine=e},this.$showLineNumbers=!0,this.$renderer="",this.setShowLineNumbers=function(e){this.$renderer=!e&&{getWidth:function(){return 0},getText:function(){return""}}},this.getShowLineNumbers=function(){return this.$showLineNumbers},this.$showFoldWidgets=!0,this.setShowFoldWidgets=function(e){e?r.addCssClass(this.element,"ace_folding-enabled"):r.removeCssClass(this.element,"ace_folding-enabled"),this.$showFoldWidgets=e,this.$padding=null},this.getShowFoldWidgets=function(){return this.$showFoldWidgets},this.$computePadding=function(){if(!this.element.firstChild)return{left:0,right:0};var e=r.computedStyle(this.element.firstChild);return this.$padding={},this.$padding.left=(parseInt(e.borderLeftWidth)||0)+(parseInt(e.paddingLeft)||0)+1,this.$padding.right=(parseInt(e.borderRightWidth)||0)+(parseInt(e.paddingRight)||0),this.$padding},this.getRegion=function(e){var t=this.$padding||this.$computePadding(),n=this.element.getBoundingClientRect();if(e.x<t.left+n.left)return"markers";if(this.$showFoldWidgets&&e.x>n.right-t.right)return"foldWidgets"}}).call(a.prototype),t.Gutter=a}),ace.define("ace/layer/marker",["require","exports","module","ace/range","ace/lib/dom"],function(e,t,n){"use strict";var r=e("../range").Range,i=e("../lib/dom"),s=function(e){this.element=i.createElement("div"),this.element.className="ace_layer ace_marker-layer",e.appendChild(this.element)};(function(){function e(e,t,n,r){return(e?1:0)|(t?2:0)|(n?4:0)|(r?8:0)}this.$padding=0,this.setPadding=function(e){this.$padding=e},this.setSession=function(e){this.session=e},this.setMarkers=function(e){this.markers=e},this.elt=function(e,t){var n=this.i!=-1&&this.element.childNodes[this.i];n?this.i++:(n=document.createElement("div"),this.element.appendChild(n),this.i=-1),n.style.cssText=t,n.className=e},this.update=function(e){if(!e)return;this.config=e,this.i=0;var t;for(var n in this.markers){var r=this.markers[n];if(!r.range){r.update(t,this,this.session,e);continue}var i=r.range.clipRows(e.firstRow,e.lastRow);if(i.isEmpty())continue;i=i.toScreenRange(this.session);if(r.renderer){var s=this.$getTop(i.start.row,e),o=this.$padding+i.start.column*e.characterWidth;r.renderer(t,i,o,s,e)}else r.type=="fullLine"?this.drawFullLineMarker(t,i,r.clazz,e):r.type=="screenLine"?this.drawScreenLineMarker(t,i,r.clazz,e):i.isMultiLine()?r.type=="text"?this.drawTextMarker(t,i,r.clazz,e):this.drawMultiLineMarker(t,i,r.clazz,e):this.drawSingleLineMarker(t,i,r.clazz+" ace_start"+" ace_br15",e)}if(this.i!=-1)while(this.i<this.element.childElementCount)this.element.removeChild(this.element.lastChild)},this.$getTop=function(e,t){return(e-t.firstRowScreen)*t.lineHeight},this.drawTextMarker=function(t,n,i,s,o){var u=this.session,a=n.start.row,f=n.end.row,l=a,c=0,h=0,p=u.getScreenLastRowColumn(l),d=new r(l,n.start.column,l,h);for(;l<=f;l++)d.start.row=d.end.row=l,d.start.column=l==a?n.start.column:u.getRowWrapIndent(l),d.end.column=p,c=h,h=p,p=l+1<f?u.getScreenLastRowColumn(l+1):l==f?0:n.end.column,this.drawSingleLineMarker(t,d,i+(l==a?" ace_start":"")+" ace_br"+e(l==a||l==a+1&&n.start.column,c<h,h>p,l==f),s,l==f?0:1,o)},this.drawMultiLineMarker=function(e,t,n,r,i){var s=this.$padding,o=r.lineHeight,u=this.$getTop(t.start.row,r),a=s+t.start.column*r.characterWidth;i=i||"";if(this.session.$bidiHandler.isBidiRow(t.start.row)){var f=t.clone();f.end.row=f.start.row,f.end.column=this.session.getLine(f.start.row).length,this.drawBidiSingleLineMarker(e,f,n+" ace_br1 ace_start",r,null,i)}else this.elt(n+" ace_br1 ace_start","height:"+o+"px;"+"right:0;"+"top:"+u+"px;left:"+a+"px;"+(i||""));if(this.session.$bidiHandler.isBidiRow(t.end.row)){var f=t.clone();f.start.row=f.end.row,f.start.column=0,this.drawBidiSingleLineMarker(e,f,n+" ace_br12",r,null,i)}else{u=this.$getTop(t.end.row,r);var l=t.end.column*r.characterWidth;this.elt(n+" ace_br12","height:"+o+"px;"+"width:"+l+"px;"+"top:"+u+"px;"+"left:"+s+"px;"+(i||""))}o=(t.end.row-t.start.row-1)*r.lineHeight;if(o<=0)return;u=this.$getTop(t.start.row+1,r);var c=(t.start.column?1:0)|(t.end.column?0:8);this.elt(n+(c?" ace_br"+c:""),"height:"+o+"px;"+"right:0;"+"top:"+u+"px;"+"left:"+s+"px;"+(i||""))},this.drawSingleLineMarker=function(e,t,n,r,i,s){if(this.session.$bidiHandler.isBidiRow(t.start.row))return this.drawBidiSingleLineMarker(e,t,n,r,i,s);var o=r.lineHeight,u=(t.end.column+(i||0)-t.start.column)*r.characterWidth,a=this.$getTop(t.start.row,r),f=this.$padding+t.start.column*r.characterWidth;this.elt(n,"height:"+o+"px;"+"width:"+u+"px;"+"top:"+a+"px;"+"left:"+f+"px;"+(s||""))},this.drawBidiSingleLineMarker=function(e,t,n,r,i,s){var o=r.lineHeight,u=this.$getTop(t.start.row,r),a=this.$padding,f=this.session.$bidiHandler.getSelections(t.start.column,t.end.column);f.forEach(function(e){this.elt(n,"height:"+o+"px;"+"width:"+e.width+(i||0)+"px;"+"top:"+u+"px;"+"left:"+(a+e.left)+"px;"+(s||""))},this)},this.drawFullLineMarker=function(e,t,n,r,i){var s=this.$getTop(t.start.row,r),o=r.lineHeight;t.start.row!=t.end.row&&(o+=this.$getTop(t.end.row,r)-s),this.elt(n,"height:"+o+"px;"+"top:"+s+"px;"+"left:0;right:0;"+(i||""))},this.drawScreenLineMarker=function(e,t,n,r,i){var s=this.$getTop(t.start.row,r),o=r.lineHeight;this.elt(n,"height:"+o+"px;"+"top:"+s+"px;"+"left:0;right:0;"+(i||""))}}).call(s.prototype),t.Marker=s}),ace.define("ace/layer/text",["require","exports","module","ace/lib/oop","ace/lib/dom","ace/lib/lang","ace/layer/lines","ace/lib/event_emitter"],function(e,t,n){"use strict";var r=e("../lib/oop"),i=e("../lib/dom"),s=e("../lib/lang"),o=e("./lines").Lines,u=e("../lib/event_emitter").EventEmitter,a=function(e){this.dom=i,this.element=this.dom.createElement("div"),this.element.className="ace_layer ace_text-layer",e.appendChild(this.element),this.$updateEolChar=this.$updateEolChar.bind(this),this.$lines=new o(this.element)};(function(){r.implement(this,u),this.EOF_CHAR="\u00b6",this.EOL_CHAR_LF="\u00ac",this.EOL_CHAR_CRLF="\u00a4",this.EOL_CHAR=this.EOL_CHAR_LF,this.TAB_CHAR="\u2014",this.SPACE_CHAR="\u00b7",this.$padding=0,this.MAX_LINE_LENGTH=1e4,this.$updateEolChar=function(){var e=this.session.doc,t=e.getNewLineCharacter()=="\n"&&e.getNewLineMode()!="windows",n=t?this.EOL_CHAR_LF:this.EOL_CHAR_CRLF;if(this.EOL_CHAR!=n)return this.EOL_CHAR=n,!0},this.setPadding=function(e){this.$padding=e,this.element.style.margin="0 "+e+"px"},this.getLineHeight=function(){return this.$fontMetrics.$characterSize.height||0},this.getCharacterWidth=function(){return this.$fontMetrics.$characterSize.width||0},this.$setFontMetrics=function(e){this.$fontMetrics=e,this.$fontMetrics.on("changeCharacterSize",function(e){this._signal("changeCharacterSize",e)}.bind(this)),this.$pollSizeChanges()},this.checkForSizeChanges=function(){this.$fontMetrics.checkForSizeChanges()},this.$pollSizeChanges=function(){return this.$pollSizeChangesTimer=this.$fontMetrics.$pollSizeChanges()},this.setSession=function(e){this.session=e,e&&this.$computeTabString()},this.showInvisibles=!1,this.showSpaces=!1,this.showTabs=!1,this.showEOL=!1,this.setShowInvisibles=function(e){return this.showInvisibles==e?!1:(this.showInvisibles=e,typeof e=="string"?(this.showSpaces=/tab/i.test(e),this.showTabs=/space/i.test(e),this.showEOL=/eol/i.test(e)):this.showSpaces=this.showTabs=this.showEOL=e,this.$computeTabString(),!0)},this.displayIndentGuides=!0,this.setDisplayIndentGuides=function(e){return this.displayIndentGuides==e?!1:(this.displayIndentGuides=e,this.$computeTabString(),!0)},this.$tabStrings=[],this.onChangeTabSize=this.$computeTabString=function(){var e=this.session.getTabSize();this.tabSize=e;var t=this.$tabStrings=[0];for(var n=1;n<e+1;n++)if(this.showTabs){var r=this.dom.createElement("span");r.className="ace_invisible ace_invisible_tab",r.textContent=s.stringRepeat(this.TAB_CHAR,n),t.push(r)}else t.push(this.dom.createTextNode(s.stringRepeat(" ",n),this.element));if(this.displayIndentGuides){this.$indentGuideRe=/\s\S| \t|\t |\s$/;var i="ace_indent-guide",o=this.showSpaces?" ace_invisible ace_invisible_space":"",u=this.showSpaces?s.stringRepeat(this.SPACE_CHAR,this.tabSize):s.stringRepeat(" ",this.tabSize),a=this.showTabs?" ace_invisible ace_invisible_tab":"",f=this.showTabs?s.stringRepeat(this.TAB_CHAR,this.tabSize):u,r=this.dom.createElement("span");r.className=i+o,r.textContent=u,this.$tabStrings[" "]=r;var r=this.dom.createElement("span");r.className=i+a,r.textContent=f,this.$tabStrings[" "]=r}},this.updateLines=function(e,t,n){if(this.config.lastRow!=e.lastRow||this.config.firstRow!=e.firstRow)return this.update(e);this.config=e;var r=Math.max(t,e.firstRow),i=Math.min(n,e.lastRow),s=this.element.childNodes,o=0;for(var u=e.firstRow;u<r;u++){var a=this.session.getFoldLine(u);if(a){if(a.containsRow(r)){r=a.start.row;break}u=a.end.row}o++}var f=!1,u=r,a=this.session.getNextFoldLine(u),l=a?a.start.row:Infinity;for(;;){u>l&&(u=a.end.row+1,a=this.session.getNextFoldLine(u,a),l=a?a.start.row:Infinity);if(u>i)break;var c=s[o++];if(c){this.dom.removeChildren(c),this.$renderLine(c,u,u==l?a:!1),f&&(c.style.top=this.$lines.computeLineTop(u,e,this.session)+"px");var h=e.lineHeight*this.session.getRowLength(u)+"px";c.style.height!=h&&(f=!0,c.style.height=h)}u++}if(f)while(o<this.$lines.cells.length){var p=this.$lines.cells[o++];p.element.style.top=this.$lines.computeLineTop(p.row,e,this.session)+"px"}},this.scrollLines=function(e){var t=this.config;this.config=e;if(this.$lines.pageChanged(t,e))return this.update(e);this.$lines.moveContainer(e);var n=e.lastRow,r=t?t.lastRow:-1;if(!t||r<e.firstRow)return this.update(e);if(n<t.firstRow)return this.update(e);if(!t||t.lastRow<e.firstRow)return this.update(e);if(e.lastRow<t.firstRow)return this.update(e);if(t.firstRow<e.firstRow)for(var i=this.session.getFoldedRowCount(t.firstRow,e.firstRow-1);i>0;i--)this.$lines.shift();if(t.lastRow>e.lastRow)for(var i=this.session.getFoldedRowCount(e.lastRow+1,t.lastRow);i>0;i--)this.$lines.pop();e.firstRow<t.firstRow&&this.$lines.unshift(this.$renderLinesFragment(e,e.firstRow,t.firstRow-1)),e.lastRow>t.lastRow&&this.$lines.push(this.$renderLinesFragment(e,t.lastRow+1,e.lastRow))},this.$renderLinesFragment=function(e,t,n){var r=[],s=t,o=this.session.getNextFoldLine(s),u=o?o.start.row:Infinity;for(;;){s>u&&(s=o.end.row+1,o=this.session.getNextFoldLine(s,o),u=o?o.start.row:Infinity);if(s>n)break;var a=this.$lines.createCell(s,e,this.session),f=a.element;this.dom.removeChildren(f),i.setStyle(f.style,"height",this.$lines.computeLineHeight(s,e,this.session)+"px"),i.setStyle(f.style,"top",this.$lines.computeLineTop(s,e,this.session)+"px"),this.$renderLine(f,s,s==u?o:!1),this.$useLineGroups()?f.className="ace_line_group":f.className="ace_line",r.push(a),s++}return r},this.update=function(e){this.$lines.moveContainer(e),this.config=e;var t=e.firstRow,n=e.lastRow,r=this.$lines;while(r.getLength())r.pop();r.push(this.$renderLinesFragment(e,t,n))},this.$textToken={text:!0,rparen:!0,lparen:!0},this.$renderToken=function(e,t,n,r){var i=this,o=/(\t)|( +)|([\x00-\x1f\x80-\xa0\xad\u1680\u180E\u2000-\u200f\u2028\u2029\u202F\u205F\uFEFF\uFFF9-\uFFFC]+)|(\u3000)|([\u1100-\u115F\u11A3-\u11A7\u11FA-\u11FF\u2329-\u232A\u2E80-\u2E99\u2E9B-\u2EF3\u2F00-\u2FD5\u2FF0-\u2FFB\u3001-\u303E\u3041-\u3096\u3099-\u30FF\u3105-\u312D\u3131-\u318E\u3190-\u31BA\u31C0-\u31E3\u31F0-\u321E\u3220-\u3247\u3250-\u32FE\u3300-\u4DBF\u4E00-\uA48C\uA490-\uA4C6\uA960-\uA97C\uAC00-\uD7A3\uD7B0-\uD7C6\uD7CB-\uD7FB\uF900-\uFAFF\uFE10-\uFE19\uFE30-\uFE52\uFE54-\uFE66\uFE68-\uFE6B\uFF01-\uFF60\uFFE0-\uFFE6]|[\uD800-\uDBFF][\uDC00-\uDFFF])/g,u=this.dom.createFragment(this.element),a,f=0;while(a=o.exec(r)){var l=a[1],c=a[2],h=a[3],p=a[4],d=a[5];if(!i.showSpaces&&c)continue;var v=f!=a.index?r.slice(f,a.index):"";f=a.index+a[0].length,v&&u.appendChild(this.dom.createTextNode(v,this.element));if(l){var m=i.session.getScreenTabSize(t+a.index);u.appendChild(i.$tabStrings[m].cloneNode(!0)),t+=m-1}else if(c)if(i.showSpaces){var g=this.dom.createElement("span");g.className="ace_invisible ace_invisible_space",g.textContent=s.stringRepeat(i.SPACE_CHAR,c.length),u.appendChild(g)}else u.appendChild(this.com.createTextNode(c,this.element));else if(h){var g=this.dom.createElement("span");g.className="ace_invisible ace_invisible_space ace_invalid",g.textContent=s.stringRepeat(i.SPACE_CHAR,h.length),u.appendChild(g)}else if(p){t+=1;var g=this.dom.createElement("span");g.style.width=i.config.characterWidth*2+"px",g.className=i.showSpaces?"ace_cjk ace_invisible ace_invisible_space":"ace_cjk",g.textContent=i.showSpaces?i.SPACE_CHAR:p,u.appendChild(g)}else if(d){t+=1;var g=this.dom.createElement("span");g.style.width=i.config.characterWidth*2+"px",g.className="ace_cjk",g.textContent=d,u.appendChild(g)}}u.appendChild(this.dom.createTextNode(f?r.slice(f):r,this.element));if(!this.$textToken[n.type]){var y="ace_"+n.type.replace(/\./g," ace_"),g=this.dom.createElement("span");n.type=="fold"&&(g.style.width=n.value.length*this.config.characterWidth+"px"),g.className=y,g.appendChild(u),e.appendChild(g)}else e.appendChild(u);return t+r.length},this.renderIndentGuide=function(e,t,n){var r=t.search(this.$indentGuideRe);if(r<=0||r>=n)return t;if(t[0]==" "){r-=r%this.tabSize;var i=r/this.tabSize;for(var s=0;s<i;s++)e.appendChild(this.$tabStrings[" "].cloneNode(!0));return t.substr(r)}if(t[0]==" "){for(var s=0;s<r;s++)e.appendChild(this.$tabStrings[" "].cloneNode(!0));return t.substr(r)}return t},this.$createLineElement=function(e){var t=this.dom.createElement("div");return t.className="ace_line",t.style.height=this.config.lineHeight+"px",t},this.$renderWrappedLine=function(e,t,n){var r=0,i=0,o=n[0],u=0,a=this.$createLineElement();e.appendChild(a);for(var f=0;f<t.length;f++){var l=t[f],c=l.value;if(f==0&&this.displayIndentGuides){r=c.length,c=this.renderIndentGuide(a,c,o);if(!c)continue;r-=c.length}if(r+c.length<o)u=this.$renderToken(a,u,l,c),r+=c.length;else{while(r+c.length>=o)u=this.$renderToken(a,u,l,c.substring(0,o-r)),c=c.substring(o-r),r=o,a=this.$createLineElement(),e.appendChild(a),a.appendChild(this.dom.createTextNode(s.stringRepeat("\u00a0",n.indent),this.element)),i++,u=0,o=n[i]||Number.MAX_VALUE;c.length!=0&&(r+=c.length,u=this.$renderToken(a,u,l,c))}}n[n.length-1]>this.MAX_LINE_LENGTH&&this.$renderOverflowMessage(a,u,null,"",!0)},this.$renderSimpleLine=function(e,t){var n=0,r=t[0],i=r.value;this.displayIndentGuides&&(i=this.renderIndentGuide(e,i)),i&&(n=this.$renderToken(e,n,r,i));for(var s=1;s<t.length;s++){r=t[s],i=r.value;if(n+i.length>this.MAX_LINE_LENGTH)return this.$renderOverflowMessage(e,n,r,i);n=this.$renderToken(e,n,r,i)}},this.$renderOverflowMessage=function(e,t,n,r,i){n&&this.$renderToken(e,t,n,r.slice(0,this.MAX_LINE_LENGTH-t));var s=this.dom.createElement("span");s.className="ace_inline_button ace_keyword ace_toggle_wrap",s.textContent=i?"<hide>":"<click to see more...>",e.appendChild(s)},this.$renderLine=function(e,t,n){!n&&n!=0&&(n=this.session.getFoldLine(t));if(n)var r=this.$getFoldLineTokens(t,n);else var r=this.session.getTokens(t);var i=e;if(r.length){var s=this.session.getRowSplitData(t);if(s&&s.length){this.$renderWrappedLine(e,r,s);var i=e.lastChild}else{var i=e;this.$useLineGroups()&&(i=this.$createLineElement(),e.appendChild(i)),this.$renderSimpleLine(i,r)}}else this.$useLineGroups()&&(i=this.$createLineElement(),e.appendChild(i));if(this.showEOL&&i){n&&(t=n.end.row);var o=this.dom.createElement("span");o.className="ace_invisible ace_invisible_eol",o.textContent=t==this.session.getLength()-1?this.EOF_CHAR:this.EOL_CHAR,i.appendChild(o)}},this.$getFoldLineTokens=function(e,t){function i(e,t,n){var i=0,s=0;while(s+e[i].value.length<t){s+=e[i].value.length,i++;if(i==e.length)return}if(s!=t){var o=e[i].value.substring(t-s);o.length>n-t&&(o=o.substring(0,n-t)),r.push({type:e[i].type,value:o}),s=t+o.length,i+=1}while(s<n&&i<e.length){var o=e[i].value;o.length+s>n?r.push({type:e[i].type,value:o.substring(0,n-s)}):r.push(e[i]),s+=o.length,i+=1}}var n=this.session,r=[],s=n.getTokens(e);return t.walk(function(e,t,o,u,a){e!=null?r.push({type:"fold",value:e}):(a&&(s=n.getTokens(t)),s.length&&i(s,u,o))},t.end.row,this.session.getLine(t.end.row).length),r},this.$useLineGroups=function(){return this.session.getUseWrapMode()},this.destroy=function(){}}).call(a.prototype),t.Text=a}),ace.define("ace/layer/cursor",["require","exports","module","ace/lib/dom"],function(e,t,n){"use strict";var r=e("../lib/dom"),i=function(e){this.element=r.createElement("div"),this.element.className="ace_layer ace_cursor-layer",e.appendChild(this.element),this.isVisible=!1,this.isBlinking=!0,this.blinkInterval=1e3,this.smoothBlinking=!1,this.cursors=[],this.cursor=this.addCursor(),r.addCssClass(this.element,"ace_hidden-cursors"),this.$updateCursors=this.$updateOpacity.bind(this)};(function(){this.$updateOpacity=function(e){var t=this.cursors;for(var n=t.length;n--;)r.setStyle(t[n].style,"opacity",e?"":"0")},this.$startCssAnimation=function(){var e=this.cursors;for(var t=e.length;t--;)e[t].style.animationDuration=this.blinkInterval+"ms";setTimeout(function(){r.addCssClass(this.element,"ace_animate-blinking")}.bind(this))},this.$stopCssAnimation=function(){r.removeCssClass(this.element,"ace_animate-blinking")},this.$padding=0,this.setPadding=function(e){this.$padding=e},this.setSession=function(e){this.session=e},this.setBlinking=function(e){e!=this.isBlinking&&(this.isBlinking=e,this.restartTimer())},this.setBlinkInterval=function(e){e!=this.blinkInterval&&(this.blinkInterval=e,this.restartTimer())},this.setSmoothBlinking=function(e){e!=this.smoothBlinking&&(this.smoothBlinking=e,r.setCssClass(this.element,"ace_smooth-blinking",e),this.$updateCursors(!0),this.restartTimer())},this.addCursor=function(){var e=r.createElement("div");return e.className="ace_cursor",this.element.appendChild(e),this.cursors.push(e),e},this.removeCursor=function(){if(this.cursors.length>1){var e=this.cursors.pop();return e.parentNode.removeChild(e),e}},this.hideCursor=function(){this.isVisible=!1,r.addCssClass(this.element,"ace_hidden-cursors"),this.restartTimer()},this.showCursor=function(){this.isVisible=!0,r.removeCssClass(this.element,"ace_hidden-cursors"),this.restartTimer()},this.restartTimer=function(){var e=this.$updateCursors;clearInterval(this.intervalId),clearTimeout(this.timeoutId),this.$stopCssAnimation(),this.smoothBlinking&&r.removeCssClass(this.element,"ace_smooth-blinking"),e(!0);if(!this.isBlinking||!this.blinkInterval||!this.isVisible){this.$stopCssAnimation();return}this.smoothBlinking&&setTimeout(function(){r.addCssClass(this.element,"ace_smooth-blinking")}.bind(this));if(r.HAS_CSS_ANIMATION)this.$startCssAnimation();else{var t=function(){this.timeoutId=setTimeout(function(){e(!1)},.6*this.blinkInterval)}.bind(this);this.intervalId=setInterval(function(){e(!0),t()},this.blinkInterval),t()}},this.getPixelPosition=function(e,t){if(!this.config||!this.session)return{left:0,top:0};e||(e=this.session.selection.getCursor());var n=this.session.documentToScreenPosition(e),r=this.$padding+(this.session.$bidiHandler.isBidiRow(n.row,e.row)?this.session.$bidiHandler.getPosLeft(n.column):n.column*this.config.characterWidth),i=(n.row-(t?this.config.firstRowScreen:0))*this.config.lineHeight;return{left:r,top:i}},this.isCursorInView=function(e,t){return e.top>=0&&e.top<t.maxHeight},this.update=function(e){this.config=e;var t=this.session.$selectionMarkers,n=0,i=0;if(t===undefined||t.length===0)t=[{cursor:null}];for(var n=0,s=t.length;n<s;n++){var o=this.getPixelPosition(t[n].cursor,!0);if((o.top>e.height+e.offset||o.top<0)&&n>1)continue;var u=this.cursors[i++]||this.addCursor(),a=u.style;this.drawCursor?this.drawCursor(u,o,e,t[n],this.session):this.isCursorInView(o,e)?(r.setStyle(a,"display","block"),r.translate(u,o.left,o.top),r.setStyle(a,"width",Math.round(e.characterWidth)+"px"),r.setStyle(a,"height",e.lineHeight+"px")):r.setStyle(a,"display","none")}while(this.cursors.length>i)this.removeCursor();var f=this.session.getOverwrite();this.$setOverwrite(f),this.$pixelPos=o,this.restartTimer()},this.drawCursor=null,this.$setOverwrite=function(e){e!=this.overwrite&&(this.overwrite=e,e?r.addCssClass(this.element,"ace_overwrite-cursors"):r.removeCssClass(this.element,"ace_overwrite-cursors"))},this.destroy=function(){clearInterval(this.intervalId),clearTimeout(this.timeoutId)}}).call(i.prototype),t.Cursor=i}),ace.define("ace/scrollbar",["require","exports","module","ace/lib/oop","ace/lib/dom","ace/lib/event","ace/lib/event_emitter"],function(e,t,n){"use strict";var r=e("./lib/oop"),i=e("./lib/dom"),s=e("./lib/event"),o=e("./lib/event_emitter").EventEmitter,u=32768,a=function(e){this.element=i.createElement("div"),this.element.className="ace_scrollbar ace_scrollbar"+this.classSuffix,this.inner=i.createElement("div"),this.inner.className="ace_scrollbar-inner",this.inner.textContent="\u00a0",this.element.appendChild(this.inner),e.appendChild(this.element),this.setVisible(!1),this.skipEvent=!1,s.addListener(this.element,"scroll",this.onScroll.bind(this)),s.addListener(this.element,"mousedown",s.preventDefault)};(function(){r.implement(this,o),this.setVisible=function(e){this.element.style.display=e?"":"none",this.isVisible=e,this.coeff=1}}).call(a.prototype);var f=function(e,t){a.call(this,e),this.scrollTop=0,this.scrollHeight=0,t.$scrollbarWidth=this.width=i.scrollbarWidth(e.ownerDocument),this.inner.style.width=this.element.style.width=(this.width||15)+5+"px",this.$minWidth=0};r.inherits(f,a),function(){this.classSuffix="-v",this.onScroll=function(){if(!this.skipEvent){this.scrollTop=this.element.scrollTop;if(this.coeff!=1){var e=this.element.clientHeight/this.scrollHeight;this.scrollTop=this.scrollTop*(1-e)/(this.coeff-e)}this._emit("scroll",{data:this.scrollTop})}this.skipEvent=!1},this.getWidth=function(){return Math.max(this.isVisible?this.width:0,this.$minWidth||0)},this.setHeight=function(e){this.element.style.height=e+"px"},this.setInnerHeight=this.setScrollHeight=function(e){this.scrollHeight=e,e>u?(this.coeff=u/e,e=u):this.coeff!=1&&(this.coeff=1),this.inner.style.height=e+"px"},this.setScrollTop=function(e){this.scrollTop!=e&&(this.skipEvent=!0,this.scrollTop=e,this.element.scrollTop=e*this.coeff)}}.call(f.prototype);var l=function(e,t){a.call(this,e),this.scrollLeft=0,this.height=t.$scrollbarWidth,this.inner.style.height=this.element.style.height=(this.height||15)+5+"px"};r.inherits(l,a),function(){this.classSuffix="-h",this.onScroll=function(){this.skipEvent||(this.scrollLeft=this.element.scrollLeft,this._emit("scroll",{data:this.scrollLeft})),this.skipEvent=!1},this.getHeight=function(){return this.isVisible?this.height:0},this.setWidth=function(e){this.element.style.width=e+"px"},this.setInnerWidth=function(e){this.inner.style.width=e+"px"},this.setScrollWidth=function(e){this.inner.style.width=e+"px"},this.setScrollLeft=function(e){this.scrollLeft!=e&&(this.skipEvent=!0,this.scrollLeft=this.element.scrollLeft=e)}}.call(l.prototype),t.ScrollBar=f,t.ScrollBarV=f,t.ScrollBarH=l,t.VScrollBar=f,t.HScrollBar=l}),ace.define("ace/renderloop",["require","exports","module","ace/lib/event"],function(e,t,n){"use strict";var r=e("./lib/event"),i=function(e,t){this.onRender=e,this.pending=!1,this.changes=0,this.$recursionLimit=2,this.window=t||window;var n=this;this._flush=function(e){n.pending=!1;var t=n.changes;t&&(r.blockIdle(100),n.changes=0,n.onRender(t));if(n.changes){if(n.$recursionLimit--<0)return;n.schedule()}else n.$recursionLimit=2}};(function(){this.schedule=function(e){this.changes=this.changes|e,this.changes&&!this.pending&&(r.nextFrame(this._flush),this.pending=!0)},this.clear=function(e){var t=this.changes;return this.changes=0,t}}).call(i.prototype),t.RenderLoop=i}),ace.define("ace/layer/font_metrics",["require","exports","module","ace/lib/oop","ace/lib/dom","ace/lib/lang","ace/lib/event","ace/lib/useragent","ace/lib/event_emitter"],function(e,t,n){var r=e("../lib/oop"),i=e("../lib/dom"),s=e("../lib/lang"),o=e("../lib/event"),u=e("../lib/useragent"),a=e("../lib/event_emitter").EventEmitter,f=256,l=typeof ResizeObserver=="function",c=200,h=t.FontMetrics=function(e){this.el=i.createElement("div"),this.$setMeasureNodeStyles(this.el.style,!0),this.$main=i.createElement("div"),this.$setMeasureNodeStyles(this.$main.style),this.$measureNode=i.createElement("div"),this.$setMeasureNodeStyles(this.$measureNode.style),this.el.appendChild(this.$main),this.el.appendChild(this.$measureNode),e.appendChild(this.el),this.$measureNode.textContent=s.stringRepeat("X",f),this.$characterSize={width:0,height:0},l?this.$addObserver():this.checkForSizeChanges()};(function(){r.implement(this,a),this.$characterSize={width:0,height:0},this.$setMeasureNodeStyles=function(e,t){e.width=e.height="auto",e.left=e.top="0px",e.visibility="hidden",e.position="absolute",e.whiteSpace="pre",u.isIE<8?e["font-family"]="inherit":e.font="inherit",e.overflow=t?"hidden":"visible"},this.checkForSizeChanges=function(e){e===undefined&&(e=this.$measureSizes());if(e&&(this.$characterSize.width!==e.width||this.$characterSize.height!==e.height)){this.$measureNode.style.fontWeight="bold";var t=this.$measureSizes();this.$measureNode.style.fontWeight="",this.$characterSize=e,this.charSizes=Object.create(null),this.allowBoldFonts=t&&t.width===e.width&&t.height===e.height,this._emit("changeCharacterSize",{data:e})}},this.$addObserver=function(){var e=this;this.$observer=new window.ResizeObserver(function(t){e.checkForSizeChanges()}),this.$observer.observe(this.$measureNode)},this.$pollSizeChanges=function(){if(this.$pollSizeChangesTimer||this.$observer)return this.$pollSizeChangesTimer;var e=this;return this.$pollSizeChangesTimer=o.onIdle(function t(){e.checkForSizeChanges(),o.onIdle(t,500)},500)},this.setPolling=function(e){e?this.$pollSizeChanges():this.$pollSizeChangesTimer&&(clearInterval(this.$pollSizeChangesTimer),this.$pollSizeChangesTimer=0)},this.$measureSizes=function(e){var t={height:(e||this.$measureNode).clientHeight,width:(e||this.$measureNode).clientWidth/f};return t.width===0||t.height===0?null:t},this.$measureCharWidth=function(e){this.$main.textContent=s.stringRepeat(e,f);var t=this.$main.getBoundingClientRect();return t.width/f},this.getCharacterWidth=function(e){var t=this.charSizes[e];return t===undefined&&(t=this.charSizes[e]=this.$measureCharWidth(e)/this.$characterSize.width),t},this.destroy=function(){clearInterval(this.$pollSizeChangesTimer),this.$observer&&this.$observer.disconnect(),this.el&&this.el.parentNode&&this.el.parentNode.removeChild(this.el)},this.$getZoom=function e(t){return!t||!t.parentElement?1:(window.getComputedStyle(t).zoom||1)*e(t.parentElement)},this.$initTransformMeasureNodes=function(){var e=function(e,t){return["div",{style:"position: absolute;top:"+e+"px;left:"+t+"px;"}]};this.els=i.buildDom([e(0,0),e(c,0),e(0,c),e(c,c)],this.el)},this.transformCoordinates=function(e,t){function r(e,t,n){var r=e[1]*t[0]-e[0]*t[1];return[(-t[1]*n[0]+t[0]*n[1])/r,(+e[1]*n[0]-e[0]*n[1])/r]}function i(e,t){return[e[0]-t[0],e[1]-t[1]]}function s(e,t){return[e[0]+t[0],e[1]+t[1]]}function o(e,t){return[e*t[0],e*t[1]]}function u(e){var t=e.getBoundingClientRect();return[t.left,t.top]}if(e){var n=this.$getZoom(this.el);e=o(1/n,e)}this.els||this.$initTransformMeasureNodes();var a=u(this.els[0]),f=u(this.els[1]),l=u(this.els[2]),h=u(this.els[3]),p=r(i(h,f),i(h,l),i(s(f,l),s(h,a))),d=o(1+p[0],i(f,a)),v=o(1+p[1],i(l,a));if(t){var m=t,g=p[0]*m[0]/c+p[1]*m[1]/c+1,y=s(o(m[0],d),o(m[1],v));return s(o(1/g/c,y),a)}var b=i(e,a),w=r(i(d,o(p[0],b)),i(v,o(p[1],b)),b);return o(c,w)}}).call(h.prototype)}),ace.define("ace/virtual_renderer",["require","exports","module","ace/lib/oop","ace/lib/dom","ace/config","ace/layer/gutter","ace/layer/marker","ace/layer/text","ace/layer/cursor","ace/scrollbar","ace/scrollbar","ace/renderloop","ace/layer/font_metrics","ace/lib/event_emitter","ace/lib/useragent"],function(e,t,n){"use strict";var r=e("./lib/oop"),i=e("./lib/dom"),s=e("./config"),o=e("./layer/gutter").Gutter,u=e("./layer/marker").Marker,a=e("./layer/text").Text,f=e("./layer/cursor").Cursor,l=e("./scrollbar").HScrollBar,c=e("./scrollbar").VScrollBar,h=e("./renderloop").RenderLoop,p=e("./layer/font_metrics").FontMetrics,d=e("./lib/event_emitter").EventEmitter,v='.ace_br1 {border-top-left-radius : 3px;}.ace_br2 {border-top-right-radius : 3px;}.ace_br3 {border-top-left-radius : 3px; border-top-right-radius: 3px;}.ace_br4 {border-bottom-right-radius: 3px;}.ace_br5 {border-top-left-radius : 3px; border-bottom-right-radius: 3px;}.ace_br6 {border-top-right-radius : 3px; border-bottom-right-radius: 3px;}.ace_br7 {border-top-left-radius : 3px; border-top-right-radius: 3px; border-bottom-right-radius: 3px;}.ace_br8 {border-bottom-left-radius : 3px;}.ace_br9 {border-top-left-radius : 3px; border-bottom-left-radius: 3px;}.ace_br10{border-top-right-radius : 3px; border-bottom-left-radius: 3px;}.ace_br11{border-top-left-radius : 3px; border-top-right-radius: 3px; border-bottom-left-radius: 3px;}.ace_br12{border-bottom-right-radius: 3px; border-bottom-left-radius: 3px;}.ace_br13{border-top-left-radius : 3px; border-bottom-right-radius: 3px; border-bottom-left-radius: 3px;}.ace_br14{border-top-right-radius : 3px; border-bottom-right-radius: 3px; border-bottom-left-radius: 3px;}.ace_br15{border-top-left-radius : 3px; border-top-right-radius: 3px; border-bottom-right-radius: 3px; border-bottom-left-radius: 3px;}.ace_editor {position: relative;overflow: hidden;padding: 0;font: 12px/normal \'Monaco\', \'Menlo\', \'Ubuntu Mono\', \'Consolas\', \'source-code-pro\', monospace;direction: ltr;text-align: left;-webkit-tap-highlight-color: rgba(0, 0, 0, 0);}.ace_scroller {position: absolute;overflow: hidden;top: 0;bottom: 0;background-color: inherit;-ms-user-select: none;-moz-user-select: none;-webkit-user-select: none;user-select: none;cursor: text;}.ace_content {position: absolute;box-sizing: border-box;min-width: 100%;contain: style size layout;font-variant-ligatures: no-common-ligatures;}.ace_dragging .ace_scroller:before{position: absolute;top: 0;left: 0;right: 0;bottom: 0;content: \'\';background: rgba(250, 250, 250, 0.01);z-index: 1000;}.ace_dragging.ace_dark .ace_scroller:before{background: rgba(0, 0, 0, 0.01);}.ace_selecting, .ace_selecting * {cursor: text !important;}.ace_gutter {position: absolute;overflow : hidden;width: auto;top: 0;bottom: 0;left: 0;cursor: default;z-index: 4;-ms-user-select: none;-moz-user-select: none;-webkit-user-select: none;user-select: none;contain: style size layout;}.ace_gutter-active-line {position: absolute;left: 0;right: 0;}.ace_scroller.ace_scroll-left {box-shadow: 17px 0 16px -16px rgba(0, 0, 0, 0.4) inset;}.ace_gutter-cell {position: absolute;top: 0;left: 0;right: 0;padding-left: 19px;padding-right: 6px;background-repeat: no-repeat;}.ace_gutter-cell.ace_error {background-image: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAMAAAAoLQ9TAAABOFBMVEX/////////QRswFAb/Ui4wFAYwFAYwFAaWGAfDRymzOSH/PxswFAb/SiUwFAYwFAbUPRvjQiDllog5HhHdRybsTi3/Tyv9Tir+Syj/UC3////XurebMBIwFAb/RSHbPx/gUzfdwL3kzMivKBAwFAbbvbnhPx66NhowFAYwFAaZJg8wFAaxKBDZurf/RB6mMxb/SCMwFAYwFAbxQB3+RB4wFAb/Qhy4Oh+4QifbNRcwFAYwFAYwFAb/QRzdNhgwFAYwFAbav7v/Uy7oaE68MBK5LxLewr/r2NXewLswFAaxJw4wFAbkPRy2PyYwFAaxKhLm1tMwFAazPiQwFAaUGAb/QBrfOx3bvrv/VC/maE4wFAbRPBq6MRO8Qynew8Dp2tjfwb0wFAbx6eju5+by6uns4uH9/f36+vr/GkHjAAAAYnRSTlMAGt+64rnWu/bo8eAA4InH3+DwoN7j4eLi4xP99Nfg4+b+/u9B/eDs1MD1mO7+4PHg2MXa347g7vDizMLN4eG+Pv7i5evs/v79yu7S3/DV7/498Yv24eH+4ufQ3Ozu/v7+y13sRqwAAADLSURBVHjaZc/XDsFgGIBhtDrshlitmk2IrbHFqL2pvXf/+78DPokj7+Fz9qpU/9UXJIlhmPaTaQ6QPaz0mm+5gwkgovcV6GZzd5JtCQwgsxoHOvJO15kleRLAnMgHFIESUEPmawB9ngmelTtipwwfASilxOLyiV5UVUyVAfbG0cCPHig+GBkzAENHS0AstVF6bacZIOzgLmxsHbt2OecNgJC83JERmePUYq8ARGkJx6XtFsdddBQgZE2nPR6CICZhawjA4Fb/chv+399kfR+MMMDGOQAAAABJRU5ErkJggg==");background-repeat: no-repeat;background-position: 2px center;}.ace_gutter-cell.ace_warning {background-image: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAMAAAAoLQ9TAAAAmVBMVEX///8AAAD///8AAAAAAABPSzb/5sAAAAB/blH/73z/ulkAAAAAAAD85pkAAAAAAAACAgP/vGz/rkDerGbGrV7/pkQICAf////e0IsAAAD/oED/qTvhrnUAAAD/yHD/njcAAADuv2r/nz//oTj/p064oGf/zHAAAAA9Nir/tFIAAAD/tlTiuWf/tkIAAACynXEAAAAAAAAtIRW7zBpBAAAAM3RSTlMAABR1m7RXO8Ln31Z36zT+neXe5OzooRDfn+TZ4p3h2hTf4t3k3ucyrN1K5+Xaks52Sfs9CXgrAAAAjklEQVR42o3PbQ+CIBQFYEwboPhSYgoYunIqqLn6/z8uYdH8Vmdnu9vz4WwXgN/xTPRD2+sgOcZjsge/whXZgUaYYvT8QnuJaUrjrHUQreGczuEafQCO/SJTufTbroWsPgsllVhq3wJEk2jUSzX3CUEDJC84707djRc5MTAQxoLgupWRwW6UB5fS++NV8AbOZgnsC7BpEAAAAABJRU5ErkJggg==");background-position: 2px center;}.ace_gutter-cell.ace_info {background-image: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAAAAAA6mKC9AAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAAAJ0Uk5TAAB2k804AAAAPklEQVQY02NgIB68QuO3tiLznjAwpKTgNyDbMegwisCHZUETUZV0ZqOquBpXj2rtnpSJT1AEnnRmL2OgGgAAIKkRQap2htgAAAAASUVORK5CYII=");background-position: 2px center;}.ace_dark .ace_gutter-cell.ace_info {background-image: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQBAMAAADt3eJSAAAAJFBMVEUAAAChoaGAgIAqKiq+vr6tra1ZWVmUlJSbm5s8PDxubm56enrdgzg3AAAAAXRSTlMAQObYZgAAAClJREFUeNpjYMAPdsMYHegyJZFQBlsUlMFVCWUYKkAZMxZAGdxlDMQBAG+TBP4B6RyJAAAAAElFTkSuQmCC");}.ace_scrollbar {contain: strict;position: absolute;right: 0;bottom: 0;z-index: 6;}.ace_scrollbar-inner {position: absolute;cursor: text;left: 0;top: 0;}.ace_scrollbar-v{overflow-x: hidden;overflow-y: scroll;top: 0;}.ace_scrollbar-h {overflow-x: scroll;overflow-y: hidden;left: 0;}.ace_print-margin {position: absolute;height: 100%;}.ace_text-input {position: absolute;z-index: 0;width: 0.5em;height: 1em;opacity: 0;background: transparent;-moz-appearance: none;appearance: none;border: none;resize: none;outline: none;overflow: hidden;font: inherit;padding: 0 1px;margin: 0 -1px;contain: strict;-ms-user-select: text;-moz-user-select: text;-webkit-user-select: text;user-select: text;white-space: pre!important;}.ace_text-input.ace_composition {background: transparent;color: inherit;z-index: 1000;opacity: 1;}.ace_composition_placeholder { color: transparent }.ace_composition_marker { border-bottom: 1px solid;position: absolute;border-radius: 0;margin-top: 1px;}[ace_nocontext=true] {transform: none!important;filter: none!important;clip-path: none!important;mask : none!important;contain: none!important;perspective: none!important;mix-blend-mode: initial!important;z-index: auto;}.ace_layer {z-index: 1;position: absolute;overflow: hidden;word-wrap: normal;white-space: pre;height: 100%;width: 100%;box-sizing: border-box;pointer-events: none;}.ace_gutter-layer {position: relative;width: auto;text-align: right;pointer-events: auto;height: 1000000px;contain: style size layout;}.ace_text-layer {font: inherit !important;position: absolute;height: 1000000px;width: 1000000px;contain: style size layout;}.ace_text-layer > .ace_line, .ace_text-layer > .ace_line_group {contain: style size layout;position: absolute;top: 0;left: 0;right: 0;}.ace_hidpi .ace_text-layer,.ace_hidpi .ace_gutter-layer,.ace_hidpi .ace_content,.ace_hidpi .ace_gutter {contain: strict;will-change: transform;}.ace_hidpi .ace_text-layer > .ace_line, .ace_hidpi .ace_text-layer > .ace_line_group {contain: strict;}.ace_cjk {display: inline-block;text-align: center;}.ace_cursor-layer {z-index: 4;}.ace_cursor {z-index: 4;position: absolute;box-sizing: border-box;border-left: 2px solid;transform: translatez(0);}.ace_multiselect .ace_cursor {border-left-width: 1px;}.ace_slim-cursors .ace_cursor {border-left-width: 1px;}.ace_overwrite-cursors .ace_cursor {border-left-width: 0;border-bottom: 1px solid;}.ace_hidden-cursors .ace_cursor {opacity: 0.2;}.ace_hasPlaceholder .ace_hidden-cursors .ace_cursor {opacity: 0;}.ace_smooth-blinking .ace_cursor {transition: opacity 0.18s;}.ace_animate-blinking .ace_cursor {animation-duration: 1000ms;animation-timing-function: step-end;animation-name: blink-ace-animate;animation-iteration-count: infinite;}.ace_animate-blinking.ace_smooth-blinking .ace_cursor {animation-duration: 1000ms;animation-timing-function: ease-in-out;animation-name: blink-ace-animate-smooth;}@keyframes blink-ace-animate {from, to { opacity: 1; }60% { opacity: 0; }}@keyframes blink-ace-animate-smooth {from, to { opacity: 1; }45% { opacity: 1; }60% { opacity: 0; }85% { opacity: 0; }}.ace_marker-layer .ace_step, .ace_marker-layer .ace_stack {position: absolute;z-index: 3;}.ace_marker-layer .ace_selection {position: absolute;z-index: 5;}.ace_marker-layer .ace_bracket {position: absolute;z-index: 6;}.ace_marker-layer .ace_error_bracket {position: absolute;border-bottom: 1px solid #DE5555;border-radius: 0;}.ace_marker-layer .ace_active-line {position: absolute;z-index: 2;}.ace_marker-layer .ace_selected-word {position: absolute;z-index: 4;box-sizing: border-box;}.ace_line .ace_fold {box-sizing: border-box;display: inline-block;height: 11px;margin-top: -2px;vertical-align: middle;background-image:url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABEAAAAJCAYAAADU6McMAAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAAJpJREFUeNpi/P//PwOlgAXGYGRklAVSokD8GmjwY1wasKljQpYACtpCFeADcHVQfQyMQAwzwAZI3wJKvCLkfKBaMSClBlR7BOQikCFGQEErIH0VqkabiGCAqwUadAzZJRxQr/0gwiXIal8zQQPnNVTgJ1TdawL0T5gBIP1MUJNhBv2HKoQHHjqNrA4WO4zY0glyNKLT2KIfIMAAQsdgGiXvgnYAAAAASUVORK5CYII="),url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAA3CAYAAADNNiA5AAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAACJJREFUeNpi+P//fxgTAwPDBxDxD078RSX+YeEyDFMCIMAAI3INmXiwf2YAAAAASUVORK5CYII=");background-repeat: no-repeat, repeat-x;background-position: center center, top left;color: transparent;border: 1px solid black;border-radius: 2px;cursor: pointer;pointer-events: auto;}.ace_dark .ace_fold {}.ace_fold:hover{background-image:url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABEAAAAJCAYAAADU6McMAAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAAJpJREFUeNpi/P//PwOlgAXGYGRklAVSokD8GmjwY1wasKljQpYACtpCFeADcHVQfQyMQAwzwAZI3wJKvCLkfKBaMSClBlR7BOQikCFGQEErIH0VqkabiGCAqwUadAzZJRxQr/0gwiXIal8zQQPnNVTgJ1TdawL0T5gBIP1MUJNhBv2HKoQHHjqNrA4WO4zY0glyNKLT2KIfIMAAQsdgGiXvgnYAAAAASUVORK5CYII="),url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAA3CAYAAADNNiA5AAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAACBJREFUeNpi+P//fz4TAwPDZxDxD5X4i5fLMEwJgAADAEPVDbjNw87ZAAAAAElFTkSuQmCC");}.ace_tooltip {background-color: #FFF;background-image: linear-gradient(to bottom, transparent, rgba(0, 0, 0, 0.1));border: 1px solid gray;border-radius: 1px;box-shadow: 0 1px 2px rgba(0, 0, 0, 0.3);color: black;max-width: 100%;padding: 3px 4px;position: fixed;z-index: 999999;box-sizing: border-box;cursor: default;white-space: pre;word-wrap: break-word;line-height: normal;font-style: normal;font-weight: normal;letter-spacing: normal;pointer-events: none;}.ace_folding-enabled > .ace_gutter-cell {padding-right: 13px;}.ace_fold-widget {box-sizing: border-box;margin: 0 -12px 0 1px;display: none;width: 11px;vertical-align: top;background-image: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAUAAAAFCAYAAACNbyblAAAANElEQVR42mWKsQ0AMAzC8ixLlrzQjzmBiEjp0A6WwBCSPgKAXoLkqSot7nN3yMwR7pZ32NzpKkVoDBUxKAAAAABJRU5ErkJggg==");background-repeat: no-repeat;background-position: center;border-radius: 3px;border: 1px solid transparent;cursor: pointer;}.ace_folding-enabled .ace_fold-widget {display: inline-block; }.ace_fold-widget.ace_end {background-image: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAUAAAAFCAYAAACNbyblAAAANElEQVR42m3HwQkAMAhD0YzsRchFKI7sAikeWkrxwScEB0nh5e7KTPWimZki4tYfVbX+MNl4pyZXejUO1QAAAABJRU5ErkJggg==");}.ace_fold-widget.ace_closed {background-image: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAMAAAAGCAYAAAAG5SQMAAAAOUlEQVR42jXKwQkAMAgDwKwqKD4EwQ26sSOkVWjgIIHAzPiCgaqiqnJHZnKICBERHN194O5b9vbLuAVRL+l0YWnZAAAAAElFTkSuQmCCXA==");}.ace_fold-widget:hover {border: 1px solid rgba(0, 0, 0, 0.3);background-color: rgba(255, 255, 255, 0.2);box-shadow: 0 1px 1px rgba(255, 255, 255, 0.7);}.ace_fold-widget:active {border: 1px solid rgba(0, 0, 0, 0.4);background-color: rgba(0, 0, 0, 0.05);box-shadow: 0 1px 1px rgba(255, 255, 255, 0.8);}.ace_dark .ace_fold-widget {background-image: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAUAAAAFCAYAAACNbyblAAAAHklEQVQIW2P4//8/AzoGEQ7oGCaLLAhWiSwB146BAQCSTPYocqT0AAAAAElFTkSuQmCC");}.ace_dark .ace_fold-widget.ace_end {background-image: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAUAAAAFCAYAAACNbyblAAAAH0lEQVQIW2P4//8/AxQ7wNjIAjDMgC4AxjCVKBirIAAF0kz2rlhxpAAAAABJRU5ErkJggg==");}.ace_dark .ace_fold-widget.ace_closed {background-image: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAMAAAAFCAYAAACAcVaiAAAAHElEQVQIW2P4//+/AxAzgDADlOOAznHAKgPWAwARji8UIDTfQQAAAABJRU5ErkJggg==");}.ace_dark .ace_fold-widget:hover {box-shadow: 0 1px 1px rgba(255, 255, 255, 0.2);background-color: rgba(255, 255, 255, 0.1);}.ace_dark .ace_fold-widget:active {box-shadow: 0 1px 1px rgba(255, 255, 255, 0.2);}.ace_inline_button {border: 1px solid lightgray;display: inline-block;margin: -1px 8px;padding: 0 5px;pointer-events: auto;cursor: pointer;}.ace_inline_button:hover {border-color: gray;background: rgba(200,200,200,0.2);display: inline-block;pointer-events: auto;}.ace_fold-widget.ace_invalid {background-color: #FFB4B4;border-color: #DE5555;}.ace_fade-fold-widgets .ace_fold-widget {transition: opacity 0.4s ease 0.05s;opacity: 0;}.ace_fade-fold-widgets:hover .ace_fold-widget {transition: opacity 0.05s ease 0.05s;opacity:1;}.ace_underline {text-decoration: underline;}.ace_bold {font-weight: bold;}.ace_nobold .ace_bold {font-weight: normal;}.ace_italic {font-style: italic;}.ace_error-marker {background-color: rgba(255, 0, 0,0.2);position: absolute;z-index: 9;}.ace_highlight-marker {background-color: rgba(255, 255, 0,0.2);position: absolute;z-index: 8;}.ace_mobile-menu {position: absolute;line-height: 1.5;border-radius: 4px;-ms-user-select: none;-moz-user-select: none;-webkit-user-select: none;user-select: none;background: white;box-shadow: 1px 3px 2px grey;border: 1px solid #dcdcdc;color: black;}.ace_dark > .ace_mobile-menu {background: #333;color: #ccc;box-shadow: 1px 3px 2px grey;border: 1px solid #444;}.ace_mobile-button {padding: 2px;cursor: pointer;overflow: hidden;}.ace_mobile-button:hover {background-color: #eee;opacity:1;}.ace_mobile-button:active {background-color: #ddd;}.ace_placeholder {font-family: arial;transform: scale(0.9);transform-origin: left;white-space: pre;opacity: 0.7;margin: 0 10px;}',m=e("./lib/useragent"),g=m.isIE;i.importCssString(v,"ace_editor.css");var y=function(e,t){var n=this;this.container=e||i.createElement("div"),i.addCssClass(this.container,"ace_editor"),i.HI_DPI&&i.addCssClass(this.container,"ace_hidpi"),this.setTheme(t),this.$gutter=i.createElement("div"),this.$gutter.className="ace_gutter",this.container.appendChild(this.$gutter),this.$gutter.setAttribute("aria-hidden",!0),this.scroller=i.createElement("div"),this.scroller.className="ace_scroller",this.container.appendChild(this.scroller),this.content=i.createElement("div"),this.content.className="ace_content",this.scroller.appendChild(this.content),this.$gutterLayer=new o(this.$gutter),this.$gutterLayer.on("changeGutterWidth",this.onGutterResize.bind(this)),this.$markerBack=new u(this.content);var r=this.$textLayer=new a(this.content);this.canvas=r.element,this.$markerFront=new u(this.content),this.$cursorLayer=new f(this.content),this.$horizScroll=!1,this.$vScroll=!1,this.scrollBar=this.scrollBarV=new c(this.container,this),this.scrollBarH=new l(this.container,this),this.scrollBarV.on("scroll",function(e){n.$scrollAnimation||n.session.setScrollTop(e.data-n.scrollMargin.top)}),this.scrollBarH.on("scroll",function(e){n.$scrollAnimation||n.session.setScrollLeft(e.data-n.scrollMargin.left)}),this.scrollTop=0,this.scrollLeft=0,this.cursorPos={row:0,column:0},this.$fontMetrics=new p(this.container),this.$textLayer.$setFontMetrics(this.$fontMetrics),this.$textLayer.on("changeCharacterSize",function(e){n.updateCharacterSize(),n.onResize(!0,n.gutterWidth,n.$size.width,n.$size.height),n._signal("changeCharacterSize",e)}),this.$size={width:0,height:0,scrollerHeight:0,scrollerWidth:0,$dirty:!0},this.layerConfig={width:1,padding:0,firstRow:0,firstRowScreen:0,lastRow:0,lineHeight:0,characterWidth:0,minHeight:1,maxHeight:1,offset:0,height:1,gutterOffset:1},this.scrollMargin={left:0,right:0,top:0,bottom:0,v:0,h:0},this.margin={left:0,right:0,top:0,bottom:0,v:0,h:0},this.$keepTextAreaAtCursor=!m.isIOS,this.$loop=new h(this.$renderChanges.bind(this),this.container.ownerDocument.defaultView),this.$loop.schedule(this.CHANGE_FULL),this.updateCharacterSize(),this.setPadding(4),s.resetOptions(this),s._signal("renderer",this)};(function(){this.CHANGE_CURSOR=1,this.CHANGE_MARKER=2,this.CHANGE_GUTTER=4,this.CHANGE_SCROLL=8,this.CHANGE_LINES=16,this.CHANGE_TEXT=32,this.CHANGE_SIZE=64,this.CHANGE_MARKER_BACK=128,this.CHANGE_MARKER_FRONT=256,this.CHANGE_FULL=512,this.CHANGE_H_SCROLL=1024,r.implement(this,d),this.updateCharacterSize=function(){this.$textLayer.allowBoldFonts!=this.$allowBoldFonts&&(this.$allowBoldFonts=this.$textLayer.allowBoldFonts,this.setStyle("ace_nobold",!this.$allowBoldFonts)),this.layerConfig.characterWidth=this.characterWidth=this.$textLayer.getCharacterWidth(),this.layerConfig.lineHeight=this.lineHeight=this.$textLayer.getLineHeight(),this.$updatePrintMargin(),i.setStyle(this.scroller.style,"line-height",this.lineHeight+"px")},this.setSession=function(e){this.session&&this.session.doc.off("changeNewLineMode",this.onChangeNewLineMode),this.session=e,e&&this.scrollMargin.top&&e.getScrollTop()<=0&&e.setScrollTop(-this.scrollMargin.top),this.$cursorLayer.setSession(e),this.$markerBack.setSession(e),this.$markerFront.setSession(e),this.$gutterLayer.setSession(e),this.$textLayer.setSession(e);if(!e)return;this.$loop.schedule(this.CHANGE_FULL),this.session.$setFontMetrics(this.$fontMetrics),this.scrollBarH.scrollLeft=this.scrollBarV.scrollTop=null,this.onChangeNewLineMode=this.onChangeNewLineMode.bind(this),this.onChangeNewLineMode(),this.session.doc.on("changeNewLineMode",this.onChangeNewLineMode)},this.updateLines=function(e,t,n){t===undefined&&(t=Infinity),this.$changedLines?(this.$changedLines.firstRow>e&&(this.$changedLines.firstRow=e),this.$changedLines.lastRow<t&&(this.$changedLines.lastRow=t)):this.$changedLines={firstRow:e,lastRow:t};if(this.$changedLines.lastRow<this.layerConfig.firstRow){if(!n)return;this.$changedLines.lastRow=this.layerConfig.lastRow}if(this.$changedLines.firstRow>this.layerConfig.lastRow)return;this.$loop.schedule(this.CHANGE_LINES)},this.onChangeNewLineMode=function(){this.$loop.schedule(this.CHANGE_TEXT),this.$textLayer.$updateEolChar(),this.session.$bidiHandler.setEolChar(this.$textLayer.EOL_CHAR)},this.onChangeTabSize=function(){this.$loop.schedule(this.CHANGE_TEXT|this.CHANGE_MARKER),this.$textLayer.onChangeTabSize()},this.updateText=function(){this.$loop.schedule(this.CHANGE_TEXT)},this.updateFull=function(e){e?this.$renderChanges(this.CHANGE_FULL,!0):this.$loop.schedule(this.CHANGE_FULL)},this.updateFontSize=function(){this.$textLayer.checkForSizeChanges()},this.$changes=0,this.$updateSizeAsync=function(){this.$loop.pending?this.$size.$dirty=!0:this.onResize()},this.onResize=function(e,t,n,r){if(this.resizing>2)return;this.resizing>0?this.resizing++:this.resizing=e?1:0;var i=this.container;r||(r=i.clientHeight||i.scrollHeight),n||(n=i.clientWidth||i.scrollWidth);var s=this.$updateCachedSize(e,t,n,r);if(!this.$size.scrollerHeight||!n&&!r)return this.resizing=0;e&&(this.$gutterLayer.$padding=null),e?this.$renderChanges(s|this.$changes,!0):this.$loop.schedule(s|this.$changes),this.resizing&&(this.resizing=0),this.scrollBarV.scrollLeft=this.scrollBarV.scrollTop=null},this.$updateCachedSize=function(e,t,n,r){r-=this.$extraHeight||0;var s=0,o=this.$size,u={width:o.width,height:o.height,scrollerHeight:o.scrollerHeight,scrollerWidth:o.scrollerWidth};r&&(e||o.height!=r)&&(o.height=r,s|=this.CHANGE_SIZE,o.scrollerHeight=o.height,this.$horizScroll&&(o.scrollerHeight-=this.scrollBarH.getHeight()),this.scrollBarV.element.style.bottom=this.scrollBarH.getHeight()+"px",s|=this.CHANGE_SCROLL);if(n&&(e||o.width!=n)){s|=this.CHANGE_SIZE,o.width=n,t==null&&(t=this.$showGutter?this.$gutter.offsetWidth:0),this.gutterWidth=t,i.setStyle(this.scrollBarH.element.style,"left",t+"px"),i.setStyle(this.scroller.style,"left",t+this.margin.left+"px"),o.scrollerWidth=Math.max(0,n-t-this.scrollBarV.getWidth()-this.margin.h),i.setStyle(this.$gutter.style,"left",this.margin.left+"px");var a=this.scrollBarV.getWidth()+"px";i.setStyle(this.scrollBarH.element.style,"right",a),i.setStyle(this.scroller.style,"right",a),i.setStyle(this.scroller.style,"bottom",this.scrollBarH.getHeight());if(this.session&&this.session.getUseWrapMode()&&this.adjustWrapLimit()||e)s|=this.CHANGE_FULL}return o.$dirty=!n||!r,s&&this._signal("resize",u),s},this.onGutterResize=function(e){var t=this.$showGutter?e:0;t!=this.gutterWidth&&(this.$changes|=this.$updateCachedSize(!0,t,this.$size.width,this.$size.height)),this.session.getUseWrapMode()&&this.adjustWrapLimit()?this.$loop.schedule(this.CHANGE_FULL):this.$size.$dirty?this.$loop.schedule(this.CHANGE_FULL):this.$computeLayerConfig()},this.adjustWrapLimit=function(){var e=this.$size.scrollerWidth-this.$padding*2,t=Math.floor(e/this.characterWidth);return this.session.adjustWrapLimit(t,this.$showPrintMargin&&this.$printMarginColumn)},this.setAnimatedScroll=function(e){this.setOption("animatedScroll",e)},this.getAnimatedScroll=function(){return this.$animatedScroll},this.setShowInvisibles=function(e){this.setOption("showInvisibles",e),this.session.$bidiHandler.setShowInvisibles(e)},this.getShowInvisibles=function(){return this.getOption("showInvisibles")},this.getDisplayIndentGuides=function(){return this.getOption("displayIndentGuides")},this.setDisplayIndentGuides=function(e){this.setOption("displayIndentGuides",e)},this.setShowPrintMargin=function(e){this.setOption("showPrintMargin",e)},this.getShowPrintMargin=function(){return this.getOption("showPrintMargin")},this.setPrintMarginColumn=function(e){this.setOption("printMarginColumn",e)},this.getPrintMarginColumn=function(){return this.getOption("printMarginColumn")},this.getShowGutter=function(){return this.getOption("showGutter")},this.setShowGutter=function(e){return this.setOption("showGutter",e)},this.getFadeFoldWidgets=function(){return this.getOption("fadeFoldWidgets")},this.setFadeFoldWidgets=function(e){this.setOption("fadeFoldWidgets",e)},this.setHighlightGutterLine=function(e){this.setOption("highlightGutterLine",e)},this.getHighlightGutterLine=function(){return this.getOption("highlightGutterLine")},this.$updatePrintMargin=function(){if(!this.$showPrintMargin&&!this.$printMarginEl)return;if(!this.$printMarginEl){var e=i.createElement("div");e.className="ace_layer ace_print-margin-layer",this.$printMarginEl=i.createElement("div"),this.$printMarginEl.className="ace_print-margin",e.appendChild(this.$printMarginEl),this.content.insertBefore(e,this.content.firstChild)}var t=this.$printMarginEl.style;t.left=Math.round(this.characterWidth*this.$printMarginColumn+this.$padding)+"px",t.visibility=this.$showPrintMargin?"visible":"hidden",this.session&&this.session.$wrap==-1&&this.adjustWrapLimit()},this.getContainerElement=function(){return this.container},this.getMouseEventTarget=function(){return this.scroller},this.getTextAreaContainer=function(){return this.container},this.$moveTextAreaToCursor=function(){if(this.$isMousePressed)return;var e=this.textarea.style,t=this.$composition;if(!this.$keepTextAreaAtCursor&&!t){i.translate(this.textarea,-100,0);return}var n=this.$cursorLayer.$pixelPos;if(!n)return;t&&t.markerRange&&(n=this.$cursorLayer.getPixelPosition(t.markerRange.start,!0));var r=this.layerConfig,s=n.top,o=n.left;s-=r.offset;var u=t&&t.useTextareaForIME?this.lineHeight:g?0:1;if(s<0||s>r.height-u){i.translate(this.textarea,0,0);return}var a=1,f=this.$size.height-u;if(!t)s+=this.lineHeight;else if(t.useTextareaForIME){var l=this.textarea.value;a=this.characterWidth*this.session.$getStringScreenWidth(l)[0]}else s+=this.lineHeight+2;o-=this.scrollLeft,o>this.$size.scrollerWidth-a&&(o=this.$size.scrollerWidth-a),o+=this.gutterWidth+this.margin.left,i.setStyle(e,"height",u+"px"),i.setStyle(e,"width",a+"px"),i.translate(this.textarea,Math.min(o,this.$size.scrollerWidth-a),Math.min(s,f))},this.getFirstVisibleRow=function(){return this.layerConfig.firstRow},this.getFirstFullyVisibleRow=function(){return this.layerConfig.firstRow+(this.layerConfig.offset===0?0:1)},this.getLastFullyVisibleRow=function(){var e=this.layerConfig,t=e.lastRow,n=this.session.documentToScreenRow(t,0)*e.lineHeight;return n-this.session.getScrollTop()>e.height-e.lineHeight?t-1:t},this.getLastVisibleRow=function(){return this.layerConfig.lastRow},this.$padding=null,this.setPadding=function(e){this.$padding=e,this.$textLayer.setPadding(e),this.$cursorLayer.setPadding(e),this.$markerFront.setPadding(e),this.$markerBack.setPadding(e),this.$loop.schedule(this.CHANGE_FULL),this.$updatePrintMargin()},this.setScrollMargin=function(e,t,n,r){var i=this.scrollMargin;i.top=e|0,i.bottom=t|0,i.right=r|0,i.left=n|0,i.v=i.top+i.bottom,i.h=i.left+i.right,i.top&&this.scrollTop<=0&&this.session&&this.session.setScrollTop(-i.top),this.updateFull()},this.setMargin=function(e,t,n,r){var i=this.margin;i.top=e|0,i.bottom=t|0,i.right=r|0,i.left=n|0,i.v=i.top+i.bottom,i.h=i.left+i.right,this.$updateCachedSize(!0,this.gutterWidth,this.$size.width,this.$size.height),this.updateFull()},this.getHScrollBarAlwaysVisible=function(){return this.$hScrollBarAlwaysVisible},this.setHScrollBarAlwaysVisible=function(e){this.setOption("hScrollBarAlwaysVisible",e)},this.getVScrollBarAlwaysVisible=function(){return this.$vScrollBarAlwaysVisible},this.setVScrollBarAlwaysVisible=function(e){this.setOption("vScrollBarAlwaysVisible",e)},this.$updateScrollBarV=function(){var e=this.layerConfig.maxHeight,t=this.$size.scrollerHeight;!this.$maxLines&&this.$scrollPastEnd&&(e-=(t-this.lineHeight)*this.$scrollPastEnd,this.scrollTop>e-t&&(e=this.scrollTop+t,this.scrollBarV.scrollTop=null)),this.scrollBarV.setScrollHeight(e+this.scrollMargin.v),this.scrollBarV.setScrollTop(this.scrollTop+this.scrollMargin.top)},this.$updateScrollBarH=function(){this.scrollBarH.setScrollWidth(this.layerConfig.width+2*this.$padding+this.scrollMargin.h),this.scrollBarH.setScrollLeft(this.scrollLeft+this.scrollMargin.left)},this.$frozen=!1,this.freeze=function(){this.$frozen=!0},this.unfreeze=function(){this.$frozen=!1},this.$renderChanges=function(e,t){this.$changes&&(e|=this.$changes,this.$changes=0);if(!this.session||!this.container.offsetWidth||this.$frozen||!e&&!t){this.$changes|=e;return}if(this.$size.$dirty)return this.$changes|=e,this.onResize(!0);this.lineHeight||this.$textLayer.checkForSizeChanges(),this._signal("beforeRender",e),this.session&&this.session.$bidiHandler&&this.session.$bidiHandler.updateCharacterWidths(this.$fontMetrics);var n=this.layerConfig;if(e&this.CHANGE_FULL||e&this.CHANGE_SIZE||e&this.CHANGE_TEXT||e&this.CHANGE_LINES||e&this.CHANGE_SCROLL||e&this.CHANGE_H_SCROLL){e|=this.$computeLayerConfig()|this.$loop.clear();if(n.firstRow!=this.layerConfig.firstRow&&n.firstRowScreen==this.layerConfig.firstRowScreen){var r=this.scrollTop+(n.firstRow-this.layerConfig.firstRow)*this.lineHeight;r>0&&(this.scrollTop=r,e|=this.CHANGE_SCROLL,e|=this.$computeLayerConfig()|this.$loop.clear())}n=this.layerConfig,this.$updateScrollBarV(),e&this.CHANGE_H_SCROLL&&this.$updateScrollBarH(),i.translate(this.content,-this.scrollLeft,-n.offset);var s=n.width+2*this.$padding+"px",o=n.minHeight+"px";i.setStyle(this.content.style,"width",s),i.setStyle(this.content.style,"height",o)}e&this.CHANGE_H_SCROLL&&(i.translate(this.content,-this.scrollLeft,-n.offset),this.scroller.className=this.scrollLeft<=0?"ace_scroller":"ace_scroller ace_scroll-left");if(e&this.CHANGE_FULL){this.$changedLines=null,this.$textLayer.update(n),this.$showGutter&&this.$gutterLayer.update(n),this.$markerBack.update(n),this.$markerFront.update(n),this.$cursorLayer.update(n),this.$moveTextAreaToCursor(),this._signal("afterRender",e);return}if(e&this.CHANGE_SCROLL){this.$changedLines=null,e&this.CHANGE_TEXT||e&this.CHANGE_LINES?this.$textLayer.update(n):this.$textLayer.scrollLines(n),this.$showGutter&&(e&this.CHANGE_GUTTER||e&this.CHANGE_LINES?this.$gutterLayer.update(n):this.$gutterLayer.scrollLines(n)),this.$markerBack.update(n),this.$markerFront.update(n),this.$cursorLayer.update(n),this.$moveTextAreaToCursor(),this._signal("afterRender",e);return}e&this.CHANGE_TEXT?(this.$changedLines=null,this.$textLayer.update(n),this.$showGutter&&this.$gutterLayer.update(n)):e&this.CHANGE_LINES?(this.$updateLines()||e&this.CHANGE_GUTTER&&this.$showGutter)&&this.$gutterLayer.update(n):e&this.CHANGE_TEXT||e&this.CHANGE_GUTTER?this.$showGutter&&this.$gutterLayer.update(n):e&this.CHANGE_CURSOR&&this.$highlightGutterLine&&this.$gutterLayer.updateLineHighlight(n),e&this.CHANGE_CURSOR&&(this.$cursorLayer.update(n),this.$moveTextAreaToCursor()),e&(this.CHANGE_MARKER|this.CHANGE_MARKER_FRONT)&&this.$markerFront.update(n),e&(this.CHANGE_MARKER|this.CHANGE_MARKER_BACK)&&this.$markerBack.update(n),this._signal("afterRender",e)},this.$autosize=function(){var e=this.session.getScreenLength()*this.lineHeight,t=this.$maxLines*this.lineHeight,n=Math.min(t,Math.max((this.$minLines||1)*this.lineHeight,e))+this.scrollMargin.v+(this.$extraHeight||0);this.$horizScroll&&(n+=this.scrollBarH.getHeight()),this.$maxPixelHeight&&n>this.$maxPixelHeight&&(n=this.$maxPixelHeight);var r=n<=2*this.lineHeight,i=!r&&e>t;if(n!=this.desiredHeight||this.$size.height!=this.desiredHeight||i!=this.$vScroll){i!=this.$vScroll&&(this.$vScroll=i,this.scrollBarV.setVisible(i));var s=this.container.clientWidth;this.container.style.height=n+"px",this.$updateCachedSize(!0,this.$gutterWidth,s,n),this.desiredHeight=n,this._signal("autosize")}},this.$computeLayerConfig=function(){var e=this.session,t=this.$size,n=t.height<=2*this.lineHeight,r=this.session.getScreenLength(),i=r*this.lineHeight,s=this.$getLongestLine(),o=!n&&(this.$hScrollBarAlwaysVisible||t.scrollerWidth-s-2*this.$padding<0),u=this.$horizScroll!==o;u&&(this.$horizScroll=o,this.scrollBarH.setVisible(o));var a=this.$vScroll;this.$maxLines&&this.lineHeight>1&&this.$autosize();var f=t.scrollerHeight+this.lineHeight,l=!this.$maxLines&&this.$scrollPastEnd?(t.scrollerHeight-this.lineHeight)*this.$scrollPastEnd:0;i+=l;var c=this.scrollMargin;this.session.setScrollTop(Math.max(-c.top,Math.min(this.scrollTop,i-t.scrollerHeight+c.bottom))),this.session.setScrollLeft(Math.max(-c.left,Math.min(this.scrollLeft,s+2*this.$padding-t.scrollerWidth+c.right)));var h=!n&&(this.$vScrollBarAlwaysVisible||t.scrollerHeight-i+l<0||this.scrollTop>c.top),p=a!==h;p&&(this.$vScroll=h,this.scrollBarV.setVisible(h));var d=this.scrollTop%this.lineHeight,v=Math.ceil(f/this.lineHeight)-1,m=Math.max(0,Math.round((this.scrollTop-d)/this.lineHeight)),g=m+v,y,b,w=this.lineHeight;m=e.screenToDocumentRow(m,0);var E=e.getFoldLine(m);E&&(m=E.start.row),y=e.documentToScreenRow(m,0),b=e.getRowLength(m)*w,g=Math.min(e.screenToDocumentRow(g,0),e.getLength()-1),f=t.scrollerHeight+e.getRowLength(g)*w+b,d=this.scrollTop-y*w;var S=0;if(this.layerConfig.width!=s||u)S=this.CHANGE_H_SCROLL;if(u||p)S|=this.$updateCachedSize(!0,this.gutterWidth,t.width,t.height),this._signal("scrollbarVisibilityChanged"),p&&(s=this.$getLongestLine());return this.layerConfig={width:s,padding:this.$padding,firstRow:m,firstRowScreen:y,lastRow:g,lineHeight:w,characterWidth:this.characterWidth,minHeight:f,maxHeight:i,offset:d,gutterOffset:w?Math.max(0,Math.ceil((d+t.height-t.scrollerHeight)/w)):0,height:this.$size.scrollerHeight},this.session.$bidiHandler&&this.session.$bidiHandler.setContentWidth(s-this.$padding),S},this.$updateLines=function(){if(!this.$changedLines)return;var e=this.$changedLines.firstRow,t=this.$changedLines.lastRow;this.$changedLines=null;var n=this.layerConfig;if(e>n.lastRow+1)return;if(t<n.firstRow)return;if(t===Infinity){this.$showGutter&&this.$gutterLayer.update(n),this.$textLayer.update(n);return}return this.$textLayer.updateLines(n,e,t),!0},this.$getLongestLine=function(){var e=this.session.getScreenWidth();return this.showInvisibles&&!this.session.$useWrapMode&&(e+=1),this.$textLayer&&e>this.$textLayer.MAX_LINE_LENGTH&&(e=this.$textLayer.MAX_LINE_LENGTH+30),Math.max(this.$size.scrollerWidth-2*this.$padding,Math.round(e*this.characterWidth))},this.updateFrontMarkers=function(){this.$markerFront.setMarkers(this.session.getMarkers(!0)),this.$loop.schedule(this.CHANGE_MARKER_FRONT)},this.updateBackMarkers=function(){this.$markerBack.setMarkers(this.session.getMarkers()),this.$loop.schedule(this.CHANGE_MARKER_BACK)},this.addGutterDecoration=function(e,t){this.$gutterLayer.addGutterDecoration(e,t)},this.removeGutterDecoration=function(e,t){this.$gutterLayer.removeGutterDecoration(e,t)},this.updateBreakpoints=function(e){this.$loop.schedule(this.CHANGE_GUTTER)},this.setAnnotations=function(e){this.$gutterLayer.setAnnotations(e),this.$loop.schedule(this.CHANGE_GUTTER)},this.updateCursor=function(){this.$loop.schedule(this.CHANGE_CURSOR)},this.hideCursor=function(){this.$cursorLayer.hideCursor()},this.showCursor=function(){this.$cursorLayer.showCursor()},this.scrollSelectionIntoView=function(e,t,n){this.scrollCursorIntoView(e,n),this.scrollCursorIntoView(t,n)},this.scrollCursorIntoView=function(e,t,n){if(this.$size.scrollerHeight===0)return;var r=this.$cursorLayer.getPixelPosition(e),i=r.left,s=r.top,o=n&&n.top||0,u=n&&n.bottom||0,a=this.$scrollAnimation?this.session.getScrollTop():this.scrollTop;a+o>s?(t&&a+o>s+this.lineHeight&&(s-=t*this.$size.scrollerHeight),s===0&&(s=-this.scrollMargin.top),this.session.setScrollTop(s)):a+this.$size.scrollerHeight-u<s+this.lineHeight&&(t&&a+this.$size.scrollerHeight-u<s-this.lineHeight&&(s+=t*this.$size.scrollerHeight),this.session.setScrollTop(s+this.lineHeight+u-this.$size.scrollerHeight));var f=this.scrollLeft;f>i?(i<this.$padding+2*this.layerConfig.characterWidth&&(i=-this.scrollMargin.left),this.session.setScrollLeft(i)):f+this.$size.scrollerWidth<i+this.characterWidth?this.session.setScrollLeft(Math.round(i+this.characterWidth-this.$size.scrollerWidth)):f<=this.$padding&&i-f<this.characterWidth&&this.session.setScrollLeft(0)},this.getScrollTop=function(){return this.session.getScrollTop()},this.getScrollLeft=function(){return this.session.getScrollLeft()},this.getScrollTopRow=function(){return this.scrollTop/this.lineHeight},this.getScrollBottomRow=function(){return Math.max(0,Math.floor((this.scrollTop+this.$size.scrollerHeight)/this.lineHeight)-1)},this.scrollToRow=function(e){this.session.setScrollTop(e*this.lineHeight)},this.alignCursor=function(e,t){typeof e=="number"&&(e={row:e,column:0});var n=this.$cursorLayer.getPixelPosition(e),r=this.$size.scrollerHeight-this.lineHeight,i=n.top-r*(t||0);return this.session.setScrollTop(i),i},this.STEPS=8,this.$calcSteps=function(e,t){var n=0,r=this.STEPS,i=[],s=function(e,t,n){return n*(Math.pow(e-1,3)+1)+t};for(n=0;n<r;++n)i.push(s(n/this.STEPS,e,t-e));return i},this.scrollToLine=function(e,t,n,r){var i=this.$cursorLayer.getPixelPosition({row:e,column:0}),s=i.top;t&&(s-=this.$size.scrollerHeight/2);var o=this.scrollTop;this.session.setScrollTop(s),n!==!1&&this.animateScrolling(o,r)},this.animateScrolling=function(e,t){var n=this.scrollTop;if(!this.$animatedScroll)return;var r=this;if(e==n)return;if(this.$scrollAnimation){var i=this.$scrollAnimation.steps;if(i.length){e=i[0];if(e==n)return}}var s=r.$calcSteps(e,n);this.$scrollAnimation={from:e,to:n,steps:s},clearInterval(this.$timer),r.session.setScrollTop(s.shift()),r.session.$scrollTop=n,this.$timer=setInterval(function(){if(!r.session)return clearInterval(r.$timer);s.length?(r.session.setScrollTop(s.shift()),r.session.$scrollTop=n):n!=null?(r.session.$scrollTop=-1,r.session.setScrollTop(n),n=null):(r.$timer=clearInterval(r.$timer),r.$scrollAnimation=null,t&&t())},10)},this.scrollToY=function(e){this.scrollTop!==e&&(this.$loop.schedule(this.CHANGE_SCROLL),this.scrollTop=e)},this.scrollToX=function(e){this.scrollLeft!==e&&(this.scrollLeft=e),this.$loop.schedule(this.CHANGE_H_SCROLL)},this.scrollTo=function(e,t){this.session.setScrollTop(t),this.session.setScrollLeft(t)},this.scrollBy=function(e,t){t&&this.session.setScrollTop(this.session.getScrollTop()+t),e&&this.session.setScrollLeft(this.session.getScrollLeft()+e)},this.isScrollableBy=function(e,t){if(t<0&&this.session.getScrollTop()>=1-this.scrollMargin.top)return!0;if(t>0&&this.session.getScrollTop()+this.$size.scrollerHeight-this.layerConfig.maxHeight<-1+this.scrollMargin.bottom)return!0;if(e<0&&this.session.getScrollLeft()>=1-this.scrollMargin.left)return!0;if(e>0&&this.session.getScrollLeft()+this.$size.scrollerWidth-this.layerConfig.width<-1+this.scrollMargin.right)return!0},this.pixelToScreenCoordinates=function(e,t){var n;if(this.$hasCssTransforms){n={top:0,left:0};var r=this.$fontMetrics.transformCoordinates([e,t]);e=r[1]-this.gutterWidth-this.margin.left,t=r[0]}else n=this.scroller.getBoundingClientRect();var i=e+this.scrollLeft-n.left-this.$padding,s=i/this.characterWidth,o=Math.floor((t+this.scrollTop-n.top)/this.lineHeight),u=this.$blockCursor?Math.floor(s):Math.round(s);return{row:o,column:u,side:s-u>0?1:-1,offsetX:i}},this.screenToTextCoordinates=function(e,t){var n;if(this.$hasCssTransforms){n={top:0,left:0};var r=this.$fontMetrics.transformCoordinates([e,t]);e=r[1]-this.gutterWidth-this.margin.left,t=r[0]}else n=this.scroller.getBoundingClientRect();var i=e+this.scrollLeft-n.left-this.$padding,s=i/this.characterWidth,o=this.$blockCursor?Math.floor(s):Math.round(s),u=Math.floor((t+this.scrollTop-n.top)/this.lineHeight);return this.session.screenToDocumentPosition(u,Math.max(o,0),i)},this.textToScreenCoordinates=function(e,t){var n=this.scroller.getBoundingClientRect(),r=this.session.documentToScreenPosition(e,t),i=this.$padding+(this.session.$bidiHandler.isBidiRow(r.row,e)?this.session.$bidiHandler.getPosLeft(r.column):Math.round(r.column*this.characterWidth)),s=r.row*this.lineHeight;return{pageX:n.left+i-this.scrollLeft,pageY:n.top+s-this.scrollTop}},this.visualizeFocus=function(){i.addCssClass(this.container,"ace_focus")},this.visualizeBlur=function(){i.removeCssClass(this.container,"ace_focus")},this.showComposition=function(e){this.$composition=e,e.cssText||(e.cssText=this.textarea.style.cssText),e.useTextareaForIME==undefined&&(e.useTextareaForIME=this.$useTextareaForIME),this.$useTextareaForIME?(i.addCssClass(this.textarea,"ace_composition"),this.textarea.style.cssText="",this.$moveTextAreaToCursor(),this.$cursorLayer.element.style.display="none"):e.markerId=this.session.addMarker(e.markerRange,"ace_composition_marker","text")},this.setCompositionText=function(e){var t=this.session.selection.cursor;this.addToken(e,"composition_placeholder",t.row,t.column),this.$moveTextAreaToCursor()},this.hideComposition=function(){if(!this.$composition)return;this.$composition.markerId&&this.session.removeMarker(this.$composition.markerId),i.removeCssClass(this.textarea,"ace_composition"),this.textarea.style.cssText=this.$composition.cssText;var e=this.session.selection.cursor;this.removeExtraToken(e.row,e.column),this.$composition=null,this.$cursorLayer.element.style.display=""},this.addToken=function(e,t,n,r){var i=this.session;i.bgTokenizer.lines[n]=null;var s={type:t,value:e},o=i.getTokens(n);if(r==null)o.push(s);else{var u=0;for(var a=0;a<o.length;a++){var f=o[a];u+=f.value.length;if(r<=u){var l=f.value.length-(u-r),c=f.value.slice(0,l),h=f.value.slice(l);o.splice(a,1,{type:f.type,value:c},s,{type:f.type,value:h});break}}}this.updateLines(n,n)},this.removeExtraToken=function(e,t){this.updateLines(e,e)},this.setTheme=function(e,t){function o(r){if(n.$themeId!=e)return t&&t();if(!r||!r.cssClass)throw new Error("couldn't load module "+e+" or it didn't call define");r.$id&&(n.$themeId=r.$id),i.importCssString(r.cssText,r.cssClass,n.container),n.theme&&i.removeCssClass(n.container,n.theme.cssClass);var s="padding"in r?r.padding:"padding"in(n.theme||{})?4:n.$padding;n.$padding&&s!=n.$padding&&n.setPadding(s),n.$theme=r.cssClass,n.theme=r,i.addCssClass(n.container,r.cssClass),i.setCssClass(n.container,"ace_dark",r.isDark),n.$size&&(n.$size.width=0,n.$updateSizeAsync()),n._dispatchEvent("themeLoaded",{theme:r}),t&&t()}var n=this;this.$themeId=e,n._dispatchEvent("themeChange",{theme:e});if(!e||typeof e=="string"){var r=e||this.$options.theme.initialValue;s.loadModule(["theme",r],o)}else o(e)},this.getTheme=function(){return this.$themeId},this.setStyle=function(e,t){i.setCssClass(this.container,e,t!==!1)},this.unsetStyle=function(e){i.removeCssClass(this.container,e)},this.setCursorStyle=function(e){i.setStyle(this.scroller.style,"cursor",e)},this.setMouseCursor=function(e){i.setStyle(this.scroller.style,"cursor",e)},this.attachToShadowRoot=function(){i.importCssString(v,"ace_editor.css",this.container)},this.destroy=function(){this.freeze(),this.$fontMetrics.destroy(),this.$cursorLayer.destroy(),this.removeAllListeners(),this.container.textContent=""}}).call(y.prototype),s.defineOptions(y.prototype,"renderer",{animatedScroll:{initialValue:!1},showInvisibles:{set:function(e){this.$textLayer.setShowInvisibles(e)&&this.$loop.schedule(this.CHANGE_TEXT)},initialValue:!1},showPrintMargin:{set:function(){this.$updatePrintMargin()},initialValue:!0},printMarginColumn:{set:function(){this.$updatePrintMargin()},initialValue:80},printMargin:{set:function(e){typeof e=="number"&&(this.$printMarginColumn=e),this.$showPrintMargin=!!e,this.$updatePrintMargin()},get:function(){return this.$showPrintMargin&&this.$printMarginColumn}},showGutter:{set:function(e){this.$gutter.style.display=e?"block":"none",this.$loop.schedule(this.CHANGE_FULL),this.onGutterResize()},initialValue:!0},fadeFoldWidgets:{set:function(e){i.setCssClass(this.$gutter,"ace_fade-fold-widgets",e)},initialValue:!1},showFoldWidgets:{set:function(e){this.$gutterLayer.setShowFoldWidgets(e),this.$loop.schedule(this.CHANGE_GUTTER)},initialValue:!0},displayIndentGuides:{set:function(e){this.$textLayer.setDisplayIndentGuides(e)&&this.$loop.schedule(this.CHANGE_TEXT)},initialValue:!0},highlightGutterLine:{set:function(e){this.$gutterLayer.setHighlightGutterLine(e),this.$loop.schedule(this.CHANGE_GUTTER)},initialValue:!0},hScrollBarAlwaysVisible:{set:function(e){(!this.$hScrollBarAlwaysVisible||!this.$horizScroll)&&this.$loop.schedule(this.CHANGE_SCROLL)},initialValue:!1},vScrollBarAlwaysVisible:{set:function(e){(!this.$vScrollBarAlwaysVisible||!this.$vScroll)&&this.$loop.schedule(this.CHANGE_SCROLL)},initialValue:!1},fontSize:{set:function(e){typeof e=="number"&&(e+="px"),this.container.style.fontSize=e,this.updateFontSize()},initialValue:12},fontFamily:{set:function(e){this.container.style.fontFamily=e,this.updateFontSize()}},maxLines:{set:function(e){this.updateFull()}},minLines:{set:function(e){this.$minLines<562949953421311||(this.$minLines=0),this.updateFull()}},maxPixelHeight:{set:function(e){this.updateFull()},initialValue:0},scrollPastEnd:{set:function(e){e=+e||0;if(this.$scrollPastEnd==e)return;this.$scrollPastEnd=e,this.$loop.schedule(this.CHANGE_SCROLL)},initialValue:0,handlesSet:!0},fixedWidthGutter:{set:function(e){this.$gutterLayer.$fixedWidth=!!e,this.$loop.schedule(this.CHANGE_GUTTER)}},theme:{set:function(e){this.setTheme(e)},get:function(){return this.$themeId||this.theme},initialValue:"./theme/textmate",handlesSet:!0},hasCssTransforms:{},useTextareaForIME:{initialValue:!m.isMobile&&!m.isIE}}),t.VirtualRenderer=y}),ace.define("ace/worker/worker_client",["require","exports","module","ace/lib/oop","ace/lib/net","ace/lib/event_emitter","ace/config"],function(e,t,n){"use strict";function u(e){var t="importScripts('"+i.qualifyURL(e)+"');";try{return new Blob([t],{type:"application/javascript"})}catch(n){var r=window.BlobBuilder||window.WebKitBlobBuilder||window.MozBlobBuilder,s=new r;return s.append(t),s.getBlob("application/javascript")}}function a(e){if(typeof Worker=="undefined")return{postMessage:function(){},terminate:function(){}};if(o.get("loadWorkerFromBlob")){var t=u(e),n=window.URL||window.webkitURL,r=n.createObjectURL(t);return new Worker(r)}return new Worker(e)}var r=e("../lib/oop"),i=e("../lib/net"),s=e("../lib/event_emitter").EventEmitter,o=e("../config"),f=function(e){e.postMessage||(e=this.$createWorkerFromOldConfig.apply(this,arguments)),this.$worker=e,this.$sendDeltaQueue=this.$sendDeltaQueue.bind(this),this.changeListener=this.changeListener.bind(this),this.onMessage=this.onMessage.bind(this),this.callbackId=1,this.callbacks={},this.$worker.onmessage=this.onMessage};(function(){r.implement(this,s),this.$createWorkerFromOldConfig=function(t,n,r,i,s){e.nameToUrl&&!e.toUrl&&(e.toUrl=e.nameToUrl);if(o.get("packaged")||!e.toUrl)i=i||o.moduleUrl(n,"worker");else{var u=this.$normalizePath;i=i||u(e.toUrl("ace/worker/worker.js",null,"_"));var f={};t.forEach(function(t){f[t]=u(e.toUrl(t,null,"_").replace(/(\.js)?(\?.*)?$/,""))})}return this.$worker=a(i),s&&this.send("importScripts",s),this.$worker.postMessage({init:!0,tlns:f,module:n,classname:r}),this.$worker},this.onMessage=function(e){var t=e.data;switch(t.type){case"event":this._signal(t.name,{data:t.data});break;case"call":var n=this.callbacks[t.id];n&&(n(t.data),delete this.callbacks[t.id]);break;case"error":this.reportError(t.data);break;case"log":window.console&&console.log&&console.log.apply(console,t.data)}},this.reportError=function(e){window.console&&console.error&&console.error(e)},this.$normalizePath=function(e){return i.qualifyURL(e)},this.terminate=function(){this._signal("terminate",{}),this.deltaQueue=null,this.$worker.terminate(),this.$worker=null,this.$doc&&this.$doc.off("change",this.changeListener),this.$doc=null},this.send=function(e,t){this.$worker.postMessage({command:e,args:t})},this.call=function(e,t,n){if(n){var r=this.callbackId++;this.callbacks[r]=n,t.push(r)}this.send(e,t)},this.emit=function(e,t){try{t.data&&t.data.err&&(t.data.err={message:t.data.err.message,stack:t.data.err.stack,code:t.data.err.code}),this.$worker.postMessage({event:e,data:{data:t.data}})}catch(n){console.error(n.stack)}},this.attachToDocument=function(e){this.$doc&&this.terminate(),this.$doc=e,this.call("setValue",[e.getValue()]),e.on("change",this.changeListener)},this.changeListener=function(e){this.deltaQueue||(this.deltaQueue=[],setTimeout(this.$sendDeltaQueue,0)),e.action=="insert"?this.deltaQueue.push(e.start,e.lines):this.deltaQueue.push(e.start,e.end)},this.$sendDeltaQueue=function(){var e=this.deltaQueue;if(!e)return;this.deltaQueue=null,e.length>50&&e.length>this.$doc.getLength()>>1?this.call("setValue",[this.$doc.getValue()]):this.emit("change",{data:e})}}).call(f.prototype);var l=function(e,t,n){var r=null,i=!1,u=Object.create(s),a=[],l=new f({messageBuffer:a,terminate:function(){},postMessage:function(e){a.push(e);if(!r)return;i?setTimeout(c):c()}});l.setEmitSync=function(e){i=e};var c=function(){var e=a.shift();e.command?r[e.command].apply(r,e.args):e.event&&u._signal(e.event,e.data)};return u.postMessage=function(e){l.onMessage({data:e})},u.callback=function(e,t){this.postMessage({type:"call",id:t,data:e})},u.emit=function(e,t){this.postMessage({type:"event",name:e,data:t})},o.loadModule(["worker",t],function(e){r=new e[n](u);while(a.length)c()}),l};t.UIWorkerClient=l,t.WorkerClient=f,t.createWorker=a}),ace.define("ace/placeholder",["require","exports","module","ace/range","ace/lib/event_emitter","ace/lib/oop"],function(e,t,n){"use strict";var r=e("./range").Range,i=e("./lib/event_emitter").EventEmitter,s=e("./lib/oop"),o=function(e,t,n,r,i,s){var o=this;this.length=t,this.session=e,this.doc=e.getDocument(),this.mainClass=i,this.othersClass=s,this.$onUpdate=this.onUpdate.bind(this),this.doc.on("change",this.$onUpdate),this.$others=r,this.$onCursorChange=function(){setTimeout(function(){o.onCursorChange()})},this.$pos=n;var u=e.getUndoManager().$undoStack||e.getUndoManager().$undostack||{length:-1};this.$undoStackDepth=u.length,this.setup(),e.selection.on("changeCursor",this.$onCursorChange)};(function(){s.implement(this,i),this.setup=function(){var e=this,t=this.doc,n=this.session;this.selectionBefore=n.selection.toJSON(),n.selection.inMultiSelectMode&&n.selection.toSingleRange(),this.pos=t.createAnchor(this.$pos.row,this.$pos.column);var i=this.pos;i.$insertRight=!0,i.detach(),i.markerId=n.addMarker(new r(i.row,i.column,i.row,i.column+this.length),this.mainClass,null,!1),this.others=[],this.$others.forEach(function(n){var r=t.createAnchor(n.row,n.column);r.$insertRight=!0,r.detach(),e.others.push(r)}),n.setUndoSelect(!1)},this.showOtherMarkers=function(){if(this.othersActive)return;var e=this.session,t=this;this.othersActive=!0,this.others.forEach(function(n){n.markerId=e.addMarker(new r(n.row,n.column,n.row,n.column+t.length),t.othersClass,null,!1)})},this.hideOtherMarkers=function(){if(!this.othersActive)return;this.othersActive=!1;for(var e=0;e<this.others.length;e++)this.session.removeMarker(this.others[e].markerId)},this.onUpdate=function(e){if(this.$updating)return this.updateAnchors(e);var t=e;if(t.start.row!==t.end.row)return;if(t.start.row!==this.pos.row)return;this.$updating=!0;var n=e.action==="insert"?t.end.column-t.start.column:t.start.column-t.end.column,i=t.start.column>=this.pos.column&&t.start.column<=this.pos.column+this.length+1,s=t.start.column-this.pos.column;this.updateAnchors(e),i&&(this.length+=n);if(i&&!this.session.$fromUndo)if(e.action==="insert")for(var o=this.others.length-1;o>=0;o--){var u=this.others[o],a={row:u.row,column:u.column+s};this.doc.insertMergedLines(a,e.lines)}else if(e.action==="remove")for(var o=this.others.length-1;o>=0;o--){var u=this.others[o],a={row:u.row,column:u.column+s};this.doc.remove(new r(a.row,a.column,a.row,a.column-n))}this.$updating=!1,this.updateMarkers()},this.updateAnchors=function(e){this.pos.onChange(e);for(var t=this.others.length;t--;)this.others[t].onChange(e);this.updateMarkers()},this.updateMarkers=function(){if(this.$updating)return;var e=this,t=this.session,n=function(n,i){t.removeMarker(n.markerId),n.markerId=t.addMarker(new r(n.row,n.column,n.row,n.column+e.length),i,null,!1)};n(this.pos,this.mainClass);for(var i=this.others.length;i--;)n(this.others[i],this.othersClass)},this.onCursorChange=function(e){if(this.$updating||!this.session)return;var t=this.session.selection.getCursor();t.row===this.pos.row&&t.column>=this.pos.column&&t.column<=this.pos.column+this.length?(this.showOtherMarkers(),this._emit("cursorEnter",e)):(this.hideOtherMarkers(),this._emit("cursorLeave",e))},this.detach=function(){this.session.removeMarker(this.pos&&this.pos.markerId),this.hideOtherMarkers(),this.doc.off("change",this.$onUpdate),this.session.selection.off("changeCursor",this.$onCursorChange),this.session.setUndoSelect(!0),this.session=null},this.cancel=function(){if(this.$undoStackDepth===-1)return;var e=this.session.getUndoManager(),t=(e.$undoStack||e.$undostack).length-this.$undoStackDepth;for(var n=0;n<t;n++)e.undo(this.session,!0);this.selectionBefore&&this.session.selection.fromJSON(this.selectionBefore)}}).call(o.prototype),t.PlaceHolder=o}),ace.define("ace/mouse/multi_select_handler",["require","exports","module","ace/lib/event","ace/lib/useragent"],function(e,t,n){function s(e,t){return e.row==t.row&&e.column==t.column}function o(e){var t=e.domEvent,n=t.altKey,o=t.shiftKey,u=t.ctrlKey,a=e.getAccelKey(),f=e.getButton();u&&i.isMac&&(f=t.button);if(e.editor.inMultiSelectMode&&f==2){e.editor.textInput.onContextMenu(e.domEvent);return}if(!u&&!n&&!a){f===0&&e.editor.inMultiSelectMode&&e.editor.exitMultiSelectMode();return}if(f!==0)return;var l=e.editor,c=l.selection,h=l.inMultiSelectMode,p=e.getDocumentPosition(),d=c.getCursor(),v=e.inSelection()||c.isEmpty()&&s(p,d),m=e.x,g=e.y,y=function(e){m=e.clientX,g=e.clientY},b=l.session,w=l.renderer.pixelToScreenCoordinates(m,g),E=w,S;if(l.$mouseHandler.$enableJumpToDef)u&&n||a&&n?S=o?"block":"add":n&&l.$blockSelectEnabled&&(S="block");else if(a&&!n){S="add";if(!h&&o)return}else n&&l.$blockSelectEnabled&&(S="block");S&&i.isMac&&t.ctrlKey&&l.$mouseHandler.cancelContextMenu();if(S=="add"){if(!h&&v)return;if(!h){var x=c.toOrientedRange();l.addSelectionMarker(x)}var T=c.rangeList.rangeAtPoint(p);l.inVirtualSelectionMode=!0,o&&(T=null,x=c.ranges[0]||x,l.removeSelectionMarker(x)),l.once("mouseup",function(){var e=c.toOrientedRange();T&&e.isEmpty()&&s(T.cursor,e.cursor)?c.substractPoint(e.cursor):(o?c.substractPoint(x.cursor):x&&(l.removeSelectionMarker(x),c.addRange(x)),c.addRange(e)),l.inVirtualSelectionMode=!1})}else if(S=="block"){e.stop(),l.inVirtualSelectionMode=!0;var N,C=[],k=function(){var e=l.renderer.pixelToScreenCoordinates(m,g),t=b.screenToDocumentPosition(e.row,e.column,e.offsetX);if(s(E,e)&&s(t,c.lead))return;E=e,l.selection.moveToPosition(t),l.renderer.scrollCursorIntoView(),l.removeSelectionMarkers(C),C=c.rectangularRangeBlock(E,w),l.$mouseHandler.$clickSelection&&C.length==1&&C[0].isEmpty()&&(C[0]=l.$mouseHandler.$clickSelection.clone()),C.forEach(l.addSelectionMarker,l),l.updateSelectionMarkers()};h&&!a?c.toSingleRange():!h&&a&&(N=c.toOrientedRange(),l.addSelectionMarker(N)),o?w=b.documentToScreenPosition(c.lead):c.moveToPosition(p),E={row:-1,column:-1};var L=function(e){k(),clearInterval(O),l.removeSelectionMarkers(C),C.length||(C=[c.toOrientedRange()]),N&&(l.removeSelectionMarker(N),c.toSingleRange(N));for(var t=0;t<C.length;t++)c.addRange(C[t]);l.inVirtualSelectionMode=!1,l.$mouseHandler.$clickSelection=null},A=k;r.capture(l.container,y,L);var O=setInterval(function(){A()},20);return e.preventDefault()}}var r=e("../lib/event"),i=e("../lib/useragent");t.onMouseDown=o}),ace.define("ace/commands/multi_select_commands",["require","exports","module","ace/keyboard/hash_handler"],function(e,t,n){t.defaultCommands=[{name:"addCursorAbove",description:"Add cursor above",exec:function(e){e.selectMoreLines(-1)},bindKey:{win:"Ctrl-Alt-Up",mac:"Ctrl-Alt-Up"},scrollIntoView:"cursor",readOnly:!0},{name:"addCursorBelow",description:"Add cursor below",exec:function(e){e.selectMoreLines(1)},bindKey:{win:"Ctrl-Alt-Down",mac:"Ctrl-Alt-Down"},scrollIntoView:"cursor",readOnly:!0},{name:"addCursorAboveSkipCurrent",description:"Add cursor above (skip current)",exec:function(e){e.selectMoreLines(-1,!0)},bindKey:{win:"Ctrl-Alt-Shift-Up",mac:"Ctrl-Alt-Shift-Up"},scrollIntoView:"cursor",readOnly:!0},{name:"addCursorBelowSkipCurrent",description:"Add cursor below (skip current)",exec:function(e){e.selectMoreLines(1,!0)},bindKey:{win:"Ctrl-Alt-Shift-Down",mac:"Ctrl-Alt-Shift-Down"},scrollIntoView:"cursor",readOnly:!0},{name:"selectMoreBefore",description:"Select more before",exec:function(e){e.selectMore(-1)},bindKey:{win:"Ctrl-Alt-Left",mac:"Ctrl-Alt-Left"},scrollIntoView:"cursor",readOnly:!0},{name:"selectMoreAfter",description:"Select more after",exec:function(e){e.selectMore(1)},bindKey:{win:"Ctrl-Alt-Right",mac:"Ctrl-Alt-Right"},scrollIntoView:"cursor",readOnly:!0},{name:"selectNextBefore",description:"Select next before",exec:function(e){e.selectMore(-1,!0)},bindKey:{win:"Ctrl-Alt-Shift-Left",mac:"Ctrl-Alt-Shift-Left"},scrollIntoView:"cursor",readOnly:!0},{name:"selectNextAfter",description:"Select next after",exec:function(e){e.selectMore(1,!0)},bindKey:{win:"Ctrl-Alt-Shift-Right",mac:"Ctrl-Alt-Shift-Right"},scrollIntoView:"cursor",readOnly:!0},{name:"toggleSplitSelectionIntoLines",description:"Split into lines",exec:function(e){e.multiSelect.rangeCount>1?e.multiSelect.joinSelections():e.multiSelect.splitIntoLines()},bindKey:{win:"Ctrl-Alt-L",mac:"Ctrl-Alt-L"},readOnly:!0},{name:"splitSelectionIntoLines",description:"Split into lines",exec:function(e){e.multiSelect.splitIntoLines()},readOnly:!0},{name:"alignCursors",description:"Align cursors",exec:function(e){e.alignCursors()},bindKey:{win:"Ctrl-Alt-A",mac:"Ctrl-Alt-A"},scrollIntoView:"cursor"},{name:"findAll",description:"Find all",exec:function(e){e.findAll()},bindKey:{win:"Ctrl-Alt-K",mac:"Ctrl-Alt-G"},scrollIntoView:"cursor",readOnly:!0}],t.multiSelectCommands=[{name:"singleSelection",description:"Single selection",bindKey:"esc",exec:function(e){e.exitMultiSelectMode()},scrollIntoView:"cursor",readOnly:!0,isAvailable:function(e){return e&&e.inMultiSelectMode}}];var r=e("../keyboard/hash_handler").HashHandler;t.keyboardHandler=new r(t.multiSelectCommands)}),ace.define("ace/multi_select",["require","exports","module","ace/range_list","ace/range","ace/selection","ace/mouse/multi_select_handler","ace/lib/event","ace/lib/lang","ace/commands/multi_select_commands","ace/search","ace/edit_session","ace/editor","ace/config"],function(e,t,n){function h(e,t,n){return c.$options.wrap=!0,c.$options.needle=t,c.$options.backwards=n==-1,c.find(e)}function v(e,t){return e.row==t.row&&e.column==t.column}function m(e){if(e.$multiselectOnSessionChange)return;e.$onAddRange=e.$onAddRange.bind(e),e.$onRemoveRange=e.$onRemoveRange.bind(e),e.$onMultiSelect=e.$onMultiSelect.bind(e),e.$onSingleSelect=e.$onSingleSelect.bind(e),e.$multiselectOnSessionChange=t.onSessionChange.bind(e),e.$checkMultiselectChange=e.$checkMultiselectChange.bind(e),e.$multiselectOnSessionChange(e),e.on("changeSession",e.$multiselectOnSessionChange),e.on("mousedown",o),e.commands.addCommands(f.defaultCommands),g(e)}function g(e){function r(t){n&&(e.renderer.setMouseCursor(""),n=!1)}if(!e.textInput)return;var t=e.textInput.getElement(),n=!1;u.addListener(t,"keydown",function(t){var i=t.keyCode==18&&!(t.ctrlKey||t.shiftKey||t.metaKey);e.$blockSelectEnabled&&i?n||(e.renderer.setMouseCursor("crosshair"),n=!0):n&&r()},e),u.addListener(t,"keyup",r,e),u.addListener(t,"blur",r,e)}var r=e("./range_list").RangeList,i=e("./range").Range,s=e("./selection").Selection,o=e("./mouse/multi_select_handler").onMouseDown,u=e("./lib/event"),a=e("./lib/lang"),f=e("./commands/multi_select_commands");t.commands=f.defaultCommands.concat(f.multiSelectCommands);var l=e("./search").Search,c=new l,p=e("./edit_session").EditSession;(function(){this.getSelectionMarkers=function(){return this.$selectionMarkers}}).call(p.prototype),function(){this.ranges=null,this.rangeList=null,this.addRange=function(e,t){if(!e)return;if(!this.inMultiSelectMode&&this.rangeCount===0){var n=this.toOrientedRange();this.rangeList.add(n),this.rangeList.add(e);if(this.rangeList.ranges.length!=2)return this.rangeList.removeAll(),t||this.fromOrientedRange(e);this.rangeList.removeAll(),this.rangeList.add(n),this.$onAddRange(n)}e.cursor||(e.cursor=e.end);var r=this.rangeList.add(e);return this.$onAddRange(e),r.length&&this.$onRemoveRange(r),this.rangeCount>1&&!this.inMultiSelectMode&&(this._signal("multiSelect"),this.inMultiSelectMode=!0,this.session.$undoSelect=!1,this.rangeList.attach(this.session)),t||this.fromOrientedRange(e)},this.toSingleRange=function(e){e=e||this.ranges[0];var t=this.rangeList.removeAll();t.length&&this.$onRemoveRange(t),e&&this.fromOrientedRange(e)},this.substractPoint=function(e){var t=this.rangeList.substractPoint(e);if(t)return this.$onRemoveRange(t),t[0]},this.mergeOverlappingRanges=function(){var e=this.rangeList.merge();e.length&&this.$onRemoveRange(e)},this.$onAddRange=function(e){this.rangeCount=this.rangeList.ranges.length,this.ranges.unshift(e),this._signal("addRange",{range:e})},this.$onRemoveRange=function(e){this.rangeCount=this.rangeList.ranges.length;if(this.rangeCount==1&&this.inMultiSelectMode){var t=this.rangeList.ranges.pop();e.push(t),this.rangeCount=0}for(var n=e.length;n--;){var r=this.ranges.indexOf(e[n]);this.ranges.splice(r,1)}this._signal("removeRange",{ranges:e}),this.rangeCount===0&&this.inMultiSelectMode&&(this.inMultiSelectMode=!1,this._signal("singleSelect"),this.session.$undoSelect=!0,this.rangeList.detach(this.session)),t=t||this.ranges[0],t&&!t.isEqual(this.getRange())&&this.fromOrientedRange(t)},this.$initRangeList=function(){if(this.rangeList)return;this.rangeList=new r,this.ranges=[],this.rangeCount=0},this.getAllRanges=function(){return this.rangeCount?this.rangeList.ranges.concat():[this.getRange()]},this.splitIntoLines=function(){var e=this.ranges.length?this.ranges:[this.getRange()],t=[];for(var n=0;n<e.length;n++){var r=e[n],s=r.start.row,o=r.end.row;if(s===o)t.push(r.clone());else{t.push(new i(s,r.start.column,s,this.session.getLine(s).length));while(++s<o)t.push(this.getLineRange(s,!0));t.push(new i(o,0,o,r.end.column))}n==0&&!this.isBackwards()&&(t=t.reverse())}this.toSingleRange();for(var n=t.length;n--;)this.addRange(t[n])},this.joinSelections=function(){var e=this.rangeList.ranges,t=e[e.length-1],n=i.fromPoints(e[0].start,t.end);this.toSingleRange(),this.setSelectionRange(n,t.cursor==t.start)},this.toggleBlockSelection=function(){if(this.rangeCount>1){var e=this.rangeList.ranges,t=e[e.length-1],n=i.fromPoints(e[0].start,t.end);this.toSingleRange(),this.setSelectionRange(n,t.cursor==t.start)}else{var r=this.session.documentToScreenPosition(this.cursor),s=this.session.documentToScreenPosition(this.anchor),o=this.rectangularRangeBlock(r,s);o.forEach(this.addRange,this)}},this.rectangularRangeBlock=function(e,t,n){var r=[],s=e.column<t.column;if(s)var o=e.column,u=t.column,a=e.offsetX,f=t.offsetX;else var o=t.column,u=e.column,a=t.offsetX,f=e.offsetX;var l=e.row<t.row;if(l)var c=e.row,h=t.row;else var c=t.row,h=e.row;o<0&&(o=0),c<0&&(c=0),c==h&&(n=!0);var p;for(var d=c;d<=h;d++){var m=i.fromPoints(this.session.screenToDocumentPosition(d,o,a),this.session.screenToDocumentPosition(d,u,f));if(m.isEmpty()){if(p&&v(m.end,p))break;p=m.end}m.cursor=s?m.start:m.end,r.push(m)}l&&r.reverse();if(!n){var g=r.length-1;while(r[g].isEmpty()&&g>0)g--;if(g>0){var y=0;while(r[y].isEmpty())y++}for(var b=g;b>=y;b--)r[b].isEmpty()&&r.splice(b,1)}return r}}.call(s.prototype);var d=e("./editor").Editor;(function(){this.updateSelectionMarkers=function(){this.renderer.updateCursor(),this.renderer.updateBackMarkers()},this.addSelectionMarker=function(e){e.cursor||(e.cursor=e.end);var t=this.getSelectionStyle();return e.marker=this.session.addMarker(e,"ace_selection",t),this.session.$selectionMarkers.push(e),this.session.selectionMarkerCount=this.session.$selectionMarkers.length,e},this.removeSelectionMarker=function(e){if(!e.marker)return;this.session.removeMarker(e.marker);var t=this.session.$selectionMarkers.indexOf(e);t!=-1&&this.session.$selectionMarkers.splice(t,1),this.session.selectionMarkerCount=this.session.$selectionMarkers.length},this.removeSelectionMarkers=function(e){var t=this.session.$selectionMarkers;for(var n=e.length;n--;){var r=e[n];if(!r.marker)continue;this.session.removeMarker(r.marker);var i=t.indexOf(r);i!=-1&&t.splice(i,1)}this.session.selectionMarkerCount=t.length},this.$onAddRange=function(e){this.addSelectionMarker(e.range),this.renderer.updateCursor(),this.renderer.updateBackMarkers()},this.$onRemoveRange=function(e){this.removeSelectionMarkers(e.ranges),this.renderer.updateCursor(),this.renderer.updateBackMarkers()},this.$onMultiSelect=function(e){if(this.inMultiSelectMode)return;this.inMultiSelectMode=!0,this.setStyle("ace_multiselect"),this.keyBinding.addKeyboardHandler(f.keyboardHandler),this.commands.setDefaultHandler("exec",this.$onMultiSelectExec),this.renderer.updateCursor(),this.renderer.updateBackMarkers()},this.$onSingleSelect=function(e){if(this.session.multiSelect.inVirtualMode)return;this.inMultiSelectMode=!1,this.unsetStyle("ace_multiselect"),this.keyBinding.removeKeyboardHandler(f.keyboardHandler),this.commands.removeDefaultHandler("exec",this.$onMultiSelectExec),this.renderer.updateCursor(),this.renderer.updateBackMarkers(),this._emit("changeSelection")},this.$onMultiSelectExec=function(e){var t=e.command,n=e.editor;if(!n.multiSelect)return;if(!t.multiSelectAction){var r=t.exec(n,e.args||{});n.multiSelect.addRange(n.multiSelect.toOrientedRange()),n.multiSelect.mergeOverlappingRanges()}else t.multiSelectAction=="forEach"?r=n.forEachSelection(t,e.args):t.multiSelectAction=="forEachLine"?r=n.forEachSelection(t,e.args,!0):t.multiSelectAction=="single"?(n.exitMultiSelectMode(),r=t.exec(n,e.args||{})):r=t.multiSelectAction(n,e.args||{});return r},this.forEachSelection=function(e,t,n){if(this.inVirtualSelectionMode)return;var r=n&&n.keepOrder,i=n==1||n&&n.$byLines,o=this.session,u=this.selection,a=u.rangeList,f=(r?u:a).ranges,l;if(!f.length)return e.exec?e.exec(this,t||{}):e(this,t||{});var c=u._eventRegistry;u._eventRegistry={};var h=new s(o);this.inVirtualSelectionMode=!0;for(var p=f.length;p--;){if(i)while(p>0&&f[p].start.row==f[p-1].end.row)p--;h.fromOrientedRange(f[p]),h.index=p,this.selection=o.selection=h;var d=e.exec?e.exec(this,t||{}):e(this,t||{});!l&&d!==undefined&&(l=d),h.toOrientedRange(f[p])}h.detach(),this.selection=o.selection=u,this.inVirtualSelectionMode=!1,u._eventRegistry=c,u.mergeOverlappingRanges(),u.ranges[0]&&u.fromOrientedRange(u.ranges[0]);var v=this.renderer.$scrollAnimation;return this.onCursorChange(),this.onSelectionChange(),v&&v.from==v.to&&this.renderer.animateScrolling(v.from),l},this.exitMultiSelectMode=function(){if(!this.inMultiSelectMode||this.inVirtualSelectionMode)return;this.multiSelect.toSingleRange()},this.getSelectedText=function(){var e="";if(this.inMultiSelectMode&&!this.inVirtualSelectionMode){var t=this.multiSelect.rangeList.ranges,n=[];for(var r=0;r<t.length;r++)n.push(this.session.getTextRange(t[r]));var i=this.session.getDocument().getNewLineCharacter();e=n.join(i),e.length==(n.length-1)*i.length&&(e="")}else this.selection.isEmpty()||(e=this.session.getTextRange(this.getSelectionRange()));return e},this.$checkMultiselectChange=function(e,t){if(this.inMultiSelectMode&&!this.inVirtualSelectionMode){var n=this.multiSelect.ranges[0];if(this.multiSelect.isEmpty()&&t==this.multiSelect.anchor)return;var r=t==this.multiSelect.anchor?n.cursor==n.start?n.end:n.start:n.cursor;r.row!=t.row||this.session.$clipPositionToDocument(r.row,r.column).column!=t.column?this.multiSelect.toSingleRange(this.multiSelect.toOrientedRange()):this.multiSelect.mergeOverlappingRanges()}},this.findAll=function(e,t,n){t=t||{},t.needle=e||t.needle;if(t.needle==undefined){var r=this.selection.isEmpty()?this.selection.getWordRange():this.selection.getRange();t.needle=this.session.getTextRange(r)}this.$search.set(t);var i=this.$search.findAll(this.session);if(!i.length)return 0;var s=this.multiSelect;n||s.toSingleRange(i[0]);for(var o=i.length;o--;)s.addRange(i[o],!0);return r&&s.rangeList.rangeAtPoint(r.start)&&s.addRange(r,!0),i.length},this.selectMoreLines=function(e,t){var n=this.selection.toOrientedRange(),r=n.cursor==n.end,s=this.session.documentToScreenPosition(n.cursor);this.selection.$desiredColumn&&(s.column=this.selection.$desiredColumn);var o=this.session.screenToDocumentPosition(s.row+e,s.column);if(!n.isEmpty())var u=this.session.documentToScreenPosition(r?n.end:n.start),a=this.session.screenToDocumentPosition(u.row+e,u.column);else var a=o;if(r){var f=i.fromPoints(o,a);f.cursor=f.start}else{var f=i.fromPoints(a,o);f.cursor=f.end}f.desiredColumn=s.column;if(!this.selection.inMultiSelectMode)this.selection.addRange(n);else if(t)var l=n.cursor;this.selection.addRange(f),l&&this.selection.substractPoint(l)},this.transposeSelections=function(e){var t=this.session,n=t.multiSelect,r=n.ranges;for(var i=r.length;i--;){var s=r[i];if(s.isEmpty()){var o=t.getWordRange(s.start.row,s.start.column);s.start.row=o.start.row,s.start.column=o.start.column,s.end.row=o.end.row,s.end.column=o.end.column}}n.mergeOverlappingRanges();var u=[];for(var i=r.length;i--;){var s=r[i];u.unshift(t.getTextRange(s))}e<0?u.unshift(u.pop()):u.push(u.shift());for(var i=r.length;i--;){var s=r[i],o=s.clone();t.replace(s,u[i]),s.start.row=o.start.row,s.start.column=o.start.column}n.fromOrientedRange(n.ranges[0])},this.selectMore=function(e,t,n){var r=this.session,i=r.multiSelect,s=i.toOrientedRange();if(s.isEmpty()){s=r.getWordRange(s.start.row,s.start.column),s.cursor=e==-1?s.start:s.end,this.multiSelect.addRange(s);if(n)return}var o=r.getTextRange(s),u=h(r,o,e);u&&(u.cursor=e==-1?u.start:u.end,this.session.unfold(u),this.multiSelect.addRange(u),this.renderer.scrollCursorIntoView(null,.5)),t&&this.multiSelect.substractPoint(s.cursor)},this.alignCursors=function(){var e=this.session,t=e.multiSelect,n=t.ranges,r=-1,s=n.filter(function(e){if(e.cursor.row==r)return!0;r=e.cursor.row});if(!n.length||s.length==n.length-1){var o=this.selection.getRange(),u=o.start.row,f=o.end.row,l=u==f;if(l){var c=this.session.getLength(),h;do h=this.session.getLine(f);while(/[=:]/.test(h)&&++f<c);do h=this.session.getLine(u);while(/[=:]/.test(h)&&--u>0);u<0&&(u=0),f>=c&&(f=c-1)}var p=this.session.removeFullLines(u,f);p=this.$reAlignText(p,l),this.session.insert({row:u,column:0},p.join("\n")+"\n"),l||(o.start.column=0,o.end.column=p[p.length-1].length),this.selection.setRange(o)}else{s.forEach(function(e){t.substractPoint(e.cursor)});var d=0,v=Infinity,m=n.map(function(t){var n=t.cursor,r=e.getLine(n.row),i=r.substr(n.column).search(/\S/g);return i==-1&&(i=0),n.column>d&&(d=n.column),i<v&&(v=i),i});n.forEach(function(t,n){var r=t.cursor,s=d-r.column,o=m[n]-v;s>o?e.insert(r,a.stringRepeat(" ",s-o)):e.remove(new i(r.row,r.column,r.row,r.column-s+o)),t.start.column=t.end.column=d,t.start.row=t.end.row=r.row,t.cursor=t.end}),t.fromOrientedRange(n[0]),this.renderer.updateCursor(),this.renderer.updateBackMarkers()}},this.$reAlignText=function(e,t){function u(e){return a.stringRepeat(" ",e)}function f(e){return e[2]?u(i)+e[2]+u(s-e[2].length+o)+e[4].replace(/^([=:])\s+/,"$1 "):e[0]}function l(e){return e[2]?u(i+s-e[2].length)+e[2]+u(o)+e[4].replace(/^([=:])\s+/,"$1 "):e[0]}function c(e){return e[2]?u(i)+e[2]+u(o)+e[4].replace(/^([=:])\s+/,"$1 "):e[0]}var n=!0,r=!0,i,s,o;return e.map(function(e){var t=e.match(/(\s*)(.*?)(\s*)([=:].*)/);return t?i==null?(i=t[1].length,s=t[2].length,o=t[3].length,t):(i+s+o!=t[1].length+t[2].length+t[3].length&&(r=!1),i!=t[1].length&&(n=!1),i>t[1].length&&(i=t[1].length),s<t[2].length&&(s=t[2].length),o>t[3].length&&(o=t[3].length),t):[e]}).map(t?f:n?r?l:f:c)}}).call(d.prototype),t.onSessionChange=function(e){var t=e.session;t&&!t.multiSelect&&(t.$selectionMarkers=[],t.selection.$initRangeList(),t.multiSelect=t.selection),this.multiSelect=t&&t.multiSelect;var n=e.oldSession;n&&(n.multiSelect.off("addRange",this.$onAddRange),n.multiSelect.off("removeRange",this.$onRemoveRange),n.multiSelect.off("multiSelect",this.$onMultiSelect),n.multiSelect.off("singleSelect",this.$onSingleSelect),n.multiSelect.lead.off("change",this.$checkMultiselectChange),n.multiSelect.anchor.off("change",this.$checkMultiselectChange)),t&&(t.multiSelect.on("addRange",this.$onAddRange),t.multiSelect.on("removeRange",this.$onRemoveRange),t.multiSelect.on("multiSelect",this.$onMultiSelect),t.multiSelect.on("singleSelect",this.$onSingleSelect),t.multiSelect.lead.on("change",this.$checkMultiselectChange),t.multiSelect.anchor.on("change",this.$checkMultiselectChange)),t&&this.inMultiSelectMode!=t.selection.inMultiSelectMode&&(t.selection.inMultiSelectMode?this.$onMultiSelect():this.$onSingleSelect())},t.MultiSelect=m,e("./config").defineOptions(d.prototype,"editor",{enableMultiselect:{set:function(e){m(this),e?(this.on("changeSession",this.$multiselectOnSessionChange),this.on("mousedown",o)):(this.off("changeSession",this.$multiselectOnSessionChange),this.off("mousedown",o))},value:!0},enableBlockSelect:{set:function(e){this.$blockSelectEnabled=e},value:!0}})}),ace.define("ace/mode/folding/fold_mode",["require","exports","module","ace/range"],function(e,t,n){"use strict";var r=e("../../range").Range,i=t.FoldMode=function(){};(function(){this.foldingStartMarker=null,this.foldingStopMarker=null,this.getFoldWidget=function(e,t,n){var r=e.getLine(n);return this.foldingStartMarker.test(r)?"start":t=="markbeginend"&&this.foldingStopMarker&&this.foldingStopMarker.test(r)?"end":""},this.getFoldWidgetRange=function(e,t,n){return null},this.indentationBlock=function(e,t,n){var i=/\S/,s=e.getLine(t),o=s.search(i);if(o==-1)return;var u=n||s.length,a=e.getLength(),f=t,l=t;while(++t<a){var c=e.getLine(t).search(i);if(c==-1)continue;if(c<=o){var h=e.getTokenAt(t,0);if(!h||h.type!=="string")break}l=t}if(l>f){var p=e.getLine(l).length;return new r(f,u,l,p)}},this.openingBracketBlock=function(e,t,n,i,s){var o={row:n,column:i+1},u=e.$findClosingBracket(t,o,s);if(!u)return;var a=e.foldWidgets[u.row];return a==null&&(a=e.getFoldWidget(u.row)),a=="start"&&u.row>o.row&&(u.row--,u.column=e.getLine(u.row).length),r.fromPoints(o,u)},this.closingBracketBlock=function(e,t,n,i,s){var o={row:n,column:i},u=e.$findOpeningBracket(t,o);if(!u)return;return u.column++,o.column--,r.fromPoints(u,o)}}).call(i.prototype)}),ace.define("ace/theme/textmate",["require","exports","module","ace/lib/dom"],function(e,t,n){"use strict";t.isDark=!1,t.cssClass="ace-tm",t.cssText='.ace-tm .ace_gutter {background: #f0f0f0;color: #333;}.ace-tm .ace_print-margin {width: 1px;background: #e8e8e8;}.ace-tm .ace_fold {background-color: #6B72E6;}.ace-tm {background-color: #FFFFFF;color: black;}.ace-tm .ace_cursor {color: black;}.ace-tm .ace_invisible {color: rgb(191, 191, 191);}.ace-tm .ace_storage,.ace-tm .ace_keyword {color: blue;}.ace-tm .ace_constant {color: rgb(197, 6, 11);}.ace-tm .ace_constant.ace_buildin {color: rgb(88, 72, 246);}.ace-tm .ace_constant.ace_language {color: rgb(88, 92, 246);}.ace-tm .ace_constant.ace_library {color: rgb(6, 150, 14);}.ace-tm .ace_invalid {background-color: rgba(255, 0, 0, 0.1);color: red;}.ace-tm .ace_support.ace_function {color: rgb(60, 76, 114);}.ace-tm .ace_support.ace_constant {color: rgb(6, 150, 14);}.ace-tm .ace_support.ace_type,.ace-tm .ace_support.ace_class {color: rgb(109, 121, 222);}.ace-tm .ace_keyword.ace_operator {color: rgb(104, 118, 135);}.ace-tm .ace_string {color: rgb(3, 106, 7);}.ace-tm .ace_comment {color: rgb(76, 136, 107);}.ace-tm .ace_comment.ace_doc {color: rgb(0, 102, 255);}.ace-tm .ace_comment.ace_doc.ace_tag {color: rgb(128, 159, 191);}.ace-tm .ace_constant.ace_numeric {color: rgb(0, 0, 205);}.ace-tm .ace_variable {color: rgb(49, 132, 149);}.ace-tm .ace_xml-pe {color: rgb(104, 104, 91);}.ace-tm .ace_entity.ace_name.ace_function {color: #0000A2;}.ace-tm .ace_heading {color: rgb(12, 7, 255);}.ace-tm .ace_list {color:rgb(185, 6, 144);}.ace-tm .ace_meta.ace_tag {color:rgb(0, 22, 142);}.ace-tm .ace_string.ace_regex {color: rgb(255, 0, 0)}.ace-tm .ace_marker-layer .ace_selection {background: rgb(181, 213, 255);}.ace-tm.ace_multiselect .ace_selection.ace_start {box-shadow: 0 0 3px 0px white;}.ace-tm .ace_marker-layer .ace_step {background: rgb(252, 255, 0);}.ace-tm .ace_marker-layer .ace_stack {background: rgb(164, 229, 101);}.ace-tm .ace_marker-layer .ace_bracket {margin: -1px 0 0 -1px;border: 1px solid rgb(192, 192, 192);}.ace-tm .ace_marker-layer .ace_active-line {background: rgba(0, 0, 0, 0.07);}.ace-tm .ace_gutter-active-line {background-color : #dcdcdc;}.ace-tm .ace_marker-layer .ace_selected-word {background: rgb(250, 250, 255);border: 1px solid rgb(200, 200, 250);}.ace-tm .ace_indent-guide {background: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAACCAYAAACZgbYnAAAAE0lEQVQImWP4////f4bLly//BwAmVgd1/w11/gAAAABJRU5ErkJggg==") right repeat-y;}',t.$id="ace/theme/textmate";var r=e("../lib/dom");r.importCssString(t.cssText,t.cssClass)}),ace.define("ace/line_widgets",["require","exports","module","ace/lib/dom"],function(e,t,n){"use strict";function i(e){this.session=e,this.session.widgetManager=this,this.session.getRowLength=this.getRowLength,this.session.$getWidgetScreenLength=this.$getWidgetScreenLength,this.updateOnChange=this.updateOnChange.bind(this),this.renderWidgets=this.renderWidgets.bind(this),this.measureWidgets=this.measureWidgets.bind(this),this.session._changedWidgets=[],this.$onChangeEditor=this.$onChangeEditor.bind(this),this.session.on("change",this.updateOnChange),this.session.on("changeFold",this.updateOnFold),this.session.on("changeEditor",this.$onChangeEditor)}var r=e("./lib/dom");(function(){this.getRowLength=function(e){var t;return this.lineWidgets?t=this.lineWidgets[e]&&this.lineWidgets[e].rowCount||0:t=0,!this.$useWrapMode||!this.$wrapData[e]?1+t:this.$wrapData[e].length+1+t},this.$getWidgetScreenLength=function(){var e=0;return this.lineWidgets.forEach(function(t){t&&t.rowCount&&!t.hidden&&(e+=t.rowCount)}),e},this.$onChangeEditor=function(e){this.attach(e.editor)},this.attach=function(e){e&&e.widgetManager&&e.widgetManager!=this&&e.widgetManager.detach();if(this.editor==e)return;this.detach(),this.editor=e,e&&(e.widgetManager=this,e.renderer.on("beforeRender",this.measureWidgets),e.renderer.on("afterRender",this.renderWidgets))},this.detach=function(e){var t=this.editor;if(!t)return;this.editor=null,t.widgetManager=null,t.renderer.off("beforeRender",this.measureWidgets),t.renderer.off("afterRender",this.renderWidgets);var n=this.session.lineWidgets;n&&n.forEach(function(e){e&&e.el&&e.el.parentNode&&(e._inDocument=!1,e.el.parentNode.removeChild(e.el))})},this.updateOnFold=function(e,t){var n=t.lineWidgets;if(!n||!e.action)return;var r=e.data,i=r.start.row,s=r.end.row,o=e.action=="add";for(var u=i+1;u<s;u++)n[u]&&(n[u].hidden=o);n[s]&&(o?n[i]?n[s].hidden=o:n[i]=n[s]:(n[i]==n[s]&&(n[i]=undefined),n[s].hidden=o))},this.updateOnChange=function(e){var t=this.session.lineWidgets;if(!t)return;var n=e.start.row,r=e.end.row-n;if(r!==0)if(e.action=="remove"){var i=t.splice(n+1,r);!t[n]&&i[i.length-1]&&(t[n]=i.pop()),i.forEach(function(e){e&&this.removeLineWidget(e)},this),this.$updateRows()}else{var s=new Array(r);t[n]&&t[n].column!=null&&e.start.column>t[n].column&&n++,s.unshift(n,0),t.splice.apply(t,s),this.$updateRows()}},this.$updateRows=function(){var e=this.session.lineWidgets;if(!e)return;var t=!0;e.forEach(function(e,n){if(e){t=!1,e.row=n;while(e.$oldWidget)e.$oldWidget.row=n,e=e.$oldWidget}}),t&&(this.session.lineWidgets=null)},this.$registerLineWidget=function(e){this.session.lineWidgets||(this.session.lineWidgets=new Array(this.session.getLength()));var t=this.session.lineWidgets[e.row];return t&&(e.$oldWidget=t,t.el&&t.el.parentNode&&(t.el.parentNode.removeChild(t.el),t._inDocument=!1)),this.session.lineWidgets[e.row]=e,e},this.addLineWidget=function(e){this.$registerLineWidget(e),e.session=this.session;if(!this.editor)return e;var t=this.editor.renderer;e.html&&!e.el&&(e.el=r.createElement("div"),e.el.innerHTML=e.html),e.el&&(r.addCssClass(e.el,"ace_lineWidgetContainer"),e.el.style.position="absolute",e.el.style.zIndex=5,t.container.appendChild(e.el),e._inDocument=!0,e.coverGutter||(e.el.style.zIndex=3),e.pixelHeight==null&&(e.pixelHeight=e.el.offsetHeight)),e.rowCount==null&&(e.rowCount=e.pixelHeight/t.layerConfig.lineHeight);var n=this.session.getFoldAt(e.row,0);e.$fold=n;if(n){var i=this.session.lineWidgets;e.row==n.end.row&&!i[n.start.row]?i[n.start.row]=e:e.hidden=!0}return this.session._emit("changeFold",{data:{start:{row:e.row}}}),this.$updateRows(),this.renderWidgets(null,t),this.onWidgetChanged(e),e},this.removeLineWidget=function(e){e._inDocument=!1,e.session=null,e.el&&e.el.parentNode&&e.el.parentNode.removeChild(e.el);if(e.editor&&e.editor.destroy)try{e.editor.destroy()}catch(t){}if(this.session.lineWidgets){var n=this.session.lineWidgets[e.row];if(n==e)this.session.lineWidgets[e.row]=e.$oldWidget,e.$oldWidget&&this.onWidgetChanged(e.$oldWidget);else while(n){if(n.$oldWidget==e){n.$oldWidget=e.$oldWidget;break}n=n.$oldWidget}}this.session._emit("changeFold",{data:{start:{row:e.row}}}),this.$updateRows()},this.getWidgetsAtRow=function(e){var t=this.session.lineWidgets,n=t&&t[e],r=[];while(n)r.push(n),n=n.$oldWidget;return r},this.onWidgetChanged=function(e){this.session._changedWidgets.push(e),this.editor&&this.editor.renderer.updateFull()},this.measureWidgets=function(e,t){var n=this.session._changedWidgets,r=t.layerConfig;if(!n||!n.length)return;var i=Infinity;for(var s=0;s<n.length;s++){var o=n[s];if(!o||!o.el)continue;if(o.session!=this.session)continue;if(!o._inDocument){if(this.session.lineWidgets[o.row]!=o)continue;o._inDocument=!0,t.container.appendChild(o.el)}o.h=o.el.offsetHeight,o.fixedWidth||(o.w=o.el.offsetWidth,o.screenWidth=Math.ceil(o.w/r.characterWidth));var u=o.h/r.lineHeight;o.coverLine&&(u-=this.session.getRowLineCount(o.row),u<0&&(u=0)),o.rowCount!=u&&(o.rowCount=u,o.row<i&&(i=o.row))}i!=Infinity&&(this.session._emit("changeFold",{data:{start:{row:i}}}),this.session.lineWidgetWidth=null),this.session._changedWidgets=[]},this.renderWidgets=function(e,t){var n=t.layerConfig,r=this.session.lineWidgets;if(!r)return;var i=Math.min(this.firstRow,n.firstRow),s=Math.max(this.lastRow,n.lastRow,r.length);while(i>0&&!r[i])i--;this.firstRow=n.firstRow,this.lastRow=n.lastRow,t.$cursorLayer.config=n;for(var o=i;o<=s;o++){var u=r[o];if(!u||!u.el)continue;if(u.hidden){u.el.style.top=-100-(u.pixelHeight||0)+"px";continue}u._inDocument||(u._inDocument=!0,t.container.appendChild(u.el));var a=t.$cursorLayer.getPixelPosition({row:o,column:0},!0).top;u.coverLine||(a+=n.lineHeight*this.session.getRowLineCount(u.row)),u.el.style.top=a-n.offset+"px";var f=u.coverGutter?0:t.gutterWidth;u.fixedWidth||(f-=t.scrollLeft),u.el.style.left=f+"px",u.fullWidth&&u.screenWidth&&(u.el.style.minWidth=n.width+2*n.padding+"px"),u.fixedWidth?u.el.style.right=t.scrollBar.getWidth()+"px":u.el.style.right=""}}}).call(i.prototype),t.LineWidgets=i}),ace.define("ace/ext/error_marker",["require","exports","module","ace/line_widgets","ace/lib/dom","ace/range"],function(e,t,n){"use strict";function o(e,t,n){var r=0,i=e.length-1;while(r<=i){var s=r+i>>1,o=n(t,e[s]);if(o>0)r=s+1;else{if(!(o<0))return s;i=s-1}}return-(r+1)}function u(e,t,n){var r=e.getAnnotations().sort(s.comparePoints);if(!r.length)return;var i=o(r,{row:t,column:-1},s.comparePoints);i<0&&(i=-i-1),i>=r.length?i=n>0?0:r.length-1:i===0&&n<0&&(i=r.length-1);var u=r[i];if(!u||!n)return;if(u.row===t){do u=r[i+=n];while(u&&u.row===t);if(!u)return r.slice()}var a=[];t=u.row;do a[n<0?"unshift":"push"](u),u=r[i+=n];while(u&&u.row==t);return a.length&&a}var r=e("../line_widgets").LineWidgets,i=e("../lib/dom"),s=e("../range").Range;t.showErrorMarker=function(e,t){var n=e.session;n.widgetManager||(n.widgetManager=new r(n),n.widgetManager.attach(e));var s=e.getCursorPosition(),o=s.row,a=n.widgetManager.getWidgetsAtRow(o).filter(function(e){return e.type=="errorMarker"})[0];a?a.destroy():o-=t;var f=u(n,o,t),l;if(f){var c=f[0];s.column=(c.pos&&typeof c.column!="number"?c.pos.sc:c.column)||0,s.row=c.row,l=e.renderer.$gutterLayer.$annotations[s.row]}else{if(a)return;l={text:["Looks good!"],className:"ace_ok"}}e.session.unfold(s.row),e.selection.moveToPosition(s);var h={row:s.row,fixedWidth:!0,coverGutter:!0,el:i.createElement("div"),type:"errorMarker"},p=h.el.appendChild(i.createElement("div")),d=h.el.appendChild(i.createElement("div"));d.className="error_widget_arrow "+l.className;var v=e.renderer.$cursorLayer.getPixelPosition(s).left;d.style.left=v+e.renderer.gutterWidth-5+"px",h.el.className="error_widget_wrapper",p.className="error_widget "+l.className,p.innerHTML=l.text.join("<br>"),p.appendChild(i.createElement("div"));var m=function(e,t,n){if(t===0&&(n==="esc"||n==="return"))return h.destroy(),{command:"null"}};h.destroy=function(){if(e.$mouseHandler.isMousePressed)return;e.keyBinding.removeKeyboardHandler(m),n.widgetManager.removeLineWidget(h),e.off("changeSelection",h.destroy),e.off("changeSession",h.destroy),e.off("mouseup",h.destroy),e.off("change",h.destroy)},e.keyBinding.addKeyboardHandler(m),e.on("changeSelection",h.destroy),e.on("changeSession",h.destroy),e.on("mouseup",h.destroy),e.on("change",h.destroy),e.session.widgetManager.addLineWidget(h),h.el.onmousedown=e.focus.bind(e),e.renderer.scrollCursorIntoView(null,.5,{bottom:h.el.offsetHeight})},i.importCssString(" .error_widget_wrapper { background: inherit; color: inherit; border:none } .error_widget { border-top: solid 2px; border-bottom: solid 2px; margin: 5px 0; padding: 10px 40px; white-space: pre-wrap; } .error_widget.ace_error, .error_widget_arrow.ace_error{ border-color: #ff5a5a } .error_widget.ace_warning, .error_widget_arrow.ace_warning{ border-color: #F1D817 } .error_widget.ace_info, .error_widget_arrow.ace_info{ border-color: #5a5a5a } .error_widget.ace_ok, .error_widget_arrow.ace_ok{ border-color: #5aaa5a } .error_widget_arrow { position: absolute; border: solid 5px; border-top-color: transparent!important; border-right-color: transparent!important; border-left-color: transparent!important; top: -5px; }","")}),ace.define("ace/ace",["require","exports","module","ace/lib/fixoldbrowsers","ace/lib/dom","ace/lib/event","ace/range","ace/editor","ace/edit_session","ace/undomanager","ace/virtual_renderer","ace/worker/worker_client","ace/keyboard/hash_handler","ace/placeholder","ace/multi_select","ace/mode/folding/fold_mode","ace/theme/textmate","ace/ext/error_marker","ace/config"],function(e,t,n){"use strict";e("./lib/fixoldbrowsers");var r=e("./lib/dom"),i=e("./lib/event"),s=e("./range").Range,o=e("./editor").Editor,u=e("./edit_session").EditSession,a=e("./undomanager").UndoManager,f=e("./virtual_renderer").VirtualRenderer;e("./worker/worker_client"),e("./keyboard/hash_handler"),e("./placeholder"),e("./multi_select"),e("./mode/folding/fold_mode"),e("./theme/textmate"),e("./ext/error_marker"),t.config=e("./config"),t.require=e,typeof define=="function"&&(t.define=define),t.edit=function(e,n){if(typeof e=="string"){var s=e;e=document.getElementById(s);if(!e)throw new Error("ace.edit can't find div #"+s)}if(e&&e.env&&e.env.editor instanceof o)return e.env.editor;var u="";if(e&&/input|textarea/i.test(e.tagName)){var a=e;u=a.value,e=r.createElement("pre"),a.parentNode.replaceChild(e,a)}else e&&(u=e.textContent,e.innerHTML="");var l=t.createEditSession(u),c=new o(new f(e),l,n),h={document:l,editor:c,onResize:c.resize.bind(c,null)};return a&&(h.textarea=a),i.addListener(window,"resize",h.onResize),c.on("destroy",function(){i.removeListener(window,"resize",h.onResize),h.editor.container.env=null}),c.container.env=c.env=h,c},t.createEditSession=function(e,t){var n=new u(e,t);return n.setUndoManager(new a),n},t.Range=s,t.Editor=o,t.EditSession=u,t.UndoManager=a,t.VirtualRenderer=f,t.version=t.config.version}); (function() { + ace.require(["ace/ace"], function(a) { + if (a) { + a.config.init(true); + a.define = ace.define; + } + if (!window.ace) + window.ace = a; + for (var key in a) if (a.hasOwnProperty(key)) + window.ace[key] = a[key]; + window.ace["default"] = window.ace; + if (typeof module == "object" && typeof exports == "object" && module) { + module.exports = window.ace; + } + }); + })(); + ;ace.define("ace/snippets",["require","exports","module","ace/lib/oop","ace/lib/event_emitter","ace/lib/lang","ace/range","ace/range_list","ace/keyboard/hash_handler","ace/tokenizer","ace/clipboard","ace/lib/dom","ace/editor"],function(e,t,n){"use strict";function h(e){var t=(new Date).toLocaleString("en-us",e);return t.length==1?"0"+t:t}var r=e("./lib/oop"),i=e("./lib/event_emitter").EventEmitter,s=e("./lib/lang"),o=e("./range").Range,u=e("./range_list").RangeList,a=e("./keyboard/hash_handler").HashHandler,f=e("./tokenizer").Tokenizer,l=e("./clipboard"),c={CURRENT_WORD:function(e){return e.session.getTextRange(e.session.getWordRange())},SELECTION:function(e,t,n){var r=e.session.getTextRange();return n?r.replace(/\n\r?([ \t]*\S)/g,"\n"+n+"$1"):r},CURRENT_LINE:function(e){return e.session.getLine(e.getCursorPosition().row)},PREV_LINE:function(e){return e.session.getLine(e.getCursorPosition().row-1)},LINE_INDEX:function(e){return e.getCursorPosition().row},LINE_NUMBER:function(e){return e.getCursorPosition().row+1},SOFT_TABS:function(e){return e.session.getUseSoftTabs()?"YES":"NO"},TAB_SIZE:function(e){return e.session.getTabSize()},CLIPBOARD:function(e){return l.getText&&l.getText()},FILENAME:function(e){return/[^/\\]*$/.exec(this.FILEPATH(e))[0]},FILENAME_BASE:function(e){return/[^/\\]*$/.exec(this.FILEPATH(e))[0].replace(/\.[^.]*$/,"")},DIRECTORY:function(e){return this.FILEPATH(e).replace(/[^/\\]*$/,"")},FILEPATH:function(e){return"/not implemented.txt"},WORKSPACE_NAME:function(){return"Unknown"},FULLNAME:function(){return"Unknown"},BLOCK_COMMENT_START:function(e){var t=e.session.$mode||{};return t.blockComment&&t.blockComment.start||""},BLOCK_COMMENT_END:function(e){var t=e.session.$mode||{};return t.blockComment&&t.blockComment.end||""},LINE_COMMENT:function(e){var t=e.session.$mode||{};return t.lineCommentStart||""},CURRENT_YEAR:h.bind(null,{year:"numeric"}),CURRENT_YEAR_SHORT:h.bind(null,{year:"2-digit"}),CURRENT_MONTH:h.bind(null,{month:"numeric"}),CURRENT_MONTH_NAME:h.bind(null,{month:"long"}),CURRENT_MONTH_NAME_SHORT:h.bind(null,{month:"short"}),CURRENT_DATE:h.bind(null,{day:"2-digit"}),CURRENT_DAY_NAME:h.bind(null,{weekday:"long"}),CURRENT_DAY_NAME_SHORT:h.bind(null,{weekday:"short"}),CURRENT_HOUR:h.bind(null,{hour:"2-digit",hour12:!1}),CURRENT_MINUTE:h.bind(null,{minute:"2-digit"}),CURRENT_SECOND:h.bind(null,{second:"2-digit"})};c.SELECTED_TEXT=c.SELECTION;var p=function(){this.snippetMap={},this.snippetNameMap={}};(function(){r.implement(this,i),this.getTokenizer=function(){return p.$tokenizer||this.createTokenizer()},this.createTokenizer=function(){function e(e){return e=e.substr(1),/^\d+$/.test(e)?[{tabstopId:parseInt(e,10)}]:[{text:e}]}function t(e){return"(?:[^\\\\"+e+"]|\\\\.)"}var n={regex:"/("+t("/")+"+)/",onMatch:function(e,t,n){var r=n[0];return r.fmtString=!0,r.guard=e.slice(1,-1),r.flag="",""},next:"formatString"};return p.$tokenizer=new f({start:[{regex:/\\./,onMatch:function(e,t,n){var r=e[1];return r=="}"&&n.length?e=r:"`$\\".indexOf(r)!=-1&&(e=r),[e]}},{regex:/}/,onMatch:function(e,t,n){return[n.length?n.shift():e]}},{regex:/\$(?:\d+|\w+)/,onMatch:e},{regex:/\$\{[\dA-Z_a-z]+/,onMatch:function(t,n,r){var i=e(t.substr(1));return r.unshift(i[0]),i},next:"snippetVar"},{regex:/\n/,token:"newline",merge:!1}],snippetVar:[{regex:"\\|"+t("\\|")+"*\\|",onMatch:function(e,t,n){var r=e.slice(1,-1).replace(/\\[,|\\]|,/g,function(e){return e.length==2?e[1]:"\0"}).split("\0").map(function(e){return{value:e}});return n[0].choices=r,[r[0]]},next:"start"},n,{regex:"([^:}\\\\]|\\\\.)*:?",token:"",next:"start"}],formatString:[{regex:/:/,onMatch:function(e,t,n){return n.length&&n[0].expectElse?(n[0].expectElse=!1,n[0].ifEnd={elseEnd:n[0]},[n[0].ifEnd]):":"}},{regex:/\\./,onMatch:function(e,t,n){var r=e[1];return r=="}"&&n.length?e=r:"`$\\".indexOf(r)!=-1?e=r:r=="n"?e="\n":r=="t"?e=" ":"ulULE".indexOf(r)!=-1&&(e={changeCase:r,local:r>"a"}),[e]}},{regex:"/\\w*}",onMatch:function(e,t,n){var r=n.shift();return r&&(r.flag=e.slice(1,-1)),this.next=r&&r.tabstopId?"start":"",[r||e]},next:"start"},{regex:/\$(?:\d+|\w+)/,onMatch:function(e,t,n){return[{text:e.slice(1)}]}},{regex:/\${\w+/,onMatch:function(e,t,n){var r={text:e.slice(2)};return n.unshift(r),[r]},next:"formatStringVar"},{regex:/\n/,token:"newline",merge:!1},{regex:/}/,onMatch:function(e,t,n){var r=n.shift();return this.next=r&&r.tabstopId?"start":"",[r||e]},next:"start"}],formatStringVar:[{regex:/:\/\w+}/,onMatch:function(e,t,n){var r=n[0];return r.formatFunction=e.slice(2,-1),[n.shift()]},next:"formatString"},n,{regex:/:[\?\-+]?/,onMatch:function(e,t,n){e[1]=="+"&&(n[0].ifEnd=n[0]),e[1]=="?"&&(n[0].expectElse=!0)},next:"formatString"},{regex:"([^:}\\\\]|\\\\.)*:?",token:"",next:"formatString"}]}),p.$tokenizer},this.tokenizeTmSnippet=function(e,t){return this.getTokenizer().getLineTokens(e,t).tokens.map(function(e){return e.value||e})},this.getVariableValue=function(e,t,n){if(/^\d+$/.test(t))return(this.variables.__||{})[t]||"";if(/^[A-Z]\d+$/.test(t))return(this.variables[t[0]+"__"]||{})[t.substr(1)]||"";t=t.replace(/^TM_/,"");if(!this.variables.hasOwnProperty(t))return"";var r=this.variables[t];return typeof r=="function"&&(r=this.variables[t](e,t,n)),r==null?"":r},this.variables=c,this.tmStrFormat=function(e,t,n){if(!t.fmt)return e;var r=t.flag||"",i=t.guard;i=new RegExp(i,r.replace(/[^gim]/g,""));var s=typeof t.fmt=="string"?this.tokenizeTmSnippet(t.fmt,"formatString"):t.fmt,o=this,u=e.replace(i,function(){var e=o.variables.__;o.variables.__=[].slice.call(arguments);var t=o.resolveVariables(s,n),r="E";for(var i=0;i<t.length;i++){var u=t[i];if(typeof u=="object"){t[i]="";if(u.changeCase&&u.local){var a=t[i+1];a&&typeof a=="string"&&(u.changeCase=="u"?t[i]=a[0].toUpperCase():t[i]=a[0].toLowerCase(),t[i+1]=a.substr(1))}else u.changeCase&&(r=u.changeCase)}else r=="U"?t[i]=u.toUpperCase():r=="L"&&(t[i]=u.toLowerCase())}return o.variables.__=e,t.join("")});return u},this.tmFormatFunction=function(e,t,n){return t.formatFunction=="upcase"?e.toUpperCase():t.formatFunction=="downcase"?e.toLowerCase():e},this.resolveVariables=function(e,t){function f(t){var n=e.indexOf(t,s+1);n!=-1&&(s=n)}var n=[],r="",i=!0;for(var s=0;s<e.length;s++){var o=e[s];if(typeof o=="string"){n.push(o),o=="\n"?(i=!0,r=""):i&&(r=/^\t*/.exec(o)[0],i=/\S/.test(o));continue}if(!o)continue;i=!1;if(o.fmtString){var u=e.indexOf(o,s+1);u==-1&&(u=e.length),o.fmt=e.slice(s+1,u),s=u}if(o.text){var a=this.getVariableValue(t,o.text,r)+"";o.fmtString&&(a=this.tmStrFormat(a,o,t)),o.formatFunction&&(a=this.tmFormatFunction(a,o,t)),a&&!o.ifEnd?(n.push(a),f(o)):!a&&o.ifEnd&&f(o.ifEnd)}else o.elseEnd?f(o.elseEnd):o.tabstopId!=null?n.push(o):o.changeCase!=null&&n.push(o)}return n},this.insertSnippetForSelection=function(e,t){function f(e){var t=[];for(var n=0;n<e.length;n++){var r=e[n];if(typeof r=="object"){if(a[r.tabstopId])continue;var i=e.lastIndexOf(r,n-1);r=t[i]||{tabstopId:r.tabstopId}}t[n]=r}return t}var n=e.getCursorPosition(),r=e.session.getLine(n.row),i=e.session.getTabString(),s=r.match(/^\s*/)[0];n.column<s.length&&(s=s.slice(0,n.column)),t=t.replace(/\r/g,"");var o=this.tokenizeTmSnippet(t);o=this.resolveVariables(o,e),o=o.map(function(e){return e=="\n"?e+s:typeof e=="string"?e.replace(/\t/g,i):e});var u=[];o.forEach(function(e,t){if(typeof e!="object")return;var n=e.tabstopId,r=u[n];r||(r=u[n]=[],r.index=n,r.value="",r.parents={});if(r.indexOf(e)!==-1)return;e.choices&&!r.choices&&(r.choices=e.choices),r.push(e);var i=o.indexOf(e,t+1);if(i===-1)return;var s=o.slice(t+1,i),a=s.some(function(e){return typeof e=="object"});a&&!r.value?r.value=s:s.length&&(!r.value||typeof r.value!="string")&&(r.value=s.join(""))}),u.forEach(function(e){e.length=0});var a={};for(var l=0;l<o.length;l++){var c=o[l];if(typeof c!="object")continue;var h=c.tabstopId,p=u[h],v=o.indexOf(c,l+1);if(a[h]){a[h]===c&&(delete a[h],Object.keys(a).forEach(function(e){p.parents[e]=!0}));continue}a[h]=c;var m=p.value;typeof m!="string"?m=f(m):c.fmt&&(m=this.tmStrFormat(m,c,e)),o.splice.apply(o,[l+1,Math.max(0,v-l)].concat(m,c)),p.indexOf(c)===-1&&p.push(c)}var g=0,y=0,b="";o.forEach(function(e){if(typeof e=="string"){var t=e.split("\n");t.length>1?(y=t[t.length-1].length,g+=t.length-1):y+=e.length,b+=e}else e&&(e.start?e.end={row:g,column:y}:e.start={row:g,column:y})});var w=e.getSelectionRange(),E=e.session.replace(w,b),S=new d(e),x=e.inVirtualSelectionMode&&e.selection.index;S.addTabstops(u,w.start,E,x)},this.insertSnippet=function(e,t){var n=this;if(e.inVirtualSelectionMode)return n.insertSnippetForSelection(e,t);e.forEachSelection(function(){n.insertSnippetForSelection(e,t)},null,{keepOrder:!0}),e.tabstopManager&&e.tabstopManager.tabNext()},this.$getScope=function(e){var t=e.session.$mode.$id||"";t=t.split("/").pop();if(t==="html"||t==="php"){t==="php"&&!e.session.$mode.inlinePhp&&(t="html");var n=e.getCursorPosition(),r=e.session.getState(n.row);typeof r=="object"&&(r=r[0]),r.substring&&(r.substring(0,3)=="js-"?t="javascript":r.substring(0,4)=="css-"?t="css":r.substring(0,4)=="php-"&&(t="php"))}return t},this.getActiveScopes=function(e){var t=this.$getScope(e),n=[t],r=this.snippetMap;return r[t]&&r[t].includeScopes&&n.push.apply(n,r[t].includeScopes),n.push("_"),n},this.expandWithTab=function(e,t){var n=this,r=e.forEachSelection(function(){return n.expandSnippetForSelection(e,t)},null,{keepOrder:!0});return r&&e.tabstopManager&&e.tabstopManager.tabNext(),r},this.expandSnippetForSelection=function(e,t){var n=e.getCursorPosition(),r=e.session.getLine(n.row),i=r.substring(0,n.column),s=r.substr(n.column),o=this.snippetMap,u;return this.getActiveScopes(e).some(function(e){var t=o[e];return t&&(u=this.findMatchingSnippet(t,i,s)),!!u},this),u?t&&t.dryRun?!0:(e.session.doc.removeInLine(n.row,n.column-u.replaceBefore.length,n.column+u.replaceAfter.length),this.variables.M__=u.matchBefore,this.variables.T__=u.matchAfter,this.insertSnippetForSelection(e,u.content),this.variables.M__=this.variables.T__=null,!0):!1},this.findMatchingSnippet=function(e,t,n){for(var r=e.length;r--;){var i=e[r];if(i.startRe&&!i.startRe.test(t))continue;if(i.endRe&&!i.endRe.test(n))continue;if(!i.startRe&&!i.endRe)continue;return i.matchBefore=i.startRe?i.startRe.exec(t):[""],i.matchAfter=i.endRe?i.endRe.exec(n):[""],i.replaceBefore=i.triggerRe?i.triggerRe.exec(t)[0]:"",i.replaceAfter=i.endTriggerRe?i.endTriggerRe.exec(n)[0]:"",i}},this.snippetMap={},this.snippetNameMap={},this.register=function(e,t){function o(e){return e&&!/^\^?\(.*\)\$?$|^\\b$/.test(e)&&(e="(?:"+e+")"),e||""}function u(e,t,n){return e=o(e),t=o(t),n?(e=t+e,e&&e[e.length-1]!="$"&&(e+="$")):(e+=t,e&&e[0]!="^"&&(e="^"+e)),new RegExp(e)}function a(e){e.scope||(e.scope=t||"_"),t=e.scope,n[t]||(n[t]=[],r[t]={});var o=r[t];if(e.name){var a=o[e.name];a&&i.unregister(a),o[e.name]=e}n[t].push(e),e.prefix&&(e.tabTrigger=e.prefix),!e.content&&e.body&&(e.content=Array.isArray(e.body)?e.body.join("\n"):e.body),e.tabTrigger&&!e.trigger&&(!e.guard&&/^\w/.test(e.tabTrigger)&&(e.guard="\\b"),e.trigger=s.escapeRegExp(e.tabTrigger));if(!e.trigger&&!e.guard&&!e.endTrigger&&!e.endGuard)return;e.startRe=u(e.trigger,e.guard,!0),e.triggerRe=new RegExp(e.trigger),e.endRe=u(e.endTrigger,e.endGuard,!0),e.endTriggerRe=new RegExp(e.endTrigger)}var n=this.snippetMap,r=this.snippetNameMap,i=this;e||(e=[]),Array.isArray(e)?e.forEach(a):Object.keys(e).forEach(function(t){a(e[t])}),this._signal("registerSnippets",{scope:t})},this.unregister=function(e,t){function i(e){var i=r[e.scope||t];if(i&&i[e.name]){delete i[e.name];var s=n[e.scope||t],o=s&&s.indexOf(e);o>=0&&s.splice(o,1)}}var n=this.snippetMap,r=this.snippetNameMap;e.content?i(e):Array.isArray(e)&&e.forEach(i)},this.parseSnippetFile=function(e){e=e.replace(/\r/g,"");var t=[],n={},r=/^#.*|^({[\s\S]*})\s*$|^(\S+) (.*)$|^((?:\n*\t.*)+)/gm,i;while(i=r.exec(e)){if(i[1])try{n=JSON.parse(i[1]),t.push(n)}catch(s){}if(i[4])n.content=i[4].replace(/^\t/gm,""),t.push(n),n={};else{var o=i[2],u=i[3];if(o=="regex"){var a=/\/((?:[^\/\\]|\\.)*)|$/g;n.guard=a.exec(u)[1],n.trigger=a.exec(u)[1],n.endTrigger=a.exec(u)[1],n.endGuard=a.exec(u)[1]}else o=="snippet"?(n.tabTrigger=u.match(/^\S*/)[0],n.name||(n.name=u)):o&&(n[o]=u)}}return t},this.getSnippetByName=function(e,t){var n=this.snippetNameMap,r;return this.getActiveScopes(t).some(function(t){var i=n[t];return i&&(r=i[e]),!!r},this),r}}).call(p.prototype);var d=function(e){if(e.tabstopManager)return e.tabstopManager;e.tabstopManager=this,this.$onChange=this.onChange.bind(this),this.$onChangeSelection=s.delayedCall(this.onChangeSelection.bind(this)).schedule,this.$onChangeSession=this.onChangeSession.bind(this),this.$onAfterExec=this.onAfterExec.bind(this),this.attach(e)};(function(){this.attach=function(e){this.index=0,this.ranges=[],this.tabstops=[],this.$openTabstops=null,this.selectedTabstop=null,this.editor=e,this.editor.on("change",this.$onChange),this.editor.on("changeSelection",this.$onChangeSelection),this.editor.on("changeSession",this.$onChangeSession),this.editor.commands.on("afterExec",this.$onAfterExec),this.editor.keyBinding.addKeyboardHandler(this.keyboardHandler)},this.detach=function(){this.tabstops.forEach(this.removeTabstopMarkers,this),this.ranges=null,this.tabstops=null,this.selectedTabstop=null,this.editor.removeListener("change",this.$onChange),this.editor.removeListener("changeSelection",this.$onChangeSelection),this.editor.removeListener("changeSession",this.$onChangeSession),this.editor.commands.removeListener("afterExec",this.$onAfterExec),this.editor.keyBinding.removeKeyboardHandler(this.keyboardHandler),this.editor.tabstopManager=null,this.editor=null},this.onChange=function(e){var t=e.action[0]=="r",n=this.selectedTabstop||{},r=n.parents||{},i=(this.tabstops||[]).slice();for(var s=0;s<i.length;s++){var o=i[s],u=o==n||r[o.index];o.rangeList.$bias=u?0:1;if(e.action=="remove"&&o!==n){var a=o.parents&&o.parents[n.index],f=o.rangeList.pointIndex(e.start,a);f=f<0?-f-1:f+1;var l=o.rangeList.pointIndex(e.end,a);l=l<0?-l-1:l-1;var c=o.rangeList.ranges.slice(f,l);for(var h=0;h<c.length;h++)this.removeRange(c[h])}o.rangeList.$onChange(e)}var p=this.editor.session;!this.$inChange&&t&&p.getLength()==1&&!p.getValue()&&this.detach()},this.updateLinkedFields=function(){var e=this.selectedTabstop;if(!e||!e.hasLinkedRanges||!e.firstNonLinked)return;this.$inChange=!0;var n=this.editor.session,r=n.getTextRange(e.firstNonLinked);for(var i=0;i<e.length;i++){var s=e[i];if(!s.linked)continue;var o=s.original,u=t.snippetManager.tmStrFormat(r,o,this.editor);n.replace(s,u)}this.$inChange=!1},this.onAfterExec=function(e){e.command&&!e.command.readOnly&&this.updateLinkedFields()},this.onChangeSelection=function(){if(!this.editor)return;var e=this.editor.selection.lead,t=this.editor.selection.anchor,n=this.editor.selection.isEmpty();for(var r=0;r<this.ranges.length;r++){if(this.ranges[r].linked)continue;var i=this.ranges[r].contains(e.row,e.column),s=n||this.ranges[r].contains(t.row,t.column);if(i&&s)return}this.detach()},this.onChangeSession=function(){this.detach()},this.tabNext=function(e){var t=this.tabstops.length,n=this.index+(e||1);n=Math.min(Math.max(n,1),t),n==t&&(n=0),this.selectTabstop(n),n===0&&this.detach()},this.selectTabstop=function(e){this.$openTabstops=null;var t=this.tabstops[this.index];t&&this.addTabstopMarkers(t),this.index=e,t=this.tabstops[this.index];if(!t||!t.length)return;this.selectedTabstop=t;var n=t.firstNonLinked||t;t.choices&&(n.cursor=n.start);if(!this.editor.inVirtualSelectionMode){var r=this.editor.multiSelect;r.toSingleRange(n);for(var i=0;i<t.length;i++){if(t.hasLinkedRanges&&t[i].linked)continue;r.addRange(t[i].clone(),!0)}}else this.editor.selection.fromOrientedRange(n);this.editor.keyBinding.addKeyboardHandler(this.keyboardHandler),this.selectedTabstop&&this.selectedTabstop.choices&&this.editor.execCommand("startAutocomplete",{matches:this.selectedTabstop.choices})},this.addTabstops=function(e,t,n){var r=this.useLink||!this.editor.getOption("enableMultiselect");this.$openTabstops||(this.$openTabstops=[]);if(!e[0]){var i=o.fromPoints(n,n);m(i.start,t),m(i.end,t),e[0]=[i],e[0].index=0}var s=this.index,a=[s+1,0],f=this.ranges;e.forEach(function(e,n){var i=this.$openTabstops[n]||e;for(var s=0;s<e.length;s++){var l=e[s],c=o.fromPoints(l.start,l.end||l.start);v(c.start,t),v(c.end,t),c.original=l,c.tabstop=i,f.push(c),i!=e?i.unshift(c):i[s]=c,l.fmtString||i.firstNonLinked&&r?(c.linked=!0,i.hasLinkedRanges=!0):i.firstNonLinked||(i.firstNonLinked=c)}i.firstNonLinked||(i.hasLinkedRanges=!1),i===e&&(a.push(i),this.$openTabstops[n]=i),this.addTabstopMarkers(i),i.rangeList=i.rangeList||new u,i.rangeList.$bias=0,i.rangeList.addList(i)},this),a.length>2&&(this.tabstops.length&&a.push(a.splice(2,1)[0]),this.tabstops.splice.apply(this.tabstops,a))},this.addTabstopMarkers=function(e){var t=this.editor.session;e.forEach(function(e){e.markerId||(e.markerId=t.addMarker(e,"ace_snippet-marker","text"))})},this.removeTabstopMarkers=function(e){var t=this.editor.session;e.forEach(function(e){t.removeMarker(e.markerId),e.markerId=null})},this.removeRange=function(e){var t=e.tabstop.indexOf(e);t!=-1&&e.tabstop.splice(t,1),t=this.ranges.indexOf(e),t!=-1&&this.ranges.splice(t,1),t=e.tabstop.rangeList.ranges.indexOf(e),t!=-1&&e.tabstop.splice(t,1),this.editor.session.removeMarker(e.markerId),e.tabstop.length||(t=this.tabstops.indexOf(e.tabstop),t!=-1&&this.tabstops.splice(t,1),this.tabstops.length||this.detach())},this.keyboardHandler=new a,this.keyboardHandler.bindKeys({Tab:function(e){if(t.snippetManager&&t.snippetManager.expandWithTab(e))return;e.tabstopManager.tabNext(1),e.renderer.scrollCursorIntoView()},"Shift-Tab":function(e){e.tabstopManager.tabNext(-1),e.renderer.scrollCursorIntoView()},Esc:function(e){e.tabstopManager.detach()}})}).call(d.prototype);var v=function(e,t){e.row==0&&(e.column+=t.column),e.row+=t.row},m=function(e,t){e.row==t.row&&(e.column-=t.column),e.row-=t.row};e("./lib/dom").importCssString(".ace_snippet-marker { -moz-box-sizing: border-box; box-sizing: border-box; background: rgba(194, 193, 208, 0.09); border: 1px dotted rgba(211, 208, 235, 0.62); position: absolute;}"),t.snippetManager=new p;var g=e("./editor").Editor;(function(){this.insertSnippet=function(e,n){return t.snippetManager.insertSnippet(this,e,n)},this.expandSnippet=function(e){return t.snippetManager.expandWithTab(this,e)}}).call(g.prototype)}),ace.define("ace/autocomplete/popup",["require","exports","module","ace/virtual_renderer","ace/editor","ace/range","ace/lib/event","ace/lib/lang","ace/lib/dom"],function(e,t,n){"use strict";var r=e("../virtual_renderer").VirtualRenderer,i=e("../editor").Editor,s=e("../range").Range,o=e("../lib/event"),u=e("../lib/lang"),a=e("../lib/dom"),f=function(e){var t=new r(e);t.$maxLines=4;var n=new i(t);return n.setHighlightActiveLine(!1),n.setShowPrintMargin(!1),n.renderer.setShowGutter(!1),n.renderer.setHighlightGutterLine(!1),n.$mouseHandler.$focusTimeout=0,n.$highlightTagPending=!0,n},l=function(e){var t=a.createElement("div"),n=new f(t);e&&e.appendChild(t),t.style.display="none",n.renderer.content.style.cursor="default",n.renderer.setStyle("ace_autocomplete"),n.setOption("displayIndentGuides",!1),n.setOption("dragDelay",150);var r=function(){};n.focus=r,n.$isFocused=!0,n.renderer.$cursorLayer.restartTimer=r,n.renderer.$cursorLayer.element.style.opacity=0,n.renderer.$maxLines=8,n.renderer.$keepTextAreaAtCursor=!1,n.setHighlightActiveLine(!1),n.session.highlight(""),n.session.$searchHighlight.clazz="ace_highlight-marker",n.on("mousedown",function(e){var t=e.getDocumentPosition();n.selection.moveToPosition(t),c.start.row=c.end.row=t.row,e.stop()});var i,l=new s(-1,0,-1,Infinity),c=new s(-1,0,-1,Infinity);c.id=n.session.addMarker(c,"ace_active-line","fullLine"),n.setSelectOnHover=function(e){e?l.id&&(n.session.removeMarker(l.id),l.id=null):l.id=n.session.addMarker(l,"ace_line-hover","fullLine")},n.setSelectOnHover(!1),n.on("mousemove",function(e){if(!i){i=e;return}if(i.x==e.x&&i.y==e.y)return;i=e,i.scrollTop=n.renderer.scrollTop;var t=i.getDocumentPosition().row;l.start.row!=t&&(l.id||n.setRow(t),p(t))}),n.renderer.on("beforeRender",function(){if(i&&l.start.row!=-1){i.$pos=null;var e=i.getDocumentPosition().row;l.id||n.setRow(e),p(e,!0)}}),n.renderer.on("afterRender",function(){var e=n.getRow(),t=n.renderer.$textLayer,r=t.element.childNodes[e-t.config.firstRow];r!==t.selectedNode&&t.selectedNode&&a.removeCssClass(t.selectedNode,"ace_selected"),t.selectedNode=r,r&&a.addCssClass(r,"ace_selected")});var h=function(){p(-1)},p=function(e,t){e!==l.start.row&&(l.start.row=l.end.row=e,t||n.session._emit("changeBackMarker"),n._emit("changeHoverMarker"))};n.getHoveredRow=function(){return l.start.row},o.addListener(n.container,"mouseout",h),n.on("hide",h),n.on("changeSelection",h),n.session.doc.getLength=function(){return n.data.length},n.session.doc.getLine=function(e){var t=n.data[e];return typeof t=="string"?t:t&&t.value||""};var d=n.session.bgTokenizer;return d.$tokenizeRow=function(e){function s(e,n){e&&r.push({type:(t.className||"")+(n||""),value:e})}var t=n.data[e],r=[];if(!t)return r;typeof t=="string"&&(t={value:t});var i=t.caption||t.value||t.name,o=i.toLowerCase(),u=(n.filterText||"").toLowerCase(),a=0,f=0;for(var l=0;l<=u.length;l++)if(l!=f&&(t.matchMask&1<<l||l==u.length)){var c=u.slice(f,l);f=l;var h=o.indexOf(c,a);if(h==-1)continue;s(i.slice(a,h),""),a=h+c.length,s(i.slice(h,a),"completion-highlight")}return s(i.slice(a,i.length),""),t.meta&&r.push({type:"completion-meta",value:t.meta}),t.message&&r.push({type:"completion-message",value:t.message}),r},d.$updateOnChange=r,d.start=r,n.session.$computeWidth=function(){return this.screenWidth=0},n.isOpen=!1,n.isTopdown=!1,n.autoSelect=!0,n.filterText="",n.data=[],n.setData=function(e,t){n.filterText=t||"",n.setValue(u.stringRepeat("\n",e.length),-1),n.data=e||[],n.setRow(0)},n.getData=function(e){return n.data[e]},n.getRow=function(){return c.start.row},n.setRow=function(e){e=Math.max(this.autoSelect?0:-1,Math.min(this.data.length,e)),c.start.row!=e&&(n.selection.clearSelection(),c.start.row=c.end.row=e||0,n.session._emit("changeBackMarker"),n.moveCursorTo(e||0,0),n.isOpen&&n._signal("select"))},n.on("changeSelection",function(){n.isOpen&&n.setRow(n.selection.lead.row),n.renderer.scrollCursorIntoView()}),n.hide=function(){this.container.style.display="none",this._signal("hide"),n.isOpen=!1},n.show=function(e,t,r){var s=this.container,o=window.innerHeight,u=window.innerWidth,a=this.renderer,f=a.$maxLines*t*1.4,l=e.top+this.$borderSize,c=l>o/2&&!r;c&&l+t+f>o?(a.$maxPixelHeight=l-2*this.$borderSize,s.style.top="",s.style.bottom=o-l+"px",n.isTopdown=!1):(l+=t,a.$maxPixelHeight=o-l-.2*t,s.style.top=l+"px",s.style.bottom="",n.isTopdown=!0),s.style.display="";var h=e.left;h+s.offsetWidth>u&&(h=u-s.offsetWidth),s.style.left=h+"px",this._signal("show"),i=null,n.isOpen=!0},n.goTo=function(e){var t=this.getRow(),n=this.session.getLength()-1;switch(e){case"up":t=t<=0?n:t-1;break;case"down":t=t>=n?-1:t+1;break;case"start":t=0;break;case"end":t=n}this.setRow(t)},n.getTextLeftOffset=function(){return this.$borderSize+this.renderer.$padding+this.$imageSize},n.$imageSize=0,n.$borderSize=1,n};a.importCssString(".ace_editor.ace_autocomplete .ace_marker-layer .ace_active-line { background-color: #CAD6FA; z-index: 1;}.ace_dark.ace_editor.ace_autocomplete .ace_marker-layer .ace_active-line { background-color: #3a674e;}.ace_editor.ace_autocomplete .ace_line-hover { border: 1px solid #abbffe; margin-top: -1px; background: rgba(233,233,253,0.4); position: absolute; z-index: 2;}.ace_dark.ace_editor.ace_autocomplete .ace_line-hover { border: 1px solid rgba(109, 150, 13, 0.8); background: rgba(58, 103, 78, 0.62);}.ace_completion-meta { opacity: 0.5; margin: 0.9em;}.ace_completion-message { color: blue;}.ace_editor.ace_autocomplete .ace_completion-highlight{ color: #2d69c7;}.ace_dark.ace_editor.ace_autocomplete .ace_completion-highlight{ color: #93ca12;}.ace_editor.ace_autocomplete { width: 300px; z-index: 200000; border: 1px lightgray solid; position: fixed; box-shadow: 2px 3px 5px rgba(0,0,0,.2); line-height: 1.4; background: #fefefe; color: #111;}.ace_dark.ace_editor.ace_autocomplete { border: 1px #484747 solid; box-shadow: 2px 3px 5px rgba(0, 0, 0, 0.51); line-height: 1.4; background: #25282c; color: #c1c1c1;}","autocompletion.css"),t.AcePopup=l,t.$singleLineEditor=f}),ace.define("ace/autocomplete/util",["require","exports","module"],function(e,t,n){"use strict";t.parForEach=function(e,t,n){var r=0,i=e.length;i===0&&n();for(var s=0;s<i;s++)t(e[s],function(e,t){r++,r===i&&n(e,t)})};var r=/[a-zA-Z_0-9\$\-\u00A2-\u2000\u2070-\uFFFF]/;t.retrievePrecedingIdentifier=function(e,t,n){n=n||r;var i=[];for(var s=t-1;s>=0;s--){if(!n.test(e[s]))break;i.push(e[s])}return i.reverse().join("")},t.retrieveFollowingIdentifier=function(e,t,n){n=n||r;var i=[];for(var s=t;s<e.length;s++){if(!n.test(e[s]))break;i.push(e[s])}return i},t.getCompletionPrefix=function(e){var t=e.getCursorPosition(),n=e.session.getLine(t.row),r;return e.completers.forEach(function(e){e.identifierRegexps&&e.identifierRegexps.forEach(function(e){!r&&e&&(r=this.retrievePrecedingIdentifier(n,t.column,e))}.bind(this))}.bind(this)),r||this.retrievePrecedingIdentifier(n,t.column)}}),ace.define("ace/autocomplete",["require","exports","module","ace/keyboard/hash_handler","ace/autocomplete/popup","ace/autocomplete/util","ace/lib/lang","ace/lib/dom","ace/snippets","ace/config"],function(e,t,n){"use strict";var r=e("./keyboard/hash_handler").HashHandler,i=e("./autocomplete/popup").AcePopup,s=e("./autocomplete/util"),o=e("./lib/lang"),u=e("./lib/dom"),a=e("./snippets").snippetManager,f=e("./config"),l=function(){this.autoInsert=!1,this.autoSelect=!0,this.exactMatch=!1,this.gatherCompletionsId=0,this.keyboardHandler=new r,this.keyboardHandler.bindKeys(this.commands),this.blurListener=this.blurListener.bind(this),this.changeListener=this.changeListener.bind(this),this.mousedownListener=this.mousedownListener.bind(this),this.mousewheelListener=this.mousewheelListener.bind(this),this.changeTimer=o.delayedCall(function(){this.updateCompletions(!0)}.bind(this)),this.tooltipTimer=o.delayedCall(this.updateDocTooltip.bind(this),50)};(function(){this.$init=function(){return this.popup=new i(document.body||document.documentElement),this.popup.on("click",function(e){this.insertMatch(),e.stop()}.bind(this)),this.popup.focus=this.editor.focus.bind(this.editor),this.popup.on("show",this.tooltipTimer.bind(null,null)),this.popup.on("select",this.tooltipTimer.bind(null,null)),this.popup.on("changeHoverMarker",this.tooltipTimer.bind(null,null)),this.popup},this.getPopup=function(){return this.popup||this.$init()},this.openPopup=function(e,t,n){this.popup||this.$init(),this.popup.autoSelect=this.autoSelect,this.popup.setData(this.completions.filtered,this.completions.filterText),e.keyBinding.addKeyboardHandler(this.keyboardHandler);var r=e.renderer;this.popup.setRow(this.autoSelect?0:-1);if(!n){this.popup.setTheme(e.getTheme()),this.popup.setFontSize(e.getFontSize());var i=r.layerConfig.lineHeight,s=r.$cursorLayer.getPixelPosition(this.base,!0);s.left-=this.popup.getTextLeftOffset();var o=e.container.getBoundingClientRect();s.top+=o.top-r.layerConfig.offset,s.left+=o.left-e.renderer.scrollLeft,s.left+=r.gutterWidth,this.popup.show(s,i)}else n&&!t&&this.detach();this.changeTimer.cancel()},this.detach=function(){this.editor.keyBinding.removeKeyboardHandler(this.keyboardHandler),this.editor.off("changeSelection",this.changeListener),this.editor.off("blur",this.blurListener),this.editor.off("mousedown",this.mousedownListener),this.editor.off("mousewheel",this.mousewheelListener),this.changeTimer.cancel(),this.hideDocTooltip(),this.gatherCompletionsId+=1,this.popup&&this.popup.isOpen&&this.popup.hide(),this.base&&this.base.detach(),this.activated=!1,this.completions=this.base=null},this.changeListener=function(e){var t=this.editor.selection.lead;(t.row!=this.base.row||t.column<this.base.column)&&this.detach(),this.activated?this.changeTimer.schedule():this.detach()},this.blurListener=function(e){var t=document.activeElement,n=this.editor.textInput.getElement(),r=e.relatedTarget&&this.tooltipNode&&this.tooltipNode.contains(e.relatedTarget),i=this.popup&&this.popup.container;t!=n&&t.parentNode!=i&&!r&&t!=this.tooltipNode&&e.relatedTarget!=n&&this.detach()},this.mousedownListener=function(e){this.detach()},this.mousewheelListener=function(e){this.detach()},this.goTo=function(e){this.popup.goTo(e)},this.insertMatch=function(e,t){e||(e=this.popup.getData(this.popup.getRow()));if(!e)return!1;var n=this.completions;this.editor.startOperation({command:{name:"insertMatch"}});if(e.completer&&e.completer.insertMatch)e.completer.insertMatch(this.editor,e);else{if(n.filterText){var r=this.editor.selection.getAllRanges();for(var i=0,s;s=r[i];i++)s.start.column-=n.filterText.length,this.editor.session.remove(s)}e.snippet?a.insertSnippet(this.editor,e.snippet):this.editor.execCommand("insertstring",e.value||e)}this.completions==n&&this.detach(),this.editor.endOperation()},this.commands={Up:function(e){e.completer.goTo("up")},Down:function(e){e.completer.goTo("down")},"Ctrl-Up|Ctrl-Home":function(e){e.completer.goTo("start")},"Ctrl-Down|Ctrl-End":function(e){e.completer.goTo("end")},Esc:function(e){e.completer.detach()},Return:function(e){return e.completer.insertMatch()},"Shift-Return":function(e){e.completer.insertMatch(null,{deleteSuffix:!0})},Tab:function(e){var t=e.completer.insertMatch();if(!!t||!!e.tabstopManager)return t;e.completer.goTo("down")},PageUp:function(e){e.completer.popup.gotoPageUp()},PageDown:function(e){e.completer.popup.gotoPageDown()}},this.gatherCompletions=function(e,t){var n=e.getSession(),r=e.getCursorPosition(),i=s.getCompletionPrefix(e);this.base=n.doc.createAnchor(r.row,r.column-i.length),this.base.$insertRight=!0;var o=[],u=e.completers.length;return e.completers.forEach(function(a,f){a.getCompletions(e,n,r,i,function(n,r){!n&&r&&(o=o.concat(r)),t(null,{prefix:s.getCompletionPrefix(e),matches:o,finished:--u===0})})}),!0},this.showPopup=function(e,t){this.editor&&this.detach(),this.activated=!0,this.editor=e,e.completer!=this&&(e.completer&&e.completer.detach(),e.completer=this),e.on("changeSelection",this.changeListener),e.on("blur",this.blurListener),e.on("mousedown",this.mousedownListener),e.on("mousewheel",this.mousewheelListener),this.updateCompletions(!1,t)},this.updateCompletions=function(e,t){if(e&&this.base&&this.completions){var n=this.editor.getCursorPosition(),r=this.editor.session.getTextRange({start:this.base,end:n});if(r==this.completions.filterText)return;this.completions.setFilter(r);if(!this.completions.filtered.length)return this.detach();if(this.completions.filtered.length==1&&this.completions.filtered[0].value==r&&!this.completions.filtered[0].snippet)return this.detach();this.openPopup(this.editor,r,e);return}if(t&&t.matches){var n=this.editor.getSelectionRange().start;return this.base=this.editor.session.doc.createAnchor(n.row,n.column),this.base.$insertRight=!0,this.completions=new c(t.matches),this.openPopup(this.editor,"",e)}var i=this.gatherCompletionsId;this.gatherCompletions(this.editor,function(t,n){var r=function(){if(!n.finished)return;return this.detach()}.bind(this),s=n.prefix,o=n&&n.matches;if(!o||!o.length)return r();if(s.indexOf(n.prefix)!==0||i!=this.gatherCompletionsId)return;this.completions=new c(o),this.exactMatch&&(this.completions.exactMatch=!0),this.completions.setFilter(s);var u=this.completions.filtered;if(!u.length)return r();if(u.length==1&&u[0].value==s&&!u[0].snippet)return r();if(this.autoInsert&&u.length==1&&n.finished)return this.insertMatch(u[0]);this.openPopup(this.editor,s,e)}.bind(this))},this.cancelContextMenu=function(){this.editor.$mouseHandler.cancelContextMenu()},this.updateDocTooltip=function(){var e=this.popup,t=e.data,n=t&&(t[e.getHoveredRow()]||t[e.getRow()]),r=null;if(!n||!this.editor||!this.popup.isOpen)return this.hideDocTooltip();this.editor.completers.some(function(e){return e.getDocTooltip&&(r=e.getDocTooltip(n)),r}),!r&&typeof n!="string"&&(r=n),typeof r=="string"&&(r={docText:r});if(!r||!r.docHTML&&!r.docText)return this.hideDocTooltip();this.showDocTooltip(r)},this.showDocTooltip=function(e){this.tooltipNode||(this.tooltipNode=u.createElement("div"),this.tooltipNode.className="ace_tooltip ace_doc-tooltip",this.tooltipNode.style.margin=0,this.tooltipNode.style.pointerEvents="auto",this.tooltipNode.tabIndex=-1,this.tooltipNode.onblur=this.blurListener.bind(this),this.tooltipNode.onclick=this.onTooltipClick.bind(this));var t=this.tooltipNode;e.docHTML?t.innerHTML=e.docHTML:e.docText&&(t.textContent=e.docText),t.parentNode||document.body.appendChild(t);var n=this.popup,r=n.container.getBoundingClientRect();t.style.top=n.container.style.top,t.style.bottom=n.container.style.bottom,t.style.display="block",window.innerWidth-r.right<320?r.left<320?n.isTopdown?(t.style.top=r.bottom+"px",t.style.left=r.left+"px",t.style.right="",t.style.bottom=""):(t.style.top=n.container.offsetTop-t.offsetHeight+"px",t.style.left=r.left+"px",t.style.right="",t.style.bottom=""):(t.style.right=window.innerWidth-r.left+"px",t.style.left=""):(t.style.left=r.right+1+"px",t.style.right="")},this.hideDocTooltip=function(){this.tooltipTimer.cancel();if(!this.tooltipNode)return;var e=this.tooltipNode;!this.editor.isFocused()&&document.activeElement==e&&this.editor.focus(),this.tooltipNode=null,e.parentNode&&e.parentNode.removeChild(e)},this.onTooltipClick=function(e){var t=e.target;while(t&&t!=this.tooltipNode){if(t.nodeName=="A"&&t.href){t.rel="noreferrer",t.target="_blank";break}t=t.parentNode}},this.destroy=function(){this.detach();if(this.popup){this.popup.destroy();var e=this.popup.container;e&&e.parentNode&&e.parentNode.removeChild(e)}this.editor&&this.editor.completer==this&&this.editor.completer==null,this.popup=null}}).call(l.prototype),l.for=function(e){return e.completer?e.completer:(f.get("sharedPopups")?(l.$shared||(l.$sharedInstance=new l),e.completer=l.$sharedInstance):(e.completer=new l,e.once("destroy",function(e,t){t.completer.destroy()})),e.completer)},l.startCommand={name:"startAutocomplete",exec:function(e,t){var n=l.for(e);n.autoInsert=!1,n.autoSelect=!0,n.showPopup(e,t),n.cancelContextMenu()},bindKey:"Ctrl-Space|Ctrl-Shift-Space|Alt-Space"};var c=function(e,t){this.all=e,this.filtered=e,this.filterText=t||"",this.exactMatch=!1};(function(){this.setFilter=function(e){if(e.length>this.filterText&&e.lastIndexOf(this.filterText,0)===0)var t=this.filtered;else var t=this.all;this.filterText=e,t=this.filterCompletions(t,this.filterText),t=t.sort(function(e,t){return t.exactMatch-e.exactMatch||t.$score-e.$score||(e.caption||e.value).localeCompare(t.caption||t.value)});var n=null;t=t.filter(function(e){var t=e.snippet||e.caption||e.value;return t===n?!1:(n=t,!0)}),this.filtered=t},this.filterCompletions=function(e,t){var n=[],r=t.toUpperCase(),i=t.toLowerCase();e:for(var s=0,o;o=e[s];s++){var u=o.caption||o.value||o.snippet;if(!u)continue;var a=-1,f=0,l=0,c,h;if(this.exactMatch){if(t!==u.substr(0,t.length))continue e}else{var p=u.toLowerCase().indexOf(i);if(p>-1)l=p;else for(var d=0;d<t.length;d++){var v=u.indexOf(i[d],a+1),m=u.indexOf(r[d],a+1);c=v>=0?m<0||v<m?v:m:m;if(c<0)continue e;h=c-a-1,h>0&&(a===-1&&(l+=10),l+=h,f|=1<<d),a=c}}o.matchMask=f,o.exactMatch=l?0:1,o.$score=(o.score||0)-l,n.push(o)}return n}}).call(c.prototype),t.Autocomplete=l,t.FilteredList=c}),ace.define("ace/autocomplete/text_completer",["require","exports","module","ace/range"],function(e,t,n){function s(e,t){var n=e.getTextRange(r.fromPoints({row:0,column:0},t));return n.split(i).length-1}function o(e,t){var n=s(e,t),r=e.getValue().split(i),o=Object.create(null),u=r[n];return r.forEach(function(e,t){if(!e||e===u)return;var i=Math.abs(n-t),s=r.length-i;o[e]?o[e]=Math.max(s,o[e]):o[e]=s}),o}var r=e("../range").Range,i=/[^a-zA-Z_0-9\$\-\u00C0-\u1FFF\u2C00-\uD7FF\w]+/;t.getCompletions=function(e,t,n,r,i){var s=o(t,n),u=Object.keys(s);i(null,u.map(function(e){return{caption:e,value:e,score:s[e],meta:"local"}}))}}),ace.define("ace/ext/language_tools",["require","exports","module","ace/snippets","ace/autocomplete","ace/config","ace/lib/lang","ace/autocomplete/util","ace/autocomplete/text_completer","ace/editor","ace/config"],function(e,t,n){"use strict";var r=e("../snippets").snippetManager,i=e("../autocomplete").Autocomplete,s=e("../config"),o=e("../lib/lang"),u=e("../autocomplete/util"),a=e("../autocomplete/text_completer"),f={getCompletions:function(e,t,n,r,i){if(t.$mode.completer)return t.$mode.completer.getCompletions(e,t,n,r,i);var s=e.session.getState(n.row),o=t.$mode.getCompletions(s,t,n,r);i(null,o)}},l={getCompletions:function(e,t,n,i,s){var o=[],u=t.getTokenAt(n.row,n.column);u&&u.type.match(/(tag-name|tag-open|tag-whitespace|attribute-name|attribute-value)\.xml$/)?o.push("html-tag"):o=r.getActiveScopes(e);var a=r.snippetMap,f=[];o.forEach(function(e){var t=a[e]||[];for(var n=t.length;n--;){var r=t[n],i=r.name||r.tabTrigger;if(!i)continue;f.push({caption:i,snippet:r.content,meta:r.tabTrigger&&!r.name?r.tabTrigger+"\u21e5 ":"snippet",type:"snippet"})}},this),s(null,f)},getDocTooltip:function(e){e.type=="snippet"&&!e.docHTML&&(e.docHTML=["<b>",o.escapeHTML(e.caption),"</b>","<hr></hr>",o.escapeHTML(e.snippet)].join(""))}},c=[l,a,f];t.setCompleters=function(e){c.length=0,e&&c.push.apply(c,e)},t.addCompleter=function(e){c.push(e)},t.textCompleter=a,t.keyWordCompleter=f,t.snippetCompleter=l;var h={name:"expandSnippet",exec:function(e){return r.expandWithTab(e)},bindKey:"Tab"},p=function(e,t){d(t.session.$mode)},d=function(e){typeof e=="string"&&(e=s.$modes[e]);if(!e)return;r.files||(r.files={}),v(e.$id,e.snippetFileId),e.modes&&e.modes.forEach(d)},v=function(e,t){if(!t||!e||r.files[e])return;r.files[e]={},s.loadModule(t,function(t){if(!t)return;r.files[e]=t,!t.snippets&&t.snippetText&&(t.snippets=r.parseSnippetFile(t.snippetText)),r.register(t.snippets||[],t.scope),t.includeScopes&&(r.snippetMap[t.scope].includeScopes=t.includeScopes,t.includeScopes.forEach(function(e){d("ace/mode/"+e)}))})},m=function(e){var t=e.editor,n=t.completer&&t.completer.activated;if(e.command.name==="backspace")n&&!u.getCompletionPrefix(t)&&t.completer.detach();else if(e.command.name==="insertstring"){var r=u.getCompletionPrefix(t);if(r&&!n){var s=i.for(t);s.autoInsert=!1,s.showPopup(t)}}},g=e("../editor").Editor;e("../config").defineOptions(g.prototype,"editor",{enableBasicAutocompletion:{set:function(e){e?(this.completers||(this.completers=Array.isArray(e)?e:c),this.commands.addCommand(i.startCommand)):this.commands.removeCommand(i.startCommand)},value:!1},enableLiveAutocompletion:{set:function(e){e?(this.completers||(this.completers=Array.isArray(e)?e:c),this.commands.on("afterExec",m)):this.commands.removeListener("afterExec",m)},value:!1},enableSnippets:{set:function(e){e?(this.commands.addCommand(h),this.on("changeMode",p),p(null,this)):(this.commands.removeCommand(h),this.off("changeMode",p))},value:!1}})}); (function() { + ace.require(["ace/ext/language_tools"], function(m) { + if (typeof module == "object" && typeof exports == "object" && module) { + module.exports = m; + } + }); + })(); + \ No newline at end of file diff --git a/software/dashboard/grafana/grafana.db b/software/dashboard/grafana/grafana.db index 2c00d4c..109d227 100644 Binary files a/software/dashboard/grafana/grafana.db and b/software/dashboard/grafana/grafana.db differ diff --git a/software/firmware/shelly-monitor/README.md b/software/firmware/shelly-monitor/README.md index 953b922..48b75a8 100644 --- a/software/firmware/shelly-monitor/README.md +++ b/software/firmware/shelly-monitor/README.md @@ -86,7 +86,7 @@ The message is fed into a filter function to only store usefull information: return { payload: { power: Number(msg.payload.ENERGY.Power), - volate: Number(msg.payload.ENERGY.Voltage), + voltage: Number(msg.payload.ENERGY.Voltage), current: Number(msg.payload.ENERGY.Current) } }; @@ -106,7 +106,7 @@ The query created by Data Explorer looks like that: from(bucket: "shelly") |> range(start: v.timeRangeStart, stop: v.timeRangeStop) |> filter(fn: (r) => r["_measurement"] == "msg") - |> filter(fn: (r) => r["_field"] == "power" or r["_field"] == "volate" or r["_field"] == "current") + |> filter(fn: (r) => r["_field"] == "power" or r["_field"] == "voltage" or r["_field"] == "current") |> aggregateWindow(every: v.windowPeriod, fn: mean, createEmpty: false) |> yield(name: "mean") ``` diff --git a/software/firmware/shelly-monitor/docs/images/grafana.png b/software/firmware/shelly-monitor/docs/images/grafana.png index 3fd5b44..1002f91 100644 Binary files a/software/firmware/shelly-monitor/docs/images/grafana.png and b/software/firmware/shelly-monitor/docs/images/grafana.png differ diff --git a/software/flow/.flows.json.backup b/software/flow/.flows.json.backup index 4430f4e..da5fafd 100644 --- a/software/flow/.flows.json.backup +++ b/software/flow/.flows.json.backup @@ -419,7 +419,7 @@ "type": "function", "z": "f6f2187d.f17ca8", "name": "shelly2Influx", - "func": "return {\n payload: {\n power: Number(msg.payload.ENERGY.Power),\n volate: Number(msg.payload.ENERGY.Voltage),\n current: Number(msg.payload.ENERBY.Current)\n }\n};\n", + "func": "return {\n payload: {\n power: Number(msg.payload.ENERGY.Power),\n volate: Number(msg.payload.ENERGY.Voltage),\n current: Number(msg.payload.ENERGY.Current)\n }\n};\n", "outputs": 1, "noerr": 0, "initialize": "", diff --git a/software/flow/flows.json b/software/flow/flows.json index da5fafd..0a4c037 100644 --- a/software/flow/flows.json +++ b/software/flow/flows.json @@ -419,7 +419,7 @@ "type": "function", "z": "f6f2187d.f17ca8", "name": "shelly2Influx", - "func": "return {\n payload: {\n power: Number(msg.payload.ENERGY.Power),\n volate: Number(msg.payload.ENERGY.Voltage),\n current: Number(msg.payload.ENERGY.Current)\n }\n};\n", + "func": "return {\n payload: {\n power: Number(msg.payload.ENERGY.Power),\n voltage: Number(msg.payload.ENERGY.Voltage),\n current: Number(msg.payload.ENERGY.Current)\n }\n};\n", "outputs": 1, "noerr": 0, "initialize": "",