Good saving point. Version reset looks good now.
This commit is contained in:
@@ -102,8 +102,10 @@ function clear_local() {
|
||||
$ae_loc.authenticated_access = false;
|
||||
$ae_loc.edit_mode = false;
|
||||
|
||||
$ae_loc.ver = '';
|
||||
|
||||
localStorage.clear();
|
||||
window.localStorage.clear();
|
||||
// window.localStorage.clear();
|
||||
}
|
||||
|
||||
function clear_sess() {
|
||||
@@ -134,11 +136,13 @@ function clear_sess() {
|
||||
|
||||
> -->
|
||||
{#if ($events_loc?.ver !== $events_sess?.ver)}
|
||||
<div class="fixed inset-0 bg-pink-100/80 z-40">
|
||||
<button
|
||||
class="
|
||||
fixed top-16 left-0 right-0 z-50 p-4 m-8 sm:mx-16 md:mx-32
|
||||
btn btn-lg
|
||||
preset-tonal-warning preset-outlined-warning-400-600 hover:preset-filled-success-200-800
|
||||
btn btn-lg rounded-2xl
|
||||
preset-tonal-warning hover:preset-filled-success-200-800
|
||||
border-4 border-warning-300 dark:border-warning-700
|
||||
transition-all
|
||||
"
|
||||
onclick={() => {
|
||||
@@ -149,9 +153,12 @@ function clear_sess() {
|
||||
clear_local();
|
||||
// clear_sess();
|
||||
|
||||
alert('The page will now reload. You may need to sign in again.');
|
||||
// Clear local storage and reload the page to get the latest version.
|
||||
// window.localStorage.clear();
|
||||
location.reload();
|
||||
}}
|
||||
title="A new version of the launcher is available. Click to reload the page and get the latest version."
|
||||
title="A new version of One Sky IT's Aether Events module is available. Click to reload the page and use the latest version."
|
||||
>
|
||||
<span class="fas fa-sync-alt fa-spin m-1"></span>
|
||||
<span class="m-4 sm:mx-8 text-wrap">
|
||||
@@ -160,8 +167,14 @@ function clear_sess() {
|
||||
<div class="italic text-base">You may need to sign in again.</div>
|
||||
</span>
|
||||
<span class="fas fa-sync-alt fa-spin m-1"></span>
|
||||
|
||||
<!-- <span class="text-xs">
|
||||
$events_loc.ver=${$events_loc?.ver}<br>
|
||||
$events_sess.ver=${$events_sess?.ver}
|
||||
</span> -->
|
||||
</button>
|
||||
$events_loc.ver=${$events_loc?.ver} $events_sess.ver=${$events_sess?.ver}
|
||||
|
||||
</div>
|
||||
{/if}
|
||||
<!-- </Modal> -->
|
||||
|
||||
|
||||
Reference in New Issue
Block a user