feat: support try agent app

This commit is contained in:
Joel 2025-10-11 10:42:55 +08:00
parent 1ab7e1cba8
commit 50072a63ae
3 changed files with 3 additions and 3 deletions

View File

@ -16,7 +16,7 @@ const TryApp: FC<Props> = ({
}) => {
const { isFetching: isFetchingAppInfo, data: appInfo } = useGetTryAppInfo(appId)
const mode = appInfo?.mode
const isChat = mode === 'chat' || mode === 'advanced-chat'
const isChat = ['chat', 'advanced-chat', 'agent-chat'].includes(mode!)
const isCompletion = !isChat
if (isFetchingAppInfo) {
return (

View File

@ -45,7 +45,6 @@ const TextGeneration: FC<Props> = ({
doSetInputs(newInputs)
inputsRef.current = newInputs
}, [])
// console.log(isPC, setInputs)
const updateAppInfo = useWebAppStore(s => s.updateAppInfo)
const { data: tryAppParams } = useGetTryAppParams(appId)

View File

@ -1,3 +1,4 @@
import type { AppMode } from '@/types/app'
import {
get,
} from './base'
@ -7,7 +8,7 @@ import type {
type TryAppInfo = {
name: string
mode: 'chat' | 'advanced-chat' | 'text-generation' | 'workflow'
mode: AppMode
site: SiteInfo
}