Timeseries: Limit long text in legend (#66307)

This commit is contained in:
Adela Almasan 2023-04-11 13:01:57 -05:00 committed by GitHub
parent ae23ef5b41
commit 7e270021a8
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 8 additions and 0 deletions

View File

@ -74,6 +74,7 @@ export const VizLegendListItem = <T = unknown,>({
<button
disabled={readonly}
type="button"
title={item.label}
onBlur={onMouseOut}
onFocus={onMouseOver}
onMouseOver={onMouseOver}
@ -100,6 +101,9 @@ const getStyles = (theme: GrafanaTheme2) => ({
font-size: inherit;
padding: 0;
user-select: text;
max-width: 600px;
text-overflow: ellipsis;
overflow: hidden;
`,
itemDisabled: css`
label: LegendLabelDisabled;

View File

@ -73,6 +73,7 @@ export const LegendTableItem = ({
<button
disabled={readonly}
type="button"
title={item.label}
onBlur={onMouseOut}
onFocus={onMouseOver}
onMouseOver={onMouseOver}
@ -122,6 +123,9 @@ const getStyles = (theme: GrafanaTheme2) => {
border: none;
font-size: inherit;
padding: 0;
max-width: 600px;
text-overflow: ellipsis;
overflow: hidden;
`,
labelDisabled: css`
label: LegendLabelDisabled;