mirror of
https://github.com/MrPatben8/konduktor.git
synced 2026-11-27 10:22:51 +01:00
Initial Commit: Implemented library list
This commit is contained in:
1 parent
704d128289
commit
fceaab6d78
36 files changed
+3910
No files matched your search
@@ -0,0 +1,20 @@
|
||||
interface Props {
|
||||
value: number
|
||||
}
|
||||
|
||||
// Compact 5-star rating. Filled stars use the gold accent; empties are faint.
|
||||
export function RatingStars({ value }: Props) {
|
||||
if (!value) return <span className="text-faint">—</span>
|
||||
return (
|
||||
<span className="whitespace-nowrap tracking-tight" title={`${value} / 5`}>
|
||||
{[1, 2, 3, 4, 5].map((i) => (
|
||||
<span
|
||||
key={i}
|
||||
className={i <= value ? 'text-gold' : 'text-ink-600'}
|
||||
>
|
||||
★
|
||||
</span>
|
||||
))}
|
||||
</span>
|
||||
)
|
||||
}
|
||||
Reference in new issue
Block a user