Skip to content

Commit

Permalink
[Controls] Fix text alignment of options list control selections (#17…
Browse files Browse the repository at this point in the history
…5073)

Closes #174971

## Summary

This PR fixes the alignment issue for the options list control that
happened due to the most recent EUI update.

| Before | After |
|--------|--------|
| ![Jan-17-2024
16-03-07](https://github.com/elastic/kibana/assets/8698078/d40993fc-ed16-4ca6-86fa-aa156e4ef4d8)
| ![Jan-17-2024
16-04-00](https://github.com/elastic/kibana/assets/8698078/1746cecb-8c93-46a9-b381-1ef07b1d9999)
|

### Checklist

- [x] This renders correctly on smaller devices using a responsive
layout. (You can test this [in your
browser](https://www.browserstack.com/guide/responsive-testing-on-local-server))
- [x] This was checked for [cross-browser
compatibility](https://www.elastic.co/support/matrix#matrix_browsers)

### For maintainers

- [ ] This was checked for breaking API changes and was [labeled
appropriately](https://www.elastic.co/guide/en/kibana/master/contributing.html#kibana-release-notes-process)
  • Loading branch information
Heenawter authored Jan 30, 2024
1 parent ac6feb9 commit 0a2ccf5
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -31,10 +31,9 @@
color: $euiColorDanger;
}

.euiFilterButton__text-hasNotification {
.optionsList--selectionText {
flex-grow: 1;
justify-content: space-between;
width: 0;
text-align: left;
}
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -152,6 +152,7 @@ export const OptionsListControl = ({
isSelected={isPopoverOpen}
numActiveFilters={validSelectionsCount}
hasActiveFilters={Boolean(validSelectionsCount)}
textProps={{ className: 'optionsList--selectionText' }}
>
{hasSelections || existsSelected
? selectionDisplayNode
Expand Down

0 comments on commit 0a2ccf5

Please sign in to comment.