- {#if $currentTool === Tool.WAYPOINT}
+ {#if tool.current === Tool.WAYPOINT}
{/if}
@@ -96,6 +96,8 @@
diff --git a/website/src/lib/components/ui/toggle-group/toggle-group-item.svelte b/website/src/lib/components/ui/toggle-group/toggle-group-item.svelte
index 8143635f..a22a114c 100644
--- a/website/src/lib/components/ui/toggle-group/toggle-group-item.svelte
+++ b/website/src/lib/components/ui/toggle-group/toggle-group-item.svelte
@@ -18,11 +18,15 @@
diff --git a/website/src/lib/components/ui/toggle/toggle.svelte b/website/src/lib/components/ui/toggle/toggle.svelte
index b66fa93f..d3b35f02 100644
--- a/website/src/lib/components/ui/toggle/toggle.svelte
+++ b/website/src/lib/components/ui/toggle/toggle.svelte
@@ -2,17 +2,17 @@
import { type VariantProps, tv } from "tailwind-variants";
export const toggleVariants = tv({
- base: "ring-offset-background hover:bg-muted hover:text-muted-foreground focus-visible:ring-ring data-[state=on]:bg-accent data-[state=on]:text-accent-foreground inline-flex items-center justify-center gap-2 rounded-md text-sm font-medium transition-colors focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-offset-2 disabled:pointer-events-none disabled:opacity-50 [&_svg]:pointer-events-none [&_svg]:size-4 [&_svg]:shrink-0",
+ base: "hover:bg-muted hover:text-muted-foreground data-[state=on]:bg-accent data-[state=on]:text-accent-foreground focus-visible:border-ring focus-visible:ring-ring/50 aria-invalid:ring-destructive/20 dark:aria-invalid:ring-destructive/40 aria-invalid:border-destructive inline-flex items-center justify-center gap-2 whitespace-nowrap rounded-md text-sm font-medium outline-none transition-[color,box-shadow] focus-visible:ring-[3px] disabled:pointer-events-none disabled:opacity-50 [&_svg:not([class*='size-'])]:size-4 [&_svg]:pointer-events-none [&_svg]:shrink-0",
variants: {
variant: {
default: "bg-transparent",
outline:
- "border-input hover:bg-accent hover:text-accent-foreground border bg-transparent",
+ "border-input shadow-xs hover:bg-accent hover:text-accent-foreground border bg-transparent",
},
size: {
- default: "h-10 min-w-10 px-3",
- sm: "h-9 min-w-9 px-2.5",
- lg: "h-11 min-w-11 px-5",
+ default: "h-9 min-w-9 px-2",
+ sm: "h-8 min-w-8 px-1.5",
+ lg: "h-10 min-w-10 px-2.5",
},
},
defaultVariants: {
@@ -46,6 +46,7 @@
diff --git a/website/src/lib/components/ui/tooltip/index.ts b/website/src/lib/components/ui/tooltip/index.ts
index e9e1fd73..313a7f06 100644
--- a/website/src/lib/components/ui/tooltip/index.ts
+++ b/website/src/lib/components/ui/tooltip/index.ts
@@ -1,18 +1,21 @@
import { Tooltip as TooltipPrimitive } from "bits-ui";
+import Trigger from "./tooltip-trigger.svelte";
import Content from "./tooltip-content.svelte";
const Root = TooltipPrimitive.Root;
-const Trigger = TooltipPrimitive.Trigger;
const Provider = TooltipPrimitive.Provider;
+const Portal = TooltipPrimitive.Portal;
export {
Root,
Trigger,
Content,
Provider,
+ Portal,
//
Root as Tooltip,
Content as TooltipContent,
Trigger as TooltipTrigger,
Provider as TooltipProvider,
+ Portal as TooltipPortal,
};
diff --git a/website/src/lib/components/ui/tooltip/tooltip-content.svelte b/website/src/lib/components/ui/tooltip/tooltip-content.svelte
index 68ff232b..b0c399ca 100644
--- a/website/src/lib/components/ui/tooltip/tooltip-content.svelte
+++ b/website/src/lib/components/ui/tooltip/tooltip-content.svelte
@@ -5,17 +5,43 @@
let {
ref = $bindable(null),
class: className,
- sideOffset = 4,
+ sideOffset = 0,
+ side = "top",
+ children,
+ arrowClasses,
...restProps
- }: TooltipPrimitive.ContentProps = $props();
+ }: TooltipPrimitive.ContentProps & {
+ arrowClasses?: string;
+ } = $props();
-
+
+
+ {@render children?.()}
+
+ {#snippet child({ props })}
+
+ {/snippet}
+
+
+
diff --git a/website/src/lib/components/ui/tooltip/tooltip-trigger.svelte b/website/src/lib/components/ui/tooltip/tooltip-trigger.svelte
new file mode 100644
index 00000000..1acdaa47
--- /dev/null
+++ b/website/src/lib/components/ui/tooltip/tooltip-trigger.svelte
@@ -0,0 +1,7 @@
+
+
+
diff --git a/website/src/lib/db.ts b/website/src/lib/db.ts
index f96dc0e5..ab68224c 100644
--- a/website/src/lib/db.ts
+++ b/website/src/lib/db.ts
@@ -1,67 +1,54 @@
-import Dexie, { liveQuery } from 'dexie';
-import {
- GPXFile,
- GPXStatistics,
- Track,
- TrackSegment,
- Waypoint,
- TrackPoint,
- type Coordinates,
- distance,
- type LineStyleExtension,
- type WaypointType,
-} from 'gpx';
-import {
- enableMapSet,
- enablePatches,
- applyPatches,
- type Patch,
- type WritableDraft,
- freeze,
- produceWithPatches,
-} from 'immer';
-import { writable, get, derived, type Readable, type Writable } from 'svelte/store';
-import {
- gpxStatistics,
- initTargetMapBounds,
- map,
- splitAs,
- updateAllHidden,
- updateTargetMapBounds,
-} from './stores';
-import {
- defaultBasemap,
- defaultBasemapTree,
- defaultOverlayTree,
- defaultOverlays,
- type CustomLayer,
- defaultOpacities,
- defaultOverpassQueries,
- defaultOverpassTree,
-} from './assets/layers';
-import {
- applyToOrderedItemsFromFile,
- applyToOrderedSelectedItemsFromFile,
- selection,
-} from '$lib/components/file-list/Selection';
-import {
- ListFileItem,
- ListItem,
- ListTrackItem,
- ListLevel,
- ListTrackSegmentItem,
- ListWaypointItem,
- ListRootItem,
-} from '$lib/components/file-list/FileList';
-import { updateAnchorPoints } from '$lib/components/toolbar/tools/routing/Simplify';
-import { SplitType } from '$lib/components/toolbar/tools/scissors/Scissors.svelte';
-import { getClosestLinePoint, getElevation } from '$lib/utils';
-import { browser } from '$app/environment';
+// import Dexie, { liveQuery } from 'dexie';
+// import {
+// GPXFile,
+// GPXStatistics,
+// Track,
+// TrackSegment,
+// Waypoint,
+// TrackPoint,
+// type Coordinates,
+// distance,
+// type LineStyleExtension,
+// type WaypointType,
+// } from 'gpx';
+// import {
+// enableMapSet,
+// enablePatches,
+// applyPatches,
+// type Patch,
+// type WritableDraft,
+// freeze,
+// produceWithPatches,
+// } from 'immer';
+// import { writable, get, derived, type Readable, type Writable } from 'svelte/store';
+// import { gpxStatistics, updateAllHidden } from './stores';
+// import { initTargetMapBounds, updateTargetMapBounds } from '$lib/components/map/utils.svelte';
+// import {
+// applyToOrderedItemsFromFile,
+// applyToOrderedSelectedItemsFromFile,
+// selection,
+// } from '$lib/components/file-list/Selection';
+// import {
+// ListFileItem,
+// ListItem,
+// ListTrackItem,
+// ListLevel,
+// ListTrackSegmentItem,
+// ListWaypointItem,
+// ListRootItem,
+// } from '$lib/components/file-list/FileList';
+// import { updateAnchorPoints } from '$lib/components/toolbar/tools/routing/Simplify';
+// import { SplitType } from '$lib/components/toolbar/tools/scissors/utils.svelte';
+// import { getClosestLinePoint, getElevation } from '$lib/utils';
+
+import Dexie from 'dexie';
+import type { GPXFile } from 'gpx';
+import { enableMapSet, enablePatches, type Patch } from 'immer';
enableMapSet();
enablePatches();
-class Database extends Dexie {
+export class Database extends Dexie {
fileids!: Dexie.Table
;
files!: Dexie.Table;
patches!: Dexie.Table<{ patch: Patch[]; inversePatch: Patch[]; index: number }, number>;
@@ -92,1312 +79,1220 @@ class Database extends Dexie {
export const db = new Database();
-// Wrap Dexie live queries in a Svelte store to avoid triggering the query for every subscriber, and updates to the store are pushed to the DB
-export function bidirectionalDexieStore(
- table: Dexie.Table,
- key: K,
- initial: V,
- initialize: boolean = true
-): Writable {
- let first = true;
- let store = writable(initialize ? initial : undefined);
- liveQuery(() => table.get(key)).subscribe((value) => {
- if (value === undefined) {
- if (first) {
- if (!initialize) {
- store.set(initial);
- }
- } else {
- store.set(value);
- }
- } else {
- store.set(value);
- }
- first = false;
- });
- return {
- subscribe: store.subscribe,
- set: (value: any) => {
- if (typeof value === 'object' || value !== get(store)) {
- table.put(value, key);
- }
- },
- update: (callback: (value: any) => any) => {
- let newValue = callback(get(store));
- if (typeof newValue === 'object' || newValue !== get(store)) {
- table.put(newValue, key);
- }
- },
- };
-}
-
-export function dexieSettingStore(
- key: string,
- initial: T,
- initialize: boolean = true
-): Writable {
- return bidirectionalDexieStore(db.settings, key, initial, initialize);
-}
-
-export const settings = {
- distanceUnits: dexieSettingStore<'metric' | 'imperial' | 'nautical'>('distanceUnits', 'metric'),
- velocityUnits: dexieSettingStore<'speed' | 'pace'>('velocityUnits', 'speed'),
- temperatureUnits: dexieSettingStore<'celsius' | 'fahrenheit'>('temperatureUnits', 'celsius'),
- elevationProfile: dexieSettingStore('elevationProfile', true),
- additionalDatasets: dexieSettingStore('additionalDatasets', []),
- elevationFill: dexieSettingStore<'slope' | 'surface' | undefined>('elevationFill', undefined),
- treeFileView: dexieSettingStore('fileView', false),
- minimizeRoutingMenu: dexieSettingStore('minimizeRoutingMenu', false),
- routing: dexieSettingStore('routing', true),
- routingProfile: dexieSettingStore('routingProfile', 'bike'),
- privateRoads: dexieSettingStore('privateRoads', false),
- currentBasemap: dexieSettingStore('currentBasemap', defaultBasemap),
- previousBasemap: dexieSettingStore('previousBasemap', defaultBasemap),
- selectedBasemapTree: dexieSettingStore('selectedBasemapTree', defaultBasemapTree),
- currentOverlays: dexieSettingStore('currentOverlays', defaultOverlays, false),
- previousOverlays: dexieSettingStore('previousOverlays', defaultOverlays),
- selectedOverlayTree: dexieSettingStore('selectedOverlayTree', defaultOverlayTree),
- currentOverpassQueries: dexieSettingStore(
- 'currentOverpassQueries',
- defaultOverpassQueries,
- false
- ),
- selectedOverpassTree: dexieSettingStore('selectedOverpassTree', defaultOverpassTree),
- opacities: dexieSettingStore('opacities', defaultOpacities),
- customLayers: dexieSettingStore>('customLayers', {}),
- customBasemapOrder: dexieSettingStore('customBasemapOrder', []),
- customOverlayOrder: dexieSettingStore('customOverlayOrder', []),
- directionMarkers: dexieSettingStore('directionMarkers', false),
- distanceMarkers: dexieSettingStore('distanceMarkers', false),
- streetViewSource: dexieSettingStore('streetViewSource', 'mapillary'),
- fileOrder: dexieSettingStore('fileOrder', []),
- defaultOpacity: dexieSettingStore('defaultOpacity', 0.7),
- defaultWidth: dexieSettingStore('defaultWidth', browser && window.innerWidth < 600 ? 8 : 5),
- bottomPanelSize: dexieSettingStore('bottomPanelSize', 170),
- rightPanelSize: dexieSettingStore('rightPanelSize', 240),
-};
-
// Wrap Dexie live queries in a Svelte store to avoid triggering the query for every subscriber
-function dexieStore(querier: () => T | Promise, initial?: T): Readable {
- let store = writable(initial);
- liveQuery(querier).subscribe((value) => {
- if (value !== undefined) {
- store.set(value);
- }
- });
- return {
- subscribe: store.subscribe,
- };
-}
+// function dexieStore(querier: () => T | Promise, initial?: T): Readable {
+// let store = writable(initial);
+// liveQuery(querier).subscribe((value) => {
+// if (value !== undefined) {
+// store.set(value);
+// }
+// });
+// return {
+// subscribe: store.subscribe,
+// };
+// }
-export class GPXStatisticsTree {
- level: ListLevel;
- statistics: {
- [key: number]: GPXStatisticsTree | GPXStatistics;
- } = {};
+// export class GPXStatisticsTree {
+// level: ListLevel;
+// statistics: {
+// [key: string]: GPXStatisticsTree | GPXStatistics;
+// } = {};
- constructor(element: GPXFile | Track) {
- if (element instanceof GPXFile) {
- this.level = ListLevel.FILE;
- element.children.forEach((child, index) => {
- this.statistics[index] = new GPXStatisticsTree(child);
- });
- } else {
- this.level = ListLevel.TRACK;
- element.children.forEach((child, index) => {
- this.statistics[index] = child.getStatistics();
- });
- }
- }
+// constructor(element: GPXFile | Track) {
+// if (element instanceof GPXFile) {
+// this.level = ListLevel.FILE;
+// element.children.forEach((child, index) => {
+// this.statistics[index] = new GPXStatisticsTree(child);
+// });
+// } else {
+// this.level = ListLevel.TRACK;
+// element.children.forEach((child, index) => {
+// this.statistics[index] = child.getStatistics();
+// });
+// }
+// }
- getStatisticsFor(item: ListItem): GPXStatistics {
- let statistics = new GPXStatistics();
- let id = item.getIdAtLevel(this.level);
- if (id === undefined || id === 'waypoints') {
- Object.keys(this.statistics).forEach((key) => {
- if (this.statistics[key] instanceof GPXStatistics) {
- statistics.mergeWith(this.statistics[key]);
- } else {
- statistics.mergeWith(this.statistics[key].getStatisticsFor(item));
- }
- });
- } else {
- let child = this.statistics[id];
- if (child instanceof GPXStatistics) {
- statistics.mergeWith(child);
- } else if (child !== undefined) {
- statistics.mergeWith(child.getStatisticsFor(item));
- }
- }
- return statistics;
- }
-}
-export type GPXFileWithStatistics = { file: GPXFile; statistics: GPXStatisticsTree };
+// getStatisticsFor(item: ListItem): GPXStatistics {
+// let statistics = new GPXStatistics();
+// let id = item.getIdAtLevel(this.level);
+// if (id === undefined || id === 'waypoints') {
+// Object.keys(this.statistics).forEach((key) => {
+// if (this.statistics[key] instanceof GPXStatistics) {
+// statistics.mergeWith(this.statistics[key]);
+// } else {
+// statistics.mergeWith(this.statistics[key].getStatisticsFor(item));
+// }
+// });
+// } else {
+// let child = this.statistics[id];
+// if (child instanceof GPXStatistics) {
+// statistics.mergeWith(child);
+// } else if (child !== undefined) {
+// statistics.mergeWith(child.getStatisticsFor(item));
+// }
+// }
+// return statistics;
+// }
+// }
+// export type GPXFileWithStatistics = { file: GPXFile; statistics: GPXStatisticsTree };
-// Wrap Dexie live queries in a Svelte store to avoid triggering the query for every subscriber, also takes care of the conversion to a GPXFile object
-function dexieGPXFileStore(id: string): Readable & { destroy: () => void } {
- let store = writable(undefined);
- let query = liveQuery(() => db.files.get(id)).subscribe((value) => {
- if (value !== undefined) {
- let gpx = new GPXFile(value);
- updateAnchorPoints(gpx);
+// // Wrap Dexie live queries in a Svelte store to avoid triggering the query for every subscriber, also takes care of the conversion to a GPXFile object
+// function dexieGPXFileStore(id: string): Readable & { destroy: () => void } {
+// let store = writable(undefined);
+// let query = liveQuery(() => db.files.get(id)).subscribe((value) => {
+// if (value !== undefined) {
+// let gpx = new GPXFile(value);
+// updateAnchorPoints(gpx);
- let statistics = new GPXStatisticsTree(gpx);
- if (!fileState.has(id)) {
- // Update the map bounds for new files
- updateTargetMapBounds(
- id,
- statistics.getStatisticsFor(new ListFileItem(id)).global.bounds
- );
- }
+// let statistics = new GPXStatisticsTree(gpx);
+// if (!fileState.has(id)) {
+// // Update the map bounds for new files
+// updateTargetMapBounds(
+// id,
+// statistics.getStatisticsFor(new ListFileItem(id)).global.bounds
+// );
+// }
- fileState.set(id, gpx);
- store.set({
- file: gpx,
- statistics,
- });
+// fileState.set(id, gpx);
+// store.set({
+// file: gpx,
+// statistics,
+// });
- if (get(selection).hasAnyChildren(new ListFileItem(id))) {
- updateAllHidden();
- }
- }
- });
- return {
- subscribe: store.subscribe,
- destroy: () => {
- fileState.delete(id);
- query.unsubscribe();
- },
- };
-}
+// if (get(selection).hasAnyChildren(new ListFileItem(id))) {
+// updateAllHidden();
+// }
+// }
+// });
+// return {
+// subscribe: store.subscribe,
+// destroy: () => {
+// fileState.delete(id);
+// query.unsubscribe();
+// },
+// };
+// }
-function updateSelection(updatedFiles: GPXFile[], deletedFileIds: string[]) {
- let removedItems: ListItem[] = [];
+// function updateSelection(updatedFiles: GPXFile[], deletedFileIds: string[]) {
+// let removedItems: ListItem[] = [];
- applyToOrderedItemsFromFile(get(selection).getSelected(), (fileId, level, items) => {
- let file = updatedFiles.find((file) => file._data.id === fileId);
- if (file) {
- items.forEach((item) => {
- if (item instanceof ListTrackItem) {
- let newTrackIndex = file.trk.findIndex(
- (track) => track._data.trackIndex === item.getTrackIndex()
- );
- if (newTrackIndex === -1) {
- removedItems.push(item);
- }
- } else if (item instanceof ListTrackSegmentItem) {
- let newTrackIndex = file.trk.findIndex(
- (track) => track._data.trackIndex === item.getTrackIndex()
- );
- if (newTrackIndex === -1) {
- removedItems.push(item);
- } else {
- let newSegmentIndex = file.trk[newTrackIndex].trkseg.findIndex(
- (segment) => segment._data.segmentIndex === item.getSegmentIndex()
- );
- if (newSegmentIndex === -1) {
- removedItems.push(item);
- }
- }
- } else if (item instanceof ListWaypointItem) {
- let newWaypointIndex = file.wpt.findIndex(
- (wpt) => wpt._data.index === item.getWaypointIndex()
- );
- if (newWaypointIndex === -1) {
- removedItems.push(item);
- }
- }
- });
- } else if (deletedFileIds.includes(fileId)) {
- items.forEach((item) => {
- removedItems.push(item);
- });
- }
- });
+// applyToOrderedItemsFromFile(get(selection).getSelected(), (fileId, level, items) => {
+// let file = updatedFiles.find((file) => file._data.id === fileId);
+// if (file) {
+// items.forEach((item) => {
+// if (item instanceof ListTrackItem) {
+// let newTrackIndex = file.trk.findIndex(
+// (track) => track._data.trackIndex === item.getTrackIndex()
+// );
+// if (newTrackIndex === -1) {
+// removedItems.push(item);
+// }
+// } else if (item instanceof ListTrackSegmentItem) {
+// let newTrackIndex = file.trk.findIndex(
+// (track) => track._data.trackIndex === item.getTrackIndex()
+// );
+// if (newTrackIndex === -1) {
+// removedItems.push(item);
+// } else {
+// let newSegmentIndex = file.trk[newTrackIndex].trkseg.findIndex(
+// (segment) => segment._data.segmentIndex === item.getSegmentIndex()
+// );
+// if (newSegmentIndex === -1) {
+// removedItems.push(item);
+// }
+// }
+// } else if (item instanceof ListWaypointItem) {
+// let newWaypointIndex = file.wpt.findIndex(
+// (wpt) => wpt._data.index === item.getWaypointIndex()
+// );
+// if (newWaypointIndex === -1) {
+// removedItems.push(item);
+// }
+// }
+// });
+// } else if (deletedFileIds.includes(fileId)) {
+// items.forEach((item) => {
+// removedItems.push(item);
+// });
+// }
+// });
- if (removedItems.length > 0) {
- selection.update(($selection) => {
- removedItems.forEach((item) => {
- if (item instanceof ListFileItem) {
- $selection.deleteChild(item.getFileId());
- } else {
- $selection.set(item, false);
- }
- });
- return $selection;
- });
- }
-}
+// if (removedItems.length > 0) {
+// selection.update(($selection) => {
+// removedItems.forEach((item) => {
+// if (item instanceof ListFileItem) {
+// $selection.deleteChild(item.getFileId());
+// } else {
+// $selection.set(item, false);
+// }
+// });
+// return $selection;
+// });
+// }
+// }
-// Commit the changes to the file state to the database
-function commitFileStateChange(newFileState: ReadonlyMap, patch: Patch[]) {
- let changedFileIds = getChangedFileIds(patch);
- let updatedFileIds: string[] = [],
- deletedFileIds: string[] = [];
+// // Commit the changes to the file state to the database
+// function commitFileStateChange(newFileState: ReadonlyMap, patch: Patch[]) {
+// let changedFileIds = getChangedFileIds(patch);
+// let updatedFileIds: string[] = [],
+// deletedFileIds: string[] = [];
- changedFileIds.forEach((id) => {
- if (newFileState.has(id)) {
- updatedFileIds.push(id);
- } else {
- deletedFileIds.push(id);
- }
- });
+// changedFileIds.forEach((id) => {
+// if (newFileState.has(id)) {
+// updatedFileIds.push(id);
+// } else {
+// deletedFileIds.push(id);
+// }
+// });
- let updatedFiles = updatedFileIds
- .map((id) => newFileState.get(id))
- .filter((file) => file !== undefined) as GPXFile[];
- updatedFileIds = updatedFiles.map((file) => file._data.id);
+// let updatedFiles = updatedFileIds
+// .map((id) => newFileState.get(id))
+// .filter((file) => file !== undefined) as GPXFile[];
+// updatedFileIds = updatedFiles.map((file) => file._data.id);
- updateSelection(updatedFiles, deletedFileIds);
+// updateSelection(updatedFiles, deletedFileIds);
- return db.transaction('rw', db.fileids, db.files, async () => {
- if (updatedFileIds.length > 0) {
- await db.fileids.bulkPut(updatedFileIds, updatedFileIds);
- await db.files.bulkPut(updatedFiles, updatedFileIds);
- }
- if (deletedFileIds.length > 0) {
- await db.fileids.bulkDelete(deletedFileIds);
- await db.files.bulkDelete(deletedFileIds);
- }
- });
-}
+// return db.transaction('rw', db.fileids, db.files, async () => {
+// if (updatedFileIds.length > 0) {
+// await db.fileids.bulkPut(updatedFileIds, updatedFileIds);
+// await db.files.bulkPut(updatedFiles, updatedFileIds);
+// }
+// if (deletedFileIds.length > 0) {
+// await db.fileids.bulkDelete(deletedFileIds);
+// await db.files.bulkDelete(deletedFileIds);
+// }
+// });
+// }
-export const fileObservers: Writable<
- Map & { destroy?: () => void }>
-> = writable(new Map());
-const fileState: Map = new Map(); // Used to generate patches
+// export const fileObservers: Writable<
+// Map & { destroy?: () => void }>
+// > = writable(new Map());
+// const fileState: Map = new Map(); // Used to generate patches
-// Observe the file ids in the database, and maintain a map of file observers for the corresponding files
-export function observeFilesFromDatabase(fitBounds: boolean) {
- let initialize = true;
- liveQuery(() => db.fileids.toArray()).subscribe((dbFileIds) => {
- if (initialize) {
- if (fitBounds && dbFileIds.length > 0) {
- initTargetMapBounds(dbFileIds);
- }
- initialize = false;
- }
- // Find new files to observe
- let newFiles = dbFileIds
- .filter((id) => !get(fileObservers).has(id))
- .sort((a, b) => parseInt(a.split('-')[1]) - parseInt(b.split('-')[1]));
- // Find deleted files to stop observing
- let deletedFiles = Array.from(get(fileObservers).keys()).filter(
- (id) => !dbFileIds.find((fileId) => fileId === id)
- );
+// // Observe the file ids in the database, and maintain a map of file observers for the corresponding files
+// export function observeFilesFromDatabase(fitBounds: boolean) {
+// let initialize = true;
+// liveQuery(() => db.fileids.toArray()).subscribe((dbFileIds) => {
+// if (initialize) {
+// if (fitBounds && dbFileIds.length > 0) {
+// initTargetMapBounds(dbFileIds);
+// }
+// initialize = false;
+// }
+// // Find new files to observe
+// let newFiles = dbFileIds
+// .filter((id) => !get(fileObservers).has(id))
+// .sort((a, b) => parseInt(a.split('-')[1]) - parseInt(b.split('-')[1]));
+// // Find deleted files to stop observing
+// let deletedFiles = Array.from(get(fileObservers).keys()).filter(
+// (id) => !dbFileIds.find((fileId) => fileId === id)
+// );
- // Update the store
- if (newFiles.length > 0 || deletedFiles.length > 0) {
- fileObservers.update(($files) => {
- newFiles.forEach((id) => {
- $files.set(id, dexieGPXFileStore(id));
- });
- deletedFiles.forEach((id) => {
- $files.get(id)?.destroy?.();
- $files.delete(id);
- });
- return $files;
- });
- settings.fileOrder.update((order) => {
- newFiles.forEach((fileId) => {
- if (!order.includes(fileId)) {
- order.push(fileId);
- }
- });
- deletedFiles.forEach((fileId) => {
- let index = order.indexOf(fileId);
- if (index !== -1) {
- order.splice(index, 1);
- }
- });
- return order;
- });
- }
- });
-}
+// // Update the store
+// if (newFiles.length > 0 || deletedFiles.length > 0) {
+// fileObservers.update(($files) => {
+// newFiles.forEach((id) => {
+// $files.set(id, dexieGPXFileStore(id));
+// });
+// deletedFiles.forEach((id) => {
+// $files.get(id)?.destroy?.();
+// $files.delete(id);
+// });
+// return $files;
+// });
+// settings.fileOrder.update((order) => {
+// newFiles.forEach((fileId) => {
+// if (!order.includes(fileId)) {
+// order.push(fileId);
+// }
+// });
+// deletedFiles.forEach((fileId) => {
+// let index = order.indexOf(fileId);
+// if (index !== -1) {
+// order.splice(index, 1);
+// }
+// });
+// return order;
+// });
+// }
+// });
+// }
-export function getFile(fileId: string): GPXFile | undefined {
- let fileStore = get(fileObservers).get(fileId);
- return fileStore ? get(fileStore)?.file : undefined;
-}
+// export function getFile(fileId: string): GPXFile | undefined {
+// let fileStore = get(fileObservers).get(fileId);
+// return fileStore ? get(fileStore)?.file : undefined;
+// }
-export function getStatistics(fileId: string): GPXStatisticsTree | undefined {
- let fileStore = get(fileObservers).get(fileId);
- return fileStore ? get(fileStore)?.statistics : undefined;
-}
+// export function getStatistics(fileId: string): GPXStatisticsTree | undefined {
+// let fileStore = get(fileObservers).get(fileId);
+// return fileStore ? get(fileStore)?.statistics : undefined;
+// }
-const patchIndex: Readable = dexieStore(() => db.settings.get('patchIndex'), -1);
-const patchMinMaxIndex: Readable<{ min: number; max: number }> = dexieStore(
- () =>
- db.patches
- .orderBy(':id')
- .keys()
- .then((keys) => {
- if (keys.length === 0) {
- return { min: 0, max: 0 };
- } else {
- return { min: keys[0], max: keys[keys.length - 1] + 1 };
- }
- }),
- { min: 0, max: 0 }
-);
-export const canUndo: Readable = derived(
- [patchIndex, patchMinMaxIndex],
- ([$patchIndex, $patchMinMaxIndex]) => $patchIndex >= $patchMinMaxIndex.min
-);
-export const canRedo: Readable = derived(
- [patchIndex, patchMinMaxIndex],
- ([$patchIndex, $patchMinMaxIndex]) => $patchIndex < $patchMinMaxIndex.max - 1
-);
+// const patchIndex: Readable = dexieStore(() => db.settings.get('patchIndex'), -1);
+// const patchMinMaxIndex: Readable<{ min: number; max: number }> = dexieStore(
+// () =>
+// (db.patches.orderBy(':id').keys() as Promise).then((keys) => {
+// if (keys.length === 0) {
+// return { min: 0, max: 0 };
+// } else {
+// return { min: keys[0], max: keys[keys.length - 1] + 1 };
+// }
+// }),
+// { min: 0, max: 0 }
+// );
+// export const canUndo: Readable = derived(
+// [patchIndex, patchMinMaxIndex],
+// ([$patchIndex, $patchMinMaxIndex]) => $patchIndex >= $patchMinMaxIndex.min
+// );
+// export const canRedo: Readable = derived(
+// [patchIndex, patchMinMaxIndex],
+// ([$patchIndex, $patchMinMaxIndex]) => $patchIndex < $patchMinMaxIndex.max - 1
+// );
-// Helper function to apply a callback to the global file state
-function applyGlobal(callback: (files: Map) => void) {
- const [newFileState, patch, inversePatch] = produceWithPatches(fileState, callback);
+// // Helper function to apply a callback to the global file state
+// function applyGlobal(callback: (files: Map) => void) {
+// const [newFileState, patch, inversePatch] = produceWithPatches(fileState, callback);
- storePatches(patch, inversePatch);
+// storePatches(patch, inversePatch);
- return commitFileStateChange(newFileState, patch);
-}
+// return commitFileStateChange(newFileState, patch);
+// }
-// Helper function to apply a callback to multiple files
-function applyToFiles(fileIds: string[], callback: (file: WritableDraft) => void) {
- const [newFileState, patch, inversePatch] = produceWithPatches(fileState, (draft) => {
- fileIds.forEach((fileId) => {
- let file = draft.get(fileId);
- if (file) {
- callback(file);
- }
- });
- });
+// // Helper function to apply a callback to multiple files
+// function applyToFiles(fileIds: string[], callback: (file: WritableDraft) => void) {
+// const [newFileState, patch, inversePatch] = produceWithPatches(fileState, (draft) => {
+// fileIds.forEach((fileId) => {
+// let file = draft.get(fileId);
+// if (file) {
+// callback(file);
+// }
+// });
+// });
- storePatches(patch, inversePatch);
+// storePatches(patch, inversePatch);
- return commitFileStateChange(newFileState, patch);
-}
+// return commitFileStateChange(newFileState, patch);
+// }
-// Helper function to apply different callbacks to multiple files
-function applyEachToFilesAndGlobal(
- fileIds: string[],
- callbacks: ((file: WritableDraft, context?: any) => void)[],
- globalCallback: (files: Map, context?: any) => void,
- context?: any
-) {
- const [newFileState, patch, inversePatch] = produceWithPatches(fileState, (draft) => {
- fileIds.forEach((fileId, index) => {
- let file = draft.get(fileId);
- if (file) {
- callbacks[index](file, context);
- }
- });
- globalCallback(draft, context);
- });
+// // Helper function to apply different callbacks to multiple files
+// function applyEachToFilesAndGlobal(
+// fileIds: string[],
+// callbacks: ((file: WritableDraft, context?: any) => void)[],
+// globalCallback: (files: Map, context?: any) => void,
+// context?: any
+// ) {
+// const [newFileState, patch, inversePatch] = produceWithPatches(fileState, (draft) => {
+// fileIds.forEach((fileId, index) => {
+// let file = draft.get(fileId);
+// if (file) {
+// callbacks[index](file, context);
+// }
+// });
+// globalCallback(draft, context);
+// });
- storePatches(patch, inversePatch);
+// storePatches(patch, inversePatch);
- return commitFileStateChange(newFileState, patch);
-}
+// return commitFileStateChange(newFileState, patch);
+// }
-const MAX_PATCHES = 100;
-// Store the new patches in the database
-async function storePatches(patch: Patch[], inversePatch: Patch[]) {
- if (get(patchIndex) !== undefined) {
- db.patches.where(':id').above(get(patchIndex)).delete(); // Delete all patches after the current patch to avoid redoing them
- let minmax = get(patchMinMaxIndex);
- if (minmax.max - minmax.min + 1 > MAX_PATCHES) {
- db.patches
- .where(':id')
- .belowOrEqual(get(patchMinMaxIndex).max - MAX_PATCHES)
- .delete();
- }
- }
- db.transaction('rw', db.patches, db.settings, async () => {
- let index = get(patchIndex) + 1;
- await db.patches.put(
- {
- patch,
- inversePatch,
- index,
- },
- index
- );
- await db.settings.put(index, 'patchIndex');
- });
-}
+// const MAX_PATCHES = 100;
+// // Store the new patches in the database
+// async function storePatches(patch: Patch[], inversePatch: Patch[]) {
+// if (get(patchIndex) !== undefined) {
+// db.patches.where(':id').above(get(patchIndex)).delete(); // Delete all patches after the current patch to avoid redoing them
+// let minmax = get(patchMinMaxIndex);
+// if (minmax.max - minmax.min + 1 > MAX_PATCHES) {
+// db.patches
+// .where(':id')
+// .belowOrEqual(get(patchMinMaxIndex).max - MAX_PATCHES)
+// .delete();
+// }
+// }
+// db.transaction('rw', db.patches, db.settings, async () => {
+// let index = get(patchIndex) + 1;
+// await db.patches.put(
+// {
+// patch,
+// inversePatch,
+// index,
+// },
+// index
+// );
+// await db.settings.put(index, 'patchIndex');
+// });
+// }
-// Apply a patch to the file state
-function applyPatch(patch: Patch[]) {
- let newFileState = applyPatches(fileState, patch);
- return commitFileStateChange(newFileState, patch);
-}
+// // Apply a patch to the file state
+// function applyPatch(patch: Patch[]) {
+// let newFileState = applyPatches(fileState, patch);
+// return commitFileStateChange(newFileState, patch);
+// }
-// Get the file ids of the files that have changed in the patch
-function getChangedFileIds(patch: Patch[]): string[] {
- let changedFileIds = new Set();
- for (let p of patch) {
- changedFileIds.add(p.path[0]);
- }
- return Array.from(changedFileIds);
-}
+// // Get the file ids of the files that have changed in the patch
+// function getChangedFileIds(patch: Patch[]): string[] {
+// let changedFileIds = new Set();
+// for (let p of patch) {
+// changedFileIds.add(p.path[0] as string);
+// }
+// return Array.from(changedFileIds);
+// }
-// Generate unique file ids, different from the ones in the database
-export function getFileIds(n: number) {
- let ids = [];
- for (let index = 0; ids.length < n; index++) {
- let id = `gpx-${index}`;
- if (!get(fileObservers).has(id)) {
- ids.push(id);
- }
- }
- return ids;
-}
+// // Generate unique file ids, different from the ones in the database
+// export function getFileIds(n: number) {
+// let ids = [];
+// for (let index = 0; ids.length < n; index++) {
+// let id = `gpx-${index}`;
+// if (!get(fileObservers).has(id)) {
+// ids.push(id);
+// }
+// }
+// return ids;
+// }
-// Helper functions for file operations
-export const dbUtils = {
- add: (file: GPXFile) => {
- if (file._data.id === undefined) {
- file._data.id = getFileIds(1)[0];
- }
- return applyGlobal((draft) => {
- draft.set(file._data.id, freeze(file));
- });
- },
- addMultiple: (files: GPXFile[]) => {
- let ids = getFileIds(files.length);
- applyGlobal((draft) => {
- files.forEach((file, index) => {
- file._data.id = ids[index];
- draft.set(file._data.id, freeze(file));
- });
- });
- return ids;
- },
- applyToFile: (id: string, callback: (file: WritableDraft) => void) => {
- applyToFiles([id], callback);
- },
- applyToFiles: (ids: string[], callback: (file: WritableDraft) => void) => {
- applyToFiles(ids, callback);
- },
- applyEachToFilesAndGlobal: (
- ids: string[],
- callbacks: ((file: WritableDraft, context?: any) => void)[],
- globalCallback: (files: Map, context?: any) => void,
- context?: any
- ) => {
- applyEachToFilesAndGlobal(ids, callbacks, globalCallback, context);
- },
- duplicateSelection: () => {
- if (get(selection).size === 0) {
- return;
- }
- applyGlobal((draft) => {
- let ids = getFileIds(get(settings.fileOrder).length);
- let index = 0;
- applyToOrderedSelectedItemsFromFile((fileId, level, items) => {
- if (level === ListLevel.FILE) {
- let file = getFile(fileId);
- if (file) {
- let newFile = file.clone();
- newFile._data.id = ids[index++];
- draft.set(newFile._data.id, freeze(newFile));
- }
- } else {
- let file = draft.get(fileId);
- if (file) {
- if (level === ListLevel.TRACK) {
- for (let item of items) {
- let trackIndex = (item as ListTrackItem).getTrackIndex();
- file.replaceTracks(trackIndex + 1, trackIndex, [
- file.trk[trackIndex].clone(),
- ]);
- }
- } else if (level === ListLevel.SEGMENT) {
- for (let item of items) {
- let trackIndex = (item as ListTrackSegmentItem).getTrackIndex();
- let segmentIndex = (item as ListTrackSegmentItem).getSegmentIndex();
- file.replaceTrackSegments(
- trackIndex,
- segmentIndex + 1,
- segmentIndex,
- [file.trk[trackIndex].trkseg[segmentIndex].clone()]
- );
- }
- } else if (level === ListLevel.WAYPOINTS) {
- file.replaceWaypoints(
- file.wpt.length,
- file.wpt.length - 1,
- file.wpt.map((wpt) => wpt.clone())
- );
- } else if (level === ListLevel.WAYPOINT) {
- for (let item of items) {
- let waypointIndex = (item as ListWaypointItem).getWaypointIndex();
- file.replaceWaypoints(waypointIndex + 1, waypointIndex, [
- file.wpt[waypointIndex].clone(),
- ]);
- }
- }
- }
- }
- });
- });
- },
- addNewTrack: (fileId: string) => {
- dbUtils.applyToFile(fileId, (file) =>
- file.replaceTracks(file.trk.length, file.trk.length, [new Track()])
- );
- },
- addNewSegment: (fileId: string, trackIndex: number) => {
- dbUtils.applyToFile(fileId, (file) => {
- let track = file.trk[trackIndex];
- track.replaceTrackSegments(track.trkseg.length, track.trkseg.length, [
- new TrackSegment(),
- ]);
- });
- },
- reverseSelection: () => {
- if (
- !get(selection).hasAnyChildren(new ListRootItem(), true, ['waypoints']) ||
- get(gpxStatistics).local.points?.length <= 1
- ) {
- return;
- }
- applyGlobal((draft) => {
- applyToOrderedSelectedItemsFromFile((fileId, level, items) => {
- let file = draft.get(fileId);
- if (file) {
- if (level === ListLevel.FILE) {
- file.reverse();
- } else if (level === ListLevel.TRACK) {
- for (let item of items) {
- let trackIndex = (item as ListTrackItem).getTrackIndex();
- file.reverseTrack(trackIndex);
- }
- } else if (level === ListLevel.SEGMENT) {
- for (let item of items) {
- let trackIndex = (item as ListTrackSegmentItem).getTrackIndex();
- let segmentIndex = (item as ListTrackSegmentItem).getSegmentIndex();
- file.reverseTrackSegment(trackIndex, segmentIndex);
- }
- }
- }
- });
- });
- },
- createRoundTripForSelection() {
- if (!get(selection).hasAnyChildren(new ListRootItem(), true, ['waypoints'])) {
- return;
- }
- applyGlobal((draft) => {
- applyToOrderedSelectedItemsFromFile((fileId, level, items) => {
- let file = draft.get(fileId);
- if (file) {
- if (level === ListLevel.FILE) {
- file.roundTrip();
- } else if (level === ListLevel.TRACK) {
- for (let item of items) {
- let trackIndex = (item as ListTrackItem).getTrackIndex();
- file.roundTripTrack(trackIndex);
- }
- } else if (level === ListLevel.SEGMENT) {
- for (let item of items) {
- let trackIndex = (item as ListTrackSegmentItem).getTrackIndex();
- let segmentIndex = (item as ListTrackSegmentItem).getSegmentIndex();
- file.roundTripTrackSegment(trackIndex, segmentIndex);
- }
- }
- }
- });
- });
- },
- mergeSelection: (mergeTraces: boolean, removeGaps: boolean) => {
- applyGlobal((draft) => {
- let first = true;
- let target: ListItem = new ListRootItem();
- let targetFile: GPXFile | undefined = undefined;
- let toMerge: {
- trk: Track[];
- trkseg: TrackSegment[];
- wpt: Waypoint[];
- } = {
- trk: [],
- trkseg: [],
- wpt: [],
- };
- applyToOrderedSelectedItemsFromFile((fileId, level, items) => {
- let file = draft.get(fileId);
- let originalFile = getFile(fileId);
- if (file && originalFile) {
- if (level === ListLevel.FILE) {
- toMerge.trk.push(...originalFile.trk.map((track) => track.clone()));
- for (const wpt of originalFile.wpt) {
- if (!toMerge.wpt.some((w) => w.equals(wpt))) {
- toMerge.wpt.push(wpt.clone());
- }
- }
- if (first) {
- target = items[0];
- targetFile = file;
- } else {
- draft.delete(fileId);
- }
- } else {
- if (level === ListLevel.TRACK) {
- items.forEach((item, index) => {
- let trackIndex = (item as ListTrackItem).getTrackIndex();
- toMerge.trkseg.splice(
- 0,
- 0,
- ...originalFile.trk[trackIndex].trkseg.map((segment) =>
- segment.clone()
- )
- );
- if (index === items.length - 1) {
- // Order is reversed, so the last track is the first one and the one to keep
- target = item;
- file.trk[trackIndex].trkseg = [];
- } else {
- file.trk.splice(trackIndex, 1);
- }
- });
- } else if (level === ListLevel.SEGMENT) {
- items.forEach((item, index) => {
- let trackIndex = (item as ListTrackSegmentItem).getTrackIndex();
- let segmentIndex = (item as ListTrackSegmentItem).getSegmentIndex();
- if (index === items.length - 1) {
- // Order is reversed, so the last segment is the first one and the one to keep
- target = item;
- }
- toMerge.trkseg.splice(
- 0,
- 0,
- originalFile.trk[trackIndex].trkseg[segmentIndex].clone()
- );
- file.trk[trackIndex].trkseg.splice(segmentIndex, 1);
- });
- }
- targetFile = file;
- }
- first = false;
- }
- });
+// // Helper functions for file operations
+// export const dbUtils = {
+// add: (file: GPXFile) => {
+// if (file._data.id === undefined) {
+// file._data.id = getFileIds(1)[0];
+// }
+// return applyGlobal((draft) => {
+// draft.set(file._data.id, freeze(file));
+// });
+// },
+// addMultiple: (files: GPXFile[]) => {
+// let ids = getFileIds(files.length);
+// applyGlobal((draft) => {
+// files.forEach((file, index) => {
+// file._data.id = ids[index];
+// draft.set(file._data.id, freeze(file));
+// });
+// });
+// return ids;
+// },
+// applyToFile: (id: string, callback: (file: WritableDraft) => void) => {
+// applyToFiles([id], callback);
+// },
+// applyToFiles: (ids: string[], callback: (file: WritableDraft) => void) => {
+// applyToFiles(ids, callback);
+// },
+// applyEachToFilesAndGlobal: (
+// ids: string[],
+// callbacks: ((file: WritableDraft, context?: any) => void)[],
+// globalCallback: (files: Map, context?: any) => void,
+// context?: any
+// ) => {
+// applyEachToFilesAndGlobal(ids, callbacks, globalCallback, context);
+// },
+// duplicateSelection: () => {
+// if (get(selection).size === 0) {
+// return;
+// }
+// applyGlobal((draft) => {
+// let ids = getFileIds(get(settings.fileOrder).length);
+// let index = 0;
+// applyToOrderedSelectedItemsFromFile((fileId, level, items) => {
+// if (level === ListLevel.FILE) {
+// let file = getFile(fileId);
+// if (file) {
+// let newFile = file.clone();
+// newFile._data.id = ids[index++];
+// draft.set(newFile._data.id, freeze(newFile));
+// }
+// } else {
+// let file = draft.get(fileId);
+// if (file) {
+// if (level === ListLevel.TRACK) {
+// for (let item of items) {
+// let trackIndex = (item as ListTrackItem).getTrackIndex();
+// file.replaceTracks(trackIndex + 1, trackIndex, [
+// file.trk[trackIndex].clone(),
+// ]);
+// }
+// } else if (level === ListLevel.SEGMENT) {
+// for (let item of items) {
+// let trackIndex = (item as ListTrackSegmentItem).getTrackIndex();
+// let segmentIndex = (item as ListTrackSegmentItem).getSegmentIndex();
+// file.replaceTrackSegments(
+// trackIndex,
+// segmentIndex + 1,
+// segmentIndex,
+// [file.trk[trackIndex].trkseg[segmentIndex].clone()]
+// );
+// }
+// } else if (level === ListLevel.WAYPOINTS) {
+// file.replaceWaypoints(
+// file.wpt.length,
+// file.wpt.length - 1,
+// file.wpt.map((wpt) => wpt.clone())
+// );
+// } else if (level === ListLevel.WAYPOINT) {
+// for (let item of items) {
+// let waypointIndex = (item as ListWaypointItem).getWaypointIndex();
+// file.replaceWaypoints(waypointIndex + 1, waypointIndex, [
+// file.wpt[waypointIndex].clone(),
+// ]);
+// }
+// }
+// }
+// }
+// });
+// });
+// },
+// addNewTrack: (fileId: string) => {
+// dbUtils.applyToFile(fileId, (file) =>
+// file.replaceTracks(file.trk.length, file.trk.length, [new Track()])
+// );
+// },
+// addNewSegment: (fileId: string, trackIndex: number) => {
+// dbUtils.applyToFile(fileId, (file) => {
+// let track = file.trk[trackIndex];
+// track.replaceTrackSegments(track.trkseg.length, track.trkseg.length, [
+// new TrackSegment(),
+// ]);
+// });
+// },
+// reverseSelection: () => {
+// if (
+// !get(selection).hasAnyChildren(new ListRootItem(), true, ['waypoints']) ||
+// get(gpxStatistics).local.points?.length <= 1
+// ) {
+// return;
+// }
+// applyGlobal((draft) => {
+// applyToOrderedSelectedItemsFromFile((fileId, level, items) => {
+// let file = draft.get(fileId);
+// if (file) {
+// if (level === ListLevel.FILE) {
+// file.reverse();
+// } else if (level === ListLevel.TRACK) {
+// for (let item of items) {
+// let trackIndex = (item as ListTrackItem).getTrackIndex();
+// file.reverseTrack(trackIndex);
+// }
+// } else if (level === ListLevel.SEGMENT) {
+// for (let item of items) {
+// let trackIndex = (item as ListTrackSegmentItem).getTrackIndex();
+// let segmentIndex = (item as ListTrackSegmentItem).getSegmentIndex();
+// file.reverseTrackSegment(trackIndex, segmentIndex);
+// }
+// }
+// }
+// });
+// });
+// },
+// createRoundTripForSelection() {
+// if (!get(selection).hasAnyChildren(new ListRootItem(), true, ['waypoints'])) {
+// return;
+// }
+// applyGlobal((draft) => {
+// applyToOrderedSelectedItemsFromFile((fileId, level, items) => {
+// let file = draft.get(fileId);
+// if (file) {
+// if (level === ListLevel.FILE) {
+// file.roundTrip();
+// } else if (level === ListLevel.TRACK) {
+// for (let item of items) {
+// let trackIndex = (item as ListTrackItem).getTrackIndex();
+// file.roundTripTrack(trackIndex);
+// }
+// } else if (level === ListLevel.SEGMENT) {
+// for (let item of items) {
+// let trackIndex = (item as ListTrackSegmentItem).getTrackIndex();
+// let segmentIndex = (item as ListTrackSegmentItem).getSegmentIndex();
+// file.roundTripTrackSegment(trackIndex, segmentIndex);
+// }
+// }
+// }
+// });
+// });
+// },
+// mergeSelection: (mergeTraces: boolean, removeGaps: boolean) => {
+// applyGlobal((draft) => {
+// let first = true;
+// let target: ListItem = new ListRootItem();
+// let targetFile: GPXFile | undefined = undefined;
+// let toMerge: {
+// trk: Track[];
+// trkseg: TrackSegment[];
+// wpt: Waypoint[];
+// } = {
+// trk: [],
+// trkseg: [],
+// wpt: [],
+// };
+// applyToOrderedSelectedItemsFromFile((fileId, level, items) => {
+// let file = draft.get(fileId);
+// let originalFile = getFile(fileId);
+// if (file && originalFile) {
+// if (level === ListLevel.FILE) {
+// toMerge.trk.push(...originalFile.trk.map((track) => track.clone()));
+// for (const wpt of originalFile.wpt) {
+// if (!toMerge.wpt.some((w) => w.equals(wpt))) {
+// toMerge.wpt.push(wpt.clone());
+// }
+// }
+// if (first) {
+// target = items[0];
+// targetFile = file;
+// } else {
+// draft.delete(fileId);
+// }
+// } else {
+// if (level === ListLevel.TRACK) {
+// items.forEach((item, index) => {
+// let trackIndex = (item as ListTrackItem).getTrackIndex();
+// toMerge.trkseg.splice(
+// 0,
+// 0,
+// ...originalFile.trk[trackIndex].trkseg.map((segment) =>
+// segment.clone()
+// )
+// );
+// if (index === items.length - 1) {
+// // Order is reversed, so the last track is the first one and the one to keep
+// target = item;
+// file.trk[trackIndex].trkseg = [];
+// } else {
+// file.trk.splice(trackIndex, 1);
+// }
+// });
+// } else if (level === ListLevel.SEGMENT) {
+// items.forEach((item, index) => {
+// let trackIndex = (item as ListTrackSegmentItem).getTrackIndex();
+// let segmentIndex = (item as ListTrackSegmentItem).getSegmentIndex();
+// if (index === items.length - 1) {
+// // Order is reversed, so the last segment is the first one and the one to keep
+// target = item;
+// }
+// toMerge.trkseg.splice(
+// 0,
+// 0,
+// originalFile.trk[trackIndex].trkseg[segmentIndex].clone()
+// );
+// file.trk[trackIndex].trkseg.splice(segmentIndex, 1);
+// });
+// }
+// targetFile = file;
+// }
+// first = false;
+// }
+// });
- if (mergeTraces) {
- let statistics = get(gpxStatistics);
- let speed =
- statistics.global.speed.moving > 0 ? statistics.global.speed.moving : undefined;
- let startTime: Date | undefined = undefined;
- if (speed !== undefined) {
- if (
- statistics.local.points.length > 0 &&
- statistics.local.points[0].time !== undefined
- ) {
- startTime = statistics.local.points[0].time;
- } else {
- let index = statistics.local.points.findIndex(
- (point) => point.time !== undefined
- );
- if (index !== -1) {
- startTime = new Date(
- statistics.local.points[index].time.getTime() -
- (1000 * 3600 * statistics.local.distance.total[index]) / speed
- );
- }
- }
- }
+// if (mergeTraces) {
+// let statistics = get(gpxStatistics);
+// let speed =
+// statistics.global.speed.moving > 0 ? statistics.global.speed.moving : undefined;
+// let startTime: Date | undefined = undefined;
+// if (speed !== undefined) {
+// if (
+// statistics.local.points.length > 0 &&
+// statistics.local.points[0].time !== undefined
+// ) {
+// startTime = statistics.local.points[0].time;
+// } else {
+// let index = statistics.local.points.findIndex(
+// (point) => point.time !== undefined
+// );
+// if (index !== -1 && statistics.local.points[index].time) {
+// startTime = new Date(
+// statistics.local.points[index].time.getTime() -
+// (1000 * 3600 * statistics.local.distance.total[index]) / speed
+// );
+// }
+// }
+// }
- if (toMerge.trk.length > 0 && toMerge.trk[0].trkseg.length > 0) {
- let s = new TrackSegment();
- toMerge.trk.map((track) => {
- track.trkseg.forEach((segment) => {
- s.replaceTrackPoints(
- s.trkpt.length,
- s.trkpt.length,
- segment.trkpt.slice(),
- speed,
- startTime,
- removeGaps
- );
- });
- });
- toMerge.trk = [toMerge.trk[0]];
- toMerge.trk[0].trkseg = [s];
- }
- if (toMerge.trkseg.length > 0) {
- let s = new TrackSegment();
- toMerge.trkseg.forEach((segment) => {
- s.replaceTrackPoints(
- s.trkpt.length,
- s.trkpt.length,
- segment.trkpt.slice(),
- speed,
- startTime,
- removeGaps
- );
- });
- toMerge.trkseg = [s];
- }
- }
+// if (toMerge.trk.length > 0 && toMerge.trk[0].trkseg.length > 0) {
+// let s = new TrackSegment();
+// toMerge.trk.map((track) => {
+// track.trkseg.forEach((segment) => {
+// s.replaceTrackPoints(
+// s.trkpt.length,
+// s.trkpt.length,
+// segment.trkpt.slice(),
+// speed,
+// startTime,
+// removeGaps
+// );
+// });
+// });
+// toMerge.trk = [toMerge.trk[0]];
+// toMerge.trk[0].trkseg = [s];
+// }
+// if (toMerge.trkseg.length > 0) {
+// let s = new TrackSegment();
+// toMerge.trkseg.forEach((segment) => {
+// s.replaceTrackPoints(
+// s.trkpt.length,
+// s.trkpt.length,
+// segment.trkpt.slice(),
+// speed,
+// startTime,
+// removeGaps
+// );
+// });
+// toMerge.trkseg = [s];
+// }
+// }
- if (targetFile) {
- if (target instanceof ListFileItem) {
- targetFile.replaceTracks(0, targetFile.trk.length - 1, toMerge.trk);
- targetFile.replaceWaypoints(0, targetFile.wpt.length - 1, toMerge.wpt);
- } else if (target instanceof ListTrackItem) {
- let trackIndex = target.getTrackIndex();
- targetFile.replaceTrackSegments(trackIndex, 0, -1, toMerge.trkseg);
- } else if (target instanceof ListTrackSegmentItem) {
- let trackIndex = target.getTrackIndex();
- let segmentIndex = target.getSegmentIndex();
- targetFile.replaceTrackSegments(
- trackIndex,
- segmentIndex,
- segmentIndex - 1,
- toMerge.trkseg
- );
- }
- }
- });
- },
- cropSelection: (start: number, end: number) => {
- if (get(selection).size === 0) {
- return;
- }
- applyGlobal((draft) => {
- applyToOrderedSelectedItemsFromFile((fileId, level, items) => {
- let file = draft.get(fileId);
- if (file) {
- if (level === ListLevel.FILE) {
- let length = file.getNumberOfTrackPoints();
- if (start >= length || end < 0) {
- draft.delete(fileId);
- } else if (start > 0 || end < length - 1) {
- file.crop(Math.max(0, start), Math.min(length - 1, end));
- }
- start -= length;
- end -= length;
- } else if (level === ListLevel.TRACK) {
- let trackIndices = items.map((item) =>
- (item as ListTrackItem).getTrackIndex()
- );
- file.crop(start, end, trackIndices);
- } else if (level === ListLevel.SEGMENT) {
- let trackIndices = [(items[0] as ListTrackSegmentItem).getTrackIndex()];
- let segmentIndices = items.map((item) =>
- (item as ListTrackSegmentItem).getSegmentIndex()
- );
- file.crop(start, end, trackIndices, segmentIndices);
- }
- }
- }, false);
- });
- },
- extractSelection: () => {
- return applyGlobal((draft) => {
- applyToOrderedSelectedItemsFromFile((fileId, level, items) => {
- if (level === ListLevel.FILE) {
- let file = getFile(fileId);
- if (file) {
- if (file.trk.length > 1) {
- let fileIds = getFileIds(file.trk.length);
+// if (targetFile) {
+// if (target instanceof ListFileItem) {
+// targetFile.replaceTracks(0, targetFile.trk.length - 1, toMerge.trk);
+// targetFile.replaceWaypoints(0, targetFile.wpt.length - 1, toMerge.wpt);
+// } else if (target instanceof ListTrackItem) {
+// let trackIndex = target.getTrackIndex();
+// targetFile.replaceTrackSegments(trackIndex, 0, -1, toMerge.trkseg);
+// } else if (target instanceof ListTrackSegmentItem) {
+// let trackIndex = target.getTrackIndex();
+// let segmentIndex = target.getSegmentIndex();
+// targetFile.replaceTrackSegments(
+// trackIndex,
+// segmentIndex,
+// segmentIndex - 1,
+// toMerge.trkseg
+// );
+// }
+// }
+// });
+// },
+// cropSelection: (start: number, end: number) => {
+// if (get(selection).size === 0) {
+// return;
+// }
+// applyGlobal((draft) => {
+// applyToOrderedSelectedItemsFromFile((fileId, level, items) => {
+// let file = draft.get(fileId);
+// if (file) {
+// if (level === ListLevel.FILE) {
+// let length = file.getNumberOfTrackPoints();
+// if (start >= length || end < 0) {
+// draft.delete(fileId);
+// } else if (start > 0 || end < length - 1) {
+// file.crop(Math.max(0, start), Math.min(length - 1, end));
+// }
+// start -= length;
+// end -= length;
+// } else if (level === ListLevel.TRACK) {
+// let trackIndices = items.map((item) =>
+// (item as ListTrackItem).getTrackIndex()
+// );
+// file.crop(start, end, trackIndices);
+// } else if (level === ListLevel.SEGMENT) {
+// let trackIndices = [(items[0] as ListTrackSegmentItem).getTrackIndex()];
+// let segmentIndices = items.map((item) =>
+// (item as ListTrackSegmentItem).getSegmentIndex()
+// );
+// file.crop(start, end, trackIndices, segmentIndices);
+// }
+// }
+// }, false);
+// });
+// },
+// extractSelection: () => {
+// return applyGlobal((draft) => {
+// applyToOrderedSelectedItemsFromFile((fileId, level, items) => {
+// if (level === ListLevel.FILE) {
+// let file = getFile(fileId);
+// if (file) {
+// if (file.trk.length > 1) {
+// let fileIds = getFileIds(file.trk.length);
- let closest = file.wpt.map((wpt, wptIndex) => {
- return {
- wptIndex: wptIndex,
- index: [0],
- distance: Number.MAX_VALUE,
- };
- });
- file.trk.forEach((track, index) => {
- track.getSegments().forEach((segment) => {
- segment.trkpt.forEach((point) => {
- file.wpt.forEach((wpt, wptIndex) => {
- let dist = distance(
- point.getCoordinates(),
- wpt.getCoordinates()
- );
- if (dist < closest[wptIndex].distance) {
- closest[wptIndex].distance = dist;
- closest[wptIndex].index = [index];
- } else if (dist === closest[wptIndex].distance) {
- closest[wptIndex].index.push(index);
- }
- });
- });
- });
- });
+// let closest = file.wpt.map((wpt, wptIndex) => {
+// return {
+// wptIndex: wptIndex,
+// index: [0],
+// distance: Number.MAX_VALUE,
+// };
+// });
+// file.trk.forEach((track, index) => {
+// track.getSegments().forEach((segment) => {
+// segment.trkpt.forEach((point) => {
+// file.wpt.forEach((wpt, wptIndex) => {
+// let dist = distance(
+// point.getCoordinates(),
+// wpt.getCoordinates()
+// );
+// if (dist < closest[wptIndex].distance) {
+// closest[wptIndex].distance = dist;
+// closest[wptIndex].index = [index];
+// } else if (dist === closest[wptIndex].distance) {
+// closest[wptIndex].index.push(index);
+// }
+// });
+// });
+// });
+// });
- file.trk.forEach((track, index) => {
- let newFile = file.clone();
- let tracks = track.trkseg.map((segment, segmentIndex) => {
- let t = track.clone();
- t.replaceTrackSegments(0, track.trkseg.length - 1, [segment]);
- if (track.name) {
- t.name = `${track.name} (${segmentIndex + 1})`;
- }
- return t;
- });
- newFile.replaceTracks(0, file.trk.length - 1, tracks);
- newFile.replaceWaypoints(
- 0,
- file.wpt.length - 1,
- closest
- .filter((c) => c.index.includes(index))
- .map((c) => file.wpt[c.wptIndex])
- );
- newFile._data.id = fileIds[index];
- newFile.metadata.name =
- track.name ?? `${file.metadata.name} (${index + 1})`;
- draft.set(newFile._data.id, freeze(newFile));
- });
- } else if (file.trk.length === 1) {
- let fileIds = getFileIds(file.trk[0].trkseg.length);
+// file.trk.forEach((track, index) => {
+// let newFile = file.clone();
+// let tracks = track.trkseg.map((segment, segmentIndex) => {
+// let t = track.clone();
+// t.replaceTrackSegments(0, track.trkseg.length - 1, [segment]);
+// if (track.name) {
+// t.name = `${track.name} (${segmentIndex + 1})`;
+// }
+// return t;
+// });
+// newFile.replaceTracks(0, file.trk.length - 1, tracks);
+// newFile.replaceWaypoints(
+// 0,
+// file.wpt.length - 1,
+// closest
+// .filter((c) => c.index.includes(index))
+// .map((c) => file.wpt[c.wptIndex])
+// );
+// newFile._data.id = fileIds[index];
+// newFile.metadata.name =
+// track.name ?? `${file.metadata.name} (${index + 1})`;
+// draft.set(newFile._data.id, freeze(newFile));
+// });
+// } else if (file.trk.length === 1) {
+// let fileIds = getFileIds(file.trk[0].trkseg.length);
- let closest = file.wpt.map((wpt, wptIndex) => {
- return {
- wptIndex: wptIndex,
- index: [0],
- distance: Number.MAX_VALUE,
- };
- });
- file.trk[0].trkseg.forEach((segment, index) => {
- segment.trkpt.forEach((point) => {
- file.wpt.forEach((wpt, wptIndex) => {
- let dist = distance(
- point.getCoordinates(),
- wpt.getCoordinates()
- );
- if (dist < closest[wptIndex].distance) {
- closest[wptIndex].distance = dist;
- closest[wptIndex].index = [index];
- } else if (dist === closest[wptIndex].distance) {
- closest[wptIndex].index.push(index);
- }
- });
- });
- });
+// let closest = file.wpt.map((wpt, wptIndex) => {
+// return {
+// wptIndex: wptIndex,
+// index: [0],
+// distance: Number.MAX_VALUE,
+// };
+// });
+// file.trk[0].trkseg.forEach((segment, index) => {
+// segment.trkpt.forEach((point) => {
+// file.wpt.forEach((wpt, wptIndex) => {
+// let dist = distance(
+// point.getCoordinates(),
+// wpt.getCoordinates()
+// );
+// if (dist < closest[wptIndex].distance) {
+// closest[wptIndex].distance = dist;
+// closest[wptIndex].index = [index];
+// } else if (dist === closest[wptIndex].distance) {
+// closest[wptIndex].index.push(index);
+// }
+// });
+// });
+// });
- file.trk[0].trkseg.forEach((segment, index) => {
- let newFile = file.clone();
- newFile.replaceTrackSegments(0, 0, file.trk[0].trkseg.length - 1, [
- segment,
- ]);
- newFile.replaceWaypoints(
- 0,
- file.wpt.length - 1,
- closest
- .filter((c) => c.index.includes(index))
- .map((c) => file.wpt[c.wptIndex])
- );
- newFile._data.id = fileIds[index];
- newFile.metadata.name = `${file.trk[0].name ?? file.metadata.name} (${index + 1})`;
- draft.set(newFile._data.id, freeze(newFile));
- });
- }
- draft.delete(fileId);
- }
- } else if (level === ListLevel.TRACK) {
- let file = draft.get(fileId);
- if (file) {
- for (let item of items) {
- let trackIndex = (item as ListTrackItem).getTrackIndex();
- let track = file.trk[trackIndex];
- let tracks = track.trkseg.map((segment, segmentIndex) => {
- let t = track.clone();
- t.replaceTrackSegments(0, track.trkseg.length - 1, [segment]);
- if (track.name) {
- t.name = `${track.name} (${segmentIndex + 1})`;
- }
- return t;
- });
- file.replaceTracks(trackIndex, trackIndex, tracks);
- }
- }
- }
- });
- });
- },
- split(
- fileId: string,
- trackIndex: number,
- segmentIndex: number,
- coordinates: Coordinates,
- trkptIndex?: number
- ) {
- let splitType = get(splitAs);
- return applyGlobal((draft) => {
- let file = getFile(fileId);
- if (file) {
- let segment = file.trk[trackIndex].trkseg[segmentIndex];
+// file.trk[0].trkseg.forEach((segment, index) => {
+// let newFile = file.clone();
+// newFile.replaceTrackSegments(0, 0, file.trk[0].trkseg.length - 1, [
+// segment,
+// ]);
+// newFile.replaceWaypoints(
+// 0,
+// file.wpt.length - 1,
+// closest
+// .filter((c) => c.index.includes(index))
+// .map((c) => file.wpt[c.wptIndex])
+// );
+// newFile._data.id = fileIds[index];
+// newFile.metadata.name = `${file.trk[0].name ?? file.metadata.name} (${index + 1})`;
+// draft.set(newFile._data.id, freeze(newFile));
+// });
+// }
+// draft.delete(fileId);
+// }
+// } else if (level === ListLevel.TRACK) {
+// let file = draft.get(fileId);
+// if (file) {
+// for (let item of items) {
+// let trackIndex = (item as ListTrackItem).getTrackIndex();
+// let track = file.trk[trackIndex];
+// let tracks = track.trkseg.map((segment, segmentIndex) => {
+// let t = track.clone();
+// t.replaceTrackSegments(0, track.trkseg.length - 1, [segment]);
+// if (track.name) {
+// t.name = `${track.name} (${segmentIndex + 1})`;
+// }
+// return t;
+// });
+// file.replaceTracks(trackIndex, trackIndex, tracks);
+// }
+// }
+// }
+// });
+// });
+// },
+// split(
+// splitType: SplitType,
+// fileId: string,
+// trackIndex: number,
+// segmentIndex: number,
+// coordinates: Coordinates,
+// trkptIndex?: number
+// ) {
+// return applyGlobal((draft) => {
+// let file = getFile(fileId);
+// if (file) {
+// let segment = file.trk[trackIndex].trkseg[segmentIndex];
- let minIndex = 0;
- if (trkptIndex === undefined) {
- // Find the point closest to split
- let closest = getClosestLinePoint(segment.trkpt, coordinates);
- minIndex = closest._data.index;
- } else {
- minIndex = trkptIndex;
- }
+// let minIndex = 0;
+// if (trkptIndex === undefined) {
+// // Find the point closest to split
+// let closest = getClosestLinePoint(segment.trkpt, coordinates);
+// minIndex = closest._data.index;
+// } else {
+// minIndex = trkptIndex;
+// }
- let absoluteIndex = minIndex;
- file.forEachSegment((seg, trkIndex, segIndex) => {
- if (
- (trkIndex < trackIndex && splitType === SplitType.FILES) ||
- (trkIndex === trackIndex && segIndex < segmentIndex)
- ) {
- absoluteIndex += seg.trkpt.length;
- }
- });
+// let absoluteIndex = minIndex;
+// file.forEachSegment((seg, trkIndex, segIndex) => {
+// if (
+// (trkIndex < trackIndex && splitType === SplitType.FILES) ||
+// (trkIndex === trackIndex && segIndex < segmentIndex)
+// ) {
+// absoluteIndex += seg.trkpt.length;
+// }
+// });
- if (splitType === SplitType.FILES) {
- let newFile = draft.get(fileId);
- if (newFile) {
- newFile.crop(0, absoluteIndex);
- let newFile2 = file.clone();
- newFile2._data.id = getFileIds(1)[0];
- newFile2.crop(absoluteIndex, file.getNumberOfTrackPoints() - 1);
- draft.set(newFile2._data.id, freeze(newFile2));
- }
- } else if (splitType === SplitType.TRACKS) {
- let newFile = draft.get(fileId);
- if (newFile) {
- let start = file.trk[trackIndex].clone();
- start.crop(0, absoluteIndex);
- let end = file.trk[trackIndex].clone();
- end.crop(absoluteIndex, file.trk[trackIndex].getNumberOfTrackPoints() - 1);
- newFile.replaceTracks(trackIndex, trackIndex, [start, end]);
- }
- } else if (splitType === SplitType.SEGMENTS) {
- let newFile = draft.get(fileId);
- if (newFile) {
- let start = segment.clone();
- start.crop(0, minIndex);
- let end = segment.clone();
- end.crop(minIndex, segment.trkpt.length - 1);
- newFile.replaceTrackSegments(trackIndex, segmentIndex, segmentIndex, [
- start,
- end,
- ]);
- }
- }
- }
- });
- },
- cleanSelection: (
- bounds: [Coordinates, Coordinates],
- inside: boolean,
- deleteTrackPoints: boolean,
- deleteWaypoints: boolean
- ) => {
- if (get(selection).size === 0) {
- return;
- }
- applyGlobal((draft) => {
- applyToOrderedSelectedItemsFromFile((fileId, level, items) => {
- let file = draft.get(fileId);
- if (file) {
- if (level === ListLevel.FILE) {
- file.clean(bounds, inside, deleteTrackPoints, deleteWaypoints);
- } else if (level === ListLevel.TRACK) {
- let trackIndices = items.map((item) =>
- (item as ListTrackItem).getTrackIndex()
- );
- file.clean(
- bounds,
- inside,
- deleteTrackPoints,
- deleteWaypoints,
- trackIndices
- );
- } else if (level === ListLevel.SEGMENT) {
- let trackIndices = [(items[0] as ListTrackSegmentItem).getTrackIndex()];
- let segmentIndices = items.map((item) =>
- (item as ListTrackSegmentItem).getSegmentIndex()
- );
- file.clean(
- bounds,
- inside,
- deleteTrackPoints,
- deleteWaypoints,
- trackIndices,
- segmentIndices
- );
- } else if (level === ListLevel.WAYPOINTS) {
- file.clean(bounds, inside, false, deleteWaypoints);
- } else if (level === ListLevel.WAYPOINT) {
- let waypointIndices = items.map((item) =>
- (item as ListWaypointItem).getWaypointIndex()
- );
- file.clean(bounds, inside, false, deleteWaypoints, [], [], waypointIndices);
- }
- }
- });
- });
- },
- reduce: (itemsAndPoints: Map) => {
- if (itemsAndPoints.size === 0) {
- return;
- }
- applyGlobal((draft) => {
- let allItems = Array.from(itemsAndPoints.keys());
- applyToOrderedItemsFromFile(allItems, (fileId, level, items) => {
- let file = draft.get(fileId);
- if (file) {
- for (let item of items) {
- if (item instanceof ListTrackSegmentItem) {
- let trackIndex = item.getTrackIndex();
- let segmentIndex = item.getSegmentIndex();
- let points = itemsAndPoints.get(item);
- if (points) {
- file.replaceTrackPoints(
- trackIndex,
- segmentIndex,
- 0,
- file.trk[trackIndex].trkseg[
- segmentIndex
- ].getNumberOfTrackPoints() - 1,
- points
- );
- }
- }
- }
- }
- });
- });
- },
- addOrUpdateWaypoint: (waypoint: WaypointType, item?: ListWaypointItem) => {
- let m = get(map);
- if (m === null) {
- return;
- }
- getElevation([waypoint.attributes]).then((elevation) => {
- if (item) {
- dbUtils.applyToFile(item.getFileId(), (file) => {
- let wpt = file.wpt[item.getWaypointIndex()];
- wpt.name = waypoint.name;
- wpt.desc = waypoint.desc;
- wpt.cmt = waypoint.cmt;
- wpt.sym = waypoint.sym;
- wpt.link = waypoint.link;
- wpt.setCoordinates(waypoint.attributes);
- wpt.ele = elevation[0];
- });
- } else {
- let fileIds = new Set();
- get(selection)
- .getSelected()
- .forEach((item) => {
- fileIds.add(item.getFileId());
- });
- let wpt = new Waypoint(waypoint);
- wpt.ele = elevation[0];
- dbUtils.applyToFiles(Array.from(fileIds), (file) =>
- file.replaceWaypoints(file.wpt.length, file.wpt.length, [wpt])
- );
- }
- });
- },
- setStyleToSelection: (style: LineStyleExtension) => {
- if (get(selection).size === 0) {
- return;
- }
- applyGlobal((draft) => {
- applyToOrderedSelectedItemsFromFile((fileId, level, items) => {
- let file = draft.get(fileId);
- if (file && (level === ListLevel.FILE || level === ListLevel.TRACK)) {
- if (level === ListLevel.FILE) {
- file.setStyle(style);
- } else if (level === ListLevel.TRACK) {
- if (items.length === file.trk.length) {
- file.setStyle(style);
- } else {
- for (let item of items) {
- let trackIndex = (item as ListTrackItem).getTrackIndex();
- file.trk[trackIndex].setStyle(style);
- }
- }
- }
- }
- });
- });
- },
- setHiddenToSelection: (hidden: boolean) => {
- if (get(selection).size === 0) {
- return;
- }
- applyGlobal((draft) => {
- applyToOrderedSelectedItemsFromFile((fileId, level, items) => {
- let file = draft.get(fileId);
- if (file) {
- if (level === ListLevel.FILE) {
- file.setHidden(hidden);
- } else if (level === ListLevel.TRACK) {
- let trackIndices = items.map((item) =>
- (item as ListTrackItem).getTrackIndex()
- );
- file.setHidden(hidden, trackIndices);
- } else if (level === ListLevel.SEGMENT) {
- let trackIndices = [(items[0] as ListTrackSegmentItem).getTrackIndex()];
- let segmentIndices = items.map((item) =>
- (item as ListTrackSegmentItem).getSegmentIndex()
- );
- file.setHidden(hidden, trackIndices, segmentIndices);
- } else if (level === ListLevel.WAYPOINTS) {
- file.setHiddenWaypoints(hidden);
- } else if (level === ListLevel.WAYPOINT) {
- let waypointIndices = items.map((item) =>
- (item as ListWaypointItem).getWaypointIndex()
- );
- file.setHiddenWaypoints(hidden, waypointIndices);
- }
- }
- });
- });
- },
- deleteSelection: () => {
- if (get(selection).size === 0) {
- return;
- }
- applyGlobal((draft) => {
- applyToOrderedSelectedItemsFromFile((fileId, level, items) => {
- if (level === ListLevel.FILE) {
- draft.delete(fileId);
- } else {
- let file = draft.get(fileId);
- if (file) {
- if (level === ListLevel.TRACK) {
- for (let item of items) {
- let trackIndex = (item as ListTrackItem).getTrackIndex();
- file.replaceTracks(trackIndex, trackIndex, []);
- }
- } else if (level === ListLevel.SEGMENT) {
- for (let item of items) {
- let trackIndex = (item as ListTrackSegmentItem).getTrackIndex();
- let segmentIndex = (item as ListTrackSegmentItem).getSegmentIndex();
- file.replaceTrackSegments(
- trackIndex,
- segmentIndex,
- segmentIndex,
- []
- );
- }
- } else if (level === ListLevel.WAYPOINTS) {
- file.replaceWaypoints(0, file.wpt.length - 1, []);
- } else if (level === ListLevel.WAYPOINT) {
- for (let item of items) {
- let waypointIndex = (item as ListWaypointItem).getWaypointIndex();
- file.replaceWaypoints(waypointIndex, waypointIndex, []);
- }
- }
- }
- }
- });
- });
- },
- addElevationToSelection: async (map: mapboxgl.Map) => {
- if (get(selection).size === 0) {
- return;
- }
- let points: (TrackPoint | Waypoint)[] = [];
- applyToOrderedSelectedItemsFromFile((fileId, level, items) => {
- let file = fileState.get(fileId);
- if (file) {
- if (level === ListLevel.FILE) {
- points.push(...file.getTrackPoints());
- points.push(...file.wpt);
- } else if (level === ListLevel.TRACK) {
- let trackIndices = items.map((item) => (item as ListTrackItem).getTrackIndex());
- trackIndices.forEach((trackIndex) => {
- points.push(...file.trk[trackIndex].getTrackPoints());
- });
- } else if (level === ListLevel.SEGMENT) {
- let trackIndex = (items[0] as ListTrackSegmentItem).getTrackIndex();
- let segmentIndices = items.map((item) =>
- (item as ListTrackSegmentItem).getSegmentIndex()
- );
- segmentIndices.forEach((segmentIndex) => {
- points.push(...file.trk[trackIndex].trkseg[segmentIndex].getTrackPoints());
- });
- } else if (level === ListLevel.WAYPOINTS) {
- points.push(...file.wpt);
- } else if (level === ListLevel.WAYPOINT) {
- let waypointIndices = items.map((item) =>
- (item as ListWaypointItem).getWaypointIndex()
- );
- points.push(...waypointIndices.map((waypointIndex) => file.wpt[waypointIndex]));
- }
- }
- });
+// if (splitType === SplitType.FILES) {
+// let newFile = draft.get(fileId);
+// if (newFile) {
+// newFile.crop(0, absoluteIndex);
+// let newFile2 = file.clone();
+// newFile2._data.id = getFileIds(1)[0];
+// newFile2.crop(absoluteIndex, file.getNumberOfTrackPoints() - 1);
+// draft.set(newFile2._data.id, freeze(newFile2));
+// }
+// } else if (splitType === SplitType.TRACKS) {
+// let newFile = draft.get(fileId);
+// if (newFile) {
+// let start = file.trk[trackIndex].clone();
+// start.crop(0, absoluteIndex);
+// let end = file.trk[trackIndex].clone();
+// end.crop(absoluteIndex, file.trk[trackIndex].getNumberOfTrackPoints() - 1);
+// newFile.replaceTracks(trackIndex, trackIndex, [start, end]);
+// }
+// } else if (splitType === SplitType.SEGMENTS) {
+// let newFile = draft.get(fileId);
+// if (newFile) {
+// let start = segment.clone();
+// start.crop(0, minIndex);
+// let end = segment.clone();
+// end.crop(minIndex, segment.trkpt.length - 1);
+// newFile.replaceTrackSegments(trackIndex, segmentIndex, segmentIndex, [
+// start,
+// end,
+// ]);
+// }
+// }
+// }
+// });
+// },
+// cleanSelection: (
+// bounds: [Coordinates, Coordinates],
+// inside: boolean,
+// deleteTrackPoints: boolean,
+// deleteWaypoints: boolean
+// ) => {
+// if (get(selection).size === 0) {
+// return;
+// }
+// applyGlobal((draft) => {
+// applyToOrderedSelectedItemsFromFile((fileId, level, items) => {
+// let file = draft.get(fileId);
+// if (file) {
+// if (level === ListLevel.FILE) {
+// file.clean(bounds, inside, deleteTrackPoints, deleteWaypoints);
+// } else if (level === ListLevel.TRACK) {
+// let trackIndices = items.map((item) =>
+// (item as ListTrackItem).getTrackIndex()
+// );
+// file.clean(
+// bounds,
+// inside,
+// deleteTrackPoints,
+// deleteWaypoints,
+// trackIndices
+// );
+// } else if (level === ListLevel.SEGMENT) {
+// let trackIndices = [(items[0] as ListTrackSegmentItem).getTrackIndex()];
+// let segmentIndices = items.map((item) =>
+// (item as ListTrackSegmentItem).getSegmentIndex()
+// );
+// file.clean(
+// bounds,
+// inside,
+// deleteTrackPoints,
+// deleteWaypoints,
+// trackIndices,
+// segmentIndices
+// );
+// } else if (level === ListLevel.WAYPOINTS) {
+// file.clean(bounds, inside, false, deleteWaypoints);
+// } else if (level === ListLevel.WAYPOINT) {
+// let waypointIndices = items.map((item) =>
+// (item as ListWaypointItem).getWaypointIndex()
+// );
+// file.clean(bounds, inside, false, deleteWaypoints, [], [], waypointIndices);
+// }
+// }
+// });
+// });
+// },
+// reduce: (itemsAndPoints: Map) => {
+// if (itemsAndPoints.size === 0) {
+// return;
+// }
+// applyGlobal((draft) => {
+// let allItems = Array.from(itemsAndPoints.keys());
+// applyToOrderedItemsFromFile(allItems, (fileId, level, items) => {
+// let file = draft.get(fileId);
+// if (file) {
+// for (let item of items) {
+// if (item instanceof ListTrackSegmentItem) {
+// let trackIndex = item.getTrackIndex();
+// let segmentIndex = item.getSegmentIndex();
+// let points = itemsAndPoints.get(item);
+// if (points) {
+// file.replaceTrackPoints(
+// trackIndex,
+// segmentIndex,
+// 0,
+// file.trk[trackIndex].trkseg[
+// segmentIndex
+// ].getNumberOfTrackPoints() - 1,
+// points
+// );
+// }
+// }
+// }
+// }
+// });
+// });
+// },
+// addOrUpdateWaypoint: (waypoint: WaypointType, item?: ListWaypointItem) => {
+// getElevation([waypoint.attributes]).then((elevation) => {
+// if (item) {
+// dbUtils.applyToFile(item.getFileId(), (file) => {
+// let wpt = file.wpt[item.getWaypointIndex()];
+// wpt.name = waypoint.name;
+// wpt.desc = waypoint.desc;
+// wpt.cmt = waypoint.cmt;
+// wpt.sym = waypoint.sym;
+// wpt.link = waypoint.link;
+// wpt.setCoordinates(waypoint.attributes);
+// wpt.ele = elevation[0];
+// });
+// } else {
+// let fileIds = new Set();
+// get(selection)
+// .getSelected()
+// .forEach((item) => {
+// fileIds.add(item.getFileId());
+// });
+// let wpt = new Waypoint(waypoint);
+// wpt.ele = elevation[0];
+// dbUtils.applyToFiles(Array.from(fileIds), (file) =>
+// file.replaceWaypoints(file.wpt.length, file.wpt.length, [wpt])
+// );
+// }
+// });
+// },
+// setStyleToSelection: (style: LineStyleExtension) => {
+// if (get(selection).size === 0) {
+// return;
+// }
+// applyGlobal((draft) => {
+// applyToOrderedSelectedItemsFromFile((fileId, level, items) => {
+// let file = draft.get(fileId);
+// if (file && (level === ListLevel.FILE || level === ListLevel.TRACK)) {
+// if (level === ListLevel.FILE) {
+// file.setStyle(style);
+// } else if (level === ListLevel.TRACK) {
+// if (items.length === file.trk.length) {
+// file.setStyle(style);
+// } else {
+// for (let item of items) {
+// let trackIndex = (item as ListTrackItem).getTrackIndex();
+// file.trk[trackIndex].setStyle(style);
+// }
+// }
+// }
+// }
+// });
+// });
+// },
+// setHiddenToSelection: (hidden: boolean) => {
+// if (get(selection).size === 0) {
+// return;
+// }
+// applyGlobal((draft) => {
+// applyToOrderedSelectedItemsFromFile((fileId, level, items) => {
+// let file = draft.get(fileId);
+// if (file) {
+// if (level === ListLevel.FILE) {
+// file.setHidden(hidden);
+// } else if (level === ListLevel.TRACK) {
+// let trackIndices = items.map((item) =>
+// (item as ListTrackItem).getTrackIndex()
+// );
+// file.setHidden(hidden, trackIndices);
+// } else if (level === ListLevel.SEGMENT) {
+// let trackIndices = [(items[0] as ListTrackSegmentItem).getTrackIndex()];
+// let segmentIndices = items.map((item) =>
+// (item as ListTrackSegmentItem).getSegmentIndex()
+// );
+// file.setHidden(hidden, trackIndices, segmentIndices);
+// } else if (level === ListLevel.WAYPOINTS) {
+// file.setHiddenWaypoints(hidden);
+// } else if (level === ListLevel.WAYPOINT) {
+// let waypointIndices = items.map((item) =>
+// (item as ListWaypointItem).getWaypointIndex()
+// );
+// file.setHiddenWaypoints(hidden, waypointIndices);
+// }
+// }
+// });
+// });
+// },
+// deleteSelection: () => {
+// if (get(selection).size === 0) {
+// return;
+// }
+// applyGlobal((draft) => {
+// applyToOrderedSelectedItemsFromFile((fileId, level, items) => {
+// if (level === ListLevel.FILE) {
+// draft.delete(fileId);
+// } else {
+// let file = draft.get(fileId);
+// if (file) {
+// if (level === ListLevel.TRACK) {
+// for (let item of items) {
+// let trackIndex = (item as ListTrackItem).getTrackIndex();
+// file.replaceTracks(trackIndex, trackIndex, []);
+// }
+// } else if (level === ListLevel.SEGMENT) {
+// for (let item of items) {
+// let trackIndex = (item as ListTrackSegmentItem).getTrackIndex();
+// let segmentIndex = (item as ListTrackSegmentItem).getSegmentIndex();
+// file.replaceTrackSegments(
+// trackIndex,
+// segmentIndex,
+// segmentIndex,
+// []
+// );
+// }
+// } else if (level === ListLevel.WAYPOINTS) {
+// file.replaceWaypoints(0, file.wpt.length - 1, []);
+// } else if (level === ListLevel.WAYPOINT) {
+// for (let item of items) {
+// let waypointIndex = (item as ListWaypointItem).getWaypointIndex();
+// file.replaceWaypoints(waypointIndex, waypointIndex, []);
+// }
+// }
+// }
+// }
+// });
+// });
+// },
+// addElevationToSelection: async (map: mapboxgl.Map) => {
+// if (get(selection).size === 0) {
+// return;
+// }
+// let points: (TrackPoint | Waypoint)[] = [];
+// applyToOrderedSelectedItemsFromFile((fileId, level, items) => {
+// let file = fileState.get(fileId);
+// if (file) {
+// if (level === ListLevel.FILE) {
+// points.push(...file.getTrackPoints());
+// points.push(...file.wpt);
+// } else if (level === ListLevel.TRACK) {
+// let trackIndices = items.map((item) => (item as ListTrackItem).getTrackIndex());
+// trackIndices.forEach((trackIndex) => {
+// points.push(...file.trk[trackIndex].getTrackPoints());
+// });
+// } else if (level === ListLevel.SEGMENT) {
+// let trackIndex = (items[0] as ListTrackSegmentItem).getTrackIndex();
+// let segmentIndices = items.map((item) =>
+// (item as ListTrackSegmentItem).getSegmentIndex()
+// );
+// segmentIndices.forEach((segmentIndex) => {
+// points.push(...file.trk[trackIndex].trkseg[segmentIndex].getTrackPoints());
+// });
+// } else if (level === ListLevel.WAYPOINTS) {
+// points.push(...file.wpt);
+// } else if (level === ListLevel.WAYPOINT) {
+// let waypointIndices = items.map((item) =>
+// (item as ListWaypointItem).getWaypointIndex()
+// );
+// points.push(...waypointIndices.map((waypointIndex) => file.wpt[waypointIndex]));
+// }
+// }
+// });
- if (points.length === 0) {
- return;
- }
+// if (points.length === 0) {
+// return;
+// }
- getElevation(points).then((elevations) => {
- applyGlobal((draft) => {
- applyToOrderedSelectedItemsFromFile((fileId, level, items) => {
- let file = draft.get(fileId);
- if (file) {
- if (level === ListLevel.FILE) {
- file.addElevation(elevations);
- } else if (level === ListLevel.TRACK) {
- let trackIndices = items.map((item) =>
- (item as ListTrackItem).getTrackIndex()
- );
- file.addElevation(elevations, trackIndices, undefined, []);
- } else if (level === ListLevel.SEGMENT) {
- let trackIndices = [(items[0] as ListTrackSegmentItem).getTrackIndex()];
- let segmentIndices = items.map((item) =>
- (item as ListTrackSegmentItem).getSegmentIndex()
- );
- file.addElevation(elevations, trackIndices, segmentIndices, []);
- } else if (level === ListLevel.WAYPOINTS) {
- file.addElevation(elevations, [], [], undefined);
- } else if (level === ListLevel.WAYPOINT) {
- let waypointIndices = items.map((item) =>
- (item as ListWaypointItem).getWaypointIndex()
- );
- file.addElevation(elevations, [], [], waypointIndices);
- }
- }
- });
- });
- });
- },
- deleteSelectedFiles: () => {
- if (get(selection).size === 0) {
- return;
- }
- applyGlobal((draft) => {
- applyToOrderedSelectedItemsFromFile((fileId, level, items) => {
- draft.delete(fileId);
- });
- });
- },
- deleteAllFiles: () => {
- applyGlobal((draft) => {
- draft.clear();
- });
- },
- // undo-redo
- undo: () => {
- if (get(canUndo)) {
- let index = get(patchIndex);
- db.patches.get(index).then((patch) => {
- if (patch) {
- applyPatch(patch.inversePatch);
- db.settings.put(index - 1, 'patchIndex');
- }
- });
- }
- },
- redo: () => {
- if (get(canRedo)) {
- let index = get(patchIndex) + 1;
- db.patches.get(index).then((patch) => {
- if (patch) {
- applyPatch(patch.patch);
- db.settings.put(index, 'patchIndex');
- }
- });
- }
- },
-};
+// getElevation(points).then((elevations) => {
+// applyGlobal((draft) => {
+// applyToOrderedSelectedItemsFromFile((fileId, level, items) => {
+// let file = draft.get(fileId);
+// if (file) {
+// if (level === ListLevel.FILE) {
+// file.addElevation(elevations);
+// } else if (level === ListLevel.TRACK) {
+// let trackIndices = items.map((item) =>
+// (item as ListTrackItem).getTrackIndex()
+// );
+// file.addElevation(elevations, trackIndices, undefined, []);
+// } else if (level === ListLevel.SEGMENT) {
+// let trackIndices = [(items[0] as ListTrackSegmentItem).getTrackIndex()];
+// let segmentIndices = items.map((item) =>
+// (item as ListTrackSegmentItem).getSegmentIndex()
+// );
+// file.addElevation(elevations, trackIndices, segmentIndices, []);
+// } else if (level === ListLevel.WAYPOINTS) {
+// file.addElevation(elevations, [], [], undefined);
+// } else if (level === ListLevel.WAYPOINT) {
+// let waypointIndices = items.map((item) =>
+// (item as ListWaypointItem).getWaypointIndex()
+// );
+// file.addElevation(elevations, [], [], waypointIndices);
+// }
+// }
+// });
+// });
+// });
+// },
+// deleteSelectedFiles: () => {
+// if (get(selection).size === 0) {
+// return;
+// }
+// applyGlobal((draft) => {
+// applyToOrderedSelectedItemsFromFile((fileId, level, items) => {
+// draft.delete(fileId);
+// });
+// });
+// },
+// deleteAllFiles: () => {
+// applyGlobal((draft) => {
+// draft.clear();
+// });
+// },
+// // undo-redo
+// undo: () => {
+// if (get(canUndo)) {
+// let index = get(patchIndex);
+// db.patches.get(index).then((patch) => {
+// if (patch) {
+// applyPatch(patch.inversePatch);
+// db.settings.put(index - 1, 'patchIndex');
+// }
+// });
+// }
+// },
+// redo: () => {
+// if (get(canRedo)) {
+// let index = get(patchIndex) + 1;
+// db.patches.get(index).then((patch) => {
+// if (patch) {
+// applyPatch(patch.patch);
+// db.settings.put(index, 'patchIndex');
+// }
+// });
+// }
+// },
+// };
diff --git a/website/src/lib/docs/be/files-and-stats.mdx b/website/src/lib/docs/be/files-and-stats.mdx
index 19cf4e98..6bad33ea 100644
--- a/website/src/lib/docs/be/files-and-stats.mdx
+++ b/website/src/lib/docs/be/files-and-stats.mdx
@@ -3,7 +3,7 @@ title: Files and statistics
---
# { title }
diff --git a/website/src/lib/docs/be/home/funding.mdx b/website/src/lib/docs/be/home/funding.mdx
index 93c7014f..9ec64d32 100644
--- a/website/src/lib/docs/be/home/funding.mdx
+++ b/website/src/lib/docs/be/home/funding.mdx
@@ -1,5 +1,5 @@
## Help keep the website free (and ad-free)
diff --git a/website/src/lib/docs/be/home/translation.mdx b/website/src/lib/docs/be/home/translation.mdx
index 1299512e..e8ba45f6 100644
--- a/website/src/lib/docs/be/home/translation.mdx
+++ b/website/src/lib/docs/be/home/translation.mdx
@@ -1,5 +1,5 @@
## Translation
diff --git a/website/src/lib/docs/be/map-controls.mdx b/website/src/lib/docs/be/map-controls.mdx
index 8200c4ff..5aa77b9e 100644
--- a/website/src/lib/docs/be/map-controls.mdx
+++ b/website/src/lib/docs/be/map-controls.mdx
@@ -3,7 +3,7 @@ title: Map controls
---
diff --git a/website/src/lib/docs/be/menu/edit.mdx b/website/src/lib/docs/be/menu/edit.mdx
index cbcdd96e..ac0b4e9a 100644
--- a/website/src/lib/docs/be/menu/edit.mdx
+++ b/website/src/lib/docs/be/menu/edit.mdx
@@ -3,7 +3,7 @@ title: Edit actions
---
diff --git a/website/src/lib/docs/be/menu/file.mdx b/website/src/lib/docs/be/menu/file.mdx
index 5ef690e2..ab910a6d 100644
--- a/website/src/lib/docs/be/menu/file.mdx
+++ b/website/src/lib/docs/be/menu/file.mdx
@@ -3,7 +3,7 @@ title: File actions
---
diff --git a/website/src/lib/docs/be/menu/settings.mdx b/website/src/lib/docs/be/menu/settings.mdx
index 8c529729..6fdf26cd 100644
--- a/website/src/lib/docs/be/menu/settings.mdx
+++ b/website/src/lib/docs/be/menu/settings.mdx
@@ -3,7 +3,7 @@ title: Settings
---
diff --git a/website/src/lib/docs/be/menu/view.mdx b/website/src/lib/docs/be/menu/view.mdx
index c7c5b18f..d338e2b7 100644
--- a/website/src/lib/docs/be/menu/view.mdx
+++ b/website/src/lib/docs/be/menu/view.mdx
@@ -3,7 +3,7 @@ title: View options
---
diff --git a/website/src/lib/docs/be/toolbar/clean.mdx b/website/src/lib/docs/be/toolbar/clean.mdx
index e8b8ffc5..5b98149f 100644
--- a/website/src/lib/docs/be/toolbar/clean.mdx
+++ b/website/src/lib/docs/be/toolbar/clean.mdx
@@ -3,7 +3,7 @@ title: Clean
---
diff --git a/website/src/lib/docs/be/toolbar/elevation.mdx b/website/src/lib/docs/be/toolbar/elevation.mdx
index 8fb869d5..3ba9b759 100644
--- a/website/src/lib/docs/be/toolbar/elevation.mdx
+++ b/website/src/lib/docs/be/toolbar/elevation.mdx
@@ -3,7 +3,7 @@ title: Elevation
---
diff --git a/website/src/lib/docs/be/toolbar/extract.mdx b/website/src/lib/docs/be/toolbar/extract.mdx
index 737c451d..a8fd74c5 100644
--- a/website/src/lib/docs/be/toolbar/extract.mdx
+++ b/website/src/lib/docs/be/toolbar/extract.mdx
@@ -3,7 +3,7 @@ title: Extract
---
diff --git a/website/src/lib/docs/be/toolbar/merge.mdx b/website/src/lib/docs/be/toolbar/merge.mdx
index 11ca1f1d..6b0413cd 100644
--- a/website/src/lib/docs/be/toolbar/merge.mdx
+++ b/website/src/lib/docs/be/toolbar/merge.mdx
@@ -3,7 +3,7 @@ title: Merge
---
diff --git a/website/src/lib/docs/be/toolbar/minify.mdx b/website/src/lib/docs/be/toolbar/minify.mdx
index 11b53248..2f50d7c6 100644
--- a/website/src/lib/docs/be/toolbar/minify.mdx
+++ b/website/src/lib/docs/be/toolbar/minify.mdx
@@ -3,12 +3,12 @@ title: Minify
---
-# { title }
+# { title }
This tool can be used to reduce the number of GPS points in a trace, which can be useful for decreasing its size.
diff --git a/website/src/lib/docs/be/toolbar/poi.mdx b/website/src/lib/docs/be/toolbar/poi.mdx
index 6cdc531f..c677df5f 100644
--- a/website/src/lib/docs/be/toolbar/poi.mdx
+++ b/website/src/lib/docs/be/toolbar/poi.mdx
@@ -3,7 +3,7 @@ title: Points of interest
---
diff --git a/website/src/lib/docs/be/toolbar/routing.mdx b/website/src/lib/docs/be/toolbar/routing.mdx
index dfed41da..bdb26d7c 100644
--- a/website/src/lib/docs/be/toolbar/routing.mdx
+++ b/website/src/lib/docs/be/toolbar/routing.mdx
@@ -3,7 +3,7 @@ title: Route planning and editing
---
diff --git a/website/src/lib/docs/be/toolbar/time.mdx b/website/src/lib/docs/be/toolbar/time.mdx
index 4b016114..6e7afcb2 100644
--- a/website/src/lib/docs/be/toolbar/time.mdx
+++ b/website/src/lib/docs/be/toolbar/time.mdx
@@ -3,7 +3,7 @@ title: Time
---
diff --git a/website/src/lib/docs/ca/files-and-stats.mdx b/website/src/lib/docs/ca/files-and-stats.mdx
index 1202b4c8..472a1824 100644
--- a/website/src/lib/docs/ca/files-and-stats.mdx
+++ b/website/src/lib/docs/ca/files-and-stats.mdx
@@ -3,7 +3,7 @@ title: Fitxers i estadístiques
---
# { title }
diff --git a/website/src/lib/docs/ca/home/funding.mdx b/website/src/lib/docs/ca/home/funding.mdx
index cdbc41dc..a13f0ac2 100644
--- a/website/src/lib/docs/ca/home/funding.mdx
+++ b/website/src/lib/docs/ca/home/funding.mdx
@@ -1,5 +1,5 @@
## Ajuda a mantenir aquesta pàgina web gratuïta (i sense anuncis)
diff --git a/website/src/lib/docs/ca/home/translation.mdx b/website/src/lib/docs/ca/home/translation.mdx
index 15eeffba..ff9a7641 100644
--- a/website/src/lib/docs/ca/home/translation.mdx
+++ b/website/src/lib/docs/ca/home/translation.mdx
@@ -1,5 +1,5 @@
## Traducció
diff --git a/website/src/lib/docs/ca/map-controls.mdx b/website/src/lib/docs/ca/map-controls.mdx
index 3c29cecb..a429295b 100644
--- a/website/src/lib/docs/ca/map-controls.mdx
+++ b/website/src/lib/docs/ca/map-controls.mdx
@@ -3,7 +3,7 @@ title: Controls del mapa
---
diff --git a/website/src/lib/docs/ca/menu/edit.mdx b/website/src/lib/docs/ca/menu/edit.mdx
index ae0f5b56..424e1963 100644
--- a/website/src/lib/docs/ca/menu/edit.mdx
+++ b/website/src/lib/docs/ca/menu/edit.mdx
@@ -3,7 +3,7 @@ title: Accions d'edició
---
diff --git a/website/src/lib/docs/ca/menu/file.mdx b/website/src/lib/docs/ca/menu/file.mdx
index 1142580f..baf530a6 100644
--- a/website/src/lib/docs/ca/menu/file.mdx
+++ b/website/src/lib/docs/ca/menu/file.mdx
@@ -3,7 +3,7 @@ title: Accions d'arxiu
---
diff --git a/website/src/lib/docs/ca/menu/settings.mdx b/website/src/lib/docs/ca/menu/settings.mdx
index 7e36dbe4..608e8ff1 100644
--- a/website/src/lib/docs/ca/menu/settings.mdx
+++ b/website/src/lib/docs/ca/menu/settings.mdx
@@ -3,7 +3,7 @@ title: Configuració
---
diff --git a/website/src/lib/docs/ca/menu/view.mdx b/website/src/lib/docs/ca/menu/view.mdx
index 278b53f3..08da7d5d 100644
--- a/website/src/lib/docs/ca/menu/view.mdx
+++ b/website/src/lib/docs/ca/menu/view.mdx
@@ -3,7 +3,7 @@ title: Opcions de vista
---
diff --git a/website/src/lib/docs/ca/toolbar/clean.mdx b/website/src/lib/docs/ca/toolbar/clean.mdx
index 5847fd59..9494d3e1 100644
--- a/website/src/lib/docs/ca/toolbar/clean.mdx
+++ b/website/src/lib/docs/ca/toolbar/clean.mdx
@@ -3,7 +3,7 @@ title: Neteja
---
diff --git a/website/src/lib/docs/ca/toolbar/elevation.mdx b/website/src/lib/docs/ca/toolbar/elevation.mdx
index 69013c4b..dbfe6214 100644
--- a/website/src/lib/docs/ca/toolbar/elevation.mdx
+++ b/website/src/lib/docs/ca/toolbar/elevation.mdx
@@ -3,7 +3,7 @@ title: Elevació
---
diff --git a/website/src/lib/docs/ca/toolbar/extract.mdx b/website/src/lib/docs/ca/toolbar/extract.mdx
index 44dbb01a..d8d47c61 100644
--- a/website/src/lib/docs/ca/toolbar/extract.mdx
+++ b/website/src/lib/docs/ca/toolbar/extract.mdx
@@ -3,7 +3,7 @@ title: Extreu
---
diff --git a/website/src/lib/docs/ca/toolbar/merge.mdx b/website/src/lib/docs/ca/toolbar/merge.mdx
index 49961de5..8f6cf8e8 100644
--- a/website/src/lib/docs/ca/toolbar/merge.mdx
+++ b/website/src/lib/docs/ca/toolbar/merge.mdx
@@ -3,7 +3,7 @@ title: Fusionar
---
diff --git a/website/src/lib/docs/ca/toolbar/minify.mdx b/website/src/lib/docs/ca/toolbar/minify.mdx
index 2ca2a6e7..a1a1e750 100644
--- a/website/src/lib/docs/ca/toolbar/minify.mdx
+++ b/website/src/lib/docs/ca/toolbar/minify.mdx
@@ -3,12 +3,12 @@ title: Minimitzar
---
-# { title }
+# { title }
Aquesta eina es pot utilitzar per reduir el nombre de punts GPS en una traça, cosa que serà útil per disminuir la seva mida.
diff --git a/website/src/lib/docs/ca/toolbar/poi.mdx b/website/src/lib/docs/ca/toolbar/poi.mdx
index 20083c0e..5a6bdf85 100644
--- a/website/src/lib/docs/ca/toolbar/poi.mdx
+++ b/website/src/lib/docs/ca/toolbar/poi.mdx
@@ -3,7 +3,7 @@ title: Punts d'interès
---
diff --git a/website/src/lib/docs/ca/toolbar/routing.mdx b/website/src/lib/docs/ca/toolbar/routing.mdx
index 980986e1..352addc4 100644
--- a/website/src/lib/docs/ca/toolbar/routing.mdx
+++ b/website/src/lib/docs/ca/toolbar/routing.mdx
@@ -3,7 +3,7 @@ title: Planificació i edició de rutes
---
diff --git a/website/src/lib/docs/ca/toolbar/time.mdx b/website/src/lib/docs/ca/toolbar/time.mdx
index aa2b26b7..0bf72c03 100644
--- a/website/src/lib/docs/ca/toolbar/time.mdx
+++ b/website/src/lib/docs/ca/toolbar/time.mdx
@@ -3,7 +3,7 @@ title: Temps
---
diff --git a/website/src/lib/docs/cs/files-and-stats.mdx b/website/src/lib/docs/cs/files-and-stats.mdx
index 65b6fd30..94abca74 100644
--- a/website/src/lib/docs/cs/files-and-stats.mdx
+++ b/website/src/lib/docs/cs/files-and-stats.mdx
@@ -3,7 +3,7 @@ title: Soubory a statistiky
---
# { title }
diff --git a/website/src/lib/docs/cs/home/funding.mdx b/website/src/lib/docs/cs/home/funding.mdx
index 3524ab6a..604bd643 100644
--- a/website/src/lib/docs/cs/home/funding.mdx
+++ b/website/src/lib/docs/cs/home/funding.mdx
@@ -1,5 +1,5 @@
## Pomozte udržet web zdarma (a bez reklam)
diff --git a/website/src/lib/docs/cs/home/translation.mdx b/website/src/lib/docs/cs/home/translation.mdx
index 08003971..184aeb6e 100644
--- a/website/src/lib/docs/cs/home/translation.mdx
+++ b/website/src/lib/docs/cs/home/translation.mdx
@@ -1,5 +1,5 @@
## Překlad
diff --git a/website/src/lib/docs/cs/map-controls.mdx b/website/src/lib/docs/cs/map-controls.mdx
index e2cb9adf..8fece103 100644
--- a/website/src/lib/docs/cs/map-controls.mdx
+++ b/website/src/lib/docs/cs/map-controls.mdx
@@ -3,7 +3,7 @@ title: Ovládací prvky mapy
---
diff --git a/website/src/lib/docs/cs/menu/edit.mdx b/website/src/lib/docs/cs/menu/edit.mdx
index 9ea05f9e..044cdf3c 100644
--- a/website/src/lib/docs/cs/menu/edit.mdx
+++ b/website/src/lib/docs/cs/menu/edit.mdx
@@ -3,7 +3,7 @@ title: Akce úprav
---
diff --git a/website/src/lib/docs/cs/menu/file.mdx b/website/src/lib/docs/cs/menu/file.mdx
index 6120d8f0..4fb0f87b 100644
--- a/website/src/lib/docs/cs/menu/file.mdx
+++ b/website/src/lib/docs/cs/menu/file.mdx
@@ -3,7 +3,7 @@ title: Akce souboru
---
diff --git a/website/src/lib/docs/cs/menu/settings.mdx b/website/src/lib/docs/cs/menu/settings.mdx
index 3dcc6954..789346fb 100644
--- a/website/src/lib/docs/cs/menu/settings.mdx
+++ b/website/src/lib/docs/cs/menu/settings.mdx
@@ -3,7 +3,7 @@ title: Nastavení
---
diff --git a/website/src/lib/docs/cs/menu/view.mdx b/website/src/lib/docs/cs/menu/view.mdx
index 0c24f3c6..cd1a99d9 100644
--- a/website/src/lib/docs/cs/menu/view.mdx
+++ b/website/src/lib/docs/cs/menu/view.mdx
@@ -3,7 +3,7 @@ title: Možnosti zobrazení
---
diff --git a/website/src/lib/docs/cs/toolbar/clean.mdx b/website/src/lib/docs/cs/toolbar/clean.mdx
index d06787e9..a0a2fe5e 100644
--- a/website/src/lib/docs/cs/toolbar/clean.mdx
+++ b/website/src/lib/docs/cs/toolbar/clean.mdx
@@ -3,7 +3,7 @@ title: Vyčistit
---
diff --git a/website/src/lib/docs/cs/toolbar/elevation.mdx b/website/src/lib/docs/cs/toolbar/elevation.mdx
index 655e9e43..61df1f3d 100644
--- a/website/src/lib/docs/cs/toolbar/elevation.mdx
+++ b/website/src/lib/docs/cs/toolbar/elevation.mdx
@@ -3,7 +3,7 @@ title: Nadmořská výška
---
diff --git a/website/src/lib/docs/cs/toolbar/extract.mdx b/website/src/lib/docs/cs/toolbar/extract.mdx
index a0f76532..869cd954 100644
--- a/website/src/lib/docs/cs/toolbar/extract.mdx
+++ b/website/src/lib/docs/cs/toolbar/extract.mdx
@@ -3,7 +3,7 @@ title: Extrahovat
---
diff --git a/website/src/lib/docs/cs/toolbar/merge.mdx b/website/src/lib/docs/cs/toolbar/merge.mdx
index 4e5e4c1e..82121360 100644
--- a/website/src/lib/docs/cs/toolbar/merge.mdx
+++ b/website/src/lib/docs/cs/toolbar/merge.mdx
@@ -3,7 +3,7 @@ title: Sloučit
---
diff --git a/website/src/lib/docs/cs/toolbar/minify.mdx b/website/src/lib/docs/cs/toolbar/minify.mdx
index a3967e4e..ef3ffa50 100644
--- a/website/src/lib/docs/cs/toolbar/minify.mdx
+++ b/website/src/lib/docs/cs/toolbar/minify.mdx
@@ -3,12 +3,12 @@ title: Zjednodušit
---
-# { title }
+# { title }
Tento nástroj lze použít ke snížení počtu GPS bodů v trase, což může být užitečné pro zmenšení její velikosti.
diff --git a/website/src/lib/docs/cs/toolbar/poi.mdx b/website/src/lib/docs/cs/toolbar/poi.mdx
index 825f2579..a33628c6 100644
--- a/website/src/lib/docs/cs/toolbar/poi.mdx
+++ b/website/src/lib/docs/cs/toolbar/poi.mdx
@@ -3,7 +3,7 @@ title: Body zájmu
---
diff --git a/website/src/lib/docs/cs/toolbar/routing.mdx b/website/src/lib/docs/cs/toolbar/routing.mdx
index abee6a15..6df3f62d 100644
--- a/website/src/lib/docs/cs/toolbar/routing.mdx
+++ b/website/src/lib/docs/cs/toolbar/routing.mdx
@@ -3,7 +3,7 @@ title: Plánování a úpravy tras
---
diff --git a/website/src/lib/docs/cs/toolbar/time.mdx b/website/src/lib/docs/cs/toolbar/time.mdx
index 3091b536..5b415602 100644
--- a/website/src/lib/docs/cs/toolbar/time.mdx
+++ b/website/src/lib/docs/cs/toolbar/time.mdx
@@ -3,7 +3,7 @@ title: Čas
---
diff --git a/website/src/lib/docs/da/files-and-stats.mdx b/website/src/lib/docs/da/files-and-stats.mdx
index 19cf4e98..6bad33ea 100644
--- a/website/src/lib/docs/da/files-and-stats.mdx
+++ b/website/src/lib/docs/da/files-and-stats.mdx
@@ -3,7 +3,7 @@ title: Files and statistics
---
# { title }
diff --git a/website/src/lib/docs/da/home/funding.mdx b/website/src/lib/docs/da/home/funding.mdx
index 4b2d7901..98a6acda 100644
--- a/website/src/lib/docs/da/home/funding.mdx
+++ b/website/src/lib/docs/da/home/funding.mdx
@@ -1,5 +1,5 @@
## Help keep the website free (and ad-free)
diff --git a/website/src/lib/docs/da/home/translation.mdx b/website/src/lib/docs/da/home/translation.mdx
index 223c6cff..e1c01741 100644
--- a/website/src/lib/docs/da/home/translation.mdx
+++ b/website/src/lib/docs/da/home/translation.mdx
@@ -1,5 +1,5 @@
## Oversættelse
diff --git a/website/src/lib/docs/da/map-controls.mdx b/website/src/lib/docs/da/map-controls.mdx
index 8eee6884..a880fb51 100644
--- a/website/src/lib/docs/da/map-controls.mdx
+++ b/website/src/lib/docs/da/map-controls.mdx
@@ -3,7 +3,7 @@ title: Map controls
---
diff --git a/website/src/lib/docs/da/menu/edit.mdx b/website/src/lib/docs/da/menu/edit.mdx
index 98181916..e89a1a23 100644
--- a/website/src/lib/docs/da/menu/edit.mdx
+++ b/website/src/lib/docs/da/menu/edit.mdx
@@ -3,7 +3,7 @@ title: Edit actions
---
diff --git a/website/src/lib/docs/da/menu/file.mdx b/website/src/lib/docs/da/menu/file.mdx
index 046179c2..69e10276 100644
--- a/website/src/lib/docs/da/menu/file.mdx
+++ b/website/src/lib/docs/da/menu/file.mdx
@@ -3,7 +3,7 @@ title: File actions
---
diff --git a/website/src/lib/docs/da/menu/settings.mdx b/website/src/lib/docs/da/menu/settings.mdx
index c24fd523..4a05f721 100644
--- a/website/src/lib/docs/da/menu/settings.mdx
+++ b/website/src/lib/docs/da/menu/settings.mdx
@@ -3,7 +3,7 @@ title: Settings
---
diff --git a/website/src/lib/docs/da/menu/view.mdx b/website/src/lib/docs/da/menu/view.mdx
index 0e6ff3f3..84bc48ed 100644
--- a/website/src/lib/docs/da/menu/view.mdx
+++ b/website/src/lib/docs/da/menu/view.mdx
@@ -3,7 +3,7 @@ title: View options
---
diff --git a/website/src/lib/docs/da/toolbar/clean.mdx b/website/src/lib/docs/da/toolbar/clean.mdx
index e8b8ffc5..5b98149f 100644
--- a/website/src/lib/docs/da/toolbar/clean.mdx
+++ b/website/src/lib/docs/da/toolbar/clean.mdx
@@ -3,7 +3,7 @@ title: Clean
---
diff --git a/website/src/lib/docs/da/toolbar/elevation.mdx b/website/src/lib/docs/da/toolbar/elevation.mdx
index 8fb869d5..3ba9b759 100644
--- a/website/src/lib/docs/da/toolbar/elevation.mdx
+++ b/website/src/lib/docs/da/toolbar/elevation.mdx
@@ -3,7 +3,7 @@ title: Elevation
---
diff --git a/website/src/lib/docs/da/toolbar/extract.mdx b/website/src/lib/docs/da/toolbar/extract.mdx
index 737c451d..a8fd74c5 100644
--- a/website/src/lib/docs/da/toolbar/extract.mdx
+++ b/website/src/lib/docs/da/toolbar/extract.mdx
@@ -3,7 +3,7 @@ title: Extract
---
diff --git a/website/src/lib/docs/da/toolbar/merge.mdx b/website/src/lib/docs/da/toolbar/merge.mdx
index 11ca1f1d..6b0413cd 100644
--- a/website/src/lib/docs/da/toolbar/merge.mdx
+++ b/website/src/lib/docs/da/toolbar/merge.mdx
@@ -3,7 +3,7 @@ title: Merge
---
diff --git a/website/src/lib/docs/da/toolbar/minify.mdx b/website/src/lib/docs/da/toolbar/minify.mdx
index 11b53248..2f50d7c6 100644
--- a/website/src/lib/docs/da/toolbar/minify.mdx
+++ b/website/src/lib/docs/da/toolbar/minify.mdx
@@ -3,12 +3,12 @@ title: Minify
---
-# { title }
+# { title }
This tool can be used to reduce the number of GPS points in a trace, which can be useful for decreasing its size.
diff --git a/website/src/lib/docs/da/toolbar/poi.mdx b/website/src/lib/docs/da/toolbar/poi.mdx
index 6cdc531f..c677df5f 100644
--- a/website/src/lib/docs/da/toolbar/poi.mdx
+++ b/website/src/lib/docs/da/toolbar/poi.mdx
@@ -3,7 +3,7 @@ title: Points of interest
---
diff --git a/website/src/lib/docs/da/toolbar/routing.mdx b/website/src/lib/docs/da/toolbar/routing.mdx
index dfed41da..bdb26d7c 100644
--- a/website/src/lib/docs/da/toolbar/routing.mdx
+++ b/website/src/lib/docs/da/toolbar/routing.mdx
@@ -3,7 +3,7 @@ title: Route planning and editing
---
diff --git a/website/src/lib/docs/da/toolbar/time.mdx b/website/src/lib/docs/da/toolbar/time.mdx
index 4b016114..6e7afcb2 100644
--- a/website/src/lib/docs/da/toolbar/time.mdx
+++ b/website/src/lib/docs/da/toolbar/time.mdx
@@ -3,7 +3,7 @@ title: Time
---
diff --git a/website/src/lib/docs/de/files-and-stats.mdx b/website/src/lib/docs/de/files-and-stats.mdx
index f056f739..9250bc9c 100644
--- a/website/src/lib/docs/de/files-and-stats.mdx
+++ b/website/src/lib/docs/de/files-and-stats.mdx
@@ -3,7 +3,7 @@ title: Dateien und Statistiken
---
# { title }
diff --git a/website/src/lib/docs/de/home/funding.mdx b/website/src/lib/docs/de/home/funding.mdx
index b3d4613f..13f675dd 100644
--- a/website/src/lib/docs/de/home/funding.mdx
+++ b/website/src/lib/docs/de/home/funding.mdx
@@ -1,5 +1,5 @@
## Helfen Sie, die Website kostenlos (und werbefrei) zu erhalten
diff --git a/website/src/lib/docs/de/home/translation.mdx b/website/src/lib/docs/de/home/translation.mdx
index 875b0200..a76c67b6 100644
--- a/website/src/lib/docs/de/home/translation.mdx
+++ b/website/src/lib/docs/de/home/translation.mdx
@@ -1,5 +1,5 @@
## Übersetzung
diff --git a/website/src/lib/docs/de/map-controls.mdx b/website/src/lib/docs/de/map-controls.mdx
index 4a225c9b..01a53208 100644
--- a/website/src/lib/docs/de/map-controls.mdx
+++ b/website/src/lib/docs/de/map-controls.mdx
@@ -3,7 +3,7 @@ title: Kartensteuerungen
---
diff --git a/website/src/lib/docs/de/menu/edit.mdx b/website/src/lib/docs/de/menu/edit.mdx
index 6bd083c3..57ee68c6 100644
--- a/website/src/lib/docs/de/menu/edit.mdx
+++ b/website/src/lib/docs/de/menu/edit.mdx
@@ -3,7 +3,7 @@ title: Bearbeite Aktionen
---
diff --git a/website/src/lib/docs/de/menu/file.mdx b/website/src/lib/docs/de/menu/file.mdx
index d555cb31..0212ea2d 100644
--- a/website/src/lib/docs/de/menu/file.mdx
+++ b/website/src/lib/docs/de/menu/file.mdx
@@ -3,7 +3,7 @@ title: Dateiaktionen
---
diff --git a/website/src/lib/docs/de/menu/settings.mdx b/website/src/lib/docs/de/menu/settings.mdx
index a1f632d1..a431265a 100644
--- a/website/src/lib/docs/de/menu/settings.mdx
+++ b/website/src/lib/docs/de/menu/settings.mdx
@@ -3,7 +3,7 @@ title: Einstellungen
---
diff --git a/website/src/lib/docs/de/menu/view.mdx b/website/src/lib/docs/de/menu/view.mdx
index ba7873cb..be2679e9 100644
--- a/website/src/lib/docs/de/menu/view.mdx
+++ b/website/src/lib/docs/de/menu/view.mdx
@@ -3,7 +3,7 @@ title: Anzeigeoptionen
---
diff --git a/website/src/lib/docs/de/toolbar/clean.mdx b/website/src/lib/docs/de/toolbar/clean.mdx
index e918e35d..c7ae4cb5 100644
--- a/website/src/lib/docs/de/toolbar/clean.mdx
+++ b/website/src/lib/docs/de/toolbar/clean.mdx
@@ -3,7 +3,7 @@ title: Bereinigen
---
diff --git a/website/src/lib/docs/de/toolbar/elevation.mdx b/website/src/lib/docs/de/toolbar/elevation.mdx
index 659072d0..9ace7b67 100644
--- a/website/src/lib/docs/de/toolbar/elevation.mdx
+++ b/website/src/lib/docs/de/toolbar/elevation.mdx
@@ -3,7 +3,7 @@ title: Anstieg
---
diff --git a/website/src/lib/docs/de/toolbar/extract.mdx b/website/src/lib/docs/de/toolbar/extract.mdx
index 040f5f95..47f65560 100644
--- a/website/src/lib/docs/de/toolbar/extract.mdx
+++ b/website/src/lib/docs/de/toolbar/extract.mdx
@@ -3,7 +3,7 @@ title: Extrahieren
---
diff --git a/website/src/lib/docs/de/toolbar/merge.mdx b/website/src/lib/docs/de/toolbar/merge.mdx
index e9900699..bec62522 100644
--- a/website/src/lib/docs/de/toolbar/merge.mdx
+++ b/website/src/lib/docs/de/toolbar/merge.mdx
@@ -3,7 +3,7 @@ title: Zusammenfügen
---
diff --git a/website/src/lib/docs/de/toolbar/minify.mdx b/website/src/lib/docs/de/toolbar/minify.mdx
index 9cccc0d4..16bd8093 100644
--- a/website/src/lib/docs/de/toolbar/minify.mdx
+++ b/website/src/lib/docs/de/toolbar/minify.mdx
@@ -3,12 +3,12 @@ title: Minimieren
---
-# { title }
+# { title }
Dieses Tool kann benutzt werden, um die Anzahl der GPS-Punkte in einer Spur zu reduzieren, was nützlich sein kann, um seine Größe zu verringern.
diff --git a/website/src/lib/docs/de/toolbar/poi.mdx b/website/src/lib/docs/de/toolbar/poi.mdx
index d0296892..633de761 100644
--- a/website/src/lib/docs/de/toolbar/poi.mdx
+++ b/website/src/lib/docs/de/toolbar/poi.mdx
@@ -3,7 +3,7 @@ title: Interessante Orte
---
diff --git a/website/src/lib/docs/de/toolbar/routing.mdx b/website/src/lib/docs/de/toolbar/routing.mdx
index bb4cea29..c616df0b 100644
--- a/website/src/lib/docs/de/toolbar/routing.mdx
+++ b/website/src/lib/docs/de/toolbar/routing.mdx
@@ -3,7 +3,7 @@ title: Routenplanung und Bearbeitung
---
diff --git a/website/src/lib/docs/de/toolbar/time.mdx b/website/src/lib/docs/de/toolbar/time.mdx
index dbb78708..fd0cba05 100644
--- a/website/src/lib/docs/de/toolbar/time.mdx
+++ b/website/src/lib/docs/de/toolbar/time.mdx
@@ -3,7 +3,7 @@ title: Zeit
---
diff --git a/website/src/lib/docs/el/files-and-stats.mdx b/website/src/lib/docs/el/files-and-stats.mdx
index 19cf4e98..6bad33ea 100644
--- a/website/src/lib/docs/el/files-and-stats.mdx
+++ b/website/src/lib/docs/el/files-and-stats.mdx
@@ -3,7 +3,7 @@ title: Files and statistics
---
# { title }
diff --git a/website/src/lib/docs/el/home/funding.mdx b/website/src/lib/docs/el/home/funding.mdx
index 93c7014f..9ec64d32 100644
--- a/website/src/lib/docs/el/home/funding.mdx
+++ b/website/src/lib/docs/el/home/funding.mdx
@@ -1,5 +1,5 @@
## Help keep the website free (and ad-free)
diff --git a/website/src/lib/docs/el/home/translation.mdx b/website/src/lib/docs/el/home/translation.mdx
index 1299512e..e8ba45f6 100644
--- a/website/src/lib/docs/el/home/translation.mdx
+++ b/website/src/lib/docs/el/home/translation.mdx
@@ -1,5 +1,5 @@
## Translation
diff --git a/website/src/lib/docs/el/map-controls.mdx b/website/src/lib/docs/el/map-controls.mdx
index 8eee6884..a880fb51 100644
--- a/website/src/lib/docs/el/map-controls.mdx
+++ b/website/src/lib/docs/el/map-controls.mdx
@@ -3,7 +3,7 @@ title: Map controls
---
diff --git a/website/src/lib/docs/el/menu/edit.mdx b/website/src/lib/docs/el/menu/edit.mdx
index cbcdd96e..ac0b4e9a 100644
--- a/website/src/lib/docs/el/menu/edit.mdx
+++ b/website/src/lib/docs/el/menu/edit.mdx
@@ -3,7 +3,7 @@ title: Edit actions
---
diff --git a/website/src/lib/docs/el/menu/file.mdx b/website/src/lib/docs/el/menu/file.mdx
index 5ef690e2..ab910a6d 100644
--- a/website/src/lib/docs/el/menu/file.mdx
+++ b/website/src/lib/docs/el/menu/file.mdx
@@ -3,7 +3,7 @@ title: File actions
---
diff --git a/website/src/lib/docs/el/menu/settings.mdx b/website/src/lib/docs/el/menu/settings.mdx
index 8c529729..6fdf26cd 100644
--- a/website/src/lib/docs/el/menu/settings.mdx
+++ b/website/src/lib/docs/el/menu/settings.mdx
@@ -3,7 +3,7 @@ title: Settings
---
diff --git a/website/src/lib/docs/el/menu/view.mdx b/website/src/lib/docs/el/menu/view.mdx
index 0e6ff3f3..84bc48ed 100644
--- a/website/src/lib/docs/el/menu/view.mdx
+++ b/website/src/lib/docs/el/menu/view.mdx
@@ -3,7 +3,7 @@ title: View options
---
diff --git a/website/src/lib/docs/el/toolbar/clean.mdx b/website/src/lib/docs/el/toolbar/clean.mdx
index e8b8ffc5..5b98149f 100644
--- a/website/src/lib/docs/el/toolbar/clean.mdx
+++ b/website/src/lib/docs/el/toolbar/clean.mdx
@@ -3,7 +3,7 @@ title: Clean
---
diff --git a/website/src/lib/docs/el/toolbar/elevation.mdx b/website/src/lib/docs/el/toolbar/elevation.mdx
index 1f034ffb..2cd6e474 100644
--- a/website/src/lib/docs/el/toolbar/elevation.mdx
+++ b/website/src/lib/docs/el/toolbar/elevation.mdx
@@ -3,7 +3,7 @@ title: Υψόμετρο
---
diff --git a/website/src/lib/docs/el/toolbar/extract.mdx b/website/src/lib/docs/el/toolbar/extract.mdx
index 737c451d..a8fd74c5 100644
--- a/website/src/lib/docs/el/toolbar/extract.mdx
+++ b/website/src/lib/docs/el/toolbar/extract.mdx
@@ -3,7 +3,7 @@ title: Extract
---
diff --git a/website/src/lib/docs/el/toolbar/merge.mdx b/website/src/lib/docs/el/toolbar/merge.mdx
index 11ca1f1d..6b0413cd 100644
--- a/website/src/lib/docs/el/toolbar/merge.mdx
+++ b/website/src/lib/docs/el/toolbar/merge.mdx
@@ -3,7 +3,7 @@ title: Merge
---
diff --git a/website/src/lib/docs/el/toolbar/minify.mdx b/website/src/lib/docs/el/toolbar/minify.mdx
index 11b53248..2f50d7c6 100644
--- a/website/src/lib/docs/el/toolbar/minify.mdx
+++ b/website/src/lib/docs/el/toolbar/minify.mdx
@@ -3,12 +3,12 @@ title: Minify
---
-# { title }
+# { title }
This tool can be used to reduce the number of GPS points in a trace, which can be useful for decreasing its size.
diff --git a/website/src/lib/docs/el/toolbar/poi.mdx b/website/src/lib/docs/el/toolbar/poi.mdx
index 6cdc531f..c677df5f 100644
--- a/website/src/lib/docs/el/toolbar/poi.mdx
+++ b/website/src/lib/docs/el/toolbar/poi.mdx
@@ -3,7 +3,7 @@ title: Points of interest
---
diff --git a/website/src/lib/docs/el/toolbar/routing.mdx b/website/src/lib/docs/el/toolbar/routing.mdx
index dfed41da..bdb26d7c 100644
--- a/website/src/lib/docs/el/toolbar/routing.mdx
+++ b/website/src/lib/docs/el/toolbar/routing.mdx
@@ -3,7 +3,7 @@ title: Route planning and editing
---
diff --git a/website/src/lib/docs/el/toolbar/time.mdx b/website/src/lib/docs/el/toolbar/time.mdx
index 4b016114..6e7afcb2 100644
--- a/website/src/lib/docs/el/toolbar/time.mdx
+++ b/website/src/lib/docs/el/toolbar/time.mdx
@@ -3,7 +3,7 @@ title: Time
---
diff --git a/website/src/lib/docs/en/files-and-stats.mdx b/website/src/lib/docs/en/files-and-stats.mdx
index b645edbd..e42d37e7 100644
--- a/website/src/lib/docs/en/files-and-stats.mdx
+++ b/website/src/lib/docs/en/files-and-stats.mdx
@@ -3,7 +3,7 @@ title: Files and statistics
---
# { title }
diff --git a/website/src/lib/docs/en/home/funding.mdx b/website/src/lib/docs/en/home/funding.mdx
index 03b71030..eaec15b8 100644
--- a/website/src/lib/docs/en/home/funding.mdx
+++ b/website/src/lib/docs/en/home/funding.mdx
@@ -1,5 +1,5 @@
## Help keep the website free (and ad-free)
diff --git a/website/src/lib/docs/en/home/translation.mdx b/website/src/lib/docs/en/home/translation.mdx
index e5f4800c..e7d18ca7 100644
--- a/website/src/lib/docs/en/home/translation.mdx
+++ b/website/src/lib/docs/en/home/translation.mdx
@@ -1,5 +1,5 @@
## Translation
diff --git a/website/src/lib/docs/en/map-controls.mdx b/website/src/lib/docs/en/map-controls.mdx
index 6c6cf9d4..ad34dd62 100644
--- a/website/src/lib/docs/en/map-controls.mdx
+++ b/website/src/lib/docs/en/map-controls.mdx
@@ -3,7 +3,7 @@ title: Map controls
---
diff --git a/website/src/lib/docs/en/menu/edit.mdx b/website/src/lib/docs/en/menu/edit.mdx
index 5a571a0f..77e8ca96 100644
--- a/website/src/lib/docs/en/menu/edit.mdx
+++ b/website/src/lib/docs/en/menu/edit.mdx
@@ -3,7 +3,7 @@ title: Edit actions
---
diff --git a/website/src/lib/docs/en/menu/file.mdx b/website/src/lib/docs/en/menu/file.mdx
index f9128654..141da763 100644
--- a/website/src/lib/docs/en/menu/file.mdx
+++ b/website/src/lib/docs/en/menu/file.mdx
@@ -3,7 +3,7 @@ title: File actions
---
diff --git a/website/src/lib/docs/en/menu/settings.mdx b/website/src/lib/docs/en/menu/settings.mdx
index 2a95081e..142fe601 100644
--- a/website/src/lib/docs/en/menu/settings.mdx
+++ b/website/src/lib/docs/en/menu/settings.mdx
@@ -3,7 +3,7 @@ title: Settings
---
diff --git a/website/src/lib/docs/en/menu/view.mdx b/website/src/lib/docs/en/menu/view.mdx
index 85325319..703815d3 100644
--- a/website/src/lib/docs/en/menu/view.mdx
+++ b/website/src/lib/docs/en/menu/view.mdx
@@ -3,7 +3,7 @@ title: View options
---
diff --git a/website/src/lib/docs/en/toolbar/clean.mdx b/website/src/lib/docs/en/toolbar/clean.mdx
index 0d13ab5c..df35d313 100644
--- a/website/src/lib/docs/en/toolbar/clean.mdx
+++ b/website/src/lib/docs/en/toolbar/clean.mdx
@@ -3,7 +3,7 @@ title: Clean
---
diff --git a/website/src/lib/docs/en/toolbar/elevation.mdx b/website/src/lib/docs/en/toolbar/elevation.mdx
index 09d784e7..e3e5e9f5 100644
--- a/website/src/lib/docs/en/toolbar/elevation.mdx
+++ b/website/src/lib/docs/en/toolbar/elevation.mdx
@@ -3,7 +3,7 @@ title: Elevation
---
diff --git a/website/src/lib/docs/en/toolbar/extract.mdx b/website/src/lib/docs/en/toolbar/extract.mdx
index 8bd1dbbf..f5c83715 100644
--- a/website/src/lib/docs/en/toolbar/extract.mdx
+++ b/website/src/lib/docs/en/toolbar/extract.mdx
@@ -3,7 +3,7 @@ title: Extract
---
diff --git a/website/src/lib/docs/en/toolbar/merge.mdx b/website/src/lib/docs/en/toolbar/merge.mdx
index 6101e59d..051fb26b 100644
--- a/website/src/lib/docs/en/toolbar/merge.mdx
+++ b/website/src/lib/docs/en/toolbar/merge.mdx
@@ -3,7 +3,7 @@ title: Merge
---
diff --git a/website/src/lib/docs/en/toolbar/minify.mdx b/website/src/lib/docs/en/toolbar/minify.mdx
index d8d9e039..7628aa8f 100644
--- a/website/src/lib/docs/en/toolbar/minify.mdx
+++ b/website/src/lib/docs/en/toolbar/minify.mdx
@@ -3,12 +3,12 @@ title: Minify
---
-# { title }
+# { title }
This tool can be used to reduce the number of GPS points in a trace, which can be useful for decreasing its size.
diff --git a/website/src/lib/docs/en/toolbar/poi.mdx b/website/src/lib/docs/en/toolbar/poi.mdx
index b1ad70ab..c7e8b323 100644
--- a/website/src/lib/docs/en/toolbar/poi.mdx
+++ b/website/src/lib/docs/en/toolbar/poi.mdx
@@ -3,7 +3,7 @@ title: Points of interest
---
diff --git a/website/src/lib/docs/en/toolbar/routing.mdx b/website/src/lib/docs/en/toolbar/routing.mdx
index 5aadd6d7..7e15a8fe 100644
--- a/website/src/lib/docs/en/toolbar/routing.mdx
+++ b/website/src/lib/docs/en/toolbar/routing.mdx
@@ -3,7 +3,7 @@ title: Route planning and editing
---
diff --git a/website/src/lib/docs/en/toolbar/time.mdx b/website/src/lib/docs/en/toolbar/time.mdx
index deb57454..67c9999e 100644
--- a/website/src/lib/docs/en/toolbar/time.mdx
+++ b/website/src/lib/docs/en/toolbar/time.mdx
@@ -3,7 +3,7 @@ title: Time
---
diff --git a/website/src/lib/docs/es/files-and-stats.mdx b/website/src/lib/docs/es/files-and-stats.mdx
index 3a8b8d29..e28a5c8c 100644
--- a/website/src/lib/docs/es/files-and-stats.mdx
+++ b/website/src/lib/docs/es/files-and-stats.mdx
@@ -3,7 +3,7 @@ title: Archivos y estadísticas
---
# { title }
diff --git a/website/src/lib/docs/es/home/funding.mdx b/website/src/lib/docs/es/home/funding.mdx
index e96ae5b3..6130a56e 100644
--- a/website/src/lib/docs/es/home/funding.mdx
+++ b/website/src/lib/docs/es/home/funding.mdx
@@ -1,5 +1,5 @@
## Ayude a mantener este sitio gratis (y libre de anuncios)
diff --git a/website/src/lib/docs/es/home/translation.mdx b/website/src/lib/docs/es/home/translation.mdx
index 3cbfcf14..8a5d538e 100644
--- a/website/src/lib/docs/es/home/translation.mdx
+++ b/website/src/lib/docs/es/home/translation.mdx
@@ -1,5 +1,5 @@
## Traducción
diff --git a/website/src/lib/docs/es/map-controls.mdx b/website/src/lib/docs/es/map-controls.mdx
index 5fb1abf4..4c1fb3b2 100644
--- a/website/src/lib/docs/es/map-controls.mdx
+++ b/website/src/lib/docs/es/map-controls.mdx
@@ -3,7 +3,7 @@ title: Controles del mapa
---
diff --git a/website/src/lib/docs/es/menu/edit.mdx b/website/src/lib/docs/es/menu/edit.mdx
index c6ce87fd..39b0de1d 100644
--- a/website/src/lib/docs/es/menu/edit.mdx
+++ b/website/src/lib/docs/es/menu/edit.mdx
@@ -3,7 +3,7 @@ title: Acciones de edición
---
diff --git a/website/src/lib/docs/es/menu/file.mdx b/website/src/lib/docs/es/menu/file.mdx
index 668319d3..7b5f23ec 100644
--- a/website/src/lib/docs/es/menu/file.mdx
+++ b/website/src/lib/docs/es/menu/file.mdx
@@ -3,7 +3,7 @@ title: Acciones de archivo
---
diff --git a/website/src/lib/docs/es/menu/settings.mdx b/website/src/lib/docs/es/menu/settings.mdx
index 1b3caf39..16801ebc 100644
--- a/website/src/lib/docs/es/menu/settings.mdx
+++ b/website/src/lib/docs/es/menu/settings.mdx
@@ -3,7 +3,7 @@ title: Configuración
---
diff --git a/website/src/lib/docs/es/menu/view.mdx b/website/src/lib/docs/es/menu/view.mdx
index de2f73a2..e669652d 100644
--- a/website/src/lib/docs/es/menu/view.mdx
+++ b/website/src/lib/docs/es/menu/view.mdx
@@ -3,7 +3,7 @@ title: Opciones de vista
---
diff --git a/website/src/lib/docs/es/toolbar/clean.mdx b/website/src/lib/docs/es/toolbar/clean.mdx
index aea4a0bf..06127134 100644
--- a/website/src/lib/docs/es/toolbar/clean.mdx
+++ b/website/src/lib/docs/es/toolbar/clean.mdx
@@ -3,7 +3,7 @@ title: Limpiar
---
diff --git a/website/src/lib/docs/es/toolbar/elevation.mdx b/website/src/lib/docs/es/toolbar/elevation.mdx
index 192fcbd8..488242fc 100644
--- a/website/src/lib/docs/es/toolbar/elevation.mdx
+++ b/website/src/lib/docs/es/toolbar/elevation.mdx
@@ -3,7 +3,7 @@ title: Desnivel
---
diff --git a/website/src/lib/docs/es/toolbar/extract.mdx b/website/src/lib/docs/es/toolbar/extract.mdx
index c416f061..6fddcebc 100644
--- a/website/src/lib/docs/es/toolbar/extract.mdx
+++ b/website/src/lib/docs/es/toolbar/extract.mdx
@@ -3,7 +3,7 @@ title: Extracción
---
diff --git a/website/src/lib/docs/es/toolbar/merge.mdx b/website/src/lib/docs/es/toolbar/merge.mdx
index 246ae63f..731e188a 100644
--- a/website/src/lib/docs/es/toolbar/merge.mdx
+++ b/website/src/lib/docs/es/toolbar/merge.mdx
@@ -3,7 +3,7 @@ title: Combinar
---
diff --git a/website/src/lib/docs/es/toolbar/minify.mdx b/website/src/lib/docs/es/toolbar/minify.mdx
index 8fa8da4b..830b6ba8 100644
--- a/website/src/lib/docs/es/toolbar/minify.mdx
+++ b/website/src/lib/docs/es/toolbar/minify.mdx
@@ -3,12 +3,12 @@ title: Minimizar
---
-# { title }
+# { title }
Esta herramienta se puede usar para reducir el número de puntos GPS en un trazado, lo que puede ser útil para reducir su tamaño.
diff --git a/website/src/lib/docs/es/toolbar/poi.mdx b/website/src/lib/docs/es/toolbar/poi.mdx
index c7f8892c..4c3d6d03 100644
--- a/website/src/lib/docs/es/toolbar/poi.mdx
+++ b/website/src/lib/docs/es/toolbar/poi.mdx
@@ -3,7 +3,7 @@ title: Puntos de interés
---
diff --git a/website/src/lib/docs/es/toolbar/routing.mdx b/website/src/lib/docs/es/toolbar/routing.mdx
index 39f364f3..0e9d3dbc 100644
--- a/website/src/lib/docs/es/toolbar/routing.mdx
+++ b/website/src/lib/docs/es/toolbar/routing.mdx
@@ -3,7 +3,7 @@ title: Planificación y edición de rutas
---
diff --git a/website/src/lib/docs/es/toolbar/time.mdx b/website/src/lib/docs/es/toolbar/time.mdx
index 147013e8..a6f015aa 100644
--- a/website/src/lib/docs/es/toolbar/time.mdx
+++ b/website/src/lib/docs/es/toolbar/time.mdx
@@ -3,7 +3,7 @@ title: Tiempo
---
diff --git a/website/src/lib/docs/eu/files-and-stats.mdx b/website/src/lib/docs/eu/files-and-stats.mdx
index 910da3af..ec0a0fb5 100644
--- a/website/src/lib/docs/eu/files-and-stats.mdx
+++ b/website/src/lib/docs/eu/files-and-stats.mdx
@@ -3,7 +3,7 @@ title: Fitxategiak eta estatistikak
---
# { title }
diff --git a/website/src/lib/docs/eu/home/funding.mdx b/website/src/lib/docs/eu/home/funding.mdx
index e1bbf9f7..448abf5b 100644
--- a/website/src/lib/docs/eu/home/funding.mdx
+++ b/website/src/lib/docs/eu/home/funding.mdx
@@ -1,5 +1,5 @@
## Lagundu mantentzen webgunea doan (eta propagandarik gabe)
diff --git a/website/src/lib/docs/eu/home/translation.mdx b/website/src/lib/docs/eu/home/translation.mdx
index 69a68765..d9d0a859 100644
--- a/website/src/lib/docs/eu/home/translation.mdx
+++ b/website/src/lib/docs/eu/home/translation.mdx
@@ -1,5 +1,5 @@
## Itzulpena
diff --git a/website/src/lib/docs/eu/map-controls.mdx b/website/src/lib/docs/eu/map-controls.mdx
index 5063b807..46c47ecc 100644
--- a/website/src/lib/docs/eu/map-controls.mdx
+++ b/website/src/lib/docs/eu/map-controls.mdx
@@ -3,7 +3,7 @@ title: Maparen kontrolak
---
diff --git a/website/src/lib/docs/eu/menu/edit.mdx b/website/src/lib/docs/eu/menu/edit.mdx
index e290a82f..a5c8ddfa 100644
--- a/website/src/lib/docs/eu/menu/edit.mdx
+++ b/website/src/lib/docs/eu/menu/edit.mdx
@@ -3,7 +3,7 @@ title: Edizio ekintzak
---
diff --git a/website/src/lib/docs/eu/menu/file.mdx b/website/src/lib/docs/eu/menu/file.mdx
index 4b99b912..9dc6e379 100644
--- a/website/src/lib/docs/eu/menu/file.mdx
+++ b/website/src/lib/docs/eu/menu/file.mdx
@@ -3,7 +3,7 @@ title: Fitxategi ekintzak
---
diff --git a/website/src/lib/docs/eu/menu/settings.mdx b/website/src/lib/docs/eu/menu/settings.mdx
index 74254a11..6d992d6e 100644
--- a/website/src/lib/docs/eu/menu/settings.mdx
+++ b/website/src/lib/docs/eu/menu/settings.mdx
@@ -3,7 +3,7 @@ title: Ezarpenak
---
diff --git a/website/src/lib/docs/eu/menu/view.mdx b/website/src/lib/docs/eu/menu/view.mdx
index 669d8e7a..e6ab6682 100644
--- a/website/src/lib/docs/eu/menu/view.mdx
+++ b/website/src/lib/docs/eu/menu/view.mdx
@@ -3,7 +3,7 @@ title: Ikusteko aukerak
---
diff --git a/website/src/lib/docs/eu/toolbar/clean.mdx b/website/src/lib/docs/eu/toolbar/clean.mdx
index 49a148ff..b2d31cef 100644
--- a/website/src/lib/docs/eu/toolbar/clean.mdx
+++ b/website/src/lib/docs/eu/toolbar/clean.mdx
@@ -3,7 +3,7 @@ title: Garbitu
---
diff --git a/website/src/lib/docs/eu/toolbar/elevation.mdx b/website/src/lib/docs/eu/toolbar/elevation.mdx
index 1d4bcc54..36dc12c6 100644
--- a/website/src/lib/docs/eu/toolbar/elevation.mdx
+++ b/website/src/lib/docs/eu/toolbar/elevation.mdx
@@ -3,7 +3,7 @@ title: Altuerak
---
diff --git a/website/src/lib/docs/eu/toolbar/extract.mdx b/website/src/lib/docs/eu/toolbar/extract.mdx
index e74595e7..42e992ab 100644
--- a/website/src/lib/docs/eu/toolbar/extract.mdx
+++ b/website/src/lib/docs/eu/toolbar/extract.mdx
@@ -3,7 +3,7 @@ title: Erauzi
---
diff --git a/website/src/lib/docs/eu/toolbar/merge.mdx b/website/src/lib/docs/eu/toolbar/merge.mdx
index 260859c4..29c24006 100644
--- a/website/src/lib/docs/eu/toolbar/merge.mdx
+++ b/website/src/lib/docs/eu/toolbar/merge.mdx
@@ -3,7 +3,7 @@ title: Batu
---
diff --git a/website/src/lib/docs/eu/toolbar/minify.mdx b/website/src/lib/docs/eu/toolbar/minify.mdx
index 23572686..9bef742e 100644
--- a/website/src/lib/docs/eu/toolbar/minify.mdx
+++ b/website/src/lib/docs/eu/toolbar/minify.mdx
@@ -3,12 +3,12 @@ title: Txikiagotu
---
-# { title }
+# { title }
Tresna hau arrasto bateko GPS puntu kopurua murrizteko erabil daiteke, bere tamaina txikitzeko.
diff --git a/website/src/lib/docs/eu/toolbar/poi.mdx b/website/src/lib/docs/eu/toolbar/poi.mdx
index 4973d7d6..96fc5504 100644
--- a/website/src/lib/docs/eu/toolbar/poi.mdx
+++ b/website/src/lib/docs/eu/toolbar/poi.mdx
@@ -3,7 +3,7 @@ title: Interesguneak
---
diff --git a/website/src/lib/docs/eu/toolbar/routing.mdx b/website/src/lib/docs/eu/toolbar/routing.mdx
index d36091ab..a9c25b6b 100644
--- a/website/src/lib/docs/eu/toolbar/routing.mdx
+++ b/website/src/lib/docs/eu/toolbar/routing.mdx
@@ -3,7 +3,7 @@ title: Ibilbideak planifikatzea eta editatzea
---
diff --git a/website/src/lib/docs/eu/toolbar/time.mdx b/website/src/lib/docs/eu/toolbar/time.mdx
index 9e831f33..1973e594 100644
--- a/website/src/lib/docs/eu/toolbar/time.mdx
+++ b/website/src/lib/docs/eu/toolbar/time.mdx
@@ -3,7 +3,7 @@ title: Denbora
---
diff --git a/website/src/lib/docs/fi/files-and-stats.mdx b/website/src/lib/docs/fi/files-and-stats.mdx
index 19cf4e98..6bad33ea 100644
--- a/website/src/lib/docs/fi/files-and-stats.mdx
+++ b/website/src/lib/docs/fi/files-and-stats.mdx
@@ -3,7 +3,7 @@ title: Files and statistics
---
# { title }
diff --git a/website/src/lib/docs/fi/home/funding.mdx b/website/src/lib/docs/fi/home/funding.mdx
index 93c7014f..9ec64d32 100644
--- a/website/src/lib/docs/fi/home/funding.mdx
+++ b/website/src/lib/docs/fi/home/funding.mdx
@@ -1,5 +1,5 @@
## Help keep the website free (and ad-free)
diff --git a/website/src/lib/docs/fi/home/translation.mdx b/website/src/lib/docs/fi/home/translation.mdx
index 1299512e..e8ba45f6 100644
--- a/website/src/lib/docs/fi/home/translation.mdx
+++ b/website/src/lib/docs/fi/home/translation.mdx
@@ -1,5 +1,5 @@
## Translation
diff --git a/website/src/lib/docs/fi/map-controls.mdx b/website/src/lib/docs/fi/map-controls.mdx
index 8eee6884..a880fb51 100644
--- a/website/src/lib/docs/fi/map-controls.mdx
+++ b/website/src/lib/docs/fi/map-controls.mdx
@@ -3,7 +3,7 @@ title: Map controls
---
diff --git a/website/src/lib/docs/fi/menu/edit.mdx b/website/src/lib/docs/fi/menu/edit.mdx
index cbcdd96e..ac0b4e9a 100644
--- a/website/src/lib/docs/fi/menu/edit.mdx
+++ b/website/src/lib/docs/fi/menu/edit.mdx
@@ -3,7 +3,7 @@ title: Edit actions
---
diff --git a/website/src/lib/docs/fi/menu/file.mdx b/website/src/lib/docs/fi/menu/file.mdx
index 5ef690e2..ab910a6d 100644
--- a/website/src/lib/docs/fi/menu/file.mdx
+++ b/website/src/lib/docs/fi/menu/file.mdx
@@ -3,7 +3,7 @@ title: File actions
---
diff --git a/website/src/lib/docs/fi/menu/settings.mdx b/website/src/lib/docs/fi/menu/settings.mdx
index 8c529729..6fdf26cd 100644
--- a/website/src/lib/docs/fi/menu/settings.mdx
+++ b/website/src/lib/docs/fi/menu/settings.mdx
@@ -3,7 +3,7 @@ title: Settings
---
diff --git a/website/src/lib/docs/fi/menu/view.mdx b/website/src/lib/docs/fi/menu/view.mdx
index 0e6ff3f3..84bc48ed 100644
--- a/website/src/lib/docs/fi/menu/view.mdx
+++ b/website/src/lib/docs/fi/menu/view.mdx
@@ -3,7 +3,7 @@ title: View options
---
diff --git a/website/src/lib/docs/fi/toolbar/clean.mdx b/website/src/lib/docs/fi/toolbar/clean.mdx
index e8b8ffc5..5b98149f 100644
--- a/website/src/lib/docs/fi/toolbar/clean.mdx
+++ b/website/src/lib/docs/fi/toolbar/clean.mdx
@@ -3,7 +3,7 @@ title: Clean
---
diff --git a/website/src/lib/docs/fi/toolbar/elevation.mdx b/website/src/lib/docs/fi/toolbar/elevation.mdx
index 8fb869d5..3ba9b759 100644
--- a/website/src/lib/docs/fi/toolbar/elevation.mdx
+++ b/website/src/lib/docs/fi/toolbar/elevation.mdx
@@ -3,7 +3,7 @@ title: Elevation
---
diff --git a/website/src/lib/docs/fi/toolbar/extract.mdx b/website/src/lib/docs/fi/toolbar/extract.mdx
index 737c451d..a8fd74c5 100644
--- a/website/src/lib/docs/fi/toolbar/extract.mdx
+++ b/website/src/lib/docs/fi/toolbar/extract.mdx
@@ -3,7 +3,7 @@ title: Extract
---
diff --git a/website/src/lib/docs/fi/toolbar/merge.mdx b/website/src/lib/docs/fi/toolbar/merge.mdx
index 11ca1f1d..6b0413cd 100644
--- a/website/src/lib/docs/fi/toolbar/merge.mdx
+++ b/website/src/lib/docs/fi/toolbar/merge.mdx
@@ -3,7 +3,7 @@ title: Merge
---
diff --git a/website/src/lib/docs/fi/toolbar/minify.mdx b/website/src/lib/docs/fi/toolbar/minify.mdx
index 11b53248..2f50d7c6 100644
--- a/website/src/lib/docs/fi/toolbar/minify.mdx
+++ b/website/src/lib/docs/fi/toolbar/minify.mdx
@@ -3,12 +3,12 @@ title: Minify
---
-# { title }
+# { title }
This tool can be used to reduce the number of GPS points in a trace, which can be useful for decreasing its size.
diff --git a/website/src/lib/docs/fi/toolbar/poi.mdx b/website/src/lib/docs/fi/toolbar/poi.mdx
index 6cdc531f..c677df5f 100644
--- a/website/src/lib/docs/fi/toolbar/poi.mdx
+++ b/website/src/lib/docs/fi/toolbar/poi.mdx
@@ -3,7 +3,7 @@ title: Points of interest
---
diff --git a/website/src/lib/docs/fi/toolbar/routing.mdx b/website/src/lib/docs/fi/toolbar/routing.mdx
index dfed41da..bdb26d7c 100644
--- a/website/src/lib/docs/fi/toolbar/routing.mdx
+++ b/website/src/lib/docs/fi/toolbar/routing.mdx
@@ -3,7 +3,7 @@ title: Route planning and editing
---
diff --git a/website/src/lib/docs/fi/toolbar/time.mdx b/website/src/lib/docs/fi/toolbar/time.mdx
index 4b016114..6e7afcb2 100644
--- a/website/src/lib/docs/fi/toolbar/time.mdx
+++ b/website/src/lib/docs/fi/toolbar/time.mdx
@@ -3,7 +3,7 @@ title: Time
---
diff --git a/website/src/lib/docs/fr/files-and-stats.mdx b/website/src/lib/docs/fr/files-and-stats.mdx
index 087a0495..4d2d5d56 100644
--- a/website/src/lib/docs/fr/files-and-stats.mdx
+++ b/website/src/lib/docs/fr/files-and-stats.mdx
@@ -3,7 +3,7 @@ title: Fichiers et statistiques
---
# { title }
diff --git a/website/src/lib/docs/fr/home/funding.mdx b/website/src/lib/docs/fr/home/funding.mdx
index 5ae057fb..0ec94b6e 100644
--- a/website/src/lib/docs/fr/home/funding.mdx
+++ b/website/src/lib/docs/fr/home/funding.mdx
@@ -1,5 +1,5 @@
## Aidez à garder le site gratuit (et sans pub)
diff --git a/website/src/lib/docs/fr/home/translation.mdx b/website/src/lib/docs/fr/home/translation.mdx
index 34b92668..54ca4493 100644
--- a/website/src/lib/docs/fr/home/translation.mdx
+++ b/website/src/lib/docs/fr/home/translation.mdx
@@ -1,5 +1,5 @@
## Traduction
diff --git a/website/src/lib/docs/fr/map-controls.mdx b/website/src/lib/docs/fr/map-controls.mdx
index 11eb075d..0085d14b 100644
--- a/website/src/lib/docs/fr/map-controls.mdx
+++ b/website/src/lib/docs/fr/map-controls.mdx
@@ -3,7 +3,7 @@ title: Commandes de la carte
---
diff --git a/website/src/lib/docs/fr/menu/edit.mdx b/website/src/lib/docs/fr/menu/edit.mdx
index 4ad0d25e..598962de 100644
--- a/website/src/lib/docs/fr/menu/edit.mdx
+++ b/website/src/lib/docs/fr/menu/edit.mdx
@@ -3,7 +3,7 @@ title: Actions d'édition
---
diff --git a/website/src/lib/docs/fr/menu/file.mdx b/website/src/lib/docs/fr/menu/file.mdx
index bdf220a0..f6a1a47d 100644
--- a/website/src/lib/docs/fr/menu/file.mdx
+++ b/website/src/lib/docs/fr/menu/file.mdx
@@ -3,7 +3,7 @@ title: Actions sur les fichiers
---
diff --git a/website/src/lib/docs/fr/menu/settings.mdx b/website/src/lib/docs/fr/menu/settings.mdx
index ec0c5ef2..3a282927 100644
--- a/website/src/lib/docs/fr/menu/settings.mdx
+++ b/website/src/lib/docs/fr/menu/settings.mdx
@@ -3,7 +3,7 @@ title: Réglages
---
diff --git a/website/src/lib/docs/fr/menu/view.mdx b/website/src/lib/docs/fr/menu/view.mdx
index 236887d5..476cacb1 100644
--- a/website/src/lib/docs/fr/menu/view.mdx
+++ b/website/src/lib/docs/fr/menu/view.mdx
@@ -3,7 +3,7 @@ title: Options d'affichage
---
diff --git a/website/src/lib/docs/fr/toolbar/clean.mdx b/website/src/lib/docs/fr/toolbar/clean.mdx
index 3646ec96..d978032f 100644
--- a/website/src/lib/docs/fr/toolbar/clean.mdx
+++ b/website/src/lib/docs/fr/toolbar/clean.mdx
@@ -3,7 +3,7 @@ title: Nettoyer
---
diff --git a/website/src/lib/docs/fr/toolbar/elevation.mdx b/website/src/lib/docs/fr/toolbar/elevation.mdx
index 12bf0158..6f8227c6 100644
--- a/website/src/lib/docs/fr/toolbar/elevation.mdx
+++ b/website/src/lib/docs/fr/toolbar/elevation.mdx
@@ -3,7 +3,7 @@ title: Altitude
---
diff --git a/website/src/lib/docs/fr/toolbar/extract.mdx b/website/src/lib/docs/fr/toolbar/extract.mdx
index e547add8..8acac874 100644
--- a/website/src/lib/docs/fr/toolbar/extract.mdx
+++ b/website/src/lib/docs/fr/toolbar/extract.mdx
@@ -3,7 +3,7 @@ title: Extraire
---
diff --git a/website/src/lib/docs/fr/toolbar/merge.mdx b/website/src/lib/docs/fr/toolbar/merge.mdx
index 56959a1a..3162161b 100644
--- a/website/src/lib/docs/fr/toolbar/merge.mdx
+++ b/website/src/lib/docs/fr/toolbar/merge.mdx
@@ -3,7 +3,7 @@ title: Fusionner
---
diff --git a/website/src/lib/docs/fr/toolbar/minify.mdx b/website/src/lib/docs/fr/toolbar/minify.mdx
index c66bebc2..25d06a0d 100644
--- a/website/src/lib/docs/fr/toolbar/minify.mdx
+++ b/website/src/lib/docs/fr/toolbar/minify.mdx
@@ -3,12 +3,12 @@ title: Minifier
---
-# { title }
+# { title }
Cet outil peut être utilisé pour réduire le nombre de points GPS d'une trace, ce qui peut être utile pour réduire sa taille.
diff --git a/website/src/lib/docs/fr/toolbar/poi.mdx b/website/src/lib/docs/fr/toolbar/poi.mdx
index c5ae5ea5..71c36d3d 100644
--- a/website/src/lib/docs/fr/toolbar/poi.mdx
+++ b/website/src/lib/docs/fr/toolbar/poi.mdx
@@ -3,7 +3,7 @@ title: Points d'intérêt
---
diff --git a/website/src/lib/docs/fr/toolbar/routing.mdx b/website/src/lib/docs/fr/toolbar/routing.mdx
index 938105ae..bb3a04a6 100644
--- a/website/src/lib/docs/fr/toolbar/routing.mdx
+++ b/website/src/lib/docs/fr/toolbar/routing.mdx
@@ -3,7 +3,7 @@ title: Planification et édition d'itinéraires
---
diff --git a/website/src/lib/docs/fr/toolbar/time.mdx b/website/src/lib/docs/fr/toolbar/time.mdx
index c6a68c96..b9f5dce6 100644
--- a/website/src/lib/docs/fr/toolbar/time.mdx
+++ b/website/src/lib/docs/fr/toolbar/time.mdx
@@ -3,7 +3,7 @@ title: Temps
---
diff --git a/website/src/lib/docs/he/files-and-stats.mdx b/website/src/lib/docs/he/files-and-stats.mdx
index 19cf4e98..6bad33ea 100644
--- a/website/src/lib/docs/he/files-and-stats.mdx
+++ b/website/src/lib/docs/he/files-and-stats.mdx
@@ -3,7 +3,7 @@ title: Files and statistics
---
# { title }
diff --git a/website/src/lib/docs/he/home/funding.mdx b/website/src/lib/docs/he/home/funding.mdx
index 85930d06..f392a6a0 100644
--- a/website/src/lib/docs/he/home/funding.mdx
+++ b/website/src/lib/docs/he/home/funding.mdx
@@ -1,5 +1,5 @@
## עזור לשמור על אתר זה נקי מפרסומות
diff --git a/website/src/lib/docs/he/home/translation.mdx b/website/src/lib/docs/he/home/translation.mdx
index 1299512e..e8ba45f6 100644
--- a/website/src/lib/docs/he/home/translation.mdx
+++ b/website/src/lib/docs/he/home/translation.mdx
@@ -1,5 +1,5 @@
## Translation
diff --git a/website/src/lib/docs/he/map-controls.mdx b/website/src/lib/docs/he/map-controls.mdx
index 8eee6884..a880fb51 100644
--- a/website/src/lib/docs/he/map-controls.mdx
+++ b/website/src/lib/docs/he/map-controls.mdx
@@ -3,7 +3,7 @@ title: Map controls
---
diff --git a/website/src/lib/docs/he/menu/edit.mdx b/website/src/lib/docs/he/menu/edit.mdx
index cbcdd96e..ac0b4e9a 100644
--- a/website/src/lib/docs/he/menu/edit.mdx
+++ b/website/src/lib/docs/he/menu/edit.mdx
@@ -3,7 +3,7 @@ title: Edit actions
---
diff --git a/website/src/lib/docs/he/menu/file.mdx b/website/src/lib/docs/he/menu/file.mdx
index 5ef690e2..ab910a6d 100644
--- a/website/src/lib/docs/he/menu/file.mdx
+++ b/website/src/lib/docs/he/menu/file.mdx
@@ -3,7 +3,7 @@ title: File actions
---
diff --git a/website/src/lib/docs/he/menu/settings.mdx b/website/src/lib/docs/he/menu/settings.mdx
index 8c529729..6fdf26cd 100644
--- a/website/src/lib/docs/he/menu/settings.mdx
+++ b/website/src/lib/docs/he/menu/settings.mdx
@@ -3,7 +3,7 @@ title: Settings
---
diff --git a/website/src/lib/docs/he/menu/view.mdx b/website/src/lib/docs/he/menu/view.mdx
index 0e6ff3f3..84bc48ed 100644
--- a/website/src/lib/docs/he/menu/view.mdx
+++ b/website/src/lib/docs/he/menu/view.mdx
@@ -3,7 +3,7 @@ title: View options
---
diff --git a/website/src/lib/docs/he/toolbar/clean.mdx b/website/src/lib/docs/he/toolbar/clean.mdx
index e8b8ffc5..5b98149f 100644
--- a/website/src/lib/docs/he/toolbar/clean.mdx
+++ b/website/src/lib/docs/he/toolbar/clean.mdx
@@ -3,7 +3,7 @@ title: Clean
---
diff --git a/website/src/lib/docs/he/toolbar/elevation.mdx b/website/src/lib/docs/he/toolbar/elevation.mdx
index 8fb869d5..3ba9b759 100644
--- a/website/src/lib/docs/he/toolbar/elevation.mdx
+++ b/website/src/lib/docs/he/toolbar/elevation.mdx
@@ -3,7 +3,7 @@ title: Elevation
---
diff --git a/website/src/lib/docs/he/toolbar/extract.mdx b/website/src/lib/docs/he/toolbar/extract.mdx
index 737c451d..a8fd74c5 100644
--- a/website/src/lib/docs/he/toolbar/extract.mdx
+++ b/website/src/lib/docs/he/toolbar/extract.mdx
@@ -3,7 +3,7 @@ title: Extract
---
diff --git a/website/src/lib/docs/he/toolbar/merge.mdx b/website/src/lib/docs/he/toolbar/merge.mdx
index 11ca1f1d..6b0413cd 100644
--- a/website/src/lib/docs/he/toolbar/merge.mdx
+++ b/website/src/lib/docs/he/toolbar/merge.mdx
@@ -3,7 +3,7 @@ title: Merge
---
diff --git a/website/src/lib/docs/he/toolbar/minify.mdx b/website/src/lib/docs/he/toolbar/minify.mdx
index 11b53248..2f50d7c6 100644
--- a/website/src/lib/docs/he/toolbar/minify.mdx
+++ b/website/src/lib/docs/he/toolbar/minify.mdx
@@ -3,12 +3,12 @@ title: Minify
---
-# { title }
+# { title }
This tool can be used to reduce the number of GPS points in a trace, which can be useful for decreasing its size.
diff --git a/website/src/lib/docs/he/toolbar/poi.mdx b/website/src/lib/docs/he/toolbar/poi.mdx
index 6cdc531f..c677df5f 100644
--- a/website/src/lib/docs/he/toolbar/poi.mdx
+++ b/website/src/lib/docs/he/toolbar/poi.mdx
@@ -3,7 +3,7 @@ title: Points of interest
---
diff --git a/website/src/lib/docs/he/toolbar/routing.mdx b/website/src/lib/docs/he/toolbar/routing.mdx
index dfed41da..bdb26d7c 100644
--- a/website/src/lib/docs/he/toolbar/routing.mdx
+++ b/website/src/lib/docs/he/toolbar/routing.mdx
@@ -3,7 +3,7 @@ title: Route planning and editing
---
diff --git a/website/src/lib/docs/he/toolbar/time.mdx b/website/src/lib/docs/he/toolbar/time.mdx
index 4b016114..6e7afcb2 100644
--- a/website/src/lib/docs/he/toolbar/time.mdx
+++ b/website/src/lib/docs/he/toolbar/time.mdx
@@ -3,7 +3,7 @@ title: Time
---
diff --git a/website/src/lib/docs/hu/files-and-stats.mdx b/website/src/lib/docs/hu/files-and-stats.mdx
index c9f87cd6..29486d81 100644
--- a/website/src/lib/docs/hu/files-and-stats.mdx
+++ b/website/src/lib/docs/hu/files-and-stats.mdx
@@ -3,7 +3,7 @@ title: Fájlok és statisztikák
---
# { title }
diff --git a/website/src/lib/docs/hu/home/funding.mdx b/website/src/lib/docs/hu/home/funding.mdx
index 39b8bd09..bdf051af 100644
--- a/website/src/lib/docs/hu/home/funding.mdx
+++ b/website/src/lib/docs/hu/home/funding.mdx
@@ -1,5 +1,5 @@
## Segítsen megőrizni a webhely ingyenességét (és reklám mentességét)
diff --git a/website/src/lib/docs/hu/home/translation.mdx b/website/src/lib/docs/hu/home/translation.mdx
index a3013e7e..91d40893 100644
--- a/website/src/lib/docs/hu/home/translation.mdx
+++ b/website/src/lib/docs/hu/home/translation.mdx
@@ -1,5 +1,5 @@
## Fordítás
diff --git a/website/src/lib/docs/hu/map-controls.mdx b/website/src/lib/docs/hu/map-controls.mdx
index 8cc8a90e..5e038774 100644
--- a/website/src/lib/docs/hu/map-controls.mdx
+++ b/website/src/lib/docs/hu/map-controls.mdx
@@ -3,7 +3,7 @@ title: Térkép vezérlők
---
diff --git a/website/src/lib/docs/hu/menu/edit.mdx b/website/src/lib/docs/hu/menu/edit.mdx
index addb64ec..05b2ee03 100644
--- a/website/src/lib/docs/hu/menu/edit.mdx
+++ b/website/src/lib/docs/hu/menu/edit.mdx
@@ -3,7 +3,7 @@ title: Műveletek szerkesztése
---
diff --git a/website/src/lib/docs/hu/menu/file.mdx b/website/src/lib/docs/hu/menu/file.mdx
index 90c78333..c2c163c2 100644
--- a/website/src/lib/docs/hu/menu/file.mdx
+++ b/website/src/lib/docs/hu/menu/file.mdx
@@ -3,7 +3,7 @@ title: Fájlműveletek
---
diff --git a/website/src/lib/docs/hu/menu/settings.mdx b/website/src/lib/docs/hu/menu/settings.mdx
index 909a6720..319415a3 100644
--- a/website/src/lib/docs/hu/menu/settings.mdx
+++ b/website/src/lib/docs/hu/menu/settings.mdx
@@ -3,7 +3,7 @@ title: Beállítások
---
diff --git a/website/src/lib/docs/hu/menu/view.mdx b/website/src/lib/docs/hu/menu/view.mdx
index bf82a6cb..0d3c7436 100644
--- a/website/src/lib/docs/hu/menu/view.mdx
+++ b/website/src/lib/docs/hu/menu/view.mdx
@@ -3,7 +3,7 @@ title: Nézet beállításai
---
diff --git a/website/src/lib/docs/hu/toolbar/clean.mdx b/website/src/lib/docs/hu/toolbar/clean.mdx
index 06aece66..a5b8206b 100644
--- a/website/src/lib/docs/hu/toolbar/clean.mdx
+++ b/website/src/lib/docs/hu/toolbar/clean.mdx
@@ -3,7 +3,7 @@ title: Tiszta
---
diff --git a/website/src/lib/docs/hu/toolbar/elevation.mdx b/website/src/lib/docs/hu/toolbar/elevation.mdx
index a0e68797..a1776e70 100644
--- a/website/src/lib/docs/hu/toolbar/elevation.mdx
+++ b/website/src/lib/docs/hu/toolbar/elevation.mdx
@@ -3,7 +3,7 @@ title: Emelkedés
---
diff --git a/website/src/lib/docs/hu/toolbar/extract.mdx b/website/src/lib/docs/hu/toolbar/extract.mdx
index 4cc79e9c..f91559d7 100644
--- a/website/src/lib/docs/hu/toolbar/extract.mdx
+++ b/website/src/lib/docs/hu/toolbar/extract.mdx
@@ -3,7 +3,7 @@ title: Kiemelés
---
diff --git a/website/src/lib/docs/hu/toolbar/merge.mdx b/website/src/lib/docs/hu/toolbar/merge.mdx
index 833a9110..0dfe6bca 100644
--- a/website/src/lib/docs/hu/toolbar/merge.mdx
+++ b/website/src/lib/docs/hu/toolbar/merge.mdx
@@ -3,7 +3,7 @@ title: Egyesítés
---
diff --git a/website/src/lib/docs/hu/toolbar/minify.mdx b/website/src/lib/docs/hu/toolbar/minify.mdx
index efc082d1..22f026f2 100644
--- a/website/src/lib/docs/hu/toolbar/minify.mdx
+++ b/website/src/lib/docs/hu/toolbar/minify.mdx
@@ -3,12 +3,12 @@ title: Minimalizálás
---
-# { title }
+# { title }
Ezzel az eszközzel csökkenthető a GPS-pontok száma a nyomkövetésben, ami hasznos lehet a méretének csökkentésében.
diff --git a/website/src/lib/docs/hu/toolbar/poi.mdx b/website/src/lib/docs/hu/toolbar/poi.mdx
index e4bedad0..5eb34170 100644
--- a/website/src/lib/docs/hu/toolbar/poi.mdx
+++ b/website/src/lib/docs/hu/toolbar/poi.mdx
@@ -3,7 +3,7 @@ title: Nevezetes helyek
---
diff --git a/website/src/lib/docs/hu/toolbar/routing.mdx b/website/src/lib/docs/hu/toolbar/routing.mdx
index 44edd4cd..b8f6f7e1 100644
--- a/website/src/lib/docs/hu/toolbar/routing.mdx
+++ b/website/src/lib/docs/hu/toolbar/routing.mdx
@@ -3,7 +3,7 @@ title: Útvonal tervezés és szerkesztés
---
diff --git a/website/src/lib/docs/hu/toolbar/time.mdx b/website/src/lib/docs/hu/toolbar/time.mdx
index 118af426..d64fbcb2 100644
--- a/website/src/lib/docs/hu/toolbar/time.mdx
+++ b/website/src/lib/docs/hu/toolbar/time.mdx
@@ -3,7 +3,7 @@ title: Idő
---
diff --git a/website/src/lib/docs/it/files-and-stats.mdx b/website/src/lib/docs/it/files-and-stats.mdx
index 29d877e7..9d60a93a 100644
--- a/website/src/lib/docs/it/files-and-stats.mdx
+++ b/website/src/lib/docs/it/files-and-stats.mdx
@@ -3,7 +3,7 @@ title: File e statistiche
---
# { title }
diff --git a/website/src/lib/docs/it/home/funding.mdx b/website/src/lib/docs/it/home/funding.mdx
index f7b53239..38235799 100644
--- a/website/src/lib/docs/it/home/funding.mdx
+++ b/website/src/lib/docs/it/home/funding.mdx
@@ -1,5 +1,5 @@
## Aiuta a mantenere il sito gratuito (e senza pubblicità)
diff --git a/website/src/lib/docs/it/home/translation.mdx b/website/src/lib/docs/it/home/translation.mdx
index 204f92ca..2ae61112 100644
--- a/website/src/lib/docs/it/home/translation.mdx
+++ b/website/src/lib/docs/it/home/translation.mdx
@@ -1,5 +1,5 @@
## Traduzione
diff --git a/website/src/lib/docs/it/map-controls.mdx b/website/src/lib/docs/it/map-controls.mdx
index 9f014ce5..7d756c1d 100644
--- a/website/src/lib/docs/it/map-controls.mdx
+++ b/website/src/lib/docs/it/map-controls.mdx
@@ -3,7 +3,7 @@ title: Controlli Mappa
---
diff --git a/website/src/lib/docs/it/menu/edit.mdx b/website/src/lib/docs/it/menu/edit.mdx
index 6041a02c..8a14f27d 100644
--- a/website/src/lib/docs/it/menu/edit.mdx
+++ b/website/src/lib/docs/it/menu/edit.mdx
@@ -3,7 +3,7 @@ title: Azioni di modifica
---
diff --git a/website/src/lib/docs/it/menu/file.mdx b/website/src/lib/docs/it/menu/file.mdx
index aac3869d..a4a9b44d 100644
--- a/website/src/lib/docs/it/menu/file.mdx
+++ b/website/src/lib/docs/it/menu/file.mdx
@@ -3,7 +3,7 @@ title: Azioni sui File
---
diff --git a/website/src/lib/docs/it/menu/settings.mdx b/website/src/lib/docs/it/menu/settings.mdx
index b359bde9..5e05496d 100644
--- a/website/src/lib/docs/it/menu/settings.mdx
+++ b/website/src/lib/docs/it/menu/settings.mdx
@@ -3,7 +3,7 @@ title: Impostazioni
---
diff --git a/website/src/lib/docs/it/menu/view.mdx b/website/src/lib/docs/it/menu/view.mdx
index 79f3b199..feea7d34 100644
--- a/website/src/lib/docs/it/menu/view.mdx
+++ b/website/src/lib/docs/it/menu/view.mdx
@@ -3,7 +3,7 @@ title: Opzioni di visualizzazione
---
diff --git a/website/src/lib/docs/it/toolbar/clean.mdx b/website/src/lib/docs/it/toolbar/clean.mdx
index c251ec3a..7068b2a0 100644
--- a/website/src/lib/docs/it/toolbar/clean.mdx
+++ b/website/src/lib/docs/it/toolbar/clean.mdx
@@ -3,7 +3,7 @@ title: Cancella
---
diff --git a/website/src/lib/docs/it/toolbar/elevation.mdx b/website/src/lib/docs/it/toolbar/elevation.mdx
index ad1f7689..7669213f 100644
--- a/website/src/lib/docs/it/toolbar/elevation.mdx
+++ b/website/src/lib/docs/it/toolbar/elevation.mdx
@@ -3,7 +3,7 @@ title: Dislivello
---
diff --git a/website/src/lib/docs/it/toolbar/extract.mdx b/website/src/lib/docs/it/toolbar/extract.mdx
index f68f603a..d7f6754c 100644
--- a/website/src/lib/docs/it/toolbar/extract.mdx
+++ b/website/src/lib/docs/it/toolbar/extract.mdx
@@ -3,7 +3,7 @@ title: Estrai
---
diff --git a/website/src/lib/docs/it/toolbar/merge.mdx b/website/src/lib/docs/it/toolbar/merge.mdx
index 1ea3ead7..c6905f81 100644
--- a/website/src/lib/docs/it/toolbar/merge.mdx
+++ b/website/src/lib/docs/it/toolbar/merge.mdx
@@ -3,7 +3,7 @@ title: Unisci
---
diff --git a/website/src/lib/docs/it/toolbar/minify.mdx b/website/src/lib/docs/it/toolbar/minify.mdx
index 1949a9f7..6588b7a0 100644
--- a/website/src/lib/docs/it/toolbar/minify.mdx
+++ b/website/src/lib/docs/it/toolbar/minify.mdx
@@ -3,12 +3,12 @@ title: Minimizza
---
-# { title }
+# { title }
Questo strumento può essere utilizzato per ridurre il numero di punti GPS in una traccia, che può essere utile per diminuire la sua dimensione.
diff --git a/website/src/lib/docs/it/toolbar/poi.mdx b/website/src/lib/docs/it/toolbar/poi.mdx
index cbd453b9..9a2a260d 100644
--- a/website/src/lib/docs/it/toolbar/poi.mdx
+++ b/website/src/lib/docs/it/toolbar/poi.mdx
@@ -3,7 +3,7 @@ title: Punti di interesse
---
diff --git a/website/src/lib/docs/it/toolbar/routing.mdx b/website/src/lib/docs/it/toolbar/routing.mdx
index 477a449b..b9ea4dee 100644
--- a/website/src/lib/docs/it/toolbar/routing.mdx
+++ b/website/src/lib/docs/it/toolbar/routing.mdx
@@ -3,7 +3,7 @@ title: Pianificazione e modifica del percorso
---
diff --git a/website/src/lib/docs/it/toolbar/time.mdx b/website/src/lib/docs/it/toolbar/time.mdx
index 2dd57414..0f9080de 100644
--- a/website/src/lib/docs/it/toolbar/time.mdx
+++ b/website/src/lib/docs/it/toolbar/time.mdx
@@ -3,7 +3,7 @@ title: Dati temporali
---
diff --git a/website/src/lib/docs/ko/files-and-stats.mdx b/website/src/lib/docs/ko/files-and-stats.mdx
index 19cf4e98..6bad33ea 100644
--- a/website/src/lib/docs/ko/files-and-stats.mdx
+++ b/website/src/lib/docs/ko/files-and-stats.mdx
@@ -3,7 +3,7 @@ title: Files and statistics
---
# { title }
diff --git a/website/src/lib/docs/ko/home/funding.mdx b/website/src/lib/docs/ko/home/funding.mdx
index 93c7014f..9ec64d32 100644
--- a/website/src/lib/docs/ko/home/funding.mdx
+++ b/website/src/lib/docs/ko/home/funding.mdx
@@ -1,5 +1,5 @@
## Help keep the website free (and ad-free)
diff --git a/website/src/lib/docs/ko/home/translation.mdx b/website/src/lib/docs/ko/home/translation.mdx
index 038e2e34..aa122530 100644
--- a/website/src/lib/docs/ko/home/translation.mdx
+++ b/website/src/lib/docs/ko/home/translation.mdx
@@ -1,5 +1,5 @@
## 번역
diff --git a/website/src/lib/docs/ko/map-controls.mdx b/website/src/lib/docs/ko/map-controls.mdx
index 8eee6884..a880fb51 100644
--- a/website/src/lib/docs/ko/map-controls.mdx
+++ b/website/src/lib/docs/ko/map-controls.mdx
@@ -3,7 +3,7 @@ title: Map controls
---
diff --git a/website/src/lib/docs/ko/menu/edit.mdx b/website/src/lib/docs/ko/menu/edit.mdx
index cbcdd96e..ac0b4e9a 100644
--- a/website/src/lib/docs/ko/menu/edit.mdx
+++ b/website/src/lib/docs/ko/menu/edit.mdx
@@ -3,7 +3,7 @@ title: Edit actions
---
diff --git a/website/src/lib/docs/ko/menu/file.mdx b/website/src/lib/docs/ko/menu/file.mdx
index 5ef690e2..ab910a6d 100644
--- a/website/src/lib/docs/ko/menu/file.mdx
+++ b/website/src/lib/docs/ko/menu/file.mdx
@@ -3,7 +3,7 @@ title: File actions
---
diff --git a/website/src/lib/docs/ko/menu/settings.mdx b/website/src/lib/docs/ko/menu/settings.mdx
index d4e9eabc..5629f64b 100644
--- a/website/src/lib/docs/ko/menu/settings.mdx
+++ b/website/src/lib/docs/ko/menu/settings.mdx
@@ -3,7 +3,7 @@ title: Settings
---
diff --git a/website/src/lib/docs/ko/menu/view.mdx b/website/src/lib/docs/ko/menu/view.mdx
index 0e6ff3f3..84bc48ed 100644
--- a/website/src/lib/docs/ko/menu/view.mdx
+++ b/website/src/lib/docs/ko/menu/view.mdx
@@ -3,7 +3,7 @@ title: View options
---
diff --git a/website/src/lib/docs/ko/toolbar/clean.mdx b/website/src/lib/docs/ko/toolbar/clean.mdx
index e8b8ffc5..5b98149f 100644
--- a/website/src/lib/docs/ko/toolbar/clean.mdx
+++ b/website/src/lib/docs/ko/toolbar/clean.mdx
@@ -3,7 +3,7 @@ title: Clean
---
diff --git a/website/src/lib/docs/ko/toolbar/elevation.mdx b/website/src/lib/docs/ko/toolbar/elevation.mdx
index 79b38d3c..dfcafedf 100644
--- a/website/src/lib/docs/ko/toolbar/elevation.mdx
+++ b/website/src/lib/docs/ko/toolbar/elevation.mdx
@@ -3,7 +3,7 @@ title: 고도
---
diff --git a/website/src/lib/docs/ko/toolbar/extract.mdx b/website/src/lib/docs/ko/toolbar/extract.mdx
index 737c451d..a8fd74c5 100644
--- a/website/src/lib/docs/ko/toolbar/extract.mdx
+++ b/website/src/lib/docs/ko/toolbar/extract.mdx
@@ -3,7 +3,7 @@ title: Extract
---
diff --git a/website/src/lib/docs/ko/toolbar/merge.mdx b/website/src/lib/docs/ko/toolbar/merge.mdx
index 11ca1f1d..6b0413cd 100644
--- a/website/src/lib/docs/ko/toolbar/merge.mdx
+++ b/website/src/lib/docs/ko/toolbar/merge.mdx
@@ -3,7 +3,7 @@ title: Merge
---
diff --git a/website/src/lib/docs/ko/toolbar/minify.mdx b/website/src/lib/docs/ko/toolbar/minify.mdx
index 11b53248..2f50d7c6 100644
--- a/website/src/lib/docs/ko/toolbar/minify.mdx
+++ b/website/src/lib/docs/ko/toolbar/minify.mdx
@@ -3,12 +3,12 @@ title: Minify
---
-# { title }
+# { title }
This tool can be used to reduce the number of GPS points in a trace, which can be useful for decreasing its size.
diff --git a/website/src/lib/docs/ko/toolbar/poi.mdx b/website/src/lib/docs/ko/toolbar/poi.mdx
index 6cdc531f..c677df5f 100644
--- a/website/src/lib/docs/ko/toolbar/poi.mdx
+++ b/website/src/lib/docs/ko/toolbar/poi.mdx
@@ -3,7 +3,7 @@ title: Points of interest
---
diff --git a/website/src/lib/docs/ko/toolbar/routing.mdx b/website/src/lib/docs/ko/toolbar/routing.mdx
index dfed41da..bdb26d7c 100644
--- a/website/src/lib/docs/ko/toolbar/routing.mdx
+++ b/website/src/lib/docs/ko/toolbar/routing.mdx
@@ -3,7 +3,7 @@ title: Route planning and editing
---
diff --git a/website/src/lib/docs/ko/toolbar/time.mdx b/website/src/lib/docs/ko/toolbar/time.mdx
index 4b016114..6e7afcb2 100644
--- a/website/src/lib/docs/ko/toolbar/time.mdx
+++ b/website/src/lib/docs/ko/toolbar/time.mdx
@@ -3,7 +3,7 @@ title: Time
---
diff --git a/website/src/lib/docs/lt/files-and-stats.mdx b/website/src/lib/docs/lt/files-and-stats.mdx
index 0b6846d6..1cba5b65 100644
--- a/website/src/lib/docs/lt/files-and-stats.mdx
+++ b/website/src/lib/docs/lt/files-and-stats.mdx
@@ -3,7 +3,7 @@ title: Puslapis nerastas
---
# { title }
diff --git a/website/src/lib/docs/lt/home/funding.mdx b/website/src/lib/docs/lt/home/funding.mdx
index 93c7014f..9ec64d32 100644
--- a/website/src/lib/docs/lt/home/funding.mdx
+++ b/website/src/lib/docs/lt/home/funding.mdx
@@ -1,5 +1,5 @@
## Help keep the website free (and ad-free)
diff --git a/website/src/lib/docs/lt/home/translation.mdx b/website/src/lib/docs/lt/home/translation.mdx
index 1299512e..e8ba45f6 100644
--- a/website/src/lib/docs/lt/home/translation.mdx
+++ b/website/src/lib/docs/lt/home/translation.mdx
@@ -1,5 +1,5 @@
## Translation
diff --git a/website/src/lib/docs/lt/map-controls.mdx b/website/src/lib/docs/lt/map-controls.mdx
index 8eee6884..a880fb51 100644
--- a/website/src/lib/docs/lt/map-controls.mdx
+++ b/website/src/lib/docs/lt/map-controls.mdx
@@ -3,7 +3,7 @@ title: Map controls
---
diff --git a/website/src/lib/docs/lt/menu/edit.mdx b/website/src/lib/docs/lt/menu/edit.mdx
index cbcdd96e..ac0b4e9a 100644
--- a/website/src/lib/docs/lt/menu/edit.mdx
+++ b/website/src/lib/docs/lt/menu/edit.mdx
@@ -3,7 +3,7 @@ title: Edit actions
---
diff --git a/website/src/lib/docs/lt/menu/file.mdx b/website/src/lib/docs/lt/menu/file.mdx
index 5ef690e2..ab910a6d 100644
--- a/website/src/lib/docs/lt/menu/file.mdx
+++ b/website/src/lib/docs/lt/menu/file.mdx
@@ -3,7 +3,7 @@ title: File actions
---
diff --git a/website/src/lib/docs/lt/menu/settings.mdx b/website/src/lib/docs/lt/menu/settings.mdx
index 8c529729..6fdf26cd 100644
--- a/website/src/lib/docs/lt/menu/settings.mdx
+++ b/website/src/lib/docs/lt/menu/settings.mdx
@@ -3,7 +3,7 @@ title: Settings
---
diff --git a/website/src/lib/docs/lt/menu/view.mdx b/website/src/lib/docs/lt/menu/view.mdx
index 0e6ff3f3..84bc48ed 100644
--- a/website/src/lib/docs/lt/menu/view.mdx
+++ b/website/src/lib/docs/lt/menu/view.mdx
@@ -3,7 +3,7 @@ title: View options
---
diff --git a/website/src/lib/docs/lt/toolbar/clean.mdx b/website/src/lib/docs/lt/toolbar/clean.mdx
index e8b8ffc5..5b98149f 100644
--- a/website/src/lib/docs/lt/toolbar/clean.mdx
+++ b/website/src/lib/docs/lt/toolbar/clean.mdx
@@ -3,7 +3,7 @@ title: Clean
---
diff --git a/website/src/lib/docs/lt/toolbar/elevation.mdx b/website/src/lib/docs/lt/toolbar/elevation.mdx
index 79e96044..14aa8e09 100644
--- a/website/src/lib/docs/lt/toolbar/elevation.mdx
+++ b/website/src/lib/docs/lt/toolbar/elevation.mdx
@@ -3,7 +3,7 @@ title: Aukštis
---
diff --git a/website/src/lib/docs/lt/toolbar/extract.mdx b/website/src/lib/docs/lt/toolbar/extract.mdx
index 737c451d..a8fd74c5 100644
--- a/website/src/lib/docs/lt/toolbar/extract.mdx
+++ b/website/src/lib/docs/lt/toolbar/extract.mdx
@@ -3,7 +3,7 @@ title: Extract
---
diff --git a/website/src/lib/docs/lt/toolbar/merge.mdx b/website/src/lib/docs/lt/toolbar/merge.mdx
index 11ca1f1d..6b0413cd 100644
--- a/website/src/lib/docs/lt/toolbar/merge.mdx
+++ b/website/src/lib/docs/lt/toolbar/merge.mdx
@@ -3,7 +3,7 @@ title: Merge
---
diff --git a/website/src/lib/docs/lt/toolbar/minify.mdx b/website/src/lib/docs/lt/toolbar/minify.mdx
index 11b53248..2f50d7c6 100644
--- a/website/src/lib/docs/lt/toolbar/minify.mdx
+++ b/website/src/lib/docs/lt/toolbar/minify.mdx
@@ -3,12 +3,12 @@ title: Minify
---
-# { title }
+# { title }
This tool can be used to reduce the number of GPS points in a trace, which can be useful for decreasing its size.
diff --git a/website/src/lib/docs/lt/toolbar/poi.mdx b/website/src/lib/docs/lt/toolbar/poi.mdx
index d92f1d95..dcfb9e21 100644
--- a/website/src/lib/docs/lt/toolbar/poi.mdx
+++ b/website/src/lib/docs/lt/toolbar/poi.mdx
@@ -3,7 +3,7 @@ title: Svarbios vietos
---
diff --git a/website/src/lib/docs/lt/toolbar/routing.mdx b/website/src/lib/docs/lt/toolbar/routing.mdx
index dfed41da..bdb26d7c 100644
--- a/website/src/lib/docs/lt/toolbar/routing.mdx
+++ b/website/src/lib/docs/lt/toolbar/routing.mdx
@@ -3,7 +3,7 @@ title: Route planning and editing
---
diff --git a/website/src/lib/docs/lt/toolbar/time.mdx b/website/src/lib/docs/lt/toolbar/time.mdx
index 4b016114..6e7afcb2 100644
--- a/website/src/lib/docs/lt/toolbar/time.mdx
+++ b/website/src/lib/docs/lt/toolbar/time.mdx
@@ -3,7 +3,7 @@ title: Time
---
diff --git a/website/src/lib/docs/lv/files-and-stats.mdx b/website/src/lib/docs/lv/files-and-stats.mdx
index 19cf4e98..6bad33ea 100644
--- a/website/src/lib/docs/lv/files-and-stats.mdx
+++ b/website/src/lib/docs/lv/files-and-stats.mdx
@@ -3,7 +3,7 @@ title: Files and statistics
---
# { title }
diff --git a/website/src/lib/docs/lv/home/funding.mdx b/website/src/lib/docs/lv/home/funding.mdx
index 7d0a003f..abefcbb2 100644
--- a/website/src/lib/docs/lv/home/funding.mdx
+++ b/website/src/lib/docs/lv/home/funding.mdx
@@ -1,5 +1,5 @@
## Help keep the website free (and ad-free)
diff --git a/website/src/lib/docs/lv/home/translation.mdx b/website/src/lib/docs/lv/home/translation.mdx
index 06248df0..b2b058f7 100644
--- a/website/src/lib/docs/lv/home/translation.mdx
+++ b/website/src/lib/docs/lv/home/translation.mdx
@@ -1,5 +1,5 @@
## Tulkojums
diff --git a/website/src/lib/docs/lv/map-controls.mdx b/website/src/lib/docs/lv/map-controls.mdx
index 8eee6884..a880fb51 100644
--- a/website/src/lib/docs/lv/map-controls.mdx
+++ b/website/src/lib/docs/lv/map-controls.mdx
@@ -3,7 +3,7 @@ title: Map controls
---
diff --git a/website/src/lib/docs/lv/menu/edit.mdx b/website/src/lib/docs/lv/menu/edit.mdx
index cbcdd96e..ac0b4e9a 100644
--- a/website/src/lib/docs/lv/menu/edit.mdx
+++ b/website/src/lib/docs/lv/menu/edit.mdx
@@ -3,7 +3,7 @@ title: Edit actions
---
diff --git a/website/src/lib/docs/lv/menu/file.mdx b/website/src/lib/docs/lv/menu/file.mdx
index 5ef690e2..ab910a6d 100644
--- a/website/src/lib/docs/lv/menu/file.mdx
+++ b/website/src/lib/docs/lv/menu/file.mdx
@@ -3,7 +3,7 @@ title: File actions
---
diff --git a/website/src/lib/docs/lv/menu/settings.mdx b/website/src/lib/docs/lv/menu/settings.mdx
index 8c529729..6fdf26cd 100644
--- a/website/src/lib/docs/lv/menu/settings.mdx
+++ b/website/src/lib/docs/lv/menu/settings.mdx
@@ -3,7 +3,7 @@ title: Settings
---
diff --git a/website/src/lib/docs/lv/menu/view.mdx b/website/src/lib/docs/lv/menu/view.mdx
index 0e6ff3f3..84bc48ed 100644
--- a/website/src/lib/docs/lv/menu/view.mdx
+++ b/website/src/lib/docs/lv/menu/view.mdx
@@ -3,7 +3,7 @@ title: View options
---
diff --git a/website/src/lib/docs/lv/toolbar/clean.mdx b/website/src/lib/docs/lv/toolbar/clean.mdx
index e8b8ffc5..5b98149f 100644
--- a/website/src/lib/docs/lv/toolbar/clean.mdx
+++ b/website/src/lib/docs/lv/toolbar/clean.mdx
@@ -3,7 +3,7 @@ title: Clean
---
diff --git a/website/src/lib/docs/lv/toolbar/elevation.mdx b/website/src/lib/docs/lv/toolbar/elevation.mdx
index 8fb869d5..3ba9b759 100644
--- a/website/src/lib/docs/lv/toolbar/elevation.mdx
+++ b/website/src/lib/docs/lv/toolbar/elevation.mdx
@@ -3,7 +3,7 @@ title: Elevation
---
diff --git a/website/src/lib/docs/lv/toolbar/extract.mdx b/website/src/lib/docs/lv/toolbar/extract.mdx
index 737c451d..a8fd74c5 100644
--- a/website/src/lib/docs/lv/toolbar/extract.mdx
+++ b/website/src/lib/docs/lv/toolbar/extract.mdx
@@ -3,7 +3,7 @@ title: Extract
---
diff --git a/website/src/lib/docs/lv/toolbar/merge.mdx b/website/src/lib/docs/lv/toolbar/merge.mdx
index 11ca1f1d..6b0413cd 100644
--- a/website/src/lib/docs/lv/toolbar/merge.mdx
+++ b/website/src/lib/docs/lv/toolbar/merge.mdx
@@ -3,7 +3,7 @@ title: Merge
---
diff --git a/website/src/lib/docs/lv/toolbar/minify.mdx b/website/src/lib/docs/lv/toolbar/minify.mdx
index 11b53248..2f50d7c6 100644
--- a/website/src/lib/docs/lv/toolbar/minify.mdx
+++ b/website/src/lib/docs/lv/toolbar/minify.mdx
@@ -3,12 +3,12 @@ title: Minify
---
-# { title }
+# { title }
This tool can be used to reduce the number of GPS points in a trace, which can be useful for decreasing its size.
diff --git a/website/src/lib/docs/lv/toolbar/poi.mdx b/website/src/lib/docs/lv/toolbar/poi.mdx
index 6cdc531f..c677df5f 100644
--- a/website/src/lib/docs/lv/toolbar/poi.mdx
+++ b/website/src/lib/docs/lv/toolbar/poi.mdx
@@ -3,7 +3,7 @@ title: Points of interest
---
diff --git a/website/src/lib/docs/lv/toolbar/routing.mdx b/website/src/lib/docs/lv/toolbar/routing.mdx
index dfed41da..bdb26d7c 100644
--- a/website/src/lib/docs/lv/toolbar/routing.mdx
+++ b/website/src/lib/docs/lv/toolbar/routing.mdx
@@ -3,7 +3,7 @@ title: Route planning and editing
---
diff --git a/website/src/lib/docs/lv/toolbar/time.mdx b/website/src/lib/docs/lv/toolbar/time.mdx
index 84aa1b36..c75e45ae 100644
--- a/website/src/lib/docs/lv/toolbar/time.mdx
+++ b/website/src/lib/docs/lv/toolbar/time.mdx
@@ -3,7 +3,7 @@ title: Laiks
---
diff --git a/website/src/lib/docs/nl/files-and-stats.mdx b/website/src/lib/docs/nl/files-and-stats.mdx
index 0b92ee61..f763e19d 100644
--- a/website/src/lib/docs/nl/files-and-stats.mdx
+++ b/website/src/lib/docs/nl/files-and-stats.mdx
@@ -3,7 +3,7 @@ title: Bestanden en statistieken
---
# { title }
diff --git a/website/src/lib/docs/nl/home/funding.mdx b/website/src/lib/docs/nl/home/funding.mdx
index efa36cd8..2abb807e 100644
--- a/website/src/lib/docs/nl/home/funding.mdx
+++ b/website/src/lib/docs/nl/home/funding.mdx
@@ -1,5 +1,5 @@
## Help de website gratis te houden (en advertentievrij)
diff --git a/website/src/lib/docs/nl/home/translation.mdx b/website/src/lib/docs/nl/home/translation.mdx
index 6c92a9c5..5d7287c0 100644
--- a/website/src/lib/docs/nl/home/translation.mdx
+++ b/website/src/lib/docs/nl/home/translation.mdx
@@ -1,5 +1,5 @@
## Vertaling
diff --git a/website/src/lib/docs/nl/map-controls.mdx b/website/src/lib/docs/nl/map-controls.mdx
index 0cc30db2..c6cbd396 100644
--- a/website/src/lib/docs/nl/map-controls.mdx
+++ b/website/src/lib/docs/nl/map-controls.mdx
@@ -3,7 +3,7 @@ title: Kaart beheer
---
diff --git a/website/src/lib/docs/nl/menu/edit.mdx b/website/src/lib/docs/nl/menu/edit.mdx
index c82549bc..4440b2f4 100644
--- a/website/src/lib/docs/nl/menu/edit.mdx
+++ b/website/src/lib/docs/nl/menu/edit.mdx
@@ -3,7 +3,7 @@ title: Bewerkingen
---
diff --git a/website/src/lib/docs/nl/menu/file.mdx b/website/src/lib/docs/nl/menu/file.mdx
index 0c6a87f7..2093279c 100644
--- a/website/src/lib/docs/nl/menu/file.mdx
+++ b/website/src/lib/docs/nl/menu/file.mdx
@@ -3,7 +3,7 @@ title: Bestandsbewerkingen
---
diff --git a/website/src/lib/docs/nl/menu/settings.mdx b/website/src/lib/docs/nl/menu/settings.mdx
index f9b10f6a..aa87e25f 100644
--- a/website/src/lib/docs/nl/menu/settings.mdx
+++ b/website/src/lib/docs/nl/menu/settings.mdx
@@ -3,7 +3,7 @@ title: Instellingen
---
diff --git a/website/src/lib/docs/nl/menu/view.mdx b/website/src/lib/docs/nl/menu/view.mdx
index 92ecad31..fd93e41c 100644
--- a/website/src/lib/docs/nl/menu/view.mdx
+++ b/website/src/lib/docs/nl/menu/view.mdx
@@ -3,7 +3,7 @@ title: Bekijk opties
---
diff --git a/website/src/lib/docs/nl/toolbar/clean.mdx b/website/src/lib/docs/nl/toolbar/clean.mdx
index bad5750b..2fed563f 100644
--- a/website/src/lib/docs/nl/toolbar/clean.mdx
+++ b/website/src/lib/docs/nl/toolbar/clean.mdx
@@ -3,7 +3,7 @@ title: Opruimen
---
diff --git a/website/src/lib/docs/nl/toolbar/elevation.mdx b/website/src/lib/docs/nl/toolbar/elevation.mdx
index 67248d65..16a72cd9 100644
--- a/website/src/lib/docs/nl/toolbar/elevation.mdx
+++ b/website/src/lib/docs/nl/toolbar/elevation.mdx
@@ -3,7 +3,7 @@ title: Stijging
---
diff --git a/website/src/lib/docs/nl/toolbar/extract.mdx b/website/src/lib/docs/nl/toolbar/extract.mdx
index 9554fc71..d1495fd0 100644
--- a/website/src/lib/docs/nl/toolbar/extract.mdx
+++ b/website/src/lib/docs/nl/toolbar/extract.mdx
@@ -3,7 +3,7 @@ title: Uitpakken
---
diff --git a/website/src/lib/docs/nl/toolbar/merge.mdx b/website/src/lib/docs/nl/toolbar/merge.mdx
index 0ac7e8fd..d3f4edd3 100644
--- a/website/src/lib/docs/nl/toolbar/merge.mdx
+++ b/website/src/lib/docs/nl/toolbar/merge.mdx
@@ -3,7 +3,7 @@ title: Samenvoegen
---
diff --git a/website/src/lib/docs/nl/toolbar/minify.mdx b/website/src/lib/docs/nl/toolbar/minify.mdx
index ec9a1891..1994a51c 100644
--- a/website/src/lib/docs/nl/toolbar/minify.mdx
+++ b/website/src/lib/docs/nl/toolbar/minify.mdx
@@ -3,12 +3,12 @@ title: Verkleinen
---
-# { title }
+# { title }
Dit gereedschap kan worden gebruikt om het aantal GPS-punten in een spoor te verminderen, wat nuttig kan zijn om de grootte te verminderen.
diff --git a/website/src/lib/docs/nl/toolbar/poi.mdx b/website/src/lib/docs/nl/toolbar/poi.mdx
index 838ca5f3..36f28b7a 100644
--- a/website/src/lib/docs/nl/toolbar/poi.mdx
+++ b/website/src/lib/docs/nl/toolbar/poi.mdx
@@ -3,7 +3,7 @@ title: Interessante punten (POI's)
---
diff --git a/website/src/lib/docs/nl/toolbar/routing.mdx b/website/src/lib/docs/nl/toolbar/routing.mdx
index e9ad79a7..b2d3a19f 100644
--- a/website/src/lib/docs/nl/toolbar/routing.mdx
+++ b/website/src/lib/docs/nl/toolbar/routing.mdx
@@ -3,7 +3,7 @@ title: Routeplanning en -bewerking
---
diff --git a/website/src/lib/docs/nl/toolbar/time.mdx b/website/src/lib/docs/nl/toolbar/time.mdx
index f4548baa..a7c1699a 100644
--- a/website/src/lib/docs/nl/toolbar/time.mdx
+++ b/website/src/lib/docs/nl/toolbar/time.mdx
@@ -3,7 +3,7 @@ title: Tijd
---
diff --git a/website/src/lib/docs/no/files-and-stats.mdx b/website/src/lib/docs/no/files-and-stats.mdx
index 19cf4e98..6bad33ea 100644
--- a/website/src/lib/docs/no/files-and-stats.mdx
+++ b/website/src/lib/docs/no/files-and-stats.mdx
@@ -3,7 +3,7 @@ title: Files and statistics
---
# { title }
diff --git a/website/src/lib/docs/no/home/funding.mdx b/website/src/lib/docs/no/home/funding.mdx
index 93c7014f..9ec64d32 100644
--- a/website/src/lib/docs/no/home/funding.mdx
+++ b/website/src/lib/docs/no/home/funding.mdx
@@ -1,5 +1,5 @@
## Help keep the website free (and ad-free)
diff --git a/website/src/lib/docs/no/home/translation.mdx b/website/src/lib/docs/no/home/translation.mdx
index 540a47e3..62d10cf6 100644
--- a/website/src/lib/docs/no/home/translation.mdx
+++ b/website/src/lib/docs/no/home/translation.mdx
@@ -1,5 +1,5 @@
## Translation
diff --git a/website/src/lib/docs/no/map-controls.mdx b/website/src/lib/docs/no/map-controls.mdx
index 8eee6884..a880fb51 100644
--- a/website/src/lib/docs/no/map-controls.mdx
+++ b/website/src/lib/docs/no/map-controls.mdx
@@ -3,7 +3,7 @@ title: Map controls
---
diff --git a/website/src/lib/docs/no/menu/edit.mdx b/website/src/lib/docs/no/menu/edit.mdx
index cbcdd96e..ac0b4e9a 100644
--- a/website/src/lib/docs/no/menu/edit.mdx
+++ b/website/src/lib/docs/no/menu/edit.mdx
@@ -3,7 +3,7 @@ title: Edit actions
---
diff --git a/website/src/lib/docs/no/menu/file.mdx b/website/src/lib/docs/no/menu/file.mdx
index 5ef690e2..ab910a6d 100644
--- a/website/src/lib/docs/no/menu/file.mdx
+++ b/website/src/lib/docs/no/menu/file.mdx
@@ -3,7 +3,7 @@ title: File actions
---
diff --git a/website/src/lib/docs/no/menu/settings.mdx b/website/src/lib/docs/no/menu/settings.mdx
index c5716341..e0e4d2d4 100644
--- a/website/src/lib/docs/no/menu/settings.mdx
+++ b/website/src/lib/docs/no/menu/settings.mdx
@@ -3,7 +3,7 @@ title: Settings
---
diff --git a/website/src/lib/docs/no/menu/view.mdx b/website/src/lib/docs/no/menu/view.mdx
index 0e6ff3f3..84bc48ed 100644
--- a/website/src/lib/docs/no/menu/view.mdx
+++ b/website/src/lib/docs/no/menu/view.mdx
@@ -3,7 +3,7 @@ title: View options
---
diff --git a/website/src/lib/docs/no/toolbar/clean.mdx b/website/src/lib/docs/no/toolbar/clean.mdx
index e8b8ffc5..5b98149f 100644
--- a/website/src/lib/docs/no/toolbar/clean.mdx
+++ b/website/src/lib/docs/no/toolbar/clean.mdx
@@ -3,7 +3,7 @@ title: Clean
---
diff --git a/website/src/lib/docs/no/toolbar/elevation.mdx b/website/src/lib/docs/no/toolbar/elevation.mdx
index 8aaf63aa..f4b9fef0 100644
--- a/website/src/lib/docs/no/toolbar/elevation.mdx
+++ b/website/src/lib/docs/no/toolbar/elevation.mdx
@@ -3,7 +3,7 @@ title: Høyde
---
diff --git a/website/src/lib/docs/no/toolbar/extract.mdx b/website/src/lib/docs/no/toolbar/extract.mdx
index 737c451d..a8fd74c5 100644
--- a/website/src/lib/docs/no/toolbar/extract.mdx
+++ b/website/src/lib/docs/no/toolbar/extract.mdx
@@ -3,7 +3,7 @@ title: Extract
---
diff --git a/website/src/lib/docs/no/toolbar/merge.mdx b/website/src/lib/docs/no/toolbar/merge.mdx
index 11ca1f1d..6b0413cd 100644
--- a/website/src/lib/docs/no/toolbar/merge.mdx
+++ b/website/src/lib/docs/no/toolbar/merge.mdx
@@ -3,7 +3,7 @@ title: Merge
---
diff --git a/website/src/lib/docs/no/toolbar/minify.mdx b/website/src/lib/docs/no/toolbar/minify.mdx
index 11b53248..2f50d7c6 100644
--- a/website/src/lib/docs/no/toolbar/minify.mdx
+++ b/website/src/lib/docs/no/toolbar/minify.mdx
@@ -3,12 +3,12 @@ title: Minify
---
-# { title }
+# { title }
This tool can be used to reduce the number of GPS points in a trace, which can be useful for decreasing its size.
diff --git a/website/src/lib/docs/no/toolbar/poi.mdx b/website/src/lib/docs/no/toolbar/poi.mdx
index 6cdc531f..c677df5f 100644
--- a/website/src/lib/docs/no/toolbar/poi.mdx
+++ b/website/src/lib/docs/no/toolbar/poi.mdx
@@ -3,7 +3,7 @@ title: Points of interest
---
diff --git a/website/src/lib/docs/no/toolbar/routing.mdx b/website/src/lib/docs/no/toolbar/routing.mdx
index dfed41da..bdb26d7c 100644
--- a/website/src/lib/docs/no/toolbar/routing.mdx
+++ b/website/src/lib/docs/no/toolbar/routing.mdx
@@ -3,7 +3,7 @@ title: Route planning and editing
---
diff --git a/website/src/lib/docs/no/toolbar/time.mdx b/website/src/lib/docs/no/toolbar/time.mdx
index 4b016114..6e7afcb2 100644
--- a/website/src/lib/docs/no/toolbar/time.mdx
+++ b/website/src/lib/docs/no/toolbar/time.mdx
@@ -3,7 +3,7 @@ title: Time
---
diff --git a/website/src/lib/docs/pl/files-and-stats.mdx b/website/src/lib/docs/pl/files-and-stats.mdx
index 19cf4e98..6bad33ea 100644
--- a/website/src/lib/docs/pl/files-and-stats.mdx
+++ b/website/src/lib/docs/pl/files-and-stats.mdx
@@ -3,7 +3,7 @@ title: Files and statistics
---
# { title }
diff --git a/website/src/lib/docs/pl/home/funding.mdx b/website/src/lib/docs/pl/home/funding.mdx
index fac56dcc..38b0a568 100644
--- a/website/src/lib/docs/pl/home/funding.mdx
+++ b/website/src/lib/docs/pl/home/funding.mdx
@@ -1,5 +1,5 @@
## Pomóż, aby ta strona pozostała darmowa (i bez reklam)
diff --git a/website/src/lib/docs/pl/home/translation.mdx b/website/src/lib/docs/pl/home/translation.mdx
index 12cea124..48a15f99 100644
--- a/website/src/lib/docs/pl/home/translation.mdx
+++ b/website/src/lib/docs/pl/home/translation.mdx
@@ -1,5 +1,5 @@
## Tłumaczenie
diff --git a/website/src/lib/docs/pl/map-controls.mdx b/website/src/lib/docs/pl/map-controls.mdx
index 8eee6884..a880fb51 100644
--- a/website/src/lib/docs/pl/map-controls.mdx
+++ b/website/src/lib/docs/pl/map-controls.mdx
@@ -3,7 +3,7 @@ title: Map controls
---
diff --git a/website/src/lib/docs/pl/menu/edit.mdx b/website/src/lib/docs/pl/menu/edit.mdx
index de4d50f3..7d97e37a 100644
--- a/website/src/lib/docs/pl/menu/edit.mdx
+++ b/website/src/lib/docs/pl/menu/edit.mdx
@@ -3,7 +3,7 @@ title: Edit actions
---
diff --git a/website/src/lib/docs/pl/menu/file.mdx b/website/src/lib/docs/pl/menu/file.mdx
index 5ef690e2..ab910a6d 100644
--- a/website/src/lib/docs/pl/menu/file.mdx
+++ b/website/src/lib/docs/pl/menu/file.mdx
@@ -3,7 +3,7 @@ title: File actions
---
diff --git a/website/src/lib/docs/pl/menu/settings.mdx b/website/src/lib/docs/pl/menu/settings.mdx
index 0954c38a..d44c682f 100644
--- a/website/src/lib/docs/pl/menu/settings.mdx
+++ b/website/src/lib/docs/pl/menu/settings.mdx
@@ -3,7 +3,7 @@ title: Settings
---
diff --git a/website/src/lib/docs/pl/menu/view.mdx b/website/src/lib/docs/pl/menu/view.mdx
index 0e6ff3f3..84bc48ed 100644
--- a/website/src/lib/docs/pl/menu/view.mdx
+++ b/website/src/lib/docs/pl/menu/view.mdx
@@ -3,7 +3,7 @@ title: View options
---
diff --git a/website/src/lib/docs/pl/toolbar/clean.mdx b/website/src/lib/docs/pl/toolbar/clean.mdx
index 384c60e9..ef69122a 100644
--- a/website/src/lib/docs/pl/toolbar/clean.mdx
+++ b/website/src/lib/docs/pl/toolbar/clean.mdx
@@ -3,7 +3,7 @@ title: Wyczyść
---
diff --git a/website/src/lib/docs/pl/toolbar/elevation.mdx b/website/src/lib/docs/pl/toolbar/elevation.mdx
index a8403e00..71927e4b 100644
--- a/website/src/lib/docs/pl/toolbar/elevation.mdx
+++ b/website/src/lib/docs/pl/toolbar/elevation.mdx
@@ -3,7 +3,7 @@ title: Przewyższenie
---
diff --git a/website/src/lib/docs/pl/toolbar/extract.mdx b/website/src/lib/docs/pl/toolbar/extract.mdx
index 737c451d..a8fd74c5 100644
--- a/website/src/lib/docs/pl/toolbar/extract.mdx
+++ b/website/src/lib/docs/pl/toolbar/extract.mdx
@@ -3,7 +3,7 @@ title: Extract
---
diff --git a/website/src/lib/docs/pl/toolbar/merge.mdx b/website/src/lib/docs/pl/toolbar/merge.mdx
index 11ca1f1d..6b0413cd 100644
--- a/website/src/lib/docs/pl/toolbar/merge.mdx
+++ b/website/src/lib/docs/pl/toolbar/merge.mdx
@@ -3,7 +3,7 @@ title: Merge
---
diff --git a/website/src/lib/docs/pl/toolbar/minify.mdx b/website/src/lib/docs/pl/toolbar/minify.mdx
index 11b53248..2f50d7c6 100644
--- a/website/src/lib/docs/pl/toolbar/minify.mdx
+++ b/website/src/lib/docs/pl/toolbar/minify.mdx
@@ -3,12 +3,12 @@ title: Minify
---
-# { title }
+# { title }
This tool can be used to reduce the number of GPS points in a trace, which can be useful for decreasing its size.
diff --git a/website/src/lib/docs/pl/toolbar/poi.mdx b/website/src/lib/docs/pl/toolbar/poi.mdx
index 6cdc531f..c677df5f 100644
--- a/website/src/lib/docs/pl/toolbar/poi.mdx
+++ b/website/src/lib/docs/pl/toolbar/poi.mdx
@@ -3,7 +3,7 @@ title: Points of interest
---
diff --git a/website/src/lib/docs/pl/toolbar/routing.mdx b/website/src/lib/docs/pl/toolbar/routing.mdx
index dfed41da..bdb26d7c 100644
--- a/website/src/lib/docs/pl/toolbar/routing.mdx
+++ b/website/src/lib/docs/pl/toolbar/routing.mdx
@@ -3,7 +3,7 @@ title: Route planning and editing
---
diff --git a/website/src/lib/docs/pl/toolbar/time.mdx b/website/src/lib/docs/pl/toolbar/time.mdx
index 4b016114..6e7afcb2 100644
--- a/website/src/lib/docs/pl/toolbar/time.mdx
+++ b/website/src/lib/docs/pl/toolbar/time.mdx
@@ -3,7 +3,7 @@ title: Time
---
diff --git a/website/src/lib/docs/pt-BR/files-and-stats.mdx b/website/src/lib/docs/pt-BR/files-and-stats.mdx
index 32ce0c3f..d41ffde8 100644
--- a/website/src/lib/docs/pt-BR/files-and-stats.mdx
+++ b/website/src/lib/docs/pt-BR/files-and-stats.mdx
@@ -3,7 +3,7 @@ title: Arquivos e estatísticas
---
# { title }
diff --git a/website/src/lib/docs/pt-BR/home/funding.mdx b/website/src/lib/docs/pt-BR/home/funding.mdx
index 4f95f45a..779c6a35 100644
--- a/website/src/lib/docs/pt-BR/home/funding.mdx
+++ b/website/src/lib/docs/pt-BR/home/funding.mdx
@@ -1,5 +1,5 @@
## Ajude a manter o site gratuito (e sem anúncios)
diff --git a/website/src/lib/docs/pt-BR/home/translation.mdx b/website/src/lib/docs/pt-BR/home/translation.mdx
index 5144cd44..0230a036 100644
--- a/website/src/lib/docs/pt-BR/home/translation.mdx
+++ b/website/src/lib/docs/pt-BR/home/translation.mdx
@@ -1,5 +1,5 @@
## Tradução
diff --git a/website/src/lib/docs/pt-BR/map-controls.mdx b/website/src/lib/docs/pt-BR/map-controls.mdx
index 4495657d..2348af7c 100644
--- a/website/src/lib/docs/pt-BR/map-controls.mdx
+++ b/website/src/lib/docs/pt-BR/map-controls.mdx
@@ -3,7 +3,7 @@ title: Controles do mapa
---
diff --git a/website/src/lib/docs/pt-BR/menu/edit.mdx b/website/src/lib/docs/pt-BR/menu/edit.mdx
index 7a35a809..97a49988 100644
--- a/website/src/lib/docs/pt-BR/menu/edit.mdx
+++ b/website/src/lib/docs/pt-BR/menu/edit.mdx
@@ -3,7 +3,7 @@ title: Ações de edição
---
diff --git a/website/src/lib/docs/pt-BR/menu/file.mdx b/website/src/lib/docs/pt-BR/menu/file.mdx
index 715971e4..2c4a817f 100644
--- a/website/src/lib/docs/pt-BR/menu/file.mdx
+++ b/website/src/lib/docs/pt-BR/menu/file.mdx
@@ -3,7 +3,7 @@ title: Ações do arquivo
---
diff --git a/website/src/lib/docs/pt-BR/menu/settings.mdx b/website/src/lib/docs/pt-BR/menu/settings.mdx
index 448cded7..2ee1da25 100644
--- a/website/src/lib/docs/pt-BR/menu/settings.mdx
+++ b/website/src/lib/docs/pt-BR/menu/settings.mdx
@@ -3,7 +3,7 @@ title: Configurações
---
diff --git a/website/src/lib/docs/pt-BR/menu/view.mdx b/website/src/lib/docs/pt-BR/menu/view.mdx
index 0db9d2ee..653ee487 100644
--- a/website/src/lib/docs/pt-BR/menu/view.mdx
+++ b/website/src/lib/docs/pt-BR/menu/view.mdx
@@ -3,7 +3,7 @@ title: Ver opções
---
diff --git a/website/src/lib/docs/pt-BR/toolbar/clean.mdx b/website/src/lib/docs/pt-BR/toolbar/clean.mdx
index 5f351f09..bfd9f6b1 100644
--- a/website/src/lib/docs/pt-BR/toolbar/clean.mdx
+++ b/website/src/lib/docs/pt-BR/toolbar/clean.mdx
@@ -3,7 +3,7 @@ title: Limpar
---
diff --git a/website/src/lib/docs/pt-BR/toolbar/elevation.mdx b/website/src/lib/docs/pt-BR/toolbar/elevation.mdx
index 26b75b10..548fa7b5 100644
--- a/website/src/lib/docs/pt-BR/toolbar/elevation.mdx
+++ b/website/src/lib/docs/pt-BR/toolbar/elevation.mdx
@@ -3,7 +3,7 @@ title: Elevação
---
diff --git a/website/src/lib/docs/pt-BR/toolbar/extract.mdx b/website/src/lib/docs/pt-BR/toolbar/extract.mdx
index 11ea0709..65284951 100644
--- a/website/src/lib/docs/pt-BR/toolbar/extract.mdx
+++ b/website/src/lib/docs/pt-BR/toolbar/extract.mdx
@@ -3,7 +3,7 @@ title: Extrair
---
diff --git a/website/src/lib/docs/pt-BR/toolbar/merge.mdx b/website/src/lib/docs/pt-BR/toolbar/merge.mdx
index 7d086ef1..1da2e303 100644
--- a/website/src/lib/docs/pt-BR/toolbar/merge.mdx
+++ b/website/src/lib/docs/pt-BR/toolbar/merge.mdx
@@ -3,7 +3,7 @@ title: Mesclar
---
diff --git a/website/src/lib/docs/pt-BR/toolbar/minify.mdx b/website/src/lib/docs/pt-BR/toolbar/minify.mdx
index a8f79261..98f0fa4b 100644
--- a/website/src/lib/docs/pt-BR/toolbar/minify.mdx
+++ b/website/src/lib/docs/pt-BR/toolbar/minify.mdx
@@ -3,12 +3,12 @@ title: Minificar
---
-# { title }
+# { title }
Esta ferramenta pode ser utilizada para reduzir o número de pontos GPS em um traço, o que pode ser útil para diminuir seu tamanho.
diff --git a/website/src/lib/docs/pt-BR/toolbar/poi.mdx b/website/src/lib/docs/pt-BR/toolbar/poi.mdx
index 24a2b41c..e4ec95a7 100644
--- a/website/src/lib/docs/pt-BR/toolbar/poi.mdx
+++ b/website/src/lib/docs/pt-BR/toolbar/poi.mdx
@@ -3,7 +3,7 @@ title: Pontos de interesse
---
diff --git a/website/src/lib/docs/pt-BR/toolbar/routing.mdx b/website/src/lib/docs/pt-BR/toolbar/routing.mdx
index e0b3cb93..9e0cc303 100644
--- a/website/src/lib/docs/pt-BR/toolbar/routing.mdx
+++ b/website/src/lib/docs/pt-BR/toolbar/routing.mdx
@@ -3,7 +3,7 @@ title: Planejamento e edição de rotas
---
diff --git a/website/src/lib/docs/pt-BR/toolbar/time.mdx b/website/src/lib/docs/pt-BR/toolbar/time.mdx
index a4df73e4..2480123b 100644
--- a/website/src/lib/docs/pt-BR/toolbar/time.mdx
+++ b/website/src/lib/docs/pt-BR/toolbar/time.mdx
@@ -3,7 +3,7 @@ title: Tempo
---
diff --git a/website/src/lib/docs/pt/files-and-stats.mdx b/website/src/lib/docs/pt/files-and-stats.mdx
index 19cf4e98..6bad33ea 100644
--- a/website/src/lib/docs/pt/files-and-stats.mdx
+++ b/website/src/lib/docs/pt/files-and-stats.mdx
@@ -3,7 +3,7 @@ title: Files and statistics
---
# { title }
diff --git a/website/src/lib/docs/pt/home/funding.mdx b/website/src/lib/docs/pt/home/funding.mdx
index 4f95f45a..779c6a35 100644
--- a/website/src/lib/docs/pt/home/funding.mdx
+++ b/website/src/lib/docs/pt/home/funding.mdx
@@ -1,5 +1,5 @@
## Ajude a manter o site gratuito (e sem anúncios)
diff --git a/website/src/lib/docs/pt/home/translation.mdx b/website/src/lib/docs/pt/home/translation.mdx
index 057b09ab..50fc7014 100644
--- a/website/src/lib/docs/pt/home/translation.mdx
+++ b/website/src/lib/docs/pt/home/translation.mdx
@@ -1,5 +1,5 @@
## Tradução
diff --git a/website/src/lib/docs/pt/map-controls.mdx b/website/src/lib/docs/pt/map-controls.mdx
index 8eee6884..a880fb51 100644
--- a/website/src/lib/docs/pt/map-controls.mdx
+++ b/website/src/lib/docs/pt/map-controls.mdx
@@ -3,7 +3,7 @@ title: Map controls
---
diff --git a/website/src/lib/docs/pt/menu/edit.mdx b/website/src/lib/docs/pt/menu/edit.mdx
index cbcdd96e..ac0b4e9a 100644
--- a/website/src/lib/docs/pt/menu/edit.mdx
+++ b/website/src/lib/docs/pt/menu/edit.mdx
@@ -3,7 +3,7 @@ title: Edit actions
---
diff --git a/website/src/lib/docs/pt/menu/file.mdx b/website/src/lib/docs/pt/menu/file.mdx
index 5ef690e2..ab910a6d 100644
--- a/website/src/lib/docs/pt/menu/file.mdx
+++ b/website/src/lib/docs/pt/menu/file.mdx
@@ -3,7 +3,7 @@ title: File actions
---
diff --git a/website/src/lib/docs/pt/menu/settings.mdx b/website/src/lib/docs/pt/menu/settings.mdx
index 900dbead..f9d5eccb 100644
--- a/website/src/lib/docs/pt/menu/settings.mdx
+++ b/website/src/lib/docs/pt/menu/settings.mdx
@@ -3,7 +3,7 @@ title: Settings
---
diff --git a/website/src/lib/docs/pt/menu/view.mdx b/website/src/lib/docs/pt/menu/view.mdx
index 0e6ff3f3..84bc48ed 100644
--- a/website/src/lib/docs/pt/menu/view.mdx
+++ b/website/src/lib/docs/pt/menu/view.mdx
@@ -3,7 +3,7 @@ title: View options
---
diff --git a/website/src/lib/docs/pt/toolbar/clean.mdx b/website/src/lib/docs/pt/toolbar/clean.mdx
index e8b8ffc5..5b98149f 100644
--- a/website/src/lib/docs/pt/toolbar/clean.mdx
+++ b/website/src/lib/docs/pt/toolbar/clean.mdx
@@ -3,7 +3,7 @@ title: Clean
---
diff --git a/website/src/lib/docs/pt/toolbar/elevation.mdx b/website/src/lib/docs/pt/toolbar/elevation.mdx
index 34649516..6ce74bf2 100644
--- a/website/src/lib/docs/pt/toolbar/elevation.mdx
+++ b/website/src/lib/docs/pt/toolbar/elevation.mdx
@@ -3,7 +3,7 @@ title: Elevação
---
diff --git a/website/src/lib/docs/pt/toolbar/extract.mdx b/website/src/lib/docs/pt/toolbar/extract.mdx
index 737c451d..a8fd74c5 100644
--- a/website/src/lib/docs/pt/toolbar/extract.mdx
+++ b/website/src/lib/docs/pt/toolbar/extract.mdx
@@ -3,7 +3,7 @@ title: Extract
---
diff --git a/website/src/lib/docs/pt/toolbar/merge.mdx b/website/src/lib/docs/pt/toolbar/merge.mdx
index 11ca1f1d..6b0413cd 100644
--- a/website/src/lib/docs/pt/toolbar/merge.mdx
+++ b/website/src/lib/docs/pt/toolbar/merge.mdx
@@ -3,7 +3,7 @@ title: Merge
---
diff --git a/website/src/lib/docs/pt/toolbar/minify.mdx b/website/src/lib/docs/pt/toolbar/minify.mdx
index 11b53248..2f50d7c6 100644
--- a/website/src/lib/docs/pt/toolbar/minify.mdx
+++ b/website/src/lib/docs/pt/toolbar/minify.mdx
@@ -3,12 +3,12 @@ title: Minify
---
-# { title }
+# { title }
This tool can be used to reduce the number of GPS points in a trace, which can be useful for decreasing its size.
diff --git a/website/src/lib/docs/pt/toolbar/poi.mdx b/website/src/lib/docs/pt/toolbar/poi.mdx
index 6cdc531f..c677df5f 100644
--- a/website/src/lib/docs/pt/toolbar/poi.mdx
+++ b/website/src/lib/docs/pt/toolbar/poi.mdx
@@ -3,7 +3,7 @@ title: Points of interest
---
diff --git a/website/src/lib/docs/pt/toolbar/routing.mdx b/website/src/lib/docs/pt/toolbar/routing.mdx
index dfed41da..bdb26d7c 100644
--- a/website/src/lib/docs/pt/toolbar/routing.mdx
+++ b/website/src/lib/docs/pt/toolbar/routing.mdx
@@ -3,7 +3,7 @@ title: Route planning and editing
---
diff --git a/website/src/lib/docs/pt/toolbar/time.mdx b/website/src/lib/docs/pt/toolbar/time.mdx
index 5aaff07b..574c36a4 100644
--- a/website/src/lib/docs/pt/toolbar/time.mdx
+++ b/website/src/lib/docs/pt/toolbar/time.mdx
@@ -3,7 +3,7 @@ title: Tempo
---
diff --git a/website/src/lib/docs/ro/files-and-stats.mdx b/website/src/lib/docs/ro/files-and-stats.mdx
index 19cf4e98..6bad33ea 100644
--- a/website/src/lib/docs/ro/files-and-stats.mdx
+++ b/website/src/lib/docs/ro/files-and-stats.mdx
@@ -3,7 +3,7 @@ title: Files and statistics
---
# { title }
diff --git a/website/src/lib/docs/ro/home/funding.mdx b/website/src/lib/docs/ro/home/funding.mdx
index 93c7014f..9ec64d32 100644
--- a/website/src/lib/docs/ro/home/funding.mdx
+++ b/website/src/lib/docs/ro/home/funding.mdx
@@ -1,5 +1,5 @@
## Help keep the website free (and ad-free)
diff --git a/website/src/lib/docs/ro/home/translation.mdx b/website/src/lib/docs/ro/home/translation.mdx
index 909df9a3..9dbfb37e 100644
--- a/website/src/lib/docs/ro/home/translation.mdx
+++ b/website/src/lib/docs/ro/home/translation.mdx
@@ -1,5 +1,5 @@
## Translation
diff --git a/website/src/lib/docs/ro/map-controls.mdx b/website/src/lib/docs/ro/map-controls.mdx
index 8eee6884..a880fb51 100644
--- a/website/src/lib/docs/ro/map-controls.mdx
+++ b/website/src/lib/docs/ro/map-controls.mdx
@@ -3,7 +3,7 @@ title: Map controls
---
diff --git a/website/src/lib/docs/ro/menu/edit.mdx b/website/src/lib/docs/ro/menu/edit.mdx
index cbcdd96e..ac0b4e9a 100644
--- a/website/src/lib/docs/ro/menu/edit.mdx
+++ b/website/src/lib/docs/ro/menu/edit.mdx
@@ -3,7 +3,7 @@ title: Edit actions
---
diff --git a/website/src/lib/docs/ro/menu/file.mdx b/website/src/lib/docs/ro/menu/file.mdx
index 5ef690e2..ab910a6d 100644
--- a/website/src/lib/docs/ro/menu/file.mdx
+++ b/website/src/lib/docs/ro/menu/file.mdx
@@ -3,7 +3,7 @@ title: File actions
---
diff --git a/website/src/lib/docs/ro/menu/settings.mdx b/website/src/lib/docs/ro/menu/settings.mdx
index c8b2fd84..998164f7 100644
--- a/website/src/lib/docs/ro/menu/settings.mdx
+++ b/website/src/lib/docs/ro/menu/settings.mdx
@@ -3,7 +3,7 @@ title: Settings
---
diff --git a/website/src/lib/docs/ro/menu/view.mdx b/website/src/lib/docs/ro/menu/view.mdx
index 0e6ff3f3..84bc48ed 100644
--- a/website/src/lib/docs/ro/menu/view.mdx
+++ b/website/src/lib/docs/ro/menu/view.mdx
@@ -3,7 +3,7 @@ title: View options
---
diff --git a/website/src/lib/docs/ro/toolbar/clean.mdx b/website/src/lib/docs/ro/toolbar/clean.mdx
index e8b8ffc5..5b98149f 100644
--- a/website/src/lib/docs/ro/toolbar/clean.mdx
+++ b/website/src/lib/docs/ro/toolbar/clean.mdx
@@ -3,7 +3,7 @@ title: Clean
---
diff --git a/website/src/lib/docs/ro/toolbar/elevation.mdx b/website/src/lib/docs/ro/toolbar/elevation.mdx
index 8fb869d5..3ba9b759 100644
--- a/website/src/lib/docs/ro/toolbar/elevation.mdx
+++ b/website/src/lib/docs/ro/toolbar/elevation.mdx
@@ -3,7 +3,7 @@ title: Elevation
---
diff --git a/website/src/lib/docs/ro/toolbar/extract.mdx b/website/src/lib/docs/ro/toolbar/extract.mdx
index 737c451d..a8fd74c5 100644
--- a/website/src/lib/docs/ro/toolbar/extract.mdx
+++ b/website/src/lib/docs/ro/toolbar/extract.mdx
@@ -3,7 +3,7 @@ title: Extract
---
diff --git a/website/src/lib/docs/ro/toolbar/merge.mdx b/website/src/lib/docs/ro/toolbar/merge.mdx
index 11ca1f1d..6b0413cd 100644
--- a/website/src/lib/docs/ro/toolbar/merge.mdx
+++ b/website/src/lib/docs/ro/toolbar/merge.mdx
@@ -3,7 +3,7 @@ title: Merge
---
diff --git a/website/src/lib/docs/ro/toolbar/minify.mdx b/website/src/lib/docs/ro/toolbar/minify.mdx
index 11b53248..2f50d7c6 100644
--- a/website/src/lib/docs/ro/toolbar/minify.mdx
+++ b/website/src/lib/docs/ro/toolbar/minify.mdx
@@ -3,12 +3,12 @@ title: Minify
---
-# { title }
+# { title }
This tool can be used to reduce the number of GPS points in a trace, which can be useful for decreasing its size.
diff --git a/website/src/lib/docs/ro/toolbar/poi.mdx b/website/src/lib/docs/ro/toolbar/poi.mdx
index 6cdc531f..c677df5f 100644
--- a/website/src/lib/docs/ro/toolbar/poi.mdx
+++ b/website/src/lib/docs/ro/toolbar/poi.mdx
@@ -3,7 +3,7 @@ title: Points of interest
---
diff --git a/website/src/lib/docs/ro/toolbar/routing.mdx b/website/src/lib/docs/ro/toolbar/routing.mdx
index dfed41da..bdb26d7c 100644
--- a/website/src/lib/docs/ro/toolbar/routing.mdx
+++ b/website/src/lib/docs/ro/toolbar/routing.mdx
@@ -3,7 +3,7 @@ title: Route planning and editing
---
diff --git a/website/src/lib/docs/ro/toolbar/time.mdx b/website/src/lib/docs/ro/toolbar/time.mdx
index 4b016114..6e7afcb2 100644
--- a/website/src/lib/docs/ro/toolbar/time.mdx
+++ b/website/src/lib/docs/ro/toolbar/time.mdx
@@ -3,7 +3,7 @@ title: Time
---
diff --git a/website/src/lib/docs/ru/files-and-stats.mdx b/website/src/lib/docs/ru/files-and-stats.mdx
index f32c35e1..723559a8 100644
--- a/website/src/lib/docs/ru/files-and-stats.mdx
+++ b/website/src/lib/docs/ru/files-and-stats.mdx
@@ -3,7 +3,7 @@ title: Файлы и статистика
---
# { title }
diff --git a/website/src/lib/docs/ru/home/funding.mdx b/website/src/lib/docs/ru/home/funding.mdx
index cb0f6be7..efd48a8c 100644
--- a/website/src/lib/docs/ru/home/funding.mdx
+++ b/website/src/lib/docs/ru/home/funding.mdx
@@ -1,5 +1,5 @@
## Помогите сделать сайт бесплатным (и без рекламы)
diff --git a/website/src/lib/docs/ru/home/translation.mdx b/website/src/lib/docs/ru/home/translation.mdx
index ec2e1e50..30852144 100644
--- a/website/src/lib/docs/ru/home/translation.mdx
+++ b/website/src/lib/docs/ru/home/translation.mdx
@@ -1,5 +1,5 @@
## Перевод
diff --git a/website/src/lib/docs/ru/map-controls.mdx b/website/src/lib/docs/ru/map-controls.mdx
index 8d1d3a68..926805c0 100644
--- a/website/src/lib/docs/ru/map-controls.mdx
+++ b/website/src/lib/docs/ru/map-controls.mdx
@@ -3,7 +3,7 @@ title: Управление картой
---
diff --git a/website/src/lib/docs/ru/menu/edit.mdx b/website/src/lib/docs/ru/menu/edit.mdx
index eb875aba..f4e821a4 100644
--- a/website/src/lib/docs/ru/menu/edit.mdx
+++ b/website/src/lib/docs/ru/menu/edit.mdx
@@ -3,7 +3,7 @@ title: Редактировать действия
---
diff --git a/website/src/lib/docs/ru/menu/file.mdx b/website/src/lib/docs/ru/menu/file.mdx
index 5ef690e2..ab910a6d 100644
--- a/website/src/lib/docs/ru/menu/file.mdx
+++ b/website/src/lib/docs/ru/menu/file.mdx
@@ -3,7 +3,7 @@ title: File actions
---
diff --git a/website/src/lib/docs/ru/menu/settings.mdx b/website/src/lib/docs/ru/menu/settings.mdx
index 1a769852..ab18e472 100644
--- a/website/src/lib/docs/ru/menu/settings.mdx
+++ b/website/src/lib/docs/ru/menu/settings.mdx
@@ -3,7 +3,7 @@ title: Settings
---
diff --git a/website/src/lib/docs/ru/menu/view.mdx b/website/src/lib/docs/ru/menu/view.mdx
index fa7d46bf..8471f72f 100644
--- a/website/src/lib/docs/ru/menu/view.mdx
+++ b/website/src/lib/docs/ru/menu/view.mdx
@@ -3,7 +3,7 @@ title: View options
---
diff --git a/website/src/lib/docs/ru/toolbar/clean.mdx b/website/src/lib/docs/ru/toolbar/clean.mdx
index e8b8ffc5..5b98149f 100644
--- a/website/src/lib/docs/ru/toolbar/clean.mdx
+++ b/website/src/lib/docs/ru/toolbar/clean.mdx
@@ -3,7 +3,7 @@ title: Clean
---
diff --git a/website/src/lib/docs/ru/toolbar/elevation.mdx b/website/src/lib/docs/ru/toolbar/elevation.mdx
index 56d33cdf..c43ac9aa 100644
--- a/website/src/lib/docs/ru/toolbar/elevation.mdx
+++ b/website/src/lib/docs/ru/toolbar/elevation.mdx
@@ -3,7 +3,7 @@ title: Высота
---
diff --git a/website/src/lib/docs/ru/toolbar/extract.mdx b/website/src/lib/docs/ru/toolbar/extract.mdx
index 737c451d..a8fd74c5 100644
--- a/website/src/lib/docs/ru/toolbar/extract.mdx
+++ b/website/src/lib/docs/ru/toolbar/extract.mdx
@@ -3,7 +3,7 @@ title: Extract
---
diff --git a/website/src/lib/docs/ru/toolbar/merge.mdx b/website/src/lib/docs/ru/toolbar/merge.mdx
index 11ca1f1d..6b0413cd 100644
--- a/website/src/lib/docs/ru/toolbar/merge.mdx
+++ b/website/src/lib/docs/ru/toolbar/merge.mdx
@@ -3,7 +3,7 @@ title: Merge
---
diff --git a/website/src/lib/docs/ru/toolbar/minify.mdx b/website/src/lib/docs/ru/toolbar/minify.mdx
index 11b53248..2f50d7c6 100644
--- a/website/src/lib/docs/ru/toolbar/minify.mdx
+++ b/website/src/lib/docs/ru/toolbar/minify.mdx
@@ -3,12 +3,12 @@ title: Minify
---
-# { title }
+# { title }
This tool can be used to reduce the number of GPS points in a trace, which can be useful for decreasing its size.
diff --git a/website/src/lib/docs/ru/toolbar/poi.mdx b/website/src/lib/docs/ru/toolbar/poi.mdx
index cbd5b49b..eb5bbabb 100644
--- a/website/src/lib/docs/ru/toolbar/poi.mdx
+++ b/website/src/lib/docs/ru/toolbar/poi.mdx
@@ -3,7 +3,7 @@ title: Точки интереса
---
diff --git a/website/src/lib/docs/ru/toolbar/routing.mdx b/website/src/lib/docs/ru/toolbar/routing.mdx
index 1c4b69eb..0cb1a49c 100644
--- a/website/src/lib/docs/ru/toolbar/routing.mdx
+++ b/website/src/lib/docs/ru/toolbar/routing.mdx
@@ -3,7 +3,7 @@ title: Планирование и редактирование маршрута
---
diff --git a/website/src/lib/docs/ru/toolbar/time.mdx b/website/src/lib/docs/ru/toolbar/time.mdx
index 46df0153..e66ff668 100644
--- a/website/src/lib/docs/ru/toolbar/time.mdx
+++ b/website/src/lib/docs/ru/toolbar/time.mdx
@@ -3,7 +3,7 @@ title: Время
---
diff --git a/website/src/lib/docs/sr/files-and-stats.mdx b/website/src/lib/docs/sr/files-and-stats.mdx
index e94e016d..1b9352f4 100644
--- a/website/src/lib/docs/sr/files-and-stats.mdx
+++ b/website/src/lib/docs/sr/files-and-stats.mdx
@@ -3,7 +3,7 @@ title: Datoteke i statistike
---
# { title }
diff --git a/website/src/lib/docs/sr/home/funding.mdx b/website/src/lib/docs/sr/home/funding.mdx
index 93c7014f..9ec64d32 100644
--- a/website/src/lib/docs/sr/home/funding.mdx
+++ b/website/src/lib/docs/sr/home/funding.mdx
@@ -1,5 +1,5 @@
## Help keep the website free (and ad-free)
diff --git a/website/src/lib/docs/sr/home/translation.mdx b/website/src/lib/docs/sr/home/translation.mdx
index 1299512e..e8ba45f6 100644
--- a/website/src/lib/docs/sr/home/translation.mdx
+++ b/website/src/lib/docs/sr/home/translation.mdx
@@ -1,5 +1,5 @@
## Translation
diff --git a/website/src/lib/docs/sr/map-controls.mdx b/website/src/lib/docs/sr/map-controls.mdx
index ba990000..f8e4f50b 100644
--- a/website/src/lib/docs/sr/map-controls.mdx
+++ b/website/src/lib/docs/sr/map-controls.mdx
@@ -3,7 +3,7 @@ title: Kontrole mape
---
diff --git a/website/src/lib/docs/sr/menu/edit.mdx b/website/src/lib/docs/sr/menu/edit.mdx
index a3bdc842..afa140e2 100644
--- a/website/src/lib/docs/sr/menu/edit.mdx
+++ b/website/src/lib/docs/sr/menu/edit.mdx
@@ -3,7 +3,7 @@ title: Akcije uređivanja
---
diff --git a/website/src/lib/docs/sr/menu/file.mdx b/website/src/lib/docs/sr/menu/file.mdx
index 5ef690e2..ab910a6d 100644
--- a/website/src/lib/docs/sr/menu/file.mdx
+++ b/website/src/lib/docs/sr/menu/file.mdx
@@ -3,7 +3,7 @@ title: File actions
---
diff --git a/website/src/lib/docs/sr/menu/settings.mdx b/website/src/lib/docs/sr/menu/settings.mdx
index 8c529729..6fdf26cd 100644
--- a/website/src/lib/docs/sr/menu/settings.mdx
+++ b/website/src/lib/docs/sr/menu/settings.mdx
@@ -3,7 +3,7 @@ title: Settings
---
diff --git a/website/src/lib/docs/sr/menu/view.mdx b/website/src/lib/docs/sr/menu/view.mdx
index ce649f33..d9a6e7a9 100644
--- a/website/src/lib/docs/sr/menu/view.mdx
+++ b/website/src/lib/docs/sr/menu/view.mdx
@@ -3,7 +3,7 @@ title: View options
---
diff --git a/website/src/lib/docs/sr/toolbar/clean.mdx b/website/src/lib/docs/sr/toolbar/clean.mdx
index e8b8ffc5..5b98149f 100644
--- a/website/src/lib/docs/sr/toolbar/clean.mdx
+++ b/website/src/lib/docs/sr/toolbar/clean.mdx
@@ -3,7 +3,7 @@ title: Clean
---
diff --git a/website/src/lib/docs/sr/toolbar/elevation.mdx b/website/src/lib/docs/sr/toolbar/elevation.mdx
index 8fb869d5..3ba9b759 100644
--- a/website/src/lib/docs/sr/toolbar/elevation.mdx
+++ b/website/src/lib/docs/sr/toolbar/elevation.mdx
@@ -3,7 +3,7 @@ title: Elevation
---
diff --git a/website/src/lib/docs/sr/toolbar/extract.mdx b/website/src/lib/docs/sr/toolbar/extract.mdx
index 737c451d..a8fd74c5 100644
--- a/website/src/lib/docs/sr/toolbar/extract.mdx
+++ b/website/src/lib/docs/sr/toolbar/extract.mdx
@@ -3,7 +3,7 @@ title: Extract
---
diff --git a/website/src/lib/docs/sr/toolbar/merge.mdx b/website/src/lib/docs/sr/toolbar/merge.mdx
index 11ca1f1d..6b0413cd 100644
--- a/website/src/lib/docs/sr/toolbar/merge.mdx
+++ b/website/src/lib/docs/sr/toolbar/merge.mdx
@@ -3,7 +3,7 @@ title: Merge
---
diff --git a/website/src/lib/docs/sr/toolbar/minify.mdx b/website/src/lib/docs/sr/toolbar/minify.mdx
index 11b53248..2f50d7c6 100644
--- a/website/src/lib/docs/sr/toolbar/minify.mdx
+++ b/website/src/lib/docs/sr/toolbar/minify.mdx
@@ -3,12 +3,12 @@ title: Minify
---
-# { title }
+# { title }
This tool can be used to reduce the number of GPS points in a trace, which can be useful for decreasing its size.
diff --git a/website/src/lib/docs/sr/toolbar/poi.mdx b/website/src/lib/docs/sr/toolbar/poi.mdx
index 6cdc531f..c677df5f 100644
--- a/website/src/lib/docs/sr/toolbar/poi.mdx
+++ b/website/src/lib/docs/sr/toolbar/poi.mdx
@@ -3,7 +3,7 @@ title: Points of interest
---
diff --git a/website/src/lib/docs/sr/toolbar/routing.mdx b/website/src/lib/docs/sr/toolbar/routing.mdx
index dfed41da..bdb26d7c 100644
--- a/website/src/lib/docs/sr/toolbar/routing.mdx
+++ b/website/src/lib/docs/sr/toolbar/routing.mdx
@@ -3,7 +3,7 @@ title: Route planning and editing
---
diff --git a/website/src/lib/docs/sr/toolbar/time.mdx b/website/src/lib/docs/sr/toolbar/time.mdx
index 4b016114..6e7afcb2 100644
--- a/website/src/lib/docs/sr/toolbar/time.mdx
+++ b/website/src/lib/docs/sr/toolbar/time.mdx
@@ -3,7 +3,7 @@ title: Time
---
diff --git a/website/src/lib/docs/sv/files-and-stats.mdx b/website/src/lib/docs/sv/files-and-stats.mdx
index 0e90f3f8..3a8fb6d0 100644
--- a/website/src/lib/docs/sv/files-and-stats.mdx
+++ b/website/src/lib/docs/sv/files-and-stats.mdx
@@ -3,7 +3,7 @@ title: Files and statistics
---
# { title }
diff --git a/website/src/lib/docs/sv/home/funding.mdx b/website/src/lib/docs/sv/home/funding.mdx
index 9a152c77..96a914d9 100644
--- a/website/src/lib/docs/sv/home/funding.mdx
+++ b/website/src/lib/docs/sv/home/funding.mdx
@@ -1,5 +1,5 @@
## Hjälp till att hålla webbplatsen gratis (och annonsfri)
diff --git a/website/src/lib/docs/sv/home/translation.mdx b/website/src/lib/docs/sv/home/translation.mdx
index afffc27d..a5147c04 100644
--- a/website/src/lib/docs/sv/home/translation.mdx
+++ b/website/src/lib/docs/sv/home/translation.mdx
@@ -1,5 +1,5 @@
## Översättning
diff --git a/website/src/lib/docs/sv/map-controls.mdx b/website/src/lib/docs/sv/map-controls.mdx
index 5838975a..22cce36a 100644
--- a/website/src/lib/docs/sv/map-controls.mdx
+++ b/website/src/lib/docs/sv/map-controls.mdx
@@ -3,7 +3,7 @@ title: Map controls
---
diff --git a/website/src/lib/docs/sv/menu/edit.mdx b/website/src/lib/docs/sv/menu/edit.mdx
index 71a3b575..a3d9f3b4 100644
--- a/website/src/lib/docs/sv/menu/edit.mdx
+++ b/website/src/lib/docs/sv/menu/edit.mdx
@@ -3,7 +3,7 @@ title: Edit actions
---
diff --git a/website/src/lib/docs/sv/menu/file.mdx b/website/src/lib/docs/sv/menu/file.mdx
index 7d0bde1c..0c06b63c 100644
--- a/website/src/lib/docs/sv/menu/file.mdx
+++ b/website/src/lib/docs/sv/menu/file.mdx
@@ -3,7 +3,7 @@ title: File actions
---
diff --git a/website/src/lib/docs/sv/menu/settings.mdx b/website/src/lib/docs/sv/menu/settings.mdx
index b0dd2d1b..64d300e9 100644
--- a/website/src/lib/docs/sv/menu/settings.mdx
+++ b/website/src/lib/docs/sv/menu/settings.mdx
@@ -3,7 +3,7 @@ title: Settings
---
diff --git a/website/src/lib/docs/sv/menu/view.mdx b/website/src/lib/docs/sv/menu/view.mdx
index e77fd764..0c7b7486 100644
--- a/website/src/lib/docs/sv/menu/view.mdx
+++ b/website/src/lib/docs/sv/menu/view.mdx
@@ -3,7 +3,7 @@ title: View options
---
diff --git a/website/src/lib/docs/sv/toolbar/clean.mdx b/website/src/lib/docs/sv/toolbar/clean.mdx
index e6d8a54a..5e96d689 100644
--- a/website/src/lib/docs/sv/toolbar/clean.mdx
+++ b/website/src/lib/docs/sv/toolbar/clean.mdx
@@ -3,7 +3,7 @@ title: Clean
---
diff --git a/website/src/lib/docs/sv/toolbar/elevation.mdx b/website/src/lib/docs/sv/toolbar/elevation.mdx
index b924fdc5..10aca93e 100644
--- a/website/src/lib/docs/sv/toolbar/elevation.mdx
+++ b/website/src/lib/docs/sv/toolbar/elevation.mdx
@@ -3,7 +3,7 @@ title: Höjd
---
diff --git a/website/src/lib/docs/sv/toolbar/extract.mdx b/website/src/lib/docs/sv/toolbar/extract.mdx
index 07227312..cee184ba 100644
--- a/website/src/lib/docs/sv/toolbar/extract.mdx
+++ b/website/src/lib/docs/sv/toolbar/extract.mdx
@@ -3,7 +3,7 @@ title: Extract
---
diff --git a/website/src/lib/docs/sv/toolbar/merge.mdx b/website/src/lib/docs/sv/toolbar/merge.mdx
index 3085fd0e..ca5a378c 100644
--- a/website/src/lib/docs/sv/toolbar/merge.mdx
+++ b/website/src/lib/docs/sv/toolbar/merge.mdx
@@ -3,7 +3,7 @@ title: Merge
---
diff --git a/website/src/lib/docs/sv/toolbar/minify.mdx b/website/src/lib/docs/sv/toolbar/minify.mdx
index 86499c9a..055fddef 100644
--- a/website/src/lib/docs/sv/toolbar/minify.mdx
+++ b/website/src/lib/docs/sv/toolbar/minify.mdx
@@ -3,12 +3,12 @@ title: Minimera
---
-# { title }
+# { title }
Detta verktyg kan användas för att minska antalet GPS-punkter i en spårning, vilket kan vara användbart för att minimera dess storlek.
diff --git a/website/src/lib/docs/sv/toolbar/poi.mdx b/website/src/lib/docs/sv/toolbar/poi.mdx
index 23ceb0e5..2f187e9b 100644
--- a/website/src/lib/docs/sv/toolbar/poi.mdx
+++ b/website/src/lib/docs/sv/toolbar/poi.mdx
@@ -3,7 +3,7 @@ title: Points of interest
---
diff --git a/website/src/lib/docs/sv/toolbar/routing.mdx b/website/src/lib/docs/sv/toolbar/routing.mdx
index 5ece1085..0b30fa45 100644
--- a/website/src/lib/docs/sv/toolbar/routing.mdx
+++ b/website/src/lib/docs/sv/toolbar/routing.mdx
@@ -3,7 +3,7 @@ title: Route planning and editing
---
diff --git a/website/src/lib/docs/sv/toolbar/time.mdx b/website/src/lib/docs/sv/toolbar/time.mdx
index b0fed523..799dbea8 100644
--- a/website/src/lib/docs/sv/toolbar/time.mdx
+++ b/website/src/lib/docs/sv/toolbar/time.mdx
@@ -3,7 +3,7 @@ title: Time
---
diff --git a/website/src/lib/docs/tr/files-and-stats.mdx b/website/src/lib/docs/tr/files-and-stats.mdx
index e8e8d102..d1683a4b 100644
--- a/website/src/lib/docs/tr/files-and-stats.mdx
+++ b/website/src/lib/docs/tr/files-and-stats.mdx
@@ -3,7 +3,7 @@ title: Dosyalar ve istatistikler
---
# { title }
diff --git a/website/src/lib/docs/tr/home/funding.mdx b/website/src/lib/docs/tr/home/funding.mdx
index 77a48daf..a8f612eb 100644
--- a/website/src/lib/docs/tr/home/funding.mdx
+++ b/website/src/lib/docs/tr/home/funding.mdx
@@ -1,5 +1,5 @@
## Web sayfasının ücretsiz (ve reklamsız) kalması için yardım et
diff --git a/website/src/lib/docs/tr/home/translation.mdx b/website/src/lib/docs/tr/home/translation.mdx
index dbfc5b84..52b495f2 100644
--- a/website/src/lib/docs/tr/home/translation.mdx
+++ b/website/src/lib/docs/tr/home/translation.mdx
@@ -1,5 +1,5 @@
## Çeviri
diff --git a/website/src/lib/docs/tr/map-controls.mdx b/website/src/lib/docs/tr/map-controls.mdx
index 4e3fb72d..ff75715d 100644
--- a/website/src/lib/docs/tr/map-controls.mdx
+++ b/website/src/lib/docs/tr/map-controls.mdx
@@ -3,7 +3,7 @@ title: Harita Kontrolleri
---
diff --git a/website/src/lib/docs/tr/menu/edit.mdx b/website/src/lib/docs/tr/menu/edit.mdx
index e9836bf4..6b78a39c 100644
--- a/website/src/lib/docs/tr/menu/edit.mdx
+++ b/website/src/lib/docs/tr/menu/edit.mdx
@@ -3,7 +3,7 @@ title: Düzenleme işlemleri
---
diff --git a/website/src/lib/docs/tr/menu/file.mdx b/website/src/lib/docs/tr/menu/file.mdx
index 05cedfee..9ceae4c4 100644
--- a/website/src/lib/docs/tr/menu/file.mdx
+++ b/website/src/lib/docs/tr/menu/file.mdx
@@ -3,7 +3,7 @@ title: Dosya işlemleri
---
diff --git a/website/src/lib/docs/tr/menu/settings.mdx b/website/src/lib/docs/tr/menu/settings.mdx
index c559ced4..51993b66 100644
--- a/website/src/lib/docs/tr/menu/settings.mdx
+++ b/website/src/lib/docs/tr/menu/settings.mdx
@@ -3,7 +3,7 @@ title: Ayarlar
---
diff --git a/website/src/lib/docs/tr/menu/view.mdx b/website/src/lib/docs/tr/menu/view.mdx
index 1a8cf6b4..878c763d 100644
--- a/website/src/lib/docs/tr/menu/view.mdx
+++ b/website/src/lib/docs/tr/menu/view.mdx
@@ -3,7 +3,7 @@ title: Görünüm seçenekleri
---
diff --git a/website/src/lib/docs/tr/toolbar/clean.mdx b/website/src/lib/docs/tr/toolbar/clean.mdx
index c0453264..5938b0df 100644
--- a/website/src/lib/docs/tr/toolbar/clean.mdx
+++ b/website/src/lib/docs/tr/toolbar/clean.mdx
@@ -3,7 +3,7 @@ title: Temizle
---
diff --git a/website/src/lib/docs/tr/toolbar/elevation.mdx b/website/src/lib/docs/tr/toolbar/elevation.mdx
index 0b93b6b5..3ecb8834 100644
--- a/website/src/lib/docs/tr/toolbar/elevation.mdx
+++ b/website/src/lib/docs/tr/toolbar/elevation.mdx
@@ -3,7 +3,7 @@ title: Yükseklik
---
diff --git a/website/src/lib/docs/tr/toolbar/extract.mdx b/website/src/lib/docs/tr/toolbar/extract.mdx
index 749ffc10..7693390a 100644
--- a/website/src/lib/docs/tr/toolbar/extract.mdx
+++ b/website/src/lib/docs/tr/toolbar/extract.mdx
@@ -3,7 +3,7 @@ title: Çıkar
---
diff --git a/website/src/lib/docs/tr/toolbar/merge.mdx b/website/src/lib/docs/tr/toolbar/merge.mdx
index b3082956..54f433d3 100644
--- a/website/src/lib/docs/tr/toolbar/merge.mdx
+++ b/website/src/lib/docs/tr/toolbar/merge.mdx
@@ -3,7 +3,7 @@ title: Birleştir
---
diff --git a/website/src/lib/docs/tr/toolbar/minify.mdx b/website/src/lib/docs/tr/toolbar/minify.mdx
index dcc30f85..2123fad2 100644
--- a/website/src/lib/docs/tr/toolbar/minify.mdx
+++ b/website/src/lib/docs/tr/toolbar/minify.mdx
@@ -3,12 +3,12 @@ title: Küçült
---
-# { title }
+# { title }
Bu araç iz içinde bulunan GPS noktalarının sayısını azaltmak için kullanılır. Dosya boyutunu azaltmak için kullanışlı olabilir.
diff --git a/website/src/lib/docs/tr/toolbar/poi.mdx b/website/src/lib/docs/tr/toolbar/poi.mdx
index 9bc1d217..4ae838c3 100644
--- a/website/src/lib/docs/tr/toolbar/poi.mdx
+++ b/website/src/lib/docs/tr/toolbar/poi.mdx
@@ -3,7 +3,7 @@ title: İlgi alanları
---
diff --git a/website/src/lib/docs/tr/toolbar/routing.mdx b/website/src/lib/docs/tr/toolbar/routing.mdx
index 6deccf1f..96dcf821 100644
--- a/website/src/lib/docs/tr/toolbar/routing.mdx
+++ b/website/src/lib/docs/tr/toolbar/routing.mdx
@@ -3,7 +3,7 @@ title: Güzergah planlama ve düzenleme
---
diff --git a/website/src/lib/docs/tr/toolbar/time.mdx b/website/src/lib/docs/tr/toolbar/time.mdx
index 07e21c71..ef25eb24 100644
--- a/website/src/lib/docs/tr/toolbar/time.mdx
+++ b/website/src/lib/docs/tr/toolbar/time.mdx
@@ -3,7 +3,7 @@ title: Zaman
---
diff --git a/website/src/lib/docs/uk/files-and-stats.mdx b/website/src/lib/docs/uk/files-and-stats.mdx
index 19cf4e98..6bad33ea 100644
--- a/website/src/lib/docs/uk/files-and-stats.mdx
+++ b/website/src/lib/docs/uk/files-and-stats.mdx
@@ -3,7 +3,7 @@ title: Files and statistics
---
# { title }
diff --git a/website/src/lib/docs/uk/home/funding.mdx b/website/src/lib/docs/uk/home/funding.mdx
index 93c7014f..9ec64d32 100644
--- a/website/src/lib/docs/uk/home/funding.mdx
+++ b/website/src/lib/docs/uk/home/funding.mdx
@@ -1,5 +1,5 @@
## Help keep the website free (and ad-free)
diff --git a/website/src/lib/docs/uk/home/translation.mdx b/website/src/lib/docs/uk/home/translation.mdx
index 1299512e..e8ba45f6 100644
--- a/website/src/lib/docs/uk/home/translation.mdx
+++ b/website/src/lib/docs/uk/home/translation.mdx
@@ -1,5 +1,5 @@
## Translation
diff --git a/website/src/lib/docs/uk/map-controls.mdx b/website/src/lib/docs/uk/map-controls.mdx
index 8eee6884..a880fb51 100644
--- a/website/src/lib/docs/uk/map-controls.mdx
+++ b/website/src/lib/docs/uk/map-controls.mdx
@@ -3,7 +3,7 @@ title: Map controls
---
diff --git a/website/src/lib/docs/uk/menu/edit.mdx b/website/src/lib/docs/uk/menu/edit.mdx
index cbcdd96e..ac0b4e9a 100644
--- a/website/src/lib/docs/uk/menu/edit.mdx
+++ b/website/src/lib/docs/uk/menu/edit.mdx
@@ -3,7 +3,7 @@ title: Edit actions
---
diff --git a/website/src/lib/docs/uk/menu/file.mdx b/website/src/lib/docs/uk/menu/file.mdx
index 5ef690e2..ab910a6d 100644
--- a/website/src/lib/docs/uk/menu/file.mdx
+++ b/website/src/lib/docs/uk/menu/file.mdx
@@ -3,7 +3,7 @@ title: File actions
---
diff --git a/website/src/lib/docs/uk/menu/settings.mdx b/website/src/lib/docs/uk/menu/settings.mdx
index 8c529729..6fdf26cd 100644
--- a/website/src/lib/docs/uk/menu/settings.mdx
+++ b/website/src/lib/docs/uk/menu/settings.mdx
@@ -3,7 +3,7 @@ title: Settings
---
diff --git a/website/src/lib/docs/uk/menu/view.mdx b/website/src/lib/docs/uk/menu/view.mdx
index 0e6ff3f3..84bc48ed 100644
--- a/website/src/lib/docs/uk/menu/view.mdx
+++ b/website/src/lib/docs/uk/menu/view.mdx
@@ -3,7 +3,7 @@ title: View options
---
diff --git a/website/src/lib/docs/uk/toolbar/clean.mdx b/website/src/lib/docs/uk/toolbar/clean.mdx
index e8b8ffc5..5b98149f 100644
--- a/website/src/lib/docs/uk/toolbar/clean.mdx
+++ b/website/src/lib/docs/uk/toolbar/clean.mdx
@@ -3,7 +3,7 @@ title: Clean
---
diff --git a/website/src/lib/docs/uk/toolbar/elevation.mdx b/website/src/lib/docs/uk/toolbar/elevation.mdx
index 8fb869d5..3ba9b759 100644
--- a/website/src/lib/docs/uk/toolbar/elevation.mdx
+++ b/website/src/lib/docs/uk/toolbar/elevation.mdx
@@ -3,7 +3,7 @@ title: Elevation
---
diff --git a/website/src/lib/docs/uk/toolbar/extract.mdx b/website/src/lib/docs/uk/toolbar/extract.mdx
index 737c451d..a8fd74c5 100644
--- a/website/src/lib/docs/uk/toolbar/extract.mdx
+++ b/website/src/lib/docs/uk/toolbar/extract.mdx
@@ -3,7 +3,7 @@ title: Extract
---
diff --git a/website/src/lib/docs/uk/toolbar/merge.mdx b/website/src/lib/docs/uk/toolbar/merge.mdx
index 11ca1f1d..6b0413cd 100644
--- a/website/src/lib/docs/uk/toolbar/merge.mdx
+++ b/website/src/lib/docs/uk/toolbar/merge.mdx
@@ -3,7 +3,7 @@ title: Merge
---
diff --git a/website/src/lib/docs/uk/toolbar/minify.mdx b/website/src/lib/docs/uk/toolbar/minify.mdx
index 11b53248..2f50d7c6 100644
--- a/website/src/lib/docs/uk/toolbar/minify.mdx
+++ b/website/src/lib/docs/uk/toolbar/minify.mdx
@@ -3,12 +3,12 @@ title: Minify
---
-# { title }
+# { title }
This tool can be used to reduce the number of GPS points in a trace, which can be useful for decreasing its size.
diff --git a/website/src/lib/docs/uk/toolbar/poi.mdx b/website/src/lib/docs/uk/toolbar/poi.mdx
index 6cdc531f..c677df5f 100644
--- a/website/src/lib/docs/uk/toolbar/poi.mdx
+++ b/website/src/lib/docs/uk/toolbar/poi.mdx
@@ -3,7 +3,7 @@ title: Points of interest
---
diff --git a/website/src/lib/docs/uk/toolbar/routing.mdx b/website/src/lib/docs/uk/toolbar/routing.mdx
index dfed41da..bdb26d7c 100644
--- a/website/src/lib/docs/uk/toolbar/routing.mdx
+++ b/website/src/lib/docs/uk/toolbar/routing.mdx
@@ -3,7 +3,7 @@ title: Route planning and editing
---
diff --git a/website/src/lib/docs/uk/toolbar/time.mdx b/website/src/lib/docs/uk/toolbar/time.mdx
index 4b016114..6e7afcb2 100644
--- a/website/src/lib/docs/uk/toolbar/time.mdx
+++ b/website/src/lib/docs/uk/toolbar/time.mdx
@@ -3,7 +3,7 @@ title: Time
---
diff --git a/website/src/lib/docs/vi/files-and-stats.mdx b/website/src/lib/docs/vi/files-and-stats.mdx
index 19cf4e98..6bad33ea 100644
--- a/website/src/lib/docs/vi/files-and-stats.mdx
+++ b/website/src/lib/docs/vi/files-and-stats.mdx
@@ -3,7 +3,7 @@ title: Files and statistics
---
# { title }
diff --git a/website/src/lib/docs/vi/home/funding.mdx b/website/src/lib/docs/vi/home/funding.mdx
index 7c4ff031..7cd12eab 100644
--- a/website/src/lib/docs/vi/home/funding.mdx
+++ b/website/src/lib/docs/vi/home/funding.mdx
@@ -1,5 +1,5 @@
## Hãy giúp cho website hoạt động hoàn toàn miễn phí (không quảng cáo)
diff --git a/website/src/lib/docs/vi/home/translation.mdx b/website/src/lib/docs/vi/home/translation.mdx
index 1f54612c..b448ff0e 100644
--- a/website/src/lib/docs/vi/home/translation.mdx
+++ b/website/src/lib/docs/vi/home/translation.mdx
@@ -1,5 +1,5 @@
## Dịch thuật
diff --git a/website/src/lib/docs/vi/map-controls.mdx b/website/src/lib/docs/vi/map-controls.mdx
index 8eee6884..a880fb51 100644
--- a/website/src/lib/docs/vi/map-controls.mdx
+++ b/website/src/lib/docs/vi/map-controls.mdx
@@ -3,7 +3,7 @@ title: Map controls
---
diff --git a/website/src/lib/docs/vi/menu/edit.mdx b/website/src/lib/docs/vi/menu/edit.mdx
index cbcdd96e..ac0b4e9a 100644
--- a/website/src/lib/docs/vi/menu/edit.mdx
+++ b/website/src/lib/docs/vi/menu/edit.mdx
@@ -3,7 +3,7 @@ title: Edit actions
---
diff --git a/website/src/lib/docs/vi/menu/file.mdx b/website/src/lib/docs/vi/menu/file.mdx
index 5ef690e2..ab910a6d 100644
--- a/website/src/lib/docs/vi/menu/file.mdx
+++ b/website/src/lib/docs/vi/menu/file.mdx
@@ -3,7 +3,7 @@ title: File actions
---
diff --git a/website/src/lib/docs/vi/menu/settings.mdx b/website/src/lib/docs/vi/menu/settings.mdx
index ee1b218e..7daa89ba 100644
--- a/website/src/lib/docs/vi/menu/settings.mdx
+++ b/website/src/lib/docs/vi/menu/settings.mdx
@@ -3,7 +3,7 @@ title: Settings
---
diff --git a/website/src/lib/docs/vi/menu/view.mdx b/website/src/lib/docs/vi/menu/view.mdx
index 0e6ff3f3..84bc48ed 100644
--- a/website/src/lib/docs/vi/menu/view.mdx
+++ b/website/src/lib/docs/vi/menu/view.mdx
@@ -3,7 +3,7 @@ title: View options
---
diff --git a/website/src/lib/docs/vi/toolbar/clean.mdx b/website/src/lib/docs/vi/toolbar/clean.mdx
index e8b8ffc5..5b98149f 100644
--- a/website/src/lib/docs/vi/toolbar/clean.mdx
+++ b/website/src/lib/docs/vi/toolbar/clean.mdx
@@ -3,7 +3,7 @@ title: Clean
---
diff --git a/website/src/lib/docs/vi/toolbar/elevation.mdx b/website/src/lib/docs/vi/toolbar/elevation.mdx
index 8fb869d5..3ba9b759 100644
--- a/website/src/lib/docs/vi/toolbar/elevation.mdx
+++ b/website/src/lib/docs/vi/toolbar/elevation.mdx
@@ -3,7 +3,7 @@ title: Elevation
---
diff --git a/website/src/lib/docs/vi/toolbar/extract.mdx b/website/src/lib/docs/vi/toolbar/extract.mdx
index 737c451d..a8fd74c5 100644
--- a/website/src/lib/docs/vi/toolbar/extract.mdx
+++ b/website/src/lib/docs/vi/toolbar/extract.mdx
@@ -3,7 +3,7 @@ title: Extract
---
diff --git a/website/src/lib/docs/vi/toolbar/merge.mdx b/website/src/lib/docs/vi/toolbar/merge.mdx
index 11ca1f1d..6b0413cd 100644
--- a/website/src/lib/docs/vi/toolbar/merge.mdx
+++ b/website/src/lib/docs/vi/toolbar/merge.mdx
@@ -3,7 +3,7 @@ title: Merge
---
diff --git a/website/src/lib/docs/vi/toolbar/minify.mdx b/website/src/lib/docs/vi/toolbar/minify.mdx
index 11b53248..2f50d7c6 100644
--- a/website/src/lib/docs/vi/toolbar/minify.mdx
+++ b/website/src/lib/docs/vi/toolbar/minify.mdx
@@ -3,12 +3,12 @@ title: Minify
---
-# { title }
+# { title }
This tool can be used to reduce the number of GPS points in a trace, which can be useful for decreasing its size.
diff --git a/website/src/lib/docs/vi/toolbar/poi.mdx b/website/src/lib/docs/vi/toolbar/poi.mdx
index 6cdc531f..c677df5f 100644
--- a/website/src/lib/docs/vi/toolbar/poi.mdx
+++ b/website/src/lib/docs/vi/toolbar/poi.mdx
@@ -3,7 +3,7 @@ title: Points of interest
---
diff --git a/website/src/lib/docs/vi/toolbar/routing.mdx b/website/src/lib/docs/vi/toolbar/routing.mdx
index dfed41da..bdb26d7c 100644
--- a/website/src/lib/docs/vi/toolbar/routing.mdx
+++ b/website/src/lib/docs/vi/toolbar/routing.mdx
@@ -3,7 +3,7 @@ title: Route planning and editing
---
diff --git a/website/src/lib/docs/vi/toolbar/time.mdx b/website/src/lib/docs/vi/toolbar/time.mdx
index 4b016114..6e7afcb2 100644
--- a/website/src/lib/docs/vi/toolbar/time.mdx
+++ b/website/src/lib/docs/vi/toolbar/time.mdx
@@ -3,7 +3,7 @@ title: Time
---
diff --git a/website/src/lib/docs/zh/files-and-stats.mdx b/website/src/lib/docs/zh/files-and-stats.mdx
index 60fe2f1c..843f015f 100644
--- a/website/src/lib/docs/zh/files-and-stats.mdx
+++ b/website/src/lib/docs/zh/files-and-stats.mdx
@@ -3,7 +3,7 @@ title: 文件和统计
---
# { title }
diff --git a/website/src/lib/docs/zh/home/funding.mdx b/website/src/lib/docs/zh/home/funding.mdx
index a664c204..ba47f3d5 100644
--- a/website/src/lib/docs/zh/home/funding.mdx
+++ b/website/src/lib/docs/zh/home/funding.mdx
@@ -1,5 +1,5 @@
## 帮助网站保持免费(且无广告)
diff --git a/website/src/lib/docs/zh/home/translation.mdx b/website/src/lib/docs/zh/home/translation.mdx
index 126804f6..32ba1f99 100644
--- a/website/src/lib/docs/zh/home/translation.mdx
+++ b/website/src/lib/docs/zh/home/translation.mdx
@@ -1,5 +1,5 @@
## 翻译
diff --git a/website/src/lib/docs/zh/map-controls.mdx b/website/src/lib/docs/zh/map-controls.mdx
index 076807f5..6272f7c1 100644
--- a/website/src/lib/docs/zh/map-controls.mdx
+++ b/website/src/lib/docs/zh/map-controls.mdx
@@ -3,7 +3,7 @@ title: 地图控件
---
diff --git a/website/src/lib/docs/zh/menu/edit.mdx b/website/src/lib/docs/zh/menu/edit.mdx
index dea3b54b..78033959 100644
--- a/website/src/lib/docs/zh/menu/edit.mdx
+++ b/website/src/lib/docs/zh/menu/edit.mdx
@@ -3,7 +3,7 @@ title: 编辑
---
diff --git a/website/src/lib/docs/zh/menu/file.mdx b/website/src/lib/docs/zh/menu/file.mdx
index a064ac7d..2865d2a8 100644
--- a/website/src/lib/docs/zh/menu/file.mdx
+++ b/website/src/lib/docs/zh/menu/file.mdx
@@ -3,7 +3,7 @@ title: 文件
---
diff --git a/website/src/lib/docs/zh/menu/settings.mdx b/website/src/lib/docs/zh/menu/settings.mdx
index 68d199f4..6feebc7d 100644
--- a/website/src/lib/docs/zh/menu/settings.mdx
+++ b/website/src/lib/docs/zh/menu/settings.mdx
@@ -3,7 +3,7 @@ title: 设置
---
diff --git a/website/src/lib/docs/zh/menu/view.mdx b/website/src/lib/docs/zh/menu/view.mdx
index 149c0a87..954976b9 100644
--- a/website/src/lib/docs/zh/menu/view.mdx
+++ b/website/src/lib/docs/zh/menu/view.mdx
@@ -3,7 +3,7 @@ title: 显示
---
diff --git a/website/src/lib/docs/zh/toolbar/clean.mdx b/website/src/lib/docs/zh/toolbar/clean.mdx
index 5aed92d6..d75fa930 100644
--- a/website/src/lib/docs/zh/toolbar/clean.mdx
+++ b/website/src/lib/docs/zh/toolbar/clean.mdx
@@ -3,7 +3,7 @@ title: 使用选区清除要素
---
diff --git a/website/src/lib/docs/zh/toolbar/elevation.mdx b/website/src/lib/docs/zh/toolbar/elevation.mdx
index 9b9bbfb3..9c8107f1 100644
--- a/website/src/lib/docs/zh/toolbar/elevation.mdx
+++ b/website/src/lib/docs/zh/toolbar/elevation.mdx
@@ -3,7 +3,7 @@ title: 请求海拔数据
---
diff --git a/website/src/lib/docs/zh/toolbar/extract.mdx b/website/src/lib/docs/zh/toolbar/extract.mdx
index 0dca672f..1e1eb67e 100644
--- a/website/src/lib/docs/zh/toolbar/extract.mdx
+++ b/website/src/lib/docs/zh/toolbar/extract.mdx
@@ -3,7 +3,7 @@ title: 提取为多个独立要素
---
diff --git a/website/src/lib/docs/zh/toolbar/merge.mdx b/website/src/lib/docs/zh/toolbar/merge.mdx
index 92bf37f5..1a81b0ca 100644
--- a/website/src/lib/docs/zh/toolbar/merge.mdx
+++ b/website/src/lib/docs/zh/toolbar/merge.mdx
@@ -3,7 +3,7 @@ title: 合并要素
---
diff --git a/website/src/lib/docs/zh/toolbar/minify.mdx b/website/src/lib/docs/zh/toolbar/minify.mdx
index d37af954..a0f066f5 100644
--- a/website/src/lib/docs/zh/toolbar/minify.mdx
+++ b/website/src/lib/docs/zh/toolbar/minify.mdx
@@ -3,12 +3,12 @@ title: 精简 GPS 点数量
---
-# { title }
+# { title }
该工具通过减少轨迹中 GPS 点的数量来压缩文件。
diff --git a/website/src/lib/docs/zh/toolbar/poi.mdx b/website/src/lib/docs/zh/toolbar/poi.mdx
index 2d65767d..5d33e53a 100644
--- a/website/src/lib/docs/zh/toolbar/poi.mdx
+++ b/website/src/lib/docs/zh/toolbar/poi.mdx
@@ -3,7 +3,7 @@ title: 创建或编辑兴趣点
---
diff --git a/website/src/lib/docs/zh/toolbar/routing.mdx b/website/src/lib/docs/zh/toolbar/routing.mdx
index 54a14144..33dfa7ef 100644
--- a/website/src/lib/docs/zh/toolbar/routing.mdx
+++ b/website/src/lib/docs/zh/toolbar/routing.mdx
@@ -3,7 +3,7 @@ title: 规划或编辑路线
---
diff --git a/website/src/lib/docs/zh/toolbar/time.mdx b/website/src/lib/docs/zh/toolbar/time.mdx
index f809795f..dd939770 100644
--- a/website/src/lib/docs/zh/toolbar/time.mdx
+++ b/website/src/lib/docs/zh/toolbar/time.mdx
@@ -3,7 +3,7 @@ title: 管理时间数据
---
diff --git a/website/src/lib/i18n.svelte.ts b/website/src/lib/i18n.svelte.ts
new file mode 100644
index 00000000..d1f2c58d
--- /dev/null
+++ b/website/src/lib/i18n.svelte.ts
@@ -0,0 +1,72 @@
+type Dictionary = {
+ [key: string]: string | Dictionary;
+};
+
+function getDateFormatter(locale: string) {
+ return new Intl.DateTimeFormat(locale, {
+ dateStyle: 'medium',
+ timeStyle: 'medium',
+ });
+}
+
+class Locale {
+ private _lang = $state('');
+ private _isLoadingInitial = $state(true);
+ private _isLoading = $state(true);
+ private dictionary: Dictionary = $state({});
+ private _t = $derived((key: string) => {
+ const keys = key.split('.');
+ let value: string | Dictionary = this.dictionary;
+
+ for (const k of keys) {
+ if (value && typeof value === 'object' && k in value) {
+ value = value[k];
+ } else {
+ return key;
+ }
+ }
+
+ return typeof value === 'string' ? value : key;
+ });
+ private _df = $derived(getDateFormatter(this._lang === '' ? 'en' : this._lang));
+
+ public set lang(lang: string) {
+ this._lang = lang;
+ if (this._lang !== '') {
+ if (!this._isLoading) {
+ this._isLoading = true;
+ }
+ import(`../locales/${this._lang}.json`).then((module) => {
+ this.dictionary = module.default;
+ if (this._isLoadingInitial) {
+ this._isLoadingInitial = false;
+ }
+ if (this._isLoading) {
+ this._isLoading = false;
+ }
+ });
+ }
+ }
+
+ public get lang() {
+ return this._lang;
+ }
+
+ public get isLoading() {
+ return this._isLoading;
+ }
+
+ public get isLoadingInitial() {
+ return this._isLoadingInitial;
+ }
+
+ public get _() {
+ return this._t;
+ }
+
+ public get df() {
+ return this._df;
+ }
+}
+
+export const i18n = new Locale();
diff --git a/website/src/lib/i18n.ts b/website/src/lib/i18n.ts
deleted file mode 100644
index 91efd6b6..00000000
--- a/website/src/lib/i18n.ts
+++ /dev/null
@@ -1,56 +0,0 @@
-import { derived, writable, get } from 'svelte/store';
-
-export const locale = writable('');
-
-type Dictionary = {
- [key: string]: string | Dictionary;
-};
-export const dictionary = writable({});
-
-export const isLoadingInitialLocale = writable(true);
-export const isLoadingLocale = writable(true);
-
-locale.subscribe((lang) => {
- if (lang !== '') {
- if (!get(isLoadingLocale)) {
- isLoadingLocale.set(true);
- }
- import(`../locales/${lang}.json`).then((module) => {
- dictionary.set(module.default);
- if (get(isLoadingInitialLocale)) {
- isLoadingInitialLocale.set(false);
- }
- if (get(isLoadingLocale)) {
- isLoadingLocale.set(false);
- }
- });
- }
-});
-
-export const _ = derived(dictionary, ($dictionary) => {
- return (key: string) => {
- const keys = key.split('.');
- let value: string | Dictionary = $dictionary;
-
- for (const k of keys) {
- if (value && typeof value === 'object' && k in value) {
- value = value[k];
- } else {
- return key;
- }
- }
-
- return typeof value === 'string' ? value : key;
- };
-});
-
-function getDateFormatter(locale: string) {
- return new Intl.DateTimeFormat(locale, {
- dateStyle: 'medium',
- timeStyle: 'medium',
- });
-}
-
-export const df = derived(locale, ($locale) => {
- return getDateFormatter($locale === '' ? 'en-US' : $locale);
-});
diff --git a/website/src/lib/logic/files.svelte.ts b/website/src/lib/logic/files.svelte.ts
new file mode 100644
index 00000000..166a99f0
--- /dev/null
+++ b/website/src/lib/logic/files.svelte.ts
@@ -0,0 +1,40 @@
+import { updateAnchorPoints } from '$lib/components/toolbar/tools/routing/Simplify';
+import { GPXStatisticsTree, type Database } from '$lib/db';
+import { liveQuery } from 'dexie';
+import { GPXFile } from 'gpx';
+
+class GPXFileState {
+ private _db: Database;
+ private _file: GPXFile | undefined;
+
+ constructor(db: Database, fileId: string, file: GPXFile) {
+ this._db = db;
+ this._file = $state(undefined);
+
+ liveQuery(() => db.files.get(fileId)).subscribe((value) => {
+ if (value !== undefined) {
+ let gpx = new GPXFile(value);
+ updateAnchorPoints(gpx);
+
+ let statistics = new GPXStatisticsTree(gpx);
+ if (!fileState.has(id)) {
+ // Update the map bounds for new files
+ updateTargetMapBounds(
+ id,
+ statistics.getStatisticsFor(new ListFileItem(id)).global.bounds
+ );
+ }
+
+ fileState.set(id, gpx);
+ store.set({
+ file: gpx,
+ statistics,
+ });
+
+ if (get(selection).hasAnyChildren(new ListFileItem(id))) {
+ updateAllHidden();
+ }
+ }
+ });
+ }
+}
diff --git a/website/src/lib/logic/selection.svelte.ts b/website/src/lib/logic/selection.svelte.ts
new file mode 100644
index 00000000..32f47a99
--- /dev/null
+++ b/website/src/lib/logic/selection.svelte.ts
@@ -0,0 +1,375 @@
+import { get, writable } from 'svelte/store';
+import {
+ ListFileItem,
+ ListItem,
+ ListRootItem,
+ ListTrackItem,
+ ListTrackSegmentItem,
+ ListWaypointItem,
+ ListLevel,
+ sortItems,
+ ListWaypointsItem,
+ moveItems,
+} from './FileList';
+import { fileObservers, getFile, getFileIds, settings } from '$lib/db';
+
+export class SelectionTreeType {
+ item: ListItem;
+ selected: boolean;
+ children: {
+ [key: string | number]: SelectionTreeType;
+ };
+ size: number = 0;
+
+ constructor(item: ListItem) {
+ this.item = item;
+ this.selected = false;
+ this.children = {};
+ }
+
+ clear() {
+ this.selected = false;
+ for (let key in this.children) {
+ this.children[key].clear();
+ }
+ this.size = 0;
+ }
+
+ _setOrToggle(item: ListItem, value?: boolean) {
+ if (item.level === this.item.level) {
+ let newSelected = value === undefined ? !this.selected : value;
+ if (this.selected !== newSelected) {
+ this.selected = newSelected;
+ this.size += this.selected ? 1 : -1;
+ }
+ } else {
+ let id = item.getIdAtLevel(this.item.level);
+ if (id !== undefined) {
+ if (!this.children.hasOwnProperty(id)) {
+ this.children[id] = new SelectionTreeType(this.item.extend(id));
+ }
+ this.size -= this.children[id].size;
+ this.children[id]._setOrToggle(item, value);
+ this.size += this.children[id].size;
+ }
+ }
+ }
+
+ set(item: ListItem, value: boolean) {
+ this._setOrToggle(item, value);
+ }
+
+ toggle(item: ListItem) {
+ this._setOrToggle(item);
+ }
+
+ has(item: ListItem): boolean {
+ if (item.level === this.item.level) {
+ return this.selected;
+ } else {
+ let id = item.getIdAtLevel(this.item.level);
+ if (id !== undefined) {
+ if (this.children.hasOwnProperty(id)) {
+ return this.children[id].has(item);
+ }
+ }
+ }
+ return false;
+ }
+
+ hasAnyParent(item: ListItem, self: boolean = true): boolean {
+ if (
+ this.selected &&
+ this.item.level <= item.level &&
+ (self || this.item.level < item.level)
+ ) {
+ return this.selected;
+ }
+ let id = item.getIdAtLevel(this.item.level);
+ if (id !== undefined) {
+ if (this.children.hasOwnProperty(id)) {
+ return this.children[id].hasAnyParent(item, self);
+ }
+ }
+ return false;
+ }
+
+ hasAnyChildren(item: ListItem, self: boolean = true, ignoreIds?: (string | number)[]): boolean {
+ if (
+ this.selected &&
+ this.item.level >= item.level &&
+ (self || this.item.level > item.level)
+ ) {
+ return this.selected;
+ }
+ let id = item.getIdAtLevel(this.item.level);
+ if (id !== undefined) {
+ if (ignoreIds === undefined || ignoreIds.indexOf(id) === -1) {
+ if (this.children.hasOwnProperty(id)) {
+ return this.children[id].hasAnyChildren(item, self, ignoreIds);
+ }
+ }
+ } else {
+ for (let key in this.children) {
+ if (ignoreIds === undefined || ignoreIds.indexOf(key) === -1) {
+ if (this.children[key].hasAnyChildren(item, self, ignoreIds)) {
+ return true;
+ }
+ }
+ }
+ }
+ return false;
+ }
+
+ getSelected(selection: ListItem[] = []): ListItem[] {
+ if (this.selected) {
+ selection.push(this.item);
+ }
+ for (let key in this.children) {
+ this.children[key].getSelected(selection);
+ }
+ return selection;
+ }
+
+ forEach(callback: (item: ListItem) => void) {
+ if (this.selected) {
+ callback(this.item);
+ }
+ for (let key in this.children) {
+ this.children[key].forEach(callback);
+ }
+ }
+
+ getChild(id: string | number): SelectionTreeType | undefined {
+ return this.children[id];
+ }
+
+ deleteChild(id: string | number) {
+ if (this.children.hasOwnProperty(id)) {
+ this.size -= this.children[id].size;
+ delete this.children[id];
+ }
+ }
+}
+
+export const selection = writable(new SelectionTreeType(new ListRootItem()));
+
+export function selectItem(item: ListItem) {
+ selection.update(($selection) => {
+ $selection.clear();
+ $selection.set(item, true);
+ return $selection;
+ });
+}
+
+export function selectFile(fileId: string) {
+ selectItem(new ListFileItem(fileId));
+}
+
+export function addSelectItem(item: ListItem) {
+ selection.update(($selection) => {
+ $selection.toggle(item);
+ return $selection;
+ });
+}
+
+export function addSelectFile(fileId: string) {
+ addSelectItem(new ListFileItem(fileId));
+}
+
+export function selectAll() {
+ selection.update(($selection) => {
+ let item: ListItem = new ListRootItem();
+ $selection.forEach((i) => {
+ item = i;
+ });
+
+ if (item instanceof ListRootItem || item instanceof ListFileItem) {
+ $selection.clear();
+ get(fileObservers).forEach((_file, fileId) => {
+ $selection.set(new ListFileItem(fileId), true);
+ });
+ } else if (item instanceof ListTrackItem) {
+ let file = getFile(item.getFileId());
+ if (file) {
+ file.trk.forEach((_track, trackId) => {
+ $selection.set(new ListTrackItem(item.getFileId(), trackId), true);
+ });
+ }
+ } else if (item instanceof ListTrackSegmentItem) {
+ let file = getFile(item.getFileId());
+ if (file) {
+ file.trk[item.getTrackIndex()].trkseg.forEach((_segment, segmentId) => {
+ $selection.set(
+ new ListTrackSegmentItem(item.getFileId(), item.getTrackIndex(), segmentId),
+ true
+ );
+ });
+ }
+ } else if (item instanceof ListWaypointItem) {
+ let file = getFile(item.getFileId());
+ if (file) {
+ file.wpt.forEach((_waypoint, waypointId) => {
+ $selection.set(new ListWaypointItem(item.getFileId(), waypointId), true);
+ });
+ }
+ }
+
+ return $selection;
+ });
+}
+
+export function getOrderedSelection(reverse: boolean = false): ListItem[] {
+ let selected: ListItem[] = [];
+ applyToOrderedSelectedItemsFromFile((fileId, level, items) => {
+ selected.push(...items);
+ }, reverse);
+ return selected;
+}
+
+export function applyToOrderedItemsFromFile(
+ selectedItems: ListItem[],
+ callback: (fileId: string, level: ListLevel | undefined, items: ListItem[]) => void,
+ reverse: boolean = true
+) {
+ settings.fileOrder.value.forEach((fileId) => {
+ let level: ListLevel | undefined = undefined;
+ let items: ListItem[] = [];
+ selectedItems.forEach((item) => {
+ if (item.getFileId() === fileId) {
+ level = item.level;
+ if (
+ item instanceof ListFileItem ||
+ item instanceof ListTrackItem ||
+ item instanceof ListTrackSegmentItem ||
+ item instanceof ListWaypointsItem ||
+ item instanceof ListWaypointItem
+ ) {
+ items.push(item);
+ }
+ }
+ });
+
+ if (items.length > 0) {
+ sortItems(items, reverse);
+ callback(fileId, level, items);
+ }
+ });
+}
+
+export function applyToOrderedSelectedItemsFromFile(
+ callback: (fileId: string, level: ListLevel | undefined, items: ListItem[]) => void,
+ reverse: boolean = true
+) {
+ applyToOrderedItemsFromFile(get(selection).getSelected(), callback, reverse);
+}
+
+export const copied = writable(undefined);
+export const cut = writable(false);
+
+export function copySelection(): boolean {
+ let selected = get(selection).getSelected();
+ if (selected.length > 0) {
+ copied.set(selected);
+ cut.set(false);
+ return true;
+ }
+ return false;
+}
+
+export function cutSelection() {
+ if (copySelection()) {
+ cut.set(true);
+ }
+}
+
+function resetCopied() {
+ copied.set(undefined);
+ cut.set(false);
+}
+
+export function pasteSelection() {
+ let fromItems = get(copied);
+ if (fromItems === undefined || fromItems.length === 0) {
+ return;
+ }
+
+ let selected = get(selection).getSelected();
+ if (selected.length === 0) {
+ selected = [new ListRootItem()];
+ }
+
+ let fromParent = fromItems[0].getParent();
+ let toParent = selected[selected.length - 1];
+
+ let startIndex: number | undefined = undefined;
+
+ if (fromItems[0].level === toParent.level) {
+ if (
+ toParent instanceof ListTrackItem ||
+ toParent instanceof ListTrackSegmentItem ||
+ toParent instanceof ListWaypointItem
+ ) {
+ startIndex = toParent.getId() + 1;
+ }
+ toParent = toParent.getParent();
+ }
+
+ let toItems: ListItem[] = [];
+ if (toParent.level === ListLevel.ROOT) {
+ let fileIds = getFileIds(fromItems.length);
+ fileIds.forEach((fileId) => {
+ toItems.push(new ListFileItem(fileId));
+ });
+ } else {
+ let toFile = getFile(toParent.getFileId());
+ if (toFile) {
+ fromItems.forEach((item, index) => {
+ if (toParent instanceof ListFileItem) {
+ if (item instanceof ListTrackItem || item instanceof ListTrackSegmentItem) {
+ toItems.push(
+ new ListTrackItem(
+ toParent.getFileId(),
+ (startIndex ?? toFile.trk.length) + index
+ )
+ );
+ } else if (item instanceof ListWaypointsItem) {
+ toItems.push(new ListWaypointsItem(toParent.getFileId()));
+ } else if (item instanceof ListWaypointItem) {
+ toItems.push(
+ new ListWaypointItem(
+ toParent.getFileId(),
+ (startIndex ?? toFile.wpt.length) + index
+ )
+ );
+ }
+ } else if (toParent instanceof ListTrackItem) {
+ if (item instanceof ListTrackSegmentItem) {
+ let toTrackIndex = toParent.getTrackIndex();
+ toItems.push(
+ new ListTrackSegmentItem(
+ toParent.getFileId(),
+ toTrackIndex,
+ (startIndex ?? toFile.trk[toTrackIndex].trkseg.length) + index
+ )
+ );
+ }
+ } else if (toParent instanceof ListWaypointsItem) {
+ if (item instanceof ListWaypointItem) {
+ toItems.push(
+ new ListWaypointItem(
+ toParent.getFileId(),
+ (startIndex ?? toFile.wpt.length) + index
+ )
+ );
+ }
+ }
+ });
+ }
+ }
+
+ if (fromItems.length === toItems.length) {
+ moveItems(fromParent, toParent, fromItems, toItems, get(cut));
+ resetCopied();
+ }
+}
diff --git a/website/src/lib/logic/settings.svelte.ts b/website/src/lib/logic/settings.svelte.ts
new file mode 100644
index 00000000..f8ca5b6c
--- /dev/null
+++ b/website/src/lib/logic/settings.svelte.ts
@@ -0,0 +1,121 @@
+import { db, type Database } from '$lib/db';
+import { liveQuery } from 'dexie';
+import {
+ defaultBasemap,
+ defaultBasemapTree,
+ defaultOpacities,
+ defaultOverlays,
+ defaultOverlayTree,
+ defaultOverpassQueries,
+ defaultOverpassTree,
+ type CustomLayer,
+} from '$lib/assets/layers';
+import { browser } from '$app/environment';
+
+export class Setting {
+ private _db: Database;
+ private _key: string;
+ private _value: V;
+
+ constructor(db: Database, key: string, initial: V) {
+ this._db = db;
+ this._key = key;
+ this._value = $state(initial);
+
+ let first = true;
+ liveQuery(() => db.settings.get(key)).subscribe((value) => {
+ if (value === undefined) {
+ if (!first) {
+ this._value = value;
+ }
+ } else {
+ this._value = value;
+ }
+ first = false;
+ });
+ }
+
+ get value(): V {
+ return this._value;
+ }
+
+ set value(newValue: V) {
+ if (newValue !== this._value) {
+ this._db.settings.put(newValue, this._key);
+ }
+ }
+}
+
+export class SettingInitOnFirstRead {
+ private _db: Database;
+ private _key: string;
+ private _value: V | undefined;
+
+ constructor(db: Database, key: string, initial: V) {
+ this._db = db;
+ this._key = key;
+ this._value = $state(undefined);
+
+ let first = true;
+ liveQuery(() => db.settings.get(key)).subscribe((value) => {
+ if (value === undefined) {
+ if (first) {
+ this._value = initial;
+ } else {
+ this._value = value;
+ }
+ } else {
+ this._value = value;
+ }
+ first = false;
+ });
+ }
+
+ get value(): V | undefined {
+ return this._value;
+ }
+
+ set value(newValue: V) {
+ if (newValue !== this._value) {
+ this._db.settings.put(newValue, this._key);
+ }
+ }
+}
+
+export const settings = {
+ distanceUnits: new Setting<'metric' | 'imperial' | 'nautical'>(db, 'distanceUnits', 'metric'),
+ velocityUnits: new Setting<'speed' | 'pace'>(db, 'velocityUnits', 'speed'),
+ temperatureUnits: new Setting<'celsius' | 'fahrenheit'>(db, 'temperatureUnits', 'celsius'),
+ elevationProfile: new Setting(db, 'elevationProfile', true),
+ additionalDatasets: new Setting(db, 'additionalDatasets', []),
+ elevationFill: new Setting<'slope' | 'surface' | undefined>(db, 'elevationFill', undefined),
+ treeFileView: new Setting(db, 'fileView', false),
+ minimizeRoutingMenu: new Setting(db, 'minimizeRoutingMenu', false),
+ routing: new Setting(db, 'routing', true),
+ routingProfile: new Setting(db, 'routingProfile', 'bike'),
+ privateRoads: new Setting(db, 'privateRoads', false),
+ currentBasemap: new Setting(db, 'currentBasemap', defaultBasemap),
+ previousBasemap: new Setting(db, 'previousBasemap', defaultBasemap),
+ selectedBasemapTree: new Setting(db, 'selectedBasemapTree', defaultBasemapTree),
+ currentOverlays: new SettingInitOnFirstRead(db, 'currentOverlays', defaultOverlays),
+ previousOverlays: new Setting(db, 'previousOverlays', defaultOverlays),
+ selectedOverlayTree: new Setting(db, 'selectedOverlayTree', defaultOverlayTree),
+ currentOverpassQueries: new SettingInitOnFirstRead(
+ db,
+ 'currentOverpassQueries',
+ defaultOverpassQueries
+ ),
+ selectedOverpassTree: new Setting(db, 'selectedOverpassTree', defaultOverpassTree),
+ opacities: new Setting(db, 'opacities', defaultOpacities),
+ customLayers: new Setting>(db, 'customLayers', {}),
+ customBasemapOrder: new Setting(db, 'customBasemapOrder', []),
+ customOverlayOrder: new Setting(db, 'customOverlayOrder', []),
+ directionMarkers: new Setting(db, 'directionMarkers', false),
+ distanceMarkers: new Setting(db, 'distanceMarkers', false),
+ streetViewSource: new Setting(db, 'streetViewSource', 'mapillary'),
+ fileOrder: new Setting(db, 'fileOrder', []),
+ defaultOpacity: new Setting(db, 'defaultOpacity', 0.7),
+ defaultWidth: new Setting(db, 'defaultWidth', browser && window.innerWidth < 600 ? 8 : 5),
+ bottomPanelSize: new Setting(db, 'bottomPanelSize', 170),
+ rightPanelSize: new Setting(db, 'rightPanelSize', 240),
+};
diff --git a/website/src/lib/logic/statistics.svelte.ts b/website/src/lib/logic/statistics.svelte.ts
new file mode 100644
index 00000000..e69de29b
diff --git a/website/src/lib/pwa-manifest.ts b/website/src/lib/scripts/pwa-manifest.ts
similarity index 95%
rename from website/src/lib/pwa-manifest.ts
rename to website/src/lib/scripts/pwa-manifest.ts
index 88983c6c..55857475 100644
--- a/website/src/lib/pwa-manifest.ts
+++ b/website/src/lib/scripts/pwa-manifest.ts
@@ -1,5 +1,5 @@
import fs from 'fs';
-import { languages } from './languages';
+import { languages } from '$lib/languages';
function localizeManifest(manifestTemplateData: any, language: string) {
const localizedManifestFile = `static/${language}.manifest.webmanifest`;
diff --git a/website/src/lib/sitemap.ts b/website/src/lib/scripts/sitemap.ts
similarity index 100%
rename from website/src/lib/sitemap.ts
rename to website/src/lib/scripts/sitemap.ts
diff --git a/website/src/lib/stores.ts b/website/src/lib/stores.ts
index 9b83671f..aa69e747 100644
--- a/website/src/lib/stores.ts
+++ b/website/src/lib/stores.ts
@@ -1,518 +1,219 @@
-import { writable, get, type Writable, derived } from 'svelte/store';
+// import { writable, get, type Writable } from 'svelte/store';
-import mapboxgl from 'mapbox-gl';
-import { GPXFile, buildGPX, parseGPX, GPXStatistics, type Coordinates } from 'gpx';
-import { tick } from 'svelte';
-import { _ } from '$lib/i18n';
-import type { GPXLayer } from '$lib/components/gpx-layer/GPXLayer';
-import { dbUtils, fileObservers, getFile, getStatistics, settings } from './db';
-import {
- addSelectItem,
- applyToOrderedSelectedItemsFromFile,
- selectFile,
- selectItem,
- selection,
-} from '$lib/components/file-list/Selection';
-import {
- ListFileItem,
- ListItem,
- ListTrackItem,
- ListTrackSegmentItem,
- ListWaypointItem,
- ListWaypointsItem,
-} from '$lib/components/file-list/FileList';
-import type { RoutingControls } from '$lib/components/toolbar/tools/routing/RoutingControls';
-import { SplitType } from '$lib/components/toolbar/tools/scissors/Scissors.svelte';
-import FileSaver from 'file-saver';
-import JSZip from 'jszip';
+// import { GPXFile, parseGPX, GPXStatistics } from 'gpx';
+// import { tick } from 'svelte';
+// import { i18n } from '$lib/i18n.svelte';
+// import type { GPXLayer } from '$lib/components/map/gpx-layer/GPXLayer';
+// import { dbUtils, fileObservers, getFile, getStatistics } from '$lib/db';
+// import {
+// applyToOrderedSelectedItemsFromFile,
+// selectFile,
+// selection,
+// } from '$lib/components/file-list/Selection';
+// import {
+// ListFileItem,
+// ListTrackItem,
+// ListTrackSegmentItem,
+// ListWaypointItem,
+// ListWaypointsItem,
+// } from '$lib/components/file-list/FileList';
+// import type { RoutingControls } from '$lib/components/toolbar/tools/routing/RoutingControls';
-const { fileOrder } = settings;
+// export const embedding = writable(false);
+// export const selectFiles = writable<{ [key: string]: (fileId?: string) => void }>({});
-export const map = writable(null);
-export const embedding = writable(false);
-export const selectFiles = writable<{ [key: string]: (fileId?: string) => void }>({});
+// export const gpxStatistics: Writable = writable(new GPXStatistics());
+// export const slicedGPXStatistics: Writable<[GPXStatistics, number, number] | undefined> =
+// writable(undefined);
-export const gpxStatistics: Writable = writable(new GPXStatistics());
-export const slicedGPXStatistics: Writable<[GPXStatistics, number, number] | undefined> =
- writable(undefined);
+// export function updateGPXData() {
+// let statistics = new GPXStatistics();
+// applyToOrderedSelectedItemsFromFile((fileId, level, items) => {
+// let stats = getStatistics(fileId);
+// if (stats) {
+// let first = true;
+// items.forEach((item) => {
+// if (
+// !(item instanceof ListWaypointItem || item instanceof ListWaypointsItem) ||
+// first
+// ) {
+// statistics.mergeWith(stats.getStatisticsFor(item));
+// first = false;
+// }
+// });
+// }
+// }, false);
+// gpxStatistics.set(statistics);
+// }
-export function updateGPXData() {
- let statistics = new GPXStatistics();
- applyToOrderedSelectedItemsFromFile((fileId, level, items) => {
- let stats = getStatistics(fileId);
- if (stats) {
- let first = true;
- items.forEach((item) => {
- if (
- !(item instanceof ListWaypointItem || item instanceof ListWaypointsItem) ||
- first
- ) {
- statistics.mergeWith(stats.getStatisticsFor(item));
- first = false;
- }
- });
- }
- }, false);
- gpxStatistics.set(statistics);
-}
+// let unsubscribes: Map void> = new Map();
+// selection.subscribe(($selection) => {
+// // Maintain up-to-date statistics for the current selection
+// updateGPXData();
-let unsubscribes: Map void> = new Map();
-selection.subscribe(($selection) => {
- // Maintain up-to-date statistics for the current selection
- updateGPXData();
+// while (unsubscribes.size > 0) {
+// let [fileId, unsubscribe] = unsubscribes.entries().next().value;
+// unsubscribe();
+// unsubscribes.delete(fileId);
+// }
- while (unsubscribes.size > 0) {
- let [fileId, unsubscribe] = unsubscribes.entries().next().value;
- unsubscribe();
- unsubscribes.delete(fileId);
- }
+// $selection.forEach((item) => {
+// let fileId = item.getFileId();
+// if (!unsubscribes.has(fileId)) {
+// let fileObserver = get(fileObservers).get(fileId);
+// if (fileObserver) {
+// let first = true;
+// unsubscribes.set(
+// fileId,
+// fileObserver.subscribe(() => {
+// if (first) first = false;
+// else updateGPXData();
+// })
+// );
+// }
+// }
+// });
+// });
- $selection.forEach((item) => {
- let fileId = item.getFileId();
- if (!unsubscribes.has(fileId)) {
- let fileObserver = get(fileObservers).get(fileId);
- if (fileObserver) {
- let first = true;
- unsubscribes.set(
- fileId,
- fileObserver.subscribe(() => {
- if (first) first = false;
- else updateGPXData();
- })
- );
- }
- }
- });
-});
+// gpxStatistics.subscribe(() => {
+// slicedGPXStatistics.set(undefined);
+// });
-gpxStatistics.subscribe(() => {
- slicedGPXStatistics.set(undefined);
-});
+// export const gpxLayers: Map = new Map();
+// export const routingControls: Map = new Map();
-const targetMapBounds = writable<{
- bounds: mapboxgl.LngLatBounds;
- ids: string[];
- total: number;
-}>({
- bounds: new mapboxgl.LngLatBounds([180, 90, -180, -90]),
- ids: [],
- total: 0,
-});
+// export function newGPXFile() {
+// const newFileName = i18n._('menu.new_file');
-derived([targetMapBounds, map], (x) => x).subscribe(([bounds, $map]) => {
- if (
- $map === null ||
- bounds.ids.length > 0 ||
- (bounds.bounds.getSouth() === 90 &&
- bounds.bounds.getWest() === 180 &&
- bounds.bounds.getNorth() === -90 &&
- bounds.bounds.getEast() === -180)
- ) {
- return;
- }
+// let file = new GPXFile();
- let currentZoom = $map.getZoom();
- let currentBounds = $map.getBounds();
- if (
- bounds.total !== get(fileObservers).size &&
- currentBounds &&
- currentZoom > 2 // Extend current bounds only if the map is zoomed in
- ) {
- // There are other files on the map
- if (
- currentBounds.contains(bounds.bounds.getSouthEast()) &&
- currentBounds.contains(bounds.bounds.getNorthWest())
- ) {
- return;
- }
+// let maxNewFileNumber = 0;
+// get(fileObservers).forEach((f) => {
+// let file = get(f)?.file;
+// if (file && file.metadata.name && file.metadata.name.startsWith(newFileName)) {
+// let number = parseInt(file.metadata.name.split(' ').pop() ?? '0');
+// if (!isNaN(number) && number > maxNewFileNumber) {
+// maxNewFileNumber = number;
+// }
+// }
+// });
- bounds.bounds.extend(currentBounds.getSouthWest());
- bounds.bounds.extend(currentBounds.getNorthEast());
- }
+// file.metadata.name = `${newFileName} ${maxNewFileNumber + 1}`;
- $map.fitBounds(bounds.bounds, { padding: 80, linear: true, easing: () => 1 });
-});
+// return file;
+// }
-export function initTargetMapBounds(ids: string[]) {
- targetMapBounds.set({
- bounds: new mapboxgl.LngLatBounds([180, 90, -180, -90]),
- ids,
- total: ids.length,
- });
-}
+// export function createFile() {
+// let file = newGPXFile();
-export function updateTargetMapBounds(
- id: string,
- bounds: { southWest: Coordinates; northEast: Coordinates }
-) {
- if (get(targetMapBounds).ids.indexOf(id) === -1) {
- return;
- }
+// dbUtils.add(file);
- targetMapBounds.update((target) => {
- target.ids = target.ids.filter((x) => x !== id);
- if (
- bounds.southWest.lat !== 90 ||
- bounds.southWest.lon !== 180 ||
- bounds.northEast.lat !== -90 ||
- bounds.northEast.lon !== -180
- ) {
- // Avoid update for empty (new) files
- target.bounds.extend(bounds.southWest);
- target.bounds.extend(bounds.northEast);
- }
+// selectFileWhenLoaded(file._data.id);
+// currentTool.set(Tool.ROUTING);
+// }
- return target;
- });
-}
+// export function triggerFileInput() {
+// const input = document.createElement('input');
+// input.type = 'file';
+// input.accept = '.gpx';
+// input.multiple = true;
+// input.className = 'hidden';
+// input.onchange = () => {
+// if (input.files) {
+// loadFiles(input.files);
+// }
+// };
+// input.click();
+// }
-export function centerMapOnSelection() {
- let selected = get(selection).getSelected();
- let bounds = new mapboxgl.LngLatBounds();
+// export async function loadFiles(list: FileList | File[]) {
+// let files: GPXFile[] = [];
+// for (let i = 0; i < list.length; i++) {
+// let file = await loadFile(list[i]);
+// if (file) {
+// files.push(file);
+// }
+// }
- if (selected.find((item) => item instanceof ListWaypointItem)) {
- applyToOrderedSelectedItemsFromFile((fileId, level, items) => {
- let file = getFile(fileId);
- if (file) {
- items.forEach((item) => {
- if (item instanceof ListWaypointItem) {
- let waypoint = file.wpt[item.getWaypointIndex()];
- if (waypoint) {
- bounds.extend([waypoint.getLongitude(), waypoint.getLatitude()]);
- }
- }
- });
- }
- });
- } else {
- let selectionBounds = get(gpxStatistics).global.bounds;
- bounds.setNorthEast(selectionBounds.northEast);
- bounds.setSouthWest(selectionBounds.southWest);
- }
+// let ids = dbUtils.addMultiple(files);
- get(map)?.fitBounds(bounds, {
- padding: 80,
- easing: () => 1,
- maxZoom: 15,
- });
-}
+// initTargetMapBounds(ids);
+// selectFileWhenLoaded(ids[0]);
+// }
-export const gpxLayers: Map = new Map();
-export const routingControls: Map = new Map();
+// export async function loadFile(file: File): Promise {
+// let result = await new Promise((resolve) => {
+// const reader = new FileReader();
+// reader.onload = () => {
+// let data = reader.result?.toString() ?? null;
+// if (data) {
+// let gpx = parseGPX(data);
+// if (gpx.metadata === undefined) {
+// gpx.metadata = {};
+// }
+// if (gpx.metadata.name === undefined || gpx.metadata.name.trim() === '') {
+// gpx.metadata.name = file.name.split('.').slice(0, -1).join('.');
+// }
+// resolve(gpx);
+// } else {
+// resolve(null);
+// }
+// };
+// reader.readAsText(file);
+// });
+// return result;
+// }
-export enum Tool {
- ROUTING,
- WAYPOINT,
- SCISSORS,
- TIME,
- MERGE,
- EXTRACT,
- ELEVATION,
- REDUCE,
- CLEAN,
-}
-export const currentTool = writable(null);
-export const splitAs = writable(SplitType.FILES);
-export const streetViewEnabled = writable(false);
+// export function selectFileWhenLoaded(fileId: string) {
+// const unsubscribe = fileObservers.subscribe((files) => {
+// if (files.has(fileId)) {
+// tick().then(() => {
+// selectFile(fileId);
+// });
+// unsubscribe();
+// }
+// });
+// }
-export function newGPXFile() {
- const newFileName = get(_)('menu.new_file');
+// export const allHidden = writable(false);
- let file = new GPXFile();
+// export function updateAllHidden() {
+// let hidden = true;
+// applyToOrderedSelectedItemsFromFile((fileId, level, items) => {
+// let file = getFile(fileId);
+// if (file) {
+// for (let item of items) {
+// if (!hidden) {
+// return;
+// }
- let maxNewFileNumber = 0;
- get(fileObservers).forEach((f) => {
- let file = get(f)?.file;
- if (file && file.metadata.name && file.metadata.name.startsWith(newFileName)) {
- let number = parseInt(file.metadata.name.split(' ').pop() ?? '0');
- if (!isNaN(number) && number > maxNewFileNumber) {
- maxNewFileNumber = number;
- }
- }
- });
-
- file.metadata.name = `${newFileName} ${maxNewFileNumber + 1}`;
-
- return file;
-}
-
-export function createFile() {
- let file = newGPXFile();
-
- dbUtils.add(file);
-
- selectFileWhenLoaded(file._data.id);
- currentTool.set(Tool.ROUTING);
-}
-
-export function triggerFileInput() {
- const input = document.createElement('input');
- input.type = 'file';
- input.accept = '.gpx';
- input.multiple = true;
- input.className = 'hidden';
- input.onchange = () => {
- if (input.files) {
- loadFiles(input.files);
- }
- };
- input.click();
-}
-
-export async function loadFiles(list: FileList | File[]) {
- let files: GPXFile[] = [];
- for (let i = 0; i < list.length; i++) {
- let file = await loadFile(list[i]);
- if (file) {
- files.push(file);
- }
- }
-
- let ids = dbUtils.addMultiple(files);
-
- initTargetMapBounds(ids);
- selectFileWhenLoaded(ids[0]);
-}
-
-export async function loadFile(file: File): Promise {
- let result = await new Promise((resolve) => {
- const reader = new FileReader();
- reader.onload = () => {
- let data = reader.result?.toString() ?? null;
- if (data) {
- let gpx = parseGPX(data);
- if (gpx.metadata === undefined) {
- gpx.metadata = {};
- }
- if (gpx.metadata.name === undefined || gpx.metadata.name.trim() === '') {
- gpx.metadata.name = file.name.split('.').slice(0, -1).join('.');
- }
- resolve(gpx);
- } else {
- resolve(null);
- }
- };
- reader.readAsText(file);
- });
- return result;
-}
-
-export function selectFileWhenLoaded(fileId: string) {
- const unsubscribe = fileObservers.subscribe((files) => {
- if (files.has(fileId)) {
- tick().then(() => {
- selectFile(fileId);
- });
- unsubscribe();
- }
- });
-}
-
-export function updateSelectionFromKey(down: boolean, shift: boolean) {
- let selected = get(selection).getSelected();
- if (selected.length === 0) {
- return;
- }
-
- let next: ListItem | undefined = undefined;
- if (selected[0] instanceof ListFileItem) {
- let order = get(fileOrder);
- let limitIndex: number | undefined = undefined;
- selected.forEach((item) => {
- let index = order.indexOf(item.getFileId());
- if (
- limitIndex === undefined ||
- (down && index > limitIndex) ||
- (!down && index < limitIndex)
- ) {
- limitIndex = index;
- }
- });
-
- if (limitIndex !== undefined) {
- let nextIndex = down ? limitIndex + 1 : limitIndex - 1;
-
- while (true) {
- if (nextIndex < 0) {
- nextIndex = order.length - 1;
- } else if (nextIndex >= order.length) {
- nextIndex = 0;
- }
-
- if (nextIndex === limitIndex) {
- break;
- }
-
- next = new ListFileItem(order[nextIndex]);
- if (!get(selection).has(next)) {
- break;
- }
-
- nextIndex += down ? 1 : -1;
- }
- }
- } else if (
- selected[0] instanceof ListTrackItem &&
- selected[selected.length - 1] instanceof ListTrackItem
- ) {
- let fileId = selected[0].getFileId();
- let file = getFile(fileId);
- if (file) {
- let numberOfTracks = file.trk.length;
- let trackIndex = down
- ? selected[selected.length - 1].getTrackIndex()
- : selected[0].getTrackIndex();
- if (down && trackIndex < numberOfTracks - 1) {
- next = new ListTrackItem(fileId, trackIndex + 1);
- } else if (!down && trackIndex > 0) {
- next = new ListTrackItem(fileId, trackIndex - 1);
- }
- }
- } else if (
- selected[0] instanceof ListTrackSegmentItem &&
- selected[selected.length - 1] instanceof ListTrackSegmentItem
- ) {
- let fileId = selected[0].getFileId();
- let file = getFile(fileId);
- if (file) {
- let trackIndex = selected[0].getTrackIndex();
- let numberOfSegments = file.trk[trackIndex].trkseg.length;
- let segmentIndex = down
- ? selected[selected.length - 1].getSegmentIndex()
- : selected[0].getSegmentIndex();
- if (down && segmentIndex < numberOfSegments - 1) {
- next = new ListTrackSegmentItem(fileId, trackIndex, segmentIndex + 1);
- } else if (!down && segmentIndex > 0) {
- next = new ListTrackSegmentItem(fileId, trackIndex, segmentIndex - 1);
- }
- }
- } else if (
- selected[0] instanceof ListWaypointItem &&
- selected[selected.length - 1] instanceof ListWaypointItem
- ) {
- let fileId = selected[0].getFileId();
- let file = getFile(fileId);
- if (file) {
- let numberOfWaypoints = file.wpt.length;
- let waypointIndex = down
- ? selected[selected.length - 1].getWaypointIndex()
- : selected[0].getWaypointIndex();
- if (down && waypointIndex < numberOfWaypoints - 1) {
- next = new ListWaypointItem(fileId, waypointIndex + 1);
- } else if (!down && waypointIndex > 0) {
- next = new ListWaypointItem(fileId, waypointIndex - 1);
- }
- }
- }
-
- if (next && (!get(selection).has(next) || !shift)) {
- if (shift) {
- addSelectItem(next);
- } else {
- selectItem(next);
- }
- }
-}
-
-async function exportFiles(fileIds: string[], exclude: string[]) {
- if (fileIds.length > 1) {
- await exportFilesAsZip(fileIds, exclude);
- } else {
- const firstFileId = fileIds.at(0);
- if (firstFileId != null) {
- const file = getFile(firstFileId);
- if (file) {
- exportFile(file, exclude);
- }
- }
- }
-}
-
-export async function exportSelectedFiles(exclude: string[]) {
- const fileIds: string[] = [];
- applyToOrderedSelectedItemsFromFile(async (fileId, level, items) => {
- fileIds.push(fileId);
- });
- await exportFiles(fileIds, exclude);
-}
-
-export async function exportAllFiles(exclude: string[]) {
- await exportFiles(get(fileOrder), exclude);
-}
-
-function exportFile(file: GPXFile, exclude: string[]) {
- const blob = new Blob([buildGPX(file, exclude)], { type: 'application/gpx+xml' });
- FileSaver.saveAs(blob, `${file.metadata.name}.gpx`);
-}
-
-async function exportFilesAsZip(fileIds: string[], exclude: string[]) {
- const zip = new JSZip();
- for (const fileId of fileIds) {
- const file = getFile(fileId);
- if (file) {
- const gpx = buildGPX(file, exclude);
- let filename = file.metadata.name;
- for (let i = 1; zip.files[filename + '.gpx']; i++) {
- filename = file.metadata.name + `-${i}`;
- }
- zip.file(filename + '.gpx', gpx);
- }
- }
- if (Object.keys(zip.files).length > 0) {
- const blob = await zip.generateAsync({ type: 'blob' });
- FileSaver.saveAs(blob, 'gpx-files.zip');
- }
-}
-
-export const allHidden = writable(false);
-
-export function updateAllHidden() {
- let hidden = true;
- applyToOrderedSelectedItemsFromFile((fileId, level, items) => {
- let file = getFile(fileId);
- if (file) {
- for (let item of items) {
- if (!hidden) {
- return;
- }
-
- if (item instanceof ListFileItem) {
- hidden = hidden && file._data.hidden === true;
- } else if (
- item instanceof ListTrackItem &&
- item.getTrackIndex() < file.trk.length
- ) {
- hidden = hidden && file.trk[item.getTrackIndex()]._data.hidden === true;
- } else if (
- item instanceof ListTrackSegmentItem &&
- item.getTrackIndex() < file.trk.length &&
- item.getSegmentIndex() < file.trk[item.getTrackIndex()].trkseg.length
- ) {
- hidden =
- hidden &&
- file.trk[item.getTrackIndex()].trkseg[item.getSegmentIndex()]._data
- .hidden === true;
- } else if (item instanceof ListWaypointsItem) {
- hidden = hidden && file._data.hiddenWpt === true;
- } else if (
- item instanceof ListWaypointItem &&
- item.getWaypointIndex() < file.wpt.length
- ) {
- hidden = hidden && file.wpt[item.getWaypointIndex()]._data.hidden === true;
- }
- }
- }
- });
- allHidden.set(hidden);
-}
-selection.subscribe(updateAllHidden);
-
-export const editMetadata = writable(false);
-export const editStyle = writable(false);
-
-export enum ExportState {
- NONE,
- SELECTION,
- ALL,
-}
-export const exportState = writable(ExportState.NONE);
+// if (item instanceof ListFileItem) {
+// hidden = hidden && file._data.hidden === true;
+// } else if (
+// item instanceof ListTrackItem &&
+// item.getTrackIndex() < file.trk.length
+// ) {
+// hidden = hidden && file.trk[item.getTrackIndex()]._data.hidden === true;
+// } else if (
+// item instanceof ListTrackSegmentItem &&
+// item.getTrackIndex() < file.trk.length &&
+// item.getSegmentIndex() < file.trk[item.getTrackIndex()].trkseg.length
+// ) {
+// hidden =
+// hidden &&
+// file.trk[item.getTrackIndex()].trkseg[item.getSegmentIndex()]._data
+// .hidden === true;
+// } else if (item instanceof ListWaypointsItem) {
+// hidden = hidden && file._data.hiddenWpt === true;
+// } else if (
+// item instanceof ListWaypointItem &&
+// item.getWaypointIndex() < file.wpt.length
+// ) {
+// hidden = hidden && file.wpt[item.getWaypointIndex()]._data.hidden === true;
+// }
+// }
+// }
+// });
+// allHidden.set(hidden);
+// }
+// selection.subscribe(updateAllHidden);
diff --git a/website/src/lib/units.ts b/website/src/lib/units.ts
index 97f53d9e..c2ce11e6 100644
--- a/website/src/lib/units.ts
+++ b/website/src/lib/units.ts
@@ -1,6 +1,5 @@
-import { get } from 'svelte/store';
-import { settings } from '$lib/db';
-import { _ } from '$lib/i18n';
+import { settings } from '$lib/logic/settings.svelte';
+import { i18n } from '$lib/i18n.svelte';
const { distanceUnits, velocityUnits, temperatureUnits } = settings;
@@ -56,7 +55,7 @@ export function getDistanceWithUnits(value: number, convert: boolean = true) {
}
export function getVelocityWithUnits(value: number, convert: boolean = true) {
- if (get(velocityUnits) === 'speed') {
+ if (velocityUnits.value === 'speed') {
if (convert) {
return getConvertedVelocity(value).toFixed(2) + ' ' + getVelocityUnits();
} else {
@@ -100,74 +99,74 @@ export function getTemperatureWithUnits(value: number, convert: boolean = true)
}
// Get the units
-export function getDistanceUnits(targetDistanceUnits = get(distanceUnits)) {
+export function getDistanceUnits(targetDistanceUnits = distanceUnits.value) {
switch (targetDistanceUnits) {
case 'metric':
- return get(_)('units.kilometers');
+ return i18n._('units.kilometers');
case 'imperial':
- return get(_)('units.miles');
+ return i18n._('units.miles');
case 'nautical':
- return get(_)('units.nautical_miles');
+ return i18n._('units.nautical_miles');
}
}
export function getVelocityUnits(
- targetVelocityUnits = get(velocityUnits),
- targetDistanceUnits = get(distanceUnits)
+ targetVelocityUnits = velocityUnits.value,
+ targetDistanceUnits = distanceUnits.value
) {
if (targetVelocityUnits === 'speed') {
switch (targetDistanceUnits) {
case 'metric':
- return get(_)('units.kilometers_per_hour');
+ return i18n._('units.kilometers_per_hour');
case 'imperial':
- return get(_)('units.miles_per_hour');
+ return i18n._('units.miles_per_hour');
case 'nautical':
- return get(_)('units.knots');
+ return i18n._('units.knots');
}
} else {
switch (targetDistanceUnits) {
case 'metric':
- return get(_)('units.minutes_per_kilometer');
+ return i18n._('units.minutes_per_kilometer');
case 'imperial':
- return get(_)('units.minutes_per_mile');
+ return i18n._('units.minutes_per_mile');
case 'nautical':
- return get(_)('units.minutes_per_nautical_mile');
+ return i18n._('units.minutes_per_nautical_mile');
}
}
}
-export function getElevationUnits(targetDistanceUnits = get(distanceUnits)) {
+export function getElevationUnits(targetDistanceUnits = distanceUnits.value) {
switch (targetDistanceUnits) {
case 'metric':
- return get(_)('units.meters');
+ return i18n._('units.meters');
case 'imperial':
- return get(_)('units.feet');
+ return i18n._('units.feet');
case 'nautical':
// See https://github.com/gpxstudio/gpx.studio/pull/66#issuecomment-2306568997
- return get(_)('units.meters');
+ return i18n._('units.meters');
}
}
export function getHeartRateUnits() {
- return get(_)('units.heartrate');
+ return i18n._('units.heartrate');
}
export function getCadenceUnits() {
- return get(_)('units.cadence');
+ return i18n._('units.cadence');
}
export function getPowerUnits() {
- return get(_)('units.power');
+ return i18n._('units.power');
}
export function getTemperatureUnits() {
- return get(temperatureUnits) === 'celsius'
- ? get(_)('units.celsius')
- : get(_)('units.fahrenheit');
+ return temperatureUnits.value === 'celsius'
+ ? i18n._('units.celsius')
+ : i18n._('units.fahrenheit');
}
// Convert only the value
-export function getConvertedDistance(value: number, targetDistanceUnits = get(distanceUnits)) {
+export function getConvertedDistance(value: number, targetDistanceUnits = distanceUnits.value) {
switch (targetDistanceUnits) {
case 'metric':
return value;
@@ -178,7 +177,7 @@ export function getConvertedDistance(value: number, targetDistanceUnits = get(di
}
}
-export function getConvertedElevation(value: number, targetDistanceUnits = get(distanceUnits)) {
+export function getConvertedElevation(value: number, targetDistanceUnits = distanceUnits.value) {
switch (targetDistanceUnits) {
case 'metric':
return value;
@@ -191,8 +190,8 @@ export function getConvertedElevation(value: number, targetDistanceUnits = get(d
export function getConvertedVelocity(
value: number,
- targetVelocityUnits = get(velocityUnits),
- targetDistanceUnits = get(distanceUnits)
+ targetVelocityUnits = velocityUnits.value,
+ targetDistanceUnits = distanceUnits.value
) {
if (targetVelocityUnits === 'speed') {
switch (targetDistanceUnits) {
@@ -216,5 +215,5 @@ export function getConvertedVelocity(
}
export function getConvertedTemperature(value: number) {
- return get(temperatureUnits) === 'celsius' ? value : celsiusToFahrenheit(value);
+ return temperatureUnits.value === 'celsius' ? value : celsiusToFahrenheit(value);
}
diff --git a/website/src/lib/utils.ts b/website/src/lib/utils.ts
index 1bbc88f9..6d8c911e 100644
--- a/website/src/lib/utils.ts
+++ b/website/src/lib/utils.ts
@@ -1,7 +1,5 @@
import { type ClassValue, clsx } from 'clsx';
import { twMerge } from 'tailwind-merge';
-import { get } from 'svelte/store';
-import { map } from './stores';
import { base } from '$app/paths';
import { languages } from '$lib/languages';
import { TrackPoint, Waypoint, type Coordinates, crossarcDistance, distance } from 'gpx';
@@ -129,37 +127,31 @@ export function getElevation(
}
let previousCursors: string[] = [];
-export function setCursor(cursor: string) {
- let m = get(map);
- if (m) {
- previousCursors.push(m.getCanvas().style.cursor);
- m.getCanvas().style.cursor = cursor;
- }
+export function setCursor(canvas: HTMLCanvasElement, cursor: string) {
+ previousCursors.push(canvas.style.cursor);
+ canvas.style.cursor = cursor;
}
-export function resetCursor() {
- let m = get(map);
- if (m) {
- m.getCanvas().style.cursor = previousCursors.pop() ?? '';
- }
+export function resetCursor(canvas: HTMLCanvasElement) {
+ canvas.style.cursor = previousCursors.pop() ?? '';
}
-export function setPointerCursor() {
- setCursor('pointer');
+export function setPointerCursor(canvas: HTMLCanvasElement) {
+ setCursor(canvas, 'pointer');
}
-export function setGrabbingCursor() {
- setCursor('grabbing');
+export function setGrabbingCursor(canvas: HTMLCanvasElement) {
+ setCursor(canvas, 'grabbing');
}
-export function setCrosshairCursor() {
- setCursor('crosshair');
+export function setCrosshairCursor(canvas: HTMLCanvasElement) {
+ setCursor(canvas, 'crosshair');
}
export const scissorsCursor = `url('data:image/svg+xml,') 12 12, auto`;
-export function setScissorsCursor() {
- setCursor(scissorsCursor);
+export function setScissorsCursor(canvas: HTMLCanvasElement) {
+ setCursor(canvas, scissorsCursor);
}
export function isMac() {
diff --git a/website/src/routes/+layout.svelte b/website/src/routes/+layout.svelte
index b31963b2..37ecba0d 100644
--- a/website/src/routes/+layout.svelte
+++ b/website/src/routes/+layout.svelte
@@ -1,11 +1,11 @@
- {#if !$isLoadingInitialLocale}
+ {#if !i18n.isLoadingInitial}
{#if showNavAndFooter}
{/if}
-
+ {@render children()}
{#if showNavAndFooter}
diff --git a/website/src/routes/404/+page.svelte b/website/src/routes/404/+page.svelte
index 1963b7c4..d7941e3a 100644
--- a/website/src/routes/404/+page.svelte
+++ b/website/src/routes/404/+page.svelte
@@ -2,35 +2,35 @@
import { Button } from '$lib/components/ui/button';
import Logo from '$lib/components/Logo.svelte';
import { getURLForLanguage } from '$lib/utils';
- import { Home, Map, BookOpenText } from 'lucide-svelte';
- import { _, locale } from '$lib/i18n';
+ import { Home, Map, BookOpenText } from '@lucide/svelte';
+ import { i18n } from '$lib/i18n.svelte';
404
-
{$_('page_not_found')}
+
{i18n._('page_not_found')}
diff --git a/website/src/routes/[[language]]/+page.svelte b/website/src/routes/[[language]]/+page.svelte
index 107ac542..8652e60d 100644
--- a/website/src/routes/[[language]]/+page.svelte
+++ b/website/src/routes/[[language]]/+page.svelte
@@ -2,9 +2,9 @@
import { Button } from '$lib/components/ui/button';
import DocsContainer from '$lib/components/docs/DocsContainer.svelte';
import Logo from '$lib/components/Logo.svelte';
- import ElevationProfile from '$lib/components/ElevationProfile.svelte';
- import GPXStatistics from '$lib/components/GPXStatistics.svelte';
- import Routing from '$lib/components/toolbar/tools/routing/Routing.svelte';
+ // import ElevationProfile from '$lib/components/ElevationProfile.svelte';
+ // import GPXStatistics from '$lib/components/GPXStatistics.svelte';
+ // import Routing from '$lib/components/toolbar/tools/routing/Routing.svelte';
import {
BookOpenText,
Heart,
@@ -14,35 +14,43 @@
PenLine,
Route,
Scale,
- } from 'lucide-svelte';
- import { _, locale } from '$lib/i18n';
+ } from '@lucide/svelte';
+ import { i18n } from '$lib/i18n.svelte';
import { getURLForLanguage } from '$lib/utils';
import { exampleGPXFile } from '$lib/assets/example';
import { writable } from 'svelte/store';
- import Toolbar from '$lib/components/toolbar/Toolbar.svelte';
- import { currentTool, Tool } from '$lib/stores';
+ // import Toolbar from '$lib/components/toolbar/Toolbar.svelte';
+ // import { tool, Tool } from '$lib/components/toolbar/utils.svelte';
import { onDestroy, onMount } from 'svelte';
- export let data: {
- fundingModule: any;
- translationModule: any;
- mapboxModule: any;
- };
+ let {
+ data,
+ }: {
+ data: {
+ fundingModule: Promise
;
+ translationModule: Promise;
+ mapboxModule: Promise;
+ };
+ } = $props();
let gpxStatistics = writable(exampleGPXFile.getStatistics());
let slicedGPXStatistics = writable(undefined);
let additionalDatasets = writable(['speed', 'atemp']);
let elevationFill = writable<'slope' | 'surface' | undefined>(undefined);
- onMount(() => {
- $currentTool = Tool.SCISSORS;
- });
+ // onMount(() => {
+ // tool.current = Tool.SCISSORS;
+ // });
- $: $currentTool, ($currentTool = Tool.SCISSORS);
+ // $effect(() => {
+ // if (tool.current !== Tool.SCISSORS) {
+ // tool.current = Tool.SCISSORS;
+ // }
+ // });
- onDestroy(() => {
- $currentTool = null;
- });
+ // onDestroy(() => {
+ // tool.current = null;
+ // });
@@ -50,23 +58,23 @@
- {$_('metadata.home_title')}
+ {i18n._('metadata.home_title')}
- {$_('metadata.description')}
+ {i18n._('metadata.description')}
-
@@ -89,12 +97,12 @@
- {$_('homepage.route_planning')}
+ {i18n._('homepage.route_planning')}
-
{$_('homepage.route_planning_description')}
+
{i18n._('homepage.route_planning_description')}
-
+
@@ -105,19 +113,23 @@
- {$_('homepage.file_processing')}
+ {i18n._('homepage.file_processing')}
-
{$_('homepage.file_processing_description')}
+
+ {i18n._('homepage.file_processing_description')}
+
-
+
- {$_('homepage.file_processing')}
+ {i18n._('homepage.file_processing')}
-
{$_('homepage.file_processing_description')}
+
+ {i18n._('homepage.file_processing_description')}
+
@@ -128,12 +140,12 @@
- {$_('homepage.maps')}
+ {i18n._('homepage.maps')}
-
{$_('homepage.maps_description')}
+
{i18n._('homepage.maps_description')}