-
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
[Search v1] Add small followups for sorting in search #42980
[Search v1] Add small followups for sorting in search #42980
Conversation
src/CONST.ts
Outdated
@@ -4779,7 +4779,7 @@ const CONST = { | |||
SEARCH_RESULTS_PAGE_SIZE: 50, | |||
|
|||
SEARCH_DATA_TYPES: { | |||
TRANSACTION: 'transaction', | |||
TRANSACTION: 'transactions', |
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.
Will this be proper name or will we revert back to singular? @luacmartins
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.
Yes, the correct value is transaction
@luacmartins In general the issue of getting new records with bigger/longer values is inevitable. This will happen both when changing sort (as we put sorting params inside So they might pop-in and pop-out based on records. I believe that was your (?) decision to code them like this? We can always change that. As for showing a loader: when doing this issue I decided the UX was bad with constant loading flicker and so I added keeping track of previous results which made the table feel more smooth. rec-web-sortingloader.mp4You will get the flicker every time new data loads. I tried to make tax and cat columns a bit smaller, check here: I will need some more comments from you on how to move forward. |
@Expensify/design I'd love your thoughts on this issue. I'm not really sure how to solve it yet for the reasons @Kicu laid out here. |
Hmm it seems like the columns are not set up the way we have them designed in Figma. In Figma, we just have the columns using a How do you have the column widths working right now? |
@shawnborton you can see the column styles defined here. So we have:
|
Ah, that does seem right. Then why is the bug in the video happening exactly? |
I think because we add/remove columns. In the video, we the |
Got it, I think that one makes the most sense to me. |
This makes the most sense to me too. I don't think we want columns popping in and out of existence based on sort order. |
Yeah I also agree with that, looking as a user of visual interfaces the constant jumping of columns is quite confusing. So how do you wanna return this from backend @luacmartins - a new field in onyx response for Also a temp solution might be to hardcode this in web before June 12th, since we do have capacity in here to deliver something in web quite fast I think. |
We agreed to use policy settings to determine the columns that should be shown, e.g. if the user has a policy with |
@luacmartins Sounds good 👍 So may I suggest we merge this PR? it has a very small fix for undefined It will be easier to create this as a separate PR instead of continually updating this PR |
@Kicu could you also disable sorting on the report views please? e.g. |
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.
We need to disable sorting on the hybrid report views, e.g. Shared
, Drafts
, Finished
@luacmartins Changes done, we now have a list of what is sortable: I also added small code tweaks, but did not change any logic, just moved stuff around. sorting allowedsorting disallowed |
@luacmartins added new commit:
|
Hmm yeah, also I thought those buttons/that column was supposed to have a fixed width around 80px so that all the buttons would end up being the same width, regardless of what action it was? (Even if they're all |
Yup - that's my exact understanding as well. |
Cool, I can fix the action button width in a follow up since that's not specific to this PR. Also, I've noticed that sorting by tax amount is still not implemented in the backend so we need to disable that too. I'll address that in the same follow up though |
Reviewer Checklist
Screenshots/Videosweb.movAndroid: NativeAndroid: mWeb ChromeiOS: NativeiOS: mWeb SafariMacOS: Chrome / SafariMacOS: Desktop |
✋ 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 production by https://github.com/luacmartins in version: 1.4.81-11 🚀
|
Details
from
orto
insidetransactionItem
Fixed Issues
$ #42856
PROPOSAL:
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
Android: mWeb Chrome
iOS: Native
iOS: mWeb Safari
MacOS: Chrome / Safari
MacOS: Desktop