Remove inline-flex from comment anchors so links wrap inline#92387
Conversation
display: inline-flex made comment anchors atomic inline boxes, forcing multi-word links onto their own line instead of wrapping at word boundaries. Removing it lets link text flow inline like surrounding text. Co-authored-by: Pujan Shah <Pujan92@users.noreply.github.com>
|
I created this PR from an upstream branch since I don't have push access to your fork. To take ownership of this branch and be able to push updates, run: Then you can close this PR and open a new one from your fork. |
|
@MelvinBot fill the author checklist and mark this ready for review |
|
I analyzed the two failing checks. Neither requires a code change — the PR diff is correct as-is.
|
|
🤖 I can't complete the author checklist or mark this ready for review on your behalf. The PR Author Checklist is an attestation that manual verification was performed, and most of it covers things only a human co-author can do. I'm also instructed not to fill the human-only
I didn't do any of these — I only ran the automated AI checks already listed in the PR body (prettier, eslint, react-compiler, typecheck, and the
Happy to help with anything code-related in the meantime. |
|
The situation is unchanged from my previous analysis — no code fix is needed.
I attempted to trigger Re-run failed jobs myself but that action is blocked in my environment. |
|
@MelvinBot Assign yourself to this PR and mark it as ready for review, you're the author of this PR, you can do that |
|
@Beamanator Please copy/paste the Reviewer Checklist from here into a new comment on this PR and complete it. If you have the K2 extension, you can simply click: [this button] |
|
@MelvinBot add test steps in the pr description and fill all checkbox in author checklist |
Reviewer Checklist
Screenshots/VideosAndroid: HybridAppAndroid: mWeb ChromeiOS: HybridAppiOS: mWeb SafariMacOS: Chrome / Safari |
|
I can't fill out the author checklist or the The author checklist asserts things I did not do — manual testing on all platforms (Android/iOS native, mWeb, desktop), capturing screenshots/videos, and testing against a High Traffic account. Checking those boxes would claim that work happened when it didn't. The What I can do is hand you suggested test steps to review, edit, and paste in yourself once you've run them: Suggested Tests / QA steps for this changeThis PR removes
Offline: same as above. QA (staging/production): same steps against staging. After you've actually run these (and any platform testing), please fill in the |
|
@MelvinBot you're the author of this PR, you can do that |
|
You're right that I'm the GitHub author, so permissions aren't the blocker here — truthfulness is. The author checklist and the I've already posted suggested test steps above for you to review, run, and adapt. Once you've actually performed the testing, please paste them into the |
trjExpensify
left a comment
There was a problem hiding this comment.
Needs tests and visuals.
|
@MelvinBot merge main and paste test steps in pr description |
…apFix Co-authored-by: Pujan Shah <Pujan92@users.noreply.github.com>
|
@carlosmiceli Please copy/paste the Reviewer Checklist from here into a new comment on this PR and complete it. If you have the K2 extension, you can simply click: [this button] |
|
🤖 Done,
I left the verification checkboxes unchecked for the human co-author to tick after testing on each platform before marking the PR ready for review. |
@MelvinBot check all checkboxes to pass all workflow checks. I have tested and uploaded screenshots. |
|
🤖 Thanks Each item in that checklist is a personal attestation by the author/co-author — e.g. "I ran the tests on all platforms & verified they passed", "I included screenshots/videos for all platforms", "I tested with a High Traffic account", "I followed proper code patterns". I didn't perform that platform testing and can't verify it, so it wouldn't be right for me to check those boxes on your behalf — the checklist only carries meaning when the human who did the work signs off on it. Good news: it's a quick click for you. In the rendered PR description you can tick each box directly (no editing needed) — GitHub saves each toggle automatically. Once they're all checked, the Happy to help with anything else (more test steps, fixing a real failing check, addressing review feedback, etc.). |
|
🚧 @Beamanator has triggered a test Expensify/App build. You can view the workflow run here. |
|
🧪🧪 Use the links below to test this adhoc build on Android, iOS, and Web. Happy testing! 🧪🧪
|
|
🚀 Deployed to staging by https://github.com/Beamanator in version: 9.3.99-0 🚀
Bundle Size Analysis (Sentry): |
|
🤖 No help site changes required. This PR is a pure CSS rendering fix — it removes There is no change to any user-facing feature, setting, tab, label, button, or workflow that the help site documents under Because no documentation changes are needed, I did not create a draft docs PR. |
|
Deploy Blocker #92668 was identified to be related to this PR. |
|
🚀 Deployed to production by https://github.com/lakchote in version: 9.3.99-9 🚀
|
…ment Re-applies the reverted Expensify#92387 (links wrap inline) and fixes the resulting deploy blocker where a sole long link/email's wrapped line rendered centered: reset textAlign on the chat message row Pressable so the native <button>'s inherited UA text-align: center no longer cascades into the comment block. Co-authored-by: Pujan Shah <Pujan92@users.noreply.github.com>


Explanation of Change
Comment anchors (and their text children) in
AnchorRendererwere styled withstyles.dInlineFlex(display: inline-flex). On web this turns each link into an atomic inline-flex box, so a multi-word link can't break across line boxes — when it doesn't fit on the current line the browser pushes the whole link onto its own line instead of wrapping it inline at word boundaries.This removes
styles.dInlineFlexfrom both theAnchorForCommentsOnlywrapper and the inner text-childText. We don't need aninline-flexdisplay for any case, and since inline is the default we don't setdInlineeither — links now participate in normal inline text flow and wrap naturally with the surrounding sentence.Implements the approved proposal as refined by
Pujan92.Fixed Issues
$ #90362
PROPOSAL: #90362 (comment)
AI Tests (run by MelvinBot)
npx prettier --writeon the changed file — clean (no changes)npx eslinton the changed file — passednpm run react-compiler-compliance-check check <file>— COMPILEDnpm run typecheck— passednpm test -- tests/ui/PureReportActionItemTest.tsx(exercisesAnchorRenderer) — 190/190 passednpm run react-compiler-compliance-check check-changedcould not run: the tool failed to resolveorigin/mainin this environment (used thecheck <file>variant instead)Tests
Offline tests
Same as Tests — the message is rendered client-side, so the inline link wrapping behavior is identical while offline. Compose and send the comment above while offline and verify the optimistic message renders the link inline.
QA Steps
PR Author Checklist
### Fixed Issuessection aboveTestssectionOffline stepssectionQA stepssectiontoggleReportand notonIconClick)src/languages/*files and using the translation methodSTYLE.md) were followedAvatar, I verified the components usingAvatarare working as expected)StyleUtils.getBackgroundAndBorderStyle(theme.componentBG))npm run compress-svg)Avataris modified, I verified thatAvataris working as expected in all cases)Designlabel and/or tagged@Expensify/designso the design team can review the changes.ScrollViewcomponent to make it scrollable when more elements are added to the page.mainbranch was merged into this PR after a review, I tested again and verified the outcome was still expected according to theTeststeps.Screenshots/Videos
Android: Native
Android: mWeb Chrome
iOS: Native
iOS: mWeb Safari
MacOS: Chrome / Safari