mirror of
https://github.com/gpxstudio/gpx.studio.git
synced 2025-08-31 23:53:25 +00:00
add link to docs
This commit is contained in:
@@ -1,33 +1,33 @@
|
|||||||
<script lang="ts">
|
<script lang="ts">
|
||||||
import { Button } from '$lib/components/ui/button';
|
import { Button } from '$lib/components/ui/button';
|
||||||
import { selection } from '$lib/components/file-list/Selection';
|
import { selection } from '$lib/components/file-list/Selection';
|
||||||
import Help from '$lib/components/Help.svelte';
|
import Help from '$lib/components/Help.svelte';
|
||||||
import { MountainSnow } from 'lucide-svelte';
|
import { MountainSnow } from 'lucide-svelte';
|
||||||
import { dbUtils } from '$lib/db';
|
import { dbUtils } from '$lib/db';
|
||||||
import { map } from '$lib/stores';
|
import { map } from '$lib/stores';
|
||||||
import { _ } from 'svelte-i18n';
|
import { _ } from 'svelte-i18n';
|
||||||
|
|
||||||
$: validSelection = $selection.size > 0;
|
$: validSelection = $selection.size > 0;
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
<div class="flex flex-col gap-3 w-full max-w-80 {$$props.class ?? ''}">
|
<div class="flex flex-col gap-3 w-full max-w-80 {$$props.class ?? ''}">
|
||||||
<Button
|
<Button
|
||||||
variant="outline"
|
variant="outline"
|
||||||
disabled={!validSelection}
|
disabled={!validSelection}
|
||||||
on:click={async () => {
|
on:click={async () => {
|
||||||
if ($map) {
|
if ($map) {
|
||||||
dbUtils.addElevationToSelection($map);
|
dbUtils.addElevationToSelection($map);
|
||||||
}
|
}
|
||||||
}}
|
}}
|
||||||
>
|
>
|
||||||
<MountainSnow size="16" class="mr-1" />
|
<MountainSnow size="16" class="mr-1" />
|
||||||
{$_('toolbar.elevation.button')}
|
{$_('toolbar.elevation.button')}
|
||||||
</Button>
|
</Button>
|
||||||
<Help>
|
<Help link="./help/toolbar/elevation">
|
||||||
{#if validSelection}
|
{#if validSelection}
|
||||||
{$_('toolbar.elevation.help')}
|
{$_('toolbar.elevation.help')}
|
||||||
{:else}
|
{:else}
|
||||||
{$_('toolbar.elevation.help_no_selection')}
|
{$_('toolbar.elevation.help_no_selection')}
|
||||||
{/if}
|
{/if}
|
||||||
</Help>
|
</Help>
|
||||||
</div>
|
</div>
|
||||||
|
Reference in New Issue
Block a user