refactoring: more state splitting, basic layoutFeatureSource

This commit is contained in:
Pieter Vander Vennet 2023-03-26 05:58:28 +02:00
parent 8e2f04c0d0
commit b94a8f5745
54 changed files with 1067 additions and 1969 deletions

View file

@ -68,6 +68,8 @@ export default class LayerConfig extends WithContextLoader {
public readonly forceLoad: boolean
public readonly syncSelection: typeof LayerConfig.syncSelectionAllowed[number] // this is a trick to conver a constant array of strings into a type union of these values
public readonly _needsFullNodeDatabase = false
constructor(json: LayerConfigJson, context?: string, official: boolean = true) {
context = context + "." + json.id
const translationContext = "layers:" + json.id
@ -250,7 +252,7 @@ export default class LayerConfig extends WithContextLoader {
| "osmbasedmap"
| "historicphoto"
| string
)[]
)[]
if (typeof pr.preciseInput.preferredBackground === "string") {
preferredBackground = [pr.preciseInput.preferredBackground]
} else {