Skip to content
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

[HOLD for payment 2024-01-17] [$500] mWeb - Room - The invited users email id is not fully visible in room chat page #33305

Closed
1 of 6 tasks
lanitochka17 opened this issue Dec 19, 2023 · 31 comments
Assignees
Labels
Awaiting Payment Auto-added when associated PR is deployed to production Bug Something is broken. Auto assigns a BugZero manager. Daily KSv2 External Added to denote the issue can be worked on by a contributor

Comments

@lanitochka17
Copy link

lanitochka17 commented Dec 19, 2023

If you haven’t already, check out our contributing guidelines for onboarding and email contributors@expensify.com to request to join our Slack channel!


Version Number: 1.4.14
Reproducible in staging?: Y
Reproducible in production?: Y
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:

Action Performed:

  1. Go to https://staging.new.expensify.com/
  2. Tap on a room chat
  3. Tap on room header
  4. Tap on members---- Invite
  5. Invite 2 members with long email id

Expected Result:

The invited users email id must be fully visible in room chat page

Actual Result:

The invited users email id is not fully visible in room chat page

Workaround:

Unknown

Platforms:

Which of our officially supported platforms is this issue occurring on?

  • Android: Native
  • Android: mWeb Chrome
  • iOS: Native
  • iOS: mWeb Safari
  • MacOS: Chrome / Safari
  • MacOS: Desktop

Screenshots/Videos

Add any screenshot/video evidence

Bug6319929_1703004451885.room.mp4
Bug6319929_1703004451885.room.mp4

View all open jobs on GitHub

Upwork Automation - Do Not Edit
  • Upwork Job URL: https://www.upwork.com/jobs/~01118481c486c1f575
  • Upwork Job ID: 1737160340105293824
  • Last Price Increase: 2024-01-02
  • Automatic offers:
    • jjcoffee | Reviewer | 28077803
    • bernhardoj | Contributor | 28077804
Issue OwnerCurrent Issue Owner: @muttmuure
@lanitochka17 lanitochka17 added External Added to denote the issue can be worked on by a contributor Daily KSv2 Bug Something is broken. Auto assigns a BugZero manager. labels Dec 19, 2023
@melvin-bot melvin-bot bot changed the title mWeb - Room - The invited users email id is not fully visible in room chat page [$500] mWeb - Room - The invited users email id is not fully visible in room chat page Dec 19, 2023
Copy link

melvin-bot bot commented Dec 19, 2023

Job added to Upwork: https://www.upwork.com/jobs/~01118481c486c1f575

Copy link

melvin-bot bot commented Dec 19, 2023

Triggered auto assignment to @muttmuure (Bug), see https://stackoverflow.com/c/expensify/questions/14418 for more details.

@melvin-bot melvin-bot bot added the Help Wanted Apply this label when an issue is open to proposals by contributors label Dec 19, 2023
Copy link

melvin-bot bot commented Dec 19, 2023

