diff --git a/src/UI/History/AggregateView.svelte b/src/UI/History/AggregateView.svelte index 35ce509cd..130e7c2dd 100644 --- a/src/UI/History/AggregateView.svelte +++ b/src/UI/History/AggregateView.svelte @@ -12,9 +12,9 @@ import Translations from "../i18n/Translations" import type { TagRenderingConfigJson } from "../../Models/ThemeConfig/Json/TagRenderingConfigJson" import { Or } from "../../Logic/Tags/Or" - import { Utils } from "../../Utils" import ChartJs from "../Base/ChartJs.svelte" import { ChartJsUtils } from "../Base/ChartJsUtils" + import { Lists } from "../../Utils/Lists" export let onlyShowUsername: string[] export let features: Feature[] diff --git a/src/UI/InspectorGUI.svelte b/src/UI/InspectorGUI.svelte index 5afae05be..32f0c8f5d 100644 --- a/src/UI/InspectorGUI.svelte +++ b/src/UI/InspectorGUI.svelte @@ -33,6 +33,9 @@ import GeocodeResults from "./Search/GeocodeResults.svelte" import MagnifyingGlassCircle from "@babeard/svelte-heroicons/mini/MagnifyingGlassCircle" import type { GeocodeResult } from "../Logic/Search/GeocodingProvider" + import { Tab, TabGroup, TabList, TabPanel, TabPanels } from "@rgossiaux/svelte-headlessui" + import WikipediaTitle from "./Wikipedia/WikipediaTitle.svelte" + import WikipediaArticle from "./Wikipedia/WikipediaArticle.svelte" console.log("Loading inspector GUI") let username = QueryParameters.GetQueryParameter("user", undefined, "Inspect this user") @@ -49,7 +52,7 @@ new CoordinateSearch(), new OpenLocationCodeSearch(), new PhotonSearch(true, 2), - new PhotonSearch() + new PhotonSearch(), ) let showSearchDrawer = new UIEventSource(true) let searchIsFocussed = new UIEventSource(false) @@ -138,7 +141,7 @@ const overpass = new Overpass( Constants.defaultOverpassUrls[0], undefined, - user.split(";").map((user) => 'nw(user_touched:"' + user + '");') + user.split(";").map((user) => "nw(user_touched:\"" + user + "\");"), ) if (!maplibremap.bounds.data) { return @@ -161,8 +164,6 @@ return true }) - let mode: "map" | "table" | "aggregate" | "images" = "map" - let showPreviouslyVisited = new UIEventSource(true) const t = Translations.t.inspector @@ -207,89 +208,98 @@ -
- - - - -
+ + + ("tab "+ (selected ? "tab-selected" : "tab-unselected"))}> - {#if mode === "map"} - {#if $selectedElement !== undefined} - - + + ("tab "+ (selected ? "tab-selected" : "tab-unselected"))}> + + + + ("tab "+ (selected ? "tab-selected" : "tab-unselected"))}> + + + + ("tab "+ (selected ? "tab-selected" : "tab-unselected"))}> + + + + + + + + + {#if $selectedElement !== undefined} + + - {/if} - -
- -
- search()} - isFocused={searchIsFocussed} - value={searchvalue} - on:focus={() => state.searchState.showSearchDrawer.set(true)} - /> - {#if $searchSuggestions?.length > 0 || $searchIsFocussed} - search(event.detail)} /> + + + {/if} -
-
- {:else if mode === "table"} -
- {#each $featuresStore as f} - - {/each} -
- {:else if mode === "aggregate"} -
- -
- {:else if mode === "images"} -
- -
- {/if} + +
+ +
+ search()} + isFocused={searchIsFocussed} + value={searchvalue} + on:focus={() => state.searchState.showSearchDrawer.set(true)} + /> + {#if $searchSuggestions?.length > 0 || $searchIsFocussed} + search(event.detail)} /> + {/if} +
+
+ +
+ + + {#each $featuresStore as f} + + {/each} + + + + + + + + +
+