diff options
author | Matt Strapp <matt@mattstrapp.net> | 2024-04-05 16:56:02 -0500 |
---|---|---|
committer | Matt Strapp <matt@mattstrapp.net> | 2024-04-06 08:47:20 -0500 |
commit | 8a635a8e5bf8d23994d30d7d90b0318c27246a5d (patch) | |
tree | 254f145153b122190449f8701e4f6282eb9faf20 /clients/www/src/lib | |
parent | Do not actually override the UI yet (diff) | |
download | zorascript-8a635a8e5bf8d23994d30d7d90b0318c27246a5d.tar zorascript-8a635a8e5bf8d23994d30d7d90b0318c27246a5d.tar.gz zorascript-8a635a8e5bf8d23994d30d7d90b0318c27246a5d.tar.bz2 zorascript-8a635a8e5bf8d23994d30d7d90b0318c27246a5d.tar.lz zorascript-8a635a8e5bf8d23994d30d7d90b0318c27246a5d.tar.xz zorascript-8a635a8e5bf8d23994d30d7d90b0318c27246a5d.tar.zst zorascript-8a635a8e5bf8d23994d30d7d90b0318c27246a5d.zip |
Lint
Signed-off-by: Matt Strapp <matt@mattstrapp.net>
Diffstat (limited to '')
-rw-r--r-- | clients/www/src/lib/components/ReloadPrompt.svelte | 56 |
1 files changed, 28 insertions, 28 deletions
diff --git a/clients/www/src/lib/components/ReloadPrompt.svelte b/clients/www/src/lib/components/ReloadPrompt.svelte index e6effbb..6c778b6 100644 --- a/clients/www/src/lib/components/ReloadPrompt.svelte +++ b/clients/www/src/lib/components/ReloadPrompt.svelte @@ -1,32 +1,32 @@ <script lang="ts"> - import { getToastStore } from '@skeletonlabs/skeleton' - import { useRegisterSW } from 'virtual:pwa-register/svelte' + import { getToastStore } from '@skeletonlabs/skeleton'; + import { useRegisterSW } from 'virtual:pwa-register/svelte'; - const toastStore = getToastStore() + const toastStore = getToastStore(); - const { updateServiceWorker } = useRegisterSW({ - onRegisteredSW(r) { - console.log('SW Registered: ', r) - }, - onNeedRefresh() { - toastStore.trigger({ - message: 'A new version of the application is available.', - autohide: false, - action: { - label: 'Refresh', - response: updateServiceWorker, - }, - }) - }, - onOfflineReady() { - toastStore.trigger({ - background: 'variant-filled-success', - message: 'Now ready for offline use!', - timeout: 5000, - }) - }, - onRegisterError(err) { - console.error('SW Registration Error: ', err) - }, - }) + const { updateServiceWorker } = useRegisterSW({ + onRegisteredSW(r) { + console.log('SW Registered: ', r); + }, + onNeedRefresh() { + toastStore.trigger({ + message: 'A new version of the application is available.', + autohide: false, + action: { + label: 'Refresh', + response: updateServiceWorker + } + }); + }, + onOfflineReady() { + toastStore.trigger({ + background: 'variant-filled-success', + message: 'Now ready for offline use!', + timeout: 5000 + }); + }, + onRegisterError(err) { + console.error('SW Registration Error: ', err); + } + }); </script> |