Bug0 Triage Checklist (Main S/O)

  • This "bug" occurs on a supported platform (ensure Platforms in OP are ✅)
  • This bug is not a duplicate report (check E/App issues and #expensify-bugs)
    • If it is, comment with a link to the original report, close the issue and add any novel details to the original issue instead
  • This bug is reproducible using the reproduction steps in the OP. S/O
    • If the reproduction steps are clear and you're unable to reproduce the bug, check with the reporter and QA first, then close the issue.
    • If the reproduction steps aren't clear and you determine the correct steps, please update the OP.
  • This issue is filled out as thoroughly and clearly as possible
    • Pay special attention to the title, results, platforms where the bug occurs, and if the bug happens on staging/production.
  • I have reviewed and subscribed to the linked Slack conversation to ensure Slack/Github stay in sync

Copy link

melvin-bot bot commented Dec 19, 2023

Triggered auto assignment to Contributor-plus team member for initial proposal review - @jjcoffee (External)

@bernhardoj
Copy link
Contributor

bernhardoj commented Dec 19, 2023

Proposal

Please re-state the problem that we are trying to solve in this issue.

The long invited message is out of screen.

What is the root cause of that problem?

We don't have a style to break the word if it's very long. For other types of messages, we have a View wrapper with a style of break-word.

return (
<View style={[styles.chatItemMessage, ...props.style]}>
{!props.isHidden ? (
renderReportActionItemFragments(isApprovedOrSubmittedReportAction)
) : (
<Text style={[styles.textLabelSupporting, styles.lh20]}>{props.translate('moderation.flaggedContent')}</Text>
)}
</View>

App/src/styles/index.ts

Lines 1744 to 1753 in 9857874

chatItemMessage: {
color: theme.text,
fontSize: variables.fontSizeNormal,
fontFamily: fontFamily.EXP_NEUE,
lineHeight: variables.lineHeightXLarge,
maxWidth: '100%',
...cursor.cursorAuto,
...whiteSpace.preWrap,
...wordBreak.breakWord,
},

But we don't have for invited message.

return (
<TextCommentFragment
fragment={fragment}
displayAsGroup={props.displayAsGroup}
style={props.style}
source=""
styleAsDeleted={false}
/>
);

What changes do you think we should make in order to solve the problem?

Have the same view wrapper and the same style.

image

What alternative solutions did you explore? (Optional)

Or just apply a single break word style (wordBreak.breakWord or wordBreak.breakAll), but I still prefer with the main solution to make it consistent.

@yh-0218
Copy link
Contributor

yh-0218 commented Dec 19, 2023

Proposal

Please re-state the problem that we are trying to solve in this issue.

The long invited message is out of screen.

What is the root cause of that problem?

We display text using RenderCommentHTML here

What changes do you think we should make in order to solve the problem?

I think we need same logic between "workspace added message" and "room invite message".
For this we need to remove codes.

if (ReportActionsUtils.isMemberChangeAction(props.action)) {
const fragment = ReportActionsUtils.getMemberChangeMessageFragment(props.action);
return (
<TextCommentFragment
fragment={fragment}
displayAsGroup={props.displayAsGroup}
style={props.style}
source=""
styleAsDeleted={false}
/>
);
}

What alternative solutions did you explore? (Optional)

@samilabud
Copy link
Contributor

It looks like this is intentional because this has a tooltip to view the entire mail:

image

But if not, here is my proposal:

Proposal

Please re-state the problem that we are trying to solve in this issue.

mWeb - Room - The invited users email id is not fully visible in room chat page

What is the root cause of that problem?

The content of the account/email text is shorter than the container and we are specifying the max line number of 1, the content will never break the line due to this pre style and the next below:

What changes do you think we should make in order to solve the problem?

We can switch the numberOfLines props to change it by 2 when the mouse enters and leave like:

const [alterTextNumberOfLines, setAlterTextNumberOfLines] = useState(1);
.
.
.
   <Text
        style={alternateTextStyles}
        numberOfLines={alterTextNumberOfLines}
        onMouseEnter={() => setAlterTextNumberOfLines(2)}
        onMouseLeave={() => setAlterTextNumberOfLines(1)}
    >
        {item.alternateText}
    </Text>

Also, we should remove the unnecessary prop in:

Result:

After.changes.mouse.over.invites.mov

@Krishna2323
Copy link
Contributor

Krishna2323 commented Dec 19, 2023

Proposal

Please re-state the problem that we are trying to solve in this issue.

mWeb - Room - The invited users email id is not fully visible in room chat page

What is the root cause of that problem?

For lengthy words, we lack a specific styling to enable word-breaking. Conversely, in various message formats, we wrap with a View element featuring a break-word style.

What changes do you think we should make in order to solve the problem?

Instead of adding the word-breaking style everywhere we should add it in the defaultViewProps styles inside BaseHTMLEngineProvider, so we don't face similar issue in future. We can add the styling to defaultViewProps styles or defaultTextProps styles.

const defaultTextProps = useMemo(() => ({selectable: props.textSelectable, allowFontScaling: false, textBreakStrategy: 'simple'}), [props.textSelectable]);
const defaultViewProps = {style: [styles.alignItemsStart, styles.userSelectText]};

Updated code: const defaultViewProps = {style: [styles.alignItemsStart, styles.userSelectText, styles.breakWord]};

Result

breakWord

@melvin-bot melvin-bot bot added the Overdue label Dec 21, 2023
Copy link

melvin-bot bot commented Dec 25, 2023

@jjcoffee, @muttmuure Huh... This is 4 days overdue. Who can take care of this?

Copy link

melvin-bot bot commented Dec 26, 2023

📣 It's been a week! Do we have any satisfactory proposals yet? Do we need to adjust the bounty for this issue? 💸

Copy link

melvin-bot bot commented Dec 27, 2023

@jjcoffee, @muttmuure 6 days overdue. This is scarier than being forced to listen to Vogon poetry!

Copy link

melvin-bot bot commented Dec 29, 2023

@jjcoffee, @muttmuure 8 days overdue is a lot. Should this be a Weekly issue? If so, feel free to change it!

Copy link

melvin-bot bot commented Jan 1, 2024

@jjcoffee, @muttmuure 12 days overdue now... This issue's end is nigh!

@jjcoffee
Copy link
Contributor

jjcoffee commented Jan 2, 2024

Reviewing today!

@melvin-bot melvin-bot bot removed the Overdue label Jan 2, 2024
Copy link

melvin-bot bot commented Jan 2, 2024

📣 It's been a week! Do we have any satisfactory proposals yet? Do we need to adjust the bounty for this issue? 💸

@jjcoffee
Copy link
Contributor

jjcoffee commented Jan 2, 2024

I'm inclined to go with @bernhardoj's proposal as the email is styled as a mention and we already wrap mentions in normal messages:

image

I don't think in this case we would want to apply it as a general style for BaseHTMLEngineProvider as in @Krishna2323's proposal, as it could cause unexpected results.

🎀👀🎀 C+ reviewed

Copy link

melvin-bot bot commented Jan 2, 2024

Triggered auto assignment to @dangrous, see https://stackoverflow.com/c/expensify/questions/7972 for more details.

Copy link

melvin-bot bot commented Jan 2, 2024

@dangrous @jjcoffee @muttmuure this issue was created 2 weeks ago. Are we close to approving a proposal? If not, what's blocking us from getting this issue assigned? Don't hesitate to create a thread in #expensify-open-source to align faster in real time. Thanks!

@dangrous
Copy link
Contributor

dangrous commented Jan 2, 2024

Yeah I think that's fine! My only note would be to double check those other styles added in chatItemMessage don't change the display other than wrapping, but I don't think they will.

Assigning!

@melvin-bot melvin-bot bot removed the Help Wanted Apply this label when an issue is open to proposals by contributors label Jan 2, 2024
Copy link

melvin-bot bot commented Jan 2, 2024

📣 @jjcoffee 🎉 An offer has been automatically sent to your Upwork account for the Reviewer role 🎉 Thanks for contributing to the Expensify app!

Offer link
Upwork job

Copy link

melvin-bot bot commented Jan 2, 2024

📣 @bernhardoj 🎉 An offer has been automatically sent to your Upwork account for the Contributor role 🎉 Thanks for contributing to the Expensify app!

Offer link
Upwork job
Please accept the offer and leave a comment on the Github issue letting us know when we can expect a PR to be ready for review 🧑‍💻
Keep in mind: Code of Conduct | Contributing 📖

@melvin-bot melvin-bot bot added Reviewing Has a PR in review Weekly KSv2 and removed Daily KSv2 labels Jan 3, 2024
@bernhardoj
Copy link
Contributor

PR is ready

cc: @jjcoffee

@melvin-bot melvin-bot bot added Weekly KSv2 Awaiting Payment Auto-added when associated PR is deployed to production and removed Weekly KSv2 labels Jan 10, 2024
@melvin-bot melvin-bot bot changed the title [$500] mWeb - Room - The invited users email id is not fully visible in room chat page [HOLD for payment 2024-01-17] [$500] mWeb - Room - The invited users email id is not fully visible in room chat page Jan 10, 2024
@melvin-bot melvin-bot bot removed the Reviewing Has a PR in review label Jan 10, 2024
Copy link

melvin-bot bot commented Jan 10, 2024

Reviewing label has been removed, please complete the "BugZero Checklist".

Copy link

melvin-bot bot commented Jan 10, 2024

The solution for this issue has been 🚀 deployed to production 🚀 in version 1.4.23-4 and is now subject to a 7-day regression period 📆. Here is the list of pull requests that resolve this issue:

If no regressions arise, payment will be issued on 2024-01-17. 🎊

For reference, here are some details about the assignees on this issue:

Copy link

melvin-bot bot commented Jan 10, 2024

BugZero Checklist: The PR fixing this issue has been merged! The following checklist (instructions) will need to be completed before the issue can be closed:

  • [@jjcoffee] The PR that introduced the bug has been identified. Link to the PR:
  • [@jjcoffee] The offending PR has been commented on, pointing out the bug it caused and why, so the author and reviewers can learn from the mistake. Link to comment:
  • [@jjcoffee] A discussion in #expensify-bugs has been started about whether any other steps should be taken (e.g. updating the PR review checklist) in order to catch this type of bug sooner. Link to discussion:
  • [@jjcoffee] Determine if we should create a regression test for this bug.
  • [@jjcoffee] If we decide to create a regression test for the bug, please propose the regression test steps to ensure the same bug will not reach production again.
  • [@muttmuure] Link the GH issue for creating/updating the regression test once above steps have been agreed upon:

@melvin-bot melvin-bot bot added Daily KSv2 and removed Weekly KSv2 labels Jan 16, 2024
@dangrous
Copy link
Contributor

@jjcoffee I think we're ready to get the checklist updated and close this out!

@jjcoffee
Copy link
Contributor

  • The PR that introduced the bug has been identified. Link to the PR: translate invite member to room #30927
  • The offending PR has been commented on, pointing out the bug it caused and why, so the author and reviewers can learn from the mistake. Link to comment: https://github.com/Expensify/App/pull/30927/files#r1456022482
  • A discussion in #expensify-bugs has been started about whether any other steps should be taken (e.g. updating the PR review checklist) in order to catch this type of bug sooner. Link to discussion: N/A - just needed more thorough testing
  • Determine if we should create a regression test for this bug. Yes
  • If we decide to create a regression test for the bug, please propose the regression test steps to ensure the same bug will not reach production again.

Regression Test Proposal

  1. Open any room chat
  2. Invite 2 users with a very long email
  3. Verify you can see the whole invited message and that the long email text wraps, rather than overflowing the screen

Do we agree 👍 or 👎

@dangrous
Copy link
Contributor

Looks good! One tiny edit, just for clarity:

  1. Invite 2 users with very long email addresses (+50 characters)

@bernhardoj
Copy link
Contributor

@muttmuure hi, I think we haven't been paid yet.

@Julesssss Julesssss reopened this Jan 23, 2024
@melvin-bot melvin-bot bot removed the Overdue label Jan 23, 2024
@jjcoffee
Copy link
Contributor

@muttmuure Friendly bump for payment! 🙇

@muttmuure
Copy link
Contributor

Oops, sorry!

All paid up

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Awaiting Payment Auto-added when associated PR is deployed to production Bug Something is broken. Auto assigns a BugZero manager. Daily KSv2 External Added to denote the issue can be worked on by a contributor
Projects
None yet
Development

No branches or pull requests

9 participants