diff --git a/src/components/CFDellButton/CFDellButton.tsx b/src/components/CFDellButton/CFDellButton.tsx new file mode 100644 index 00000000..b4a688fa --- /dev/null +++ b/src/components/CFDellButton/CFDellButton.tsx @@ -0,0 +1,18 @@ +import React, { ReactElement } from "react"; +import { IoTrashBinOutline } from "react-icons/io5"; + +interface ICFDellButton { + disabled?: boolean; + onClick: () => void; +} + +export default function CFDellButton({ + disabled, + onClick, +}: ICFDellButton): ReactElement { + return ( + + ); +} diff --git a/src/components/CFHostDirectoriesInput/CFHostDirectoriesInput.tsx b/src/components/CFHostDirectoriesInput/CFHostDirectoriesInput.tsx index 286fe21f..7cd2d312 100644 --- a/src/components/CFHostDirectoriesInput/CFHostDirectoriesInput.tsx +++ b/src/components/CFHostDirectoriesInput/CFHostDirectoriesInput.tsx @@ -2,7 +2,7 @@ import { ReactElement } from "react"; import FormInputText from "../FormInputText/FormInputText"; import { IDetails } from "../../interfaces/robotInterfaces"; import { FormikProps } from "formik/dist/types"; -import CreateRobotFormDeleteButton from "../CreateRobotFormDeleteButton/CreateRobotFormDeleteButton"; +import CFDellButton from "../CFDellButton/CFDellButton"; interface ICFHostDirectoriesInput { index: number; @@ -15,10 +15,8 @@ export default function CFHostDirectoriesInput({ formik, disabled, }: ICFHostDirectoriesInput): ReactElement { - console.log("formik.getFieldProps", formik.values.hostDirectories); - return ( -
+
-
- + { const hostDirectories = [...formik.values.hostDirectories]; hostDirectories.splice(index, 1); formik.setFieldValue("hostDirectories", hostDirectories); }} - disabled={disabled} />
diff --git a/src/components/CodeEditor/CodeEditor.tsx b/src/components/CodeEditor/CodeEditor.tsx index 94455950..74aea104 100644 --- a/src/components/CodeEditor/CodeEditor.tsx +++ b/src/components/CodeEditor/CodeEditor.tsx @@ -3,7 +3,7 @@ import CardLayout from "../../layouts/CardLayout"; import { FullScreen, useFullScreenHandle } from "react-full-screen"; import { useAppSelector } from "../../hooks/redux"; import useRobot from "../../hooks/useRobot"; -import RestartService from "../RestartService/RestartService"; +import RestartService from "../RestartServiceButton/RestartServiceButton"; import FullScreenButton from "../FullScreenButton/FullScreenButton"; export default function CodeEditor(): ReactElement { diff --git a/src/components/Connections/Connections.tsx b/src/components/Connections/Connections.tsx index 1d626aa3..ef8000ad 100644 --- a/src/components/Connections/Connections.tsx +++ b/src/components/Connections/Connections.tsx @@ -1,4 +1,4 @@ -import React, { ReactElement, useEffect } from "react"; +import React, { ReactElement } from "react"; import useRobot from "../../hooks/useRobot"; import StateCell from "../TableInformationCells/StateCell"; import ConnectionLabel from "../ConnectionLabel/ConnectionLabel"; @@ -8,10 +8,6 @@ export default function Connections(): ReactElement { const { responseRobot, isSettedCookie } = useRobot(); const { keycloak } = useKeycloak(); - useEffect(() => { - console.log("isSettedCookie", isSettedCookie); - }, [isSettedCookie]); - return (
diff --git a/src/components/CreateRobotFormAddButton/CreateRobotFormAddButton.tsx b/src/components/CreateRobotFormAddButton/CreateRobotFormAddButton.tsx index e71abbfc..a8033e50 100644 --- a/src/components/CreateRobotFormAddButton/CreateRobotFormAddButton.tsx +++ b/src/components/CreateRobotFormAddButton/CreateRobotFormAddButton.tsx @@ -18,7 +18,7 @@ export default function CreateRobotFormAddButton({ {} : onClick} - size={22} + size={18} className={`animate__animated animate__fadeIn mx-auto mt-4 cursor-pointer transition-all duration-500 ${ disabled ? "text-layer-light-600 hover:cursor-not-allowed" diff --git a/src/components/FullScreenButton/FullScreenButton.tsx b/src/components/FullScreenButton/FullScreenButton.tsx index ddebb66f..4bc251a3 100644 --- a/src/components/FullScreenButton/FullScreenButton.tsx +++ b/src/components/FullScreenButton/FullScreenButton.tsx @@ -10,8 +10,8 @@ export default function FullScreenButton({ handleFullScreen, }: IFullScreenButton) { return ( -
{isFullScreen ? ( @@ -26,6 +26,6 @@ export default function FullScreenButton({ /> )}

Full Screen

-
+ ); } diff --git a/src/components/InputText/InputText.tsx b/src/components/InputText/InputText.tsx index a1a5a0d8..00410ba9 100644 --- a/src/components/InputText/InputText.tsx +++ b/src/components/InputText/InputText.tsx @@ -46,7 +46,7 @@ export default function InputText({
diff --git a/src/components/RemoteDesktopController/RemoteDesktopController.tsx b/src/components/RemoteDesktopController/RemoteDesktopController.tsx index 4dc470fb..fff0403c 100644 --- a/src/components/RemoteDesktopController/RemoteDesktopController.tsx +++ b/src/components/RemoteDesktopController/RemoteDesktopController.tsx @@ -1,5 +1,5 @@ import { IoIosArrowUp, IoIosArrowDown } from "react-icons/io"; -import RestartService from "../RestartService/RestartService"; +import RestartService from "../RestartServiceButton/RestartServiceButton"; import VolumeControl from "../VolumeControl/VolumeControl"; import { ReactElement, useState } from "react"; import { useKeycloak } from "@react-keycloak/web"; diff --git a/src/components/RestartService/RestartService.tsx b/src/components/RestartServiceButton/RestartServiceButton.tsx similarity index 72% rename from src/components/RestartService/RestartService.tsx rename to src/components/RestartServiceButton/RestartServiceButton.tsx index b6358594..2845d340 100644 --- a/src/components/RestartService/RestartService.tsx +++ b/src/components/RestartServiceButton/RestartServiceButton.tsx @@ -10,8 +10,8 @@ export default function RestartService({ type }: IRestartService) { const [isOpenedModal, setIsOpenedModal] = useState(false); return ( -
- setIsOpenedModal(true)} /> +
+ ); } diff --git a/src/contexts/MainContext.tsx b/src/contexts/MainContext.tsx index 2b4160d2..3274f805 100644 --- a/src/contexts/MainContext.tsx +++ b/src/contexts/MainContext.tsx @@ -10,8 +10,8 @@ export default ({ children }: any) => { const url = useLocation(); const [sidebarState, setSidebarState] = useState({ - isOpen: true, - isCreateMode: true, + isOpen: false, + isCreateMode: false, page: undefined, instanceTab: "Cloud Instances", });