feat: enhance condition handling with enum value options and metadata in workflow components

This commit is contained in:
mlogclub
2026-06-27 12:50:29 +08:00
parent d4ff0980c4
commit f85fb6d406
12 changed files with 497 additions and 41 deletions
+7
View File
@@ -301,9 +301,16 @@ export type AIWorkflowVariableSelector = {
export type AIWorkflowVariableSpec = {
name: string
label?: string
type: AIWorkflowVariableType
required?: boolean
description: string
operators?: string[]
valueOptions?: {
value: unknown
label: string
description?: string
}[]
}
export type AIWorkflowDefinition = {
+19
View File
@@ -0,0 +1,19 @@
import { request } from "@/lib/api/client"
export type PublicConfig = {
language: string
wxworkEnabled: boolean
oidcEnabled: boolean
}
let publicConfigPromise: Promise<PublicConfig> | null = null
export function fetchPublicConfig() {
publicConfigPromise ??= request<PublicConfig>("/api/config", {
skipAuth: true,
}).catch((error) => {
publicConfigPromise = null
throw error
})
return publicConfigPromise
}