excalidraw/src/components/FixedSideContainer.tsx
Danila b50c54f855
Add and use clsx (classnames alternative) (#2249)
Co-authored-by: David Luzar <luzar.david@gmail.com>
2020-10-19 16:14:28 +02:00

27 lines
467 B
TypeScript

import "./FixedSideContainer.scss";
import React from "react";
import clsx from "clsx";
type FixedSideContainerProps = {
children: React.ReactNode;
side: "top" | "left" | "right";
className?: string;
};
export const FixedSideContainer = ({
children,
side,
className,
}: FixedSideContainerProps) => (
<div
className={clsx(
"FixedSideContainer",
`FixedSideContainer_side_${side}`,
className,
)}
>
{children}
</div>
);