Merge master

This commit is contained in:
Pieter Vander Vennet 2025-05-27 20:02:07 +02:00
commit 9cd602cf29
13 changed files with 88 additions and 17 deletions

View file

@ -2,6 +2,29 @@
All notable changes to this project will be documented in this file. See [standard-version](https://github.com/conventional-changelog/standard-version) for commit guidelines.
### [0.51.8](https://source.mapcomplete.org/MapComplete/MapComplete/compare/v0.51.7...v0.51.8) (2025-05-24)
### Bug Fixes
* add comment on duplicate nearby images, make sure they are always deduplicated ([a3aba99](https://source.mapcomplete.org/MapComplete/MapComplete/commits/a3aba991c51b6aacdcf3058644bd00189f3bed25))
* fix loading notes based on hash ([cde7bf6](https://source.mapcomplete.org/MapComplete/MapComplete/commits/cde7bf6d9aa7c521b9b4a22fd52509d8e725cae5))
* inspector: fix AggregateImages.svelte ([e2e3e4b](https://source.mapcomplete.org/MapComplete/MapComplete/commits/e2e3e4b51d17c863d5c75e2c9bc62e3479e8e888))
* probably partial fix of [#2407](https://source.mapcomplete.org/MapComplete/MapComplete/issues/2407) ([68d9606](https://source.mapcomplete.org/MapComplete/MapComplete/commits/68d96063acb0e5c1299b12dc38ada4440b493958))
### Theme improvements
* **aircraft:** add historical aircraft layer and theme, https://en.osm.town/@pietervdvn/114491536018069317 ([0e91656](https://source.mapcomplete.org/MapComplete/MapComplete/commits/0e91656dd68a8c1a687200e623ddb6b94811f350))
* **elevator:** Move speech output question higher, add condition on induction loop question, see [#2411](https://source.mapcomplete.org/MapComplete/MapComplete/issues/2411) ([41e501c](https://source.mapcomplete.org/MapComplete/MapComplete/commits/41e501c18e6888a4b99678baf294cea325a71e7c))
* **food:** add 'spanish' as option ([cdd5003](https://source.mapcomplete.org/MapComplete/MapComplete/commits/cdd5003aed8a81024b19322af941ccf7ec9fb7dd))
* **historic_aircraft:** make build work ([f673b54](https://source.mapcomplete.org/MapComplete/MapComplete/commits/f673b540e53c144ca19d69cf8d7794c89dc3b14d))
* **historic_rolling_stock:** create rolling stock theme ([a591a44](https://source.mapcomplete.org/MapComplete/MapComplete/commits/a591a44c1a334417f91e00af68d004c57e5e92d0))
* **rolling_stock:** more questions ([3d90e14](https://source.mapcomplete.org/MapComplete/MapComplete/commits/3d90e143d6e9b5c334c58cab1598274ce386b7ce))
* **shops:** add hairdresser specific questions ([cd8b614](https://source.mapcomplete.org/MapComplete/MapComplete/commits/cd8b614bd975bb8f0738da469bcb0cce58a9cb7a))
* **toilets:** add an allowed range to some freeform inputs, allow to specify 'units' in the freeform, add the possibility to convert units ([1e0ac3f](https://source.mapcomplete.org/MapComplete/MapComplete/commits/1e0ac3febf06272a5978a87cceeb281929356936))
* **windpumps:** add windpump layer ([f03877b](https://source.mapcomplete.org/MapComplete/MapComplete/commits/f03877b570e569c8ef9ca716edb39e5f9e6852b2))
### [0.51.7](https://source.mapcomplete.org/MapComplete/MapComplete/compare/v0.51.6...v0.51.7) (2025-05-12)

View file

@ -728,6 +728,7 @@
},
{
"if": "colour=gray",
"alsoShowIf": "colour=grey",
"then": {
"en": "Colour: gray",
"de": "Farbe: grau",

View file

@ -285,7 +285,7 @@
],
"tagRenderings": [
"images",
"level",
"reviews",
{
"question": {
"nl": "Wat is de naam van deze zaak?",
@ -432,13 +432,40 @@
"email",
"phone",
"payment-options",
"wheelchair-access",
"level",
"smoking",
"wheelchair-access",
{
"question": {
"en": "Does {title()} accept bring-your-own reusable cups?"
},
"id": "pub_reusable_packaging",
"mappings": [
{
"if": "reusable_packaging:accept=yes",
"then": {
"en": "Accepts reusable cups"
}
},
{
"if": "reusable_packaging:accept=no",
"alsoShowIf": "reusable_packaging:accept=",
"then": {
"en": "Does not accept reusable cups"
}
},
{
"if": "reusable_packaging:accept=only",
"then": {
"en": "<b>Only</b> serves to people who bring reusable cups"
}
}
]
},
"service:electricity",
"seating",
"dog-access",
"internet-all",
"reviews",
"toilet_at_amenity_lib.all"
],
"filter": [

View file

@ -150,6 +150,10 @@
],
"tagRenderings": [
"images",
{
"id": "preset_type",
"render": "{preset_type_select()}"
},
"wikipedia",
{
"id": "model",

View file

@ -76,8 +76,12 @@
{
"and": [
"shop~*",
"second_hand=yes",
"second_hand=only"
{
"or": [
"second_hand=yes",
"second_hand=only"
]
}
]
}
]

4
package-lock.json generated
View file

@ -1,12 +1,12 @@
{
"name": "mapcomplete",
"version": "0.51.7",
"version": "0.51.8",
"lockfileVersion": 3,
"requires": true,
"packages": {
"": {
"name": "mapcomplete",
"version": "0.51.7",
"version": "0.51.8",
"hasInstallScript": true,
"license": "GPL-3.0-or-later",
"dependencies": {

View file

@ -1,6 +1,6 @@
{
"name": "mapcomplete",
"version": "0.51.7",
"version": "0.51.8",
"repository": "https://source.mapcomplete.org/MapComplete/MapComplete",
"description": "A small website to edit OSM easily",
"bugs": "hhttps://source.mapcomplete.org/MapComplete/MapComplete/issues",

View file

@ -34,7 +34,8 @@ export default class AllImageProviders {
AllImageProviders.genericImageProvider,
]
public static apiUrls: string[] = [].concat(
...AllImageProviders.imageAttributionSources.map((src) => src.apiUrls())
...AllImageProviders.imageAttributionSources.map((src) => src.apiUrls()),
"https://panoramax-storage-public-fast.s3.gra.perf.cloud.ovh.net"
)
public static defaultKeys: string[] = [].concat(
...AllImageProviders.imageAttributionSources.map((provider) => provider.defaultKeyPrefixes)

View file

@ -5,7 +5,7 @@
import { OsmObject } from "../../Logic/Osm/OsmObject"
import Loading from "../Base/Loading.svelte"
import { HistoryUtils } from "./HistoryUtils"
import * as shared_questions from "../../../public/assets/generated/layers/questions.json"
import * as favourite from "../../../public/assets/generated/layers/favourite.json"
import TagRenderingConfig from "../../Models/ThemeConfig/TagRenderingConfig"
import Tr from "../Base/Tr.svelte"
import AccordionSingle from "../Flowbite/AccordionSingle.svelte"
@ -13,6 +13,8 @@
import TagRenderingChart from "../BigComponents/TagRenderingChart"
import ToSvelte from "../Base/ToSvelte.svelte"
import type { TagRenderingConfigJson } from "../../Models/ThemeConfig/Json/TagRenderingConfigJson"
import { Or } from "../../Logic/Tags/Or"
import { Utils } from "../../Utils"
export let onlyShowUsername: string[]
export let features: Feature[]
@ -32,12 +34,21 @@
}[]
> = allHistories.mapD((histories) => HistoryUtils.fullHistoryDiff(histories, usernames))
const trs = shared_questions.tagRenderings.map(
// We use the favourite-layer as it contains _all_ questions
const trs = favourite.tagRenderings.map(
(tr) => new TagRenderingConfig(<TagRenderingConfigJson>tr)
)
function detectQuestion(key: string): TagRenderingConfig {
return trs.find((tr) => tr.freeform?.key === key)
const byKey = trs.find((tr) => tr.freeform?.key === key)
if (byKey) {
return byKey
}
return trs.find(tr => tr.mappings.some(mapping => {
const ifTags = Or.construct(Utils.NoNull([mapping.if, mapping.alsoShowIf]))
const keys = ifTags.usedKeys()
return keys.some(k => k == key)
}))
}
const mergedCount: Store<
@ -134,7 +145,7 @@
/>
</div>
{:else}
Could not create a graph
Could not create a graph - this item type has no associated question
{/if}
</AccordionSingle>
{/each}

View file

@ -25,7 +25,6 @@
| Store<Feature<Geometry, HotspotProperties>[]> = []
let isLoaded = new UIEventSource(false)
console.log(">>> slots are", $$slots)
</script>
<div class={twMerge("relative h-full w-full", clss)}>

View file

@ -53,7 +53,7 @@
informationLocation: (image.detailsUrl ?? image.pictureUrl ?? image.thumbUrl),
date
}
console.log(">>> trying to create license info based on", image, license)
let providedImage: ProvidedImage = {
url: image.thumbUrl ?? image.pictureUrl,
url_hd: image.pictureUrl,

View file

@ -180,7 +180,7 @@
</script>
<div class="flex h-screen w-full flex-col">
<div class="low-interaction flex items-center gap-x-2 p-2">
<div class="low-interaction flex items-center gap-x-2 p-2 flex-wrap">
<MagnifyingGlassCircle class="h-12 w-12" />
<h1 class="m-0 mx-2 flex-shrink-0">
<Tr t={t.title} />
@ -190,6 +190,7 @@
type="string"
value={username}
on:submit={() => load()}
cls="shrink-0 border-interactive border-2"
/>
{#if loadingData}
<Loading />

View file

@ -21,7 +21,7 @@ class QuestionViz implements SpecialVisualizationSvelte {
funcName = "questions"
needsUrls = []
docs =
"The special element which shows the questions which are unkown. Added by default if not yet there"
"The special element which shows the questions which are unknown. Added by default if not yet there"
args = [
{
name: "labels",