Add warning for big minzoom
This commit is contained in:
parent
d4a2b5899b
commit
aa5fc97269
1 changed files with 4 additions and 0 deletions
|
@ -538,6 +538,10 @@ export class ValidateLayer extends DesugaringStep<LayerConfigJson> {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if(json.minzoom > Constants.userJourney.minZoomLevelToAddNewPoints ){
|
||||||
|
(json.presets?.length > 0 ? errors : warnings).push(`At ${context}: minzoom is ${json.minzoom}, this should be at most ${Constants.userJourney.minZoomLevelToAddNewPoints} as a preset is set. Why? Selecting the pin for a new item will zoom in to level before adding the point. Having a greater minzoom will hide the points, resulting in possible duplicates`)
|
||||||
|
}
|
||||||
|
|
||||||
{
|
{
|
||||||
// duplicate ids in tagrenderings check
|
// duplicate ids in tagrenderings check
|
||||||
const duplicates = Utils.Dedup(Utils.Dupiclates(Utils.NoNull((json.tagRenderings ?? []).map(tr => tr["id"]))))
|
const duplicates = Utils.Dedup(Utils.Dupiclates(Utils.NoNull((json.tagRenderings ?? []).map(tr => tr["id"]))))
|
||||||
|
|
Loading…
Reference in a new issue