Skip to content
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

Listing: load more #2150

Merged
merged 7 commits into from
Apr 6, 2021
Merged

Listing: load more #2150

merged 7 commits into from
Apr 6, 2021

Conversation

nl0
Copy link
Member

@nl0 nl0 commented Apr 5, 2021

Description

There's two ways to load more results: "load more" button in header / footer and second "..." button (displayed after the last page in pagination)
Screenshot 2021-04-05 at 22 25 03

TODO

  • Unit tests
  • Automated tests (e.g. Preflight)
  • Documentation
    • Python: Run build.py for new docstrings
    • JavaScript: basic explanation and screenshot of new features
  • Changelog entry

@nl0 nl0 requested a review from fiskus April 5, 2021 17:27
@codecov
Copy link

codecov bot commented Apr 5, 2021

Codecov Report

Merging #2150 (f53d27e) into master (bd54f67) will decrease coverage by 0.10%.
The diff coverage is 18.34%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master    #2150      +/-   ##
==========================================
- Coverage   46.41%   46.30%   -0.11%     
==========================================
  Files         431      434       +3     
  Lines       20557    20618      +61     
  Branches     2410     2431      +21     
==========================================
+ Hits         9542     9548       +6     
- Misses      10100    10161      +61     
+ Partials      915      909       -6     
Flag Coverage Δ
api-python 89.78% <ø> (ø)
catalog 16.17% <18.34%> (-0.04%) ⬇️
lambda 93.03% <ø> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.

Impacted Files Coverage Δ
catalog/app/containers/Bucket/Dir.tsx 0.00% <0.00%> (ø)
catalog/app/containers/Bucket/Listing.tsx 0.00% <0.00%> (ø)
...og/app/containers/Bucket/requests/bucketListing.ts 16.00% <16.00%> (ø)
catalog/app/utils/AsyncResult.js 63.63% <33.33%> (-11.37%) ⬇️
catalog/app/containers/Bucket/errors.tsx 47.12% <53.84%> (ø)
catalog/app/containers/Bucket/requests/index.ts 100.00% <100.00%> (ø)
.../app/containers/Bucket/requests/requestsUntyped.js 17.84% <100.00%> (ø)
catalog/app/containers/Bucket/requests/utils.ts 100.00% <100.00%> (ø)
catalog/app/utils/error.ts 100.00% <100.00%> (ø)
... and 2 more

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update bd54f67...f53d27e. Read the comment docs.

Copy link
Member

@fiskus fiskus left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The layout doesn't fit into viewport on mobile and on iPad landscape mode


I think that "Load more" is not quite an appropriate action for the user. The user wants to see more results, sort or filter on a bigger chunk of results. Loading more — is our internal workaround. As a user, I just don't understand what's going to happen on "Load more" click, what is going to load and where. I spotted that number of results and page number incremented after results loading.

Possible enhancement 1. Tell the user what is going with helper tooltips. We can explain that we can't load everything and need to work with a slice of data. The size of this slice can be increased by user action.
Possible enhancement 2. Instead of clicking "Load more" button user can input the exact number of results he wants (we can use input + dropdown).

catalog/app/containers/Bucket/Dir.tsx Show resolved Hide resolved
catalog/app/containers/Bucket/errors.tsx Show resolved Hide resolved
catalog/app/containers/Bucket/errors.tsx Show resolved Hide resolved
@nl0
Copy link
Member Author

nl0 commented Apr 6, 2021

I think that "Load more" is not quite an appropriate action for the user. The user wants to see more results, sort or filter on a bigger chunk of results. Loading more — is our internal workaround. As a user, I just don't understand what's going to happen on "Load more" click, what is going to load and where. I spotted that number of results and page number incremented after results loading.

yep, true

Possible enhancement 1. Tell the user what is going with helper tooltips. We can explain that we can't load everything and need to work with a slice of data. The size of this slice can be increased by user action.

seems like a good idea (and easily implementable)

Possible enhancement 2. Instead of clicking "Load more" button user can input the exact number of results he wants (we can use input + dropdown).

this seems confusing, i dont quite get the ux you try to describe, and also it may be a little harder to implement

the proper solution in the long term (as i see it) would be to do all this fetching / slicing / filtering / sorting on the backend and only send to the front-end the data it needs to render the UI -- in-stack requests are very fast and cheap, and there's not that much data to use up too much ram (say, it should handle 100k keys without any problems)

@nl0
Copy link
Member Author

nl0 commented Apr 6, 2021

The layout doesn't fit into viewport on mobile and on iPad landscape mode

it does now (by wrapping lines) -- i wouldnt say it's beautiful, but seems usable
Screenshot 2021-04-06 at 14 32 39

@nl0 nl0 force-pushed the listing-adjustments-load-more branch from 8378ea1 to 03fef32 Compare April 6, 2021 09:40
@nl0 nl0 merged commit 75cbb6b into master Apr 6, 2021
@nl0 nl0 deleted the listing-adjustments-load-more branch April 6, 2021 09:51
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants