forked from Github/frigate
Use cn() for class names throughout (#11278)
* add scrollbar on ptz presets dropdown
* use cn function for class names throughout
* Revert "add scrollbar on ptz presets dropdown"
This reverts commit 2cee93dc3e.
This commit is contained in:
@@ -5,6 +5,7 @@ import {
|
||||
TooltipTrigger,
|
||||
} from "@/components/ui/tooltip";
|
||||
import { isDesktop } from "react-device-detect";
|
||||
import { cn } from "@/lib/utils";
|
||||
|
||||
const variants = {
|
||||
primary: {
|
||||
@@ -38,9 +39,11 @@ export default function CameraFeatureToggle({
|
||||
const content = (
|
||||
<div
|
||||
onClick={onClick}
|
||||
className={`${className} flex flex-col justify-center items-center ${
|
||||
variants[variant][isActive ? "active" : "inactive"]
|
||||
}`}
|
||||
className={cn(
|
||||
className,
|
||||
"flex flex-col justify-center items-center",
|
||||
variants[variant][isActive ? "active" : "inactive"],
|
||||
)}
|
||||
>
|
||||
<Icon
|
||||
className={`size-5 md:m-[6px] ${isActive ? "text-white" : "text-secondary-foreground"}`}
|
||||
|
||||
Reference in New Issue
Block a user