-
Notifications
You must be signed in to change notification settings - Fork 2.9k
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
fix error when clicking on attachment note #40844
fix error when clicking on attachment note #40844
Conversation
@shubham1206agra 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] |
@nkdengineer Please fix conflicts and can you summarize what you have done in this PR? |
This PR will create a new route:
that can be used in report attachments, note attachments and any type of attachments in the future |
@shubham1206agra Pls help review the PR when you have a chance. Thanks |
@nkdengineer Please merge main here. |
@shubham1206agra I merged main |
src/CONST.ts
Outdated
@@ -1184,6 +1184,12 @@ const CONST = { | |||
WEBP: 'image/webp', | |||
JPEG: 'image/jpeg', | |||
}, | |||
ATTACHMENT_TYPE: { | |||
REPORT: 'r', | |||
REPORT_ACTION: 'a', |
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.
Can you give me example of type a
, and s
?
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.
Now, these types are not being used. I think we can remove these and add them in the future.
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.
Why these types were added then?
Just confirming.
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.
I added them based on the comment
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.
@kidroca Can you help me understand why do we need this?
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.
The comment is just an example, you can skip the keys that don't have application here
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.
@nkdengineer Can you make the change here?
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.
@shubham1206agra I removed it
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.
I've reviewed the code and left two comments regarding potential improvements. Please have a look and let me know if you have any questions.
src/components/Attachments/AttachmentCarousel/extractAttachmentsFromNote.ts
Outdated
Show resolved
Hide resolved
@nkdengineer Bump on the comments. |
@shubham1206agra Sure. I am working on it |
@shubham1206agra I fixed comments #40844 (comment) and #40844 (comment) |
@nkdengineer Can you merge main here please? |
@shubham1206agra please check again |
Screen.Recording.2024-05-22.at.7.52.26.PM.mov@nkdengineer Wrong attachment is getting opened. |
@shubham1206agra Can you give me a tip to reproduce this bug? Currently I cannot reproduce it |
@shubham1206agra Do you have any feedback about my comment above. Here is the video from my side: Screen.Recording.2024-05-27.at.15.42.45.mov |
Reviewer Checklist
Screenshots/VideosAndroid: NativeAndroid: mWeb ChromeScreen.Recording.2024-05-27.at.5.08.49.PM.moviOS: NativeScreen.Recording.2024-05-27.at.5.23.28.PM.mp4iOS: mWeb SafariScreen.Recording.2024-05-27.at.5.06.13.PM.movMacOS: Chrome / SafariScreen.Recording.2024-05-22.at.7.44.06.PM.movMacOS: DesktopScreen.Recording.2024-05-27.at.5.16.08.PM.mov |
@chiragsalian Can you help review this one? |
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
✋ 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/chiragsalian in version: 1.4.77-11 🚀
|
🚀 Deployed to staging by https://github.com/chiragsalian in version: 1.4.77-11 🚀
|
🚀 Deployed to production by https://github.com/mountiny in version: 1.4.78-5 🚀
|
Details
Fixed Issues
$ #38835
PROPOSAL: #38835 (comment)
Tests
Offline tests
QA Steps
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
Screen.Recording.2024-04-25.at.15.37.22.mov
Android: mWeb Chrome
Screen.Recording.2024-04-25.at.15.23.32.mov
iOS: Native
Screen.Recording.2024-04-25.at.15.38.26.mov
iOS: mWeb Safari
Screen.Recording.2024-04-25.at.15.26.21.mov
MacOS: Chrome / Safari
output.mp4
MacOS: Desktop
output.mp4