diff --git a/frontends/nextjs/src/components/editors/JsonEditor.tsx b/frontends/nextjs/src/components/editors/JsonEditor.tsx index f575e5005..97bb2b052 100644 --- a/frontends/nextjs/src/components/editors/JsonEditor.tsx +++ b/frontends/nextjs/src/components/editors/JsonEditor.tsx @@ -13,6 +13,7 @@ import { DialogTitle, } from '@/components/ui' import { securityScanner, type SecurityScanResult } from '@/lib/security-scanner' +import type { JsonValue } from '@/types/utility-types' import { SchemaSection } from './json/SchemaSection' import { Toolbar } from './json/Toolbar' @@ -21,9 +22,9 @@ interface JsonEditorProps { open: boolean onClose: () => void title: string - value: any - onSave: (value: any) => void - schema?: any + value: JsonValue + onSave: (value: JsonValue) => void + schema?: JsonValue } export function JsonEditor({ open, onClose, title, value, onSave, schema }: JsonEditorProps) { @@ -41,7 +42,7 @@ export function JsonEditor({ open, onClose, title, value, onSave, schema }: Json } }, [open, value]) - const parseJson = () => JSON.parse(jsonText) + const parseJson = (): JsonValue => JSON.parse(jsonText) as JsonValue const handleSave = () => { try { diff --git a/frontends/nextjs/src/components/level4/tabs/TabContent.tsx b/frontends/nextjs/src/components/level4/tabs/TabContent.tsx index 89c839549..d644743bf 100644 --- a/frontends/nextjs/src/components/level4/tabs/TabContent.tsx +++ b/frontends/nextjs/src/components/level4/tabs/TabContent.tsx @@ -16,7 +16,8 @@ import { ThemeEditor } from '@/components/ThemeEditor' import { TabsContent } from '@/components/ui' import { UserManagement } from '@/components/UserManagement' import { WorkflowEditor } from '@/components/WorkflowEditor' -import type { AppConfiguration, User } from '@/lib/level-types' +import type { AppConfiguration, LuaScript, User, Workflow } from '@/lib/level-types' +import type { ModelSchema } from '@/lib/types/schema-types' import type { Level4TabConfig } from './config' @@ -25,9 +26,9 @@ interface Level4TabContentProps { appConfig: AppConfiguration user: User nerdMode: boolean - onSchemasChange: (schemas: any[]) => Promise - onWorkflowsChange: (workflows: any[]) => Promise - onLuaScriptsChange: (scripts: any[]) => Promise + onSchemasChange: (schemas: ModelSchema[]) => Promise + onWorkflowsChange: (workflows: Workflow[]) => Promise + onLuaScriptsChange: (scripts: LuaScript[]) => Promise } export function TabContent({