Compare commits
No commits in common. "dd4b3b5373bee71b2afe764a10934697c9fa414d" and "53002630c1087d5265e89a4cb21c277d8e65fe30" have entirely different histories.
dd4b3b5373
...
53002630c1
11 changed files with 21 additions and 22 deletions
|
@ -20,7 +20,6 @@
|
||||||
"eslint": "^8.45.0",
|
"eslint": "^8.45.0",
|
||||||
"eslint-config-prettier": "^8.5.0",
|
"eslint-config-prettier": "^8.5.0",
|
||||||
"eslint-plugin-svelte": "^2.30.0",
|
"eslint-plugin-svelte": "^2.30.0",
|
||||||
"kolorist": "^1.8.0",
|
|
||||||
"prettier": "^3.0.0",
|
"prettier": "^3.0.0",
|
||||||
"prettier-plugin-svelte": "^3.0.0",
|
"prettier-plugin-svelte": "^3.0.0",
|
||||||
"svelte": "^4.0.0",
|
"svelte": "^4.0.0",
|
||||||
|
|
Binary file not shown.
Before Width: | Height: | Size: 136 KiB |
|
@ -12,7 +12,7 @@
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
{#if visible}
|
{#if visible}
|
||||||
<img transition:fade src="/splash.webp" alt="splash" />
|
<img transition:fade src="/splash.jpeg" alt="splash" />
|
||||||
{/if}
|
{/if}
|
||||||
|
|
||||||
<style>
|
<style>
|
||||||
|
|
|
@ -10,13 +10,10 @@
|
||||||
let latitude;
|
let latitude;
|
||||||
let longitude;
|
let longitude;
|
||||||
let accuracy;
|
let accuracy;
|
||||||
const errorMessage = "Geolocation not available";
|
|
||||||
let errored = false;
|
|
||||||
|
|
||||||
const watchPosition = async () => {
|
const loadWorker = async () => {
|
||||||
if (!("geolocation" in navigator)) {
|
if (!("geolocation" in navigator)) {
|
||||||
errored = true;
|
return;
|
||||||
throw new Error(errorMessage)
|
|
||||||
}
|
}
|
||||||
|
|
||||||
const options = {
|
const options = {
|
||||||
|
@ -48,7 +45,7 @@
|
||||||
};
|
};
|
||||||
|
|
||||||
onMount(async () => {
|
onMount(async () => {
|
||||||
await watchPosition();
|
await loadWorker();
|
||||||
leaflet = await import('leaflet');
|
leaflet = await import('leaflet');
|
||||||
layerGroup = leaflet.layerGroup();
|
layerGroup = leaflet.layerGroup();
|
||||||
|
|
||||||
|
@ -78,11 +75,8 @@
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
</script>
|
</script>
|
||||||
{#if !errored}
|
|
||||||
<div id="map" in:fade bind:this={mapElement} />
|
<div id="map" in:fade bind:this={mapElement} />
|
||||||
{:else}
|
|
||||||
{errorMessage}
|
|
||||||
{/if}
|
|
||||||
|
|
||||||
<style>
|
<style>
|
||||||
@import 'leaflet/dist/leaflet.css';
|
@import 'leaflet/dist/leaflet.css';
|
||||||
|
|
|
@ -24,7 +24,7 @@
|
||||||
|
|
||||||
|
|
||||||
<Header></Header>
|
<Header></Header>
|
||||||
<img src='/splash.webp' alt='splash'>
|
<img src='/splash.jpeg' alt='splash'>
|
||||||
|
|
||||||
<div bind:this={divider} id='divider'>
|
<div bind:this={divider} id='divider'>
|
||||||
<div id='banner'>
|
<div id='banner'>
|
||||||
|
|
BIN
frontend/static/images/splash-background.png
Normal file
BIN
frontend/static/images/splash-background.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 11 MiB |
Binary file not shown.
Before Width: | Height: | Size: 136 KiB |
|
@ -7,6 +7,12 @@ const config = {
|
||||||
// for more information about preprocessors
|
// for more information about preprocessors
|
||||||
preprocess: vitePreprocess(),
|
preprocess: vitePreprocess(),
|
||||||
kit: {
|
kit: {
|
||||||
|
files: {
|
||||||
|
serviceWorker: 'src/sw.ts',
|
||||||
|
},
|
||||||
|
serviceWorker: {
|
||||||
|
register: false
|
||||||
|
},
|
||||||
adapter: adapter({
|
adapter: adapter({
|
||||||
precompress: false,
|
precompress: false,
|
||||||
}),
|
}),
|
||||||
|
|
|
@ -5,7 +5,12 @@ import { SvelteKitPWA } from '@vite-pwa/sveltekit'
|
||||||
const config = {
|
const config = {
|
||||||
plugins: [
|
plugins: [
|
||||||
sveltekit(),
|
sveltekit(),
|
||||||
SvelteKitPWA()
|
SvelteKitPWA({
|
||||||
|
registerType: 'autoUpdate',
|
||||||
|
strategies: 'injectManifest',
|
||||||
|
srcDir: 'src',
|
||||||
|
filename: 'sw.ts',
|
||||||
|
})
|
||||||
],
|
],
|
||||||
test: {
|
test: {
|
||||||
include: ["src/**/*.{test,spec}.{js,ts}"],
|
include: ["src/**/*.{test,spec}.{js,ts}"],
|
||||||
|
|
|
@ -2741,11 +2741,6 @@ known-css-properties@^0.27.0:
|
||||||
resolved "https://registry.yarnpkg.com/known-css-properties/-/known-css-properties-0.27.0.tgz#82a9358dda5fe7f7bd12b5e7142c0a205393c0c5"
|
resolved "https://registry.yarnpkg.com/known-css-properties/-/known-css-properties-0.27.0.tgz#82a9358dda5fe7f7bd12b5e7142c0a205393c0c5"
|
||||||
integrity sha512-uMCj6+hZYDoffuvAJjFAPz56E9uoowFHmTkqRtRq5WyC5Q6Cu/fTZKNQpX/RbzChBYLLl3lo8CjFZBAZXq9qFg==
|
integrity sha512-uMCj6+hZYDoffuvAJjFAPz56E9uoowFHmTkqRtRq5WyC5Q6Cu/fTZKNQpX/RbzChBYLLl3lo8CjFZBAZXq9qFg==
|
||||||
|
|
||||||
kolorist@^1.8.0:
|
|
||||||
version "1.8.0"
|
|
||||||
resolved "https://registry.yarnpkg.com/kolorist/-/kolorist-1.8.0.tgz#edddbbbc7894bc13302cdf740af6374d4a04743c"
|
|
||||||
integrity sha512-Y+60/zizpJ3HRH8DCss+q95yr6145JXZo46OTpFvDZWLfRCE4qChOyk1b26nMaNpfHHgxagk9dXT5OP0Tfe+dQ==
|
|
||||||
|
|
||||||
leaflet@^1.9.4:
|
leaflet@^1.9.4:
|
||||||
version "1.9.4"
|
version "1.9.4"
|
||||||
resolved "https://registry.yarnpkg.com/leaflet/-/leaflet-1.9.4.tgz#23fae724e282fa25745aff82ca4d394748db7d8d"
|
resolved "https://registry.yarnpkg.com/leaflet/-/leaflet-1.9.4.tgz#23fae724e282fa25745aff82ca4d394748db7d8d"
|
||||||
|
|
Loading…
Reference in a new issue