anki/ts/editor-toolbar/IconButton.svelte

16 lines
409 B
Svelte
Raw Normal View History

2021-03-29 14:54:10 +02:00
<script lang="typescript">
import SquareButton from "./SquareButton.svelte";
2021-03-29 14:54:10 +02:00
export let id = "";
2021-03-29 21:05:30 +02:00
export let className = "";
export let props: Record<string, string> = {};
export let title: string;
2021-03-29 21:05:30 +02:00
export let icon = "";
export let onClick: (event: ClickEvent) => void;
2021-03-29 14:54:10 +02:00
</script>
<SquareButton {id} {className} {props} {title} {onClick} on:mount>
2021-03-30 00:51:44 +02:00
{@html icon}
</SquareButton>