{!isRunning && !currentVars.length && (
setShowVariableInspectPanel(true)}
+ className={cn('system-2xs-semibold-uppercase flex h-5 cursor-pointer items-center gap-1 rounded-md border-[0.5px] border-effects-highlight bg-components-actionbar-bg px-2 text-text-tertiary shadow-lg backdrop-blur-sm hover:bg-background-default-hover',
+ nodesReadOnly && 'cursor-not-allowed text-text-disabled hover:bg-transparent hover:text-text-disabled',
+ )}
+ onClick={() => {
+ if (getNodesReadOnly())
+ return
+ setShowVariableInspectPanel(true)
+ }}
>
{t('workflow.debug.variableInspect.trigger.normal')}
@@ -70,13 +80,21 @@ const VariableInspectTrigger: FC = () => {
{!isRunning && currentVars.length > 0 && (
<>
setShowVariableInspectPanel(true)}
+ className={cn('system-xs-medium flex h-6 cursor-pointer items-center gap-1 rounded-md border-[0.5px] border-effects-highlight bg-components-actionbar-bg px-2 text-text-accent shadow-lg backdrop-blur-sm hover:bg-components-actionbar-bg-accent',
+ nodesReadOnly && 'cursor-not-allowed text-text-disabled hover:bg-transparent hover:text-text-disabled',
+ )}
+ onClick={() => {
+ if (getNodesReadOnly())
+ return
+ setShowVariableInspectPanel(true)
+ }}
>
{t('workflow.debug.variableInspect.trigger.cached')}
{t('workflow.debug.variableInspect.trigger.clear')}
diff --git a/web/app/styles/globals.css b/web/app/styles/globals.css
index 52e36a2767..353cfa2fff 100644
--- a/web/app/styles/globals.css
+++ b/web/app/styles/globals.css
@@ -697,4 +697,15 @@ button:focus-within {
-ms-overflow-style: none;
scrollbar-width: none;
}
+
+ /* Hide arrows from number input */
+ .no-spinner::-webkit-outer-spin-button,
+ .no-spinner::-webkit-inner-spin-button {
+ -webkit-appearance: none;
+ margin: 0;
+ }
+
+ .no-spinner {
+ -moz-appearance: textfield;
+ }
}
diff --git a/web/i18n/en-US/dataset-documents.ts b/web/i18n/en-US/dataset-documents.ts
index 2a79324477..7d0a3541a0 100644
--- a/web/i18n/en-US/dataset-documents.ts
+++ b/web/i18n/en-US/dataset-documents.ts
@@ -355,7 +355,9 @@ const translation = {
newChildChunk: 'New Child Chunk',
keywords: 'KEYWORDS',
addKeyWord: 'Add keyword',
+ keywordEmpty: 'The keyword cannot be empty',
keywordError: 'The maximum length of keyword is 20',
+ keywordDuplicate: 'The keyword already exists',
characters_one: 'character',
characters_other: 'characters',
hitCount: 'Retrieval count',
diff --git a/web/service/use-plugins.ts b/web/service/use-plugins.ts
index 1b6bda5715..86f8134a5d 100644
--- a/web/service/use-plugins.ts
+++ b/web/service/use-plugins.ts
@@ -1,5 +1,6 @@
import { useCallback, useEffect } from 'react'
import type {
+ FormOption,
ModelProvider,
} from '@/app/components/header/account-setting/model-provider-page/declarations'
import { fetchModelProviderModelList } from '@/service/common'
@@ -518,7 +519,7 @@ export const usePluginTaskList = (category?: PluginType) => {
refreshPluginList(category ? { category } as any : undefined, !category)
}
}
- // eslint-disable-next-line react-hooks/exhaustive-deps
+ // eslint-disable-next-line react-hooks/exhaustive-deps
}, [isRefetching])
const handleRefetch = useCallback(() => {
@@ -612,3 +613,17 @@ export const usePluginInfo = (providerName?: string) => {
enabled: !!providerName,
})
}
+
+export const useFetchDynamicOptions = (plugin_id: string, provider: string, action: string, parameter: string, provider_type: 'tool') => {
+ return useMutation({
+ mutationFn: () => get<{ options: FormOption[] }>('/workspaces/current/plugin/parameters/dynamic-options', {
+ params: {
+ plugin_id,
+ provider,
+ action,
+ parameter,
+ provider_type,
+ },
+ }),
+ })
+}