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

[Lens][Heatmap] Enables cursor syncronization #142821

Merged
merged 8 commits into from
Oct 12, 2022

Conversation

stratoula
Copy link
Contributor

@stratoula stratoula commented Oct 6, 2022

Summary

Part of #138398

This PR enables cursor synchronization into the heatmap charts.

The tooltip synchronization doesn't work. I opened a feature request in EC repo elastic/elastic-charts#1844

lens

@stratoula
Copy link
Contributor Author

stratoula commented Oct 6, 2022

@markov00 @nickofthyme I need your help here.

On the following gif I have an agg based heatmap (2nd chart) and a lens heatmap (3rd chart). Both charts share the same code but the hovering effect is visible only on the lens heatmap but not on the agg based. Can you understand why?

lens

@nickofthyme
Copy link
Contributor

nickofthyme commented Oct 6, 2022

Hey @stratoula, this is because Lens is setting Settings.externalPointerEvents.tooltip.visible to true, default is false. Added here.

externalPointerEvents={{
tooltip: { visible: syncTooltips, placement: Placement.Right },
}}

This prop on the Settings spec is meant to control the behavior of the externally driven pointer events, including cursor sync. See externalPointerEvents and ExternalPointerEventsSettings for more details on available options.

Update

There was an error that created a difference in the behavior of the tooltip.visible option. Fixing it in elastic/elastic-charts#1842

@stratoula
Copy link
Contributor Author

stratoula commented Oct 10, 2022

@nickofthyme thanx for the tip! You helped me to identify a bug #142954

So this means that the heatmap and the xy work differently right? In the XY even if I have the

externalPointerEvents={{
              tooltip: { visible: false, placement: Placement.Right },
            }}

although the tooltips are not synced, I can see the hovering

image

but in heatmap in order to see the hovering effect this should be always set to true?

@stratoula stratoula changed the title [Lens][Heatmap] Enables cursor syncronizations [Lens][Heatmap] Enables cursor syncronization Oct 10, 2022
@nickofthyme
Copy link
Contributor

So this means that the heatmap and the xy work differently right?

No I agree this is a bug 🐛 that creates a difference in the behavior of the tooltip.visible option. Fixing it in elastic/elastic-charts#1842

@stratoula
Copy link
Contributor Author

Pausing this until the fix on EC gets merged

@nickofthyme
Copy link
Contributor

Updating EC with fix in #143103

@stratoula stratoula added backport:skip This commit does not require backporting Team:Visualizations Visualization editors, elastic-charts and infrastructure labels Oct 12, 2022
@stratoula stratoula marked this pull request as ready for review October 12, 2022 13:11
@stratoula stratoula requested a review from a team as a code owner October 12, 2022 13:11
@elasticmachine
Copy link
Contributor

Pinging @elastic/kibana-vis-editors @elastic/kibana-vis-editors-external (Team:VisEditors)

@kibana-ci
Copy link
Collaborator

💚 Build Succeeded

Metrics [docs]

Public APIs missing comments

Total count of every public API that lacks a comment. Target amount is 0. Run node scripts/build_api_docs --plugin [yourplugin] --stats comments for more detailed information.

id before after diff
expressionHeatmap 101 102 +1

Async chunks

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

id before after diff
expressionHeatmap 91.1KB 91.3KB +203.0B

Page load bundle

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

id before after diff
expressionHeatmap 13.8KB 14.0KB +192.0B
Unknown metric groups

API count

id before after diff
expressionHeatmap 105 106 +1

History

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

Copy link
Contributor

@flash1293 flash1293 left a comment

Choose a reason for hiding this comment

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

LGTM for now, lets wait for datavis to add this on their side to complete the feature

@stratoula stratoula merged commit 64472d2 into elastic:main Oct 12, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
backport:skip This commit does not require backporting Feature:Heatmap Heatmap visualization Feature:Lens release_note:enhancement Team:Visualizations Visualization editors, elastic-charts and infrastructure v8.6.0
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants