feat: add var type

This commit is contained in:
Joel
2025-07-04 16:02:28 +08:00
parent 77aa35ff15
commit 1094b3da23
2 changed files with 7 additions and 3 deletions

View File

@ -49,9 +49,10 @@ export const isConversationVar = (valueSelector: ValueSelector) => {
return valueSelector[0] === 'conversation'
}
const inputVarTypeToVarType = (type: InputVarType): VarType => {
export const inputVarTypeToVarType = (type: InputVarType): VarType => {
return ({
[InputVarType.number]: VarType.number,
[InputVarType.boolean]: VarType.boolean,
[InputVarType.singleFile]: VarType.file,
[InputVarType.multiFiles]: VarType.arrayFile,
} as any)[type] || VarType.string