изменения

This commit is contained in:
Dmitry Borisenko
2022-02-11 00:22:41 +01:00
parent 050a813471
commit 34d26bbe1d
11 changed files with 216 additions and 137 deletions

View File

@@ -5,11 +5,11 @@
</script>
<div class="crd-itm-psn">
<div class="wgt-dscr-w">
<div class="w-2/3">
<!-- svelte-ignore a11y-label-has-associated-control -->
<label class="wgt-dscr-stl">{!widget.descr ? "" : widget.descr}</label>
</div>
<div class="wgt-w">
<div class="flex justify-end w-1/3">
<!-- svelte-ignore a11y-label-has-associated-control -->
<label class="wgt-adt-stl">{!widget.status ? "" : widget.status}</label>
<!-- svelte-ignore a11y-label-has-associated-control -->

View File

@@ -6,11 +6,11 @@
</script>
<div class="crd-itm-psn">
<div class="wgt-dscr-w">
<div class="w-2/3">
<!-- svelte-ignore a11y-label-has-associated-control -->
<label class="wgt-dscr-stl">{!widget.descr ? "" : widget.descr}</label>
</div>
<div class="wgt-w">
<div class="flex justify-end w-1/3">
{#if widget.type == "number"}
<input class={widget["send"] == true ? "ipt-rnd text-right border-red-500" : "ipt-rnd text-right focus:border-indigo-500"} on:change={() => ((widget["send"] = true), wsPush(widget.ws, widget.topic, widget.status))} bind:value={widget.status} step="0.1" type="number" />
{/if}

View File

@@ -6,11 +6,11 @@
</script>
<div class="crd-itm-psn">
<div class="wgt-dscr-w">
<div class="w-2/3">
<!-- svelte-ignore a11y-label-has-associated-control -->
<label class="wgt-dscr-stl">{!widget.descr ? "" : widget.descr}</label>
</div>
<div class="wgt-w">
<div class="flex justify-end w-1/3">
<label for={widget.topic} class="items-center cursor-pointer">
<div class="relative">
<input on:change={() => ((widget["send"] = true), wsPush(widget.ws, widget.topic, widget.status))} bind:value={widget.status} id={widget.topic} type="checkbox" class="sr-only" />