mirror of
https://github.com/gpxstudio/gpx.studio.git
synced 2025-12-27 13:39:59 +00:00
show selected icon in waypoint tool
This commit is contained in:
@@ -174,19 +174,27 @@
|
|||||||
bind:value={description}
|
bind:value={description}
|
||||||
id="description"
|
id="description"
|
||||||
disabled={!canCreate && !$selectedWaypoint}
|
disabled={!canCreate && !$selectedWaypoint}
|
||||||
|
class="min-h-8 h-8 py-1 px-3 text-sm"
|
||||||
/>
|
/>
|
||||||
<Label for="symbol">{i18n._('toolbar.waypoint.icon')}</Label>
|
<Label for="symbol">{i18n._('toolbar.waypoint.icon')}</Label>
|
||||||
<Select.Root bind:value={sym} type="single">
|
<Select.Root bind:value={sym} type="single">
|
||||||
<Select.Trigger
|
<Select.Trigger
|
||||||
id="symbol"
|
id="symbol"
|
||||||
class="w-full h-8"
|
size="sm"
|
||||||
|
class="w-full"
|
||||||
disabled={!canCreate && !$selectedWaypoint}
|
disabled={!canCreate && !$selectedWaypoint}
|
||||||
>
|
>
|
||||||
|
<span class="flex flex-row gap-1.5 items-center">
|
||||||
{#if symbolKey}
|
{#if symbolKey}
|
||||||
|
{#if symbols[symbolKey].icon}
|
||||||
|
{@const Component = symbols[symbolKey].icon}
|
||||||
|
<Component size="14" />
|
||||||
|
{/if}
|
||||||
{i18n._(`gpx.symbol.${symbolKey}`)}
|
{i18n._(`gpx.symbol.${symbolKey}`)}
|
||||||
{:else}
|
{:else}
|
||||||
{sym}
|
{sym}
|
||||||
{/if}
|
{/if}
|
||||||
|
</span>
|
||||||
</Select.Trigger>
|
</Select.Trigger>
|
||||||
<Select.Content class="max-h-60 overflow-y-scroll">
|
<Select.Content class="max-h-60 overflow-y-scroll">
|
||||||
{#each sortedSymbols as [key, symbol]}
|
{#each sortedSymbols as [key, symbol]}
|
||||||
|
|||||||
Reference in New Issue
Block a user