mirror of
https://github.com/gpxstudio/gpx.studio.git
synced 2026-01-01 15:54:44 +00:00
Compare commits
4 Commits
1ab3fe1c4a
...
9cff71fed3
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
9cff71fed3 | ||
|
|
e76040e416 | ||
|
|
1facf50621 | ||
|
|
57f3cc8bc0 |
@@ -1,6 +1,5 @@
|
|||||||
import {
|
import {
|
||||||
Landmark,
|
Landmark,
|
||||||
Icon,
|
|
||||||
Shell,
|
Shell,
|
||||||
Bike,
|
Bike,
|
||||||
Building,
|
Building,
|
||||||
@@ -29,6 +28,7 @@ import {
|
|||||||
TriangleAlert,
|
TriangleAlert,
|
||||||
Anchor,
|
Anchor,
|
||||||
Toilet,
|
Toilet,
|
||||||
|
X,
|
||||||
type IconProps,
|
type IconProps,
|
||||||
} from '@lucide/svelte';
|
} from '@lucide/svelte';
|
||||||
import {
|
import {
|
||||||
@@ -61,6 +61,7 @@ import {
|
|||||||
TriangleAlert as TriangleAlertSvg,
|
TriangleAlert as TriangleAlertSvg,
|
||||||
Anchor as AnchorSvg,
|
Anchor as AnchorSvg,
|
||||||
Toilet as ToiletSvg,
|
Toilet as ToiletSvg,
|
||||||
|
X as XSvg,
|
||||||
} from 'lucide-static';
|
} from 'lucide-static';
|
||||||
import type { Component } from 'svelte';
|
import type { Component } from 'svelte';
|
||||||
|
|
||||||
@@ -87,7 +88,11 @@ export const symbols: { [key: string]: Symbol } = {
|
|||||||
icon: ShoppingBasket,
|
icon: ShoppingBasket,
|
||||||
iconSvg: ShoppingBasketSvg,
|
iconSvg: ShoppingBasketSvg,
|
||||||
},
|
},
|
||||||
crossing: { value: 'Crossing' },
|
crossing: {
|
||||||
|
value: 'Crossing',
|
||||||
|
icon: X,
|
||||||
|
iconSvg: XSvg,
|
||||||
|
},
|
||||||
department_store: {
|
department_store: {
|
||||||
value: 'Department Store',
|
value: 'Department Store',
|
||||||
icon: ShoppingBasket,
|
icon: ShoppingBasket,
|
||||||
|
|||||||
@@ -160,7 +160,7 @@
|
|||||||
type="single"
|
type="single"
|
||||||
onValueChange={setOpacityFromSelection}
|
onValueChange={setOpacityFromSelection}
|
||||||
>
|
>
|
||||||
<Select.Trigger class="h-8 mr-1 w-full">
|
<Select.Trigger class="mr-1 w-full" size="sm">
|
||||||
{#if selectedOverlay}
|
{#if selectedOverlay}
|
||||||
{#if isSelected($selectedOverlayTree, selectedOverlay)}
|
{#if isSelected($selectedOverlayTree, selectedOverlay)}
|
||||||
{#if $isLayerFromExtension(selectedOverlay)}
|
{#if $isLayerFromExtension(selectedOverlay)}
|
||||||
|
|||||||
@@ -163,7 +163,7 @@
|
|||||||
{i18n._('toolbar.routing.activity')}
|
{i18n._('toolbar.routing.activity')}
|
||||||
</span>
|
</span>
|
||||||
<Select.Root type="single" bind:value={$routingProfile}>
|
<Select.Root type="single" bind:value={$routingProfile}>
|
||||||
<Select.Trigger class="h-8 grow">
|
<Select.Trigger class="grow" size="sm">
|
||||||
{i18n._(`toolbar.routing.activities.${$routingProfile}`)}
|
{i18n._(`toolbar.routing.activities.${$routingProfile}`)}
|
||||||
</Select.Trigger>
|
</Select.Trigger>
|
||||||
<Select.Content>
|
<Select.Content>
|
||||||
|
|||||||
@@ -107,7 +107,7 @@
|
|||||||
{i18n._('toolbar.scissors.split_as')}
|
{i18n._('toolbar.scissors.split_as')}
|
||||||
</span>
|
</span>
|
||||||
<Select.Root bind:value={$splitAs} type="single">
|
<Select.Root bind:value={$splitAs} type="single">
|
||||||
<Select.Trigger class="h-8 w-fit grow">
|
<Select.Trigger class="w-fit grow" size="sm">
|
||||||
{i18n._('gpx.' + $splitAs)}
|
{i18n._('gpx.' + $splitAs)}
|
||||||
</Select.Trigger>
|
</Select.Trigger>
|
||||||
<Select.Content>
|
<Select.Content>
|
||||||
|
|||||||
@@ -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}
|
||||||
>
|
>
|
||||||
{#if symbolKey}
|
<span class="flex flex-row gap-1.5 items-center">
|
||||||
{i18n._(`gpx.symbol.${symbolKey}`)}
|
{#if symbolKey}
|
||||||
{:else}
|
{#if symbols[symbolKey].icon}
|
||||||
{sym}
|
{@const Component = symbols[symbolKey].icon}
|
||||||
{/if}
|
<Component size="14" />
|
||||||
|
{/if}
|
||||||
|
{i18n._(`gpx.symbol.${symbolKey}`)}
|
||||||
|
{:else}
|
||||||
|
{sym}
|
||||||
|
{/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]}
|
||||||
@@ -194,7 +202,7 @@
|
|||||||
<span>
|
<span>
|
||||||
{#if symbol.icon}
|
{#if symbol.icon}
|
||||||
{@const Component = symbol.icon}
|
{@const Component = symbol.icon}
|
||||||
<Component size="14" class="inline-block align-sub mr-0.5" />
|
<Component size="14" class="inline-block align-sub" />
|
||||||
{:else}
|
{:else}
|
||||||
<span class="w-4 inline-block"></span>
|
<span class="w-4 inline-block"></span>
|
||||||
{/if}
|
{/if}
|
||||||
|
|||||||
Reference in New Issue
Block a user