refactoring
This commit is contained in:
@@ -5,6 +5,7 @@ import Button from "../Button";
|
||||
import HintIcon from "../icons/HintIcon";
|
||||
import ResizeIcon from "../icons/ResizeIcon";
|
||||
import HelpModal from "../modals/HelpModal";
|
||||
import ActiveResizeIcon from "../icons/ActiveResizeIcon";
|
||||
|
||||
const TopPanel = () => {
|
||||
const [isFullMode, setIsFullMode] = useState(false);
|
||||
@@ -27,12 +28,24 @@ const TopPanel = () => {
|
||||
};
|
||||
|
||||
return (
|
||||
<div className="absolute top-[62px] left-0 z-20 w-full p-4 flex justify-end gap-2">
|
||||
<Button
|
||||
buttonType="fab"
|
||||
icon={<ResizeIcon />}
|
||||
onClick={handleOnFullScreenClick}
|
||||
/>
|
||||
<div
|
||||
className={`absolute ${
|
||||
isFullMode ? "" : "top-[62px]"
|
||||
} left-0 z-20 w-full p-4 flex justify-end gap-2`}
|
||||
>
|
||||
{isFullMode ? (
|
||||
<Button
|
||||
buttonType="fab"
|
||||
icon={<ActiveResizeIcon />}
|
||||
onClick={handleOnFullScreenClick}
|
||||
/>
|
||||
) : (
|
||||
<Button
|
||||
buttonType="fab"
|
||||
icon={<ResizeIcon />}
|
||||
onClick={handleOnFullScreenClick}
|
||||
/>
|
||||
)}
|
||||
<Button
|
||||
buttonType="fab"
|
||||
icon={<HintIcon />}
|
||||
|
||||
Reference in New Issue
Block a user