Skip to content

Commit

Permalink
Disable layer if hidden
Browse files Browse the repository at this point in the history
Update disable property based on layer visibility.

Signed-off-by: Vijayan Balasubramanian <[email protected]>
  • Loading branch information
VijayanB committed Dec 9, 2022
1 parent f16fdbe commit 72a81cf
Showing 1 changed file with 1 addition and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -222,6 +222,7 @@ const LayerControlPanel = memo(({ maplibreRef, setLayers, layers }: Props) => {
iconType={LAYER_ICON_TYPE_MAP[layer.type]}
aria-label="layer in the map layers list"
onClick={() => onClickLayerName(layer)}
isDisabled={layerVisibility.get(layer.id) ? false : true}
/>
</EuiFlexItem>
<EuiFlexGroup justifyContent="flexEnd" gutterSize="none">
Expand Down

0 comments on commit 72a81cf

Please sign in to comment.