diff --git a/lib/ui/layers/listview.mjs b/lib/ui/layers/listview.mjs index c70b1c4e79..abaf5f82d3 100644 --- a/lib/ui/layers/listview.mjs +++ b/lib/ui/layers/listview.mjs @@ -1,5 +1,3 @@ -import view from './view.mjs' - mapp.utils.merge(mapp.dictionaries, { en: { layer_group_hide_layers: 'Hide all layers in group', @@ -45,7 +43,7 @@ export default function (params){ if (layer.hidden) return; // Create the layer view. - view(layer) + mapp.ui.layers.view(layer) if (!layer.group) { listview.node.appendChild(layer.view) diff --git a/lib/ui/layers/view.mjs b/lib/ui/layers/view.mjs index 543f51d6ee..94be2c0515 100644 --- a/lib/ui/layers/view.mjs +++ b/lib/ui/layers/view.mjs @@ -34,7 +34,7 @@ export default (layer) => { if (layer.view === null) { // Do not create a layer view. - return; + return layer; } layer.view = mapp.utils.html.node`