fix: add ui when no device is connected

fixes #60
This commit is contained in:
2023-12-08 22:38:46 +01:00
parent f44e5a79de
commit 9d7cefb3b4
3 changed files with 19 additions and 0 deletions

View File

@@ -59,6 +59,7 @@ const de = {
DISCONNECT: "Entfernen",
TERMINAL: "Konsole",
APPLY_SETTINGS: "Änderungen auf das Gerät brennen",
NO_DEVICE: "Kein Gerät verbunden",
bootMenu: {
TITLE: "Bootmenü",
REBOOT: "Neustarten",

View File

@@ -58,6 +58,7 @@ const en = {
DISCONNECT: "Disconnect",
TERMINAL: "Terminal",
APPLY_SETTINGS: "Flash changes to device",
NO_DEVICE: "No device connected",
bootMenu: {
TITLE: "Boot Menu",
REBOOT: "Reboot",

View File

@@ -0,0 +1,17 @@
<script>
import {serialPort} from "$lib/serial/connection"
import {LL} from "../../i18n/i18n-svelte"
</script>
{#if $serialPort}
<slot />
{:else}
<p>{$LL.deviceManager.NO_DEVICE()}</p>
{/if}
<style lang="scss">
p {
margin: auto;
opacity: 0.4;
}
</style>