mirror of
https://github.com/KevinMidboe/hivemonitor.git
synced 2025-10-29 17:40:25 +00:00
Display tiles for showing a summarized view on first modal tab
This commit is contained in:
22
src/lib/components/displays/TemperatureDisplay.svelte
Normal file
22
src/lib/components/displays/TemperatureDisplay.svelte
Normal file
@@ -0,0 +1,22 @@
|
||||
<script lang="ts">
|
||||
import Display from "$lib/components/Display.svelte";
|
||||
import ThermometerIcon from "$lib/icons/thermometer.svelte";
|
||||
import { formatTemperature } from "$lib/telemetryFormatters";
|
||||
|
||||
export let temperature: string | undefined = undefined
|
||||
export let change: string | null = '';
|
||||
</script>
|
||||
|
||||
<Display>
|
||||
<ThermometerIcon slot="icon" />
|
||||
|
||||
<span slot="title">Temperature</span>
|
||||
<span slot="value">{ formatTemperature(temperature) }°C</span>
|
||||
|
||||
<span slot="change">{change}</span>
|
||||
</Display>
|
||||
|
||||
|
||||
<style lang="scss">
|
||||
|
||||
</style>
|
||||
Reference in New Issue
Block a user