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

[Time to Visualize] Stay in Edit Mode After Dashboard Quicksave #91729

Merged

Conversation

ThomThomson
Copy link
Contributor

@ThomThomson ThomThomson commented Feb 17, 2021

Summary

Changes the dashboard quicksave function to keep the user in edit mode instead of booting them out.

This also necessitated a loading state on the quick save button, and the disabling of the other buttons on the top nav while the dashboard is being saved.

Quicksave

Additionally, the Cancel button has been renamed to Return to better reflect its new usage to return to view mode after saving the dashboard. The confirm modal when the user has active changes has also been changed.

Screen Shot 2021-02-17 at 3 52 41 PM

Checklist

Delete any items that are not applicable to this PR.

For maintainers

@ThomThomson ThomThomson force-pushed the feature/quickSaveStayInEditMode branch from 9e71818 to 0ac10bc Compare February 17, 2021 20:34
@ThomThomson ThomThomson marked this pull request as ready for review February 17, 2021 22:54
@ThomThomson ThomThomson requested review from a team as code owners February 17, 2021 22:54
Copy link
Member

@tsullivan tsullivan left a comment

Choose a reason for hiding this comment

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

LGTM

Copy link
Contributor

@cqliu1 cqliu1 left a comment

Choose a reason for hiding this comment

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

LGTM 👍 I tested it out locally and staying in edit mode after quick saving makes a lot of sense. I've just got a couple pieces of feedback.

Screen Shot 2021-02-18 at 9 23 43 AM

Can we set initialFocus on this return modal to one of the buttons? Maybe Cancel or Keep changes?

It also might be nice to disable the Save button when there aren't any unsaved changes.

@ThomThomson
Copy link
Contributor Author

@elasticmachine merge upstream

@ThomThomson
Copy link
Contributor Author

I was able to disable the quickSave button when there are no active changes, good call!

I have been working on adding an initialFocus prop to the overlays.openModal service, but it EuiModal isn't able to find the element properly. My best guess is that the mount point is somehow causing the contents of the modal to not be loaded by the time the EuiModal searches for the initialFocus element. I have reached out to the core team to discuss this.

There are a number of places where this is used, that could do with an initialFocus setting, so I may create a followup for this feature.

@ThomThomson
Copy link
Contributor Author

@elasticmachine merge upstream

@kibanamachine
Copy link
Contributor

💚 Build Succeeded

Metrics [docs]

Async chunks

Total size of all lazy-loaded chunks that will be downloaded as the user navigates the app

id before after diff
dashboard 181.3KB 182.0KB +726.0B

Page load bundle

Size of the bundles that are downloaded on every page load. Target size is below 100kb

id before after diff
dashboard 309.0KB 309.9KB +924.0B
navigation 20.3KB 20.4KB +26.0B
total +950.0B

History

To update your PR or re-run it, just comment with:
@elasticmachine merge upstream

@ThomThomson ThomThomson merged commit 85bc8b0 into elastic:master Feb 19, 2021
ThomThomson added a commit to ThomThomson/kibana that referenced this pull request Feb 19, 2021
ThomThomson added a commit to ThomThomson/kibana that referenced this pull request Feb 19, 2021
ThomThomson added a commit that referenced this pull request Feb 19, 2021
ThomThomson added a commit that referenced this pull request Feb 19, 2021
jloleysens added a commit to jloleysens/kibana that referenced this pull request Feb 22, 2021
…ndition-for-hiding-recommded-allocation

* 'master' of github.com:elastic/kibana: (117 commits)
  [coverage] ingest data in parallel (elastic#92074)
  [Lens] Drag and drop performance improvements (elastic#91641)
  A few more environment uiFilters fixes (elastic#92044)
  Enabling Uptime and Dashboard a11y test (elastic#91017)
  [Security Solution][Detections] Adds more granular validation for nested fields (elastic#92041)
  [Security Solution] [Detections] add overflow-wrap for description (elastic#91945)
  [Security Solution] [Detections] do not truncate filename in value list table in modal (elastic#91952)
  Skip flaky apm test elastic#91673 (elastic#92065)
  [docker] Default server.name to hostname (elastic#90799)
  Use documentation link service for snapshot restore (elastic#91596)
  [Security Solution] Clearing up all jest errors and warnings (elastic#91740)
  Add `@kbn/analytics` to UI Shared Deps (elastic#91810)
  [7.12][Telemetry] Add missing fields for security telemetry (elastic#91920)
  [Security Solution] Adds cypress-pipe (elastic#91550)
  [ML] Fix event rate chart annotation position (elastic#91899)
  [APM] Break down error table api removing the sparklines (elastic#89138)
  docs: update dependencies table bug (elastic#91964)
  [Time to Visualize] Stay in Edit Mode After Dashboard Quicksave (elastic#91729)
  Unskip Search Sessions Management UI test (elastic#90110)
  [Fleet] Handle long text in agent details page (elastic#91776)
  ...

# Conflicts:
#	x-pack/plugins/index_lifecycle_management/__jest__/client_integration/edit_policy/edit_policy.helpers.tsx
#	x-pack/plugins/index_lifecycle_management/__jest__/components/edit_policy.test.tsx
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants