-
Notifications
You must be signed in to change notification settings - Fork 0
326 Allow layers to be filtered for visible features #327
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
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull Request Overview
This PR replaces the graph button with a time filter toggle in the layers toolbar to support time-based filtering in the UI.
- Introduces a new boolean state for time filtering in the Layers component.
- Replaces the graph button in LayersToolbar with a toggle button that switches between two filter icons.
- Removes the redundant color attribute from the ControlPanel's Button.
Reviewed Changes
Copilot reviewed 3 out of 3 changed files in this pull request and generated no comments.
| File | Description |
|---|---|
| src/components/Layers/index.tsx | Adds time filter state and passes it as props to child components. |
| src/components/Layers/LayersToolbar.tsx | Implements a toggle button for time filtering, replacing the graph button. |
| src/components/ControlPanel/index.tsx | Removes the color attribute from the Button for design consistency. |
Comments suppressed due to low confidence (2)
src/components/Layers/index.tsx:49
- [nitpick] Consider renaming 'useTimeFilter' to 'isTimeFilterEnabled' for clearer semantic meaning.
const [useTimeFilter, setUseTimeFilter] = useState(false)
src/components/Layers/LayersToolbar.tsx:81
- [nitpick] Consider renaming 'onFilterForTime' to 'toggleTimeFilter' to better reflect its purpose.
<Button size={'middle'} onClick={() => onFilterForTime(!hasTimeFilter)}>
✅ Deploy Preview for reactol ready!
To edit notification comments on pull requests, go to your Netlify site configuration. |
Fixes #326