feat: add download app card on web
This commit is contained in:
@ -129,6 +129,13 @@
|
||||
"skip": "Onboarding überspringen",
|
||||
"choose-lang": "Wählen Sie Ihre Sprache",
|
||||
"first-vehicle": "Erstellen wir Ihr erstes Fahrzeug."
|
||||
},
|
||||
"main": {
|
||||
"download-app": {
|
||||
"title": "App herunterladen!",
|
||||
"description": "TrafficCue ist auf Android verfügbar. Holen Sie es sich für das beste Erlebnis!",
|
||||
"button": "Runterladen"
|
||||
}
|
||||
}
|
||||
},
|
||||
"location-selector": {
|
||||
|
||||
@ -130,6 +130,13 @@
|
||||
"skip": "Skip Onboarding",
|
||||
"choose-lang": "Choose your language",
|
||||
"first-vehicle": "Let's create your first vehicle."
|
||||
},
|
||||
"main": {
|
||||
"download-app": {
|
||||
"title": "Download the app!",
|
||||
"description": "TrafficCue is available on Android. Get it for the best experience!",
|
||||
"button": "Get it"
|
||||
}
|
||||
}
|
||||
},
|
||||
"unsave": "Unsave",
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
<script lang="ts">
|
||||
import { BriefcaseIcon, HomeIcon, SchoolIcon } from "@lucide/svelte";
|
||||
import { BriefcaseIcon, DownloadIcon, HomeIcon, SchoolIcon } from "@lucide/svelte";
|
||||
import { Button } from "../../ui/button";
|
||||
import { fly } from "svelte/transition";
|
||||
import { circInOut } from "svelte/easing";
|
||||
@ -11,6 +11,7 @@
|
||||
import { m } from "$lang/messages";
|
||||
import { getSaved } from "$lib/services/lnv";
|
||||
import { view } from "../view.svelte";
|
||||
import * as Card from "$lib/components/ui/card";
|
||||
</script>
|
||||
|
||||
<div
|
||||
@ -98,6 +99,29 @@
|
||||
|
||||
<VehicleSelector />
|
||||
|
||||
{#if !window.__TAURI__}
|
||||
<Card.Root style="margin-top: 1rem;">
|
||||
<Card.Header>
|
||||
<Card.Title>{m["sidebar.main.download-app.title"]()}</Card.Title>
|
||||
</Card.Header>
|
||||
<Card.Content>
|
||||
{m["sidebar.main.download-app.description"]()}
|
||||
</Card.Content>
|
||||
<Card.Footer>
|
||||
<a
|
||||
href="/trafficcue.apk"
|
||||
target="_blank"
|
||||
rel="noopener noreferrer"
|
||||
>
|
||||
<Button>
|
||||
<DownloadIcon />
|
||||
{m["sidebar.main.download-app.button"]()}
|
||||
</Button>
|
||||
</a>
|
||||
</Card.Footer>
|
||||
</Card.Root>
|
||||
{/if}
|
||||
|
||||
<RequiresCapability capability="saved-routes">
|
||||
{#await getSaved() then saved}
|
||||
{#if saved.length != 0}
|
||||
|
||||
Reference in New Issue
Block a user