Web interface: add keypress to non-interactive elements with on:click

This commit is contained in:
SG 2023-09-22 08:09:37 +03:00
parent d0b0031ce2
commit ab9435151b
3 changed files with 10 additions and 3 deletions

View File

@ -60,6 +60,9 @@
on:click={() => {
change_tab(tab);
}}
on:keypress={() => {
change_tab(tab);
}}
>
{tab}
</tab>
@ -81,7 +84,11 @@
</tab-content>
{:else if current_tab == tabs[3]}
<tab-content>
<UartTerminal bind:this={uart_terminal} on_mount={uart_on_mount} send={uart_send}/>
<UartTerminal
bind:this={uart_terminal}
on_mount={uart_on_mount}
send={uart_send}
/>
</tab-content>
{/if}
</tabs-content>

View File

@ -2,7 +2,7 @@
let server = "";
if (development_mode) {
server = "http://172.30.1.83";
server = "http://192.168.0.18";
}
export const api = {

View File

@ -14,7 +14,7 @@
<popup-wrapper>
<popup-body>
<popup-content>
<popup-close on:click={close}>X</popup-close>
<popup-close on:click={close} on:keypress={close}>X</popup-close>
<popup-border>
<slot />
</popup-border>