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] fix map center change shows unsaved change after clicking reset #213445

Merged
merged 4 commits into from
Mar 7, 2025

Conversation

nreese
Copy link
Contributor

@nreese nreese commented Mar 6, 2025

Closes #213444

The problem is setting the view with the globe view may not set the view to the exact value. For example setting zoom to 1.74 may move the map to zoom 1.77. PR resolves this problem by adding a margin of error for comparing zoom differences.

@nreese nreese marked this pull request as ready for review March 6, 2025 21:58
@nreese nreese requested a review from a team as a code owner March 6, 2025 21:58
@nreese nreese added Team:Presentation Presentation Team for Dashboard, Input Controls, and Canvas release_note:skip Skip the PR/issue when compiling release notes Feature:Maps backport:version Backport to applied version labels v9.1.0 v8.19.0 labels Mar 6, 2025
@elasticmachine
Copy link
Contributor

Pinging @elastic/kibana-presentation (Team:Presentation)

@nreese
Copy link
Contributor Author

nreese commented Mar 6, 2025

/ci

@nreese
Copy link
Contributor Author

nreese commented Mar 7, 2025

@elasticmachine merge upstream

@elasticmachine
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
maps 3.0MB 3.0MB +72.0B

History

@nreese nreese merged commit ea266bc into elastic:main Mar 7, 2025
9 checks passed
@kibanamachine
Copy link
Contributor

Starting backport for target branches: 8.x

https://github.com/elastic/kibana/actions/runs/13723616474

kibanamachine pushed a commit to kibanamachine/kibana that referenced this pull request Mar 7, 2025
… reset (elastic#213445)

Closes elastic#213444

The problem is setting the view with the globe view may not set the view
to the exact value. For example setting zoom to 1.74 may move the map to
zoom 1.77. PR resolves this problem by adding a margin of error for
comparing zoom differences.

---------

Co-authored-by: kibanamachine <42973632+kibanamachine@users.noreply.github.com>
Co-authored-by: Elastic Machine <elasticmachine@users.noreply.github.com>
(cherry picked from commit ea266bc)
@kibanamachine
Copy link
Contributor

💚 All backports created successfully

Status Branch Result
8.x

Note: Successful backport PRs will be merged automatically after passing CI.

Questions ?

Please refer to the Backport tool documentation

kibanamachine added a commit that referenced this pull request Mar 7, 2025
…icking reset (#213445) (#213585)

# Backport

This will backport the following commits from `main` to `8.x`:
- [[dashboard] fix map center change shows unsaved change after clicking
reset (#213445)](#213445)

<!--- Backport version: 9.6.6 -->

### Questions ?
Please refer to the [Backport tool
documentation](https://github.com/sorenlouv/backport)

<!--BACKPORT [{"author":{"name":"Nathan
Reese","email":"reese.nathan@elastic.co"},"sourceCommit":{"committedDate":"2025-03-07T15:15:21Z","message":"[dashboard]
fix map center change shows unsaved change after clicking reset
(#213445)\n\nCloses
https://github.com/elastic/kibana/issues/213444\n\nThe problem is
setting the view with the globe view may not set the view\nto the exact
value. For example setting zoom to 1.74 may move the map to\nzoom 1.77.
PR resolves this problem by adding a margin of error for\ncomparing zoom
differences.\n\n---------\n\nCo-authored-by: kibanamachine
<42973632+kibanamachine@users.noreply.github.com>\nCo-authored-by:
Elastic Machine
<elasticmachine@users.noreply.github.com>","sha":"ea266bcd7e90cca036a82165a8c91ea81bc02c0e","branchLabelMapping":{"^v9.1.0$":"main","^v8.19.0$":"8.x","^v(\\d+).(\\d+).\\d+$":"$1.$2"}},"sourcePullRequest":{"labels":["Team:Presentation","release_note:skip","Feature:Maps","backport:version","v9.1.0","v8.19.0"],"title":"[dashboard]
fix map center change shows unsaved change after clicking
reset","number":213445,"url":"https://github.com/elastic/kibana/pull/213445","mergeCommit":{"message":"[dashboard]
fix map center change shows unsaved change after clicking reset
(#213445)\n\nCloses
https://github.com/elastic/kibana/issues/213444\n\nThe problem is
setting the view with the globe view may not set the view\nto the exact
value. For example setting zoom to 1.74 may move the map to\nzoom 1.77.
PR resolves this problem by adding a margin of error for\ncomparing zoom
differences.\n\n---------\n\nCo-authored-by: kibanamachine
<42973632+kibanamachine@users.noreply.github.com>\nCo-authored-by:
Elastic Machine
<elasticmachine@users.noreply.github.com>","sha":"ea266bcd7e90cca036a82165a8c91ea81bc02c0e"}},"sourceBranch":"main","suggestedTargetBranches":["8.x"],"targetPullRequestStates":[{"branch":"main","label":"v9.1.0","branchLabelMappingKey":"^v9.1.0$","isSourceBranch":true,"state":"MERGED","url":"https://github.com/elastic/kibana/pull/213445","number":213445,"mergeCommit":{"message":"[dashboard]
fix map center change shows unsaved change after clicking reset
(#213445)\n\nCloses
https://github.com/elastic/kibana/issues/213444\n\nThe problem is
setting the view with the globe view may not set the view\nto the exact
value. For example setting zoom to 1.74 may move the map to\nzoom 1.77.
PR resolves this problem by adding a margin of error for\ncomparing zoom
differences.\n\n---------\n\nCo-authored-by: kibanamachine
<42973632+kibanamachine@users.noreply.github.com>\nCo-authored-by:
Elastic Machine
<elasticmachine@users.noreply.github.com>","sha":"ea266bcd7e90cca036a82165a8c91ea81bc02c0e"}},{"branch":"8.x","label":"v8.19.0","branchLabelMappingKey":"^v8.19.0$","isSourceBranch":false,"state":"NOT_CREATED"}]}]
BACKPORT-->

Co-authored-by: Nathan Reese <reese.nathan@elastic.co>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
backport:version Backport to applied version labels Feature:Maps release_note:skip Skip the PR/issue when compiling release notes Team:Presentation Presentation Team for Dashboard, Input Controls, and Canvas v8.19.0 v9.1.0
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[dashboard] map center change shows unsaved change after clicking reset
4 participants