Follow up improvements for inline code blocks on iOS#89705
Follow up improvements for inline code blocks on iOS#89705QichenZhu wants to merge 1 commit intoExpensify:mainfrom
Conversation
|
|
|
|
||
| using namespace facebook::react; | ||
|
|
||
| +static const CGFloat inlineCodeBackgroundTopInset = 3; |
There was a problem hiding this comment.
The value is agreed with the design team to make letters visually centered. We can't derive it, so define a const for it.
|
|
||
| if (textAttributes.backgroundColor || !isnan(textAttributes.opacity)) { | ||
| - attributes[NSBackgroundColorAttributeName] = RCTEffectiveBackgroundColorFromTextAttributes(textAttributes); | ||
| + UIColor *bgColor = RCTEffectiveBackgroundColorFromTextAttributes(textAttributes) ?: [UIColor clearColor]; |
There was a problem hiding this comment.
RCTEffectiveBackgroundColorFromTextAttributes won't return nil , but that's not documented and subject to change, so fall back to clearColor just in case.
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 59c2eca268
ℹ️ About Codex in GitHub
Codex has been enabled to automatically review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
When you sign up for Codex through ChatGPT, Codex can also answer questions or update the PR, like "@codex address that feedback".
Explanation of Change
This implements step 1 on iOS of the 3-step incremental approach:
Fixed Issues
$ #57556
PROPOSAL:
Tests
Note: This change only affects iOS Native.
Offline tests
Same as Tests.
QA Steps
Same as Tests.
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 (N/A)
Android: mWeb Chrome (N/A)
iOS: Native
iOS: mWeb Safari (N/A)
MacOS: Chrome / Safari (N/A)