App
App copied to clipboard
Poc/split navs
Details
Fixed Issues
$ PROPOSAL:
Tests
- [ ] Verify that no errors appear in the JS console
Offline tests
QA Steps
- [ ] Verify that no errors appear in the JS console
PR Author Checklist
- [ ] I linked the correct issue in the
### Fixed Issuessection above - [ ] I wrote clear testing steps that cover the changes made in this PR
- [ ] I added steps for local testing in the
Testssection - [ ] I added steps for the expected offline behavior in the
Offline stepssection - [ ] I added steps for Staging and/or Production testing in the
QA stepssection - [ ] I added steps to cover failure scenarios (i.e. verify an input displays the correct error message if the entered data is not correct)
- [ ] 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)
- [ ] 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).
- [ ] I added steps for local testing in the
- [ ] I included screenshots or videos for tests on all platforms
- [ ] I ran the tests on all platforms & verified they passed on:
- [ ] Android: Native
- [ ] Android: mWeb Chrome
- [ ] iOS: Native
- [ ] iOS: mWeb Safari
- [ ] MacOS: Chrome / Safari
- [ ] MacOS: Desktop
- [ ] 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)
- [ ] I followed proper code patterns (see Reviewing the code)
- [ ] 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.
toggleReportand notonIconClick) - [ ] I verified that the left part of a conditional rendering a React component is a boolean and NOT a string, e.g.
myBool && <MyComponent />. - [ ] I verified that comments were added to code that is not self explanatory
- [ ] 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.
- [ ] I verified any copy / text shown in the product is localized by adding it to
src/languages/*files and using the translation method- [ ] 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:
- [ ] I verified all numbers, amounts, dates and phone numbers shown in the product are using the localization methods
- [ ] 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)
- [ ] 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.
- [ ] I verified the JSDocs style guidelines (in
STYLE.md) were followed
- [ ] 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.
- [ ] If a new code pattern is added I verified it was agreed to be used by multiple Expensify engineers
- [ ] I followed the guidelines as stated in the Review Guidelines
- [ ] 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 usingAvatarare working as expected) - [ ] I verified all code is DRY (the PR doesn't include any logic written more than once, with the exception of tests)
- [ ] 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
- [ ] I verified that if a function's arguments changed that all usages have also been updated correctly
- [ ] If any new file was added I verified that:
- [ ] 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
- [ ] If a new CSS style is added I verified that:
- [ ] A similar style doesn't already exist
- [ ] The style can't be created with an existing StyleUtils function (i.e.
StyleUtils.getBackgroundAndBorderStyle(theme.componentBG))
- [ ] 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.
- [ ] 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
Avataris modified, I verified thatAvataris working as expected in all cases) - [ ] 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.
- [ ] 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.
- [ ] 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:
- [ ] I verified that all the inputs inside a form are aligned with each other.
- [ ] I added
Designlabel and/or tagged@Expensify/designso the design team can review the changes.
- [ ] If a new page is added, I verified it's using the
ScrollViewcomponent to make it scrollable when more elements are added to the page. - [ ] If the
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
Android: mWeb Chrome
iOS: Native
iOS: mWeb Safari
MacOS: Chrome / Safari
MacOS: Desktop
:test_tube::test_tube: Use the links below to test this adhoc build on Android, iOS, Desktop, and Web. Happy testing! :test_tube::test_tube:
| Android :robot: | iOS :apple: |
|---|---|
| https://ad-hoc-expensify-cash.s3.amazonaws.com/android/49539/index.html | https://ad-hoc-expensify-cash.s3.amazonaws.com/ios/49539/index.html |
| Desktop :computer: | Web :spider_web: |
| https://ad-hoc-expensify-cash.s3.amazonaws.com/desktop/49539/NewExpensify.dmg | https://49539.pr-testing.expensify.com |
:eyes: View the workflow run that generated this build :eyes:
https://github.com/user-attachments/assets/d7b55ed8-616e-4a9b-94b9-8dc658ba4856
There are no page animations in the settings stack
I took this for a quick spin on Chrome/web and it worked fairly well, including properly accounting for the browser back case. One thing I noticed, though I'm not sure if it's related to this PR or not: I occasionally experienced performance issues, where the responsiveness of the page would slow down and almost freeze up for a second or two. I saw this on the Settings pages. I can do a profile trace if helpful, just let me know.
Definitely performance is something we need to keep in mind
@mountiny If I understand correctly this is something that we want. Those screens have the bottom tab bar. Other bottom tab screens don't have animations from the beginning.
@JmillsExpensify we are still working on adjusting performance tricks for these changes. Please point us to flows that feels slower than before so we can investigate it 🙇
If I understand correctly this is something that we want. Those screens have the bottom tab bar. Other bottom tab screens don't have animations from the beginning.
Hmm, I dont think we want that, going deeper in the settings should have animations, same as going to a report from LHN has animation @Expensify/design @trjExpensify @JmillsExpensify
@adamgrzybowski Wanted to report here as well that I think the performance on web for me is gradually getting worse and this morning it's noticeably slow, you can see it here as well which I have recorded for a different bug
https://github.com/user-attachments/assets/be3de8ff-1183-4a43-899d-b67d3f492f39
Hmm, I dont think we want that, going deeper in the settings should have animations, same as going to a report from LHN has animation
https://github.com/user-attachments/assets/7798ff81-4982-4db5-8b41-1e862e222a91
But doesn't that look weird? You can see how one bottom tab bar covers the previous one with animation.
cc: @mountiny
Yeah, I think that does look weird. The bottom tab bar feels like it's part of page being animated in, rather than persisting across the different pages.
Yeah that looks a bit off. The view should go over the bottom navigation instead. Though there's another issue to put the bottom navigation on top in workspaces.
Which should give us this:
https://github.com/user-attachments/assets/6fc1ef59-d4c6-4a27-bec9-b1c4e2ddc563
I agree that the bottom tab should not animate if it's staying on another page, too. I would defer to @dubielzyk-expensify and the design team to see how we want to handle this.
The video that Jon shared is what I would expect and prefer. But if that's not technically feasible at the moment, I would rather have the bottom tabs than the animation.
https://github.com/Expensify/App/pull/49539#issuecomment-2375537540 is what I would expect and prefer. But if that's not technically feasible at the moment, I would rather have the bottom tabs than the animation.
That's the problem. It may be tough to implement and if that's okay I would investigate this as follow-up. But let me explain why this is problematic at all.
Previously, we had a navigator that displayed a bottom tab bar over every screen within itself. This approach did not allow us to place the bottom tab bar on every screen in the app. Only on screens in this particular navigator. And it definitely did not allow us to display the bottom tab bar conditionally, as in the "Workspaces screen" case.
We decided to render the bottom on every screen that requires it instead. This approach gives us a lot of flexibility.
We did know that we couldn't create an animation of sliding screen with the bottom tab onto another screen with the bottom tab. But we assumed that as in current use cases, we won't animate screens with the bottom tab so that's not a problem.
Let's assume that we want to have this animation and we won't display it on every page but we will figure out a way to do it smarter.
https://github.com/Expensify/App/pull/49539#issuecomment-2375537540
All screens that you can open from the menu visible in the video above are on the same level. Screen containing this menu is also on the same level. If that doesn't make sense, please consider the fact that we also need to handle the wide layout with this structure.
That means they are rendered with one <StackView />. In the case of workspaces screen and settings root we would need to render the bottom tab bar on top of this stack view. For other screens, we would need to render it somewhere between these cards to have proper animation. But we can't really put anything between these cards. The task will be even harder given the incoming <NativeStackView /> which leaves us with even less wiggle room.
I am not saying it is impossible. I just want to give you context on how complex is adding this little animation. I have a few tricks in my mind but I would rather focus on this after migrating to the new structure.
When it comes to performance. I started digging and couldn't reproduce the laggy RHP that you filmed @mountiny. I might have to try the high traffic account or something like that.
However, I discovered a different issue when switching to the "Reports" tab.
What you can notice in our POC is that you can't see the skeleton loading. The first render of the report screen is delayed in comparison to the main.
https://github.com/user-attachments/assets/7d423b9c-537d-4ccb-9db0-7765aa10a39d
It doesn't look like a big delay but it feels laggy when you click it yourself.
I investigate that and it looks like this doesn't happen on the main only by coincidence. I figured out a solution for that and tomorrow I will work on PR that we could merge to the main. It should help with the initial render of heavy screens in general and improve the user experience.
Below you can see the test result
https://github.com/user-attachments/assets/0051a65c-1ffb-448b-a86e-56950f46bd9b
I am fine exploring the animation later
@adamgrzybowski, you should definitely test with a high-traffic account at least; you could even try the heavy performance testing account we provided to SWM. Testing with a fresh account is not representative of the users we care about the most.
FYI: I played around with a solution I found yesterday regarding performance, and it may need more work and investigation. For now, I'll focus on other work left for this PR and get back to perf closer to review.
:test_tube::test_tube: Use the links below to test this adhoc build on Android, iOS, Desktop, and Web. Happy testing! :test_tube::test_tube:
| Android :robot: | iOS :apple: |
|---|---|
| https://ad-hoc-expensify-cash.s3.amazonaws.com/android/49539/index.html | https://ad-hoc-expensify-cash.s3.amazonaws.com/ios/49539/index.html |
| Desktop :computer: | Web :spider_web: |
| https://ad-hoc-expensify-cash.s3.amazonaws.com/desktop/49539/NewExpensify.dmg | https://49539.pr-testing.expensify.com |
:eyes: View the workflow run that generated this build :eyes:
Hey! Here's a little update from me and Adam :)
Tasks we have accomplished recently:
- new simplified
Navigation.goBackhas been merged to our feature branch, now we are focused on comparing whether it works the same way as on the main branch and fixing bugs - we started working on cleaning up the code to fix checks in our PR
- Tests section has been added to the
NAVIGATION.md. It's still in progress but first tests are ready to check. We are working on preparing further tests, but we also believe that bugs reported in this PR can be a source of knowledge for us, so feel free to test and report us what you find :bug: - Adam worked on polishing performance, one of the planned improvements has already been added to the feature branch
- many resolved conflicts 😄
Thanks for the update! I think the performance is the critical part to nail down. Also deeplinks, those are often a can of worms
Let us know when you want us to fire up another test build so we can take it for a spin!
@shawnborton Great timing 😄 we just improved performance and fixed some regressions we found. I think it's time to use your help with testing. 🙇
cc: @mountiny
:test_tube::test_tube: Use the links below to test this adhoc build on Android, iOS, Desktop, and Web. Happy testing! :test_tube::test_tube:
| Android :robot: | iOS :apple: |
|---|---|
| https://ad-hoc-expensify-cash.s3.amazonaws.com/android/49539/index.html | https://ad-hoc-expensify-cash.s3.amazonaws.com/ios/49539/index.html |
| Desktop :computer: | Web :spider_web: |
| https://ad-hoc-expensify-cash.s3.amazonaws.com/desktop/49539/NewExpensify.dmg | https://49539.pr-testing.expensify.com |
:eyes: View the workflow run that generated this build :eyes:
:test_tube::test_tube: Use the links below to test this adhoc build on Android, iOS, Desktop, and Web. Happy testing! :test_tube::test_tube:
| Android :robot: | iOS :apple: |
|---|---|
| https://ad-hoc-expensify-cash.s3.amazonaws.com/android/49539/index.html | ❌ FAILED ❌ |
| The QR code can't be generated, because the iOS build failed | |
| Desktop :computer: | Web :spider_web: |
| https://ad-hoc-expensify-cash.s3.amazonaws.com/desktop/49539/NewExpensify.dmg | https://49539.pr-testing.expensify.com |
:eyes: View the workflow run that generated this build :eyes:
Testing now - one quick thing I noticed: when I am on the Search page, the bottom tab for Search is not getting the "active" state:
I am also seeing a weird behavior where if I go to Settings, then Workspaces, then into a Workspace, then go back to Search, then Inbox, then Search, then when I try to go back to Settings, the bottom tab does not work or navigate me anywhere.
https://github.com/user-attachments/assets/0f5c18a7-d89f-4a6d-84bf-f26ab4d41c6d
:test_tube::test_tube: Use the links below to test this adhoc build on Android, iOS, Desktop, and Web. Happy testing! :test_tube::test_tube:
| Android :robot: | iOS :apple: |
|---|---|
| https://ad-hoc-expensify-cash.s3.amazonaws.com/android/49539/index.html | https://ad-hoc-expensify-cash.s3.amazonaws.com/ios/49539/index.html |
| Desktop :computer: | Web :spider_web: |
| https://ad-hoc-expensify-cash.s3.amazonaws.com/desktop/49539/NewExpensify.dmg | https://49539.pr-testing.expensify.com |
:eyes: View the workflow run that generated this build :eyes:
Hey guys! We fixed problems found by @shawnborton. A few others as well. There is one problem that we are aware of remaining but it is related to <StackView> on android and we would probably need to patch the react-navigation to fix it. I am not sure if it's worth fixing if we switch to native stacks on mobiles soon.
In that case, can we ask testers for help? In the meantime, @WojtekBoman and I will clean the remaining code and prepare a PR to remove the draft label.
cc: @mountiny
BTW this is the bug with StackView. It looks terrible but as I said it won't occur on NativeStack.
https://github.com/user-attachments/assets/45ee6d35-0da8-4097-a28f-c4f63ee66461
I think we are getting close to merging the native stack pr cc @chrispader so hopefully that would be fine.
Making a new test build
:test_tube::test_tube: Use the links below to test this adhoc build on Android, iOS, Desktop, and Web. Happy testing! :test_tube::test_tube:
| Android :robot: | iOS :apple: |
|---|---|
| https://ad-hoc-expensify-cash.s3.amazonaws.com/android/49539/index.html | ❌ FAILED ❌ |
| The QR code can't be generated, because the iOS build failed | |
| Desktop :computer: | Web :spider_web: |
| https://ad-hoc-expensify-cash.s3.amazonaws.com/desktop/49539/NewExpensify.dmg | https://49539.pr-testing.expensify.com |
:eyes: View the workflow run that generated this build :eyes:
Trying it again https://github.com/Expensify/App/actions/runs/11453185400