mirror of
http://112.124.100.131/huang.ze/ebiz-dify-ai.git
synced 2025-12-12 04:16:54 +08:00
Chore: frontend infrastructure upgrade (#16420)
Co-authored-by: NFish <douxc512@gmail.com> Co-authored-by: zxhlyh <jasonapring2015@outlook.com> Co-authored-by: twwu <twwu@dify.ai> Co-authored-by: jZonG <jzongcode@gmail.com>
This commit is contained in:
@@ -171,14 +171,14 @@ const InputVarList: FC<Props> = ({
|
||||
|
||||
return (
|
||||
<div key={variable} className='space-y-1'>
|
||||
<div className='flex items-center h-[18px] space-x-2'>
|
||||
<span className='text-text-secondary code-sm-semibold'>{label[language] || label.en_US}</span>
|
||||
<span className='text-text-tertiary system-xs-regular'>{paramType(type)}</span>
|
||||
{required && <span className='text-util-colors-orange-dark-orange-dark-600 system-xs-regular'>Required</span>}
|
||||
<div className='flex h-[18px] items-center space-x-2'>
|
||||
<span className='code-sm-semibold text-text-secondary'>{label[language] || label.en_US}</span>
|
||||
<span className='system-xs-regular text-text-tertiary'>{paramType(type)}</span>
|
||||
{required && <span className='system-xs-regular text-util-colors-orange-dark-orange-dark-600'>Required</span>}
|
||||
</div>
|
||||
{isString && (
|
||||
<Input
|
||||
className={cn(inputsIsFocus[variable] ? 'shadow-xs bg-gray-50 border-gray-300' : 'bg-gray-100 border-gray-100', 'rounded-lg px-3 py-[6px] border')}
|
||||
className={cn(inputsIsFocus[variable] ? 'border-gray-300 bg-gray-50 shadow-xs' : 'border-gray-100 bg-gray-100', 'rounded-lg border px-3 py-[6px]')}
|
||||
value={varInput?.value as string || ''}
|
||||
onChange={handleMixedTypeChange(variable)}
|
||||
readOnly={readOnly}
|
||||
@@ -235,7 +235,7 @@ const InputVarList: FC<Props> = ({
|
||||
scope={scope}
|
||||
/>
|
||||
)}
|
||||
{tooltip && <div className='text-text-tertiary body-xs-regular'>{tooltip[language] || tooltip.en_US}</div>}
|
||||
{tooltip && <div className='body-xs-regular text-text-tertiary'>{tooltip[language] || tooltip.en_US}</div>}
|
||||
</div>
|
||||
)
|
||||
})
|
||||
|
||||
@@ -17,17 +17,17 @@ const Node: FC<NodeProps<ToolNodeType>> = ({
|
||||
<div className='mb-1 px-3 py-1'>
|
||||
<div className='space-y-0.5'>
|
||||
{toolConfigs.map((key, index) => (
|
||||
<div key={index} className='flex items-center h-6 justify-between bg-gray-100 rounded-md px-1 space-x-1 text-xs font-normal text-gray-700'>
|
||||
<div title={key} className='max-w-[100px] shrink-0 truncate text-xs font-medium text-gray-500 uppercase'>
|
||||
<div key={index} className='flex h-6 items-center justify-between space-x-1 rounded-md bg-gray-100 px-1 text-xs font-normal text-gray-700'>
|
||||
<div title={key} className='max-w-[100px] shrink-0 truncate text-xs font-medium uppercase text-gray-500'>
|
||||
{key}
|
||||
</div>
|
||||
{typeof tool_configurations[key] === 'string' && (
|
||||
<div title={tool_configurations[key]} className='grow w-0 shrink-0 truncate text-right text-xs font-normal text-gray-700'>
|
||||
<div title={tool_configurations[key]} className='w-0 shrink-0 grow truncate text-right text-xs font-normal text-gray-700'>
|
||||
{tool_configurations[key]}
|
||||
</div>
|
||||
)}
|
||||
{typeof tool_configurations[key] !== 'string' && tool_configurations[key]?.type === FormTypeEnum.modelSelector && (
|
||||
<div title={tool_configurations[key].model} className='grow w-0 shrink-0 truncate text-right text-xs font-normal text-gray-700'>
|
||||
<div title={tool_configurations[key].model} className='w-0 shrink-0 grow truncate text-right text-xs font-normal text-gray-700'>
|
||||
{tool_configurations[key].model}
|
||||
</div>
|
||||
)}
|
||||
|
||||
@@ -82,7 +82,7 @@ const Panel: FC<NodePanelProps<ToolNodeType>> = ({
|
||||
</>
|
||||
)}
|
||||
{!isShowAuthBtn && <>
|
||||
<div className='px-4 space-y-4'>
|
||||
<div className='space-y-4 px-4'>
|
||||
{toolInputVarSchema.length > 0 && (
|
||||
<Field
|
||||
title={t(`${i18nPrefix}.inputVars`)}
|
||||
|
||||
Reference in New Issue
Block a user