Add settings for new functionality

This commit is contained in:
Djuri Baars 2024-03-11 21:09:15 +01:00
parent 1b8ab93da6
commit dcdf98964a
6 changed files with 82 additions and 55 deletions

View file

@ -17,6 +17,8 @@
"useBigCharsMcap": "Use big characters for market cap", "useBigCharsMcap": "Use big characters for market cap",
"useBlkCountdown": "Blocks countdown for halving", "useBlkCountdown": "Blocks countdown for halving",
"useSatsSymbol": "Use sats symbol", "useSatsSymbol": "Use sats symbol",
"suffixPrice": "Suffix price format",
"disableLeds": "Disable all LEDs effects",
"otaUpdates": "OTA updates", "otaUpdates": "OTA updates",
"enableMdns": "mDNS", "enableMdns": "mDNS",
"fetchEuroPrice": "Fetch € price", "fetchEuroPrice": "Fetch € price",

View file

@ -22,6 +22,8 @@
"enableMdns": "mDNS", "enableMdns": "mDNS",
"hostnamePrefix": "Prefijo de nombre de host", "hostnamePrefix": "Prefijo de nombre de host",
"mempoolnstance": "Instancia de Mempool", "mempoolnstance": "Instancia de Mempool",
"suffixPrice": "Precio con sufijos",
"disableLeds": "Desactivar efectos de LED",
"otaUpdates": "Actualización por aire", "otaUpdates": "Actualización por aire",
"wifiTxPowerText": "En la mayoría de los casos no es necesario configurar esto.", "wifiTxPowerText": "En la mayoría de los casos no es necesario configurar esto.",
"settingsSaved": "Configuración guardada", "settingsSaved": "Configuración guardada",

View file

@ -22,6 +22,8 @@
"screens": "Schermen", "screens": "Schermen",
"hostnamePrefix": "Hostnaam voorvoegsel", "hostnamePrefix": "Hostnaam voorvoegsel",
"mempoolnstance": "Mempool instantie", "mempoolnstance": "Mempool instantie",
"suffixPrice": "Achtervoegsel prijs formaat",
"disableLeds": "Alle LEDs effecten uit",
"otaUpdates": "OTA updates", "otaUpdates": "OTA updates",
"wifiTxPower": "WiFi TX power", "wifiTxPower": "WiFi TX power",
"wifiTxPowerText": "Meestal hoeft dit niet aangepast te worden.", "wifiTxPowerText": "Meestal hoeft dit niet aangepast te worden.",

View file

@ -106,6 +106,7 @@
<Button color="primary" on:click={setCustomText}>{$_('section.control.showText')}</Button> <Button color="primary" on:click={setCustomText}>{$_('section.control.showText')}</Button>
</Form> </Form>
<hr /> <hr />
{#if !$settings.disableLeds}
<h3>LEDs</h3> <h3>LEDs</h3>
<Form> <Form>
<Row> <Row>
@ -143,8 +144,8 @@
> >
<Button color="primary" on:click={setLEDcolor}>{$_('section.control.setColor')}</Button> <Button color="primary" on:click={setLEDcolor}>{$_('section.control.setColor')}</Button>
</Form> </Form>
<hr /> <hr />
{/if}
<h3>{$_('section.control.systemInfo')}</h3> <h3>{$_('section.control.systemInfo')}</h3>
<ul class="small system_info"> <ul class="small system_info">
<li>{$_('section.control.version')}: {$settings.gitRev}</li> <li>{$_('section.control.version')}: {$settings.gitRev}</li>

View file

@ -323,6 +323,24 @@
label={$_('section.settings.useSatsSymbol')} label={$_('section.settings.useSatsSymbol')}
/> />
</Col> </Col>
<Col md="6">
<Input
id="suffixPrice"
bind:checked={$settings.suffixPrice}
type="switch"
bsSize="sm"
label={$_('section.settings.suffixPrice')}
/>
</Col>
<Col md="6">
<Input
id="disableLeds"
bind:checked={$settings.disableLeds}
type="switch"
bsSize="sm"
label={$_('section.settings.disableLeds')}
/>
</Col>
</Row> </Row>
<Row> <Row>

View file

@ -120,6 +120,7 @@
{/if} {/if}
{/if} {/if}
<hr /> <hr />
{#if !$settings.disableLeds}
<Row class="justify-content-evenly"> <Row class="justify-content-evenly">
{#if $status.leds} {#if $status.leds}
{#each $status.leds as led} {#each $status.leds as led}
@ -136,6 +137,7 @@
{/if} {/if}
</Row> </Row>
<hr /> <hr />
{/if}
<Progress striped value={memoryFreePercent}>{memoryFreePercent}%</Progress> <Progress striped value={memoryFreePercent}>{memoryFreePercent}%</Progress>
<div class="d-flex justify-content-between"> <div class="d-flex justify-content-between">
<div>{$_('section.status.memoryFree')}</div> <div>{$_('section.status.memoryFree')}</div>