Fix color consistency: error states, status shades, progress bar colors#3891
Fix color consistency: error states, status shades, progress bar colors#3891
Conversation
✅ Deploy Preview for kubestellarconsole ready!
To edit notification comments on pull requests, go to your Netlify project configuration. |
|
👋 Hey @copilot — thanks for opening this PR!
This is an automated message. |
❌ PR Title Verification FailedYour PR title does not follow the required format. Current title: Required FormatPR titles must start with one of these emoji prefixes:
How to FixEdit your PR title to start with the appropriate emoji. For example:
You can edit the title by clicking the Edit button next to your PR title. This comment was automatically posted by the PR Title Verifier workflow. |
Agent-Logs-Url: https://github.com/kubestellar/console/sessions/8046eb7a-792e-4b31-a1ad-139875edbed9 Co-authored-by: clubanderson <407614+clubanderson@users.noreply.github.com>
|
[APPROVALNOTIFIER] This PR is NOT APPROVED This pull-request has been approved by: The full list of commands accepted by this bot can be found here. DetailsNeeds approval from an approver in each of these files:Approvers can indicate their approval by writing |
|
Thanks for your pull request. Before we can look at it, you'll need to add a 'DCO signoff' to your commits. 📝 Please follow instructions in the contributing guide to update your commits with the DCO Full details of the Developer Certificate of Origin can be found at developercertificate.org. The list of commits missing DCO signoff: DetailsInstructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes-sigs/prow repository. I understand the commands that are listed here. |
There was a problem hiding this comment.
Pull request overview
This PR addresses UI color consistency across several components by aligning status/error/progress colors with the app’s intended semantic palette.
Changes:
- Adjusted Kyverno PolicyReport “Error” indicator/bar segment color.
- Standardized Persistence connection test result text shades.
- Updated Missions progress bar “no failed clusters” color to the app accent.
Reviewed changes
Copilot reviewed 3 out of 3 changed files in this pull request and generated 2 comments.
| File | Description |
|---|---|
| web/src/components/settings/sections/PersistenceSection.tsx | Uses text-green-400 / text-red-400 for test result feedback text. |
| web/src/components/cards/kyverno/KyvernoDetailModal.tsx | Changes PolicyReport “Error” legend + bar segment color from blue to orange. |
| web/src/components/cards/Missions.tsx | Changes progress bar “no failed clusters” color from blue to purple. |
| <span className="flex items-center gap-1"><span className="w-2.5 h-2.5 rounded-sm bg-green-500" /> Pass</span> | ||
| <span className="flex items-center gap-1"><span className="w-2.5 h-2.5 rounded-sm bg-red-500" /> Fail</span> | ||
| <span className="flex items-center gap-1"><span className="w-2.5 h-2.5 rounded-sm bg-yellow-500" /> Warn</span> | ||
| <span className="flex items-center gap-1"><span className="w-2.5 h-2.5 rounded-sm bg-blue-500" /> Error</span> | ||
| <span className="flex items-center gap-1"><span className="w-2.5 h-2.5 rounded-sm bg-orange-500" /> Error</span> | ||
| <span className="flex items-center gap-1"><span className="w-2.5 h-2.5 rounded-sm bg-zinc-500" /> Skip</span> |
There was a problem hiding this comment.
This card hardcodes status colors in the legend. The repo has a centralized status color system intended to prevent exactly these inconsistencies (see web/src/lib/cards/statusColors.ts:1-6). Consider deriving these classes from STATUS_COLORS/getSeverityColors instead of inline Tailwind strings; if “Error” needs to be distinct from “Fail”, encode that distinction centrally so other cards stay consistent too.
| 'h-full rounded-full transition-all duration-500', | ||
| mission.status === 'orbit' ? 'bg-green-500' : | ||
| mission.status === 'abort' ? 'bg-red-500' : | ||
| failedClusters > 0 ? 'bg-red-500' : 'bg-blue-500', | ||
| failedClusters > 0 ? 'bg-red-500' : 'bg-purple-500', | ||
| )} |
There was a problem hiding this comment.
The progress bar color selection is hardcoded here. Given the repo’s centralized status color system (web/src/lib/cards/statusColors.ts) and the amount of status-color reuse across cards, consider routing this through the shared status color helpers (or an existing status→color map in this file) so future palette tweaks don’t require editing multiple conditionals.
🔄 Auto-Applying Copilot Code ReviewCopilot code review found 0 code suggestion(s) and 2 general comment(s). Also address these general comments:
Push all fixes in a single commit. Run Auto-generated by copilot-review-apply workflow. |
Auto-QA flagged several color inconsistencies where error/failure states used non-semantic colors and status text used non-standard shades.
📌 Fixes
📝 Summary of Changes
Three targeted Tailwind class fixes across components:
KyvernoDetailModal:bg-blue-500→bg-orange-500for "Error" in policy report legend/bars. Blue is info/neutral; error needs a warm danger color. Orange differentiates frombg-red-500(used for "Fail") while staying semantically correct.PersistenceSection:text-green-500/text-red-500→text-green-400/text-red-400for connection test result text. Standardizes to the dominant codebase shade (56×text-green-400, 50×text-red-400).Missions:bg-blue-500→bg-purple-500for the progress bar on missions with no failed clusters. Purple matches the app's primary accent color.Changes Made
bg-blue-500→bg-orange-500for Kyverno policy report "Error" status (legend + bar segment)text-green-500/text-red-500→text-green-400/text-red-400in PersistenceSection connection test feedbackbg-blue-500→bg-purple-500for Missions progress bar (no-failure state)Checklist
git commit -s)Screenshots or Logs (if applicable)
N/A — pure Tailwind class changes, no behavioral change.
👀 Reviewer Notes
Changes are 5 lines across 3 files. No logic touched — only CSS utility class strings.
⚡ Quickly spin up Copilot coding agent tasks from anywhere on your macOS or Windows machine with Raycast.