-
Notifications
You must be signed in to change notification settings - Fork 2.9k
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
Profile - Using \u200D as a first/last name is not treated like it’s empty but shown blank #29644
Comments
Triggered auto assignment to @MitchExpensify ( |
Bug0 Triage Checklist (Main S/O)
|
ProposalPlease re-state the problem that we are trying to solve in this issue.zero width unicode characters can be entered into First name & Last name fields, causing Display name to be shown as "empty" instead of falling back to login email, both only zero width characters are filled in the names fields. What is the root cause of that problem?We are trimming the firstName and lastName at App/src/pages/settings/Profile/DisplayNamePage.js Lines 42 to 44 in 0e64161
However trim does not remove zero width unicode characters. What changes do you think we should make in order to solve the problem?To update the trimming logic before saving values of firstName and lastName, by removing zero width unicode characters listed below:
So that input having just the zero width character will be "trimmed" to empty string, and Display Name will fallback to login email instead of empty. What alternative solutions did you explore? (Optional)Add input validation to validate First name and Last name does not contains invalid characters (including zero space unicode chars) before allow savings. |
Similar reported issue: |
Without a screenshot or recording I am closing this |
@MitchExpensify Hello |
Sorry for missing that @lanitochka17 and thanks for pointing where to look 👀 |
I don't quite follow how this will hurt user experience so closing as such |
If you haven’t already, check out our contributing guidelines for onboarding and email [email protected] to request to join our Slack channel!
Version Number: 1.3.84-0
Reproducible in staging?: Yes
Reproducible in production?: Yes
If this was caught during regression testing, add the test name, ID and link from TestRail:
Email or phone of affected tester (no customers):
Logs: https://stackoverflow.com/c/expensify/questions/4856
Expensify/Expensify Issue URL:
Issue reported by: Applause - Internal Team
Slack conversation:
Issue found when executing PR #28821
Action Performed:
to copy it and paste in the fields)
Expected Result:
It should be saved, but the name will be treated as empty so the email of the account should be shown
Actual Result:
The name is shown as blank as the character is saved but since it's invisible it won't appear as a name
Workaround:
Unknown
Platforms:
Which of our officially supported platforms is this issue occurring on?
Screenshots/Videos
Android: Native
Bug6238179_1697400812355.RPReplay_Final1697313271.mp4
Android: mWeb Chrome
iOS: Native
iOS: mWeb Safari
MacOS: Chrome / Safari
Recording.1628.mp4
MacOS: Desktop
View all open jobs on GitHub
The text was updated successfully, but these errors were encountered: