Compare commits
2 Commits
cb4a2140f7
...
f66f6783d2
| Author | SHA1 | Date | |
|---|---|---|---|
| f66f6783d2 | |||
| 415c9e3ae1 |
@ -21,6 +21,9 @@
|
|||||||
/** Make the button act as a link. */
|
/** Make the button act as a link. */
|
||||||
href?: string;
|
href?: string;
|
||||||
|
|
||||||
|
/** Open the link inside a new tab. */
|
||||||
|
newtab?: boolean;
|
||||||
|
|
||||||
/** Add a width class to the button. */
|
/** Add a width class to the button. */
|
||||||
width?: string;
|
width?: string;
|
||||||
|
|
||||||
@ -54,6 +57,7 @@
|
|||||||
color = undefined,
|
color = undefined,
|
||||||
submit = false,
|
submit = false,
|
||||||
href = undefined,
|
href = undefined,
|
||||||
|
newtab = false,
|
||||||
width = "w-auto",
|
width = "w-auto",
|
||||||
activate = false,
|
activate = false,
|
||||||
activate_href = false,
|
activate_href = false,
|
||||||
@ -70,6 +74,8 @@
|
|||||||
{#if href}
|
{#if href}
|
||||||
<a
|
<a
|
||||||
{href}
|
{href}
|
||||||
|
target={newtab ? "_blank" : undefined}
|
||||||
|
rel={newtab ? "noopener noreferrer" : undefined}
|
||||||
class="btn m-0 select-none px-2 py-2 {color ? `variant-filled-${color}` : ''} {width} {activate
|
class="btn m-0 select-none px-2 py-2 {color ? `variant-filled-${color}` : ''} {width} {activate
|
||||||
? 'btn-hover'
|
? 'btn-hover'
|
||||||
: ''} {activate_href && is_at_path(href) ? 'btn-hover' : ''} {shadow
|
: ''} {activate_href && is_at_path(href) ? 'btn-hover' : ''} {shadow
|
||||||
|
|||||||
@ -380,6 +380,16 @@
|
|||||||
<Button href="/rules" onclick={close_drawer} color="surface" width="w-full" shadow>
|
<Button href="/rules" onclick={close_drawer} color="surface" width="w-full" shadow>
|
||||||
Rules
|
Rules
|
||||||
</Button>
|
</Button>
|
||||||
|
<Button
|
||||||
|
href="https://gitea.vps.chriphost.de/christoph/svelte-formula11/projects/1"
|
||||||
|
onclick={close_drawer}
|
||||||
|
color="surface"
|
||||||
|
width="w-full"
|
||||||
|
shadow
|
||||||
|
newtab
|
||||||
|
>
|
||||||
|
Roadmap
|
||||||
|
</Button>
|
||||||
</div>
|
</div>
|
||||||
{:else if $drawerStore.id === "data_drawer"}
|
{:else if $drawerStore.id === "data_drawer"}
|
||||||
<!-- Data Drawer -->
|
<!-- Data Drawer -->
|
||||||
@ -585,6 +595,14 @@
|
|||||||
<Button href="/leaderboard" color="primary" activate_href>Leaderboard</Button>
|
<Button href="/leaderboard" color="primary" activate_href>Leaderboard</Button>
|
||||||
<Button href="/statistics" color="primary" activate_href>Statistics</Button>
|
<Button href="/statistics" color="primary" activate_href>Statistics</Button>
|
||||||
<Button href="/rules" color="primary" activate_href>Rules</Button>
|
<Button href="/rules" color="primary" activate_href>Rules</Button>
|
||||||
|
<Button
|
||||||
|
href="https://gitea.vps.chriphost.de/christoph/svelte-formula11/projects/1"
|
||||||
|
color="primary"
|
||||||
|
activate_href
|
||||||
|
newtab
|
||||||
|
>
|
||||||
|
Roadmap
|
||||||
|
</Button>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<svelte:fragment slot="trail">
|
<svelte:fragment slot="trail">
|
||||||
|
|||||||
Reference in New Issue
Block a user