-
Notifications
You must be signed in to change notification settings - Fork 19
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
Facility mapper #1590
Facility mapper #1590
Conversation
📝 Walkthrough📝 Walkthrough📝 WalkthroughWalkthroughThis pull request introduces several changes across multiple components in the microplan module. A new CSS class for dropdown styling is added, enhancing layout options. The Changes
Possibly related PRs
Suggested reviewers
Thank you for using CodeRabbit. We offer it for free to the OSS community and would appreciate your support in helping us grow. If you find it useful, would you consider giving us a shout-out on your favorite social media? 🪧 TipsChatThere are 3 ways to chat with CodeRabbit:
Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments. CodeRabbit Commands (Invoked using PR comments)
Other keywords and placeholders
CodeRabbit Configuration File (
|
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.
Actionable comments posted: 12
🧹 Outside diff range comments (1)
health/micro-ui/web/micro-ui-internals/packages/modules/microplan/src/components/SearchJurisdiction.js (1)
Line range hint
71-86
: Approved with a suggestion for improvementThe addition of the wrapper
<div>
withwidth: 100%
is a good improvement for layout consistency. It ensures that theMultiSelectDropdown
component takes up the full width of its container, which aligns with the intended UI design.However, to improve maintainability, consider moving the inline style to a CSS class. This would make it easier to manage styles across the application and adhere to the principle of separation of concerns.
Consider refactoring the inline style to a CSS class:
- In your CSS file (e.g.,
microplan.scss
), add:.full-width-dropdown-wrapper { width: 100%; }
- Then, update the JSX:
- <div style={{ width: "100%" }}> + <div className="full-width-dropdown-wrapper">This change will improve code maintainability while preserving the intended layout.
📜 Review details
Configuration used: CodeRabbit UI
Review profile: ASSERTIVE
📒 Files selected for processing (6)
- health/micro-ui/web/micro-ui-internals/packages/css/src/components/microplan.scss (1 hunks)
- health/micro-ui/web/micro-ui-internals/packages/modules/microplan/src/components/FacilityPopup.js (1 hunks)
- health/micro-ui/web/micro-ui-internals/packages/modules/microplan/src/components/SearchJurisdiction.js (2 hunks)
- health/micro-ui/web/micro-ui-internals/packages/modules/microplan/src/hooks/index.js (2 hunks)
- health/micro-ui/web/micro-ui-internals/packages/modules/microplan/src/hooks/services/censusSearchConfig.js (1 hunks)
- health/micro-ui/web/micro-ui-internals/packages/modules/microplan/src/hooks/useCensusSearch.js (1 hunks)
🧰 Additional context used
📓 Path-based instructions (5)
health/micro-ui/web/micro-ui-internals/packages/modules/microplan/src/components/FacilityPopup.js (1)
Pattern
**/*.js
: checkhealth/micro-ui/web/micro-ui-internals/packages/modules/microplan/src/components/SearchJurisdiction.js (1)
Pattern
**/*.js
: checkhealth/micro-ui/web/micro-ui-internals/packages/modules/microplan/src/hooks/index.js (1)
Pattern
**/*.js
: checkhealth/micro-ui/web/micro-ui-internals/packages/modules/microplan/src/hooks/services/censusSearchConfig.js (1)
Pattern
**/*.js
: checkhealth/micro-ui/web/micro-ui-internals/packages/modules/microplan/src/hooks/useCensusSearch.js (1)
Pattern
**/*.js
: check
🪛 Biome
health/micro-ui/web/micro-ui-internals/packages/modules/microplan/src/components/FacilityPopup.js
[error] 270-270: Avoid passing children using a prop
The canonical way to pass children in React is to use JSX elements
(lint/correctness/noChildrenProp)
[error] 271-271: Missing key property for this element in iterable.
The order of the items may change, and having a key can help React identify which item was moved.
Check the React documentation.(lint/correctness/useJsxKeyInIterable)
[error] 338-345: Missing key property for this element in iterable.
The order of the items may change, and having a key can help React identify which item was moved.
Check the React documentation.(lint/correctness/useJsxKeyInIterable)
🔇 Additional comments (2)
health/micro-ui/web/micro-ui-internals/packages/modules/microplan/src/hooks/useCensusSearch.js (1)
1-7
: LGTM! Well-structured custom hook implementation.The
useCensusSearch
hook is well-implemented using react-query'suseQuery
. The structure is clean and follows good practices for custom hook creation.health/micro-ui/web/micro-ui-internals/packages/modules/microplan/src/hooks/index.js (1)
12-13
: LGTM: New hooks imported correctly.The new imports for
usePlanSearchEmployee
anduseCensusSearch
are added correctly, following the existing import pattern and naming conventions.
Summary by CodeRabbit
Release Notes
New Features
FacilityPopup
component with improved data management and a tabbed interface for better navigation between assigned and unassigned facilities.Bug Fixes
Documentation