frontend: DO IT THE SVELTE WAY
This commit is contained in:
@@ -99,14 +99,6 @@
|
|||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
|
||||||
* Sets the active tab
|
|
||||||
* @param {string} tab - The tab to set as active
|
|
||||||
*/
|
|
||||||
function setActiveTab(tab) {
|
|
||||||
activeTab = tab;
|
|
||||||
}
|
|
||||||
|
|
||||||
/** @type {import('../../routes/auth/about/[id]/$types').SubmitFunction} */
|
/** @type {import('../../routes/auth/about/[id]/$types').SubmitFunction} */
|
||||||
const handleUpdate = async () => {
|
const handleUpdate = async () => {
|
||||||
isUpdating = true;
|
isUpdating = true;
|
||||||
@@ -158,7 +150,7 @@
|
|||||||
type="button"
|
type="button"
|
||||||
class="button-dark"
|
class="button-dark"
|
||||||
class:active={activeTab === tab}
|
class:active={activeTab === tab}
|
||||||
on:click={() => setActiveTab(tab)}
|
on:click={() => (activeTab = tab)}
|
||||||
>
|
>
|
||||||
{$t(tab)}
|
{$t(tab)}
|
||||||
</button>
|
</button>
|
||||||
|
|||||||
Reference in New Issue
Block a user