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

feat: embedded superset dashboards #3205

Open
wants to merge 47 commits into
base: master
Choose a base branch
from

Conversation

HendrikThePendric
Copy link
Contributor

@HendrikThePendric HendrikThePendric commented Feb 4, 2025

TODO list based on KFMT session

(remove this section once completed)

  • Documentation added
  • Fix: The warning text in the delete dialog accepts focus which should not be possible
  • Fix: the delete button in the delete dialog should auto-focus
  • Fix: modal should get scrolling content in case of limited screen height.
  • Fix: Stop disabling the “save” button in the create/update modal and run validation before taking action, so that the user gets better feedback of when the UUID is not valid.
  • Show improved error messages and prevent flashing of embedded superset error page where possible. To do this we will request a guest token once before we embed the dashboard and if this fails we do not attempt to embed the dashboard but show an error notification instead. This task is currently blocked. The superset-gateway/api/guestTokens endpoint should start returning HTTP errors and error codes first.
  • In the sharing dialog we should prevent the second tab to show, since it is not possible to apply sharing settings to embedded dashboard items.
  • [STATUS: ✅ DONE] Change "External data" to "External source"
  • [STATUS: ✅ DONE] Change "Embed a dashboard from a third-party source, like Superset." to "Embed a superset dashboard"
  • [STATUS: ⛔ NOT POSSIBLE] Attempt to fix fullscreen option of individual embedded items by adjusting sandboxing properties
  • [STATUS: ⛔ NOT POSSIBLE] Attempt to fix "share by email" option of embedded item by adjusting sandboxing properties

Implements DHIS2-17891

References


Key features

  1. When the app loads it checks if the backend supports Superset embedded dashboards and enables them if this is the case
  2. When creating a new dashboard, the user can choose to create an internal or external dashboard
  3. Title, Code, Description and Superset Embed ID can be provided when creating/editing a Superset Embedded dashboard, as well as the options to "Show chart controls on dashboard items" and/or "Expand filters" in the emedded dashboard (using the Superset Embed SDK)
  4. Embedded Superset dashboards can be starred, shared, and the description can be displayed/hidden, just like internal dashboards
  5. They cannot, however, be filtered, taken offline, go into slideshow mode, or be printed. So these menu items are disabled

Partial PRs

Several PRs have been merged into this main feature PR. Please review PR descriptions and commit messages for a more granular view on the changes:


Note for testers

Since this feature is only available for instances which have Superset included, you will need to use such an instance when testing, i.e. https://debug.dhis2.org/dev. To test the dashboard-app, you can either use the Netlify link or run the app locally.


Screenshots

Choosing a dashboard type
Screenshot 2025-02-10 at 12 47 49

Configuring a Superset embedded dashboard
Screenshot 2025-02-10 at 12 48 26

Viewing a Superset embedded dashboard
Screenshot 2025-02-10 at 12 49 00

@dhis2-bot
Copy link
Contributor

dhis2-bot commented Feb 4, 2025

🚀 Deployed on https://pr-3205.dashboard.netlify.dhis2.org

@dhis2-bot dhis2-bot temporarily deployed to netlify February 4, 2025 09:41 Inactive
@HendrikThePendric HendrikThePendric force-pushed the feat/embedded-superset-dashboards-DHIS2-17891 branch from 47e9b85 to a1c84ee Compare February 4, 2025 13:36
@HendrikThePendric HendrikThePendric changed the title Feat/embedded superset dashboards dhis2 17891 feat: embedded superset dashboards Feb 4, 2025
@dhis2-bot dhis2-bot temporarily deployed to netlify February 4, 2025 13:38 Inactive
@dhis2-bot dhis2-bot temporarily deployed to netlify February 6, 2025 12:51 Inactive
@HendrikThePendric HendrikThePendric force-pushed the feat/embedded-superset-dashboards-DHIS2-17891 branch from 9cbe2e3 to 86a2794 Compare February 10, 2025 10:54
@dhis2-bot dhis2-bot temporarily deployed to netlify February 10, 2025 11:04 Inactive
@dhis2-bot dhis2-bot temporarily deployed to netlify February 10, 2025 11:12 Inactive
@HendrikThePendric HendrikThePendric marked this pull request as ready for review February 10, 2025 11:51
@HendrikThePendric HendrikThePendric force-pushed the feat/embedded-superset-dashboards-DHIS2-17891 branch from 0f2b16b to 92bbefe Compare February 10, 2025 14:29
@dhis2-bot dhis2-bot temporarily deployed to netlify February 10, 2025 14:31 Inactive
@dhis2-bot dhis2-bot temporarily deployed to netlify February 11, 2025 15:12 Inactive
@dhis2-bot dhis2-bot temporarily deployed to netlify February 11, 2025 15:15 Inactive
@dhis2-bot dhis2-bot temporarily deployed to netlify February 11, 2025 15:59 Inactive
@jenniferarnesen jenniferarnesen added the e2e record Apply this label to a pull request to trigger recording of E2E tests on Cypress Cloud label Feb 12, 2025
Never use Superset and Embedded together, so that names are shorter and
all superset dashboards are embedded so the embedded part is redundant
anyway

Move and rename the superset dashboard  create/edit  components
@HendrikThePendric HendrikThePendric force-pushed the feat/embedded-superset-dashboards-DHIS2-17891 branch from 0e93af7 to 4946b6a Compare March 11, 2025 16:43
Copy link

@dhis2-bot dhis2-bot temporarily deployed to netlify March 11, 2025 16:44 Inactive
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.

4 participants