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

[dashboard builder] sticky tabs, container hierarchy, undo-redo fixes #1

Conversation

williaster
Copy link

This PR adds the following to the new dashboard builder feature branch:

  • adds support for sticky top-level tab (using react-sticky)
  • improves dashboard tab performance in two significant ways:
    • refactors the DashboardBuilder React component tree to always include tabs regardless of whether top-level tabs exist. this makes adding/removing top-level tabs significantly more performant because we don't unmount/mount the entire dashboard which would otherwise happen because of the React diff-ing algorithm.
    • improves performance of switching between any set of tabs by setting the react-bootstrap mountOnEnter=true and unmountOnExit=false. note this allows us to lazy load visualizations in tabs because queries trigger on mount
  • improves the logic for undo/redo affecting the "popped" state of the "save dashboard" button (if you perform actions we enable you to save changes. if you then undo all the way you can no longer save changes, unless you have exceeded the undo history limit)
  • moves dashboard title + chart title edits into the dashboardLayout part of the redux state tree, which is necessary to correctly affect and leverage undo/redo functionality.
    • note that previously chart titles were saved immediately upon edit; I removed the functionality to update the title of a single chart, and instead moved this logic to the python _set_dash_metadata method, which will update slices in the slice table if their name changed
    • I verified that slice names update upon save, including when you clone a dashboard and when you clone slices.
  • improves the visual hierarchy of all container components to more clearly distinguish between nested containers
  • I moved the layout "versioning" into the top-level of dashboardLayout instead of within the layout objects themselves (@graceguo-supercat , this may break your local build because getInitialState looks for this version key in order to determine if it should convert the layout, you could add a line of JS to update it to v2 => save the dashboard, and then remove the JS)

fixed-tabs-demo

@graceguo-supercat

@graceguo-supercat graceguo-supercat force-pushed the gg-dash-builder-header branch 3 times, most recently from c2d6b07 to d4363b9 Compare May 5, 2018 00:00
@williaster williaster force-pushed the chris--fixed-tabs branch from 0f685b2 to ef081ce Compare May 5, 2018 00:30
@graceguo-supercat graceguo-supercat force-pushed the gg-dash-builder-header branch from d4363b9 to 2717baf Compare May 5, 2018 04:58
@williaster williaster force-pushed the chris--fixed-tabs branch from 551e42c to 5c55dfe Compare May 7, 2018 19:18
@williaster
Copy link
Author

@graceguo-supercat I think this is ready to merge, I rebased on your latest and both sticky side pane + tabs works 👍

@graceguo-supercat graceguo-supercat merged commit 4018398 into graceguo-supercat:gg-dash-builder-header May 7, 2018
graceguo-supercat pushed a commit that referenced this pull request Nov 23, 2019
* First cut at app factory

* Setting things back to master

* Working with new FLASK_APP

* Still need to refactor Celery

* CLI mostly working

* Working on unit tests

* Moving cli stuff around a bit

* Removing get in config

* Defaulting test config

* Adding flask-testing

* flask-testing casing

* resultsbackend property bug

* Fixing up cli

* Quick fix for KV api

* Working on save slice

* Fixed core_tests

* Fixed utils_tests

* Most tests working - still need to dig into remaining app_context issue in tests

* All tests passing locally - need to update code comments

* Fixing dashboard tests again

* Blacking

* Sorting imports

* linting

* removing envvar mangling

* blacking

* Fixing unit tests

* isorting

* licensing

* fixing mysql tests

* fixing cypress?

* fixing .flaskenv

* fixing test app_ctx

* fixing cypress

* moving manifest processor around

* moving results backend manager around

* Cleaning up __init__ a bit more

* Addressing PR comments

* Addressing PR comments

* Blacking

* Fixes for running celery worker

* Tuning isort

* Blacking
graceguo-supercat pushed a commit that referenced this pull request Nov 23, 2019
* Sweep #1

* moving a few more colors, fixing an import issue.

* another include, another color nabbed.

* more whittling.

* moving filterbox css to less, standardizing colors in there.

* nixing the css file I meant to nab in the last commit

* Moving the variables file to a more global/sensible (I hope?) location.

* FilterableTable moved from CSS to LESS, using color vars now.

* more whittling

* standardizing opacity stops

* nails more colors, removes some old (seemingly unused) css

* removing more dead css

* DatasourceControl moved from CSS to LESS

* BootstrapSliderWrapper CSS -> LESS

* reactable-pagination CSS->LESS, color-conformed

* FilterBadgeIcon CSS->LESS, conformed

* deleting unused/deprecated css

* welcome.css -> welcome.less (is this even being used?)

* main.css -> main.less, standardized

* there were two main.css files - this should have been in the last commit.

* explore.css -> explore.less (not used anywhere?)

* sql.css -> sql.less (also not used anywhere?)

* another main.css -> main.less, standardized on colors

* time to add shades and tints!

* caught some colors in SVG that should be in LESS.

* nixing commented css

* deleting commented code

* pulling in z-index vars lost in a conflict resolution
graceguo-supercat pushed a commit that referenced this pull request Oct 4, 2021
[SIP-4] add lerna monorepo and`@superset-ui/core` package with `SupersetClient`
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