-
Notifications
You must be signed in to change notification settings - Fork 3k
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
Support markdown for description preview #39466
Conversation
@eVoloshchak 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] |
Reviewer Checklist
Screenshots/VideosAndroid: NativeAndroid: mWeb ChromeRecord_2024-04-03-06-44-55.mp4iOS: NativeScreen.Recording.2024-04-03.at.6.28.26.AM.moviOS: mWeb SafariScreen.Recording.2024-04-03.at.6.22.54.AM.movMacOS: Chrome / SafariScreen.Recording.2024-04-03.at.6.18.03.AM.movMacOS: DesktopScreen.Recording.2024-04-03.at.6.35.42.AM-1.mov |
@aldo-expensify Lint is failing :( |
Hmm 🤔 is it expected that we want to render the merchant as html in report preview asking because we dont render it as html in transaction preview Screen.Recording.2024-04-03.at.5.51.26.AM.mov |
Good question, checking... |
@ishpaul777 nice catch about the Merchant. I ended up rendering only as HTML if the text is coming from the description. Merchant is not rendered as html because that is consistent with the input that is not doing it either. I fixed the linter issues, sorry about that! |
Updated tests steps to check for the merchant too |
Nice! i'll complete the videos |
@techievivek 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] |
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.
LGTM
…scription-preview Support markdown for description preview (cherry picked from commit bce4724)
🚀 Cherry-picked to staging by https://github.com/jasperhuangg in version: 1.4.59-7 🚀
@Expensify/applauseleads please QA this PR and check it off on the deploy checklist if it passes. |
Looks like the desktop CP failed, rerunning it |
🚀 Deployed to production by https://github.com/Julesssss in version: 1.4.60-13 🚀
|
Details
Add new custom html tag<supporting-text>
to handle passing the styles we use for supporting textRenderHTML
along with<muted-text>
instead of<Text>
to handle the html derived from the markdownuseState
+useRef
byuseMemo
Update: changed it to use the existing
muted-text
since it looks the sameFixed Issues
$ #39451
PROPOSAL:
Tests
~test~
testas the description (markdown rendered correctly)test~merchant~
~merchant~
and notmerchant
~merchant~
and notmerchant
Offline tests
N/A
QA Steps
~test~
testas the description (markdown rendered correctly)test~merchant~
~merchant~
and notmerchant
~merchant~
and notmerchant
PR Author Checklist
### Fixed Issues
section aboveTests
sectionOffline steps
sectionQA steps
sectiontoggleReport
and notonIconClick
)myBool && <MyComponent />
.src/languages/*
files and using the translation methodSTYLE.md
) were followedAvatar
, I verified the components usingAvatar
are working as expected)StyleUtils.getBackgroundAndBorderStyle(theme.componentBG)
)Avatar
is modified, I verified thatAvatar
is working as expected in all cases)Design
label and/or tagged@Expensify/design
so the design team can review the changes.ScrollView
component to make it scrollable when more elements are added to the page.main
branch was merged into this PR after a review, I tested again and verified the outcome was still expected according to theTest
steps.Screenshots/Videos
Android: Native
Android: mWeb Chrome
iOS: Native
iOS: mWeb Safari
MacOS: Chrome / Safari
MacOS: Desktop