Skip to content

Commit 8895a7b

Browse files
committed
refactor(ui/card): update badge import and props, add CSS variables
- Changed import path for BadgeStatus to badge-status.tsx - Updated CardWrapper border radius to rounded-lg for consistency - Modified BadgeStatus prop from 'mode' to 'status' for clarity - Added new CSS variables for badge in-progress and success states to enhance UI theming
1 parent 6270921 commit 8895a7b

File tree

2 files changed

+10
-3
lines changed

2 files changed

+10
-3
lines changed

src/components/ui/card.tsx

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
import type { UploadProgress } from '../upload/upload-progress.tsx'
2-
import { BadgeStatus } from './badge.tsx'
2+
import { BadgeStatus } from './badge-status.tsx'
33

44
type CardWrapperProps = {
55
children: React.ReactNode
@@ -16,14 +16,14 @@ type CardContentProps = {
1616
}
1717

1818
function CardWrapper({ children }: CardWrapperProps) {
19-
return <div className="bg-zinc-900 p-6 rounded-md">{children}</div>
19+
return <div className="bg-zinc-900 p-6 rounded-lg">{children}</div>
2020
}
2121

2222
function CardHeader({ title, status }: CardHeaderProps) {
2323
return (
2424
<div className="flex items-center justify-between">
2525
<h3 className="font-medium">{title}</h3>
26-
{status !== 'in-progress' && <BadgeStatus mode={status} />}
26+
{status !== 'in-progress' && <BadgeStatus status={status} />}
2727
</div>
2828
)
2929
}

src/index.css

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,13 @@
77

88
--color-button-brand: #086dc5;
99
--color-button-brand-disabled: #005280;
10+
11+
--color-badge-in-progress: #3B1400;
12+
--color-badge-in-progress-text: #FF8C3B;
13+
--color-badge-in-progress-border: #662100;
14+
15+
--color-badge-success: #001D3B;
16+
--color-badge-success-border: #003669;
1017
}
1118

1219
:root {

0 commit comments

Comments
 (0)