-
Notifications
You must be signed in to change notification settings - Fork 8.3k
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
[ML] Standardize Add embeddable flow from the Anomaly Explorer page #123199
[ML] Standardize Add embeddable flow from the Anomaly Explorer page #123199
Conversation
Pinging @elastic/ml-ui (:ml) |
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.
Tested and LGTM
description: i18n.translate('xpack.ml.explorer.dashboardsTable.editActionName', { | ||
defaultMessage: 'Add to dashboard', | ||
}), | ||
icon: 'documentEdit', |
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.
This icon implies more of an 'edit' action to me than 'add', but can't find anything better! You are redirected to Dashboard to allow more 'editing', so maybe it's ok?
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.
listAdd
icon (take a look in https://elastic.github.io/eui/#/display/icons) might also work 🤔
💚 Build Succeeded
Metrics [docs]Async chunks
Page load bundle
History
To update your PR or re-run it, just comment with: cc @darnautov |
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.
Tested this locally on chrome, everything works as expected! The user is redirected to the dashboard, and the swimlane embeddable works as expected.
I also looked through the diff, and it's great to see the last usage of the URL generator getting removed, very exciting!
I am approving, but I think there are many UX improvements to be made in the future to better align this with how other Kibana apps add their embeddables to a dashboard.
- Redirecting to a dashboard is a pretty major action, so using such a small action button per-row seems jarring from a UX POV. Additionally, there is no description stating that you will be redirected.
- There is no way to add the swimlane embeddable directly to a new dashboard
- The inline dashboard selection table causes layout shifting in the modal depending on how many dashboards are available.
If we eventually re-think the UX of this window, we should look at the way Visualize / Lens accomplishes this:
We would need to remove the None / add to Library
radio buttons, but the rest of the UI could be retained.
Thanks for the review @ThomThomson! Agree, we need to rethink the UX here because originally it was possible to change multiple dashboards at once. Visualize / Lens approach seems sensible! Merged it to remove the blocker, but we'll get back to it. |
Amazing, thanks again for doing this! |
Summary
Standardizes the workflow for adding an embeddable swim lane or anomaly charts from the Anomaly Explorer to Dashboard so that it is aligned with that used in other places in Kibana. Users are now always redirected to Dashboard app after adding the embeddable so that they can modify and save their changes inside Dashboard.
Resolves #122300 and #122271
Updates the user flow of adding ML embeddables to dashboards from the Anomaly Explorer page by utilizing the embeddable transfer state service. Due to the lack of alternative solutions, we used to manipulate dashboards saved objects directly. Now the user is redirected to the dashboard in edit mode and should save changes explicitly.
Important differences with the previous version:
Checklist