From a787dd2b9fcf3efb6dcb1013b127d3155cbbf8e9 Mon Sep 17 00:00:00 2001 From: gokhangunduz Date: Mon, 12 Feb 2024 16:57:51 +0300 Subject: [PATCH] feat(version): release 0.34.0 version --- package.json | 2 +- src/components/CFStep0/CFStep0.tsx | 4 ++-- src/components/CreateForms/CFAppStep1.tsx | 18 +++++++++--------- src/components/WidgetGPUCell/WidgetGPUCell.tsx | 2 +- src/contexts/FunctionsContext.tsx | 7 ++++--- .../hook/functions.hook.interface.ts | 5 ++--- 6 files changed, 19 insertions(+), 19 deletions(-) diff --git a/package.json b/package.json index bf0c2ef9..dc57e066 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "ui", - "version": "0.33.9", + "version": "0.34.0", "private": true, "scripts": { "dev": "GENERATE_SOURCEMAP=false react-scripts start", diff --git a/src/components/CFStep0/CFStep0.tsx b/src/components/CFStep0/CFStep0.tsx index 09c5527c..d8a2aa91 100644 --- a/src/components/CFStep0/CFStep0.tsx +++ b/src/components/CFStep0/CFStep0.tsx @@ -18,7 +18,7 @@ export default function CFStep0(): ReactElement { category: "private", template: undefined, }); - const { getTemplates } = useFunctions(); + const { getTemplatesFC } = useFunctions(); const [isLoading, setIsLoading] = useState(false); useEffect(() => { @@ -47,7 +47,7 @@ export default function CFStep0(): ReactElement { const { handleCreateRobotNextStep } = useMain(); async function handleGetTemplates() { - setTemplates(await getTemplates()); + setTemplates(await getTemplatesFC()); } const box = (template: ITemplate) => { diff --git a/src/components/CreateForms/CFAppStep1.tsx b/src/components/CreateForms/CFAppStep1.tsx index 8526b4db..c782e2c1 100644 --- a/src/components/CreateForms/CFAppStep1.tsx +++ b/src/components/CreateForms/CFAppStep1.tsx @@ -100,18 +100,18 @@ export default function CFAppStep1({ )} - - - - - - + + + + - + + + - + - + ); } diff --git a/src/components/WidgetGPUCell/WidgetGPUCell.tsx b/src/components/WidgetGPUCell/WidgetGPUCell.tsx index ab2cb567..7e28d4dc 100644 --- a/src/components/WidgetGPUCell/WidgetGPUCell.tsx +++ b/src/components/WidgetGPUCell/WidgetGPUCell.tsx @@ -22,7 +22,7 @@ export default function WidgetGPUCell(): ReactElement { {pagesState?.instance?.resources?.hardware?.gpu?.hardware?.map( (gpu, index: number) => { return ( - ); diff --git a/src/contexts/FunctionsContext.tsx b/src/contexts/FunctionsContext.tsx index 61fbb78d..1f59d196 100644 --- a/src/contexts/FunctionsContext.tsx +++ b/src/contexts/FunctionsContext.tsx @@ -101,6 +101,7 @@ import { import { IPhysicalInstance } from "../interfaces/global/physicalInstance.interface"; import { dataScienceAppsMapper } from "../handler/dataScience.handler"; import { IDataScienceApp } from "../interfaces/global/dataSciende.interface"; +import { ITemplate } from "../interfaces/global/template.interface"; export const FunctionsContext: any = createContext(null); @@ -862,8 +863,8 @@ export default ({ children }: any) => { }); } - async function getTemplates(): Promise { - return new Promise(async (resolve, reject) => { + async function getTemplatesFC(): Promise { + return new Promise(async (resolve, reject) => { try { const response: any = await dispatch( getTemplatesDispatch({ @@ -1511,6 +1512,7 @@ export default ({ children }: any) => { deleteRobotFC, //// Tools //// getSystemStatusFC, + getTemplatesFC, getFreePortFC, //// //// @@ -1530,7 +1532,6 @@ export default ({ children }: any) => { getIP, getFilesFromFileManager, - getTemplates, }} > {children} diff --git a/src/interfaces/hook/functions.hook.interface.ts b/src/interfaces/hook/functions.hook.interface.ts index ab250575..93b27ea7 100644 --- a/src/interfaces/hook/functions.hook.interface.ts +++ b/src/interfaces/hook/functions.hook.interface.ts @@ -8,6 +8,7 @@ import { INamespace } from "../global/namespace.interface"; import { ISystemStatus } from "../global/system.interface"; import { IRegion } from "../global/region.interface"; import { IFleet } from "../global/fleet.interface"; +import { ITemplate } from "../global/template.interface"; export interface IsingleGetParameters { isSetState?: boolean; @@ -162,12 +163,12 @@ export interface IuseFunctions { deleteRobotFC: (robotName: string) => Promise; //// Tools //// getSystemStatusFC: () => Promise; + getTemplatesFC: () => Promise; getFreePortFC: () => Promise; //// //// //// //// - getPhysicalFleet: ( values: IgetPhysicalFleet, parameters?: IsingleGetParameters, @@ -186,6 +187,4 @@ export interface IuseFunctions { instanceIP: string; paths?: string[]; }) => Promise; - - getTemplates: () => Promise; }