-
Notifications
You must be signed in to change notification settings - Fork 3.5k
Company card - Android: "Can't downgrade workspace" content is very small when font size is small #76092
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
Conversation
|
@bernhardoj 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] |
|
@situchan will review this since it comes from our PR |
Codecov Report✅ Changes either increased or maintained existing code coverage, great job!
|
|
@twilight2294 just a tip, you can add the original issue as the last issue on the |
|
Tagging in @Expensify/design team 👍 |
|
Don't we have upper and lower bounds for font sizes even when the user adjusts via settings? |
|
At least it looks like the left screenshot uses the same body font. The right is wrong. Can you scale the font size up as well to see that they interact the same? |
@dubielzyk-expensify what's the expected result now? do we not want to adjust the font at all? |
|
Looking |
|
Fixed the code to not update the font size : Screen.Recording.2025-12-15.at.2.29.38.PM.mov |
|
bump for review @situchan |
|
bump |
| return onLinkPress ? ( | ||
| <RenderHTMLConfigProvider | ||
| defaultTextProps={{selectable: true}} | ||
| defaultTextProps={{selectable: true, allowFontScaling: false}} |
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.
We already set this prop here:
| const defaultTextProps: TextProps = useMemo(() => ({selectable: textSelectable, allowFontScaling: false, textBreakStrategy: 'simple'}), [textSelectable]); |
Do you know why it doesn't work?
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.
Nvm, we're rendering separately. Not related each other.
App/src/components/HTMLEngineProvider/BaseHTMLEngineProvider.tsx
Lines 237 to 245 in 75234df
| <RenderHTMLConfigProvider | |
| defaultTextProps={defaultTextProps} | |
| defaultViewProps={defaultViewProps} | |
| renderers={htmlRenderers} | |
| computeEmbeddedMaxWidth={computeEmbeddedMaxWidth} | |
| enableExperimentalBRCollapsing={enableExperimentalBRCollapsing} | |
| > | |
| {children} | |
| </RenderHTMLConfigProvider> |
App/src/components/RenderHTML.tsx
Lines 51 to 56 in 75234df
| <RenderHTMLConfigProvider | |
| defaultTextProps={{selectable: true}} | |
| renderersProps={renderersProps} | |
| > | |
| {htmlSource} | |
| </RenderHTMLConfigProvider> |
Reviewer Checklist
Screenshots/Videos |
|
This is global fix for all texts rendered with @twilight2294 please add screenshots for all platforms. |
Can you also add more tests to make sure other uses of RenderHTML still work as intended? |
|
Text and UI wise it looks correct now 👍 |
|
✋ This PR was not deployed to staging yet because QA is ongoing. It will be automatically deployed to staging after the next production release. |
|
🚀 Deployed to staging by https://github.com/cead22 in version: 9.2.95-0 🚀
|
|
🚀 Deployed to production by https://github.com/arosiclair in version: 9.2.95-5 🚀
|









Explanation of Change
This PR is a follow up to #72926, there is an edge case where on android if the font is small, then the text is displayed extra small, we fix that with this PR.
Fixed Issues
$ #74299
PROPOSAL: N/A
Tests
Offline tests
QA Steps
Precondition:
Test:
Verify that "Can't downgrade workspace" content will not be too small.
PR Author Checklist
### Fixed Issuessection aboveTestssectionOffline stepssectionQA stepssectioncanBeMissingparam foruseOnyxtoggleReportand 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.Screen.Recording.2025-11-26.at.11.03.28.AM.mov