From: Jérôme Benoit Date: Thu, 7 Mar 2024 22:17:32 +0000 (+0100) Subject: refactor(ui): always display the buttons bar X-Git-Tag: v1.3.0~23 X-Git-Url: https://git.piment-noir.org/?a=commitdiff_plain;h=558db46fe98fb6bdb10531c30b63658521fe0d5f;p=e-mobility-charging-stations-simulator.git refactor(ui): always display the buttons bar Signed-off-by: Jérôme Benoit --- diff --git a/ui/web/src/composables/Utils.ts b/ui/web/src/composables/Utils.ts index 8db8851a..792e4481 100644 --- a/ui/web/src/composables/Utils.ts +++ b/ui/web/src/composables/Utils.ts @@ -35,15 +35,15 @@ export const convertToInt = (value: unknown): number => { return changedValue } -export const setToLocalStorage = (key: string, value: T): void => { - localStorage.setItem(key, JSON.stringify(value)) -} - export const getFromLocalStorage = (key: string, defaultValue: T): T => { const item = localStorage.getItem(key) return item != null ? (JSON.parse(item) as T) : defaultValue } +export const setToLocalStorage = (key: string, value: T): void => { + localStorage.setItem(key, JSON.stringify(value)) +} + export const deleteFromLocalStorage = (key: string): void => { localStorage.removeItem(key) } diff --git a/ui/web/src/views/ChargingStationsView.vue b/ui/web/src/views/ChargingStationsView.vue index 7b4f8a53..0b57bb9d 100644 --- a/ui/web/src/views/ChargingStationsView.vue +++ b/ui/web/src/views/ChargingStationsView.vue @@ -353,6 +353,8 @@ const stopSimulator = (): void => { #buttons-container { display: flex; flex-direction: row; + position: sticky; + top: 0; } .simulator-start-button {