-
Notifications
You must be signed in to change notification settings - Fork 2.4k
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
Fixes #7220: Remove primary banner icon when only one value present #7275
Conversation
Log
|
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.
PR Summary
This pull request addresses issue #7220 by removing the primary banner icon for emails, phone numbers, and domains when only one value is present, enhancing the user interface clarity.
- Added
isPrimaryEmail
function inEmailsFieldInput.tsx
to check for multiple emails before displaying primary icon - Implemented
isPrimaryLink
function inLinksFieldInput.tsx
to ensure primary icon only shows with multiple links - Modified
PhonesFieldInput.tsx
withisPrimaryPhone
function to display primary icon only when multiple phone numbers exist - These changes improve UI consistency across email, link, and phone number fields
3 file(s) reviewed, no comment(s)
Edit PR Review Bot Settings
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.
Great! Thank you
…resent (twentyhq#7275) ## Changes - Added a check to make sure that we only indicate an entry is primary if there is more than one value. - The banner icon now only displays when there are either **2 or more emails, phone numbers, or domains.** ## Emails ![image](https://github.com/user-attachments/assets/54832aaf-a319-4b70-87bf-3621e05f1637) ![image](https://github.com/user-attachments/assets/44bb8909-9f34-426d-8942-2bb7974e9113) ## Phones ![image](https://github.com/user-attachments/assets/85ca4c36-c148-4d86-89d6-1c02a960f2f4) ![image](https://github.com/user-attachments/assets/f11b5c2e-4376-4bf6-8560-e4c956f2c2e5) ## Domains ![image](https://github.com/user-attachments/assets/ce324714-6bd7-45ac-9a2f-8a2671d080a0) ![image](https://github.com/user-attachments/assets/153883a3-782f-424b-abc4-d882ec969bc2) ## Notes This is my first time contributing so I am open to any feedback. Co-authored-by: Keerat Kohli <[email protected]>
Changes
Added a check to make sure that we only indicate an entry is primary if there is more than one value.
The banner icon now only displays when there are either 2 or more emails, phone numbers, or domains.
Emails
Phones
Domains
Notes
This is my first time contributing so I am open to any feedback.