diff --git a/supervisor/shared/web_workflow/static/blinka_16x16.ico b/supervisor/shared/web_workflow/static/blinka_16x16.ico deleted file mode 100644 index ff2937dfee..0000000000 Binary files a/supervisor/shared/web_workflow/static/blinka_16x16.ico and /dev/null differ diff --git a/supervisor/shared/web_workflow/static/blinka_32x32.ico b/supervisor/shared/web_workflow/static/blinka_32x32.ico new file mode 100644 index 0000000000..5aca98376a Binary files /dev/null and b/supervisor/shared/web_workflow/static/blinka_32x32.ico differ diff --git a/supervisor/shared/web_workflow/static/directory.html b/supervisor/shared/web_workflow/static/directory.html index cf9ff507f9..56498c1329 100644 --- a/supervisor/shared/web_workflow/static/directory.html +++ b/supervisor/shared/web_workflow/static/directory.html @@ -3,7 +3,6 @@ - @@ -21,4 +20,5 @@
+📁  + diff --git a/supervisor/shared/web_workflow/static/directory.js b/supervisor/shared/web_workflow/static/directory.js index a89d5e5602..2068ca38ea 100644 --- a/supervisor/shared/web_workflow/static/directory.js +++ b/supervisor/shared/web_workflow/static/directory.js @@ -267,3 +267,13 @@ new_directory_name.oninput = () => { } window.onhashchange = refresh_list; + +window.addEventListener("pageshow", function (event) { + var historyTraversal = event.persisted || + (typeof window.performance != "undefined" && + window.performance.navigation.type === 2); + if (historyTraversal) { + // Handle page restore. + window.location.reload(); + } +}); diff --git a/supervisor/shared/web_workflow/static/serial.html b/supervisor/shared/web_workflow/static/serial.html index 9193953443..24fb3a3d32 100644 --- a/supervisor/shared/web_workflow/static/serial.html +++ b/supervisor/shared/web_workflow/static/serial.html @@ -4,7 +4,6 @@ Simple client - @@ -16,11 +15,13 @@
Ctrl +
+ diff --git a/supervisor/shared/web_workflow/static/serial.js b/supervisor/shared/web_workflow/static/serial.js index 5c644795a0..52cde95396 100644 --- a/supervisor/shared/web_workflow/static/serial.js +++ b/supervisor/shared/web_workflow/static/serial.js @@ -72,6 +72,17 @@ input.addEventListener("beforeinput", function(e) { } }); +window.addEventListener("unload", function() { + if (ws.readyState == WebSocket.OPEN) { + ws.close(); + } +}); + +let ctrl_b = document.querySelector("#b"); +ctrl_b.onclick = function() { + ws.send("\x02"); +} + let ctrl_c = document.querySelector("#c"); ctrl_c.onclick = function() { ws.send("\x03"); diff --git a/supervisor/shared/web_workflow/static/welcome.html b/supervisor/shared/web_workflow/static/welcome.html index efbb30e312..ffd23b72e9 100644 --- a/supervisor/shared/web_workflow/static/welcome.html +++ b/supervisor/shared/web_workflow/static/welcome.html @@ -4,7 +4,6 @@ CircuitPython - @@ -30,5 +29,6 @@

Here are other CircuitPython devices on your network:

+ diff --git a/supervisor/shared/web_workflow/web_workflow.c b/supervisor/shared/web_workflow/web_workflow.c index d24547dd09..30ff2004a7 100644 --- a/supervisor/shared/web_workflow/web_workflow.c +++ b/supervisor/shared/web_workflow/web_workflow.c @@ -1002,7 +1002,7 @@ STATIC_FILE(edit_js); STATIC_FILE(style_css); STATIC_FILE(serial_html); STATIC_FILE(serial_js); -STATIC_FILE(blinka_16x16_ico); +STATIC_FILE(blinka_32x32_ico); static void _reply_static(socketpool_socket_obj_t *socket, _request *request, const uint8_t *response, size_t response_len, const char *content_type) { uint32_t total_length = response_len; @@ -1303,7 +1303,7 @@ static bool _reply(socketpool_socket_obj_t *socket, _request *request) { } else if (strcmp(request->path, "/favicon.ico") == 0) { // TODO: Autogenerate this based on the blinka bitmap and change the // palette based on MAC address. - _REPLY_STATIC(socket, request, blinka_16x16_ico); + _REPLY_STATIC(socket, request, blinka_32x32_ico); } else { _reply_missing(socket, request); }