-
Notifications
You must be signed in to change notification settings - Fork 8.2k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[Maps] Fix long field truncation on Comboboxes (#171829)
## Summary Fixes #171509 (fixed in all the places in maps) Adds middle truncation and combobox auto-expansion to the content to approximate of 60 character maximum for `SingleFieldSelect` and `FieldSelect` components in maps. I removed custom `renderOption` prop so the combobox can take care of the proper truncation while searching through the fields. One case I had to hack was to display a tooltip for a disabled state. I used `prepend` and some custom styling to do so - it works as before (check out the screenshot below). <details> <summary> FieldSelect component before</summary> <img width="471" alt="Screenshot 2023-11-22 at 16 08 21" src="https://github.com/elastic/kibana/assets/4283304/eb8a682a-0dfe-4bb0-9a88-8dc5863a5aff"> </details> <details> <summary> FieldSelect component after</summary> <img width="582" alt="Screenshot 2023-11-22 at 16 10 02" src="https://github.com/elastic/kibana/assets/4283304/b840fb7e-0789-46b7-b783-8e0aadb270ac"> </details> <details> <summary> SingleFieldSelect component before</summary> <img width="430" alt="Screenshot 2023-11-23 at 10 23 15" src="https://github.com/elastic/kibana/assets/4283304/fc4af30c-32ad-40d8-a051-4b123be8aa54"> </details> <details> <summary> SingleFieldSelect component after</summary> <img width="576" alt="Screenshot 2023-11-22 at 16 32 43" src="https://github.com/elastic/kibana/assets/4283304/2c3f496e-2e1b-4cf9-aa5b-f38c7a7eace2"> #### disabled state <img width="829" alt="Screenshot 2023-11-22 at 17 10 48" src="https://github.com/elastic/kibana/assets/4283304/8db0b076-d3f5-4ec4-9e7c-0e7121b14e04"> </details> --------- Co-authored-by: kibanamachine <42973632+kibanamachine@users.noreply.github.com>
- Loading branch information
1 parent
bf5f8cb
commit 37d5aca
Showing
5 changed files
with
69 additions
and
71 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters