[Unified Field List] fix long single-word values (#172544)

## Summary

Fixes non-wrapping of a single word values:

![image](3a9acfed-15da-4e46-84fc-72f42acc8716)

It worked correctly for long values that are multi words, that's why I
didn't notice it.
<img width="437" alt="Screenshot 2023-12-05 at 10 03 51"
src="2713a65e-c3fb-4bbb-a6f5-49f6cc00ac11">

It was caused by last minute change in my
[PR](https://github.com/elastic/kibana/pull/171076) here: where I
swapped `word-break: break-word;` (deprecated) to `overflow-wrap:
break-word;` which is not equivalent. Changing the value to `anywhere`
solves it.
This commit is contained in:
Marta Bondyra 2023-12-05 14:07:31 +01:00 committed by GitHub
parent 5fe03cc128
commit e5e64f8c9f
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -87,7 +87,7 @@ const FieldTopValuesBucket: React.FC<FieldTopValuesBucketProps> = ({
grow={true}
data-test-subj={`${dataTestSubject}-topValues-formattedFieldValue`}
css={css`
overflow-wrap: break-word;
overflow-wrap: anywhere;
`}
>
{(formattedFieldValue?.length ?? 0) > 0 ? (