From 05d2d1b7fef11db4bb7691976dc63cba1adb54ad Mon Sep 17 00:00:00 2001 From: Rohit Rajan Date: Thu, 20 Nov 2025 13:25:43 +0530 Subject: [PATCH] feat: add optional type and url fields --- server/src/models/Robot.ts | 2 ++ src/components/robot/pages/RobotDuplicatePage.tsx | 7 +------ src/components/robot/pages/RobotEditPage.tsx | 7 +------ src/components/robot/pages/RobotSettingsPage.tsx | 1 + src/context/globalInfo.tsx | 2 ++ 5 files changed, 7 insertions(+), 12 deletions(-) diff --git a/server/src/models/Robot.ts b/server/src/models/Robot.ts index eae9438e..5acbdf13 100644 --- a/server/src/models/Robot.ts +++ b/server/src/models/Robot.ts @@ -9,6 +9,8 @@ interface RobotMeta { pairs: number; updatedAt: string; params: any[]; + type?: 'traditional' | 'markdown'; + url?: string; } interface RobotWorkflow { diff --git a/src/components/robot/pages/RobotDuplicatePage.tsx b/src/components/robot/pages/RobotDuplicatePage.tsx index b02cecde..7c45c8e8 100644 --- a/src/components/robot/pages/RobotDuplicatePage.tsx +++ b/src/components/robot/pages/RobotDuplicatePage.tsx @@ -24,12 +24,7 @@ interface RobotMeta { pairs: number; updatedAt: string; params: any[]; - type?: string; - description?: string; - usedByUsers?: number[]; - subscriptionLevel?: number; - access?: string; - sample?: any[]; + type?: 'traditional' | 'markdown'; url?: string; } diff --git a/src/components/robot/pages/RobotEditPage.tsx b/src/components/robot/pages/RobotEditPage.tsx index d5e7cb2d..19b9e43b 100644 --- a/src/components/robot/pages/RobotEditPage.tsx +++ b/src/components/robot/pages/RobotEditPage.tsx @@ -24,12 +24,7 @@ interface RobotMeta { pairs: number; updatedAt: string; params: any[]; - type?: string; - description?: string; - usedByUsers?: number[]; - subscriptionLevel?: number; - access?: string; - sample?: any[]; + type?: 'traditional' | 'markdown'; url?: string; } diff --git a/src/components/robot/pages/RobotSettingsPage.tsx b/src/components/robot/pages/RobotSettingsPage.tsx index 11832935..96b7d3ec 100644 --- a/src/components/robot/pages/RobotSettingsPage.tsx +++ b/src/components/robot/pages/RobotSettingsPage.tsx @@ -16,6 +16,7 @@ interface RobotMeta { pairs: number; updatedAt: string; params: any[]; + type?: 'traditional' | 'markdown'; url?: string; } diff --git a/src/context/globalInfo.tsx b/src/context/globalInfo.tsx index 69969a09..a0c79622 100644 --- a/src/context/globalInfo.tsx +++ b/src/context/globalInfo.tsx @@ -27,6 +27,8 @@ interface RobotMeta { pairs: number; updatedAt: string; params: any[]; + type?: 'traditional' | 'markdown'; + url?: string; } interface RobotWorkflow {