-
Notifications
You must be signed in to change notification settings - Fork 524
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: Address and Map icon alignment #9722
Fix: Address and Map icon alignment #9722
Conversation
✅ Deploy Preview for care-ohc ready!
To edit notification comments on pull requests, go to your Netlify site configuration. |
WalkthroughThe pull request introduces modifications to the Changes
Possibly related PRs
Suggested labels
Suggested reviewers
Poem
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: 0
🧹 Nitpick comments (2)
src/components/Facility/FacilityHome.tsx (2)
85-92
: Avoid mutating theparentDetails
array in place.The usage of
parentDetails.reverse()
mutates the original array, which can lead to unexpected side effects ifparentDetails
is used elsewhere. To keep your code predictable, consider using a copy of the array before reversing:- const filteredDetails = parentDetails - .reverse() - .concat({ + const reversedDetails = [...parentDetails].reverse(); + const filteredDetails = reversedDetails.concat({ label: getOrgLevelLabel(geoOrg.org_type, geoOrg.level_cache), value: geoOrg.name, }) .slice(-2);
93-100
: Consider a more robust or i18n-friendly separator.Using a raw
can be a quick solution, but you may want to externalize or parametrize the separator for better i18n support or improved consistency. For instance, you could store aseparator
constant or use a translation string. This also makes it easier to replace the separator in the future if design requirements change.
📜 Review details
Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro
📒 Files selected for processing (1)
src/components/Facility/FacilityHome.tsx
(2 hunks)
🔇 Additional comments (1)
src/components/Facility/FacilityHome.tsx (1)
291-291
: Verify the increased vertical spacing withmt-3
.Raising the margin from
mt-1
tomt-3
may create extra blank space on small devices. Double-check the UI on different screen sizes to ensure it aligns with intended designs.
)} | ||
</span> | ||
)); | ||
.slice(-2); |
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.
The LSG structure of a state/country can vary, we can't choose to trim it.
We should render everything.
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.
oh okay will make the necessary changes for the same
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.
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.
i think format 1, but orgs reversed would look good!
Also, add justify-between the phone number and address
👋 Hi, @abhimanyurajeesh, This message is automatically generated by prince-chrismc/label-merge-conflicts-action so don't hesitate to report issues/improvements there. |
Proposed Changes
Visual Changes Explanation (User Interface Side)
When the changes were made to the renderGeoOrganizations function, the following updates were reflected on the UI (User Interface) side:
✅ Before Changes:
✅ After Changes (New UI Behavior):
@ohcnetwork/care-fe-code-reviewers
Merge Checklist
Summary by CodeRabbit
Style
Refactor