App icon indicating copy to clipboard operation
App copied to clipboard

Ensure keyboard dismisses before navigating to workspace list

Open huult opened this issue 11 months ago β€’ 1 comments

Details

Fixed Issues

$ https://github.com/Expensify/App/issues/53327 PROPOSAL: https://github.com/Expensify/App/issues/53327#issuecomment-2508862747

Tests

Same QA step

  • [x] Verify that no errors appear in the JS console

Offline tests

QA Steps

  1. Open the app and log in with an account that has more than 7 workspaces.
  2. Tap the FAB > Start Chat > Room.
  3. Wait for the keyboard to open.
  4. Select the Workspace row.
  5. Verify that the list of workspaces is fully visible.
  • [x] Verify that no errors appear in the JS console

PR Author Checklist

  • [x] I linked the correct issue in the ### Fixed Issues section above
  • [x] I wrote clear testing steps that cover the changes made in this PR
    • [x] I added steps for local testing in the Tests section
    • [x] I added steps for the expected offline behavior in the Offline steps section
    • [x] I added steps for Staging and/or Production testing in the QA steps section
    • [x] I added steps to cover failure scenarios (i.e. verify an input displays the correct error message if the entered data is not correct)
    • [x] I turned off my network connection and tested it while offline to ensure it matches the expected behavior (i.e. verify the default avatar icon is displayed if app is offline)
    • [x] I tested this PR with a High Traffic account against the staging or production API to ensure there are no regressions (e.g. long loading states that impact usability).
  • [x] I included screenshots or videos for tests on all platforms
  • [x] I ran the tests on all platforms & verified they passed on:
    • [x] Android: Native
    • [x] Android: mWeb Chrome
    • [x] iOS: Native
    • [x] iOS: mWeb Safari
    • [x] MacOS: Chrome / Safari
    • [x] MacOS: Desktop
  • [x] I verified there are no console errors (if there's a console error not related to the PR, report it or open an issue for it to be fixed)
  • [x] I followed proper code patterns (see Reviewing the code)
    • [x] I verified that any callback methods that were added or modified are named for what the method does and never what callback they handle (i.e. toggleReport and not onIconClick)
    • [x] I verified that the left part of a conditional rendering a React component is a boolean and NOT a string, e.g. myBool && <MyComponent />.
    • [x] I verified that comments were added to code that is not self explanatory
    • [x] I verified that any new or modified comments were clear, correct English, and explained "why" the code was doing something instead of only explaining "what" the code was doing.
    • [x] I verified any copy / text shown in the product is localized by adding it to src/languages/* files and using the translation method
      • [x] If any non-english text was added/modified, I verified the translation was requested/reviewed in #expensify-open-source and it was approved by an internal Expensify engineer. Link to Slack message:
    • [x] I verified all numbers, amounts, dates and phone numbers shown in the product are using the localization methods
    • [x] I verified any copy / text that was added to the app is grammatically correct in English. It adheres to proper capitalization guidelines (note: only the first word of header/labels should be capitalized), and is either coming verbatim from figma or has been approved by marketing (in order to get marketing approval, ask the Bug Zero team member to add the Waiting for copy label to the issue)
    • [x] I verified proper file naming conventions were followed for any new files or renamed files. All non-platform specific files are named after what they export and are not named "index.js". All platform-specific files are named for the platform the code supports as outlined in the README.
    • [x] I verified the JSDocs style guidelines (in STYLE.md) were followed
  • [x] If a new code pattern is added I verified it was agreed to be used by multiple Expensify engineers
  • [x] I followed the guidelines as stated in the Review Guidelines
  • [x] I tested other components that can be impacted by my changes (i.e. if the PR modifies a shared library or component like Avatar, I verified the components using Avatar are working as expected)
  • [x] I verified all code is DRY (the PR doesn't include any logic written more than once, with the exception of tests)
  • [x] I verified any variables that can be defined as constants (ie. in CONST.js or at the top of the file that uses the constant) are defined as such
  • [x] I verified that if a function's arguments changed that all usages have also been updated correctly
  • [x] If any new file was added I verified that:
    • [x] The file has a description of what it does and/or why is needed at the top of the file if the code is not self explanatory
  • [x] If a new CSS style is added I verified that:
    • [x] A similar style doesn't already exist
    • [x] The style can't be created with an existing StyleUtils function (i.e. StyleUtils.getBackgroundAndBorderStyle(theme.componentBG))
  • [x] If the PR modifies code that runs when editing or sending messages, I tested and verified there is no unexpected behavior for all supported markdown - URLs, single line code, code blocks, quotes, headings, bold, strikethrough, and italic.
  • [x] If the PR modifies a generic component, I tested and verified that those changes do not break usages of that component in the rest of the App (i.e. if a shared library or component like Avatar is modified, I verified that Avatar is working as expected in all cases)
  • [x] If the PR modifies a component related to any of the existing Storybook stories, I tested and verified all stories for that component are still working as expected.
  • [x] If the PR modifies a component or page that can be accessed by a direct deeplink, I verified that the code functions as expected when the deeplink is used - from a logged in and logged out account.
  • [x] If the PR modifies the UI (e.g. new buttons, new UI components, changing the padding/spacing/sizing, moving components, etc) or modifies the form input styles:
    • [x] I verified that all the inputs inside a form are aligned with each other.
  • [x] If a new page is added, I verified it's using the ScrollView component to make it scrollable when more elements are added to the page.
  • [x] If the main branch was merged into this PR after a review, I tested again and verified the outcome was still expected according to the Test steps.

Screenshots/Videos

Android: Native

https://github.com/user-attachments/assets/3fee6c07-479a-48ce-a0ba-91445870c724

Android: mWeb Chrome

https://github.com/user-attachments/assets/def731ea-8580-4fd1-97fc-ed2f24c0d0a1

iOS: Native

https://github.com/user-attachments/assets/44638735-1477-4199-9e5b-bfbec051c609

iOS: mWeb Safari

https://github.com/user-attachments/assets/b52242d8-a2e9-4c41-abf9-13fedaed0a03

MacOS: Chrome / Safari

https://github.com/user-attachments/assets/7480c8c4-7e44-47ff-acb4-84974cf37e24

MacOS: Desktop

https://github.com/user-attachments/assets/74b46483-17f4-4166-862a-df3c0dbfeb7c

huult avatar Dec 11 '24 01:12 huult

@sobitneupane 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]

melvin-bot[bot] avatar Dec 11 '24 01:12 melvin-bot[bot]

@sobitneupane in your iOS video, it looks like the scrollbar is right in the middle of the view - is that known?

rafecolton avatar Dec 13 '24 02:12 rafecolton

@rafecolton It's not related to the PR. It can be reproduced in main as well.

https://github.com/user-attachments/assets/61db1378-45ba-494a-bf09-2fc800d70aba

sobitneupane avatar Dec 13 '24 09:12 sobitneupane

:hand: This PR was not deployed to staging yet because QA is ongoing. It will be automatically deployed to staging after the next production release.

OSBotify avatar Dec 14 '24 01:12 OSBotify

I still encountered the issue in the latest main. Could you help confirm, pls @huult?

truph01 avatar Dec 14 '24 16:12 truph01

πŸš€ Deployed to staging by https://github.com/rafecolton in version: 9.0.77-0 πŸš€

platform result
πŸ€– android πŸ€– success βœ…
πŸ–₯ desktop πŸ–₯ success βœ…
🍎 iOS 🍎 success βœ…
πŸ•Έ web πŸ•Έ success βœ…
πŸ€–πŸ”„ android HybridApp πŸ€–πŸ”„ success βœ…
πŸŽπŸ”„ iOS HybridApp πŸŽπŸ”„ failure ❌

github-actions[bot] avatar Dec 18 '24 13:12 github-actions[bot]

πŸš€ Deployed to production by https://github.com/jasperhuangg in version: 9.0.77-6 πŸš€

platform result
πŸ€– android πŸ€– true ❌
πŸ–₯ desktop πŸ–₯ success βœ…
🍎 iOS 🍎 success βœ…
πŸ•Έ web πŸ•Έ success βœ…
πŸ€–πŸ”„ android HybridApp πŸ€–πŸ”„ failure ❌
πŸŽπŸ”„ iOS HybridApp πŸŽπŸ”„ success βœ…

github-actions[bot] avatar Dec 23 '24 20:12 github-actions[bot]

@rafecolton @sobitneupane @huult Coming from https://github.com/Expensify/App/pull/55047, @truph01 noticed that this PR didn't solve the original problem totally. And he introduced a new approach to solve it completely and suggested reverting this change. Could you guys provide any thoughts on it?

DylanDylann avatar Jan 14 '25 08:01 DylanDylann

@DylanDylann Which issue did you mention?

huult avatar Jan 14 '25 13:01 huult

This one: https://github.com/Expensify/App/issues/54157

DylanDylann avatar Jan 14 '25 13:01 DylanDylann

@DylanDylann Is the issue https://github.com/Expensify/App/issues/53327 still fixed after applying the new solution, and have you ensured there are no regression tests failing?

huult avatar Jan 14 '25 13:01 huult

@DylanDylann Is the issue https://github.com/Expensify/App/issues/53327 still fixed after applying the new solution, and have you ensured there are no regression tests failing?

It is the reason why I re-call you here πŸ˜„

It seems that this PR can't ensure the keyboard dismisses before navigating to the workspace list. So https://github.com/Expensify/App/issues/53327 still happening. @truph01 is this right?

DylanDylann avatar Jan 14 '25 13:01 DylanDylann

@DylanDylann https://github.com/Expensify/App/issues/53327 is closed without any issues because QA verified it. If you would like to revert this pull request, I think we need confirmation from @sobitneupane because he is C+. As for my side, I am not sure about that because I don’t have the context for the issue you encountered, but I will review your issue within three working days and provide my feedback. Thanks.

huult avatar Jan 14 '25 13:01 huult

@DylanDylann If merging https://github.com/Expensify/App/pull/55047 doesn't recreate this issue, I am okay with the changes. This is the specification of the device where the issue was noticed.

sobitneupane avatar Jan 15 '25 11:01 sobitneupane

@sobitneupane Sure, merging my PR does not recreate this issue.

truph01 avatar Jan 15 '25 11:01 truph01