mirror of
https://github.com/excalidraw/excalidraw.git
synced 2025-11-21 05:04:29 +01:00
Add and use clsx (classnames alternative) (#2249)
Co-authored-by: David Luzar <luzar.david@gmail.com>
This commit is contained in:
@@ -1,4 +1,5 @@
|
||||
import React from "react";
|
||||
import clsx from "clsx";
|
||||
|
||||
export const ButtonSelect = <T extends Object>({
|
||||
options,
|
||||
@@ -15,7 +16,7 @@ export const ButtonSelect = <T extends Object>({
|
||||
{options.map((option) => (
|
||||
<label
|
||||
key={option.text}
|
||||
className={value === option.value ? "active" : ""}
|
||||
className={clsx({ active: value === option.value })}
|
||||
>
|
||||
<input
|
||||
type="radio"
|
||||
|
||||
Reference in New Issue
Block a user