2020-09-15 22:53:02 +12:00
|
|
|
<script>
|
2020-11-19 10:06:12 +13:00
|
|
|
import { getContext } from "svelte"
|
|
|
|
|
2021-01-20 01:42:49 +13:00
|
|
|
const { styleable } = getContext("sdk")
|
|
|
|
const component = getContext("component")
|
2020-09-15 22:53:02 +12:00
|
|
|
|
|
|
|
export let icon = ""
|
|
|
|
export let size = "fa-lg"
|
2021-01-20 02:00:15 +13:00
|
|
|
export let color = "#f00"
|
2021-01-23 00:07:27 +13:00
|
|
|
|
2021-01-20 02:00:15 +13:00
|
|
|
$: styles = {
|
2021-01-23 00:07:27 +13:00
|
|
|
...$component.styles,
|
|
|
|
normal: {
|
|
|
|
...$component.styles.normal,
|
|
|
|
color,
|
|
|
|
},
|
2021-01-20 02:00:15 +13:00
|
|
|
}
|
2020-09-15 22:53:02 +12:00
|
|
|
</script>
|
|
|
|
|
2021-01-23 00:07:27 +13:00
|
|
|
<i use:styleable={styles} class="{icon} {size}" />
|