mirror of
https://github.com/bitbaum/evig.git
synced 2026-12-04 04:46:59 +01:00
fix(color): status/positive badges -> success token; brand -> action (SSOT)
Follow-up to the primary-* sweep. The config status/badge maps used the raw `primary-*` lime scale for "approved / published / active / completed / available / eco / done" statuses — an off-token green that did not theme-flip. Those are STATUS semantics, not brand, so they move to the `success-*` token. Result: a clean two-green system — brand = action (CTAs / logo), status-positive = success (badges) — instead of a third rogue lime. - 23 config maps (review / location / booking / marketplace / approval / hr / it-hilfe / tasks / decisions / protocols / workshops / deliverables / team / activity / conditions / service-categories / evig-projects / metrics …) -> success-*. - ui/status.ts `success` token (was itself primary-*) -> success-*. - designPrimitive.badge.success + adminBadge.green -> success-*. - lib/hirn methodology colors -> success; data/about hero band -> bg-action (brand). - AI-confidence "high" -> text-success; form accent-primary-600 -> accent-action. - Updated 3 test suites' colour assertions (+ a stale buttonVariants assertion). verify green (typecheck 0, lint 0, 90/90 unit tests). Zero primary-* class usage left in src; CLAUDE.md grep guard in place. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
This commit is contained in:
1 parent
00b3603cf0
commit
285b2eb86a
31 files changed
+119
-119
No files matched your search
@@ -61,7 +61,7 @@ export function ReportModal({
|
||||
value={r.value}
|
||||
checked={reportReason === r.value}
|
||||
onChange={e => onReportReasonChange(e.target.value)}
|
||||
className="accent-primary-600"
|
||||
className="accent-action"
|
||||
/>
|
||||
<span className="text-sm text-text-primary">{r.label}</span>
|
||||
</label>
|
||||
|
||||
@@ -23,10 +23,10 @@ export const ACTIVITY_UPDATE_TYPE_LABELS: Record<ActivityUpdateType, string> = {
|
||||
};
|
||||
|
||||
export const ACTIVITY_UPDATE_TYPE_COLORS: Record<ActivityUpdateType, string> = {
|
||||
accomplishment: 'bg-primary-100 dark:bg-primary-900/30 text-primary-800 dark:text-primary-300',
|
||||
accomplishment: 'bg-success-100 dark:bg-success-900/30 text-success-800 dark:text-success-300',
|
||||
milestone: 'bg-purple-100 text-purple-800',
|
||||
note: 'bg-neutral-100 text-neutral-800',
|
||||
announcement: 'bg-primary-100 dark:bg-primary-900/30 text-primary-800 dark:text-primary-300',
|
||||
announcement: 'bg-success-100 dark:bg-success-900/30 text-success-800 dark:text-success-300',
|
||||
};
|
||||
|
||||
export const ACTIVITY_UPDATE_TYPE_ICONS: Record<ActivityUpdateType, string> = {
|
||||
@@ -91,8 +91,8 @@ export const HELP_REQUEST_STATUS_LABELS: Record<HelpRequestStatus, string> = {
|
||||
|
||||
export const HELP_REQUEST_STATUS_COLORS: Record<HelpRequestStatus, string> = {
|
||||
open: 'bg-warning-100 dark:bg-warning-900/30 text-warning-800 dark:text-warning-200',
|
||||
in_progress: 'bg-primary-100 dark:bg-primary-900/30 text-primary-800 dark:text-primary-300',
|
||||
resolved: 'bg-primary-100 dark:bg-primary-900/30 text-primary-800 dark:text-primary-300',
|
||||
in_progress: 'bg-success-100 dark:bg-success-900/30 text-success-800 dark:text-success-300',
|
||||
resolved: 'bg-success-100 dark:bg-success-900/30 text-success-800 dark:text-success-300',
|
||||
cancelled: 'bg-neutral-100 text-neutral-800',
|
||||
};
|
||||
|
||||
|
||||
@@ -306,7 +306,7 @@ export const CATEGORY_LABELS: Record<MetricCategory, string> = {
|
||||
// Category colors for display
|
||||
export const CATEGORY_COLORS: Record<MetricCategory, { bg: string; text: string; icon: string }> = {
|
||||
financial: { bg: 'bg-neutral-100', text: 'text-neutral-700', icon: 'text-neutral-600' },
|
||||
environmental: { bg: 'bg-primary-100 dark:bg-primary-900/30', text: 'text-primary-700 dark:text-primary-300', icon: 'text-primary-600 dark:text-primary-400' },
|
||||
environmental: { bg: 'bg-success-100 dark:bg-success-900/30', text: 'text-success-700 dark:text-success-300', icon: 'text-success-600 dark:text-success-400' },
|
||||
social: { bg: 'bg-purple-100', text: 'text-purple-700', icon: 'text-purple-600' },
|
||||
digital: { bg: 'bg-orange-100', text: 'text-orange-700', icon: 'text-orange-600' },
|
||||
}
|
||||
@@ -39,8 +39,8 @@ export const APPROVAL_STATUS_BADGES: Record<string, ApprovalBadge> = {
|
||||
},
|
||||
[APPROVAL_STATUS.APPROVED]: {
|
||||
label: 'Genehmigt',
|
||||
color: 'text-primary-800 dark:text-primary-300',
|
||||
bg: 'bg-primary-100 dark:bg-primary-900/30',
|
||||
color: 'text-success-800 dark:text-success-300',
|
||||
bg: 'bg-success-100 dark:bg-success-900/30',
|
||||
},
|
||||
[APPROVAL_STATUS.REJECTED]: {
|
||||
label: 'Abgelehnt',
|
||||
@@ -54,8 +54,8 @@ export const APPROVAL_STATUS_BADGES: Record<string, ApprovalBadge> = {
|
||||
},
|
||||
[APPROVAL_STATUS.PUBLISHED]: {
|
||||
label: 'Veröffentlicht',
|
||||
color: 'text-primary-800 dark:text-primary-300',
|
||||
bg: 'bg-primary-100 dark:bg-primary-900/30',
|
||||
color: 'text-success-800 dark:text-success-300',
|
||||
bg: 'bg-success-100 dark:bg-success-900/30',
|
||||
},
|
||||
}
|
||||
|
||||
|
||||
@@ -158,7 +158,7 @@ export const BOOKING_STATUS_BADGES: Record<string, BookingStatusBadge> = {
|
||||
},
|
||||
[BOOKING_STATUS.ACCEPTED]: {
|
||||
label: 'Angenommen',
|
||||
color: 'bg-primary-100 text-primary-800 dark:bg-primary-900/30 dark:text-primary-300',
|
||||
color: 'bg-success-100 text-success-800 dark:bg-success-900/30 dark:text-success-300',
|
||||
description: `${TECHNICIAN_LABEL} hat angenommen`,
|
||||
},
|
||||
[BOOKING_STATUS.QUOTED]: {
|
||||
@@ -168,7 +168,7 @@ export const BOOKING_STATUS_BADGES: Record<string, BookingStatusBadge> = {
|
||||
},
|
||||
[BOOKING_STATUS.QUOTE_APPROVED]: {
|
||||
label: 'Bestätigt',
|
||||
color: 'bg-primary-100 text-primary-800 dark:bg-primary-900/30 dark:text-primary-300',
|
||||
color: 'bg-success-100 text-success-800 dark:bg-success-900/30 dark:text-success-300',
|
||||
description: 'Wartet auf Start',
|
||||
},
|
||||
[BOOKING_STATUS.QUOTE_REJECTED]: {
|
||||
@@ -178,12 +178,12 @@ export const BOOKING_STATUS_BADGES: Record<string, BookingStatusBadge> = {
|
||||
},
|
||||
[BOOKING_STATUS.IN_PROGRESS]: {
|
||||
label: 'In Bearbeitung',
|
||||
color: 'bg-primary-100 text-primary-800 dark:bg-primary-900/30 dark:text-primary-300',
|
||||
color: 'bg-success-100 text-success-800 dark:bg-success-900/30 dark:text-success-300',
|
||||
description: 'Wird repariert',
|
||||
},
|
||||
[BOOKING_STATUS.COMPLETED]: {
|
||||
label: 'Abgeschlossen',
|
||||
color: 'bg-primary-100 text-primary-800 dark:bg-primary-900/30 dark:text-primary-300',
|
||||
color: 'bg-success-100 text-success-800 dark:bg-success-900/30 dark:text-success-300',
|
||||
description: 'Reparatur fertig',
|
||||
},
|
||||
[BOOKING_STATUS.REJECTED]: {
|
||||
@@ -203,7 +203,7 @@ export const BOOKING_STATUS_BADGES: Record<string, BookingStatusBadge> = {
|
||||
},
|
||||
[BOOKING_STATUS.CONFIRMED]: {
|
||||
label: 'Bestätigt',
|
||||
color: 'bg-primary-100 text-primary-800 dark:bg-primary-900/30 dark:text-primary-300',
|
||||
color: 'bg-success-100 text-success-800 dark:bg-success-900/30 dark:text-success-300',
|
||||
},
|
||||
}
|
||||
|
||||
|
||||
@@ -21,9 +21,9 @@ export const DECISION_STATUS_CONFIG: Record<
|
||||
{ label: string; color: string }
|
||||
> = {
|
||||
draft: { label: 'Entwurf', color: 'bg-neutral-100 text-neutral-700' },
|
||||
discussion: { label: 'Diskussion', color: 'bg-primary-100 dark:bg-primary-900/30 text-primary-700 dark:text-primary-300' },
|
||||
discussion: { label: 'Diskussion', color: 'bg-success-100 dark:bg-success-900/30 text-success-700 dark:text-success-300' },
|
||||
voting: { label: 'Abstimmung', color: 'bg-warning-100 dark:bg-warning-900/30 text-warning-700 dark:text-warning-200' },
|
||||
closed: { label: 'Abgeschlossen', color: 'bg-primary-100 dark:bg-primary-900/30 text-primary-700 dark:text-primary-300' },
|
||||
closed: { label: 'Abgeschlossen', color: 'bg-success-100 dark:bg-success-900/30 text-success-700 dark:text-success-300' },
|
||||
cancelled: { label: 'Abgebrochen', color: 'bg-error-100 text-error-700' },
|
||||
};
|
||||
|
||||
@@ -360,7 +360,7 @@ export const CONSENT_RESPONSE_CONFIG: Record<
|
||||
ConsentResponse,
|
||||
{ label: string; color: string }
|
||||
> = {
|
||||
agree: { label: 'Zustimmen', color: 'bg-primary-100 dark:bg-primary-900/30 text-primary-700 dark:text-primary-300' },
|
||||
agree: { label: 'Zustimmen', color: 'bg-success-100 dark:bg-success-900/30 text-success-700 dark:text-success-300' },
|
||||
abstain: { label: 'Enthalten', color: 'bg-neutral-100 text-neutral-700' },
|
||||
disagree: { label: 'Ablehnen', color: 'bg-orange-100 text-orange-700' },
|
||||
block: { label: 'Blockieren', color: 'bg-error-100 text-error-700' },
|
||||
@@ -397,7 +397,7 @@ export const COMMENT_POSITION_CONFIG: Record<
|
||||
CommentPosition,
|
||||
{ label: string; color: string }
|
||||
> = {
|
||||
for: { label: 'Dafür', color: 'bg-primary-100 dark:bg-primary-900/30 text-primary-700 dark:text-primary-300' },
|
||||
for: { label: 'Dafür', color: 'bg-success-100 dark:bg-success-900/30 text-success-700 dark:text-success-300' },
|
||||
against: { label: 'Dagegen', color: 'bg-error-100 text-error-700' },
|
||||
question: { label: 'Frage', color: 'bg-neutral-100 text-neutral-700' },
|
||||
info: { label: 'Information', color: 'bg-purple-100 text-purple-700' },
|
||||
|
||||
@@ -53,7 +53,7 @@ export const DELIVERABLE_STATUS_COLORS: Record<DeliverableStatus, string> = {
|
||||
draft: 'bg-neutral-100 text-neutral-800',
|
||||
in_review: 'bg-warning-100 dark:bg-warning-900/30 text-warning-800 dark:text-warning-200',
|
||||
revising: 'bg-orange-100 text-orange-800',
|
||||
approved: 'bg-primary-100 dark:bg-primary-900/30 text-primary-800 dark:text-primary-300',
|
||||
approved: 'bg-success-100 dark:bg-success-900/30 text-success-800 dark:text-success-300',
|
||||
}
|
||||
|
||||
// ---- Visibility -------------------------------------------------------------
|
||||
@@ -89,7 +89,7 @@ export const FEEDBACK_KIND_LABELS: Record<FeedbackKind, string> = {
|
||||
export const FEEDBACK_KIND_COLORS: Record<FeedbackKind, string> = {
|
||||
comment: 'bg-neutral-100 text-neutral-800',
|
||||
change_request: 'bg-orange-100 text-orange-800',
|
||||
approval: 'bg-primary-100 dark:bg-primary-900/30 text-primary-800 dark:text-primary-300',
|
||||
approval: 'bg-success-100 dark:bg-success-900/30 text-success-800 dark:text-success-300',
|
||||
}
|
||||
|
||||
// ---- Feedback status (change_request lifecycle) -----------------------------
|
||||
@@ -112,9 +112,9 @@ export const FEEDBACK_STATUS_LABELS: Record<FeedbackStatus, string> = {
|
||||
|
||||
export const FEEDBACK_STATUS_COLORS: Record<FeedbackStatus, string> = {
|
||||
open: 'bg-warning-100 dark:bg-warning-900/30 text-warning-800 dark:text-warning-200',
|
||||
addressed: 'bg-primary-100 dark:bg-primary-900/30 text-primary-800 dark:text-primary-300',
|
||||
addressed: 'bg-success-100 dark:bg-success-900/30 text-success-800 dark:text-success-300',
|
||||
wontfix: 'bg-neutral-100 text-neutral-800',
|
||||
approved: 'bg-primary-100 dark:bg-primary-900/30 text-primary-800 dark:text-primary-300',
|
||||
approved: 'bg-success-100 dark:bg-success-900/30 text-success-800 dark:text-success-300',
|
||||
}
|
||||
|
||||
// ---- Files ------------------------------------------------------------------
|
||||
|
||||
@@ -98,8 +98,8 @@ export interface ConditionBadge {
|
||||
}
|
||||
|
||||
const CONDITION_BADGE_COLORS: Record<string, string> = {
|
||||
new: 'bg-primary-100 dark:bg-primary-900/30 text-primary-800 dark:text-primary-300',
|
||||
like_new: 'bg-primary-100 dark:bg-primary-900/30 text-primary-800 dark:text-primary-300',
|
||||
new: 'bg-success-100 dark:bg-success-900/30 text-success-800 dark:text-success-300',
|
||||
like_new: 'bg-success-100 dark:bg-success-900/30 text-success-800 dark:text-success-300',
|
||||
good: 'bg-warning-100 dark:bg-warning-900/30 text-warning-800 dark:text-warning-200',
|
||||
fair: 'bg-orange-100 text-orange-800',
|
||||
poor: 'bg-error-100 text-error-800',
|
||||
|
||||
@@ -53,7 +53,7 @@ export const EVIG_PROJECTS: EvigProject[] = [
|
||||
* kennzahlen confidence badges.
|
||||
*/
|
||||
export const PROJECT_STATUS_STYLE: Record<ProjectStatus, string> = {
|
||||
live: 'bg-primary-50 text-primary-700 dark:bg-primary-900/30 dark:text-primary-300',
|
||||
live: 'bg-success-50 text-success-700 dark:bg-success-900/30 dark:text-success-300',
|
||||
beta: 'bg-info-50 text-info-700 dark:bg-info-900/30 dark:text-info-300',
|
||||
building: 'bg-warning-50 text-warning-700 dark:bg-warning-900/30 dark:text-warning-300',
|
||||
planned: 'bg-neutral-100 text-neutral-600 dark:bg-neutral-800 dark:text-neutral-300',
|
||||
|
||||
@@ -36,16 +36,16 @@ const APPLICATION_STATUS_BADGE_STYLES: Record<ApplicationStatus, { color: string
|
||||
bg: 'bg-warning-100 dark:bg-warning-900/30',
|
||||
},
|
||||
interview: {
|
||||
color: 'text-primary-800 dark:text-primary-300',
|
||||
bg: 'bg-primary-100 dark:bg-primary-900/30',
|
||||
color: 'text-success-800 dark:text-success-300',
|
||||
bg: 'bg-success-100 dark:bg-success-900/30',
|
||||
},
|
||||
offer: {
|
||||
color: 'text-purple-800 dark:text-purple-300',
|
||||
bg: 'bg-purple-100 dark:bg-purple-900/30',
|
||||
},
|
||||
hired: {
|
||||
color: 'text-primary-800 dark:text-primary-300',
|
||||
bg: 'bg-primary-100 dark:bg-primary-900/30',
|
||||
color: 'text-success-800 dark:text-success-300',
|
||||
bg: 'bg-success-100 dark:bg-success-900/30',
|
||||
},
|
||||
rejected: {
|
||||
color: 'text-error-800 dark:text-error-300',
|
||||
|
||||
@@ -62,7 +62,7 @@ export const VACANCY_STATUS_LABELS: Record<VacancyStatus, string> = {
|
||||
|
||||
export const VACANCY_STATUS_COLORS: Record<VacancyStatus, string> = {
|
||||
draft: 'bg-neutral-100 text-neutral-700 dark:bg-neutral-800 dark:text-neutral-300',
|
||||
published: 'bg-primary-100 text-primary-800 dark:bg-primary-900/30 dark:text-primary-300',
|
||||
published: 'bg-success-100 text-success-800 dark:bg-success-900/30 dark:text-success-300',
|
||||
frozen: 'bg-warning-100 text-warning-800 dark:bg-warning-900/30 dark:text-warning-300',
|
||||
filled: 'bg-info-100 text-info-800 dark:bg-info-900/30 dark:text-info-300',
|
||||
closed: 'bg-neutral-200 text-neutral-800 dark:bg-neutral-700 dark:text-neutral-200',
|
||||
|
||||
+10
-10
@@ -148,14 +148,14 @@ export const SERVICE_CATEGORIES: ServiceCategory[] = [
|
||||
name: 'Reparaturen',
|
||||
description: 'Hardware-Reparaturen und Ersatzteile',
|
||||
icon: Wrench,
|
||||
color: 'bg-primary-500',
|
||||
color: 'bg-success-500',
|
||||
},
|
||||
{
|
||||
id: 'setup',
|
||||
name: 'Installation & Setup',
|
||||
description: 'Software-Installation und Geräte-Einrichtung',
|
||||
icon: Settings,
|
||||
color: 'bg-primary-500',
|
||||
color: 'bg-success-500',
|
||||
},
|
||||
{
|
||||
id: 'support',
|
||||
@@ -291,7 +291,7 @@ export const BUDGET_TIERS: BudgetTier[] = [
|
||||
icon: '💰',
|
||||
requiresAmount: true,
|
||||
multiplier: 1.0,
|
||||
badgeClass: 'bg-primary-100 dark:bg-primary-900/30 text-primary-700 dark:text-primary-300',
|
||||
badgeClass: 'bg-success-100 dark:bg-success-900/30 text-success-700 dark:text-success-300',
|
||||
},
|
||||
{
|
||||
id: 'supporter',
|
||||
@@ -300,7 +300,7 @@ export const BUDGET_TIERS: BudgetTier[] = [
|
||||
icon: '💚',
|
||||
requiresAmount: true,
|
||||
multiplier: 1.5,
|
||||
badgeClass: 'bg-primary-100 dark:bg-primary-900/30 text-primary-700 dark:text-primary-300',
|
||||
badgeClass: 'bg-success-100 dark:bg-success-900/30 text-success-700 dark:text-success-300',
|
||||
},
|
||||
]
|
||||
|
||||
@@ -325,7 +325,7 @@ export const DEVICE_CATEGORIES: DeviceCategory[] = [
|
||||
name: 'Laptop',
|
||||
description: 'Notebooks, MacBooks, Ultrabooks',
|
||||
icon: Laptop,
|
||||
color: 'bg-primary-500',
|
||||
color: 'bg-success-500',
|
||||
suggestedSkills: ['hardware_diagnosis', 'screen_repair', 'battery_replacement', 'keyboard_repair', 'ssd_upgrade', 'os_installation'],
|
||||
defaultTitle: 'Laptop-Hilfe benötigt',
|
||||
defaultDescription: 'Mein Laptop hat folgendes Problem:\n\n- \n\nMarke/Modell: \nAlter: ca. ',
|
||||
@@ -365,7 +365,7 @@ export const DEVICE_CATEGORIES: DeviceCategory[] = [
|
||||
name: 'Spielkonsole',
|
||||
description: 'PlayStation, Xbox, Nintendo, Retro-Konsolen',
|
||||
icon: Gamepad2,
|
||||
color: 'bg-primary-500',
|
||||
color: 'bg-success-500',
|
||||
suggestedSkills: ['hardware_diagnosis', 'soldering', 'cleaning'],
|
||||
defaultTitle: 'Konsolen-Hilfe benötigt',
|
||||
defaultDescription: 'Meine Spielkonsole hat folgendes Problem:\n\n- \n\nKonsole: \nAlter: ca. ',
|
||||
@@ -538,9 +538,9 @@ export function deriveBudgetType(amountCents: number | null | undefined): 'free'
|
||||
}
|
||||
|
||||
export const REQUEST_STATUSES: RequestStatus[] = [
|
||||
{ id: REQUEST_STATUS.OPEN, name: 'Offen', description: 'Anfrage ist offen für Angebote', badgeClass: 'bg-primary-100 dark:bg-primary-900/30 text-primary-700 dark:text-primary-300' },
|
||||
{ id: REQUEST_STATUS.MATCHED, name: 'Vergeben', description: 'Angebot akzeptiert, Hilfe läuft', badgeClass: 'bg-primary-100 dark:bg-primary-900/30 text-primary-700 dark:text-primary-300' },
|
||||
{ id: REQUEST_STATUS.COMPLETED, name: 'Abgeschlossen', description: 'Erfolgreich abgeschlossen', badgeClass: 'bg-primary-100 dark:bg-primary-900/30 text-primary-700 dark:text-primary-300' },
|
||||
{ id: REQUEST_STATUS.OPEN, name: 'Offen', description: 'Anfrage ist offen für Angebote', badgeClass: 'bg-success-100 dark:bg-success-900/30 text-success-700 dark:text-success-300' },
|
||||
{ id: REQUEST_STATUS.MATCHED, name: 'Vergeben', description: 'Angebot akzeptiert, Hilfe läuft', badgeClass: 'bg-success-100 dark:bg-success-900/30 text-success-700 dark:text-success-300' },
|
||||
{ id: REQUEST_STATUS.COMPLETED, name: 'Abgeschlossen', description: 'Erfolgreich abgeschlossen', badgeClass: 'bg-success-100 dark:bg-success-900/30 text-success-700 dark:text-success-300' },
|
||||
{ id: REQUEST_STATUS.CANCELLED, name: 'Abgebrochen', description: 'Anfrage wurde abgebrochen', badgeClass: 'bg-neutral-100 text-neutral-500' },
|
||||
{ id: REQUEST_STATUS.EXPIRED, name: 'Abgelaufen', description: 'Frist abgelaufen — keine Angebote erhalten', badgeClass: 'bg-neutral-100 text-neutral-500' },
|
||||
]
|
||||
@@ -566,7 +566,7 @@ export type OfferStatusId = typeof OFFER_STATUS[keyof typeof OFFER_STATUS];
|
||||
|
||||
export const OFFER_STATUSES: OfferStatus[] = [
|
||||
{ id: OFFER_STATUS.PENDING, name: 'Ausstehend', badgeClass: 'bg-warning-100 dark:bg-warning-900/30 text-warning-700 dark:text-warning-200' },
|
||||
{ id: OFFER_STATUS.ACCEPTED, name: 'Akzeptiert', badgeClass: 'bg-primary-100 dark:bg-primary-900/30 text-primary-700 dark:text-primary-300' },
|
||||
{ id: OFFER_STATUS.ACCEPTED, name: 'Akzeptiert', badgeClass: 'bg-success-100 dark:bg-success-900/30 text-success-700 dark:text-success-300' },
|
||||
{ id: OFFER_STATUS.REJECTED, name: 'Abgelehnt', badgeClass: 'bg-error-100 text-error-700' },
|
||||
{ id: OFFER_STATUS.WITHDRAWN, name: 'Zurückgezogen', badgeClass: 'bg-neutral-100 text-neutral-500' },
|
||||
]
|
||||
|
||||
@@ -28,7 +28,7 @@ export function getLocationStatusLabel(status: string): string {
|
||||
}
|
||||
|
||||
export const LOCATION_STATUS_COLORS: Record<string, string> = {
|
||||
[LOCATION_STATUS.APPROVED]: 'bg-primary-100 dark:bg-primary-900/30 text-primary-800 dark:text-primary-300',
|
||||
[LOCATION_STATUS.APPROVED]: 'bg-success-100 dark:bg-success-900/30 text-success-800 dark:text-success-300',
|
||||
[LOCATION_STATUS.PENDING]: 'bg-warning-100 dark:bg-warning-900/30 text-warning-800 dark:text-warning-200',
|
||||
[LOCATION_STATUS.REJECTED]: 'bg-error-100 text-error-800',
|
||||
[LOCATION_STATUS.SUSPENDED]: 'bg-orange-100 text-orange-800',
|
||||
|
||||
@@ -19,7 +19,7 @@ export const MARKETPLACE_STATUS_LABELS: Record<string, string> = {
|
||||
}
|
||||
|
||||
export const MARKETPLACE_STATUS_BADGES: Record<string, string> = {
|
||||
[MARKETPLACE_STATUS.PUBLISHED]: 'bg-primary-100 dark:bg-primary-900/30 text-primary-800 dark:text-primary-300',
|
||||
[MARKETPLACE_STATUS.PUBLISHED]: 'bg-success-100 dark:bg-success-900/30 text-success-800 dark:text-success-300',
|
||||
[MARKETPLACE_STATUS.DRAFT]: 'bg-warning-100 dark:bg-warning-900/30 text-warning-800 dark:text-warning-200',
|
||||
}
|
||||
|
||||
@@ -57,7 +57,7 @@ export const PRODUCT_STATUS_LABELS: Record<string, string> = {
|
||||
}
|
||||
|
||||
export const PRODUCT_STATUS_BADGES: Record<string, string> = {
|
||||
[PRODUCT_STATUS.APPROVED]: 'bg-primary-100 dark:bg-primary-900/30 text-primary-800 dark:text-primary-300',
|
||||
[PRODUCT_STATUS.APPROVED]: 'bg-success-100 dark:bg-success-900/30 text-success-800 dark:text-success-300',
|
||||
[PRODUCT_STATUS.PENDING_REVIEW]: 'bg-orange-100 text-orange-800',
|
||||
[PRODUCT_STATUS.REJECTED]: 'bg-error-100 text-error-800',
|
||||
}
|
||||
|
||||
@@ -330,7 +330,7 @@ export const VERIFICATION_CONFIG = {
|
||||
label: 'Geprüft von evig',
|
||||
shortLabel: 'Geprüft',
|
||||
color: UI_STATUS.success,
|
||||
borderColor: 'border-primary-200 dark:border-primary-800',
|
||||
borderColor: 'border-success-200 dark:border-success-800',
|
||||
},
|
||||
} as const;
|
||||
|
||||
|
||||
@@ -67,13 +67,13 @@ export interface OSSAlternative {
|
||||
// ---------------------------------------------------------------------------
|
||||
|
||||
export const MATURITY_CONFIG: Record<Maturity, { label: string; color: string }> = {
|
||||
established: { label: 'Etabliert', color: 'bg-primary-100 dark:bg-primary-900/30 text-primary-800 dark:text-primary-300' },
|
||||
established: { label: 'Etabliert', color: 'bg-success-100 dark:bg-success-900/30 text-success-800 dark:text-success-300' },
|
||||
growing: { label: 'Wachsend', color: 'bg-neutral-100 text-neutral-800' },
|
||||
emerging: { label: 'Aufkommend', color: 'bg-warning-100 dark:bg-warning-900/30 text-warning-800 dark:text-warning-200' },
|
||||
}
|
||||
|
||||
export const MIGRATION_DIFFICULTY_CONFIG: Record<MigrationDifficulty, { label: string; color: string; description: string }> = {
|
||||
easy: { label: 'Einfach', color: 'bg-primary-100 dark:bg-primary-900/30 text-primary-800 dark:text-primary-300', description: 'Direkter Umstieg, kaum Einarbeitung nötig' },
|
||||
easy: { label: 'Einfach', color: 'bg-success-100 dark:bg-success-900/30 text-success-800 dark:text-success-300', description: 'Direkter Umstieg, kaum Einarbeitung nötig' },
|
||||
medium: { label: 'Mittel', color: 'bg-warning-100 dark:bg-warning-900/30 text-warning-800 dark:text-warning-200', description: 'Etwas Einarbeitung nötig, aber machbar' },
|
||||
advanced: { label: 'Anspruchsvoll', color: 'bg-error-100 text-error-800', description: 'Deutliche Unterschiede, Einarbeitung erforderlich' },
|
||||
}
|
||||
|
||||
@@ -29,9 +29,9 @@ export const MEETING_TYPE_LABELS: Record<MeetingType, string> = {
|
||||
};
|
||||
|
||||
export const MEETING_TYPE_COLORS: Record<MeetingType, string> = {
|
||||
team_weekly: 'bg-primary-100 dark:bg-primary-900/30 text-primary-800 dark:text-primary-300',
|
||||
team_weekly: 'bg-success-100 dark:bg-success-900/30 text-success-800 dark:text-success-300',
|
||||
project_review: 'bg-purple-100 text-purple-800',
|
||||
retro: 'bg-primary-100 dark:bg-primary-900/30 text-primary-800 dark:text-primary-300',
|
||||
retro: 'bg-success-100 dark:bg-success-900/30 text-success-800 dark:text-success-300',
|
||||
board: 'bg-orange-100 text-orange-800',
|
||||
ad_hoc: 'bg-neutral-100 text-neutral-800',
|
||||
};
|
||||
@@ -105,7 +105,7 @@ export const PROTOCOL_STATUS_COLORS: Record<ProtocolStatus, string> = {
|
||||
draft: 'bg-neutral-100 text-neutral-800',
|
||||
processing: 'bg-warning-100 dark:bg-warning-900/30 text-warning-800 dark:text-warning-200',
|
||||
review: 'bg-warning-100 dark:bg-warning-900/30 text-warning-800 dark:text-warning-200',
|
||||
finalized: 'bg-primary-100 dark:bg-primary-900/30 text-primary-800 dark:text-primary-300',
|
||||
finalized: 'bg-success-100 dark:bg-success-900/30 text-success-800 dark:text-success-300',
|
||||
};
|
||||
|
||||
// Visibility options
|
||||
@@ -133,20 +133,20 @@ export const ACTION_ITEM_TYPE_LABELS: Record<ActionItemType, string> = {
|
||||
};
|
||||
|
||||
export const ACTION_ITEM_TYPE_COLORS: Record<ActionItemType, string> = {
|
||||
task: 'bg-primary-100 dark:bg-primary-900/30 text-primary-800 dark:text-primary-300',
|
||||
task: 'bg-success-100 dark:bg-success-900/30 text-success-800 dark:text-success-300',
|
||||
decision: 'bg-purple-100 text-purple-800',
|
||||
info: 'bg-neutral-100 text-neutral-800',
|
||||
};
|
||||
|
||||
export const ACTION_ITEM_BORDER_COLORS: Record<ActionItemType, string> = {
|
||||
task: 'border-l-4 border-l-primary-400',
|
||||
task: 'border-l-4 border-l-success-400',
|
||||
decision: 'border-l-4 border-l-purple-400',
|
||||
info: 'border-l-4 border-l-neutral-300',
|
||||
};
|
||||
|
||||
export const FOLLOW_UP_STATUS_COLORS: Record<string, string> = {
|
||||
erledigt: 'bg-primary-100 dark:bg-primary-900/30 text-primary-800 dark:text-primary-300',
|
||||
'in Arbeit': 'bg-primary-100 dark:bg-primary-900/30 text-primary-800 dark:text-primary-300',
|
||||
erledigt: 'bg-success-100 dark:bg-success-900/30 text-success-800 dark:text-success-300',
|
||||
'in Arbeit': 'bg-success-100 dark:bg-success-900/30 text-success-800 dark:text-success-300',
|
||||
offen: 'bg-warning-100 dark:bg-warning-900/30 text-warning-800 dark:text-warning-200',
|
||||
};
|
||||
|
||||
@@ -217,7 +217,7 @@ export const DECISION_RESULT_LABELS: Record<DecisionResult, string> = {
|
||||
};
|
||||
|
||||
export const DECISION_RESULT_COLORS: Record<DecisionResult, string> = {
|
||||
approved: 'bg-primary-100 dark:bg-primary-900/30 text-primary-800 dark:text-primary-300',
|
||||
approved: 'bg-success-100 dark:bg-success-900/30 text-success-800 dark:text-success-300',
|
||||
rejected: 'bg-error-100 text-error-800',
|
||||
pending: 'bg-warning-100 dark:bg-warning-900/30 text-warning-800 dark:text-warning-200',
|
||||
};
|
||||
|
||||
@@ -24,7 +24,7 @@ export const REVIEW_STATUS_LABELS: Record<string, string> = {
|
||||
}
|
||||
|
||||
export const REVIEW_STATUS_BADGES: Record<string, string> = {
|
||||
[REVIEW_STATUS.PUBLISHED]: 'bg-primary-100 dark:bg-primary-900/30 text-primary-800 dark:text-primary-300',
|
||||
[REVIEW_STATUS.PUBLISHED]: 'bg-success-100 dark:bg-success-900/30 text-success-800 dark:text-success-300',
|
||||
[REVIEW_STATUS.PENDING_MODERATION]: 'bg-orange-100 text-orange-800',
|
||||
[REVIEW_STATUS.HIDDEN]: 'bg-error-100 text-error-800',
|
||||
[REVIEW_STATUS.DELETED]: 'bg-neutral-100 text-neutral-800',
|
||||
|
||||
@@ -36,42 +36,42 @@ export interface CategoryStyle {
|
||||
*/
|
||||
export const CATEGORY_STYLES: Record<ServiceCategory, CategoryStyle> = {
|
||||
repair: {
|
||||
primary: 'primary-600',
|
||||
bgLight: 'primary-50',
|
||||
bgDark: 'primary-900/20',
|
||||
primary: 'success-600',
|
||||
bgLight: 'success-50',
|
||||
bgDark: 'success-900/20',
|
||||
textOnPrimary: 'white',
|
||||
gradient: 'from-primary-600 to-primary-800',
|
||||
gradient: 'from-success-600 to-success-800',
|
||||
badge: {
|
||||
bg: 'bg-primary-100',
|
||||
text: 'text-primary-800',
|
||||
bgDark: 'dark:bg-primary-900/30',
|
||||
textDark: 'dark:text-primary-300',
|
||||
bg: 'bg-success-100',
|
||||
text: 'text-success-800',
|
||||
bgDark: 'dark:bg-success-900/30',
|
||||
textDark: 'dark:text-success-300',
|
||||
},
|
||||
},
|
||||
data: {
|
||||
primary: 'primary-600',
|
||||
bgLight: 'primary-50',
|
||||
bgDark: 'primary-900/20',
|
||||
primary: 'success-600',
|
||||
bgLight: 'success-50',
|
||||
bgDark: 'success-900/20',
|
||||
textOnPrimary: 'white',
|
||||
gradient: 'from-primary-600 to-primary-800',
|
||||
gradient: 'from-success-600 to-success-800',
|
||||
badge: {
|
||||
bg: 'bg-primary-100',
|
||||
text: 'text-primary-800',
|
||||
bgDark: 'dark:bg-primary-900/30',
|
||||
textDark: 'dark:text-primary-300',
|
||||
bg: 'bg-success-100',
|
||||
text: 'text-success-800',
|
||||
bgDark: 'dark:bg-success-900/30',
|
||||
textDark: 'dark:text-success-300',
|
||||
},
|
||||
},
|
||||
recycling: {
|
||||
primary: 'primary-600',
|
||||
bgLight: 'primary-50',
|
||||
bgDark: 'primary-900/20',
|
||||
primary: 'success-600',
|
||||
bgLight: 'success-50',
|
||||
bgDark: 'success-900/20',
|
||||
textOnPrimary: 'white',
|
||||
gradient: 'from-primary-600 to-primary-800',
|
||||
gradient: 'from-success-600 to-success-800',
|
||||
badge: {
|
||||
bg: 'bg-primary-100',
|
||||
text: 'text-primary-800',
|
||||
bgDark: 'dark:bg-primary-900/30',
|
||||
textDark: 'dark:text-primary-300',
|
||||
bg: 'bg-success-100',
|
||||
text: 'text-success-800',
|
||||
bgDark: 'dark:bg-success-900/30',
|
||||
textDark: 'dark:text-success-300',
|
||||
},
|
||||
},
|
||||
software: {
|
||||
|
||||
+2
-2
@@ -139,10 +139,10 @@ export type RequestStatus = (typeof REQUEST_STATUSES)[keyof typeof REQUEST_STATU
|
||||
|
||||
// Color maps for UI badges (SSOT for status/priority colors)
|
||||
export const TASK_STATUS_COLORS: Record<TaskStatus, string> = {
|
||||
idle: 'bg-primary-100 dark:bg-primary-900/30 text-primary-800 dark:text-primary-300',
|
||||
idle: 'bg-success-100 dark:bg-success-900/30 text-success-800 dark:text-success-300',
|
||||
needs_attention: 'bg-error-100 text-error-800',
|
||||
requested: 'bg-warning-100 dark:bg-warning-900/30 text-warning-800 dark:text-warning-200',
|
||||
in_progress: 'bg-primary-100 dark:bg-primary-900/30 text-primary-800 dark:text-primary-300',
|
||||
in_progress: 'bg-success-100 dark:bg-success-900/30 text-success-800 dark:text-success-300',
|
||||
};
|
||||
|
||||
// SSOT for project-status badge colors — was duplicated byte-for-byte in
|
||||
|
||||
+3
-3
@@ -31,7 +31,7 @@ export const EMPLOYMENT_TYPE_LABELS: Record<EmploymentType, string> = {
|
||||
|
||||
export const EMPLOYMENT_TYPE_COLORS: Record<EmploymentType, string> = {
|
||||
employee: 'bg-neutral-100 text-neutral-800 dark:bg-neutral-700 dark:text-neutral-300',
|
||||
volunteer: 'bg-primary-100 text-primary-800 dark:bg-primary-900/30 dark:text-primary-300',
|
||||
volunteer: 'bg-success-100 text-success-800 dark:bg-success-900/30 dark:text-success-300',
|
||||
intern: 'bg-purple-100 text-purple-800 dark:bg-purple-900/30 dark:text-purple-300',
|
||||
contractor: 'bg-orange-100 text-orange-800 dark:bg-orange-900/30 dark:text-orange-300',
|
||||
}
|
||||
@@ -69,7 +69,7 @@ export const DEPARTMENT_COLORS: Record<Department, string> = {
|
||||
Werkstatt: 'bg-warning-100 text-warning-800 dark:bg-warning-900/30 dark:text-warning-300',
|
||||
Verwaltung: 'bg-slate-100 text-slate-800 dark:bg-slate-900/30 dark:text-slate-300',
|
||||
Marketing: 'bg-pink-100 text-pink-800 dark:bg-pink-900/30 dark:text-pink-300',
|
||||
Verkauf: 'bg-primary-100 text-primary-800 dark:bg-primary-900/30 dark:text-primary-300',
|
||||
Verkauf: 'bg-success-100 text-success-800 dark:bg-success-900/30 dark:text-success-300',
|
||||
Bildung: 'bg-cyan-100 text-cyan-800 dark:bg-cyan-900/30 dark:text-cyan-300',
|
||||
Logistik: 'bg-rose-100 text-rose-800 dark:bg-rose-900/30 dark:text-rose-300',
|
||||
}
|
||||
@@ -99,7 +99,7 @@ export const WORK_STATE_LABELS: Record<WorkState, string> = {
|
||||
}
|
||||
|
||||
export const WORK_STATE_COLORS: Record<WorkState, string> = {
|
||||
active: 'bg-primary-100 text-primary-800 dark:bg-primary-900/30 dark:text-primary-300',
|
||||
active: 'bg-success-100 text-success-800 dark:bg-success-900/30 dark:text-success-300',
|
||||
on_leave: 'bg-warning-100 text-warning-800 dark:bg-warning-900/30 dark:text-warning-300',
|
||||
unavailable: 'bg-neutral-200 text-neutral-700 dark:bg-neutral-700 dark:text-neutral-300',
|
||||
inactive: 'bg-neutral-100 text-neutral-500 dark:bg-neutral-800 dark:text-neutral-400',
|
||||
|
||||
@@ -7,7 +7,7 @@
|
||||
*/
|
||||
|
||||
export const UI_STATUS = {
|
||||
success: 'bg-primary-100 text-primary-800 dark:bg-primary-900/30 dark:text-primary-300',
|
||||
success: 'bg-success-100 text-success-800 dark:bg-success-900/30 dark:text-success-300',
|
||||
warning: 'bg-warning-100 text-warning-800 dark:bg-warning-900/30 dark:text-warning-300',
|
||||
danger: 'bg-error-100 text-error-800 dark:bg-error-900/30 dark:text-error-300',
|
||||
info: 'bg-neutral-100 text-neutral-700 dark:bg-neutral-700 dark:text-neutral-300',
|
||||
|
||||
@@ -25,10 +25,10 @@ export const WORKSHOP_REGISTRATION_STATUS_LABELS: Record<string, string> = {
|
||||
};
|
||||
|
||||
export const WORKSHOP_REGISTRATION_STATUS_COLORS: Record<string, string> = {
|
||||
[WORKSHOP_REGISTRATION_STATUS.CONFIRMED]: 'bg-primary-100 dark:bg-primary-900/30 text-primary-800 dark:text-primary-300',
|
||||
[WORKSHOP_REGISTRATION_STATUS.CONFIRMED]: 'bg-success-100 dark:bg-success-900/30 text-success-800 dark:text-success-300',
|
||||
[WORKSHOP_REGISTRATION_STATUS.PENDING]: 'bg-warning-100 dark:bg-warning-900/30 text-warning-800 dark:text-warning-200',
|
||||
[WORKSHOP_REGISTRATION_STATUS.CANCELLED]: 'bg-error-100 text-error-800',
|
||||
[WORKSHOP_REGISTRATION_STATUS.ATTENDED]: 'bg-primary-100 dark:bg-primary-900/30 text-primary-800 dark:text-primary-300',
|
||||
[WORKSHOP_REGISTRATION_STATUS.ATTENDED]: 'bg-success-100 dark:bg-success-900/30 text-success-800 dark:text-success-300',
|
||||
[WORKSHOP_REGISTRATION_STATUS.NO_SHOW]: 'bg-neutral-100 text-neutral-800',
|
||||
[WORKSHOP_REGISTRATION_STATUS.WAITLIST]: 'bg-neutral-100 text-neutral-600',
|
||||
};
|
||||
@@ -58,7 +58,7 @@ export const WORKSHOP_PAYMENT_STATUS_LABELS: Record<string, string> = {
|
||||
};
|
||||
|
||||
export const WORKSHOP_PAYMENT_STATUS_COLORS: Record<string, string> = {
|
||||
[WORKSHOP_PAYMENT_STATUS.PAID]: 'bg-primary-100 dark:bg-primary-900/30 text-primary-800 dark:text-primary-300',
|
||||
[WORKSHOP_PAYMENT_STATUS.PAID]: 'bg-success-100 dark:bg-success-900/30 text-success-800 dark:text-success-300',
|
||||
[WORKSHOP_PAYMENT_STATUS.PENDING]: 'bg-warning-100 dark:bg-warning-900/30 text-warning-800 dark:text-warning-200',
|
||||
[WORKSHOP_PAYMENT_STATUS.REFUNDED]: 'bg-purple-100 text-purple-800',
|
||||
[WORKSHOP_PAYMENT_STATUS.NOT_REQUIRED]: 'bg-neutral-100 text-neutral-600',
|
||||
|
||||
@@ -66,7 +66,7 @@ export const WORKSHOP_CATEGORIES: WorkshopCategory[] = [
|
||||
description:
|
||||
"Betriebssysteme, Terminal, Server-Administration und Open-Source-Tools.",
|
||||
icon: BookOpen,
|
||||
color: "bg-primary-500",
|
||||
color: "bg-success-500",
|
||||
},
|
||||
{
|
||||
id: "hardware",
|
||||
@@ -122,7 +122,7 @@ export const WORKSHOP_CATEGORIES: WorkshopCategory[] = [
|
||||
description:
|
||||
"Nachhaltige IT: Reparieren statt wegwerfen, Energie sparen, E-Waste vermeiden.",
|
||||
icon: Leaf,
|
||||
color: "bg-primary-500",
|
||||
color: "bg-success-500",
|
||||
},
|
||||
{
|
||||
id: "digital-skills",
|
||||
@@ -141,7 +141,7 @@ export const WORKSHOP_LEVELS: WorkshopLevel[] = [
|
||||
{
|
||||
id: "beginner",
|
||||
name: "Anfänger",
|
||||
badgeClass: "bg-primary-100 dark:bg-primary-900/30 text-primary-800 dark:text-primary-300",
|
||||
badgeClass: "bg-success-100 dark:bg-success-900/30 text-success-800 dark:text-success-300",
|
||||
},
|
||||
{
|
||||
id: "intermediate",
|
||||
@@ -179,9 +179,9 @@ export const WORKSHOP_INSTANCE_STATUS_LABELS: Record<WorkshopInstanceStatus, str
|
||||
};
|
||||
|
||||
export const WORKSHOP_INSTANCE_STATUS_COLORS: Record<WorkshopInstanceStatus, string> = {
|
||||
[WORKSHOP_INSTANCE_STATUS.SCHEDULED]: 'bg-primary-100 dark:bg-primary-900/30 text-primary-800 dark:text-primary-300',
|
||||
[WORKSHOP_INSTANCE_STATUS.SCHEDULED]: 'bg-success-100 dark:bg-success-900/30 text-success-800 dark:text-success-300',
|
||||
[WORKSHOP_INSTANCE_STATUS.CANCELLED]: 'bg-error-100 text-error-800',
|
||||
[WORKSHOP_INSTANCE_STATUS.COMPLETED]: 'bg-primary-100 dark:bg-primary-900/30 text-primary-800 dark:text-primary-300',
|
||||
[WORKSHOP_INSTANCE_STATUS.COMPLETED]: 'bg-success-100 dark:bg-success-900/30 text-success-800 dark:text-success-300',
|
||||
};
|
||||
|
||||
/**
|
||||
|
||||
+1
-1
@@ -65,7 +65,7 @@ export const aboutConfig: AboutPageConfig = {
|
||||
hero: {
|
||||
title: 'Technik ein zweites Leben geben',
|
||||
description: `Seit über ${new Date().getFullYear() - getDefaultNumeric('founding_year')} Jahren setzen wir uns gegen die vorschnelle Ausmusterung von Computern ein und fördern nachhaltige IT-Praktiken.`,
|
||||
backgroundColor: 'bg-primary-700',
|
||||
backgroundColor: 'bg-action',
|
||||
ctas: [
|
||||
{
|
||||
text: 'Mitmachen',
|
||||
|
||||
@@ -466,9 +466,9 @@ describe('handleFileSelect', () => {
|
||||
|
||||
describe('getConfidenceColor', () => {
|
||||
it('high confidence (>=0.9) → green', () => {
|
||||
expect(getConfidenceColor(0.95)).toBe('text-primary-600')
|
||||
expect(getConfidenceColor(0.9)).toBe('text-primary-600') // boundary inclusive
|
||||
expect(getConfidenceColor(1)).toBe('text-primary-600')
|
||||
expect(getConfidenceColor(0.95)).toBe('text-success-600')
|
||||
expect(getConfidenceColor(0.9)).toBe('text-success-600') // boundary inclusive
|
||||
expect(getConfidenceColor(1)).toBe('text-success-600')
|
||||
})
|
||||
|
||||
it('medium confidence (0.7 to 0.9) → warning', () => {
|
||||
|
||||
@@ -189,7 +189,7 @@ export function useAIProductAnalysis(options: UseAIProductAnalysisOptions = {})
|
||||
|
||||
/** Utility: confidence level color */
|
||||
export function getConfidenceColor(confidence: number): string {
|
||||
if (confidence >= 0.9) return 'text-primary-600'
|
||||
if (confidence >= 0.9) return 'text-success-600'
|
||||
if (confidence >= 0.7) return 'text-warning-600'
|
||||
return 'text-error-600'
|
||||
}
|
||||
@@ -96,8 +96,8 @@ describe('getBackgroundColor', () => {
|
||||
expect(getBackgroundColor('neutral')).toBe('bg-surface-raised')
|
||||
})
|
||||
|
||||
it('returns bg-primary-600 for primary', () => {
|
||||
expect(getBackgroundColor('primary')).toBe('bg-primary-600')
|
||||
it('returns bg-action for primary', () => {
|
||||
expect(getBackgroundColor('primary')).toBe('bg-action')
|
||||
})
|
||||
|
||||
it('returns bg-secondary-500 for secondary', () => {
|
||||
@@ -134,8 +134,8 @@ describe('getBorderColor', () => {
|
||||
expect(getBorderColor('neutral')).toBe('border-default')
|
||||
})
|
||||
|
||||
it('returns border-primary-700 for primary', () => {
|
||||
expect(getBorderColor('primary')).toBe('border-primary-700')
|
||||
it('returns border-action for primary', () => {
|
||||
expect(getBorderColor('primary')).toBe('border-action')
|
||||
})
|
||||
|
||||
it('returns border-subtle for dark background', () => {
|
||||
@@ -202,9 +202,9 @@ describe('getStatusColors', () => {
|
||||
describe('getButtonVariant', () => {
|
||||
it('returns primary button classes', () => {
|
||||
const result = getButtonVariant('primary')
|
||||
expect(result.bg).toBe('bg-action')
|
||||
expect(result.text).toBe('text-action-text')
|
||||
expect(result.hover).toBe('hover:bg-action-hover')
|
||||
expect(result.bg).toBe('bg-action-strong')
|
||||
expect(result.text).toBe('text-action-strong-text')
|
||||
expect(result.hover).toBe('hover:opacity-90')
|
||||
})
|
||||
|
||||
it('returns secondary button classes', () => {
|
||||
|
||||
+1
-1
@@ -96,7 +96,7 @@ export const adminIconBox = {
|
||||
// Keys are kept for API stability; the non-semantic ones now render neutral.
|
||||
const NEUTRAL_ICON = 'bg-neutral-100 text-neutral-600 dark:bg-neutral-500/12 dark:text-neutral-400'
|
||||
export const adminIconColor = {
|
||||
green: 'bg-primary-100 text-primary-600 dark:bg-primary-500/12 dark:text-primary-400',
|
||||
green: 'bg-success-100 text-success-600 dark:bg-success-500/12 dark:text-success-400',
|
||||
amber: 'bg-warning-100 text-warning-600 dark:bg-warning-500/12 dark:text-warning-400',
|
||||
red: 'bg-error-100 text-error-600 dark:bg-error-500/12 dark:text-error-400',
|
||||
blue: NEUTRAL_ICON,
|
||||
|
||||
@@ -50,9 +50,9 @@ export const contrastSafeColors = {
|
||||
// Primary green backgrounds
|
||||
primary: {
|
||||
text: {
|
||||
primary: 'text-white', // White on green
|
||||
secondary: 'text-primary-50', // Very light green
|
||||
muted: 'text-primary-100',
|
||||
primary: 'text-white', // White on the action fill
|
||||
secondary: 'text-white/90',
|
||||
muted: 'text-white/75',
|
||||
inverse: 'text-white',
|
||||
onPrimary: 'text-white',
|
||||
},
|
||||
@@ -387,7 +387,7 @@ export const designPrimitive = {
|
||||
secondary: 'border-transparent bg-surface-raised text-text-secondary',
|
||||
destructive: 'border-transparent bg-error-600 text-white',
|
||||
outline: 'border-subtle text-text-secondary',
|
||||
success: 'border-primary-200 bg-primary-50 text-primary-800 dark:border-primary-500/30 dark:bg-primary-500/10 dark:text-primary-400',
|
||||
success: 'border-success-200 bg-success-50 text-success-800 dark:border-success-500/30 dark:bg-success-500/10 dark:text-success-400',
|
||||
warning: 'border-warning-200 bg-warning-50 text-warning-800 dark:border-warning-500/30 dark:bg-warning-500/10 dark:text-warning-400',
|
||||
info: 'border-neutral-200 bg-neutral-50 text-neutral-800 dark:border-neutral-500/30 dark:bg-neutral-500/10 dark:text-neutral-400',
|
||||
},
|
||||
|
||||
@@ -493,9 +493,9 @@ export const THREE_PILLARS: Record<PillarId, Pillar> = {
|
||||
name: 'Umwelt',
|
||||
motto: 'Alte Computer',
|
||||
icon: '🌍',
|
||||
color: 'text-primary-800 dark:text-primary-300',
|
||||
bgColor: 'bg-primary-50 dark:bg-primary-900/20',
|
||||
borderColor: 'border-primary-200',
|
||||
color: 'text-success-800 dark:text-success-300',
|
||||
bgColor: 'bg-success-50 dark:bg-success-900/20',
|
||||
borderColor: 'border-success-200',
|
||||
description: 'Durch die Wiederverwendung von IT-Geräten vermeiden wir E-Waste und reduzieren den Ressourcenverbrauch.',
|
||||
dimensions: ['Umweltwirkung'],
|
||||
methodologies: ['device_co2_avoided', 'device_lifetime_extension', 'material_recovery', 'ewaste_prevention'],
|
||||
@@ -517,9 +517,9 @@ export const THREE_PILLARS: Record<PillarId, Pillar> = {
|
||||
name: 'Bildung',
|
||||
motto: 'Bessere Zukunft',
|
||||
icon: '📚',
|
||||
color: 'text-primary-800 dark:text-primary-300',
|
||||
bgColor: 'bg-primary-50 dark:bg-primary-900/20',
|
||||
borderColor: 'border-primary-200',
|
||||
color: 'text-success-800 dark:text-success-300',
|
||||
bgColor: 'bg-success-50 dark:bg-success-900/20',
|
||||
borderColor: 'border-success-200',
|
||||
description: '"Knowhow" ist Teil unseres Mottos. Wir vermitteln IT-Kompetenzen durch praktische Arbeit, Workshops und Linux-Schulungen.',
|
||||
dimensions: ['Bildungswirkung'],
|
||||
methodologies: ['education_transfer', 'workshop_impact', 'linux_adoption'],
|
||||
@@ -620,8 +620,8 @@ export const CONFIDENCE_LEVELS: Record<ConfidenceLevel, ConfidenceLevelDefinitio
|
||||
level: 'high',
|
||||
name: 'Hoch',
|
||||
description: 'Direkt gemessen oder aus geprüften Daten berechnet',
|
||||
color: 'text-primary-800 dark:text-primary-300',
|
||||
bgColor: 'bg-primary-100 dark:bg-primary-900/30',
|
||||
color: 'text-success-800 dark:text-success-300',
|
||||
bgColor: 'bg-success-100 dark:bg-success-900/30',
|
||||
requirements: [
|
||||
'Daten aus primärer Quelle (z.B. Buchhaltung, direktes Tracking)',
|
||||
'Vollständige Dokumentation der Erhebung',
|
||||
|
||||
Reference in new issue
Block a user