Skip to content

Commit 839a59c

Browse files
committed
feat: update PriorityBadge and StatusBadge styles for improved visibility; add dependency in turbo.json
1 parent bb85e35 commit 839a59c

File tree

3 files changed

+22
-17
lines changed

3 files changed

+22
-17
lines changed

packages/ui-vite/src/components/PriorityBadge.tsx

Lines changed: 10 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -10,26 +10,26 @@ interface PriorityBadgeProps {
1010
}
1111

1212
const priorityConfig: Record<string, { icon: typeof AlertCircle; labelKey: `priority.${string}`; className: string }> = {
13-
critical: {
13+
'critical': {
1414
icon: AlertCircle,
1515
labelKey: 'priority.critical',
16-
className: 'bg-red-500/20 text-red-700 dark:text-red-300 border border-red-200/60 dark:border-red-400/40',
16+
className: 'bg-red-100 text-red-800 dark:bg-red-900/30 dark:text-red-400'
1717
},
18-
high: {
18+
'high': {
1919
icon: ArrowUp,
2020
labelKey: 'priority.high',
21-
className: 'bg-orange-500/20 text-orange-700 dark:text-orange-300 border border-orange-200/60 dark:border-orange-400/40',
21+
className: 'bg-orange-100 text-orange-800 dark:bg-orange-900/30 dark:text-orange-400'
2222
},
23-
medium: {
23+
'medium': {
2424
icon: Minus,
2525
labelKey: 'priority.medium',
26-
className: 'bg-blue-500/20 text-blue-600 dark:text-blue-300 border border-blue-200/60 dark:border-blue-400/40',
26+
className: 'bg-blue-100 text-blue-800 dark:bg-blue-900/30 dark:text-blue-400'
2727
},
28-
low: {
28+
'low': {
2929
icon: ArrowDown,
3030
labelKey: 'priority.low',
31-
className: 'bg-gray-500/20 text-gray-600 dark:text-gray-300 border border-gray-200/60 dark:border-gray-500/40',
32-
},
31+
className: 'bg-gray-100 text-gray-800 dark:bg-gray-800 dark:text-gray-400'
32+
}
3333
};
3434

3535
export function getPriorityLabel(priority: string, t: (key: string) => string) {
@@ -44,6 +44,7 @@ export function PriorityBadge({ priority, className, iconOnly = false }: Priorit
4444

4545
return (
4646
<Badge
47+
variant="outline"
4748
className={cn(
4849
'flex items-center w-fit h-5 px-2 py-0.5 text-xs font-medium',
4950
!iconOnly && 'gap-1.5',

packages/ui-vite/src/components/StatusBadge.tsx

Lines changed: 9 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -10,26 +10,26 @@ interface StatusBadgeProps {
1010
}
1111

1212
const statusConfig: Record<string, { icon: typeof Clock; labelKey: `status.${string}`; className: string }> = {
13-
planned: {
13+
'planned': {
1414
icon: Clock,
1515
labelKey: 'status.planned',
16-
className: 'bg-blue-500/20 text-blue-700 dark:text-blue-300 border border-blue-200/60 dark:border-blue-400/40',
16+
className: 'bg-blue-100 text-blue-800 dark:bg-blue-900/30 dark:text-blue-400'
1717
},
1818
'in-progress': {
1919
icon: PlayCircle,
2020
labelKey: 'status.inProgress',
21-
className: 'bg-orange-500/20 text-orange-700 dark:text-orange-300 border border-orange-200/60 dark:border-orange-400/40',
21+
className: 'bg-orange-100 text-orange-800 dark:bg-orange-900/30 dark:text-orange-400'
2222
},
23-
complete: {
23+
'complete': {
2424
icon: CheckCircle2,
2525
labelKey: 'status.complete',
26-
className: 'bg-green-500/20 text-green-700 dark:text-green-300 border border-green-200/60 dark:border-green-400/40',
26+
className: 'bg-green-100 text-green-800 dark:bg-green-900/30 dark:text-green-400'
2727
},
28-
archived: {
28+
'archived': {
2929
icon: Archive,
3030
labelKey: 'status.archived',
31-
className: 'bg-gray-500/20 text-gray-600 dark:text-gray-300 border border-gray-200/60 dark:border-gray-500/40',
32-
},
31+
className: 'bg-gray-100 text-gray-800 dark:bg-gray-800 dark:text-gray-400'
32+
}
3333
};
3434

3535
export function getStatusLabel(status: string, t: (key: string) => string) {
@@ -44,6 +44,7 @@ export function StatusBadge({ status, className, iconOnly = false }: StatusBadge
4444

4545
return (
4646
<Badge
47+
variant="outline"
4748
className={cn(
4849
'flex items-center w-fit h-5 px-2 py-0.5 text-xs font-medium',
4950
!iconOnly && 'gap-1.5',

turbo.json

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,9 @@
1919
]
2020
},
2121
"dev": {
22+
"dependsOn": [
23+
"@leanspec/ui-components#build"
24+
],
2225
"cache": false,
2326
"persistent": true,
2427
"passThroughEnv": [

0 commit comments

Comments
 (0)