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][Unified search] Auto expand comboboxes and popovers based on the content #171573

Merged
merged 28 commits into from
Nov 28, 2023

Conversation

mbondyra
Copy link
Contributor

@mbondyra mbondyra commented Nov 20, 2023

Summary

Fixes partially two remaining tasks from #168753
Fixes partially dataview issue from #170398
It stretches to maximum approximate 60 characters if any of the labels in the list is of this length. If the content doesn't need the container to stretch, it doesn't do it.

Field picker in Lens

minimum width:
Screenshot 2023-11-21 at 15 56 03

auto-expanded width:
Screenshot 2023-11-21 at 15 58 22

Layer data view picker in Lens Screenshot 2023-11-21 at 16 01 17 Screenshot 2023-11-21 at 15 58 09 Screenshot 2023-11-21 at 15 56 27
Data view picker in Unified Search Screenshot 2023-11-21 at 16 00 29 Screenshot 2023-11-21 at 15 58 04 Screenshot 2023-11-21 at 15 56 20
Data view picker in dashboard Create control flyout Screenshot 2023-11-21 at 16 14 00 Screenshot 2023-11-21 at 15 54 56
Unified search data view select component (tested in maps) Screenshot 2023-11-22 at 14 38 25
Unified search field and value picker Adds `panelMinWidth`, removes the custom flex width change behavior Screenshot 2023-11-22 at 14 40 26
Nov-22-2023.14-20-48.mp4
Discover breakdown field

Removes the focus stretching and instead uses the panelMinWidth prop

Screenshot 2023-11-21 at 16 46 50 Screenshot 2023-11-21 at 16 48 20

@mbondyra mbondyra added release_note:skip Skip the PR/issue when compiling release notes Feature:Lens Feature:Unified search Unified search related tasks v8.12.0 labels Nov 20, 2023
@mbondyra mbondyra force-pushed the widen_eui_selectables_steps branch 2 times, most recently from bc2a5b8 to 73acf81 Compare November 20, 2023 20:14
@mbondyra mbondyra force-pushed the widen_eui_selectables_steps branch 2 times, most recently from 00f0e43 to b076dd1 Compare November 21, 2023 14:41
@mbondyra mbondyra marked this pull request as ready for review November 21, 2023 15:29
@mbondyra mbondyra requested review from a team as code owners November 21, 2023 15:29
Copy link
Contributor

@ThomThomson ThomThomson left a comment

Choose a reason for hiding this comment

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

Changes in presentation-util LGTM! Nice work!

@mbondyra mbondyra requested a review from a team as a code owner November 21, 2023 15:50
Copy link
Contributor

@davismcphee davismcphee left a comment

Choose a reason for hiding this comment

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

Tested the Unified Histogram changes locally, and it's working as intended. Data Discovery changes LGTM 👍

@mbondyra mbondyra added the Team:Visualizations Visualization editors, elastic-charts and infrastructure label Nov 22, 2023
@elasticmachine
Copy link
Contributor

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

@mbondyra mbondyra changed the title [Lens][Unified search] Auto expand dataview popovers based on the content [Lens][Unified search] Auto expand comboboxes and popovers based on the content Nov 22, 2023
};

const handleFocus: React.FocusEventHandler<HTMLDivElement> = () => {
Copy link
Contributor

Choose a reason for hiding this comment

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

That's nice to get rid of this type of code 🎉

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.

First code review pass done.
Will test it locally shortly.

@mbondyra
Copy link
Contributor Author

Thanks @dej611 I addressed your comments 😊

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 locally with Safari! 👍

@mbondyra mbondyra removed the request for review from a team November 28, 2023 11:14
@kibana-ci
Copy link
Collaborator

💚 Build Succeeded

Metrics [docs]

Module Count

Fewer modules leads to a faster build time

id before after diff
eventAnnotationListing 456 460 +4
lens 1141 1145 +4
presentationUtil 124 128 +4
unifiedHistogram 64 68 +4
unifiedSearch 215 219 +4
total +20

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
@kbn/calculate-width-from-char-count - 7 +7

Async chunks

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

id before after diff
eventAnnotationListing 196.8KB 197.0KB +132.0B
lens 1.4MB 1.4MB +476.0B
presentationUtil 82.0KB 82.4KB +402.0B
unifiedHistogram 50.6KB 51.0KB +409.0B
unifiedSearch 213.8KB 214.7KB +907.0B
total +2.3KB

Public APIs missing exports

Total count of every type that is part of your API that should be exported but is not. This will cause broken links in the API documentation system. Target amount is 0. Run node scripts/build_api_docs --plugin [yourplugin] --stats exports for more detailed information.

id before after diff
@kbn/calculate-width-from-char-count - 1 +1

Page load bundle

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

id before after diff
unifiedSearch 35.3KB 35.4KB +64.0B
Unknown metric groups

API count

id before after diff
@kbn/calculate-width-from-char-count - 7 +7

async chunk count

id before after diff
unifiedSearch 20 21 +1

History

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

@mbondyra mbondyra merged commit 085878c into elastic:main Nov 28, 2023
28 checks passed
@kibanamachine kibanamachine added the backport:skip This commit does not require backporting label Nov 28, 2023
@mbondyra mbondyra deleted the widen_eui_selectables_steps branch November 28, 2023 12:13
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:Lens Feature:Unified search Unified search related tasks release_note:skip Skip the PR/issue when compiling release notes Team:Visualizations Visualization editors, elastic-charts and infrastructure v8.12.0
Projects
None yet
Development

Successfully merging this pull request may close these issues.

7 participants