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

fix: adds pagination/infinite scroll to owners select on DashboardList and ChartList #10035

Merged
merged 4 commits into from Jun 17, 2020

Conversation

nytai
Copy link
Member

@nytai nytai commented Jun 10, 2020

SUMMARY

followup from #9989

This PR adds infinite scroll via react-select-async-paginate (same author as react-select).

TEST PLAN

  • manually tested.

ADDITIONAL INFORMATION

  • Has associated issue:
  • Changes UI
  • Requires DB Migration.
  • Confirm DB Migration upgrade and downgrade tested.
  • Introduces new feature or API
  • Removes existing feature or API

@nytai nytai changed the title Tai/async paginate react select fix: adds pagination/infinite scroll to owners select on DashboardList and ChartList Jun 10, 2020
@codecov-commenter
Copy link

codecov-commenter commented Jun 10, 2020

Codecov Report

Merging #10035 into master will decrease coverage by 1.60%.
The diff coverage is 41.66%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master   #10035      +/-   ##
==========================================
- Coverage   70.47%   68.86%   -1.61%     
==========================================
  Files         583      584       +1     
  Lines       31019    31061      +42     
  Branches     3175     3182       +7     
==========================================
- Hits        21861    21391     -470     
- Misses       9049     9561     +512     
  Partials      109      109              
Flag Coverage Δ
#cypress 53.92% <100.00%> (+<0.01%) ⬆️
#javascript 59.41% <41.66%> (+<0.01%) ⬆️
#python 67.33% <ø> (-2.74%) ⬇️
Impacted Files Coverage Δ
...rset-frontend/src/components/ListView/ListView.tsx 98.03% <ø> (ø)
...uperset-frontend/src/views/chartList/ChartList.tsx 61.22% <ø> (ø)
...frontend/src/views/dashboardList/DashboardList.tsx 66.66% <ø> (ø)
...erset-frontend/src/components/ListView/Filters.tsx 72.30% <30.00%> (-16.03%) ⬇️
...end/src/components/Select/SupersetStyledSelect.tsx 91.01% <100.00%> (+0.20%) ⬆️
superset/connectors/druid/models.py 28.16% <0.00%> (-54.28%) ⬇️
superset/connectors/base/models.py 86.42% <0.00%> (-2.51%) ⬇️
superset/views/datasource.py 91.80% <0.00%> (-1.64%) ⬇️
superset/views/core.py 75.39% <0.00%> (-0.89%) ⬇️
...rc/explore/components/controls/AnnotationLayer.jsx 51.17% <0.00%> (-0.49%) ⬇️
... and 14 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 e17da58...98819e1. Read the comment docs.

@@ -347,10 +348,6 @@ describe('ListView with new UI filters', () => {
expect(wrapper.find(ListViewFilters)).toHaveLength(1);
});

it('fetched selects if function is provided', () => {
Copy link
Member Author

Choose a reason for hiding this comment

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

fetching now happens on select open/click. This is really hard to simulate via enzyme.

@nytai nytai requested review from ktmud and mistercrunch June 10, 2020 23:20
@nytai nytai marked this pull request as ready for review June 10, 2020 23:21
@@ -198,7 +198,7 @@ const ListView: FunctionComponent<Props> = ({
{bulkActions.map(action => (
// @ts-ignore
<MenuItem
key={action.key}
key={action.key || action.name}
Copy link
Member

Choose a reason for hiding this comment

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

when will an action not have a key?

Copy link
Member Author

Choose a reason for hiding this comment

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

I added this after getting a react error in tests. I've updated the BulkAction type and made key a required field. Also fixed the test

@nytai nytai force-pushed the tai/async-paginate-react-select branch from 98819e1 to d65341f Compare June 17, 2020 20:57
@nytai nytai merged commit c914af0 into apache:master Jun 17, 2020
@nytai nytai deleted the tai/async-paginate-react-select branch June 17, 2020 23:27
auxten pushed a commit to auxten/incubator-superset that referenced this pull request Nov 20, 2020
@mistercrunch mistercrunch added 🏷️ bot A label used by `supersetbot` to keep track of which PR where auto-tagged with release labels 🚢 0.37.0 labels Mar 12, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
🏷️ bot A label used by `supersetbot` to keep track of which PR where auto-tagged with release labels size/M 🚢 0.37.0
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

5 participants