-
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
Allow replacing visualizations on dashboard #45095
Conversation
Since this is a community submitted pull request, a Jenkins build has not been kicked off automatically. Can an Elastic organization member please verify the contents of this patch and then kick off a build manually? |
1 similar comment
Since this is a community submitted pull request, a Jenkins build has not been kicked off automatically. Can an Elastic organization member please verify the contents of this patch and then kick off a build manually? |
Pinging @elastic/kibana-app |
jenkins test this |
💔 Build Failed |
@TinaHeiligers : can you please run the build again? |
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.
LGTM from the design side. A Kibana engineer will need to complete a code review / approval before merging.
This is a really nice addition, simple and very intuitive. The interaction does exactly what I would expect - clicking the action link opens the flyout, allowing me to choose as a new viz. Thanks for the PR!
@stacey-gammon Since the embeddable layer is still rather new, could we perhaps bother you for a review here? |
Jenkins, test this |
This is awesome! You might have to update some things after #44707 is merged, hopefully today. I am out tomorrow and Friday and I'm not sure I'll be able to finish the review today but if not I'll get back around to it early next week. |
💔 Build Failed |
@stacey-gammon : the type_check script fails for this error: ERROR x-pack failed But the error is not in files I've touched. The same line of code is also on master: Edit: this was before the merge of #44707. |
Jenkins, test this |
💔 Build Failed |
@timroes : error is not in my code, is it? |
@friol , it's probably that something in jest is now importing that file that wasn't before. Those imports don't work in jenkins unfortunately so the recommendation is still relative file paths (discussed here: #40446). We eventually we want to move to support these short file imports, and they are still scattered about the code because they don't always cause failures. Short term fix is to just switch to a relative file path import. |
@stacey-gammon : ok, so, exactly, what should I do? |
@stacey-gammon : I renamed the menu item to "Replace panel". To be honest, one would have to change all the file names and all the object names to "change_panel_something"... but I hope you won't need that :) |
@friol Thanks for jumping on this so quickly I thought of this feature just a few months ago! I updated the naming to I couldn't find any issue with the test you pointed out, tbd if the ci passes 🤞. I also added some functional tests to your PR. Please let me know if you have any comments witht the changes and feel free to make any changes you'd like. |
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.
Code LGTM, Thanks for this enhancement! I Love it!
💔 Build Failed |
@nickofthyme : simply great! You had the patience to rename all the objects to "replacePanel*" :) |
💔 Build Failed |
@elasticmachine merge upstream |
retest |
💚 Build Succeeded |
@nickofthyme : tell me we can finally merge this one! It's 1 month and 15 days old :) |
@friol Done! Thanks again for all the help! |
@nickofthyme : there is another PR from me, dated 28 august, that got "lost" -> #35379 . |
* First version of change view functionality * Adds the 'replace view' functionality to dashboard edit mode * Fixed type_check errors * Make action part of dashboard_embeddable_container * Fixed import paths for type check errors * Fixed i18n errors * Renamed action to 'Replace panel' and adjusted jest tests to pass type check * test: add functional tests Closes elastic#43900
…9173) * First version of change view functionality * Adds the 'replace view' functionality to dashboard edit mode * Fixed type_check errors * Make action part of dashboard_embeddable_container * Fixed import paths for type check errors * Fixed i18n errors * Renamed action to 'Replace panel' and adjusted jest tests to pass type check * test: add functional tests Closes #43900
💚 Build Succeeded |
@nickofthyme : thanks! |
Summary
As asked in Issue #43900, this PR adds the "Replace visualization" function to the Edit Menu when a Dashboard is in edit mode. The new visualization is chosen from a flyout, and replaces the old one with the same position and dimensions.