App: [$500] Delete request confirmation modal has `Delete comment` as the title
If you haven’t already, check out our contributing guidelines for onboarding and email contributors@expensify.com to request to join our Slack channel!
Action Performed:
- Create a request
- Navigate to the expense/iouReport
- Hover over the request > click the trash icon on the comment action menu
- Observe the title of the modal reads
Delete comment
Expected Result:
The delete confirmation modal should read Delete request
Actual Result:
The delete confirmation modal reads Delete comment
Workaround:
N/A
Platforms:
Which of our officially supported platforms is this issue occurring on?
- Android / native
- Android / Chrome
- iOS / native
- iOS / Safari
- MacOS / Chrome / Safari
- MacOS / Desktop
Version Number: v1.3.77-5
Reproducible in staging?: Y
Reproducible in production?: Y
If this was caught during regression testing, add the test name, ID and link from TestRail:
Email or phone of affected tester (no customers):
Logs: https://stackoverflow.com/c/expensify/questions/4856
Notes/Photos/Videos: Any additional supporting documentation
https://github.com/Expensify/App/assets/16232057/270e74dc-8c12-4715-9c36-f505e49d7da1
Expensify/Expensify Issue URL: Issue reported by: @trjExpensify Slack conversation:
Upwork Automation - Do Not Edit
- Upwork Job URL: https://www.upwork.com/jobs/~01677c1677ad8e585b
- Upwork Job ID: 1709667849059155968
- Last Price Increase: 2023-10-04
- Automatic offers:
- aimane-chnaif | Reviewer | 27107636
About this issue
- Original URL
- State: closed
- Created 9 months ago
- Comments: 25 (15 by maintainers)
This is regression from https://github.com/Expensify/App/pull/27221
Ah, you’re looking at the second place in the video you can see this same modal where it is indeed correct. Look at the first one shown at 0.10s where it’s incorrect.
I just opened the PR with the fix.
Proposal
Please re-state the problem that we are trying to solve in this issue
The delete confirmation modal reads Delete comment.
What is the root cause of that problem?
The problem is that within the
PopoverReportActionContextMenu.jscomponent:https://github.com/Expensify/App/blob/ef3073066be6855bed47088b29e99a405e1d0feb/src/pages/home/report/ContextMenu/PopoverReportActionContextMenu.js#L318C1-L333C7
The
ConfirmModaltitle passes empty objectreportActionto thereportActionContextMenu.deleteActiontranslate function which causes the function to render ‘comment’ because action value is false:https://github.com/Expensify/App/blob/ef3073066be6855bed47088b29e99a405e1d0feb/src/languages/en.ts#L403C1-L403C141
What changes do you think we should make in order to solve the problem?
Within the
PopoverReportActionContextMenu.jscomponent pass the correcttitleby passing{action: reportAction}like it is passed below for the prompt:What alternative solutions did you explore? (Optional)
N/A
Videos
https://github.com/Expensify/App/assets/56457735/cde60184-6d2b-41a4-a8cb-2d656936c4be