Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix feature layer toggling bug #2557

Merged
merged 3 commits into from
Feb 18, 2025
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
17 changes: 7 additions & 10 deletions src/components/EnhancedMap/LayerToggle/LayerToggle.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@
import _filter from "lodash/filter";
import _isEmpty from "lodash/isEmpty";
import _map from "lodash/map";
import _noop from "lodash/noop";
import _sortBy from "lodash/sortBy";
import PropTypes from "prop-types";
import { Component, Fragment } from "react";
Expand Down Expand Up @@ -279,16 +278,14 @@
"mr-my-2 mr-flex mr-items-center mr-leading-none",
props.toggleClassName,
)}
onClick={props.toggleLayerActive}
>
<input
id={props.layerLabel}
type="checkbox"
className="mr-checkbox-toggle"
checked={props.isLayerActive}
onChange={_noop}
/>
<label htmlFor={props.layerLabel} className="mr-ml-3 mr-text-orange">
<label className="mr-text-orange mr-cursor-pointer">
<input
type="checkbox"
className="mr-checkbox-toggle mr-mr-3"
checked={props.isLayerActive}
onChange={props.toggleLayerActive}

Check warning on line 287 in src/components/EnhancedMap/LayerToggle/LayerToggle.jsx

View check run for this annotation

Codecov / codecov/patch

src/components/EnhancedMap/LayerToggle/LayerToggle.jsx#L282-L287

Added lines #L282 - L287 were not covered by tests
/>
{props.layerLabel}
</label>
</div>
Expand Down