mirror of https://github.com/langgenius/dify.git
feat: tools readonly
This commit is contained in:
parent
0aa984219f
commit
8f311b020a
|
|
@ -62,7 +62,7 @@ const TypeSelector: FC<Props> = ({
|
|||
onClick={toggleShow}
|
||||
className={cn(showOption && 'bg-black/5', 'flex items-center h-5 pl-1 pr-0.5 rounded-md text-xs font-semibold text-gray-700 cursor-pointer hover:bg-black/5')}>
|
||||
<div className={cn(triggerClassName, 'text-sm font-semibold', uppercase && 'uppercase', noValue && 'text-gray-400')}>{!noValue ? item?.label : placeholder}</div>
|
||||
<DropDownIcon className='w-3 h-3 ' />
|
||||
{!readonly && <DropDownIcon className='w-3 h-3 ' />}
|
||||
</div>
|
||||
)}
|
||||
|
||||
|
|
|
|||
|
|
@ -198,6 +198,7 @@ const VarReferencePicker: FC<Props> = ({
|
|||
<TypeSelector
|
||||
noLeft
|
||||
triggerClassName='!text-xs'
|
||||
readonly={readonly}
|
||||
DropDownIcon={ChevronDown}
|
||||
value={varKindType}
|
||||
options={varKindTypes}
|
||||
|
|
@ -217,6 +218,7 @@ const VarReferencePicker: FC<Props> = ({
|
|||
onChange={handleStaticChange}
|
||||
onFocus={() => setIsFocus(true)}
|
||||
onBlur={() => setIsFocus(false)}
|
||||
readOnly={readonly}
|
||||
/>
|
||||
)
|
||||
: (
|
||||
|
|
|
|||
|
|
@ -22,9 +22,9 @@ const Panel: FC<NodePanelProps<ToolNodeType>> = ({
|
|||
data,
|
||||
}) => {
|
||||
const { t } = useTranslation()
|
||||
const readOnly = false
|
||||
|
||||
const {
|
||||
readOnly,
|
||||
inputs,
|
||||
toolInputVarSchema,
|
||||
setInputVar,
|
||||
|
|
|
|||
Loading…
Reference in New Issue