2023-10-11 04:16:52 +02:00
|
|
|
<script lang="ts">
|
2023-12-19 22:08:00 +01:00
|
|
|
import { IconConfig } from "../../Models/ThemeConfig/PointRenderingConfig"
|
|
|
|
import { Store } from "../../Logic/UIEventSource"
|
|
|
|
import Icon from "./Icon.svelte"
|
2023-10-11 04:16:52 +02:00
|
|
|
|
|
|
|
/**
|
|
|
|
* Renders a single icon.
|
|
|
|
*
|
|
|
|
* Icons -placed on top of each other- form a 'Marker' together
|
|
|
|
*/
|
2023-11-09 16:30:26 +01:00
|
|
|
export let icon: IconConfig
|
|
|
|
export let tags: Store<Record<string, string>>
|
2023-10-11 04:16:52 +02:00
|
|
|
|
2023-11-11 11:33:29 +01:00
|
|
|
let iconItem = icon.icon?.GetRenderValue($tags)?.Subs($tags)?.txt
|
|
|
|
$: iconItem = icon.icon?.GetRenderValue($tags)?.Subs($tags)?.txt
|
2023-11-09 16:30:26 +01:00
|
|
|
let color = icon.color?.GetRenderValue(tags)?.txt ?? "#000000"
|
|
|
|
$: color = icon.color?.GetRenderValue($tags)?.txt ?? "#000000"
|
2023-10-11 04:16:52 +02:00
|
|
|
</script>
|
|
|
|
|
2023-11-09 16:30:26 +01:00
|
|
|
<Icon icon={iconItem} {color} />
|