commit bb2f8dbea1df9f3b6991d49042221eccb3158bec
Author: alex
Date: Thu May 9 22:40:37 2024 +0200
init
diff --git a/builder/Dockerfile b/builder/Dockerfile
new file mode 100644
index 0000000..2c2dc0b
--- /dev/null
+++ b/builder/Dockerfile
@@ -0,0 +1,3 @@
+FROM octoprint/octoprint
+
+COPY octoprint /octoprint
diff --git a/builder/docker-compose.yml b/builder/docker-compose.yml
new file mode 100644
index 0000000..dd8406a
--- /dev/null
+++ b/builder/docker-compose.yml
@@ -0,0 +1,16 @@
+version: '2.4'
+
+services:
+ octoprint_server_test2:
+ container_name: octoprint-server-test2
+ build:
+ context: .
+ dockerfile: Dockerfile
+ restart: unless-stopped
+ ports:
+ - 127.0.0.1:50138:80
+ volumes:
+ - octoprint-server-test2:/octoprint
+
+volumes:
+ octoprint-server-test2:
diff --git a/builder/octoprint/octoprint/config.backup b/builder/octoprint/octoprint/config.backup
new file mode 100644
index 0000000..eb07d93
--- /dev/null
+++ b/builder/octoprint/octoprint/config.backup
@@ -0,0 +1,74 @@
+accessControl:
+ userfile: /octoprint/octoprint/users.yaml
+api:
+ key: 91EEB0475E5844059C3CBC0C18E37B63
+appearance:
+ color: white
+ name: My Template
+plugins:
+ announcements:
+ _config_version: 1
+ channels:
+ _blog:
+ read_until: 1711358100
+ _important:
+ read_until: 1698310200
+ _octopi:
+ read_until: 1684929600
+ _plugins:
+ read_until: 1714176000
+ _releases:
+ read_until: 1713957300
+ bambu_printer:
+ access_code: '1234'
+ device_type: P1P
+ host: 127.0.0.1
+ serial: '1234'
+ classicwebcam:
+ _config_version: 1
+ snapshot: http://localhost:8080/?action=snapshot
+ stream: /webcam/?action=stream
+ discovery:
+ upnpUuid: f208a345-7fab-4b7b-8922-a12766395145
+ errortracking:
+ unique_id: 2074483d-5218-452c-992f-07225b0f7efd
+ gcodeviewer:
+ _config_version: 1
+ softwareupdate:
+ _config_version: 9
+ tracking:
+ enabled: false
+ unique_id: 2aa3b43d-6962-431d-a80b-818b7230d03e
+ virtual_printer:
+ _config_version: 1
+printerProfiles:
+ default: _default
+serial:
+ autoconnect: true
+server:
+ commands:
+ serverRestartCommand: s6-svc -r /var/run/s6/services/octoprint
+ firstRun: false
+ onlineCheck:
+ enabled: false
+ pluginBlacklist:
+ enabled: true
+ secretKey: xZHLyQYSTO24lFaEE7yHGoMKiYcJWE46
+ seenWizards:
+ backup: null
+ classicwebcam: 1
+ corewizard: 4
+ file_check: 1
+ tracking: null
+temperature:
+ profiles:
+ - bed: 100
+ chamber: null
+ extruder: 210
+ name: ABS
+ - bed: 60
+ chamber: null
+ extruder: 180
+ name: PLA
+webcam:
+ ffmpeg: /usr/bin/ffmpeg
diff --git a/builder/octoprint/octoprint/config.yaml b/builder/octoprint/octoprint/config.yaml
new file mode 100644
index 0000000..6c3ed02
--- /dev/null
+++ b/builder/octoprint/octoprint/config.yaml
@@ -0,0 +1,74 @@
+accessControl:
+ userfile: /octoprint/octoprint/users.yaml
+api:
+ key: 91EEB0475E5844059C3CBC0C18E37B63
+appearance:
+ color: white
+ name: My A2
+plugins:
+ announcements:
+ _config_version: 1
+ channels:
+ _blog:
+ read_until: 1711358100
+ _important:
+ read_until: 1698310200
+ _octopi:
+ read_until: 1684929600
+ _plugins:
+ read_until: 1714176000
+ _releases:
+ read_until: 1713957300
+ bambu_printer:
+ access_code: '1234'
+ device_type: P1P
+ host: 127.0.0.1
+ serial: '1234'
+ classicwebcam:
+ _config_version: 1
+ snapshot: http://localhost:8080/?action=snapshot
+ stream: /webcam/?action=stream
+ discovery:
+ upnpUuid: f208a345-7fab-4b7b-8922-a12766395145
+ errortracking:
+ unique_id: 2074483d-5218-452c-992f-07225b0f7efd
+ gcodeviewer:
+ _config_version: 1
+ softwareupdate:
+ _config_version: 9
+ tracking:
+ enabled: false
+ unique_id: 2aa3b43d-6962-431d-a80b-818b7230d03e
+ virtual_printer:
+ _config_version: 1
+printerProfiles:
+ default: _default
+serial:
+ autoconnect: true
+server:
+ commands:
+ serverRestartCommand: s6-svc -r /var/run/s6/services/octoprint
+ firstRun: false
+ onlineCheck:
+ enabled: false
+ pluginBlacklist:
+ enabled: true
+ secretKey: xZHLyQYSTO24lFaEE7yHGoMKiYcJWE46
+ seenWizards:
+ backup: null
+ classicwebcam: 1
+ corewizard: 4
+ file_check: 1
+ tracking: null
+temperature:
+ profiles:
+ - bed: 100
+ chamber: null
+ extruder: 210
+ name: ABS
+ - bed: 60
+ chamber: null
+ extruder: 180
+ name: PLA
+webcam:
+ ffmpeg: /usr/bin/ffmpeg
diff --git a/builder/octoprint/octoprint/data/achievements/2024.json b/builder/octoprint/octoprint/data/achievements/2024.json
new file mode 100644
index 0000000..afbdccc
--- /dev/null
+++ b/builder/octoprint/octoprint/data/achievements/2024.json
@@ -0,0 +1,22 @@
+{
+ "last_version": "1.10.0",
+ "seen_versions": 1,
+ "server_starts": 8,
+ "prints_started": 0,
+ "prints_cancelled": 0,
+ "prints_errored": 0,
+ "prints_finished": 0,
+ "prints_started_per_weekday": {},
+ "print_duration_total": 0.0,
+ "print_duration_cancelled": 0.0,
+ "print_duration_errored": 0.0,
+ "print_duration_finished": 0.0,
+ "longest_print_duration": 0.0,
+ "longest_print_date": 0,
+ "files_uploaded": 0,
+ "files_deleted": 0,
+ "plugins_installed": 0,
+ "plugins_uninstalled": 0,
+ "most_plugins": 20,
+ "achievements": 1
+}
\ No newline at end of file
diff --git a/builder/octoprint/octoprint/data/achievements/data.json b/builder/octoprint/octoprint/data/achievements/data.json
new file mode 100644
index 0000000..d604fe0
--- /dev/null
+++ b/builder/octoprint/octoprint/data/achievements/data.json
@@ -0,0 +1,39 @@
+{
+ "stats": {
+ "last_version": "1.10.0",
+ "seen_versions": 1,
+ "server_starts": 8,
+ "prints_started": 0,
+ "prints_cancelled": 0,
+ "prints_errored": 0,
+ "prints_finished": 0,
+ "prints_started_per_weekday": {},
+ "print_duration_total": 0.0,
+ "print_duration_cancelled": 0.0,
+ "print_duration_errored": 0.0,
+ "print_duration_finished": 0.0,
+ "longest_print_duration": 0.0,
+ "longest_print_date": 0,
+ "files_uploaded": 0,
+ "files_deleted": 0,
+ "plugins_installed": 0,
+ "plugins_uninstalled": 0,
+ "most_plugins": 20,
+ "created": 1715245186,
+ "created_version": "1.10.0"
+ },
+ "achievements": {
+ "the_wizard": 1715245188
+ },
+ "state": {
+ "date_last_print": "",
+ "prints_today": 0,
+ "date_last_cancelled_print": "",
+ "prints_cancelled_today": 0,
+ "consecutive_prints_cancelled_today": 0,
+ "file_last_print": "",
+ "consecutive_prints_of_same_file": 0,
+ "date_last_weekend_print": "",
+ "consecutive_weekend_prints": 0
+ }
+}
\ No newline at end of file
diff --git a/builder/octoprint/octoprint/data/announcements/_blog.cache b/builder/octoprint/octoprint/data/announcements/_blog.cache
new file mode 100644
index 0000000..c1186f0
Binary files /dev/null and b/builder/octoprint/octoprint/data/announcements/_blog.cache differ
diff --git a/builder/octoprint/octoprint/data/announcements/_important.cache b/builder/octoprint/octoprint/data/announcements/_important.cache
new file mode 100644
index 0000000..12f0440
Binary files /dev/null and b/builder/octoprint/octoprint/data/announcements/_important.cache differ
diff --git a/builder/octoprint/octoprint/data/announcements/_octopi.cache b/builder/octoprint/octoprint/data/announcements/_octopi.cache
new file mode 100644
index 0000000..75987cc
Binary files /dev/null and b/builder/octoprint/octoprint/data/announcements/_octopi.cache differ
diff --git a/builder/octoprint/octoprint/data/announcements/_plugins.cache b/builder/octoprint/octoprint/data/announcements/_plugins.cache
new file mode 100644
index 0000000..97b7c9e
Binary files /dev/null and b/builder/octoprint/octoprint/data/announcements/_plugins.cache differ
diff --git a/builder/octoprint/octoprint/data/announcements/_releases.cache b/builder/octoprint/octoprint/data/announcements/_releases.cache
new file mode 100644
index 0000000..27a39bf
Binary files /dev/null and b/builder/octoprint/octoprint/data/announcements/_releases.cache differ
diff --git a/builder/octoprint/octoprint/data/file_check/last_check_info.json b/builder/octoprint/octoprint/data/file_check/last_check_info.json
new file mode 100644
index 0000000..244f31f
--- /dev/null
+++ b/builder/octoprint/octoprint/data/file_check/last_check_info.json
@@ -0,0 +1 @@
+{"version": 1, "timestamp": 1715248737}
\ No newline at end of file
diff --git a/builder/octoprint/octoprint/data/plugin_blacklist.yaml b/builder/octoprint/octoprint/data/plugin_blacklist.yaml
new file mode 100644
index 0000000..69fb118
--- /dev/null
+++ b/builder/octoprint/octoprint/data/plugin_blacklist.yaml
@@ -0,0 +1,5 @@
+- roomtemp
+- - GcodeEditor
+ - '>=0.1.1,<=0.2.8'
+- - gcodeleveling
+ - '>=0.1.0,<=0.1.1'
diff --git a/builder/octoprint/octoprint/data/pluginmanager/notices.json b/builder/octoprint/octoprint/data/pluginmanager/notices.json
new file mode 100644
index 0000000..f314dcf
--- /dev/null
+++ b/builder/octoprint/octoprint/data/pluginmanager/notices.json
@@ -0,0 +1 @@
+[{"date": "2017-05-16 10:30:00 +0000", "link": "https://github.com/OctoPrint/OctoPrint-Autoselect/releases/tag/0.2.0", "plugin": "autoselect", "text": "Version 0.2.0 of this plugin is available, but your version 0.1.0 does not yet support updating automatically. Please re-install the plugin from the repository to update. More details can be found at the \"Read more...\" link below.", "versions": ["0.1.0"]}, {"date": "2020-04-21 08:30:00 +0000", "link": "https://github.com/OllisGit/OctoPrint-DisplayLayerProgress/issues/124", "plugin": "DisplayLayerProgress", "text": "Some users are experiencing layer shifts that seem to be caused by this plugin. If this affects you, please disable it for now and follow the discussion found at the \"Read more...\" link below.", "versions": ["1.17.0", "1.18.0", "1.19.0", "1.19.1", "1.20.0"]}, {"date": "2020-05-04 13:00:00 +0000", "link": "https://github.com/tpmullan/OctoPrint-DetailedProgress/releases/tag/0.2.3", "plugin": "detailedprogress", "text": "Version 0.2.3 of this plugin is available from a new maintainer, but your version still looks for updates at the repository of the old maintainer. Please re-install the plugin from the repository to update. The release notes of the version by the new maintainer can be found at the \"Read more...\" link below.", "versions": ["0.1.0", "0.1.1", "0.1.2", "0.1.3", "0.1.4"]}, {"date": "2020-05-18 14:50:00 +0000", "link": "https://github.com/OctoPrint/plugins.octoprint.org/issues/466", "plugin": "octoprint_eta", "text": "This plugin seems to have been abandoned by its original author, but a new maintainer has stepped up to maintain a fork which you might want to manually install. If so, please uninstall \"OctoPrint-Display-ETA\" and then install \"OctoPrint-Display-ETA\" from the repository."}, {"date": "2020-06-15 09:45:00 +0000", "link": "https://github.com/OctoPrint/OctoPrint-CommandSplitter/releases/tag/0.2.2", "plugin": "commandsplitter", "text": "Version 0.2.2 of this plugin is available, but your version does not yet support updating automatically. Please re-install the plugin from the repository to update. More details can be found at the \"Read more...\" link below.", "versions": ["0.1.0", "0.2.0", "0.2.1"]}, {"date": "2020-09-14 08:45:00 +0000", "link": "https://github.com/OllisGit/OctoPrint-FilamentManager/releases/tag/1.6.0", "plugin": "filamentmanager", "pluginversions": ["<1.6.0"], "text": "Version 1.6.0 of this plugin is available from a new maintainer, but your version still looks for updates at the repository of the old maintainer. Please re-install the plugin from the repository to update, keeping your settings. The release notes of the version by the new maintainer can be found at the \"Read more...\" link below.", "versions": ["0.1.0", "0.1.1", "0.2.0", "0.2.1", "0.2.2", "0.3.0", "0.4.0", "0.4.1", "0.5.0", "0.5.1", "0.5.2", "0.5.3"]}, {"date": "2020-09-15 04:00:00 +0000", "link": "https://github.com/AliceGrey/OctoprintKlipperPlugin/releases/tag/0.3.1", "plugin": "klipper", "pluginversions": ["<0.3.1"], "text": "Version 0.3.1 of this plugin is available from a new maintainer, but your version still looks for updates at the repository of the old maintainer. Please re-install the plugin from the repository to update, keeping your settings. The release notes of the version by the new maintainer can be found at the \"Read more...\" link below.", "versions": ["0.1.5", "0.2.0", "0.2.1", "0.2.2", "0.2.3", "0.2.4", "0.2.5"]}, {"date": "2020-09-22 08:45:00 +0000", "link": "https://github.com/OllisGit/OctoPrint-CostEstimation/releases/tag/3.0.0", "plugin": "costestimation", "pluginversions": ["<3.0.0"], "text": "Version 3.0.0 of this plugin is available from a new maintainer, but your version still looks for updates at the repository of the old maintainer. Please re-install the plugin from the repository to update, keeping your settings. The release notes of the version by the new maintainer can be found at the \"Read more...\" link below.", "versions": ["0.3.0", "0.4.0", "1.0.0", "1.1.0", "2.0.0", "2.0.1", "2.1.0", "2.1.1", "2.1.2", "2.1.3"]}, {"date": "2020-09-23 15:15:00 +0000", "plugin": "ender3v2tempfix", "text": "Version 0.0.4 of this plugin is available, but due to a name change the automatic update needs a bit of extra help. Please uninstall the plugin and then just reinstall it from the plugin repository.", "versions": ["0.0.1", "0.0.2", "0.0.3"]}, {"date": "2020-09-27 18:00:00 +0000", "link": "https://github.com/ssorgatem/Octoprint-Filament-Reloaded/releases/tag/1.3.0", "plugin": "filamentreload", "pluginversions": ["<1.3.0"], "text": "Version 1.3.0 of this plugin is available from a new maintainer, but your version still looks for updates at the repository of the old maintainer. Please re-install the plugin from the repository to update, keeping your settings. The release notes of the version by the new maintainer can be found at the \"Read more...\" link below.", "versions": ["1.0.0", "1.1.0", "1.1.1", "1.2.0"]}, {"date": "2020-10-07 12:00:00 +0000", "link": "https://github.com/cp2004/OctoPrint-EEPROM-Marlin/releases/tag/2.0.0", "plugin": "eeprom_marlin", "pluginversions": ["<2.0.0"], "text": "Version 2.0.0 of this plugin is available from a new maintainer, but your version still looks for updates at the repository of the old maintainer. Please uninstall the old plugin from the plugin manager, then reinstall from the plugin repository to update it. The release notes of the version by the new maintainer can be found at the \"Read more...\" link below.", "versions": ["0.1.0", "1.0.0", "1.0.1", "1.0.2", "1.0.3", "1.0.4", "1.2", "1.2.1", "1.2.2"]}, {"date": "2020-10-19 12:00:00 +0000", "link": "https://github.com/AlexVerrico/octoprint-stats/releases/tag/3.0.0", "plugin": "stats", "pluginversions": ["<3.0.0"], "text": "Version 3.0.0 of this plugin is available from a new maintainer, but your version still looks for updates at the repository of the old maintainer. Please uninstall the old plugin from the plugin manager, then reinstall from the plugin repository to update it. The release notes of the version by the new maintainer can be found at the \"Read more...\" link below.", "versions": ["1.0.0", "2.0.0", "2.0.2"]}, {"date": "2020-10-31 12:00:00 +0000", "link": "https://github.com/Zinc-OS/continuousprint/releases/tag/1.0.4", "plugin": "continuousprint", "pluginversions": ["<1.0.4"], "text": "Version 1.0.4 of this plugin is available from a new maintainer, but your version still looks for updates at the repository of the old maintainer. Please uninstall the old plugin from the plugin manager, then reinstall from the plugin repository to update it. The release notes of the version by the new maintainer can be found at the \"Read more...\" link below.", "versions": ["1.0.0", "1.0.1", "1.0.2", "1.0.3"]}, {"date": "2020-12-02 15:00:00 +0000", "link": "https://github.com/Willmac16/OctoPrint-GcodeLeveling/issues/5", "octoversions": [">=1.5.0"], "plugin": "gcodeleveling", "pluginversions": ["<=0.1.1"], "text": "There are reports of this plugin somehow breaking extrusion on OctoPrint 1.5.0. It has since been blacklisted until the author can look into this. If it is still active on your instance, please disable it and restart to avoid this problem.", "versions": ["0.1.0", "0.1.1"]}, {"date": "2020-12-08 12:00:00 +0000", "link": "https://github.com/gdombiak/OctoPrint-M73ETAOverride/releases/tag/1.0.4", "plugin": "m73etaoverride", "pluginversions": ["<1.0.2"], "text": "Version 1.0.4 of this plugin is available from a new maintainer, but your version still looks for updates at the repository of the old maintainer. Please uninstall the old plugin from the plugin manager, then reinstall from the plugin repository to update it. The release notes of the version by the new maintainer can be found at the \"Read more...\" link below.", "versions": ["1.0.0", "1.0.1"]}, {"date": "2020-12-09 12:00:00 +0000", "link": "https://github.com/gruvin/OctoPrint-WebcamTab/releases/tag/0.2.0", "plugin": "webcamtab", "pluginversions": ["<0.2.0"], "text": "Version 0.2.0 of this plugin is available from a new maintainer, but your version still looks for updates at the repository of the old maintainer. Please uninstall the old plugin from the plugin manager, then reinstall from the plugin repository to update it. The release notes of the version by the new maintainer can be found at the \"Read more...\" link below.", "versions": ["0.1.0", "0.1.1", "0.1.2"]}, {"date": "2021-02-10 12:00:00 +0000", "link": "https://github.com/tkoecker/OctoPrint-Mmu2filamentselect/releases/tag/1.0.3", "plugin": "mmu2filamentselect", "pluginversions": ["<1.0.3"], "text": "Version 1.0.3 of this plugin is available from a new maintainer, but your version still looks for updates at the repository of the old maintainer. Please uninstall the old plugin from the plugin manager, then reinstall from the plugin repository to update it. The release notes of the version by the new maintainer can be found at the \"Read more...\" link below.", "versions": ["1.0.0", "1.0.1", "1.0.2"]}, {"date": "2021-02-27 17:00:00 +0000", "link": "https://github.com/mkevenaar/OctoPrint-Slack/releases/tag/0.2.4", "plugin": "slack", "pluginversions": ["<0.2.4"], "text": "Version 0.2.4 of this plugin is available from a new maintainer, but your version still looks for updates at the repository of the old maintainer. Please uninstall the old plugin from the plugin manager, then reinstall from the plugin repository to update it. The release notes of the version by the new maintainer can be found at the \"Read more...\" link below.", "versions": ["0.1", "0.2", "0.2.1", "0.2.2", "0.2.3"]}, {"date": "2021-08-19 22:30:00 +0000", "link": "https://www.thespaghettidetective.com/blog/2021/08/19/what-happened-last-night/", "plugin": "thespaghettidetective", "pluginversions": ["<1.7.3"], "text": "On August 19th 2021 a vulnerability was discovered with The Spaghetti Detective that allowed unauthorized access to OctoPrint instances. The issue was resolved shortly after being discovered, more information is available at the \"Read more...\" link below.", "versions": ["0.2.0", "0.2.1", "0.3.0", "0.5.0", "0.5.1", "0.5.2", "0.5.3", "0.5.4", "0.6.0", "0.6.1", "0.7.0", "0.7.1", "0.8.0", "0.8.1", "0.8.2", "0.8.3", "0.9.0", "0.9.1", "0.9.2", "0.9.3", "1.0.1", "1.0.2", "1.0.3", "1.0.4", "1.0.5", "1.0.6", "1.0.7", "1.0.8", "1.1.0", "1.1.1", "1.1.2", "1.1.3", "1.1.4", "1.1.5", "1.1.6", "1.2.0", "1.2.1", "1.2.2", "1.2.3", "1.2.4", "1.2.5", "1.3.0", "1.3.1", "1.3.2", "1.3.3", "1.3.4", "1.3.5", "1.4.0", "1.4.1", "1.4.2", "1.4.3", "1.4.4", "1.4.5", "1.4.6", "1.4.7", "1.5.0", "1.5.1", "1.5.2", "1.5.3", "1.6.0", "1.6.1", "1.6.2", "1.6.3", "1.6.4", "1.6.5", "1.6.6", "1.6.7", "1.7.0", "1.7.1", "1.7.2"]}, {"date": "2021-08-25 12:00:00 +0000", "link": "https://github.com/awenelo/OctoPrint-MetadataPreprocessor/releases/tag/0.2.1", "plugin": "metadatapreprocessor", "pluginversions": ["<0.2.1"], "text": "Version 0.2.1 of this plugin is available from a new maintainer, but your version still looks for updates at the repository of the old maintainer. Please uninstall the old plugin from the plugin manager, then reinstall from the plugin repository to update it. The release notes of the version by the new maintainer can be found at the \"Read more...\" link below.", "versions": ["0.1.0", "0.2.0"]}, {"date": "2021-10-12 16:00:00 +0000", "link": "https://github.com/vitormhenrique/OctoPrint-Enclosure/issues/435", "plugin": "enclosure", "text": "The maintainer of this plugin is looking for some help with maintaining it from the community. If this sounds like something you'd like to lend a hand in, please click on the \"Read more...\" link below."}, {"date": "2021-10-20 12:00:00 +0000", "link": "https://github.com/Andy-ch/OctoPrint-HeaterTimeout/releases/tag/0.0.4", "plugin": "HeaterTimeout", "pluginversions": ["<0.0.4"], "text": "Version 0.0.4 of this plugin is available from a new maintainer, but your version still looks for updates at the repository of the old maintainer. Please uninstall the old plugin from the plugin manager, then reinstall from the plugin repository to update it. The release notes of the version by the new maintainer can be found at the \"Read more...\" link below.", "versions": ["0.0.1", "0.0.2", "0.0.3"]}, {"date": "2022-01-27 12:00:00 +0000", "link": "https://github.com/Royrdan/Octoprint-Smart-Filament-Sensor/releases/tag/1.1.6", "plugin": "smartfilamentsensor", "pluginversions": ["<1.1.6"], "text": "Version 1.1.6 of this plugin is available from a new maintainer, but your version still looks for updates at the repository of the old maintainer. Please uninstall the old plugin from the plugin manager, then reinstall from the plugin repository to update it. The release notes of the version by the new maintainer can be found at the \"Read more...\" link below.", "versions": []}, {"date": "2022-03-12 12:00:00 +0000", "link": "https://github.com/smartin015/continuousprint/releases/tag/1.4.1", "plugin": "continuousprint", "pluginversions": ["<1.4.1"], "text": "Version 1.4.1 of this plugin is available from a new maintainer, but your version still looks for updates at the repository of the old maintainer. Please uninstall the old plugin from the plugin manager, then reinstall from the plugin repository to update it. The release notes of the version by the new maintainer can be found at the \"Read more...\" link below.", "versions": []}, {"date": "2022-03-24 12:00:00 +0000", "link": "https://github.com/egguy/OctoPrint-Prusa-Mini-ETA/releases/tag/0.1.4", "plugin": "prusa_mini_eta", "pluginversions": ["<0.1.4"], "text": "Version 0.1.4 of this plugin is available from a new maintainer, but your version still looks for updates at the repository of the old maintainer. Please uninstall the old plugin from the plugin manager, then reinstall from the plugin repository to update it. The release notes of the version by the new maintainer can be found at the \"Read more...\" link below.", "versions": []}, {"date": "2022-05-09 12:00:00 +0000", "link": "https://www.obico.io/docs/user-guides/move-from-tsd-to-obico-in-octoprint/", "plugin": "thespaghettidetective", "text": "This plugin is now succeeded by \"Obico for OctoPrint\". Please uninstall this plugin (keep data) in the plugin manager. Then install the \"Obico for OctoPrint\" plugin. Your settings in this plugin will be automatically migrated to the new plugin. To find out more, click the \"Read more...\" link below."}, {"date": "2022-10-01 12:00:00 +0000", "link": "https://github.com/gbonesso/OctoPrint-LEDStripControl/releases/tag/v0.3.8", "plugin": "ledstripcontrol", "pluginversions": ["<0.3.8"], "text": "Version 0.3.8 of this plugin is available from a new maintainer, but your version still looks for updates at the repository of the old maintainer. Please uninstall the old plugin from the plugin manager, then reinstall from the plugin repository to update it. The release notes of the version by the new maintainer can be found at the \"Read more...\" link below.", "versions": []}, {"date": "2022-12-11 18:00:00 +0000", "link": "https://github.com/larsjuhw/OctoPrint-SlicerSettingsParser/releases/tag/v3.0.1", "plugin": "SlicerSettingsParser", "pluginversions": ["<3.0.0"], "text": "Version 3.0.0 of this plugin is available from a new maintainer, but your version still looks for updates at the repository of the old maintainer. Please uninstall the old plugin from the plugin manager, then reinstall from the plugin repository to update it. The release notes of the version by the new maintainer can be found at the \"Read more...\" link below.", "versions": []}, {"date": "2022-12-25 12:00:00 +0000", "link": "https://github.com/synman/OctoPrint-SystemCommandEditor/releases/tag/1.0.0", "plugin": "systemcommandeditor", "pluginversions": ["<1.0.0"], "text": "Version 1.0.0+ of this plugin is available from a new maintainer, but your version still looks for updates at the repository of the old maintainer. Please uninstall the old plugin from the plugin manager, then reinstall from the plugin repository to update it. The release notes of the version by the new maintainer can be found at the \"Read more...\" link below.", "versions": []}, {"date": "2023-02-02 12:00:00 +0000", "link": "https://github.com/derekantrican/OctoPrint-Webhooks/releases/tag/3.1.3", "plugin": "webhooks", "pluginversions": ["<3.1.3"], "text": "Version 3.1.3+ of this plugin is available from a new maintainer, but your version still looks for updates at the repository of the old maintainer. Please uninstall the old plugin from the plugin manager, then reinstall from the plugin repository to update it. The release notes of the version by the new maintainer can be found at the \"Read more...\" link below.", "versions": []}, {"date": "2023-09-16 12:00:00 +0000", "link": "https://github.com/thomst08/OctoLight/releases/tag/v0.1.5", "plugin": "octolight", "pluginversions": ["<0.1.5"], "text": "Version 0.1.5 of this plugin is available from a new maintainer, but your version still looks for updates at the repository of the old maintainer. Please re-install the plugin from the repository to update and keeping your settings. The release notes of the version by the new maintainer can be found at the \"Read more...\" link below.", "versions": ["0.1.0", "0.1.1", "0.1.2", "0.1.3", "0.1.4"]}, {"date": "2023-11-27 12:00:00 +0000", "link": "https://github.com/dojohnso/OctoPrint-PrintJobHistory/releases/tag/1.17.1", "plugin": "PrintJobHistory", "pluginversions": ["<1.17.1"], "text": "Version 1.17.1 of this plugin is available from a new maintainer. The release notes of the version by the new maintainer can be found at the \"Read more...\" link below.", "versions": []}, {"date": "2023-12-06 12:00:00 +0000", "link": "https://github.com/dojohnso/OctoPrint-SpoolManager/releases/tag/1.7.1", "plugin": "SpoolManager", "pluginversions": ["<1.7.1"], "text": "Version 1.7.1 of this plugin is available from a new maintainer. The release notes of the version by the new maintainer can be found at the \"Read more...\" link below.", "versions": []}, {"date": "2021-07-25 23:34:43 +0000", "link": "https://github.com/OctoPrint/plugins.octoprint.org/issues/914", "plugin": "TemperatureFailsafe", "text": "This plugin has been abandoned by its maintainer and is looking for someone to adopt it. If you want to step in as the new maintainer please get in touch at the \"Read more...\" link below."}, {"date": "2021-11-14 14:36:01 +0000", "link": "https://github.com/OctoPrint/plugins.octoprint.org/issues/961", "plugin": "gslc", "text": "This plugin has been abandoned by its maintainer and is looking for someone to adopt it. If you want to step in as the new maintainer please get in touch at the \"Read more...\" link below."}, {"date": "2022-01-25 07:48:19 +0000", "link": "https://github.com/OctoPrint/plugins.octoprint.org/issues/995", "plugin": "filamentrevolutions", "text": "This plugin has been abandoned by its maintainer and is looking for someone to adopt it. If you want to step in as the new maintainer please get in touch at the \"Read more...\" link below."}, {"date": "2021-02-25 14:24:57 +0000", "link": "https://github.com/OctoPrint/plugins.octoprint.org/issues/800", "plugin": "autocalibration", "text": "This plugin has been abandoned by its maintainer and is looking for someone to adopt it. If you want to step in as the new maintainer please get in touch at the \"Read more...\" link below."}, {"date": "2020-09-07 20:42:41 +0000", "link": "https://github.com/OctoPrint/plugins.octoprint.org/issues/608", "plugin": "cost", "text": "This plugin has been abandoned by its maintainer and is looking for someone to adopt it. If you want to step in as the new maintainer please get in touch at the \"Read more...\" link below."}, {"date": "2022-06-28 08:04:28 +0000", "link": "https://github.com/OctoPrint/plugins.octoprint.org/issues/1082", "plugin": "Thingiverse", "text": "This plugin has been abandoned by its maintainer and is looking for someone to adopt it. If you want to step in as the new maintainer please get in touch at the \"Read more...\" link below."}, {"date": "2021-02-24 19:39:28 +0000", "link": "https://github.com/OctoPrint/plugins.octoprint.org/issues/796", "plugin": "filetypes", "text": "This plugin has been abandoned by its maintainer and is looking for someone to adopt it. If you want to step in as the new maintainer please get in touch at the \"Read more...\" link below."}, {"date": "2020-09-21 10:13:51 +0000", "link": "https://github.com/OctoPrint/plugins.octoprint.org/issues/624", "plugin": "growl", "text": "This plugin has been abandoned by its maintainer and is looking for someone to adopt it. If you want to step in as the new maintainer please get in touch at the \"Read more...\" link below."}, {"date": "2022-12-01 23:42:04 +0000", "link": "https://github.com/OctoPrint/plugins.octoprint.org/issues/1126", "plugin": "touchui", "text": "This plugin has been abandoned by its maintainer and is looking for someone to adopt it. If you want to step in as the new maintainer please get in touch at the \"Read more...\" link below."}, {"date": "2022-07-01 08:23:04 +0000", "link": "https://github.com/OctoPrint/plugins.octoprint.org/issues/1085", "plugin": "flashforge", "text": "This plugin has been abandoned by its maintainer and is looking for someone to adopt it. If you want to step in as the new maintainer please get in touch at the \"Read more...\" link below."}, {"date": "2020-12-15 19:28:43 +0000", "link": "https://github.com/OctoPrint/plugins.octoprint.org/issues/711", "plugin": "active_filters", "text": "This plugin has been abandoned by its maintainer and is looking for someone to adopt it. If you want to step in as the new maintainer please get in touch at the \"Read more...\" link below."}, {"date": "2021-07-20 08:10:10 +0000", "link": "https://github.com/OctoPrint/plugins.octoprint.org/issues/911", "plugin": "slicer", "text": "This plugin has been abandoned by its maintainer and is looking for someone to adopt it. If you want to step in as the new maintainer please get in touch at the \"Read more...\" link below."}]
\ No newline at end of file
diff --git a/builder/octoprint/octoprint/data/pluginmanager/plugins.json b/builder/octoprint/octoprint/data/pluginmanager/plugins.json
new file mode 100644
index 0000000..b2dffa2
--- /dev/null
+++ b/builder/octoprint/octoprint/data/pluginmanager/plugins.json
@@ -0,0 +1 @@
+[{"id": "mqtt", "published": "2015-04-11 00:00:00 +0000", "title": "MQTT", "description": "Adds support for subscribing and publishing to MQTT topics.", "archive": "https://github.com/OctoPrint/OctoPrint-MQTT/archive/master.zip", "author": "Franziska Kunsmann, Gina H\u00e4u\u00dfge", "homepage": "https://github.com/OctoPrint/OctoPrint-MQTT", "page": "https://plugins.octoprint.org/plugins/mqtt/", "compatibility": {"octoprint": ["1.3.5"], "os": [], "python": ">=2.7,<4"}, "license": "AGPLv3", "abandoned": false, "github": {"latest_release": {"name": "0.8.15", "date": "2024-02-10 18:26:17 +0000", "tag": "0.8.15"}, "releases": 23, "last_push": "2024-02-10 18:25:23 +0000", "stars": 152, "issues": {"open": 34, "closed": 77}}, "stats": {"instances_month": 3222, "install_events_month": 172, "instances_week": 2467, "install_events_week": 36}}, {"id": "growl", "published": "2015-04-14 00:00:00 +0000", "title": "Growl", "description": "Get Growl notifications from your OctoPrint installation.", "archive": "https://github.com/OctoPrint/OctoPrint-Growl/archive/master.zip", "author": "Gina H\u00e4u\u00dfge", "homepage": "https://github.com/OctoPrint/OctoPrint-Growl", "page": "https://plugins.octoprint.org/plugins/growl/", "compatibility": {"octoprint": [], "os": [], "python": ">=2.7,<3"}, "license": "AGPLv3", "image": "https://plugins.octoprint.org/assets/img/plugins/growl/notification.png", "abandoned": true, "github": {"latest_release": {"name": "0.1.1", "date": "2017-11-24 16:37:26 +0000", "tag": "0.1.1"}, "releases": 2, "last_push": "2020-07-01 13:36:07 +0000", "stars": 5, "issues": {"open": 1, "closed": 6}}, "stats": {"instances_month": 7, "install_events_month": 1, "instances_week": 6, "install_events_week": 0}}, {"id": "actiontrigger", "published": "2015-04-17 00:00:00 +0000", "title": "Action Trigger Plugin", "description": "Plugin for OctoPrint that handles serial commands sent out by the printer.", "archive": "https://github.com/Booli/OctoPrint-ActionTriggerPlugin/archive/master.zip", "author": "Pim Rutgers", "homepage": "https://github.com/Booli/OctoPrint-ActionTriggerPlugin", "page": "https://plugins.octoprint.org/plugins/actiontrigger/", "compatibility": {"octoprint": [], "os": [], "python": ">=2.7,<4"}, "license": "AGPLv3", "abandoned": false, "github": {"latest_release": {"name": "Python 3 compatibility release ", "date": "2020-06-28 09:19:33 +0000", "tag": "v1.1"}, "releases": 2, "last_push": "2020-09-14 09:38:22 +0000", "stars": 4, "issues": {"open": 0, "closed": 4}}, "stats": {"instances_month": 98, "install_events_month": 8, "instances_week": 75, "install_events_week": 1}}, {"id": "navbartemp", "published": "2015-04-17 00:00:00 +0000", "title": "Navbar Temp", "description": "Display temperatures on navbar", "archive": "https://github.com/imrahil/OctoPrint-NavbarTemp/archive/master.zip", "author": "Cosik, Jarek Szczepanski", "homepage": "https://github.com/imrahil/OctoPrint-NavbarTemp", "page": "https://plugins.octoprint.org/plugins/navbartemp/", "compatibility": {"octoprint": [], "os": ["linux", "windows", "macos", "freebsd"], "python": ">=2.7,<4"}, "license": "AGPLv3", "image": "https://github.com/imrahil/OctoPrint-NavbarTemp/blob/master/images/navbar.png?raw=true", "abandoned": false, "github": {"latest_release": {"name": "v 0.15", "date": "2022-08-15 14:21:53 +0000", "tag": "0.15"}, "releases": 11, "last_push": "2022-08-15 14:16:11 +0000", "stars": 43, "issues": {"open": 14, "closed": 57}}, "stats": {"instances_month": 11785, "install_events_month": 568, "instances_week": 8507, "install_events_week": 124}}, {"id": "gpx", "published": "2015-04-23 00:00:00 +0000", "title": "GPX", "description": "Use OctoPrint with s3g/x3g printers (like FlashForge and older MakerBot)", "archive": "https://markwal.github.io/octoprint-download/OctoPrint-GPX.tgz", "author": "Mark Walker", "homepage": "https://github.com/markwal/OctoPrint-GPX", "page": "https://plugins.octoprint.org/plugins/gpx/", "compatibility": {"octoprint": [], "os": ["linux"], "python": ">=2.7,<4"}, "license": "AGPLv3", "image": "https://markwal.github.io/octoprint-download/gpx.png", "abandoned": false, "github": {"latest_release": {"name": "2.6.8", "date": "2020-12-05 23:42:05 +0000", "tag": "2.6.8"}, "releases": 30, "last_push": "2020-12-01 05:58:38 +0000", "stars": 103, "issues": {"open": 35, "closed": 59}}, "stats": {"instances_month": 387, "install_events_month": 5, "instances_week": 276, "install_events_week": 1}}, {"id": "customControl", "published": "2015-04-26 00:00:00 +0000", "title": "Custom Control Editor", "description": "Makes custom controls editable via the settings dialog", "archive": "https://github.com/Salandora/octoprint-customControl/archive/master.zip", "author": "Marc Hannappel (Salandora)", "homepage": "https://github.com/Salandora/octoprint-customControl", "page": "https://plugins.octoprint.org/plugins/customControl/", "compatibility": {"octoprint": ["1.3.0"], "os": ["linux", "windows"], "python": ">=2.7,<4"}, "license": "AGPLv3", "image": "https://plugins.octoprint.org/assets/img/plugins/customControl/img4.png", "abandoned": false, "github": {"latest_release": {"name": "Version 0.2.2", "date": "2020-05-07 13:14:45 +0000", "tag": "0.2.2"}, "releases": 4, "last_push": "2020-05-03 22:33:36 +0000", "stars": 25, "issues": {"open": 24, "closed": 17}}, "stats": {"instances_month": 1657, "install_events_month": 78, "instances_week": 1236, "install_events_week": 17}}, {"id": "octoglow", "published": "2015-05-12 00:00:00 +0000", "title": "OctoGlow", "description": "Display OctoPrint status on a PiGlow board.", "archive": "https://github.com/dmalec/OctoPrint-OctoGlow/archive/master.zip", "author": "Dan Malec", "homepage": "https://github.com/dmalec/OctoPrint-OctoGlow", "page": "https://plugins.octoprint.org/plugins/octoglow/", "compatibility": {"octoprint": [], "os": [], "python": ">=2.7,<3"}, "license": "CC BY-NC-SA 4.0", "image": "https://plugins.octoprint.org/assets/img/plugins/octoglow/progress.png", "abandoned": false, "github": {"last_push": "2015-03-08 15:12:11 +0000", "stars": 6, "issues": {"open": 5, "closed": 0}}, "stats": {"instances_month": 0, "install_events_month": 0, "instances_week": 0, "install_events_week": 0}}, {"id": "snapstream", "published": "2015-05-22 00:00:00 +0000", "title": "SnapStream", "description": "Emulate webcam streaming by showing a sequence of snapshots", "archive": "https://github.com/markwal/OctoPrint-SnapStream/archive/master.zip", "author": "Mark Walker", "homepage": "https://github.com/markwal/OctoPrint-SnapStream", "page": "https://plugins.octoprint.org/plugins/snapstream/", "compatibility": {"octoprint": [], "os": [], "python": ">=2.7,<4"}, "license": "AGPLv3", "abandoned": false, "github": {"latest_release": {"name": "0.3", "date": "2021-02-17 05:43:59 +0000", "tag": "0.3"}, "releases": 2, "last_push": "2021-02-17 05:39:43 +0000", "stars": 6, "issues": {"open": 5, "closed": 3}}, "stats": {"instances_month": 134, "install_events_month": 22, "instances_week": 86, "install_events_week": 3}}, {"id": "systemcommandeditor", "published": "2015-06-03 00:00:00 +0000", "title": "System Command Editor", "description": "This plugin makes System Commands editable through the OctoPrint WebUI", "archive": "https://github.com/synman/OctoPrint-SystemCommandEditor/archive/master.zip", "author": "Shell M. Shrader, Marc Hannappel", "homepage": "https://github.com/synman/OctoPrint-SystemCommandEditor", "page": "https://plugins.octoprint.org/plugins/systemcommandeditor/", "compatibility": {"octoprint": ["1.3.0"], "os": ["linux", "windows"], "python": ">=2.7,<4"}, "license": "AGPLv3", "image": "https://plugins.octoprint.org/assets/img/plugins/systemCommandEditor/img1.png", "abandoned": false, "github": {"latest_release": {"name": "1.0.0", "date": "2022-12-26 02:54:09 +0000", "tag": "1.0.0"}, "releases": 1, "last_push": "2022-12-26 20:05:32 +0000", "stars": 5, "issues": {"open": 1, "closed": 1}}, "stats": {"instances_month": 929, "install_events_month": 50, "instances_week": 713, "install_events_week": 10}}, {"id": "editorcollection", "published": "2015-06-04 00:00:00 +0000", "title": "Editor Collection", "description": "This plugin is for putting Salandora's editor plugins onto one page", "archive": "https://github.com/Salandora/OctoPrint-EditorCollection/archive/master.zip", "author": "Marc Hannappel (Salandora)", "homepage": "https://github.com/Salandora/OctoPrint-EditorCollection", "page": "https://plugins.octoprint.org/plugins/editorcollection/", "compatibility": {"octoprint": [], "os": [], "python": ">=2.7,<4"}, "license": "AGPLv3", "image": "https://plugins.octoprint.org/assets/img/plugins/editorCollection/img1.png", "abandoned": false, "github": {"latest_release": {"name": "Editor Collection Version 0.1.2", "date": "2015-07-24 22:01:17 +0000", "tag": "0.1.2"}, "releases": 2, "last_push": "2020-05-22 17:19:11 +0000", "stars": 1, "issues": {"open": 1, "closed": 1}}, "stats": {"instances_month": 47, "install_events_month": 3, "instances_week": 41, "install_events_week": 1}}, {"id": "screensquish", "published": "2015-06-17 00:00:00 +0000", "title": "ScreenSquish", "description": "Scalable UI that does some old fashioned (v2) bootstrap responsive and some collapse etc.", "archive": "https://github.com/markwal/OctoPrint-ScreenSquish/archive/master.zip", "author": "Mark Walker", "homepage": "https://github.com/markwal/OctoPrint-ScreenSquish", "page": "https://plugins.octoprint.org/plugins/screensquish/", "compatibility": {"octoprint": [], "os": [], "python": ">=2.7,<4"}, "license": "AGPLv3", "image": "https://plugins.octoprint.org/assets/img/plugins/screensquish/squishsample.png", "abandoned": false, "github": {"latest_release": {"name": "0.4", "date": "2020-05-10 04:17:01 +0000", "tag": "0.4"}, "releases": 1, "last_push": "2020-05-10 04:14:50 +0000", "stars": 5, "issues": {"open": 2, "closed": 0}}, "stats": {"instances_month": 44, "install_events_month": 4, "instances_week": 30, "install_events_week": 2}}, {"id": "stlviewer", "published": "2015-06-20 00:00:00 +0000", "title": "STL Viewer", "description": "Simple stl viewer tab from uploaded files.", "archive": "https://github.com/jneilliii/Octoprint-STLViewer/archive/master.zip", "author": "jneilliii", "homepage": "https://github.com/jneilliii/Octoprint-STLViewer", "page": "https://plugins.octoprint.org/plugins/stlviewer/", "compatibility": {"octoprint": [], "os": [], "python": ">=2.7,<4"}, "license": "AGPLv3", "image": "https://plugins.octoprint.org/assets/img/plugins/stlviewer/screenshot.jpg", "abandoned": false, "github": {"latest_release": {"name": "0.4.2", "date": "2019-10-22 02:50:02 +0000", "tag": "0.4.2"}, "releases": 5, "last_push": "2024-01-14 15:59:05 +0000", "stars": 21, "issues": {"open": 1, "closed": 22}}, "stats": {"instances_month": 1833, "install_events_month": 187, "instances_week": 1208, "install_events_week": 32}}, {"id": "commandsplitter", "published": "2015-06-21 00:00:00 +0000", "title": "CommandSplitter", "description": "Splits multiple commands on one line in GCODE files into multiple lines", "archive": "https://github.com/OctoPrint/OctoPrint-CommandSplitter/archive/master.zip", "author": "Gina H\u00e4u\u00dfge", "homepage": "https://github.com/OctoPrint/OctoPrint-CommandSplitter", "page": "https://plugins.octoprint.org/plugins/commandsplitter/", "compatibility": {"octoprint": [], "os": [], "python": ">=2.7,<4"}, "license": "AGPLv3", "abandoned": false, "github": {"latest_release": {"name": "0.2.3 (stable)", "date": "2020-07-28 18:24:14 +0000", "tag": "0.2.3"}, "releases": 5, "last_push": "2022-06-23 08:52:19 +0000", "stars": 2, "issues": {"open": 1, "closed": 3}}, "stats": {"instances_month": 45, "install_events_month": 13, "instances_week": 27, "install_events_week": 0}}, {"id": "requestspinner", "published": "2015-06-21 00:00:00 +0000", "title": "RequestSpinner", "description": "Shows a little spinner in the web frontend when background requests are active", "archive": "https://github.com/OctoPrint/OctoPrint-RequestSpinner/archive/master.zip", "author": "Gina H\u00e4u\u00dfge", "homepage": "https://github.com/OctoPrint/OctoPrint-RequestSpinner", "page": "https://plugins.octoprint.org/plugins/requestspinner/", "compatibility": {"octoprint": [], "os": [], "python": ">=2.7,<4"}, "license": "AGPLv3", "image": "https://plugins.octoprint.org/assets/img/plugins/requestspinner/requestspinner.png", "abandoned": false, "github": {"latest_release": {"name": "0.2.0 (stable)", "date": "2020-04-24 17:19:24 +0000", "tag": "0.2.0"}, "releases": 3, "last_push": "2020-04-24 17:17:58 +0000", "stars": 2, "issues": {"open": 0, "closed": 1}}, "stats": {"instances_month": 147, "install_events_month": 3, "instances_week": 124, "install_events_week": 1}}, {"id": "autoselect", "published": "2015-06-27 00:00:00 +0000", "title": "Autoselect", "description": "Automatically selects freshly uploaded files for printing if no print job is currently active.", "archive": "https://github.com/OctoPrint/OctoPrint-Autoselect/archive/master.zip", "author": "Jubaleth, Gina H\u00e4u\u00dfge", "homepage": "https://github.com/OctoPrint/OctoPrint-Autoselect", "page": "https://plugins.octoprint.org/plugins/autoselect/", "compatibility": {"octoprint": [], "os": [], "python": ">=2.7,<4"}, "license": "AGPLv3", "abandoned": false, "github": {"latest_release": {"name": "0.3.0 (stable)", "date": "2020-05-02 22:37:45 +0000", "tag": "0.3.0"}, "releases": 3, "last_push": "2020-05-02 22:35:41 +0000", "stars": 9, "issues": {"open": 4, "closed": 6}}, "stats": {"instances_month": 927, "install_events_month": 27, "instances_week": 717, "install_events_week": 1}}, {"id": "status_line", "published": "2015-07-04 00:00:00 +0000", "title": "StatusLine", "description": "Display M117 (Display Message) in the SideBar", "archive": "https://github.com/AmedeeBulle/StatusLine/archive/master.zip", "author": "Philippe Vanhaesendonck", "homepage": "https://github.com/AmedeeBulle/StatusLine", "page": "https://plugins.octoprint.org/plugins/status_line/", "compatibility": {"octoprint": ["1.2.0"], "os": [], "python": ">=2.7,<4"}, "license": "AGPLv3", "image": "https://raw.githubusercontent.com/AmedeeBulle/StatusLine/master/status_line.png", "abandoned": false, "github": {"last_push": "2020-06-17 09:19:09 +0000", "stars": 6, "issues": {"open": 1, "closed": 1}}, "stats": {"instances_month": 175, "install_events_month": 9, "instances_week": 124, "install_events_week": 1}}, {"id": "yamlpatcher", "published": "2015-07-07 00:00:00 +0000", "title": "Yamlpatcher", "description": "Allows patching up config.yaml through the web interface", "archive": "https://github.com/OctoPrint/OctoPrint-Yamlpatcher/archive/master.zip", "author": "Gina H\u00e4u\u00dfge", "homepage": "https://github.com/OctoPrint/OctoPrint-Yamlpatcher", "page": "https://plugins.octoprint.org/plugins/yamlpatcher/", "compatibility": {"octoprint": [], "os": [], "python": ">=2.7,<3"}, "license": "AGPLv3", "image": "http://i.imgur.com/Xs1xGHu.png", "abandoned": false, "github": {"latest_release": {"name": "0.1.1 (stable)", "date": "2016-01-19 09:09:11 +0000", "tag": "0.1.1"}, "releases": 2, "last_push": "2019-08-01 12:32:55 +0000", "stars": 1, "issues": {"open": 0, "closed": 0}}, "stats": {"instances_month": 23, "install_events_month": 3, "instances_week": 17, "install_events_week": 0}}, {"id": "octobullet", "published": "2015-07-23 00:00:00 +0000", "title": "Pushbullet", "description": "Pushes notifications about finished print jobs via Pushbullet", "archive": "https://github.com/OctoPrint/OctoPrint-Pushbullet/archive/master.zip", "author": "Gina H\u00e4u\u00dfge", "homepage": "https://github.com/OctoPrint/OctoPrint-Pushbullet", "page": "https://plugins.octoprint.org/plugins/octobullet/", "compatibility": {"octoprint": ["1.2.4"], "os": [], "python": ">=2.7,<4"}, "license": "AGPLv3", "image": "https://plugins.octoprint.org/assets/img/plugins/octobullet/example_push.png", "abandoned": false, "github": {"latest_release": {"name": "0.1.14", "date": "2020-10-17 13:53:25 +0000", "tag": "0.1.14"}, "releases": 13, "last_push": "2020-10-17 13:50:18 +0000", "stars": 13, "issues": {"open": 8, "closed": 20}}, "stats": {"instances_month": 227, "install_events_month": 9, "instances_week": 174, "install_events_week": 0}}, {"id": "eeprom_repetier", "published": "2015-07-28 00:00:00 +0000", "title": "EEPROM Repetier Editor", "description": "Makes it possible to change the EEPROM values of Repetier Firmware through OctoPrint", "archive": "https://github.com/Salandora/OctoPrint-EEprom-Repetier/archive/master.zip", "author": "Marc Hannappel (Salandora)", "homepage": "https://github.com/Salandora/OctoPrint-EEprom-Repetier", "page": "https://plugins.octoprint.org/plugins/eeprom_repetier/", "compatibility": {"octoprint": ["1.5.0"], "os": [], "python": ">=2.7,<4"}, "license": "AGPLv3", "image": "https://plugins.octoprint.org/assets/img/plugins/eeprom_repetier/eeprom_values.png", "abandoned": false, "github": {"latest_release": {"name": "Version 0.1.6", "date": "2021-04-08 06:12:14 +0000", "tag": "0.1.6"}, "releases": 5, "last_push": "2021-05-02 05:53:13 +0000", "stars": 9, "issues": {"open": 2, "closed": 8}}, "stats": {"instances_month": 159, "install_events_month": 10, "instances_week": 110, "install_events_week": 1}}, {"id": "displayprogress", "published": "2015-08-03 00:00:00 +0000", "title": "DisplayProgress", "description": "Displays the print progress on the printer's display", "archive": "https://github.com/OctoPrint/OctoPrint-DisplayProgress/archive/master.zip", "author": "jneilliii, Gina H\u00e4u\u00dfge", "homepage": "https://github.com/OctoPrint/OctoPrint-DisplayProgress", "page": "https://plugins.octoprint.org/plugins/displayprogress/", "compatibility": {"octoprint": [], "os": [], "python": ">=2.7,<4"}, "license": "AGPLv3", "image": "https://plugins.octoprint.org/assets/img/plugins/displayprogress/example.jpg", "abandoned": false, "github": {"latest_release": {"name": "0.1.3", "date": "2020-05-20 07:15:51 +0000", "tag": "0.1.3"}, "releases": 4, "last_push": "2020-05-20 07:13:26 +0000", "stars": 18, "issues": {"open": 0, "closed": 8}}, "stats": {"instances_month": 1449, "install_events_month": 115, "instances_week": 1016, "install_events_week": 23}}, {"id": "eeprom_marlin", "published": "2015-08-30 00:00:00 +0000", "title": "Marlin EEPROM Editor", "description": "Makes it possible to change the EEPROM values of Marlin Firmware through OctoPrint", "archive": "https://github.com/cp2004/OctoPrint-EEPROM-Marlin/releases/latest/download/release.zip", "author": "Charlie Powell, Anderson Silva", "homepage": "https://github.com/cp2004/OctoPrint-EEPROM-Marlin", "page": "https://plugins.octoprint.org/plugins/eeprom_marlin/", "compatibility": {"octoprint": ["1.4.0"], "os": [], "python": ">=3.7,<4"}, "license": "AGPLv3", "image": "https://plugins.octoprint.org/assets/img/plugins/eeprom_marlin/firmware_info.png", "abandoned": false, "github": {"latest_release": {"name": "3.3.0 Stable Release", "date": "2023-01-03 15:29:43 +0000", "tag": "3.3.0"}, "releases": 16, "last_push": "2023-12-27 13:00:34 +0000", "stars": 31, "issues": {"open": 7, "closed": 61}}, "stats": {"instances_month": 4596, "install_events_month": 394, "instances_week": 3274, "install_events_week": 94}}, {"id": "stats", "published": "2015-09-13 00:00:00 +0000", "title": "Printer Statistics", "description": "Statistics of your 3D Printer", "archive": "https://github.com/AlexVerrico/octoprint-stats/archive/master.zip", "author": "Alex Verrico, Anderson Silva", "homepage": "https://github.com/AlexVerrico/octoprint-stats", "page": "https://plugins.octoprint.org/plugins/stats/", "compatibility": {"octoprint": [], "os": [], "python": ">=3.5,<4"}, "license": "AGPLv3", "image": "https://plugins.octoprint.org/assets/img/plugins/stats/img1.png", "abandoned": false, "github": {"latest_release": {"name": "Version 3.1.4 - bugfix, courtesy of @jneilliii", "date": "2023-07-30 22:22:07 +0000", "tag": "v3.1.4"}, "releases": 5, "last_push": "2024-02-05 02:45:09 +0000", "stars": 14, "issues": {"open": 7, "closed": 15}}, "stats": {"instances_month": 998, "install_events_month": 36, "instances_week": 684, "install_events_week": 14}}, {"id": "automaticshutdown", "published": "2015-09-22 00:00:00 +0000", "title": "AutomaticShutdown", "description": "Plugin to enable automatic system shutdown after finishing a print job", "archive": "https://github.com/OctoPrint/OctoPrint-AutomaticShutdown/archive/master.zip", "author": "Nicanor Romero Venier", "homepage": "https://github.com/OctoPrint/OctoPrint-AutomaticShutdown", "page": "https://plugins.octoprint.org/plugins/automaticshutdown/", "compatibility": {"octoprint": ["1.2.5"], "os": [], "python": ">=2.7,<4"}, "license": "AGPLv3", "image": "https://plugins.octoprint.org/assets/img/plugins/automaticshutdown/sidebar.png", "abandoned": false, "github": {"latest_release": {"name": "0.1.5", "date": "2022-01-18 18:18:22 +0000", "tag": "0.1.5"}, "releases": 4, "last_push": "2022-01-18 18:15:32 +0000", "stars": 18, "issues": {"open": 11, "closed": 22}}, "stats": {"instances_month": 574, "install_events_month": 47, "instances_week": 338, "install_events_week": 12}}, {"id": "displayz", "published": "2015-09-22 00:00:00 +0000", "title": "DisplayZ", "description": "Brings back the current Z display in the state sidebar panel", "archive": "https://github.com/foosel/OctoPrint-DisplayZ/archive/master.zip", "author": "Gina H\u00e4u\u00dfge", "homepage": "https://github.com/foosel/OctoPrint-DisplayZ", "page": "https://plugins.octoprint.org/plugins/displayz/", "compatibility": {"octoprint": ["1.2.0"], "os": [], "python": ">=2.7,<4"}, "license": "AGPLv3", "image": "https://plugins.octoprint.org/assets/img/plugins/displayz/displayz.png", "abandoned": false, "github": {"latest_release": {"name": "0.2.0", "date": "2020-07-01 08:01:36 +0000", "tag": "0.2.0"}, "releases": 1, "last_push": "2020-07-04 20:01:44 +0000", "stars": 6, "issues": {"open": 0, "closed": 0}}, "stats": {"instances_month": 1563, "install_events_month": 86, "instances_week": 1146, "install_events_week": 16}}, {"id": "portlister", "published": "2015-10-08 00:00:00 +0000", "title": "PortLister", "description": "Refreshes the port list in the browser when a printer shows up", "archive": "https://github.com/markwal/OctoPrint-PortLister/archive/master.zip", "author": "Mark Walker", "homepage": "https://github.com/markwal/OctoPrint-PortLister", "page": "https://plugins.octoprint.org/plugins/portlister/", "compatibility": {"octoprint": [], "os": ["linux", "freebsd"], "python": ">=2.7,<4"}, "license": "AGPLv3", "abandoned": false, "github": {"latest_release": {"name": "0.1.10", "date": "2020-05-09 22:30:40 +0000", "tag": "0.1.10"}, "releases": 10, "last_push": "2020-05-09 21:54:53 +0000", "stars": 25, "issues": {"open": 3, "closed": 9}}, "stats": {"instances_month": 934, "install_events_month": 72, "instances_week": 717, "install_events_week": 22}}, {"id": "touchui", "published": "2015-10-10 00:00:00 +0000", "title": "TouchUI", "description": "A touch friendly interface for Mobile and TFT touch modules", "archive": "https://github.com/BillyBlaze/OctoPrint-TouchUI/archive/master.zip", "author": "Paul de Vries", "homepage": "https://billyblaze.github.io/OctoPrint-TouchUI", "page": "https://plugins.octoprint.org/plugins/touchui/", "compatibility": {"octoprint": ["1.2.6"], "os": [], "python": ">=2.7,<4"}, "license": "AGPLv3", "image": "https://billyblaze.github.io/OctoPrint-TouchUI/images/touchuisample.png", "abandoned": true, "github": {"latest_release": {"name": "0.3.18", "date": "2021-07-05 18:20:53 +0000", "tag": "0.3.18"}, "releases": 22, "last_push": "2021-07-05 18:17:46 +0000", "stars": 275, "issues": {"open": 0, "closed": 524}}, "stats": {"instances_month": 5476, "install_events_month": 455, "instances_week": 3706, "install_events_week": 104}}, {"id": "slack", "published": "2015-10-28 00:00:00 +0000", "title": "Slack", "description": "Send message to Slack chat when printing events happen", "archive": "https://github.com/mkevenaar/OctoPrint-Slack/releases/latest/download/release.zip", "author": "Maurice Kevenaar, Richard Joyce", "homepage": "https://github.com/mkevenaar/OctoPrint-Slack", "page": "https://plugins.octoprint.org/plugins/slack/", "compatibility": {"octoprint": [], "os": [], "python": ">=2.7,<4"}, "license": "MIT", "image": "https://plugins.octoprint.org/assets/img/plugins/slack/slack.png", "abandoned": false, "github": {"latest_release": {"name": "Release 0.2.5", "date": "2021-02-28 18:12:00 +0000", "tag": "0.2.5"}, "releases": 2, "last_push": "2024-05-09 00:41:33 +0000", "stars": 6, "issues": {"open": 18, "closed": 18}}, "stats": {"instances_month": 45, "install_events_month": 5, "instances_week": 41, "install_events_week": 2}}, {"id": "autocalibration", "published": "2015-11-09 00:00:00 +0000", "title": "Autocalibration", "description": "Calibrates your printers backlash for the X, Y or Z-axis.", "archive": "https://github.com/platsch/OctoPrint-Autocalibration/archive/master.zip", "author": "Florens Wasserfall (Platsch)", "homepage": "https://github.com/platsch/OctoPrint-Autocalibration", "page": "https://plugins.octoprint.org/plugins/autocalibration/", "compatibility": {"octoprint": [], "os": [], "python": ">=2.7,<3"}, "license": "AGPLv3", "image": "https://plugins.octoprint.org/assets/img/plugins/autocalibration/screenshot.png", "abandoned": true, "github": {"last_push": "2015-11-10 13:37:58 +0000", "stars": 2, "issues": {"open": 3, "closed": 5}}, "stats": {"instances_month": 36, "install_events_month": 2, "instances_week": 19, "install_events_week": 1}}, {"id": "updatefix127", "published": "2015-12-07 00:00:00 +0000", "title": "Updatefix 1.2.7", "description": "Fixes an issue in OctoPrint 1.2.7 that prevents updating", "archive": "https://github.com/OctoPrint/OctoPrint-Updatefix-1.2.7/archive/master.zip", "author": "Gina H\u00e4u\u00dfge", "homepage": "https://github.com/OctoPrint/OctoPrint-Updatefix-1.2.7", "page": "https://plugins.octoprint.org/plugins/updatefix127/", "compatibility": {"octoprint": [">=1.2.7,<1.2.8"], "os": [], "python": ">=2.7,<3"}, "license": "AGPLv3", "abandoned": false, "github": {"latest_release": {"name": "0.1.0 (stable)", "date": "2015-12-07 11:57:36 +0000", "tag": "0.1.0"}, "releases": 1, "last_push": "2015-12-07 11:47:13 +0000", "stars": 0, "issues": {"open": 0, "closed": 0}}, "stats": {"instances_month": 0, "install_events_month": 0, "instances_week": 0, "install_events_week": 0}}, {"id": "eeprom_marlin_printrbot", "published": "2015-12-26 00:00:00 +0000", "title": "EEPROM Printrbot variant of Marlin Editor", "description": "Makes it possible to change the EEPROM values of Printrbot variant of Marlin Firmware through OctoPrint", "archive": "https://github.com/ryanneufeld/OctoPrint-EEPROM-Marlin-Printrbot/archive/master.zip", "author": "Ryan Neufeld", "homepage": "https://github.com/ryanneufeld/OctoPrint-EEPROM-Marlin-Printrbot", "page": "https://plugins.octoprint.org/plugins/eeprom_marlin_printrbot/", "compatibility": {"octoprint": [], "os": [], "python": ">=2.7,<3"}, "license": "AGPLv3", "abandoned": false, "github": {"last_push": "2015-12-26 21:30:56 +0000", "stars": 1, "issues": {"open": 0, "closed": 0}}, "stats": {"instances_month": 15, "install_events_month": 1, "instances_week": 10, "install_events_week": 0}}, {"id": "active_filters", "published": "2016-01-01 00:00:00 +0000", "title": "Active Filters", "description": "Save terminal filters status", "archive": "https://github.com/MoonshineSG/OctoPrint-ActiveFilters/archive/master.zip", "author": "ovidiu", "homepage": "https://github.com/MoonshineSG/OctoPrint-ActiveFilters", "page": "https://plugins.octoprint.org/plugins/active_filters/", "compatibility": {"octoprint": ["1.2.6"], "os": [], "python": ">=2.7,<3"}, "license": "AGPLv3", "abandoned": true, "github": {"latest_release": {"name": "0.0.1", "date": "2016-01-04 08:23:19 +0000", "tag": "0.0.1"}, "releases": 1, "last_push": "2017-05-12 02:51:56 +0000", "stars": 1, "issues": {"open": 4, "closed": 0}}, "stats": {"instances_month": 14, "install_events_month": 1, "instances_week": 10, "install_events_week": 0}}, {"id": "title_status", "published": "2016-01-18 00:00:00 +0000", "title": "Title Status", "description": "Show printers status in window title", "archive": "https://github.com/MoonshineSG/OctoPrint-TitleStatus/archive/master.zip", "author": "ovidiu", "homepage": "https://github.com/MoonshineSG/OctoPrint-TitleStatus", "page": "https://plugins.octoprint.org/plugins/title_status/", "compatibility": {"octoprint": ["1.2.6"], "os": [], "python": ">=2.7,<4"}, "license": "AGPLv3", "abandoned": false, "github": {"latest_release": {"name": "0.0.5", "date": "2020-06-24 09:08:42 +0000", "tag": "0.0.5"}, "releases": 5, "last_push": "2020-12-09 02:46:05 +0000", "stars": 2, "issues": {"open": 3, "closed": 3}}, "stats": {"instances_month": 233, "install_events_month": 13, "instances_week": 195, "install_events_week": 5}}, {"id": "telegram", "published": "2016-02-25 00:00:00 +0000", "title": "OctoPrint-Telegram", "description": "A plugin to send and react on messages before, during and after a print via Telegram Messenger.", "archive": "https://github.com/fabianonline/OctoPrint-Telegram/archive/master.zip", "author": "Fabian Schlenz", "homepage": "https://github.com/fabianonline/OctoPrint-Telegram", "page": "https://plugins.octoprint.org/plugins/telegram/", "compatibility": {"octoprint": ["1.2.9"], "os": [], "python": ">=2.7,<4"}, "license": "AGPLv3", "image": "https://plugins.octoprint.org/assets/img/plugins/telegram/features3.png", "abandoned": false, "github": {"latest_release": {"name": "1.6.7", "date": "2024-05-08 10:15:52 +0000", "tag": "1.6.7"}, "releases": 25, "last_push": "2024-05-08 10:14:50 +0000", "stars": 305, "issues": {"open": 137, "closed": 207}}, "stats": {"instances_month": 3684, "install_events_month": 228, "instances_week": 2617, "install_events_week": 55}}, {"id": "pushover", "published": "2016-04-13 00:00:00 +0000", "title": "Pushover", "description": "A plugin that send a notification with Pushover when the job is done or is failed", "archive": "https://github.com/thijsbekke/OctoPrint-Pushover/archive/master.zip", "author": "Thijs Bekke", "homepage": "https://github.com/thijsbekke/OctoPrint-Pushover/", "page": "https://plugins.octoprint.org/plugins/pushover/", "compatibility": {"octoprint": [], "os": [], "python": ">=2.7,<4"}, "license": "AGPLv3", "image": "https://plugins.octoprint.org/assets/img/plugins/pushover/pushover.png", "abandoned": false, "github": {"latest_release": {"name": "Tweaked the log messages ", "date": "2020-07-16 21:25:46 +0000", "tag": "0.3.8"}, "releases": 23, "last_push": "2020-07-21 18:55:41 +0000", "stars": 32, "issues": {"open": 17, "closed": 41}}, "stats": {"instances_month": 647, "install_events_month": 23, "instances_week": 522, "install_events_week": 1}}, {"id": "redeem", "published": "2016-04-26 00:00:00 +0000", "title": "OctoPrint Redeem", "description": "Control Redeems configuration", "archive": "https://github.com/eliasbakken/octoprint_redeem/archive/master.zip", "author": "Elias Bakken", "homepage": "http://wiki.thing-printer.com/index.php?title=Main_Page", "page": "https://plugins.octoprint.org/plugins/redeem/", "compatibility": {"octoprint": ["1.2.8"], "os": [], "python": ">=2.7,<3"}, "license": "AGPLv3", "image": "http://www.thing-printer.com/wp-content/uploads/2016/04/octoprint-redeem.png", "abandoned": false, "github": {"last_push": "2017-08-28 06:07:26 +0000", "stars": 0, "issues": {"open": 1, "closed": 0}}, "stats": {"instances_month": 1, "install_events_month": 1, "instances_week": 1, "install_events_week": 0}}, {"id": "cost", "published": "2016-06-11 00:00:00 +0000", "title": "Cost estimator", "description": "When a file is loaded to be printed, it will display the estimated cost of printing.", "archive": "https://github.com/jasiek/OctoPrint-Cost/archive/master.zip", "author": "Jan Szumiec", "homepage": "https://github.com/jasiek/OctoPrint-Cost", "page": "https://plugins.octoprint.org/plugins/cost/", "compatibility": {"octoprint": [], "os": [], "python": ">=2.7,<3"}, "license": "MIT", "abandoned": true, "github": {"latest_release": {"name": "0.1.3: The Missing Release", "date": "2017-07-13 10:32:48 +0000", "tag": "0.1.3"}, "releases": 1, "last_push": "2019-12-14 13:07:40 +0000", "stars": 10, "issues": {"open": 16, "closed": 5}}, "stats": {"instances_month": 115, "install_events_month": 1, "instances_week": 76, "install_events_week": 0}}, {"id": "autoscroll", "published": "2016-06-27 00:00:00 +0000", "title": "Autoscroll", "description": "Turn on/off terminal autoscroll when scrolling up/down", "archive": "https://github.com/MoonshineSG/OctoPrint-Autoscroll/archive/master.zip", "author": "ovidiu", "homepage": "https://github.com/MoonshineSG/OctoPrint-Autoscroll", "page": "https://plugins.octoprint.org/plugins/autoscroll/", "compatibility": {"octoprint": ["1.2.6"], "os": [], "python": ">=2.7,<4"}, "license": "AGPLv3", "abandoned": false, "github": {"latest_release": {"name": "0.0.3", "date": "2020-05-08 01:24:30 +0000", "tag": "0.0.3"}, "releases": 3, "last_push": "2020-05-08 01:23:26 +0000", "stars": 6, "issues": {"open": 3, "closed": 1}}, "stats": {"instances_month": 1694, "install_events_month": 51, "instances_week": 1243, "install_events_week": 15}}, {"id": "filament_sensor", "published": "2016-06-29 00:00:00 +0000", "title": "Filament Sensor", "description": "Use a filament sensor to pause printing when filament runs out.", "archive": "https://github.com/MoonshineSG/OctoPrint-Filament/archive/master.zip", "author": "ovidiu", "homepage": "https://github.com/MoonshineSG/OctoPrint-Filament", "page": "https://plugins.octoprint.org/plugins/filament_sensor/", "compatibility": {"octoprint": ["1.2.6"], "os": ["linux", "freebsd"], "python": ">=2.7,<3"}, "license": "AGPLv3", "abandoned": false, "github": {"latest_release": {"name": "1.0.1", "date": "2016-06-29 02:42:55 +0000", "tag": "1.0.1"}, "releases": 1, "last_push": "2018-04-17 08:28:41 +0000", "stars": 26, "issues": {"open": 16, "closed": 10}}, "stats": {"instances_month": 36, "install_events_month": 3, "instances_week": 22, "install_events_week": 1}}, {"id": "multi_colors", "published": "2016-06-29 00:00:00 +0000", "title": "Multi Colors", "description": "Inject GCODE at specified layers to allow multi color printing", "archive": "https://github.com/MoonshineSG/OctoPrint-MultiColors/archive/master.zip", "author": "ovidiu", "homepage": "https://github.com/MoonshineSG/OctoPrint-MultiColors", "page": "https://plugins.octoprint.org/plugins/multi_colors/", "compatibility": {"octoprint": ["1.2.6"], "os": [], "python": ">=2.7,<4"}, "license": "AGPLv3", "abandoned": false, "github": {"latest_release": {"name": "1.0.17", "date": "2020-05-08 01:21:01 +0000", "tag": "1.0.17"}, "releases": 20, "last_push": "2020-05-08 01:19:23 +0000", "stars": 21, "issues": {"open": 11, "closed": 31}}, "stats": {"instances_month": 694, "install_events_month": 40, "instances_week": 506, "install_events_week": 8}}, {"id": "gcodebar", "published": "2016-09-01 00:00:00 +0000", "title": "GCodeBar", "description": "Send GCode from the sidebar", "archive": "https://github.com/mtowara/OctoPrint-Gcodebar/archive/master.zip", "author": "Markus Towara", "homepage": "https://github.com/mtowara/OctoPrint-Gcodebar", "page": "https://plugins.octoprint.org/plugins/gcodebar/", "compatibility": {"octoprint": [], "os": [], "python": ">=2.7,<4"}, "license": "AGPLv3", "image": "https://plugins.octoprint.org/assets/img/plugins/gcodebar/gcodebar.png", "abandoned": false, "github": {"latest_release": {"name": "Python3 compability", "date": "2019-12-12 10:06:48 +0000", "tag": "0.1.5"}, "releases": 2, "last_push": "2019-12-12 09:59:06 +0000", "stars": 4, "issues": {"open": 1, "closed": 2}}, "stats": {"instances_month": 406, "install_events_month": 18, "instances_week": 292, "install_events_week": 3}}, {"id": "detailedprogress", "published": "2016-09-02 00:00:00 +0000", "title": "Detailed Progress", "description": "Displays detailed progress on the LCD screen", "archive": "https://github.com/tpmullan/OctoPrint-DetailedProgress/archive/master.zip", "author": "tpmullan", "homepage": "https://github.com/tpmullan/OctoPrint-DetailedProgress", "page": "https://plugins.octoprint.org/plugins/detailedprogress/", "compatibility": {"octoprint": [], "os": [], "python": ">=2.7,<4"}, "license": "AGPLv3", "image": "https://plugins.octoprint.org/assets/img/plugins/detailedprogress/example-eta.jpg", "abandoned": false, "github": {"latest_release": {"name": "0.2.7", "date": "2021-01-31 18:42:04 +0000", "tag": "0.2.7"}, "releases": 5, "last_push": "2022-04-21 01:59:32 +0000", "stars": 28, "issues": {"open": 13, "closed": 26}}, "stats": {"instances_month": 5047, "install_events_month": 397, "instances_week": 3547, "install_events_week": 90}}, {"id": "slicer", "published": "2016-09-22 00:00:00 +0000", "title": "Full-featured Slicer", "description": "A full-blown GUI-based slicer. Rotate and scale model; slice multiple STL files at a time; set layer height and other slicing settings.", "archive": "https://github.com/kennethjiang/OctoPrint-Slicer/archive/master.zip", "author": "eyal0, Kenneth Jiang", "homepage": "https://github.com/kennethjiang/OctoPrint-Slicer", "page": "https://plugins.octoprint.org/plugins/slicer/", "compatibility": {"octoprint": ["1.2.14"], "os": [], "python": ">=2.7,<4"}, "license": "AGPLv3", "image": "https://plugins.octoprint.org/assets/img/plugins/slicer/screenshot1.png", "abandoned": true, "github": {"latest_release": {"name": "Support for OctoPrint 1.6.0 (teacher's edition)", "date": "2021-05-07 15:41:20 +0000", "tag": "2.0.0"}, "releases": 40, "last_push": "2021-05-07 15:39:39 +0000", "stars": 98, "issues": {"open": 22, "closed": 118}}, "stats": {"instances_month": 1019, "install_events_month": 131, "instances_week": 616, "install_events_week": 30}}, {"id": "M117NavBar", "published": "2016-10-27 00:00:00 +0000", "title": "OctoPrint-M117NavBar", "description": "Plugin to send M117 gcode messages to the top navbar of OctoPrint.", "archive": "https://github.com/jneilliii/OctoPrint-M117NavBar/archive/master.zip", "author": "jneilliii", "homepage": "https://github.com/jneilliii/OctoPrint-M117NavBar", "page": "https://plugins.octoprint.org/plugins/M117NavBar/", "compatibility": {"octoprint": [], "os": [], "python": ">=2.7,<4"}, "license": "AGPLv3", "image": "https://plugins.octoprint.org/assets/img/plugins/M117NavBar/screenshot.png", "abandoned": false, "github": {"latest_release": {"name": "0.1.1", "date": "2019-10-22 02:42:28 +0000", "tag": "0.1.1"}, "releases": 2, "last_push": "2024-01-14 15:58:54 +0000", "stars": 2, "issues": {"open": 0, "closed": 1}}, "stats": {"instances_month": 362, "install_events_month": 32, "instances_week": 265, "install_events_week": 5}}, {"id": "M117PopUp", "published": "2016-10-27 00:00:00 +0000", "title": "OctoPrint-M117PopUp", "description": "Plugin to send M117 gcode messages to the web interface.", "archive": "https://github.com/jneilliii/OctoPrint-M117PopUp/archive/master.zip", "author": "jneilliii", "homepage": "https://github.com/jneilliii/OctoPrint-M117PopUp", "page": "https://plugins.octoprint.org/plugins/M117PopUp/", "compatibility": {"octoprint": [], "os": [], "python": ">=2.7,<4"}, "license": "AGPLv3", "image": "https://plugins.octoprint.org/assets/img/plugins/M117PopUp/screenshot_1.png", "abandoned": false, "github": {"latest_release": {"name": "0.6.2", "date": "2019-11-25 04:53:34 +0000", "tag": "0.6.2"}, "releases": 8, "last_push": "2024-01-14 15:58:52 +0000", "stars": 6, "issues": {"open": 1, "closed": 1}}, "stats": {"instances_month": 91, "install_events_month": 11, "instances_week": 53, "install_events_week": 1}}, {"id": "filemanager", "published": "2016-12-09 00:00:00 +0000", "title": "FileManager", "description": "A simple filemanager for OctoPrint", "archive": "https://github.com/Salandora/OctoPrint-FileManager/archive/master.zip", "author": "Marc Hannappel (Salandora)", "homepage": "https://github.com/Salandora/OctoPrint-FileManager", "page": "https://plugins.octoprint.org/plugins/filemanager/", "compatibility": {"octoprint": ["1.3.0"], "os": ["linux", "windows"], "python": ">=2.7,<4"}, "license": "AGPLv3", "image": "https://plugins.octoprint.org/assets/img/plugins/filemanager/img1.png", "abandoned": false, "github": {"latest_release": {"name": "Version 0.1.6", "date": "2021-02-28 18:48:54 +0000", "tag": "0.1.6"}, "releases": 7, "last_push": "2021-02-28 18:04:17 +0000", "stars": 27, "issues": {"open": 16, "closed": 21}}, "stats": {"instances_month": 6449, "install_events_month": 545, "instances_week": 4671, "install_events_week": 94}}, {"id": "filament_sensor_reloaded", "published": "2017-01-06 00:00:00 +0000", "title": "Filament Sensor Reloaded", "description": "Use a filament sensor to pause printing when filament runs out.", "archive": "https://github.com/nickmitchko/Octoprint-Filament-Reloaded/archive/master.zip", "author": "kontakt, ssorgatem, nickmitchko", "homepage": "https://github.com/nickmitchko/Octoprint-Filament-Reloaded", "page": "https://plugins.octoprint.org/plugins/filament_sensor_reloaded/", "compatibility": {"octoprint": ["1.2.6"], "os": ["linux", "freebsd"], "python": ">=2.7,<4"}, "license": "AGPLv3", "abandoned": false, "github": {"latest_release": {"name": "1.4.3", "date": "2023-03-06 17:28:18 +0000", "tag": "1.4.3"}, "releases": 11, "last_push": "2023-03-06 17:26:06 +0000", "stars": 9, "issues": {"open": 2, "closed": 13}}, "stats": {"instances_month": 479, "install_events_month": 35, "instances_week": 326, "install_events_week": 5}}, {"id": "smsnotifier", "published": "2017-01-10 00:00:00 +0000", "title": "SMS Notifier (with Twilio)", "description": "Recieve SMS notifications when OctoPrint jobs are complete.", "archive": "https://github.com/taxilian/OctoPrint-Twilio/archive/master.zip", "author": "Richard Bteman", "homepage": "https://github.com/taxilian/OctoPrint-Twilio", "page": "https://plugins.octoprint.org/plugins/smsnotifier/", "compatibility": {"octoprint": ["1.2.4"], "os": [], "python": ">=2.7,<4"}, "license": "AGPLv3", "image": "https://plugins.octoprint.org/assets/img/plugins/smsnotifier/smsnotifier.png", "abandoned": false, "github": {"last_push": "2020-12-08 10:14:56 +0000", "stars": 5, "issues": {"open": 2, "closed": 12}}, "stats": {"instances_month": 190, "install_events_month": 11, "instances_week": 134, "install_events_week": 1}}, {"id": "fullscreen", "published": "2017-01-16 00:00:00 +0000", "title": "Fullscreen Webcam", "description": "Open the webcam feed in fullscreen mode with extra details about the printjob", "archive": "https://github.com/BillyBlaze/OctoPrint-FullScreen/archive/master.zip", "author": "Paul de Vries", "homepage": "https://github.com/BillyBlaze/OctoPrint-FullScreen", "page": "https://plugins.octoprint.org/plugins/fullscreen/", "compatibility": {"octoprint": [], "os": [], "python": ">=2.7,<4"}, "license": "AGPLv3", "image": "https://plugins.octoprint.org/assets/img/plugins/fullscreen_webcam/main.jpg", "abandoned": false, "github": {"latest_release": {"name": "0.0.6", "date": "2020-11-22 14:35:43 +0000", "tag": "0.0.6"}, "releases": 6, "last_push": "2020-11-22 14:29:52 +0000", "stars": 24, "issues": {"open": 14, "closed": 23}}, "stats": {"instances_month": 8494, "install_events_month": 563, "instances_week": 6165, "install_events_week": 132}}, {"id": "freemobilenotifier", "published": "2017-01-25 00:00:00 +0000", "title": "OctoPrint_FreeMobile-Notifier", "description": "Octoprint plugin for print completion notifications using Free (Free is a French telecommunications company)", "archive": "https://github.com/Pinaute/OctoPrint_FreeMobile-Notifier/archive/master.zip", "author": "Antoine CAVARD", "homepage": "https://github.com/Pinaute/OctoPrint_FreeMobile-Notifier", "page": "https://plugins.octoprint.org/plugins/freemobilenotifier/", "compatibility": {"octoprint": [], "os": [], "python": ">=2.7,<4"}, "license": "AGPLv3", "image": "https://plugins.octoprint.org/assets/img/plugins/freemobilenotifier/freemobilenotifier.png", "abandoned": false, "github": {"latest_release": {"name": "0.1.6", "date": "2020-12-02 22:03:47 +0000", "tag": "0.1.6"}, "releases": 7, "last_push": "2020-12-02 21:56:26 +0000", "stars": 1, "issues": {"open": 1, "closed": 4}}, "stats": {"instances_month": 72, "install_events_month": 5, "instances_week": 48, "install_events_week": 1}}, {"id": "psucontrol", "published": "2017-01-25 00:00:00 +0000", "title": "PSU Control", "description": "Smart control of your power supply via GPIO, GCODE Command, System Command, or variety of sub-plugins.", "archive": "https://github.com/kantlivelong/OctoPrint-PSUControl/archive/master.zip", "author": "Shawn Bruce", "homepage": "https://github.com/kantlivelong/OctoPrint-PSUControl", "page": "https://plugins.octoprint.org/plugins/psucontrol/", "compatibility": {"octoprint": [], "os": ["linux", "freebsd", "macos", "windows"], "python": ">=2.7,<4"}, "license": "AGPLv3", "image": "https://raw.githubusercontent.com/kantlivelong/OctoPrint-PSUControl/master/psucontrol_navbar_settings.png", "abandoned": false, "github": {"latest_release": {"name": "1.0.6", "date": "2021-05-12 14:08:04 +0000", "tag": "1.0.6"}, "releases": 19, "last_push": "2021-08-18 02:08:27 +0000", "stars": 202, "issues": {"open": 59, "closed": 180}}, "stats": {"instances_month": 6575, "install_events_month": 505, "instances_week": 4865, "install_events_week": 114}}, {"id": "slic3r", "published": "2017-02-07 00:00:00 +0000", "title": "OctoPrint-Slic3r", "description": "Adds support for slicing via Slic3r from within OctoPrint", "archive": "https://github.com/OctoPrint/OctoPrint-Slic3r/archive/master.zip", "author": "Javier Mart\u00ednez Arrieta, Eyal Soha", "homepage": "https://github.com/OctoPrint/OctoPrint-Slic3r", "page": "https://plugins.octoprint.org/plugins/slic3r/", "compatibility": {"octoprint": [], "os": [], "python": ">=2.7,<4"}, "license": "AGPLv3", "image": "https://plugins.octoprint.org/assets/img/plugins/slic3r/logo.png", "abandoned": false, "github": {"latest_release": {"name": "Update to work with PrusaSlicer 2.4", "date": "2022-08-29 17:06:02 +0000", "tag": "1.3.1"}, "releases": 9, "last_push": "2022-08-29 17:05:28 +0000", "stars": 88, "issues": {"open": 10, "closed": 41}}, "stats": {"instances_month": 402, "install_events_month": 42, "instances_week": 272, "install_events_week": 10}}, {"id": "tobecaplugin", "published": "2017-02-16 00:00:00 +0000", "title": "Tobeca Plugin", "description": "Plugin for OctoPrint that adds a special tab with commands for the Tobeca 3d printer.", "archive": "https://github.com/tobeca/OctoPrint-TobecaPlugin/archive/master.zip", "author": "Saymtech", "homepage": "https://github.com/tobeca/OctoPrint-TobecaPlugin/", "page": "https://plugins.octoprint.org/plugins/tobecaplugin/", "compatibility": {"octoprint": ["1.2.16"], "os": [], "python": ">=2.7,<3"}, "license": "AGPLv3", "abandoned": false, "github": {"latest_release": {"name": "0.1.3", "date": "2017-03-08 14:38:22 +0000", "tag": "0.1.3"}, "releases": 3, "last_push": "2017-03-08 14:36:23 +0000", "stars": 0, "issues": {"open": 0, "closed": 0}}, "stats": {"instances_month": 0, "install_events_month": 0, "instances_week": 0, "install_events_week": 0}}, {"id": "roomtemp", "published": "2017-03-02 00:00:00 +0000", "title": "Room Temperature", "description": "Display room temperature on navbar", "archive": "https://github.com/l00ma/OctoPrint-roomTemp/archive/master.zip", "author": "Frederic Moutin", "homepage": "https://github.com/l00ma/OctoPrint-roomTemp", "page": "https://plugins.octoprint.org/plugins/roomtemp/", "compatibility": {"octoprint": ["1.3.1"], "os": ["disabled"], "python": ">=2.7,<3"}, "license": "AGPLv3", "image": "https://raw.githubusercontent.com/l00ma/OctoPrint-roomTemp/master/RoomTemp.png", "disabled": "
This plugin can cause severe server issues in its current form.
You are about to disconnect from the printer while a print "+"is in progress.
"+"
Disconnecting while a print is in progress will prevent OctoPrint from "+"completing the print. If you're printing from an SD card attached directly "+"to the printer, any attempt to restart OctoPrint or reconnect to the printer "+"could interrupt the print.
"),question:gettext("Are you sure you want to disconnect from the printer?"),cancel:gettext("Stay Connected"),proceed:gettext("Disconnect"),onproceed:function(){self.requestData();OctoPrint.connection.disconnect();}});}}};self.onEventSettingsUpdated=function(){self.requestData();};self.onEventConnected=function(){self.requestData();};self.onEventDisconnected=function(){self.requestData();};self.onEventConnectionsAutorefreshed=function(){self.requestData();};self.onStartup=function(){var connectionTab=$("#connection");connectionTab.on("show",function(){self.refreshVisible(true);});connectionTab.on("hide",function(){self.refreshVisible(false);});};self.onStartupComplete=function(){self.openOrCloseOnStateChange(true);};self.onUserPermissionsChanged=self.onUserLoggedIn=self.onUserLoggedOut=function(){self.requestData();};}
+OCTOPRINT_VIEWMODELS.push({construct:ConnectionViewModel,dependencies:["loginStateViewModel","settingsViewModel","printerProfilesViewModel","accessViewModel"],elements:["#connection_wrapper"]});});
+;
+
+// source: js/app/viewmodels/control.js
+$(function(){function ControlViewModel(parameters){var self=this;self.loginState=parameters[0];self.settings=parameters[1];self.access=parameters[2];self._createToolEntry=function(){return{name:ko.observable(),key:ko.observable()};};self.isErrorOrClosed=ko.observable(undefined);self.isOperational=ko.observable(undefined);self.isPrinting=ko.observable(undefined);self.isPaused=ko.observable(undefined);self.isError=ko.observable(undefined);self.isReady=ko.observable(undefined);self.isLoading=ko.observable(undefined);self.extrusionAmount=ko.observable(undefined);self.controls=ko.observableArray([]);self.distances=ko.observableArray([0.1,1,10,100]);self.distance=ko.observable(10);self.tools=ko.observableArray([]);self.feedRate=ko.observable();self.flowRate=ko.observable();self.feedbackControlLookup={};self.controlsFromServer=[];self.additionalControls=[];self.intersectionObservers=[];self.keycontrolActive=ko.observable(false);self.keycontrolHelpActive=ko.observable(false);self.keycontrolPossible=ko.pureComputed(function(){return(self.loginState.hasPermission(self.access.permissions.CONTROL)&&self.settings.feature_keyboardControl()&&self.isOperational()&&!self.isPrinting()&&!$.browser.mobile);});self.showKeycontrols=ko.pureComputed(function(){return self.keycontrolPossible();});self._visibleWebcam=undefined;self._dispatchWebcamRefresh=function(target){log.debug(`Webcam refresh triggered for #${target.id}`);var vm=ko.dataFor(target.children[0]);if(vm===self){log.debug(`VM for webcam #${target.id} is not bound, skipping refresh`);}else if(vm===undefined){log.debug(`VM for webcam #${target.id} not found, skipping refresh`);}else if(typeof vm.onWebcamRefresh==="function"){vm.onWebcamRefresh();}else{log.debug(`VM for webcam #${target.id} does not declare 'onWebcamRefresh()', skipping refresh (vm=${vm.constructor.name})`);}};self._dispatchWebcamVisibilityChange=function(target,visible){log.debug(`Webcam visibility of #${target.id} changed to ${visible}`);var vm=ko.dataFor(target.children[0]);if(vm===self){log.debug(`VM for webcam #${target.id} is not bound, skipping visibility update`);}else if(vm===undefined){log.debug(`VM for webcam #${target.id} not found, skipping visibility update`);}else if(typeof vm.onWebcamVisibilityChange==="function"){vm.onWebcamVisibilityChange(visible);}else{log.debug(`VM for webcam #${target.id} does not declare 'onWebcamVisibilityChange(visible)', skipping visibility update (vm=${vm.constructor.name})`);}};const selectedCameraStorageKey="core.control.selectedCamera";self.selectDefaultWebcam=function(){if(!document.querySelector("#webcam_plugins_container .nav")){$("#webcam-group .tab-pane:first").addClass("active");return;}
+let div=localStorage[selectedCameraStorageKey];if(!div||document.getElementById(div.slice(1))===null){div=undefined;}
+if(div!==undefined){$(`${div}_link a`).tab("show");}else{$("#webcam_plugins_container .nav li:first a").tab("show");}};self.onStartupComplete=function(){$("#webcam_plugins_container .nav a[data-toggle='tab']").on("shown",(e)=>{localStorage[selectedCameraStorageKey]=e.target.hash;});self.selectDefaultWebcam();self.recreateIntersectionObservers();};self.recreateIntersectionObservers=function(){self.intersectionObservers.forEach(function(observer){observer.disconnect();});self.intersectionObservers=[];document.querySelectorAll("#webcam-group .tab-pane").forEach(function(target){var options={root:document.querySelector("#webcam_plugins_container"),rootMargin:"0px",threshold:0.01};var callback=function(entries){var visible=entries[0].isIntersecting;self._dispatchWebcamVisibilityChange(target,visible);if(visible){self._visibleWebcam=target;}else if(self._visibleWebcam===target&&!visible){self._visibleWebcam=undefined;}};var observer=new IntersectionObserver(callback,options);observer.observe(target);self.intersectionObservers.push(observer);});};self.onBrowserTabVisibilityChange=function(tabVisible){if(self._visibleWebcam!==undefined){self._dispatchWebcamVisibilityChange(self._visibleWebcam,tabVisible);}};self.refreshWebcam=function(){if(self._visibleWebcam!==undefined){self._dispatchWebcamRefresh(self._visibleWebcam);}};self.settings.printerProfiles.currentProfileData.subscribe(function(){self._updateExtruderCount();self._updateExtrusionAmount();const data=self.settings.printerProfiles.currentProfileData();if(data&&data.extruder){if(data.extruder.defaultExtrusionLength){data.extruder.defaultExtrusionLength.subscribe(self._updateExtrusionAmount);}
+if(data.extruder.count){data.extruder.count.subscribe(self._updateExtruderCount);}}
+self.settings.printerProfiles.currentProfileData().extruder.count.subscribe(self._updateExtruderCount);});self._updateExtrusionAmount=function(){const data=self.settings.printerProfiles.currentProfileData();if(!data||!data.extruder){return;}
+self.extrusionAmount(self.settings.printerProfiles.currentProfileData().extruder.defaultExtrusionLength());};self._updateExtruderCount=function(){const data=self.settings.printerProfiles.currentProfileData();if(!data||!data.extruder||!data.extruder.count){return;}
+var tools=[];var numExtruders=self.settings.printerProfiles.currentProfileData().extruder.count();if(numExtruders>1){for(var extruder=0;extruder0){self.additionalControls=additionalControls;self.rerenderControls();}};self.onFocus=function(data,event){if(!self.settings.feature_keyboardControl())return;self.keycontrolActive(true);};self.onMouseOver=function(data,event){if(!self.settings.feature_keyboardControl())return;$("#webcam_plugins_container").focus();self.keycontrolActive(true);};self.onMouseOut=function(data,event){if(!self.settings.feature_keyboardControl())return;$("#webcam_plugins_container").blur();self.keycontrolActive(false);};self.toggleKeycontrolHelp=function(){self.keycontrolHelpActive(!self.keycontrolHelpActive());};self.onKeyDown=function(data,event){if(!self.settings.feature_keyboardControl())return;var button=undefined;var visualizeClick=true;switch(event.which){case 37:button=$("#control-xdec");break;case 38:button=$("#control-yinc");break;case 39:button=$("#control-xinc");break;case 40:button=$("#control-ydec");break;case 49:case 97:button=$("#control-distance01");visualizeClick=false;break;case 50:case 98:button=$("#control-distance1");visualizeClick=false;break;case 51:case 99:button=$("#control-distance10");visualizeClick=false;break;case 52:case 100:button=$("#control-distance100");visualizeClick=false;break;case 33:case 87:button=$("#control-zinc");break;case 34:case 83:button=$("#control-zdec");break;case 36:button=$("#control-xyhome");break;case 35:button=$("#control-zhome");break;case 9:event.preventDefault();return false;default:return true;}
+if(button===undefined){return false;}else{event.preventDefault();if(visualizeClick){button.addClass("active");setTimeout(function(){button.removeClass("active");},150);}
+button.click();}};self.stripDistanceDecimal=function(distance){return distance.toString().replace(".","");};}
+OCTOPRINT_VIEWMODELS.push({construct:ControlViewModel,dependencies:["loginStateViewModel","settingsViewModel","accessViewModel"],elements:["#control","#control_link"]});});
+;
+
+// source: js/app/viewmodels/files.js
+$(function(){function FilesViewModel(parameters){var self=this;self.settingsViewModel=parameters[0];self.loginState=parameters[1];self.printerState=parameters[2];self.slicing=parameters[3];self.printerProfiles=parameters[4];self.access=parameters[5];self.allViewModels=undefined;self.filesListVisible=ko.observable(true);self.showInternalFilename=ko.observable(true);self.isErrorOrClosed=ko.observable(undefined);self.isOperational=ko.observable(undefined);self.isPrinting=ko.observable(undefined);self.isPaused=ko.observable(undefined);self.isError=ko.observable(undefined);self.isReady=ko.observable(undefined);self.isLoading=ko.observable(undefined);self.isSdReady=ko.observable(undefined);self.searchQuery=ko.observable(undefined);self.searchQuery.subscribe(function(){self.performSearch();});self.freeSpace=ko.observable(undefined);self.totalSpace=ko.observable(undefined);self.freeSpaceString=ko.pureComputed(function(){if(!self.freeSpace())return"-";return formatSize(self.freeSpace());});self.totalSpaceString=ko.pureComputed(function(){if(!self.totalSpace())return"-";return formatSize(self.totalSpace());});self.diskusageWarning=ko.pureComputed(function(){return(self.freeSpace()!==undefined&&self.freeSpace()0);},sd:function(data){return data["origin"]&&data["origin"]==="sdcard";},local:function(data){return!(data["origin"]&&data["origin"]==="sdcard");}};var listHelperExclusiveFilters=[["sd","local"]];if(SUPPORTED_FILETYPES.length>1){_.each(SUPPORTED_FILETYPES,function(filetype){listHelperFilters[filetype]=function(data){return(data["type"]&&(data["type"]===filetype||data["type"]==="folder"));};});listHelperExclusiveFilters.push(SUPPORTED_FILETYPES);}
+var sortByName=function(a,b){if(a["display"].toLowerCase()b["display"].toLowerCase())return 1;return 0;};self.listHelper=new ItemListHelper("gcodeFiles",{name:sortByName,upload:function(a,b){if(a["date"]===undefined&&b["date"]===undefined){return sortByName(a,b);}
+if(b["date"]===undefined||a["date"]>b["date"])return-1;if(a["date"]===undefined||a["date"]valB){return-1;}else if(valAb["size"])return-1;if(a["size"]===undefined||a["size"]=1){if(arguments.length>=2){focus={location:arguments[1],path:arguments[0]};}else{focus={location:"local",path:arguments[0]};}}
+if(arguments.length>=3){switchToPath=arguments[2];}
+if(arguments.length>=4){force=arguments[3];}}
+self._filesToFocus=self._filesToFocus||focus;self._switchToPath=self._switchToPath||switchToPath;if(self._otherRequestInProgress!==undefined){return self._otherRequestInProgress;}
+return(self._otherRequestInProgress=OctoPrint.files.list(true,force).done(function(response){self.fromResponse(response,{focus:self._filesToFocus,switchToPath:self._switchToPath});}).fail(function(){self.allItems(undefined);self.listHelper.updateItems([]);}).always(function(){self._otherRequestInProgress=undefined;self._filesToFocus=[];self._switchToPath=undefined;}));};self.fromResponse=function(response,params){var focus=[];var switchToPath;if(_.isObject(params)){focus=params.focus||undefined;switchToPath=params.switchToPath||undefined;}else if(arguments.length>1){log.warn("FilesViewModel.fromResponse called with old argument list. That is deprecated, please use parameter object instead.");if(arguments.length>2){focus={location:arguments[2],path:arguments[1]};}else{focus={location:"local",path:arguments[1]};}
+if(arguments.length>3){switchToPath=arguments[3]||undefined;}}
+var files=response.files;self.allItems(files);var createFolderList=function(entries){var result=[];_.each(entries,function(entry){if(entry.type!=="folder")return;result.push("/"+entry.path);if(entry.children){result=result.concat(createFolderList(entry.children));}});return result;};const folders=createFolderList(files);folders.sort();self.folderList(["/"].concat(folders));var nonrecursive=false;_.each(files,function(file){if(file.type==="folder"&&file.children===undefined){nonrecursive=true;}});if(nonrecursive){log.error("At least one folder doesn't have a 'children' element defined. That means the file list request "+"wasn't actually made with 'recursive=true' in the query.\n\n"+"This can happen on wrong reverse proxy configs that "+"swallow up query parameters, see https://github.com/OctoPrint/OctoPrint/issues/2572");}
+if(!switchToPath){var currentPath=self.currentPath();if(currentPath===undefined){self.listHelper.updateItems(files);self.currentPath("");}else{self.changeFolderByPath(currentPath);}}else{self.changeFolderByPath(switchToPath);}
+if(focus.length){_.each(focus,function(focusItem,index){var entryElement=self.getEntryElement({path:focusItem.path,origin:focusItem.location});if(entryElement){if(index+1===focus.length){self.listElement.scrollTop(entryElement.offsetTop);}
+var element=$(entryElement);element.on("webkitAnimationEnd oanimationend msAnimationEnd animationend",function(e){element.removeClass("highlight");});element.addClass("highlight");}});}
+if(response.free!==undefined){self.freeSpace(response.free);}
+if(response.total!==undefined){self.totalSpace(response.total);}
+self.highlightCurrentFile();};self.changeFolder=function(data){if(data.children===undefined){log.error("Can't switch to folder '"+data.path+"', no children available");return;}
+self.currentPath(data.path);self.listHelper.updateItems(data.children);self.highlightCurrentFile();};self.navigateUp=function(){var path=self.currentPath().split("/");path.pop();self.changeFolderByPath(path.join("/"));};self.changeFolderByPath=function(path){var element=self.elementByPath(path);if(element){self.currentPath(path);self.listHelper.updateItems(element.children);}else{self.currentPath("");self.listHelper.updateItems(self.allItems());}
+self.highlightCurrentFile();};self.showAddFolderDialog=function(){if(!self.loginState.hasPermission(self.access.permissions.FILES_UPLOAD))
+return;if(self.addFolderDialog){self.addFolderName("");self.addFolderDialog.modal("show");}};self.addFolder=function(){if(!self.loginState.hasPermission(self.access.permissions.FILES_UPLOAD))
+return;var name=self.addFolderName();var location="local";self.ignoreUpdatedFilesEvent=true;self.addingFolder(true);OctoPrint.files.createFolder(location,name,self.currentPath()).done(function(data){self.requestData({focus:{path:data.folder.name,location:data.folder.origin}}).done(function(){self.addFolderDialog.modal("hide");}).always(function(){self.addingFolder(false);});}).fail(function(){self.addingFolder(false);}).always(function(){self.ignoreUpdatedFilesEvent=false;});};self.removeFolder=function(folder,event){if(!self.loginState.hasPermission(self.access.permissions.FILES_DELETE))
+return;if(!folder){return;}
+if(folder.type!=="folder"){return;}
+if(folder.weight>0){var options={message:_.sprintf(gettext('You are about to delete the folder "%(folder)s" which still contains files and/or sub folders.'),{folder:_.escape(folder.name)}),onproceed:function(){self._removeEntry(folder,event);}};showConfirmationDialog(options);}else{self._removeEntry(folder,event);}};self.loadFile=function(data,printAfterLoad){if(!self.loginState.hasPermission(self.access.permissions.FILES_SELECT))
+return;if(!data){return;}
+var proceed=function(p){var prevented=false;var callback=function(){OctoPrint.files.select(data.origin,data.path,p);};if(p){callViewModels(self.allViewModels,"onBeforePrintStart",function(method){prevented=prevented||method(callback)===false;});}
+if(!prevented){callback();}};if(printAfterLoad&&self.listHelper.isSelectedByMatcher(function(item){return item&&item.origin===data.origin&&item.path===data.path;})&&self.enablePrint(data)){self.printerState.print();}else{var withinPrintDimensions=self.evaluatePrintDimensions(data,true);var print=printAfterLoad&&withinPrintDimensions;if(print&&self.settingsViewModel.feature_printStartConfirmation()){showConfirmationDialog({message:gettext("This will start a new print job. Please check that the print bed is clear."),question:gettext("Do you want to start the print job now?"),cancel:gettext("No"),proceed:gettext("Yes"),onproceed:function(){proceed(print);},nofade:true});}else{proceed(print);}}};self.showMoveDialog=function(entry,event){if(!self.loginState.hasAllPermissions(self.access.permissions.FILES_UPLOAD,self.access.permissions.FILES_DELETE)){return;}
+if(!entry){return;}
+if(entry.origin!=="local"){return;}
+if(!self.moveDialog){return;}
+var slashPos=entry.path.lastIndexOf("/");var current;if(slashPos>=0){current="/"+entry.path.substr(0,slashPos);}else{current="/";}
+self.moveEntry(entry);self.moveError("");self.moveSource(current);self.moveDestination(current);self.moveSourceFilename(entry.name);self.moveDestinationFilename(entry.name);self.moveDialog.modal("show");};self.removeFile=function(file,event){if(!self.loginState.hasPermission(self.access.permissions.FILES_DELETE))
+return;if(!file){return;}
+if(file.type==="folder"){return;}
+self._removeEntry(file,event);};self.sliceFile=function(file){if(!self.loginState.hasPermission(self.access.permissions.SLICE))return;if(!file){return;}
+self.slicing.show(file.origin,file.path,true,undefined,{display:file.display});};self.initSdCard=function(){if(!self.loginState.hasPermission(self.access.permissions.CONTROL))return;OctoPrint.printer.initSd();};self.releaseSdCard=function(){if(!self.loginState.hasPermission(self.access.permissions.CONTROL))return;OctoPrint.printer.releaseSd();};self.refreshSdFiles=function(){if(!self.loginState.hasPermission(self.access.permissions.CONTROL))return;OctoPrint.printer.refreshSd();};self.moveFileOrFolder=function(source,destination){self.movingFileOrFolder(true);return OctoPrint.files.move("local",source,destination).done(function(){self.requestData().done(function(){self.moveDialog.modal("hide");}).always(function(){self.movingFileOrFolder(false);});}).fail(function(){self.moveError(gettext("Unable to move file or folder")+" "+
+self.moveEntry().display+" "+
+gettext("to")+" "+
+self.moveDestination());self.movingFileOrFolder(false);});};self._removeEntry=function(entry,event){self.activeRemovals.push(entry.origin+":"+entry.path);var finishActiveRemoval=function(){self.activeRemovals(_.filter(self.activeRemovals(),function(e){return e!==entry.origin+":"+entry.path;}));};var activateSpinner=function(){},finishSpinner=function(){};if(event){var element=$(event.currentTarget);if(element.length){var icon=$("i.fa-trash-alt",element);if(icon.length){activateSpinner=function(){icon.removeClass("far fa-trash-alt").addClass("fas fa-spinner fa-spin");};finishSpinner=function(){icon.removeClass("fas fa-spinner fa-spin").addClass("far fa-trash-alt");};}}}
+activateSpinner();var deferred=$.Deferred();OctoPrint.files.delete(entry.origin,entry.path).done(function(){self.requestData().done(function(){deferred.resolve();}).fail(function(){deferred.reject();});}).fail(function(data){deferred.reject();var error="
"+
+gettext("Could not remove entry. Please check octoprint.log for possible reasons.")+"
"+
+_.sprintf(gettext("%(culprit)s in %(name)s exceeds the print volume of the currently selected printer profile, be careful when printing this."),formatData)+"
";warning+=pnotifyAdditionalInfo(info);warning+='
You can disable this check via Settings > Features > "Enable model size detection [...]"
";switch(data.jqXHR.status){case 409:if(e.target.id==="gcode_upload_sd"){error+=gettext("Could not upload the file to the printer's SD. Make sure the SD is initialized and the printer is not busy with a print already.");}else{error+=gettext("Could not upload the file, overwrite not possible. Make sure it is not already printing and that you have allowed overwriting.");}
+break;case 415:error+=_.sprintf(gettext("Could not upload the file. Make sure that it is a readable, valid file with one of these extensions: %(extensions)s"),{extensions:_.escape(extensions)});break;default:error+=gettext("Could not upload the file. Please check octoprint.log for possible reasons.");break;}
+error+="
");}
+new PNotify({title:"Upload failed",text:error,type:"error",hide:false});};self._handleUploadProgress=function(e,data){var progress=parseInt((data.loaded/data.total)*100,10);var uploaded=progress>=100;self._setProgressBar(progress,uploaded?gettext("Saving ..."):gettext("Uploading ..."),uploaded);};self._dragNDropTarget=null;self._dragNDropFFTimeout=undefined;self._dragNDropFFTimeoutDelay=100;self._forceEndDragNDrop=function(){self.dropOverlay.removeClass("in");if(self.dropZoneLocal)self.dropZoneLocalBackground.removeClass("hover");if(self.dropZoneSd)self.dropZoneSdBackground.removeClass("hover");if(self.dropZone)self.dropZoneBackground.removeClass("hover");self._dragNDropTarget=null;};self._handleDragLeave=function(e){if(e.target!==self._dragNDropTarget)return;self._forceEndDragNDrop();};self._handleDragEnter=function(e){if(!self.settingsViewModel.feature_enableDragDropUpload()){return;}
+const draggedFiles=Array.from(e.originalEvent.dataTransfer.items).filter((item)=>item.kind==="file");if(!draggedFiles.length){return;}
+self.dropOverlay.addClass("in");var foundLocal=false;var foundSd=false;var found=false;var node=e.target;do{if(self.dropZoneLocal&&node===self.dropZoneLocal[0]){foundLocal=true;break;}else if(self.dropZoneSd&&node===self.dropZoneSd[0]){foundSd=true;break;}else if(self.dropZone&&node===self.dropZone[0]){found=true;break;}
+node=node.parentNode;}while(node!==null);if(foundLocal){self.dropZoneLocalBackground.addClass("hover");self.dropZoneSdBackground.removeClass("hover");}else if(foundSd&&self.printerState.isSdReady()&&!self.isPrinting()){self.dropZoneSdBackground.addClass("hover");self.dropZoneLocalBackground.removeClass("hover");}else if(found){self.dropZoneBackground.addClass("hover");}else{if(self.dropZoneLocalBackground)
+self.dropZoneLocalBackground.removeClass("hover");if(self.dropZoneSdBackground)
+self.dropZoneSdBackground.removeClass("hover");if(self.dropZoneBackground)self.dropZoneBackground.removeClass("hover");}
+self._dragNDropTarget=e.target;self._dragNDropLastOver=Date.now();};self.onServerConnect=self.onServerReconnect=function(payload){self._enableDragNDrop();self.requestData();};self.onServerDisconnect=function(payload){self._disableDragNDrop();};self.onBeforeBinding=function(){self.showInternalFilename(self.settingsViewModel.settings.appearance.showInternalFilename());};self.onAllBound=function(allViewModels){self.allViewModels=allViewModels;};self.onStartupComplete=()=>{self.showInternalFilename(self.settingsViewModel.settings.appearance.showInternalFilename());self.settingsViewModel.settings.appearance.showInternalFilename.subscribe((value)=>{self.showInternalFilename(value);});self._enableDragNDrop();self.settingsViewModel.settings.feature.enableDragDropUpload.subscribe((value)=>{if(value){self._enableDragNDrop();}else{self._disableDragNDrop();}});};}
+OCTOPRINT_VIEWMODELS.push({construct:FilesViewModel,name:"filesViewModel",additionalNames:["gcodeFilesViewModel"],dependencies:["settingsViewModel","loginStateViewModel","printerStateViewModel","slicingViewModel","printerProfilesViewModel","accessViewModel"],elements:["#files_wrapper","#add_folder_dialog","#move_file_or_folder_dialog","#upload_exists_dialog"]});});
+;
+
+// source: js/app/viewmodels/firstrun_wizard.js
+$(function(){function FirstRunWizardViewModel(parameters){var self=this;self.dontPrintUnattendedAcknowledged=ko.observable(false);self.dontPortForwardAcknowledged=ko.observable(false);self.fundingRequestAcknowledged=ko.observable(false);self.error=ko.observable(false);self.acknowledgementNeeded=false;self.allAcknowledged=ko.pureComputed(function(){return(self.dontPrintUnattendedAcknowledged()&&self.dontPortForwardAcknowledged()&&self.fundingRequestAcknowledged());});self.onBeforeWizardTabChange=function(next,current){if(!self.acknowledgementNeeded){return true;}
+if(!current||current!=="wizard_firstrun_end"||self.allAcknowledged()){return true;}
+self._showAcknowledgementNeededDialog();return false;};self.onBeforeWizardFinish=function(){if(!self.acknowledgementNeeded||self.allAcknowledged()){return true;}
+self._showAcknowledgementNeededDialog();return false;};self.onAfterBinding=function(){self.acknowledgementNeeded=document.getElementById("wizard_firstrun_end")!==null;};self._showAcknowledgementNeededDialog=function(){self.error(true);showMessageDialog({title:gettext("Please acknowledge the safety warnings and call for funding"),message:gettext("You haven't yet acknowledged all safety warnings and the call for funding. Please do so first.")});};}
+OCTOPRINT_VIEWMODELS.push({construct:FirstRunWizardViewModel,elements:["#wizard_firstrun_start","#wizard_firstrun_end"]});});
+;
+
+// source: js/app/viewmodels/loginstate.js
+$(function(){function LoginStateViewModel(parameters){var self=this;self.loginUser=ko.observable("");self.loginPass=ko.observable("");self.loginRemember=ko.observable(false);self.reauthenticateDialog=undefined;self.reauthenticatePass=ko.observable("");self.reauthenticateFailed=ko.observable(false);self.loggedIn=ko.observable(undefined);self.username=ko.observable(undefined);self.userneeds=ko.observable(undefined);self.isAdmin=ko.observable(false);self.isUser=ko.observable(false);self.allViewModels=undefined;self.startupDeferred=$.Deferred();self.currentUser=ko.observable(undefined);self.currentLoginMechanism=ko.observable(undefined);self.credentialsSeen=ko.observable(undefined);self.elementUsernameInput=undefined;self.elementPasswordInput=undefined;self.elementLoginButton=undefined;self.externalAddressNotification=undefined;self.userMenuText=ko.pureComputed(function(){if(self.loggedIn()){return self.username();}else{return gettext("Login");}});self.userMenuTitle=ko.pureComputed(function(){if(self.loggedIn()){return _.sprintf(gettext("Logged in as %(name)s"),{name:_.escape(self.username())});}else{return gettext("Login");}});self.logoutSupported=ko.pureComputed(function(){var mechanism=self.currentLoginMechanism();return!(mechanism==="apikey"||mechanism==="authheader"||mechanism==="remote_user");});self.logoutTooltip=ko.pureComputed(function(){var mechanism=self.currentLoginMechanism();if(!self.logoutSupported()){var methodMap={apikey:gettext("API key based login"),authheader:gettext("Authorization header based login"),remote_user:gettext("remote user based login")};return _.sprintf(gettext("Logout not supported for %(method)s, please close the browser instead"),{method:methodMap[mechanism]});}else{return gettext("Logout of OctoPrint");}});self.reloadUser=function(){if(self.currentUser()===undefined){return;}
+return OctoPrint.access.users.get(self.currentUser().name).done(self.updateCurrentUserData);};self._reauthenticated=false;self.showReauthenticationDialog=()=>{const result=$.Deferred();self._reauthenticated=false;self.reauthenticateDialog.off("hidden");self.reauthenticateDialog.on("hidden",()=>{self.reauthenticatePass("");self.reauthenticateFailed(false);if(self._reauthenticated){result.resolve();}else{result.reject();}});self.reauthenticateDialog.modal("show");return result.promise();};self.reauthenticate=()=>{const user=self.currentUser().name;const pass=self.reauthenticatePass();return OctoPrint.browser.login(user,pass).done((response)=>{self.fromResponse(response);self.reauthenticateFailed(false);self._reauthenticated=self.credentialsSeen();$("#reauthenticate_dialog").modal("hide");}).fail((response)=>{self.reauthenticatePass("");self.reauthenticateFailed(true);});};self.reauthenticateIfNecessary=(callback)=>{if(!self.checkCredentialsSeen()){self.forceReauthentication(callback);}else{callback();}};self.forceReauthentication=(callback)=>{self.showReauthenticationDialog().done(()=>{callback();}).fail(()=>{});};self.checkCredentialsSeen=()=>{if(CONFIG_REAUTHENTICATION_TIMEOUT<=0)return true;const credentialsSeen=self.credentialsSeen();if(!credentialsSeen){return false;}
+const now=new Date();const seen=new Date(credentialsSeen);return now-seen{if(CONFIG_REAUTHENTICATION_TIMEOUT<=0)return;if(timeout)window.clearTimeout(timeout);return window.setTimeout(callback,(CONFIG_REAUTHENTICATION_TIMEOUT*60+10)*1000);};self.requestData=function(){return OctoPrint.browser.passiveLogin().done(self.fromResponse).fail(function(){self.fromResponse();});};self.fromResponse=function(response){var process=function(){var currentLoggedIn=self.loggedIn();var currentNeeds=self.userneeds();if(response&&response.name){self.loggedIn(true);self.currentLoginMechanism(response._login_mechanism);self.credentialsSeen(response._credentials_seen);self.updateCurrentUserData(response);if(!currentLoggedIn||currentLoggedIn===undefined){callViewModels(self.allViewModels,"onUserLoggedIn",[response]);log.info("User "+response.name+" logged in");}else if(!_.isEqual(currentNeeds,self.userneeds())){callViewModels(self.allViewModels,"onUserPermissionsChanged");log.info("User needs for "+response.name+" changed");}
+if(response.session){OctoPrint.socket.sendAuth(response.name,response.session);}
+var ignorePublicAddressWarning=localStorage["loginState.ignorePublicAddressWarning"];if(ignorePublicAddressWarning===undefined){ignorePublicAddressWarning=false;}else{ignorePublicAddressWarning=JSON.parse(ignorePublicAddressWarning);}
+if(response._is_external_client&&!ignorePublicAddressWarning){var text=gettext("
It seems that you are connecting to OctoPrint over the public internet.
"+"
This is strongly discouraged unless you have taken proper network security precautions. "+"Your printer is an appliance you really should not be giving access to "+"everyone with an internet connection.
Please see "+'this blog post for '+"ways to safely access your OctoPrint instance from remote.
"+"
If you know what you are doing or you are sure this message is "+"mistaken since you are in an isolated LAN, feel free to ignore it.
"+
+gettext("OctoPrint cannot reach the internet. If this is not "+"intentional, please check OctoPrint's network settings and "+"the connectivity check configuration. Updates, plugin repository "+"and anything else requiring access to the public internet will not "+"work.")+"
");};self.appearanceClasses=ko.pureComputed(function(){var classes=self.appearance.color();if(self.appearance.colorTransparent()){classes+=" transparent";}
+return classes;});self.onServerReconnect=self.onServerConnect=self.onEventConnectivityChanged=function(){self.offline(!ONLINE);};}
+OCTOPRINT_VIEWMODELS.push({construct:NavigationViewModel,dependencies:["loginStateViewModel","appearanceViewModel","settingsViewModel","userSettingsViewModel","systemViewModel","accessViewModel"],elements:["#navbar"]});});
+;
+
+// source: js/app/viewmodels/printerstate.js
+$(function(){function PrinterStateViewModel(parameters){var self=this;self.loginState=parameters[0];self.settings=parameters[1];self.access=parameters[2];self.allViewModels=undefined;self.stateString=ko.observable(undefined);self.errorString=ko.observable(undefined);self.hasErrorString=ko.pureComputed(function(){return!!self.errorString();});self.resendCount=ko.observable(0);self.resendTotalTransmitted=ko.observable(0);self.resendRatio=ko.observable(0);self.resendRatioCritical=ko.pureComputed(function(){return(self.resendRatio()>=self.settings.serial_resendRatioThreshold()&&self.resendTotalTransmitted()>=self.settings.serial_resendRatioStart());});self.resendRatioNotification=undefined;self.isErrorOrClosed=ko.observable(undefined);self.isOperational=ko.observable(undefined);self.isPrinting=ko.observable(undefined);self.isCancelling=ko.observable(undefined);self.isPausing=ko.observable(undefined);self.isPaused=ko.observable(undefined);self.isError=ko.observable(undefined);self.isReady=ko.observable(undefined);self.isLoading=ko.observable(undefined);self.isSdReady=ko.observable(undefined);self.isBusy=ko.pureComputed(function(){return(self.isPrinting()||self.isCancelling()||self.isPausing()||self.isPaused());});self.enablePrint=ko.pureComputed(function(){return(self.isOperational()&&(self.isReady()||self.isPaused())&&!self.isPrinting()&&!self.isCancelling()&&!self.isPausing()&&self.loginState.hasPermission(self.access.permissions.PRINT)&&self.filename());});self.enablePause=ko.pureComputed(function(){return(self.isOperational()&&(self.isPrinting()||self.isPaused())&&!self.isCancelling()&&!self.isPausing()&&self.loginState.hasPermission(self.access.permissions.PRINT));});self.enableCancel=ko.pureComputed(function(){return(self.isOperational()&&(self.isPrinting()||self.isPaused())&&!self.isCancelling()&&!self.isPausing()&&self.loginState.loggedIn());});self.filename=ko.observable(undefined);self.filepath=ko.observable(undefined);self.filedisplay=ko.observable(undefined);self.filesize=ko.observable(undefined);self.filepos=ko.observable(undefined);self.filedate=ko.observable(undefined);self.progress=ko.observable(undefined);self.printTime=ko.observable(undefined);self.printTimeLeft=ko.observable(undefined);self.printTimeLeftOrigin=ko.observable(undefined);self.sd=ko.observable(undefined);self.timelapse=ko.observable(undefined);self.user=ko.observable(undefined);self.busyFiles=ko.observableArray([]);self.filament=ko.observableArray([]);self.estimatedPrintTime=ko.observable(undefined);self.lastPrintTime=ko.observable(undefined);self.currentHeight=ko.observable(undefined);self.errorInfoAvailable=ko.observable(false);self.errorInfo={};self.TITLE_PRINT_BUTTON_PAUSED=gettext("Restarts the print job from the beginning");self.TITLE_PRINT_BUTTON_UNPAUSED=gettext("Starts the print job");self.TITLE_PAUSE_BUTTON_PAUSED=gettext("Resumes the print job");self.TITLE_PAUSE_BUTTON_UNPAUSED=gettext("Pauses the print job");self.titlePrintButton=ko.observable(self.TITLE_PRINT_BUTTON_UNPAUSED);self.titlePauseButton=ko.observable(self.TITLE_PAUSE_BUTTON_UNPAUSED);var estimatedPrintTimeStringHlpr=function(fmt){if(self.lastPrintTime())return fmt(self.lastPrintTime());if(self.estimatedPrintTime())return fmt(self.estimatedPrintTime());return"-";};self.estimatedPrintTimeString=ko.pureComputed(function(){return estimatedPrintTimeStringHlpr(self.settings.appearance_fuzzyTimes()?formatFuzzyPrintTime:formatDuration);});self.estimatedPrintTimeExactString=ko.pureComputed(function(){return estimatedPrintTimeStringHlpr(formatDuration);});self.byteString=ko.pureComputed(function(){if(!self.filesize())return"-";var filepos=self.filepos()?formatSize(self.filepos()):"-";return filepos+" / "+formatSize(self.filesize());});self.heightString=ko.pureComputed(function(){if(!self.currentHeight())return"-";return _.sprintf("%.02fmm",self.currentHeight());});self.printTimeString=ko.pureComputed(function(){if(!self.printTime())return"-";return formatDuration(self.printTime());});var printTimeLeftStringHlpr=function(fmt){if(self.printTimeLeft()===undefined){if(!self.printTime()||!(self.isPrinting()||self.isPaused())){return"-";}else{return gettext("Still stabilizing...");}}else{return fmt(self.printTimeLeft());}};self.printTimeLeftString=ko.pureComputed(function(){return printTimeLeftStringHlpr(self.settings.appearance_fuzzyTimes()?formatFuzzyPrintTime:formatDuration);});self.printTimeLeftExactString=ko.pureComputed(function(){return printTimeLeftStringHlpr(formatDuration);});self.printTimeLeftOriginString=ko.pureComputed(function(){var value=self.printTimeLeftOrigin();switch(value){case"linear":{return gettext("Based on a linear approximation (very low accuracy, especially at the beginning of the print)");}
+case"analysis":{return gettext("Based on the estimate from analysis of file (medium accuracy)");}
+case"mixed-analysis":{return gettext("Based on a mix of estimate from analysis and calculation (medium accuracy)");}
+case"average":{return gettext("Based on the average total of past prints of this model with the same printer profile (usually good accuracy)");}
+case"mixed-average":{return gettext("Based on a mix of average total from past prints and calculation (usually good accuracy)");}
+case"estimate":{return gettext("Based on the calculated estimate (best accuracy)");}
+default:{return"";}}});self.printTimeLeftOriginClass=ko.pureComputed(function(){var value=self.printTimeLeftOrigin();switch(value){default:case"linear":{return"text-error";}
+case"analysis":case"mixed-analysis":{return"text-warning";}
+case"average":case"mixed-average":case"estimate":{return"text-success";}}});self.progressString=ko.pureComputed(function(){if(!self.progress())return 0;return self.progress();});self.progressBarString=ko.pureComputed(function(){if(!self.progress()){return"";}
+return _.sprintf("%d%%",self.progress());});self.pauseString=ko.pureComputed(function(){if(self.isPaused())return gettext("Continue");else return gettext("Pause");});self.timelapseString=ko.pureComputed(function(){var timelapse=self.timelapse();if(!timelapse||!timelapse.hasOwnProperty("type"))return"-";var type=timelapse["type"];if(type==="zchange"){return gettext("On Z Change");}else if(type==="timed"){return(gettext("Timed")+" ("+
+timelapse["options"]["interval"]+" "+
+gettext("sec")+")");}else{return"-";}});self.userString=ko.pureComputed(function(){var user=self.user();if(user==="_api"){user="API client";}
+var file=self.filename();return user?user:file?"-":"";});self.dateString=ko.pureComputed(function(){var date=self.filedate();if(!date){return gettext("unknown");}
+return formatDate(date,{seconds:true});});self.fromCurrentData=function(data){self._fromData(data);};self.fromHistoryData=function(data){self._fromData(data);};self.fromTimelapseData=function(data){self.timelapse(data);};self._fromData=function(data){self._processStateData(data.state);self._processJobData(data.job);self._processProgressData(data.progress);self._processZData(data.currentZ);self._processBusyFiles(data.busyFiles);self._processResends(data.resends);self._checkResendRatioCriticality();};self._processStateData=function(data){var prevPaused=self.isPaused();self.stateString(gettext(data.text));self.errorString(data.error);self.isErrorOrClosed(data.flags.closedOrError);self.isOperational(data.flags.operational);self.isPaused(data.flags.paused);self.isPrinting(data.flags.printing);self.isCancelling(data.flags.cancelling);self.isPausing(data.flags.pausing);self.isError(data.flags.error);self.isReady(data.flags.ready);self.isSdReady(data.flags.sdReady);if(self.isPaused()!==prevPaused){if(self.isPaused()){self.titlePrintButton(self.TITLE_PRINT_BUTTON_PAUSED);self.titlePauseButton(self.TITLE_PAUSE_BUTTON_PAUSED);}else{self.titlePrintButton(self.TITLE_PRINT_BUTTON_UNPAUSED);self.titlePauseButton(self.TITLE_PAUSE_BUTTON_UNPAUSED);}}};self._processJobData=function(data){if(data.file){self.filename(data.file.name);self.filepath(data.file.path);self.filesize(data.file.size);self.filedisplay(data.file.display);self.filedate(data.file.date);self.sd(data.file.origin==="sdcard");}else{self.filename(undefined);self.filepath(undefined);self.filesize(undefined);self.filedisplay(undefined);self.filedate(undefined);self.sd(undefined);}
+self.estimatedPrintTime(data.estimatedPrintTime);self.lastPrintTime(data.lastPrintTime);var result=[];if(data.filament&&typeof data.filament==="object"&&_.keys(data.filament).length>0){var keys=_.keys(data.filament);keys.sort();_.each(keys,function(key){if(!_.startsWith(key,"tool")||!data.filament[key]||!data.filament[key].hasOwnProperty("length")||data.filament[key].length<=0)
+return;result.push({name:ko.observable(gettext("Tool")+" "+key.substr("tool".length)),data:ko.observable(data.filament[key])});});}
+self.filament(result);self.user(data.user);};self._processProgressData=function(data){if(data.completion){self.progress(data.completion);}else{self.progress(undefined);}
+self.filepos(data.filepos);self.printTime(data.printTime);self.printTimeLeft(data.printTimeLeft);self.printTimeLeftOrigin(data.printTimeLeftOrigin);};self._processZData=function(data){self.currentHeight(data);};self._processBusyFiles=function(data){var busyFiles=[];_.each(data,function(entry){if(entry.hasOwnProperty("path")&&entry.hasOwnProperty("origin")){busyFiles.push(entry.origin+":"+entry.path);}});self.busyFiles(busyFiles);};self._processResends=function(data){self.resendCount(data.count);self.resendTotalTransmitted(data.transmitted);self.resendRatio(data.ratio);};self._checkResendRatioCriticality=function(){if(self.resendRatioCritical()){if(self.resendRatioNotification===undefined){var message=gettext("
%(ratio)d%% of transmitted lines have triggered resend "+"requests. The communication with the printer is unreliable "+"and this will cause print artefacts and failures.
Please "+"see this FAQ entry "+"on tips on how to solve this.
");message=_.sprintf(message,{ratio:self.resendRatio(),url:"https://faq.octoprint.org/communication-errors"});self.resendRatioNotification=new PNotify({title:gettext("Critical resend ratio!"),text:message,type:"error",hide:false});}}else if(self.resendRatioNotification!==undefined){self.resendRatioNotification.remove();self.resendRatioNotification=undefined;}};self.print=function(){if(self.isPaused()){showConfirmationDialog({message:gettext("This will restart the print job from the beginning."),onproceed:function(){OctoPrint.job.restart();}});}else{var proceed=function(p){var prevented=false;var callback=function(){OctoPrint.job.start();};callViewModels(self.allViewModels,"onBeforePrintStart",function(method){prevented=prevented||method(callback)===false;});if(!prevented){callback();}};if(!self.settings.feature_printStartConfirmation()){proceed();}else{showConfirmationDialog({message:gettext("This will start a new print job. Please check that the print bed is clear."),question:gettext("Do you want to start the print job now?"),cancel:gettext("No"),proceed:gettext("Yes"),onproceed:proceed,nofade:true});}}};self.onlyPause=function(){OctoPrint.job.pause();};self.onlyResume=function(){OctoPrint.job.resume();};self.pause=function(action){OctoPrint.job.togglePause();};self.cancel=function(){if(!self.settings.feature_printCancelConfirmation()){OctoPrint.job.cancel();}else{showConfirmationDialog({message:gettext("This will cancel your print."),cancel:gettext("No, continue the print"),proceed:gettext("Yes, cancel the print"),onproceed:function(){OctoPrint.job.cancel();},nofade:true});}};self.showFirmwareErrorModal=(data)=>{if(!data){data=self.errorInfo;}
+if(!data)return;const modal=$("#firmwareErrorModal");if(!modal.length)return;$("#firmwareErrorModalError",modal).text(data.error);switch(data.consequence){case"emergency":{$("#firmwareErrorModalM112",modal).show();$("#firmwareErrorModalDisconnect",modal).hide();$("#firmwareErrorModalCancel",modal).hide();break;}
+case"disconnect":{$("#firmwareErrorModalM112",modal).hide();$("#firmwareErrorModalDisconnect",modal).show();$("#firmwareErrorModalCancel",modal).hide();break;}
+case"cancel":{$("#firmwareErrorModalM112",modal).hide();$("#firmwareErrorModalDisconnect",modal).hide();$("#firmwareErrorModalCancel",modal).show();break;}
+default:{$("#firmwareErrorModalM112",modal).hide();$("#firmwareErrorModalDisconnect",modal).hide();$("#firmwareErrorModalCancel",modal).hide();break;}}
+if(data.faq){$("#firmwareErrorModalFaq a",modal).attr("href","https://faq.octoprint.org/"+data.faq);$("#firmwareErrorModalFaq",modal).show();}else{$("#firmwareErrorModalFaq",modal).hide();}
+const logs=$("#firmwareErrorModalLogs",modal);const logOutput=$("#firmwareErrorModalLogsOutput",logs);if(data.logs){logOutput.empty();_.each(data.logs,(line)=>{logOutput.append(''+_.escape(line)+"\n"+"");});logs.show();}else{logs.hide();}
+modal.modal("show");logOutput.scrollTop(logOutput.prop("scrollHeight"));};self.requestErrorInfo=()=>{OctoPrint.printer.getErrorInfo().then((data)=>{if(data&&data.error&&data.error!==""){self.errorInfoAvailable(true);self.errorInfo=data;}else{self.errorInfoAvailable(false);self.errorInfo={};}});};self.onEventError=(payload)=>{if(payload.reason==="firmware"){self.errorInfo=payload;self.errorInfoAvailable(true);self.showFirmwareErrorModal();}};self.onEventConnecting=self.onEventPrintCancelling=self.onEventPrintStarted=()=>{self.requestErrorInfo();};self.onUserPermissionsChanged=self.onUserLoggedIn=self.onUserLoggedOut=()=>{self.requestErrorInfo();};self.onAllBound=(allViewModels)=>{self.allViewModels=allViewModels;};}
+OCTOPRINT_VIEWMODELS.push({construct:PrinterStateViewModel,dependencies:["loginStateViewModel","settingsViewModel","accessViewModel"],elements:["#state_wrapper","#drop_overlay"]});});
+;
+
+// source: js/app/viewmodels/printerprofiles.js
+$(function(){var cleanProfile=function(){return{id:"",name:"",model:"",color:"default",volume:{formFactor:"rectangular",width:200,depth:200,height:200,origin:"lowerleft",custom_box:false},heatedBed:true,heatedChamber:false,axes:{x:{speed:6000,inverted:false},y:{speed:6000,inverted:false},z:{speed:200,inverted:false},e:{speed:300,inverted:false}},extruder:{count:1,offsets:[[0,0]],nozzleDiameter:0.4,sharedNozzle:false,defaultExtrusionLength:5}};};function EditedProfileViewModel(profiles){var self=this;self.profiles=profiles;self.isNew=ko.observable(false);self.name=ko.observable();self.color=ko.observable();self.identifier=ko.observable();self.identifierPlaceholder=ko.observable();self.model=ko.observable();self.volumeWidth=ko.observable();self.volumeHeight=ko.observable();self.volumeDepth=ko.observable();self.volumeFormFactor=ko.observable();self.volumeOrigin=ko.observable();self.volumeFormFactor.subscribe(function(value){if(value=="circular"){self.volumeOrigin("center");}});self.volumeOrigin.subscribe(function(){self.toBoundingBoxPlaceholders(self.defaultBoundingBox(self.volumeWidth(),self.volumeDepth(),self.volumeHeight(),self.volumeOrigin()));});self.heatedBed=ko.observable();self.heatedChamber=ko.observable();self.nozzleDiameter=ko.observable();self.extruders=ko.observable();self.extruderOffsets=ko.observableArray();self.sharedNozzle=ko.observable();self.defaultExtrusionLength=ko.observable();self.axisXSpeed=ko.observable();self.axisYSpeed=ko.observable();self.axisZSpeed=ko.observable();self.axisESpeed=ko.observable();self.axisXInverted=ko.observable(false);self.axisYInverted=ko.observable(false);self.axisZInverted=ko.observable(false);self.axisEInverted=ko.observable(false);self.customBoundingBox=ko.observable(false);self.boundingBoxMinX=ko.observable();self.boundingBoxMinY=ko.observable();self.boundingBoxMinZ=ko.observable();self.boundingBoxMaxX=ko.observable();self.boundingBoxMaxY=ko.observable();self.boundingBoxMaxZ=ko.observable();self.boundingBoxMinXPlaceholder=ko.observable();self.boundingBoxMinYPlaceholder=ko.observable();self.boundingBoxMinZPlaceholder=ko.observable();self.boundingBoxMaxXPlaceholder=ko.observable();self.boundingBoxMaxYPlaceholder=ko.observable();self.boundingBoxMaxZPlaceholder=ko.observable();self.koExtruderOffsets=ko.pureComputed(function(){var extruderOffsets=self.extruderOffsets();var numExtruders=self.extruders();if(!numExtruders){numExtruders=1;}
+if(numExtruders-1>extruderOffsets.length){for(var i=extruderOffsets.length;i0&&self.volumeWidth()<10000)||!(self.volumeDepth()>0&&self.volumeDepth()<10000)||!(self.volumeHeight()>0&&self.volumeHeight()<10000));});self.identifierInvalid=ko.pureComputed(function(){var identifier=self.identifier();var placeholder=self.identifierPlaceholder();var data=identifier;if(!identifier){data=placeholder;}
+var validCharacters=data&&data==self._sanitize(data);var existingProfile=self.profiles.getItem(function(item){return item.id==data;});return(!data||!validCharacters||(self.isNew()&&existingProfile!=undefined));});self.identifierInvalidText=ko.pureComputed(function(){if(!self.identifierInvalid()){return"";}
+if(!self.identifier()&&!self.identifierPlaceholder()){return gettext("Identifier must be set");}else if(self.identifier()!=self._sanitize(self.identifier())){return gettext("Invalid characters, only a-z, A-Z, 0-9, -, ., _, ( and ) are allowed");}else{return gettext("A profile with such an identifier already exists");}});self.name.subscribe(function(){self.identifierPlaceholder(self._sanitize(self.name()).toLowerCase());});self.valid=function(){return(!self.nameInvalid()&&!self.identifierInvalid()&&!self.sizeInvalid());};self.availableColors=ko.observable([{key:"default",name:gettext("default")},{key:"red",name:gettext("red")},{key:"orange",name:gettext("orange")},{key:"yellow",name:gettext("yellow")},{key:"green",name:gettext("green")},{key:"blue",name:gettext("blue")},{key:"black",name:gettext("black")}]);self.availableOrigins=ko.pureComputed(function(){var formFactor=self.volumeFormFactor();var possibleOrigins={lowerleft:gettext("Lower Left"),center:gettext("Center")};var keys=[];if(formFactor=="rectangular"){keys=["lowerleft","center"];}else if(formFactor=="circular"){keys=["center"];}
+var result=[];_.each(keys,function(key){result.push({key:key,name:possibleOrigins[key]});});return result;});self.fromProfileData=function(data){self.isNew(data===undefined);if(data===undefined){data=cleanProfile();}
+self.identifier(data.id);self.name(data.name);self.color(data.color);self.model(data.model);self.volumeWidth(data.volume.width);self.volumeHeight(data.volume.height);self.volumeDepth(data.volume.depth);self.volumeFormFactor(data.volume.formFactor);self.volumeOrigin(data.volume.origin);if(data.volume.custom_box){self.toBoundingBoxData(data.volume.custom_box,true);}else{var box=self.defaultBoundingBox(data.volume.width,data.volume.depth,data.volume.height,data.volume.origin);self.toBoundingBoxData(box,false);}
+self.heatedBed(data.heatedBed);self.heatedChamber(data.heatedChamber);self.nozzleDiameter(data.extruder.nozzleDiameter);self.sharedNozzle(data.extruder.sharedNozzle);self.defaultExtrusionLength(data.extruder.defaultExtrusionLength);self.extruders(data.extruder.count);var offsets=[];if(data.extruder.count>1){_.each(_.slice(data.extruder.offsets,1),function(offset,index){offsets.push({idx:index+1,x:ko.observable(offset[0]),y:ko.observable(offset[1])});});}
+self.extruderOffsets(offsets);self.axisXSpeed(data.axes.x.speed);self.axisXInverted(data.axes.x.inverted);self.axisYSpeed(data.axes.y.speed);self.axisYInverted(data.axes.y.inverted);self.axisZSpeed(data.axes.z.speed);self.axisZInverted(data.axes.z.inverted);self.axisESpeed(data.axes.e.speed);self.axisEInverted(data.axes.e.inverted);};self.toProfileData=function(){var identifier=self.identifier();if(!identifier){identifier=self.identifierPlaceholder();}
+var defaultProfile=cleanProfile();var valid=function(value,f,def){var v=f(value);if(isNaN(v)){return def;}
+return v;};var runChecks=function(value,def,checks){if(checks.gt!==undefined){if(!(value>checks.gt)){return def;}}
+if(checks.lt!==undefined){if(!(value1){for(var i=0;ib["name"].toLocaleLowerCase())
+return 1;return 0;}},{},"name",[],[],10);self.defaultProfile=ko.observable();self.currentProfile=ko.observable();self.createProfileEditor=function(data){var editor=new EditedProfileViewModel(self.profiles);if(data!==undefined){editor.fromProfileData(data);}
+return editor;};self.editor=self.createProfileEditor();self.currentProfileData=ko.observable();self.enableEditorSubmitButton=ko.pureComputed(function(){return self.editor.valid()&&!self.requestInProgress();});self.makeDefault=function(data){var profile={id:data.id,default:true};self.updateProfile(profile);};self.canMakeDefault=function(data){return!data.isdefault();};self.canRemove=function(data){return!data.iscurrent()&&!data.isdefault();};self.requestData=function(){if(!self.loginState.hasPermission(self.access.permissions.CONNECTION)){return;}
+return OctoPrint.printerprofiles.list().done(self.fromResponse);};self.fromResponse=function(data){var items=[];var defaultProfile=undefined;var currentProfile=undefined;var currentProfileData=undefined;_.each(data.profiles,function(entry){if(entry.default){defaultProfile=entry.id;}
+if(entry.current){currentProfile=entry.id;currentProfileData=ko.mapping.fromJS(entry,self.currentProfileData);}
+entry["isdefault"]=ko.observable(entry.default);entry["iscurrent"]=ko.observable(entry.current);items.push(entry);});self.profiles.updateItems(items);self.defaultProfile(defaultProfile);if(currentProfile&¤tProfileData){self.currentProfile(currentProfile);self.currentProfileData(currentProfileData);}else{log.warn("Current printer profile could not be detected, using default values");self.currentProfile("");self.currentProfileData(ko.mapping.fromJS(cleanProfile(),self.currentProfileData));}};self.addProfile=function(callback){var profile=self.editor.toProfileData();self.requestInProgress(true);OctoPrint.printerprofiles.add(profile).done(function(){if(callback!==undefined){callback();}
+self.requestData();}).fail(function(xhr){var text=gettext("There was unexpected error while saving the printer profile, please consult the logs.");new PNotify({title:gettext("Could not add profile"),text:text,type:"error",hide:false});}).always(function(){self.requestInProgress(false);});};self.removeProfile=function(data){var perform=function(){self.requestInProgress(true);OctoPrint.printerprofiles.delete(data.id,{url:data.resource}).done(function(){self.requestData().always(function(){self.requestInProgress(false);});}).fail(function(xhr){var text;if(xhr.status==409){text=gettext("Cannot delete the default profile or the currently active profile.");}else{text=gettext("There was unexpected error while removing the printer profile, please consult the logs.");}
+new PNotify({title:gettext("Could not delete profile"),text:text,type:"error",hide:false});self.requestInProgress(false);});};showConfirmationDialog(_.sprintf(gettext('You are about to delete the printer profile "%(name)s".'),{name:_.escape(data.name)}),perform);};self.updateProfile=function(profile,callback){if(profile==undefined){profile=self.editor.toProfileData();}
+self.requestInProgress(true);OctoPrint.printerprofiles.update(profile.id,profile).done(function(){if(callback!==undefined){callback();}
+self.requestData().always(function(){self.requestInProgress(false);});}).fail(function(){var text=gettext("There was unexpected error while updating the printer profile, please consult the logs.");new PNotify({title:gettext("Could not update profile"),text:text,type:"error",hide:false});self.requestInProgress(false);});};self.showEditProfileDialog=function(data){self.editor.fromProfileData(data);var editDialog=$("#settings_printerProfiles_editDialog");var confirmButton=$("button.btn-confirm",editDialog);var dialogTitle=$("h3.modal-title",editDialog);var add=data===undefined;dialogTitle.text(add?gettext("Add Printer Profile"):_.sprintf(gettext('Edit Printer Profile "%(name)s"'),{name:_.escape(data.name)}));confirmButton.unbind("click");confirmButton.bind("click",function(){if(self.enableEditorSubmitButton()){self.confirmEditProfile(add);}});$('ul.nav-pills a[data-toggle="tab"]:first',editDialog).tab("show");editDialog.modal({minHeight:function(){return Math.max($.fn.modal.defaults.maxHeight()-80,250);}}).css({"margin-left":function(){return-($(this).width()/2);}});};self.confirmEditProfile=function(add){var callback=function(){$("#settings_printerProfiles_editDialog").modal("hide");};if(add){self.addProfile(callback);}else{self.updateProfile(undefined,callback);}};self.onSettingsShown=self.requestData;self.onUserPermissionsChanged=self.onUserLoggedIn=self.onUserLoggedOut=function(){self.requestData();};}
+OCTOPRINT_VIEWMODELS.push({construct:PrinterProfilesViewModel,dependencies:["loginStateViewModel","accessViewModel"]});});
+;
+
+// source: js/app/viewmodels/settings.js
+$(function(){function SettingsViewModel(parameters){var self=this;self.loginState=parameters[0];self.access=parameters[1];self.printerProfiles=parameters[2];self.about=parameters[3];self.users=parameters[4];var firstRequest=$.Deferred();self.firstRequest=firstRequest.promise();self.allViewModels=[];self.receiving=ko.observable(false);self.sending=ko.observable(false);self.exchanging=ko.pureComputed(function(){return self.receiving()||self.sending();});self.outstanding=[];self.active=false;self.sawUpdateEventWhileActive=false;self.ignoreNextUpdateEvent=false;self.settingsDialog=undefined;self.settings_dialog_update_detected=undefined;self.translationManagerDialog=undefined;self.translationUploadElement=$("#settings_appearance_managelanguagesdialog_upload");self.translationUploadButton=$("#settings_appearance_managelanguagesdialog_upload_start");self.translationUploadFilename=ko.observable();self.invalidTranslationArchive=ko.pureComputed(function(){var name=self.translationUploadFilename();return name!==undefined&&!_.endsWith(name.toLocaleLowerCase(),".zip");});self.enableTranslationUpload=ko.pureComputed(function(){var name=self.translationUploadFilename();return(name!==undefined&&name.trim()!=""&&!self.invalidTranslationArchive());});self.translations=new ItemListHelper("settings.translations",{locale:function(a,b){if(a["locale"].toLocaleLowerCase()b["locale"].toLocaleLowerCase())
+return 1;return 0;}},{},"locale",[],[],0);self.appearance_available_colors=ko.observable([{key:"default",name:gettext("default")},{key:"red",name:gettext("red")},{key:"orange",name:gettext("orange")},{key:"yellow",name:gettext("yellow")},{key:"green",name:gettext("green")},{key:"blue",name:gettext("blue")},{key:"violet",name:gettext("violet")},{key:"black",name:gettext("black")},{key:"white",name:gettext("white")}]);self.appearance_colorName=function(color){switch(color){case"red":return gettext("red");case"orange":return gettext("orange");case"yellow":return gettext("yellow");case"green":return gettext("green");case"blue":return gettext("blue");case"violet":return gettext("violet");case"black":return gettext("black");case"white":return gettext("white");case"default":return gettext("default");default:return color;}};self.webcam_available_videocodecs=["libx264","mpeg2video"];var auto_locale={language:"_default",display:gettext("Autodetect from browser"),english:undefined};self.locales=ko.observableArray([auto_locale].concat(_.sortBy(_.values(AVAILABLE_LOCALES),function(n){return n.display;})));self.locale_languages=_.keys(AVAILABLE_LOCALES);self.api_key=ko.observable(undefined);self.api_allowCrossOrigin=ko.observable(undefined);self.apiKeyVisible=ko.observable(false);self.appearance_name=ko.observable(undefined);self.appearance_color=ko.observable(undefined);self.appearance_colorTransparent=ko.observable();self.appearance_colorIcon=ko.observable();self.appearance_defaultLanguage=ko.observable();self.appearance_showFahrenheitAlso=ko.observable(undefined);self.appearance_fuzzyTimes=ko.observable(undefined);self.appearance_closeModalsWithClick=ko.observable(undefined);self.appearance_showInternalFilename=ko.observable(undefined);self.printer_defaultExtrusionLength=ko.observable(undefined);self.webcam_webcamEnabled=ko.observable(undefined);self.webcam_timelapseEnabled=ko.observable(undefined);self.webcam_snapshotTimeout=ko.observable(undefined);self.webcam_snapshotSslValidation=ko.observable(undefined);self.webcam_ffmpegPath=ko.observable(undefined);self.webcam_ffmpegCommandline=ko.observable(undefined);self.webcam_bitrate=ko.observable(undefined);self.webcam_ffmpegThreads=ko.observable(undefined);self.webcam_ffmpegVideoCodec=ko.observable(undefined);self.webcam_watermark=ko.observable(undefined);self.webcam_defaultWebcam=ko.observable(undefined);self.webcam_snapshotWebcam=ko.observable(undefined);self.webcam_webcams=ko.observableArray([]);self.feature_temperatureGraph=ko.observable(undefined);self.feature_sdSupport=ko.observable(undefined);self.feature_keyboardControl=ko.observable(undefined);self.feature_pollWatched=ko.observable(undefined);self.feature_modelSizeDetection=ko.observable(undefined);self.feature_rememberFileFolder=ko.observable(undefined);self.feature_printStartConfirmation=ko.observable(undefined);self.feature_printCancelConfirmation=ko.observable(undefined);self.feature_uploadOverwriteConfirmation=ko.observable(undefined);self.feature_g90InfluencesExtruder=ko.observable(undefined);self.feature_autoUppercaseBlacklist=ko.observable(undefined);self.feature_enableDragDropUpload=ko.observable(undefined);self.gcodeAnalysis_runAt=ko.observable(undefined);self.serial_port=ko.observable();self.serial_baudrate=ko.observable();self.serial_exclusive=ko.observable();self.serial_lowLatency=ko.observable();self.serial_portOptions=ko.observableArray([]);self.serial_baudrateOptions=ko.observableArray([]);self.serial_autoconnect=ko.observable(undefined);self.serial_timeoutConnection=ko.observable(undefined);self.serial_timeoutDetectionFirst=ko.observable(undefined);self.serial_timeoutDetectionConsecutive=ko.observable(undefined);self.serial_timeoutCommunication=ko.observable(undefined);self.serial_timeoutCommunicationBusy=ko.observable(undefined);self.serial_timeoutTemperature=ko.observable(undefined);self.serial_timeoutTemperatureTargetSet=ko.observable(undefined);self.serial_timeoutTemperatureAutoreport=ko.observable(undefined);self.serial_timeoutSdStatus=ko.observable(undefined);self.serial_timeoutSdStatusAutoreport=ko.observable(undefined);self.serial_timeoutPosAutoreport=ko.observable(undefined);self.serial_timeoutBaudrateDetectionPause=ko.observable(undefined);self.serial_timeoutPositionLogWait=ko.observable(undefined);self.serial_log=ko.observable(undefined);self.serial_additionalPorts=ko.observable(undefined);self.serial_additionalBaudrates=ko.observable(undefined);self.serial_blacklistedPorts=ko.observable(undefined);self.serial_blacklistedBaudrates=ko.observable(undefined);self.serial_longRunningCommands=ko.observable(undefined);self.serial_checksumRequiringCommands=ko.observable(undefined);self.serial_blockedCommands=ko.observable(undefined);self.serial_ignoredCommands=ko.observable(undefined);self.serial_pausingCommands=ko.observable(undefined);self.serial_sdCancelCommand=ko.observable(undefined);self.serial_emergencyCommands=ko.observable(undefined);self.serial_helloCommand=ko.observable(undefined);self.serial_serialErrorBehaviour=ko.observable("cancel");self.serial_triggerOkForM29=ko.observable(undefined);self.serial_waitForStart=ko.observable(undefined);self.serial_waitToLoadSdFileList=ko.observable(undefined);self.serial_sendChecksum=ko.observable("print");self.serial_sendChecksumWithUnknownCommands=ko.observable(undefined);self.serial_unknownCommandsNeedAck=ko.observable(undefined);self.serial_sdRelativePath=ko.observable(undefined);self.serial_sdLowerCase=ko.observable(undefined);self.serial_sdAlwaysAvailable=ko.observable(undefined);self.serial_swallowOkAfterResend=ko.observable(undefined);self.serial_repetierTargetTemp=ko.observable(undefined);self.serial_disableExternalHeatupDetection=ko.observable(undefined);self.serial_ignoreIdenticalResends=ko.observable(undefined);self.serial_firmwareDetection=ko.observable(undefined);self.serial_blockWhileDwelling=ko.observable(undefined);self.serial_useParityWorkaround=ko.observable(undefined);self.serial_sanityCheckTools=ko.observable(undefined);self.serial_supportResendsWithoutOk=ko.observable(undefined);self.serial_logPositionOnPause=ko.observable(undefined);self.serial_logPositionOnCancel=ko.observable(undefined);self.serial_abortHeatupOnCancel=ko.observable(undefined);self.serial_maxTimeoutsIdle=ko.observable(undefined);self.serial_maxTimeoutsPrinting=ko.observable(undefined);self.serial_maxTimeoutsLong=ko.observable(undefined);self.serial_capAutoreportTemp=ko.observable(undefined);self.serial_capAutoreportSdStatus=ko.observable(undefined);self.serial_capAutoreportPos=ko.observable(undefined);self.serial_capBusyProtocol=ko.observable(undefined);self.serial_capEmergencyParser=ko.observable(undefined);self.serial_capExtendedM20=ko.observable(undefined);self.serial_capLfnWrite=ko.observable(undefined);self.serial_sendM112OnError=ko.observable(undefined);self.serial_disableSdPrintingDetection=ko.observable(undefined);self.serial_ackMax=ko.observable(undefined);self.serial_resendRatioThreshold=ko.observable(100);self.serial_resendRatioStart=ko.observable(100);self.serial_ignoreEmptyPorts=ko.observable(undefined);self.serial_enableShutdownActionCommand=ko.observable(undefined);self.folder_uploads=ko.observable(undefined);self.folder_timelapse=ko.observable(undefined);self.folder_watched=ko.observable(undefined);self.scripts_gcode_beforePrintStarted=ko.observable(undefined);self.scripts_gcode_afterPrintDone=ko.observable(undefined);self.scripts_gcode_afterPrintCancelled=ko.observable(undefined);self.scripts_gcode_afterPrintPaused=ko.observable(undefined);self.scripts_gcode_beforePrintResumed=ko.observable(undefined);self.scripts_gcode_afterPrinterConnected=ko.observable(undefined);self.scripts_gcode_beforePrinterDisconnected=ko.observable(undefined);self.scripts_gcode_afterToolChange=ko.observable(undefined);self.scripts_gcode_beforeToolChange=ko.observable(undefined);self.temperature_profiles=ko.observableArray(undefined);self.temperature_cutoff=ko.observable(undefined);self.temperature_sendAutomatically=ko.observable(undefined);self.temperature_sendAutomaticallyAfter=ko.observable(undefined);self.system_actions=ko.observableArray([]);self.terminalFilters=ko.observableArray([]);self.server_commands_systemShutdownCommand=ko.observable(undefined);self.server_commands_systemRestartCommand=ko.observable(undefined);self.server_commands_serverRestartCommand=ko.observable(undefined);self.server_diskspace_warning=ko.observable();self.server_diskspace_critical=ko.observable();self.server_diskspace_warning_str=sizeObservable(self.server_diskspace_warning);self.server_diskspace_critical_str=sizeObservable(self.server_diskspace_critical);self.server_onlineCheck_enabled=ko.observable();self.server_onlineCheck_interval=ko.observable();self.server_onlineCheck_host=ko.observable();self.server_onlineCheck_port=ko.observable();self.server_onlineCheck_name=ko.observable();self.server_pluginBlacklist_enabled=ko.observable();self.server_pluginBlacklist_url=ko.observable();self.server_pluginBlacklist_ttl=ko.observable();self.server_allowFraming=ko.observable();self.settings=undefined;self.lastReceivedSettings=undefined;self.webcam_ffmpegPathText=ko.observable();self.webcam_ffmpegPathOk=ko.observable(false);self.webcam_ffmpegPathBroken=ko.observable(false);self.webcam_ffmpegPathReset=function(){self.webcam_ffmpegPathText("");self.webcam_ffmpegPathOk(false);self.webcam_ffmpegPathBroken(false);};self.server_onlineCheckText=ko.observable();self.server_onlineCheckOk=ko.observable(false);self.server_onlineCheckBroken=ko.observable(false);self.server_onlineCheckReset=function(){self.server_onlineCheckText("");self.server_onlineCheckOk(false);self.server_onlineCheckBroken(false);};self.server_onlineCheckResolutionText=ko.observable();self.server_onlineCheckResolutionOk=ko.observable(false);self.server_onlineCheckResolutionBroken=ko.observable(false);self.server_onlineCheckResolutionReset=function(){self.server_onlineCheckResolutionText("");self.server_onlineCheckResolutionOk(false);self.server_onlineCheckResolutionBroken(false);};var folderTypes=["uploads","timelapse","watched"];var checkForDuplicateFolders=function(){_.each(folderTypes,function(folderType){var path=self["folder_"+folderType]();var duplicate=false;_.each(folderTypes,function(otherFolderType){if(folderType!==otherFolderType){duplicate=duplicate||path===self["folder_"+otherFolderType]();}});self.testFolderConfigDuplicate[folderType](duplicate);});};self.testFolderConfigText={};self.testFolderConfigOk={};self.testFolderConfigBroken={};self.testFolderConfigDuplicate={};self.testFolderConfigError={};self.testFolderConfigSuccess={};_.each(folderTypes,function(folderType){self.testFolderConfigText[folderType]=ko.observable("");self.testFolderConfigOk[folderType]=ko.observable(false);self.testFolderConfigBroken[folderType]=ko.observable(false);self.testFolderConfigDuplicate[folderType]=ko.observable(false);self.testFolderConfigError[folderType]=ko.pureComputed(function(){return(self.testFolderConfigBroken[folderType]()||self.testFolderConfigDuplicate[folderType]());});self.testFolderConfigSuccess[folderType]=ko.pureComputed(function(){return(self.testFolderConfigOk[folderType]()&&!self.testFolderConfigDuplicate[folderType]());});self["folder_"+folderType].subscribe(checkForDuplicateFolders);});self.testFolderConfigReset=function(){_.each(folderTypes,function(folderType){self.testFolderConfigText[folderType]("");self.testFolderConfigOk[folderType](false);self.testFolderConfigBroken[folderType](false);});};self.testFoldersDuplicate=ko.pureComputed(function(){var foundDupe=false;_.each(folderTypes,function(folderType){foundDupe=foundDupe||self.testFolderConfigDuplicate[folderType]();});return foundDupe;});self.observableCopies={feature_waitForStart:"serial_waitForStart",feature_waitToLoadSdFileList:"serial_waitToLoadSdFileList",feature_sendChecksum:"serial_sendChecksum",feature_sdRelativePath:"serial_sdRelativePath",feature_sdAlwaysAvailable:"serial_sdAlwaysAvailable",feature_swallowOkAfterResend:"serial_swallowOkAfterResend",feature_repetierTargetTemp:"serial_repetierTargetTemp",feature_disableExternalHeatupDetection:"serial_disableExternalHeatupDetection",feature_ignoreIdenticalResends:"serial_ignoreIdenticalResends",feature_firmwareDetection:"serial_firmwareDetection",feature_blockWhileDwelling:"serial_blockWhileDwelling",serial_:"feature_"};_.each(self.observableCopies,function(value,key){if(self.hasOwnProperty(value)){self[key]=self[value];}});self.webcamCompat={webcam_streamUrl:"streamUrl",webcam_streamRatio:"streamRatio",webcam_streamTimeout:"streamTimeout",webcam_streamWebrtcIceServers:"webrtcIceServers",webcam_snapshotUrl:"snapshotUrl",webcam_flipH:"flipH",webcam_flipV:"flipV",webcam_rotate90:"rotate90",webcam_cacheBuster:"cacheBuster"};self.addTemperatureProfile=function(){self.temperature_profiles.push({name:"New",extruder:0,bed:0,chamber:0});};self.removeTemperatureProfile=function(profile){self.temperature_profiles.remove(profile);};self.addTerminalFilter=function(){self.terminalFilters.push({name:"New",regex:"(Send:\\s+(N\\d+\\s+)?M105)|(Recv:\\s+(ok\\s+([PBN]\\d+\\s+)*)?.*([BCLPR]|T\\d*):-?\\d+)"});};self.removeTerminalFilter=function(filter){self.terminalFilters.remove(filter);};self.testWebcamFfmpegPathBusy=ko.observable(false);self.testWebcamFfmpegPath=function(){if(!self.webcam_ffmpegPath()){return;}
+if(self.testWebcamFfmpegPathBusy()){return;}
+self.testWebcamFfmpegPathBusy(true);OctoPrint.util.testExecutable(self.webcam_ffmpegPath()).done(function(response){if(!response.result){if(!response.exists){self.webcam_ffmpegPathText(gettext("The path doesn't exist"));}else if(!response.typeok){self.webcam_ffmpegPathText(gettext("The path is not a file"));}else if(!response.access){self.webcam_ffmpegPathText(gettext("The path is not an executable"));}}else{self.webcam_ffmpegPathText(gettext("The path is valid"));}
+self.webcam_ffmpegPathOk(response.result);self.webcam_ffmpegPathBroken(!response.result);}).always(function(){self.testWebcamFfmpegPathBusy(false);});};self.testOnlineConnectivityConfigBusy=ko.observable(false);self.testOnlineConnectivityConfig=function(){if(!self.server_onlineCheck_host())return;if(!self.server_onlineCheck_port())return;if(self.testOnlineConnectivityConfigBusy())return;self.testOnlineConnectivityConfigBusy(true);OctoPrint.util.testServer(self.server_onlineCheck_host(),self.server_onlineCheck_port()).done(function(response){if(!response.result){self.server_onlineCheckText(gettext("The server is not reachable"));}else{self.server_onlineCheckText(gettext("The server is reachable"));}
+self.server_onlineCheckOk(response.result);self.server_onlineCheckBroken(!response.result);}).always(function(){self.testOnlineConnectivityConfigBusy(false);});};self.testOnlineConnectivityResolutionConfigBusy=ko.observable(false);self.testOnlineConnectivityResolutionConfig=function(){if(!self.server_onlineCheck_name())return;if(self.testOnlineConnectivityResolutionConfigBusy())return;self.testOnlineConnectivityResolutionConfigBusy(true);OctoPrint.util.testResolution(self.server_onlineCheck_name()).done(function(response){if(!response.result){self.server_onlineCheckResolutionText(gettext("Name cannot be resolved"));}else{self.server_onlineCheckResolutionText(gettext("Name can be resolved"));}
+self.server_onlineCheckResolutionOk(response.result);self.server_onlineCheckResolutionBroken(!response.result);}).always(function(){self.testOnlineConnectivityResolutionConfigBusy(false);});};self.testFolderConfigBusy=ko.observable(false);self.testFolderConfig=function(folder){var observable="folder_"+folder;if(!self.hasOwnProperty(observable))return;if(self.testFolderConfigBusy())return;self.testFolderConfigBusy(true);var opts={check_type:"dir",check_access:"w",allow_create_dir:true,check_writable_dir:true};var path=self[observable]();OctoPrint.util.testPath(path,opts).done(function(response){if(!response.result){if(response.broken_symlink){self.testFolderConfigText[folder](gettext("The path is a broken symlink."));}else if(!response.exists){self.testFolderConfigText[folder](gettext("The path does not exist and cannot be created."));}else if(!response.typeok){self.testFolderConfigText[folder](gettext("The path is not a folder."));}else if(!response.access){self.testFolderConfigText[folder](gettext("The path is not writable."));}}else{self.testFolderConfigText[folder](gettext("The path is valid"));}
+self.testFolderConfigOk[folder](response.result);self.testFolderConfigBroken[folder](!response.result);}).always(function(){self.testFolderConfigBusy(false);});};self.onSettingsHidden=function(){self.webcam_ffmpegPathReset();self.server_onlineCheckReset();self.server_onlineCheckResolutionReset();self.testFolderConfigReset();};self.isDialogActive=function(){return self.settingsDialog.is(":visible");};self.onStartup=function(){self.settingsDialog=$("#settings_dialog");self.settingsUpdatedDialog=$("#settings_dialog_update_detected");self.translationManagerDialog=$("#settings_appearance_managelanguagesdialog");self.translationUploadElement=$("#settings_appearance_managelanguagesdialog_upload");self.translationUploadButton=$("#settings_appearance_managelanguagesdialog_upload_start");self.translationUploadElement.fileupload({dataType:"json",maxNumberOfFiles:1,autoUpload:false,add:function(e,data){if(data.files.length==0){return false;}
+self.translationUploadFilename(data.files[0].name);self.translationUploadButton.unbind("click");self.translationUploadButton.bind("click",function(){data.submit();return false;});},done:function(e,data){self.translationUploadButton.unbind("click");self.translationUploadFilename(undefined);self.fromTranslationResponse(data.result);},fail:function(e,data){self.translationUploadButton.unbind("click");self.translationUploadFilename(undefined);}});};self.onAllBound=function(allViewModels){self.allViewModels=allViewModels;self.settingsDialog.on("show",function(event){OctoPrint.coreui.settingsOpen=true;if(event.target.id=="settings_dialog"){self.requestTranslationData();callViewModels(allViewModels,"onSettingsShown");}});self.settingsDialog.on("hidden",function(event){OctoPrint.coreui.settingsOpen=false;if(event.target.id=="settings_dialog"){callViewModels(allViewModels,"onSettingsHidden");}});self.settingsDialog.on("beforeSave",function(){callViewModels(allViewModels,"onSettingsBeforeSave");});$(".reload_all",self.settingsUpdatedDialog).click(function(e){e.preventDefault();self.settingsUpdatedDialog.modal("hide");self.requestData();return false;});$(".reload_nonconflicts",self.settingsUpdatedDialog).click(function(e){e.preventDefault();self.settingsUpdatedDialog.modal("hide");self.requestData(true);return false;});$('ul.nav-list a[data-toggle="tab"]',self.settingsDialog).on("show",function(){self._resetScrollPosition();});};self.show=function(tab){self.selectTab(tab);self._resetScrollPosition();self.settingsDialog.modal({minHeight:function(){return Math.max($.fn.modal.defaults.maxHeight()-80,250);}}).css({"margin-left":function(){return-($(this).width()/2);}});return false;};self.hide=function(){self.settingsDialog.modal("hide");};self.generateApiKey=function(){if(!CONFIG_ACCESS_CONTROL)return;showConfirmationDialog(gettext("This will generate a new API Key. The old API Key will cease to function immediately."),function(){OctoPrint.settings.generateApiKey().done(function(response){self.api_key(response.apikey);self.requestData();});});};self.deleteApiKey=()=>{if(!CONFIG_ACCESS_CONTROL)return;if(!self.api_key())return;showConfirmationDialog(gettext("This will delete the API Key. It will cease to to function immediately."),function(){OctoPrint.settings.deleteApiKey().done(()=>{self.api_key(undefined);});});};self.copyApiKey=function(){copyToClipboard(self.api_key());};self.revealingApiKey=ko.observable(false);self.revealApiKey=()=>{self.loginState.reauthenticateIfNecessary(()=>{self.revealingApiKey(true);self.requestData().always(()=>{self.revealingApiKey(false);});});};self.showTranslationManager=function(){self.translationManagerDialog.modal();return false;};self.requestData=function(local){var callback=undefined;if(arguments.length===2||_.isFunction(local)){var exc=new Error();log.warn("The callback parameter of SettingsViewModel.requestData is deprecated, the method now returns a promise, please use that instead. Stacktrace:",exc.stack||exc.stacktrace||"");if(arguments.length===2){callback=arguments[0];local=arguments[1];}else{callback=local;local=false;}}
+var callbackHandler=function(){if(!callback)return;try{callback();}catch(exc){log.error("Error calling settings callback",callback,":",`${exc.message}\n${exc.stack || exc}`);}};if(self.receiving()){var deferred=$.Deferred();self.outstanding.push(deferred);if(callback){deferred.done(callbackHandler);}
+return deferred.promise();}
+self.receiving(true);return OctoPrint.settings.get().always(function(){self.receiving(false);}).done(function(response){self.fromResponse(response,local);if(callback){var deferred=$.Deferred();deferred.done(callbackHandler);self.outstanding.push(deferred);}
+var args=arguments;_.each(self.outstanding,function(deferred){deferred.resolve(args);});self.outstanding=[];}).fail(function(){var args=arguments;_.each(self.outstanding,function(deferred){deferred.reject(args);});self.outstanding=[];});};self.requestTranslationData=function(){return OctoPrint.languages.list().done(self.fromTranslationResponse);};self.fromTranslationResponse=function(response){var translationsByLocale={};_.each(response.language_packs,function(item,key){_.each(item.languages,function(pack){var locale=pack.locale;if(!_.has(translationsByLocale,locale)){translationsByLocale[locale]={locale:locale,display:pack.locale_display,english:pack.locale_english,packs:[]};}
+translationsByLocale[locale]["packs"].push({identifier:key,display:item.display,pack:pack});});});var translations=[];_.each(translationsByLocale,function(item){item["packs"].sort(function(a,b){if(a.identifier=="_core")return-1;if(b.identifier=="_core")return 1;if(a.displayb.display)return 1;return 0;});translations.push(item);});self.translations.updateItems(translations);};self.languagePackDisplay=function(item){return(item.display+
+(item.english!=undefined?" ("+item.english+")":""));};self.languagePacksAvailable=ko.pureComputed(function(){return self.translations.allSize()>0;});self.deleteLanguagePack=function(locale,pack){OctoPrint.languages.delete(locale,pack).done(self.fromTranslationResponse);};self.getLocalData=function(){var data={};if(self.settings!=undefined){data=ko.mapping.toJS(self.settings);}
+var specialMappings={feature:{autoUppercaseBlacklist:function(){return splitTextToArray(self.feature_autoUppercaseBlacklist(),",",true);}},serial:{additionalPorts:function(){return commentableLinesToArray(self.serial_additionalPorts());},additionalBaudrates:function(){return _.map(splitTextToArray(self.serial_additionalBaudrates(),",",true,function(item){return!isNaN(parseInt(item));}),function(item){return parseInt(item);});},blacklistedPorts:function(){return commentableLinesToArray(self.serial_blacklistedPorts());},blacklistedBaudrates:function(){return _.map(splitTextToArray(self.serial_blacklistedBaudrates(),",",true,function(item){return!isNaN(parseInt(item));}),function(item){return parseInt(item);});},longRunningCommands:function(){return splitTextToArray(self.serial_longRunningCommands(),",",true);},checksumRequiringCommands:function(){return splitTextToArray(self.serial_checksumRequiringCommands(),",",true);},blockedCommands:function(){return splitTextToArray(self.serial_blockedCommands(),",",true);},ignoredCommands:function(){return splitTextToArray(self.serial_ignoredCommands(),",",true);},pausingCommands:function(){return splitTextToArray(self.serial_pausingCommands(),",",true);},emergencyCommands:function(){return splitTextToArray(self.serial_emergencyCommands(),",",true);},externalHeatupDetection:function(){return!self.serial_disableExternalHeatupDetection();},alwaysSendChecksum:function(){return self.serial_sendChecksum()==="always";},neverSendChecksum:function(){return self.serial_sendChecksum()==="never";},ignoreErrorsFromFirmware:function(){return self.serial_serialErrorBehaviour()==="ignore";},disconnectOnErrors:function(){return self.serial_serialErrorBehaviour()==="disconnect";}},scripts:{gcode:function(){var result={};var prefix="scripts_gcode_";var observables=_.filter(_.keys(self),function(key){return _.startsWith(key,prefix);});_.each(observables,function(observable){var script=observable.substring(prefix.length);result[script]=self[observable]();});return result;}},temperature:{profiles:function(){var result=[];_.each(self.temperature_profiles(),function(profile){try{result.push({name:profile.name,extruder:Math.floor(_.isNumber(profile.extruder)?profile.extruder:parseInt(profile.extruder)),bed:Math.floor(_.isNumber(profile.bed)?profile.bed:parseInt(profile.bed)),chamber:Math.floor(_.isNumber(profile.chamber)?profile.chamber:_.isNumber(parseInt(profile.chamber))?parseInt(profile.chamber):0)});}catch(ex){}});return result;}}};var mapFromObservables=function(data,mapping,keyPrefix){var flag=false;var result={};_.forOwn(data,function(value,key){var observable=key;if(keyPrefix!==undefined){observable=keyPrefix+"_"+observable;}
+if(self.observableCopies.hasOwnProperty(observable)){return;}
+if(self.webcamCompat.hasOwnProperty(observable)){return;}
+if(mapping&&mapping[key]&&_.isFunction(mapping[key])){result[key]=mapping[key]();flag=true;}else if(_.isPlainObject(value)){var subresult=mapFromObservables(value,mapping&&mapping[key]?mapping[key]:undefined,observable);if(subresult!==undefined){result[key]=subresult;flag=true;}}else if(self.hasOwnProperty(observable)){result[key]=self[observable]();flag=true;}});return flag?result:undefined;};var dataFromObservables=mapFromObservables(data,specialMappings);data=deepMerge(data,dataFromObservables);return data;};self.reauthenticationTimeout=undefined;self.fromResponse=function(response,local){var serverChangedData;var clientChangedData;if(local){serverChangedData=getOnlyChangedData(response,self.lastReceivedSettings);clientChangedData=getOnlyChangedData(self.getLocalData(),self.lastReceivedSettings);}else{serverChangedData=response;clientChangedData=undefined;}
+self.lastReceivedSettings=response;if(self.settings===undefined){self.settings=ko.mapping.fromJS(serverChangedData);}else{ko.mapping.fromJS(serverChangedData,self.settings);}
+var specialMappings={appearance:{defaultLanguage:function(value){self.appearance_defaultLanguage("_default");if(_.includes(self.locale_languages,value)){self.appearance_defaultLanguage(value);}}},feature:{autoUppercaseBlacklist:function(value){self.feature_autoUppercaseBlacklist(value.join(", "));}},serial:{additionalPorts:function(value){self.serial_additionalPorts(value.join("\n"));},additionalBaudrates:function(value){self.serial_additionalBaudrates(value.join(", "));},blacklistedPorts:function(value){self.serial_blacklistedPorts(value.join("\n"));},blacklistedBaudrates:function(value){self.serial_blacklistedBaudrates(value.join(", "));},longRunningCommands:function(value){self.serial_longRunningCommands(value.join(", "));},checksumRequiringCommands:function(value){self.serial_checksumRequiringCommands(value.join(", "));},blockedCommands:function(value){self.serial_blockedCommands(value.join(", "));},ignoredCommands:function(value){self.serial_ignoredCommands(value.join(", "));},pausingCommands:function(value){self.serial_pausingCommands(value.join(", "));},emergencyCommands:function(value){self.serial_emergencyCommands(value.join(", "));},externalHeatupDetection:function(value){self.serial_disableExternalHeatupDetection(!value);},alwaysSendChecksum:function(value){if(value){self.serial_sendChecksum("always");}},neverSendChecksum:function(value){if(value){self.serial_sendChecksum("never");}},ignoreErrorsFromFirmware:function(value){if(value){self.serial_serialErrorBehaviour("ignore");}},disconnectOnErrors:function(value){if(value){self.serial_serialErrorBehaviour("disconnect");}}},terminalFilters:function(value){self.terminalFilters($.extend(true,[],value));},temperature:{profiles:function(value){self.temperature_profiles($.extend(true,[],value));}}};_.each(self.webcamCompat,(mapped,key)=>{if(self.settings.hasOwnProperty(key))return;if(!self.settings.webcam.hasOwnProperty(mapped))return;const message="Please use the webcam system introduced with 1.9.0, the "+
+key+" config setting is deprecated and will be removed in a future release. Stacktrace:";self[key]=ko.pureComputed({read:()=>{const exc=new Error();log.warn(message,exc.stack||exc.stacktrace||"");return self.settings.webcam[mapped]();},write:(value)=>{const exc=new Error();log.warn(message,exc.stack||exc.stacktrace||"");self.settings.webcam[mapped](value);},owner:self});});var mapToObservables=function(data,mapping,local,keyPrefix){if(!_.isPlainObject(data)){return;}
+_.forOwn(data,function(value,key){var observable=key;if(keyPrefix!=undefined){observable=keyPrefix+"_"+observable;}
+if(self.observableCopies.hasOwnProperty(observable)){return;}
+if(self.webcamCompat.hasOwnProperty(observable)){return;}
+var haveLocalVersion=local&&local.hasOwnProperty(key);if(mapping&&mapping[key]&&_.isFunction(mapping[key])&&!haveLocalVersion){mapping[key](value);}else if(_.isPlainObject(value)){mapToObservables(value,mapping&&mapping[key]?mapping[key]:undefined,local&&local[key]?local[key]:undefined,observable);}else if(!haveLocalVersion&&self.hasOwnProperty(observable)){self[observable](value);}});};mapToObservables(serverChangedData,specialMappings,clientChangedData);firstRequest.resolve();self.apiKeyVisible(self.loginState.checkCredentialsSeen());if(self.apiKeyVisible()){self.reauthenticationTimeout=self.loginState.afterReauthenticationTimeout(()=>{self.requestData();},self.reauthenticationTimeout);}};self.cancelData=function(){self.fromResponse(self.lastReceivedSettings);self.hide();};self.saveData=function(data,successCallback,setAsSending){var options;if(_.isPlainObject(successCallback)){options=successCallback;}else{options={success:successCallback,sending:setAsSending===true};}
+self.settingsDialog.trigger("beforeSave");self.sawUpdateEventWhileSending=false;self.sending(data===undefined||options.sending||false);if(data===undefined){var localData=self.getLocalData();data=getOnlyChangedData(localData,self.lastReceivedSettings);}
+if(self.testFoldersDuplicate()){delete data.folder;}
+self.active=true;return OctoPrint.settings.save(data).done(function(data,status,xhr){self.ignoreNextUpdateEvent=!self.sawUpdateEventWhileSending;self.active=false;self.receiving(true);self.sending(false);try{self.fromResponse(data);if(options.success)options.success(data,status,xhr);}finally{self.receiving(false);}}).fail(function(xhr,status,error){self.sending(false);self.active=false;if(options.error)options.error(xhr,status,error);}).always(function(xhr,status){if(options.complete)options.complete(xhr,status);});};self.onEventSettingsUpdated=function(){if(self.active){self.sawUpdateEventWhileActive=true;}
+var preventSettingsRefresh=_.any(self.allViewModels,function(viewModel){if(viewModel.hasOwnProperty("onSettingsPreventRefresh")){try{return viewModel["onSettingsPreventRefresh"]();}catch(e){log.warn("Error while calling onSettingsPreventRefresh on",viewModel,":",e);return false;}}else{return false;}});if(preventSettingsRefresh){return;}
+if(self.isDialogActive()){if(self.sending()||self.receiving()||self.active||self.ignoreNextUpdateEvent){self.ignoreNextUpdateEvent=false;return;}
+if(!hasDataChanged(self.getLocalData(),self.lastReceivedSettings)){self.requestData();}else{self.settingsUpdatedDialog.modal("show");}}else{self.requestData();}};self._resetScrollPosition=function(){$("#settings_dialog_content",self.settingsDialog).scrollTop(0);$('#settings_dialog_content ul.nav-pills a[data-toggle="tab"]:first',self.settingsDialog).tab("show");$('#settings_dialog_content ul.nav-list a[data-toggle="tab"]:first',self.settingsDialog).tab("show");$('#settings_dialog_content ul.nav-tabs a[data-toggle="tab"]:first',self.settingsDialog).tab("show");};self.selectTab=function(tab){if(tab!=undefined){if(!_.startsWith(tab,"#")){tab="#"+tab;}
+$('ul.nav-list a[href="'+tab+'"]',self.settingsDialog).tab("show");}else{$('ul.nav-list a[data-toggle="tab"]:first',self.settingsDialog).tab("show");}};self.onServerReconnect=function(){self.requestData();};self.onUserPermissionsChanged=self.onUserLoggedIn=self.onUserLoggedOut=function(){if(!self._startupComplete)return;self.requestData();};self.validURL=function(str){var pattern=new RegExp("^(https?:\\/\\/)?"+"((([a-z\\d]([a-z\\d-]*[a-z\\d])*)\\.)+[a-z]{2,}|"+"((\\d{1,3}\\.){3}\\d{1,3}))"+"(\\:\\d+)?(\\/[-a-z\\d%_.~+]*)*"+"(\\?[;&a-z\\d%_.~+=-]*)?"+"(\\#[-a-z\\d_]*)?$","i");return!!pattern.test(str);};}
+OCTOPRINT_VIEWMODELS.push({construct:SettingsViewModel,dependencies:["loginStateViewModel","accessViewModel","printerProfilesViewModel","aboutViewModel","usersViewModel"],elements:["#settings_dialog","#navbar_settings"]});});
+;
+
+// source: js/app/viewmodels/slicing.js
+$(function(){function SlicingViewModel(parameters){var self=this;self.loginState=parameters[0];self.printerProfiles=parameters[1];self.printerState=parameters[2];self.access=parameters[3];self.file=ko.observable(undefined);self.target=undefined;self.path=undefined;self.data=undefined;self.defaultSlicer=undefined;self.defaultProfile=undefined;self.destinationFilename=ko.observable();self.gcodeFilename=self.destinationFilename;self.title=ko.observable();self.slicer=ko.observable();self.slicers=ko.observableArray();self.profile=ko.observable();self.profiles=ko.observableArray();self.printerProfile=ko.observable();self.slicerSameDevice=ko.observable();self.allViewModels=undefined;self.slicersForFile=function(file){if(file===undefined){return[];}
+return _.filter(self.configuredSlicers(),function(slicer){return _.any(slicer.sourceExtensions,function(extension){return _.endsWith(file.toLowerCase(),"."+extension.toLowerCase());});});};self.profilesForSlicer=function(key){if(key==undefined){key=self.slicer();}
+if(key==undefined||!self.data.hasOwnProperty(key)){return;}
+var slicer=self.data[key];var selectedProfile=undefined;self.profiles.removeAll();_.each(_.values(slicer.profiles),function(profile){var name=profile.displayName;if(name==undefined){name=profile.key;}
+if(profile.default){selectedProfile=profile.key;}
+self.profiles.push({key:profile.key,name:name});});self.profile(selectedProfile);self.defaultProfile=selectedProfile;};self.resetProfiles=function(){self.profiles.removeAll();self.profile(undefined);};self.metadataForSlicer=function(key){if(key==undefined||!self.data.hasOwnProperty(key)){return;}
+var slicer=self.data[key];self.slicerSameDevice(slicer.sameDevice);};self.resetMetadata=function(){self.slicerSameDevice(true);};self.configuredSlicers=ko.pureComputed(function(){return _.filter(self.slicers(),function(slicer){return slicer.configured;});});self.matchingSlicers=ko.computed(function(){var slicers=self.slicersForFile(self.file());var containsSlicer=function(key){return _.any(slicers,function(slicer){return slicer.key==key;});};var current=self.slicer();if(!containsSlicer(current)){if(self.defaultSlicer!==undefined&&containsSlicer(self.defaultSlicer)){self.slicer(self.defaultSlicer);}else{self.slicer(undefined);self.resetProfiles();}}else{self.profilesForSlicer(self.slicer());}
+return slicers;});self.afterSlicingOptions=[{value:"none",text:gettext("Do nothing")},{value:"select",text:gettext("Select for printing")},{value:"print",text:gettext("Start printing")}];self.afterSlicing=ko.observable("none");self.show=function(target,file,force,path,options){options=options||{};if(!self.enableSlicingDialog()&&!force){return;}
+var filename=file;if(filename.lastIndexOf("/")!=0){path=path||filename.substr(0,filename.lastIndexOf("/"));filename=filename.substr(filename.lastIndexOf("/")+1);}
+var display=options.display||filename;var destination=display.substr(0,display.lastIndexOf("."));self.requestData();self.target=target;self.file(file);self.path=path;self.title(_.sprintf(gettext("Slicing %(filename)s"),{filename:_.escape(display)}));self.destinationFilename(destination);self.printerProfile(self.printerProfiles.currentProfile());self.afterSlicing("none");$("#slicing_configuration_dialog").modal("show");};self.slicer.subscribe(function(newValue){if(newValue===undefined){self.resetProfiles();self.resetMetadata();}else{self.profilesForSlicer(newValue);self.metadataForSlicer(newValue);}});self.enableSlicingDialog=ko.pureComputed(function(){return self.configuredSlicers().length>0;});self.enableSlicingDialogForFile=function(file){return self.slicersForFile(file).length>0;};self.enableSliceButton=ko.pureComputed(function(){return(self.destinationFilename()!=undefined&&self.destinationFilename().trim()!=""&&self.slicer()!=undefined&&self.profile()!=undefined&&(!(self.printerState.isPrinting()||self.printerState.isPaused())||!self.slicerSameDevice()));});self.sliceButtonTooltip=ko.pureComputed(function(){if(!self.enableSliceButton()){if((self.printerState.isPrinting()||self.printerState.isPaused())&&self.slicerSameDevice()){return gettext("Cannot slice on the same device while printing");}else{return gettext("Cannot slice, not all parameters specified");}}else{return gettext("Start the slicing process");}});self.requestData=function(){if(!self.loginState.hasPermission(self.access.permissions.SLICE)){return;}
+return OctoPrint.slicing.listAllSlicersAndProfiles().done(function(data){self.fromResponse(data);});};self.destinationExtension=ko.pureComputed(function(){var fallback="???";if(self.slicer()===undefined){return fallback;}
+var slicer=self.data[self.slicer()];if(slicer===undefined){return fallback;}
+var extensions=slicer.extensions;if(extensions===undefined){return fallback;}
+var destinationExtensions=extensions.destination;if(destinationExtensions===undefined||!destinationExtensions.length){return fallback;}
+return destinationExtensions[0]||fallback;});self.fromResponse=function(data){self.data=data;var selectedSlicer=undefined;self.slicers.removeAll();_.each(_.values(data),function(slicer){var name=slicer.displayName;if(name==undefined){name=slicer.key;}
+if(slicer.default&&slicer.configured){selectedSlicer=slicer.key;}
+var props={key:slicer.key,name:name,configured:slicer.configured,sourceExtensions:slicer.extensions.source,destinationExtensions:slicer.extensions.destination,sameDevice:slicer.sameDevice};self.slicers.push(props);});self.defaultSlicer=selectedSlicer;if(self.allViewModels){callViewModels(self.allViewModels,"onSlicingData",[data]);}};self.slice=function(){if(!self.enableSliceButton()){return;}
+var destinationFilename=self.destinationFilename();var destinationExtensions=self.data[self.slicer()]&&self.data[self.slicer()].extensions&&self.data[self.slicer()].extensions.destination?self.data[self.slicer()].extensions.destination:["???"];if(!_.any(destinationExtensions,function(extension){return _.endsWith(destinationFilename.toLowerCase(),"."+extension.toLowerCase());})){destinationFilename=destinationFilename+"."+destinationExtensions[0];}
+var data={slicer:self.slicer(),profile:self.profile(),printerProfile:self.printerProfile(),destination:destinationFilename};if(self.path!=undefined){data["path"]=self.path;}
+if(self.afterSlicing()=="print"){data["print"]=true;}else if(self.afterSlicing()=="select"){data["select"]=true;}
+OctoPrint.files.slice(self.target,self.file(),data).done(function(){$("#slicing_configuration_dialog").modal("hide");self.destinationFilename(undefined);self.slicer(self.defaultSlicer);self.profile(self.defaultProfile);});};self._sanitize=function(name){return name.replace(/[^a-zA-Z0-9\-_\.\(\) ]/g,"").replace(/ /g,"_");};self.onUserPermissionsChanged=self.onUserLoggedIn=self.onUserLoggedOut=function(){self.requestData();};self.onEventSettingsUpdated=function(payload){self.requestData();};self.onAllBound=function(allViewModels){self.allViewModels=allViewModels;};}
+OCTOPRINT_VIEWMODELS.push({construct:SlicingViewModel,dependencies:["loginStateViewModel","printerProfilesViewModel","printerStateViewModel","accessViewModel"],elements:["#slicing_configuration_dialog"]});});
+;
+
+// source: js/app/viewmodels/system.js
+$(function(){function SystemViewModel(parameters){var self=this;self.loginState=parameters[0];self.access=parameters[1];self.lastCommandResponse=undefined;self.systemActions=ko.observableArray([]);self._startupNotification=undefined;self.requestData=function(){self.requestCommandData();self.requestStartupData();};self.requestCommandData=function(){if(!self.loginState.hasPermission(self.access.permissions.SYSTEM)){return $.Deferred().reject().promise();}
+return OctoPrint.system.getCommands().done(self.fromCommandResponse);};self.fromCommandResponse=function(response){var actions=[];if(response.core&&response.core.length){_.each(response.core,function(data){var action=_.extend({},data);action.actionSource="core";actions.push(action);});if((response.custom&&response.custom.length)||(response.plugin&&response.plugin.length)){actions.push({action:"divider"});}}
+_.each(response.plugin,function(data){var action=_.extend({},data);action.actionSource="plugin";actions.push(action);if(response.custom&&response.custom.length){actions.push({action:"divider"});}});_.each(response.custom,function(data){var action=_.extend({},data);action.actionSource="custom";actions.push(action);});self.lastCommandResponse=response;self.systemActions(actions);};self.requestStartupData=function(){if(!self.loginState.hasPermission(self.access.permissions.SYSTEM)){return $.Deferred().reject().promise();}
+return OctoPrint.system.getStartupData().done(self.fromStartupResponse);};self.fromStartupResponse=function(response){const startupData=response.startup;if(startupData.flagged_basefolders){if(self._startupNotification)self._startupNotification.remove();let html="
"+
+gettext("The following folder(s) were found to be unusable by OctoPrint during startup and have been turned back to the default:")+"
"+
+gettext("Please check the permissions of these folders and make sure they are writable by the user running OctoPrint. In case of network shares, make sure they have been mounted before OctoPrint starts.")+"
");new PNotify({title:gettext("Could not remove timelapse"),text:html,type:"error",hide:false});});};showConfirmationDialog(_.sprintf(gettext('You are about to delete timelapse file "%(name)s".'),{name:_.escape(filename)}),perform);};self.removeMarkedFiles=function(){if(!self.loginState.hasPermission(self.access.permissions.TIMELAPSE_DELETE))
+return;var perform=function(){self._bulkRemove(self.markedForFileDeletion(),"files").done(function(){self.markedForFileDeletion.removeAll();});};showConfirmationDialog(_.sprintf(gettext("You are about to delete %(count)d timelapse files."),{count:self.markedForFileDeletion().length}),perform);};self.enableBulkDownload=ko.pureComputed(function(){return(self.markedForFileDeletion().length&&!self.isBusy()&&!self.bulkDownloadUrlTooLong());});self.bulkDownloadUrlTooLong=ko.pureComputed(function(){return BASEURL.length+self.bulkDownloadUrl().length>=2000;});self.bulkDownloadButtonUrl=ko.pureComputed(function(){var files=self.markedForFileDeletion();if(!files.length||self.bulkDownloadUrlTooLong()){return"javascript:void(0)";}
+return self.bulkDownloadUrl();});self.bulkDownloadUrl=function(){var files=self.markedForFileDeletion();return OctoPrint.timelapse.bulkDownloadUrl(files);};self.markUnrenderedOnPage=function(){self.markedForUnrenderedDeletion(_.uniq(self.markedForUnrenderedDeletion().concat(_.map(self.unrenderedListHelper.paginatedItems(),"name"))));};self.markAllUnrendered=function(){self.markedForUnrenderedDeletion(_.map(self.unrenderedListHelper.allItems,"name"));};self.clearMarkedUnrendered=function(){self.markedForUnrenderedDeletion.removeAll();};self.removeUnrendered=function(name){if(!self.loginState.hasPermission(self.access.permissions.TIMELAPSE_MANAGE_UNRENDERED))
+return;var perform=function(){OctoPrint.timelapse.deleteUnrendered(name).done(function(){self.markedForUnrenderedDeletion.remove(name);self.requestData();});};showConfirmationDialog(_.sprintf(gettext('You are about to delete unrendered timelapse "%(name)s".'),{name:_.escape(name)}),perform);};self.removeMarkedUnrendered=function(){if(!self.loginState.hasPermission(self.access.permissions.TIMELAPSE_MANAGE_UNRENDERED))
+return;var perform=function(){self._bulkRemove(self.markedForUnrenderedDeletion(),"unrendered").done(function(){self.markedForUnrenderedDeletion.removeAll();});};showConfirmationDialog(_.sprintf(gettext("You are about to delete %(count)d unrendered timelapses."),{count:self.markedForUnrenderedDeletion().length}),perform);};self._bulkRemove=function(files,type){var title,message,handler;if(type==="files"){title=gettext("Deleting timelapse files");message=_.sprintf(gettext("Deleting %(count)d timelapse files..."),{count:files.length});handler=function(filename){return OctoPrint.timelapse.delete(filename).done(function(){deferred.notify(_.sprintf(gettext("Deleted %(filename)s..."),{filename:_.escape(filename)}),true);}).fail(function(jqXHR){var short=_.sprintf(gettext("Deletion of %(filename)s failed, continuing..."),{filename:_.escape(filename)});var long=_.sprintf(gettext("Deletion of %(filename)s failed: %(error)s"),{filename:_.escape(filename),error:_.escape(jqXHR.responseText)});deferred.notify(short,long,false);});};}else if(type==="unrendered"){title=gettext("Deleting unrendered timelapses");message=_.sprintf(gettext("Deleting %(count)d unrendered timelapses..."),{count:files.length});handler=function(filename){return OctoPrint.timelapse.deleteUnrendered(filename).done(function(){deferred.notify(_.sprintf(gettext("Deleted %(filename)s..."),{filename:_.escape(filename)}),true);}).fail(function(){deferred.notify(_.sprintf(gettext("Deletion of %(filename)s failed, continuing..."),{filename:_.escape(filename)}),false);});};}else{return;}
+var deferred=$.Deferred();var promise=deferred.promise();var options={title:title,message:message,max:files.length,output:true};showProgressModal(options,promise);var requests=[];_.each(files,function(filename){var request=handler(filename);requests.push(request);});$.when.apply($,_.map(requests,wrapPromiseWithAlways)).done(function(){deferred.resolve();self.requestData();});return promise;};self.renderUnrendered=function(name){if(!self.loginState.hasPermission(self.access.permissions.TIMELAPSE_ADMIN))
+return;OctoPrint.timelapse.renderUnrendered(name).done(self.requestData);};self.save=function(){if(!self.loginState.hasPermission(self.access.permissions.TIMELAPSE_ADMIN))
+return;var payload={type:self.timelapseType(),postRoll:self.timelapsePostRoll(),fps:self.timelapseFps(),save:self.persist()};if(self.timelapseType()==="timed"){payload["interval"]=self.timelapseTimedInterval();}
+if(self.timelapseType()==="zchange"){payload["retractionZHop"]=self.timelapseRetractionZHop();payload["minDelay"]=self.timelapseMinDelay();}
+OctoPrint.timelapse.saveConfig(payload).done(self.fromResponse);};self.reset=function(){if(self.serverConfig()===undefined)return;self.fromConfig(self.serverConfig());};self.displayTimelapsePopup=function(options){if(self.timelapsePopup!==undefined){self.timelapsePopup.remove();}
+_.extend(options,{callbacks:{before_close:function(notice){if(self.timelapsePopup===notice){self.timelapsePopup=undefined;}}}});self.timelapsePopup=new PNotify(options);};self.onDataUpdaterReconnect=function(){self.requestData();};self.onEventPostRollStart=function(payload){var title=gettext("Capturing timelapse postroll");var text;if(!payload.postroll_duration){text=_.sprintf(gettext("Now capturing timelapse post roll, this will take only a moment..."));}else{var format={time:moment().add(payload.postroll_duration,"s").format("LT")};if(payload.postroll_duration>60){format.duration=_.sprintf(gettext("%(minutes)d min"),{minutes:payload.postroll_duration/60});text=_.sprintf(gettext("Now capturing timelapse post roll, this will take approximately %(duration)s (so until %(time)s)..."),format);}else{format.duration=_.sprintf(gettext("%(seconds)d sec"),{seconds:payload.postroll_duration});text=_.sprintf(gettext("Now capturing timelapse post roll, this will take approximately %(duration)s..."),format);}}
+self.displayTimelapsePopup({title:title,text:text,hide:false});};self._warnAboutCaptureFailThreshold=3;self._warnAboutCaptureFailCounter=0;self._warnedAboutCaptureFail=false;self.onEventPrintStarted=function(payload){self._warnAboutCaptureFailCounter=0;self._warnedAboutCaptureFail=false;};self.onEventCaptureDone=function(payload){self._warnAboutCaptureFailCounter=0;self._warnedAboutCaptureFail=false;};self.onEventCaptureFailed=function(payload){self._warnAboutCaptureFailCounter++;if(self._warnedAboutCaptureFail||self._warnAboutCaptureFailCounter<=self._warnAboutCaptureFailThreshold){return;}
+self._warnedAboutCaptureFail=true;var html="
"+
+gettext("Failed repeatedly to capture timelapse frame from webcam - is the snapshot webcam configured correctly and the camera on?");var additional="";if(payload.snapshotDisplay){additional+='Snapshot info:
";}
+if(additional){html+=pnotifyAdditionalInfo(additional);}
+new PNotify({title:gettext("Could not capture snapshots"),text:html,type:"error",hide:false});};self.onEventMovieRendering=function(payload){self.displayTimelapsePopup({title:gettext("Rendering timelapse"),text:_.sprintf(gettext("Now rendering timelapse %(movie_prefix)s. Due to performance reasons it is not recommended to start a print job while a movie is still rendering."),{movie_prefix:_.escape(payload.movie_prefix)}),hide:false});self.renderProgress(0);self.renderTarget(payload.movie_prefix);self.renderAnimation(true);};self.onRenderProgress=function(percentage){self.renderProgress(percentage);self.renderAnimation(false);};self.onEventMovieFailed=function(payload){var title,html;if(payload.reason==="no_frames"){title=gettext("Cannot render timelapse");html="
"+
+_.sprintf(gettext("Rendering of timelapse %(movie_prefix)s is not possible since no frames were captured. Is the snapshot webcam configured correctly?"),{movie_prefix:_.escape(payload.movie_prefix)})+"
"+
+_.sprintf(gettext("Rendering of timelapse %(movie_prefix)s failed with return code %(returncode)s"),{movie_prefix:_.escape(payload.movie_prefix),returncode:_.escape(payload.returncode)})+"
"+
+_.sprintf(gettext("Rendering of timelapse %(movie_prefix)s failed due to an unknown error, please consult the log file"),{movie_prefix:_.escape(payload.movie_prefix)})+"
";}
+self.displayTimelapsePopup({title:title,text:html,type:"error",hide:false});self.renderProgress(0);self.renderTarget(undefined);self.renderAnimation(false);};self.onEventMovieDone=function(payload){self.displayTimelapsePopup({title:gettext("Timelapse ready"),text:_.sprintf(gettext("New timelapse %(movie_prefix)s is done rendering."),{movie_prefix:_.escape(payload.movie_prefix)}),type:"success",callbacks:{before_close:function(notice){if(self.timelapsePopup===notice){self.timelapsePopup=undefined;}}}});self.requestData();self.renderProgress(0);self.renderTarget(undefined);self.renderAnimation(false);};self.onUserPermissionsChanged=self.onUserLoggedIn=self.onUserLoggedOut=function(){self.requestData();self.renderProgressBar=$("#render_progress");};}
+OCTOPRINT_VIEWMODELS.push({construct:TimelapseViewModel,dependencies:["loginStateViewModel","accessViewModel","settingsViewModel"],elements:["#timelapse","#timelapse_link","#timelapsePreviewModal"]});});
+;
+
+// source: js/app/viewmodels/uistate.js
+$(function(){function UiStateViewModel(parameters){var self=this;self.loading=ko.observable(CONFIG_LOADINGANIMATION);self.loading_error=ko.observable(false);self.visible=ko.pureComputed(function(){return!self.loading();});self.showLoadingError=function(error){log.error("Loading error: "+
+error+" Please check prior messages and 'octoprint.log' for possible reasons.");$("#page-container-loading-header").text("Loading failed");$("#page-container-loading-spinner").removeClass("fa-spinner fa-spin").addClass("fa-exclamation-triangle text-error");$("#page-container-loading-error").html(error+" "+
+_.sprintf("Please check your browser's error console and octoprint.log for possible reasons.Also make sure that the server is actually running by reloading this page.",{browser:"https://faq.octoprint.org/browser-console",octoprint:"https://faq.octoprint.org/logs"})).show();};}
+OCTOPRINT_VIEWMODELS.push({construct:UiStateViewModel,elements:["#page-container-main","#page-container-loading"]});});
+;
+
+// source: js/app/viewmodels/users.js
+$(function(){function UsersViewModel(parameters){var self=this;self.access=parameters[0];self.deprecatedUsersMethod=function(oldFct){var newFct=oldFct;if(arguments.length===2){newFct=arguments[1];}
+OctoPrintClient.deprecatedMethod(self,"UsersViewModel",oldFct,"AccessViewModel.users",newFct,function(){self.access.users[newFct](this.arguments);});};self.deprecatedUsersVariable=function(oldVar){var newVar=oldVar;if(arguments.length===2){newVar=arguments[1];}
+OctoPrintClient.deprecatedVariable(self,"UsersViewModel",oldVar,"AccessViewModel.users",newVar,function(){return self.access.users[newVar];},function(val){self.access.users[newVar]=val;});};self.deprecatedUsersVariable("listHelper");self.deprecatedUsersVariable("emptyUser");self.deprecatedUsersVariable("currentUser");self.deprecatedUsersVariable("editorUsername");self.deprecatedUsersVariable("editorGroups");self.deprecatedUsersVariable("editorPermissions");self.deprecatedUsersVariable("editorPassword");self.deprecatedUsersVariable("editorRepeatedPassword");self.deprecatedUsersVariable("editorApikey");self.deprecatedUsersVariable("editorActive");self.deprecatedUsersVariable("editorPasswordMismatch");self.deprecatedUsersMethod("requestData");self.deprecatedUsersMethod("fromResponse");self.deprecatedUsersMethod("showAddUserDialog");self.deprecatedUsersMethod("confirmAddUser");self.deprecatedUsersMethod("showEditUserDialog");self.deprecatedUsersMethod("confirmEditUser");self.deprecatedUsersMethod("showChangePasswordDialog");self.deprecatedUsersMethod("confirmChangePassword");self.deprecatedUsersMethod("confirmGenerateApikey");self.deprecatedUsersMethod("copyApikey");self.deprecatedUsersMethod("confirmDeleteApikey");self.deprecatedUsersMethod("_updateApikey");self.deprecatedUsersMethod("addUser");self.deprecatedUsersMethod("removeUser");self.deprecatedUsersMethod("updateUser");self.deprecatedUsersMethod("updatePassword");self.deprecatedUsersMethod("generateApikey");self.deprecatedUsersMethod("deleteApikey");}
+OCTOPRINT_VIEWMODELS.push({construct:UsersViewModel,dependencies:["accessViewModel"]});});
+;
+
+// source: js/app/viewmodels/usersettings.js
+$(function(){function UserSettingsViewModel(parameters){var self=this;self.loginState=parameters[0];self.access=parameters[1];self.users=self.access.users;self.userSettingsDialog=undefined;var auto_locale={language:"_default",display:gettext("Site default"),english:undefined};self.locales=ko.observableArray([auto_locale].concat(_.sortBy(_.values(AVAILABLE_LOCALES),function(n){return n.display;})));self.locale_languages=_.keys(AVAILABLE_LOCALES);self.access_password=ko.observable(undefined);self.access_repeatedPassword=ko.observable(undefined);self.access_currentPassword=ko.observable(undefined);self.access_currentPasswordMismatch=ko.observable(false);self.access_apikey=ko.observable(undefined);self.interface_language=ko.observable(undefined);self.currentUser=ko.observable(undefined);self.currentUser.subscribe(function(newUser){self.access_password(undefined);self.access_repeatedPassword(undefined);self.access_currentPassword(undefined);self.access_currentPasswordMismatch(false);self.access_apikey(undefined);self.interface_language("_default");if(newUser!==undefined){self.access_apikey(newUser.apikey);if(newUser.settings.hasOwnProperty("interface")&&newUser.settings.interface.hasOwnProperty("language")){self.interface_language(newUser.settings.interface.language);}}});self.access_currentPassword.subscribe(function(){self.access_currentPasswordMismatch(false);});self.passwordMismatch=ko.pureComputed(function(){return self.access_password()!==self.access_repeatedPassword();});self.show=function(user){if(!CONFIG_ACCESS_CONTROL)return;if(user===undefined){user=self.loginState.currentUser();}
+var process=function(user){self.currentUser(user);self.userSettingsDialog.modal("show");};OctoPrint.access.users.get(user.name).done(function(data){process(data);}).fail(function(){log.warn("Could not fetch current user data, proceeding with client side data copy");process(user);});};self.save=function(){if(!CONFIG_ACCESS_CONTROL)return;self.userSettingsDialog.trigger("beforeSave");function saveSettings(){var settings={interface:{language:self.interface_language()}};self.updateSettings(self.currentUser().name,settings).done(function(){self.currentUser(undefined);self.userSettingsDialog.modal("hide");self.loginState.reloadUser();});}
+if(self.access_password()&&!self.passwordMismatch()){self.users.updatePassword(self.currentUser().name,self.access_password(),self.access_currentPassword()).done(function(){saveSettings();}).fail(function(xhr){if(xhr.status===403){self.access_currentPasswordMismatch(true);}});}else{saveSettings();}};self.copyApikey=function(){copyToClipboard(self.access_apikey());};self.generateApikey=function(){if(!CONFIG_ACCESS_CONTROL)return;var generate=function(){self.users.generateApikey(self.currentUser().name).done(function(response){self.access_apikey(response.apikey);});};if(self.access_apikey()){showConfirmationDialog(gettext("This will generate a new API Key. The old API Key will cease to function immediately."),generate);}else{generate();}};self.deleteApikey=function(){if(!CONFIG_ACCESS_CONTROL)return;if(!self.access_apikey())return;showConfirmationDialog(gettext("This will delete the API Key. It will cease to to function immediately."),function(){self.users.deleteApikey(self.currentUser().name).done(function(){self.access_apikey(undefined);});});};self.updateSettings=function(username,settings){return OctoPrint.access.users.saveSettings(username,settings);};self.saveEnabled=function(){return!self.passwordMismatch();};self.onStartup=function(){self.userSettingsDialog=$("#usersettings_dialog");};self.onAllBound=function(allViewModels){self.userSettingsDialog.on("show",function(){callViewModels(allViewModels,"onUserSettingsShown");});self.userSettingsDialog.on("hidden",function(){callViewModels(allViewModels,"onUserSettingsHidden");});self.userSettingsDialog.on("beforeSave",function(){callViewModels(allViewModels,"onUserSettingsBeforeSave");});};}
+OCTOPRINT_VIEWMODELS.push({construct:UserSettingsViewModel,dependencies:["loginStateViewModel","accessViewModel"],elements:["#usersettings_dialog"]});});
+;
+
+// source: js/app/viewmodels/wizard.js
+$(function(){function WizardViewModel(parameters){var self=this;self.loginState=parameters[0];self.settingsViewModel=parameters[1];self.wizardDialog=undefined;self.reloadOverlay=undefined;self.allViewModels=undefined;self.finishing=false;self.wizards=[];self.isDialogActive=function(){return self.wizardDialog.is(":visible");};self.showDialog=function(){if(!CONFIG_WIZARD||(!CONFIG_FIRST_RUN&&!self.loginState.isAdmin()))
+return;self.getWizardDetails().done(function(response){callViewModels(self.allViewModels,"onWizardDetails",[response]);if(!self.isDialogActive()){self.wizardDialog.modal({minHeight:function(){return Math.max($.fn.modal.defaults.maxHeight()-80,250);}}).css({"margin-left":function(){return-($(this).width()/2);}});}
+callViewModels(self.allViewModels,"onWizardShow");callViewModels(self.allViewModels,"onBeforeWizardTabChange",[OCTOPRINT_INITIAL_WIZARD,undefined]);callViewModels(self.allViewModels,"onAfterWizardTabChange",[OCTOPRINT_INITIAL_WIZARD]);});};self.closeDialog=function(){self.wizardDialog.modal("hide");};self.onStartup=function(){self.wizardDialog=$("#wizard_dialog");self.wizardDialog.on("show",function(event){OctoPrint.coreui.wizardOpen=true;});self.wizardDialog.on("hidden",function(event){OctoPrint.coreui.wizardOpen=false;});self.reloadOverlay=$("#reloadui_overlay");};self.onUserLoggedIn=function(){self.showDialog();};self.onAllBound=function(allViewModels){self.allViewModels=allViewModels;self.wizardDialog.bootstrapWizard({tabClass:"nav nav-list",nextSelector:".button-next",previousSelector:".button-previous",finishSelector:".button-finish",withVisible:false,onTabClick:function(){return false;},onTabShow:function(tab,navigation,index){if(index<0||tab.length==0){return true;}
+var total=self.wizardDialog.bootstrapWizard("navigationLength");if(index==total){self.wizardDialog.find(".button-next").hide();self.wizardDialog.find(".button-finish").show().removeClass("disabled");}else{self.wizardDialog.find(".button-finish").hide();self.wizardDialog.find(".button-next").show();}
+var active=tab[0].id;if(active!=undefined){callViewModels(allViewModels,"onAfterWizardTabChange",[active]);}},onTabChange:function(tab,navigation,index,nextTabIndex,nextTab){var current,next;if(index==undefined||index<0||nextTabIndex==undefined||nextTabIndex<0||index==nextTabIndex||tab.length==0||nextTab.length==0){return;}
+current=tab[0].id;next=nextTab[0].id;if(current!=undefined&&next!=undefined){var result=true;callViewModels(allViewModels,"onBeforeWizardTabChange",function(method){result=method(next,current)!==false&&result;});callViewModels(allViewModels,"onWizardTabChange",function(method,viewModel){log.warn("View model",viewModel,'is using deprecated callback "onWizardTabChange", please change to "onBeforeWizardTabChange"');result=method(current,next)!==false&&result;});return result;}},onFinish:function(tab,navigation,index){var closeDialog=true;callViewModels(allViewModels,"onBeforeWizardFinish",function(method){closeDialog=closeDialog&&method()!==false;});if(closeDialog){var reload=false;callViewModels(allViewModels,"onWizardFinish",function(method){reload=method()=="reload"||reload;});self.finishWizard().done(function(){self.closeDialog();if(reload){self.reloadOverlay.show();}
+callViewModels(allViewModels,"onAfterWizardFinish");});}}});self.showDialog();};self.getWizardDetails=function(){return OctoPrint.wizard.get().done(function(response){self.wizards=_.filter(_.keys(response),function(key){return(response[key]&&response[key]["required"]&&!response[key]["ignored"]);});});};self.finishWizard=function(){var deferred=$.Deferred();self.finishing=true;self.settingsViewModel.saveData().done(function(){OctoPrint.wizard.finish(self.wizards).done(function(){deferred.resolve(arguments);}).fail(function(){deferred.reject(arguments);}).always(function(){self.finishing=false;});}).fail(function(){deferred.reject(arguments);});return deferred;};self.onSettingsPreventRefresh=function(){return self.isDialogActive();};}
+OCTOPRINT_VIEWMODELS.push({construct:WizardViewModel,dependencies:["loginStateViewModel","settingsViewModel"],elements:["#wizard_dialog"]});});
+;
+
+// source: js/app/viewmodels/about.js
+$(function(){function AboutViewModel(parameters){var self=this;self.loginState=parameters[0];self.access=parameters[1];self.aboutDialog=undefined;self.aboutContent=undefined;self.aboutTabs=undefined;self.systeminfo=ko.observableArray();self.devmode=getQueryParameterByName("devmode")!==null;self.getSystemInfo=function(){if(!self.loginState.hasPermission(self.access.permissions.SYSTEM))return;return OctoPrint.system.getInfo().done(self.fromSystemInfo);};self.fromSystemInfo=function(r){var systeminfo=[];_.forOwn(r.systeminfo,function(value,key){systeminfo.push({key:key,value:value});});self.systeminfo(systeminfo);};self.copySystemInfo=function(){var text="";_.each(self.systeminfo(),function(entry){text+=entry.key+": "+entry.value+"\r\n";});copyToClipboard(text);};self.show=function(tab){if(tab){$('a[href="#'+tab+'"]',self.aboutTabs).tab("show");}else{$("a:first",self.aboutTabs).tab("show");}
+self.aboutContent.scrollTop(0);const maxHeight=$.fn.modal.defaults.maxHeight()-80-60;self.aboutDialog.modal({minHeight:function(){return Math.max(maxHeight,250);},maxHeight:maxHeight}).css({"margin-left":function(){return-($(this).width()/2);}});self.getSystemInfo();return false;};self.hide=function(){self.aboutDialog.modal("hide");};self.onStartup=function(){self.aboutDialog=$("#about_dialog");self.aboutTabs=$("#about_dialog_tabs");self.aboutContent=$("#about_dialog_content");$('a[data-toggle="tab"]',self.aboutTabs).on("show",function(){self.aboutContent.scrollTop(0);});};self.onAllBound=function(allViewModels){self.aboutDialog.on("show",function(){callViewModels(allViewModels,"onAboutShown");});self.aboutDialog.on("hidden",function(){callViewModels(allViewModels,"onAboutHidden");});};self.showTab=function(tab){$('a[href="#'+tab+'"]',self.aboutTabs).tab("show");};}
+OCTOPRINT_VIEWMODELS.push({construct:AboutViewModel,elements:["#about_dialog","#footer_about","#footer_achievements","#footer_systeminfo"],dependencies:["loginStateViewModel","accessViewModel"]});});
+;
+
+// source: plugin/achievements/js/achievements.js
+$(function(){function AchievementsViewModel(parameters){var self=this;self.loginState=parameters[0];self.access=parameters[1];self.stats=undefined;self.statsFetched=ko.observable(false);self.dummy=ko.observable();self.achievements=ko.observableArray([]);self.hiddenAchievements=ko.observable();self.achievedAchievements=ko.observable();self.totalAchievements=ko.observable();self.collectingSince=ko.pureComputed(()=>{self.dummy();if(!self.statsFetched()){return"n/a";}
+return`${formatDate(self.stats.created())} (${formatTimeAgo(
+ self.stats.created()
+ )})`;});self.collectionVersion=ko.pureComputed(()=>{if(!self.statsFetched()){return"n/a";}
+return`OctoPrint ${self.stats.created_version()}`;});self.prints=ko.pureComputed(()=>{if(!self.statsFetched()){return"n/a";}
+if(self.stats.prints_started()===0){return gettext("No prints yet");}
+return _.sprintf(gettext("%(prints)s (%(finished)s finished)"),{prints:this.stats.prints_started(),finished:self.stats.prints_finished()});});self.duration=ko.pureComputed(()=>{if(!self.statsFetched()){return"n/a";}
+if(!self.stats.print_duration_finished()){return _.sprintf(gettext("%(total)s"),{total:formatDuration(self.stats.print_duration_total())});}else{return _.sprintf(gettext("%(total)s (%(finished)s finished)"),{total:formatDuration(self.stats.print_duration_total()),finished:formatDuration(self.stats.print_duration_finished())});}});self.longestPrint=ko.pureComputed(()=>{self.dummy();if(!self.statsFetched()){return"n/a";}
+return _.sprintf(gettext("%(duration)s (finished on %(date)s, %(timeSince)s)"),{duration:formatDuration(self.stats.longest_print_duration()),date:formatDate(self.stats.longest_print_date()),timeSince:formatTimeAgo(self.stats.longest_print_date())});});self.hiddenAchievementsText=ko.pureComputed(()=>{return _.sprintf(gettext("... and %(count)s hidden achievements!"),{count:self.hiddenAchievements()});});self.requestData=()=>{if(!self.loginState.hasPermission(self.access.permissions.PLUGIN_ACHIEVEMENTS_VIEW)){return;}
+OctoPrint.plugins.achievements.get().done(self.fromResponse);};self.fromResponse=(response)=>{self.fromStatsResponse(response.stats);self.fromAchievementsResponse(response.achievements);const achieved=_.filter(self.achievements(),(achievement)=>achievement.achieved).length;self.achievedAchievements(achieved);self.hiddenAchievements(response.hidden_achievements);self.totalAchievements(response.achievements.length+response.hidden_achievements);};self.fromStatsResponse=(response)=>{if(self.stats===undefined){self.stats=ko.mapping.fromJS(response);self.statsFetched(true);}else{ko.mapping.fromJS(response,self.stats);}};self.fromAchievementsResponse=(response)=>{self.achievements(response);};self.CALLS_TO_ACTION=[gettext('Enjoying OctoPrint? Looks like it! It might be time to give something back then - thank you!'),gettext('Getting value from OctoPrint? Then please consider supporting its sole maintainer with a donation - thank you!'),gettext('Has OctoPrint helped you enjoy your printer more? Then please consider supporting its continued development - thank you!')];self.showAchievement=(achievement)=>{let html=`
"+
+gettext(_.sprintf("... and %(rest)d more.",{rest:rest}))+"
";}
+text+=""+
+gettext("You can edit your announcement subscriptions under Settings > Announcements.")+"";var options={title:channel,text:text,hide:false,confirm:{confirm:true,buttons:[{text:gettext("Later"),click:function(notice){notice.remove();self.hiddenChannels.push(key);}},{text:gettext("Mark read"),click:function(notice){notice.remove();self.markRead(key,value.last);}},{text:gettext("Read..."),addClass:"btn-primary",click:function(notice){notice.remove();self.showAnnouncementDialog(key);self.markRead(key,value.last);}}]},buttons:{sticker:false,closer:false}};if(priority===1){options.type="error";}
+if(self.channelNotifications[key]){self.channelNotifications[key].remove();}
+self.channelNotifications[key]=new PNotify(options);});};self.hideAnnouncements=function(){_.each(self.channelNotifications,function(notification,key){notification.remove();});self.channelNotifications={};};self.configureAnnouncements=function(){self.settings.show("settings_plugin_announcements");};self.onUserPermissionsChanged=self.onUserLoggedIn=self.onUserLoggedOut=function(){if(!self.loginState.hasPermission(self.access.permissions.PLUGIN_ANNOUNCEMENTS_READ)){self.hideAnnouncements();}else{self.retrieveData();}};self.onStartup=function(){self.announcementDialog=$("#plugin_announcements_dialog");self.announcementDialogContent=$("#plugin_announcements_dialog_content");self.announcementDialogTabs=$("#plugin_announcements_dialog_tabs");};self.onEventConnectivityChanged=function(payload){if(!payload||!payload.new)return;self.retrieveData();};}
+OCTOPRINT_VIEWMODELS.push({construct:AnnouncementsViewModel,dependencies:["loginStateViewModel","settingsViewModel","accessViewModel"],elements:["#plugin_announcements_dialog","#settings_plugin_announcements","#navbar_plugin_announcements"]});});
+;
+
+// source: plugin/appkeys/js/appkeys.js
+$(function(){function AppKeysDialogViewModel(parameters){var self=this;self.dialog=undefined;self.onStartup=function(){self.dialog=$("#plugin_appkeys_keygenerated");self.dialog.on("hidden",()=>{self.resetDialog();});};self.showDialog=function(title,data){if(self.dialog===undefined)return;var qrcode={text:data.api_key,size:180,fill:"#000",background:null,label:"",fontname:"sans",fontcolor:"#000",radius:0,ecLevel:"L"};self.dialog.find("#plugin_appkeys_keygenerated_title").text(title);self.dialog.find("#plugin_appkeys_keygenerated_user").text(data.user_id);self.dialog.find("#plugin_appkeys_keygenerated_app").text(data.app_id);self.dialog.find("#plugin_appkeys_keygenerated_key_text").text(data.api_key);self.dialog.find("#plugin_appkeys_keygenerated_key_copy").off().click(function(){copyToClipboard(data.api_key);});self.dialog.find("#plugin_appkeys_keygenerated_key_qrcode").empty().qrcode(qrcode);self.dialog.modal("show");};self.resetDialog=()=>{if(self.dialog===undefined)return;self.dialog.find("#plugin_appkeys_keygenerated_title").text("");self.dialog.find("#plugin_appkeys_keygenerated_user").text("");self.dialog.find("#plugin_appkeys_keygenerated_app").text("");self.dialog.find("#plugin_appkeys_keygenerated_key_text").text("");self.dialog.find("#plugin_appkeys_keygenerated_key_copy").off();self.dialog.find("#plugin_appkeys_keygenerated_key_qrcode").empty();};}
+function UserAppKeysViewModel(parameters){var self=this;self.dialog=parameters[0];self.loginState=parameters[1];self.keys=new ItemListHelper("plugin.appkeys.userkeys",{app:function(a,b){if(a["app_id"].toLowerCase()b["app_id"].toLowerCase())return 1;return 0;}},{},"app",[],[],5);self.pending={};self.openRequests={};self.editorApp=ko.observable();self.requestData=function(){return OctoPrint.plugins.appkeys.getKeys().done(self.fromResponse);};self.fromResponse=function(response){self.keys.updateItems(response.keys);self.pending=response.pending;_.each(self.pending,function(data,token){self.openRequests[token]=self.promptForAccess(data.app_id,token);});};self.generateKey=function(){self.loginState.reauthenticateIfNecessary(()=>{OctoPrint.plugins.appkeys.generateKey(self.editorApp()).done(self.requestData).done(function(){self.editorApp("");});});};self.revokeKey=(data)=>{const app=data.app_id;self.loginState.reauthenticateIfNecessary(()=>{showConfirmationDialog(_.sprintf(gettext("You are about to revoke the application key for %(app)s."),{app:_.escape(app)}),()=>{OctoPrint.plugins.appkeys.revokeKeyForApp(app).done(self.requestData);});});};self.showKeyDetails=(data)=>{self.loginState.reauthenticateIfNecessary(()=>{OctoPrint.plugins.appkeys.getKey(data.app_id).done((response)=>{self.dialog.showDialog(gettext("Details"),response.key);});});};self.allowApp=function(token){return OctoPrint.plugins.appkeys.decide(token,true).done(self.requestData);};self.denyApp=function(token){return OctoPrint.plugins.appkeys.decide(token,false).done(self.requestData);};self.promptForAccess=function(app,token){var message=gettext('"%(app)s" has requested access to control OctoPrint through the API.');message=_.sprintf(message,{app:_.escape(app)});message="
"+
+message+"
"+
+gettext("Do you want to allow access to this application with your user account?")+"
";return new PNotify({title:gettext("Access Request"),text:message,hide:false,icon:"fa fa-key",confirm:{confirm:true,buttons:[{text:gettext("Allow"),click:function(notice){self.loginState.reauthenticateIfNecessary(()=>{self.allowApp(token);notice.remove();});}},{text:gettext("Deny"),click:function(notice){self.denyApp(token);notice.remove();}}]},buttons:{sticker:false,closer:false}});};self.onUserSettingsShown=function(){self.requestData();};self.onUserLoggedIn=function(){self.requestData();};self.onDataUpdaterPluginMessage=function(plugin,data){if(plugin!=="appkeys"){return;}
+var app,token,user;if(data.type==="request_access"&&self.loginState.isUser()){app=data.app_name;token=data.user_token;user=data.user_id;if(user&&user!==self.loginState.username()){return;}
+if(self.pending[token]!==undefined){return;}
+self.openRequests[token]=self.promptForAccess(app,token);}else if(data.type==="end_request"){token=data.user_token;if(self.openRequests[token]!==undefined){if(self.openRequests[token].state!=="closed"){self.openRequests[token].remove();}
+delete self.openRequests[token];}}};}
+function AllAppKeysViewModel(parameters){var self=this;self.dialog=parameters[0];self.loginState=parameters[1];self.access=parameters[2];self.keys=new ItemListHelper("plugin.appkeys.allkeys",{user_app:function(a,b){if(a["user_id"]>b["user_id"])return 1;if(a["user_id"]b["app_id"].toLowerCase())return 1;if(a["app_id"].toLowerCase(){self.loginState.reauthenticateIfNecessary(()=>{OctoPrint.plugins.appkeys.getKey(data.app_id,data.user_id).done((response)=>{self.dialog.showDialog(gettext("Details"),response.key);});});};self.generateKey=function(){self.loginState.reauthenticateIfNecessary(()=>{OctoPrint.plugins.appkeys.generateKeyForUser(self.editorUser(),self.editorApp()).done(self.requestData).done(function(){self.editorUser(self.loginState.username());self.editorApp("");}).done(function(data){self.dialog.showDialog(gettext("New key generated!"),data);});});};self.revokeKey=function(data){const app=data.app_id;const user=data.user_id;showConfirmationDialog(_.sprintf(gettext("You are about to revoke the application key for %(app)s for user %(user)s."),{app:_.escape(app),user:_.escape(user)}),()=>{self.loginState.reauthenticateIfNecessary(()=>{OctoPrint.plugins.appkeys.revokeKeyForApp(app,user).done(self.requestData);});});};self.revokeMarked=function(){showConfirmationDialog(_.sprintf(gettext("You are about to revoke %(count)d application keys."),{count:self.markedForDeletion().length}),()=>{self.loginState.forceReauthentication(()=>{self._bulkRevoke(self.markedForDeletion()).done(()=>{self.markedForDeletion.removeAll();});});});};self.markAllOnPageForDeletion=function(){self.markedForDeletion(_.uniq(self.markedForDeletion().concat(_.map(self.keys.paginatedItems(),(item)=>`${item.user_id}:${item.app_id}`))));};self.markAllForDeletion=function(){self.markedForDeletion(_.uniq(_.map(self.keys.allItems,(item)=>`${item.user_id}:${item.app_id}`)));};self.markAllByUserForDeletion=function(user){self.markAllByFilterForDeletion(function(e){return e.user_id===user;});};self.markAllByAppForDeletion=function(app){self.markAllByFilterForDeletion(function(e){return e.app_id.toLowerCase()===app;});};self.markAllByFilterForDeletion=function(filter){self.markedForDeletion(_.uniq(self.markedForDeletion().concat(_.map(_.filter(self.keys.allItems,filter),(item)=>`${item.user_id}:${item.app_id}`))));};self.clearMarked=function(){self.markedForDeletion.removeAll();};self._bulkRevoke=function(keys){var title,message,handler;title=gettext("Revoking application keys");message=_.sprintf(gettext("Revoking %(count)d application keys..."),{count:keys.length});handler=function(id){const[user,app]=rsplit(id,":",1);return OctoPrint.plugins.appkeys.revokeKeyForApp(app,user).done(function(){deferred.notify(_.sprintf(gettext("Revoked %(app)s for %(user)s..."),{app:_.escape(app),user:_.escape(user)}),true);}).fail(function(jqXHR){var short=_.sprintf(gettext("Revocation of %(app)s for user %(user)s failed, continuing..."),{app:_.escape(app),user:_.escape(user)});var long=_.sprintf(gettext("Deletion of %(app)s for user %(user)s failed: %(error)s"),{app:_.escape(app),user:_.escape(user),error:_.escape(jqXHR.responseText)});deferred.notify(short,long,false);});};var deferred=$.Deferred();var promise=deferred.promise();var options={title:title,message:message,max:keys.length,output:true};showProgressModal(options,promise);var requests=[];_.each(keys,function(key){var request=handler(key);requests.push(request);});$.when.apply($,_.map(requests,wrapPromiseWithAlways)).done(function(){deferred.resolve();self.requestData();});return promise;};}
+OCTOPRINT_VIEWMODELS.push([AppKeysDialogViewModel,[],[]]);OCTOPRINT_VIEWMODELS.push([UserAppKeysViewModel,["appKeysDialogViewModel","loginStateViewModel"],["#usersettings_plugin_appkeys"]]);OCTOPRINT_VIEWMODELS.push([AllAppKeysViewModel,["appKeysDialogViewModel","loginStateViewModel","accessViewModel"],["#settings_plugin_appkeys"]]);});
+;
+
+// source: plugin/backup/js/backup.js
+$(function(){function BackupViewModel(parameters){var self=this;self.loginState=parameters[0];self.settings=parameters[1];self.backups=new ItemListHelper("plugin.backup.backups",{date:function(a,b){if(a["date"]>b["date"])return-1;if(a["date"]self.maxUploadSize();};const backupFileuploadOptionsFactory=(source)=>{return{dataType:"json",maxNumberOfFiles:1,autoUpload:false,add:(e,data)=>{if(data.files.length===0){return false;}
+self.backupUploadName(data.files[0].name);self.backupUploadData=data;self.backupUploadSource=source;},done:(e,data)=>{self.backupUploadName(undefined);self.backupUploadData=undefined;self.backupUploadSource=undefined;}};};$("#settings-backup-upload").fileupload(backupFileuploadOptionsFactory("settings"));$("#wizard-backup-upload").fileupload(backupFileuploadOptionsFactory("wizard"));self.restoreInProgress=ko.observable(false);self.restoreTitle=ko.observable();self.restoreDialog=undefined;self.restoreOutput=undefined;self.unknownPlugins=ko.observableArray([]);self.loglines=ko.observableArray([]);self.requestData=function(){OctoPrint.plugins.backup.get().done(self.fromResponse);};self.fromResponse=function(response){self.backups.updateItems(response.backups);self.unknownPlugins(response.unknown_plugins);self.restoreSupported(response.restore_supported);self.maxUploadSize(response.max_upload_size);};self.reauthenticateDownload=(url)=>{self.loginState.reauthenticateIfNecessary(()=>{const link=document.createElement("a");link.href=url;link.download="";document.body.appendChild(link);link.click();document.body.removeChild(link);});};self.createBackup=function(){var excluded=self.excludeFromBackup();OctoPrint.plugins.backup.createBackup(excluded).done(function(){self.excludeFromBackup([]);});};self.removeBackup=function(backup){var perform=function(){OctoPrint.plugins.backup.deleteBackup(backup).done(function(){self.requestData();});};showConfirmationDialog(_.sprintf(gettext('You are about to delete backup file "%(name)s".'),{name:_.escape(backup)}),perform);};self.restoreBackup=function(backup){if(!self.restoreSupported())return;showConfirmationDialog(_.sprintf(gettext('You are about to restore the backup file "%(name)s". This cannot be undone.'),{name:_.escape(backup)}),()=>{self.loginState.reauthenticateIfNecessary(()=>{self.restoreInProgress(true);self.loglines.removeAll();self.loglines.push({line:"Preparing to restore...",stream:"message"});self.loglines.push({line:" ",stream:"message"});self.restoreDialog.modal({keyboard:false,backdrop:"static",show:true});OctoPrint.plugins.backup.restoreBackup(backup);});});};self.performRestoreFromUpload=function(){if(self.backupUploadData===undefined)return;const proceed=()=>{self.restoreInProgress(true);self.loglines.removeAll();self.loglines.push({line:"Uploading backup, this can take a while. Please wait...",stream:"message"});self.loglines.push({line:" ",stream:"message"});self.restoreDialog.modal({keyboard:false,backdrop:"static",show:true});self.backupUploadData.submit();};showConfirmationDialog(_.sprintf(gettext('You are about to upload and restore the backup file "%(name)s". This cannot be undone.'),{name:_.escape(self.backupUploadName())}),()=>{if(self.backupUploadSource==="wizard"){proceed();}else{self.loginState.reauthenticateIfNecessary(proceed);}});};self.deleteUnknownPluginRecord=function(){var perform=function(){OctoPrint.plugins.backup.deleteUnknownPlugins().done(function(){self.requestData();});};showConfirmationDialog(gettext("You are about to delete the record of plugins unknown during the last restore."),perform);};self.markFilesOnPage=function(){self.markedForBackupDeletion(_.uniq(self.markedForBackupDeletion().concat(_.map(self.backups.paginatedItems(),"name"))));};self.markAllFiles=function(){self.markedForBackupDeletion(_.map(self.backups.allItems,"name"));};self.clearMarkedFiles=function(){self.markedForBackupDeletion.removeAll();};self.removeMarkedFiles=function(){var perform=function(){self._bulkRemove(self.markedForBackupDeletion()).done(function(){self.markedForBackupDeletion.removeAll();});};showConfirmationDialog(_.sprintf(gettext("You are about to delete %(count)d backups."),{count:self.markedForBackupDeletion().length}),perform);};self.onStartup=function(){self.restoreDialog=$("#settings_plugin_backup_restoredialog");self.restoreOutput=$("#settings_plugin_backup_restoredialog_output");};self.onSettingsShown=function(){self.requestData();};self.onDataUpdaterPluginMessage=function(plugin,data){if(plugin!=="backup")return;if(data.type==="backup_done"){self.requestData();self.backupInProgress(false);new PNotify({title:gettext("Backup created successfully"),type:"success"});}else if(data.type==="backup_started"){self.backupInProgress(true);}else if(data.type==="backup_error"){self.requestData();self.backupInProgress(false);new PNotify({title:gettext("Creating the backup failed"),text:_.sprintf(gettext("OctoPrint could not create your backup. Please consult octoprint.log for details. Error: %(error)s"),{error:_.escape(data.error)}),type:"error",hide:false});}else if(data.type==="restore_started"){self.loglines.push({line:gettext("Restoring from backup..."),stream:"message"});self.loglines.push({line:" ",stream:"message"});}else if(data.type==="restore_failed"){self.loglines.push({line:" ",stream:"message"});self.loglines.push({line:gettext("Restore failed! Check the above output and octoprint.log for reasons as to why."),stream:"error"});self.restoreInProgress(false);}else if(data.type==="restore_done"){self.loglines.push({line:" ",stream:"message"});self.loglines.push({line:gettext("Restore successful! The server will now be restarted!"),stream:"message"});self.restoreInProgress(false);}else if(data.type==="installing_plugin"){self.loglines.push({line:" ",stream:"message"});self.loglines.push({line:_.sprintf(gettext('Installing plugin "%(plugin)s"...'),{plugin:_.escape(data.plugin)}),stream:"message"});}else if(data.type==="plugin_incompatible"){self.loglines.push({line:" ",stream:"message"});self.loglines.push({line:_.sprintf(gettext('Cannot install plugin "%(plugin)s" due to it being incompatible to this OctoPrint version and/or underlying operating system'),{plugin:_.escape(data.plugin.key)}),stream:"stderr"});}else if(data.type==="unknown_plugins"){if(data.plugins.length>0){self.loglines.push({line:" ",stream:"message"});self.loglines.push({line:_.sprintf(gettext("There are %(count)d plugins you'll need to install manually since they aren't registered on the repository:"),{count:data.plugins.length}),stream:"message"});_.each(data.plugins,function(plugin){self.loglines.push({line:plugin.name+": "+plugin.url,stream:"message"});});self.loglines.push({line:" ",stream:"message"});self.unknownPlugins(data.plugins);}}else if(data.type==="logline"){self.loglines.push(self._preprocessLine({line:data.line,stream:data.stream}));self._scrollRestoreOutputToEnd();}};self._scrollRestoreOutputToEnd=function(){self.restoreOutput.scrollTop(self.restoreOutput[0].scrollHeight-self.restoreOutput.height());};self._forcedStdoutLine=/You are using pip version .*?, however version .*? is available\.|You should consider upgrading via the '.*?' command\./;self._preprocessLine=function(line){if(line.stream==="stderr"&&line.line.match(self._forcedStdoutLine)){line.stream="stdout";}
+return line;};self._bulkRemove=function(files){var title,message,handler;title=gettext("Deleting backups");message=_.sprintf(gettext("Deleting %(count)d backups..."),{count:files.length});handler=function(filename){return OctoPrint.plugins.backup.deleteBackup(filename).done(function(){deferred.notify(_.sprintf(gettext("Deleted %(filename)s..."),{filename:_.escape(filename)}),true);}).fail(function(jqXHR){var short=_.sprintf(gettext("Deletion of %(filename)s failed, continuing..."),{filename:_.escape(filename)});var long=_.sprintf(gettext("Deletion of %(filename)s failed: %(error)s"),{filename:_.escape(filename),error:_.escape(jqXHR.responseText)});deferred.notify(short,long,false);});};var deferred=$.Deferred();var promise=deferred.promise();var options={title:title,message:message,max:files.length,output:true};showProgressModal(options,promise);var requests=[];_.each(files,function(filename){var request=handler(filename);requests.push(request);});$.when.apply($,_.map(requests,wrapPromiseWithAlways)).done(function(){deferred.resolve();self.requestData();});return promise;};}
+OCTOPRINT_VIEWMODELS.push({construct:BackupViewModel,dependencies:["loginStateViewModel","settingsViewModel"],elements:["#settings_plugin_backup","#wizard_plugin_backup"]});});
+;
+
+// source: plugin/classicwebcam/js/classicwebcam.js
+$(function(){function ClassicWebcamViewModel(parameters){var self=this;self.loginState=parameters[0];self.settings=parameters[1];self.webcamStreamVisible=false;self.webcamDisableTimeout=undefined;self.webcamLoaded=ko.observable(false);self.webcamMjpgEnabled=ko.observable(false);self.webcamHlsEnabled=ko.observable(false);self.webcamWebRTCEnabled=ko.observable(false);self.webcamError=ko.observable(false);self.webcamMuted=ko.observable(true);self.webRTCPeerConnection=null;self.webcamElementHls=null;self.webcamElementWebrtc=null;self.webcamRatioClass=ko.pureComputed(function(){if(self.settings.streamRatio()=="4:3"){return"ratio43";}else{return"ratio169";}});self.webcamClass=ko.pureComputed(function(){if(self.settings.rotate90()){return"webcam_rotated "+self.webcamRatioClass();}else{return"webcam_unrotated "+self.webcamRatioClass();}});self.onBeforeBinding=function(){self.settings.rotate90.subscribe(function(){window.setTimeout(function(){self._updateVideoTagWebcamLayout();},1);});self.streamUrlEscaped=ko.pureComputed(function(){return encodeURI(self.settings.streamUrl());});self.webcamStreamType=ko.pureComputed(function(){try{return self.determineWebcamStreamType(self.streamUrlEscaped());}catch(e){console.error(e);self.webcamError(true);return"mjpg";}});self.webcamStreamValid=ko.pureComputed(function(){var url=self.streamUrlEscaped();return!url||validateWebcamUrl(url);});};self.onWebcamVisibilityChange=function(visible){self.webcamStreamVisible=visible;if(self.webcamStreamVisible){self._enableWebcam();}else{self._disableWebcam();}};self.onWebcamRefresh=function(){var streamType=self.webcamStreamType();if(streamType=="mjpg"){if(OctoPrint.coreui.browser.safari){return;}
+$("#webcam_image").attr("src","");self._switchToMjpgWebcam();log.info("Triggered refresh of mjpg webcam stream");}};self.onEventSettingsUpdated=function(payload){self._enableWebcamIfVisible();};self._getActiveWebcamVideoElement=function(){if(self.webcamWebRTCEnabled()){return self.webcamElementWebrtc;}else{return self.webcamElementHls;}};self.launchWebcamPictureInPicture=function(){self._getActiveWebcamVideoElement().requestPictureInPicture();};self.launchWebcamFullscreen=function(){self._getActiveWebcamVideoElement().requestFullscreen();};self.toggleWebcamMute=function(){self.webcamMuted(!self.webcamMuted());self.webcamElementWebrtc.muted=self.webcamMuted();self.webcamElementHls.muted=self.webcamMuted();};self._disableWebcam=function(){if(OctoPrint.coreui.browser.safari){return;}
+var timeout=self.settings.streamTimeout()||5;self.webcamDisableTimeout=setTimeout(function(){log.debug("Unloading webcam stream after",timeout,"seconds");$("#webcam_image").attr("src","");self.webcamLoaded(false);},timeout*1000);};self._enableWebcamIfVisible=function(){if(self.webcamStreamVisible){self._enableWebcam();}};self._enableWebcam=function(){if(self.webcamDisableTimeout!=undefined){clearTimeout(self.webcamDisableTimeout);}
+if(self.settings.webcamEnabled()==false){console.log("Webcam not enabled");return;}
+var streamType=self.webcamStreamType();if(streamType=="mjpg"){self._switchToMjpgWebcam();}else if(streamType=="hls"){self._switchToHlsWebcam();}else if(isWebRTCAvailable()&&streamType=="webrtc"){self._switchToWebRTCWebcam();}else{throw"Unknown stream type "+streamType;}};self.onWebcamLoaded=function(){if(self.webcamLoaded())return;log.debug("Webcam stream loaded");self.webcamLoaded(true);self.webcamError(false);};self.onWebcamErrored=function(){log.debug("Webcam stream failed to load/was unloaded");self.webcamLoaded(false);self.webcamError(true);};self.onUserPermissionsChanged=self.onUserLoggedIn=self.onUserLoggedOut=function(){self.syncWebcamElements();};self.syncWebcamElements=function(){self.webcamElementHls=document.getElementById("webcam_hls");self.webcamElementWebrtc=document.getElementById("webcam_webrtc");};self.onStartup=function(){self.syncWebcamElements();};self._switchToMjpgWebcam=function(){var webcamImage=$("#webcam_image");var currentSrc=webcamImage.attr("src");if(OctoPrint.coreui.browser.safari&¤tSrc!=undefined){return;}
+var newSrc=self.streamUrlEscaped();if(currentSrc!=newSrc){if(self.settings.cacheBuster()){if(newSrc.lastIndexOf("?")>-1){newSrc+="&";}else{newSrc+="?";}
+newSrc+=new Date().getTime();}
+self.webcamLoaded(false);self.webcamError(false);webcamImage.attr("src",newSrc);self.webcamHlsEnabled(false);self.webcamMjpgEnabled(true);self.webcamWebRTCEnabled(false);}};self._switchToHlsWebcam=function(){var video=self.webcamElementHls;video.onresize=self._updateVideoTagWebcamLayout;if(self.webRTCPeerConnection!=null){self.webRTCPeerConnection.close();self.webRTCPeerConnection=null;}
+if(video!=null&&typeof video.canPlayType!=undefined&&video.canPlayType("application/vnd.apple.mpegurl")=="probably"){video.src=self.streamUrlEscaped();}else if(Hls.isSupported()){self.hls=new Hls();self.hls.loadSource(self.streamUrlEscaped());self.hls.attachMedia(video);}
+self.webcamMjpgEnabled(false);self.webcamHlsEnabled(true);self.webcamWebRTCEnabled(false);};self._switchToWebRTCWebcam=function(){if(!isWebRTCAvailable()){return;}
+var video=self.webcamElementWebrtc;video.onresize=self._updateVideoTagWebcamLayout;if(self.hls!=null){self.webcamElementHls.src=null;self.hls.destroy();self.hls=null;}
+if(self.webRTCPeerConnection!=null&&self.webRTCPeerConnection.connectionState!="connected"){self.webRTCPeerConnection.close();self.webRTCPeerConnection=null;}
+if(self.webRTCPeerConnection==null){self.webRTCPeerConnection=startWebRTC(video,self.streamUrlEscaped(),self.settings.streamWebrtcIceServers());}
+self.webcamMjpgEnabled(false);self.webcamHlsEnabled(false);self.webcamWebRTCEnabled(true);};self._updateVideoTagWebcamLayout=function(){var player=self._getActiveWebcamVideoElement();var rotationContainer=document.querySelector("#webcam_video_container .webcam_rotated");var rotationTarget=document.querySelector("#webcam_video_container .webcam_rotated .rotation_target");var unrotationContainer=document.querySelector("#webcam_video_container .webcam_unrotated");var unrotationTarget=document.querySelector("#webcam_video_container .webcam_unrotated .rotation_target");if(rotationContainer){var height=rotationContainer.offsetWidth;rotationContainer.style.height=height+"px";rotationTarget.style.height=rotationContainer.offsetWidth+"px";rotationTarget.style.width=rotationContainer.offsetHeight+"px";rotationContainer.style.paddingBottom=0;}
+if(unrotationContainer){unrotationContainer.style.height=null;unrotationContainer.style.paddingBottom=0;unrotationTarget.style.height=null;unrotationTarget.style.width=null;}};self.determineWebcamStreamType=function(streamUrl){if(!streamUrl){throw"Empty streamUrl. Cannot determine stream type.";}
+var parsed=validateWebcamUrl(streamUrl);if(!parsed){throw"Invalid streamUrl. Cannot determine stream type.";}
+if(parsed.protocol==="webrtc:"||parsed.protocol==="webrtcs:"){return"webrtc";}
+var lastDotPosition=parsed.pathname.lastIndexOf(".");if(lastDotPosition!==-1){var extension=parsed.pathname.substring(lastDotPosition+1);if(extension.toLowerCase()==="m3u8"){return"hls";}}
+return"mjpg";};}
+OCTOPRINT_VIEWMODELS.push({construct:ClassicWebcamViewModel,dependencies:["loginStateViewModel","classicWebcamSettingsViewModel"],elements:["#classicwebcam_container"]});});
+;
+
+// source: plugin/classicwebcam/js/classicwebcam_settings.js
+$(function(){function ClassicWebcamSettingsViewModel(parameters){var self=this;self.loginState=parameters[0];self.settings=parameters[1];self._subscriptions=[];self.webRtcServersToText=function(list){self.streamWebrtcIceServersText(self.streamWebrtcIceServers().join(", "));};self.textToWebRtcServers=function(list){self.streamWebrtcIceServers(splitTextToArray(self.streamWebrtcIceServersText(),",",true));};self.onBeforeBinding=function(){self.snapshotUrl=self.settings.settings.plugins.classicwebcam.snapshot;self.snapshotTimeout=self.settings.settings.plugins.classicwebcam.snapshotTimeout;self.snapshotSslValidation=self.settings.settings.plugins.classicwebcam.snapshotSslValidation;self.flipH=self.settings.settings.plugins.classicwebcam.flipH;self.flipV=self.settings.settings.plugins.classicwebcam.flipV;self.rotate90=self.settings.settings.plugins.classicwebcam.rotate90;self.streamUrl=self.settings.settings.plugins.classicwebcam.stream;self.webcamEnabled=self.settings.settings.webcam.webcamEnabled;self.streamRatio=self.settings.settings.plugins.classicwebcam.streamRatio;self.streamTimeout=self.settings.settings.plugins.classicwebcam.streamTimeout;self.streamWebrtcIceServers=self.settings.settings.plugins.classicwebcam.streamWebrtcIceServers;self.streamWebrtcIceServersText=ko.observable("");self.cacheBuster=self.settings.settings.plugins.classicwebcam.cacheBuster;self.available_ratios=["16:9","4:3"];self.webRtcServersToText();self.streamWebrtcIceServers.subscribe(function(value){self.webRtcServersToText();});};self.onSettingsBeforeSave=function(){self.textToWebRtcServers();};self.onUserSettingsHidden=function(){self.webRtcServersToText();};self.streamUrlEscaped=ko.pureComputed(function(){return encodeURI(self.streamUrl());});self.streamType=ko.pureComputed(function(){try{return determineWebcamStreamType(self.streamUrlEscaped());}catch(e){return"";}});self.streamValid=ko.pureComputed(function(){var url=self.streamUrlEscaped();return!url||validateWebcamUrl(url);});self.testWebcamStreamUrlBusy=ko.observable(false);self.testWebcamStreamUrl=function(){var url=self.streamUrlEscaped();if(!url){return;}
+if(self.testWebcamStreamUrlBusy()){return;}
+var text=gettext("If you see your webcam stream below, the entered stream URL is ok.");var streamType;try{streamType=self.streamType();}catch(e){streamType="";}
+var webcam_element;var webrtc_peer_connection;if(streamType==="mjpg"){webcam_element=$('');}else if(streamType==="hls"){webcam_element=$('');video_element=webcam_element[0];if(video_element.canPlayType("application/vnd.apple.mpegurl")){video_element.src=url;}else if(Hls.isSupported()){var hls=new Hls();hls.loadSource(url);hls.attachMedia(video_element);}}else if(isWebRTCAvailable()&&streamType==="webrtc"){webcam_element=$('');video_element=webcam_element[0];webrtc_peer_connection=startWebRTC(video_element,url,self.streamWebrtcIceServers());}else{throw"Unknown stream type "+streamType;}
+var message=$("").append($("")).append(text).append(webcam_element);self.testWebcamStreamUrlBusy(true);showMessageDialog({title:gettext("Stream test"),message:message,onclose:function(){self.testWebcamStreamUrlBusy(false);if(webrtc_peer_connection!=null){webrtc_peer_connection.close();webrtc_peer_connection=null;}}});};self.testWebcamSnapshotUrlBusy=ko.observable(false);self.testWebcamSnapshotUrl=function(viewModel,event){if(!self.snapshotUrl()){return;}
+if(self.testWebcamSnapshotUrlBusy()){return;}
+var errorText=gettext("Could not retrieve snapshot URL, please double check the URL");var errorTitle=gettext("Snapshot test failed");self.testWebcamSnapshotUrlBusy(true);OctoPrint.util.testUrl(self.snapshotUrl(),{method:"GET",response:"bytes",timeout:self.settings.settings.webcam.snapshotTimeout(),validSsl:self.settings.settings.webcam.snapshotSslValidation(),content_type_whitelist:["image/*"],content_type_guess:true}).done(function(response){if(!response.result){if(response.status&&response.response&&response.response.content_type){errorText=gettext("Could retrieve the snapshot URL, but it didn't look like an "+"image. Got this as a content type header: %(content_type)s. Please "+"double check that the URL is returning static images, not multipart data "+"or videos.");errorText=_.sprintf(errorText,{content_type:_.escape(response.response.content_type)});}
+showMessageDialog({title:errorTitle,message:errorText,onclose:function(){self.testWebcamSnapshotUrlBusy(false);}});return;}
+const content=response.response.content;const contentType=response.response.assumed_content_type;const text=gettext("If you see your webcam snapshot picture below, the entered snapshot URL is ok.");const mimeType=contentType?contentType.split(";")[0]:"image/jpeg";const textElement=$("").text(text);const imgElement=$("").attr("src","data:"+mimeType+";base64,"+content).css("border","1px solid black");const message=$("").append(textElement).append(imgElement);showMessageDialog({title:gettext("Snapshot test"),message:message,onclose:function(){self.testWebcamSnapshotUrlBusy(false);}});}).fail(function(){showMessageDialog({title:errorTitle,message:errorText,onclose:function(){self.testWebcamSnapshotUrlBusy(false);}});});};}
+OCTOPRINT_VIEWMODELS.push({construct:ClassicWebcamSettingsViewModel,dependencies:["loginStateViewModel","settingsViewModel"],elements:["#classicwebcam_settings"]});});
+;
+
+// source: plugin/classicwebcam/js/classicwebcam_wizard.js
+$(function(){function ClassicWebcamWizardViewModel(parameters){var self=this;self.settingsViewModel=parameters[0];self.onWizardFinish=function(){if(self.settingsViewModel.streamUrl()){return"reload";}};}
+OCTOPRINT_VIEWMODELS.push({construct:ClassicWebcamWizardViewModel,dependencies:["classicWebcamSettingsViewModel"],elements:["#wizard_classicwebcam"]});});
+;
+
+// source: plugin/errortracking/js/sentry.min.js
+/*! @sentry/browser 6.18.2 (22f518e) | https://github.com/getsentry/sentry-javascript */
+var Sentry=function(t){var n=function(t,r){return n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,n){t.__proto__=n}||function(t,n){for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(t[r]=n[r])},n(t,r)};function r(t,r){if("function"!=typeof r&&null!==r)throw new TypeError("Class extends value "+String(r)+" is not a constructor or null");function i(){this.constructor=t}n(t,r),t.prototype=null===r?Object.create(r):(i.prototype=r.prototype,new i)}var i,e=function(){return e=Object.assign||function(t){for(var n,r=1,i=arguments.length;r=t.length&&(t=void 0),{value:t&&t[i++],done:!t}}};throw new TypeError(n?"Object is not iterable.":"Symbol.iterator is not defined.")}function u(t,n){var r="function"==typeof Symbol&&t[Symbol.iterator];if(!r)return t;var i,e,o=r.call(t),u=[];try{for(;(void 0===n||n-- >0)&&!(i=o.next()).done;)u.push(i.value)}catch(t){e={error:t}}finally{try{i&&!i.done&&(r=o.return)&&r.call(o)}finally{if(e)throw e.error}}return u}function a(){for(var t=[],n=0;n ".length,a=void 0;r&&e++<5&&!("html"===(a=_(r,n))||e>1&&o+i.length*u+a.length>=80);)i.push(a),o+=a.length,r=r.parentNode;return i.reverse().join(" > ")}catch(t){return""}}function _(t,n){var r,i,e,o,u,a=t,c=[];if(!a||!a.tagName)return"";c.push(a.tagName.toLowerCase());var s=n&&n.length?n.filter((function(t){return a.getAttribute(t)})).map((function(t){return[t,a.getAttribute(t)]})):null;if(s&&s.length)s.forEach((function(t){c.push("["+t[0]+'="'+t[1]+'"]')}));else if(a.id&&c.push("#"+a.id),(r=a.className)&&p(r))for(i=r.split(/\s+/),u=0;u1&&(h=d.slice(0,-1).join("/"),v=d.pop()),v){var l=v.match(/^\d+/);l&&(v=l[0])}return T({host:c,pass:a,path:h,projectId:v,port:f,protocol:i,publicKey:e})}(t):T(t);return n}var R=["fatal","error","warning","log","info","debug","critical"],N=s(),I="Sentry Logger ";function M(t){var n=s();if(!("console"in n))return t();var r=n.console,i={};["debug","info","warn","error","log","assert"].forEach((function(t){t in n.console&&r[t].__sentry_original__&&(i[t]=r[t],r[t]=r[t].__sentry_original__)}));var e=t();return Object.keys(i).forEach((function(t){r[t]=i[t]})),e}var q=function(){function t(){this.t=!1}return t.prototype.disable=function(){this.t=!1},t.prototype.enable=function(){this.t=!0},t.prototype.log=function(){for(var t=[],n=0;n"}try{o.currentTarget=w(e.currentTarget)?E(e.currentTarget):Object.prototype.toString.call(e.currentTarget)}catch(t){o.currentTarget=""}for(var u in"undefined"!=typeof CustomEvent&&x(t,CustomEvent)&&(o.detail=e.detail),e)Object.prototype.hasOwnProperty.call(e,u)&&(o[u]=e[u]);return o}return t}function z(t){return function(t){return~-encodeURI(t).split(/%..|./).length}(JSON.stringify(t))}function G(t,n,r){void 0===n&&(n=3),void 0===r&&(r=102400);var i=Q(t,n);return z(i)>r?G(t,n-1,r):i}function K(t,n){return"domain"===n&&t&&"object"==typeof t&&t.i?"[Domain]":"domainEmitter"===n?"[DomainEmitter]":"undefined"!=typeof global&&t===global?"[Global]":"undefined"!=typeof window&&t===window?"[Window]":"undefined"!=typeof document&&t===document?"[Document]":m(r=t)&&"nativeEvent"in r&&"preventDefault"in r&&"stopPropagation"in r?"[SyntheticEvent]":"number"==typeof t&&t!=t?"[NaN]":void 0===t?"[undefined]":"function"==typeof t?"[Function: "+U(t)+"]":"symbol"==typeof t?"["+String(t)+"]":"bigint"==typeof t?"[BigInt: "+String(t)+"]":t;var r}function V(t,n,r,i){var e,o;void 0===r&&(r=1/0),void 0===i&&(e="function"==typeof WeakSet,o=e?new WeakSet:[],i=[function(t){if(e)return!!o.has(t)||(o.add(t),!1);for(var n=0;n=n)return H(r[0],n);for(var i=r.length;i>0;i--){var e=r.slice(0,i).join(", ");if(!(e.length>n))return i===r.length?e:H(e,n)}return""}function Z(t){var n,r;if(m(t)){var i=t,e={};try{for(var u=o(Object.keys(i)),a=u.next();!a.done;a=u.next()){var c=a.value;void 0!==i[c]&&(e[c]=Z(i[c]))}}catch(t){n={error:t}}finally{try{a&&!a.done&&(r=u.return)&&r.call(u)}finally{if(n)throw n.error}}return e}return Array.isArray(t)?t.map(Z):t}function tt(){if(!("fetch"in s()))return!1;try{return new Headers,new Request(""),new Response,!0}catch(t){return!1}}function nt(t){return t&&/^function fetch\(\)\s+\{\s+\[native code\]\s+\}$/.test(t.toString())}function rt(){if(!tt())return!1;try{return new Request("_",{referrerPolicy:"origin"}),!0}catch(t){return!1}}var it,et=s(),ot={},ut={};function at(t){if(!ut[t])switch(ut[t]=!0,t){case"console":!function(){if(!("console"in et))return;["debug","info","warn","error","log","assert"].forEach((function(t){t in et.console&&X(et.console,t,(function(n){return function(){for(var r=[],i=0;i2?n[2]:void 0;if(i){var e=it,o=String(i);it=o,st("history",{from:e,to:o})}return t.apply(this,n)}}et.onpopstate=function(){for(var n=[],r=0;r":r||""}function xt(t,n,r){var i=t.exception=t.exception||{},e=i.values=i.values||[],o=e[0]=e[0]||{};o.value||(o.value=n||""),o.type||(o.type=r||"Error")}function Et(t,n){var r=wt(t);if(r){var i=r.mechanism;if(r.mechanism=e(e(e({},{type:"generic",handled:!0}),i),n),n&&"data"in n){var o=e(e({},i&&i.data),n.data);r.mechanism.data=o}}}function _t(t){if(t&&t.__sentry_captured__)return!0;try{B(t,"__sentry_captured__",!0)}catch(t){}return!1}function jt(t){return new St((function(n){n(t)}))}function kt(t){return new St((function(n,r){r(t)}))}var St=function(){function t(t){var n=this;this.o=0,this.u=[],this.h=function(t){n.v(1,t)},this.l=function(t){n.v(2,t)},this.v=function(t,r){0===n.o&&(g(r)?r.then(n.h,n.l):(n.o=t,n.p=r,n.m()))},this.m=function(){if(0!==n.o){var t=n.u.slice();n.u=[],t.forEach((function(t){t[0]||(1===n.o&&t[1](n.p),2===n.o&&t[2](n.p),t[0]=!0)}))}};try{t(this.h,this.l)}catch(t){this.l(t)}}return t.prototype.then=function(n,r){var i=this;return new t((function(t,e){i.u.push([!1,function(r){if(n)try{t(n(r))}catch(t){e(t)}else t(r)},function(n){if(r)try{t(r(n))}catch(t){e(t)}else e(n)}]),i.m()}))},t.prototype.catch=function(t){return this.then((function(t){return t}),t)},t.prototype.finally=function(n){var r=this;return new t((function(t,i){var e,o;return r.then((function(t){o=!1,e=t,n&&n()}),(function(t){o=!0,e=t,n&&n()})).then((function(){o?i(e):t(e)}))}))},t}();function Ot(t){var n=[];function r(t){return n.splice(n.indexOf(t),1)[0]}return{$:n,add:function(i){if(!(void 0===t||n.length0&&r(!1)}),t);n.forEach((function(t){jt(t).then((function(){--e||(clearTimeout(o),r(!0))}),i)}))}))}}}function Tt(n){return"warn"===n?t.Severity.Warning:function(t){return-1!==R.indexOf(t)}(n)?n:t.Severity.Log}var Dt={nowSeconds:function(){return Date.now()/1e3}};var Rt=function(){var t=s().performance;if(t&&t.now)return{now:function(){return t.now()},timeOrigin:Date.now()-t.now()}}(),Nt=void 0===Rt?Dt:{nowSeconds:function(){return(Rt.timeOrigin+Rt.now())/1e3}},It=Dt.nowSeconds.bind(Dt),Mt=Nt.nowSeconds.bind(Nt);function qt(t,n){return void 0===n&&(n=[]),[t,n]}function At(t){var n=u(t,2),r=n[0],i=n[1],e=JSON.stringify(r);return i.reduce((function(t,n){var r=u(n,2),i=r[0],e=r[1],o=y(e)?String(e):JSON.stringify(e);return t+"\n"+JSON.stringify(i)+"\n"+o}),e)}!function(){var t=s().performance;if(t&&t.now){var n=36e5,r=t.now(),i=Date.now(),e=t.timeOrigin?Math.abs(t.timeOrigin+r-i):n,o=e0?t.breadcrumbs:void 0,t.sdkProcessingMetadata=this.R,this.H(a(Lt(),this.j),t,n)},t.prototype.setSDKProcessingMetadata=function(t){return this.R=e(e({},this.R),t),this},t.prototype.H=function(t,n,r,i){var o=this;return void 0===i&&(i=0),new St((function(u,a){var c=t[i];if(null===n||"function"!=typeof c)u(n);else{var s=c(e({},n),r);g(s)?s.then((function(n){return o.H(t,n,r,i+1).then(u)})).then(null,a):o.H(t,s,r,i+1).then(u).then(null,a)}}))},t.prototype.L=function(){var t=this;this.g||(this.g=!0,this._.forEach((function(n){n(t)})),this.g=!1)},t.prototype.U=function(t){t.fingerprint=t.fingerprint?Array.isArray(t.fingerprint)?t.fingerprint:[t.fingerprint]:[],this.A&&(t.fingerprint=t.fingerprint.concat(this.A)),t.fingerprint&&!t.fingerprint.length&&delete t.fingerprint},t}();function Lt(){var t=s();return t.__SENTRY__=t.__SENTRY__||{},t.__SENTRY__.globalEventProcessors=t.__SENTRY__.globalEventProcessors||[],t.__SENTRY__.globalEventProcessors}function Ut(t){Lt().push(t)}var Ht=function(){function t(t){this.errors=0,this.sid=mt(),this.duration=0,this.status="ok",this.init=!0,this.ignoreDuration=!1;var n=Mt();this.timestamp=n,this.started=n,t&&this.update(t)}return t.prototype.update=function(t){if(void 0===t&&(t={}),t.user&&(!this.ipAddress&&t.user.ip_address&&(this.ipAddress=t.user.ip_address),this.did||t.did||(this.did=t.user.id||t.user.email||t.user.username)),this.timestamp=t.timestamp||Mt(),t.ignoreDuration&&(this.ignoreDuration=t.ignoreDuration),t.sid&&(this.sid=32===t.sid.length?t.sid:mt()),void 0!==t.init&&(this.init=t.init),!this.did&&t.did&&(this.did=""+t.did),"number"==typeof t.started&&(this.started=t.started),this.ignoreDuration)this.duration=void 0;else if("number"==typeof t.duration)this.duration=t.duration;else{var n=this.timestamp-this.started;this.duration=n>=0?n:0}t.release&&(this.release=t.release),t.environment&&(this.environment=t.environment),!this.ipAddress&&t.ipAddress&&(this.ipAddress=t.ipAddress),!this.userAgent&&t.userAgent&&(this.userAgent=t.userAgent),"number"==typeof t.errors&&(this.errors=t.errors),t.status&&(this.status=t.status)},t.prototype.close=function(t){t?this.update({status:t}):"ok"===this.status?this.update({status:"exited"}):this.update()},t.prototype.toJSON=function(){return Z({sid:""+this.sid,init:this.init,started:new Date(1e3*this.started).toISOString(),timestamp:new Date(1e3*this.timestamp).toISOString(),status:this.status,errors:this.errors,did:"number"==typeof this.did||"string"==typeof this.did?""+this.did:void 0,duration:this.duration,attrs:{release:this.release,environment:this.environment,ip_address:this.ipAddress,user_agent:this.userAgent}})},t}(),Ft=function(){function t(t,n,r){void 0===n&&(n=new Ct),void 0===r&&(r=4),this.F=r,this.P=[{}],this.getStackTop().scope=n,t&&this.bindClient(t)}return t.prototype.isOlderThan=function(t){return this.F=t&&(clearInterval(e),r(!1)))}),1)}))},t.prototype.nt=function(){return this.V},t.prototype.it=function(){return!1!==this.getOptions().enabled&&void 0!==this.Z},t.prototype.at=function(t,n,r){var i=this,o=this.getOptions().normalizeDepth,u=void 0===o?3:o,a=e(e({},t),{event_id:t.event_id||(r&&r.event_id?r.event_id:mt()),timestamp:t.timestamp||It()});this.ct(a),this.st(a);var c=n;r&&r.captureContext&&(c=Ct.clone(c).update(r.captureContext));var s=jt(a);return c&&(s=c.applyToEvent(a,r)),s.then((function(t){return t&&(t.sdkProcessingMetadata=e(e({},t.sdkProcessingMetadata),{normalizeDepth:Q(u)})),"number"==typeof u&&u>0?i.ft(t,u):t}))},t.prototype.ft=function(t,n){if(!t)return null;var r=e(e(e(e(e({},t),t.breadcrumbs&&{breadcrumbs:t.breadcrumbs.map((function(t){return e(e({},t),t.data&&{data:Q(t.data,n)})}))}),t.user&&{user:Q(t.user,n)}),t.contexts&&{contexts:Q(t.contexts,n)}),t.extra&&{extra:Q(t.extra,n)});return t.contexts&&t.contexts.trace&&(r.contexts.trace=t.contexts.trace),t.sdkProcessingMetadata=e(e({},t.sdkProcessingMetadata),{baseClientNormalized:!0}),r},t.prototype.ct=function(t){var n=this.getOptions(),r=n.environment,i=n.release,e=n.dist,o=n.maxValueLength,u=void 0===o?250:o;"environment"in t||(t.environment="environment"in n?r:"production"),void 0===t.release&&void 0!==i&&(t.release=i),void 0===t.dist&&void 0!==e&&(t.dist=e),t.message&&(t.message=H(t.message,u));var a=t.exception&&t.exception.values&&t.exception.values[0];a&&a.value&&(a.value=H(a.value,u));var c=t.request;c&&c.url&&(c.url=H(c.url,u))},t.prototype.st=function(t){var n=Object.keys(this.G);n.length>0&&(t.sdk=t.sdk||{},t.sdk.integrations=a(t.sdk.integrations||[],n))},t.prototype.ht=function(t){this.nt().sendEvent(t)},t.prototype.rt=function(t,n,r){return this.vt(t,n,r).then((function(t){return t.event_id}),(function(t){A.error(t)}))},t.prototype.vt=function(t,n,r){var i=this,e=this.getOptions(),o=e.beforeSend,u=e.sampleRate,a=this.getTransport();function c(t,n){a.recordLostEvent&&a.recordLostEvent(t,n)}if(!this.it())return kt(new k("SDK not enabled, will not capture event."));var s="transaction"===t.type;return!s&&"number"==typeof u&&Math.random()>u?(c("sample_rate","event"),kt(new k("Discarding event because it's not included in the random sample (sampling rate = "+u+")"))):this.at(t,r,n).then((function(r){if(null===r)throw c("event_processor",t.type||"event"),new k("An event processor returned null, will not send event.");return n&&n.data&&!0===n.data.__sentry__||s||!o?r:function(t){var n="`beforeSend` method has to return `null` or a valid event.";if(g(t))return t.then((function(t){if(!m(t)&&null!==t)throw new k(n);return t}),(function(t){throw new k("beforeSend rejected with "+t)}));if(!m(t)&&null!==t)throw new k(n);return t}(o(r,n))})).then((function(n){if(null===n)throw c("before_send",t.type||"event"),new k("`beforeSend` returned `null`, will not send event.");var e=r&&r.getSession&&r.getSession();return!s&&e&&i.ut(e,n),i.ht(n),n})).then(null,(function(t){if(t instanceof k)throw t;throw i.captureException(t,{data:{__sentry__:!0},originalException:t}),new k("Event processing pipeline threw an error, original event will not be sent. Details have been sent as a new event.\nReason: "+t)}))},t.prototype.tt=function(t){var n=this;this.K+=1,t.then((function(t){return n.K-=1,t}),(function(t){return n.K-=1,t}))},t}();var on=function(){function t(){}return t.prototype.sendEvent=function(t){return jt({reason:"NoopTransport: Event has been skipped because no Dsn is configured.",status:"skipped"})},t.prototype.close=function(t){return jt(!0)},t}(),un=function(){function t(t){this.Y=t,this.Y.dsn||A.warn("No DSN provided, backend will not do anything."),this.dt=this.lt()}return t.prototype.eventFromException=function(t,n){throw new k("Backend has to implement `eventFromException` method")},t.prototype.eventFromMessage=function(t,n,r){throw new k("Backend has to implement `eventFromMessage` method")},t.prototype.sendEvent=function(t){this.dt.sendEvent(t).then(null,(function(t){0}))},t.prototype.sendSession=function(t){this.dt.sendSession&&this.dt.sendSession(t).then(null,(function(t){0}))},t.prototype.getTransport=function(){return this.dt},t.prototype.lt=function(){return new on},t}();function an(t){if(t.metadata&&t.metadata.sdk){var n=t.metadata.sdk;return{name:n.name,version:n.version}}}function cn(t,n){var r,i=an(n),o=t.type||"event",u="transaction"===o||!!n.tunnel,c=(t.sdkProcessingMetadata||{}).transactionSampling||{},s=c.method,f=c.rate;!function(t,n){n&&(t.sdk=t.sdk||{},t.sdk.name=t.sdk.name||n.name,t.sdk.version=t.sdk.version||n.version,t.sdk.integrations=a(t.sdk.integrations||[],n.integrations||[]),t.sdk.packages=a(t.sdk.packages||[],n.packages||[]))}(t,n.metadata.sdk),t.tags=t.tags||{},t.extra=t.extra||{},t.sdkProcessingMetadata&&t.sdkProcessingMetadata.baseClientNormalized||(t.tags.skippedNormalization=!0,t.extra.normalizeDepth=t.sdkProcessingMetadata?t.sdkProcessingMetadata.normalizeDepth:"unset"),delete t.sdkProcessingMetadata;try{r=JSON.stringify(t)}catch(n){t.tags.JSONStringifyError=!0,t.extra.JSONStringifyError=n;try{r=JSON.stringify(Q(t))}catch(t){var h=t;r=JSON.stringify({message:"JSON.stringify error after renormalization",extra:{message:h.message,stack:h.stack}})}}var v={body:r,type:o,url:u?Yt(n.dsn,n.tunnel):Qt(n.dsn)};if(u){var d=qt(e(e({event_id:t.event_id,sent_at:(new Date).toISOString()},i&&{sdk:i}),!!n.tunnel&&{dsn:O(n.dsn)}),[[{type:o,sample_rates:[{id:s,rate:f}]},v.body]]);v.body=At(d)}return v}var sn,fn="6.18.2",hn=function(){function t(){this.name=t.id}return t.prototype.setupOnce=function(){sn=Function.prototype.toString,Function.prototype.toString=function(){for(var t=[],n=0;n=0;n--){var r=t[n];if(r&&""!==r.filename&&"[native code]"!==r.filename)return r.filename||null}return null},t.prototype.jt=function(t){try{if(t.stacktrace)return this.kt(t.stacktrace.frames);var n;try{n=t.exception.values[0].stacktrace.frames}catch(t){}return n?this.kt(n):null}catch(t){return null}},t.id="InboundFilters",t}(),ln=Object.freeze({__proto__:null,FunctionToString:hn,InboundFilters:dn}),pn="?";function yn(t,n,r,i){var e={filename:t,function:n,in_app:!0};return void 0!==r&&(e.lineno=r),void 0!==i&&(e.colno=i),e}var mn=/^\s*at (?:(.*?) ?\((?:address at )?)?((?:file|https?|blob|chrome-extension|address|native|eval|webpack||[-a-z]+:|.*bundle|\/).*?)(?::(\d+))?(?::(\d+))?\)?\s*$/i,bn=/\((\S*)(?::(\d+))(?::(\d+))\)/,wn=[30,function(t){var n=mn.exec(t);if(n){if(n[2]&&0===n[2].indexOf("eval")){var r=bn.exec(n[2]);r&&(n[2]=r[1],n[3]=r[2],n[4]=r[3])}var i=u(Dn(n[1]||pn,n[2]),2),e=i[0];return yn(i[1],e,n[3]?+n[3]:void 0,n[4]?+n[4]:void 0)}}],gn=/^\s*(.*?)(?:\((.*?)\))?(?:^|@)?((?:file|https?|blob|chrome|webpack|resource|moz-extension|capacitor).*?:\/.*?|\[native code\]|[^@]*(?:bundle|\d+\.js)|\/[\w\-. /=]+)(?::(\d+))?(?::(\d+))?\s*$/i,xn=/(\S+) line (\d+)(?: > eval line \d+)* > eval/i,En=[50,function(t){var n,r=gn.exec(t);if(r){if(r[3]&&r[3].indexOf(" > eval")>-1){var i=xn.exec(r[3]);i&&(r[1]=r[1]||"eval",r[3]=i[1],r[4]=i[2],r[5]="")}var e=r[3],o=r[1]||pn;return o=(n=u(Dn(o,e),2))[0],yn(e=n[1],o,r[4]?+r[4]:void 0,r[5]?+r[5]:void 0)}}],_n=/^\s*at (?:((?:\[object object\])?.+) )?\(?((?:file|ms-appx|https?|webpack|blob):.*?):(\d+)(?::(\d+))?\)?\s*$/i,jn=[40,function(t){var n=_n.exec(t);return n?yn(n[2],n[1]||pn,+n[3],n[4]?+n[4]:void 0):void 0}],kn=/ line (\d+).*script (?:in )?(\S+)(?:: in function (\S+))?$/i,Sn=[10,function(t){var n=kn.exec(t);return n?yn(n[2],n[3]||pn,+n[1]):void 0}],On=/ line (\d+), column (\d+)\s*(?:in (?:]+)>|([^)]+))\(.*\))? in (.*):\s*$/i,Tn=[20,function(t){var n=On.exec(t);return n?yn(n[5],n[3]||n[4]||pn,+n[1],+n[2]):void 0}],Dn=function(t,n){var r=-1!==t.indexOf("safari-extension"),i=-1!==t.indexOf("safari-web-extension");return r||i?[-1!==t.indexOf("@")?t.split("@")[0]:pn,r?"safari-extension:"+n:"safari-web-extension:"+n]:[t,n]};function Rn(t){var n=In(t),r={type:t&&t.name,value:qn(t)};return n.length&&(r.stacktrace={frames:n}),void 0===r.type&&""===r.value&&(r.value="Unrecoverable error caught"),r}function Nn(t){return{exception:{values:[Rn(t)]}}}function In(t){var n=t.stacktrace||t.stack||"",r=function(t){if(t){if("number"==typeof t.framesToPop)return t.framesToPop;if(Mn.test(t.message))return 1}return 0}(t);try{return function(){for(var t=[],n=0;n=200&&n<300?"success":429===n?"rate_limit":n>=400&&n<500?"invalid":n>=500?"failed":"unknown";this.qt(i);"success"!==u?o(r):e({status:u})},t.prototype.At=function(t){var n=Bn(t);return this.Ot[n]||this.Ot.all},t.prototype.Ct=function(t){return this.At(t)>new Date(Date.now())},t.prototype.qt=function(t){var n,r,i,e,u=Date.now(),a=t["x-sentry-rate-limits"],c=t["retry-after"];if(a){try{for(var s=o(a.trim().split(",")),f=s.next();!f.done;f=s.next()){var h=f.value.split(":",2),v=parseInt(h[0],10),d=1e3*(isNaN(v)?60:v);try{for(var l=(i=void 0,o(h[1].split(";"))),p=l.next();!p.done;p=l.next()){var y=p.value;this.Ot[y||"all"]=new Date(u+d)}}catch(t){i={error:t}}finally{try{p&&!p.done&&(e=l.return)&&e.call(l)}finally{if(i)throw i.error}}}}catch(t){n={error:t}}finally{try{f&&!f.done&&(r=s.return)&&r.call(s)}finally{if(n)throw n.error}}return!0}return!!c&&(this.Ot.all=new Date(u+function(t,n){void 0===n&&(n=Date.now());var r=parseInt(""+t,10);if(!isNaN(r))return 1e3*r;var i=Date.parse(""+t);return isNaN(i)?6e4:i-n}(c,u)),!0)},t}(),Jn=function(t){function n(n,r){void 0===r&&(r=Pn());var i=t.call(this,n)||this;return i.Lt=r,i}return r(n,t),n.prototype.It=function(t,n){var r=this;if(this.Ct(t.type))return this.recordLostEvent("ratelimit_backoff",t.type),Promise.reject({event:n,type:t.type,reason:"Transport for "+t.type+" requests locked till "+this.At(t.type)+" due to too many requests.",status:429});var i={body:t.body,method:"POST",referrerPolicy:rt()?"origin":""};return void 0!==this.options.fetchParameters&&Object.assign(i,this.options.fetchParameters),void 0!==this.options.headers&&(i.headers=this.options.headers),this.St.add((function(){return new St((function(n,e){r.Lt(t.url,i).then((function(i){var o={"x-sentry-rate-limits":i.headers.get("X-Sentry-Rate-Limits"),"retry-after":i.headers.get("Retry-After")};r.Mt({requestType:t.type,response:i,headers:o,resolve:n,reject:e})})).catch(e)}))})).then(void 0,(function(n){throw n instanceof k?r.recordLostEvent("queue_overflow",t.type):r.recordLostEvent("network_error",t.type),n}))},n}($n),zn=function(t){function n(){return null!==t&&t.apply(this,arguments)||this}return r(n,t),n.prototype.It=function(t,n){var r=this;return this.Ct(t.type)?(this.recordLostEvent("ratelimit_backoff",t.type),Promise.reject({event:n,type:t.type,reason:"Transport for "+t.type+" requests locked till "+this.At(t.type)+" due to too many requests.",status:429})):this.St.add((function(){return new St((function(n,i){var e=new XMLHttpRequest;for(var o in e.onreadystatechange=function(){if(4===e.readyState){var o={"x-sentry-rate-limits":e.getResponseHeader("X-Sentry-Rate-Limits"),"retry-after":e.getResponseHeader("Retry-After")};r.Mt({requestType:t.type,response:e,headers:o,resolve:n,reject:i})}},e.open("POST",t.url),r.options.headers)Object.prototype.hasOwnProperty.call(r.options.headers,o)&&e.setRequestHeader(o,r.options.headers[o]);e.send(t.body)}))})).then(void 0,(function(n){throw n instanceof k?r.recordLostEvent("queue_overflow",t.type):r.recordLostEvent("network_error",t.type),n}))},n}($n),Gn=Object.freeze({__proto__:null,BaseTransport:$n,FetchTransport:Jn,XHRTransport:zn}),Kn=function(n){function i(){return null!==n&&n.apply(this,arguments)||this}return r(i,n),i.prototype.eventFromException=function(t,n){return An(t,n,this.Y.attachStacktrace)},i.prototype.eventFromMessage=function(n,r,i){return void 0===r&&(r=t.Severity.Info),Cn(n,r,i,this.Y.attachStacktrace)},i.prototype.lt=function(){if(!this.Y.dsn)return n.prototype.lt.call(this);var t=e(e({},this.Y.transportOptions),{dsn:this.Y.dsn,tunnel:this.Y.tunnel,sendClientReports:this.Y.sendClientReports,Rt:this.Y.Rt});return this.Y.transport?new this.Y.transport(t):tt()?new Jn(t):new zn(t)},i}(un),Vn=s(),Qn=0;function Yn(){return Qn>0}function Zn(){Qn+=1,setTimeout((function(){Qn-=1}))}function tr(t,n,r){if(void 0===n&&(n={}),"function"!=typeof t)return t;try{var i=t.__sentry_wrapped__;if(i)return i;if($(t))return t}catch(n){return t}var sentryWrapped=function(){var i=Array.prototype.slice.call(arguments);try{r&&"function"==typeof r&&r.apply(this,arguments);var o=i.map((function(t){return tr(t,n)}));return t.apply(this,o)}catch(t){throw Zn(),zt((function(r){r.addEventProcessor((function(t){return n.mechanism&&(xt(t,void 0,void 0),Et(t,n.mechanism)),t.extra=e(e({},t.extra),{arguments:i}),t})),captureException(t)})),t}};try{for(var o in t)Object.prototype.hasOwnProperty.call(t,o)&&(sentryWrapped[o]=t[o])}catch(t){}W(sentryWrapped,t),B(t,"__sentry_wrapped__",sentryWrapped);try{Object.getOwnPropertyDescriptor(sentryWrapped,"name").configurable&&Object.defineProperty(sentryWrapped,"name",{get:function(){return t.name}})}catch(t){}return sentryWrapped}function nr(t){if(void 0===t&&(t={}),Vn.document&&t.eventId&&t.dsn){var n=Vn.document.createElement("script");n.async=!0,n.src=function(t,n){var r=D(t),i=Gt(r)+"embed/error-page/",e="dsn="+O(r);for(var o in n)if("dsn"!==o)if("user"===o){if(!n.user)continue;n.user.name&&(e+="&name="+encodeURIComponent(n.user.name)),n.user.email&&(e+="&email="+encodeURIComponent(n.user.email))}else e+="&"+encodeURIComponent(o)+"="+encodeURIComponent(n[o]);return i+"?"+e}(t.dsn,t),t.onLoad&&(n.onload=t.onLoad);var r=Vn.document.head||Vn.document.body;r&&r.appendChild(n)}}var rr=function(){function t(n){this.name=t.id,this.Ut={onerror:ir,onunhandledrejection:er},this.Y=e({onerror:!0,onunhandledrejection:!0},n)}return t.prototype.setupOnce=function(){Error.stackTraceLimit=50;var t=this.Y;for(var n in t){var r=this.Ut[n];r&&t[n]&&(ur(n),r(),this.Ut[n]=void 0)}},t.id="GlobalHandlers",t}();function ir(){ct("error",(function(n){var r=u(cr(),2),i=r[0],e=r[1];if(i.getIntegration(rr)){var o=n.msg,a=n.url,c=n.line,s=n.column,f=n.error;if(!(Yn()||f&&f.__sentry_own_request__)){var h=void 0===f&&p(o)?function(t,n,r,i){var e=/^(?:[Uu]ncaught (?:exception: )?)?(?:((?:Eval|Internal|Range|Reference|Syntax|Type|URI|)Error): )?(.*)$/i,o=d(t)?t.message:t,u="Error",a=o.match(e);a&&(u=a[1],o=a[2]);return or({exception:{values:[{type:u,value:o}]}},n,r,i)}(o,a,c,s):or(Ln(f||o,void 0,e,!1),a,c,s);h.level=t.Severity.Error,ar(i,f,h,"onerror")}}}))}function er(){ct("unhandledrejection",(function(n){var r=u(cr(),2),i=r[0],e=r[1];if(i.getIntegration(rr)){var o=n;try{"reason"in n?o=n.reason:"detail"in n&&"reason"in n.detail&&(o=n.detail.reason)}catch(t){}if(Yn()||o&&o.__sentry_own_request__)return!0;var a=y(o)?{exception:{values:[{type:"UnhandledRejection",value:"Non-Error promise rejection captured with value: "+String(o)}]}}:Ln(o,void 0,e,!0);a.level=t.Severity.Error,ar(i,o,a,"onunhandledrejection")}}))}function or(t,n,r,i){var e=t.exception=t.exception||{},o=e.values=e.values||[],u=o[0]=o[0]||{},a=u.stacktrace=u.stacktrace||{},c=a.frames=a.frames||[],f=isNaN(parseInt(i,10))?void 0:i,h=isNaN(parseInt(r,10))?void 0:r,v=p(n)&&n.length>0?n:function(){var t=s();try{return t.document.location.href}catch(t){return""}}();return 0===c.length&&c.push({colno:f,filename:v,function:"?",in_app:!0,lineno:h}),t}function ur(t){0}function ar(t,n,r,i){Et(r,{handled:!1,type:i}),t.captureEvent(r,{originalException:n})}function cr(){var t=Bt(),n=t.getClient();return[t,n&&n.getOptions().attachStacktrace]}var sr=["EventTarget","Window","Node","ApplicationCache","AudioTrackList","ChannelMergerNode","CryptoOperation","EventSource","FileReader","HTMLUnknownElement","IDBDatabase","IDBRequest","IDBTransaction","KeyOperation","MediaController","MessagePort","ModalWindow","Notification","SVGElementInstance","Screen","TextTrack","TextTrackCue","TextTrackList","WebSocket","WebSocketWorker","Worker","XMLHttpRequest","XMLHttpRequestEventTarget","XMLHttpRequestUpload"],fr=function(){function t(n){this.name=t.id,this.Y=e({XMLHttpRequest:!0,eventTarget:!0,requestAnimationFrame:!0,setInterval:!0,setTimeout:!0},n)}return t.prototype.setupOnce=function(){var t=s();this.Y.setTimeout&&X(t,"setTimeout",hr),this.Y.setInterval&&X(t,"setInterval",hr),this.Y.requestAnimationFrame&&X(t,"requestAnimationFrame",vr),this.Y.XMLHttpRequest&&"XMLHttpRequest"in t&&X(XMLHttpRequest.prototype,"send",dr);var n=this.Y.eventTarget;n&&(Array.isArray(n)?n:sr).forEach(lr)},t.id="TryCatch",t}();function hr(t){return function(){for(var n=[],r=0;r"}0!==r.length&&Bt().addBreadcrumb({category:"ui."+n.name,message:r},{event:n.event,name:n.name,global:n.global})}return n}(this.Y.dom)),this.Y.xhr&&ct("xhr",mr),this.Y.fetch&&ct("fetch",br),this.Y.history&&ct("history",wr)},t.id="Breadcrumbs",t}();function yr(t){var n={category:"console",data:{arguments:t.args,logger:"console"},level:Tt(t.level),message:F(t.args," ")};if("assert"===t.level){if(!1!==t.args[0])return;n.message="Assertion failed: "+(F(t.args.slice(1)," ")||"console.assert"),n.data.arguments=t.args.slice(1)}Bt().addBreadcrumb(n,{input:t.args,level:t.level})}function mr(t){if(t.endTimestamp){if(t.xhr.__sentry_own_request__)return;var n=t.xhr.__sentry_xhr__||{},r=n.method,i=n.url,e=n.status_code,o=n.body;Bt().addBreadcrumb({category:"xhr",data:{method:r,url:i,status_code:e},type:"http"},{xhr:t.xhr,input:o})}else;}function br(n){n.endTimestamp&&(n.fetchData.url.match(/sentry_key/)&&"POST"===n.fetchData.method||(n.error?Bt().addBreadcrumb({category:"fetch",data:n.fetchData,level:t.Severity.Error,type:"http"},{data:n.error,input:n.args}):Bt().addBreadcrumb({category:"fetch",data:e(e({},n.fetchData),{status_code:n.response.status}),type:"http"},{input:n.args,response:n.response})))}function wr(t){var n=s(),r=t.from,i=t.to,e=bt(n.location.href),o=bt(r),u=bt(i);o.path||(o=e),e.protocol===u.protocol&&e.host===u.host&&(i=u.relative),e.protocol===o.protocol&&e.host===o.host&&(r=o.relative),Bt().addBreadcrumb({category:"navigation",data:{from:r,to:i}})}var gr=function(){function t(n){void 0===n&&(n={}),this.name=t.id,this.Ht=n.key||"cause",this.Ft=n.limit||5}return t.prototype.setupOnce=function(){Ut((function(n,r){var i=Bt().getIntegration(t);return i?function(t,n,r,i){if(!(r.exception&&r.exception.values&&i&&x(i.originalException,Error)))return r;var e=xr(n,i.originalException,t);return r.exception.values=a(e,r.exception.values),r}(i.Ht,i.Ft,n,r):n}))},t.id="LinkedErrors",t}();function xr(t,n,r,i){if(void 0===i&&(i=[]),!x(n[r],Error)||i.length+1>=t)return i;var e=Rn(n[r]);return xr(t,n[r],r,a([e],i))}var Er=s(),_r=function(){function t(){this.name=t.id}return t.prototype.setupOnce=function(){Ut((function(n){if(Bt().getIntegration(t)){if(!Er.navigator&&!Er.location&&!Er.document)return n;var r=n.request&&n.request.url||Er.location&&Er.location.href,i=(Er.document||{}).referrer,o=(Er.navigator||{}).userAgent,u=e(e(e({},n.request&&n.request.headers),i&&{Referer:i}),o&&{"User-Agent":o}),a=e(e({},r&&{url:r}),{headers:u});return e(e({},n),{request:a})}return n}))},t.id="UserAgent",t}(),jr=function(){function t(){this.name=t.id}return t.prototype.setupOnce=function(n,r){n((function(n){var i=r().getIntegration(t);if(i){try{if(function(t,n){if(!n)return!1;if(function(t,n){var r=t.message,i=n.message;if(!r&&!i)return!1;if(r&&!i||!r&&i)return!1;if(r!==i)return!1;if(!Sr(t,n))return!1;if(!kr(t,n))return!1;return!0}(t,n))return!0;if(function(t,n){var r=Or(n),i=Or(t);if(!r||!i)return!1;if(r.type!==i.type||r.value!==i.value)return!1;if(!Sr(t,n))return!1;if(!kr(t,n))return!1;return!0}(t,n))return!0;return!1}(n,i.Pt))return A.warn("Event dropped due to being a duplicate of previously captured event."),null}catch(t){return i.Pt=n}return i.Pt=n}return n}))},t.id="Dedupe",t}();function kr(t,n){var r=Tr(t),i=Tr(n);if(!r&&!i)return!0;if(r&&!i||!r&&i)return!1;if(r=r,(i=i).length!==r.length)return!1;for(var e=0;eIt looks like you are tracking an OctoPrint RC release channel. It "+"would be great if you would enable error reporting so that any kind of errors that occur "+"with an RC can be looked into more easily. Thank you!"+"
You can find more information on error reporting "+"under Settings > Error Tracking
"),hide:false,confirm:{confirm:true,buttons:[{text:gettext("Ignore"),click:function(){notification.remove();notification=undefined;new PNotify({text:gettext('You can still enable error tracking via "Settings" > "Error Tracking"')});if(Modernizr.localstorage){localStorage["plugin.errortracking.notification_ignored"]=JSON.stringify(true);}}},{text:gettext("Enable"),addClass:"btn-primary",click:function(){self.settings.saveData({plugins:{errortracking:{enabled:true}}}).done(function(){notification.remove();notification=undefined;location.reload(true);});}}]},buttons:{closer:false,sticker:false}});}else if(notification!==undefined){notification.remove();notification=undefined;}};var subbed=false;self.onStartup=self.onUserLoggedIn=self.onUserLoggedOut=function(){performCheck();if(self.settings&&self.settings.settings&&self.settings.settings.plugins&&self.settings.settings.plugins.softwareupdate&&!subbed){subbed=true;self.settings.settings.plugins.softwareupdate.octoprint_release_channel.subscribe(performCheck);}};}
+OCTOPRINT_VIEWMODELS.push({construct:ErrorTrackingViewModel,dependencies:["settingsViewModel","loginStateViewModel"]});});
+;
+
+// source: plugin/eventmanager/js/events.js
+$(function(){function eventManagerViewModel(parameters){var self=this;self.settingsViewModel=parameters[0];self.selectedCommand=ko.observable();self.eventDetails=function(data){if(data===false){return{event:ko.observable(""),command:ko.observable(""),name:ko.observable(""),type:ko.observable(""),enabled:ko.observable(true),debug:ko.observable(false)};}else{if(!data.hasOwnProperty("enabled")){data["enabled"]=ko.observable(true);}
+if(!data.hasOwnProperty("debug")){data["debug"]=ko.observable(false);}
+return data;}};self.addEvent=function(){self.selectedCommand(self.eventDetails(false));self.settingsViewModel.settings.plugins.eventmanager.subscriptions.push(self.selectedCommand());$("#EventManagerEditor").modal("show");};self.editEvent=function(data){self.selectedCommand(self.eventDetails(data));$("#EventManagerEditor").modal("show");};self.removeEvent=function(data){self.settingsViewModel.settings.plugins.eventmanager.subscriptions.remove(data);};}
+OCTOPRINT_VIEWMODELS.push({construct:eventManagerViewModel,dependencies:["settingsViewModel"],elements:["#settings_plugin_eventmanager"]});});
+;
+
+// source: plugin/file_check/js/file_check.js
+$(function(){function FileCheckViewModel(parameters){const self=this;self.loginState=parameters[0];self.access=parameters[1];self.settingsViewModel=parameters[2];self.printerState=parameters[3];self.filesViewModel=parameters[4];self.fullCheckAvailable=ko.observable(false);self.checkResult=ko.observable();self.checkRunning=ko.observable(false);self.lastCheckTimestamp=ko.observable();self.lastCheckCurrent=ko.observable();self.issueNotification=undefined;const ISSUES={travel_speed:{title:gettext("Travel Speed Placeholder"),message:gettext("Your file still contains a place holder {travel_speed}. "+"This is a common issue when using old start/stop GCODE code snippets in current versions of "+"Cura, as the placeholder name switched to {speed_travel} at some point and "+"no longer gets replaced in current versions. You need to fix this in your slicer and reslice "+"your file, do not print it like it is as it will cause issues!")},leaked_api_key:{title:gettext("Leaked API Key"),message:gettext("Your file contains an API key that is not supposed to be there. "+"This is caused by a bug in your slicer, and known to happen with PrusaSlicer (<= 2.1.1), "+"BambuStudio (<= 1.8.4) and OrcaSlicer (<= 1.9.0). "+"Do not share this file with anyone, update your slicer to a patched version immediately, "+"and reslice your file. Also consider changing your API key in OctoPrint, as it might have been leaked by your slicer "+"to third parties through any GCODE files shared previously."),severity:"error"}};self.checksArray=ko.pureComputed(()=>{return Object.keys(ISSUES).map((key)=>{return{key:key,title:ISSUES[key].title,message:ISSUES[key].message,enabled:ko.pureComputed({read:()=>{return!self.settingsViewModel.settings.plugins.file_check.ignored_checks().includes(key);},write:(value)=>{if(value){self.settingsViewModel.settings.plugins.file_check.ignored_checks.remove(key);}else{self.settingsViewModel.settings.plugins.file_check.ignored_checks.push(key);}}})};});});self.lastCheckTimestampText=ko.pureComputed(()=>{return formatDate(self.lastCheckTimestamp(),{placeholder:gettext("unknown")});});self.lastCheckStateText=ko.pureComputed(()=>{if(self.lastCheckCurrent()){return gettext("Up to date");}else{return gettext("Outdated");}});self.lastCheckStateClass=ko.pureComputed(()=>{if(self.lastCheckCurrent()){return"text-success";}else{return"text-error";}});self.requestData=function(){if(!self.loginState.hasPermission(self.access.permissions.PLUGIN_FILE_CHECK_RUN))
+return $.Deferred().reject();return OctoPrint.plugins.file_check.get().done(self.fromResponse);};self.fromResponse=function(response){self.fullCheckAvailable(response.native_grep);self.checkResult(response.check_result);self.lastCheckTimestamp(response.last_full_check.timestamp);self.lastCheckCurrent(response.last_full_check.current);};self.checkAll=function(){if(!self.loginState.hasPermission(self.access.permissions.PLUGIN_FILE_CHECK_RUN))
+return;showConfirmationDialog({title:gettext("Run File Check on all files?"),message:gettext("This will perform a check of all of your uploaded files for known issues. "+"Depending on the amount of files this could take several minutes. "+"It should not be done while a print is running."),onproceed:()=>{self.checkRunning(true);OctoPrint.plugins.file_check.checkAll();}});};self.hasCheckResult=function(storage,file){if(!storage)return null;if(_.isPlainObject(storage)){file=storage.path;storage=storage.origin;}else if(!file){file=storage;storage="local";}
+const key=`${storage}:${file}`;return(self.checkResult()&&self.checkResult()[key]&&self.loginState.hasPermission(self.access.permissions.PLUGIN_FILE_CHECK_RUN));};self.showCheckResult=function(storage,file){if(!self.loginState.hasPermission(self.access.permissions.PLUGIN_FILE_CHECK_RUN))
+return;if(_.isPlainObject(storage)){file=storage.path;storage=storage.origin;}else if(!file){file=storage;storage="local";}
+const key=`${storage}:${file}`;const data=self.checkResult()[key];if(!data)return;const getMessage=(issue)=>{return $("",{html:ISSUES[issue].message});};const getReadMore=(issue)=>{return $("").append($("",{href:"https://faq.octoprint.org/file-check-"+
+issue.replaceAll("_","-"),target:"_blank",rel:"noreferrer noopener",text:gettext("Read more...")}));};const title=gettext("File Check detected the following issues:");let message;if(data.length===1){const issue=data[0];message=$("").append(getMessage(issue)).append(getReadMore(issue));}else{message=$("
").append(data.map((issue)=>$("").append(getMessage(issue)).append(getReadMore(issue))));}
+showMessageDialog({title:title,message:message});};self.onDataUpdaterPluginMessage=function(plugin,data){if(plugin!=="file_check")return;if(!self.loginState.hasPermission(self.access.permissions.PLUGIN_FILE_CHECK_RUN))
+return;switch(data["action"]){case"notify":{self._handleNotification(data);break;}
+case"check_update":{self._handleCheckUpdate(data);break;}}};self._handleNotification=function(data){let severity="warning";const result=[];for(const t of data["types"]){if(!ISSUES[t])continue;const spec=ISSUES[t];const message=spec["message"];if(spec["severity"]==="error"){severity="error";}
+const faq=""+
+gettext("Read more...")+"";result.push("
"+
+gettext("It can negatively impact print performance and also take up a lot of storage space "+"depending on how long you keep it enabled and thus should only be used for "+"debugging.")+"
";}
+return content;};self.configuredLoggersHasChanged=function(){self.configuredLoggersChanged=true;};self.addLogger=function(){if(!self.loginState.hasPermission(self.access.permissions.PLUGIN_LOGGING_MANAGE)){return;}
+var component=self.availableLoggersName();if(!component){return;}
+var level=self.availableLoggersLevel();self.configuredLoggers.push({component:component,level:ko.observable(level)});self.availableLoggers.remove(component);self.configuredLoggersHasChanged();};self.removeLogger=function(logger){if(!self.loginState.hasPermission(self.access.permissions.PLUGIN_LOGGING_MANAGE)){return;}
+self.configuredLoggers.remove(logger);self.availableLoggers.push(logger.component);self.configuredLoggersHasChanged();};self.removeFile=function(filename){if(!self.loginState.hasPermission(self.access.permissions.PLUGIN_LOGGING_MANAGE)){return;}
+var perform=function(){OctoPrint.plugins.logging.deleteLog(filename).done(self.requestData);};showConfirmationDialog(_.sprintf(gettext('You are about to delete log file "%(name)s".'),{name:_.escape(filename)}),perform);};self.markFilesOnPage=function(){self.markedForDeletion(_.uniq(self.markedForDeletion().concat(_.map(self.listHelper.paginatedItems(),"name"))));};self.markAllFiles=function(){self.markedForDeletion(_.map(self.listHelper.allItems,"name"));};self.clearMarkedFiles=function(){if(!self.loginState.hasPermission(self.access.permissions.PLUGIN_LOGGING_MANAGE)){return;}
+self.markedForDeletion.removeAll();};self.removeMarkedFiles=function(){if(!self.loginState.hasPermission(self.access.permissions.PLUGIN_LOGGING_MANAGE)){return;}
+var perform=function(){self._bulkRemove(self.markedForDeletion(),"files").done(function(){self.markedForDeletion.removeAll();});};showConfirmationDialog(_.sprintf(gettext("You are about to delete %(count)d log files."),{count:self.markedForDeletion().length}),perform);};self.enableBulkDownload=ko.pureComputed(function(){return self.markedForDeletion().length&&!self.bulkDownloadUrlTooLong();});self.bulkDownloadUrlTooLong=ko.pureComputed(function(){return BASEURL.length+self.bulkDownloadUrl().length>=2000;});self.bulkDownloadButtonUrl=ko.pureComputed(function(){var files=self.markedForDeletion();if(!files.length||self.bulkDownloadUrlTooLong()){return"javascript:void(0)";}
+return self.bulkDownloadUrl();});self.bulkDownloadUrl=function(){var files=self.markedForDeletion();return OctoPrint.plugins.logging.bulkDownloadUrl(files);};self.onServerReconnect=self.onUserLoggedIn=self.onEventSettingsUpdated=self.onSettingsShown=function(){if(!self.loginState.hasPermission(self.access.permissions.PLUGIN_LOGGING_MANAGE)){return;}
+self.requestData();};self.onSettingsBeforeSave=function(){if(!self.loginState.hasPermission(self.access.permissions.PLUGIN_LOGGING_MANAGE)){return;}
+if(self.configuredLoggersChanged){console.log("ConfiguredLoggers has changed. Saving!");var levels={};_.each(self.configuredLoggers(),function(data){levels[data.component]=data.level();});OctoPrint.plugins.logging.updateLevels(levels);}else{console.log("ConfiguredLoggers has not changed. Not saving.");}};self._bulkRemove=function(files){if(!self.loginState.hasPermission(self.access.permissions.PLUGIN_LOGGING_MANAGE)){return;}
+var title=gettext("Deleting log files");var message=_.sprintf(gettext("Deleting %(count)d log files..."),{count:files.length});var handler=function(filename){return OctoPrint.plugins.logging.deleteLog(filename).done(function(){deferred.notify(_.sprintf(gettext("Deleted %(filename)s..."),{filename:_.escape(filename)}),true);}).fail(function(jqXHR){var short=_.sprintf(gettext("Deletion of %(filename)s failed, continuing..."),{filename:_.escape(filename)});var long=_.sprintf(gettext("Deletion of %(filename)s failed: %(error)s"),{filename:_.escape(filename),error:_.escape(jqXHR.responseText)});deferred.notify(short,long,false);});};var deferred=$.Deferred();var promise=deferred.promise();var options={title:title,message:message,max:files.length,output:true};showProgressModal(options,promise);var requests=[];_.each(files,function(filename){var request=handler(filename);requests.push(request);});$.when.apply($,_.map(requests,wrapPromiseWithAlways)).done(function(){deferred.resolve();self.requestData();});return promise;};}
+OCTOPRINT_VIEWMODELS.push({construct:LoggingViewModel,additionalNames:["logsViewModel"],dependencies:["loginStateViewModel","accessViewModel"],elements:["#settings_plugin_logging","#navbar_plugin_logging_seriallog","#navbar_plugin_logging_plugintimingslog"]});});
+;
+
+// source: plugin/pluginmanager/js/pluginmanager.js
+$(function(){function PluginManagerViewModel(parameters){var self=this;self.loginState=parameters[0];self.settingsViewModel=parameters[1];self.printerState=parameters[2];self.systemViewModel=parameters[3];self.access=parameters[4];self.piSupport=parameters[5];self.config_repositoryUrl=ko.observable();self.config_repositoryTtl=ko.observable();self.config_noticesUrl=ko.observable();self.config_noticesTtl=ko.observable();self.config_pipAdditionalArgs=ko.observable();self.config_pipForceUser=ko.observable();self.config_confirmUninstall=ko.observable();self.config_confirmDisable=ko.observable();self.configurationDialog=$("#settings_plugin_pluginmanager_configurationdialog");self.plugins=new ItemListHelper("plugin.pluginmanager.installedplugins",{name:function(a,b){if(a["name"].toLocaleLowerCase()b["name"].toLocaleLowerCase())
+return 1;return 0;}},{"bundled":function(item){return item.bundled;},"3rdparty":function(item){return!item.bundled;},"enabled":function(item){return item.enabled;},"disabled":function(item){return!item.enabled;}},"name",[],[["bundled","3rdparty"],["enabled","disabled"]],0);self.plugins.currentFilters.subscribe(function(){self.clearPluginsSelection();});self.pluginLookup={};self.repositoryplugins=new ItemListHelper("plugin.pluginmanager.repositoryplugins",{title:function(a,b){if(a.title.toLocaleLowerCase()b.title.toLocaleLowerCase())
+return 1;return 0;},published:function(a,b){if(a.published.toLocaleLowerCase()>b.published.toLocaleLowerCase())
+return-1;if(a.published.toLocaleLowerCase()countB)return-1;if(countAvalB)return-1;if(valAvalB)return-1;if(valAvalB)return-1;if(valAb["identifier"].toLocaleLowerCase())
+return 1;return 0;}},{},"identifier",[],[],0);self.selectedPlugins=ko.observableArray([]);self.uploadElement=$("#settings_plugin_pluginmanager_repositorydialog_upload");self.uploadButton=$("#settings_plugin_pluginmanager_repositorydialog_upload_start");self.repositoryAvailable=ko.observable(undefined);self.repositorySearchQuery=ko.observable();self.repositorySearchQuery.subscribe(function(){self.performRepositorySearch();});self.listingSearchQuery=ko.observable();self.listingSearchQuery.subscribe(function(){self.performListingSearch();});self.installUrl=ko.observable();self.uploadFilename=ko.observable();self.loglines=ko.observableArray([]);self.installedPlugins=ko.observableArray([]);self.followDependencyLinks=ko.observable(false);self.pipAvailable=ko.observable(true);self.pipVersion=ko.observable();self.pipInstallDir=ko.observable();self.pipUseUser=ko.observable();self.pipVirtualEnv=ko.observable();self.pipAdditionalArgs=ko.observable();self.pipPython=ko.observable();self.safeMode=ko.observable();self.online=ko.observable();self.supportedArchiveExtensions=ko.observableArray([]);self.supportedPythonExtensions=ko.observableArray([]);self.supportedJsonExtensions=ko.observableArray([]);var createExtensionsHelp=function(extensions){return _.reduce(extensions,function(result,ext,index){return(result+'"'+
+ext+'"'+
+(indexpip that "+"have the extension %(archiveExtensions)s, or single file python "+"plugins with the extension %(pythonExtensions)s, or a plugin list "+"export with the extension %(jsonExtensions)s."),{archiveExtensions:archiveExts,pythonExtensions:pythonExts,jsonExtensions:jsonExts});});self.requestError=ko.observable(false);self.pipUseUserString=ko.pureComputed(function(){return self.pipUseUser()?"yes":"no";});self.pipVirtualEnvString=ko.pureComputed(function(){return self.pipVirtualEnv()?"yes":"no";});self.working=ko.observable(false);self.workingTitle=ko.observable();self.workingDialog=undefined;self.workingOutput=undefined;self.toggling=ko.observable(false);self.restartCommandSpec=undefined;self.systemViewModel.systemActions.subscribe(function(){var lastResponse=self.systemViewModel.lastCommandResponse;if(!lastResponse||!lastResponse.core){self.restartCommandSpec=undefined;return;}
+var restartSpec=_.filter(lastResponse.core,function(spec){return spec.action=="restart";});self.restartCommandSpec=restartSpec!=undefined&&restartSpec.length>0?restartSpec[0]:undefined;});self.noticeNotifications=[];self.hiddenNoticeNotifications={};self.noticeCount=ko.observable(0);self.notification=undefined;self.logContents={steps:[],action:{reload:false,refresh:false,reconnect:false}};self.noticeCountText=ko.pureComputed(function(){var count=self.noticeCount();if(count===0){return gettext("There are no plugin notices. Great!");}else if(count===1){return gettext("There is a plugin notice for one of your installed plugins.");}else{return _.sprintf(gettext("There are %(count)d plugin notices for one or more of your installed plugins."),{count:count});}});self.enableManagement=ko.pureComputed(function(){return!self.printerState.isBusy();});self.enableBulk=function(data){return self.enableToggle(data,true)&&!data.bundled;};self.enableToggle=function(data,ignoreToggling){var command=self._getToggleCommand(data);var not_safemode_victim=!data.safe_mode_victim;var not_blacklisted=!data.blacklisted;var not_incompatible=!data.incompatible;ignoreToggling=!!ignoreToggling;return(self.enableManagement()&&(ignoreToggling||!self.toggling())&&(command==="disable"||(not_safemode_victim&¬_blacklisted&¬_incompatible))&&data.key!=="pluginmanager");};self.enableUninstall=function(data){return(self.enableManagement()&&(data.origin!=="entry_point"||self.pipAvailable())&&data.managable&&!data.bundled&&data.key!=="pluginmanager"&&!data.pending_uninstall);};self.enableCleanup=function(data){return(self.enableManagement()&&data.key!=="pluginmanager"&&!data.pending_uninstall);};self.enableRepoInstall=function(data){return(self.pipAvailable()&&!self.safeMode()&&!self.throttled()&&self.online()&&self.isCompatible(data));};self.throttled=ko.pureComputed(function(){return(self.piSupport&&self.piSupport.currentIssue()&&!self.settingsViewModel.settings.plugins.pluginmanager.ignore_throttled());});self.invalidUrl=ko.pureComputed(function(){var allowedUrlSchemes=["http","https","git","git+http","git+https","git+ssh","git+git","hg+http","hg+https","hg+static-http","hg+ssh","svn","svn+svn","svn+http","svn+https","svn+ssh","bzr+http","bzr+https","bzr+ssh","bzr+sftp","brz+ftp","bzr+lp"];var url=self.installUrl();var lowerUrl=url!==undefined?url.toLocaleLowerCase():undefined;var lowerUrlStartsWithScheme=function(scheme){return _.startsWith(lowerUrl,scheme+"://");};return(url!==undefined&&url.trim()!==""&&!_.any(allowedUrlSchemes,lowerUrlStartsWithScheme));});self.enableUrlInstall=ko.pureComputed(function(){var url=self.installUrl();return(self.enableManagement()&&self.pipAvailable()&&!self.safeMode()&&!self.throttled()&&self.online()&&url!==undefined&&url.trim()!==""&&!self.invalidUrl());});self.hasExtension=function(name,extensions){const lowerName=name.toLocaleLowerCase();return extensions.some((ext)=>lowerName.endsWith(ext));};self.invalidFile=ko.pureComputed(function(){var allowedFileExtensions=self.supportedArchiveExtensions().concat(self.supportedPythonExtensions()).concat(self.supportedJsonExtensions());var name=self.uploadFilename();return name!==undefined&&!self.hasExtension(name,allowedFileExtensions);});self.enableFileInstall=ko.pureComputed(function(){var name=self.uploadFilename();return(self.enableManagement()&&self.pipAvailable()&&!self.safeMode()&&!self.throttled()&&name!==undefined&&name.trim()!==""&&!self.invalidFile());});self.uploadElement.fileupload({dataType:"json",maxNumberOfFiles:1,autoUpload:false,add:function(e,data){if(data.files.length===0){return false;}
+var name=data.files[0].name;self.uploadFilename(name);var isJsonFile=name!==undefined&&self.hasExtension(name,self.supportedJsonExtensions());self.uploadButton.unbind("click");self.uploadButton.bind("click",function(){const proceed=()=>{self.loginState.reauthenticateIfNecessary(()=>{self._markWorking(isJsonFile?gettext("Installing plugins..."):gettext("Installing plugin..."),isJsonFile?gettext("Installing plugins from uploaded file..."):gettext("Installing plugin from uploaded file..."));data.formData={dependency_links:self.followDependencyLinks()};data.submit();});};if(isJsonFile){showConfirmationDialog({title:gettext("Confirm installation of multiple plugins"),message:gettext("Please confirm you want to perform all plugins specified in the json file."),cancel:gettext("Cancel"),proceed:gettext("Install"),proceedClass:"primary",onproceed:proceed});}else{proceed();}
+return false;});},done:function(e,data){var response=data.result;if(!response.in_progress){if(response.result){self._markDone();}else{self._markDone(response.reason);}}
+self.uploadButton.unbind("click");self.uploadFilename(undefined);},fail:function(e,data){if(data&&data.errorThrown==="CONFLICT"){self._markDone("There's already another plugin install in progress.");}else{new PNotify({title:gettext("Something went wrong"),text:gettext("Please consult octoprint.log for details"),type:"error",hide:false});self._markDone("Could not install plugin, unknown error.");}
+self.uploadButton.unbind("click");self.uploadFilename(undefined);}});self.performListingSearch=function(){var query=self.listingSearchQuery();if(query!==undefined&&query.trim()!==""){query=query.toLocaleLowerCase();self.plugins.changeSearchFunction(function(entry){return(entry&&(entry["name"].toLocaleLowerCase().indexOf(query)>-1||(entry.description&&entry.description.toLocaleLowerCase().indexOf(query)>-1)));});}else{self.plugins.resetSearch();}};self.multiInstallQueue=ko.observableArray([]);self.queuedInstalls=ko.observableArray([]);self.multiInstallRunning=ko.observable(false);self.multiInstallInitialSize=ko.observable(0);self.multiInstallValid=function(){return(self.loginState.hasPermission(self.access.permissions.PLUGIN_PLUGINMANAGER_INSTALL)&&self.pipAvailable()&&!self.safeMode()&&!self.throttled()&&self.online()&&self.multiInstallQueue().length>0&&self.multiInstallQueue().every(self.isCompatible));};self.repoInstallSelectedButtonText=function(){return self.multiInstallQueue().some(self.installed)?"(Re)install selected":"Install selected";};self.repoInstallSelectedConfirm=function(){if(!self.multiInstallValid())return;if(self.multiInstallQueue().length===1){self.installFromRepository(self.multiInstallQueue()[0]);return;}
+var question="
";if(typeof self.installQueuePopup!=="undefined"){self.installQueuePopup.update({text:text});if(self.installQueuePopup.state==="closed"){self.installQueuePopup.open();}}else{self.installQueuePopup=new PNotify({title:gettext("Plugin installs queued"),text:text,type:"notice"});}
+if(self.multiInstallQueue().length>0){self.performMultiInstallJob();}else{self.multiInstallRunning(false);self.workingDialog.modal("hide");self._markDone();}}},onError=function(jqXHR){if(jqXHR.status===409){self._markDone("There's already another plugin install in progress.");}else{self._markDone("Could not install plugin, unknown error, please consult octoprint.log for details");new PNotify({title:gettext("Something went wrong"),text:gettext("Please consult octoprint.log for details"),type:"error",hide:false});}};if(reinstall){OctoPrint.plugins.pluginmanager.reinstall(reinstall,url,followDependencyLinks,fromRepo).done(onSuccess).fail(onError);}else{OctoPrint.plugins.pluginmanager.install(url,followDependencyLinks,fromRepo).done(onSuccess).fail(onError);}});};self.uninstallPlugin=function(data){if(!self.loginState.hasPermission(self.access.permissions.PLUGIN_PLUGINMANAGER_MANAGE)){return;}
+if(!self.enableUninstall(data)){return;}
+if(data.bundled)return;if(data.key==="pluginmanager")return;var performUninstall=function(cleanup){self._markWorking(gettext("Uninstalling plugin..."),_.sprintf(gettext('Uninstalling plugin "%(name)s"'),{name:_.escape(data.name)}));OctoPrint.plugins.pluginmanager.uninstall(data.key,cleanup).done(function(){self.requestPluginData();}).fail(function(){new PNotify({title:gettext("Something went wrong"),text:gettext("Please consult octoprint.log for details"),type:"error",hide:false});}).always(function(){self._markDone();});};showConfirmationDialog({message:_.sprintf(gettext('You are about to uninstall the plugin "%(name)s"'),{name:_.escape(data.name)}),cancel:gettext("Keep installed"),proceed:[gettext("Uninstall"),gettext("Uninstall & clean up data")],onproceed:function(button){performUninstall(button===1);},nofade:true});};self.cleanupPlugin=function(data){var key,name;if(_.isObject(data)){key=data.key;name=data.name;}else{key=name=data;}
+if(!self.loginState.isAdmin()){return;}
+if(key==="pluginmanager")return;var performCleanup=function(){self._markWorking(gettext("Cleaning up plugin data..."),_.sprintf(gettext('Cleaning up data of plugin "%(name)s"'),{name:_.escape(name)}));OctoPrint.plugins.pluginmanager.cleanup(key).done(function(){self.requestOrphanData();}).fail(function(){new PNotify({title:gettext("Something went wrong"),text:gettext("Please consult octoprint.log for details"),type:"error",hide:false});}).always(function(){self._markDone();});};showConfirmationDialog({message:_.sprintf(gettext('You are about to cleanup the plugin data of "%(name)s". This operation cannot be reversed.'),{name:_.escape(name)}),cancel:gettext("Keep data"),proceed:gettext("Cleanup data"),onproceed:performCleanup,nofade:true});};self.cleanupAll=function(){if(!self.loginState.isAdmin()){return;}
+var performCleanup=function(){var title=gettext("Cleaning up all left over plugin data...");self._markWorking(title,title);OctoPrint.plugins.pluginmanager.cleanupAll().fail(function(){new PNotify({title:gettext("Something went wrong"),text:gettext("Please consult octoprint.log for details"),type:"error",hide:false});}).always(function(){self._markDone();});};showConfirmationDialog({message:gettext("You are about to cleanup left over plugin settings and data of plugins no longer installed. This operation cannot be reversed."),cancel:gettext("Keep data"),proceed:gettext("Cleanup all data"),onproceed:performCleanup,nofade:true});};self.refreshRepository=function(){if(!self.loginState.hasPermission(self.access.permissions.PLUGIN_PLUGINMANAGER_INSTALL)){return;}
+self.requestRepositoryData({refresh:true});};self.refreshNotices=function(){if(!self.loginState.isAdmin()){return;}
+self.requestPluginData({refresh:true,eval_notices:true,ignore_notice_hidden:true,ignore_notice_ignored:true});};self.reshowNotices=function(){if(!self.loginState.isAdmin()){return;}
+self.requestPluginData({eval_notices:true,ignore_notice_hidden:true,ignore_notice_ignored:true});};self.showPluginSettings=function(){self._copyConfig();self.configurationDialog.modal();};self.savePluginSettings=function(){var repository=self.config_repositoryUrl();if(repository!==null&&repository.trim()===""){repository=null;}
+var repositoryTtl;try{repositoryTtl=parseInt(self.config_repositoryTtl());}catch(ex){repositoryTtl=null;}
+var notices=self.config_noticesUrl();if(notices!==null&¬ices.trim()===""){notices=null;}
+var noticesTtl;try{noticesTtl=parseInt(self.config_noticesTtl());}catch(ex){noticesTtl=null;}
+var pipArgs=self.config_pipAdditionalArgs();if(pipArgs!==null&&pipArgs.trim()===""){pipArgs=null;}
+var data={plugins:{pluginmanager:{repository:repository,repository_ttl:repositoryTtl,notices:notices,notices_ttl:noticesTtl,pip_args:pipArgs,pip_force_user:self.config_pipForceUser(),confirm_disable:self.config_confirmDisable()}}};self.settingsViewModel.saveData(data,function(){self.configurationDialog.modal("hide");self._copyConfig();self.requestPluginData({refresh:true,eval_notices:true});if(self.repositoryAvailable()!==undefined){self.requestRepositoryData({refresh:true});}});};self._copyConfig=function(){self.config_repositoryUrl(self.settingsViewModel.settings.plugins.pluginmanager.repository());self.config_repositoryTtl(self.settingsViewModel.settings.plugins.pluginmanager.repository_ttl());self.config_noticesUrl(self.settingsViewModel.settings.plugins.pluginmanager.notices());self.config_noticesTtl(self.settingsViewModel.settings.plugins.pluginmanager.notices_ttl());self.config_pipAdditionalArgs(self.settingsViewModel.settings.plugins.pluginmanager.pip_args());self.config_pipForceUser(self.settingsViewModel.settings.plugins.pluginmanager.pip_force_user());self.config_confirmDisable(self.settingsViewModel.settings.plugins.pluginmanager.confirm_disable());};self.installed=function(data){return _.includes(self.installedPlugins(),data.id);};self.isCompatible=function(data){return(data.is_compatible.octoprint&&data.is_compatible.os&&data.is_compatible.python);};self.installButtonAction=function(data){if(self.enableRepoInstall(data)){if(!self.installQueued(data)){self.installFromRepository(data);}else{self.removeFromQueue(data);}}else{return false;}};self.installButtonText=function(data){if(!self.isCompatible(data)){if(data.disabled){return gettext("Disabled");}else{return gettext("Incompatible");}}
+if(self.installQueued(data)){return gettext("Dequeue");}else if(self.installed(data)){return gettext("Reinstall");}else{return gettext("Install");}};self._processPluginManagementResult=function(response,action,plugin){if(response.type=="partial_result"){if(!response.result){self.loglines.push({line:gettext("Error!"),stream:"error"});self.loglines.push({line:response.reason,stream:"error"});if(response.faq){self.loglines.push({line:_.sprintf(gettext("You can find more info on this issue in the FAQ at %(url)s"),{url:faq}),stream:"error"});}}
+self.loglines.push({line:"",stream:"separator"});self.loglines.push({line:_.repeat("+",50),stream:"separator"});self.loglines.push({line:"",stream:"separator"});}else{if(response.result){if(self.queuedInstalls().length>0&&action==="install"){var plugin_dequeue=ko.utils.arrayFirst(self.queuedInstalls(),function(item){return item.url===response.source;});if(plugin_dequeue){self.queuedInstalls.remove(plugin_dequeue);}
+if(self.queuedInstalls().length===0){self.multiInstallRunning(false);self._markDone();}}else if(self.multiInstallRunning()&&action==="install"){self.alertMultiInstallJobDone(response);}else{self._markDone();}}else{self._markDone(response.reason,response.faq);}}
+self._addPluginManagementLog(response,action,plugin);self._displayPluginManagementNotification();};self._extractActionAndNameFromResult=function(result){var action=result.action;var name="Unknown";if(result.hasOwnProperty("plugin")){if(result.plugin!=="unknown"){if(_.isPlainObject(result.plugin)){name=result.plugin.name;}else{name=result.plugin;}}}
+return{action:action,name:name};};self._addPluginManagementLog=function(response,action,plugin){self.logContents.action.restart=self.logContents.action.restart||response.needs_restart;self.logContents.action.refresh=self.logContents.action.refresh||response.needs_refresh;self.logContents.action_reconnect=self.logContents.action.reconnect||response.needs_reconnect;self.logContents.steps.push({action:action,plugin:plugin,result:response.result,faq:response.faq});};self._displayPluginManagementNotification=function(){var title=gettext("Plugin management log");var text="
"+
+gettext("A restart is needed for the changes to take effect.")+"
";type="warning";if(self.restartCommandSpec&&!self.multiInstallRunning()&&!self.working()){var restartClicked=false;confirm={confirm:true,buttons:[{text:gettext("Restart now"),click:function(notice){if(restartClicked)return;restartClicked=true;showConfirmationDialog({message:gettext("This will restart your OctoPrint server.
This action may disrupt any ongoing print jobs (depending on your printer's controller and general setup that might also apply to prints run directly from your printer's internal storage)."),onproceed:function(){OctoPrint.system.executeCommand("core","restart").done(function(){notice.remove();new PNotify({title:gettext("Restart in progress"),text:gettext("The server is now being restarted in the background")});}).fail(function(){new PNotify({title:gettext("Something went wrong"),text:gettext("Trying to restart the server produced an error, please check octoprint.log for details. You'll have to restart manually.")});});},onclose:function(){restartClicked=false;}});}}]};}}else if(self.logContents.action.refresh){text+="
"+
+gettext("A refresh is needed for the changes to take effect.")+"
"+
+gettext("A reconnect to the printer is needed for the changes to take effect.")+"
";type="warning";}
+if(negativeResult)type="error";var options={title:title,text:text,type:type,hide:false};if(confirm!==undefined){options.confirm=confirm;if(self.logNotification===undefined){self.logNotification=PNotify.singleButtonNotify(options);}else{self.logNotification.update(options);self.logNotification=PNotify.fixSingleButton(self.logNotification,options);}}else{if(self.logNotification===undefined){self.logNotification=new PNotify(options);}else{self.logNotification.update(options);}}
+if(self.logNotification.state!=="open"&&self.logNotification.state!=="opening"){self.logNotification.open();}};self._markWorking=function(title,line){self.working(true);self.workingTitle(title);self.loglines.removeAll();self.loglines.push({line:line,stream:"message"});self._scrollWorkingOutputToEnd();self.workingDialog.modal({keyboard:false,backdrop:"static",show:true});};self._markDone=function(error,faq){self.working(false);if(error){self.loglines.push({line:gettext("Error!"),stream:"error"});self.loglines.push({line:error,stream:"error"});if(faq){self.loglines.push({line:_.sprintf(gettext("You can find more info on this issue in the FAQ at %(url)s"),{url:faq}),stream:"error"});}}else{self.loglines.push({line:gettext("Done!"),stream:"message"});}
+self._scrollWorkingOutputToEnd();};self._scrollWorkingOutputToEnd=function(){self.workingOutput.scrollTop(self.workingOutput[0].scrollHeight-self.workingOutput.height());};self._getToggleCommand=function(data){var disable=(data.enabled||(data.safe_mode_victim&&!data.forced_disabled)||data.pending_enable)&&!data.pending_disable;return disable?"disable":"enable";};self.toggleButtonCss=function(data){var icon,disabled;if(self.toggling()){icon="fa fa-spin fa-spinner";disabled=" disabled";}else{icon=self._getToggleCommand(data)==="enable"?"fa fa-toggle-off":"fa fa-toggle-on";disabled=self.enableToggle(data)?"":" disabled";}
+return icon+disabled;};self.toggleButtonTitle=function(data){var command=self._getToggleCommand(data);if(command==="enable"){if(data.blacklisted){return gettext("Blacklisted");}else if(data.safe_mode_victim){return gettext("Disabled due to active safe mode");}else{return gettext("Enable Plugin");}}else{return gettext("Disable Plugin");}};self.showPluginNotifications=function(plugin){if(!plugin.notifications||plugin.notifications.length===0)return;self._removeAllNoticeNotificationsForPlugin(plugin.key);_.each(plugin.notifications,function(notification){self._showPluginNotification(plugin,notification);});};self.showPluginNotificationsLinkText=function(plugins){if(!plugins.notifications||plugins.notifications.length===0)return;var count=plugins.notifications.length;var importantCount=_.filter(plugins.notifications,function(notification){return notification.important;}).length;if(count>1){if(importantCount){return _.sprintf(gettext("There are %(count)d notices (%(important)d marked as important) available regarding this plugin - click to show!"),{count:count,important:importantCount});}else{return _.sprintf(gettext("There are %(count)d notices available regarding this plugin - click to show!"),{count:count});}}else{if(importantCount){return gettext("There is an important notice available regarding this plugin - click to show!");}else{return gettext("There is a notice available regarding this plugin - click to show!");}}};self._showPluginNotification=function(plugin,notification){var name=plugin.name;var version=plugin.version;var important=notification.important;var link=notification.link;var title;if(important){title=_.sprintf(gettext('Important notice regarding plugin "%(name)s"'),{name:_.escape(name)});}else{title=_.sprintf(gettext('Notice regarding plugin "%(name)s"'),{name:_.escape(name)});}
+var text="";if(notification.versions&¬ification.versions.length>0){var versions=_.map(notification.versions,function(v){return v===version?""+_.escape(v)+"":_.escape(v);}).join(", ");text+=""+
+_.sprintf(gettext("Affected versions: %(versions)s"),{versions:versions})+"";}else{text+=""+gettext("Affected versions: all")+"";}
+text+="
"+
+gettext("To have updates applied, get in touch with an administrator of this OctoPrint instance.")+"
";}
+text+="
";var options={title:gettext("Update Available"),text:text,hide:false};var eventListeners={};var singleButtonNotify=false;if(data.status==="updatePossible"&&self.loginState.hasPermission(self.access.permissions.PLUGIN_SOFTWAREUPDATE_UPDATE)){options["confirm"]={confirm:true,buttons:[{text:gettext("Ignore"),click:function(){self._markNotificationAsSeen(data.information);self._showPopup({text:gettext('You can make this message display again via "Settings" > "Software Update" > "Check for update now"')});}},{text:gettext("Update now"),addClass:"btn-primary",click:function(){if(self._updateClicked)return;self._updateClicked=true;self.updateEnabled();}}]};options["buttons"]={closer:false,sticker:false};}else{options["confirm"]={confirm:true,buttons:[{text:gettext("Ignore"),click:function(notice){notice.remove();self._markNotificationAsSeen(data.information);}}]};options["buttons"]={closer:false,sticker:false};singleButtonNotify=true;}
+if((ignoreSeen||!self._hasNotificationBeenSeen(data.information))&&!OctoPrint.coreui.wizardOpen){self._showPopup(options,eventListeners,singleButtonNotify);}}else if(data.status==="current"){if(showIfNothingNew){self._showPopup({title:gettext("Everything is up-to-date"),type:"success"});}else{self._closePopup();}}};self.performCheck=function(showIfNothingNew,force,ignoreSeen,entries){self.checking(true);OctoPrint.plugins.softwareupdate.check({entries:entries,force:force}).done(function(data){self.fromCheckResponse(data,ignoreSeen,showIfNothingNew);}).always(function(){self.checking(false);});};self.fromUpdatelogResponse=function(response){self.updatelog(response.updatelog);};self.requestUpdatelog=function(){OctoPrint.plugins.softwareupdate.getUpdatelog().done(self.fromUpdatelogResponse);};self.iconTitleForEntry=function(data){if(data.updatePossible){return"";}else if(!data.online&&data.information&&data.information.needs_online){return gettext("No internet connection");}else if(data.error){return self.errorTextForEntry(data);}else{return gettext("Update not possible");}};self.errorTextForEntry=function(data){if(!data.error){return"";}
+switch(data.error){case"unknown_check":{return gettext("Unknown update check, configuration ok?");}
+case"needs_online":{return gettext("Cannot check for update, need online connection");}
+case"network":{return gettext("Network error while checking for update, please check the logs");}
+case"api":{return gettext("API error while checking for update, please check the logs");}
+case"ratelimit":{return gettext("Rate limit exceeded while checking for update, please try again later");}
+case"check":{return gettext("Check internal error while checking for update, please check the logs");}
+case"unknown":{return gettext("Unknown error while checking for update, please check the logs");}
+case"update":{return gettext("Unknown error while checking if update is possible, please check the logs");}
+case"windows":{return _.sprintf(gettext('Update not possible under Windows due to its strict file locking behaviour, please see the FAQ'),{url:"https://faq.octoprint.org/update-not-possible-windows"});}
+default:{return"";}}};self._markNotificationAsSeen=function(data){if(!Modernizr.localstorage)return false;var currentString=localStorage["plugin.softwareupdate.seen_information"];var current;if(currentString===undefined){current={};}else{current=JSON.parse(currentString);}
+current[self.loginState.username()]=self._informationToRemoteVersions(data);localStorage["plugin.softwareupdate.seen_information"]=JSON.stringify(current);};self._hasNotificationBeenSeen=function(data){if(!Modernizr.localstorage)return false;if(localStorage["plugin.softwareupdate.seen_information"]===undefined)
+return false;var knownData=JSON.parse(localStorage["plugin.softwareupdate.seen_information"]);var userData=knownData[self.loginState.username()];if(userData===undefined)return false;var freshData=self._informationToRemoteVersions(data);var hasBeenSeen=true;_.each(freshData,function(value,key){if(!_.has(userData,key)||userData[key]!==freshData[key]){hasBeenSeen=false;}});return hasBeenSeen;};self._informationToRemoteVersions=function(data){var result={};_.each(data,function(value,key){result[key]=value.information.remote.value;});return result;};self.performUpdate=function(force,items){if(!self.updateAccess())return;self.updateInProgress=true;var options={title:gettext("Updating..."),text:gettext("Now updating, please wait."),icon:"fa fa-cog fa-spin",hide:false,buttons:{closer:false,sticker:false}};self._showPopup(options);OctoPrint.plugins.softwareupdate.update(items,force).done(function(data){if(data.hasOwnProperty("queued")){self.queuedUpdates(data.queued);var message="
"+
+gettext("The install of the following plugin update(s) has been queued for after current print is finished or cancelled.")+'
"+
+gettext("The update could not be started. Is it already active? Please consult octoprint.log for details.")+"
"+
+_.escape(response.responseJSON.error)+"
";self._showPopup({title:gettext("Update not started!"),text:message,type:"error",hide:false,buttons:{sticker:false}});});};self.updateAll=function(force){return self.update(force,self.availableAndPossible());};self.updateEnabled=function(force){return self.update(force,self.availableAndPossibleAndEnabled());};self.updateAccess=function(){return(self.loginState.hasPermission(self.access.permissions.PLUGIN_SOFTWAREUPDATE_UPDATE)||CONFIG_FIRST_RUN);};self.update=function(force,items){if(self.updateInProgress||!self.updateAccess()){self._updateClicked=false;return;}
+if(items===undefined){items=self.availableAndPossibleAndEnabled();}
+if(self.throttled()){self._showPopup({title:gettext("Can't update while throttled"),text:gettext("Your system is currently throttled. OctoPrint refuses to run updates while in this state due to possible stability issues."),type:"error"});self._updateClicked=false;return;}
+var html="
"+
+gettext("This will update the following components and restart the server:")+"
"+
+gettext("Be sure to read through any linked release notes, especially those for OctoPrint since they might contain important information you need to know before upgrading.")+"
"+"
"+
+gettext("Updates will be queued if currently printing,")+" "+
+gettext("however this action may disrupt any ongoing print if OctoPrint is not currently controlling it.")+""+"
"+"
"+
+gettext("Are you sure you want to proceed?")+"
";showConfirmationDialog({title:gettext("Are you sure you want to update now?"),html:html,proceed:gettext("Proceed"),onproceed:function(){self.performUpdate(force===true,_.map(items,function(info){return info.key;}));},onclose:function(){self._updateClicked=false;}});};self._showWorkingDialog=function(title){if(!(self.loginState.hasPermission(self.access.permissions.PLUGIN_SOFTWAREUPDATE_CHECK)||CONFIG_FIRST_RUN)){return;}
+self.working(true);self.workingTitle(title);self.workingDialog.modal({keyboard:false,backdrop:"static",show:true});};self._markWorking=function(title,line,stream){if(stream===undefined){stream="message";}
+self.loglines.removeAll();self.loglines.push({line:line,stream:stream});self._showWorkingDialog(title);};self._markDone=function(line,stream){if(stream===undefined){stream="message";}
+self.working(false);self.loglines.push({line:"",stream:stream});self.loglines.push({line:line,stream:stream});self._scrollWorkingOutputToEnd();};self._scrollWorkingOutputToEnd=function(){self.workingOutput.scrollTop(self.workingOutput[0].scrollHeight-self.workingOutput.height());};self.onBeforeWizardTabChange=function(next,current){if(next&&next==="#wizard_plugin_softwareupdate"){self._copyConfig();}else if(current&¤t==="#wizard_plugin_softwareupdate"){self._copyConfigBack();}
+return true;};self.onAfterWizardFinish=function(){self.performCheck();};self.onStartup=function(){self.workingDialog=$("#settings_plugin_softwareupdate_workingdialog");self.workingOutput=$("#settings_plugin_softwareupdate_workingdialog_output");self.configurationDialog=$("#settings_plugin_softwareupdate_configurationdialog");};self.onServerDisconnect=function(){if(self.restartTimeout!==undefined){clearTimeout(self.restartTimeout);}
+return true;};self.onEventConnectivityChanged=function(payload){if(!payload||!payload.new)return;self.performCheck();};self.onWizardDetails=function(data){if(data.softwareupdate&&data.softwareupdate.details&&data.softwareupdate.details.update){var value=data.softwareupdate.details.update;self._enrichInformation("octoprint",value);self.octoprintData.item=value;self.octoprintData.current(value.information.local.name);self.octoprintData.available(value.information.remote.name);}};self.onDataUpdaterReconnect=function(){if(self.waitingForRestart){self.waitingForRestart=false;self.updateInProgress=false;if(!self.reloadOverlay.is(":visible")){self.reloadOverlay.show();}}};self.cancelQueued=function(items){self.cancelInProgress=true;OctoPrint.plugins.softwareupdate.cancelQueued({targets:_.map(items,function(info){return info.key;})}).done(function(data){self.queuedUpdates(data.queued);self.cancelInProgress=false;}).fail(function(response){console.log(response);self.cancelInProgress=false;});};self.onDataUpdaterPluginMessage=function(plugin,data){if(plugin!=="softwareupdate"){return;}
+var messageType=data.type;var messageData=data.data;var options=undefined;var restartType=undefined;var title=undefined;var text=undefined;switch(messageType){case"loglines":case"updating":case"restarting":case"restart_manually":case"restart_failed":case"success":case"error":{if(!self.working()){self._markWorking(gettext("Updating..."),gettext("Updating, please wait."));}
+break;}}
+switch(messageType){case"loglines":{_.each(messageData.loglines,function(line){self.loglines.push(self._preprocessLine(line));});self._scrollWorkingOutputToEnd();break;}
+case"updating":{text=_.sprintf(gettext("Now updating %(name)s to %(version)s"),{name:_.escape(messageData.name),version:_.escape(messageData.version)});self.loglines.push({line:"",stream:"separator"});self.loglines.push({line:_.repeat("+",text.length),stream:"separator"});self.loglines.push({line:text,stream:"message"});self.loglines.push({line:_.repeat("+",text.length),stream:"separator"});self._scrollWorkingOutputToEnd();self._updatePopup({text:text,hide:false,buttons:{sticker:false}});break;}
+case"restarting":{title=gettext("Update successful, restarting!");text=gettext("The update finished successfully and the server will now be restarted.");options={title:title,text:text,type:"success",hide:false,buttons:{sticker:false}};self.loglines.push({line:text,stream:"message"});self._scrollWorkingOutputToEnd();self.waitingForRestart=true;self.restartTimeout=setTimeout(function(){title=gettext("Restart failed");text=gettext("The server apparently did not restart by itself, you'll have to do it manually. Please consult octoprint.log on what went wrong.");self._showPopup({title:title,text:text,type:"error",hide:false,buttons:{sticker:false}});self.waitingForRestart=false;self._markDone(text,"message_error");},60000);break;}
+case"restart_manually":{restartType=messageData.restart_type;text=gettext("The update finished successfully, please restart OctoPrint now.");if(restartType==="environment"){text=gettext("The update finished successfully, please reboot the server now.");}
+title=gettext("Update successful, restart required!");options={title:title,text:text,type:"success",hide:false,buttons:{sticker:false}};self.updateInProgress=false;self._markDone(text);break;}
+case"restart_failed":{restartType=messageData.restart_type;text=gettext("Restarting OctoPrint failed, please restart it manually. You might also want to consult octoprint.log on what went wrong here.");if(restartType==="environment"){text=gettext("Rebooting the server failed, please reboot it manually. You might also want to consult octoprint.log on what went wrong here.");}
+title=gettext("Restart failed");options={title:title,test:text,type:"error",hide:false,buttons:{sticker:false}};self.waitingForRestart=false;self.updateInProgress=false;self._markDone(text,"message_error");break;}
+case"success":{title=gettext("Update successful!");text=gettext("The update finished successfully.");options={title:title,text:text,type:"success",hide:false,buttons:{sticker:false}};self.updateInProgress=false;self._markDone(text);break;}
+case"error":{title=gettext("Update failed!");text=gettext("The update did not finish successfully. Please consult octoprint.log and plugin_softwareupdate_console.log for details.");self._showPopup({title:title,text:text,type:"error",hide:false,buttons:{sticker:false}});self.updateInProgress=false;self._markDone(text,"message_error");break;}
+case"update_versions":{self.performCheck();break;}
+case"queued_updates":{if(!self.updateAccess()){return;}
+if(messageData.hasOwnProperty("targets")){self.queuedUpdates(messageData.targets);var queuedUpdatesPopupOptions={title:title,text:text,type:"notice",icon:false,hide:false,buttons:{closer:false,sticker:false},history:{history:false}};if(messageData.print_failed&&messageData.targets.length>0){queuedUpdatesPopupOptions.title=gettext("Queued Updates Paused");queuedUpdatesPopupOptions.text='
";queuedUpdatesPopupOptions.confirm={confirm:true,buttons:[{text:gettext("Cancel Updates"),addClass:"btn-block btn-danger",promptTrigger:true,click:function(notice,value){notice.remove();notice.get().trigger("pnotify.cancel",[notice,value]);}},{text:"",addClass:"hidden"}]};}else{if(typeof self.queuedUpdatesPopup!=="undefined"){self.queuedUpdatesPopup.remove();self.queuedUpdatesPopup=undefined;}
+return;}
+if(typeof self.queuedUpdatesPopup!=="undefined"){self.queuedUpdatesPopup.update(queuedUpdatesPopupOptions);}else{self.queuedUpdatesPopup=new PNotify(queuedUpdatesPopupOptions);self.queuedUpdatesPopup.get().on("pnotify.cancel",function(){self.queuedUpdatesPopup=undefined;self.cancelQueued();});self.queuedUpdatesPopup.get().on("pnotify.continue",function(){self.queuedUpdatesPopup=undefined;self.performUpdate(true,self.queuedUpdates());self._updateClicked=false;});}}else{if(typeof self.queuedUpdatesPopup!=="undefined"){self.queuedUpdatesPopup.remove();self.queuedUpdatesPopup=undefined;}}}
+if(options!==undefined){self._showPopup(options);}}
+self._forcedStdoutPatterns=["You are using pip version .*?, however version .*? is available.","You should consider upgrading via the '.*?' command.","'.*?' does not exist -- can't clean it"];self._forcedStdoutLine=new RegExp(self._forcedStdoutPatterns.join("|"));self._preprocessLine=function(line){if(line.stream==="stderr"&&line.line.match(self._forcedStdoutLine)){line.stream="stdout";}
+return line;};};}
+OCTOPRINT_VIEWMODELS.push({construct:SoftwareUpdateViewModel,dependencies:["loginStateViewModel","printerStateViewModel","settingsViewModel","accessViewModel","piSupportViewModel"],optional:["piSupportViewModel"],elements:["#settings_plugin_softwareupdate","#softwareupdate_confirmation_dialog","#wizard_plugin_softwareupdate_update","#wizard_plugin_softwareupdate_settings"]});});
+;
+
+// source: plugin/tracking/js/usage.js
+$(function(){function UsageViewModel(parameters){var self=this;self.settingsViewModel=parameters[0];self.setup=ko.observable(false);self.decision=ko.observable();self.active=ko.observable();self.required=false;self.onStartupComplete=function(){OctoPrint.plugins.tracking.track("webui_load",{browser_name:OctoPrint.coreui.browser.browser_name,browser_version:OctoPrint.coreui.browser.browser_version,os_name:OctoPrint.coreui.browser.os_name,os_version:OctoPrint.coreui.browser.os_version});};self.enableUsage=function(){self.settingsViewModel.settings.plugins.tracking.enabled(true);self.decision(true);self._sendData();};self.disableUsage=function(){self.settingsViewModel.settings.plugins.tracking.enabled(false);self.decision(false);self._sendData();};self.onBeforeWizardTabChange=function(next,current){if(!self.required)return true;if(!current||!_.startsWith(current,"wizard_plugin_tracking")||self.setup()){return true;}
+self._showDecisionNeededDialog();return false;};self.onBeforeWizardFinish=function(){if(!self.required)return true;if(self.setup()){return true;}
+self._showDecisionNeededDialog();return false;};self.onWizardDetails=function(response){self.required=response&&response.tracking&&response.tracking.required;};self._showDecisionNeededDialog=function(){showMessageDialog({title:gettext("Please set up anonymous usage tracking"),message:gettext("You haven't yet decided on whether to enable or disable anonymous usage tracking. You need to either enable or disable it before continuing.")});};self._sendData=function(){var data={plugins:{tracking:{enabled:self.settingsViewModel.settings.plugins.tracking.enabled()}}};self.active(true);self.settingsViewModel.saveData(data).done(function(){self.setup(true);self.active(false);}).fail(function(){self.decision(false);self.setup(true);self.active(false);var message=gettext("Please open a "+"bug report on this. Make sure to include all requested information, including your "+"JS console and "+"octoprint.log.");new PNotify({title:gettext("Something went wrong"),text:_.sprintf(message,{bugreport:"https://github.com/OctoPrint/OctoPrint/blob/master/CONTRIBUTING.md#how-to-file-a-bug-report",jsconsole:"https://webmasters.stackexchange.com/a/77337"}),type:"error",hide:false});});};}
+OCTOPRINT_VIEWMODELS.push([UsageViewModel,["settingsViewModel"],"#wizard_plugin_tracking"]);});
+;
+
+// source: js/app/dataupdater.js
+function DataUpdater(allViewModels,connectCallback,disconnectCallback){var self=this;self.allViewModels=allViewModels;self.connectCallback=connectCallback;self.disconnectCallback=disconnectCallback;self._pluginHash=undefined;self._configHash=undefined;self._connectedDeferred=undefined;self._initializedDeferred=undefined;self._throttleFactor=1;self._baseProcessingLimit=500.0;self._lastProcessingTimes=[];self._lastProcessingTimesSize=20;self._safeModePopup=undefined;self._reloadPopup=undefined;self.increaseThrottle=function(){self.setThrottle(self._throttleFactor+1);};self.decreaseThrottle=function(){if(self._throttleFactor<=1){return;}
+self.setThrottle(self._throttleFactor-1);};self.setThrottle=function(throttle){self._throttleFactor=throttle;self._send("throttle",self._throttleFactor);log.debug("DataUpdater: New SockJS throttle factor:",self._throttleFactor," new processing limit:",self._baseProcessingLimit*self._throttleFactor);};self._send=function(message,data){var payload={};payload[message]=data;self._socket.send(JSON.stringify(payload));};self.connect=function(){if(self._connectedDeferred){self._connectedDeferred.reject("reconnect");}
+self._connectedDeferred=$.Deferred();OctoPrint.socket.connect({debug:!!SOCKJS_DEBUG,connectTimeout:SOCKJS_CONNECT_TIMEOUT});return self._connectedDeferred.promise();};self.reconnect=function(){if(self._connectedDeferred){self._connectedDeferred.reject("reconnect");}
+self._connectedDeferred=$.Deferred();OctoPrint.socket.reconnect();return self._connectedDeferred.promise();};self.initialized=function(){if(self._initializedDeferred){self._initializedDeferred.resolve();self._initializedDeferred=undefined;}};self._onReconnectAttempt=function(trial){if(trial<=0){return;}
+var handled=false;callViewModelsIf(self.allViewModels,"onServerDisconnect",function(){return!handled;},function(method){var result=method();handled=(result!==undefined&&!result)||handled;});if(handled){return true;}
+showOfflineOverlay(gettext("Server is offline"),gettext("The server appears to be offline, at least I'm not getting any response from it. I'll try to reconnect automatically over the next couple of minutes, however you are welcome to try a manual reconnect anytime using the button below."),self.reconnect);};self._onReconnectFailed=function(){var handled=false;callViewModelsIf(self.allViewModels,"onServerDisconnect",function(){return!handled;},function(method){var result=method();handled=(result!==undefined&&!result)||handled;});if(handled){return;}
+$("#offline_overlay_title").text(gettext("Server is offline"));$("#offline_overlay_message").html(gettext("The server appears to be offline, at least I'm not getting any response from it. I could not reconnect automatically, but you may try a manual reconnect using the button below."));};self._onDisconnected=function(code){if(self._initializedDeferred){self._initializedDeferred.reject();}
+self._initializedDeferred=undefined;if(self.disconnectCallback){self.disconnectCallback();}};self._onConnectTimeout=function(){if(self._connectedDeferred){self._connectedDeferred.reject("timeout");}};self._onConnectMessage=function(event){if(self._initializedDeferred){self._initializedDeferred.reject();}
+self._initializedDeferred=$.Deferred();if(self.connectCallback){self.connectCallback();}
+var data=event.data;PERMISSIONS=data["permissions"];var oldVersion=VERSION;VERSION=data["version"];DISPLAY_VERSION=data["display_version"];BRANCH=data["branch"];PYTHON_VERSION=data["python_version"];$("span.version").text(DISPLAY_VERSION);$("span.python_version").text(PYTHON_VERSION);ONLINE=data["online"];var oldPluginHash=self._pluginHash;self._pluginHash=data["plugin_hash"];var oldConfigHash=self._configHash;self._configHash=data["config_hash"];log.info("Connected to the server");if(self._connectedDeferred){self._connectedDeferred.resolve();self._connectedDeferred=undefined;}
+self._ifInitialized(function(){if(self._safeModePopup)self._safeModePopup.remove();if(data["safe_mode"]){log.info("❗ Safe mode is active. Third party plugins and language packs are disabled and cannot be enabled.");log.info("❗ Reason for safe mode: "+data["safe_mode"]);var reason=gettext("Unknown");switch(data["safe_mode"]){case"flag":{reason=gettext("Command line flag");break;}
+case"settings":{reason=gettext("Setting in config.yaml");break;}
+case"incomplete_startup":{reason=gettext("Problem during last startup");break;}}
+self._safeModePopup=new PNotify({title:gettext("Safe mode is active"),text:_.sprintf(gettext("
The server is currently running in safe mode. Third party plugins and language packs are disabled and cannot be enabled.
Reason: %(reason)s
"),{reason:_.escape(reason)}),hide:false});}
+if($("#offline_overlay").is(":visible")){hideOfflineOverlay();log.info("Triggering reconnect on all view models");callViewModels(self.allViewModels,"onServerReconnect");callViewModels(self.allViewModels,"onDataUpdaterReconnect");}else{log.info("Triggering connect on all view models");callViewModels(self.allViewModels,"onServerConnect");}
+const versionChanged=oldVersion!==VERSION;const pluginsChanged=oldPluginHash!==undefined&&oldPluginHash!==self._pluginHash;const configChanged=oldConfigHash!==undefined&&oldConfigHash!==self._configHash;if(versionChanged){showReloadOverlay();}else if(pluginsChanged||configChanged){if(self._reloadPopup)self._reloadPopup.remove();let text;if(pluginsChanged&&configChanged){text=gettext("A client reconnect happened and the configuration of the server and the active UI relevant plugins have changed.");}else if(pluginsChanged){text=gettext("A client reconnect happened and the active UI relevant plugins have changed.");}else if(configChanged){text=gettext("A client reconnect happened and the configuration of the server has changed.");}
+self._reloadPopup=new PNotify({title:gettext("Page reload recommended"),text:"
"+
+text+"
"+"
"+
+gettext("Due to this a reload of the UI is recommended. "+"Please reload the UI now by clicking "+'the "Reload" button below. This will not interrupt '+"any print jobs you might have ongoing.")+"
",hide:false,confirm:{confirm:true,buttons:[{text:gettext("Ignore"),click:function(){self._reloadPopup.remove();}},{text:gettext("Reload"),addClass:"btn-primary",click:function(){self._reloadPopup.remove();location.reload(true);}}]},buttons:{closer:false,sticker:false}});}
+log.info("Server (re)connect processed");});};self._onHistoryData=function(event){self._ifInitialized(function(){callViewModels(self.allViewModels,"fromHistoryData",[event.data]);});};self._onCurrentData=function(event){self._ifInitialized(function(){callViewModels(self.allViewModels,"fromCurrentData",[event.data]);});};self._onSlicingProgress=function(event){self._ifInitialized(function(){$("#gcode_upload_progress").find(".bar").text(_.sprintf(gettext("Slicing ... (%(percentage)d%%)"),{percentage:Math.round(event.data["progress"])}));var data=event.data;callViewModels(self.allViewModels,"onSlicingProgress",[data["slicer"],data["model_path"],data["machinecode_path"],data["progress"]]);});};self._onRenderProgress=function(event){self._ifInitialized(function(){var data=event.data;callViewModels(self.allViewModels,"onRenderProgress",[data["progress"]]);});};self._printerErrorCancelNotification=undefined;self._printerErrorDisconnectNotification=undefined;self._printerResetNotification=undefined;self._onEvent=function(event){self._ifInitialized(function(){var type=event.data["type"];var payload=event.data["payload"];var title,text,severity;log.debug("Got event "+type+" with payload: "+JSON.stringify(payload));if(type==="PrintCancelling"&&payload.firmwareError){if(self._printerErrorCancelNotification!==undefined){self._printerErrorCancelNotification.remove();}
+self._printerErrorCancelNotification=new PNotify({title:gettext("Error reported by printer"),text:_.sprintf(gettext("Your printer's firmware reported an error. Due to that the ongoing print job will be cancelled. Reported error: %(firmwareError)s"),{firmwareError:_.escape(payload.firmwareError)}),type:"error",hide:false});}else if(type==="Error"&&payload.error){severity="error";switch(payload.reason){case"firmware":{title=gettext("Error reported by printer");text=_.sprintf(gettext("Your printer's firmware reported an error. Due to that OctoPrint will disconnect. Reported error: %(error)s"),{error:_.escape(payload.error)});break;}
+case"resend":case"resend_loop":case"timeout":{title=gettext("Communication error");text=_.sprintf(gettext("There was a communication error while talking to your printer. Please consult the terminal output and octoprint.log for details. Error: %(error)s"),{error:_.escape(payload.error)});break;}
+case"connection":{title=gettext("Error connecting to printer");text=_.sprintf(gettext("There was an error while trying to connect to your printer. Error: %(error)s"),{error:_.escape(payload.error)});break;}
+case"start_print":{title=gettext("Error starting a print");text=_.sprintf(gettext("There was an error while trying to start a print job. Error: %(error)s"),{error:_.escape(payload.error)});break;}
+case"autodetect":{title=gettext("Could not autodetect your printer");text=_.sprintf(gettext('No working connection parameters could be found. Are you sure your printer is physically connected and supported? Refer to the FAQ for help in debugging this.'),{url:"https://faq.octoprint.org/connection-error"});break;}
+default:{title=gettext("Unknown error");text=_.sprintf(gettext("There was an unknown error while talking to your printer. Please consult the terminal output and octoprint.log for details. Error: %(error)s"),{error:_.escape(payload.error)});break;}}
+if(title&&text){if(self._printerErrorDisconnectNotification!==undefined){self._printerErrorDisconnectNotification.remove();}
+self._printerErrorDisconnectNotification=new PNotify({title:title,text:text,type:severity,hide:false});}}else if(type==="PrinterReset"){if(payload.idle){text=gettext("It looks like your printer reset while a connection was active. If this was intentional you may safely ignore this message. Otherwise you should investigate why your printer reset itself, since this will interrupt prints and also file transfers to your printer's SD.");severity="alert";}else{text=gettext("It looks like your printer reset while a connection was active. Due to this the ongoing job was aborted. If this was intentional you may safely ignore this message. Otherwise you should investigate why your printer reset itself, since this will interrupt prints and also file transfers to your printer's SD.");severity="error";}
+if(self._printerResetNotification!==undefined){self._printerResetNotification.remove();}
+self._printerResetNotification=new PNotify({title:gettext("Printer reset detected"),text:text,type:severity,hide:false});}else if(type==="ConnectivityChanged"){ONLINE=payload.new;}else if(type==="SettingsUpdated"){self._configHash=payload.config_hash;}
+var legacyEventHandlers={UpdatedFiles:"onUpdatedFiles",MetadataStatisticsUpdated:"onMetadataStatisticsUpdated",MetadataAnalysisFinished:"onMetadataAnalysisFinished",SlicingDone:"onSlicingDone",SlicingCancelled:"onSlicingCancelled",SlicingFailed:"onSlicingFailed"};const camelCaseType=type.split("_").map((item)=>item.charAt(0).toUpperCase()+item.slice(1)).join("");_.each(self.allViewModels,function(viewModel){if(viewModel.hasOwnProperty("onEvent"+camelCaseType)){viewModel["onEvent"+camelCaseType](payload);}else if(type!==camelCaseType&&viewModel.hasOwnProperty("onEvent"+type)){viewModel["onEvent"+type](payload);}else if(legacyEventHandlers.hasOwnProperty(type)&&viewModel.hasOwnProperty(legacyEventHandlers[type])){log.warn("View model "+
+viewModel.name+" is using legacy event handler "+
+legacyEventHandlers[type]+", new handler is called "+
+legacyEventHandlers[type]);viewModel[legacyEventHandlers[type]](payload);}});});};self._onTimelapse=function(event){self._ifInitialized(function(){callViewModels(self.allViewModels,"fromTimelapseData",[event.data]);});};self._onPluginMessage=function(event){self._ifInitialized(function(){callViewModels(self.allViewModels,"onDataUpdaterPluginMessage",[event.data.plugin,event.data.data]);});};self._onReauthMessage=function(event){self._ifInitialized(function(){callViewModels(self.allViewModels,"onDataUpdaterReauthRequired",[event.data.reason]);});};self._onIncreaseRate=function(measurement,minimum){log.debug("We are fast ("+measurement+" < "+minimum+"), increasing refresh rate");OctoPrint.socket.increaseRate();};self._onDecreaseRate=function(measurement,maximum){log.debug("We are slow ("+measurement+" > "+maximum+"), reducing refresh rate");OctoPrint.socket.decreaseRate();};self._ifInitialized=function(callback){if(self._initializedDeferred){self._initializedDeferred.done(callback);}else{callback();}};OctoPrint.socket.onDisconnected=self._onDisconnected;OctoPrint.socket.onReconnectAttempt=self._onReconnectAttempt;OctoPrint.socket.onReconnectFailed=self._onReconnectFailed;OctoPrint.socket.onConnectTimeout=self._onConnectTimeout;OctoPrint.socket.onRateTooHigh=self._onDecreaseRate;OctoPrint.socket.onRateTooLow=self._onIncreaseRate;OctoPrint.socket.onMessage("connected",self._onConnectMessage).onMessage("history",self._onHistoryData).onMessage("current",self._onCurrentData).onMessage("slicingProgress",self._onSlicingProgress).onMessage("renderProgress",self._onRenderProgress).onMessage("event",self._onEvent).onMessage("timelapse",self._onTimelapse).onMessage("plugin",self._onPluginMessage).onMessage("reauthRequired",self._onReauthMessage);}
+;
+
+// source: js/app/helpers.js
+function ItemListHelper(listType,supportedSorting,supportedFilters,defaultSorting,defaultFilters,exclusiveFilters,defaultPageSize,persistPageSize){var self=this;self.listType=listType;self.supportedSorting=supportedSorting;self.supportedFilters=supportedFilters;self.defaultSorting=defaultSorting;self.defaultFilters=defaultFilters;self.exclusiveFilters=exclusiveFilters;self.defaultPageSize=defaultPageSize;self.persistPageSize=!!persistPageSize;self.searchFunction=undefined;self.allItems=[];self.allSize=ko.observable(0);self.items=ko.observableArray([]);self.pageSize=ko.observable(self.defaultPageSize);self.currentPage=ko.observable(0);self.currentSorting=ko.observable(self.defaultSorting);self.currentFilters=ko.observableArray(self.defaultFilters);self.selectedItem=ko.observable(undefined);self.filterSearch=ko.observable(true);self.storageIds={currentSorting:self.listType+"."+"currentSorting",currentFilters:self.listType+"."+"currentFilters",pageSize:self.listType+"."+"pageSize"};self.refresh=function(){self._updateItems();};self.updateItems=function(items){if(items===undefined)items=[];self.allItems=items;self.allSize(items.length);self._updateItems();};self.selectItem=function(matcher){var itemList=self.items();for(var i=0;i-1){self.allItems.splice(index,1);self._updateItems();}};self.updateItem=function(matcher,item){var index=self.allItems.findIndex(matcher);if(index>-1){self.allItems[index]=item;self._updateItems();}};self.addItem=function(item){self.allItems.push(item);self._updateItems();};self.paginatedItems=ko.dependentObservable(function(){if(self.items()===undefined){return[];}else if(self.pageSize()===0){return self.items();}else{var from=Math.max(self.currentPage()*self.pageSize(),0);var to=Math.min(from+self.pageSize(),self.items().length);return self.items().slice(from,to);}});self.lastPage=ko.dependentObservable(function(){return self.pageSize()===0?1:Math.ceil(self.items().length/self.pageSize())-1;});self.pages=ko.dependentObservable(function(){var pages=[];var i;if(self.pageSize()===0){pages.push({number:0,text:1});}else if(self.lastPage()<7){for(i=0;iself.lastPage()-5){pages.push({number:-1,text:"…"});for(i=self.lastPage()-4;i-1){var page=Math.floor(pos/self.pageSize());self.changePage(page);}};self.changePage=function(newPage){if(newPage<0||newPage>self.lastPage())return;self.currentPage(newPage);};self.prevPage=function(){if(self.currentPage()>0){self.currentPage(self.currentPage()-1);}};self.nextPage=function(){if(self.currentPage()-1?self.allItems[index]:undefined;}else{return index>-1?self.items()[index]:undefined;}};self.resetPage=function(){if(self.currentPage()>self.lastPage()){self.currentPage(self.lastPage());}};self.changeSearchFunction=function(searchFunction){self.searchFunction=searchFunction;self.changePage(0);self._updateItems();};self.resetSearch=function(){self.changeSearchFunction(undefined);};self.changeSorting=function(sorting){if(!_.contains(_.keys(self.supportedSorting),sorting))return;self.currentSorting(sorting);self._saveCurrentSortingToLocalStorage();self.changePage(0);self._updateItems();};self.setFilterSearch=function(enabled){if(self.filterSearch()===enabled)return;self.filterSearch(enabled);self.changePage(0);self._updateItems();};self.toggleFilterSearch=function(){self.setFilterSearch(!self.filterSearch());};self.toggleFilter=function(filter){if(!_.contains(_.keys(self.supportedFilters),filter))return;if(_.contains(self.currentFilters(),filter)){self.removeFilter(filter);}else{self.addFilter(filter);}};self.addFilter=function(filter){if(!_.contains(_.keys(self.supportedFilters),filter))return;for(var i=0;i=1){if(hours>=16){replacements.days+=1;if(replacements.days===1){text=gettext("%(days)d day");}else{text=gettext("%(days)d days");}}else if(hours>=8&&hours<16){text=gettext("%(days)d.5 days");}else{if(days===1){text=gettext("%(days)d day");}else{text=gettext("%(days)d days");}}}else if(hours>=1){if(hours<12){if(minutes<15){if(hours===1){text=gettext("%(hours)d hour");}else{text=gettext("%(hours)d hours");}}else if(minutes>=15&&minutes<45){text=gettext("%(hours)d.5 hours");}else{replacements.hours+=1;if(replacements.hours===1){text=gettext("%(hours)d hour");}else{text=gettext("%(hours)d hours");}}}else{if(hours===23&&minutes>30){text=gettext("1 day");}else{if(minutes>30){replacements.hours+=1;}
+text=gettext("%(hours)d hours");}}}else if(minutes>=1){if(minutes<2){if(seconds<30){text=gettext("a minute");}else{text=gettext("2 minutes");}}else if(minutes<30){if(seconds>30){replacements.minutes+=1;}
+text=gettext("%(minutes)d minutes");}else if(minutes<=40){text=gettext("40 minutes");}else if(minutes<=50){text=gettext("50 minutes");}else{text=gettext("1 hour");}}else{if(seconds<30){text=gettext("a few seconds");}else{text=gettext("less than a minute");}}
+return _.sprintf(text,replacements);}
+function formatDate(unixTimestamp,options){if(!options){options={seconds:false};}
+var placeholder=options.placeholder||"-";if(!unixTimestamp)return placeholder;var format=gettext("YYYY-MM-DD HH:mm");if(options.seconds){format=gettext("YYYY-MM-DD HH:mm:ss");}
+return moment.unix(unixTimestamp).format(format);}
+function formatTimeAgo(unixTimestamp,placeholder){placeholder=placeholder||"-";if(!unixTimestamp)return placeholder;return moment.unix(unixTimestamp).fromNow();}
+function formatFilament(filament){if(!filament||!filament["length"])return"-";var result="%(length).02fm";if(filament.hasOwnProperty("volume")&&filament.volume){result+=" / "+"%(volume).02fcm³";}
+return _.sprintf(result,{length:filament["length"]/1000,volume:filament["volume"]});}
+function cleanTemperature(temp,offThreshold){if(temp===undefined||!_.isNumber(temp))return"-";if(offThreshold!==undefined&&temp1000){num=num/1000.0;return _.sprintf("%.2fk",num);}else{return _.sprintf("%i",num);}}
+function rsplit(str,sep,limit){const parts=str.split(sep);return limit?[parts.slice(0,-limit).join(sep)].concat(parts.slice(-limit)):parts;}
+function pnotifyAdditionalInfo(inner){return('