-
Notifications
You must be signed in to change notification settings - Fork 8.3k
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
[Fleet][Eui Visual Refresh] Make agent status colors theme aware #204070
[Fleet][Eui Visual Refresh] Make agent status colors theme aware #204070
Conversation
Pinging @elastic/fleet (Team:Fleet) |
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.
code LGTM 🚀
99ce7db
to
144c01b
Compare
Thanks @nchaulet - FYI I had accidentally committed an unrelated WIP change that I reverted, code is otherwise the same. |
💛 Build succeeded, but was flaky
Failed CI StepsTest Failures
Metrics [docs]Async chunks
|
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
@elasticmachine merge upstream |
x-pack/plugins/fleet/public/applications/fleet/sections/agents/services/agent_status.tsx
Outdated
Show resolved
Hide resolved
9b2b349
to
5eafbc6
Compare
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.
✅ Changes LGTM from EUI side
…stic#204070) ## Summary Closes elastic#201997 Fleet does not make proper use of [color palettes](https://eui.elastic.co/#/utilities/color-palettes), in the sense that [vis colors should only be used to visualizations](elastic#199715 (comment)). There are currently two Fleet UI elements, in the agents list table, that use some vis colors and need to be updated: - the status icons in the agent status summary - the horizontal agent status bar ![image](https://github.com/user-attachments/assets/7c4500b0-1c2d-4a65-9886-3857c8210dc2) This PR updates the function `getColorForAgentStatus`, which returns the color based on agent status, to return theme colors with semantic meaning aligned with the agent status badges. This will ensure colours are aligned between agent status badges and the table header in both Amsterdam and Borealis themes. It should be noted that the colours used for offline and inactive status (lightShade and darkShade), are marked as disabled, since their use isn't properly semantic: <img width="1012" alt="Screenshot 2024-12-16 at 15 31 00" src="https://github.com/user-attachments/assets/ee7a185f-01d9-4139-a1ff-785a249fd882" /> ## Screenshots ### Before (current `main`) #### Amsterdam theme <img width="1918" alt="fleet-agents-amsterdam-main" src="https://github.com/user-attachments/assets/1be3ccf7-64bd-40e3-832d-b79f47345170" /> #### Borealis theme <img width="1918" alt="fleet-agents-borealis-main" src="https://github.com/user-attachments/assets/276208ed-91a8-41df-8858-53a0e7894c4a" /> ### After #### Amsterdam theme <img width="1918" alt="fleet-agents-amsterdam-branch" src="https://github.com/user-attachments/assets/e9e6ab25-f43e-4949-9e9c-8edc3443effd" /> #### Borealis theme <img width="1918" alt="fleet-agents-borealis-branch" src="https://github.com/user-attachments/assets/6ae2c3ca-9209-406f-8f46-6ee40dc77632" />
Summary
Closes #201997
Fleet does not make proper use of color palettes, in the sense that vis colors should only be used to visualizations.
There are currently two Fleet UI elements, in the agents list table, that use some vis colors and need to be updated:
This PR updates the function
getColorForAgentStatus
, which returns the color based on agent status, to return theme colors with semantic meaning aligned with the agent status badges. This will ensure colours are aligned between agent status badges and the table header in both Amsterdam and Borealis themes.It should be noted that the colours used for offline and inactive status (lightShade and darkShade), are marked as disabled, since their use isn't properly semantic:
Screenshots
Before (current
main
)Amsterdam theme
Borealis theme
After
Amsterdam theme
Borealis theme