v1 review pass: fixed some minor bugs
This commit is contained in:
@@ -7,9 +7,12 @@ interface VoteButtonProps {
|
||||
onRemove: (dumpId: string) => void;
|
||||
}
|
||||
|
||||
export function VoteButton({ dumpId, count, voted, disabled, onCast, onRemove }: VoteButtonProps) {
|
||||
export function VoteButton(
|
||||
{ dumpId, count, voted, disabled, onCast, onRemove }: VoteButtonProps,
|
||||
) {
|
||||
return (
|
||||
<button
|
||||
type="button"
|
||||
className={`vote-btn${voted ? " vote-btn--active" : ""}`}
|
||||
onClick={() => voted ? onRemove(dumpId) : onCast(dumpId)}
|
||||
disabled={disabled}
|
||||
|
||||
Reference in New Issue
Block a user