Desktop poll code clean up and refinements (#120)

This commit is contained in:
Luke Vella 2022-04-21 13:01:29 +01:00 committed by GitHub
parent 8cd1db41db
commit 00b72d01bf
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
11 changed files with 160 additions and 146 deletions

View file

@ -1,34 +0,0 @@
import clsx from "clsx";
import * as React from "react";
export interface ScoreProps {
count: number;
highlight?: boolean;
style?: React.CSSProperties;
className?: string;
}
const Score: React.VoidFunctionComponent<ScoreProps> = ({
count,
highlight,
style,
className,
}) => {
return (
<div
className={clsx(
" z-20 flex h-5 w-5 items-center justify-center rounded-full text-xs shadow-sm shadow-slate-200 transition-colors",
{
"bg-rose-500 text-white": highlight,
"bg-slate-200 text-slate-500": !highlight,
},
className,
)}
style={style}
>
{count}
</div>
);
};
export default Score;