-
Notifications
You must be signed in to change notification settings - Fork 0
Closed
Description
Priority: HIGH
Severity: Design System Consistency
Identified in: Design QA Review (2026-01-10)
Location: All dashboard files
Description
Three dashboards use different color values and approaches despite having comprehensive design token documentation. The governance dashboard introduces ad-hoc colors not defined in the design system, creating maintenance burden and potential visual inconsistency.
Current State
Design Tokens (Source of Truth)
Located in: /frontend/src/design-system/lexecon-design-tokens.js
- Primary:
#0891b2✅ (consistent) - Background dark:
#0f172a✅ (consistent) - Background card:
#1e293b✅ (consistent) - Text primary:
#f1f5f9✅ (consistent) - Text secondary:
#94a3b8✅ (consistent) - Border:
#334155✅ (consistent)
Problem: Ad-hoc Colors in Governance Dashboard
governance_dashboard.html:20
:root {
--bg-card-hover: #2d3b52; /* ❌ Not in design tokens */
--risk-critical: #dc2626;
--risk-high: #f59e0b;
--risk-medium: #eab308;
--risk-low: #84cc16;
}Impact
- Design System Fragmentation: Creates parallel color system
- Maintenance Burden: Changes must be made in multiple places
- Future Inconsistency: Risk of colors drifting apart
- Onboarding Difficulty: New developers unsure which colors to use
Recommended Solution
1. Add Missing Colors to Design Tokens
Update /frontend/src/design-system/lexecon-design-tokens.js:
export const colors = {
// ... existing colors ...
// Interactive states
'bg-card-hover': '#2d3b52',
// Risk levels (standardized)
'risk-critical': '#dc2626',
'risk-high': '#f59e0b',
'risk-medium': '#eab308',
'risk-low': '#84cc16',
// Alternatively, use semantic naming:
'state-danger': '#dc2626',
'state-warning': '#f59e0b',
'state-caution': '#eab308',
'state-success': '#84cc16',
};2. Update Governance Dashboard
Replace custom CSS variables with design token imports:
import { colors } from '/frontend/src/design-system/lexecon-design-tokens.js';
// Use design tokens
const styles = `
:root {
--bg-card-hover: ${colors['bg-card-hover']};
--risk-critical: ${colors['state-danger']};
--risk-high: ${colors['state-warning']};
/* etc */
}
`;3. Audit All Color Usage
Search for color hex values not in design tokens:
grep -r "#[0-9a-fA-F]\{6\}" *.html --colorReplace with design token references.
Implementation Steps
- Review and approve color additions to design system
- Update
lexecon-design-tokens.jswith missing colors - Update design system documentation with new colors
- Refactor
governance_dashboard.htmlto use design tokens - Audit
dashboard.htmlfor any ad-hoc colors - Audit
login.htmlfor any ad-hoc colors - Update component guide with risk level color usage
- Create linting rule to prevent hardcoded colors (optional)
Acceptance Criteria
- All colors defined in design tokens
- No ad-hoc hex colors in any dashboard
- Consistent risk level colors across all interfaces
- Documentation updated with new color tokens
- Visual regression test passes
Files to Update
/frontend/src/design-system/lexecon-design-tokens.jsgovernance_dashboard.htmldashboard.html(audit only)login.html(audit only)/docs/design-system/lexecon-design-system.md/docs/design-system/lexecon-component-guide.md
Related Issues
- Design QA Report Issue Welcome to Lexecon Discussions! #1
- See: Design System Specification Improvements
Labels
design-system, high-priority, consistency, refactoring