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

[ES|QL] Clicking the editor closes the documentation popover #176394

Merged

Conversation

stratoula
Copy link
Contributor

@stratoula stratoula commented Feb 7, 2024

Summary

Part of #166907

Fixes the problem with the eui popovers and the monaco editor. I am not sure why it is happening. I think it is due to the third party library that eui uses to detects the outside clicks.

What I did to fix it:

  • Wrap the documentation popover in an EuiOutsideClickDetector
  • I force monaco editor to focus onMoyseDown

meow

This solves the problem on the documentation popover but not on the SuperDatePicker because I don't have a way to force it to close. I will ping the EUI team

@stratoula
Copy link
Contributor Author

/ci

@kibana-ci
Copy link
Collaborator

💛 Build succeeded, but was flaky

Failed CI Steps

Test Failures

  • [job] [logs] FTR Configs #86 / maps app Auto open file upload wizard in maps app "before all" hook for "should navigate to maps app with url params"
  • [job] [logs] FTR Configs #10 / ObservabilityApp Alert status filter > "after all" hook for "can be filtered to only show "all" alerts using the filter button"

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
lens 1.4MB 1.4MB +70.0B
textBasedLanguages 154.2KB 154.3KB +127.0B
total +197.0B

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

@stratoula stratoula marked this pull request as ready for review February 8, 2024 06:32
@stratoula stratoula requested a review from a team as a code owner February 8, 2024 06:32
@stratoula stratoula added release_note:fix Team:Visualizations Visualization editors, elastic-charts and infrastructure Feature:ES|QL ES|QL related features in Kibana labels Feb 8, 2024
@elasticmachine
Copy link
Contributor

Pinging @elastic/kibana-visualizations (Team:Visualizations)

@stratoula stratoula added v8.13.0 backport:skip This commit does not require backporting labels Feb 8, 2024
Copy link
Contributor

@dej611 dej611 left a comment

Choose a reason for hiding this comment

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

Tested and now the popover closes when clicking outside. 👍
The only annoying thing I found is that, in Safari and only sometimes, when clicking on the ES|QL editor the query gets all selected rather than just set the cursor at the end/in the clicked position. But not a blocker 🚀

@stratoula stratoula merged commit d492fb7 into elastic:main Feb 8, 2024
31 checks passed
fkanout pushed a commit to fkanout/kibana that referenced this pull request Feb 8, 2024
…#176394)

## Summary

Part of elastic#166907

Fixes the problem with the eui popovers and the monaco editor. I am not
sure why it is happening. I think it is due to the third party library
that eui uses to detects the outside clicks.

What I did to fix it:

- Wrap the documentation popover in an EuiOutsideClickDetector
- I force monaco editor to focus onMoyseDown


![meow](https://github.com/elastic/kibana/assets/17003240/f432608d-0801-4a68-b327-da1e8dec9f9a)

This solves the problem on the documentation popover but not on the
SuperDatePicker because I don't have a way to force it to close. I will
ping the EUI team
CoenWarmer pushed a commit to CoenWarmer/kibana that referenced this pull request Feb 15, 2024
…#176394)

## Summary

Part of elastic#166907

Fixes the problem with the eui popovers and the monaco editor. I am not
sure why it is happening. I think it is due to the third party library
that eui uses to detects the outside clicks.

What I did to fix it:

- Wrap the documentation popover in an EuiOutsideClickDetector
- I force monaco editor to focus onMoyseDown


![meow](https://github.com/elastic/kibana/assets/17003240/f432608d-0801-4a68-b327-da1e8dec9f9a)

This solves the problem on the documentation popover but not on the
SuperDatePicker because I don't have a way to force it to close. I will
ping the EUI team
fkanout pushed a commit to fkanout/kibana that referenced this pull request Mar 4, 2024
…#176394)

## Summary

Part of elastic#166907

Fixes the problem with the eui popovers and the monaco editor. I am not
sure why it is happening. I think it is due to the third party library
that eui uses to detects the outside clicks.

What I did to fix it:

- Wrap the documentation popover in an EuiOutsideClickDetector
- I force monaco editor to focus onMoyseDown


![meow](https://github.com/elastic/kibana/assets/17003240/f432608d-0801-4a68-b327-da1e8dec9f9a)

This solves the problem on the documentation popover but not on the
SuperDatePicker because I don't have a way to force it to close. I will
ping the EUI team
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:ES|QL ES|QL related features in Kibana release_note:fix Team:Visualizations Visualization editors, elastic-charts and infrastructure v8.13.0
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants