diff --git a/web/src/lib/assets/svg-paths.ts b/web/src/lib/assets/svg-paths.ts new file mode 100644 index 0000000000..cc8d0a1800 --- /dev/null +++ b/web/src/lib/assets/svg-paths.ts @@ -0,0 +1,6 @@ +export const moonPath = 'M17.293 13.293A8 8 0 016.707 2.707a8.001 8.001 0 1010.586 10.586z'; +export const sunPath = + 'M10 2a1 1 0 011 1v1a1 1 0 11-2 0V3a1 1 0 011-1zm4 8a4 4 0 11-8 0 4 4 0 018 0zm-.464 4.95l.707.707a1 1 0 001.414-1.414l-.707-.707a1 1 0 00-1.414 1.414zm2.12-10.607a1 1 0 010 1.414l-.706.707a1 1 0 11-1.414-1.414l.707-.707a1 1 0 011.414 0zM17 11a1 1 0 100-2h-1a1 1 0 100 2h1zm-7 4a1 1 0 011 1v1a1 1 0 11-2 0v-1a1 1 0 011-1zM5.05 6.464A1 1 0 106.465 5.05l-.708-.707a1 1 0 00-1.414 1.414l.707.707zm1.414 8.486l-.707.707a1 1 0 01-1.414-1.414l.707-.707a1 1 0 011.414 1.414zM4 11a1 1 0 100-2H3a1 1 0 000 2h1z'; + +export const moonViewBox = '0 0 20 20'; +export const sunViewBox = '0 0 20 20'; diff --git a/web/src/lib/components/admin-page/settings/storage-template/storage-template-settings.svelte b/web/src/lib/components/admin-page/settings/storage-template/storage-template-settings.svelte index d3c3e72af7..a0ac0dbf01 100644 --- a/web/src/lib/components/admin-page/settings/storage-template/storage-template-settings.svelte +++ b/web/src/lib/components/admin-page/settings/storage-template/storage-template-settings.svelte @@ -19,7 +19,7 @@ import Button from '$lib/components/elements/buttons/button.svelte'; import { createEventDispatcher } from 'svelte'; import Icon from '$lib/components/elements/icon.svelte'; - import { mdiCheck } from '@mdi/js'; + import { mdiArrowLeft, mdiCheck } from '@mdi/js'; export let storageConfig: SystemConfigStorageTemplateDto; export let disabled = false; @@ -30,7 +30,10 @@ let templateOptions: SystemConfigTemplateStorageOptionDto; let selectedPreset = ''; - const dispatch = createEventDispatcher<{ save: void }>(); + const dispatch = createEventDispatcher<{ + save: void; + previous: void; + }>(); const handleReset = (detail: ResetOptions) => { if (detail.default) { @@ -283,13 +286,21 @@ {/if} {#if minified} -