mirror of https://github.com/langgenius/dify.git
refactor: improve TypeScript types for NodeCardProps and debug configuration context (#27001)
This commit is contained in:
parent
24612adf2c
commit
650e38e17f
|
|
@ -23,8 +23,10 @@ import {
|
|||
} from '../node-handle'
|
||||
import ErrorHandleOnNode from '../error-handle-on-node'
|
||||
|
||||
type NodeChildElement = ReactElement<Partial<NodeProps>>
|
||||
|
||||
type NodeCardProps = NodeProps & {
|
||||
children?: ReactElement
|
||||
children?: NodeChildElement
|
||||
}
|
||||
|
||||
const BaseCard = ({
|
||||
|
|
|
|||
|
|
@ -242,7 +242,7 @@ const DebugConfigurationContext = createContext<IDebugConfiguration>({
|
|||
},
|
||||
datasetConfigsRef: {
|
||||
current: null,
|
||||
},
|
||||
} as unknown as RefObject<DatasetConfigs>,
|
||||
setDatasetConfigs: noop,
|
||||
hasSetContextVar: false,
|
||||
isShowVisionConfig: false,
|
||||
|
|
|
|||
|
|
@ -324,7 +324,7 @@ const baseFetch = base
|
|||
|
||||
type UploadOptions = {
|
||||
xhr: XMLHttpRequest
|
||||
method: string
|
||||
method?: string
|
||||
url?: string
|
||||
headers?: Record<string, string>
|
||||
data: FormData
|
||||
|
|
|
|||
Loading…
Reference in New Issue