UX: hide layers without name from search, search for those layers in the themesearch (see #2157)

This commit is contained in:
Pieter Vander Vennet 2024-09-28 02:53:44 +02:00
parent 556c26d99b
commit 03db69f1a0
2 changed files with 4 additions and 3 deletions

View file

@ -36,7 +36,7 @@ export default class ThemeSearch {
private readonly _otherThemes: MinimalLayoutInformation[]
constructor(state: {osmConnection: OsmConnection, layout: LayoutConfig}) {
this._layersToIgnore = state.layout.layers.map(l => l.id)
this._layersToIgnore = state.layout.layers.filter(l => l.isNormal()).map(l => l.id)
this._knownHiddenThemes = UserRelatedState.initDiscoveredHiddenThemes(state.osmConnection).map(list => new Set(list))
this._otherThemes = ThemeSearch.officialThemes.themes
.filter(th => th.id !== state.layout.id)