-
Notifications
You must be signed in to change notification settings - Fork 187
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Enhancement/4211 improve visualizations text size #4254
Enhancement/4211 improve visualizations text size #4254
Conversation
…into enhancement/4211-improve-visualizations-text-size
@@ -34,51 +36,55 @@ export const VisualizationBasic = ({ | |||
noDataMessage, | |||
errorTitle = 'Error', | |||
errorMessage, | |||
error | |||
error, | |||
select |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
nitpick If we want to include some element before the legend, we should not call it select
and I would suggest a more generic name.
@@ -17,7 +17,7 @@ type ChartLegendProps = { | |||
*/ | |||
export function ChartLegend({ data }: ChartLegendProps) { | |||
const list = data.map(({label, labelColor, value, ...rest}, idx) => ({ | |||
label: `${label} (${value})`, | |||
label: <div style={{fontSize: '0.793rem'}}>{`${label} (${value})`}</div>, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
nitpick: The EuiListGroup
component has a property to modify the size of all EuiListItem
. You could use the property instead of the proposed solution.
Example:
return (
<EuiListGroup
className="chart-legend"
listItems={list}
color='text'
size='xs'
flush />
)
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
review
code ✔️
test ✔️
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM!
* Unused imports * Centered gravity graphic and list * font size texts first graph * CHANGELOG * Removing centered, and putting the same font size to the select (cherry picked from commit ad37304)
* Unused imports * Centered gravity graphic and list * font size texts first graph * CHANGELOG * Removing centered, and putting the same font size to the select (cherry picked from commit ad37304)
…#4275) Enhancement/4211 improve visualizations text size (#4254) * Unused imports * Centered gravity graphic and list * font size texts first graph * CHANGELOG * Removing centered, and putting the same font size to the select (cherry picked from commit ad37304) Co-authored-by: Chantal Belén kelm <[email protected]>
…ize (#4276) Enhancement/4211 improve visualizations text size (#4254) * Unused imports * Centered gravity graphic and list * font size texts first graph * CHANGELOG * Removing centered, and putting the same font size to the select (cherry picked from commit ad37304) Co-authored-by: Chantal Belén kelm <[email protected]>
The two graphs, the lists and the select were centered.
The font size was also corrected to the same used in the table.
To test go to:
Modules/Vulnerabilities.
or Agents/Select an agent/Click on the more button/Click on Vulnerabilities.