Skip to content

Commit

Permalink
chore: Merge branch dev to main (#245)
Browse files Browse the repository at this point in the history
Co-authored-by: Ushie <[email protected]>
  • Loading branch information
oSumAtrIX and Ushie authored Jul 10, 2024
2 parents c4c3ba7 + 38c565c commit 1d36bd9
Showing 1 changed file with 7 additions and 3 deletions.
10 changes: 7 additions & 3 deletions src/layout/Navbar/NavHost.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -16,19 +16,23 @@
const client = useQueryClient();
function reload() {
location.reload();
}
function clear_and_reload() {
client.clear();
// `client.clear()` does technically do this for us, but it takes a while.
localStorage.clear();
location.reload();
reload();
}
let url = settings.api_base_url();
function save() {
settings.set_api_base_url(url);
clear_and_reload();
reload();
}
function reset() {
Expand Down Expand Up @@ -130,7 +134,7 @@
</div>

<svelte:fragment slot="buttons">
<Button type="text" on:click={clear_and_reload} label="Clear Cache Button">Clear cache</Button>
<Button type="text" on:click={clear_and_reload} label="Reset Button">Reset</Button>
<Button type="text" on:click={save} label="Save Button">Save</Button>
</svelte:fragment>
</Modal>
Expand Down

0 comments on commit 1d36bd9

Please sign in to comment.