moved stylised button to outlined-button.svelte; added drawing gallery (currently hidden)
This commit is contained in:
38
src/lib/components/outlined-button.svelte
Normal file
38
src/lib/components/outlined-button.svelte
Normal file
@@ -0,0 +1,38 @@
|
||||
<script lang="ts">
|
||||
let {
|
||||
text,
|
||||
onClick,
|
||||
fullWidth,
|
||||
}: {
|
||||
text: string;
|
||||
onClick: () => undefined;
|
||||
fullWidth?: boolean;
|
||||
} = $props();
|
||||
</script>
|
||||
|
||||
{#if fullWidth}
|
||||
<button class="outlined-button outlined-button-fullwidth" onclick={onClick}>{text}</button>
|
||||
{:else}
|
||||
<button class="outlined-button" onclick={onClick}>{text}</button>
|
||||
{/if}
|
||||
|
||||
<style>
|
||||
.outlined-button {
|
||||
font-family: var(--font-mono);
|
||||
font-size: var(--font-size-mono);
|
||||
padding: 8px;
|
||||
border: dashed 2px var(--color-highlight);
|
||||
color: var(--color-highlight);
|
||||
font-weight: 700;
|
||||
cursor: pointer;
|
||||
transition: background-color 0.05s ease-out;
|
||||
}
|
||||
|
||||
.outlined-button:hover {
|
||||
background-color: var(--color-background-highlight);
|
||||
}
|
||||
|
||||
.outlined-button-fullwidth {
|
||||
width: 100%;
|
||||
}
|
||||
</style>
|
||||
Reference in New Issue
Block a user