mirror of
https://github.com/elastic/kibana.git
synced 2025-06-27 10:40:07 -04:00
[Controls] Small visual fixes (#225430)
## Summary Fixes [#221140](https://github.com/elastic/kibana/issues/221140) Fixes [#223579](https://github.com/elastic/kibana/issues/223579) --- ### 🏷️ Long labels no longer truncated Label truncation was introduced sometime between versions 8.14 and 8.18: **8.14 (working):**  **8.18 (broken):**  ✅ **After the fix:**  --- ### 🎛️ [Controls] Options list hover background fix The original hover style comes from EUI. Removing it entirely made the interaction feel unclear, so I’ve reintroduced a lighter background to subtly indicate the hover state: **9.0 (broken):** <img width="648" alt="Screenshot 2025-06-26 at 14 05 51" src="https://github.com/user-attachments/assets/2eff832d-47bd-4664-84d3-62c88d013a89" /> ✅ **After the fix:** 
This commit is contained in:
parent
b0704474f0
commit
26d56b5060
2 changed files with 15 additions and 17 deletions
|
@ -162,12 +162,9 @@ export const ControlPanel = <ApiType extends DefaultControlApi = DefaultControlA
|
|||
) : isTwoLine ? null : (
|
||||
<EuiToolTip
|
||||
content={panelTitle || defaultPanelTitle}
|
||||
anchorProps={{ css: styles.tooltipAnchor }}
|
||||
anchorProps={{ css: styles.tooltipAnchor, className: 'eui-textTruncate' }}
|
||||
>
|
||||
<EuiFormLabel
|
||||
css={styles.formLabel}
|
||||
className="eui-textTruncate controlPanel--label"
|
||||
>
|
||||
<EuiFormLabel className="controlPanel--label">
|
||||
{panelTitle || defaultPanelTitle}
|
||||
</EuiFormLabel>
|
||||
</EuiToolTip>
|
||||
|
@ -213,14 +210,6 @@ const controlPanelStyles = {
|
|||
containerHidden: css({
|
||||
display: 'none', // Don't unmount, just hide
|
||||
}),
|
||||
formLabel: css({
|
||||
padding: '0 !important',
|
||||
height: '100%',
|
||||
maxWidth: '100%',
|
||||
overflow: 'hidden !important',
|
||||
textOverflow: 'ellipsis !important',
|
||||
whiteSpace: `nowrap !important` as 'nowrap',
|
||||
}),
|
||||
formControl: ({ euiTheme }: UseEuiTheme) =>
|
||||
css({
|
||||
'.euiFormControlLayout__prepend': {
|
||||
|
@ -277,6 +266,11 @@ const controlPanelStyles = {
|
|||
right: `calc(-${euiTheme.size.xs} - 1px)`,
|
||||
},
|
||||
},
|
||||
'.controlPanel--label': {
|
||||
padding: '0 !important',
|
||||
height: '100%',
|
||||
maxWidth: '100%',
|
||||
},
|
||||
}),
|
||||
tooltipAnchor: css({
|
||||
height: '100%',
|
||||
|
|
|
@ -55,10 +55,14 @@ const optionListControlStyles = {
|
|||
font-weight: ${euiTheme.font.weight.medium};
|
||||
`,
|
||||
invalidSelectionsToken: css({ verticalAlign: 'text-bottom' }),
|
||||
filterButton: ({ euiTheme }: UseEuiTheme) => css`
|
||||
font-weight: ${euiTheme.font.weight.regular} !important;
|
||||
color: ${euiTheme.colors.subduedText} !important;
|
||||
`,
|
||||
filterButton: ({ euiTheme }: UseEuiTheme) =>
|
||||
css({
|
||||
fontWeight: `${euiTheme.font.weight.regular} !important` as 'normal',
|
||||
color: `${euiTheme.colors.subduedText} !important`,
|
||||
'&:hover::before': {
|
||||
background: `${euiTheme.colors.backgroundBaseSubdued} !important`,
|
||||
},
|
||||
}),
|
||||
filterButtonText: css({
|
||||
flexGrow: 1,
|
||||
textAlign: 'left',
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue