Build Agentic workflows, RAG pipelines, with rich AI model and tool support on one collaborative workspace. Deploy on cloud, VPC, or self-hosted, so teams move from prototype to production without rebuilding the stack.
Python agentagentic-aiagentic-frameworkagentic-workflowaiautomationclaudedeepseekgenaigptllmlow-codemcpnextjsno-codeopenaipythonskillsworkflow
chore: lint require and how to import react (#30041)
Stephen Zhou403adefc0725
diff --git a/web/__tests__/check-i18n.test.ts b/web/__tests__/check-i18n.test.tsindex bd315a3fa92..a6f86d81077 100644--- a/web/__tests__/check-i18n.test.ts+++ b/web/__tests__/check-i18n.test.ts@@ -1,9 +1,7 @@import fs from 'node:fs'import path from 'node:path'--// Mock functions to simulate the check-i18n functionality-const vm = require('node:vm')-const transpile = require('typescript').transpile+import vm from 'node:vm'+import { transpile } from 'typescript'describe('check-i18n script functionality', () => {const testDir = path.join(__dirname, '../i18n-test')diff --git a/web/__tests__/embedded-user-id-auth.test.tsx b/web/__tests__/embedded-user-id-auth.test.tsxindex 8817aa2e1eb..9231ac61991 100644--- a/web/__tests__/embedded-user-id-auth.test.tsx+++ b/web/__tests__/embedded-user-id-auth.test.tsx@@ -1,5 +1,5 @@import { fireEvent, render, screen, waitFor } from '@testing-library/react'-import React from 'react'+import * as React from 'react'import CheckCode from '@/app/(shareLayout)/webapp-signin/check-code/page'import MailAndPasswordAuth from '@/app/(shareLayout)/webapp-signin/components/mail-and-password-auth'diff --git a/web/__tests__/embedded-user-id-store.test.tsx b/web/__tests__/embedded-user-id-store.test.tsxindex d1f99b88337..276b22bcd7b 100644--- a/web/__tests__/embedded-user-id-store.test.tsx+++ b/web/__tests__/embedded-user-id-store.test.tsx@@ -1,5 +1,5 @@import { render, screen, waitFor } from '@testing-library/react'-import React from 'react'+import * as React from 'react'import WebAppStoreProvider, { useWebAppStore } from '@/context/web-app-context'import { AccessMode } from '@/models/access-control'diff --git a/web/__tests__/goto-anything/command-selector.test.tsx b/web/__tests__/goto-anything/command-selector.test.tsxindex 1a9ef33b004..f0168ab3be7 100644--- a/web/__tests__/goto-anything/command-selector.test.tsx+++ b/web/__tests__/goto-anything/command-selector.test.tsx@@ -1,6 +1,6 @@import type { ActionItem } from '../../app/components/goto-anything/actions/types'import { fireEvent, render, screen } from '@testing-library/react'-import React from 'react'+import * as React from 'react'import CommandSelector from '../../app/components/goto-anything/command-selector'vi.mock('cmdk', () => ({diff --git a/web/__tests__/goto-anything/scope-command-tags.test.tsx b/web/__tests__/goto-anything/scope-command-tags.test.tsxindex de34875d021..c25f4fc74e0 100644--- a/web/__tests__/goto-anything/scope-command-tags.test.tsx+++ b/web/__tests__/goto-anything/scope-command-tags.test.tsx@@ -1,5 +1,5 @@import { render, screen } from '@testing-library/react'-import React from 'react'+import * as React from 'react'// Type alias for search modetype SearchMode = 'scopes' | 'commands' | nulldiff --git a/web/__tests__/workflow-parallel-limit.test.tsx b/web/__tests__/workflow-parallel-limit.test.tsxindex d2afb30882d..18657f4bd2f 100644--- a/web/__tests__/workflow-parallel-limit.test.tsx+++ b/web/__tests__/workflow-parallel-limit.test.tsx@@ -6,7 +6,7 @@*/import { render, screen } from '@testing-library/react'-import React from 'react'+import * as React from 'react'// Mock environment variables before importing constantsconst originalEnv = process.env.NEXT_PUBLIC_MAX_PARALLEL_LIMITdiff --git a/web/__tests__/xss-prevention.test.tsx b/web/__tests__/xss-prevention.test.tsxindex b236f9ed3e9..10a8b21a301 100644--- a/web/__tests__/xss-prevention.test.tsx+++ b/web/__tests__/xss-prevention.test.tsx@@ -6,7 +6,7 @@*/import { cleanup, render } from '@testing-library/react'-import React from 'react'+import * as React from 'react'import BlockInput from '../app/components/base/block-input'import SupportVarInput from '../app/components/workflow/nodes/_base/components/support-var-input'diff --git a/web/app/(commonLayout)/app/(appDetailLayout)/[appId]/annotations/page.tsx b/web/app/(commonLayout)/app/(appDetailLayout)/[appId]/annotations/page.tsxindex 5fb3ff4b4dc..a17a4a3d035 100644--- a/web/app/(commonLayout)/app/(appDetailLayout)/[appId]/annotations/page.tsx+++ b/web/app/(commonLayout)/app/(appDetailLayout)/[appId]/annotations/page.tsx@@ -1,4 +1,4 @@-import React from 'react'+import * as React from 'react'import Main from '@/app/components/app/log-annotation'import { PageType } from '@/app/components/base/features/new-feature-panel/annotation-reply/type'diff --git a/web/app/(commonLayout)/app/(appDetailLayout)/[appId]/configuration/page.tsx b/web/app/(commonLayout)/app/(appDetailLayout)/[appId]/configuration/page.tsxindex 41143b979a1..850bd47aad0 100644--- a/web/app/(commonLayout)/app/(appDetailLayout)/[appId]/configuration/page.tsx+++ b/web/app/(commonLayout)/app/(appDetailLayout)/[appId]/configuration/page.tsx@@ -1,4 +1,4 @@-import React from 'react'+import * as React from 'react'import Configuration from '@/app/components/app/configuration'const IConfiguration = async () => {diff --git a/web/app/(commonLayout)/app/(appDetailLayout)/[appId]/develop/page.tsx b/web/app/(commonLayout)/app/(appDetailLayout)/[appId]/develop/page.tsxindex ba04eae64a0..14864aba8b1 100644--- a/web/app/(commonLayout)/app/(appDetailLayout)/[appId]/develop/page.tsx+++ b/web/app/(commonLayout)/app/(appDetailLayout)/[appId]/develop/page.tsx@@ -1,5 +1,5 @@import type { Locale } from '@/i18n-config'-import React from 'react'+import * as React from 'react'import DevelopMain from '@/app/components/develop'export type IDevelopProps = {diff --git a/web/app/(commonLayout)/app/(appDetailLayout)/[appId]/layout-main.tsx b/web/app/(commonLayout)/app/(appDetailLayout)/[appId]/layout-main.tsxindex 41bf4c3acf0..c1feb3ea5d6 100644--- a/web/app/(commonLayout)/app/(appDetailLayout)/[appId]/layout-main.tsx+++ b/web/app/(commonLayout)/app/(appDetailLayout)/[appId]/layout-main.tsx@@ -15,7 +15,8 @@ import {import { useUnmount } from 'ahooks'import dynamic from 'next/dynamic'import { usePathname, useRouter } from 'next/navigation'-import React, { useCallback, useEffect, useState } from 'react'+import * as React from 'react'+import { useCallback, useEffect, useState } from 'react'import { useTranslation } from 'react-i18next'import { useShallow } from 'zustand/react/shallow'import AppSideBar from '@/app/components/app-sidebar'diff --git a/web/app/(commonLayout)/app/(appDetailLayout)/[appId]/logs/page.tsx b/web/app/(commonLayout)/app/(appDetailLayout)/[appId]/logs/page.tsxindex 244a3576167..eb8ff8f795d 100644--- a/web/app/(commonLayout)/app/(appDetailLayout)/[appId]/logs/page.tsx+++ b/web/app/(commonLayout)/app/(appDetailLayout)/[appId]/logs/page.tsx@@ -1,4 +1,4 @@-import React from 'react'+import * as React from 'react'import Main from '@/app/components/app/log-annotation'import { PageType } from '@/app/components/base/features/new-feature-panel/annotation-reply/type'diff --git a/web/app/(commonLayout)/app/(appDetailLayout)/[appId]/overview/card-view.tsx b/web/app/(commonLayout)/app/(appDetailLayout)/[appId]/overview/card-view.tsxindex f9110c9c1b7..e9877f17157 100644--- a/web/app/(commonLayout)/app/(appDetailLayout)/[appId]/overview/card-view.tsx+++ b/web/app/(commonLayout)/app/(appDetailLayout)/[appId]/overview/card-view.tsx@@ -4,7 +4,8 @@ import type { IAppCardProps } from '@/app/components/app/overview/app-card'import type { BlockEnum } from '@/app/components/workflow/types'import type { UpdateAppSiteCodeResponse } from '@/models/app'import type { App } from '@/types/app'-import React, { useCallback, useMemo } from 'react'+import * as React from 'react'+import { useCallback, useMemo } from 'react'import { useTranslation } from 'react-i18next'import { useContext } from 'use-context-selector'import AppCard from '@/app/components/app/overview/app-card'diff --git a/web/app/(commonLayout)/app/(appDetailLayout)/[appId]/overview/chart-view.tsx b/web/app/(commonLayout)/app/(appDetailLayout)/[appId]/overview/chart-view.tsxindex 9304b45284f..e1fca90c5db 100644--- a/web/app/(commonLayout)/app/(appDetailLayout)/[appId]/overview/chart-view.tsx+++ b/web/app/(commonLayout)/app/(appDetailLayout)/[appId]/overview/chart-view.tsx@@ -2,7 +2,8 @@import type { PeriodParams } from '@/app/components/app/overview/app-chart'import dayjs from 'dayjs'import quarterOfYear from 'dayjs/plugin/quarterOfYear'-import React, { useState } from 'react'+import * as React from 'react'+import { useState } from 'react'import { useTranslation } from 'react-i18next'import { TIME_PERIOD_MAPPING as LONG_TIME_PERIOD_MAPPING } from '@/app/components/app/log/filter'import { AvgResponseTime, AvgSessionInteractions, AvgUserInteractions, ConversationsChart, CostChart, EndUsersChart, MessagesChart, TokenPerSecond, UserSatisfactionRate, WorkflowCostChart, WorkflowDailyTerminalsChart, WorkflowMessagesChart } from '@/app/components/app/overview/app-chart'diff --git a/web/app/(commonLayout)/app/(appDetailLayout)/[appId]/overview/long-time-range-picker.tsx b/web/app/(commonLayout)/app/(appDetailLayout)/[appId]/overview/long-time-range-picker.tsxindex 4d59f4a67f0..557b723259a 100644--- a/web/app/(commonLayout)/app/(appDetailLayout)/[appId]/overview/long-time-range-picker.tsx+++ b/web/app/(commonLayout)/app/(appDetailLayout)/[appId]/overview/long-time-range-picker.tsx@@ -3,7 +3,7 @@ import type { FC } from 'react'import type { PeriodParams } from '@/app/components/app/overview/app-chart'import type { Item } from '@/app/components/base/select'import dayjs from 'dayjs'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import { SimpleSelect } from '@/app/components/base/select'diff --git a/web/app/(commonLayout)/app/(appDetailLayout)/[appId]/overview/page.tsx b/web/app/(commonLayout)/app/(appDetailLayout)/[appId]/overview/page.tsxindex e7ee4eb2037..39c42d067d1 100644--- a/web/app/(commonLayout)/app/(appDetailLayout)/[appId]/overview/page.tsx+++ b/web/app/(commonLayout)/app/(appDetailLayout)/[appId]/overview/page.tsx@@ -1,4 +1,4 @@-import React from 'react'+import * as React from 'react'import ApikeyInfoPanel from '@/app/components/app/overview/apikey-info-panel'import ChartView from './chart-view'import TracingPanel from './tracing/panel'diff --git a/web/app/(commonLayout)/app/(appDetailLayout)/[appId]/overview/time-range-picker/date-picker.tsx b/web/app/(commonLayout)/app/(appDetailLayout)/[appId]/overview/time-range-picker/date-picker.tsxindex bc8bf583548..ab39846a363 100644--- a/web/app/(commonLayout)/app/(appDetailLayout)/[appId]/overview/time-range-picker/date-picker.tsx+++ b/web/app/(commonLayout)/app/(appDetailLayout)/[appId]/overview/time-range-picker/date-picker.tsx@@ -5,7 +5,8 @@ import type { TriggerProps } from '@/app/components/base/date-and-time-picker/tyimport { RiCalendarLine } from '@remixicon/react'import dayjs from 'dayjs'import { noop } from 'lodash-es'-import React, { useCallback } from 'react'+import * as React from 'react'+import { useCallback } from 'react'import Picker from '@/app/components/base/date-and-time-picker/date-picker'import { useI18N } from '@/context/i18n'import { cn } from '@/utils/classnames'diff --git a/web/app/(commonLayout)/app/(appDetailLayout)/[appId]/overview/time-range-picker/index.tsx b/web/app/(commonLayout)/app/(appDetailLayout)/[appId]/overview/time-range-picker/index.tsxindex 2a6dca33d76..469bc97737b 100644--- a/web/app/(commonLayout)/app/(appDetailLayout)/[appId]/overview/time-range-picker/index.tsx+++ b/web/app/(commonLayout)/app/(appDetailLayout)/[appId]/overview/time-range-picker/index.tsx@@ -3,7 +3,8 @@ import type { Dayjs } from 'dayjs'import type { FC } from 'react'import type { PeriodParams, PeriodParamsWithTimeRange } from '@/app/components/app/overview/app-chart'import dayjs from 'dayjs'-import React, { useCallback, useState } from 'react'+import * as React from 'react'+import { useCallback, useState } from 'react'import { HourglassShape } from '@/app/components/base/icons/src/vender/other'import { useI18N } from '@/context/i18n'import { formatToLocalTime } from '@/utils/format'diff --git a/web/app/(commonLayout)/app/(appDetailLayout)/[appId]/overview/time-range-picker/range-selector.tsx b/web/app/(commonLayout)/app/(appDetailLayout)/[appId]/overview/time-range-picker/range-selector.tsxindex e820ae46e11..be7181c7593 100644--- a/web/app/(commonLayout)/app/(appDetailLayout)/[appId]/overview/time-range-picker/range-selector.tsx+++ b/web/app/(commonLayout)/app/(appDetailLayout)/[appId]/overview/time-range-picker/range-selector.tsx@@ -4,7 +4,8 @@ import type { PeriodParamsWithTimeRange, TimeRange } from '@/app/components/app/import type { Item } from '@/app/components/base/select'import { RiArrowDownSLine, RiCheckLine } from '@remixicon/react'import dayjs from 'dayjs'-import React, { useCallback } from 'react'+import * as React from 'react'+import { useCallback } from 'react'import { useTranslation } from 'react-i18next'import { SimpleSelect } from '@/app/components/base/select'import { cn } from '@/utils/classnames'diff --git a/web/app/(commonLayout)/app/(appDetailLayout)/[appId]/overview/tracing/__tests__/svg-attribute-error-reproduction.spec.tsx b/web/app/(commonLayout)/app/(appDetailLayout)/[appId]/overview/tracing/__tests__/svg-attribute-error-reproduction.spec.tsxindex a08a1476d71..fc27f84c608 100644--- a/web/app/(commonLayout)/app/(appDetailLayout)/[appId]/overview/tracing/__tests__/svg-attribute-error-reproduction.spec.tsx+++ b/web/app/(commonLayout)/app/(appDetailLayout)/[appId]/overview/tracing/__tests__/svg-attribute-error-reproduction.spec.tsx@@ -1,5 +1,5 @@import { render } from '@testing-library/react'-import React from 'react'+import * as React from 'react'import { OpikIconBig } from '@/app/components/base/icons/src/public/tracing'import iconData from '@/app/components/base/icons/src/public/tracing/OpikIconBig.json'import { normalizeAttrs } from '@/app/components/base/icons/utils'diff --git a/web/app/(commonLayout)/app/(appDetailLayout)/[appId]/overview/tracing/config-button.tsx b/web/app/(commonLayout)/app/(appDetailLayout)/[appId]/overview/tracing/config-button.tsxindex 8dbb410f8ce..8429f8a3a91 100644--- a/web/app/(commonLayout)/app/(appDetailLayout)/[appId]/overview/tracing/config-button.tsx+++ b/web/app/(commonLayout)/app/(appDetailLayout)/[appId]/overview/tracing/config-button.tsx@@ -2,7 +2,8 @@import type { FC } from 'react'import type { PopupProps } from './config-popup'-import React, { useCallback, useRef, useState } from 'react'+import * as React from 'react'+import { useCallback, useRef, useState } from 'react'import {PortalToFollowElem,PortalToFollowElemContent,diff --git a/web/app/(commonLayout)/app/(appDetailLayout)/[appId]/overview/tracing/config-popup.tsx b/web/app/(commonLayout)/app/(appDetailLayout)/[appId]/overview/tracing/config-popup.tsxindex 3cbfcb4315a..35ab8a61eca 100644--- a/web/app/(commonLayout)/app/(appDetailLayout)/[appId]/overview/tracing/config-popup.tsx+++ b/web/app/(commonLayout)/app/(appDetailLayout)/[appId]/overview/tracing/config-popup.tsx@@ -2,7 +2,8 @@import type { FC, JSX } from 'react'import type { AliyunConfig, ArizeConfig, DatabricksConfig, LangFuseConfig, LangSmithConfig, MLflowConfig, OpikConfig, PhoenixConfig, TencentConfig, WeaveConfig } from './type'import { useBoolean } from 'ahooks'-import React, { useCallback, useState } from 'react'+import * as React from 'react'+import { useCallback, useState } from 'react'import { useTranslation } from 'react-i18next'import Divider from '@/app/components/base/divider'import Switch from '@/app/components/base/switch'diff --git a/web/app/(commonLayout)/app/(appDetailLayout)/[appId]/overview/tracing/field.tsx b/web/app/(commonLayout)/app/(appDetailLayout)/[appId]/overview/tracing/field.tsxindex a827a2b80c0..7c472498304 100644--- a/web/app/(commonLayout)/app/(appDetailLayout)/[appId]/overview/tracing/field.tsx+++ b/web/app/(commonLayout)/app/(appDetailLayout)/[appId]/overview/tracing/field.tsx@@ -1,6 +1,6 @@'use client'import type { FC } from 'react'-import React from 'react'+import * as React from 'react'import Input from '@/app/components/base/input'import { cn } from '@/utils/classnames'diff --git a/web/app/(commonLayout)/app/(appDetailLayout)/[appId]/overview/tracing/panel.tsx b/web/app/(commonLayout)/app/(appDetailLayout)/[appId]/overview/tracing/panel.tsxindex 1ea89012e3a..438dbddfb8b 100644--- a/web/app/(commonLayout)/app/(appDetailLayout)/[appId]/overview/tracing/panel.tsx+++ b/web/app/(commonLayout)/app/(appDetailLayout)/[appId]/overview/tracing/panel.tsx@@ -8,7 +8,8 @@ import {} from '@remixicon/react'import { useBoolean } from 'ahooks'import { usePathname } from 'next/navigation'-import React, { useEffect, useState } from 'react'+import * as React from 'react'+import { useEffect, useState } from 'react'import { useTranslation } from 'react-i18next'import Divider from '@/app/components/base/divider'import { AliyunIcon, ArizeIcon, DatabricksIcon, LangfuseIcon, LangsmithIcon, MlflowIcon, OpikIcon, PhoenixIcon, TencentIcon, WeaveIcon } from '@/app/components/base/icons/src/public/tracing'diff --git a/web/app/(commonLayout)/app/(appDetailLayout)/[appId]/overview/tracing/provider-config-modal.tsx b/web/app/(commonLayout)/app/(appDetailLayout)/[appId]/overview/tracing/provider-config-modal.tsxindex 254ca4e01a2..0ef97e69706 100644--- a/web/app/(commonLayout)/app/(appDetailLayout)/[appId]/overview/tracing/provider-config-modal.tsx+++ b/web/app/(commonLayout)/app/(appDetailLayout)/[appId]/overview/tracing/provider-config-modal.tsx@@ -2,7 +2,8 @@import type { FC } from 'react'import type { AliyunConfig, ArizeConfig, DatabricksConfig, LangFuseConfig, LangSmithConfig, MLflowConfig, OpikConfig, PhoenixConfig, TencentConfig, WeaveConfig } from './type'import { useBoolean } from 'ahooks'-import React, { useCallback, useState } from 'react'+import * as React from 'react'+import { useCallback, useState } from 'react'import { useTranslation } from 'react-i18next'import Button from '@/app/components/base/button'import Confirm from '@/app/components/base/confirm'diff --git a/web/app/(commonLayout)/app/(appDetailLayout)/[appId]/overview/tracing/provider-panel.tsx b/web/app/(commonLayout)/app/(appDetailLayout)/[appId]/overview/tracing/provider-panel.tsxindex aebdf70b55f..6c66b19ad34 100644--- a/web/app/(commonLayout)/app/(appDetailLayout)/[appId]/overview/tracing/provider-panel.tsx+++ b/web/app/(commonLayout)/app/(appDetailLayout)/[appId]/overview/tracing/provider-panel.tsx@@ -3,7 +3,8 @@ import type { FC } from 'react'import {RiEqualizer2Line,} from '@remixicon/react'-import React, { useCallback } from 'react'+import * as React from 'react'+import { useCallback } from 'react'import { useTranslation } from 'react-i18next'import { AliyunIconBig, ArizeIconBig, DatabricksIconBig, LangfuseIconBig, LangsmithIconBig, MlflowIconBig, OpikIconBig, PhoenixIconBig, TencentIconBig, WeaveIconBig } from '@/app/components/base/icons/src/public/tracing'import { Eye as View } from '@/app/components/base/icons/src/vender/solid/general'diff --git a/web/app/(commonLayout)/app/(appDetailLayout)/[appId]/overview/tracing/tracing-icon.tsx b/web/app/(commonLayout)/app/(appDetailLayout)/[appId]/overview/tracing/tracing-icon.tsxindex aa8567548da..137fff05df3 100644--- a/web/app/(commonLayout)/app/(appDetailLayout)/[appId]/overview/tracing/tracing-icon.tsx+++ b/web/app/(commonLayout)/app/(appDetailLayout)/[appId]/overview/tracing/tracing-icon.tsx@@ -1,6 +1,6 @@'use client'import type { FC } from 'react'-import React from 'react'+import * as React from 'react'import { TracingIcon as Icon } from '@/app/components/base/icons/src/public/tracing'import { cn } from '@/utils/classnames'diff --git a/web/app/(commonLayout)/app/(appDetailLayout)/layout.tsx b/web/app/(commonLayout)/app/(appDetailLayout)/layout.tsxindex f41babeb4e7..4135482dd91 100644--- a/web/app/(commonLayout)/app/(appDetailLayout)/layout.tsx+++ b/web/app/(commonLayout)/app/(appDetailLayout)/layout.tsx@@ -1,7 +1,8 @@'use client'import type { FC } from 'react'import { useRouter } from 'next/navigation'-import React, { useEffect } from 'react'+import * as React from 'react'+import { useEffect } from 'react'import { useTranslation } from 'react-i18next'import { useAppContext } from '@/context/app-context'import useDocumentTitle from '@/hooks/use-document-title'diff --git a/web/app/(commonLayout)/datasets/(datasetDetailLayout)/[datasetId]/api/page.tsx b/web/app/(commonLayout)/datasets/(datasetDetailLayout)/[datasetId]/api/page.tsxindex 167520ca7b6..200fc994ea2 100644--- a/web/app/(commonLayout)/datasets/(datasetDetailLayout)/[datasetId]/api/page.tsx+++ b/web/app/(commonLayout)/datasets/(datasetDetailLayout)/[datasetId]/api/page.tsx@@ -1,4 +1,4 @@-import React from 'react'+import * as React from 'react'const page = () => {return (diff --git a/web/app/(commonLayout)/datasets/(datasetDetailLayout)/[datasetId]/documents/[documentId]/page.tsx b/web/app/(commonLayout)/datasets/(datasetDetailLayout)/[datasetId]/documents/[documentId]/page.tsxindex ed6365c8905..dd51c84bcf9 100644--- a/web/app/(commonLayout)/datasets/(datasetDetailLayout)/[datasetId]/documents/[documentId]/page.tsx+++ b/web/app/(commonLayout)/datasets/(datasetDetailLayout)/[datasetId]/documents/[documentId]/page.tsx@@ -1,4 +1,4 @@-import React from 'react'+import * as React from 'react'import MainDetail from '@/app/components/datasets/documents/detail'export type IDocumentDetailProps = {diff --git a/web/app/(commonLayout)/datasets/(datasetDetailLayout)/[datasetId]/documents/[documentId]/settings/page.tsx b/web/app/(commonLayout)/datasets/(datasetDetailLayout)/[datasetId]/documents/[documentId]/settings/page.tsxindex e8576d4a4b9..cd9a37b4265 100644--- a/web/app/(commonLayout)/datasets/(datasetDetailLayout)/[datasetId]/documents/[documentId]/settings/page.tsx+++ b/web/app/(commonLayout)/datasets/(datasetDetailLayout)/[datasetId]/documents/[documentId]/settings/page.tsx@@ -1,4 +1,4 @@-import React from 'react'+import * as React from 'react'import Settings from '@/app/components/datasets/documents/detail/settings'export type IProps = {diff --git a/web/app/(commonLayout)/datasets/(datasetDetailLayout)/[datasetId]/documents/create-from-pipeline/page.tsx b/web/app/(commonLayout)/datasets/(datasetDetailLayout)/[datasetId]/documents/create-from-pipeline/page.tsxindex 9ce86bbef4c..046f69dab2b 100644--- a/web/app/(commonLayout)/datasets/(datasetDetailLayout)/[datasetId]/documents/create-from-pipeline/page.tsx+++ b/web/app/(commonLayout)/datasets/(datasetDetailLayout)/[datasetId]/documents/create-from-pipeline/page.tsx@@ -1,4 +1,4 @@-import React from 'react'+import * as React from 'react'import CreateFromPipeline from '@/app/components/datasets/documents/create-from-pipeline'const CreateFromPipelinePage = async () => {diff --git a/web/app/(commonLayout)/datasets/(datasetDetailLayout)/[datasetId]/documents/create/page.tsx b/web/app/(commonLayout)/datasets/(datasetDetailLayout)/[datasetId]/documents/create/page.tsxindex 8fd2caa246c..987bd1ea705 100644--- a/web/app/(commonLayout)/datasets/(datasetDetailLayout)/[datasetId]/documents/create/page.tsx+++ b/web/app/(commonLayout)/datasets/(datasetDetailLayout)/[datasetId]/documents/create/page.tsx@@ -1,4 +1,4 @@-import React from 'react'+import * as React from 'react'import DatasetUpdateForm from '@/app/components/datasets/create'export type IProps = {diff --git a/web/app/(commonLayout)/datasets/(datasetDetailLayout)/[datasetId]/documents/page.tsx b/web/app/(commonLayout)/datasets/(datasetDetailLayout)/[datasetId]/documents/page.tsxindex 2ff4631deae..7a049e0b1b2 100644--- a/web/app/(commonLayout)/datasets/(datasetDetailLayout)/[datasetId]/documents/page.tsx+++ b/web/app/(commonLayout)/datasets/(datasetDetailLayout)/[datasetId]/documents/page.tsx@@ -1,4 +1,4 @@-import React from 'react'+import * as React from 'react'import Main from '@/app/components/datasets/documents'export type IProps = {diff --git a/web/app/(commonLayout)/datasets/(datasetDetailLayout)/[datasetId]/hitTesting/page.tsx b/web/app/(commonLayout)/datasets/(datasetDetailLayout)/[datasetId]/hitTesting/page.tsxindex 9a701c68f5c..9a339030b97 100644--- a/web/app/(commonLayout)/datasets/(datasetDetailLayout)/[datasetId]/hitTesting/page.tsx+++ b/web/app/(commonLayout)/datasets/(datasetDetailLayout)/[datasetId]/hitTesting/page.tsx@@ -1,4 +1,4 @@-import React from 'react'+import * as React from 'react'import Main from '@/app/components/datasets/hit-testing'type Props = {diff --git a/web/app/(commonLayout)/datasets/(datasetDetailLayout)/[datasetId]/layout-main.tsx b/web/app/(commonLayout)/datasets/(datasetDetailLayout)/[datasetId]/layout-main.tsxindex 6caecc4826f..10a12d75e14 100644--- a/web/app/(commonLayout)/datasets/(datasetDetailLayout)/[datasetId]/layout-main.tsx+++ b/web/app/(commonLayout)/datasets/(datasetDetailLayout)/[datasetId]/layout-main.tsx@@ -10,7 +10,8 @@ import {RiFocus2Line,} from '@remixicon/react'import { usePathname } from 'next/navigation'-import React, { useEffect, useMemo, useState } from 'react'+import * as React from 'react'+import { useEffect, useMemo, useState } from 'react'import { useTranslation } from 'react-i18next'import AppSideBar from '@/app/components/app-sidebar'import { useStore } from '@/app/components/app/store'diff --git a/web/app/(commonLayout)/datasets/(datasetDetailLayout)/[datasetId]/settings/page.tsx b/web/app/(commonLayout)/datasets/(datasetDetailLayout)/[datasetId]/settings/page.tsxindex 59540a18547..9dfeaef5280 100644--- a/web/app/(commonLayout)/datasets/(datasetDetailLayout)/[datasetId]/settings/page.tsx+++ b/web/app/(commonLayout)/datasets/(datasetDetailLayout)/[datasetId]/settings/page.tsx@@ -1,4 +1,4 @@-import React from 'react'+import * as React from 'react'import Form from '@/app/components/datasets/settings/form'import { getLocaleOnServer, useTranslation as translate } from '@/i18n-config/server'diff --git a/web/app/(commonLayout)/datasets/(datasetDetailLayout)/layout.tsx b/web/app/(commonLayout)/datasets/(datasetDetailLayout)/layout.tsxindex ccbc58f5e5c..09555ae0f03 100644--- a/web/app/(commonLayout)/datasets/(datasetDetailLayout)/layout.tsx+++ b/web/app/(commonLayout)/datasets/(datasetDetailLayout)/layout.tsx@@ -1,5 +1,5 @@import type { FC } from 'react'-import React from 'react'+import * as React from 'react'export type IDatasetDetail = {children: React.ReactNodediff --git a/web/app/(commonLayout)/datasets/connect/page.tsx b/web/app/(commonLayout)/datasets/connect/page.tsxindex 724c506a7f4..1ac4dc2f7ca 100644--- a/web/app/(commonLayout)/datasets/connect/page.tsx+++ b/web/app/(commonLayout)/datasets/connect/page.tsx@@ -1,4 +1,4 @@-import React from 'react'+import * as React from 'react'import ExternalKnowledgeBaseConnector from '@/app/components/datasets/external-knowledge-base/connector'const ExternalKnowledgeBaseCreation = () => {diff --git a/web/app/(commonLayout)/datasets/create-from-pipeline/page.tsx b/web/app/(commonLayout)/datasets/create-from-pipeline/page.tsxindex 72f5ecdfd9a..63f09655b37 100644--- a/web/app/(commonLayout)/datasets/create-from-pipeline/page.tsx+++ b/web/app/(commonLayout)/datasets/create-from-pipeline/page.tsx@@ -1,4 +1,4 @@-import React from 'react'+import * as React from 'react'import CreateFromPipeline from '@/app/components/datasets/create-from-pipeline'const DatasetCreation = async () => {diff --git a/web/app/(commonLayout)/datasets/create/page.tsx b/web/app/(commonLayout)/datasets/create/page.tsxindex 50fd1f5a191..fe5765437fa 100644--- a/web/app/(commonLayout)/datasets/create/page.tsx+++ b/web/app/(commonLayout)/datasets/create/page.tsx@@ -1,4 +1,4 @@-import React from 'react'+import * as React from 'react'import DatasetUpdateForm from '@/app/components/datasets/create'const DatasetCreation = async () => {diff --git a/web/app/(commonLayout)/explore/apps/page.tsx b/web/app/(commonLayout)/explore/apps/page.tsxindex b2430605e7f..e0da5d64d27 100644--- a/web/app/(commonLayout)/explore/apps/page.tsx+++ b/web/app/(commonLayout)/explore/apps/page.tsx@@ -1,4 +1,4 @@-import React from 'react'+import * as React from 'react'import AppList from '@/app/components/explore/app-list'const Apps = () => {diff --git a/web/app/(commonLayout)/explore/installed/[appId]/page.tsx b/web/app/(commonLayout)/explore/installed/[appId]/page.tsxindex 983fdb9d23f..0b71d1a26c1 100644--- a/web/app/(commonLayout)/explore/installed/[appId]/page.tsx+++ b/web/app/(commonLayout)/explore/installed/[appId]/page.tsx@@ -1,4 +1,4 @@-import React from 'react'+import * as React from 'react'import Main from '@/app/components/explore/installed-app'export type IInstalledAppProps = {diff --git a/web/app/(commonLayout)/explore/layout.tsx b/web/app/(commonLayout)/explore/layout.tsxindex 46bd41cb0cb..5928308cdca 100644--- a/web/app/(commonLayout)/explore/layout.tsx+++ b/web/app/(commonLayout)/explore/layout.tsx@@ -1,6 +1,6 @@'use client'import type { FC, PropsWithChildren } from 'react'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import ExploreClient from '@/app/components/explore'import useDocumentTitle from '@/hooks/use-document-title'diff --git a/web/app/(commonLayout)/layout.tsx b/web/app/(commonLayout)/layout.tsxindex a759506bf05..91bdb3f99a7 100644--- a/web/app/(commonLayout)/layout.tsx+++ b/web/app/(commonLayout)/layout.tsx@@ -1,5 +1,5 @@import type { ReactNode } from 'react'-import React from 'react'+import * as React from 'react'import AmplitudeProvider from '@/app/components/base/amplitude'import GA, { GaType } from '@/app/components/base/ga'import Zendesk from '@/app/components/base/zendesk'diff --git a/web/app/(commonLayout)/tools/page.tsx b/web/app/(commonLayout)/tools/page.tsxindex 3ea50e70ef7..2d5c1a8e444 100644--- a/web/app/(commonLayout)/tools/page.tsx+++ b/web/app/(commonLayout)/tools/page.tsx@@ -1,7 +1,8 @@'use client'import type { FC } from 'react'import { useRouter } from 'next/navigation'-import React, { useEffect } from 'react'+import * as React from 'react'+import { useEffect } from 'react'import { useTranslation } from 'react-i18next'import ToolProviderList from '@/app/components/tools/provider-list'import { useAppContext } from '@/context/app-context'diff --git a/web/app/(shareLayout)/chat/[token]/page.tsx b/web/app/(shareLayout)/chat/[token]/page.tsxindex 8ce67585f06..b4248aedbcc 100644--- a/web/app/(shareLayout)/chat/[token]/page.tsx+++ b/web/app/(shareLayout)/chat/[token]/page.tsx@@ -1,5 +1,5 @@'use client'-import React from 'react'+import * as React from 'react'import ChatWithHistoryWrap from '@/app/components/base/chat/chat-with-history'import AuthenticatedLayout from '../../components/authenticated-layout'diff --git a/web/app/(shareLayout)/chatbot/[token]/page.tsx b/web/app/(shareLayout)/chatbot/[token]/page.tsxindex 5323d0dacc9..187d736c54e 100644--- a/web/app/(shareLayout)/chatbot/[token]/page.tsx+++ b/web/app/(shareLayout)/chatbot/[token]/page.tsx@@ -1,5 +1,5 @@'use client'-import React from 'react'+import * as React from 'react'import EmbeddedChatbot from '@/app/components/base/chat/embedded-chatbot'import AuthenticatedLayout from '../../components/authenticated-layout'diff --git a/web/app/(shareLayout)/completion/[token]/page.tsx b/web/app/(shareLayout)/completion/[token]/page.tsxindex ae91338b9ae..ba96ac05cb3 100644--- a/web/app/(shareLayout)/completion/[token]/page.tsx+++ b/web/app/(shareLayout)/completion/[token]/page.tsx@@ -1,4 +1,4 @@-import React from 'react'+import * as React from 'react'import Main from '@/app/components/share/text-generation'import AuthenticatedLayout from '../../components/authenticated-layout'diff --git a/web/app/(shareLayout)/components/authenticated-layout.tsx b/web/app/(shareLayout)/components/authenticated-layout.tsxindex 5f436429d31..00288b7a611 100644--- a/web/app/(shareLayout)/components/authenticated-layout.tsx+++ b/web/app/(shareLayout)/components/authenticated-layout.tsx@@ -1,7 +1,8 @@'use client'import { usePathname, useRouter, useSearchParams } from 'next/navigation'-import React, { useCallback, useEffect } from 'react'+import * as React from 'react'+import { useCallback, useEffect } from 'react'import { useTranslation } from 'react-i18next'import AppUnavailable from '@/app/components/base/app-unavailable'import Loading from '@/app/components/base/loading'diff --git a/web/app/(shareLayout)/webapp-signin/components/external-member-sso-auth.tsx b/web/app/(shareLayout)/webapp-signin/components/external-member-sso-auth.tsxindex 091493812f8..0776df036d6 100644--- a/web/app/(shareLayout)/webapp-signin/components/external-member-sso-auth.tsx+++ b/web/app/(shareLayout)/webapp-signin/components/external-member-sso-auth.tsx@@ -1,6 +1,7 @@'use client'import { useRouter, useSearchParams } from 'next/navigation'-import React, { useCallback, useEffect } from 'react'+import * as React from 'react'+import { useCallback, useEffect } from 'react'import AppUnavailable from '@/app/components/base/app-unavailable'import Loading from '@/app/components/base/loading'import Toast from '@/app/components/base/toast'diff --git a/web/app/(shareLayout)/webapp-signin/normalForm.tsx b/web/app/(shareLayout)/webapp-signin/normalForm.tsxindex 2aaa2679621..40d34dcaf54 100644--- a/web/app/(shareLayout)/webapp-signin/normalForm.tsx+++ b/web/app/(shareLayout)/webapp-signin/normalForm.tsx@@ -1,7 +1,8 @@'use client'import { RiContractLine, RiDoorLockLine, RiErrorWarningFill } from '@remixicon/react'import Link from 'next/link'-import React, { useCallback, useEffect, useState } from 'react'+import * as React from 'react'+import { useCallback, useEffect, useState } from 'react'import { useTranslation } from 'react-i18next'import Loading from '@/app/components/base/loading'import { IS_CE_EDITION } from '@/config'diff --git a/web/app/(shareLayout)/webapp-signin/page.tsx b/web/app/(shareLayout)/webapp-signin/page.tsxindex ca380c9398c..cfa0295b28a 100644--- a/web/app/(shareLayout)/webapp-signin/page.tsx+++ b/web/app/(shareLayout)/webapp-signin/page.tsx@@ -1,7 +1,8 @@'use client'import type { FC } from 'react'import { useRouter, useSearchParams } from 'next/navigation'-import React, { useCallback } from 'react'+import * as React from 'react'+import { useCallback } from 'react'import { useTranslation } from 'react-i18next'import AppUnavailable from '@/app/components/base/app-unavailable'import { useGlobalPublicStore } from '@/context/global-public-context'diff --git a/web/app/(shareLayout)/workflow/[token]/page.tsx b/web/app/(shareLayout)/workflow/[token]/page.tsxindex 4f5923e91f7..b2828ee5dbd 100644--- a/web/app/(shareLayout)/workflow/[token]/page.tsx+++ b/web/app/(shareLayout)/workflow/[token]/page.tsx@@ -1,4 +1,4 @@-import React from 'react'+import * as React from 'react'import Main from '@/app/components/share/text-generation'import AuthenticatedLayout from '../../components/authenticated-layout'diff --git a/web/app/account/(commonLayout)/account-page/AvatarWithEdit.tsx b/web/app/account/(commonLayout)/account-page/AvatarWithEdit.tsxindex dd254435bb0..9b65db4eaa5 100644--- a/web/app/account/(commonLayout)/account-page/AvatarWithEdit.tsx+++ b/web/app/account/(commonLayout)/account-page/AvatarWithEdit.tsx@@ -5,7 +5,8 @@ import type { OnImageInput } from '@/app/components/base/app-icon-picker/ImageInimport type { AvatarProps } from '@/app/components/base/avatar'import type { ImageFile } from '@/types/app'import { RiDeleteBin5Line, RiPencilLine } from '@remixicon/react'-import React, { useCallback, useState } from 'react'+import * as React from 'react'+import { useCallback, useState } from 'react'import { useTranslation } from 'react-i18next'import { useContext } from 'use-context-selector'import ImageInput from '@/app/components/base/app-icon-picker/ImageInput'diff --git a/web/app/account/(commonLayout)/account-page/email-change-modal.tsx b/web/app/account/(commonLayout)/account-page/email-change-modal.tsxindex 83e667a1f34..99b4f5c6860 100644--- a/web/app/account/(commonLayout)/account-page/email-change-modal.tsx+++ b/web/app/account/(commonLayout)/account-page/email-change-modal.tsx@@ -2,7 +2,8 @@ import type { ResponseError } from '@/service/fetch'import { RiCloseLine } from '@remixicon/react'import { noop } from 'lodash-es'import { useRouter } from 'next/navigation'-import React, { useState } from 'react'+import * as React from 'react'+import { useState } from 'react'import { Trans, useTranslation } from 'react-i18next'import { useContext } from 'use-context-selector'import Button from '@/app/components/base/button'diff --git a/web/app/account/(commonLayout)/layout.tsx b/web/app/account/(commonLayout)/layout.tsxindex af1ec0afd6c..f264441b867 100644--- a/web/app/account/(commonLayout)/layout.tsx+++ b/web/app/account/(commonLayout)/layout.tsx@@ -1,5 +1,5 @@import type { ReactNode } from 'react'-import React from 'react'+import * as React from 'react'import AmplitudeProvider from '@/app/components/base/amplitude'import GA, { GaType } from '@/app/components/base/ga'import HeaderWrapper from '@/app/components/header/header-wrapper'diff --git a/web/app/account/oauth/authorize/page.tsx b/web/app/account/oauth/authorize/page.tsxindex 9993c27e4bf..bbb96abf4e1 100644--- a/web/app/account/oauth/authorize/page.tsx+++ b/web/app/account/oauth/authorize/page.tsx@@ -9,7 +9,8 @@ import {} from '@remixicon/react'import dayjs from 'dayjs'import { useRouter, useSearchParams } from 'next/navigation'-import React, { useEffect, useRef } from 'react'+import * as React from 'react'+import { useEffect, useRef } from 'react'import { useTranslation } from 'react-i18next'import Avatar from '@/app/components/base/avatar'import Button from '@/app/components/base/button'diff --git a/web/app/activate/page.tsx b/web/app/activate/page.tsxindex 01e4e1a35f3..5852ef54e4e 100644--- a/web/app/activate/page.tsx+++ b/web/app/activate/page.tsx@@ -1,5 +1,5 @@'use client'-import React from 'react'+import * as React from 'react'import { useGlobalPublicStore } from '@/context/global-public-context'import { cn } from '@/utils/classnames'import Header from '../signin/_header'diff --git a/web/app/components/app-sidebar/app-info.tsx b/web/app/components/app-sidebar/app-info.tsxindex e175de5c6ef..497124c7024 100644--- a/web/app/components/app-sidebar/app-info.tsx+++ b/web/app/components/app-sidebar/app-info.tsx@@ -13,7 +13,8 @@ import {} from '@remixicon/react'import dynamic from 'next/dynamic'import { useRouter } from 'next/navigation'-import React, { useCallback, useState } from 'react'+import * as React from 'react'+import { useCallback, useState } from 'react'import { useTranslation } from 'react-i18next'import { useContext } from 'use-context-selector'import CardView from '@/app/(commonLayout)/app/(appDetailLayout)/[appId]/overview/card-view'diff --git a/web/app/components/app-sidebar/app-sidebar-dropdown.tsx b/web/app/components/app-sidebar/app-sidebar-dropdown.tsxindex 30ec906c93a..4d80af8bcb0 100644--- a/web/app/components/app-sidebar/app-sidebar-dropdown.tsx+++ b/web/app/components/app-sidebar/app-sidebar-dropdown.tsx@@ -3,7 +3,8 @@ import {RiEqualizer2Line,RiMenuLine,} from '@remixicon/react'-import React, { useCallback, useRef, useState } from 'react'+import * as React from 'react'+import { useCallback, useRef, useState } from 'react'import { useTranslation } from 'react-i18next'import { useStore as useAppStore } from '@/app/components/app/store'import {diff --git a/web/app/components/app-sidebar/basic.tsx b/web/app/components/app-sidebar/basic.tsxindex 40e95206c84..1503afcdad6 100644--- a/web/app/components/app-sidebar/basic.tsx+++ b/web/app/components/app-sidebar/basic.tsx@@ -1,4 +1,4 @@-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import {ApiAggregate,diff --git a/web/app/components/app-sidebar/dataset-info/dropdown.tsx b/web/app/components/app-sidebar/dataset-info/dropdown.tsxindex f20b35de800..c072bd75474 100644--- a/web/app/components/app-sidebar/dataset-info/dropdown.tsx+++ b/web/app/components/app-sidebar/dataset-info/dropdown.tsx@@ -1,7 +1,8 @@import type { DataSet } from '@/models/datasets'import { RiMoreFill } from '@remixicon/react'import { useRouter } from 'next/navigation'-import React, { useCallback, useState } from 'react'+import * as React from 'react'+import { useCallback, useState } from 'react'import { useTranslation } from 'react-i18next'import { useSelector as useAppContextWithSelector } from '@/context/app-context'import { useDatasetDetailContextWithSelector } from '@/context/dataset-detail'diff --git a/web/app/components/app-sidebar/dataset-info/index.spec.tsx b/web/app/components/app-sidebar/dataset-info/index.spec.tsxindex a03b5da488f..da7eb6d7ff8 100644--- a/web/app/components/app-sidebar/dataset-info/index.spec.tsx+++ b/web/app/components/app-sidebar/dataset-info/index.spec.tsx@@ -2,7 +2,7 @@ import type { DataSet } from '@/models/datasets'import { RiEditLine } from '@remixicon/react'import { render, screen, waitFor } from '@testing-library/react'import userEvent from '@testing-library/user-event'-import React from 'react'+import * as React from 'react'import {ChunkingMode,DatasetPermission,diff --git a/web/app/components/app-sidebar/dataset-info/index.tsx b/web/app/components/app-sidebar/dataset-info/index.tsxindex 43fded35a95..ce409ff13a8 100644--- a/web/app/components/app-sidebar/dataset-info/index.tsx+++ b/web/app/components/app-sidebar/dataset-info/index.tsx@@ -1,7 +1,8 @@'use client'import type { FC } from 'react'import type { DataSet } from '@/models/datasets'-import React, { useMemo } from 'react'+import * as React from 'react'+import { useMemo } from 'react'import { useTranslation } from 'react-i18next'import { useDatasetDetailContextWithSelector } from '@/context/dataset-detail'import { useKnowledge } from '@/hooks/use-knowledge'diff --git a/web/app/components/app-sidebar/dataset-info/menu-item.tsx b/web/app/components/app-sidebar/dataset-info/menu-item.tsxindex 5cc082a19e4..441482283b8 100644--- a/web/app/components/app-sidebar/dataset-info/menu-item.tsx+++ b/web/app/components/app-sidebar/dataset-info/menu-item.tsx@@ -1,5 +1,5 @@import type { RemixiconComponentType } from '@remixicon/react'-import React from 'react'+import * as React from 'react'type MenuItemProps = {name: stringdiff --git a/web/app/components/app-sidebar/dataset-info/menu.tsx b/web/app/components/app-sidebar/dataset-info/menu.tsxindex f4a49b3eea0..a17e0ed96d3 100644--- a/web/app/components/app-sidebar/dataset-info/menu.tsx+++ b/web/app/components/app-sidebar/dataset-info/menu.tsx@@ -1,5 +1,5 @@import { RiDeleteBinLine, RiEditLine, RiFileDownloadLine } from '@remixicon/react'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import { useDatasetDetailContextWithSelector } from '@/context/dataset-detail'import Divider from '../../base/divider'diff --git a/web/app/components/app-sidebar/dataset-sidebar-dropdown.tsx b/web/app/components/app-sidebar/dataset-sidebar-dropdown.tsxindex e8fa050a6d9..d8e26826caa 100644--- a/web/app/components/app-sidebar/dataset-sidebar-dropdown.tsx+++ b/web/app/components/app-sidebar/dataset-sidebar-dropdown.tsx@@ -3,7 +3,8 @@ import type { DataSet } from '@/models/datasets'import {RiMenuLine,} from '@remixicon/react'-import React, { useCallback, useRef, useState } from 'react'+import * as React from 'react'+import { useCallback, useRef, useState } from 'react'import { useTranslation } from 'react-i18next'import {PortalToFollowElem,diff --git a/web/app/components/app-sidebar/index.tsx b/web/app/components/app-sidebar/index.tsxindex 790d5340bc5..afc6bd0f138 100644--- a/web/app/components/app-sidebar/index.tsx+++ b/web/app/components/app-sidebar/index.tsx@@ -1,7 +1,8 @@import type { NavIcon } from './navLink'import { useHover, useKeyPress } from 'ahooks'import { usePathname } from 'next/navigation'-import React, { useCallback, useEffect, useState } from 'react'+import * as React from 'react'+import { useCallback, useEffect, useState } from 'react'import { useShallow } from 'zustand/react/shallow'import { useStore as useAppStore } from '@/app/components/app/store'import { useEventEmitterContextContext } from '@/context/event-emitter'diff --git a/web/app/components/app-sidebar/navLink.spec.tsx b/web/app/components/app-sidebar/navLink.spec.tsxindex 410dae6b2a3..62ef5533860 100644--- a/web/app/components/app-sidebar/navLink.spec.tsx+++ b/web/app/components/app-sidebar/navLink.spec.tsx@@ -1,6 +1,6 @@import type { NavLinkProps } from './navLink'import { render, screen } from '@testing-library/react'-import React from 'react'+import * as React from 'react'import NavLink from './navLink'// Mock Next.js navigationdiff --git a/web/app/components/app-sidebar/navLink.tsx b/web/app/components/app-sidebar/navLink.tsxindex 999c892199d..9d5e319046a 100644--- a/web/app/components/app-sidebar/navLink.tsx+++ b/web/app/components/app-sidebar/navLink.tsx@@ -2,7 +2,7 @@import type { RemixiconComponentType } from '@remixicon/react'import Link from 'next/link'import { useSelectedLayoutSegment } from 'next/navigation'-import React from 'react'+import * as React from 'react'import { cn } from '@/utils/classnames'export type NavIcon = React.ComponentType<diff --git a/web/app/components/app-sidebar/sidebar-animation-issues.spec.tsx b/web/app/components/app-sidebar/sidebar-animation-issues.spec.tsxindex 61f278b5770..5d85b99d9ad 100644--- a/web/app/components/app-sidebar/sidebar-animation-issues.spec.tsx+++ b/web/app/components/app-sidebar/sidebar-animation-issues.spec.tsx@@ -1,5 +1,5 @@import { fireEvent, render, screen } from '@testing-library/react'-import React from 'react'+import * as React from 'react'// Simple Mock Components that reproduce the exact UI issuesconst MockNavLink = ({ name, mode }: { name: string, mode: string }) => {diff --git a/web/app/components/app-sidebar/text-squeeze-fix-verification.spec.tsx b/web/app/components/app-sidebar/text-squeeze-fix-verification.spec.tsxindex 7752e29f463..7c0c8b3acaf 100644--- a/web/app/components/app-sidebar/text-squeeze-fix-verification.spec.tsx+++ b/web/app/components/app-sidebar/text-squeeze-fix-verification.spec.tsx@@ -4,7 +4,7 @@*/import { render } from '@testing-library/react'-import React from 'react'+import * as React from 'react'// Mock Next.js navigationvi.mock('next/navigation', () => ({diff --git a/web/app/components/app-sidebar/toggle-button.tsx b/web/app/components/app-sidebar/toggle-button.tsxindex e144d29e92d..b4dc2e91994 100644--- a/web/app/components/app-sidebar/toggle-button.tsx+++ b/web/app/components/app-sidebar/toggle-button.tsx@@ -1,5 +1,5 @@import { RiArrowLeftSLine, RiArrowRightSLine } from '@remixicon/react'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import { cn } from '@/utils/classnames'import Button from '../base/button'diff --git a/web/app/components/app/annotation/add-annotation-modal/edit-item/index.spec.tsx b/web/app/components/app/annotation/add-annotation-modal/edit-item/index.spec.tsxindex 34fbe93be6d..ce660f7880c 100644--- a/web/app/components/app/annotation/add-annotation-modal/edit-item/index.spec.tsx+++ b/web/app/components/app/annotation/add-annotation-modal/edit-item/index.spec.tsx@@ -1,5 +1,5 @@import { fireEvent, render, screen } from '@testing-library/react'-import React from 'react'+import * as React from 'react'import EditItem, { EditItemType } from './index'describe('AddAnnotationModal/EditItem', () => {diff --git a/web/app/components/app/annotation/add-annotation-modal/edit-item/index.tsx b/web/app/components/app/annotation/add-annotation-modal/edit-item/index.tsxindex 62785d00327..ec532430770 100644--- a/web/app/components/app/annotation/add-annotation-modal/edit-item/index.tsx+++ b/web/app/components/app/annotation/add-annotation-modal/edit-item/index.tsx@@ -1,6 +1,6 @@'use client'import type { FC } from 'react'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import { Robot, User } from '@/app/components/base/icons/src/public/avatar'import Textarea from '@/app/components/base/textarea'diff --git a/web/app/components/app/annotation/add-annotation-modal/index.spec.tsx b/web/app/components/app/annotation/add-annotation-modal/index.spec.tsxindex a0ddcd13d38..6837516b3ca 100644--- a/web/app/components/app/annotation/add-annotation-modal/index.spec.tsx+++ b/web/app/components/app/annotation/add-annotation-modal/index.spec.tsx@@ -1,6 +1,6 @@import type { Mock } from 'vitest'import { act, fireEvent, render, screen, waitFor } from '@testing-library/react'-import React from 'react'+import * as React from 'react'import { useProviderContext } from '@/context/provider-context'import AddAnnotationModal from './index'diff --git a/web/app/components/app/annotation/add-annotation-modal/index.tsx b/web/app/components/app/annotation/add-annotation-modal/index.tsxindex 24ef88681a4..b31fb208229 100644--- a/web/app/components/app/annotation/add-annotation-modal/index.tsx+++ b/web/app/components/app/annotation/add-annotation-modal/index.tsx@@ -1,7 +1,8 @@'use client'import type { FC } from 'react'import type { AnnotationItemBasic } from '../type'-import React, { useState } from 'react'+import * as React from 'react'+import { useState } from 'react'import { useTranslation } from 'react-i18next'import Button from '@/app/components/base/button'import Checkbox from '@/app/components/base/checkbox'diff --git a/web/app/components/app/annotation/batch-action.spec.tsx b/web/app/components/app/annotation/batch-action.spec.tsxindex 8598088702c..8d56dde14aa 100644--- a/web/app/components/app/annotation/batch-action.spec.tsx+++ b/web/app/components/app/annotation/batch-action.spec.tsx@@ -1,5 +1,5 @@import { act, fireEvent, render, screen, waitFor } from '@testing-library/react'-import React from 'react'+import * as React from 'react'import BatchAction from './batch-action'describe('BatchAction', () => {diff --git a/web/app/components/app/annotation/batch-action.tsx b/web/app/components/app/annotation/batch-action.tsxindex 5d170d7054e..491c68a6561 100644--- a/web/app/components/app/annotation/batch-action.tsx+++ b/web/app/components/app/annotation/batch-action.tsx@@ -1,7 +1,7 @@import type { FC } from 'react'import { RiDeleteBinLine } from '@remixicon/react'import { useBoolean } from 'ahooks'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import Confirm from '@/app/components/base/confirm'import Divider from '@/app/components/base/divider'diff --git a/web/app/components/app/annotation/batch-add-annotation-modal/csv-downloader.spec.tsx b/web/app/components/app/annotation/batch-add-annotation-modal/csv-downloader.spec.tsxindex a4ca710b882..a3ab73b339d 100644--- a/web/app/components/app/annotation/batch-add-annotation-modal/csv-downloader.spec.tsx+++ b/web/app/components/app/annotation/batch-add-annotation-modal/csv-downloader.spec.tsx@@ -1,6 +1,6 @@import type { Locale } from '@/i18n-config'import { render, screen } from '@testing-library/react'-import React from 'react'+import * as React from 'react'import I18nContext from '@/context/i18n'import { LanguagesSupported } from '@/i18n-config/language'import CSVDownload from './csv-downloader'diff --git a/web/app/components/app/annotation/batch-add-annotation-modal/csv-downloader.tsx b/web/app/components/app/annotation/batch-add-annotation-modal/csv-downloader.tsxindex d966a3e28aa..4735afb5cb5 100644--- a/web/app/components/app/annotation/batch-add-annotation-modal/csv-downloader.tsx+++ b/web/app/components/app/annotation/batch-add-annotation-modal/csv-downloader.tsx@@ -1,6 +1,6 @@'use client'import type { FC } from 'react'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import {useCSVDownloader,diff --git a/web/app/components/app/annotation/batch-add-annotation-modal/csv-uploader.spec.tsx b/web/app/components/app/annotation/batch-add-annotation-modal/csv-uploader.spec.tsxindex 342d2baecae..6a67ba32079 100644--- a/web/app/components/app/annotation/batch-add-annotation-modal/csv-uploader.spec.tsx+++ b/web/app/components/app/annotation/batch-add-annotation-modal/csv-uploader.spec.tsx@@ -1,6 +1,6 @@import type { Props } from './csv-uploader'import { fireEvent, render, screen, waitFor } from '@testing-library/react'-import React from 'react'+import * as React from 'react'import { ToastContext } from '@/app/components/base/toast'import CSVUploader from './csv-uploader'diff --git a/web/app/components/app/annotation/batch-add-annotation-modal/csv-uploader.tsx b/web/app/components/app/annotation/batch-add-annotation-modal/csv-uploader.tsxindex ac10e636cfd..79e2faf2832 100644--- a/web/app/components/app/annotation/batch-add-annotation-modal/csv-uploader.tsx+++ b/web/app/components/app/annotation/batch-add-annotation-modal/csv-uploader.tsx@@ -1,7 +1,8 @@'use client'import type { FC } from 'react'import { RiDeleteBinLine } from '@remixicon/react'-import React, { useEffect, useRef, useState } from 'react'+import * as React from 'react'+import { useEffect, useRef, useState } from 'react'import { useTranslation } from 'react-i18next'import { useContext } from 'use-context-selector'import Button from '@/app/components/base/button'diff --git a/web/app/components/app/annotation/batch-add-annotation-modal/index.spec.tsx b/web/app/components/app/annotation/batch-add-annotation-modal/index.spec.tsxindex feaa5e27e75..d7458d6b901 100644--- a/web/app/components/app/annotation/batch-add-annotation-modal/index.spec.tsx+++ b/web/app/components/app/annotation/batch-add-annotation-modal/index.spec.tsx@@ -1,7 +1,7 @@import type { Mock } from 'vitest'import type { IBatchModalProps } from './index'import { act, fireEvent, render, screen, waitFor } from '@testing-library/react'-import React from 'react'+import * as React from 'react'import Toast from '@/app/components/base/toast'import { useProviderContext } from '@/context/provider-context'import { annotationBatchImport, checkAnnotationBatchImportProgress } from '@/service/annotation'diff --git a/web/app/components/app/annotation/batch-add-annotation-modal/index.tsx b/web/app/components/app/annotation/batch-add-annotation-modal/index.tsxindex fcba2226563..7fbb745c489 100644--- a/web/app/components/app/annotation/batch-add-annotation-modal/index.tsx+++ b/web/app/components/app/annotation/batch-add-annotation-modal/index.tsx@@ -2,7 +2,8 @@import type { FC } from 'react'import { RiCloseLine } from '@remixicon/react'import { noop } from 'lodash-es'-import React, { useEffect, useState } from 'react'+import * as React from 'react'+import { useEffect, useState } from 'react'import { useTranslation } from 'react-i18next'import Button from '@/app/components/base/button'import Modal from '@/app/components/base/modal'diff --git a/web/app/components/app/annotation/clear-all-annotations-confirm-modal/index.spec.tsx b/web/app/components/app/annotation/clear-all-annotations-confirm-modal/index.spec.tsxindex 5c2bbcf62f7..5dbfd664f8b 100644--- a/web/app/components/app/annotation/clear-all-annotations-confirm-modal/index.spec.tsx+++ b/web/app/components/app/annotation/clear-all-annotations-confirm-modal/index.spec.tsx@@ -1,5 +1,5 @@import { fireEvent, render, screen } from '@testing-library/react'-import React from 'react'+import * as React from 'react'import ClearAllAnnotationsConfirmModal from './index'vi.mock('react-i18next', () => ({diff --git a/web/app/components/app/annotation/clear-all-annotations-confirm-modal/index.tsx b/web/app/components/app/annotation/clear-all-annotations-confirm-modal/index.tsxindex ab8c15eab60..df85f4956bc 100644--- a/web/app/components/app/annotation/clear-all-annotations-confirm-modal/index.tsx+++ b/web/app/components/app/annotation/clear-all-annotations-confirm-modal/index.tsx@@ -1,7 +1,7 @@'use client'import type { FC } from 'react'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import Confirm from '@/app/components/base/confirm'diff --git a/web/app/components/app/annotation/edit-annotation-modal/edit-item/index.tsx b/web/app/components/app/annotation/edit-annotation-modal/edit-item/index.tsxindex 9ba7d9d5fbe..cd03406a670 100644--- a/web/app/components/app/annotation/edit-annotation-modal/edit-item/index.tsx+++ b/web/app/components/app/annotation/edit-annotation-modal/edit-item/index.tsx@@ -1,7 +1,8 @@'use client'import type { FC } from 'react'import { RiDeleteBinLine, RiEditFill, RiEditLine } from '@remixicon/react'-import React, { useEffect, useState } from 'react'+import * as React from 'react'+import { useEffect, useState } from 'react'import { useTranslation } from 'react-i18next'import Button from '@/app/components/base/button'import { Robot, User } from '@/app/components/base/icons/src/public/avatar'diff --git a/web/app/components/app/annotation/edit-annotation-modal/index.tsx b/web/app/components/app/annotation/edit-annotation-modal/index.tsxindex 288ca009bc5..4c4380bc200 100644--- a/web/app/components/app/annotation/edit-annotation-modal/index.tsx+++ b/web/app/components/app/annotation/edit-annotation-modal/index.tsx@@ -1,6 +1,7 @@'use client'import type { FC } from 'react'-import React, { useState } from 'react'+import * as React from 'react'+import { useState } from 'react'import { useTranslation } from 'react-i18next'import Confirm from '@/app/components/base/confirm'import Drawer from '@/app/components/base/drawer-plus'diff --git a/web/app/components/app/annotation/empty-element.spec.tsx b/web/app/components/app/annotation/empty-element.spec.tsxindex 3f96e917fd9..89ba7e9ff8b 100644--- a/web/app/components/app/annotation/empty-element.spec.tsx+++ b/web/app/components/app/annotation/empty-element.spec.tsx@@ -1,5 +1,5 @@import { render, screen } from '@testing-library/react'-import React from 'react'+import * as React from 'react'import EmptyElement from './empty-element'describe('EmptyElement', () => {diff --git a/web/app/components/app/annotation/empty-element.tsx b/web/app/components/app/annotation/empty-element.tsxindex 523f83a7cb9..4f41a59f4f6 100644--- a/web/app/components/app/annotation/empty-element.tsx+++ b/web/app/components/app/annotation/empty-element.tsx@@ -1,6 +1,6 @@'use client'import type { FC, SVGProps } from 'react'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'const ThreeDotsIcon = ({ className }: SVGProps<SVGElement>) => {diff --git a/web/app/components/app/annotation/filter.spec.tsx b/web/app/components/app/annotation/filter.spec.tsxindex 3dfc60d73f1..9b733a8c105 100644--- a/web/app/components/app/annotation/filter.spec.tsx+++ b/web/app/components/app/annotation/filter.spec.tsx@@ -1,7 +1,7 @@import type { Mock } from 'vitest'import type { QueryParam } from './filter'import { fireEvent, render, screen } from '@testing-library/react'-import React from 'react'+import * as React from 'react'import useSWR from 'swr'import Filter from './filter'diff --git a/web/app/components/app/annotation/filter.tsx b/web/app/components/app/annotation/filter.tsxindex 02c2a859bf1..76f33d2f1b4 100644--- a/web/app/components/app/annotation/filter.tsx+++ b/web/app/components/app/annotation/filter.tsx@@ -1,6 +1,6 @@'use client'import type { FC } from 'react'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import useSWR from 'swr'import Input from '@/app/components/base/input'diff --git a/web/app/components/app/annotation/header-opts/index.tsx b/web/app/components/app/annotation/header-opts/index.tsxindex a6c9d71391e..6d2d3658088 100644--- a/web/app/components/app/annotation/header-opts/index.tsx+++ b/web/app/components/app/annotation/header-opts/index.tsx@@ -7,7 +7,8 @@ import {RiDeleteBinLine,RiMoreFill,} from '@remixicon/react'-import React, { Fragment, useEffect, useState } from 'react'+import * as React from 'react'+import { Fragment, useEffect, useState } from 'react'import { useTranslation } from 'react-i18next'import {useCSVDownloader,diff --git a/web/app/components/app/annotation/index.spec.tsx b/web/app/components/app/annotation/index.spec.tsxindex 202b631f65c..2d989a9a59e 100644--- a/web/app/components/app/annotation/index.spec.tsx+++ b/web/app/components/app/annotation/index.spec.tsx@@ -2,7 +2,7 @@ import type { Mock } from 'vitest'import type { AnnotationItem } from './type'import type { App } from '@/types/app'import { act, fireEvent, render, screen, waitFor } from '@testing-library/react'-import React from 'react'+import * as React from 'react'import Toast from '@/app/components/base/toast'import { useProviderContext } from '@/context/provider-context'import {diff --git a/web/app/components/app/annotation/index.tsx b/web/app/components/app/annotation/index.tsxindex c673db2c289..18175193dbd 100644--- a/web/app/components/app/annotation/index.tsx+++ b/web/app/components/app/annotation/index.tsx@@ -6,7 +6,8 @@ import type { AnnotationReplyConfig } from '@/models/debug'import type { App } from '@/types/app'import { RiEqualizer2Line } from '@remixicon/react'import { useDebounce } from 'ahooks'-import React, { useEffect, useState } from 'react'+import * as React from 'react'+import { useEffect, useState } from 'react'import { useTranslation } from 'react-i18next'import ActionButton from '@/app/components/base/action-button'import ConfigParamModal from '@/app/components/base/features/new-feature-panel/annotation-reply/config-param-modal'diff --git a/web/app/components/app/annotation/list.spec.tsx b/web/app/components/app/annotation/list.spec.tsxindex f0a8aa9d931..37e48327407 100644--- a/web/app/components/app/annotation/list.spec.tsx+++ b/web/app/components/app/annotation/list.spec.tsx@@ -1,6 +1,6 @@import type { AnnotationItem } from './type'import { fireEvent, render, screen, within } from '@testing-library/react'-import React from 'react'+import * as React from 'react'import List from './list'const mockFormatTime = vi.fn(() => 'formatted-time')diff --git a/web/app/components/app/annotation/list.tsx b/web/app/components/app/annotation/list.tsxindex 45e33b1a1a4..4d821aa9940 100644--- a/web/app/components/app/annotation/list.tsx+++ b/web/app/components/app/annotation/list.tsx@@ -2,7 +2,8 @@import type { FC } from 'react'import type { AnnotationItem } from './type'import { RiDeleteBinLine, RiEditLine } from '@remixicon/react'-import React, { useCallback, useMemo } from 'react'+import * as React from 'react'+import { useCallback, useMemo } from 'react'import { useTranslation } from 'react-i18next'import ActionButton from '@/app/components/base/action-button'import Checkbox from '@/app/components/base/checkbox'diff --git a/web/app/components/app/annotation/remove-annotation-confirm-modal/index.spec.tsx b/web/app/components/app/annotation/remove-annotation-confirm-modal/index.spec.tsxindex e26ea691c60..db3bb63c439 100644--- a/web/app/components/app/annotation/remove-annotation-confirm-modal/index.spec.tsx+++ b/web/app/components/app/annotation/remove-annotation-confirm-modal/index.spec.tsx@@ -1,5 +1,5 @@import { fireEvent, render, screen } from '@testing-library/react'-import React from 'react'+import * as React from 'react'import RemoveAnnotationConfirmModal from './index'vi.mock('react-i18next', () => ({diff --git a/web/app/components/app/annotation/remove-annotation-confirm-modal/index.tsx b/web/app/components/app/annotation/remove-annotation-confirm-modal/index.tsxindex a6ade49a797..bf21c95d8a4 100644--- a/web/app/components/app/annotation/remove-annotation-confirm-modal/index.tsx+++ b/web/app/components/app/annotation/remove-annotation-confirm-modal/index.tsx@@ -1,6 +1,6 @@'use client'import type { FC } from 'react'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import Confirm from '@/app/components/base/confirm'diff --git a/web/app/components/app/annotation/view-annotation-modal/hit-history-no-data.tsx b/web/app/components/app/annotation/view-annotation-modal/hit-history-no-data.tsxindex cebb5630eb6..52f360feccb 100644--- a/web/app/components/app/annotation/view-annotation-modal/hit-history-no-data.tsx+++ b/web/app/components/app/annotation/view-annotation-modal/hit-history-no-data.tsx@@ -1,6 +1,6 @@'use client'import type { FC } from 'react'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import { ClockFastForward } from '@/app/components/base/icons/src/vender/line/time'diff --git a/web/app/components/app/annotation/view-annotation-modal/index.spec.tsx b/web/app/components/app/annotation/view-annotation-modal/index.spec.tsxindex 9fe8e585f4a..3eb278b874e 100644--- a/web/app/components/app/annotation/view-annotation-modal/index.spec.tsx+++ b/web/app/components/app/annotation/view-annotation-modal/index.spec.tsx@@ -1,7 +1,7 @@import type { Mock } from 'vitest'import type { AnnotationItem, HitHistoryItem } from '../type'import { fireEvent, render, screen, waitFor } from '@testing-library/react'-import React from 'react'+import * as React from 'react'import { fetchHitHistoryList } from '@/service/annotation'import ViewAnnotationModal from './index'diff --git a/web/app/components/app/annotation/view-annotation-modal/index.tsx b/web/app/components/app/annotation/view-annotation-modal/index.tsxindex f2db6de7c01..8f24a830bbf 100644--- a/web/app/components/app/annotation/view-annotation-modal/index.tsx+++ b/web/app/components/app/annotation/view-annotation-modal/index.tsx@@ -1,7 +1,8 @@'use client'import type { FC } from 'react'import type { AnnotationItem, HitHistoryItem } from '../type'-import React, { useEffect, useState } from 'react'+import * as React from 'react'+import { useEffect, useState } from 'react'import { useTranslation } from 'react-i18next'import Badge from '@/app/components/base/badge'import Confirm from '@/app/components/base/confirm'diff --git a/web/app/components/app/app-publisher/features-wrapper.tsx b/web/app/components/app/app-publisher/features-wrapper.tsxindex 35d97287285..8257b69fca5 100644--- a/web/app/components/app/app-publisher/features-wrapper.tsx+++ b/web/app/components/app/app-publisher/features-wrapper.tsx@@ -2,7 +2,8 @@ import type { AppPublisherProps } from '@/app/components/app/app-publisher'import type { ModelAndParameter } from '@/app/components/app/configuration/debug/types'import type { FileUpload } from '@/app/components/base/features/types'import { produce } from 'immer'-import React, { useCallback, useState } from 'react'+import * as React from 'react'+import { useCallback, useState } from 'react'import { useTranslation } from 'react-i18next'import AppPublisher from '@/app/components/app/app-publisher'import Confirm from '@/app/components/base/confirm'diff --git a/web/app/components/app/app-publisher/version-info-modal.tsx b/web/app/components/app/app-publisher/version-info-modal.tsxindex 647dc57f367..ba8b7a30741 100644--- a/web/app/components/app/app-publisher/version-info-modal.tsx+++ b/web/app/components/app/app-publisher/version-info-modal.tsx@@ -1,7 +1,8 @@import type { FC } from 'react'import type { VersionHistory } from '@/types/workflow'import { RiCloseLine } from '@remixicon/react'-import React, { useCallback, useState } from 'react'+import * as React from 'react'+import { useCallback, useState } from 'react'import { useTranslation } from 'react-i18next'import Modal from '@/app/components/base/modal'import Toast from '@/app/components/base/toast'diff --git a/web/app/components/app/configuration/base/feature-panel/index.tsx b/web/app/components/app/configuration/base/feature-panel/index.tsxindex b69de31ac4d..20c4a8dc177 100644--- a/web/app/components/app/configuration/base/feature-panel/index.tsx+++ b/web/app/components/app/configuration/base/feature-panel/index.tsx@@ -1,6 +1,6 @@'use client'import type { FC, ReactNode } from 'react'-import React from 'react'+import * as React from 'react'import { cn } from '@/utils/classnames'export type IFeaturePanelProps = {diff --git a/web/app/components/app/configuration/base/group-name/index.tsx b/web/app/components/app/configuration/base/group-name/index.tsxindex 1ae31078760..b21b0c5825d 100644--- a/web/app/components/app/configuration/base/group-name/index.tsx+++ b/web/app/components/app/configuration/base/group-name/index.tsx@@ -1,6 +1,6 @@'use client'import type { FC } from 'react'-import React from 'react'+import * as React from 'react'export type IGroupNameProps = {name: stringdiff --git a/web/app/components/app/configuration/base/operation-btn/index.tsx b/web/app/components/app/configuration/base/operation-btn/index.tsxindex 2deaba37436..b9f55de26b8 100644--- a/web/app/components/app/configuration/base/operation-btn/index.tsx+++ b/web/app/components/app/configuration/base/operation-btn/index.tsx@@ -5,7 +5,7 @@ import {RiEditLine,} from '@remixicon/react'import { noop } from 'lodash-es'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import { cn } from '@/utils/classnames'diff --git a/web/app/components/app/configuration/base/var-highlight/index.tsx b/web/app/components/app/configuration/base/var-highlight/index.tsxindex b2360751c22..697007d0b04 100644--- a/web/app/components/app/configuration/base/var-highlight/index.tsx+++ b/web/app/components/app/configuration/base/var-highlight/index.tsx@@ -1,6 +1,6 @@'use client'import type { FC } from 'react'-import React from 'react'+import * as React from 'react'import s from './style.module.css'diff --git a/web/app/components/app/configuration/base/warning-mask/cannot-query-dataset.spec.tsx b/web/app/components/app/configuration/base/warning-mask/cannot-query-dataset.spec.tsxindex 4ca20f7117f..730b251e67a 100644--- a/web/app/components/app/configuration/base/warning-mask/cannot-query-dataset.spec.tsx+++ b/web/app/components/app/configuration/base/warning-mask/cannot-query-dataset.spec.tsx@@ -1,5 +1,5 @@import { fireEvent, render, screen } from '@testing-library/react'-import React from 'react'+import * as React from 'react'import CannotQueryDataset from './cannot-query-dataset'describe('CannotQueryDataset WarningMask', () => {diff --git a/web/app/components/app/configuration/base/warning-mask/cannot-query-dataset.tsx b/web/app/components/app/configuration/base/warning-mask/cannot-query-dataset.tsxindex 2c916eaf3b6..baa7782b12f 100644--- a/web/app/components/app/configuration/base/warning-mask/cannot-query-dataset.tsx+++ b/web/app/components/app/configuration/base/warning-mask/cannot-query-dataset.tsx@@ -1,6 +1,6 @@'use client'import type { FC } from 'react'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import Button from '@/app/components/base/button'import WarningMask from '.'diff --git a/web/app/components/app/configuration/base/warning-mask/formatting-changed.spec.tsx b/web/app/components/app/configuration/base/warning-mask/formatting-changed.spec.tsxindex 3171e2c183f..9b5a5d93e1a 100644--- a/web/app/components/app/configuration/base/warning-mask/formatting-changed.spec.tsx+++ b/web/app/components/app/configuration/base/warning-mask/formatting-changed.spec.tsx@@ -1,5 +1,5 @@import { fireEvent, render, screen } from '@testing-library/react'-import React from 'react'+import * as React from 'react'import FormattingChanged from './formatting-changed'describe('FormattingChanged WarningMask', () => {diff --git a/web/app/components/app/configuration/base/warning-mask/formatting-changed.tsx b/web/app/components/app/configuration/base/warning-mask/formatting-changed.tsxindex 24bb245b25f..df7d8569f8f 100644--- a/web/app/components/app/configuration/base/warning-mask/formatting-changed.tsx+++ b/web/app/components/app/configuration/base/warning-mask/formatting-changed.tsx@@ -1,6 +1,6 @@'use client'import type { FC } from 'react'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import Button from '@/app/components/base/button'import WarningMask from '.'diff --git a/web/app/components/app/configuration/base/warning-mask/has-not-set-api.spec.tsx b/web/app/components/app/configuration/base/warning-mask/has-not-set-api.spec.tsxindex 24ba0aeb3bd..be4377bfd9b 100644--- a/web/app/components/app/configuration/base/warning-mask/has-not-set-api.spec.tsx+++ b/web/app/components/app/configuration/base/warning-mask/has-not-set-api.spec.tsx@@ -1,5 +1,5 @@import { fireEvent, render, screen } from '@testing-library/react'-import React from 'react'+import * as React from 'react'import HasNotSetAPI from './has-not-set-api'describe('HasNotSetAPI WarningMask', () => {diff --git a/web/app/components/app/configuration/base/warning-mask/has-not-set-api.tsx b/web/app/components/app/configuration/base/warning-mask/has-not-set-api.tsxindex 001a7ff79ee..7be3f2001dd 100644--- a/web/app/components/app/configuration/base/warning-mask/has-not-set-api.tsx+++ b/web/app/components/app/configuration/base/warning-mask/has-not-set-api.tsx@@ -1,6 +1,6 @@'use client'import type { FC } from 'react'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import Button from '@/app/components/base/button'import WarningMask from '.'diff --git a/web/app/components/app/configuration/base/warning-mask/index.spec.tsx b/web/app/components/app/configuration/base/warning-mask/index.spec.tsxindex 9546a3e8d99..cb8ef0b6782 100644--- a/web/app/components/app/configuration/base/warning-mask/index.spec.tsx+++ b/web/app/components/app/configuration/base/warning-mask/index.spec.tsx@@ -1,5 +1,5 @@import { render, screen } from '@testing-library/react'-import React from 'react'+import * as React from 'react'import WarningMask from './index'describe('WarningMask', () => {diff --git a/web/app/components/app/configuration/base/warning-mask/index.tsx b/web/app/components/app/configuration/base/warning-mask/index.tsxindex 3d6fef72a49..6d6aeceb97d 100644--- a/web/app/components/app/configuration/base/warning-mask/index.tsx+++ b/web/app/components/app/configuration/base/warning-mask/index.tsx@@ -1,6 +1,6 @@'use client'import type { FC } from 'react'-import React from 'react'+import * as React from 'react'import s from './style.module.css'diff --git a/web/app/components/app/configuration/config-prompt/advanced-prompt-input.tsx b/web/app/components/app/configuration/config-prompt/advanced-prompt-input.tsxindex a5d97c47f18..15ba089d77f 100644--- a/web/app/components/app/configuration/config-prompt/advanced-prompt-input.tsx+++ b/web/app/components/app/configuration/config-prompt/advanced-prompt-input.tsx@@ -9,7 +9,7 @@ import {import { useBoolean } from 'ahooks'import copy from 'copy-to-clipboard'import { produce } from 'immer'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import { useContext } from 'use-context-selector'import { ADD_EXTERNAL_DATA_TOOL } from '@/app/components/app/configuration/config-var'diff --git a/web/app/components/app/configuration/config-prompt/confirm-add-var/index.spec.tsx b/web/app/components/app/configuration/config-prompt/confirm-add-var/index.spec.tsxindex f732da3f95c..360676f8296 100644--- a/web/app/components/app/configuration/config-prompt/confirm-add-var/index.spec.tsx+++ b/web/app/components/app/configuration/config-prompt/confirm-add-var/index.spec.tsx@@ -1,5 +1,5 @@import { fireEvent, render, screen } from '@testing-library/react'-import React from 'react'+import * as React from 'react'import ConfirmAddVar from './index'vi.mock('../../base/var-highlight', () => ({diff --git a/web/app/components/app/configuration/config-prompt/confirm-add-var/index.tsx b/web/app/components/app/configuration/config-prompt/confirm-add-var/index.tsxindex e8106a790a2..6c149688f42 100644--- a/web/app/components/app/configuration/config-prompt/confirm-add-var/index.tsx+++ b/web/app/components/app/configuration/config-prompt/confirm-add-var/index.tsx@@ -1,6 +1,7 @@'use client'import type { FC } from 'react'-import React, { useRef } from 'react'+import * as React from 'react'+import { useRef } from 'react'import { useTranslation } from 'react-i18next'import Button from '@/app/components/base/button'import VarHighlight from '../../base/var-highlight'diff --git a/web/app/components/app/configuration/config-prompt/conversation-history/edit-modal.spec.tsx b/web/app/components/app/configuration/config-prompt/conversation-history/edit-modal.spec.tsxindex a6033fcb607..e6532d26fce 100644--- a/web/app/components/app/configuration/config-prompt/conversation-history/edit-modal.spec.tsx+++ b/web/app/components/app/configuration/config-prompt/conversation-history/edit-modal.spec.tsx@@ -1,6 +1,6 @@import type { ConversationHistoriesRole } from '@/models/debug'import { fireEvent, render, screen } from '@testing-library/react'-import React from 'react'+import * as React from 'react'import EditModal from './edit-modal'vi.mock('@/app/components/base/modal', () => ({diff --git a/web/app/components/app/configuration/config-prompt/conversation-history/edit-modal.tsx b/web/app/components/app/configuration/config-prompt/conversation-history/edit-modal.tsxindex c21ddeb30ec..741461d53af 100644--- a/web/app/components/app/configuration/config-prompt/conversation-history/edit-modal.tsx+++ b/web/app/components/app/configuration/config-prompt/conversation-history/edit-modal.tsx@@ -1,7 +1,8 @@'use client'import type { FC } from 'react'import type { ConversationHistoriesRole } from '@/models/debug'-import React, { useState } from 'react'+import * as React from 'react'+import { useState } from 'react'import { useTranslation } from 'react-i18next'import Button from '@/app/components/base/button'import Modal from '@/app/components/base/modal'diff --git a/web/app/components/app/configuration/config-prompt/conversation-history/history-panel.spec.tsx b/web/app/components/app/configuration/config-prompt/conversation-history/history-panel.spec.tsxindex 4d3da2afa49..c6f5b3ed19a 100644--- a/web/app/components/app/configuration/config-prompt/conversation-history/history-panel.spec.tsx+++ b/web/app/components/app/configuration/config-prompt/conversation-history/history-panel.spec.tsx@@ -1,5 +1,5 @@import { render, screen } from '@testing-library/react'-import React from 'react'+import * as React from 'react'import HistoryPanel from './history-panel'const mockDocLink = vi.fn(() => 'doc-link')diff --git a/web/app/components/app/configuration/config-prompt/conversation-history/history-panel.tsx b/web/app/components/app/configuration/config-prompt/conversation-history/history-panel.tsxindex b4a133db942..d6df316201f 100644--- a/web/app/components/app/configuration/config-prompt/conversation-history/history-panel.tsx+++ b/web/app/components/app/configuration/config-prompt/conversation-history/history-panel.tsx@@ -1,6 +1,6 @@'use client'import type { FC } from 'react'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import Panel from '@/app/components/app/configuration/base/feature-panel'import OperationBtn from '@/app/components/app/configuration/base/operation-btn'diff --git a/web/app/components/app/configuration/config-prompt/index.spec.tsx b/web/app/components/app/configuration/config-prompt/index.spec.tsxindex f3992d2a052..ceb9cf3f42a 100644--- a/web/app/components/app/configuration/config-prompt/index.spec.tsx+++ b/web/app/components/app/configuration/config-prompt/index.spec.tsx@@ -1,7 +1,7 @@import type { IPromptProps } from './index'import type { PromptItem, PromptVariable } from '@/models/debug'import { fireEvent, render, screen } from '@testing-library/react'-import React from 'react'+import * as React from 'react'import { MAX_PROMPT_MESSAGE_LENGTH } from '@/config'import ConfigContext from '@/context/debug-configuration'import { PromptRole } from '@/models/debug'diff --git a/web/app/components/app/configuration/config-prompt/index.tsx b/web/app/components/app/configuration/config-prompt/index.tsxindex ab13c6fc703..0d30e0d8638 100644--- a/web/app/components/app/configuration/config-prompt/index.tsx+++ b/web/app/components/app/configuration/config-prompt/index.tsx@@ -6,7 +6,7 @@ import {RiAddLine,} from '@remixicon/react'import { produce } from 'immer'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import { useContext } from 'use-context-selector'import AdvancedMessageInput from '@/app/components/app/configuration/config-prompt/advanced-prompt-input'diff --git a/web/app/components/app/configuration/config-prompt/message-type-selector.spec.tsx b/web/app/components/app/configuration/config-prompt/message-type-selector.spec.tsxindex 5354beda8ac..5eb1896dc64 100644--- a/web/app/components/app/configuration/config-prompt/message-type-selector.spec.tsx+++ b/web/app/components/app/configuration/config-prompt/message-type-selector.spec.tsx@@ -1,5 +1,5 @@import { fireEvent, render, screen } from '@testing-library/react'-import React from 'react'+import * as React from 'react'import { PromptRole } from '@/models/debug'import MessageTypeSelector from './message-type-selector'diff --git a/web/app/components/app/configuration/config-prompt/message-type-selector.tsx b/web/app/components/app/configuration/config-prompt/message-type-selector.tsxindex 5bc29da9e49..0b404eea90f 100644--- a/web/app/components/app/configuration/config-prompt/message-type-selector.tsx+++ b/web/app/components/app/configuration/config-prompt/message-type-selector.tsx@@ -1,7 +1,7 @@'use client'import type { FC } from 'react'import { useBoolean, useClickAway } from 'ahooks'-import React from 'react'+import * as React from 'react'import { ChevronSelectorVertical } from '@/app/components/base/icons/src/vender/line/arrows'import { PromptRole } from '@/models/debug'import { cn } from '@/utils/classnames'diff --git a/web/app/components/app/configuration/config-prompt/prompt-editor-height-resize-wrap.spec.tsx b/web/app/components/app/configuration/config-prompt/prompt-editor-height-resize-wrap.spec.tsxindex cfdff405590..abd95e76604 100644--- a/web/app/components/app/configuration/config-prompt/prompt-editor-height-resize-wrap.spec.tsx+++ b/web/app/components/app/configuration/config-prompt/prompt-editor-height-resize-wrap.spec.tsx@@ -1,5 +1,5 @@import { fireEvent, render, screen } from '@testing-library/react'-import React from 'react'+import * as React from 'react'import PromptEditorHeightResizeWrap from './prompt-editor-height-resize-wrap'describe('PromptEditorHeightResizeWrap', () => {diff --git a/web/app/components/app/configuration/config-prompt/prompt-editor-height-resize-wrap.tsx b/web/app/components/app/configuration/config-prompt/prompt-editor-height-resize-wrap.tsxindex 985aa527b09..24c77c1daeb 100644--- a/web/app/components/app/configuration/config-prompt/prompt-editor-height-resize-wrap.tsx+++ b/web/app/components/app/configuration/config-prompt/prompt-editor-height-resize-wrap.tsx@@ -1,7 +1,8 @@'use client'import type { FC } from 'react'import { useDebounceFn } from 'ahooks'-import React, { useCallback, useEffect, useState } from 'react'+import * as React from 'react'+import { useCallback, useEffect, useState } from 'react'import { cn } from '@/utils/classnames'type Props = {diff --git a/web/app/components/app/configuration/config-prompt/simple-prompt-input.tsx b/web/app/components/app/configuration/config-prompt/simple-prompt-input.tsxindex 5d9d4abe1eb..9b558b58c11 100644--- a/web/app/components/app/configuration/config-prompt/simple-prompt-input.tsx+++ b/web/app/components/app/configuration/config-prompt/simple-prompt-input.tsx@@ -6,7 +6,8 @@ import type { GenRes } from '@/service/debug'import { useBoolean } from 'ahooks'import { produce } from 'immer'import { noop } from 'lodash-es'-import React, { useState } from 'react'+import * as React from 'react'+import { useState } from 'react'import { useTranslation } from 'react-i18next'import { useContext } from 'use-context-selector'import { ADD_EXTERNAL_DATA_TOOL } from '@/app/components/app/configuration/config-var'diff --git a/web/app/components/app/configuration/config-var/config-modal/field.tsx b/web/app/components/app/configuration/config-var/config-modal/field.tsxindex 8fe612a82b0..c7a9bbfa030 100644--- a/web/app/components/app/configuration/config-var/config-modal/field.tsx+++ b/web/app/components/app/configuration/config-var/config-modal/field.tsx@@ -1,6 +1,6 @@'use client'import type { FC } from 'react'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import { cn } from '@/utils/classnames'diff --git a/web/app/components/app/configuration/config-var/config-modal/index.tsx b/web/app/components/app/configuration/config-var/config-modal/index.tsxindex 155266469a3..41f37b5895e 100644--- a/web/app/components/app/configuration/config-var/config-modal/index.tsx+++ b/web/app/components/app/configuration/config-var/config-modal/index.tsx@@ -4,7 +4,8 @@ import type { Item as SelectItem } from './type-select'import type { FileEntity } from '@/app/components/base/file-uploader/types'import type { InputVar, MoreInfo, UploadFileSetting } from '@/app/components/workflow/types'import { produce } from 'immer'-import React, { useCallback, useEffect, useMemo, useRef, useState } from 'react'+import * as React from 'react'+import { useCallback, useEffect, useMemo, useRef, useState } from 'react'import { useTranslation } from 'react-i18next'import { useContext } from 'use-context-selector'import { useStore as useAppStore } from '@/app/components/app/store'diff --git a/web/app/components/app/configuration/config-var/config-modal/type-select.tsx b/web/app/components/app/configuration/config-var/config-modal/type-select.tsxindex f4768874095..66ec5a2a69c 100644--- a/web/app/components/app/configuration/config-var/config-modal/type-select.tsx+++ b/web/app/components/app/configuration/config-var/config-modal/type-select.tsx@@ -2,7 +2,8 @@import type { FC } from 'react'import type { InputVarType } from '@/app/components/workflow/types'import { ChevronDownIcon } from '@heroicons/react/20/solid'-import React, { useState } from 'react'+import * as React from 'react'+import { useState } from 'react'import Badge from '@/app/components/base/badge'import {PortalToFollowElem,diff --git a/web/app/components/app/configuration/config-var/config-select/index.tsx b/web/app/components/app/configuration/config-var/config-select/index.tsxindex 565cf772078..61bc8b70236 100644--- a/web/app/components/app/configuration/config-var/config-select/index.tsx+++ b/web/app/components/app/configuration/config-var/config-select/index.tsx@@ -1,7 +1,8 @@'use client'import type { FC } from 'react'import { RiAddLine, RiDeleteBinLine, RiDraggable } from '@remixicon/react'-import React, { useState } from 'react'+import * as React from 'react'+import { useState } from 'react'import { useTranslation } from 'react-i18next'import { ReactSortable } from 'react-sortablejs'import { cn } from '@/utils/classnames'diff --git a/web/app/components/app/configuration/config-var/config-string/index.tsx b/web/app/components/app/configuration/config-var/config-string/index.tsxindex 78f185bd85b..fce687ac3e7 100644--- a/web/app/components/app/configuration/config-var/config-string/index.tsx+++ b/web/app/components/app/configuration/config-var/config-string/index.tsx@@ -1,6 +1,7 @@'use client'import type { FC } from 'react'-import React, { useEffect } from 'react'+import * as React from 'react'+import { useEffect } from 'react'import Input from '@/app/components/base/input'export type IConfigStringProps = {diff --git a/web/app/components/app/configuration/config-var/index.tsx b/web/app/components/app/configuration/config-var/index.tsxindex 092a7aee6cf..7a2a86393a3 100644--- a/web/app/components/app/configuration/config-var/index.tsx+++ b/web/app/components/app/configuration/config-var/index.tsx@@ -5,7 +5,8 @@ import type { ExternalDataTool } from '@/models/common'import type { PromptVariable } from '@/models/debug'import { useBoolean } from 'ahooks'import { produce } from 'immer'-import React, { useMemo, useState } from 'react'+import * as React from 'react'+import { useMemo, useState } from 'react'import { useTranslation } from 'react-i18next'import { ReactSortable } from 'react-sortablejs'import { useContext } from 'use-context-selector'diff --git a/web/app/components/app/configuration/config-var/input-type-icon.tsx b/web/app/components/app/configuration/config-var/input-type-icon.tsxindex 3d6db276162..d79964ab70c 100644--- a/web/app/components/app/configuration/config-var/input-type-icon.tsx+++ b/web/app/components/app/configuration/config-var/input-type-icon.tsx@@ -1,6 +1,6 @@'use client'import type { FC } from 'react'-import React from 'react'+import * as React from 'react'import { ApiConnection } from '@/app/components/base/icons/src/vender/solid/development'import InputVarTypeIcon from '@/app/components/workflow/nodes/_base/components/input-var-type-icon'import { InputVarType } from '@/app/components/workflow/types'diff --git a/web/app/components/app/configuration/config-var/modal-foot.tsx b/web/app/components/app/configuration/config-var/modal-foot.tsxindex d1eed20a039..cad5bcb3e9f 100644--- a/web/app/components/app/configuration/config-var/modal-foot.tsx+++ b/web/app/components/app/configuration/config-var/modal-foot.tsx@@ -1,6 +1,6 @@'use client'import type { FC } from 'react'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import Button from '@/app/components/base/button'diff --git a/web/app/components/app/configuration/config-var/select-type-item/index.spec.tsx b/web/app/components/app/configuration/config-var/select-type-item/index.spec.tsxindex b21d69bc8e2..f34dd52f492 100644--- a/web/app/components/app/configuration/config-var/select-type-item/index.spec.tsx+++ b/web/app/components/app/configuration/config-var/select-type-item/index.spec.tsx@@ -1,5 +1,5 @@import { fireEvent, render, screen } from '@testing-library/react'-import React from 'react'+import * as React from 'react'import { InputVarType } from '@/app/components/workflow/types'import SelectTypeItem from './index'diff --git a/web/app/components/app/configuration/config-var/select-type-item/index.tsx b/web/app/components/app/configuration/config-var/select-type-item/index.tsxindex 4f0c3ace9ef..ccb958977c8 100644--- a/web/app/components/app/configuration/config-var/select-type-item/index.tsx+++ b/web/app/components/app/configuration/config-var/select-type-item/index.tsx@@ -1,7 +1,7 @@'use client'import type { FC } from 'react'import type { InputVarType } from '@/app/components/workflow/types'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import InputVarTypeIcon from '@/app/components/workflow/nodes/_base/components/input-var-type-icon'import { cn } from '@/utils/classnames'diff --git a/web/app/components/app/configuration/config-var/select-var-type.tsx b/web/app/components/app/configuration/config-var/select-var-type.tsxindex a74aeff45c5..0c19aeb137f 100644--- a/web/app/components/app/configuration/config-var/select-var-type.tsx+++ b/web/app/components/app/configuration/config-var/select-var-type.tsx@@ -1,6 +1,7 @@'use client'import type { FC } from 'react'-import React, { useState } from 'react'+import * as React from 'react'+import { useState } from 'react'import { useTranslation } from 'react-i18next'import OperationBtn from '@/app/components/app/configuration/base/operation-btn'import { ApiConnection } from '@/app/components/base/icons/src/vender/solid/development'diff --git a/web/app/components/app/configuration/config-var/var-item.tsx b/web/app/components/app/configuration/config-var/var-item.tsxindex 633af6dc28f..a4888db628d 100644--- a/web/app/components/app/configuration/config-var/var-item.tsx+++ b/web/app/components/app/configuration/config-var/var-item.tsx@@ -6,7 +6,8 @@ import {RiDraggable,RiEditLine,} from '@remixicon/react'-import React, { useState } from 'react'+import * as React from 'react'+import { useState } from 'react'import Badge from '@/app/components/base/badge'import { BracketsX as VarIcon } from '@/app/components/base/icons/src/vender/line/development'import { cn } from '@/utils/classnames'diff --git a/web/app/components/app/configuration/config-vision/index.spec.tsx b/web/app/components/app/configuration/config-vision/index.spec.tsxindex 7fd1d448e37..5fc7648bea3 100644--- a/web/app/components/app/configuration/config-vision/index.spec.tsx+++ b/web/app/components/app/configuration/config-vision/index.spec.tsx@@ -3,7 +3,7 @@ import type { FeatureStoreState } from '@/app/components/base/features/store'import type { FileUpload } from '@/app/components/base/features/types'import { fireEvent, render, screen } from '@testing-library/react'import userEvent from '@testing-library/user-event'-import React from 'react'+import * as React from 'react'import { SupportUploadFileTypes } from '@/app/components/workflow/types'import { Resolution, TransferMethod } from '@/types/app'import ConfigVision from './index'diff --git a/web/app/components/app/configuration/config-vision/index.tsx b/web/app/components/app/configuration/config-vision/index.tsxindex 6a73b9e5451..e53cdd4dfdc 100644--- a/web/app/components/app/configuration/config-vision/index.tsx+++ b/web/app/components/app/configuration/config-vision/index.tsx@@ -1,7 +1,8 @@'use client'import type { FC } from 'react'import { produce } from 'immer'-import React, { useCallback } from 'react'+import * as React from 'react'+import { useCallback } from 'react'import { useTranslation } from 'react-i18next'import { useContext } from 'use-context-selector'// import { Resolution } from '@/types/app'diff --git a/web/app/components/app/configuration/config-vision/param-config-content.tsx b/web/app/components/app/configuration/config-vision/param-config-content.tsxindex ebb8befbb32..2de14b9b6d3 100644--- a/web/app/components/app/configuration/config-vision/param-config-content.tsx+++ b/web/app/components/app/configuration/config-vision/param-config-content.tsx@@ -2,7 +2,8 @@import type { FC } from 'react'import type { FileUpload } from '@/app/components/base/features/types'import { produce } from 'immer'-import React, { useCallback } from 'react'+import * as React from 'react'+import { useCallback } from 'react'import { useTranslation } from 'react-i18next'import { useFeatures, useFeaturesStore } from '@/app/components/base/features/hooks'import ParamItem from '@/app/components/base/param-item'diff --git a/web/app/components/app/configuration/config/agent-setting-button.spec.tsx b/web/app/components/app/configuration/config/agent-setting-button.spec.tsxindex 1858a67a3b2..963a671a23f 100644--- a/web/app/components/app/configuration/config/agent-setting-button.spec.tsx+++ b/web/app/components/app/configuration/config/agent-setting-button.spec.tsx@@ -1,7 +1,7 @@import type { AgentConfig } from '@/models/debug'import { render, screen } from '@testing-library/react'import userEvent from '@testing-library/user-event'-import React from 'react'+import * as React from 'react'import { AgentStrategy } from '@/types/app'import AgentSettingButton from './agent-setting-button'diff --git a/web/app/components/app/configuration/config/agent-setting-button.tsx b/web/app/components/app/configuration/config/agent-setting-button.tsxindex 332b25eb1e0..c7c6ea417a4 100644--- a/web/app/components/app/configuration/config/agent-setting-button.tsx+++ b/web/app/components/app/configuration/config/agent-setting-button.tsx@@ -2,7 +2,8 @@import type { FC } from 'react'import type { AgentConfig } from '@/models/debug'import { RiSettings2Line } from '@remixicon/react'-import React, { useState } from 'react'+import * as React from 'react'+import { useState } from 'react'import { useTranslation } from 'react-i18next'import Button from '@/app/components/base/button'import AgentSetting from './agent/agent-setting'diff --git a/web/app/components/app/configuration/config/agent/agent-setting/index.spec.tsx b/web/app/components/app/configuration/config/agent/agent-setting/index.spec.tsxindex 5bb955842b9..b3a9bd7abc0 100644--- a/web/app/components/app/configuration/config/agent/agent-setting/index.spec.tsx+++ b/web/app/components/app/configuration/config/agent/agent-setting/index.spec.tsx@@ -1,6 +1,6 @@import type { AgentConfig } from '@/models/debug'import { act, fireEvent, render, screen } from '@testing-library/react'-import React from 'react'+import * as React from 'react'import { MAX_ITERATIONS_NUM } from '@/config'import AgentSetting from './index'diff --git a/web/app/components/app/configuration/config/agent/agent-setting/index.tsx b/web/app/components/app/configuration/config/agent/agent-setting/index.tsxindex 1adab75ed1d..dae24618764 100644--- a/web/app/components/app/configuration/config/agent/agent-setting/index.tsx+++ b/web/app/components/app/configuration/config/agent/agent-setting/index.tsx@@ -3,7 +3,8 @@ import type { FC } from 'react'import type { AgentConfig } from '@/models/debug'import { RiCloseLine } from '@remixicon/react'import { useClickAway } from 'ahooks'-import React, { useEffect, useRef, useState } from 'react'+import * as React from 'react'+import { useEffect, useRef, useState } from 'react'import { useTranslation } from 'react-i18next'import Button from '@/app/components/base/button'import { CuteRobot } from '@/app/components/base/icons/src/vender/solid/communication'diff --git a/web/app/components/app/configuration/config/agent/agent-setting/item-panel.spec.tsx b/web/app/components/app/configuration/config/agent/agent-setting/item-panel.spec.tsxindex dad576c9832..a4dcb7a6f30 100644--- a/web/app/components/app/configuration/config/agent/agent-setting/item-panel.spec.tsx+++ b/web/app/components/app/configuration/config/agent/agent-setting/item-panel.spec.tsx@@ -1,5 +1,5 @@import { render, screen } from '@testing-library/react'-import React from 'react'+import * as React from 'react'import ItemPanel from './item-panel'describe('AgentSetting/ItemPanel', () => {diff --git a/web/app/components/app/configuration/config/agent/agent-setting/item-panel.tsx b/web/app/components/app/configuration/config/agent/agent-setting/item-panel.tsxindex 2a6002632f8..92d32396084 100644--- a/web/app/components/app/configuration/config/agent/agent-setting/item-panel.tsx+++ b/web/app/components/app/configuration/config/agent/agent-setting/item-panel.tsx@@ -1,6 +1,6 @@'use client'import type { FC } from 'react'-import React from 'react'+import * as React from 'react'import Tooltip from '@/app/components/base/tooltip'import { cn } from '@/utils/classnames'diff --git a/web/app/components/app/configuration/config/agent/agent-tools/index.spec.tsx b/web/app/components/app/configuration/config/agent/agent-tools/index.spec.tsxindex cf9dd790311..1625db97b8f 100644--- a/web/app/components/app/configuration/config/agent/agent-tools/index.spec.tsx+++ b/web/app/components/app/configuration/config/agent/agent-tools/index.spec.tsx@@ -12,7 +12,8 @@ import type { AgentTool } from '@/types/app'import { act, render, screen, waitFor } from '@testing-library/react'import userEvent from '@testing-library/user-event'import copy from 'copy-to-clipboard'-import React, {+import * as React from 'react'+import {useEffect,useMemo,useState,diff --git a/web/app/components/app/configuration/config/agent/agent-tools/index.tsx b/web/app/components/app/configuration/config/agent/agent-tools/index.tsxindex f1e70e304f0..dfbab1f6f22 100644--- a/web/app/components/app/configuration/config/agent/agent-tools/index.tsx+++ b/web/app/components/app/configuration/config/agent/agent-tools/index.tsx@@ -11,7 +11,8 @@ import {} from '@remixicon/react'import copy from 'copy-to-clipboard'import { produce } from 'immer'-import React, { useCallback, useMemo, useState } from 'react'+import * as React from 'react'+import { useCallback, useMemo, useState } from 'react'import { useTranslation } from 'react-i18next'import { useContext } from 'use-context-selector'import Panel from '@/app/components/app/configuration/base/feature-panel'diff --git a/web/app/components/app/configuration/config/agent/agent-tools/setting-built-in-tool.spec.tsx b/web/app/components/app/configuration/config/agent/agent-tools/setting-built-in-tool.spec.tsxindex 654cd627a2e..e056baaa2fc 100644--- a/web/app/components/app/configuration/config/agent/agent-tools/setting-built-in-tool.spec.tsx+++ b/web/app/components/app/configuration/config/agent/agent-tools/setting-built-in-tool.spec.tsx@@ -1,7 +1,7 @@import type { Tool, ToolParameter } from '@/app/components/tools/types'import { render, screen, waitFor } from '@testing-library/react'import userEvent from '@testing-library/user-event'-import React from 'react'+import * as React from 'react'import { CollectionType } from '@/app/components/tools/types'import I18n from '@/context/i18n'import SettingBuiltInTool from './setting-built-in-tool'diff --git a/web/app/components/app/configuration/config/agent/agent-tools/setting-built-in-tool.tsx b/web/app/components/app/configuration/config/agent/agent-tools/setting-built-in-tool.tsxindex 31cccbf39c9..c59d7a3b6ea 100644--- a/web/app/components/app/configuration/config/agent/agent-tools/setting-built-in-tool.tsx+++ b/web/app/components/app/configuration/config/agent/agent-tools/setting-built-in-tool.tsx@@ -6,7 +6,8 @@ import {RiArrowLeftLine,RiCloseLine,} from '@remixicon/react'-import React, { useEffect, useState } from 'react'+import * as React from 'react'+import { useEffect, useState } from 'react'import { useTranslation } from 'react-i18next'import { useContext } from 'use-context-selector'import ActionButton from '@/app/components/base/action-button'diff --git a/web/app/components/app/configuration/config/agent/prompt-editor.tsx b/web/app/components/app/configuration/config/agent/prompt-editor.tsxindex 6319cc1bc58..0a09609ccae 100644--- a/web/app/components/app/configuration/config/agent/prompt-editor.tsx+++ b/web/app/components/app/configuration/config/agent/prompt-editor.tsx@@ -3,7 +3,7 @@ import type { FC } from 'react'import type { ExternalDataTool } from '@/models/common'import copy from 'copy-to-clipboard'import { noop } from 'lodash-es'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import { useContext } from 'use-context-selector'import s from '@/app/components/app/configuration/config-prompt/style.module.css'diff --git a/web/app/components/app/configuration/config/assistant-type-picker/index.spec.tsx b/web/app/components/app/configuration/config/assistant-type-picker/index.spec.tsxindex 8436a132d64..86201e996d0 100644--- a/web/app/components/app/configuration/config/assistant-type-picker/index.spec.tsx+++ b/web/app/components/app/configuration/config/assistant-type-picker/index.spec.tsx@@ -1,7 +1,7 @@import type { AgentConfig } from '@/models/debug'import { act, render, screen, waitFor } from '@testing-library/react'import userEvent from '@testing-library/user-event'-import React from 'react'+import * as React from 'react'import { AgentStrategy } from '@/types/app'import AssistantTypePicker from './index'diff --git a/web/app/components/app/configuration/config/assistant-type-picker/index.tsx b/web/app/components/app/configuration/config/assistant-type-picker/index.tsxindex 0a283835fc4..8c08e7c9212 100644--- a/web/app/components/app/configuration/config/assistant-type-picker/index.tsx+++ b/web/app/components/app/configuration/config/assistant-type-picker/index.tsx@@ -2,7 +2,8 @@import type { FC } from 'react'import type { AgentConfig } from '@/models/debug'import { RiArrowDownSLine } from '@remixicon/react'-import React, { useState } from 'react'+import * as React from 'react'+import { useState } from 'react'import { useTranslation } from 'react-i18next'import { ArrowUpRight } from '@/app/components/base/icons/src/vender/line/arrows'import { Settings04 } from '@/app/components/base/icons/src/vender/line/general'diff --git a/web/app/components/app/configuration/config/automatic/automatic-btn.tsx b/web/app/components/app/configuration/config/automatic/automatic-btn.tsxindex 86a16ba9952..636c2577b15 100644--- a/web/app/components/app/configuration/config/automatic/automatic-btn.tsx+++ b/web/app/components/app/configuration/config/automatic/automatic-btn.tsx@@ -3,7 +3,7 @@ import type { FC } from 'react'import {RiSparklingFill,} from '@remixicon/react'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import Button from '@/app/components/base/button'diff --git a/web/app/components/app/configuration/config/automatic/get-automatic-res.tsx b/web/app/components/app/configuration/config/automatic/get-automatic-res.tsxindex bc5d0fc7de8..46fcaee52be 100644--- a/web/app/components/app/configuration/config/automatic/get-automatic-res.tsx+++ b/web/app/components/app/configuration/config/automatic/get-automatic-res.tsx@@ -16,7 +16,8 @@ import {RiUser2Line,} from '@remixicon/react'import { useBoolean, useSessionStorageState } from 'ahooks'-import React, { useCallback, useEffect, useState } from 'react'+import * as React from 'react'+import { useCallback, useEffect, useState } from 'react'import { useTranslation } from 'react-i18next'import Button from '@/app/components/base/button'import Confirm from '@/app/components/base/confirm'diff --git a/web/app/components/app/configuration/config/automatic/idea-output.tsx b/web/app/components/app/configuration/config/automatic/idea-output.tsxindex 560d9be15b2..2d91683ac87 100644--- a/web/app/components/app/configuration/config/automatic/idea-output.tsx+++ b/web/app/components/app/configuration/config/automatic/idea-output.tsx@@ -1,7 +1,7 @@'use client'import type { FC } from 'react'import { useBoolean } from 'ahooks'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import { ArrowDownRoundFill } from '@/app/components/base/icons/src/vender/solid/general'import Textarea from '@/app/components/base/textarea'diff --git a/web/app/components/app/configuration/config/automatic/instruction-editor-in-workflow.tsx b/web/app/components/app/configuration/config/automatic/instruction-editor-in-workflow.tsxindex 2c6e09302c1..31a96c58187 100644--- a/web/app/components/app/configuration/config/automatic/instruction-editor-in-workflow.tsx+++ b/web/app/components/app/configuration/config/automatic/instruction-editor-in-workflow.tsx@@ -2,7 +2,8 @@import type { FC } from 'react'import type { GeneratorType } from './types'import type { ValueSelector, Var } from '@/app/components/workflow/types'-import React, { useCallback } from 'react'+import * as React from 'react'+import { useCallback } from 'react'import { useWorkflowVariableType } from '@/app/components/workflow/hooks'import useAvailableVarList from '@/app/components/workflow/nodes/_base/hooks/use-available-var-list'import { useWorkflowStore } from '@/app/components/workflow/store'diff --git a/web/app/components/app/configuration/config/automatic/instruction-editor.tsx b/web/app/components/app/configuration/config/automatic/instruction-editor.tsxindex e42d027061e..77d6e9b56c5 100644--- a/web/app/components/app/configuration/config/automatic/instruction-editor.tsx+++ b/web/app/components/app/configuration/config/automatic/instruction-editor.tsx@@ -2,7 +2,7 @@import type { FC } from 'react'import type { GeneratorType } from './types'import type { Node, NodeOutPutVar, ValueSelector } from '@/app/components/workflow/types'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import PromptEditor from '@/app/components/base/prompt-editor'import { PROMPT_EDITOR_INSERT_QUICKLY } from '@/app/components/base/prompt-editor/plugins/update-block'diff --git a/web/app/components/app/configuration/config/automatic/prompt-res-in-workflow.tsx b/web/app/components/app/configuration/config/automatic/prompt-res-in-workflow.tsxindex 80cd357eb92..71d0c95d1dc 100644--- a/web/app/components/app/configuration/config/automatic/prompt-res-in-workflow.tsx+++ b/web/app/components/app/configuration/config/automatic/prompt-res-in-workflow.tsx@@ -1,6 +1,6 @@'use client'import type { FC } from 'react'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import useAvailableVarList from '@/app/components/workflow/nodes/_base/hooks/use-available-var-list'import { Type } from '@/app/components/workflow/nodes/llm/types'diff --git a/web/app/components/app/configuration/config/automatic/prompt-res.tsx b/web/app/components/app/configuration/config/automatic/prompt-res.tsxindex 8a0e85aab77..ced438a18aa 100644--- a/web/app/components/app/configuration/config/automatic/prompt-res.tsx+++ b/web/app/components/app/configuration/config/automatic/prompt-res.tsx@@ -1,7 +1,8 @@'use client'import type { FC } from 'react'import type { WorkflowVariableBlockType } from '@/app/components/base/prompt-editor/types'-import React, { useEffect } from 'react'+import * as React from 'react'+import { useEffect } from 'react'import PromptEditor from '@/app/components/base/prompt-editor'type Props = {diff --git a/web/app/components/app/configuration/config/automatic/prompt-toast.tsx b/web/app/components/app/configuration/config/automatic/prompt-toast.tsxindex 2e53eb563c1..65a78d1e67b 100644--- a/web/app/components/app/configuration/config/automatic/prompt-toast.tsx+++ b/web/app/components/app/configuration/config/automatic/prompt-toast.tsx@@ -1,6 +1,6 @@import { RiArrowDownSLine, RiSparklingFill } from '@remixicon/react'import { useBoolean } from 'ahooks'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import { Markdown } from '@/app/components/base/markdown'import { cn } from '@/utils/classnames'diff --git a/web/app/components/app/configuration/config/automatic/res-placeholder.tsx b/web/app/components/app/configuration/config/automatic/res-placeholder.tsxindex 01d9043c82e..80ab8e1f3fb 100644--- a/web/app/components/app/configuration/config/automatic/res-placeholder.tsx+++ b/web/app/components/app/configuration/config/automatic/res-placeholder.tsx@@ -1,6 +1,6 @@'use client'import type { FC } from 'react'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import { Generator } from '@/app/components/base/icons/src/vender/other'diff --git a/web/app/components/app/configuration/config/automatic/result.tsx b/web/app/components/app/configuration/config/automatic/result.tsxindex c2a4f55f80f..b97975a6be6 100644--- a/web/app/components/app/configuration/config/automatic/result.tsx+++ b/web/app/components/app/configuration/config/automatic/result.tsx@@ -3,7 +3,7 @@ import type { FC } from 'react'import type { GenRes } from '@/service/debug'import { RiClipboardLine } from '@remixicon/react'import copy from 'copy-to-clipboard'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import Button from '@/app/components/base/button'import Toast from '@/app/components/base/toast'diff --git a/web/app/components/app/configuration/config/automatic/version-selector.tsx b/web/app/components/app/configuration/config/automatic/version-selector.tsxindex fe8c26f2d59..5449f518a5c 100644--- a/web/app/components/app/configuration/config/automatic/version-selector.tsx+++ b/web/app/components/app/configuration/config/automatic/version-selector.tsx@@ -1,6 +1,7 @@import { RiArrowDownSLine, RiCheckLine } from '@remixicon/react'import { useBoolean } from 'ahooks'-import React, { useCallback } from 'react'+import * as React from 'react'+import { useCallback } from 'react'import { useTranslation } from 'react-i18next'import { PortalToFollowElem, PortalToFollowElemContent, PortalToFollowElemTrigger } from '@/app/components/base/portal-to-follow-elem'import { cn } from '@/utils/classnames'diff --git a/web/app/components/app/configuration/config/code-generator/get-code-generator-res.tsx b/web/app/components/app/configuration/config/code-generator/get-code-generator-res.tsxindex 9eb1acf77d5..23ab46973fc 100644--- a/web/app/components/app/configuration/config/code-generator/get-code-generator-res.tsx+++ b/web/app/components/app/configuration/config/code-generator/get-code-generator-res.tsx@@ -5,7 +5,8 @@ import type { GenRes } from '@/service/debug'import type { AppModeEnum, CompletionParams, Model, ModelModeType } from '@/types/app'import { useSessionStorageState } from 'ahooks'import useBoolean from 'ahooks/lib/useBoolean'-import React, { useCallback, useEffect, useState } from 'react'+import * as React from 'react'+import { useCallback, useEffect, useState } from 'react'import { useTranslation } from 'react-i18next'import Button from '@/app/components/base/button'import Confirm from '@/app/components/base/confirm'diff --git a/web/app/components/app/configuration/config/config-audio.spec.tsx b/web/app/components/app/configuration/config/config-audio.spec.tsxindex 2ca34f9742c..c29e2ac2b47 100644--- a/web/app/components/app/configuration/config/config-audio.spec.tsx+++ b/web/app/components/app/configuration/config/config-audio.spec.tsx@@ -2,7 +2,7 @@ import type { Mock } from 'vitest'import type { FeatureStoreState } from '@/app/components/base/features/store'import { render, screen } from '@testing-library/react'import userEvent from '@testing-library/user-event'-import React from 'react'+import * as React from 'react'import { SupportUploadFileTypes } from '@/app/components/workflow/types'import ConfigAudio from './config-audio'diff --git a/web/app/components/app/configuration/config/config-audio.tsx b/web/app/components/app/configuration/config/config-audio.tsxindex 66a094804e0..93cc0d5bae1 100644--- a/web/app/components/app/configuration/config/config-audio.tsx+++ b/web/app/components/app/configuration/config/config-audio.tsx@@ -1,7 +1,8 @@'use client'import type { FC } from 'react'import { produce } from 'immer'-import React, { useCallback } from 'react'+import * as React from 'react'+import { useCallback } from 'react'import { useTranslation } from 'react-i18next'import { useContext } from 'use-context-selector'diff --git a/web/app/components/app/configuration/config/config-document.spec.tsx b/web/app/components/app/configuration/config/config-document.spec.tsxindex 4d874dc37ec..2aa87717fce 100644--- a/web/app/components/app/configuration/config/config-document.spec.tsx+++ b/web/app/components/app/configuration/config/config-document.spec.tsx@@ -2,7 +2,7 @@ import type { Mock } from 'vitest'import type { FeatureStoreState } from '@/app/components/base/features/store'import { render, screen } from '@testing-library/react'import userEvent from '@testing-library/user-event'-import React from 'react'+import * as React from 'react'import { SupportUploadFileTypes } from '@/app/components/workflow/types'import ConfigDocument from './config-document'diff --git a/web/app/components/app/configuration/config/config-document.tsx b/web/app/components/app/configuration/config/config-document.tsxindex 5616c201c64..b2caf73397f 100644--- a/web/app/components/app/configuration/config/config-document.tsx+++ b/web/app/components/app/configuration/config/config-document.tsx@@ -1,7 +1,8 @@'use client'import type { FC } from 'react'import { produce } from 'immer'-import React, { useCallback } from 'react'+import * as React from 'react'+import { useCallback } from 'react'import { useTranslation } from 'react-i18next'import { useContext } from 'use-context-selector'diff --git a/web/app/components/app/configuration/config/index.spec.tsx b/web/app/components/app/configuration/config/index.spec.tsxindex 94361ba28c7..25a112ec098 100644--- a/web/app/components/app/configuration/config/index.spec.tsx+++ b/web/app/components/app/configuration/config/index.spec.tsx@@ -2,7 +2,7 @@ import type { Mock } from 'vitest'import type { ModelConfig, PromptVariable } from '@/models/debug'import type { ToolItem } from '@/types/app'import { render, screen } from '@testing-library/react'-import React from 'react'+import * as React from 'react'import * as useContextSelector from 'use-context-selector'import { AgentStrategy, AppModeEnum, ModelModeType } from '@/types/app'import Config from './index'diff --git a/web/app/components/app/configuration/config/index.tsx b/web/app/components/app/configuration/config/index.tsxindex 2b9d2ce44e1..f208b99e595 100644--- a/web/app/components/app/configuration/config/index.tsx+++ b/web/app/components/app/configuration/config/index.tsx@@ -2,7 +2,7 @@import type { FC } from 'react'import type { ModelConfig, PromptVariable } from '@/models/debug'import { produce } from 'immer'-import React from 'react'+import * as React from 'react'import { useContext } from 'use-context-selector'import ConfigPrompt from '@/app/components/app/configuration/config-prompt'import ConfigVar from '@/app/components/app/configuration/config-var'diff --git a/web/app/components/app/configuration/ctrl-btn-group/index.tsx b/web/app/components/app/configuration/ctrl-btn-group/index.tsxindex c955c497fbb..efd38092017 100644--- a/web/app/components/app/configuration/ctrl-btn-group/index.tsx+++ b/web/app/components/app/configuration/ctrl-btn-group/index.tsx@@ -1,6 +1,6 @@'use client'import type { FC } from 'react'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import Button from '@/app/components/base/button'import s from './style.module.css'diff --git a/web/app/components/app/configuration/dataset-config/card-item/index.spec.tsx b/web/app/components/app/configuration/dataset-config/card-item/index.spec.tsxindex a69b0882d35..2e3cb47c985 100644--- a/web/app/components/app/configuration/dataset-config/card-item/index.spec.tsx+++ b/web/app/components/app/configuration/dataset-config/card-item/index.spec.tsx@@ -1,4 +1,4 @@-import type React from 'react'+import type * as React from 'react'import type { MockedFunction } from 'vitest'import type { IndexingType } from '@/app/components/datasets/create/step-two'import type { DataSet } from '@/models/datasets'diff --git a/web/app/components/app/configuration/dataset-config/card-item/index.tsx b/web/app/components/app/configuration/dataset-config/card-item/index.tsxindex 223c5948705..e0b50d1be3a 100644--- a/web/app/components/app/configuration/dataset-config/card-item/index.tsx+++ b/web/app/components/app/configuration/dataset-config/card-item/index.tsx@@ -5,7 +5,8 @@ import {RiDeleteBinLine,RiEditLine,} from '@remixicon/react'-import React, { useState } from 'react'+import * as React from 'react'+import { useState } from 'react'import { useTranslation } from 'react-i18next'import ActionButton, { ActionButtonState } from '@/app/components/base/action-button'import AppIcon from '@/app/components/base/app-icon'diff --git a/web/app/components/app/configuration/dataset-config/context-var/index.tsx b/web/app/components/app/configuration/dataset-config/context-var/index.tsxindex 4baa731f28e..b2983c313dd 100644--- a/web/app/components/app/configuration/dataset-config/context-var/index.tsx+++ b/web/app/components/app/configuration/dataset-config/context-var/index.tsx@@ -1,7 +1,7 @@'use client'import type { FC } from 'react'import type { Props } from './var-picker'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import { BracketsX } from '@/app/components/base/icons/src/vender/line/development'import Tooltip from '@/app/components/base/tooltip'diff --git a/web/app/components/app/configuration/dataset-config/context-var/var-picker.tsx b/web/app/components/app/configuration/dataset-config/context-var/var-picker.tsxindex 485e7aeb89d..6f467afa84a 100644--- a/web/app/components/app/configuration/dataset-config/context-var/var-picker.tsx+++ b/web/app/components/app/configuration/dataset-config/context-var/var-picker.tsx@@ -2,7 +2,8 @@import type { FC } from 'react'import type { IInputTypeIconProps } from '@/app/components/app/configuration/config-var/input-type-icon'import { ChevronDownIcon } from '@heroicons/react/24/outline'-import React, { useState } from 'react'+import * as React from 'react'+import { useState } from 'react'import { useTranslation } from 'react-i18next'import IconTypeIcon from '@/app/components/app/configuration/config-var/input-type-icon'import {diff --git a/web/app/components/app/configuration/dataset-config/index.tsx b/web/app/components/app/configuration/dataset-config/index.tsxindex b954944a6ec..9ac17295909 100644--- a/web/app/components/app/configuration/dataset-config/index.tsx+++ b/web/app/components/app/configuration/dataset-config/index.tsx@@ -10,7 +10,8 @@ import type {import type { DataSet } from '@/models/datasets'import { produce } from 'immer'import { intersectionBy } from 'lodash-es'-import React, { useCallback, useMemo } from 'react'+import * as React from 'react'+import { useCallback, useMemo } from 'react'import { useTranslation } from 'react-i18next'import { useContext } from 'use-context-selector'import { v4 as uuid4 } from 'uuid'diff --git a/web/app/components/app/configuration/dataset-config/select-dataset/index.tsx b/web/app/components/app/configuration/dataset-config/select-dataset/index.tsxindex 4e6bbe4a69b..c1df954bdeb 100644--- a/web/app/components/app/configuration/dataset-config/select-dataset/index.tsx+++ b/web/app/components/app/configuration/dataset-config/select-dataset/index.tsx@@ -3,7 +3,8 @@ import type { FC } from 'react'import type { DataSet } from '@/models/datasets'import { useInfiniteScroll } from 'ahooks'import Link from 'next/link'-import React, { useEffect, useMemo, useRef, useState } from 'react'+import * as React from 'react'+import { useEffect, useMemo, useRef, useState } from 'react'import { useTranslation } from 'react-i18next'import AppIcon from '@/app/components/base/app-icon'import Badge from '@/app/components/base/badge'diff --git a/web/app/components/app/configuration/debug/chat-user-input.tsx b/web/app/components/app/configuration/debug/chat-user-input.tsxindex 2847f553075..3c65394301b 100644--- a/web/app/components/app/configuration/debug/chat-user-input.tsx+++ b/web/app/components/app/configuration/debug/chat-user-input.tsx@@ -1,5 +1,6 @@import type { Inputs } from '@/models/debug'-import React, { useEffect } from 'react'+import * as React from 'react'+import { useEffect } from 'react'import { useTranslation } from 'react-i18next'import { useContext } from 'use-context-selector'import Input from '@/app/components/base/input'diff --git a/web/app/components/app/configuration/debug/index.tsx b/web/app/components/app/configuration/debug/index.tsxindex 875e3bc35f5..fe1c6550f57 100644--- a/web/app/components/app/configuration/debug/index.tsx+++ b/web/app/components/app/configuration/debug/index.tsx@@ -14,7 +14,8 @@ import { useBoolean } from 'ahooks'import { produce, setAutoFreeze } from 'immer'import { noop } from 'lodash-es'import cloneDeep from 'lodash-es/cloneDeep'-import React, { useCallback, useEffect, useRef, useState } from 'react'+import * as React from 'react'+import { useCallback, useEffect, useRef, useState } from 'react'import { useTranslation } from 'react-i18next'import { useContext } from 'use-context-selector'import { useShallow } from 'zustand/react/shallow'diff --git a/web/app/components/app/configuration/index.tsx b/web/app/components/app/configuration/index.tsxindex 9f9baea0426..eb7a9f5a321 100644--- a/web/app/components/app/configuration/index.tsx+++ b/web/app/components/app/configuration/index.tsx@@ -23,7 +23,8 @@ import { useBoolean, useGetState } from 'ahooks'import { produce } from 'immer'import { clone, isEqual } from 'lodash-es'import { usePathname } from 'next/navigation'-import React, { useCallback, useEffect, useMemo, useRef, useState } from 'react'+import * as React from 'react'+import { useCallback, useEffect, useMemo, useRef, useState } from 'react'import { useTranslation } from 'react-i18next'import { useContext } from 'use-context-selector'import { useShallow } from 'zustand/react/shallow'diff --git a/web/app/components/app/configuration/prompt-value-panel/index.tsx b/web/app/components/app/configuration/prompt-value-panel/index.tsxindex 8d006e8b2b7..0b9388c6643 100644--- a/web/app/components/app/configuration/prompt-value-panel/index.tsx+++ b/web/app/components/app/configuration/prompt-value-panel/index.tsx@@ -7,7 +7,8 @@ import {RiArrowRightSLine,RiPlayLargeFill,} from '@remixicon/react'-import React, { useEffect, useMemo, useState } from 'react'+import * as React from 'react'+import { useEffect, useMemo, useState } from 'react'import { useTranslation } from 'react-i18next'import { useContext } from 'use-context-selector'import { useStore as useAppStore } from '@/app/components/app/store'diff --git a/web/app/components/app/create-app-dialog/app-list/index.tsx b/web/app/components/app/create-app-dialog/app-list/index.tsxindex 0af1b347af9..df54de2ff18 100644--- a/web/app/components/app/create-app-dialog/app-list/index.tsx+++ b/web/app/components/app/create-app-dialog/app-list/index.tsx@@ -5,7 +5,8 @@ import type { App } from '@/models/explore'import { RiRobot2Line } from '@remixicon/react'import { useDebounceFn } from 'ahooks'import { useRouter } from 'next/navigation'-import React, { useMemo, useState } from 'react'+import * as React from 'react'+import { useMemo, useState } from 'react'import { useTranslation } from 'react-i18next'import useSWR from 'swr'import { useContext } from 'use-context-selector'diff --git a/web/app/components/app/create-from-dsl-modal/uploader.tsx b/web/app/components/app/create-from-dsl-modal/uploader.tsxindex 73043643c7c..cef288acfc2 100644--- a/web/app/components/app/create-from-dsl-modal/uploader.tsx+++ b/web/app/components/app/create-from-dsl-modal/uploader.tsx@@ -4,7 +4,8 @@ import {RiDeleteBinLine,RiUploadCloud2Line,} from '@remixicon/react'-import React, { useEffect, useRef, useState } from 'react'+import * as React from 'react'+import { useEffect, useRef, useState } from 'react'import { useTranslation } from 'react-i18next'import { useContext } from 'use-context-selector'import ActionButton from '@/app/components/base/action-button'diff --git a/web/app/components/app/duplicate-modal/index.spec.tsx b/web/app/components/app/duplicate-modal/index.spec.tsxindex 7a8c33d0d23..f214f8e343c 100644--- a/web/app/components/app/duplicate-modal/index.spec.tsx+++ b/web/app/components/app/duplicate-modal/index.spec.tsx@@ -1,7 +1,7 @@import type { ProviderContextState } from '@/context/provider-context'import { render, screen } from '@testing-library/react'import userEvent from '@testing-library/user-event'-import React from 'react'+import * as React from 'react'import Toast from '@/app/components/base/toast'import { Plan } from '@/app/components/billing/type'import { baseProviderContextValue } from '@/context/provider-context'diff --git a/web/app/components/app/duplicate-modal/index.tsx b/web/app/components/app/duplicate-modal/index.tsxindex 39b7d873042..420a6b159ae 100644--- a/web/app/components/app/duplicate-modal/index.tsx+++ b/web/app/components/app/duplicate-modal/index.tsx@@ -2,7 +2,8 @@import type { AppIconType } from '@/types/app'import { RiCloseLine } from '@remixicon/react'import { noop } from 'lodash-es'-import React, { useState } from 'react'+import * as React from 'react'+import { useState } from 'react'import { useTranslation } from 'react-i18next'import AppIcon from '@/app/components/base/app-icon'import Button from '@/app/components/base/button'diff --git a/web/app/components/app/log-annotation/index.tsx b/web/app/components/app/log-annotation/index.tsxindex fd2a730ca1f..27a70c29e76 100644--- a/web/app/components/app/log-annotation/index.tsx+++ b/web/app/components/app/log-annotation/index.tsx@@ -1,7 +1,8 @@'use client'import type { FC } from 'react'import { useRouter } from 'next/navigation'-import React, { useMemo } from 'react'+import * as React from 'react'+import { useMemo } from 'react'import { useTranslation } from 'react-i18next'import Annotation from '@/app/components/app/annotation'import Log from '@/app/components/app/log'diff --git a/web/app/components/app/log/empty-element.tsx b/web/app/components/app/log/empty-element.tsxindex e19bc6e90e7..792684587cc 100644--- a/web/app/components/app/log/empty-element.tsx+++ b/web/app/components/app/log/empty-element.tsx@@ -2,7 +2,7 @@import type { FC, SVGProps } from 'react'import type { App } from '@/types/app'import Link from 'next/link'-import React from 'react'+import * as React from 'react'import { Trans, useTranslation } from 'react-i18next'import { AppModeEnum } from '@/types/app'import { getRedirectionPath } from '@/utils/app-redirection'diff --git a/web/app/components/app/log/filter.tsx b/web/app/components/app/log/filter.tsxindex 34c39d822a8..8984ff3494b 100644--- a/web/app/components/app/log/filter.tsx+++ b/web/app/components/app/log/filter.tsx@@ -4,7 +4,7 @@ import type { QueryParam } from './index'import { RiCalendarLine } from '@remixicon/react'import dayjs from 'dayjs'import quarterOfYear from 'dayjs/plugin/quarterOfYear'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import useSWR from 'swr'import Chip from '@/app/components/base/chip'diff --git a/web/app/components/app/log/index.tsx b/web/app/components/app/log/index.tsxindex 4ac9a577a91..183826464ff 100644--- a/web/app/components/app/log/index.tsx+++ b/web/app/components/app/log/index.tsx@@ -5,7 +5,8 @@ import { useDebounce } from 'ahooks'import dayjs from 'dayjs'import { omit } from 'lodash-es'import { usePathname, useRouter, useSearchParams } from 'next/navigation'-import React, { useCallback, useEffect, useState } from 'react'+import * as React from 'react'+import { useCallback, useEffect, useState } from 'react'import { useTranslation } from 'react-i18next'import useSWR from 'swr'import Loading from '@/app/components/base/loading'diff --git a/web/app/components/app/log/list.tsx b/web/app/components/app/log/list.tsxindex c29a47123cc..06cd20b323d 100644--- a/web/app/components/app/log/list.tsx+++ b/web/app/components/app/log/list.tsx@@ -14,7 +14,8 @@ import timezone from 'dayjs/plugin/timezone'import utc from 'dayjs/plugin/utc'import { get, noop } from 'lodash-es'import { usePathname, useRouter, useSearchParams } from 'next/navigation'-import React, { useCallback, useEffect, useRef, useState } from 'react'+import * as React from 'react'+import { useCallback, useEffect, useRef, useState } from 'react'import { useTranslation } from 'react-i18next'import useSWR from 'swr'import { createContext, useContext } from 'use-context-selector'diff --git a/web/app/components/app/log/model-info.tsx b/web/app/components/app/log/model-info.tsxindex 8094b74c285..c89ea61e187 100644--- a/web/app/components/app/log/model-info.tsx+++ b/web/app/components/app/log/model-info.tsx@@ -3,7 +3,7 @@ import type { FC } from 'react'import {RiInformation2Line,} from '@remixicon/react'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import {PortalToFollowElem,diff --git a/web/app/components/app/log/var-panel.tsx b/web/app/components/app/log/var-panel.tsxindex f95f2de571e..f41737dec36 100644--- a/web/app/components/app/log/var-panel.tsx+++ b/web/app/components/app/log/var-panel.tsx@@ -5,7 +5,8 @@ import {RiArrowRightSLine,} from '@remixicon/react'import { useBoolean } from 'ahooks'-import React, { useState } from 'react'+import * as React from 'react'+import { useState } from 'react'import { useTranslation } from 'react-i18next'import { Variable02 } from '@/app/components/base/icons/src/vender/solid/development'import ImagePreview from '@/app/components/base/image-uploader/image-preview'diff --git a/web/app/components/app/overview/apikey-info-panel/index.tsx b/web/app/components/app/overview/apikey-info-panel/index.tsxindex e1a4ea08914..77e0eb99c28 100644--- a/web/app/components/app/overview/apikey-info-panel/index.tsx+++ b/web/app/components/app/overview/apikey-info-panel/index.tsx@@ -1,7 +1,8 @@'use client'import type { FC } from 'react'import { RiCloseLine } from '@remixicon/react'-import React, { useState } from 'react'+import * as React from 'react'+import { useState } from 'react'import { useTranslation } from 'react-i18next'import Button from '@/app/components/base/button'import { LinkExternal02 } from '@/app/components/base/icons/src/vender/line/general'diff --git a/web/app/components/app/overview/app-card.tsx b/web/app/components/app/overview/app-card.tsxindex 7b33a05b5eb..ac43828c364 100644--- a/web/app/components/app/overview/app-card.tsx+++ b/web/app/components/app/overview/app-card.tsx@@ -15,7 +15,8 @@ import {RiWindowLine,} from '@remixicon/react'import { usePathname, useRouter } from 'next/navigation'-import React, { useCallback, useEffect, useMemo, useState } from 'react'+import * as React from 'react'+import { useCallback, useEffect, useMemo, useState } from 'react'import { useTranslation } from 'react-i18next'import AppBasic from '@/app/components/app-sidebar/basic'import { useStore as useAppStore } from '@/app/components/app/store'diff --git a/web/app/components/app/overview/app-chart.tsx b/web/app/components/app/overview/app-chart.tsxindex 3c2a3734d0c..d876dbda27f 100644--- a/web/app/components/app/overview/app-chart.tsx+++ b/web/app/components/app/overview/app-chart.tsx@@ -7,7 +7,7 @@ import dayjs from 'dayjs'import Decimal from 'decimal.js'import ReactECharts from 'echarts-for-react'import { get } from 'lodash-es'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import Basic from '@/app/components/app-sidebar/basic'import Loading from '@/app/components/base/loading'diff --git a/web/app/components/app/overview/customize/index.tsx b/web/app/components/app/overview/customize/index.tsxindex 9dd3e3816a2..453c91f51b8 100644--- a/web/app/components/app/overview/customize/index.tsx+++ b/web/app/components/app/overview/customize/index.tsx@@ -1,7 +1,7 @@'use client'import type { FC } from 'react'import { ArrowTopRightOnSquareIcon } from '@heroicons/react/24/outline'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import Button from '@/app/components/base/button'import Modal from '@/app/components/base/modal'diff --git a/web/app/components/app/overview/embedded/index.tsx b/web/app/components/app/overview/embedded/index.tsxindex 92ea8bc49a0..5cad0b79fa3 100644--- a/web/app/components/app/overview/embedded/index.tsx+++ b/web/app/components/app/overview/embedded/index.tsx@@ -4,7 +4,8 @@ import {RiClipboardLine,} from '@remixicon/react'import copy from 'copy-to-clipboard'-import React, { useEffect, useState } from 'react'+import * as React from 'react'+import { useEffect, useState } from 'react'import { useTranslation } from 'react-i18next'import ActionButton from '@/app/components/base/action-button'import { useThemeContext } from '@/app/components/base/chat/embedded-chatbot/theme/theme-context'diff --git a/web/app/components/app/overview/settings/index.tsx b/web/app/components/app/overview/settings/index.tsxindex 6464f403095..c75c6fe53e0 100644--- a/web/app/components/app/overview/settings/index.tsx+++ b/web/app/components/app/overview/settings/index.tsx@@ -5,7 +5,8 @@ import type { AppDetailResponse } from '@/models/app'import type { AppIconType, AppSSO, Language } from '@/types/app'import { RiArrowRightSLine, RiCloseLine } from '@remixicon/react'import Link from 'next/link'-import React, { useCallback, useEffect, useState } from 'react'+import * as React from 'react'+import { useCallback, useEffect, useState } from 'react'import { Trans, useTranslation } from 'react-i18next'import ActionButton from '@/app/components/base/action-button'import AppIcon from '@/app/components/base/app-icon'diff --git a/web/app/components/app/overview/trigger-card.tsx b/web/app/components/app/overview/trigger-card.tsxindex 74b8e4100cd..bcff6cb8448 100644--- a/web/app/components/app/overview/trigger-card.tsx+++ b/web/app/components/app/overview/trigger-card.tsx@@ -3,7 +3,7 @@ import type { AppDetailResponse } from '@/models/app'import type { AppTrigger } from '@/service/use-tools'import type { AppSSO } from '@/types/app'import Link from 'next/link'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import { TriggerAll } from '@/app/components/base/icons/src/vender/workflow'import Switch from '@/app/components/base/switch'diff --git a/web/app/components/app/switch-app-modal/index.spec.tsx b/web/app/components/app/switch-app-modal/index.spec.tsxindex 1f3c787dfae..abb8dcca2a5 100644--- a/web/app/components/app/switch-app-modal/index.spec.tsx+++ b/web/app/components/app/switch-app-modal/index.spec.tsx@@ -1,7 +1,7 @@import type { App } from '@/types/app'import { render, screen, waitFor } from '@testing-library/react'import userEvent from '@testing-library/user-event'-import React from 'react'+import * as React from 'react'import { ToastContext } from '@/app/components/base/toast'import { Plan } from '@/app/components/billing/type'import { NEED_REFRESH_APP_LIST_KEY } from '@/config'diff --git a/web/app/components/app/text-generate/item/index.tsx b/web/app/components/app/text-generate/item/index.tsxindex 320bb103011..faa8c739997 100644--- a/web/app/components/app/text-generate/item/index.tsx+++ b/web/app/components/app/text-generate/item/index.tsx@@ -17,7 +17,8 @@ import {import { useBoolean } from 'ahooks'import copy from 'copy-to-clipboard'import { useParams } from 'next/navigation'-import React, { useEffect, useState } from 'react'+import * as React from 'react'+import { useEffect, useState } from 'react'import { useTranslation } from 'react-i18next'import { useStore as useAppStore } from '@/app/components/app/store'import ActionButton, { ActionButtonState } from '@/app/components/base/action-button'diff --git a/web/app/components/app/text-generate/saved-items/index.tsx b/web/app/components/app/text-generate/saved-items/index.tsxindex 8e065d095e3..59a4db8fcc6 100644--- a/web/app/components/app/text-generate/saved-items/index.tsx+++ b/web/app/components/app/text-generate/saved-items/index.tsx@@ -6,7 +6,7 @@ import {RiDeleteBinLine,} from '@remixicon/react'import copy from 'copy-to-clipboard'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import ActionButton from '@/app/components/base/action-button'import { Markdown } from '@/app/components/base/markdown'diff --git a/web/app/components/app/text-generate/saved-items/no-data/index.tsx b/web/app/components/app/text-generate/saved-items/no-data/index.tsxindex ed60372babc..e93d2f52751 100644--- a/web/app/components/app/text-generate/saved-items/no-data/index.tsx+++ b/web/app/components/app/text-generate/saved-items/no-data/index.tsx@@ -4,7 +4,7 @@ import {RiAddLine,RiBookmark3Line,} from '@remixicon/react'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import Button from '@/app/components/base/button'diff --git a/web/app/components/app/type-selector/index.spec.tsx b/web/app/components/app/type-selector/index.spec.tsxindex 0fb51e40a91..e24d9633054 100644--- a/web/app/components/app/type-selector/index.spec.tsx+++ b/web/app/components/app/type-selector/index.spec.tsx@@ -1,5 +1,5 @@import { fireEvent, render, screen, within } from '@testing-library/react'-import React from 'react'+import * as React from 'react'import { AppModeEnum } from '@/types/app'import AppTypeSelector, { AppTypeIcon, AppTypeLabel } from './index'diff --git a/web/app/components/app/type-selector/index.tsx b/web/app/components/app/type-selector/index.tsxindex 07e4b3f3431..2e5a8286ab5 100644--- a/web/app/components/app/type-selector/index.tsx+++ b/web/app/components/app/type-selector/index.tsx@@ -1,5 +1,6 @@import { RiArrowDownSLine, RiCloseCircleFill, RiExchange2Fill, RiFilter3Line } from '@remixicon/react'-import React, { useState } from 'react'+import * as React from 'react'+import { useState } from 'react'import { useTranslation } from 'react-i18next'import { BubbleTextMod, ChatBot, ListSparkle, Logic } from '@/app/components/base/icons/src/vender/solid/communication'import {diff --git a/web/app/components/app/workflow-log/filter.tsx b/web/app/components/app/workflow-log/filter.tsxindex 21e956ed504..9e3b213deb0 100644--- a/web/app/components/app/workflow-log/filter.tsx+++ b/web/app/components/app/workflow-log/filter.tsx@@ -4,7 +4,7 @@ import type { QueryParam } from './index'import { RiCalendarLine } from '@remixicon/react'import dayjs from 'dayjs'import quarterOfYear from 'dayjs/plugin/quarterOfYear'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import { trackEvent } from '@/app/components/base/amplitude/utils'import Chip from '@/app/components/base/chip'diff --git a/web/app/components/app/workflow-log/index.tsx b/web/app/components/app/workflow-log/index.tsxindex 14751ac809b..1390f2d4357 100644--- a/web/app/components/app/workflow-log/index.tsx+++ b/web/app/components/app/workflow-log/index.tsx@@ -6,7 +6,8 @@ import dayjs from 'dayjs'import timezone from 'dayjs/plugin/timezone'import utc from 'dayjs/plugin/utc'import { omit } from 'lodash-es'-import React, { useState } from 'react'+import * as React from 'react'+import { useState } from 'react'import { useTranslation } from 'react-i18next'import useSWR from 'swr'import EmptyElement from '@/app/components/app/log/empty-element'diff --git a/web/app/components/app/workflow-log/list.tsx b/web/app/components/app/workflow-log/list.tsxindex bafede0890c..d3896e5227f 100644--- a/web/app/components/app/workflow-log/list.tsx+++ b/web/app/components/app/workflow-log/list.tsx@@ -3,7 +3,8 @@ import type { FC } from 'react'import type { WorkflowAppLogDetail, WorkflowLogsResponse, WorkflowRunTriggeredFrom } from '@/models/log'import type { App } from '@/types/app'import { ArrowDownIcon } from '@heroicons/react/24/outline'-import React, { useEffect, useState } from 'react'+import * as React from 'react'+import { useEffect, useState } from 'react'import { useTranslation } from 'react-i18next'import Drawer from '@/app/components/base/drawer'import Loading from '@/app/components/base/loading'diff --git a/web/app/components/app/workflow-log/trigger-by-display.tsx b/web/app/components/app/workflow-log/trigger-by-display.tsxindex 736a75841ef..f243bcd2f1b 100644--- a/web/app/components/app/workflow-log/trigger-by-display.tsx+++ b/web/app/components/app/workflow-log/trigger-by-display.tsx@@ -1,7 +1,7 @@'use client'import type { FC } from 'react'import type { TriggerMetadata } from '@/models/log'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import {Code,diff --git a/web/app/components/apps/app-card.spec.tsx b/web/app/components/apps/app-card.spec.tsxindex 60ee2228377..b2afbabcb02 100644--- a/web/app/components/apps/app-card.spec.tsx+++ b/web/app/components/apps/app-card.spec.tsx@@ -1,6 +1,6 @@import type { Mock } from 'vitest'import { fireEvent, render, screen, waitFor } from '@testing-library/react'-import React from 'react'+import * as React from 'react'import { AccessMode } from '@/models/access-control'// Mock API services - import for direct manipulationimport * as appsService from '@/service/apps'@@ -23,18 +23,15 @@ vi.mock('next/navigation', () => ({// Mock use-context-selector with stable mockNotify reference for tracking calls// Include createContext for components that use it (like Toast)const mockNotify = vi.fn()-vi.mock('use-context-selector', () => {- const React = require('react')- return {- createContext: (defaultValue: any) => React.createContext(defaultValue),- useContext: () => ({- notify: mockNotify,- }),- useContextSelector: (_context: any, selector: any) => selector({- notify: mockNotify,- }),- }-})+vi.mock('use-context-selector', () => ({+ createContext: (defaultValue: any) => React.createContext(defaultValue),+ useContext: () => ({+ notify: mockNotify,+ }),+ useContextSelector: (_context: any, selector: any) => selector({+ notify: mockNotify,+ }),+}))// Mock app contextvi.mock('@/context/app-context', () => ({@@ -108,73 +105,70 @@ vi.mock('@/utils/time', () => ({}))// Mock dynamic imports-vi.mock('next/dynamic', () => {- const React = require('react')- return {- default: (importFn: () => Promise<any>) => {- const fnString = importFn.toString()-- if (fnString.includes('create-app-modal') || fnString.includes('explore/create-app-modal')) {- return function MockEditAppModal({ show, onHide, onConfirm }: any) {- if (!show)- return null- return React.createElement('div', { 'data-testid': 'edit-app-modal' }, React.createElement('button', { 'onClick': onHide, 'data-testid': 'close-edit-modal' }, 'Close'), React.createElement('button', {- 'onClick': () => onConfirm?.({- name: 'Updated App',- icon_type: 'emoji',- icon: '🎯',- icon_background: '#FFEAD5',- description: 'Updated description',- use_icon_as_answer_icon: false,- max_active_requests: null,- }),- 'data-testid': 'confirm-edit-modal',- }, 'Confirm'))- }+vi.mock('next/dynamic', () => ({+ default: (importFn: () => Promise<any>) => {+ const fnString = importFn.toString()++ if (fnString.includes('create-app-modal') || fnString.includes('explore/create-app-modal')) {+ return function MockEditAppModal({ show, onHide, onConfirm }: any) {+ if (!show)+ return null+ return React.createElement('div', { 'data-testid': 'edit-app-modal' }, React.createElement('button', { 'onClick': onHide, 'data-testid': 'close-edit-modal' }, 'Close'), React.createElement('button', {+ 'onClick': () => onConfirm?.({+ name: 'Updated App',+ icon_type: 'emoji',+ icon: '🎯',+ icon_background: '#FFEAD5',+ description: 'Updated description',+ use_icon_as_answer_icon: false,+ max_active_requests: null,+ }),+ 'data-testid': 'confirm-edit-modal',+ }, 'Confirm'))}- if (fnString.includes('duplicate-modal')) {- return function MockDuplicateAppModal({ show, onHide, onConfirm }: any) {- if (!show)- return null- return React.createElement('div', { 'data-testid': 'duplicate-modal' }, React.createElement('button', { 'onClick': onHide, 'data-testid': 'close-duplicate-modal' }, 'Close'), React.createElement('button', {- 'onClick': () => onConfirm?.({- name: 'Copied App',- icon_type: 'emoji',- icon: '📋',- icon_background: '#E4FBCC',- }),- 'data-testid': 'confirm-duplicate-modal',- }, 'Confirm'))- }+ }+ if (fnString.includes('duplicate-modal')) {+ return function MockDuplicateAppModal({ show, onHide, onConfirm }: any) {+ if (!show)+ return null+ return React.createElement('div', { 'data-testid': 'duplicate-modal' }, React.createElement('button', { 'onClick': onHide, 'data-testid': 'close-duplicate-modal' }, 'Close'), React.createElement('button', {+ 'onClick': () => onConfirm?.({+ name: 'Copied App',+ icon_type: 'emoji',+ icon: '📋',+ icon_background: '#E4FBCC',+ }),+ 'data-testid': 'confirm-duplicate-modal',+ }, 'Confirm'))}- if (fnString.includes('switch-app-modal')) {- return function MockSwitchAppModal({ show, onClose, onSuccess }: any) {- if (!show)- return null- return React.createElement('div', { 'data-testid': 'switch-modal' }, React.createElement('button', { 'onClick': onClose, 'data-testid': 'close-switch-modal' }, 'Close'), React.createElement('button', { 'onClick': onSuccess, 'data-testid': 'confirm-switch-modal' }, 'Switch'))- }+ }+ if (fnString.includes('switch-app-modal')) {+ return function MockSwitchAppModal({ show, onClose, onSuccess }: any) {+ if (!show)+ return null+ return React.createElement('div', { 'data-testid': 'switch-modal' }, React.createElement('button', { 'onClick': onClose, 'data-testid': 'close-switch-modal' }, 'Close'), React.createElement('button', { 'onClick': onSuccess, 'data-testid': 'confirm-switch-modal' }, 'Switch'))}- if (fnString.includes('base/confirm')) {- return function MockConfirm({ isShow, onCancel, onConfirm }: any) {- if (!isShow)- return null- return React.createElement('div', { 'data-testid': 'confirm-dialog' }, React.createElement('button', { 'onClick': onCancel, 'data-testid': 'cancel-confirm' }, 'Cancel'), React.createElement('button', { 'onClick': onConfirm, 'data-testid': 'confirm-confirm' }, 'Confirm'))- }+ }+ if (fnString.includes('base/confirm')) {+ return function MockConfirm({ isShow, onCancel, onConfirm }: any) {+ if (!isShow)+ return null+ return React.createElement('div', { 'data-testid': 'confirm-dialog' }, React.createElement('button', { 'onClick': onCancel, 'data-testid': 'cancel-confirm' }, 'Cancel'), React.createElement('button', { 'onClick': onConfirm, 'data-testid': 'confirm-confirm' }, 'Confirm'))}- if (fnString.includes('dsl-export-confirm-modal')) {- return function MockDSLExportModal({ onClose, onConfirm }: any) {- return React.createElement('div', { 'data-testid': 'dsl-export-modal' }, React.createElement('button', { 'onClick': () => onClose?.(), 'data-testid': 'close-dsl-export' }, 'Close'), React.createElement('button', { 'onClick': () => onConfirm?.(true), 'data-testid': 'confirm-dsl-export' }, 'Export with secrets'), React.createElement('button', { 'onClick': () => onConfirm?.(false), 'data-testid': 'confirm-dsl-export-no-secrets' }, 'Export without secrets'))- }+ }+ if (fnString.includes('dsl-export-confirm-modal')) {+ return function MockDSLExportModal({ onClose, onConfirm }: any) {+ return React.createElement('div', { 'data-testid': 'dsl-export-modal' }, React.createElement('button', { 'onClick': () => onClose?.(), 'data-testid': 'close-dsl-export' }, 'Close'), React.createElement('button', { 'onClick': () => onConfirm?.(true), 'data-testid': 'confirm-dsl-export' }, 'Export with secrets'), React.createElement('button', { 'onClick': () => onConfirm?.(false), 'data-testid': 'confirm-dsl-export-no-secrets' }, 'Export without secrets'))}- if (fnString.includes('app-access-control')) {- return function MockAccessControl({ onClose, onConfirm }: any) {- return React.createElement('div', { 'data-testid': 'access-control-modal' }, React.createElement('button', { 'onClick': onClose, 'data-testid': 'close-access-control' }, 'Close'), React.createElement('button', { 'onClick': onConfirm, 'data-testid': 'confirm-access-control' }, 'Confirm'))- }+ }+ if (fnString.includes('app-access-control')) {+ return function MockAccessControl({ onClose, onConfirm }: any) {+ return React.createElement('div', { 'data-testid': 'access-control-modal' }, React.createElement('button', { 'onClick': onClose, 'data-testid': 'close-access-control' }, 'Close'), React.createElement('button', { 'onClick': onConfirm, 'data-testid': 'confirm-access-control' }, 'Confirm'))}- return () => null- },- }-})+ }+ return () => null+ },+}))// Popover uses @headlessui/react portals - mock for controlled interaction testingvi.mock('@/app/components/base/popover', () => {@@ -202,7 +196,6 @@ vi.mock('@/app/components/base/tooltip', () => ({vi.mock('@/app/components/base/tag-management/selector', () => ({__esModule: true,default: ({ tags }: any) => {- const React = require('react')return React.createElement('div', { 'aria-label': 'tag-selector' }, tags?.map((tag: any) => React.createElement('span', { key: tag.id }, tag.name)))},}))diff --git a/web/app/components/apps/app-card.tsx b/web/app/components/apps/app-card.tsxindex 0490c771b00..3a3b9d6153b 100644--- a/web/app/components/apps/app-card.tsx+++ b/web/app/components/apps/app-card.tsx@@ -9,7 +9,8 @@ import type { App } from '@/types/app'import { RiBuildingLine, RiGlobalLine, RiLockLine, RiMoreFill, RiVerifiedBadgeLine } from '@remixicon/react'import dynamic from 'next/dynamic'import { useRouter } from 'next/navigation'-import React, { useCallback, useEffect, useMemo, useState } from 'react'+import * as React from 'react'+import { useCallback, useEffect, useMemo, useState } from 'react'import { useTranslation } from 'react-i18next'import { useContext } from 'use-context-selector'import { AppTypeIcon } from '@/app/components/app/type-selector'diff --git a/web/app/components/apps/empty.spec.tsx b/web/app/components/apps/empty.spec.tsxindex b7bd7f2d655..58a96f313a4 100644--- a/web/app/components/apps/empty.spec.tsx+++ b/web/app/components/apps/empty.spec.tsx@@ -1,5 +1,5 @@import { render, screen } from '@testing-library/react'-import React from 'react'+import * as React from 'react'import Empty from './empty'describe('Empty', () => {diff --git a/web/app/components/apps/empty.tsx b/web/app/components/apps/empty.tsxindex 86e03a5fb4d..b59efa9b358 100644--- a/web/app/components/apps/empty.tsx+++ b/web/app/components/apps/empty.tsx@@ -1,4 +1,4 @@-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'const DefaultCards = React.memo(() => {diff --git a/web/app/components/apps/footer.spec.tsx b/web/app/components/apps/footer.spec.tsxindex 89fe6fa471b..d93869b4800 100644--- a/web/app/components/apps/footer.spec.tsx+++ b/web/app/components/apps/footer.spec.tsx@@ -1,5 +1,5 @@import { render, screen } from '@testing-library/react'-import React from 'react'+import * as React from 'react'import Footer from './footer'describe('Footer', () => {diff --git a/web/app/components/apps/footer.tsx b/web/app/components/apps/footer.tsxindex 49ac7a0eb4b..09ec7ee7c40 100644--- a/web/app/components/apps/footer.tsx+++ b/web/app/components/apps/footer.tsx@@ -1,6 +1,6 @@import { RiDiscordFill, RiDiscussLine, RiGithubFill } from '@remixicon/react'import Link from 'next/link'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'type CustomLinkProps = {diff --git a/web/app/components/apps/index.spec.tsx b/web/app/components/apps/index.spec.tsxindex 6bb53386a47..f518c5e0393 100644--- a/web/app/components/apps/index.spec.tsx+++ b/web/app/components/apps/index.spec.tsx@@ -1,5 +1,5 @@import { render, screen } from '@testing-library/react'-import React from 'react'+import * as React from 'react'// Import after mocksimport Apps from './index'@@ -27,7 +27,6 @@ vi.mock('@/app/education-apply/hooks', () => ({vi.mock('./list', () => ({__esModule: true,default: () => {- const React = require('react')return React.createElement('div', { 'data-testid': 'apps-list' }, 'Apps List')},}))diff --git a/web/app/components/apps/list.spec.tsx b/web/app/components/apps/list.spec.tsxindex d39f2621c55..244a8d997dd 100644--- a/web/app/components/apps/list.spec.tsx+++ b/web/app/components/apps/list.spec.tsx@@ -1,5 +1,5 @@import { act, fireEvent, render, screen } from '@testing-library/react'-import React from 'react'+import * as React from 'react'import { AppModeEnum } from '@/types/app'// Import after mocks@@ -141,7 +141,6 @@ let mockTagFilterOnChange: ((value: string[]) => void) | null = nullvi.mock('@/app/components/base/tag-management/filter', () => ({__esModule: true,default: ({ onChange }: { onChange: (value: string[]) => void }) => {- const React = require('react')mockTagFilterOnChange = onChangereturn React.createElement('div', { 'data-testid': 'tag-filter' }, 'common.tag.placeholder')},@@ -161,7 +160,6 @@ vi.mock('@/hooks/use-pay', () => ({vi.mock('ahooks', () => ({useDebounceFn: (fn: () => void) => ({ run: fn }),useMount: (fn: () => void) => {- const React = require('react')const fnRef = React.useRef(fn)fnRef.current = fnReact.useEffect(() => {@@ -171,28 +169,25 @@ vi.mock('ahooks', () => ({}))// Mock dynamic imports-vi.mock('next/dynamic', () => {- const React = require('react')- return {- default: (importFn: () => Promise<any>) => {- const fnString = importFn.toString()-- if (fnString.includes('tag-management')) {- return function MockTagManagement() {- return React.createElement('div', { 'data-testid': 'tag-management-modal' })- }+vi.mock('next/dynamic', () => ({+ default: (importFn: () => Promise<any>) => {+ const fnString = importFn.toString()++ if (fnString.includes('tag-management')) {+ return function MockTagManagement() {+ return React.createElement('div', { 'data-testid': 'tag-management-modal' })}- if (fnString.includes('create-from-dsl-modal')) {- return function MockCreateFromDSLModal({ show, onClose, onSuccess }: any) {- if (!show)- return null- return React.createElement('div', { 'data-testid': 'create-dsl-modal' }, React.createElement('button', { 'onClick': onClose, 'data-testid': 'close-dsl-modal' }, 'Close'), React.createElement('button', { 'onClick': onSuccess, 'data-testid': 'success-dsl-modal' }, 'Success'))- }+ }+ if (fnString.includes('create-from-dsl-modal')) {+ return function MockCreateFromDSLModal({ show, onClose, onSuccess }: any) {+ if (!show)+ return null+ return React.createElement('div', { 'data-testid': 'create-dsl-modal' }, React.createElement('button', { 'onClick': onClose, 'data-testid': 'close-dsl-modal' }, 'Close'), React.createElement('button', { 'onClick': onSuccess, 'data-testid': 'success-dsl-modal' }, 'Success'))}- return () => null- },- }-})+ }+ return () => null+ },+}))/*** Mock child components for focused List component testing.@@ -202,24 +197,19 @@ vi.mock('next/dynamic', () => {vi.mock('./app-card', () => ({__esModule: true,default: ({ app }: any) => {- const React = require('react')return React.createElement('div', { 'data-testid': `app-card-${app.id}`, 'role': 'article' }, app.name)},}))-vi.mock('./new-app-card', () => {- const React = require('react')- return {- default: React.forwardRef((_props: any, _ref: any) => {- return React.createElement('div', { 'data-testid': 'new-app-card', 'role': 'button' }, 'New App Card')- }),- }-})+vi.mock('./new-app-card', () => ({+ default: React.forwardRef((_props: any, _ref: any) => {+ return React.createElement('div', { 'data-testid': 'new-app-card', 'role': 'button' }, 'New App Card')+ }),+}))vi.mock('./empty', () => ({__esModule: true,default: () => {- const React = require('react')return React.createElement('div', { 'data-testid': 'empty-state', 'role': 'status' }, 'No apps found')},}))@@ -227,7 +217,6 @@ vi.mock('./empty', () => ({vi.mock('./footer', () => ({__esModule: true,default: () => {- const React = require('react')return React.createElement('footer', { 'data-testid': 'footer', 'role': 'contentinfo' }, 'Footer')},}))diff --git a/web/app/components/apps/new-app-card.spec.tsx b/web/app/components/apps/new-app-card.spec.tsxindex bc8b10a2b6b..92e769adc7d 100644--- a/web/app/components/apps/new-app-card.spec.tsx+++ b/web/app/components/apps/new-app-card.spec.tsx@@ -1,5 +1,5 @@import { fireEvent, render, screen } from '@testing-library/react'-import React from 'react'+import * as React from 'react'// Import after mocksimport CreateAppCard from './new-app-card'@@ -22,37 +22,34 @@ vi.mock('@/context/provider-context', () => ({}))// Mock next/dynamic to immediately resolve components-vi.mock('next/dynamic', () => {- const React = require('react')- return {- default: (importFn: () => Promise<any>) => {- const fnString = importFn.toString()-- if (fnString.includes('create-app-modal') && !fnString.includes('create-from-dsl-modal')) {- return function MockCreateAppModal({ show, onClose, onSuccess, onCreateFromTemplate }: any) {- if (!show)- return null- return React.createElement('div', { 'data-testid': 'create-app-modal' }, React.createElement('button', { 'onClick': onClose, 'data-testid': 'close-create-modal' }, 'Close'), React.createElement('button', { 'onClick': onSuccess, 'data-testid': 'success-create-modal' }, 'Success'), React.createElement('button', { 'onClick': onCreateFromTemplate, 'data-testid': 'to-template-modal' }, 'To Template'))- }+vi.mock('next/dynamic', () => ({+ default: (importFn: () => Promise<any>) => {+ const fnString = importFn.toString()++ if (fnString.includes('create-app-modal') && !fnString.includes('create-from-dsl-modal')) {+ return function MockCreateAppModal({ show, onClose, onSuccess, onCreateFromTemplate }: any) {+ if (!show)+ return null+ return React.createElement('div', { 'data-testid': 'create-app-modal' }, React.createElement('button', { 'onClick': onClose, 'data-testid': 'close-create-modal' }, 'Close'), React.createElement('button', { 'onClick': onSuccess, 'data-testid': 'success-create-modal' }, 'Success'), React.createElement('button', { 'onClick': onCreateFromTemplate, 'data-testid': 'to-template-modal' }, 'To Template'))}- if (fnString.includes('create-app-dialog')) {- return function MockCreateAppTemplateDialog({ show, onClose, onSuccess, onCreateFromBlank }: any) {- if (!show)- return null- return React.createElement('div', { 'data-testid': 'create-template-dialog' }, React.createElement('button', { 'onClick': onClose, 'data-testid': 'close-template-dialog' }, 'Close'), React.createElement('button', { 'onClick': onSuccess, 'data-testid': 'success-template-dialog' }, 'Success'), React.createElement('button', { 'onClick': onCreateFromBlank, 'data-testid': 'to-blank-modal' }, 'To Blank'))- }+ }+ if (fnString.includes('create-app-dialog')) {+ return function MockCreateAppTemplateDialog({ show, onClose, onSuccess, onCreateFromBlank }: any) {+ if (!show)+ return null+ return React.createElement('div', { 'data-testid': 'create-template-dialog' }, React.createElement('button', { 'onClick': onClose, 'data-testid': 'close-template-dialog' }, 'Close'), React.createElement('button', { 'onClick': onSuccess, 'data-testid': 'success-template-dialog' }, 'Success'), React.createElement('button', { 'onClick': onCreateFromBlank, 'data-testid': 'to-blank-modal' }, 'To Blank'))}- if (fnString.includes('create-from-dsl-modal')) {- return function MockCreateFromDSLModal({ show, onClose, onSuccess }: any) {- if (!show)- return null- return React.createElement('div', { 'data-testid': 'create-dsl-modal' }, React.createElement('button', { 'onClick': onClose, 'data-testid': 'close-dsl-modal' }, 'Close'), React.createElement('button', { 'onClick': onSuccess, 'data-testid': 'success-dsl-modal' }, 'Success'))- }+ }+ if (fnString.includes('create-from-dsl-modal')) {+ return function MockCreateFromDSLModal({ show, onClose, onSuccess }: any) {+ if (!show)+ return null+ return React.createElement('div', { 'data-testid': 'create-dsl-modal' }, React.createElement('button', { 'onClick': onClose, 'data-testid': 'close-dsl-modal' }, 'Close'), React.createElement('button', { 'onClick': onSuccess, 'data-testid': 'success-dsl-modal' }, 'Success'))}- return () => null- },- }-})+ }+ return () => null+ },+}))// Mock CreateFromDSLModalTab enumvi.mock('@/app/components/app/create-from-dsl-modal', () => ({diff --git a/web/app/components/apps/new-app-card.tsx b/web/app/components/apps/new-app-card.tsxindex dd0918c7469..2117b3d2d02 100644--- a/web/app/components/apps/new-app-card.tsx+++ b/web/app/components/apps/new-app-card.tsx@@ -5,7 +5,8 @@ import {useRouter,useSearchParams,} from 'next/navigation'-import React, { useMemo, useState } from 'react'+import * as React from 'react'+import { useMemo, useState } from 'react'import { useTranslation } from 'react-i18next'import { CreateFromDSLModalTab } from '@/app/components/app/create-from-dsl-modal'import { FileArrow01, FilePlus01, FilePlus02 } from '@/app/components/base/icons/src/vender/line/files'diff --git a/web/app/components/base/action-button/index.tsx b/web/app/components/base/action-button/index.tsxindex 503847ba6b7..0c86adb6db9 100644--- a/web/app/components/base/action-button/index.tsx+++ b/web/app/components/base/action-button/index.tsx@@ -1,7 +1,7 @@import type { VariantProps } from 'class-variance-authority'import type { CSSProperties } from 'react'import { cva } from 'class-variance-authority'-import React from 'react'+import * as React from 'react'import { cn } from '@/utils/classnames'enum ActionButtonState {diff --git a/web/app/components/base/agent-log-modal/detail.tsx b/web/app/components/base/agent-log-modal/detail.tsxindex c436e9e23aa..5451126c9ea 100644--- a/web/app/components/base/agent-log-modal/detail.tsx+++ b/web/app/components/base/agent-log-modal/detail.tsx@@ -3,7 +3,8 @@ import type { FC } from 'react'import type { IChatItem } from '@/app/components/base/chat/chat/type'import type { AgentIteration, AgentLogDetailResponse } from '@/models/log'import { flatten, uniq } from 'lodash-es'-import React, { useCallback, useEffect, useMemo, useState } from 'react'+import * as React from 'react'+import { useCallback, useEffect, useMemo, useState } from 'react'import { useTranslation } from 'react-i18next'import { useContext } from 'use-context-selector'import { useStore as useAppStore } from '@/app/components/app/store'diff --git a/web/app/components/base/amplitude/AmplitudeProvider.tsx b/web/app/components/base/amplitude/AmplitudeProvider.tsxindex ec4d586d484..91c3713a07d 100644--- a/web/app/components/base/amplitude/AmplitudeProvider.tsx+++ b/web/app/components/base/amplitude/AmplitudeProvider.tsx@@ -3,7 +3,8 @@import type { FC } from 'react'import * as amplitude from '@amplitude/analytics-browser'import { sessionReplayPlugin } from '@amplitude/plugin-session-replay-browser'-import React, { useEffect } from 'react'+import * as React from 'react'+import { useEffect } from 'react'import { AMPLITUDE_API_KEY, IS_CLOUD_EDITION } from '@/config'export type IAmplitudeProps = {diff --git a/web/app/components/base/app-icon/index.tsx b/web/app/components/base/app-icon/index.tsxindex 01d4530b4d4..78624bab07d 100644--- a/web/app/components/base/app-icon/index.tsx+++ b/web/app/components/base/app-icon/index.tsx@@ -6,7 +6,8 @@ import { RiEditLine } from '@remixicon/react'import { useHover } from 'ahooks'import { cva } from 'class-variance-authority'import { init } from 'emoji-mart'-import React, { useRef } from 'react'+import * as React from 'react'+import { useRef } from 'react'import { cn } from '@/utils/classnames'init({ data })diff --git a/web/app/components/base/app-unavailable.tsx b/web/app/components/base/app-unavailable.tsxindex 898f9dbd007..e25b8c9ca66 100644--- a/web/app/components/base/app-unavailable.tsx+++ b/web/app/components/base/app-unavailable.tsx@@ -1,6 +1,6 @@'use client'import type { FC } from 'react'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import { cn } from '@/utils/classnames'diff --git a/web/app/components/base/audio-gallery/AudioPlayer.tsx b/web/app/components/base/audio-gallery/AudioPlayer.tsxindex d1a245d1930..859e27b08e8 100644--- a/web/app/components/base/audio-gallery/AudioPlayer.tsx+++ b/web/app/components/base/audio-gallery/AudioPlayer.tsx@@ -3,7 +3,8 @@ import {RiPlayLargeFill,} from '@remixicon/react'import { t } from 'i18next'-import React, { useCallback, useEffect, useRef, useState } from 'react'+import * as React from 'react'+import { useCallback, useEffect, useRef, useState } from 'react'import Toast from '@/app/components/base/toast'import useTheme from '@/hooks/use-theme'import { Theme } from '@/types/app'diff --git a/web/app/components/base/audio-gallery/index.tsx b/web/app/components/base/audio-gallery/index.tsxindex 2fdacab5826..e5f0b7f46be 100644--- a/web/app/components/base/audio-gallery/index.tsx+++ b/web/app/components/base/audio-gallery/index.tsx@@ -1,4 +1,4 @@-import React from 'react'+import * as React from 'react'import AudioPlayer from './AudioPlayer'type Props = {diff --git a/web/app/components/base/badge/index.tsx b/web/app/components/base/badge/index.tsxindex 663e40d2e5a..9120b28ea6c 100644--- a/web/app/components/base/badge/index.tsx+++ b/web/app/components/base/badge/index.tsx@@ -1,7 +1,7 @@import type { VariantProps } from 'class-variance-authority'import type { CSSProperties, ReactNode } from 'react'import { cva } from 'class-variance-authority'-import React from 'react'+import * as React from 'react'import { cn } from '@/utils/classnames'import './index.css'diff --git a/web/app/components/base/block-input/index.tsx b/web/app/components/base/block-input/index.tsxindex 51f5097e7d8..1b80b21059e 100644--- a/web/app/components/base/block-input/index.tsx+++ b/web/app/components/base/block-input/index.tsx@@ -1,7 +1,8 @@'use client'import type { ChangeEvent, FC } from 'react'-import React, { useCallback, useEffect, useRef, useState } from 'react'+import * as React from 'react'+import { useCallback, useEffect, useRef, useState } from 'react'import { useTranslation } from 'react-i18next'import { cn } from '@/utils/classnames'import { checkKeys } from '@/utils/var'diff --git a/web/app/components/base/button/add-button.tsx b/web/app/components/base/button/add-button.tsxindex 762766239ab..332b52dacad 100644--- a/web/app/components/base/button/add-button.tsx+++ b/web/app/components/base/button/add-button.tsx@@ -1,7 +1,7 @@'use client'import type { FC } from 'react'import { RiAddLine } from '@remixicon/react'-import React from 'react'+import * as React from 'react'import { cn } from '@/utils/classnames'type Props = {diff --git a/web/app/components/base/button/index.spec.tsx b/web/app/components/base/button/index.spec.tsxindex aa83070964f..0377fa334f0 100644--- a/web/app/components/base/button/index.spec.tsx+++ b/web/app/components/base/button/index.spec.tsx@@ -1,5 +1,5 @@import { cleanup, fireEvent, render } from '@testing-library/react'-import React from 'react'+import * as React from 'react'import Button from './index'afterEach(cleanup)diff --git a/web/app/components/base/button/index.tsx b/web/app/components/base/button/index.tsxindex 8d87174a3e7..0de57617af8 100644--- a/web/app/components/base/button/index.tsx+++ b/web/app/components/base/button/index.tsx@@ -1,7 +1,7 @@import type { VariantProps } from 'class-variance-authority'import type { CSSProperties } from 'react'import { cva } from 'class-variance-authority'-import React from 'react'+import * as React from 'react'import { cn } from '@/utils/classnames'import Spinner from '../spinner'diff --git a/web/app/components/base/button/sync-button.tsx b/web/app/components/base/button/sync-button.tsxindex 1e0a4a42f72..12c34026cb3 100644--- a/web/app/components/base/button/sync-button.tsx+++ b/web/app/components/base/button/sync-button.tsx@@ -1,7 +1,7 @@'use client'import type { FC } from 'react'import { RiRefreshLine } from '@remixicon/react'-import React from 'react'+import * as React from 'react'import TooltipPlus from '@/app/components/base/tooltip'import { cn } from '@/utils/classnames'diff --git a/web/app/components/base/chat/chat-with-history/header/operation.tsx b/web/app/components/base/chat/chat-with-history/header/operation.tsxindex c279c7b7858..fa239e198e4 100644--- a/web/app/components/base/chat/chat-with-history/header/operation.tsx+++ b/web/app/components/base/chat/chat-with-history/header/operation.tsx@@ -4,7 +4,8 @@ import type { FC } from 'react'import {RiArrowDownSLine,} from '@remixicon/react'-import React, { useState } from 'react'+import * as React from 'react'+import { useState } from 'react'import { useTranslation } from 'react-i18next'import { PortalToFollowElem, PortalToFollowElemContent, PortalToFollowElemTrigger } from '@/app/components/base/portal-to-follow-elem'import { cn } from '@/utils/classnames'diff --git a/web/app/components/base/chat/chat-with-history/inputs-form/content.tsx b/web/app/components/base/chat/chat-with-history/inputs-form/content.tsxindex 105bbe52ea9..0fd9a4cd9e0 100644--- a/web/app/components/base/chat/chat-with-history/inputs-form/content.tsx+++ b/web/app/components/base/chat/chat-with-history/inputs-form/content.tsx@@ -1,4 +1,5 @@-import React, { memo, useCallback } from 'react'+import * as React from 'react'+import { memo, useCallback } from 'react'import { useTranslation } from 'react-i18next'import { FileUploaderInAttachmentWrapper } from '@/app/components/base/file-uploader'import Input from '@/app/components/base/input'diff --git a/web/app/components/base/chat/chat-with-history/inputs-form/index.tsx b/web/app/components/base/chat/chat-with-history/inputs-form/index.tsxindex d6e0a4003d5..d3e52eb5498 100644--- a/web/app/components/base/chat/chat-with-history/inputs-form/index.tsx+++ b/web/app/components/base/chat/chat-with-history/inputs-form/index.tsx@@ -1,4 +1,4 @@-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import Button from '@/app/components/base/button'import InputsFormContent from '@/app/components/base/chat/chat-with-history/inputs-form/content'diff --git a/web/app/components/base/chat/chat-with-history/sidebar/operation.tsx b/web/app/components/base/chat/chat-with-history/sidebar/operation.tsxindex c3084c5536c..feff8d6a135 100644--- a/web/app/components/base/chat/chat-with-history/sidebar/operation.tsx+++ b/web/app/components/base/chat/chat-with-history/sidebar/operation.tsx@@ -8,7 +8,8 @@ import {RiUnpinLine,} from '@remixicon/react'import { useBoolean } from 'ahooks'-import React, { useEffect, useRef, useState } from 'react'+import * as React from 'react'+import { useEffect, useRef, useState } from 'react'import { useTranslation } from 'react-i18next'import ActionButton, { ActionButtonState } from '@/app/components/base/action-button'import { PortalToFollowElem, PortalToFollowElemContent, PortalToFollowElemTrigger } from '@/app/components/base/portal-to-follow-elem'diff --git a/web/app/components/base/chat/chat-with-history/sidebar/rename-modal.tsx b/web/app/components/base/chat/chat-with-history/sidebar/rename-modal.tsxindex 2d6168e21f6..a4f5d483169 100644--- a/web/app/components/base/chat/chat-with-history/sidebar/rename-modal.tsx+++ b/web/app/components/base/chat/chat-with-history/sidebar/rename-modal.tsx@@ -1,6 +1,7 @@'use client'import type { FC } from 'react'-import React, { useState } from 'react'+import * as React from 'react'+import { useState } from 'react'import { useTranslation } from 'react-i18next'import Button from '@/app/components/base/button'import Input from '@/app/components/base/input'diff --git a/web/app/components/base/chat/chat/citation/tooltip.tsx b/web/app/components/base/chat/chat/citation/tooltip.tsxindex 24490a96c03..a4ac64c82f2 100644--- a/web/app/components/base/chat/chat/citation/tooltip.tsx+++ b/web/app/components/base/chat/chat/citation/tooltip.tsx@@ -1,5 +1,6 @@import type { FC } from 'react'-import React, { useState } from 'react'+import * as React from 'react'+import { useState } from 'react'import {PortalToFollowElem,PortalToFollowElemContent,diff --git a/web/app/components/base/chat/chat/loading-anim/index.tsx b/web/app/components/base/chat/chat/loading-anim/index.tsxindex 496937332d4..74cc3444de2 100644--- a/web/app/components/base/chat/chat/loading-anim/index.tsx+++ b/web/app/components/base/chat/chat/loading-anim/index.tsx@@ -1,6 +1,6 @@'use client'import type { FC } from 'react'-import React from 'react'+import * as React from 'react'import { cn } from '@/utils/classnames'import s from './style.module.css'diff --git a/web/app/components/base/chat/chat/thought/index.tsx b/web/app/components/base/chat/chat/thought/index.tsxindex f77208541b8..00b8676cd84 100644--- a/web/app/components/base/chat/chat/thought/index.tsx+++ b/web/app/components/base/chat/chat/thought/index.tsx@@ -1,7 +1,7 @@'use client'import type { FC } from 'react'import type { ThoughtItem, ToolInfoInThought } from '../type'-import React from 'react'+import * as React from 'react'import ToolDetail from '@/app/components/base/chat/chat/answer/tool-detail'export type IThoughtProps = {diff --git a/web/app/components/base/chat/embedded-chatbot/header/index.tsx b/web/app/components/base/chat/embedded-chatbot/header/index.tsxindex 8d0b1dfd07b..84f8691aff1 100644--- a/web/app/components/base/chat/embedded-chatbot/header/index.tsx+++ b/web/app/components/base/chat/embedded-chatbot/header/index.tsx@@ -1,7 +1,8 @@import type { FC } from 'react'import type { Theme } from '../theme/theme-context'import { RiCollapseDiagonal2Line, RiExpandDiagonal2Line, RiResetLeftLine } from '@remixicon/react'-import React, { useCallback, useEffect, useState } from 'react'+import * as React from 'react'+import { useCallback, useEffect, useState } from 'react'import { useTranslation } from 'react-i18next'import ActionButton from '@/app/components/base/action-button'import ViewFormDropdown from '@/app/components/base/chat/embedded-chatbot/inputs-form/view-form-dropdown'diff --git a/web/app/components/base/chat/embedded-chatbot/inputs-form/content.tsx b/web/app/components/base/chat/embedded-chatbot/inputs-form/content.tsxindex 9c170131963..0136453149e 100644--- a/web/app/components/base/chat/embedded-chatbot/inputs-form/content.tsx+++ b/web/app/components/base/chat/embedded-chatbot/inputs-form/content.tsx@@ -1,4 +1,5 @@-import React, { memo, useCallback } from 'react'+import * as React from 'react'+import { memo, useCallback } from 'react'import { useTranslation } from 'react-i18next'import { FileUploaderInAttachmentWrapper } from '@/app/components/base/file-uploader'import Input from '@/app/components/base/input'diff --git a/web/app/components/base/chat/embedded-chatbot/inputs-form/index.tsx b/web/app/components/base/chat/embedded-chatbot/inputs-form/index.tsxindex 20585067c1d..b54f261f3d4 100644--- a/web/app/components/base/chat/embedded-chatbot/inputs-form/index.tsx+++ b/web/app/components/base/chat/embedded-chatbot/inputs-form/index.tsx@@ -1,4 +1,4 @@-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import Button from '@/app/components/base/button'import InputsFormContent from '@/app/components/base/chat/embedded-chatbot/inputs-form/content'diff --git a/web/app/components/base/confirm/index.tsx b/web/app/components/base/confirm/index.tsxindex f9f4d3b1d78..590d28682ba 100644--- a/web/app/components/base/confirm/index.tsx+++ b/web/app/components/base/confirm/index.tsx@@ -1,4 +1,5 @@-import React, { useEffect, useRef, useState } from 'react'+import * as React from 'react'+import { useEffect, useRef, useState } from 'react'import { createPortal } from 'react-dom'import { useTranslation } from 'react-i18next'import Button from '../button'diff --git a/web/app/components/base/copy-feedback/index.tsx b/web/app/components/base/copy-feedback/index.tsxindex 788dcee89c1..bf809a2d189 100644--- a/web/app/components/base/copy-feedback/index.tsx+++ b/web/app/components/base/copy-feedback/index.tsx@@ -5,7 +5,8 @@ import {} from '@remixicon/react'import copy from 'copy-to-clipboard'import { debounce } from 'lodash-es'-import React, { useState } from 'react'+import * as React from 'react'+import { useState } from 'react'import { useTranslation } from 'react-i18next'import ActionButton from '@/app/components/base/action-button'import Tooltip from '@/app/components/base/tooltip'diff --git a/web/app/components/base/copy-icon/index.tsx b/web/app/components/base/copy-icon/index.tsxindex a7cb12c12b8..935444a3c14 100644--- a/web/app/components/base/copy-icon/index.tsx+++ b/web/app/components/base/copy-icon/index.tsx@@ -1,7 +1,8 @@'use client'import copy from 'copy-to-clipboard'import { debounce } from 'lodash-es'-import React, { useState } from 'react'+import * as React from 'react'+import { useState } from 'react'import { useTranslation } from 'react-i18next'import {Copy,diff --git a/web/app/components/base/date-and-time-picker/calendar/days-of-week.tsx b/web/app/components/base/date-and-time-picker/calendar/days-of-week.tsxindex 30aab7a30f0..ac14d49ead4 100644--- a/web/app/components/base/date-and-time-picker/calendar/days-of-week.tsx+++ b/web/app/components/base/date-and-time-picker/calendar/days-of-week.tsx@@ -1,4 +1,4 @@-import React from 'react'+import * as React from 'react'import { useDaysOfWeek } from '../hooks'export const DaysOfWeek = () => {diff --git a/web/app/components/base/date-and-time-picker/calendar/item.tsx b/web/app/components/base/date-and-time-picker/calendar/item.tsxindex 8b6b33f96ea..f79fed0879d 100644--- a/web/app/components/base/date-and-time-picker/calendar/item.tsx+++ b/web/app/components/base/date-and-time-picker/calendar/item.tsx@@ -1,6 +1,6 @@import type { FC } from 'react'import type { CalendarItemProps } from '../types'-import React from 'react'+import * as React from 'react'import { cn } from '@/utils/classnames'import dayjs from '../utils/dayjs'diff --git a/web/app/components/base/date-and-time-picker/common/option-list-item.tsx b/web/app/components/base/date-and-time-picker/common/option-list-item.tsxindex 916e4e3d88b..040f30f686b 100644--- a/web/app/components/base/date-and-time-picker/common/option-list-item.tsx+++ b/web/app/components/base/date-and-time-picker/common/option-list-item.tsx@@ -1,5 +1,6 @@import type { FC } from 'react'-import React, { useEffect, useRef } from 'react'+import * as React from 'react'+import { useEffect, useRef } from 'react'import { cn } from '@/utils/classnames'type OptionListItemProps = {diff --git a/web/app/components/base/date-and-time-picker/date-picker/footer.tsx b/web/app/components/base/date-and-time-picker/date-picker/footer.tsxindex 44288b51096..d229564596f 100644--- a/web/app/components/base/date-and-time-picker/date-picker/footer.tsx+++ b/web/app/components/base/date-and-time-picker/date-picker/footer.tsx@@ -1,7 +1,7 @@import type { FC } from 'react'import type { DatePickerFooterProps } from '../types'import { RiTimeLine } from '@remixicon/react'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import { cn } from '@/utils/classnames'import Button from '../../button'diff --git a/web/app/components/base/date-and-time-picker/date-picker/header.tsx b/web/app/components/base/date-and-time-picker/date-picker/header.tsxindex 811a8387e25..4177edfe7a5 100644--- a/web/app/components/base/date-and-time-picker/date-picker/header.tsx+++ b/web/app/components/base/date-and-time-picker/date-picker/header.tsx@@ -1,7 +1,7 @@import type { FC } from 'react'import type { DatePickerHeaderProps } from '../types'import { RiArrowDownSLine, RiArrowUpSLine } from '@remixicon/react'-import React from 'react'+import * as React from 'react'import { useMonths } from '../hooks'const Header: FC<DatePickerHeaderProps> = ({diff --git a/web/app/components/base/date-and-time-picker/date-picker/index.tsx b/web/app/components/base/date-and-time-picker/date-picker/index.tsxindex 877b221dfcd..75a3ec61448 100644--- a/web/app/components/base/date-and-time-picker/date-picker/index.tsx+++ b/web/app/components/base/date-and-time-picker/date-picker/index.tsx@@ -1,7 +1,8 @@import type { Dayjs } from 'dayjs'import type { DatePickerProps, Period } from '../types'import { RiCalendarLine, RiCloseCircleFill } from '@remixicon/react'-import React, { useCallback, useEffect, useMemo, useRef, useState } from 'react'+import * as React from 'react'+import { useCallback, useEffect, useMemo, useRef, useState } from 'react'import { useTranslation } from 'react-i18next'import {PortalToFollowElem,diff --git a/web/app/components/base/date-and-time-picker/time-picker/footer.tsx b/web/app/components/base/date-and-time-picker/time-picker/footer.tsxindex 41ab93e25e7..74103fbf0bc 100644--- a/web/app/components/base/date-and-time-picker/time-picker/footer.tsx+++ b/web/app/components/base/date-and-time-picker/time-picker/footer.tsx@@ -1,6 +1,6 @@import type { FC } from 'react'import type { TimePickerFooterProps } from '../types'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import Button from '../../button'diff --git a/web/app/components/base/date-and-time-picker/time-picker/header.tsx b/web/app/components/base/date-and-time-picker/time-picker/header.tsxindex 3f74b8e20d0..b5c7fb0bcbc 100644--- a/web/app/components/base/date-and-time-picker/time-picker/header.tsx+++ b/web/app/components/base/date-and-time-picker/time-picker/header.tsx@@ -1,4 +1,4 @@-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'type Props = {diff --git a/web/app/components/base/date-and-time-picker/time-picker/index.spec.tsx b/web/app/components/base/date-and-time-picker/time-picker/index.spec.tsxindex 5489002210a..596b1a69b6c 100644--- a/web/app/components/base/date-and-time-picker/time-picker/index.spec.tsx+++ b/web/app/components/base/date-and-time-picker/time-picker/index.spec.tsx@@ -1,6 +1,6 @@import type { TimePickerProps } from '../types'import { fireEvent, render, screen } from '@testing-library/react'-import React from 'react'+import * as React from 'react'import dayjs, { isDayjsObject } from '../utils/dayjs'import TimePicker from './index'diff --git a/web/app/components/base/date-and-time-picker/time-picker/index.tsx b/web/app/components/base/date-and-time-picker/time-picker/index.tsxindex 874146b4579..3e0ff2d3535 100644--- a/web/app/components/base/date-and-time-picker/time-picker/index.tsx+++ b/web/app/components/base/date-and-time-picker/time-picker/index.tsx@@ -1,7 +1,8 @@import type { Dayjs } from 'dayjs'import type { TimePickerProps } from '../types'import { RiCloseCircleFill, RiTimeLine } from '@remixicon/react'-import React, { useCallback, useEffect, useRef, useState } from 'react'+import * as React from 'react'+import { useCallback, useEffect, useRef, useState } from 'react'import { useTranslation } from 'react-i18next'import {PortalToFollowElem,diff --git a/web/app/components/base/date-and-time-picker/time-picker/options.tsx b/web/app/components/base/date-and-time-picker/time-picker/options.tsxindex abd7e33b56d..a4117f03fb6 100644--- a/web/app/components/base/date-and-time-picker/time-picker/options.tsx+++ b/web/app/components/base/date-and-time-picker/time-picker/options.tsx@@ -1,6 +1,6 @@import type { FC } from 'react'import type { TimeOptionsProps } from '../types'-import React from 'react'+import * as React from 'react'import OptionListItem from '../common/option-list-item'import { useTimeOptions } from '../hooks'diff --git a/web/app/components/base/date-and-time-picker/year-and-month-picker/footer.tsx b/web/app/components/base/date-and-time-picker/year-and-month-picker/footer.tsxindex 883540a36b2..b77ab0f8a70 100644--- a/web/app/components/base/date-and-time-picker/year-and-month-picker/footer.tsx+++ b/web/app/components/base/date-and-time-picker/year-and-month-picker/footer.tsx@@ -1,6 +1,6 @@import type { FC } from 'react'import type { YearAndMonthPickerFooterProps } from '../types'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import Button from '../../button'diff --git a/web/app/components/base/date-and-time-picker/year-and-month-picker/header.tsx b/web/app/components/base/date-and-time-picker/year-and-month-picker/header.tsxindex 8e1af955504..043598884af 100644--- a/web/app/components/base/date-and-time-picker/year-and-month-picker/header.tsx+++ b/web/app/components/base/date-and-time-picker/year-and-month-picker/header.tsx@@ -1,7 +1,7 @@import type { FC } from 'react'import type { YearAndMonthPickerHeaderProps } from '../types'import { RiArrowUpSLine } from '@remixicon/react'-import React from 'react'+import * as React from 'react'import { useMonths } from '../hooks'const Header: FC<YearAndMonthPickerHeaderProps> = ({diff --git a/web/app/components/base/date-and-time-picker/year-and-month-picker/options.tsx b/web/app/components/base/date-and-time-picker/year-and-month-picker/options.tsxindex e0f5f5387fa..9b0d602a3e7 100644--- a/web/app/components/base/date-and-time-picker/year-and-month-picker/options.tsx+++ b/web/app/components/base/date-and-time-picker/year-and-month-picker/options.tsx@@ -1,6 +1,6 @@import type { FC } from 'react'import type { YearAndMonthPickerOptionsProps } from '../types'-import React from 'react'+import * as React from 'react'import OptionListItem from '../common/option-list-item'import { useMonths, useYearOptions } from '../hooks'diff --git a/web/app/components/base/divider/index.tsx b/web/app/components/base/divider/index.tsxindex 1a34be7397d..cde3189ed05 100644--- a/web/app/components/base/divider/index.tsx+++ b/web/app/components/base/divider/index.tsx@@ -1,7 +1,7 @@import type { VariantProps } from 'class-variance-authority'import type { CSSProperties, FC } from 'react'import { cva } from 'class-variance-authority'-import React from 'react'+import * as React from 'react'import { cn } from '@/utils/classnames'const dividerVariants = cva('', {diff --git a/web/app/components/base/drawer-plus/index.tsx b/web/app/components/base/drawer-plus/index.tsxindex 71f4372d35d..0b599978856 100644--- a/web/app/components/base/drawer-plus/index.tsx+++ b/web/app/components/base/drawer-plus/index.tsx@@ -1,7 +1,8 @@'use client'import type { FC } from 'react'import { RiCloseLine } from '@remixicon/react'-import React, { useRef } from 'react'+import * as React from 'react'+import { useRef } from 'react'import Drawer from '@/app/components/base/drawer'import useBreakpoints, { MediaType } from '@/hooks/use-breakpoints'import { cn } from '@/utils/classnames'diff --git a/web/app/components/base/drawer/index.spec.tsx b/web/app/components/base/drawer/index.spec.tsxindex dae574332c0..51cf0fa55cd 100644--- a/web/app/components/base/drawer/index.spec.tsx+++ b/web/app/components/base/drawer/index.spec.tsx@@ -1,6 +1,6 @@import type { IDrawerProps } from './index'import { fireEvent, render, screen } from '@testing-library/react'-import React from 'react'+import * as React from 'react'import Drawer from './index'// Capture dialog onClose for testingdiff --git a/web/app/components/base/effect/index.tsx b/web/app/components/base/effect/index.tsxindex 85fc5a7cd85..dd3415dc071 100644--- a/web/app/components/base/effect/index.tsx+++ b/web/app/components/base/effect/index.tsx@@ -1,4 +1,4 @@-import React from 'react'+import * as React from 'react'import { cn } from '@/utils/classnames'type EffectProps = {diff --git a/web/app/components/base/emoji-picker/Inner.tsx b/web/app/components/base/emoji-picker/Inner.tsxindex 4add3de9ba2..f125cfa63b7 100644--- a/web/app/components/base/emoji-picker/Inner.tsx+++ b/web/app/components/base/emoji-picker/Inner.tsx@@ -8,7 +8,8 @@ import {MagnifyingGlassIcon,} from '@heroicons/react/24/outline'import { init } from 'emoji-mart'-import React, { useState } from 'react'+import * as React from 'react'+import { useState } from 'react'import Divider from '@/app/components/base/divider'import Input from '@/app/components/base/input'import { cn } from '@/utils/classnames'diff --git a/web/app/components/base/emoji-picker/index.tsx b/web/app/components/base/emoji-picker/index.tsxindex 0c04f25fb59..53bef278f61 100644--- a/web/app/components/base/emoji-picker/index.tsx+++ b/web/app/components/base/emoji-picker/index.tsx@@ -1,7 +1,8 @@'use client'import type { FC } from 'react'import { noop } from 'lodash-es'-import React, { useCallback, useState } from 'react'+import * as React from 'react'+import { useCallback, useState } from 'react'import { useTranslation } from 'react-i18next'import Button from '@/app/components/base/button'import Divider from '@/app/components/base/divider'diff --git a/web/app/components/base/error-boundary/index.tsx b/web/app/components/base/error-boundary/index.tsxindex d72621a7547..b041bba4d6a 100644--- a/web/app/components/base/error-boundary/index.tsx+++ b/web/app/components/base/error-boundary/index.tsx@@ -1,7 +1,8 @@'use client'import type { ErrorInfo, ReactNode } from 'react'import { RiAlertLine, RiBugLine } from '@remixicon/react'-import React, { useCallback, useEffect, useRef, useState } from 'react'+import * as React from 'react'+import { useCallback, useEffect, useRef, useState } from 'react'import Button from '@/app/components/base/button'import { cn } from '@/utils/classnames'diff --git a/web/app/components/base/features/new-feature-panel/annotation-reply/annotation-ctrl-button.tsx b/web/app/components/base/features/new-feature-panel/annotation-reply/annotation-ctrl-button.tsxindex 5d562315b12..fbeffa24223 100644--- a/web/app/components/base/features/new-feature-panel/annotation-reply/annotation-ctrl-button.tsx+++ b/web/app/components/base/features/new-feature-panel/annotation-reply/annotation-ctrl-button.tsx@@ -4,7 +4,7 @@ import {RiEditLine,RiFileEditLine,} from '@remixicon/react'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import ActionButton from '@/app/components/base/action-button'import Toast from '@/app/components/base/toast'diff --git a/web/app/components/base/features/new-feature-panel/annotation-reply/config-param-modal.tsx b/web/app/components/base/features/new-feature-panel/annotation-reply/config-param-modal.tsxindex 5e46e4d4783..9050da6194e 100644--- a/web/app/components/base/features/new-feature-panel/annotation-reply/config-param-modal.tsx+++ b/web/app/components/base/features/new-feature-panel/annotation-reply/config-param-modal.tsx@@ -1,7 +1,8 @@'use client'import type { FC } from 'react'import type { AnnotationReplyConfig } from '@/models/debug'-import React, { useState } from 'react'+import * as React from 'react'+import { useState } from 'react'import { useTranslation } from 'react-i18next'import Button from '@/app/components/base/button'import Modal from '@/app/components/base/modal'diff --git a/web/app/components/base/features/new-feature-panel/annotation-reply/config-param.tsx b/web/app/components/base/features/new-feature-panel/annotation-reply/config-param.tsxindex f1a92f56286..9642aed0a8d 100644--- a/web/app/components/base/features/new-feature-panel/annotation-reply/config-param.tsx+++ b/web/app/components/base/features/new-feature-panel/annotation-reply/config-param.tsx@@ -1,6 +1,6 @@'use client'import type { FC } from 'react'-import React from 'react'+import * as React from 'react'import Tooltip from '@/app/components/base/tooltip'export const Item: FC<{ title: string, tooltip: string, children: React.JSX.Element }> = ({diff --git a/web/app/components/base/features/new-feature-panel/annotation-reply/index.tsx b/web/app/components/base/features/new-feature-panel/annotation-reply/index.tsxindex b6d0235bfdd..6acd6cad70d 100644--- a/web/app/components/base/features/new-feature-panel/annotation-reply/index.tsx+++ b/web/app/components/base/features/new-feature-panel/annotation-reply/index.tsx@@ -3,7 +3,8 @@ import type { AnnotationReplyConfig } from '@/models/debug'import { RiEqualizer2Line, RiExternalLinkLine } from '@remixicon/react'import { produce } from 'immer'import { usePathname, useRouter } from 'next/navigation'-import React, { useCallback, useState } from 'react'+import * as React from 'react'+import { useCallback, useState } from 'react'import { useTranslation } from 'react-i18next'import Button from '@/app/components/base/button'import { useFeatures, useFeaturesStore } from '@/app/components/base/features/hooks'diff --git a/web/app/components/base/features/new-feature-panel/annotation-reply/score-slider/index.tsx b/web/app/components/base/features/new-feature-panel/annotation-reply/score-slider/index.tsxindex d04b56b228b..a5fd2b75bfc 100644--- a/web/app/components/base/features/new-feature-panel/annotation-reply/score-slider/index.tsx+++ b/web/app/components/base/features/new-feature-panel/annotation-reply/score-slider/index.tsx@@ -1,6 +1,6 @@'use client'import type { FC } from 'react'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import Slider from '@/app/components/base/features/new-feature-panel/annotation-reply/score-slider/base-slider'diff --git a/web/app/components/base/features/new-feature-panel/annotation-reply/use-annotation-config.ts b/web/app/components/base/features/new-feature-panel/annotation-reply/use-annotation-config.tsindex bd4de98daa5..c74175846d2 100644--- a/web/app/components/base/features/new-feature-panel/annotation-reply/use-annotation-config.ts+++ b/web/app/components/base/features/new-feature-panel/annotation-reply/use-annotation-config.ts@@ -1,7 +1,8 @@import type { EmbeddingModelConfig } from '@/app/components/app/annotation/type'import type { AnnotationReplyConfig } from '@/models/debug'import { produce } from 'immer'-import React, { useState } from 'react'+import * as React from 'react'+import { useState } from 'react'import { AnnotationEnableStatus, JobStatus } from '@/app/components/app/annotation/type'import { ANNOTATION_DEFAULT } from '@/config'import { useProviderContext } from '@/context/provider-context'diff --git a/web/app/components/base/features/new-feature-panel/citation.tsx b/web/app/components/base/features/new-feature-panel/citation.tsxindex 321958bea4b..e8854176f9a 100644--- a/web/app/components/base/features/new-feature-panel/citation.tsx+++ b/web/app/components/base/features/new-feature-panel/citation.tsx@@ -1,6 +1,7 @@import type { OnFeaturesChange } from '@/app/components/base/features/types'import { produce } from 'immer'-import React, { useCallback } from 'react'+import * as React from 'react'+import { useCallback } from 'react'import { useTranslation } from 'react-i18next'import { useFeatures, useFeaturesStore } from '@/app/components/base/features/hooks'import FeatureCard from '@/app/components/base/features/new-feature-panel/feature-card'diff --git a/web/app/components/base/features/new-feature-panel/conversation-opener/index.tsx b/web/app/components/base/features/new-feature-panel/conversation-opener/index.tsxindex 0fef89fc333..3568ce64f59 100644--- a/web/app/components/base/features/new-feature-panel/conversation-opener/index.tsx+++ b/web/app/components/base/features/new-feature-panel/conversation-opener/index.tsx@@ -3,7 +3,8 @@ import type { InputVar } from '@/app/components/workflow/types'import type { PromptVariable } from '@/models/debug'import { RiEditLine } from '@remixicon/react'import { produce } from 'immer'-import React, { useCallback, useState } from 'react'+import * as React from 'react'+import { useCallback, useState } from 'react'import { useTranslation } from 'react-i18next'import Button from '@/app/components/base/button'import { useFeatures, useFeaturesStore } from '@/app/components/base/features/hooks'diff --git a/web/app/components/base/features/new-feature-panel/conversation-opener/modal.tsx b/web/app/components/base/features/new-feature-panel/conversation-opener/modal.tsxindex cda5a25ae00..a1b66ae0fc6 100644--- a/web/app/components/base/features/new-feature-panel/conversation-opener/modal.tsx+++ b/web/app/components/base/features/new-feature-panel/conversation-opener/modal.tsx@@ -5,7 +5,8 @@ import { RiAddLine, RiAsterisk, RiCloseLine, RiDeleteBinLine, RiDraggable } fromimport { useBoolean } from 'ahooks'import { produce } from 'immer'import { noop } from 'lodash-es'-import React, { useCallback, useEffect, useMemo, useState } from 'react'+import * as React from 'react'+import { useCallback, useEffect, useMemo, useState } from 'react'import { useTranslation } from 'react-i18next'import { ReactSortable } from 'react-sortablejs'import ConfirmAddVar from '@/app/components/app/configuration/config-prompt/confirm-add-var'diff --git a/web/app/components/base/features/new-feature-panel/feature-bar.tsx b/web/app/components/base/features/new-feature-panel/feature-bar.tsxindex 585c2d923b9..94b278c5de3 100644--- a/web/app/components/base/features/new-feature-panel/feature-bar.tsx+++ b/web/app/components/base/features/new-feature-panel/feature-bar.tsx@@ -1,5 +1,6 @@import { RiApps2AddLine, RiArrowRightLine, RiSparklingFill } from '@remixicon/react'-import React, { useMemo, useState } from 'react'+import * as React from 'react'+import { useMemo, useState } from 'react'import { useTranslation } from 'react-i18next'import Button from '@/app/components/base/button'import { useFeatures } from '@/app/components/base/features/hooks'diff --git a/web/app/components/base/features/new-feature-panel/feature-card.tsx b/web/app/components/base/features/new-feature-panel/feature-card.tsxindex b2b530e8bdb..7b7327517b3 100644--- a/web/app/components/base/features/new-feature-panel/feature-card.tsx+++ b/web/app/components/base/features/new-feature-panel/feature-card.tsx@@ -1,7 +1,7 @@import {RiQuestionLine,} from '@remixicon/react'-import React from 'react'+import * as React from 'react'import Switch from '@/app/components/base/switch'import Tooltip from '@/app/components/base/tooltip'diff --git a/web/app/components/base/features/new-feature-panel/file-upload/index.tsx b/web/app/components/base/features/new-feature-panel/file-upload/index.tsxindex 66f138037c1..1af70ddb190 100644--- a/web/app/components/base/features/new-feature-panel/file-upload/index.tsx+++ b/web/app/components/base/features/new-feature-panel/file-upload/index.tsx@@ -1,7 +1,8 @@import type { OnFeaturesChange } from '@/app/components/base/features/types'import { RiEqualizer2Line } from '@remixicon/react'import { produce } from 'immer'-import React, { useCallback, useMemo, useState } from 'react'+import * as React from 'react'+import { useCallback, useMemo, useState } from 'react'import { useTranslation } from 'react-i18next'import Button from '@/app/components/base/button'import { useFeatures, useFeaturesStore } from '@/app/components/base/features/hooks'diff --git a/web/app/components/base/features/new-feature-panel/file-upload/setting-content.tsx b/web/app/components/base/features/new-feature-panel/file-upload/setting-content.tsxindex caa9a99e226..da306a6ac99 100644--- a/web/app/components/base/features/new-feature-panel/file-upload/setting-content.tsx+++ b/web/app/components/base/features/new-feature-panel/file-upload/setting-content.tsx@@ -2,7 +2,8 @@ import type { OnFeaturesChange } from '@/app/components/base/features/types'import type { UploadFileSetting } from '@/app/components/workflow/types'import { RiCloseLine } from '@remixicon/react'import { produce } from 'immer'-import React, { useCallback, useMemo, useState } from 'react'+import * as React from 'react'+import { useCallback, useMemo, useState } from 'react'import { useTranslation } from 'react-i18next'import Button from '@/app/components/base/button'import { useFeatures, useFeaturesStore } from '@/app/components/base/features/hooks'diff --git a/web/app/components/base/features/new-feature-panel/follow-up.tsx b/web/app/components/base/features/new-feature-panel/follow-up.tsxindex ad651ab1e0b..d45476c6804 100644--- a/web/app/components/base/features/new-feature-panel/follow-up.tsx+++ b/web/app/components/base/features/new-feature-panel/follow-up.tsx@@ -1,6 +1,7 @@import type { OnFeaturesChange } from '@/app/components/base/features/types'import { produce } from 'immer'-import React, { useCallback } from 'react'+import * as React from 'react'+import { useCallback } from 'react'import { useTranslation } from 'react-i18next'import { useFeatures, useFeaturesStore } from '@/app/components/base/features/hooks'import FeatureCard from '@/app/components/base/features/new-feature-panel/feature-card'diff --git a/web/app/components/base/features/new-feature-panel/image-upload/index.tsx b/web/app/components/base/features/new-feature-panel/image-upload/index.tsxindex 043d0615127..9c2990fb72e 100644--- a/web/app/components/base/features/new-feature-panel/image-upload/index.tsx+++ b/web/app/components/base/features/new-feature-panel/image-upload/index.tsx@@ -1,7 +1,8 @@import type { OnFeaturesChange } from '@/app/components/base/features/types'import { RiEqualizer2Line, RiImage2Fill } from '@remixicon/react'import { produce } from 'immer'-import React, { useCallback, useMemo, useState } from 'react'+import * as React from 'react'+import { useCallback, useMemo, useState } from 'react'import { useTranslation } from 'react-i18next'import Badge from '@/app/components/base/badge'import Button from '@/app/components/base/button'diff --git a/web/app/components/base/features/new-feature-panel/index.tsx b/web/app/components/base/features/new-feature-panel/index.tsxindex 8ecbb2e42f0..b6d260f03df 100644--- a/web/app/components/base/features/new-feature-panel/index.tsx+++ b/web/app/components/base/features/new-feature-panel/index.tsx@@ -2,7 +2,7 @@ import type { OnFeaturesChange } from '@/app/components/base/features/types'import type { InputVar } from '@/app/components/workflow/types'import type { PromptVariable } from '@/models/debug'import { RiCloseLine, RiInformation2Fill } from '@remixicon/react'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import AnnotationReply from '@/app/components/base/features/new-feature-panel/annotation-reply'diff --git a/web/app/components/base/features/new-feature-panel/moderation/index.tsx b/web/app/components/base/features/new-feature-panel/moderation/index.tsxindex 9fdb684f1b9..d1b11aa8c89 100644--- a/web/app/components/base/features/new-feature-panel/moderation/index.tsx+++ b/web/app/components/base/features/new-feature-panel/moderation/index.tsx@@ -1,7 +1,8 @@import type { OnFeaturesChange } from '@/app/components/base/features/types'import { RiEqualizer2Line } from '@remixicon/react'import { produce } from 'immer'-import React, { useCallback, useMemo, useState } from 'react'+import * as React from 'react'+import { useCallback, useMemo, useState } from 'react'import { useTranslation } from 'react-i18next'import { useContext } from 'use-context-selector'import Button from '@/app/components/base/button'diff --git a/web/app/components/base/features/new-feature-panel/more-like-this.tsx b/web/app/components/base/features/new-feature-panel/more-like-this.tsxindex 4e2fbe07aca..98eb82c8855 100644--- a/web/app/components/base/features/new-feature-panel/more-like-this.tsx+++ b/web/app/components/base/features/new-feature-panel/more-like-this.tsx@@ -1,7 +1,8 @@import type { OnFeaturesChange } from '@/app/components/base/features/types'import { RiSparklingFill } from '@remixicon/react'import { produce } from 'immer'-import React, { useCallback } from 'react'+import * as React from 'react'+import { useCallback } from 'react'import { useTranslation } from 'react-i18next'import { useFeatures, useFeaturesStore } from '@/app/components/base/features/hooks'import FeatureCard from '@/app/components/base/features/new-feature-panel/feature-card'diff --git a/web/app/components/base/features/new-feature-panel/speech-to-text.tsx b/web/app/components/base/features/new-feature-panel/speech-to-text.tsxindex 136f7f32fad..6e9a6b06e7c 100644--- a/web/app/components/base/features/new-feature-panel/speech-to-text.tsx+++ b/web/app/components/base/features/new-feature-panel/speech-to-text.tsx@@ -1,6 +1,7 @@import type { OnFeaturesChange } from '@/app/components/base/features/types'import { produce } from 'immer'-import React, { useCallback } from 'react'+import * as React from 'react'+import { useCallback } from 'react'import { useTranslation } from 'react-i18next'import { useFeatures, useFeaturesStore } from '@/app/components/base/features/hooks'import FeatureCard from '@/app/components/base/features/new-feature-panel/feature-card'diff --git a/web/app/components/base/features/new-feature-panel/text-to-speech/index.tsx b/web/app/components/base/features/new-feature-panel/text-to-speech/index.tsxindex 482a3634ccc..96a0eaa5ff4 100644--- a/web/app/components/base/features/new-feature-panel/text-to-speech/index.tsx+++ b/web/app/components/base/features/new-feature-panel/text-to-speech/index.tsx@@ -1,7 +1,8 @@import type { OnFeaturesChange } from '@/app/components/base/features/types'import { RiEqualizer2Line } from '@remixicon/react'import { produce } from 'immer'-import React, { useCallback, useState } from 'react'+import * as React from 'react'+import { useCallback, useState } from 'react'import { useTranslation } from 'react-i18next'import Button from '@/app/components/base/button'import { useFeatures, useFeaturesStore } from '@/app/components/base/features/hooks'diff --git a/web/app/components/base/features/new-feature-panel/text-to-speech/param-config-content.tsx b/web/app/components/base/features/new-feature-panel/text-to-speech/param-config-content.tsxindex 53117d7999c..fc1052e1724 100644--- a/web/app/components/base/features/new-feature-panel/text-to-speech/param-config-content.tsx+++ b/web/app/components/base/features/new-feature-panel/text-to-speech/param-config-content.tsx@@ -6,7 +6,8 @@ import { CheckIcon, ChevronDownIcon } from '@heroicons/react/20/solid'import { RiCloseLine } from '@remixicon/react'import { produce } from 'immer'import { usePathname } from 'next/navigation'-import React, { Fragment } from 'react'+import * as React from 'react'+import { Fragment } from 'react'import { useTranslation } from 'react-i18next'import AudioBtn from '@/app/components/base/audio-btn'import { useFeatures, useFeaturesStore } from '@/app/components/base/features/hooks'diff --git a/web/app/components/base/file-thumb/image-render.tsx b/web/app/components/base/file-thumb/image-render.tsxindex f21f0a84e59..bda092ffc33 100644--- a/web/app/components/base/file-thumb/image-render.tsx+++ b/web/app/components/base/file-thumb/image-render.tsx@@ -1,4 +1,4 @@-import React from 'react'+import * as React from 'react'type ImageRenderProps = {sourceUrl: stringdiff --git a/web/app/components/base/file-thumb/index.tsx b/web/app/components/base/file-thumb/index.tsxindex e3601c445ad..09f88d5d3ba 100644--- a/web/app/components/base/file-thumb/index.tsx+++ b/web/app/components/base/file-thumb/index.tsx@@ -1,6 +1,7 @@import type { VariantProps } from 'class-variance-authority'import { cva } from 'class-variance-authority'-import React, { useCallback } from 'react'+import * as React from 'react'+import { useCallback } from 'react'import { cn } from '@/utils/classnames'import { FileTypeIcon } from '../file-uploader'import { getFileAppearanceType } from '../file-uploader/utils'diff --git a/web/app/components/base/file-uploader/audio-preview.tsx b/web/app/components/base/file-uploader/audio-preview.tsxindex 80ccc6225c1..e8be22fc9f9 100644--- a/web/app/components/base/file-uploader/audio-preview.tsx+++ b/web/app/components/base/file-uploader/audio-preview.tsx@@ -1,6 +1,6 @@import type { FC } from 'react'import { RiCloseLine } from '@remixicon/react'-import React from 'react'+import * as React from 'react'import { createPortal } from 'react-dom'import { useHotkeys } from 'react-hotkeys-hook'diff --git a/web/app/components/base/file-uploader/file-list-in-log.tsx b/web/app/components/base/file-uploader/file-list-in-log.tsxindex d35e6e096a5..279341c2bba 100644--- a/web/app/components/base/file-uploader/file-list-in-log.tsx+++ b/web/app/components/base/file-uploader/file-list-in-log.tsx@@ -1,6 +1,7 @@import type { FileEntity } from './types'import { RiArrowRightSLine } from '@remixicon/react'-import React, { useMemo, useState } from 'react'+import * as React from 'react'+import { useMemo, useState } from 'react'import { useTranslation } from 'react-i18next'import Tooltip from '@/app/components/base/tooltip'import { SupportUploadFileTypes } from '@/app/components/workflow/types'diff --git a/web/app/components/base/file-uploader/pdf-preview.tsx b/web/app/components/base/file-uploader/pdf-preview.tsxindex 30aeccfbebf..04a90a414cf 100644--- a/web/app/components/base/file-uploader/pdf-preview.tsx+++ b/web/app/components/base/file-uploader/pdf-preview.tsx@@ -2,7 +2,8 @@ import type { FC } from 'react'import { RiCloseLine, RiZoomInLine, RiZoomOutLine } from '@remixicon/react'import { t } from 'i18next'import { noop } from 'lodash-es'-import React, { useState } from 'react'+import * as React from 'react'+import { useState } from 'react'import { createPortal } from 'react-dom'import { useHotkeys } from 'react-hotkeys-hook'import { PdfHighlighter, PdfLoader } from 'react-pdf-highlighter'diff --git a/web/app/components/base/file-uploader/video-preview.tsx b/web/app/components/base/file-uploader/video-preview.tsxindex ef0c5c17b17..94d9a94c582 100644--- a/web/app/components/base/file-uploader/video-preview.tsx+++ b/web/app/components/base/file-uploader/video-preview.tsx@@ -1,6 +1,6 @@import type { FC } from 'react'import { RiCloseLine } from '@remixicon/react'-import React from 'react'+import * as React from 'react'import { createPortal } from 'react-dom'import { useHotkeys } from 'react-hotkeys-hook'diff --git a/web/app/components/base/form/components/field/file-uploader.tsx b/web/app/components/base/form/components/field/file-uploader.tsxindex 278e8e0fa52..b498cfb9515 100644--- a/web/app/components/base/form/components/field/file-uploader.tsx+++ b/web/app/components/base/form/components/field/file-uploader.tsx@@ -1,7 +1,7 @@import type { FileUploaderInAttachmentWrapperProps } from '../../../file-uploader/file-uploader-in-attachment'import type { FileEntity } from '../../../file-uploader/types'import type { LabelProps } from '../label'-import React from 'react'+import * as React from 'react'import { cn } from '@/utils/classnames'import { useFieldContext } from '../..'import FileUploaderInAttachmentWrapper from '../../../file-uploader/file-uploader-in-attachment'diff --git a/web/app/components/base/form/components/field/input-type-select/option.tsx b/web/app/components/base/form/components/field/input-type-select/option.tsxindex f0b9ee30682..d678a3e93d7 100644--- a/web/app/components/base/form/components/field/input-type-select/option.tsx+++ b/web/app/components/base/form/components/field/input-type-select/option.tsx@@ -1,5 +1,5 @@import type { FileTypeSelectOption } from './types'-import React from 'react'+import * as React from 'react'import Badge from '@/app/components/base/badge'type OptionProps = {diff --git a/web/app/components/base/form/components/field/input-type-select/trigger.tsx b/web/app/components/base/form/components/field/input-type-select/trigger.tsxindex bdd6796f708..eb26a49be96 100644--- a/web/app/components/base/form/components/field/input-type-select/trigger.tsx+++ b/web/app/components/base/form/components/field/input-type-select/trigger.tsx@@ -1,6 +1,6 @@import type { FileTypeSelectOption } from './types'import { RiArrowDownSLine } from '@remixicon/react'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import Badge from '@/app/components/base/badge'import { cn } from '@/utils/classnames'diff --git a/web/app/components/base/form/components/field/number-input.tsx b/web/app/components/base/form/components/field/number-input.tsxindex dcc4fd6663f..a7844983aec 100644--- a/web/app/components/base/form/components/field/number-input.tsx+++ b/web/app/components/base/form/components/field/number-input.tsx@@ -1,6 +1,6 @@import type { InputNumberProps } from '../../../input-number'import type { LabelProps } from '../label'-import React from 'react'+import * as React from 'react'import { cn } from '@/utils/classnames'import { useFieldContext } from '../..'import { InputNumber } from '../../../input-number'diff --git a/web/app/components/base/form/components/field/text-area.tsx b/web/app/components/base/form/components/field/text-area.tsxindex 16979d3748e..295482e56ae 100644--- a/web/app/components/base/form/components/field/text-area.tsx+++ b/web/app/components/base/form/components/field/text-area.tsx@@ -1,6 +1,6 @@import type { TextareaProps } from '../../../textarea'import type { LabelProps } from '../label'-import React from 'react'+import * as React from 'react'import { cn } from '@/utils/classnames'import { useFieldContext } from '../..'import Textarea from '../../../textarea'diff --git a/web/app/components/base/form/components/field/text.tsx b/web/app/components/base/form/components/field/text.tsxindex 470033b58a5..c9b46919a41 100644--- a/web/app/components/base/form/components/field/text.tsx+++ b/web/app/components/base/form/components/field/text.tsx@@ -1,6 +1,6 @@import type { InputProps } from '../../../input'import type { LabelProps } from '../label'-import React from 'react'+import * as React from 'react'import { cn } from '@/utils/classnames'import { useFieldContext } from '../..'import Input from '../../../input'diff --git a/web/app/components/base/form/form-scenarios/base/field.tsx b/web/app/components/base/form/form-scenarios/base/field.tsxindex d41499bbb27..6fc59d90626 100644--- a/web/app/components/base/form/form-scenarios/base/field.tsx+++ b/web/app/components/base/form/form-scenarios/base/field.tsx@@ -1,6 +1,6 @@import type { BaseConfiguration } from './types'import { useStore } from '@tanstack/react-form'-import React from 'react'+import * as React from 'react'import { withForm } from '../..'import { BaseFieldType } from './types'diff --git a/web/app/components/base/form/form-scenarios/base/index.tsx b/web/app/components/base/form/form-scenarios/base/index.tsxindex 4f154cc2e57..af552e4a815 100644--- a/web/app/components/base/form/form-scenarios/base/index.tsx+++ b/web/app/components/base/form/form-scenarios/base/index.tsx@@ -1,5 +1,6 @@import type { BaseFormProps } from './types'-import React, { useMemo } from 'react'+import * as React from 'react'+import { useMemo } from 'react'import { useAppForm } from '../..'import BaseField from './field'import { generateZodSchema } from './utils'diff --git a/web/app/components/base/form/form-scenarios/input-field/field.tsx b/web/app/components/base/form/form-scenarios/input-field/field.tsxindex 0892cc2f45e..e82ae8f914f 100644--- a/web/app/components/base/form/form-scenarios/input-field/field.tsx+++ b/web/app/components/base/form/form-scenarios/input-field/field.tsx@@ -1,6 +1,6 @@import type { InputFieldConfiguration } from './types'import { useStore } from '@tanstack/react-form'-import React from 'react'+import * as React from 'react'import { withForm } from '../..'import { InputFieldType } from './types'diff --git a/web/app/components/base/form/form-scenarios/node-panel/field.tsx b/web/app/components/base/form/form-scenarios/node-panel/field.tsxindex 5e2755a14c2..6597d8fa32d 100644--- a/web/app/components/base/form/form-scenarios/node-panel/field.tsx+++ b/web/app/components/base/form/form-scenarios/node-panel/field.tsx@@ -1,6 +1,6 @@import type { InputFieldConfiguration } from './types'import { useStore } from '@tanstack/react-form'-import React from 'react'+import * as React from 'react'import { withForm } from '../..'import { InputFieldType } from './types'diff --git a/web/app/components/base/ga/index.tsx b/web/app/components/base/ga/index.tsxindex 91614c34e07..2d5fe101d03 100644--- a/web/app/components/base/ga/index.tsx+++ b/web/app/components/base/ga/index.tsx@@ -1,7 +1,7 @@import type { FC } from 'react'import { headers } from 'next/headers'import Script from 'next/script'-import React from 'react'+import * as React from 'react'import { IS_CE_EDITION } from '@/config'export enum GaType {diff --git a/web/app/components/base/icons/IconBase.spec.tsx b/web/app/components/base/icons/IconBase.spec.tsxindex badbbc52127..ba5efd8429f 100644--- a/web/app/components/base/icons/IconBase.spec.tsx+++ b/web/app/components/base/icons/IconBase.spec.tsx@@ -1,6 +1,6 @@import type { IconData } from './IconBase'import { fireEvent, render, screen } from '@testing-library/react'-import React from 'react'+import * as React from 'react'import IconBase from './IconBase'import * as utils from './utils'diff --git a/web/app/components/base/icons/icon-gallery.stories.tsx b/web/app/components/base/icons/icon-gallery.stories.tsxindex de7d251a1f7..55322a7ea36 100644--- a/web/app/components/base/icons/icon-gallery.stories.tsx+++ b/web/app/components/base/icons/icon-gallery.stories.tsx@@ -1,5 +1,5 @@import type { Meta, StoryObj } from '@storybook/nextjs'-import React from 'react'+import * as React from 'react'declare const require: anydiff --git a/web/app/components/base/icons/utils.ts b/web/app/components/base/icons/utils.tsindex 76be8ecc465..9a15a0816de 100644--- a/web/app/components/base/icons/utils.ts+++ b/web/app/components/base/icons/utils.ts@@ -1,4 +1,4 @@-import React from 'react'+import * as React from 'react'export type AbstractNode = {name: stringdiff --git a/web/app/components/base/image-gallery/index.tsx b/web/app/components/base/image-gallery/index.tsxindex 438fcc5b112..8ca8be0fc7c 100644--- a/web/app/components/base/image-gallery/index.tsx+++ b/web/app/components/base/image-gallery/index.tsx@@ -1,6 +1,7 @@'use client'import type { FC } from 'react'-import React, { useState } from 'react'+import * as React from 'react'+import { useState } from 'react'import ImagePreview from '@/app/components/base/image-uploader/image-preview'import { cn } from '@/utils/classnames'import s from './style.module.css'diff --git a/web/app/components/base/image-uploader/image-preview.tsx b/web/app/components/base/image-uploader/image-preview.tsxindex 37170fe1d94..bfabe5e2473 100644--- a/web/app/components/base/image-uploader/image-preview.tsx+++ b/web/app/components/base/image-uploader/image-preview.tsx@@ -2,7 +2,8 @@ import type { FC } from 'react'import { RiAddBoxLine, RiCloseLine, RiDownloadCloud2Line, RiFileCopyLine, RiZoomInLine, RiZoomOutLine } from '@remixicon/react'import { t } from 'i18next'import { noop } from 'lodash-es'-import React, { useCallback, useEffect, useRef, useState } from 'react'+import * as React from 'react'+import { useCallback, useEffect, useRef, useState } from 'react'import { createPortal } from 'react-dom'import { useHotkeys } from 'react-hotkeys-hook'import Toast from '@/app/components/base/toast'diff --git a/web/app/components/base/inline-delete-confirm/index.spec.tsx b/web/app/components/base/inline-delete-confirm/index.spec.tsxindex d42e482775b..8b360929b56 100644--- a/web/app/components/base/inline-delete-confirm/index.spec.tsx+++ b/web/app/components/base/inline-delete-confirm/index.spec.tsx@@ -1,5 +1,5 @@import { cleanup, fireEvent, render } from '@testing-library/react'-import React from 'react'+import * as React from 'react'import InlineDeleteConfirm from './index'// Mock react-i18nextdiff --git a/web/app/components/base/input-with-copy/index.spec.tsx b/web/app/components/base/input-with-copy/index.spec.tsxindex b90e52adb96..782b2bab256 100644--- a/web/app/components/base/input-with-copy/index.spec.tsx+++ b/web/app/components/base/input-with-copy/index.spec.tsx@@ -1,5 +1,5 @@import { fireEvent, render, screen, waitFor } from '@testing-library/react'-import React from 'react'+import * as React from 'react'import InputWithCopy from './index'// Create a mock function that we can track using vi.hoisteddiff --git a/web/app/components/base/input-with-copy/index.tsx b/web/app/components/base/input-with-copy/index.tsxindex 57848cb6bda..151fa435e7f 100644--- a/web/app/components/base/input-with-copy/index.tsx+++ b/web/app/components/base/input-with-copy/index.tsx@@ -3,7 +3,8 @@ import type { InputProps } from '../input'import { RiClipboardFill, RiClipboardLine } from '@remixicon/react'import copy from 'copy-to-clipboard'import { debounce } from 'lodash-es'-import React, { useEffect, useState } from 'react'+import * as React from 'react'+import { useEffect, useState } from 'react'import { useTranslation } from 'react-i18next'import { cn } from '@/utils/classnames'import ActionButton from '../action-button'diff --git a/web/app/components/base/input/index.spec.tsx b/web/app/components/base/input/index.spec.tsxindex 7409559df1a..226217a1463 100644--- a/web/app/components/base/input/index.spec.tsx+++ b/web/app/components/base/input/index.spec.tsx@@ -1,5 +1,5 @@import { fireEvent, render, screen } from '@testing-library/react'-import React from 'react'+import * as React from 'react'import Input, { inputVariants } from './index'// Mock the i18n hookdiff --git a/web/app/components/base/input/index.tsx b/web/app/components/base/input/index.tsxindex 948c15456df..98529a26bc8 100644--- a/web/app/components/base/input/index.tsx+++ b/web/app/components/base/input/index.tsx@@ -3,7 +3,7 @@ import type { ChangeEventHandler, CSSProperties, FocusEventHandler } from 'reactimport { RiCloseCircleFill, RiErrorWarningLine, RiSearchLine } from '@remixicon/react'import { cva } from 'class-variance-authority'import { noop } from 'lodash-es'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import { cn } from '@/utils/classnames'import { CopyFeedbackNew } from '../copy-feedback'diff --git a/web/app/components/base/linked-apps-panel/index.tsx b/web/app/components/base/linked-apps-panel/index.tsxindex 00a562046af..adc8ccf729e 100644--- a/web/app/components/base/linked-apps-panel/index.tsx+++ b/web/app/components/base/linked-apps-panel/index.tsx@@ -3,7 +3,7 @@ import type { FC } from 'react'import type { RelatedApp } from '@/models/datasets'import { RiArrowRightUpLine } from '@remixicon/react'import Link from 'next/link'-import React from 'react'+import * as React from 'react'import AppIcon from '@/app/components/base/app-icon'import { AppModeEnum } from '@/types/app'import { cn } from '@/utils/classnames'diff --git a/web/app/components/base/list-empty/index.tsx b/web/app/components/base/list-empty/index.tsxindex ab1c968682f..6d728e3aecc 100644--- a/web/app/components/base/list-empty/index.tsx+++ b/web/app/components/base/list-empty/index.tsx@@ -1,5 +1,5 @@import type { ReactNode } from 'react'-import React from 'react'+import * as React from 'react'import { Variable02 } from '../icons/src/vender/solid/development'import HorizontalLine from './horizontal-line'import VerticalLine from './vertical-line'diff --git a/web/app/components/base/loading/index.spec.tsx b/web/app/components/base/loading/index.spec.tsxindex 0003247586e..5140f1216bb 100644--- a/web/app/components/base/loading/index.spec.tsx+++ b/web/app/components/base/loading/index.spec.tsx@@ -1,5 +1,5 @@import { render } from '@testing-library/react'-import React from 'react'+import * as React from 'react'import Loading from './index'describe('Loading Component', () => {diff --git a/web/app/components/base/loading/index.tsx b/web/app/components/base/loading/index.tsxindex 385d59b5993..072b7618330 100644--- a/web/app/components/base/loading/index.tsx+++ b/web/app/components/base/loading/index.tsx@@ -1,6 +1,6 @@'use client'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import './style.css'diff --git a/web/app/components/base/markdown-blocks/audio-block.tsx b/web/app/components/base/markdown-blocks/audio-block.tsxindex 09001f105b0..8633c908d57 100644--- a/web/app/components/base/markdown-blocks/audio-block.tsx+++ b/web/app/components/base/markdown-blocks/audio-block.tsx@@ -3,7 +3,8 @@* Extracted from the main markdown renderer for modularity.* Uses the AudioGallery component to display audio players.*/-import React, { memo } from 'react'+import * as React from 'react'+import { memo } from 'react'import AudioGallery from '@/app/components/base/audio-gallery'const AudioBlock: any = memo(({ node }: any) => {diff --git a/web/app/components/base/markdown-blocks/form.tsx b/web/app/components/base/markdown-blocks/form.tsxindex 19872738c7d..2ccf216538e 100644--- a/web/app/components/base/markdown-blocks/form.tsx+++ b/web/app/components/base/markdown-blocks/form.tsx@@ -1,4 +1,5 @@-import React, { useEffect, useState } from 'react'+import * as React from 'react'+import { useEffect, useState } from 'react'import Button from '@/app/components/base/button'import { useChatContext } from '@/app/components/base/chat/chat/context'import Checkbox from '@/app/components/base/checkbox'diff --git a/web/app/components/base/markdown-blocks/img.tsx b/web/app/components/base/markdown-blocks/img.tsxindex 33fce13f0bc..57182828a2b 100644--- a/web/app/components/base/markdown-blocks/img.tsx+++ b/web/app/components/base/markdown-blocks/img.tsx@@ -3,7 +3,7 @@* Extracted from the main markdown renderer for modularity.* Uses the ImageGallery component to display images.*/-import React from 'react'+import * as React from 'react'import ImageGallery from '@/app/components/base/image-gallery'const Img = ({ src }: any) => {diff --git a/web/app/components/base/markdown-blocks/link.tsx b/web/app/components/base/markdown-blocks/link.tsxindex ec2518990e8..717352609fe 100644--- a/web/app/components/base/markdown-blocks/link.tsx+++ b/web/app/components/base/markdown-blocks/link.tsx@@ -3,7 +3,7 @@* Extracted from the main markdown renderer for modularity.* Handles special rendering for "abbr:" type links for interactive chat actions.*/-import React from 'react'+import * as React from 'react'import { useChatContext } from '@/app/components/base/chat/chat/context'import { isValidUrl } from './utils'diff --git a/web/app/components/base/markdown-blocks/paragraph.tsx b/web/app/components/base/markdown-blocks/paragraph.tsxindex fb1612477a6..adef509a31b 100644--- a/web/app/components/base/markdown-blocks/paragraph.tsx+++ b/web/app/components/base/markdown-blocks/paragraph.tsx@@ -3,7 +3,7 @@* Extracted from the main markdown renderer for modularity.* Handles special rendering for paragraphs that directly contain an image.*/-import React from 'react'+import * as React from 'react'import ImageGallery from '@/app/components/base/image-gallery'const Paragraph = (paragraph: any) => {diff --git a/web/app/components/base/markdown-blocks/plugin-img.tsx b/web/app/components/base/markdown-blocks/plugin-img.tsxindex 486f5900d27..259f49ca9bf 100644--- a/web/app/components/base/markdown-blocks/plugin-img.tsx+++ b/web/app/components/base/markdown-blocks/plugin-img.tsx@@ -4,7 +4,8 @@ import type { SimplePluginInfo } from '../markdown/react-markdown-wrapper'* Extracted from the main markdown renderer for modularity.* Uses the ImageGallery component to display images.*/-import React, { useEffect, useMemo, useState } from 'react'+import * as React from 'react'+import { useEffect, useMemo, useState } from 'react'import ImageGallery from '@/app/components/base/image-gallery'import { usePluginReadmeAsset } from '@/service/use-plugins'import { getMarkdownImageURL } from './utils'diff --git a/web/app/components/base/markdown-blocks/plugin-paragraph.tsx b/web/app/components/base/markdown-blocks/plugin-paragraph.tsxindex dca4ee52a22..73189289f30 100644--- a/web/app/components/base/markdown-blocks/plugin-paragraph.tsx+++ b/web/app/components/base/markdown-blocks/plugin-paragraph.tsx@@ -1,5 +1,6 @@import type { SimplePluginInfo } from '../markdown/react-markdown-wrapper'-import React, { useEffect, useMemo, useState } from 'react'+import * as React from 'react'+import { useEffect, useMemo, useState } from 'react'/*** @fileoverview Paragraph component for rendering <p> tags in Markdown.* Extracted from the main markdown renderer for modularity.diff --git a/web/app/components/base/markdown-blocks/pre-code.tsx b/web/app/components/base/markdown-blocks/pre-code.tsxindex 9d10c42d3ce..efce56a158d 100644--- a/web/app/components/base/markdown-blocks/pre-code.tsx+++ b/web/app/components/base/markdown-blocks/pre-code.tsx@@ -3,7 +3,8 @@* Extracted from the main markdown renderer for modularity.* This is a simple wrapper around the HTML <pre> element.*/-import React, { useRef } from 'react'+import * as React from 'react'+import { useRef } from 'react'function PreCode(props: { children: any }) {const ref = useRef<HTMLPreElement>(null)diff --git a/web/app/components/base/markdown-blocks/think-block.tsx b/web/app/components/base/markdown-blocks/think-block.tsxindex 20d2c5cc055..a2b0b3c2935 100644--- a/web/app/components/base/markdown-blocks/think-block.tsx+++ b/web/app/components/base/markdown-blocks/think-block.tsx@@ -1,4 +1,5 @@-import React, { useEffect, useRef, useState } from 'react'+import * as React from 'react'+import { useEffect, useRef, useState } from 'react'import { useTranslation } from 'react-i18next'import { cn } from '@/utils/classnames'import { useChatContext } from '../chat/chat/context'diff --git a/web/app/components/base/markdown-blocks/video-block.tsx b/web/app/components/base/markdown-blocks/video-block.tsxindex 9f1a36f6784..13ea490499b 100644--- a/web/app/components/base/markdown-blocks/video-block.tsx+++ b/web/app/components/base/markdown-blocks/video-block.tsx@@ -3,7 +3,8 @@* Extracted from the main markdown renderer for modularity.* Uses the VideoGallery component to display videos.*/-import React, { memo } from 'react'+import * as React from 'react'+import { memo } from 'react'import VideoGallery from '@/app/components/base/video-gallery'const VideoBlock: any = memo(({ node }: any) => {diff --git a/web/app/components/base/markdown/error-boundary.tsx b/web/app/components/base/markdown/error-boundary.tsxindex 9347491aeac..fd11af5b1c5 100644--- a/web/app/components/base/markdown/error-boundary.tsx+++ b/web/app/components/base/markdown/error-boundary.tsx@@ -5,7 +5,8 @@* logs those errors, and displays a fallback UI instead of the crashed component tree.* Primarily used around complex rendering logic like ECharts or SVG within Markdown.*/-import React, { Component } from 'react'+import * as React from 'react'+import { Component } from 'react'// **Add an ECharts runtime error handler// Avoid error #7832 (Crash when ECharts accesses undefined objects)// This can happen when a component attempts to access an undefined object that references an unregistered map, causing the program to crash.diff --git a/web/app/components/base/mermaid/index.tsx b/web/app/components/base/mermaid/index.tsxindex 540df44a565..7721b8316e1 100644--- a/web/app/components/base/mermaid/index.tsx+++ b/web/app/components/base/mermaid/index.tsx@@ -2,7 +2,8 @@ import type { MermaidConfig } from 'mermaid'import { ExclamationTriangleIcon } from '@heroicons/react/24/outline'import { MoonIcon, SunIcon } from '@heroicons/react/24/solid'import mermaid from 'mermaid'-import React, { useCallback, useEffect, useRef, useState } from 'react'+import * as React from 'react'+import { useCallback, useEffect, useRef, useState } from 'react'import { useTranslation } from 'react-i18next'import LoadingAnim from '@/app/components/base/chat/chat/loading-anim'import ImagePreview from '@/app/components/base/image-uploader/image-preview'diff --git a/web/app/components/base/modal-like-wrap/index.tsx b/web/app/components/base/modal-like-wrap/index.tsxindex 65c28735826..4c45ff2f7c1 100644--- a/web/app/components/base/modal-like-wrap/index.tsx+++ b/web/app/components/base/modal-like-wrap/index.tsx@@ -1,7 +1,7 @@'use client'import type { FC } from 'react'import { RiCloseLine } from '@remixicon/react'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import { cn } from '@/utils/classnames'import Button from '../button'diff --git a/web/app/components/base/node-status/index.tsx b/web/app/components/base/node-status/index.tsxindex 118ab7181a3..3c39fa1fb31 100644--- a/web/app/components/base/node-status/index.tsx+++ b/web/app/components/base/node-status/index.tsx@@ -3,7 +3,7 @@ import type { VariantProps } from 'class-variance-authority'import type { CSSProperties } from 'react'import { RiErrorWarningFill } from '@remixicon/react'import { cva } from 'class-variance-authority'-import React from 'react'+import * as React from 'react'import AlertTriangle from '@/app/components/base/icons/src/vender/solid/alertsAndFeedback/AlertTriangle'import { cn } from '@/utils/classnames'diff --git a/web/app/components/base/notion-connector/index.tsx b/web/app/components/base/notion-connector/index.tsxindex 48c4b3a584d..cec3a9076d9 100644--- a/web/app/components/base/notion-connector/index.tsx+++ b/web/app/components/base/notion-connector/index.tsx@@ -1,4 +1,4 @@-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import Button from '../button'import { Notion } from '../icons/src/public/common'diff --git a/web/app/components/base/notion-page-selector/credential-selector/index.tsx b/web/app/components/base/notion-page-selector/credential-selector/index.tsxindex 810ec1f4e76..a7bfa1053d6 100644--- a/web/app/components/base/notion-page-selector/credential-selector/index.tsx+++ b/web/app/components/base/notion-page-selector/credential-selector/index.tsx@@ -1,7 +1,8 @@'use client'import { Menu, MenuButton, MenuItem, MenuItems, Transition } from '@headlessui/react'import { RiArrowDownSLine } from '@remixicon/react'-import React, { Fragment, useMemo } from 'react'+import * as React from 'react'+import { Fragment, useMemo } from 'react'import { CredentialIcon } from '@/app/components/datasets/common/credential-icon'export type NotionCredential = {diff --git a/web/app/components/base/pagination/hook.ts b/web/app/components/base/pagination/hook.tsindex 366e1db8229..25fa24cb26b 100644--- a/web/app/components/base/pagination/hook.ts+++ b/web/app/components/base/pagination/hook.ts@@ -1,5 +1,6 @@import type { IPaginationProps, IUsePagination } from './type'-import React, { useCallback } from 'react'+import * as React from 'react'+import { useCallback } from 'react'const usePagination = ({currentPage,diff --git a/web/app/components/base/pagination/index.tsx b/web/app/components/base/pagination/index.tsxindex 45aa97c986c..d85b8082f9c 100644--- a/web/app/components/base/pagination/index.tsx+++ b/web/app/components/base/pagination/index.tsx@@ -1,7 +1,7 @@import type { FC } from 'react'import { RiArrowLeftLine, RiArrowRightLine } from '@remixicon/react'import { useDebounceFn } from 'ahooks'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import Button from '@/app/components/base/button'import Input from '@/app/components/base/input'diff --git a/web/app/components/base/pagination/pagination.tsx b/web/app/components/base/pagination/pagination.tsxindex 599df58dc4c..25bdf5a31b0 100644--- a/web/app/components/base/pagination/pagination.tsx+++ b/web/app/components/base/pagination/pagination.tsx@@ -5,7 +5,7 @@ import type {PageButtonProps,} from './type'import { noop } from 'lodash-es'-import React from 'react'+import * as React from 'react'import { cn } from '@/utils/classnames'import usePagination from './hook'diff --git a/web/app/components/base/param-item/score-threshold-item.tsx b/web/app/components/base/param-item/score-threshold-item.tsxindex 17feea26782..d7fe82e3928 100644--- a/web/app/components/base/param-item/score-threshold-item.tsx+++ b/web/app/components/base/param-item/score-threshold-item.tsx@@ -1,6 +1,6 @@'use client'import type { FC } from 'react'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import ParamItem from '.'diff --git a/web/app/components/base/param-item/top-k-item.tsx b/web/app/components/base/param-item/top-k-item.tsxindex cfae5cf6a9b..fcfd5a9f6d2 100644--- a/web/app/components/base/param-item/top-k-item.tsx+++ b/web/app/components/base/param-item/top-k-item.tsx@@ -1,6 +1,6 @@'use client'import type { FC } from 'react'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import ParamItem from '.'diff --git a/web/app/components/base/portal-to-follow-elem/index.spec.tsx b/web/app/components/base/portal-to-follow-elem/index.spec.tsxindex 2b7cb83a53b..f320cd2a742 100644--- a/web/app/components/base/portal-to-follow-elem/index.spec.tsx+++ b/web/app/components/base/portal-to-follow-elem/index.spec.tsx@@ -1,5 +1,5 @@import { cleanup, fireEvent, render } from '@testing-library/react'-import React from 'react'+import * as React from 'react'import { PortalToFollowElem, PortalToFollowElemContent, PortalToFollowElemTrigger } from '.'const useFloatingMock = vi.fn()diff --git a/web/app/components/base/portal-to-follow-elem/index.tsx b/web/app/components/base/portal-to-follow-elem/index.tsxindex d2964e4c8a2..a656ab53084 100644--- a/web/app/components/base/portal-to-follow-elem/index.tsx+++ b/web/app/components/base/portal-to-follow-elem/index.tsx@@ -16,7 +16,8 @@ import {useRole,} from '@floating-ui/react'-import React, { useCallback, useState } from 'react'+import * as React from 'react'+import { useCallback, useState } from 'react'import { cn } from '@/utils/classnames'export type PortalToFollowElemOptions = {diff --git a/web/app/components/base/premium-badge/index.tsx b/web/app/components/base/premium-badge/index.tsxindex 130729e135f..50a5832a28e 100644--- a/web/app/components/base/premium-badge/index.tsx+++ b/web/app/components/base/premium-badge/index.tsx@@ -1,7 +1,7 @@import type { VariantProps } from 'class-variance-authority'import type { CSSProperties, ReactNode } from 'react'import { cva } from 'class-variance-authority'-import React from 'react'+import * as React from 'react'import { Highlight } from '@/app/components/base/icons/src/public/common'import { cn } from '@/utils/classnames'import './index.css'diff --git a/web/app/components/base/prompt-editor/index.tsx b/web/app/components/base/prompt-editor/index.tsxindex be1b6b79a56..99e3a3325ca 100644--- a/web/app/components/base/prompt-editor/index.tsx+++ b/web/app/components/base/prompt-editor/index.tsx@@ -26,7 +26,8 @@ import {$getRoot,TextNode,} from 'lexical'-import React, { useEffect } from 'react'+import * as React from 'react'+import { useEffect } from 'react'import { useEventEmitterContextContext } from '@/context/event-emitter'import { cn } from '@/utils/classnames'import {diff --git a/web/app/components/base/qrcode/index.tsx b/web/app/components/base/qrcode/index.tsxindex 6f6752d2ae4..664a4f104c7 100644--- a/web/app/components/base/qrcode/index.tsx+++ b/web/app/components/base/qrcode/index.tsx@@ -3,7 +3,8 @@ import {RiQrCodeLine,} from '@remixicon/react'import { QRCodeCanvas as QRCode } from 'qrcode.react'-import React, { useEffect, useRef, useState } from 'react'+import * as React from 'react'+import { useEffect, useRef, useState } from 'react'import { useTranslation } from 'react-i18next'import ActionButton from '@/app/components/base/action-button'import Tooltip from '@/app/components/base/tooltip'diff --git a/web/app/components/base/radio-card/index.tsx b/web/app/components/base/radio-card/index.tsxindex 7eb84ff2e41..ae8bb000996 100644--- a/web/app/components/base/radio-card/index.tsx+++ b/web/app/components/base/radio-card/index.tsx@@ -1,7 +1,7 @@'use client'import type { FC } from 'react'import { noop } from 'lodash-es'-import React from 'react'+import * as React from 'react'import { cn } from '@/utils/classnames'type Props = {diff --git a/web/app/components/base/radio-card/simple/index.tsx b/web/app/components/base/radio-card/simple/index.tsxindex 3a542599e1b..d5f2f0ab9c0 100644--- a/web/app/components/base/radio-card/simple/index.tsx+++ b/web/app/components/base/radio-card/simple/index.tsx@@ -1,6 +1,6 @@'use client'import type { FC } from 'react'-import React from 'react'+import * as React from 'react'import { cn } from '@/utils/classnames'import s from './style.module.css'diff --git a/web/app/components/base/radio/index.tsx b/web/app/components/base/radio/index.tsxindex 0a076007464..f5f18bac01f 100644--- a/web/app/components/base/radio/index.tsx+++ b/web/app/components/base/radio/index.tsx@@ -1,4 +1,4 @@-import type React from 'react'+import type * as React from 'react'import type { IRadioProps } from './component/radio'import Group from './component/group'import RadioComps from './component/radio'diff --git a/web/app/components/base/radio/ui.tsx b/web/app/components/base/radio/ui.tsxindex 2b2770c1042..e836dddc961 100644--- a/web/app/components/base/radio/ui.tsx+++ b/web/app/components/base/radio/ui.tsx@@ -1,6 +1,6 @@'use client'import type { FC } from 'react'-import React from 'react'+import * as React from 'react'import { cn } from '@/utils/classnames'type Props = {diff --git a/web/app/components/base/segmented-control/index.tsx b/web/app/components/base/segmented-control/index.tsxindex b9c749befb0..89a15a1f651 100644--- a/web/app/components/base/segmented-control/index.tsx+++ b/web/app/components/base/segmented-control/index.tsx@@ -1,7 +1,7 @@import type { RemixiconComponentType } from '@remixicon/react'import type { VariantProps } from 'class-variance-authority'import { cva } from 'class-variance-authority'-import React from 'react'+import * as React from 'react'import { cn } from '@/utils/classnames'import Divider from '../divider'import './index.css'diff --git a/web/app/components/base/select/index.tsx b/web/app/components/base/select/index.tsxindex 8ab8925366d..2d134bf6df6 100644--- a/web/app/components/base/select/index.tsx+++ b/web/app/components/base/select/index.tsx@@ -3,7 +3,8 @@ import type { FC } from 'react'import { Combobox, ComboboxButton, ComboboxInput, ComboboxOption, ComboboxOptions, Listbox, ListboxButton, ListboxOption, ListboxOptions } from '@headlessui/react'import { ChevronDownIcon, ChevronUpIcon, XMarkIcon } from '@heroicons/react/20/solid'import { RiCheckLine, RiLoader4Line } from '@remixicon/react'-import React, { useEffect, useRef, useState } from 'react'+import * as React from 'react'+import { useEffect, useRef, useState } from 'react'import { useTranslation } from 'react-i18next'import {PortalToFollowElem,diff --git a/web/app/components/base/spinner/index.spec.tsx b/web/app/components/base/spinner/index.spec.tsxindex d6e8fde8231..652d0612064 100644--- a/web/app/components/base/spinner/index.spec.tsx+++ b/web/app/components/base/spinner/index.spec.tsx@@ -1,5 +1,5 @@import { render } from '@testing-library/react'-import React from 'react'+import * as React from 'react'import Spinner from './index'describe('Spinner component', () => {diff --git a/web/app/components/base/spinner/index.tsx b/web/app/components/base/spinner/index.tsxindex f3810f4cff6..1c66a127f68 100644--- a/web/app/components/base/spinner/index.tsx+++ b/web/app/components/base/spinner/index.tsx@@ -1,5 +1,5 @@import type { FC } from 'react'-import React from 'react'+import * as React from 'react'type Props = {loading?: booleandiff --git a/web/app/components/base/svg/index.tsx b/web/app/components/base/svg/index.tsxindex e8e0fad9bd5..4ebfa5f3d07 100644--- a/web/app/components/base/svg/index.tsx+++ b/web/app/components/base/svg/index.tsx@@ -1,4 +1,4 @@-import React from 'react'+import * as React from 'react'import { cn } from '@/utils/classnames'import ActionButton from '../action-button'import s from './style.module.css'diff --git a/web/app/components/base/switch/index.tsx b/web/app/components/base/switch/index.tsxindex 4e32b224407..6296a33141b 100644--- a/web/app/components/base/switch/index.tsx+++ b/web/app/components/base/switch/index.tsx@@ -1,6 +1,7 @@'use client'import { Switch as OriginalSwitch } from '@headlessui/react'-import React, { useEffect, useState } from 'react'+import * as React from 'react'+import { useEffect, useState } from 'react'import { cn } from '@/utils/classnames'type SwitchProps = {diff --git a/web/app/components/base/tab-header/index.tsx b/web/app/components/base/tab-header/index.tsxindex b4dfd1f526c..e762e232323 100644--- a/web/app/components/base/tab-header/index.tsx+++ b/web/app/components/base/tab-header/index.tsx@@ -1,6 +1,6 @@'use client'import type { FC } from 'react'-import React from 'react'+import * as React from 'react'import { cn } from '@/utils/classnames'type Item = {diff --git a/web/app/components/base/tab-slider-plain/index.tsx b/web/app/components/base/tab-slider-plain/index.tsxindex 4ef4d916c9f..5b8eb270ee7 100644--- a/web/app/components/base/tab-slider-plain/index.tsx+++ b/web/app/components/base/tab-slider-plain/index.tsx@@ -1,6 +1,6 @@'use client'import type { FC } from 'react'-import React from 'react'+import * as React from 'react'import { cn } from '@/utils/classnames'type Option = {diff --git a/web/app/components/base/tag-management/panel.tsx b/web/app/components/base/tag-management/panel.tsxindex 42414e4d3d8..854de012a51 100644--- a/web/app/components/base/tag-management/panel.tsx+++ b/web/app/components/base/tag-management/panel.tsx@@ -4,7 +4,8 @@ import type { Tag } from '@/app/components/base/tag-management/constant'import { RiAddLine, RiPriceTag3Line } from '@remixicon/react'import { useUnmount } from 'ahooks'import { noop } from 'lodash-es'-import React, { useMemo, useState } from 'react'+import * as React from 'react'+import { useMemo, useState } from 'react'import { useTranslation } from 'react-i18next'import { useContext } from 'use-context-selector'import Checkbox from '@/app/components/base/checkbox'diff --git a/web/app/components/base/tag-management/trigger.tsx b/web/app/components/base/tag-management/trigger.tsxindex 84d3af55d3c..471e8cfa3d4 100644--- a/web/app/components/base/tag-management/trigger.tsx+++ b/web/app/components/base/tag-management/trigger.tsx@@ -1,5 +1,5 @@import { RiPriceTag3Line } from '@remixicon/react'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'type TriggerProps = {diff --git a/web/app/components/base/tag/index.tsx b/web/app/components/base/tag/index.tsxindex 38a686fa8ee..fa225e0f841 100644--- a/web/app/components/base/tag/index.tsx+++ b/web/app/components/base/tag/index.tsx@@ -1,4 +1,4 @@-import React from 'react'+import * as React from 'react'import { cn } from '@/utils/classnames'export type ITagProps = {diff --git a/web/app/components/base/textarea/index.tsx b/web/app/components/base/textarea/index.tsxindex 039703d8286..bea9a7bd410 100644--- a/web/app/components/base/textarea/index.tsx+++ b/web/app/components/base/textarea/index.tsx@@ -1,7 +1,7 @@import type { VariantProps } from 'class-variance-authority'import type { CSSProperties } from 'react'import { cva } from 'class-variance-authority'-import React from 'react'+import * as React from 'react'import { cn } from '@/utils/classnames'const textareaVariants = cva(diff --git a/web/app/components/base/timezone-label/__tests__/index.test.tsx b/web/app/components/base/timezone-label/__tests__/index.test.tsxindex 9fb1c6127b2..15aa4ee6857 100644--- a/web/app/components/base/timezone-label/__tests__/index.test.tsx+++ b/web/app/components/base/timezone-label/__tests__/index.test.tsx@@ -1,5 +1,5 @@import { render, screen } from '@testing-library/react'-import React from 'react'+import * as React from 'react'import TimezoneLabel from '../index'// Mock the convertTimezoneToOffsetStr functiondiff --git a/web/app/components/base/timezone-label/index.tsx b/web/app/components/base/timezone-label/index.tsxindex 2904555e5b3..f614280b3ed 100644--- a/web/app/components/base/timezone-label/index.tsx+++ b/web/app/components/base/timezone-label/index.tsx@@ -1,4 +1,5 @@-import React, { useMemo } from 'react'+import * as React from 'react'+import { useMemo } from 'react'import { convertTimezoneToOffsetStr } from '@/app/components/base/date-and-time-picker/utils/dayjs'import { cn } from '@/utils/classnames'diff --git a/web/app/components/base/toast/index.spec.tsx b/web/app/components/base/toast/index.spec.tsxindex 94b3a81d540..d32619f59a2 100644--- a/web/app/components/base/toast/index.spec.tsx+++ b/web/app/components/base/toast/index.spec.tsx@@ -1,7 +1,7 @@import type { ReactNode } from 'react'import { act, render, screen, waitFor } from '@testing-library/react'import { noop } from 'lodash-es'-import React from 'react'+import * as React from 'react'import Toast, { ToastProvider, useToastContext } from '.'const TestComponent = () => {diff --git a/web/app/components/base/toast/index.tsx b/web/app/components/base/toast/index.tsxindex f120bdeb7ce..a0167789965 100644--- a/web/app/components/base/toast/index.tsx+++ b/web/app/components/base/toast/index.tsx@@ -8,7 +8,8 @@ import {RiInformation2Fill,} from '@remixicon/react'import { noop } from 'lodash-es'-import React, { useEffect, useState } from 'react'+import * as React from 'react'+import { useEffect, useState } from 'react'import { createRoot } from 'react-dom/client'import { createContext, useContext } from 'use-context-selector'import ActionButton from '@/app/components/base/action-button'diff --git a/web/app/components/base/tooltip/index.spec.tsx b/web/app/components/base/tooltip/index.spec.tsxindex 8f77db71f61..66d3157ddc5 100644--- a/web/app/components/base/tooltip/index.spec.tsx+++ b/web/app/components/base/tooltip/index.spec.tsx@@ -1,5 +1,5 @@import { act, cleanup, fireEvent, render, screen } from '@testing-library/react'-import React from 'react'+import * as React from 'react'import Tooltip from './index'afterEach(cleanup)diff --git a/web/app/components/base/tooltip/index.tsx b/web/app/components/base/tooltip/index.tsxindex db570ac6ca3..3bd379b3185 100644--- a/web/app/components/base/tooltip/index.tsx+++ b/web/app/components/base/tooltip/index.tsx@@ -3,7 +3,8 @@ import type { OffsetOptions, Placement } from '@floating-ui/react'import type { FC } from 'react'import { RiQuestionLine } from '@remixicon/react'import { useBoolean } from 'ahooks'-import React, { useEffect, useRef, useState } from 'react'+import * as React from 'react'+import { useEffect, useRef, useState } from 'react'import { PortalToFollowElem, PortalToFollowElemContent, PortalToFollowElemTrigger } from '@/app/components/base/portal-to-follow-elem'import { cn } from '@/utils/classnames'import { tooltipManager } from './TooltipManager'diff --git a/web/app/components/base/video-gallery/VideoPlayer.tsx b/web/app/components/base/video-gallery/VideoPlayer.tsxindex f94b97ed90b..8adaf71f583 100644--- a/web/app/components/base/video-gallery/VideoPlayer.tsx+++ b/web/app/components/base/video-gallery/VideoPlayer.tsx@@ -1,4 +1,5 @@-import React, { useCallback, useEffect, useRef, useState } from 'react'+import * as React from 'react'+import { useCallback, useEffect, useRef, useState } from 'react'import styles from './VideoPlayer.module.css'type VideoPlayerProps = {diff --git a/web/app/components/base/video-gallery/index.tsx b/web/app/components/base/video-gallery/index.tsxindex 87133b94b92..b058b0b08ac 100644--- a/web/app/components/base/video-gallery/index.tsx+++ b/web/app/components/base/video-gallery/index.tsx@@ -1,4 +1,4 @@-import React from 'react'+import * as React from 'react'import VideoPlayer from './VideoPlayer'type Props = {diff --git a/web/app/components/base/with-input-validation/index.tsx b/web/app/components/base/with-input-validation/index.tsxindex f8ea3542089..9a78dbb2981 100644--- a/web/app/components/base/with-input-validation/index.tsx+++ b/web/app/components/base/with-input-validation/index.tsx@@ -1,6 +1,6 @@'use client'import type { ZodSchema } from 'zod'-import React from 'react'+import * as React from 'react'function withValidation<T extends Record<string, unknown>, K extends keyof T>(WrappedComponent: React.ComponentType<T>,diff --git a/web/app/components/billing/annotation-full/index.tsx b/web/app/components/billing/annotation-full/index.tsxindex 090e383e228..fc770a93571 100644--- a/web/app/components/billing/annotation-full/index.tsx+++ b/web/app/components/billing/annotation-full/index.tsx@@ -1,6 +1,6 @@'use client'import type { FC } from 'react'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import GridMask from '@/app/components/base/grid-mask'import { cn } from '@/utils/classnames'diff --git a/web/app/components/billing/annotation-full/modal.tsx b/web/app/components/billing/annotation-full/modal.tsxindex 0474fc0722b..0e4fbfee322 100644--- a/web/app/components/billing/annotation-full/modal.tsx+++ b/web/app/components/billing/annotation-full/modal.tsx@@ -1,6 +1,6 @@'use client'import type { FC } from 'react'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import GridMask from '@/app/components/base/grid-mask'import { cn } from '@/utils/classnames'diff --git a/web/app/components/billing/annotation-full/usage.tsx b/web/app/components/billing/annotation-full/usage.tsxindex 7ab984d04ff..eb2b79cc898 100644--- a/web/app/components/billing/annotation-full/usage.tsx+++ b/web/app/components/billing/annotation-full/usage.tsx@@ -1,6 +1,6 @@'use client'import type { FC } from 'react'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import { useProviderContext } from '@/context/provider-context'import { MessageFastPlus } from '../../base/icons/src/vender/line/communication'diff --git a/web/app/components/billing/apps-full-in-dialog/index.tsx b/web/app/components/billing/apps-full-in-dialog/index.tsxindex dbcbe490815..c69378c2f15 100644--- a/web/app/components/billing/apps-full-in-dialog/index.tsx+++ b/web/app/components/billing/apps-full-in-dialog/index.tsx@@ -1,6 +1,6 @@'use client'import type { FC } from 'react'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import Button from '@/app/components/base/button'import ProgressBar from '@/app/components/billing/progress-bar'diff --git a/web/app/components/billing/billing-page/index.tsx b/web/app/components/billing/billing-page/index.tsxindex c754386a3fc..ee68cafe2e8 100644--- a/web/app/components/billing/billing-page/index.tsx+++ b/web/app/components/billing/billing-page/index.tsx@@ -3,7 +3,7 @@ import type { FC } from 'react'import {RiArrowRightUpLine,} from '@remixicon/react'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import { useAppContext } from '@/context/app-context'import { useProviderContext } from '@/context/provider-context'diff --git a/web/app/components/billing/header-billing-btn/index.tsx b/web/app/components/billing/header-billing-btn/index.tsxindex 049ee214c01..862093c210a 100644--- a/web/app/components/billing/header-billing-btn/index.tsx+++ b/web/app/components/billing/header-billing-btn/index.tsx@@ -1,6 +1,6 @@'use client'import type { FC } from 'react'-import React from 'react'+import * as React from 'react'import { useProviderContext } from '@/context/provider-context'import { cn } from '@/utils/classnames'import { Plan } from '../type'diff --git a/web/app/components/billing/partner-stack/index.tsx b/web/app/components/billing/partner-stack/index.tsxindex 06a79054757..e7b954a5767 100644--- a/web/app/components/billing/partner-stack/index.tsx+++ b/web/app/components/billing/partner-stack/index.tsx@@ -1,6 +1,7 @@'use client'import type { FC } from 'react'-import React, { useEffect } from 'react'+import * as React from 'react'+import { useEffect } from 'react'import { IS_CLOUD_EDITION } from '@/config'import usePSInfo from './use-ps-info'diff --git a/web/app/components/billing/plan-upgrade-modal/index.spec.tsx b/web/app/components/billing/plan-upgrade-modal/index.spec.tsxindex 215218d42a5..9dbe115a893 100644--- a/web/app/components/billing/plan-upgrade-modal/index.spec.tsx+++ b/web/app/components/billing/plan-upgrade-modal/index.spec.tsx@@ -1,6 +1,6 @@import { render, screen } from '@testing-library/react'import userEvent from '@testing-library/user-event'-import React from 'react'+import * as React from 'react'import PlanUpgradeModal from './index'const mockSetShowPricingModal = vi.fn()diff --git a/web/app/components/billing/plan-upgrade-modal/index.tsx b/web/app/components/billing/plan-upgrade-modal/index.tsxindex 7bf8c1bb0d3..0d5dccdd737 100644--- a/web/app/components/billing/plan-upgrade-modal/index.tsx+++ b/web/app/components/billing/plan-upgrade-modal/index.tsx@@ -1,6 +1,7 @@'use client'import type { FC } from 'react'-import React, { useCallback } from 'react'+import * as React from 'react'+import { useCallback } from 'react'import { useTranslation } from 'react-i18next'import Button from '@/app/components/base/button'import Modal from '@/app/components/base/modal'diff --git a/web/app/components/billing/plan/assets/sandbox.spec.tsx b/web/app/components/billing/plan/assets/sandbox.spec.tsxindex 0c70f979df6..024213cf5ab 100644--- a/web/app/components/billing/plan/assets/sandbox.spec.tsx+++ b/web/app/components/billing/plan/assets/sandbox.spec.tsx@@ -1,5 +1,5 @@import { render } from '@testing-library/react'-import React from 'react'+import * as React from 'react'import Sandbox from './sandbox'describe('Sandbox Icon Component', () => {diff --git a/web/app/components/billing/plan/assets/sandbox.tsx b/web/app/components/billing/plan/assets/sandbox.tsxindex 22230f1c3d0..0839e8d9794 100644--- a/web/app/components/billing/plan/assets/sandbox.tsx+++ b/web/app/components/billing/plan/assets/sandbox.tsx@@ -1,4 +1,4 @@-import React from 'react'+import * as React from 'react'const Sandbox = () => {return (diff --git a/web/app/components/billing/plan/index.tsx b/web/app/components/billing/plan/index.tsxindex b08a9037ca5..9f826f5255a 100644--- a/web/app/components/billing/plan/index.tsx+++ b/web/app/components/billing/plan/index.tsx@@ -8,7 +8,8 @@ import {} from '@remixicon/react'import { useUnmountedRef } from 'ahooks'import { usePathname, useRouter } from 'next/navigation'-import React, { useEffect } from 'react'+import * as React from 'react'+import { useEffect } from 'react'import { useTranslation } from 'react-i18next'import Button from '@/app/components/base/button'import { ApiAggregate, TriggerAll } from '@/app/components/base/icons/src/vender/workflow'diff --git a/web/app/components/billing/pricing/footer.tsx b/web/app/components/billing/pricing/footer.tsxindex f7842327a23..48b4a9f4bd8 100644--- a/web/app/components/billing/pricing/footer.tsx+++ b/web/app/components/billing/pricing/footer.tsx@@ -1,7 +1,7 @@import type { Category } from '.'import { RiArrowRightUpLine } from '@remixicon/react'import Link from 'next/link'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import { cn } from '@/utils/classnames'import { CategoryEnum } from '.'diff --git a/web/app/components/billing/pricing/header.tsx b/web/app/components/billing/pricing/header.tsxindex 55f9960eeee..c282664e9ce 100644--- a/web/app/components/billing/pricing/header.tsx+++ b/web/app/components/billing/pricing/header.tsx@@ -1,5 +1,5 @@import { RiCloseLine } from '@remixicon/react'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import Button from '../../base/button'import DifyLogo from '../../base/logo/dify-logo'diff --git a/web/app/components/billing/pricing/index.tsx b/web/app/components/billing/pricing/index.tsxindex d726fa72566..2b581581460 100644--- a/web/app/components/billing/pricing/index.tsx+++ b/web/app/components/billing/pricing/index.tsx@@ -1,7 +1,8 @@'use client'import type { FC } from 'react'import { useKeyPress } from 'ahooks'-import React, { useState } from 'react'+import * as React from 'react'+import { useState } from 'react'import { createPortal } from 'react-dom'import { useAppContext } from '@/context/app-context'import { useGetPricingPageLanguage } from '@/context/i18n'diff --git a/web/app/components/billing/pricing/plan-switcher/index.tsx b/web/app/components/billing/pricing/plan-switcher/index.tsxindex 3a25c2a569e..416a645438a 100644--- a/web/app/components/billing/pricing/plan-switcher/index.tsx+++ b/web/app/components/billing/pricing/plan-switcher/index.tsx@@ -1,7 +1,7 @@import type { FC } from 'react'import type { Category } from '../index'import type { PlanRange } from './plan-range-switcher'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import Divider from '@/app/components/base/divider'import { Cloud, SelfHosted } from '../assets'diff --git a/web/app/components/billing/pricing/plan-switcher/plan-range-switcher.tsx b/web/app/components/billing/pricing/plan-switcher/plan-range-switcher.tsxindex 770a19505b2..080ae42fbe6 100644--- a/web/app/components/billing/pricing/plan-switcher/plan-range-switcher.tsx+++ b/web/app/components/billing/pricing/plan-switcher/plan-range-switcher.tsx@@ -1,6 +1,6 @@'use client'import type { FC } from 'react'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import Switch from '../../../base/switch'diff --git a/web/app/components/billing/pricing/plan-switcher/tab.tsx b/web/app/components/billing/pricing/plan-switcher/tab.tsxindex fab24addf8c..db1632e8df5 100644--- a/web/app/components/billing/pricing/plan-switcher/tab.tsx+++ b/web/app/components/billing/pricing/plan-switcher/tab.tsx@@ -1,4 +1,5 @@-import React, { useCallback } from 'react'+import * as React from 'react'+import { useCallback } from 'react'import { cn } from '@/utils/classnames'type TabProps<T> = {diff --git a/web/app/components/billing/pricing/plans/cloud-plan-item/button.spec.tsx b/web/app/components/billing/pricing/plans/cloud-plan-item/button.spec.tsxindex ed6c7e4efbb..d57f1c022d4 100644--- a/web/app/components/billing/pricing/plans/cloud-plan-item/button.spec.tsx+++ b/web/app/components/billing/pricing/plans/cloud-plan-item/button.spec.tsx@@ -1,5 +1,5 @@import { fireEvent, render, screen } from '@testing-library/react'-import React from 'react'+import * as React from 'react'import { Plan } from '../../../type'import Button from './button'diff --git a/web/app/components/billing/pricing/plans/cloud-plan-item/button.tsx b/web/app/components/billing/pricing/plans/cloud-plan-item/button.tsxindex 8cf7351790e..9cdef8e333a 100644--- a/web/app/components/billing/pricing/plans/cloud-plan-item/button.tsx+++ b/web/app/components/billing/pricing/plans/cloud-plan-item/button.tsx@@ -1,6 +1,6 @@import type { BasicPlan } from '../../../type'import { RiArrowRightLine } from '@remixicon/react'-import React from 'react'+import * as React from 'react'import { cn } from '@/utils/classnames'import { Plan } from '../../../type'diff --git a/web/app/components/billing/pricing/plans/cloud-plan-item/index.spec.tsx b/web/app/components/billing/pricing/plans/cloud-plan-item/index.spec.tsxindex c2a17b0d04a..f6df314917f 100644--- a/web/app/components/billing/pricing/plans/cloud-plan-item/index.spec.tsx+++ b/web/app/components/billing/pricing/plans/cloud-plan-item/index.spec.tsx@@ -1,6 +1,6 @@import type { Mock } from 'vitest'import { fireEvent, render, screen, waitFor } from '@testing-library/react'-import React from 'react'+import * as React from 'react'import { useAppContext } from '@/context/app-context'import { useAsyncWindowOpen } from '@/hooks/use-async-window-open'import { fetchBillingUrl, fetchSubscriptionUrls } from '@/service/billing'diff --git a/web/app/components/billing/pricing/plans/cloud-plan-item/index.tsx b/web/app/components/billing/pricing/plans/cloud-plan-item/index.tsxindex e104e9cdd3a..57c85cf297f 100644--- a/web/app/components/billing/pricing/plans/cloud-plan-item/index.tsx+++ b/web/app/components/billing/pricing/plans/cloud-plan-item/index.tsx@@ -1,7 +1,8 @@'use client'import type { FC } from 'react'import type { BasicPlan } from '../../../type'-import React, { useMemo } from 'react'+import * as React from 'react'+import { useMemo } from 'react'import { useTranslation } from 'react-i18next'import { useAppContext } from '@/context/app-context'import { useAsyncWindowOpen } from '@/hooks/use-async-window-open'diff --git a/web/app/components/billing/pricing/plans/cloud-plan-item/list/index.spec.tsx b/web/app/components/billing/pricing/plans/cloud-plan-item/list/index.spec.tsxindex 5e2ba2a994e..bc337984829 100644--- a/web/app/components/billing/pricing/plans/cloud-plan-item/list/index.spec.tsx+++ b/web/app/components/billing/pricing/plans/cloud-plan-item/list/index.spec.tsx@@ -1,5 +1,5 @@import { render, screen } from '@testing-library/react'-import React from 'react'+import * as React from 'react'import { Plan } from '../../../../type'import List from './index'diff --git a/web/app/components/billing/pricing/plans/cloud-plan-item/list/index.tsx b/web/app/components/billing/pricing/plans/cloud-plan-item/list/index.tsxindex 600a3c06532..1ba8b2c9bc6 100644--- a/web/app/components/billing/pricing/plans/cloud-plan-item/list/index.tsx+++ b/web/app/components/billing/pricing/plans/cloud-plan-item/list/index.tsx@@ -1,5 +1,5 @@import type { BasicPlan } from '../../../../type'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import Divider from '@/app/components/base/divider'import { ALL_PLANS, NUM_INFINITE } from '../../../../config'diff --git a/web/app/components/billing/pricing/plans/cloud-plan-item/list/item/index.tsx b/web/app/components/billing/pricing/plans/cloud-plan-item/list/item/index.tsxindex 95e232fefed..df93a5fb0ed 100644--- a/web/app/components/billing/pricing/plans/cloud-plan-item/list/item/index.tsx+++ b/web/app/components/billing/pricing/plans/cloud-plan-item/list/item/index.tsx@@ -1,4 +1,4 @@-import React from 'react'+import * as React from 'react'import Tooltip from './tooltip'type ItemProps = {diff --git a/web/app/components/billing/pricing/plans/cloud-plan-item/list/item/tooltip.tsx b/web/app/components/billing/pricing/plans/cloud-plan-item/list/item/tooltip.tsxindex 34341ed97a2..bfac36e5298 100644--- a/web/app/components/billing/pricing/plans/cloud-plan-item/list/item/tooltip.tsx+++ b/web/app/components/billing/pricing/plans/cloud-plan-item/list/item/tooltip.tsx@@ -1,5 +1,5 @@import { RiInfoI } from '@remixicon/react'-import React from 'react'+import * as React from 'react'type TooltipProps = {content: stringdiff --git a/web/app/components/billing/pricing/plans/index.spec.tsx b/web/app/components/billing/pricing/plans/index.spec.tsxindex 166f75e9415..3accaee3454 100644--- a/web/app/components/billing/pricing/plans/index.spec.tsx+++ b/web/app/components/billing/pricing/plans/index.spec.tsx@@ -1,7 +1,7 @@import type { Mock } from 'vitest'import type { UsagePlanInfo } from '../../type'import { render, screen } from '@testing-library/react'-import React from 'react'+import * as React from 'react'import { Plan } from '../../type'import { PlanRange } from '../plan-switcher/plan-range-switcher'import cloudPlanItem from './cloud-plan-item'diff --git a/web/app/components/billing/pricing/plans/self-hosted-plan-item/button.spec.tsx b/web/app/components/billing/pricing/plans/self-hosted-plan-item/button.spec.tsxindex 193e16be454..35a484e7c39 100644--- a/web/app/components/billing/pricing/plans/self-hosted-plan-item/button.spec.tsx+++ b/web/app/components/billing/pricing/plans/self-hosted-plan-item/button.spec.tsx@@ -1,6 +1,6 @@import type { MockedFunction } from 'vitest'import { fireEvent, render, screen } from '@testing-library/react'-import React from 'react'+import * as React from 'react'import useTheme from '@/hooks/use-theme'import { Theme } from '@/types/app'import { SelfHostedPlan } from '../../../type'diff --git a/web/app/components/billing/pricing/plans/self-hosted-plan-item/button.tsx b/web/app/components/billing/pricing/plans/self-hosted-plan-item/button.tsxindex 148420a85af..544141a6a5e 100644--- a/web/app/components/billing/pricing/plans/self-hosted-plan-item/button.tsx+++ b/web/app/components/billing/pricing/plans/self-hosted-plan-item/button.tsx@@ -1,5 +1,6 @@import { RiArrowRightLine } from '@remixicon/react'-import React, { useMemo } from 'react'+import * as React from 'react'+import { useMemo } from 'react'import { useTranslation } from 'react-i18next'import { AwsMarketplaceDark, AwsMarketplaceLight } from '@/app/components/base/icons/src/public/billing'import useTheme from '@/hooks/use-theme'diff --git a/web/app/components/billing/pricing/plans/self-hosted-plan-item/index.spec.tsx b/web/app/components/billing/pricing/plans/self-hosted-plan-item/index.spec.tsxindex aee3b7e8d1a..3a687de5c1a 100644--- a/web/app/components/billing/pricing/plans/self-hosted-plan-item/index.spec.tsx+++ b/web/app/components/billing/pricing/plans/self-hosted-plan-item/index.spec.tsx@@ -1,6 +1,6 @@import type { Mock } from 'vitest'import { fireEvent, render, screen } from '@testing-library/react'-import React from 'react'+import * as React from 'react'import { useAppContext } from '@/context/app-context'import Toast from '../../../../base/toast'import { contactSalesUrl, getStartedWithCommunityUrl, getWithPremiumUrl } from '../../../config'diff --git a/web/app/components/billing/pricing/plans/self-hosted-plan-item/index.tsx b/web/app/components/billing/pricing/plans/self-hosted-plan-item/index.tsxindex db1f44b23a6..b89d0c69418 100644--- a/web/app/components/billing/pricing/plans/self-hosted-plan-item/index.tsx+++ b/web/app/components/billing/pricing/plans/self-hosted-plan-item/index.tsx@@ -1,6 +1,7 @@'use client'import type { FC } from 'react'-import React, { useCallback } from 'react'+import * as React from 'react'+import { useCallback } from 'react'import { useTranslation } from 'react-i18next'import { Azure, GoogleCloud } from '@/app/components/base/icons/src/public/billing'import { useAppContext } from '@/context/app-context'diff --git a/web/app/components/billing/pricing/plans/self-hosted-plan-item/list/index.spec.tsx b/web/app/components/billing/pricing/plans/self-hosted-plan-item/list/index.spec.tsxindex 6188ac3e0ab..97329e47e59 100644--- a/web/app/components/billing/pricing/plans/self-hosted-plan-item/list/index.spec.tsx+++ b/web/app/components/billing/pricing/plans/self-hosted-plan-item/list/index.spec.tsx@@ -1,5 +1,5 @@import { render, screen } from '@testing-library/react'-import React from 'react'+import * as React from 'react'import { SelfHostedPlan } from '@/app/components/billing/type'import List from './index'diff --git a/web/app/components/billing/pricing/plans/self-hosted-plan-item/list/index.tsx b/web/app/components/billing/pricing/plans/self-hosted-plan-item/list/index.tsxindex 137b14db6b3..4ed307d36ef 100644--- a/web/app/components/billing/pricing/plans/self-hosted-plan-item/list/index.tsx+++ b/web/app/components/billing/pricing/plans/self-hosted-plan-item/list/index.tsx@@ -1,5 +1,5 @@import type { SelfHostedPlan } from '@/app/components/billing/type'-import React from 'react'+import * as React from 'react'import { Trans, useTranslation } from 'react-i18next'import Item from './item'diff --git a/web/app/components/billing/pricing/plans/self-hosted-plan-item/list/item.spec.tsx b/web/app/components/billing/pricing/plans/self-hosted-plan-item/list/item.spec.tsxindex eda85274457..2f2957fb9d1 100644--- a/web/app/components/billing/pricing/plans/self-hosted-plan-item/list/item.spec.tsx+++ b/web/app/components/billing/pricing/plans/self-hosted-plan-item/list/item.spec.tsx@@ -1,5 +1,5 @@import { render, screen } from '@testing-library/react'-import React from 'react'+import * as React from 'react'import Item from './item'describe('SelfHostedPlanItem/List/Item', () => {diff --git a/web/app/components/billing/pricing/plans/self-hosted-plan-item/list/item.tsx b/web/app/components/billing/pricing/plans/self-hosted-plan-item/list/item.tsxindex 8d219f30c21..ee14117d24d 100644--- a/web/app/components/billing/pricing/plans/self-hosted-plan-item/list/item.tsx+++ b/web/app/components/billing/pricing/plans/self-hosted-plan-item/list/item.tsx@@ -1,5 +1,5 @@import { RiCheckLine } from '@remixicon/react'-import React from 'react'+import * as React from 'react'type ItemProps = {label: stringdiff --git a/web/app/components/billing/trigger-events-limit-modal/index.tsx b/web/app/components/billing/trigger-events-limit-modal/index.tsxindex 35d5e8bf653..421ec752ddf 100644--- a/web/app/components/billing/trigger-events-limit-modal/index.tsx+++ b/web/app/components/billing/trigger-events-limit-modal/index.tsx@@ -1,6 +1,6 @@'use client'import type { FC } from 'react'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import { TriggerAll } from '@/app/components/base/icons/src/vender/workflow'import PlanUpgradeModal from '@/app/components/billing/plan-upgrade-modal'diff --git a/web/app/components/billing/upgrade-btn/index.tsx b/web/app/components/billing/upgrade-btn/index.tsxindex 10ec04e4def..0f23022b352 100644--- a/web/app/components/billing/upgrade-btn/index.tsx+++ b/web/app/components/billing/upgrade-btn/index.tsx@@ -1,6 +1,6 @@'use client'import type { CSSProperties, FC } from 'react'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import Button from '@/app/components/base/button'import { SparklesSoft } from '@/app/components/base/icons/src/public/common'diff --git a/web/app/components/billing/usage-info/apps-info.tsx b/web/app/components/billing/usage-info/apps-info.tsxindex 79ebd31a5f1..024f3c47b10 100644--- a/web/app/components/billing/usage-info/apps-info.tsx+++ b/web/app/components/billing/usage-info/apps-info.tsx@@ -3,7 +3,7 @@ import type { FC } from 'react'import {RiApps2Line,} from '@remixicon/react'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import { useProviderContext } from '@/context/provider-context'import UsageInfo from '../usage-info'diff --git a/web/app/components/billing/usage-info/index.tsx b/web/app/components/billing/usage-info/index.tsxindex 7fa9efab2ae..3681be9a20e 100644--- a/web/app/components/billing/usage-info/index.tsx+++ b/web/app/components/billing/usage-info/index.tsx@@ -1,6 +1,6 @@'use client'import type { FC } from 'react'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import Tooltip from '@/app/components/base/tooltip'import { cn } from '@/utils/classnames'diff --git a/web/app/components/billing/usage-info/vector-space-info.tsx b/web/app/components/billing/usage-info/vector-space-info.tsxindex b946a2580f5..1da573c7084 100644--- a/web/app/components/billing/usage-info/vector-space-info.tsx+++ b/web/app/components/billing/usage-info/vector-space-info.tsx@@ -3,7 +3,7 @@ import type { FC } from 'react'import {RiHardDrive3Line,} from '@remixicon/react'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import { useProviderContext } from '@/context/provider-context'import UsageInfo from '../usage-info'diff --git a/web/app/components/billing/vector-space-full/index.tsx b/web/app/components/billing/vector-space-full/index.tsxindex 67d4cd8c347..21a856b6604 100644--- a/web/app/components/billing/vector-space-full/index.tsx+++ b/web/app/components/billing/vector-space-full/index.tsx@@ -1,6 +1,6 @@'use client'import type { FC } from 'react'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import GridMask from '@/app/components/base/grid-mask'import { cn } from '@/utils/classnames'diff --git a/web/app/components/custom/custom-page/index.spec.tsx b/web/app/components/custom/custom-page/index.spec.tsxindex 3fa4479450a..0eea48fb6ec 100644--- a/web/app/components/custom/custom-page/index.spec.tsx+++ b/web/app/components/custom/custom-page/index.spec.tsx@@ -1,7 +1,7 @@import type { Mock } from 'vitest'import { render, screen } from '@testing-library/react'import userEvent from '@testing-library/user-event'-import React from 'react'+import * as React from 'react'import { createMockProviderContextValue } from '@/__mocks__/provider-context'import { contactSalesUrl } from '@/app/components/billing/config'import { Plan } from '@/app/components/billing/type'diff --git a/web/app/components/datasets/api/index.tsx b/web/app/components/datasets/api/index.tsxindex 3ca84c3e11a..801070030ce 100644--- a/web/app/components/datasets/api/index.tsx+++ b/web/app/components/datasets/api/index.tsx@@ -1,4 +1,4 @@-import React from 'react'+import * as React from 'react'const index = () => {return (diff --git a/web/app/components/datasets/common/chunking-mode-label.tsx b/web/app/components/datasets/common/chunking-mode-label.tsxindex 5147d44ad86..1a265855a40 100644--- a/web/app/components/datasets/common/chunking-mode-label.tsx+++ b/web/app/components/datasets/common/chunking-mode-label.tsx@@ -1,6 +1,6 @@'use client'import type { FC } from 'react'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import Badge from '@/app/components/base/badge'import { GeneralChunk, ParentChildChunk } from '@/app/components/base/icons/src/vender/knowledge'diff --git a/web/app/components/datasets/common/credential-icon.tsx b/web/app/components/datasets/common/credential-icon.tsxindex 27dea869936..a97cf7d4101 100644--- a/web/app/components/datasets/common/credential-icon.tsx+++ b/web/app/components/datasets/common/credential-icon.tsx@@ -1,4 +1,5 @@-import React, { useCallback, useMemo, useState } from 'react'+import * as React from 'react'+import { useCallback, useMemo, useState } from 'react'import { cn } from '@/utils/classnames'type CredentialIconProps = {diff --git a/web/app/components/datasets/common/document-file-icon.tsx b/web/app/components/datasets/common/document-file-icon.tsxindex d4ce8878ba5..d831cd78aad 100644--- a/web/app/components/datasets/common/document-file-icon.tsx+++ b/web/app/components/datasets/common/document-file-icon.tsx@@ -1,7 +1,7 @@'use client'import type { FC } from 'react'import type { FileAppearanceType } from '@/app/components/base/file-uploader/types'-import React from 'react'+import * as React from 'react'import { FileAppearanceTypeEnum } from '@/app/components/base/file-uploader/types'import FileTypeIcon from '../../base/file-uploader/file-type-icon'diff --git a/web/app/components/datasets/common/document-picker/document-list.tsx b/web/app/components/datasets/common/document-picker/document-list.tsxindex 966bc0e4c81..574792ee145 100644--- a/web/app/components/datasets/common/document-picker/document-list.tsx+++ b/web/app/components/datasets/common/document-picker/document-list.tsx@@ -1,7 +1,8 @@'use client'import type { FC } from 'react'import type { DocumentItem } from '@/models/datasets'-import React, { useCallback } from 'react'+import * as React from 'react'+import { useCallback } from 'react'import { cn } from '@/utils/classnames'import FileIcon from '../document-file-icon'diff --git a/web/app/components/datasets/common/document-picker/index.spec.tsx b/web/app/components/datasets/common/document-picker/index.spec.tsxindex d236cf4e62b..2ed29a0e231 100644--- a/web/app/components/datasets/common/document-picker/index.spec.tsx+++ b/web/app/components/datasets/common/document-picker/index.spec.tsx@@ -1,7 +1,7 @@import type { ParentMode, SimpleDocumentDetail } from '@/models/datasets'import { QueryClient, QueryClientProvider } from '@tanstack/react-query'import { fireEvent, render, screen } from '@testing-library/react'-import React from 'react'+import * as React from 'react'import { ChunkingMode, DataSourceType } from '@/models/datasets'import DocumentPicker from './index'diff --git a/web/app/components/datasets/common/document-picker/index.tsx b/web/app/components/datasets/common/document-picker/index.tsxindex fe5b96a50b7..14acd1db6c0 100644--- a/web/app/components/datasets/common/document-picker/index.tsx+++ b/web/app/components/datasets/common/document-picker/index.tsx@@ -3,7 +3,8 @@ import type { FC } from 'react'import type { DocumentItem, ParentMode, SimpleDocumentDetail } from '@/models/datasets'import { RiArrowDownSLine } from '@remixicon/react'import { useBoolean } from 'ahooks'-import React, { useCallback, useMemo, useState } from 'react'+import * as React from 'react'+import { useCallback, useMemo, useState } from 'react'import { useTranslation } from 'react-i18next'import { GeneralChunk, ParentChildChunk } from '@/app/components/base/icons/src/vender/knowledge'import Loading from '@/app/components/base/loading'diff --git a/web/app/components/datasets/common/document-picker/preview-document-picker.spec.tsx b/web/app/components/datasets/common/document-picker/preview-document-picker.spec.tsxindex 5a70cada88e..65272b77be9 100644--- a/web/app/components/datasets/common/document-picker/preview-document-picker.spec.tsx+++ b/web/app/components/datasets/common/document-picker/preview-document-picker.spec.tsx@@ -1,6 +1,6 @@import type { DocumentItem } from '@/models/datasets'import { fireEvent, render, screen } from '@testing-library/react'-import React from 'react'+import * as React from 'react'import PreviewDocumentPicker from './preview-document-picker'// Override shared i18n mock for custom translationsdiff --git a/web/app/components/datasets/common/document-picker/preview-document-picker.tsx b/web/app/components/datasets/common/document-picker/preview-document-picker.tsxindex 8b7cf8340b0..4403cf29f2b 100644--- a/web/app/components/datasets/common/document-picker/preview-document-picker.tsx+++ b/web/app/components/datasets/common/document-picker/preview-document-picker.tsx@@ -3,7 +3,8 @@ import type { FC } from 'react'import type { DocumentItem } from '@/models/datasets'import { RiArrowDownSLine } from '@remixicon/react'import { useBoolean } from 'ahooks'-import React, { useCallback } from 'react'+import * as React from 'react'+import { useCallback } from 'react'import { useTranslation } from 'react-i18next'import Loading from '@/app/components/base/loading'import {diff --git a/web/app/components/datasets/common/document-status-with-action/auto-disabled-document.tsx b/web/app/components/datasets/common/document-status-with-action/auto-disabled-document.tsxindex 3fceccb4811..8cb4d4e22b8 100644--- a/web/app/components/datasets/common/document-status-with-action/auto-disabled-document.tsx+++ b/web/app/components/datasets/common/document-status-with-action/auto-disabled-document.tsx@@ -1,6 +1,7 @@'use client'import type { FC } from 'react'-import React, { useCallback } from 'react'+import * as React from 'react'+import { useCallback } from 'react'import { useTranslation } from 'react-i18next'import Toast from '@/app/components/base/toast'import { useAutoDisabledDocuments, useDocumentEnable, useInvalidDisabledDocument } from '@/service/knowledge/use-document'diff --git a/web/app/components/datasets/common/document-status-with-action/index-failed.tsx b/web/app/components/datasets/common/document-status-with-action/index-failed.tsxindex 4fafbd8997e..16357200375 100644--- a/web/app/components/datasets/common/document-status-with-action/index-failed.tsx+++ b/web/app/components/datasets/common/document-status-with-action/index-failed.tsx@@ -2,7 +2,8 @@import type { FC } from 'react'import type { IndexingStatusResponse } from '@/models/datasets'import { noop } from 'lodash-es'-import React, { useEffect, useReducer } from 'react'+import * as React from 'react'+import { useEffect, useReducer } from 'react'import { useTranslation } from 'react-i18next'import { retryErrorDocs } from '@/service/datasets'import { useDatasetErrorDocs } from '@/service/knowledge/use-dataset'diff --git a/web/app/components/datasets/common/document-status-with-action/status-with-action.tsx b/web/app/components/datasets/common/document-status-with-action/status-with-action.tsxindex b4eedd0cfed..9d42d40b1a7 100644--- a/web/app/components/datasets/common/document-status-with-action/status-with-action.tsx+++ b/web/app/components/datasets/common/document-status-with-action/status-with-action.tsx@@ -1,7 +1,7 @@'use client'import type { FC } from 'react'import { RiAlertFill, RiCheckboxCircleFill, RiErrorWarningFill, RiInformation2Fill } from '@remixicon/react'-import React from 'react'+import * as React from 'react'import Divider from '@/app/components/base/divider'import { cn } from '@/utils/classnames'diff --git a/web/app/components/datasets/common/economical-retrieval-method-config/index.tsx b/web/app/components/datasets/common/economical-retrieval-method-config/index.tsxindex ec6878cd643..83f2911093d 100644--- a/web/app/components/datasets/common/economical-retrieval-method-config/index.tsx+++ b/web/app/components/datasets/common/economical-retrieval-method-config/index.tsx@@ -1,7 +1,7 @@'use client'import type { FC } from 'react'import type { RetrievalConfig } from '@/types/app'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import { VectorSearch } from '@/app/components/base/icons/src/vender/knowledge'import { RETRIEVE_METHOD } from '@/types/app'diff --git a/web/app/components/datasets/common/image-list/more.tsx b/web/app/components/datasets/common/image-list/more.tsxindex 6b809ee5c5e..be6b53a5a57 100644--- a/web/app/components/datasets/common/image-list/more.tsx+++ b/web/app/components/datasets/common/image-list/more.tsx@@ -1,4 +1,5 @@-import React, { useCallback } from 'react'+import * as React from 'react'+import { useCallback } from 'react'type MoreProps = {count: numberdiff --git a/web/app/components/datasets/common/image-uploader/image-uploader-in-chunk/image-input.tsx b/web/app/components/datasets/common/image-uploader/image-uploader-in-chunk/image-input.tsxindex e7e198fa861..63d3656ddad 100644--- a/web/app/components/datasets/common/image-uploader/image-uploader-in-chunk/image-input.tsx+++ b/web/app/components/datasets/common/image-uploader/image-uploader-in-chunk/image-input.tsx@@ -1,5 +1,5 @@import { RiUploadCloud2Line } from '@remixicon/react'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import { cn } from '@/utils/classnames'import { ACCEPT_TYPES } from '../constants'diff --git a/web/app/components/datasets/common/image-uploader/image-uploader-in-retrieval-testing/image-input.tsx b/web/app/components/datasets/common/image-uploader/image-uploader-in-retrieval-testing/image-input.tsxindex 5525913d3cd..390e1f1ed40 100644--- a/web/app/components/datasets/common/image-uploader/image-uploader-in-retrieval-testing/image-input.tsx+++ b/web/app/components/datasets/common/image-uploader/image-uploader-in-retrieval-testing/image-input.tsx@@ -1,5 +1,5 @@import { RiImageAddLine } from '@remixicon/react'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import Tooltip from '@/app/components/base/tooltip'import { ACCEPT_TYPES } from '../constants'diff --git a/web/app/components/datasets/common/retrieval-method-config/index.spec.tsx b/web/app/components/datasets/common/retrieval-method-config/index.spec.tsxindex da07401d0ca..ec6da2b1602 100644--- a/web/app/components/datasets/common/retrieval-method-config/index.spec.tsx+++ b/web/app/components/datasets/common/retrieval-method-config/index.spec.tsx@@ -1,6 +1,6 @@import type { RetrievalConfig } from '@/types/app'import { fireEvent, render, screen } from '@testing-library/react'-import React from 'react'+import * as React from 'react'import {DEFAULT_WEIGHTED_SCORE,RerankingModeEnum,diff --git a/web/app/components/datasets/common/retrieval-method-config/index.tsx b/web/app/components/datasets/common/retrieval-method-config/index.tsxindex cd700f55f1e..255f51f23e5 100644--- a/web/app/components/datasets/common/retrieval-method-config/index.tsx+++ b/web/app/components/datasets/common/retrieval-method-config/index.tsx@@ -1,7 +1,8 @@'use client'import type { FC } from 'react'import type { RetrievalConfig } from '@/types/app'-import React, { useCallback } from 'react'+import * as React from 'react'+import { useCallback } from 'react'import { useTranslation } from 'react-i18next'import { FullTextSearch, HybridSearch, VectorSearch } from '@/app/components/base/icons/src/vender/knowledge'import { ModelTypeEnum } from '@/app/components/header/account-setting/model-provider-page/declarations'diff --git a/web/app/components/datasets/common/retrieval-method-info/index.tsx b/web/app/components/datasets/common/retrieval-method-info/index.tsxindex ee388a9580d..df8a93f6661 100644--- a/web/app/components/datasets/common/retrieval-method-info/index.tsx+++ b/web/app/components/datasets/common/retrieval-method-info/index.tsx@@ -2,7 +2,7 @@import type { FC } from 'react'import type { RetrievalConfig } from '@/types/app'import Image from 'next/image'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import RadioCard from '@/app/components/base/radio-card'import { RETRIEVE_METHOD } from '@/types/app'diff --git a/web/app/components/datasets/common/retrieval-param-config/index.tsx b/web/app/components/datasets/common/retrieval-param-config/index.tsxindex 19653ebad74..2517bb842bc 100644--- a/web/app/components/datasets/common/retrieval-param-config/index.tsx+++ b/web/app/components/datasets/common/retrieval-param-config/index.tsx@@ -3,7 +3,8 @@ import type { FC } from 'react'import type { RetrievalConfig } from '@/types/app'import Image from 'next/image'-import React, { useCallback, useMemo } from 'react'+import * as React from 'react'+import { useCallback, useMemo } from 'react'import { useTranslation } from 'react-i18next'import WeightedScore from '@/app/components/app/configuration/dataset-config/params-config/weighted-score'import { AlertTriangle } from '@/app/components/base/icons/src/vender/solid/alertsAndFeedback'diff --git a/web/app/components/datasets/create-from-pipeline/create-options/create-from-dsl-modal/header.tsx b/web/app/components/datasets/create-from-pipeline/create-options/create-from-dsl-modal/header.tsxindex 7e36043318f..5b2fc33e3ee 100644--- a/web/app/components/datasets/create-from-pipeline/create-options/create-from-dsl-modal/header.tsx+++ b/web/app/components/datasets/create-from-pipeline/create-options/create-from-dsl-modal/header.tsx@@ -1,5 +1,5 @@import { RiCloseLine } from '@remixicon/react'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'type HeaderProps = {diff --git a/web/app/components/datasets/create-from-pipeline/create-options/create-from-dsl-modal/tab/index.tsx b/web/app/components/datasets/create-from-pipeline/create-options/create-from-dsl-modal/tab/index.tsxindex c6ec52c0f8a..7024233dd6c 100644--- a/web/app/components/datasets/create-from-pipeline/create-options/create-from-dsl-modal/tab/index.tsx+++ b/web/app/components/datasets/create-from-pipeline/create-options/create-from-dsl-modal/tab/index.tsx@@ -1,4 +1,4 @@-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import { CreateFromDSLModalTab } from '@/app/components/app/create-from-dsl-modal'import Item from './item'diff --git a/web/app/components/datasets/create-from-pipeline/create-options/create-from-dsl-modal/tab/item.tsx b/web/app/components/datasets/create-from-pipeline/create-options/create-from-dsl-modal/tab/item.tsxindex f734e1ab900..87af4714bde 100644--- a/web/app/components/datasets/create-from-pipeline/create-options/create-from-dsl-modal/tab/item.tsx+++ b/web/app/components/datasets/create-from-pipeline/create-options/create-from-dsl-modal/tab/item.tsx@@ -1,4 +1,4 @@-import React from 'react'+import * as React from 'react'import { cn } from '@/utils/classnames'type ItemProps = {diff --git a/web/app/components/datasets/create-from-pipeline/create-options/create-from-dsl-modal/uploader.tsx b/web/app/components/datasets/create-from-pipeline/create-options/create-from-dsl-modal/uploader.tsxindex 669068ab6e0..4d5c06d523b 100644--- a/web/app/components/datasets/create-from-pipeline/create-options/create-from-dsl-modal/uploader.tsx+++ b/web/app/components/datasets/create-from-pipeline/create-options/create-from-dsl-modal/uploader.tsx@@ -5,7 +5,8 @@ import {RiNodeTree,RiUploadCloud2Line,} from '@remixicon/react'-import React, { useEffect, useRef, useState } from 'react'+import * as React from 'react'+import { useEffect, useRef, useState } from 'react'import { useTranslation } from 'react-i18next'import { useContext } from 'use-context-selector'import ActionButton from '@/app/components/base/action-button'diff --git a/web/app/components/datasets/create-from-pipeline/footer.tsx b/web/app/components/datasets/create-from-pipeline/footer.tsxindex df29d06ce5e..a744a8a5ca5 100644--- a/web/app/components/datasets/create-from-pipeline/footer.tsx+++ b/web/app/components/datasets/create-from-pipeline/footer.tsx@@ -1,6 +1,7 @@import { RiFileUploadLine } from '@remixicon/react'import { useRouter, useSearchParams } from 'next/navigation'-import React, { useCallback, useMemo, useState } from 'react'+import * as React from 'react'+import { useCallback, useMemo, useState } from 'react'import { useTranslation } from 'react-i18next'import { useInvalidDatasetList } from '@/service/knowledge/use-dataset'import Divider from '../../base/divider'diff --git a/web/app/components/datasets/create-from-pipeline/header.tsx b/web/app/components/datasets/create-from-pipeline/header.tsxindex dd43998453c..690f78958c8 100644--- a/web/app/components/datasets/create-from-pipeline/header.tsx+++ b/web/app/components/datasets/create-from-pipeline/header.tsx@@ -1,6 +1,6 @@import { RiArrowLeftLine } from '@remixicon/react'import Link from 'next/link'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import Button from '../../base/button'diff --git a/web/app/components/datasets/create-from-pipeline/list/create-card.tsx b/web/app/components/datasets/create-from-pipeline/list/create-card.tsxindex 144926d97d7..57ea9202bb8 100644--- a/web/app/components/datasets/create-from-pipeline/list/create-card.tsx+++ b/web/app/components/datasets/create-from-pipeline/list/create-card.tsx@@ -1,6 +1,7 @@import { RiAddCircleLine } from '@remixicon/react'import { useRouter } from 'next/navigation'-import React, { useCallback } from 'react'+import * as React from 'react'+import { useCallback } from 'react'import { useTranslation } from 'react-i18next'import { trackEvent } from '@/app/components/base/amplitude'import Toast from '@/app/components/base/toast'diff --git a/web/app/components/datasets/create-from-pipeline/list/template-card/actions.tsx b/web/app/components/datasets/create-from-pipeline/list/template-card/actions.tsxindex c7f1b742a86..a621862a084 100644--- a/web/app/components/datasets/create-from-pipeline/list/template-card/actions.tsx+++ b/web/app/components/datasets/create-from-pipeline/list/template-card/actions.tsx@@ -1,5 +1,5 @@import { RiAddLine, RiArrowRightUpLine, RiMoreFill } from '@remixicon/react'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import Button from '@/app/components/base/button'import CustomPopover from '@/app/components/base/popover'diff --git a/web/app/components/datasets/create-from-pipeline/list/template-card/content.tsx b/web/app/components/datasets/create-from-pipeline/list/template-card/content.tsxindex 85873d97ca6..8452d20d2dd 100644--- a/web/app/components/datasets/create-from-pipeline/list/template-card/content.tsx+++ b/web/app/components/datasets/create-from-pipeline/list/template-card/content.tsx@@ -1,5 +1,5 @@import type { ChunkingMode, IconInfo } from '@/models/datasets'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import AppIcon from '@/app/components/base/app-icon'import { General } from '@/app/components/base/icons/src/public/knowledge/dataset-card'diff --git a/web/app/components/datasets/create-from-pipeline/list/template-card/details/chunk-structure-card.tsx b/web/app/components/datasets/create-from-pipeline/list/template-card/details/chunk-structure-card.tsxindex 39d03ae28df..4a6efa29a2e 100644--- a/web/app/components/datasets/create-from-pipeline/list/template-card/details/chunk-structure-card.tsx+++ b/web/app/components/datasets/create-from-pipeline/list/template-card/details/chunk-structure-card.tsx@@ -1,5 +1,5 @@import type { Option } from './types'-import React from 'react'+import * as React from 'react'import { cn } from '@/utils/classnames'import { EffectColor } from './types'diff --git a/web/app/components/datasets/create-from-pipeline/list/template-card/details/index.tsx b/web/app/components/datasets/create-from-pipeline/list/template-card/details/index.tsxindex 9f0aebf6ff5..0d48576f10c 100644--- a/web/app/components/datasets/create-from-pipeline/list/template-card/details/index.tsx+++ b/web/app/components/datasets/create-from-pipeline/list/template-card/details/index.tsx@@ -1,6 +1,7 @@import type { AppIconType } from '@/types/app'import { RiAddLine, RiCloseLine } from '@remixicon/react'-import React, { useMemo } from 'react'+import * as React from 'react'+import { useMemo } from 'react'import { useTranslation } from 'react-i18next'import AppIcon from '@/app/components/base/app-icon'import Button from '@/app/components/base/button'diff --git a/web/app/components/datasets/create-from-pipeline/list/template-card/edit-pipeline-info.tsx b/web/app/components/datasets/create-from-pipeline/list/template-card/edit-pipeline-info.tsxindex 46d09b8477d..1c1d4f0a8c1 100644--- a/web/app/components/datasets/create-from-pipeline/list/template-card/edit-pipeline-info.tsx+++ b/web/app/components/datasets/create-from-pipeline/list/template-card/edit-pipeline-info.tsx@@ -1,7 +1,8 @@import type { AppIconSelection } from '@/app/components/base/app-icon-picker'import type { PipelineTemplate } from '@/models/pipeline'import { RiCloseLine } from '@remixicon/react'-import React, { useCallback, useRef, useState } from 'react'+import * as React from 'react'+import { useCallback, useRef, useState } from 'react'import { useTranslation } from 'react-i18next'import AppIcon from '@/app/components/base/app-icon'import AppIconPicker from '@/app/components/base/app-icon-picker'diff --git a/web/app/components/datasets/create-from-pipeline/list/template-card/index.tsx b/web/app/components/datasets/create-from-pipeline/list/template-card/index.tsxindex 877e96bd1d2..61192c64303 100644--- a/web/app/components/datasets/create-from-pipeline/list/template-card/index.tsx+++ b/web/app/components/datasets/create-from-pipeline/list/template-card/index.tsx@@ -1,6 +1,7 @@import type { PipelineTemplate } from '@/models/pipeline'import { useRouter } from 'next/navigation'-import React, { useCallback, useState } from 'react'+import * as React from 'react'+import { useCallback, useState } from 'react'import { useTranslation } from 'react-i18next'import { trackEvent } from '@/app/components/base/amplitude'import Confirm from '@/app/components/base/confirm'diff --git a/web/app/components/datasets/create-from-pipeline/list/template-card/operations.tsx b/web/app/components/datasets/create-from-pipeline/list/template-card/operations.tsxindex a6ab47faec0..8fc33f21780 100644--- a/web/app/components/datasets/create-from-pipeline/list/template-card/operations.tsx+++ b/web/app/components/datasets/create-from-pipeline/list/template-card/operations.tsx@@ -1,4 +1,4 @@-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import Divider from '@/app/components/base/divider'diff --git a/web/app/components/datasets/create/embedding-process/index.tsx b/web/app/components/datasets/create/embedding-process/index.tsxindex 5cc376207fd..541eb62b60d 100644--- a/web/app/components/datasets/create/embedding-process/index.tsx+++ b/web/app/components/datasets/create/embedding-process/index.tsx@@ -16,7 +16,8 @@ import {import Image from 'next/image'import Link from 'next/link'import { useRouter } from 'next/navigation'-import React, { useCallback, useEffect, useMemo, useRef, useState } from 'react'+import * as React from 'react'+import { useCallback, useEffect, useMemo, useRef, useState } from 'react'import { useTranslation } from 'react-i18next'import Button from '@/app/components/base/button'import Divider from '@/app/components/base/divider'diff --git a/web/app/components/datasets/create/empty-dataset-creation-modal/index.spec.tsx b/web/app/components/datasets/create/empty-dataset-creation-modal/index.spec.tsxindex 708ccc4ba35..cef945c968b 100644--- a/web/app/components/datasets/create/empty-dataset-creation-modal/index.spec.tsx+++ b/web/app/components/datasets/create/empty-dataset-creation-modal/index.spec.tsx@@ -1,6 +1,6 @@import type { MockedFunction } from 'vitest'import { fireEvent, render, screen, waitFor } from '@testing-library/react'-import React from 'react'+import * as React from 'react'import { createEmptyDataset } from '@/service/datasets'import { useInvalidDatasetList } from '@/service/knowledge/use-dataset'import EmptyDatasetCreationModal from './index'diff --git a/web/app/components/datasets/create/empty-dataset-creation-modal/index.tsx b/web/app/components/datasets/create/empty-dataset-creation-modal/index.tsxindex 4427009b06e..c88eb0b47d0 100644--- a/web/app/components/datasets/create/empty-dataset-creation-modal/index.tsx+++ b/web/app/components/datasets/create/empty-dataset-creation-modal/index.tsx@@ -1,6 +1,7 @@'use client'import { useRouter } from 'next/navigation'-import React, { useState } from 'react'+import * as React from 'react'+import { useState } from 'react'import { useTranslation } from 'react-i18next'import { useContext } from 'use-context-selector'import { trackEvent } from '@/app/components/base/amplitude'diff --git a/web/app/components/datasets/create/file-preview/index.tsx b/web/app/components/datasets/create/file-preview/index.tsxindex dd174837c4e..3212f61d0cf 100644--- a/web/app/components/datasets/create/file-preview/index.tsx+++ b/web/app/components/datasets/create/file-preview/index.tsx@@ -1,7 +1,8 @@'use client'import type { CustomFile as File } from '@/models/datasets'import { XMarkIcon } from '@heroicons/react/20/solid'-import React, { useEffect, useState } from 'react'+import * as React from 'react'+import { useEffect, useState } from 'react'import { useTranslation } from 'react-i18next'import Loading from '@/app/components/base/loading'import { fetchFilePreview } from '@/service/common'diff --git a/web/app/components/datasets/create/file-uploader/index.tsx b/web/app/components/datasets/create/file-uploader/index.tsxindex b0680905d12..97d1625c10e 100644--- a/web/app/components/datasets/create/file-uploader/index.tsx+++ b/web/app/components/datasets/create/file-uploader/index.tsx@@ -1,7 +1,8 @@'use client'import type { CustomFile as File, FileItem } from '@/models/datasets'import { RiDeleteBinLine, RiUploadCloud2Line } from '@remixicon/react'-import React, { useCallback, useEffect, useMemo, useRef, useState } from 'react'+import * as React from 'react'+import { useCallback, useEffect, useMemo, useRef, useState } from 'react'import { useTranslation } from 'react-i18next'import { useContext } from 'use-context-selector'import { getFileUploadErrorMessage } from '@/app/components/base/file-uploader/utils'diff --git a/web/app/components/datasets/create/index.spec.tsx b/web/app/components/datasets/create/index.spec.tsxindex a0248d59a13..66a642db3a6 100644--- a/web/app/components/datasets/create/index.spec.tsx+++ b/web/app/components/datasets/create/index.spec.tsx@@ -1,7 +1,7 @@import type { DataSourceAuth } from '@/app/components/header/account-setting/data-source-page-new/types'import type { DataSet } from '@/models/datasets'import { fireEvent, render, screen, waitFor } from '@testing-library/react'-import React from 'react'+import * as React from 'react'import { DataSourceProvider } from '@/models/common'import { ChunkingMode, DatasetPermission, DataSourceType } from '@/models/datasets'import { RETRIEVE_METHOD } from '@/types/app'diff --git a/web/app/components/datasets/create/index.tsx b/web/app/components/datasets/create/index.tsxindex 357b2256fcc..3e4e8706281 100644--- a/web/app/components/datasets/create/index.tsx+++ b/web/app/components/datasets/create/index.tsx@@ -2,7 +2,8 @@import type { NotionPage } from '@/models/common'import type { CrawlOptions, CrawlResultItem, createDocumentResponse, FileItem } from '@/models/datasets'import { produce } from 'immer'-import React, { useCallback, useState } from 'react'+import * as React from 'react'+import { useCallback, useState } from 'react'import { useTranslation } from 'react-i18next'import Loading from '@/app/components/base/loading'import { ACCOUNT_SETTING_TAB } from '@/app/components/header/account-setting/constants'diff --git a/web/app/components/datasets/create/notion-page-preview/index.tsx b/web/app/components/datasets/create/notion-page-preview/index.tsxindex ac590cc0c3d..e245cd3490b 100644--- a/web/app/components/datasets/create/notion-page-preview/index.tsx+++ b/web/app/components/datasets/create/notion-page-preview/index.tsx@@ -1,7 +1,8 @@'use client'import type { NotionPage } from '@/models/common'import { XMarkIcon } from '@heroicons/react/20/solid'-import React, { useEffect, useState } from 'react'+import * as React from 'react'+import { useEffect, useState } from 'react'import { useTranslation } from 'react-i18next'import Loading from '@/app/components/base/loading'import NotionIcon from '@/app/components/base/notion-icon'diff --git a/web/app/components/datasets/create/step-one/index.tsx b/web/app/components/datasets/create/step-one/index.tsxindex ddbfb05e7d9..ff99c218b2e 100644--- a/web/app/components/datasets/create/step-one/index.tsx+++ b/web/app/components/datasets/create/step-one/index.tsx@@ -4,7 +4,8 @@ import type { DataSourceProvider, NotionPage } from '@/models/common'import type { CrawlOptions, CrawlResultItem, FileItem } from '@/models/datasets'import { RiArrowRightLine, RiFolder6Line } from '@remixicon/react'import { useBoolean } from 'ahooks'-import React, { useCallback, useMemo, useState } from 'react'+import * as React from 'react'+import { useCallback, useMemo, useState } from 'react'import { useTranslation } from 'react-i18next'import Button from '@/app/components/base/button'import NotionConnector from '@/app/components/base/notion-connector'diff --git a/web/app/components/datasets/create/step-one/upgrade-card.tsx b/web/app/components/datasets/create/step-one/upgrade-card.tsxindex a4fcca73c07..a354e91e56e 100644--- a/web/app/components/datasets/create/step-one/upgrade-card.tsx+++ b/web/app/components/datasets/create/step-one/upgrade-card.tsx@@ -1,6 +1,7 @@'use client'import type { FC } from 'react'-import React, { useCallback } from 'react'+import * as React from 'react'+import { useCallback } from 'react'import { useTranslation } from 'react-i18next'import UpgradeBtn from '@/app/components/billing/upgrade-btn'import { useModalContext } from '@/context/modal-context'diff --git a/web/app/components/datasets/create/step-three/index.tsx b/web/app/components/datasets/create/step-three/index.tsxindex 56ff55de84c..b4c122990f7 100644--- a/web/app/components/datasets/create/step-three/index.tsx+++ b/web/app/components/datasets/create/step-three/index.tsx@@ -1,7 +1,7 @@'use client'import type { createDocumentResponse, FullDocumentDetail } from '@/models/datasets'import { RiBookOpenLine } from '@remixicon/react'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import AppIcon from '@/app/components/base/app-icon'diff --git a/web/app/components/datasets/create/step-two/index.tsx b/web/app/components/datasets/create/step-two/index.tsxindex b2f1a221f6a..981b6c5a8fc 100644--- a/web/app/components/datasets/create/step-two/index.tsx+++ b/web/app/components/datasets/create/step-two/index.tsx@@ -12,7 +12,8 @@ import {import { noop } from 'lodash-es'import Image from 'next/image'import Link from 'next/link'-import React, { useCallback, useEffect, useMemo, useState } from 'react'+import * as React from 'react'+import { useCallback, useEffect, useMemo, useState } from 'react'import { useTranslation } from 'react-i18next'import { useContext } from 'use-context-selector'import { trackEvent } from '@/app/components/base/amplitude'diff --git a/web/app/components/datasets/create/step-two/language-select/index.spec.tsx b/web/app/components/datasets/create/step-two/language-select/index.spec.tsxindex ba1097ecb44..a2f0d96d80b 100644--- a/web/app/components/datasets/create/step-two/language-select/index.spec.tsx+++ b/web/app/components/datasets/create/step-two/language-select/index.spec.tsx@@ -1,6 +1,6 @@import type { ILanguageSelectProps } from './index'import { fireEvent, render, screen } from '@testing-library/react'-import React from 'react'+import * as React from 'react'import { languages } from '@/i18n-config/language'import LanguageSelect from './index'diff --git a/web/app/components/datasets/create/step-two/language-select/index.tsx b/web/app/components/datasets/create/step-two/language-select/index.tsxindex 9de71c12b89..b54db21970b 100644--- a/web/app/components/datasets/create/step-two/language-select/index.tsx+++ b/web/app/components/datasets/create/step-two/language-select/index.tsx@@ -1,7 +1,7 @@'use client'import type { FC } from 'react'import { RiArrowDownSLine, RiCheckLine } from '@remixicon/react'-import React from 'react'+import * as React from 'react'import Popover from '@/app/components/base/popover'import { languages } from '@/i18n-config/language'import { cn } from '@/utils/classnames'diff --git a/web/app/components/datasets/create/step-two/preview-item/index.spec.tsx b/web/app/components/datasets/create/step-two/preview-item/index.spec.tsxindex 911982b7b34..c4cdf754808 100644--- a/web/app/components/datasets/create/step-two/preview-item/index.spec.tsx+++ b/web/app/components/datasets/create/step-two/preview-item/index.spec.tsx@@ -1,6 +1,6 @@import type { IPreviewItemProps } from './index'import { render, screen } from '@testing-library/react'-import React from 'react'+import * as React from 'react'import PreviewItem, { PreviewType } from './index'// Test data builder for propsdiff --git a/web/app/components/datasets/create/step-two/preview-item/index.tsx b/web/app/components/datasets/create/step-two/preview-item/index.tsxindex 67706fae4c1..c1c95f4e626 100644--- a/web/app/components/datasets/create/step-two/preview-item/index.tsx+++ b/web/app/components/datasets/create/step-two/preview-item/index.tsx@@ -1,6 +1,6 @@'use client'import type { FC } from 'react'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'export type IPreviewItemProps = {diff --git a/web/app/components/datasets/create/stop-embedding-modal/index.tsx b/web/app/components/datasets/create/stop-embedding-modal/index.tsxindex cb3a572b326..5a65692a27b 100644--- a/web/app/components/datasets/create/stop-embedding-modal/index.tsx+++ b/web/app/components/datasets/create/stop-embedding-modal/index.tsx@@ -1,5 +1,5 @@'use client'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import Button from '@/app/components/base/button'import Modal from '@/app/components/base/modal'diff --git a/web/app/components/datasets/create/website/base/checkbox-with-label.tsx b/web/app/components/datasets/create/website/base/checkbox-with-label.tsxindex 214cc9dc042..182645d5bcc 100644--- a/web/app/components/datasets/create/website/base/checkbox-with-label.tsx+++ b/web/app/components/datasets/create/website/base/checkbox-with-label.tsx@@ -1,6 +1,6 @@'use client'import type { FC } from 'react'-import React from 'react'+import * as React from 'react'import Checkbox from '@/app/components/base/checkbox'import Tooltip from '@/app/components/base/tooltip'import { cn } from '@/utils/classnames'diff --git a/web/app/components/datasets/create/website/base/crawled-result-item.tsx b/web/app/components/datasets/create/website/base/crawled-result-item.tsxindex 47fdda193e7..4cc1e16a5f7 100644--- a/web/app/components/datasets/create/website/base/crawled-result-item.tsx+++ b/web/app/components/datasets/create/website/base/crawled-result-item.tsx@@ -1,7 +1,8 @@'use client'import type { FC } from 'react'import type { CrawlResultItem as CrawlResultItemType } from '@/models/datasets'-import React, { useCallback } from 'react'+import * as React from 'react'+import { useCallback } from 'react'import { useTranslation } from 'react-i18next'import Button from '@/app/components/base/button'import Checkbox from '@/app/components/base/checkbox'diff --git a/web/app/components/datasets/create/website/base/crawled-result.tsx b/web/app/components/datasets/create/website/base/crawled-result.tsxindex 987958c5c5d..c922a771699 100644--- a/web/app/components/datasets/create/website/base/crawled-result.tsx+++ b/web/app/components/datasets/create/website/base/crawled-result.tsx@@ -1,7 +1,8 @@'use client'import type { FC } from 'react'import type { CrawlResultItem } from '@/models/datasets'-import React, { useCallback } from 'react'+import * as React from 'react'+import { useCallback } from 'react'import { useTranslation } from 'react-i18next'import { cn } from '@/utils/classnames'import CheckboxWithLabel from './checkbox-with-label'diff --git a/web/app/components/datasets/create/website/base/crawling.tsx b/web/app/components/datasets/create/website/base/crawling.tsxindex 80642ad2f40..a9e28985f10 100644--- a/web/app/components/datasets/create/website/base/crawling.tsx+++ b/web/app/components/datasets/create/website/base/crawling.tsx@@ -1,6 +1,6 @@'use client'import type { FC } from 'react'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import { RowStruct } from '@/app/components/base/icons/src/public/other'diff --git a/web/app/components/datasets/create/website/base/error-message.tsx b/web/app/components/datasets/create/website/base/error-message.tsxindex d021d1431c8..97b18d00c16 100644--- a/web/app/components/datasets/create/website/base/error-message.tsx+++ b/web/app/components/datasets/create/website/base/error-message.tsx@@ -1,6 +1,6 @@'use client'import type { FC } from 'react'-import React from 'react'+import * as React from 'react'import { AlertTriangle } from '@/app/components/base/icons/src/vender/solid/alertsAndFeedback'import { cn } from '@/utils/classnames'diff --git a/web/app/components/datasets/create/website/base/field.tsx b/web/app/components/datasets/create/website/base/field.tsxindex 76671b65f7b..43f9e4bb37f 100644--- a/web/app/components/datasets/create/website/base/field.tsx+++ b/web/app/components/datasets/create/website/base/field.tsx@@ -1,6 +1,6 @@'use client'import type { FC } from 'react'-import React from 'react'+import * as React from 'react'import Tooltip from '@/app/components/base/tooltip'import { cn } from '@/utils/classnames'import Input from './input'diff --git a/web/app/components/datasets/create/website/base/header.tsx b/web/app/components/datasets/create/website/base/header.tsxindex 92f50a09894..cf4d537e3fe 100644--- a/web/app/components/datasets/create/website/base/header.tsx+++ b/web/app/components/datasets/create/website/base/header.tsx@@ -1,5 +1,5 @@import { RiBookOpenLine, RiEqualizer2Line } from '@remixicon/react'-import React from 'react'+import * as React from 'react'import Button from '@/app/components/base/button'import Divider from '@/app/components/base/divider'import { cn } from '@/utils/classnames'diff --git a/web/app/components/datasets/create/website/base/input.tsx b/web/app/components/datasets/create/website/base/input.tsxindex 64288f2872f..aff683c0e4f 100644--- a/web/app/components/datasets/create/website/base/input.tsx+++ b/web/app/components/datasets/create/website/base/input.tsx@@ -1,6 +1,7 @@'use client'import type { FC } from 'react'-import React, { useCallback } from 'react'+import * as React from 'react'+import { useCallback } from 'react'type Props = {value: string | numberdiff --git a/web/app/components/datasets/create/website/base/options-wrap.tsx b/web/app/components/datasets/create/website/base/options-wrap.tsxindex 50701251e11..4b6d9a55220 100644--- a/web/app/components/datasets/create/website/base/options-wrap.tsx+++ b/web/app/components/datasets/create/website/base/options-wrap.tsx@@ -2,7 +2,8 @@import type { FC } from 'react'import { RiEqualizer2Line } from '@remixicon/react'import { useBoolean } from 'ahooks'-import React, { useEffect } from 'react'+import * as React from 'react'+import { useEffect } from 'react'import { useTranslation } from 'react-i18next'import { ChevronRight } from '@/app/components/base/icons/src/vender/line/arrows'import { cn } from '@/utils/classnames'diff --git a/web/app/components/datasets/create/website/base/url-input.tsx b/web/app/components/datasets/create/website/base/url-input.tsxindex 1137c8d1c4f..c23655dcfa9 100644--- a/web/app/components/datasets/create/website/base/url-input.tsx+++ b/web/app/components/datasets/create/website/base/url-input.tsx@@ -1,6 +1,7 @@'use client'import type { FC } from 'react'-import React, { useCallback, useState } from 'react'+import * as React from 'react'+import { useCallback, useState } from 'react'import { useTranslation } from 'react-i18next'import Button from '@/app/components/base/button'import { useDocLink } from '@/context/i18n'diff --git a/web/app/components/datasets/create/website/firecrawl/index.tsx b/web/app/components/datasets/create/website/firecrawl/index.tsxindex c1146e8add2..0a79b8f660d 100644--- a/web/app/components/datasets/create/website/firecrawl/index.tsx+++ b/web/app/components/datasets/create/website/firecrawl/index.tsx@@ -1,7 +1,8 @@'use client'import type { FC } from 'react'import type { CrawlOptions, CrawlResultItem } from '@/models/datasets'-import React, { useCallback, useEffect, useState } from 'react'+import * as React from 'react'+import { useCallback, useEffect, useState } from 'react'import { useTranslation } from 'react-i18next'import Toast from '@/app/components/base/toast'import { ACCOUNT_SETTING_TAB } from '@/app/components/header/account-setting/constants'diff --git a/web/app/components/datasets/create/website/firecrawl/options.tsx b/web/app/components/datasets/create/website/firecrawl/options.tsxindex caf1895e645..59b23d34b0d 100644--- a/web/app/components/datasets/create/website/firecrawl/options.tsx+++ b/web/app/components/datasets/create/website/firecrawl/options.tsx@@ -1,7 +1,8 @@'use client'import type { FC } from 'react'import type { CrawlOptions } from '@/models/datasets'-import React, { useCallback } from 'react'+import * as React from 'react'+import { useCallback } from 'react'import { useTranslation } from 'react-i18next'import { cn } from '@/utils/classnames'import CheckboxWithLabel from '../base/checkbox-with-label'diff --git a/web/app/components/datasets/create/website/index.tsx b/web/app/components/datasets/create/website/index.tsxindex 3d0d79dc771..20146311555 100644--- a/web/app/components/datasets/create/website/index.tsx+++ b/web/app/components/datasets/create/website/index.tsx@@ -2,7 +2,8 @@import type { FC } from 'react'import type { DataSourceAuth } from '@/app/components/header/account-setting/data-source-page-new/types'import type { CrawlOptions, CrawlResultItem } from '@/models/datasets'-import React, { useCallback, useMemo, useState } from 'react'+import * as React from 'react'+import { useCallback, useMemo, useState } from 'react'import { useTranslation } from 'react-i18next'import { ACCOUNT_SETTING_TAB } from '@/app/components/header/account-setting/constants'import { ENABLE_WEBSITE_FIRECRAWL, ENABLE_WEBSITE_JINAREADER, ENABLE_WEBSITE_WATERCRAWL } from '@/config'diff --git a/web/app/components/datasets/create/website/jina-reader/base/url-input.tsx b/web/app/components/datasets/create/website/jina-reader/base/url-input.tsxindex 0e20a76d1a8..71a5037e710 100644--- a/web/app/components/datasets/create/website/jina-reader/base/url-input.tsx+++ b/web/app/components/datasets/create/website/jina-reader/base/url-input.tsx@@ -1,6 +1,7 @@'use client'import type { FC } from 'react'-import React, { useCallback, useState } from 'react'+import * as React from 'react'+import { useCallback, useState } from 'react'import { useTranslation } from 'react-i18next'import Button from '@/app/components/base/button'import { useDocLink } from '@/context/i18n'diff --git a/web/app/components/datasets/create/website/jina-reader/index.tsx b/web/app/components/datasets/create/website/jina-reader/index.tsxindex 44556a4bcb5..953f869c44b 100644--- a/web/app/components/datasets/create/website/jina-reader/index.tsx+++ b/web/app/components/datasets/create/website/jina-reader/index.tsx@@ -1,7 +1,8 @@'use client'import type { FC } from 'react'import type { CrawlOptions, CrawlResultItem } from '@/models/datasets'-import React, { useCallback, useEffect, useState } from 'react'+import * as React from 'react'+import { useCallback, useEffect, useState } from 'react'import { useTranslation } from 'react-i18next'import Toast from '@/app/components/base/toast'import { ACCOUNT_SETTING_TAB } from '@/app/components/header/account-setting/constants'diff --git a/web/app/components/datasets/create/website/jina-reader/options.tsx b/web/app/components/datasets/create/website/jina-reader/options.tsxindex 67991055dfe..c9aeae9ee5d 100644--- a/web/app/components/datasets/create/website/jina-reader/options.tsx+++ b/web/app/components/datasets/create/website/jina-reader/options.tsx@@ -1,7 +1,8 @@'use client'import type { FC } from 'react'import type { CrawlOptions } from '@/models/datasets'-import React, { useCallback } from 'react'+import * as React from 'react'+import { useCallback } from 'react'import { useTranslation } from 'react-i18next'import { cn } from '@/utils/classnames'import CheckboxWithLabel from '../base/checkbox-with-label'diff --git a/web/app/components/datasets/create/website/no-data.tsx b/web/app/components/datasets/create/website/no-data.tsxindex f01ec18f1a4..ad3e1d40101 100644--- a/web/app/components/datasets/create/website/no-data.tsx+++ b/web/app/components/datasets/create/website/no-data.tsx@@ -1,6 +1,6 @@'use client'import type { FC } from 'react'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import Button from '@/app/components/base/button'import { Icon3Dots } from '@/app/components/base/icons/src/vender/line/others'diff --git a/web/app/components/datasets/create/website/preview.tsx b/web/app/components/datasets/create/website/preview.tsxindex f9213e3c89a..cb1c5822ba8 100644--- a/web/app/components/datasets/create/website/preview.tsx+++ b/web/app/components/datasets/create/website/preview.tsx@@ -1,7 +1,7 @@'use client'import type { CrawlResultItem } from '@/models/datasets'import { XMarkIcon } from '@heroicons/react/20/solid'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import { cn } from '@/utils/classnames'import s from '../file-preview/index.module.css'diff --git a/web/app/components/datasets/create/website/watercrawl/index.tsx b/web/app/components/datasets/create/website/watercrawl/index.tsxindex 938d1dd8133..9f3a1304199 100644--- a/web/app/components/datasets/create/website/watercrawl/index.tsx+++ b/web/app/components/datasets/create/website/watercrawl/index.tsx@@ -1,7 +1,8 @@'use client'import type { FC } from 'react'import type { CrawlOptions, CrawlResultItem } from '@/models/datasets'-import React, { useCallback, useEffect, useState } from 'react'+import * as React from 'react'+import { useCallback, useEffect, useState } from 'react'import { useTranslation } from 'react-i18next'import Toast from '@/app/components/base/toast'import { ACCOUNT_SETTING_TAB } from '@/app/components/header/account-setting/constants'diff --git a/web/app/components/datasets/create/website/watercrawl/options.tsx b/web/app/components/datasets/create/website/watercrawl/options.tsxindex 0858647c60a..5af2a5e7bb8 100644--- a/web/app/components/datasets/create/website/watercrawl/options.tsx+++ b/web/app/components/datasets/create/website/watercrawl/options.tsx@@ -1,7 +1,8 @@'use client'import type { FC } from 'react'import type { CrawlOptions } from '@/models/datasets'-import React, { useCallback } from 'react'+import * as React from 'react'+import { useCallback } from 'react'import { useTranslation } from 'react-i18next'import { cn } from '@/utils/classnames'import CheckboxWithLabel from '../base/checkbox-with-label'diff --git a/web/app/components/datasets/documents/create-from-pipeline/actions/index.spec.tsx b/web/app/components/datasets/documents/create-from-pipeline/actions/index.spec.tsxindex 077b4fee3a3..cbb74bb796f 100644--- a/web/app/components/datasets/documents/create-from-pipeline/actions/index.spec.tsx+++ b/web/app/components/datasets/documents/create-from-pipeline/actions/index.spec.tsx@@ -1,5 +1,5 @@import { fireEvent, render, screen } from '@testing-library/react'-import React from 'react'+import * as React from 'react'import Actions from './index'// ==========================================diff --git a/web/app/components/datasets/documents/create-from-pipeline/actions/index.tsx b/web/app/components/datasets/documents/create-from-pipeline/actions/index.tsxindex ad860e0f599..fc2759cbdad 100644--- a/web/app/components/datasets/documents/create-from-pipeline/actions/index.tsx+++ b/web/app/components/datasets/documents/create-from-pipeline/actions/index.tsx@@ -1,7 +1,8 @@import { RiArrowRightLine } from '@remixicon/react'import Link from 'next/link'import { useParams } from 'next/navigation'-import React, { useMemo } from 'react'+import * as React from 'react'+import { useMemo } from 'react'import { useTranslation } from 'react-i18next'import Button from '@/app/components/base/button'import Checkbox from '@/app/components/base/checkbox'diff --git a/web/app/components/datasets/documents/create-from-pipeline/data-source-options/index.spec.tsx b/web/app/components/datasets/documents/create-from-pipeline/data-source-options/index.spec.tsxindex f5c56995b88..57b73e92225 100644--- a/web/app/components/datasets/documents/create-from-pipeline/data-source-options/index.spec.tsx+++ b/web/app/components/datasets/documents/create-from-pipeline/data-source-options/index.spec.tsx@@ -3,7 +3,7 @@ import type { DataSourceNodeType } from '@/app/components/workflow/nodes/data-soimport type { Node } from '@/app/components/workflow/types'import { QueryClient, QueryClientProvider } from '@tanstack/react-query'import { act, fireEvent, render, renderHook, screen } from '@testing-library/react'-import React from 'react'+import * as React from 'react'import { BlockEnum } from '@/app/components/workflow/types'import DatasourceIcon from './datasource-icon'import { useDatasourceIcon } from './hooks'diff --git a/web/app/components/datasets/documents/create-from-pipeline/data-source-options/option-card.tsx b/web/app/components/datasets/documents/create-from-pipeline/data-source-options/option-card.tsxindex 6e8d1d41052..b938afa950f 100644--- a/web/app/components/datasets/documents/create-from-pipeline/data-source-options/option-card.tsx+++ b/web/app/components/datasets/documents/create-from-pipeline/data-source-options/option-card.tsx@@ -1,5 +1,5 @@import type { DataSourceNodeType } from '@/app/components/workflow/nodes/data-source/types'-import React from 'react'+import * as React from 'react'import { cn } from '@/utils/classnames'import DatasourceIcon from './datasource-icon'import { useDatasourceIcon } from './hooks'diff --git a/web/app/components/datasets/documents/create-from-pipeline/data-source/base/credential-selector/index.spec.tsx b/web/app/components/datasets/documents/create-from-pipeline/data-source/base/credential-selector/index.spec.tsxindex 1477fe71e90..da5075ec8a0 100644--- a/web/app/components/datasets/documents/create-from-pipeline/data-source/base/credential-selector/index.spec.tsx+++ b/web/app/components/datasets/documents/create-from-pipeline/data-source/base/credential-selector/index.spec.tsx@@ -1,7 +1,7 @@import type { CredentialSelectorProps } from './index'import type { DataSourceCredential } from '@/types/pipeline'import { fireEvent, render, screen, waitFor, within } from '@testing-library/react'-import React from 'react'+import * as React from 'react'import CredentialSelector from './index'// Mock CredentialTypeEnum to avoid deep import chain issuesdiff --git a/web/app/components/datasets/documents/create-from-pipeline/data-source/base/credential-selector/index.tsx b/web/app/components/datasets/documents/create-from-pipeline/data-source/base/credential-selector/index.tsxindex abeff83ebf8..2f14b0f3b8b 100644--- a/web/app/components/datasets/documents/create-from-pipeline/data-source/base/credential-selector/index.tsx+++ b/web/app/components/datasets/documents/create-from-pipeline/data-source/base/credential-selector/index.tsx@@ -1,6 +1,7 @@import type { DataSourceCredential } from '@/types/pipeline'import { useBoolean } from 'ahooks'-import React, { useCallback, useEffect, useMemo } from 'react'+import * as React from 'react'+import { useCallback, useEffect, useMemo } from 'react'import {PortalToFollowElem,PortalToFollowElemContent,diff --git a/web/app/components/datasets/documents/create-from-pipeline/data-source/base/credential-selector/item.tsx b/web/app/components/datasets/documents/create-from-pipeline/data-source/base/credential-selector/item.tsxindex 65ea951798b..4d54a04d1fa 100644--- a/web/app/components/datasets/documents/create-from-pipeline/data-source/base/credential-selector/item.tsx+++ b/web/app/components/datasets/documents/create-from-pipeline/data-source/base/credential-selector/item.tsx@@ -1,6 +1,7 @@import type { DataSourceCredential } from '@/types/pipeline'import { RiCheckLine } from '@remixicon/react'-import React, { useCallback } from 'react'+import * as React from 'react'+import { useCallback } from 'react'import { CredentialIcon } from '@/app/components/datasets/common/credential-icon'type ItemProps = {diff --git a/web/app/components/datasets/documents/create-from-pipeline/data-source/base/credential-selector/list.tsx b/web/app/components/datasets/documents/create-from-pipeline/data-source/base/credential-selector/list.tsxindex d90feaf2c04..09988a42d5b 100644--- a/web/app/components/datasets/documents/create-from-pipeline/data-source/base/credential-selector/list.tsx+++ b/web/app/components/datasets/documents/create-from-pipeline/data-source/base/credential-selector/list.tsx@@ -1,5 +1,5 @@import type { DataSourceCredential } from '@/types/pipeline'-import React from 'react'+import * as React from 'react'import Item from './item'type ListProps = {diff --git a/web/app/components/datasets/documents/create-from-pipeline/data-source/base/credential-selector/trigger.tsx b/web/app/components/datasets/documents/create-from-pipeline/data-source/base/credential-selector/trigger.tsxindex 7bac6afd354..ed68eaef5d0 100644--- a/web/app/components/datasets/documents/create-from-pipeline/data-source/base/credential-selector/trigger.tsx+++ b/web/app/components/datasets/documents/create-from-pipeline/data-source/base/credential-selector/trigger.tsx@@ -1,6 +1,6 @@import type { DataSourceCredential } from '@/types/pipeline'import { RiArrowDownSLine } from '@remixicon/react'-import React from 'react'+import * as React from 'react'import { CredentialIcon } from '@/app/components/datasets/common/credential-icon'import { cn } from '@/utils/classnames'diff --git a/web/app/components/datasets/documents/create-from-pipeline/data-source/base/header.spec.tsx b/web/app/components/datasets/documents/create-from-pipeline/data-source/base/header.spec.tsxindex cadfbdae0f3..31be2cdba6c 100644--- a/web/app/components/datasets/documents/create-from-pipeline/data-source/base/header.spec.tsx+++ b/web/app/components/datasets/documents/create-from-pipeline/data-source/base/header.spec.tsx@@ -1,6 +1,6 @@import type { DataSourceCredential } from '@/types/pipeline'import { fireEvent, render, screen } from '@testing-library/react'-import React from 'react'+import * as React from 'react'import Header from './header'// Mock CredentialTypeEnum to avoid deep import chain issuesdiff --git a/web/app/components/datasets/documents/create-from-pipeline/data-source/base/header.tsx b/web/app/components/datasets/documents/create-from-pipeline/data-source/base/header.tsxindex cbdd24e5b95..c08e39937f2 100644--- a/web/app/components/datasets/documents/create-from-pipeline/data-source/base/header.tsx+++ b/web/app/components/datasets/documents/create-from-pipeline/data-source/base/header.tsx@@ -1,6 +1,6 @@import type { CredentialSelectorProps } from './credential-selector'import { RiBookOpenLine, RiEqualizer2Line } from '@remixicon/react'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import Button from '@/app/components/base/button'import Divider from '@/app/components/base/divider'diff --git a/web/app/components/datasets/documents/create-from-pipeline/data-source/local-file/index.tsx b/web/app/components/datasets/documents/create-from-pipeline/data-source/local-file/index.tsxindex ffa5ed6bb8f..31570ef4cf4 100644--- a/web/app/components/datasets/documents/create-from-pipeline/data-source/local-file/index.tsx+++ b/web/app/components/datasets/documents/create-from-pipeline/data-source/local-file/index.tsx@@ -3,7 +3,8 @@ import type { CustomFile as File, FileItem } from '@/models/datasets'import { RiDeleteBinLine, RiErrorWarningFill, RiUploadCloud2Line } from '@remixicon/react'import { produce } from 'immer'import dynamic from 'next/dynamic'-import React, { useCallback, useEffect, useMemo, useRef, useState } from 'react'+import * as React from 'react'+import { useCallback, useEffect, useMemo, useRef, useState } from 'react'import { useTranslation } from 'react-i18next'import { useContext } from 'use-context-selector'import { getFileUploadErrorMessage } from '@/app/components/base/file-uploader/utils'diff --git a/web/app/components/datasets/documents/create-from-pipeline/data-source/online-documents/index.spec.tsx b/web/app/components/datasets/documents/create-from-pipeline/data-source/online-documents/index.spec.tsxindex 80109c738a4..543d53ac39c 100644--- a/web/app/components/datasets/documents/create-from-pipeline/data-source/online-documents/index.spec.tsx+++ b/web/app/components/datasets/documents/create-from-pipeline/data-source/online-documents/index.spec.tsx@@ -1,7 +1,7 @@import type { DataSourceNodeType } from '@/app/components/workflow/nodes/data-source/types'import type { DataSourceNotionWorkspace, NotionPage } from '@/models/common'import { fireEvent, render, screen, waitFor } from '@testing-library/react'-import React from 'react'+import * as React from 'react'import { VarKindType } from '@/app/components/workflow/nodes/_base/types'import OnlineDocuments from './index'diff --git a/web/app/components/datasets/documents/create-from-pipeline/data-source/online-documents/page-selector/index.spec.tsx b/web/app/components/datasets/documents/create-from-pipeline/data-source/online-documents/page-selector/index.spec.tsxindex c1fe9a8cda5..60da0e7c9fe 100644--- a/web/app/components/datasets/documents/create-from-pipeline/data-source/online-documents/page-selector/index.spec.tsx+++ b/web/app/components/datasets/documents/create-from-pipeline/data-source/online-documents/page-selector/index.spec.tsx@@ -1,7 +1,7 @@import type { NotionPageTreeItem, NotionPageTreeMap } from './index'import type { DataSourceNotionPage, DataSourceNotionPageMap } from '@/models/common'import { fireEvent, render, screen } from '@testing-library/react'-import React from 'react'+import * as React from 'react'import PageSelector from './index'import { recursivePushInParentDescendants } from './utils'diff --git a/web/app/components/datasets/documents/create-from-pipeline/data-source/online-documents/page-selector/item.tsx b/web/app/components/datasets/documents/create-from-pipeline/data-source/online-documents/page-selector/item.tsxindex bc494d93aa6..99ecb84ddd3 100644--- a/web/app/components/datasets/documents/create-from-pipeline/data-source/online-documents/page-selector/item.tsx+++ b/web/app/components/datasets/documents/create-from-pipeline/data-source/online-documents/page-selector/item.tsx@@ -1,7 +1,7 @@import type { ListChildComponentProps } from 'react-window'import type { DataSourceNotionPage, DataSourceNotionPageMap } from '@/models/common'import { RiArrowDownSLine, RiArrowRightSLine } from '@remixicon/react'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import { areEqual } from 'react-window'import Checkbox from '@/app/components/base/checkbox'diff --git a/web/app/components/datasets/documents/create-from-pipeline/data-source/online-documents/title.tsx b/web/app/components/datasets/documents/create-from-pipeline/data-source/online-documents/title.tsxindex c9f48d0539a..376274ba44a 100644--- a/web/app/components/datasets/documents/create-from-pipeline/data-source/online-documents/title.tsx+++ b/web/app/components/datasets/documents/create-from-pipeline/data-source/online-documents/title.tsx@@ -1,4 +1,4 @@-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'type TitleProps = {diff --git a/web/app/components/datasets/documents/create-from-pipeline/data-source/online-drive/file-list/header/breadcrumbs/bucket.tsx b/web/app/components/datasets/documents/create-from-pipeline/data-source/online-drive/file-list/header/breadcrumbs/bucket.tsxindex 06e4dc83863..ae84b210279 100644--- a/web/app/components/datasets/documents/create-from-pipeline/data-source/online-drive/file-list/header/breadcrumbs/bucket.tsx+++ b/web/app/components/datasets/documents/create-from-pipeline/data-source/online-drive/file-list/header/breadcrumbs/bucket.tsx@@ -1,4 +1,5 @@-import React, { useCallback } from 'react'+import * as React from 'react'+import { useCallback } from 'react'import { useTranslation } from 'react-i18next'import { BucketsGray } from '@/app/components/base/icons/src/public/knowledge/online-drive'import Tooltip from '@/app/components/base/tooltip'diff --git a/web/app/components/datasets/documents/create-from-pipeline/data-source/online-drive/file-list/header/breadcrumbs/drive.tsx b/web/app/components/datasets/documents/create-from-pipeline/data-source/online-drive/file-list/header/breadcrumbs/drive.tsxindex 91884ac2c8b..208658ab5b4 100644--- a/web/app/components/datasets/documents/create-from-pipeline/data-source/online-drive/file-list/header/breadcrumbs/drive.tsx+++ b/web/app/components/datasets/documents/create-from-pipeline/data-source/online-drive/file-list/header/breadcrumbs/drive.tsx@@ -1,4 +1,4 @@-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import { cn } from '@/utils/classnames'diff --git a/web/app/components/datasets/documents/create-from-pipeline/data-source/online-drive/file-list/header/breadcrumbs/dropdown/index.spec.tsx b/web/app/components/datasets/documents/create-from-pipeline/data-source/online-drive/file-list/header/breadcrumbs/dropdown/index.spec.tsxindex 174e5f62873..13abce1c81f 100644--- a/web/app/components/datasets/documents/create-from-pipeline/data-source/online-drive/file-list/header/breadcrumbs/dropdown/index.spec.tsx+++ b/web/app/components/datasets/documents/create-from-pipeline/data-source/online-drive/file-list/header/breadcrumbs/dropdown/index.spec.tsx@@ -1,5 +1,5 @@import { fireEvent, render, screen, waitFor } from '@testing-library/react'-import React from 'react'+import * as React from 'react'import Dropdown from './index'// ==========================================diff --git a/web/app/components/datasets/documents/create-from-pipeline/data-source/online-drive/file-list/header/breadcrumbs/dropdown/index.tsx b/web/app/components/datasets/documents/create-from-pipeline/data-source/online-drive/file-list/header/breadcrumbs/dropdown/index.tsxindex 5b4948241fb..f6eda7f7aff 100644--- a/web/app/components/datasets/documents/create-from-pipeline/data-source/online-drive/file-list/header/breadcrumbs/dropdown/index.tsx+++ b/web/app/components/datasets/documents/create-from-pipeline/data-source/online-drive/file-list/header/breadcrumbs/dropdown/index.tsx@@ -1,5 +1,6 @@import { RiMoreFill } from '@remixicon/react'-import React, { useCallback, useState } from 'react'+import * as React from 'react'+import { useCallback, useState } from 'react'import {PortalToFollowElem,PortalToFollowElemContent,diff --git a/web/app/components/datasets/documents/create-from-pipeline/data-source/online-drive/file-list/header/breadcrumbs/dropdown/item.tsx b/web/app/components/datasets/documents/create-from-pipeline/data-source/online-drive/file-list/header/breadcrumbs/dropdown/item.tsxindex 59ad8a6e109..864cade85ca 100644--- a/web/app/components/datasets/documents/create-from-pipeline/data-source/online-drive/file-list/header/breadcrumbs/dropdown/item.tsx+++ b/web/app/components/datasets/documents/create-from-pipeline/data-source/online-drive/file-list/header/breadcrumbs/dropdown/item.tsx@@ -1,4 +1,5 @@-import React, { useCallback } from 'react'+import * as React from 'react'+import { useCallback } from 'react'type ItemProps = {name: stringdiff --git a/web/app/components/datasets/documents/create-from-pipeline/data-source/online-drive/file-list/header/breadcrumbs/dropdown/menu.tsx b/web/app/components/datasets/documents/create-from-pipeline/data-source/online-drive/file-list/header/breadcrumbs/dropdown/menu.tsxindex 9c5b15cb47f..44af10cd95a 100644--- a/web/app/components/datasets/documents/create-from-pipeline/data-source/online-drive/file-list/header/breadcrumbs/dropdown/menu.tsx+++ b/web/app/components/datasets/documents/create-from-pipeline/data-source/online-drive/file-list/header/breadcrumbs/dropdown/menu.tsx@@ -1,4 +1,4 @@-import React from 'react'+import * as React from 'react'import Item from './item'type MenuProps = {diff --git a/web/app/components/datasets/documents/create-from-pipeline/data-source/online-drive/file-list/header/breadcrumbs/index.spec.tsx b/web/app/components/datasets/documents/create-from-pipeline/data-source/online-drive/file-list/header/breadcrumbs/index.spec.tsxindex 24500822c67..b7e53ed1bea 100644--- a/web/app/components/datasets/documents/create-from-pipeline/data-source/online-drive/file-list/header/breadcrumbs/index.spec.tsx+++ b/web/app/components/datasets/documents/create-from-pipeline/data-source/online-drive/file-list/header/breadcrumbs/index.spec.tsx@@ -1,5 +1,5 @@import { fireEvent, render, screen, waitFor } from '@testing-library/react'-import React from 'react'+import * as React from 'react'import Breadcrumbs from './index'// ==========================================diff --git a/web/app/components/datasets/documents/create-from-pipeline/data-source/online-drive/file-list/header/breadcrumbs/index.tsx b/web/app/components/datasets/documents/create-from-pipeline/data-source/online-drive/file-list/header/breadcrumbs/index.tsxindex 4657b79c190..a85137927a0 100644--- a/web/app/components/datasets/documents/create-from-pipeline/data-source/online-drive/file-list/header/breadcrumbs/index.tsx+++ b/web/app/components/datasets/documents/create-from-pipeline/data-source/online-drive/file-list/header/breadcrumbs/index.tsx@@ -1,4 +1,5 @@-import React, { useCallback, useMemo } from 'react'+import * as React from 'react'+import { useCallback, useMemo } from 'react'import { useTranslation } from 'react-i18next'import { useDataSourceStore, useDataSourceStoreWithSelector } from '../../../../store'import Bucket from './bucket'diff --git a/web/app/components/datasets/documents/create-from-pipeline/data-source/online-drive/file-list/header/breadcrumbs/item.tsx b/web/app/components/datasets/documents/create-from-pipeline/data-source/online-drive/file-list/header/breadcrumbs/item.tsxindex fa019642f36..1bf32ab7691 100644--- a/web/app/components/datasets/documents/create-from-pipeline/data-source/online-drive/file-list/header/breadcrumbs/item.tsx+++ b/web/app/components/datasets/documents/create-from-pipeline/data-source/online-drive/file-list/header/breadcrumbs/item.tsx@@ -1,4 +1,5 @@-import React, { useCallback } from 'react'+import * as React from 'react'+import { useCallback } from 'react'import { cn } from '@/utils/classnames'type BreadcrumbItemProps = {diff --git a/web/app/components/datasets/documents/create-from-pipeline/data-source/online-drive/file-list/header/index.spec.tsx b/web/app/components/datasets/documents/create-from-pipeline/data-source/online-drive/file-list/header/index.spec.tsxindex ff2bdb27699..3c836465b8b 100644--- a/web/app/components/datasets/documents/create-from-pipeline/data-source/online-drive/file-list/header/index.spec.tsx+++ b/web/app/components/datasets/documents/create-from-pipeline/data-source/online-drive/file-list/header/index.spec.tsx@@ -1,5 +1,5 @@import { fireEvent, render, screen } from '@testing-library/react'-import React from 'react'+import * as React from 'react'import Header from './index'// ==========================================diff --git a/web/app/components/datasets/documents/create-from-pipeline/data-source/online-drive/file-list/header/index.tsx b/web/app/components/datasets/documents/create-from-pipeline/data-source/online-drive/file-list/header/index.tsxindex cda916a4e88..8f0d169f1bd 100644--- a/web/app/components/datasets/documents/create-from-pipeline/data-source/online-drive/file-list/header/index.tsx+++ b/web/app/components/datasets/documents/create-from-pipeline/data-source/online-drive/file-list/header/index.tsx@@ -1,4 +1,4 @@-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import Input from '@/app/components/base/input'import Breadcrumbs from './breadcrumbs'diff --git a/web/app/components/datasets/documents/create-from-pipeline/data-source/online-drive/file-list/index.spec.tsx b/web/app/components/datasets/documents/create-from-pipeline/data-source/online-drive/file-list/index.spec.tsxindex 0e69a185742..2ad62aae8e5 100644--- a/web/app/components/datasets/documents/create-from-pipeline/data-source/online-drive/file-list/index.spec.tsx+++ b/web/app/components/datasets/documents/create-from-pipeline/data-source/online-drive/file-list/index.spec.tsx@@ -1,6 +1,6 @@import type { OnlineDriveFile } from '@/models/pipeline'import { fireEvent, render, screen } from '@testing-library/react'-import React from 'react'+import * as React from 'react'import { OnlineDriveFileType } from '@/models/pipeline'import FileList from './index'diff --git a/web/app/components/datasets/documents/create-from-pipeline/data-source/online-drive/file-list/list/empty-folder.tsx b/web/app/components/datasets/documents/create-from-pipeline/data-source/online-drive/file-list/list/empty-folder.tsxindex 595e976ba3a..304210ca8fe 100644--- a/web/app/components/datasets/documents/create-from-pipeline/data-source/online-drive/file-list/list/empty-folder.tsx+++ b/web/app/components/datasets/documents/create-from-pipeline/data-source/online-drive/file-list/list/empty-folder.tsx@@ -1,4 +1,4 @@-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'const EmptyFolder = () => {diff --git a/web/app/components/datasets/documents/create-from-pipeline/data-source/online-drive/file-list/list/empty-search-result.tsx b/web/app/components/datasets/documents/create-from-pipeline/data-source/online-drive/file-list/list/empty-search-result.tsxindex d435f38e647..b2266b7bb32 100644--- a/web/app/components/datasets/documents/create-from-pipeline/data-source/online-drive/file-list/list/empty-search-result.tsx+++ b/web/app/components/datasets/documents/create-from-pipeline/data-source/online-drive/file-list/list/empty-search-result.tsx@@ -1,4 +1,4 @@-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import Button from '@/app/components/base/button'import { SearchMenu } from '@/app/components/base/icons/src/vender/knowledge'diff --git a/web/app/components/datasets/documents/create-from-pipeline/data-source/online-drive/file-list/list/file-icon.tsx b/web/app/components/datasets/documents/create-from-pipeline/data-source/online-drive/file-list/list/file-icon.tsxindex 1c255328840..ee873908929 100644--- a/web/app/components/datasets/documents/create-from-pipeline/data-source/online-drive/file-list/list/file-icon.tsx+++ b/web/app/components/datasets/documents/create-from-pipeline/data-source/online-drive/file-list/list/file-icon.tsx@@ -1,4 +1,5 @@-import React, { useMemo } from 'react'+import * as React from 'react'+import { useMemo } from 'react'import FileTypeIcon from '@/app/components/base/file-uploader/file-type-icon'import { BucketsBlue, Folder } from '@/app/components/base/icons/src/public/knowledge/online-drive'import { OnlineDriveFileType } from '@/models/pipeline'diff --git a/web/app/components/datasets/documents/create-from-pipeline/data-source/online-drive/file-list/list/index.spec.tsx b/web/app/components/datasets/documents/create-from-pipeline/data-source/online-drive/file-list/list/index.spec.tsxindex 29683bcfa95..0a8066bdc77 100644--- a/web/app/components/datasets/documents/create-from-pipeline/data-source/online-drive/file-list/list/index.spec.tsx+++ b/web/app/components/datasets/documents/create-from-pipeline/data-source/online-drive/file-list/list/index.spec.tsx@@ -1,7 +1,7 @@import type { Mock } from 'vitest'import type { OnlineDriveFile } from '@/models/pipeline'import { fireEvent, render, screen, waitFor } from '@testing-library/react'-import React from 'react'+import * as React from 'react'import { OnlineDriveFileType } from '@/models/pipeline'import List from './index'diff --git a/web/app/components/datasets/documents/create-from-pipeline/data-source/online-drive/file-list/list/index.tsx b/web/app/components/datasets/documents/create-from-pipeline/data-source/online-drive/file-list/list/index.tsxindex ecf28026d30..977001dbdd5 100644--- a/web/app/components/datasets/documents/create-from-pipeline/data-source/online-drive/file-list/list/index.tsx+++ b/web/app/components/datasets/documents/create-from-pipeline/data-source/online-drive/file-list/list/index.tsx@@ -1,6 +1,7 @@import type { OnlineDriveFile } from '@/models/pipeline'import { RiLoader2Line } from '@remixicon/react'-import React, { useEffect, useRef } from 'react'+import * as React from 'react'+import { useEffect, useRef } from 'react'import { useTranslation } from 'react-i18next'import Loading from '@/app/components/base/loading'import { useDataSourceStore } from '../../../store'diff --git a/web/app/components/datasets/documents/create-from-pipeline/data-source/online-drive/file-list/list/item.tsx b/web/app/components/datasets/documents/create-from-pipeline/data-source/online-drive/file-list/list/item.tsxindex 8672a1841a2..07ee21486a5 100644--- a/web/app/components/datasets/documents/create-from-pipeline/data-source/online-drive/file-list/list/item.tsx+++ b/web/app/components/datasets/documents/create-from-pipeline/data-source/online-drive/file-list/list/item.tsx@@ -1,6 +1,7 @@import type { Placement } from '@floating-ui/react'import type { OnlineDriveFile } from '@/models/pipeline'-import React, { useCallback } from 'react'+import * as React from 'react'+import { useCallback } from 'react'import { useTranslation } from 'react-i18next'import Checkbox from '@/app/components/base/checkbox'import Radio from '@/app/components/base/radio/ui'diff --git a/web/app/components/datasets/documents/create-from-pipeline/data-source/online-drive/header.tsx b/web/app/components/datasets/documents/create-from-pipeline/data-source/online-drive/header.tsxindex 4092a5b80c4..3a6f294e093 100644--- a/web/app/components/datasets/documents/create-from-pipeline/data-source/online-drive/header.tsx+++ b/web/app/components/datasets/documents/create-from-pipeline/data-source/online-drive/header.tsx@@ -1,5 +1,5 @@import { RiBookOpenLine, RiEqualizer2Line } from '@remixicon/react'-import React from 'react'+import * as React from 'react'import Button from '@/app/components/base/button'import Divider from '@/app/components/base/divider'diff --git a/web/app/components/datasets/documents/create-from-pipeline/data-source/online-drive/index.spec.tsx b/web/app/components/datasets/documents/create-from-pipeline/data-source/online-drive/index.spec.tsxindex ff65ad1385b..7bf1d123f67 100644--- a/web/app/components/datasets/documents/create-from-pipeline/data-source/online-drive/index.spec.tsx+++ b/web/app/components/datasets/documents/create-from-pipeline/data-source/online-drive/index.spec.tsx@@ -2,7 +2,7 @@ import type { DataSourceNodeType } from '@/app/components/workflow/nodes/data-soimport type { OnlineDriveFile } from '@/models/pipeline'import type { OnlineDriveData } from '@/types/pipeline'import { fireEvent, render, screen, waitFor } from '@testing-library/react'-import React from 'react'+import * as React from 'react'import { ACCOUNT_SETTING_TAB } from '@/app/components/header/account-setting/constants'import { DatasourceType, OnlineDriveFileType } from '@/models/pipeline'import Header from './header'diff --git a/web/app/components/datasets/documents/create-from-pipeline/data-source/website-crawl/base/checkbox-with-label.tsx b/web/app/components/datasets/documents/create-from-pipeline/data-source/website-crawl/base/checkbox-with-label.tsxindex f109737a412..17dfa375696 100644--- a/web/app/components/datasets/documents/create-from-pipeline/data-source/website-crawl/base/checkbox-with-label.tsx+++ b/web/app/components/datasets/documents/create-from-pipeline/data-source/website-crawl/base/checkbox-with-label.tsx@@ -1,5 +1,5 @@'use client'-import React from 'react'+import * as React from 'react'import Checkbox from '@/app/components/base/checkbox'import Tooltip from '@/app/components/base/tooltip'import { cn } from '@/utils/classnames'diff --git a/web/app/components/datasets/documents/create-from-pipeline/data-source/website-crawl/base/crawled-result-item.tsx b/web/app/components/datasets/documents/create-from-pipeline/data-source/website-crawl/base/crawled-result-item.tsxindex 871be218b32..7ca7c03d97c 100644--- a/web/app/components/datasets/documents/create-from-pipeline/data-source/website-crawl/base/crawled-result-item.tsx+++ b/web/app/components/datasets/documents/create-from-pipeline/data-source/website-crawl/base/crawled-result-item.tsx@@ -1,6 +1,7 @@'use client'import type { CrawlResultItem as CrawlResultItemType } from '@/models/datasets'-import React, { useCallback } from 'react'+import * as React from 'react'+import { useCallback } from 'react'import { useTranslation } from 'react-i18next'import Button from '@/app/components/base/button'import Checkbox from '@/app/components/base/checkbox'diff --git a/web/app/components/datasets/documents/create-from-pipeline/data-source/website-crawl/base/crawled-result.tsx b/web/app/components/datasets/documents/create-from-pipeline/data-source/website-crawl/base/crawled-result.tsxindex ecd5c709b3b..b10b1e8457e 100644--- a/web/app/components/datasets/documents/create-from-pipeline/data-source/website-crawl/base/crawled-result.tsx+++ b/web/app/components/datasets/documents/create-from-pipeline/data-source/website-crawl/base/crawled-result.tsx@@ -1,6 +1,7 @@'use client'import type { CrawlResultItem } from '@/models/datasets'-import React, { useCallback } from 'react'+import * as React from 'react'+import { useCallback } from 'react'import { useTranslation } from 'react-i18next'import { cn } from '@/utils/classnames'import CheckboxWithLabel from './checkbox-with-label'diff --git a/web/app/components/datasets/documents/create-from-pipeline/data-source/website-crawl/base/crawling.tsx b/web/app/components/datasets/documents/create-from-pipeline/data-source/website-crawl/base/crawling.tsxindex 65eb2b2c76c..3b98ec76a03 100644--- a/web/app/components/datasets/documents/create-from-pipeline/data-source/website-crawl/base/crawling.tsx+++ b/web/app/components/datasets/documents/create-from-pipeline/data-source/website-crawl/base/crawling.tsx@@ -1,5 +1,5 @@'use client'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import { cn } from '@/utils/classnames'diff --git a/web/app/components/datasets/documents/create-from-pipeline/data-source/website-crawl/base/error-message.tsx b/web/app/components/datasets/documents/create-from-pipeline/data-source/website-crawl/base/error-message.tsxindex 1423ab03a66..f0a1fb64a9e 100644--- a/web/app/components/datasets/documents/create-from-pipeline/data-source/website-crawl/base/error-message.tsx+++ b/web/app/components/datasets/documents/create-from-pipeline/data-source/website-crawl/base/error-message.tsx@@ -1,5 +1,5 @@import { RiErrorWarningFill } from '@remixicon/react'-import React from 'react'+import * as React from 'react'import { cn } from '@/utils/classnames'type ErrorMessageProps = {diff --git a/web/app/components/datasets/documents/create-from-pipeline/data-source/website-crawl/base/index.spec.tsx b/web/app/components/datasets/documents/create-from-pipeline/data-source/website-crawl/base/index.spec.tsxindex a544d90c396..94de64d7919 100644--- a/web/app/components/datasets/documents/create-from-pipeline/data-source/website-crawl/base/index.spec.tsx+++ b/web/app/components/datasets/documents/create-from-pipeline/data-source/website-crawl/base/index.spec.tsx@@ -1,6 +1,6 @@import type { CrawlResultItem as CrawlResultItemType } from '@/models/datasets'import { fireEvent, render, screen } from '@testing-library/react'-import React from 'react'+import * as React from 'react'import CheckboxWithLabel from './checkbox-with-label'import CrawledResult from './crawled-result'import CrawledResultItem from './crawled-result-item'diff --git a/web/app/components/datasets/documents/create-from-pipeline/data-source/website-crawl/base/options/index.spec.tsx b/web/app/components/datasets/documents/create-from-pipeline/data-source/website-crawl/base/options/index.spec.tsxindex 4f92d85ec73..b89114c84b3 100644--- a/web/app/components/datasets/documents/create-from-pipeline/data-source/website-crawl/base/options/index.spec.tsx+++ b/web/app/components/datasets/documents/create-from-pipeline/data-source/website-crawl/base/options/index.spec.tsx@@ -1,7 +1,7 @@import type { MockInstance } from 'vitest'import type { RAGPipelineVariables } from '@/models/pipeline'import { fireEvent, render, screen } from '@testing-library/react'-import React from 'react'+import * as React from 'react'import { BaseFieldType } from '@/app/components/base/form/form-scenarios/base/types'import Toast from '@/app/components/base/toast'import { CrawlStep } from '@/models/datasets'diff --git a/web/app/components/datasets/documents/create-from-pipeline/data-source/website-crawl/index.spec.tsx b/web/app/components/datasets/documents/create-from-pipeline/data-source/website-crawl/index.spec.tsxindex 0c38208db99..493dd257306 100644--- a/web/app/components/datasets/documents/create-from-pipeline/data-source/website-crawl/index.spec.tsx+++ b/web/app/components/datasets/documents/create-from-pipeline/data-source/website-crawl/index.spec.tsx@@ -1,7 +1,7 @@import type { DataSourceNodeType } from '@/app/components/workflow/nodes/data-source/types'import type { CrawlResultItem } from '@/models/datasets'import { fireEvent, render, screen, waitFor } from '@testing-library/react'-import React from 'react'+import * as React from 'react'import { ACCOUNT_SETTING_TAB } from '@/app/components/header/account-setting/constants'import { CrawlStep } from '@/models/datasets'import WebsiteCrawl from './index'diff --git a/web/app/components/datasets/documents/create-from-pipeline/data-source/website-crawl/index.tsx b/web/app/components/datasets/documents/create-from-pipeline/data-source/website-crawl/index.tsxindex 30fa81b6087..2a1141cf9eb 100644--- a/web/app/components/datasets/documents/create-from-pipeline/data-source/website-crawl/index.tsx+++ b/web/app/components/datasets/documents/create-from-pipeline/data-source/website-crawl/index.tsx@@ -6,7 +6,8 @@ import type {DataSourceNodeErrorResponse,DataSourceNodeProcessingResponse,} from '@/types/pipeline'-import React, { useCallback, useRef, useState } from 'react'+import * as React from 'react'+import { useCallback, useRef, useState } from 'react'import { useTranslation } from 'react-i18next'import { useShallow } from 'zustand/react/shallow'import { ACCOUNT_SETTING_TAB } from '@/app/components/header/account-setting/constants'diff --git a/web/app/components/datasets/documents/create-from-pipeline/left-header.tsx b/web/app/components/datasets/documents/create-from-pipeline/left-header.tsxindex 1760286b043..2b30c790222 100644--- a/web/app/components/datasets/documents/create-from-pipeline/left-header.tsx+++ b/web/app/components/datasets/documents/create-from-pipeline/left-header.tsx@@ -2,7 +2,7 @@ import type { Step } from './step-indicator'import { RiArrowLeftLine } from '@remixicon/react'import Link from 'next/link'import { useParams } from 'next/navigation'-import React from 'react'+import * as React from 'react'import Button from '@/app/components/base/button'import Effect from '@/app/components/base/effect'import StepIndicator from './step-indicator'diff --git a/web/app/components/datasets/documents/create-from-pipeline/preview/chunk-preview.spec.tsx b/web/app/components/datasets/documents/create-from-pipeline/preview/chunk-preview.spec.tsxindex 29584b5da52..f055c90df87 100644--- a/web/app/components/datasets/documents/create-from-pipeline/preview/chunk-preview.spec.tsx+++ b/web/app/components/datasets/documents/create-from-pipeline/preview/chunk-preview.spec.tsx@@ -2,7 +2,7 @@ import type { NotionPage } from '@/models/common'import type { CrawlResultItem, CustomFile, FileIndexingEstimateResponse } from '@/models/datasets'import type { OnlineDriveFile } from '@/models/pipeline'import { fireEvent, render, screen } from '@testing-library/react'-import React from 'react'+import * as React from 'react'import { ChunkingMode } from '@/models/datasets'import { DatasourceType, OnlineDriveFileType } from '@/models/pipeline'import ChunkPreview from './chunk-preview'diff --git a/web/app/components/datasets/documents/create-from-pipeline/preview/chunk-preview.tsx b/web/app/components/datasets/documents/create-from-pipeline/preview/chunk-preview.tsxindex d2a28feef92..6a137fa98c6 100644--- a/web/app/components/datasets/documents/create-from-pipeline/preview/chunk-preview.tsx+++ b/web/app/components/datasets/documents/create-from-pipeline/preview/chunk-preview.tsx@@ -2,7 +2,8 @@ import type { NotionPage } from '@/models/common'import type { CrawlResultItem, CustomFile, DocumentItem, FileIndexingEstimateResponse } from '@/models/datasets'import type { OnlineDriveFile } from '@/models/pipeline'import { RiSearchEyeLine } from '@remixicon/react'-import React, { useState } from 'react'+import * as React from 'react'+import { useState } from 'react'import { useTranslation } from 'react-i18next'import Badge from '@/app/components/base/badge'import Button from '@/app/components/base/button'diff --git a/web/app/components/datasets/documents/create-from-pipeline/preview/file-preview.spec.tsx b/web/app/components/datasets/documents/create-from-pipeline/preview/file-preview.spec.tsxindex e5aaa278952..6f040ffb003 100644--- a/web/app/components/datasets/documents/create-from-pipeline/preview/file-preview.spec.tsx+++ b/web/app/components/datasets/documents/create-from-pipeline/preview/file-preview.spec.tsx@@ -1,6 +1,6 @@import type { CustomFile as File } from '@/models/datasets'import { fireEvent, render, screen } from '@testing-library/react'-import React from 'react'+import * as React from 'react'import FilePreview from './file-preview'// Uses global react-i18next mock from web/vitest.setup.tsdiff --git a/web/app/components/datasets/documents/create-from-pipeline/preview/file-preview.tsx b/web/app/components/datasets/documents/create-from-pipeline/preview/file-preview.tsxindex 6962d63567f..53427a60a6a 100644--- a/web/app/components/datasets/documents/create-from-pipeline/preview/file-preview.tsx+++ b/web/app/components/datasets/documents/create-from-pipeline/preview/file-preview.tsx@@ -1,7 +1,8 @@'use client'import type { CustomFile as File } from '@/models/datasets'import { RiCloseLine } from '@remixicon/react'-import React, { useMemo } from 'react'+import * as React from 'react'+import { useMemo } from 'react'import { useTranslation } from 'react-i18next'import { useFilePreview } from '@/service/use-common'import { formatFileSize, formatNumberAbbreviated } from '@/utils/format'diff --git a/web/app/components/datasets/documents/create-from-pipeline/preview/loading.tsx b/web/app/components/datasets/documents/create-from-pipeline/preview/loading.tsxindex a367f3675c0..dedc9d6a99f 100644--- a/web/app/components/datasets/documents/create-from-pipeline/preview/loading.tsx+++ b/web/app/components/datasets/documents/create-from-pipeline/preview/loading.tsx@@ -1,4 +1,4 @@-import React from 'react'+import * as React from 'react'import { SkeletonContainer, SkeletonRectangle } from '@/app/components/base/skeleton'const Loading = () => {diff --git a/web/app/components/datasets/documents/create-from-pipeline/preview/online-document-preview.spec.tsx b/web/app/components/datasets/documents/create-from-pipeline/preview/online-document-preview.spec.tsxindex cd16ed3bbca..5375a0197c1 100644--- a/web/app/components/datasets/documents/create-from-pipeline/preview/online-document-preview.spec.tsx+++ b/web/app/components/datasets/documents/create-from-pipeline/preview/online-document-preview.spec.tsx@@ -1,6 +1,6 @@import type { NotionPage } from '@/models/common'import { fireEvent, render, screen, waitFor } from '@testing-library/react'-import React from 'react'+import * as React from 'react'import Toast from '@/app/components/base/toast'import OnlineDocumentPreview from './online-document-preview'diff --git a/web/app/components/datasets/documents/create-from-pipeline/preview/online-document-preview.tsx b/web/app/components/datasets/documents/create-from-pipeline/preview/online-document-preview.tsxindex 3582eed5dfb..6c252184215 100644--- a/web/app/components/datasets/documents/create-from-pipeline/preview/online-document-preview.tsx+++ b/web/app/components/datasets/documents/create-from-pipeline/preview/online-document-preview.tsx@@ -1,7 +1,8 @@'use client'import type { NotionPage } from '@/models/common'import { RiCloseLine } from '@remixicon/react'-import React, { useEffect, useState } from 'react'+import * as React from 'react'+import { useEffect, useState } from 'react'import { useTranslation } from 'react-i18next'import { Notion } from '@/app/components/base/icons/src/public/common'import { Markdown } from '@/app/components/base/markdown'diff --git a/web/app/components/datasets/documents/create-from-pipeline/preview/web-preview.spec.tsx b/web/app/components/datasets/documents/create-from-pipeline/preview/web-preview.spec.tsxindex cfe58de56b8..2cfb14f42a1 100644--- a/web/app/components/datasets/documents/create-from-pipeline/preview/web-preview.spec.tsx+++ b/web/app/components/datasets/documents/create-from-pipeline/preview/web-preview.spec.tsx@@ -1,6 +1,6 @@import type { CrawlResultItem } from '@/models/datasets'import { fireEvent, render, screen } from '@testing-library/react'-import React from 'react'+import * as React from 'react'import WebsitePreview from './web-preview'// Uses global react-i18next mock from web/vitest.setup.tsdiff --git a/web/app/components/datasets/documents/create-from-pipeline/preview/web-preview.tsx b/web/app/components/datasets/documents/create-from-pipeline/preview/web-preview.tsxindex c68ede7734a..22179bad05e 100644--- a/web/app/components/datasets/documents/create-from-pipeline/preview/web-preview.tsx+++ b/web/app/components/datasets/documents/create-from-pipeline/preview/web-preview.tsx@@ -1,7 +1,7 @@'use client'import type { CrawlResultItem } from '@/models/datasets'import { RiCloseLine, RiGlobalLine } from '@remixicon/react'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import { formatNumberAbbreviated } from '@/utils/format'diff --git a/web/app/components/datasets/documents/create-from-pipeline/process-documents/actions.tsx b/web/app/components/datasets/documents/create-from-pipeline/process-documents/actions.tsxindex a49a8e99640..f4f4898b1ff 100644--- a/web/app/components/datasets/documents/create-from-pipeline/process-documents/actions.tsx+++ b/web/app/components/datasets/documents/create-from-pipeline/process-documents/actions.tsx@@ -1,5 +1,5 @@import { RiArrowLeftLine } from '@remixicon/react'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import Button from '@/app/components/base/button'diff --git a/web/app/components/datasets/documents/create-from-pipeline/process-documents/components.spec.tsx b/web/app/components/datasets/documents/create-from-pipeline/process-documents/components.spec.tsxindex 2bd80ea60c1..322e6edd49c 100644--- a/web/app/components/datasets/documents/create-from-pipeline/process-documents/components.spec.tsx+++ b/web/app/components/datasets/documents/create-from-pipeline/process-documents/components.spec.tsx@@ -1,6 +1,6 @@import type { BaseConfiguration } from '@/app/components/base/form/form-scenarios/base/types'import { fireEvent, render, screen, waitFor } from '@testing-library/react'-import React from 'react'+import * as React from 'react'import { z } from 'zod'import { BaseFieldType } from '@/app/components/base/form/form-scenarios/base/types'import Toast from '@/app/components/base/toast'diff --git a/web/app/components/datasets/documents/create-from-pipeline/process-documents/header.tsx b/web/app/components/datasets/documents/create-from-pipeline/process-documents/header.tsxindex 0b6300310ae..ac1f3b0fa0d 100644--- a/web/app/components/datasets/documents/create-from-pipeline/process-documents/header.tsx+++ b/web/app/components/datasets/documents/create-from-pipeline/process-documents/header.tsx@@ -1,5 +1,5 @@import { RiSearchEyeLine } from '@remixicon/react'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import Button from '@/app/components/base/button'diff --git a/web/app/components/datasets/documents/create-from-pipeline/process-documents/index.spec.tsx b/web/app/components/datasets/documents/create-from-pipeline/process-documents/index.spec.tsxindex 2b0fd7f0d07..318a6c2cba5 100644--- a/web/app/components/datasets/documents/create-from-pipeline/process-documents/index.spec.tsx+++ b/web/app/components/datasets/documents/create-from-pipeline/process-documents/index.spec.tsx@@ -1,6 +1,6 @@import type { BaseConfiguration } from '@/app/components/base/form/form-scenarios/base/types'import { fireEvent, render, screen, waitFor } from '@testing-library/react'-import React from 'react'+import * as React from 'react'import { BaseFieldType } from '@/app/components/base/form/form-scenarios/base/types'import { useConfigurations, useInitialData } from '@/app/components/rag-pipeline/hooks/use-input-fields'import { useInputVariables } from './hooks'diff --git a/web/app/components/datasets/documents/create-from-pipeline/process-documents/index.tsx b/web/app/components/datasets/documents/create-from-pipeline/process-documents/index.tsxindex 4556d7ab851..770c6c820be 100644--- a/web/app/components/datasets/documents/create-from-pipeline/process-documents/index.tsx+++ b/web/app/components/datasets/documents/create-from-pipeline/process-documents/index.tsx@@ -1,4 +1,4 @@-import React from 'react'+import * as React from 'react'import { generateZodSchema } from '@/app/components/base/form/form-scenarios/base/utils'import { useConfigurations, useInitialData } from '@/app/components/rag-pipeline/hooks/use-input-fields'import Actions from './actions'diff --git a/web/app/components/datasets/documents/create-from-pipeline/processing/embedding-process/index.spec.tsx b/web/app/components/datasets/documents/create-from-pipeline/processing/embedding-process/index.spec.tsxindex 1626f4f7073..81e97a79a10 100644--- a/web/app/components/datasets/documents/create-from-pipeline/processing/embedding-process/index.spec.tsx+++ b/web/app/components/datasets/documents/create-from-pipeline/processing/embedding-process/index.spec.tsx@@ -2,7 +2,7 @@ import type { Mock } from 'vitest'import type { DocumentIndexingStatus, IndexingStatusResponse } from '@/models/datasets'import type { InitialDocumentDetail } from '@/models/pipeline'import { fireEvent, render, screen, waitFor } from '@testing-library/react'-import React from 'react'+import * as React from 'react'import { Plan } from '@/app/components/billing/type'import { IndexingType } from '@/app/components/datasets/create/step-two'import { DatasourceType } from '@/models/pipeline'diff --git a/web/app/components/datasets/documents/create-from-pipeline/processing/embedding-process/index.tsx b/web/app/components/datasets/documents/create-from-pipeline/processing/embedding-process/index.tsxindex 98f83f7458f..3c4dbb6e0a2 100644--- a/web/app/components/datasets/documents/create-from-pipeline/processing/embedding-process/index.tsx+++ b/web/app/components/datasets/documents/create-from-pipeline/processing/embedding-process/index.tsx@@ -12,7 +12,8 @@ import {} from '@remixicon/react'import Link from 'next/link'import { useRouter } from 'next/navigation'-import React, { useEffect, useMemo, useState } from 'react'+import * as React from 'react'+import { useEffect, useMemo, useState } from 'react'import { useTranslation } from 'react-i18next'import Button from '@/app/components/base/button'import Divider from '@/app/components/base/divider'diff --git a/web/app/components/datasets/documents/create-from-pipeline/processing/embedding-process/rule-detail.spec.tsx b/web/app/components/datasets/documents/create-from-pipeline/processing/embedding-process/rule-detail.spec.tsxindex 17d7d8305bd..9831896b909 100644--- a/web/app/components/datasets/documents/create-from-pipeline/processing/embedding-process/rule-detail.spec.tsx+++ b/web/app/components/datasets/documents/create-from-pipeline/processing/embedding-process/rule-detail.spec.tsx@@ -1,6 +1,6 @@import type { ProcessRuleResponse } from '@/models/datasets'import { render, screen } from '@testing-library/react'-import React from 'react'+import * as React from 'react'import { IndexingType } from '@/app/components/datasets/create/step-two'import { ProcessMode } from '@/models/datasets'import { RETRIEVE_METHOD } from '@/types/app'diff --git a/web/app/components/datasets/documents/create-from-pipeline/processing/embedding-process/rule-detail.tsx b/web/app/components/datasets/documents/create-from-pipeline/processing/embedding-process/rule-detail.tsxindex a96a47a5692..a16e284bcfa 100644--- a/web/app/components/datasets/documents/create-from-pipeline/processing/embedding-process/rule-detail.tsx+++ b/web/app/components/datasets/documents/create-from-pipeline/processing/embedding-process/rule-detail.tsx@@ -1,6 +1,7 @@import type { ProcessRuleResponse } from '@/models/datasets'import Image from 'next/image'-import React, { useCallback } from 'react'+import * as React from 'react'+import { useCallback } from 'react'import { useTranslation } from 'react-i18next'import { indexMethodIcon, retrievalIcon } from '@/app/components/datasets/create/icons'import { IndexingType } from '@/app/components/datasets/create/step-two'diff --git a/web/app/components/datasets/documents/create-from-pipeline/processing/index.spec.tsx b/web/app/components/datasets/documents/create-from-pipeline/processing/index.spec.tsxindex 948e3ba1189..9d7a3e7b087 100644--- a/web/app/components/datasets/documents/create-from-pipeline/processing/index.spec.tsx+++ b/web/app/components/datasets/documents/create-from-pipeline/processing/index.spec.tsx@@ -1,7 +1,7 @@import type { DocumentIndexingStatus } from '@/models/datasets'import type { InitialDocumentDetail } from '@/models/pipeline'import { render, screen } from '@testing-library/react'-import React from 'react'+import * as React from 'react'import { DatasourceType } from '@/models/pipeline'import Processing from './index'diff --git a/web/app/components/datasets/documents/create-from-pipeline/processing/index.tsx b/web/app/components/datasets/documents/create-from-pipeline/processing/index.tsxindex c57221f8a4e..09458dde89c 100644--- a/web/app/components/datasets/documents/create-from-pipeline/processing/index.tsx+++ b/web/app/components/datasets/documents/create-from-pipeline/processing/index.tsx@@ -1,7 +1,7 @@'use client'import type { InitialDocumentDetail } from '@/models/pipeline'import { RiBookOpenLine } from '@remixicon/react'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import { useDatasetDetailContextWithSelector } from '@/context/dataset-detail'import { useDocLink } from '@/context/i18n'diff --git a/web/app/components/datasets/documents/create-from-pipeline/step-indicator.tsx b/web/app/components/datasets/documents/create-from-pipeline/step-indicator.tsxindex 82bc9e9b31d..755526df79c 100644--- a/web/app/components/datasets/documents/create-from-pipeline/step-indicator.tsx+++ b/web/app/components/datasets/documents/create-from-pipeline/step-indicator.tsx@@ -1,4 +1,4 @@-import React from 'react'+import * as React from 'react'import { cn } from '@/utils/classnames'export type Step = {diff --git a/web/app/components/datasets/documents/detail/batch-modal/csv-downloader.tsx b/web/app/components/datasets/documents/detail/batch-modal/csv-downloader.tsxindex 7cf0890c43f..b6f0cbff103 100644--- a/web/app/components/datasets/documents/detail/batch-modal/csv-downloader.tsx+++ b/web/app/components/datasets/documents/detail/batch-modal/csv-downloader.tsx@@ -1,6 +1,6 @@'use client'import type { FC } from 'react'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import {useCSVDownloader,diff --git a/web/app/components/datasets/documents/detail/batch-modal/csv-uploader.tsx b/web/app/components/datasets/documents/detail/batch-modal/csv-uploader.tsxindex d127471e286..3e55da0a90b 100644--- a/web/app/components/datasets/documents/detail/batch-modal/csv-uploader.tsx+++ b/web/app/components/datasets/documents/detail/batch-modal/csv-uploader.tsx@@ -4,7 +4,8 @@ import type { FileItem } from '@/models/datasets'import {RiDeleteBinLine,} from '@remixicon/react'-import React, { useCallback, useEffect, useMemo, useRef, useState } from 'react'+import * as React from 'react'+import { useCallback, useEffect, useMemo, useRef, useState } from 'react'import { useTranslation } from 'react-i18next'import { useContext } from 'use-context-selector'import Button from '@/app/components/base/button'diff --git a/web/app/components/datasets/documents/detail/batch-modal/index.tsx b/web/app/components/datasets/documents/detail/batch-modal/index.tsxindex cc3e9455d89..091d5c493ed 100644--- a/web/app/components/datasets/documents/detail/batch-modal/index.tsx+++ b/web/app/components/datasets/documents/detail/batch-modal/index.tsx@@ -3,7 +3,8 @@ import type { FC } from 'react'import type { ChunkingMode, FileItem } from '@/models/datasets'import { RiCloseLine } from '@remixicon/react'import { noop } from 'lodash-es'-import React, { useEffect, useState } from 'react'+import * as React from 'react'+import { useEffect, useState } from 'react'import { useTranslation } from 'react-i18next'import Button from '@/app/components/base/button'import Modal from '@/app/components/base/modal'diff --git a/web/app/components/datasets/documents/detail/completed/child-segment-detail.tsx b/web/app/components/datasets/documents/detail/completed/child-segment-detail.tsxindex 135d791fb32..f7166ca4dce 100644--- a/web/app/components/datasets/documents/detail/completed/child-segment-detail.tsx+++ b/web/app/components/datasets/documents/detail/completed/child-segment-detail.tsx@@ -5,7 +5,8 @@ import {RiCollapseDiagonalLine,RiExpandDiagonalLine,} from '@remixicon/react'-import React, { useMemo, useState } from 'react'+import * as React from 'react'+import { useMemo, useState } from 'react'import { useTranslation } from 'react-i18next'import Divider from '@/app/components/base/divider'import { useEventEmitterContextContext } from '@/context/event-emitter'diff --git a/web/app/components/datasets/documents/detail/completed/common/action-buttons.tsx b/web/app/components/datasets/documents/detail/completed/common/action-buttons.tsxindex 69f7ee7889d..49a7524a8e0 100644--- a/web/app/components/datasets/documents/detail/completed/common/action-buttons.tsx+++ b/web/app/components/datasets/documents/detail/completed/common/action-buttons.tsx@@ -1,6 +1,7 @@import type { FC } from 'react'import { useKeyPress } from 'ahooks'-import React, { useMemo } from 'react'+import * as React from 'react'+import { useMemo } from 'react'import { useTranslation } from 'react-i18next'import Button from '@/app/components/base/button'import { getKeyboardKeyCodeBySystem, getKeyboardKeyNameBySystem } from '@/app/components/workflow/utils'diff --git a/web/app/components/datasets/documents/detail/completed/common/add-another.tsx b/web/app/components/datasets/documents/detail/completed/common/add-another.tsxindex 3c7eb83533f..e6103b8ffe5 100644--- a/web/app/components/datasets/documents/detail/completed/common/add-another.tsx+++ b/web/app/components/datasets/documents/detail/completed/common/add-another.tsx@@ -1,5 +1,5 @@import type { FC } from 'react'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import Checkbox from '@/app/components/base/checkbox'import { cn } from '@/utils/classnames'diff --git a/web/app/components/datasets/documents/detail/completed/common/batch-action.tsx b/web/app/components/datasets/documents/detail/completed/common/batch-action.tsxindex ed8b6ac5620..6cc60453dde 100644--- a/web/app/components/datasets/documents/detail/completed/common/batch-action.tsx+++ b/web/app/components/datasets/documents/detail/completed/common/batch-action.tsx@@ -1,7 +1,7 @@import type { FC } from 'react'import { RiArchive2Line, RiCheckboxCircleLine, RiCloseCircleLine, RiDeleteBinLine, RiDraftLine } from '@remixicon/react'import { useBoolean } from 'ahooks'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import Button from '@/app/components/base/button'import Confirm from '@/app/components/base/confirm'diff --git a/web/app/components/datasets/documents/detail/completed/common/chunk-content.tsx b/web/app/components/datasets/documents/detail/completed/common/chunk-content.tsxindex cb009030168..03ef530b111 100644--- a/web/app/components/datasets/documents/detail/completed/common/chunk-content.tsx+++ b/web/app/components/datasets/documents/detail/completed/common/chunk-content.tsx@@ -1,5 +1,6 @@import type { ComponentProps, FC } from 'react'-import React, { useEffect, useRef, useState } from 'react'+import * as React from 'react'+import { useEffect, useRef, useState } from 'react'import { useTranslation } from 'react-i18next'import { Markdown } from '@/app/components/base/markdown'import { ChunkingMode } from '@/models/datasets'diff --git a/web/app/components/datasets/documents/detail/completed/common/dot.tsx b/web/app/components/datasets/documents/detail/completed/common/dot.tsxindex 3ec98cb64fb..d0a3543851b 100644--- a/web/app/components/datasets/documents/detail/completed/common/dot.tsx+++ b/web/app/components/datasets/documents/detail/completed/common/dot.tsx@@ -1,4 +1,4 @@-import React from 'react'+import * as React from 'react'const Dot = () => {return (diff --git a/web/app/components/datasets/documents/detail/completed/common/drawer.tsx b/web/app/components/datasets/documents/detail/completed/common/drawer.tsxindex a3f30b0ebd7..dc1b7192c3e 100644--- a/web/app/components/datasets/documents/detail/completed/common/drawer.tsx+++ b/web/app/components/datasets/documents/detail/completed/common/drawer.tsx@@ -1,5 +1,6 @@import { useKeyPress } from 'ahooks'-import React, { useCallback, useEffect, useRef } from 'react'+import * as React from 'react'+import { useCallback, useEffect, useRef } from 'react'import { createPortal } from 'react-dom'import { cn } from '@/utils/classnames'import { useSegmentListContext } from '..'diff --git a/web/app/components/datasets/documents/detail/completed/common/empty.tsx b/web/app/components/datasets/documents/detail/completed/common/empty.tsxindex 04ce92a6930..48a730076e1 100644--- a/web/app/components/datasets/documents/detail/completed/common/empty.tsx+++ b/web/app/components/datasets/documents/detail/completed/common/empty.tsx@@ -1,6 +1,6 @@import type { FC } from 'react'import { RiFileList2Line } from '@remixicon/react'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'type IEmptyProps = {diff --git a/web/app/components/datasets/documents/detail/completed/common/full-screen-drawer.tsx b/web/app/components/datasets/documents/detail/completed/common/full-screen-drawer.tsxindex 9293dc862df..5f62bf0185b 100644--- a/web/app/components/datasets/documents/detail/completed/common/full-screen-drawer.tsx+++ b/web/app/components/datasets/documents/detail/completed/common/full-screen-drawer.tsx@@ -1,5 +1,5 @@import { noop } from 'lodash-es'-import React from 'react'+import * as React from 'react'import { cn } from '@/utils/classnames'import Drawer from './drawer'diff --git a/web/app/components/datasets/documents/detail/completed/common/keywords.tsx b/web/app/components/datasets/documents/detail/completed/common/keywords.tsxindex be7da98cd96..e62f2fd09d9 100644--- a/web/app/components/datasets/documents/detail/completed/common/keywords.tsx+++ b/web/app/components/datasets/documents/detail/completed/common/keywords.tsx@@ -1,6 +1,6 @@import type { FC } from 'react'import type { SegmentDetailModel } from '@/models/datasets'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import TagInput from '@/app/components/base/tag-input'import { cn } from '@/utils/classnames'diff --git a/web/app/components/datasets/documents/detail/completed/common/regeneration-modal.tsx b/web/app/components/datasets/documents/detail/completed/common/regeneration-modal.tsxindex 77518b2fe48..4957104e25e 100644--- a/web/app/components/datasets/documents/detail/completed/common/regeneration-modal.tsx+++ b/web/app/components/datasets/documents/detail/completed/common/regeneration-modal.tsx@@ -2,7 +2,8 @@ import type { FC } from 'react'import { RiLoader2Line } from '@remixicon/react'import { useCountDown } from 'ahooks'import { noop } from 'lodash-es'-import React, { useRef, useState } from 'react'+import * as React from 'react'+import { useRef, useState } from 'react'import { useTranslation } from 'react-i18next'import Button from '@/app/components/base/button'import Modal from '@/app/components/base/modal'diff --git a/web/app/components/datasets/documents/detail/completed/common/segment-index-tag.tsx b/web/app/components/datasets/documents/detail/completed/common/segment-index-tag.tsxindex 2a837f66a76..a263ca55c8f 100644--- a/web/app/components/datasets/documents/detail/completed/common/segment-index-tag.tsx+++ b/web/app/components/datasets/documents/detail/completed/common/segment-index-tag.tsx@@ -1,5 +1,6 @@import type { FC } from 'react'-import React, { useMemo } from 'react'+import * as React from 'react'+import { useMemo } from 'react'import { Chunk } from '@/app/components/base/icons/src/vender/knowledge'import { cn } from '@/utils/classnames'diff --git a/web/app/components/datasets/documents/detail/completed/common/tag.tsx b/web/app/components/datasets/documents/detail/completed/common/tag.tsxindex 66bc0bbeafb..f78cbf1c3ff 100644--- a/web/app/components/datasets/documents/detail/completed/common/tag.tsx+++ b/web/app/components/datasets/documents/detail/completed/common/tag.tsx@@ -1,4 +1,4 @@-import React from 'react'+import * as React from 'react'import { cn } from '@/utils/classnames'const Tag = ({ text, className }: { text: string, className?: string }) => {diff --git a/web/app/components/datasets/documents/detail/completed/display-toggle.tsx b/web/app/components/datasets/documents/detail/completed/display-toggle.tsxindex 2f1212acdfa..444907311a3 100644--- a/web/app/components/datasets/documents/detail/completed/display-toggle.tsx+++ b/web/app/components/datasets/documents/detail/completed/display-toggle.tsx@@ -1,6 +1,6 @@import type { FC } from 'react'import { RiLineHeight } from '@remixicon/react'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import { Collapse } from '@/app/components/base/icons/src/vender/knowledge'import Tooltip from '@/app/components/base/tooltip'diff --git a/web/app/components/datasets/documents/detail/completed/index.tsx b/web/app/components/datasets/documents/detail/completed/index.tsxindex 8c2587969d3..1b4aadfa502 100644--- a/web/app/components/datasets/documents/detail/completed/index.tsx+++ b/web/app/components/datasets/documents/detail/completed/index.tsx@@ -6,7 +6,8 @@ import type { ChildChunkDetail, SegmentDetailModel, SegmentUpdater } from '@/modimport { useDebounceFn } from 'ahooks'import { noop } from 'lodash-es'import { usePathname } from 'next/navigation'-import React, { useCallback, useEffect, useMemo, useRef, useState } from 'react'+import * as React from 'react'+import { useCallback, useEffect, useMemo, useRef, useState } from 'react'import { useTranslation } from 'react-i18next'import { createContext, useContext, useContextSelector } from 'use-context-selector'import Checkbox from '@/app/components/base/checkbox'diff --git a/web/app/components/datasets/documents/detail/completed/segment-card/chunk-content.tsx b/web/app/components/datasets/documents/detail/completed/segment-card/chunk-content.tsxindex 11c73349de3..dda2d9bf806 100644--- a/web/app/components/datasets/documents/detail/completed/segment-card/chunk-content.tsx+++ b/web/app/components/datasets/documents/detail/completed/segment-card/chunk-content.tsx@@ -1,5 +1,5 @@import type { FC } from 'react'-import React from 'react'+import * as React from 'react'import { Markdown } from '@/app/components/base/markdown'import { cn } from '@/utils/classnames'import { useSegmentListContext } from '..'diff --git a/web/app/components/datasets/documents/detail/completed/segment-card/index.spec.tsx b/web/app/components/datasets/documents/detail/completed/segment-card/index.spec.tsxindex 31f2e45ab44..536b7af3384 100644--- a/web/app/components/datasets/documents/detail/completed/segment-card/index.spec.tsx+++ b/web/app/components/datasets/documents/detail/completed/segment-card/index.spec.tsx@@ -2,7 +2,7 @@ import type { SegmentListContextValue } from '@/app/components/datasets/documentimport type { DocumentContextValue } from '@/app/components/datasets/documents/detail/context'import type { Attachment, ChildChunkDetail, ParentMode, SegmentDetailModel } from '@/models/datasets'import { fireEvent, render, screen, waitFor } from '@testing-library/react'-import React from 'react'+import * as React from 'react'import { ChunkingMode } from '@/models/datasets'import SegmentCard from './index'diff --git a/web/app/components/datasets/documents/detail/completed/segment-card/index.tsx b/web/app/components/datasets/documents/detail/completed/segment-card/index.tsxindex f0f24ec372e..2393324d554 100644--- a/web/app/components/datasets/documents/detail/completed/segment-card/index.tsx+++ b/web/app/components/datasets/documents/detail/completed/segment-card/index.tsx@@ -1,7 +1,8 @@import type { FC } from 'react'import type { ChildChunkDetail, SegmentDetailModel } from '@/models/datasets'import { RiDeleteBinLine, RiEditLine } from '@remixicon/react'-import React, { useCallback, useMemo, useState } from 'react'+import * as React from 'react'+import { useCallback, useMemo, useState } from 'react'import { useTranslation } from 'react-i18next'import Badge from '@/app/components/base/badge'import Confirm from '@/app/components/base/confirm'diff --git a/web/app/components/datasets/documents/detail/completed/segment-detail.tsx b/web/app/components/datasets/documents/detail/completed/segment-detail.tsxindex 175c08133da..1ba64176ad1 100644--- a/web/app/components/datasets/documents/detail/completed/segment-detail.tsx+++ b/web/app/components/datasets/documents/detail/completed/segment-detail.tsx@@ -6,7 +6,8 @@ import {RiCollapseDiagonalLine,RiExpandDiagonalLine,} from '@remixicon/react'-import React, { useCallback, useMemo, useState } from 'react'+import * as React from 'react'+import { useCallback, useMemo, useState } from 'react'import { useTranslation } from 'react-i18next'import { v4 as uuid4 } from 'uuid'import Divider from '@/app/components/base/divider'diff --git a/web/app/components/datasets/documents/detail/completed/segment-list.tsx b/web/app/components/datasets/documents/detail/completed/segment-list.tsxindex a0153ae76c3..9e5f0ab2fee 100644--- a/web/app/components/datasets/documents/detail/completed/segment-list.tsx+++ b/web/app/components/datasets/documents/detail/completed/segment-list.tsx@@ -1,5 +1,6 @@import type { ChildChunkDetail, SegmentDetailModel } from '@/models/datasets'-import React, { useMemo } from 'react'+import * as React from 'react'+import { useMemo } from 'react'import Checkbox from '@/app/components/base/checkbox'import Divider from '@/app/components/base/divider'import { ChunkingMode } from '@/models/datasets'diff --git a/web/app/components/datasets/documents/detail/completed/skeleton/full-doc-list-skeleton.tsx b/web/app/components/datasets/documents/detail/completed/skeleton/full-doc-list-skeleton.tsxindex e1d72312142..9f9f51b55ba 100644--- a/web/app/components/datasets/documents/detail/completed/skeleton/full-doc-list-skeleton.tsx+++ b/web/app/components/datasets/documents/detail/completed/skeleton/full-doc-list-skeleton.tsx@@ -1,4 +1,4 @@-import React from 'react'+import * as React from 'react'const Slice = React.memo(() => {return (diff --git a/web/app/components/datasets/documents/detail/completed/skeleton/general-list-skeleton.tsx b/web/app/components/datasets/documents/detail/completed/skeleton/general-list-skeleton.tsxindex 416a5e15d55..118a39ef567 100644--- a/web/app/components/datasets/documents/detail/completed/skeleton/general-list-skeleton.tsx+++ b/web/app/components/datasets/documents/detail/completed/skeleton/general-list-skeleton.tsx@@ -1,4 +1,4 @@-import React from 'react'+import * as React from 'react'import Checkbox from '@/app/components/base/checkbox'import Divider from '@/app/components/base/divider'import {diff --git a/web/app/components/datasets/documents/detail/completed/skeleton/paragraph-list-skeleton.tsx b/web/app/components/datasets/documents/detail/completed/skeleton/paragraph-list-skeleton.tsxindex aa33bfbf17f..9af0543fb6e 100644--- a/web/app/components/datasets/documents/detail/completed/skeleton/paragraph-list-skeleton.tsx+++ b/web/app/components/datasets/documents/detail/completed/skeleton/paragraph-list-skeleton.tsx@@ -1,5 +1,5 @@import { RiArrowRightSLine } from '@remixicon/react'-import React from 'react'+import * as React from 'react'import Checkbox from '@/app/components/base/checkbox'import Divider from '@/app/components/base/divider'import {diff --git a/web/app/components/datasets/documents/detail/completed/skeleton/parent-chunk-card-skeleton.tsx b/web/app/components/datasets/documents/detail/completed/skeleton/parent-chunk-card-skeleton.tsxindex 4495547edbb..be1a1696b23 100644--- a/web/app/components/datasets/documents/detail/completed/skeleton/parent-chunk-card-skeleton.tsx+++ b/web/app/components/datasets/documents/detail/completed/skeleton/parent-chunk-card-skeleton.tsx@@ -1,4 +1,4 @@-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import {SkeletonContainer,diff --git a/web/app/components/datasets/documents/detail/completed/status-item.tsx b/web/app/components/datasets/documents/detail/completed/status-item.tsxindex ce038742ffa..34fc8bf0cb6 100644--- a/web/app/components/datasets/documents/detail/completed/status-item.tsx+++ b/web/app/components/datasets/documents/detail/completed/status-item.tsx@@ -1,7 +1,7 @@import type { FC } from 'react'import type { Item } from '@/app/components/base/select'import { RiCheckLine } from '@remixicon/react'-import React from 'react'+import * as React from 'react'type IStatusItemProps = {item: Itemdiff --git a/web/app/components/datasets/documents/detail/embedding/index.tsx b/web/app/components/datasets/documents/detail/embedding/index.tsxindex 8eb5d197cb9..db83d89c404 100644--- a/web/app/components/datasets/documents/detail/embedding/index.tsx+++ b/web/app/components/datasets/documents/detail/embedding/index.tsx@@ -3,7 +3,8 @@ import type { CommonResponse } from '@/models/common'import type { IndexingStatusResponse, ProcessRuleResponse } from '@/models/datasets'import { RiLoader2Line, RiPauseCircleLine, RiPlayCircleLine } from '@remixicon/react'import Image from 'next/image'-import React, { useCallback, useEffect, useMemo, useRef, useState } from 'react'+import * as React from 'react'+import { useCallback, useEffect, useMemo, useRef, useState } from 'react'import { useTranslation } from 'react-i18next'import { useContext } from 'use-context-selector'import Divider from '@/app/components/base/divider'diff --git a/web/app/components/datasets/documents/detail/embedding/skeleton/index.tsx b/web/app/components/datasets/documents/detail/embedding/skeleton/index.tsxindex eda512f38ea..469d928eaa7 100644--- a/web/app/components/datasets/documents/detail/embedding/skeleton/index.tsx+++ b/web/app/components/datasets/documents/detail/embedding/skeleton/index.tsx@@ -1,4 +1,4 @@-import React from 'react'+import * as React from 'react'import Divider from '@/app/components/base/divider'import {SkeletonContainer,diff --git a/web/app/components/datasets/documents/detail/index.tsx b/web/app/components/datasets/documents/detail/index.tsxindex 88b9fb5153d..afb2d47c5b4 100644--- a/web/app/components/datasets/documents/detail/index.tsx+++ b/web/app/components/datasets/documents/detail/index.tsx@@ -3,7 +3,8 @@ import type { FC } from 'react'import type { DataSourceInfo, FileItem, LegacyDataSourceInfo } from '@/models/datasets'import { RiArrowLeftLine, RiLayoutLeft2Line, RiLayoutRight2Line } from '@remixicon/react'import { useRouter } from 'next/navigation'-import React, { useMemo, useState } from 'react'+import * as React from 'react'+import { useMemo, useState } from 'react'import { useTranslation } from 'react-i18next'import Divider from '@/app/components/base/divider'import FloatRightContainer from '@/app/components/base/float-right-container'diff --git a/web/app/components/datasets/documents/detail/metadata/index.tsx b/web/app/components/datasets/documents/detail/metadata/index.tsxindex 73e8357e101..87d136c3fe7 100644--- a/web/app/components/datasets/documents/detail/metadata/index.tsx+++ b/web/app/components/datasets/documents/detail/metadata/index.tsx@@ -5,7 +5,8 @@ import type { CommonResponse } from '@/models/common'import type { DocType, FullDocumentDetail } from '@/models/datasets'import { PencilIcon } from '@heroicons/react/24/outline'import { get } from 'lodash-es'-import React, { useEffect, useState } from 'react'+import * as React from 'react'+import { useEffect, useState } from 'react'import { useTranslation } from 'react-i18next'import { useContext } from 'use-context-selector'import AutoHeightTextarea from '@/app/components/base/auto-height-textarea'diff --git a/web/app/components/datasets/documents/detail/segment-add/index.tsx b/web/app/components/datasets/documents/detail/segment-add/index.tsxindex eed48eac6a5..d8c4ab5c69d 100644--- a/web/app/components/datasets/documents/detail/segment-add/index.tsx+++ b/web/app/components/datasets/documents/detail/segment-add/index.tsx@@ -7,7 +7,8 @@ import {RiLoader2Line,} from '@remixicon/react'import { useBoolean } from 'ahooks'-import React, { useCallback, useMemo } from 'react'+import * as React from 'react'+import { useCallback, useMemo } from 'react'import { useTranslation } from 'react-i18next'import { CheckCircle } from '@/app/components/base/icons/src/vender/solid/general'import Popover from '@/app/components/base/popover'diff --git a/web/app/components/datasets/documents/detail/settings/document-settings.tsx b/web/app/components/datasets/documents/detail/settings/document-settings.tsxindex 96ac687d7a6..60468295143 100644--- a/web/app/components/datasets/documents/detail/settings/document-settings.tsx+++ b/web/app/components/datasets/documents/detail/settings/document-settings.tsx@@ -11,7 +11,8 @@ import type {} from '@/models/datasets'import { useBoolean } from 'ahooks'import { useRouter } from 'next/navigation'-import React, { useMemo } from 'react'+import * as React from 'react'+import { useMemo } from 'react'import { useTranslation } from 'react-i18next'import { useContext } from 'use-context-selector'import AppUnavailable from '@/app/components/base/app-unavailable'diff --git a/web/app/components/datasets/documents/detail/settings/index.tsx b/web/app/components/datasets/documents/detail/settings/index.tsxindex ba1c1eb197b..45b885fb066 100644--- a/web/app/components/datasets/documents/detail/settings/index.tsx+++ b/web/app/components/datasets/documents/detail/settings/index.tsx@@ -1,5 +1,5 @@'use client'-import React from 'react'+import * as React from 'react'import { useDatasetDetailContextWithSelector } from '@/context/dataset-detail'import DocumentSettings from './document-settings'import PipelineSettings from './pipeline-settings'diff --git a/web/app/components/datasets/documents/detail/settings/pipeline-settings/left-header.tsx b/web/app/components/datasets/documents/detail/settings/pipeline-settings/left-header.tsxindex fb7d1356c16..547dc8f53b8 100644--- a/web/app/components/datasets/documents/detail/settings/pipeline-settings/left-header.tsx+++ b/web/app/components/datasets/documents/detail/settings/pipeline-settings/left-header.tsx@@ -1,6 +1,7 @@import { RiArrowLeftLine } from '@remixicon/react'import { useRouter } from 'next/navigation'-import React, { useCallback } from 'react'+import * as React from 'react'+import { useCallback } from 'react'import { useTranslation } from 'react-i18next'import Button from '@/app/components/base/button'import Effect from '@/app/components/base/effect'diff --git a/web/app/components/datasets/documents/detail/settings/pipeline-settings/process-documents/actions.tsx b/web/app/components/datasets/documents/detail/settings/pipeline-settings/process-documents/actions.tsxindex c14a722adea..2cd379fa5f5 100644--- a/web/app/components/datasets/documents/detail/settings/pipeline-settings/process-documents/actions.tsx+++ b/web/app/components/datasets/documents/detail/settings/pipeline-settings/process-documents/actions.tsx@@ -1,4 +1,4 @@-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import Button from '@/app/components/base/button'diff --git a/web/app/components/datasets/documents/index.tsx b/web/app/components/datasets/documents/index.tsxindex 6a8a8ca5639..5592c56224f 100644--- a/web/app/components/datasets/documents/index.tsx+++ b/web/app/components/datasets/documents/index.tsx@@ -6,7 +6,8 @@ import { PlusIcon } from '@heroicons/react/24/solid'import { RiDraftLine, RiExternalLinkLine } from '@remixicon/react'import { useDebounce, useDebounceFn } from 'ahooks'import { useRouter } from 'next/navigation'-import React, { useCallback, useEffect, useMemo, useState } from 'react'+import * as React from 'react'+import { useCallback, useEffect, useMemo, useState } from 'react'import { useTranslation } from 'react-i18next'import Button from '@/app/components/base/button'import Input from '@/app/components/base/input'diff --git a/web/app/components/datasets/documents/list.tsx b/web/app/components/datasets/documents/list.tsxindex 3c95874c462..0b06d5fe152 100644--- a/web/app/components/datasets/documents/list.tsx+++ b/web/app/components/datasets/documents/list.tsx@@ -11,7 +11,8 @@ import {import { useBoolean } from 'ahooks'import { pick, uniq } from 'lodash-es'import { useRouter } from 'next/navigation'-import React, { useCallback, useEffect, useMemo, useState } from 'react'+import * as React from 'react'+import { useCallback, useEffect, useMemo, useState } from 'react'import { useTranslation } from 'react-i18next'import Checkbox from '@/app/components/base/checkbox'import NotionIcon from '@/app/components/base/notion-icon'diff --git a/web/app/components/datasets/documents/operations.tsx b/web/app/components/datasets/documents/operations.tsxindex 561771dc891..825a3151780 100644--- a/web/app/components/datasets/documents/operations.tsx+++ b/web/app/components/datasets/documents/operations.tsx@@ -13,7 +13,8 @@ import {import { useBoolean, useDebounceFn } from 'ahooks'import { noop } from 'lodash-es'import { useRouter } from 'next/navigation'-import React, { useCallback, useState } from 'react'+import * as React from 'react'+import { useCallback, useState } from 'react'import { useTranslation } from 'react-i18next'import { useContext } from 'use-context-selector'import { DataSourceType, DocumentActionType } from '@/models/datasets'diff --git a/web/app/components/datasets/documents/rename-modal.tsx b/web/app/components/datasets/documents/rename-modal.tsxindex ee1b7a5a82b..cd4acf8eab4 100644--- a/web/app/components/datasets/documents/rename-modal.tsx+++ b/web/app/components/datasets/documents/rename-modal.tsx@@ -1,7 +1,8 @@'use client'import type { FC } from 'react'import { useBoolean } from 'ahooks'-import React, { useState } from 'react'+import * as React from 'react'+import { useState } from 'react'import { useTranslation } from 'react-i18next'import Button from '@/app/components/base/button'import Input from '@/app/components/base/input'diff --git a/web/app/components/datasets/documents/status-item/index.tsx b/web/app/components/datasets/documents/status-item/index.tsxindex f152e498adb..415b413a26d 100644--- a/web/app/components/datasets/documents/status-item/index.tsx+++ b/web/app/components/datasets/documents/status-item/index.tsx@@ -3,7 +3,8 @@ import type { ColorMap, IndicatorProps } from '@/app/components/header/indicatorimport type { CommonResponse } from '@/models/common'import type { DocumentDisplayStatus } from '@/models/datasets'import { useDebounceFn } from 'ahooks'-import React, { useMemo } from 'react'+import * as React from 'react'+import { useMemo } from 'react'import { useTranslation } from 'react-i18next'import { useContext } from 'use-context-selector'import Switch from '@/app/components/base/switch'diff --git a/web/app/components/datasets/external-api/external-api-modal/Form.tsx b/web/app/components/datasets/external-api/external-api-modal/Form.tsxindex 875475f3e47..558ea1414ed 100644--- a/web/app/components/datasets/external-api/external-api-modal/Form.tsx+++ b/web/app/components/datasets/external-api/external-api-modal/Form.tsx@@ -1,7 +1,7 @@import type { FC } from 'react'import type { CreateExternalAPIReq, FormSchema } from '../declarations'import { RiBookOpenLine } from '@remixicon/react'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import Input from '@/app/components/base/input'import { useDocLink } from '@/context/i18n'diff --git a/web/app/components/datasets/external-api/external-api-panel/index.tsx b/web/app/components/datasets/external-api/external-api-panel/index.tsxindex def26fe00b6..0cfe7657b1b 100644--- a/web/app/components/datasets/external-api/external-api-panel/index.tsx+++ b/web/app/components/datasets/external-api/external-api-panel/index.tsx@@ -3,7 +3,7 @@ import {RiBookOpenLine,RiCloseLine,} from '@remixicon/react'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import ActionButton from '@/app/components/base/action-button'import Button from '@/app/components/base/button'diff --git a/web/app/components/datasets/external-api/external-knowledge-api-card/index.tsx b/web/app/components/datasets/external-api/external-knowledge-api-card/index.tsxindex af95e6771a5..f4158fc4629 100644--- a/web/app/components/datasets/external-api/external-knowledge-api-card/index.tsx+++ b/web/app/components/datasets/external-api/external-knowledge-api-card/index.tsx@@ -4,7 +4,8 @@ import {RiDeleteBinLine,RiEditLine,} from '@remixicon/react'-import React, { useState } from 'react'+import * as React from 'react'+import { useState } from 'react'import { useTranslation } from 'react-i18next'import ActionButton from '@/app/components/base/action-button'import Confirm from '@/app/components/base/confirm'diff --git a/web/app/components/datasets/external-knowledge-base/connector/index.tsx b/web/app/components/datasets/external-knowledge-base/connector/index.tsxindex 5184bdd888a..1545c0d232a 100644--- a/web/app/components/datasets/external-knowledge-base/connector/index.tsx+++ b/web/app/components/datasets/external-knowledge-base/connector/index.tsx@@ -2,7 +2,8 @@import type { CreateKnowledgeBaseReq } from '@/app/components/datasets/external-knowledge-base/create/declarations'import { useRouter } from 'next/navigation'-import React, { useState } from 'react'+import * as React from 'react'+import { useState } from 'react'import { trackEvent } from '@/app/components/base/amplitude'import { useToastContext } from '@/app/components/base/toast'import ExternalKnowledgeBaseCreate from '@/app/components/datasets/external-knowledge-base/create'diff --git a/web/app/components/datasets/external-knowledge-base/create/ExternalApiSelect.tsx b/web/app/components/datasets/external-knowledge-base/create/ExternalApiSelect.tsxindex 2035f6709af..b07d1091e2f 100644--- a/web/app/components/datasets/external-knowledge-base/create/ExternalApiSelect.tsx+++ b/web/app/components/datasets/external-knowledge-base/create/ExternalApiSelect.tsx@@ -3,7 +3,8 @@ import {RiArrowDownSLine,} from '@remixicon/react'import { useRouter } from 'next/navigation'-import React, { useEffect, useState } from 'react'+import * as React from 'react'+import { useEffect, useState } from 'react'import { useTranslation } from 'react-i18next'import { ApiConnectionMod } from '@/app/components/base/icons/src/vender/solid/development'import { useExternalKnowledgeApi } from '@/context/external-knowledge-api-context'diff --git a/web/app/components/datasets/external-knowledge-base/create/ExternalApiSelection.tsx b/web/app/components/datasets/external-knowledge-base/create/ExternalApiSelection.tsxindex 68231b46d4d..6f4bfed1bac 100644--- a/web/app/components/datasets/external-knowledge-base/create/ExternalApiSelection.tsx+++ b/web/app/components/datasets/external-knowledge-base/create/ExternalApiSelection.tsx@@ -2,7 +2,8 @@import { RiAddLine } from '@remixicon/react'import { useRouter } from 'next/navigation'-import React, { useEffect, useState } from 'react'+import * as React from 'react'+import { useEffect, useState } from 'react'import { useTranslation } from 'react-i18next'import Button from '@/app/components/base/button'import Input from '@/app/components/base/input'diff --git a/web/app/components/datasets/external-knowledge-base/create/KnowledgeBaseInfo.tsx b/web/app/components/datasets/external-knowledge-base/create/KnowledgeBaseInfo.tsxindex 280e8ac8640..e3cddc2c69d 100644--- a/web/app/components/datasets/external-knowledge-base/create/KnowledgeBaseInfo.tsx+++ b/web/app/components/datasets/external-knowledge-base/create/KnowledgeBaseInfo.tsx@@ -1,4 +1,4 @@-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import Input from '@/app/components/base/input'diff --git a/web/app/components/datasets/external-knowledge-base/create/RetrievalSettings.tsx b/web/app/components/datasets/external-knowledge-base/create/RetrievalSettings.tsxindex a7de114a2dd..36085c5f330 100644--- a/web/app/components/datasets/external-knowledge-base/create/RetrievalSettings.tsx+++ b/web/app/components/datasets/external-knowledge-base/create/RetrievalSettings.tsx@@ -1,5 +1,5 @@import type { FC } from 'react'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import ScoreThresholdItem from '@/app/components/base/param-item/score-threshold-item'import TopKItem from '@/app/components/base/param-item/top-k-item'diff --git a/web/app/components/datasets/external-knowledge-base/create/index.spec.tsx b/web/app/components/datasets/external-knowledge-base/create/index.spec.tsxindex 0284a924c0b..2fce096cd5f 100644--- a/web/app/components/datasets/external-knowledge-base/create/index.spec.tsx+++ b/web/app/components/datasets/external-knowledge-base/create/index.spec.tsx@@ -1,7 +1,7 @@import type { ExternalAPIItem } from '@/models/datasets'import { fireEvent, render, screen, waitFor } from '@testing-library/react'import userEvent from '@testing-library/user-event'-import React from 'react'+import * as React from 'react'import ExternalKnowledgeBaseCreate from './index'import RetrievalSettings from './RetrievalSettings'diff --git a/web/app/components/datasets/extra-info/index.tsx b/web/app/components/datasets/extra-info/index.tsxindex 5b46c927983..d0f74fd2884 100644--- a/web/app/components/datasets/extra-info/index.tsx+++ b/web/app/components/datasets/extra-info/index.tsx@@ -1,5 +1,5 @@import type { RelatedAppResponse } from '@/models/datasets'-import React from 'react'+import * as React from 'react'import { useDatasetDetailContextWithSelector } from '@/context/dataset-detail'import { useDatasetApiBaseUrl } from '@/service/knowledge/use-dataset'import ServiceApi from './service-api'diff --git a/web/app/components/datasets/extra-info/service-api/card.tsx b/web/app/components/datasets/extra-info/service-api/card.tsxindex 0452ee4da1e..e5de8f66a5f 100644--- a/web/app/components/datasets/extra-info/service-api/card.tsx+++ b/web/app/components/datasets/extra-info/service-api/card.tsx@@ -1,6 +1,7 @@import { RiBookOpenLine, RiKey2Line } from '@remixicon/react'import Link from 'next/link'-import React, { useCallback, useState } from 'react'+import * as React from 'react'+import { useCallback, useState } from 'react'import { useTranslation } from 'react-i18next'import Button from '@/app/components/base/button'import CopyFeedback from '@/app/components/base/copy-feedback'diff --git a/web/app/components/datasets/extra-info/service-api/index.tsx b/web/app/components/datasets/extra-info/service-api/index.tsxindex c653f2cc70c..e8a0fbcb5af 100644--- a/web/app/components/datasets/extra-info/service-api/index.tsx+++ b/web/app/components/datasets/extra-info/service-api/index.tsx@@ -1,4 +1,5 @@-import React, { useState } from 'react'+import * as React from 'react'+import { useState } from 'react'import { useTranslation } from 'react-i18next'import { ApiAggregate } from '@/app/components/base/icons/src/vender/knowledge'import { PortalToFollowElem, PortalToFollowElemContent, PortalToFollowElemTrigger } from '@/app/components/base/portal-to-follow-elem'diff --git a/web/app/components/datasets/extra-info/statistics.tsx b/web/app/components/datasets/extra-info/statistics.tsxindex c867bade839..4982fffcb05 100644--- a/web/app/components/datasets/extra-info/statistics.tsx+++ b/web/app/components/datasets/extra-info/statistics.tsx@@ -1,6 +1,6 @@import type { RelatedAppResponse } from '@/models/datasets'import { RiInformation2Line } from '@remixicon/react'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import Divider from '@/app/components/base/divider'import LinkedAppsPanel from '@/app/components/base/linked-apps-panel'diff --git a/web/app/components/datasets/hit-testing/components/child-chunks-item.tsx b/web/app/components/datasets/hit-testing/components/child-chunks-item.tsxindex 680e8481850..bca73994bd2 100644--- a/web/app/components/datasets/hit-testing/components/child-chunks-item.tsx+++ b/web/app/components/datasets/hit-testing/components/child-chunks-item.tsx@@ -1,7 +1,7 @@'use client'import type { FC } from 'react'import type { HitTestingChildChunk } from '@/models/datasets'-import React from 'react'+import * as React from 'react'import { SliceContent } from '../../formatted-text/flavours/shared'import Score from './score'diff --git a/web/app/components/datasets/hit-testing/components/chunk-detail-modal.tsx b/web/app/components/datasets/hit-testing/components/chunk-detail-modal.tsxindex b7468ee08c9..942fe46ffb6 100644--- a/web/app/components/datasets/hit-testing/components/chunk-detail-modal.tsx+++ b/web/app/components/datasets/hit-testing/components/chunk-detail-modal.tsx@@ -1,7 +1,8 @@'use client'import type { FileAppearanceTypeEnum } from '@/app/components/base/file-uploader/types'import type { HitTesting } from '@/models/datasets'-import React, { useMemo } from 'react'+import * as React from 'react'+import { useMemo } from 'react'import { useTranslation } from 'react-i18next'import FileIcon from '@/app/components/base/file-uploader/file-type-icon'import { Markdown } from '@/app/components/base/markdown'diff --git a/web/app/components/datasets/hit-testing/components/empty-records.tsx b/web/app/components/datasets/hit-testing/components/empty-records.tsxindex 1a93439e732..dccc1f3f192 100644--- a/web/app/components/datasets/hit-testing/components/empty-records.tsx+++ b/web/app/components/datasets/hit-testing/components/empty-records.tsx@@ -1,5 +1,5 @@import { RiHistoryLine } from '@remixicon/react'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'const EmptyRecords = () => {diff --git a/web/app/components/datasets/hit-testing/components/mask.tsx b/web/app/components/datasets/hit-testing/components/mask.tsxindex 0bf329a3ff5..703644bf9da 100644--- a/web/app/components/datasets/hit-testing/components/mask.tsx+++ b/web/app/components/datasets/hit-testing/components/mask.tsx@@ -1,4 +1,4 @@-import React from 'react'+import * as React from 'react'import { cn } from '@/utils/classnames'type MaskProps = {diff --git a/web/app/components/datasets/hit-testing/components/query-input/index.tsx b/web/app/components/datasets/hit-testing/components/query-input/index.tsxindex abaed302c87..959e7f3425f 100644--- a/web/app/components/datasets/hit-testing/components/query-input/index.tsx+++ b/web/app/components/datasets/hit-testing/components/query-input/index.tsx@@ -15,7 +15,8 @@ import {RiPlayCircleLine,} from '@remixicon/react'import Image from 'next/image'-import React, { useCallback, useMemo, useState } from 'react'+import * as React from 'react'+import { useCallback, useMemo, useState } from 'react'import { useTranslation } from 'react-i18next'import { v4 as uuid4 } from 'uuid'import Button from '@/app/components/base/button'diff --git a/web/app/components/datasets/hit-testing/components/query-input/textarea.tsx b/web/app/components/datasets/hit-testing/components/query-input/textarea.tsxindex a3478d5deb5..c74bdd44925 100644--- a/web/app/components/datasets/hit-testing/components/query-input/textarea.tsx+++ b/web/app/components/datasets/hit-testing/components/query-input/textarea.tsx@@ -1,5 +1,5 @@import type { ChangeEvent } from 'react'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import { Corner } from '@/app/components/base/icons/src/vender/solid/shapes'import Tooltip from '@/app/components/base/tooltip'diff --git a/web/app/components/datasets/hit-testing/components/records.tsx b/web/app/components/datasets/hit-testing/components/records.tsxindex 37eea71625f..5de5391cc06 100644--- a/web/app/components/datasets/hit-testing/components/records.tsx+++ b/web/app/components/datasets/hit-testing/components/records.tsx@@ -1,6 +1,7 @@import type { Attachment, HitTestingRecord, Query } from '@/models/datasets'import { RiApps2Line, RiArrowDownLine, RiFocus2Line } from '@remixicon/react'-import React, { useCallback, useMemo, useState } from 'react'+import * as React from 'react'+import { useCallback, useMemo, useState } from 'react'import { useTranslation } from 'react-i18next'import useTimestamp from '@/hooks/use-timestamp'import { cn } from '@/utils/classnames'diff --git a/web/app/components/datasets/hit-testing/components/result-item-external.tsx b/web/app/components/datasets/hit-testing/components/result-item-external.tsxindex 43d07099941..d4a6f2b0022 100644--- a/web/app/components/datasets/hit-testing/components/result-item-external.tsx+++ b/web/app/components/datasets/hit-testing/components/result-item-external.tsx@@ -2,7 +2,7 @@import type { FC } from 'react'import type { ExternalKnowledgeBaseHitTesting } from '@/models/datasets'import { useBoolean } from 'ahooks'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import { FileAppearanceTypeEnum } from '@/app/components/base/file-uploader/types'import Modal from '@/app/components/base/modal'diff --git a/web/app/components/datasets/hit-testing/components/result-item-footer.tsx b/web/app/components/datasets/hit-testing/components/result-item-footer.tsxindex ad2d07d98e0..1c62828cf3a 100644--- a/web/app/components/datasets/hit-testing/components/result-item-footer.tsx+++ b/web/app/components/datasets/hit-testing/components/result-item-footer.tsx@@ -2,7 +2,7 @@import type { FC } from 'react'import type { FileAppearanceTypeEnum } from '@/app/components/base/file-uploader/types'import { RiArrowRightUpLine } from '@remixicon/react'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import FileIcon from '@/app/components/base/file-uploader/file-type-icon'diff --git a/web/app/components/datasets/hit-testing/components/result-item-meta.tsx b/web/app/components/datasets/hit-testing/components/result-item-meta.tsxindex 558333a103b..6277d9af8ec 100644--- a/web/app/components/datasets/hit-testing/components/result-item-meta.tsx+++ b/web/app/components/datasets/hit-testing/components/result-item-meta.tsx@@ -1,6 +1,6 @@'use client'import type { FC } from 'react'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import { cn } from '@/utils/classnames'import Dot from '../../documents/detail/completed/common/dot'diff --git a/web/app/components/datasets/hit-testing/components/result-item.tsx b/web/app/components/datasets/hit-testing/components/result-item.tsxindex 65ea47f3487..0df8c6d5607 100644--- a/web/app/components/datasets/hit-testing/components/result-item.tsx+++ b/web/app/components/datasets/hit-testing/components/result-item.tsx@@ -3,7 +3,8 @@ import type { FileAppearanceTypeEnum } from '@/app/components/base/file-uploaderimport type { HitTesting } from '@/models/datasets'import { RiArrowDownSLine, RiArrowRightSLine } from '@remixicon/react'import { useBoolean } from 'ahooks'-import React, { useMemo } from 'react'+import * as React from 'react'+import { useMemo } from 'react'import { useTranslation } from 'react-i18next'import { Markdown } from '@/app/components/base/markdown'import Tag from '@/app/components/datasets/documents/detail/completed/common/tag'diff --git a/web/app/components/datasets/hit-testing/components/score.tsx b/web/app/components/datasets/hit-testing/components/score.tsxindex 20113a403e3..ed5496740d5 100644--- a/web/app/components/datasets/hit-testing/components/score.tsx+++ b/web/app/components/datasets/hit-testing/components/score.tsx@@ -1,6 +1,6 @@'use client'import type { FC } from 'react'-import React from 'react'+import * as React from 'react'import { cn } from '@/utils/classnames'type Props = {diff --git a/web/app/components/datasets/hit-testing/index.tsx b/web/app/components/datasets/hit-testing/index.tsxindex 2ae5e303e2e..e75ef48abf5 100644--- a/web/app/components/datasets/hit-testing/index.tsx+++ b/web/app/components/datasets/hit-testing/index.tsx@@ -10,7 +10,8 @@ import type {} from '@/models/datasets'import type { RetrievalConfig } from '@/types/app'import { useBoolean } from 'ahooks'-import React, { useCallback, useEffect, useState } from 'react'+import * as React from 'react'+import { useCallback, useEffect, useState } from 'react'import { useTranslation } from 'react-i18next'import { useContext } from 'use-context-selector'import Drawer from '@/app/components/base/drawer'diff --git a/web/app/components/datasets/hit-testing/modify-retrieval-modal.tsx b/web/app/components/datasets/hit-testing/modify-retrieval-modal.tsxindex 801b62340ce..7c7d4c4da28 100644--- a/web/app/components/datasets/hit-testing/modify-retrieval-modal.tsx+++ b/web/app/components/datasets/hit-testing/modify-retrieval-modal.tsx@@ -3,7 +3,8 @@ import type { FC } from 'react'import type { IndexingType } from '../create/step-two'import type { RetrievalConfig } from '@/types/app'import { RiCloseLine } from '@remixicon/react'-import React, { useMemo, useRef, useState } from 'react'+import * as React from 'react'+import { useMemo, useRef, useState } from 'react'import { useTranslation } from 'react-i18next'import Button from '@/app/components/base/button'import { isReRankModelSelected } from '@/app/components/datasets/common/check-rerank-model'diff --git a/web/app/components/datasets/list/dataset-card/index.tsx b/web/app/components/datasets/list/dataset-card/index.tsxindex 4da265b43c4..8087b80fda5 100644--- a/web/app/components/datasets/list/dataset-card/index.tsx+++ b/web/app/components/datasets/list/dataset-card/index.tsx@@ -4,7 +4,8 @@ import type { DataSet } from '@/models/datasets'import { RiFileTextFill, RiMoreFill, RiRobot2Fill } from '@remixicon/react'import { useHover } from 'ahooks'import { useRouter } from 'next/navigation'-import React, { useCallback, useEffect, useMemo, useRef, useState } from 'react'+import * as React from 'react'+import { useCallback, useEffect, useMemo, useRef, useState } from 'react'import { useTranslation } from 'react-i18next'import AppIcon from '@/app/components/base/app-icon'import Confirm from '@/app/components/base/confirm'diff --git a/web/app/components/datasets/list/dataset-card/operation-item.tsx b/web/app/components/datasets/list/dataset-card/operation-item.tsxindex c5c11afe451..afa0f174e8f 100644--- a/web/app/components/datasets/list/dataset-card/operation-item.tsx+++ b/web/app/components/datasets/list/dataset-card/operation-item.tsx@@ -1,5 +1,5 @@import type { RemixiconComponentType } from '@remixicon/react'-import React from 'react'+import * as React from 'react'type OperationItemProps = {Icon: RemixiconComponentTypediff --git a/web/app/components/datasets/list/dataset-card/operations.tsx b/web/app/components/datasets/list/dataset-card/operations.tsxindex e6ecbf76b90..d83ed1d396c 100644--- a/web/app/components/datasets/list/dataset-card/operations.tsx+++ b/web/app/components/datasets/list/dataset-card/operations.tsx@@ -1,5 +1,5 @@import { RiDeleteBinLine, RiEditLine, RiFileDownloadLine } from '@remixicon/react'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import Divider from '@/app/components/base/divider'import OperationItem from './operation-item'diff --git a/web/app/components/datasets/list/dataset-footer/index.tsx b/web/app/components/datasets/list/dataset-footer/index.tsxindex 425ca0df266..233fd26456e 100644--- a/web/app/components/datasets/list/dataset-footer/index.tsx+++ b/web/app/components/datasets/list/dataset-footer/index.tsx@@ -1,6 +1,6 @@'use client'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'const DatasetFooter = () => {diff --git a/web/app/components/datasets/list/new-dataset-card/index.tsx b/web/app/components/datasets/list/new-dataset-card/index.tsxindex edc05e9919b..0f8aa525863 100644--- a/web/app/components/datasets/list/new-dataset-card/index.tsx+++ b/web/app/components/datasets/list/new-dataset-card/index.tsx@@ -3,7 +3,7 @@ import {RiAddLine,RiFunctionAddLine,} from '@remixicon/react'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import { ApiConnectionMod } from '@/app/components/base/icons/src/vender/solid/development'import Option from './option'diff --git a/web/app/components/datasets/list/new-dataset-card/option.tsx b/web/app/components/datasets/list/new-dataset-card/option.tsxindex 97a9e88b16c..e862b5c11e8 100644--- a/web/app/components/datasets/list/new-dataset-card/option.tsx+++ b/web/app/components/datasets/list/new-dataset-card/option.tsx@@ -1,5 +1,5 @@import Link from 'next/link'-import React from 'react'+import * as React from 'react'type OptionProps = {Icon: React.ComponentType<{ className?: string }>diff --git a/web/app/components/datasets/metadata/add-metadata-button.tsx b/web/app/components/datasets/metadata/add-metadata-button.tsxindex 3908c8935e3..4bb28e0b320 100644--- a/web/app/components/datasets/metadata/add-metadata-button.tsx+++ b/web/app/components/datasets/metadata/add-metadata-button.tsx@@ -1,7 +1,7 @@'use client'import type { FC } from 'react'import { RiAddLine } from '@remixicon/react'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import { cn } from '@/utils/classnames'import Button from '../../base/button'diff --git a/web/app/components/datasets/metadata/edit-metadata-batch/add-row.tsx b/web/app/components/datasets/metadata/edit-metadata-batch/add-row.tsxindex f3a05fb22d1..20fad9769ad 100644--- a/web/app/components/datasets/metadata/edit-metadata-batch/add-row.tsx+++ b/web/app/components/datasets/metadata/edit-metadata-batch/add-row.tsx@@ -2,7 +2,7 @@import type { FC } from 'react'import type { MetadataItemWithEdit } from '../types'import { RiIndeterminateCircleLine } from '@remixicon/react'-import React from 'react'+import * as React from 'react'import { cn } from '@/utils/classnames'import InputCombined from './input-combined'import Label from './label'diff --git a/web/app/components/datasets/metadata/edit-metadata-batch/edit-row.tsx b/web/app/components/datasets/metadata/edit-metadata-batch/edit-row.tsxindex 907ff127fba..1fdf8c2ef74 100644--- a/web/app/components/datasets/metadata/edit-metadata-batch/edit-row.tsx+++ b/web/app/components/datasets/metadata/edit-metadata-batch/edit-row.tsx@@ -2,7 +2,7 @@import type { FC } from 'react'import type { MetadataItemWithEdit } from '../types'import { RiDeleteBinLine } from '@remixicon/react'-import React from 'react'+import * as React from 'react'import { cn } from '@/utils/classnames'import { UpdateType } from '../types'import EditedBeacon from './edited-beacon'diff --git a/web/app/components/datasets/metadata/edit-metadata-batch/edited-beacon.tsx b/web/app/components/datasets/metadata/edit-metadata-batch/edited-beacon.tsxindex 34f4e43a33b..b6b8c2a7d0c 100644--- a/web/app/components/datasets/metadata/edit-metadata-batch/edited-beacon.tsx+++ b/web/app/components/datasets/metadata/edit-metadata-batch/edited-beacon.tsx@@ -2,7 +2,8 @@import type { FC } from 'react'import { RiResetLeftLine } from '@remixicon/react'import { useHover } from 'ahooks'-import React, { useRef } from 'react'+import * as React from 'react'+import { useRef } from 'react'import { useTranslation } from 'react-i18next'import Tooltip from '@/app/components/base/tooltip'diff --git a/web/app/components/datasets/metadata/edit-metadata-batch/input-combined.tsx b/web/app/components/datasets/metadata/edit-metadata-batch/input-combined.tsxindex 51dd81b1faf..aec74bcfefb 100644--- a/web/app/components/datasets/metadata/edit-metadata-batch/input-combined.tsx+++ b/web/app/components/datasets/metadata/edit-metadata-batch/input-combined.tsx@@ -1,6 +1,6 @@'use client'import type { FC } from 'react'-import React from 'react'+import * as React from 'react'import Input from '@/app/components/base/input'import { InputNumber } from '@/app/components/base/input-number'import { cn } from '@/utils/classnames'diff --git a/web/app/components/datasets/metadata/edit-metadata-batch/input-has-set-multiple-value.tsx b/web/app/components/datasets/metadata/edit-metadata-batch/input-has-set-multiple-value.tsxindex 412ef419e90..cf475898d3b 100644--- a/web/app/components/datasets/metadata/edit-metadata-batch/input-has-set-multiple-value.tsx+++ b/web/app/components/datasets/metadata/edit-metadata-batch/input-has-set-multiple-value.tsx@@ -1,7 +1,7 @@'use client'import type { FC } from 'react'import { RiCloseLine } from '@remixicon/react'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import { cn } from '@/utils/classnames'diff --git a/web/app/components/datasets/metadata/edit-metadata-batch/label.tsx b/web/app/components/datasets/metadata/edit-metadata-batch/label.tsxindex 009b61f0b8b..08f886be183 100644--- a/web/app/components/datasets/metadata/edit-metadata-batch/label.tsx+++ b/web/app/components/datasets/metadata/edit-metadata-batch/label.tsx@@ -1,6 +1,6 @@'use client'import type { FC } from 'react'-import React from 'react'+import * as React from 'react'import { cn } from '@/utils/classnames'type Props = {diff --git a/web/app/components/datasets/metadata/edit-metadata-batch/modal.tsx b/web/app/components/datasets/metadata/edit-metadata-batch/modal.tsxindex 8cec39b1d24..253d271a960 100644--- a/web/app/components/datasets/metadata/edit-metadata-batch/modal.tsx+++ b/web/app/components/datasets/metadata/edit-metadata-batch/modal.tsx@@ -3,7 +3,8 @@ import type { FC } from 'react'import type { BuiltInMetadataItem, MetadataItemInBatchEdit, MetadataItemWithEdit } from '../types'import { RiQuestionLine } from '@remixicon/react'import { produce } from 'immer'-import React, { useCallback, useState } from 'react'+import * as React from 'react'+import { useCallback, useState } from 'react'import { useTranslation } from 'react-i18next'import Divider from '@/app/components/base/divider'import Toast from '@/app/components/base/toast'diff --git a/web/app/components/datasets/metadata/metadata-dataset/create-content.tsx b/web/app/components/datasets/metadata/metadata-dataset/create-content.tsxindex f2eba083fb6..d31e9d79576 100644--- a/web/app/components/datasets/metadata/metadata-dataset/create-content.tsx+++ b/web/app/components/datasets/metadata/metadata-dataset/create-content.tsx@@ -2,7 +2,8 @@import type { FC } from 'react'import { RiArrowLeftLine } from '@remixicon/react'import { noop } from 'lodash-es'-import React, { useCallback, useState } from 'react'+import * as React from 'react'+import { useCallback, useState } from 'react'import { useTranslation } from 'react-i18next'import Input from '@/app/components/base/input'import ModalLikeWrap from '../../../base/modal-like-wrap'diff --git a/web/app/components/datasets/metadata/metadata-dataset/create-metadata-modal.tsx b/web/app/components/datasets/metadata/metadata-dataset/create-metadata-modal.tsxindex 9ee326fd532..713804a5413 100644--- a/web/app/components/datasets/metadata/metadata-dataset/create-metadata-modal.tsx+++ b/web/app/components/datasets/metadata/metadata-dataset/create-metadata-modal.tsx@@ -1,7 +1,7 @@'use client'import type { FC } from 'react'import type { Props as CreateContentProps } from './create-content'-import React from 'react'+import * as React from 'react'import { PortalToFollowElem, PortalToFollowElemContent, PortalToFollowElemTrigger } from '../../../base/portal-to-follow-elem'import CreateContent from './create-content'diff --git a/web/app/components/datasets/metadata/metadata-dataset/dataset-metadata-drawer.tsx b/web/app/components/datasets/metadata/metadata-dataset/dataset-metadata-drawer.tsxindex bfdda3dd65e..f94e6e136f1 100644--- a/web/app/components/datasets/metadata/metadata-dataset/dataset-metadata-drawer.tsx+++ b/web/app/components/datasets/metadata/metadata-dataset/dataset-metadata-drawer.tsx@@ -3,7 +3,8 @@ import type { FC } from 'react'import type { BuiltInMetadataItem, MetadataItemWithValueLength } from '../types'import { RiAddLine, RiDeleteBinLine, RiEditLine } from '@remixicon/react'import { useBoolean, useHover } from 'ahooks'-import React, { useCallback, useRef, useState } from 'react'+import * as React from 'react'+import { useCallback, useRef, useState } from 'react'import { useTranslation } from 'react-i18next'import Button from '@/app/components/base/button'import Confirm from '@/app/components/base/confirm'diff --git a/web/app/components/datasets/metadata/metadata-dataset/field.tsx b/web/app/components/datasets/metadata/metadata-dataset/field.tsxindex 8fb57bac34e..4e8e3e02d82 100644--- a/web/app/components/datasets/metadata/metadata-dataset/field.tsx+++ b/web/app/components/datasets/metadata/metadata-dataset/field.tsx@@ -1,6 +1,6 @@'use client'import type { FC } from 'react'-import React from 'react'+import * as React from 'react'type Props = {className?: stringdiff --git a/web/app/components/datasets/metadata/metadata-dataset/select-metadata-modal.tsx b/web/app/components/datasets/metadata/metadata-dataset/select-metadata-modal.tsxindex be0fbe9fab9..eb7189a4cd2 100644--- a/web/app/components/datasets/metadata/metadata-dataset/select-metadata-modal.tsx+++ b/web/app/components/datasets/metadata/metadata-dataset/select-metadata-modal.tsx@@ -3,7 +3,8 @@ import type { Placement } from '@floating-ui/react'import type { FC } from 'react'import type { MetadataItem } from '../types'import type { Props as CreateContentProps } from './create-content'-import React, { useCallback, useState } from 'react'+import * as React from 'react'+import { useCallback, useState } from 'react'import { useDatasetMetaData } from '@/service/knowledge/use-metadata'import { PortalToFollowElem, PortalToFollowElemContent, PortalToFollowElemTrigger } from '../../../base/portal-to-follow-elem'import CreateContent from './create-content'diff --git a/web/app/components/datasets/metadata/metadata-dataset/select-metadata.tsx b/web/app/components/datasets/metadata/metadata-dataset/select-metadata.tsxindex 3540939205e..0422c7a51a2 100644--- a/web/app/components/datasets/metadata/metadata-dataset/select-metadata.tsx+++ b/web/app/components/datasets/metadata/metadata-dataset/select-metadata.tsx@@ -2,7 +2,8 @@import type { FC } from 'react'import type { MetadataItem } from '../types'import { RiAddLine, RiArrowRightUpLine } from '@remixicon/react'-import React, { useMemo, useState } from 'react'+import * as React from 'react'+import { useMemo, useState } from 'react'import { useTranslation } from 'react-i18next'import SearchInput from '@/app/components/base/search-input'import { getIcon } from '../utils/get-icon'diff --git a/web/app/components/datasets/metadata/metadata-document/field.tsx b/web/app/components/datasets/metadata/metadata-document/field.tsxindex 46c7598d5dc..f6f5fdf8f1f 100644--- a/web/app/components/datasets/metadata/metadata-document/field.tsx+++ b/web/app/components/datasets/metadata/metadata-document/field.tsx@@ -1,6 +1,6 @@'use client'import type { FC } from 'react'-import React from 'react'+import * as React from 'react'type Props = {label: stringdiff --git a/web/app/components/datasets/metadata/metadata-document/index.tsx b/web/app/components/datasets/metadata/metadata-document/index.tsxindex beb88a8b821..4e8c9314171 100644--- a/web/app/components/datasets/metadata/metadata-document/index.tsx+++ b/web/app/components/datasets/metadata/metadata-document/index.tsx@@ -2,7 +2,7 @@import type { FC } from 'react'import type { FullDocumentDetail } from '@/models/datasets'import { RiEditLine } from '@remixicon/react'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import Button from '@/app/components/base/button'import Divider from '@/app/components/base/divider'diff --git a/web/app/components/datasets/metadata/metadata-document/info-group.tsx b/web/app/components/datasets/metadata/metadata-document/info-group.tsxindex afa490c344a..5137859bed7 100644--- a/web/app/components/datasets/metadata/metadata-document/info-group.tsx+++ b/web/app/components/datasets/metadata/metadata-document/info-group.tsx@@ -3,7 +3,7 @@ import type { FC } from 'react'import type { MetadataItemWithValue } from '../types'import { RiDeleteBinLine, RiQuestionLine } from '@remixicon/react'import { useRouter } from 'next/navigation'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import Divider from '@/app/components/base/divider'import Tooltip from '@/app/components/base/tooltip'diff --git a/web/app/components/datasets/metadata/metadata-document/no-data.tsx b/web/app/components/datasets/metadata/metadata-document/no-data.tsxindex e52f69b5902..81021ea51bb 100644--- a/web/app/components/datasets/metadata/metadata-document/no-data.tsx+++ b/web/app/components/datasets/metadata/metadata-document/no-data.tsx@@ -1,7 +1,7 @@'use client'import type { FC } from 'react'import { RiArrowRightLine } from '@remixicon/react'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import Button from '@/app/components/base/button'diff --git a/web/app/components/datasets/no-linked-apps-panel.tsx b/web/app/components/datasets/no-linked-apps-panel.tsxindex 5ab9689a127..b0a49abcdbe 100644--- a/web/app/components/datasets/no-linked-apps-panel.tsx+++ b/web/app/components/datasets/no-linked-apps-panel.tsx@@ -1,5 +1,5 @@import { RiApps2AddLine, RiBookOpenLine } from '@remixicon/react'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import { useDocLink } from '@/context/i18n'diff --git a/web/app/components/datasets/settings/chunk-structure/index.tsx b/web/app/components/datasets/settings/chunk-structure/index.tsxindex 2b9073672ec..977620c4c1c 100644--- a/web/app/components/datasets/settings/chunk-structure/index.tsx+++ b/web/app/components/datasets/settings/chunk-structure/index.tsx@@ -1,5 +1,5 @@import type { ChunkingMode } from '@/models/datasets'-import React from 'react'+import * as React from 'react'import OptionCard from '../option-card'import { useChunkStructure } from './hooks'diff --git a/web/app/components/datasets/settings/index-method/keyword-number.tsx b/web/app/components/datasets/settings/index-method/keyword-number.tsxindex c754c2a48c5..994d98f14a4 100644--- a/web/app/components/datasets/settings/index-method/keyword-number.tsx+++ b/web/app/components/datasets/settings/index-method/keyword-number.tsx@@ -1,5 +1,6 @@import { RiQuestionLine } from '@remixicon/react'-import React, { useCallback } from 'react'+import * as React from 'react'+import { useCallback } from 'react'import { useTranslation } from 'react-i18next'import { InputNumber } from '@/app/components/base/input-number'import Slider from '@/app/components/base/slider'diff --git a/web/app/components/datasets/settings/option-card.tsx b/web/app/components/datasets/settings/option-card.tsxindex 8aa255746fc..d17542935b4 100644--- a/web/app/components/datasets/settings/option-card.tsx+++ b/web/app/components/datasets/settings/option-card.tsx@@ -1,5 +1,5 @@import type { ReactNode } from 'react'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import Badge from '@/app/components/base/badge'import { cn } from '@/utils/classnames'diff --git a/web/app/components/datasets/settings/permission-selector/index.tsx b/web/app/components/datasets/settings/permission-selector/index.tsxindex 85c69a46a6d..ffbc3e4a1c7 100644--- a/web/app/components/datasets/settings/permission-selector/index.tsx+++ b/web/app/components/datasets/settings/permission-selector/index.tsx@@ -1,7 +1,8 @@import type { Member } from '@/models/common'import { RiArrowDownSLine, RiGroup2Line, RiLock2Line } from '@remixicon/react'import { useDebounceFn } from 'ahooks'-import React, { useCallback, useMemo, useState } from 'react'+import * as React from 'react'+import { useCallback, useMemo, useState } from 'react'import { useTranslation } from 'react-i18next'import Avatar from '@/app/components/base/avatar'import Input from '@/app/components/base/input'diff --git a/web/app/components/datasets/settings/permission-selector/member-item.tsx b/web/app/components/datasets/settings/permission-selector/member-item.tsxindex f70faa35532..9c1c3da70cd 100644--- a/web/app/components/datasets/settings/permission-selector/member-item.tsx+++ b/web/app/components/datasets/settings/permission-selector/member-item.tsx@@ -1,5 +1,5 @@import { RiCheckLine } from '@remixicon/react'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import { cn } from '@/utils/classnames'diff --git a/web/app/components/datasets/settings/permission-selector/permission-item.tsx b/web/app/components/datasets/settings/permission-selector/permission-item.tsxindex f926e8287c3..c5847896f78 100644--- a/web/app/components/datasets/settings/permission-selector/permission-item.tsx+++ b/web/app/components/datasets/settings/permission-selector/permission-item.tsx@@ -1,5 +1,5 @@import { RiCheckLine } from '@remixicon/react'-import React from 'react'+import * as React from 'react'type PermissionItemProps = {leftIcon: React.ReactNodediff --git a/web/app/components/develop/secret-key/input-copy.tsx b/web/app/components/develop/secret-key/input-copy.tsxindex af7edea3c58..8f12d579bc7 100644--- a/web/app/components/develop/secret-key/input-copy.tsx+++ b/web/app/components/develop/secret-key/input-copy.tsx@@ -1,7 +1,8 @@'use client'import copy from 'copy-to-clipboard'import { t } from 'i18next'-import React, { useEffect, useState } from 'react'+import * as React from 'react'+import { useEffect, useState } from 'react'import CopyFeedback from '@/app/components/base/copy-feedback'import Tooltip from '@/app/components/base/tooltip'diff --git a/web/app/components/explore/app-card/index.spec.tsx b/web/app/components/explore/app-card/index.spec.tsxindex 6247e8adc7a..769b317929d 100644--- a/web/app/components/explore/app-card/index.spec.tsx+++ b/web/app/components/explore/app-card/index.spec.tsx@@ -1,7 +1,7 @@import type { AppCardProps } from './index'import type { App } from '@/models/explore'import { fireEvent, render, screen } from '@testing-library/react'-import React from 'react'+import * as React from 'react'import { AppModeEnum } from '@/types/app'import AppCard from './index'diff --git a/web/app/components/explore/app-list/index.tsx b/web/app/components/explore/app-list/index.tsxindex 859a4c081db..585c4e60c14 100644--- a/web/app/components/explore/app-list/index.tsx+++ b/web/app/components/explore/app-list/index.tsx@@ -3,7 +3,8 @@import type { CreateAppModalProps } from '@/app/components/explore/create-app-modal'import type { App } from '@/models/explore'import { useDebounceFn } from 'ahooks'-import React, { useCallback, useMemo, useState } from 'react'+import * as React from 'react'+import { useCallback, useMemo, useState } from 'react'import { useTranslation } from 'react-i18next'import useSWR from 'swr'import { useContext } from 'use-context-selector'diff --git a/web/app/components/explore/category.tsx b/web/app/components/explore/category.tsxindex 6d44c9f46b4..eba883d8498 100644--- a/web/app/components/explore/category.tsx+++ b/web/app/components/explore/category.tsx@@ -1,7 +1,7 @@'use client'import type { FC } from 'react'import type { AppCategory } from '@/models/explore'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import { ThumbsUp } from '@/app/components/base/icons/src/vender/line/alertsAndFeedback'import exploreI18n from '@/i18n/en-US/explore'diff --git a/web/app/components/explore/create-app-modal/index.spec.tsx b/web/app/components/explore/create-app-modal/index.spec.tsxindex 55ee7f9064d..6bc1e1e9a06 100644--- a/web/app/components/explore/create-app-modal/index.spec.tsx+++ b/web/app/components/explore/create-app-modal/index.spec.tsx@@ -1,7 +1,7 @@import type { CreateAppModalProps } from './index'import type { UsagePlanInfo } from '@/app/components/billing/type'import { act, fireEvent, render, screen } from '@testing-library/react'-import React from 'react'+import * as React from 'react'import { createMockPlan, createMockPlanTotal, createMockPlanUsage } from '@/__mocks__/provider-context'import { Plan } from '@/app/components/billing/type'import { AppModeEnum } from '@/types/app'diff --git a/web/app/components/explore/create-app-modal/index.tsx b/web/app/components/explore/create-app-modal/index.tsxindex ccd1280201d..dac89bc776e 100644--- a/web/app/components/explore/create-app-modal/index.tsx+++ b/web/app/components/explore/create-app-modal/index.tsx@@ -3,7 +3,8 @@ import type { AppIconType } from '@/types/app'import { RiCloseLine, RiCommandLine, RiCornerDownLeftLine } from '@remixicon/react'import { useDebounceFn, useKeyPress } from 'ahooks'import { noop } from 'lodash-es'-import React, { useCallback, useState } from 'react'+import * as React from 'react'+import { useCallback, useState } from 'react'import { useTranslation } from 'react-i18next'import AppIcon from '@/app/components/base/app-icon'import Button from '@/app/components/base/button'diff --git a/web/app/components/explore/index.tsx b/web/app/components/explore/index.tsxindex d9919e90d92..a405fe0d28f 100644--- a/web/app/components/explore/index.tsx+++ b/web/app/components/explore/index.tsx@@ -2,7 +2,8 @@import type { FC } from 'react'import type { InstalledApp } from '@/models/explore'import { useRouter } from 'next/navigation'-import React, { useEffect, useState } from 'react'+import * as React from 'react'+import { useEffect, useState } from 'react'import { useTranslation } from 'react-i18next'import Sidebar from '@/app/components/explore/sidebar'import { useAppContext } from '@/context/app-context'diff --git a/web/app/components/explore/installed-app/index.tsx b/web/app/components/explore/installed-app/index.tsxindex cd8bc468fb5..def66c02609 100644--- a/web/app/components/explore/installed-app/index.tsx+++ b/web/app/components/explore/installed-app/index.tsx@@ -1,7 +1,8 @@'use client'import type { FC } from 'react'import type { AppData } from '@/models/share'-import React, { useEffect } from 'react'+import * as React from 'react'+import { useEffect } from 'react'import { useContext } from 'use-context-selector'import ChatWithHistory from '@/app/components/base/chat/chat-with-history'import Loading from '@/app/components/base/loading'diff --git a/web/app/components/explore/item-operation/index.tsx b/web/app/components/explore/item-operation/index.tsxindex bc145a633af..3703c0d4c09 100644--- a/web/app/components/explore/item-operation/index.tsx+++ b/web/app/components/explore/item-operation/index.tsx@@ -5,7 +5,8 @@ import {RiEditLine,} from '@remixicon/react'import { useBoolean } from 'ahooks'-import React, { useEffect, useRef, useState } from 'react'+import * as React from 'react'+import { useEffect, useRef, useState } from 'react'import { useTranslation } from 'react-i18next'import { PortalToFollowElem, PortalToFollowElemContent, PortalToFollowElemTrigger } from '@/app/components/base/portal-to-follow-elem'diff --git a/web/app/components/explore/sidebar/app-nav-item/index.tsx b/web/app/components/explore/sidebar/app-nav-item/index.tsxindex 37163de42ae..3347efeb3f5 100644--- a/web/app/components/explore/sidebar/app-nav-item/index.tsx+++ b/web/app/components/explore/sidebar/app-nav-item/index.tsx@@ -3,7 +3,8 @@ import type { AppIconType } from '@/types/app'import { useHover } from 'ahooks'import { useRouter } from 'next/navigation'-import React, { useRef } from 'react'+import * as React from 'react'+import { useRef } from 'react'import AppIcon from '@/app/components/base/app-icon'import ItemOperation from '@/app/components/explore/item-operation'import { cn } from '@/utils/classnames'diff --git a/web/app/components/explore/sidebar/index.tsx b/web/app/components/explore/sidebar/index.tsxindex d178e65cbec..2d370ef1533 100644--- a/web/app/components/explore/sidebar/index.tsx+++ b/web/app/components/explore/sidebar/index.tsx@@ -2,7 +2,8 @@import type { FC } from 'react'import Link from 'next/link'import { useSelectedLayoutSegments } from 'next/navigation'-import React, { useEffect, useState } from 'react'+import * as React from 'react'+import { useEffect, useState } from 'react'import { useTranslation } from 'react-i18next'import { useContext } from 'use-context-selector'import Confirm from '@/app/components/base/confirm'diff --git a/web/app/components/goto-anything/actions/commands/account.tsx b/web/app/components/goto-anything/actions/commands/account.tsxindex 82fc24ccb9f..82025191b1d 100644--- a/web/app/components/goto-anything/actions/commands/account.tsx+++ b/web/app/components/goto-anything/actions/commands/account.tsx@@ -1,6 +1,6 @@import type { SlashCommandHandler } from './types'import { RiUser3Line } from '@remixicon/react'-import React from 'react'+import * as React from 'react'import i18n from '@/i18n-config/i18next-config'import { registerCommands, unregisterCommands } from './command-bus'diff --git a/web/app/components/goto-anything/actions/commands/community.tsx b/web/app/components/goto-anything/actions/commands/community.tsxindex 3327c44c206..95ca9f89f3a 100644--- a/web/app/components/goto-anything/actions/commands/community.tsx+++ b/web/app/components/goto-anything/actions/commands/community.tsx@@ -1,6 +1,6 @@import type { SlashCommandHandler } from './types'import { RiDiscordLine } from '@remixicon/react'-import React from 'react'+import * as React from 'react'import i18n from '@/i18n-config/i18next-config'import { registerCommands, unregisterCommands } from './command-bus'diff --git a/web/app/components/goto-anything/actions/commands/docs.tsx b/web/app/components/goto-anything/actions/commands/docs.tsxindex d8023795706..8a95b5a836c 100644--- a/web/app/components/goto-anything/actions/commands/docs.tsx+++ b/web/app/components/goto-anything/actions/commands/docs.tsx@@ -1,6 +1,6 @@import type { SlashCommandHandler } from './types'import { RiBookOpenLine } from '@remixicon/react'-import React from 'react'+import * as React from 'react'import { defaultDocBaseUrl } from '@/context/i18n'import i18n from '@/i18n-config/i18next-config'import { getDocLanguage } from '@/i18n-config/language'diff --git a/web/app/components/goto-anything/actions/commands/forum.tsx b/web/app/components/goto-anything/actions/commands/forum.tsxindex 50fc55211c1..2156642bcfb 100644--- a/web/app/components/goto-anything/actions/commands/forum.tsx+++ b/web/app/components/goto-anything/actions/commands/forum.tsx@@ -1,6 +1,6 @@import type { SlashCommandHandler } from './types'import { RiFeedbackLine } from '@remixicon/react'-import React from 'react'+import * as React from 'react'import i18n from '@/i18n-config/i18next-config'import { registerCommands, unregisterCommands } from './command-bus'diff --git a/web/app/components/goto-anything/actions/commands/theme.tsx b/web/app/components/goto-anything/actions/commands/theme.tsxindex c70e4378d6e..dc8ca46bc03 100644--- a/web/app/components/goto-anything/actions/commands/theme.tsx+++ b/web/app/components/goto-anything/actions/commands/theme.tsx@@ -2,7 +2,7 @@ import type { ReactNode } from 'react'import type { CommandSearchResult } from '../types'import type { SlashCommandHandler } from './types'import { RiComputerLine, RiMoonLine, RiSunLine } from '@remixicon/react'-import React from 'react'+import * as React from 'react'import i18n from '@/i18n-config/i18next-config'import { registerCommands, unregisterCommands } from './command-bus'diff --git a/web/app/components/goto-anything/actions/commands/zen.tsx b/web/app/components/goto-anything/actions/commands/zen.tsxindex e8ee4c80877..9fa055a8cc2 100644--- a/web/app/components/goto-anything/actions/commands/zen.tsx+++ b/web/app/components/goto-anything/actions/commands/zen.tsx@@ -1,6 +1,6 @@import type { SlashCommandHandler } from './types'import { RiFullscreenLine } from '@remixicon/react'-import React from 'react'+import * as React from 'react'import { isInWorkflowPage } from '@/app/components/workflow/constants'import i18n from '@/i18n-config/i18next-config'import { registerCommands, unregisterCommands } from './command-bus'diff --git a/web/app/components/goto-anything/command-selector.spec.tsx b/web/app/components/goto-anything/command-selector.spec.tsxindex 40e67789cb5..0ee20860586 100644--- a/web/app/components/goto-anything/command-selector.spec.tsx+++ b/web/app/components/goto-anything/command-selector.spec.tsx@@ -2,7 +2,7 @@ import type { ActionItem } from './actions/types'import { render, screen } from '@testing-library/react'import userEvent from '@testing-library/user-event'import { Command } from 'cmdk'-import React from 'react'+import * as React from 'react'import CommandSelector from './command-selector'vi.mock('next/navigation', () => ({diff --git a/web/app/components/goto-anything/context.spec.tsx b/web/app/components/goto-anything/context.spec.tsxindex 6922e83af19..ec979e1f888 100644--- a/web/app/components/goto-anything/context.spec.tsx+++ b/web/app/components/goto-anything/context.spec.tsx@@ -1,5 +1,5 @@import { render, screen, waitFor } from '@testing-library/react'-import React from 'react'+import * as React from 'react'import { GotoAnythingProvider, useGotoAnythingContext } from './context'let pathnameMock = '/'diff --git a/web/app/components/goto-anything/context.tsx b/web/app/components/goto-anything/context.tsxindex e0802d07c5e..5c2bf3cb6b8 100644--- a/web/app/components/goto-anything/context.tsx+++ b/web/app/components/goto-anything/context.tsx@@ -2,7 +2,8 @@import type { ReactNode } from 'react'import { usePathname } from 'next/navigation'-import React, { createContext, useContext, useEffect, useState } from 'react'+import * as React from 'react'+import { createContext, useContext, useEffect, useState } from 'react'import { isInWorkflowPage } from '../workflow/constants'/**diff --git a/web/app/components/goto-anything/index.spec.tsx b/web/app/components/goto-anything/index.spec.tsxindex 29f6a6be99c..7a8c1ead113 100644--- a/web/app/components/goto-anything/index.spec.tsx+++ b/web/app/components/goto-anything/index.spec.tsx@@ -1,7 +1,7 @@import type { ActionItem, SearchResult } from './actions/types'import { act, render, screen } from '@testing-library/react'import userEvent from '@testing-library/user-event'-import React from 'react'+import * as React from 'react'import GotoAnything from './index'const routerPush = vi.fn()diff --git a/web/app/components/header/account-setting/data-source-page/data-source-notion/index.tsx b/web/app/components/header/account-setting/data-source-page/data-source-notion/index.tsxindex 7897e6da942..d139ab39df6 100644--- a/web/app/components/header/account-setting/data-source-page/data-source-notion/index.tsx+++ b/web/app/components/header/account-setting/data-source-page/data-source-notion/index.tsx@@ -2,7 +2,8 @@import type { FC } from 'react'import type { DataSourceNotion as TDataSourceNotion } from '@/models/common'import { noop } from 'lodash-es'-import React, { useEffect, useState } from 'react'+import * as React from 'react'+import { useEffect, useState } from 'react'import { useTranslation } from 'react-i18next'import NotionIcon from '@/app/components/base/notion-icon'import Toast from '@/app/components/base/toast'diff --git a/web/app/components/header/account-setting/data-source-page/data-source-website/config-firecrawl-modal.tsx b/web/app/components/header/account-setting/data-source-page/data-source-website/config-firecrawl-modal.tsxindex 0d30ed1d855..54a4f4e9cfd 100644--- a/web/app/components/header/account-setting/data-source-page/data-source-website/config-firecrawl-modal.tsx+++ b/web/app/components/header/account-setting/data-source-page/data-source-website/config-firecrawl-modal.tsx@@ -1,7 +1,8 @@'use client'import type { FC } from 'react'import type { FirecrawlConfig } from '@/models/common'-import React, { useCallback, useState } from 'react'+import * as React from 'react'+import { useCallback, useState } from 'react'import { useTranslation } from 'react-i18next'import Button from '@/app/components/base/button'import { LinkExternal02 } from '@/app/components/base/icons/src/vender/line/general'diff --git a/web/app/components/header/account-setting/data-source-page/data-source-website/config-jina-reader-modal.tsx b/web/app/components/header/account-setting/data-source-page/data-source-website/config-jina-reader-modal.tsxindex e02a49e5e1f..74392d30dae 100644--- a/web/app/components/header/account-setting/data-source-page/data-source-website/config-jina-reader-modal.tsx+++ b/web/app/components/header/account-setting/data-source-page/data-source-website/config-jina-reader-modal.tsx@@ -1,6 +1,7 @@'use client'import type { FC } from 'react'-import React, { useCallback, useState } from 'react'+import * as React from 'react'+import { useCallback, useState } from 'react'import { useTranslation } from 'react-i18next'import Button from '@/app/components/base/button'import { LinkExternal02 } from '@/app/components/base/icons/src/vender/line/general'diff --git a/web/app/components/header/account-setting/data-source-page/data-source-website/config-watercrawl-modal.tsx b/web/app/components/header/account-setting/data-source-page/data-source-website/config-watercrawl-modal.tsxindex 7405991f834..92a2f7b8069 100644--- a/web/app/components/header/account-setting/data-source-page/data-source-website/config-watercrawl-modal.tsx+++ b/web/app/components/header/account-setting/data-source-page/data-source-website/config-watercrawl-modal.tsx@@ -1,7 +1,8 @@'use client'import type { FC } from 'react'import type { WatercrawlConfig } from '@/models/common'-import React, { useCallback, useState } from 'react'+import * as React from 'react'+import { useCallback, useState } from 'react'import { useTranslation } from 'react-i18next'import Button from '@/app/components/base/button'import { LinkExternal02 } from '@/app/components/base/icons/src/vender/line/general'diff --git a/web/app/components/header/account-setting/data-source-page/data-source-website/index.tsx b/web/app/components/header/account-setting/data-source-page/data-source-website/index.tsxindex 4fccd064f99..5ad75a94660 100644--- a/web/app/components/header/account-setting/data-source-page/data-source-website/index.tsx+++ b/web/app/components/header/account-setting/data-source-page/data-source-website/index.tsx@@ -1,7 +1,8 @@'use client'import type { FC } from 'react'import type { DataSourceItem } from '@/models/common'-import React, { useCallback, useEffect, useState } from 'react'+import * as React from 'react'+import { useCallback, useEffect, useState } from 'react'import { useTranslation } from 'react-i18next'import Toast from '@/app/components/base/toast'import s from '@/app/components/datasets/create/website/index.module.css'diff --git a/web/app/components/header/account-setting/data-source-page/panel/config-item.tsx b/web/app/components/header/account-setting/data-source-page/panel/config-item.tsxindex a6bcb3adbb5..b98dd7933dd 100644--- a/web/app/components/header/account-setting/data-source-page/panel/config-item.tsx+++ b/web/app/components/header/account-setting/data-source-page/panel/config-item.tsx@@ -4,7 +4,7 @@ import {RiDeleteBinLine,} from '@remixicon/react'import { noop } from 'lodash-es'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import { cn } from '@/utils/classnames'import Indicator from '../../../indicator'diff --git a/web/app/components/header/account-setting/data-source-page/panel/index.tsx b/web/app/components/header/account-setting/data-source-page/panel/index.tsxindex 0cdaadbd30a..49ef183136c 100644--- a/web/app/components/header/account-setting/data-source-page/panel/index.tsx+++ b/web/app/components/header/account-setting/data-source-page/panel/index.tsx@@ -2,7 +2,7 @@import type { FC } from 'react'import type { ConfigItemType } from './config-item'import { RiAddLine } from '@remixicon/react'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import Button from '@/app/components/base/button'diff --git a/web/app/components/header/account-setting/members-page/invite-modal/role-selector.tsx b/web/app/components/header/account-setting/members-page/invite-modal/role-selector.tsxindex cee4e2b4669..7d8169e4c48 100644--- a/web/app/components/header/account-setting/members-page/invite-modal/role-selector.tsx+++ b/web/app/components/header/account-setting/members-page/invite-modal/role-selector.tsx@@ -1,5 +1,6 @@import { RiArrowDownSLine } from '@remixicon/react'-import React, { useState } from 'react'+import * as React from 'react'+import { useState } from 'react'import { useTranslation } from 'react-i18next'import { Check } from '@/app/components/base/icons/src/vender/line/general'import {diff --git a/web/app/components/header/account-setting/members-page/invited-modal/invitation-link.tsx b/web/app/components/header/account-setting/members-page/invited-modal/invitation-link.tsxindex 48776cdfef1..825c225a513 100644--- a/web/app/components/header/account-setting/members-page/invited-modal/invitation-link.tsx+++ b/web/app/components/header/account-setting/members-page/invited-modal/invitation-link.tsx@@ -2,7 +2,8 @@import type { SuccessInvitationResult } from '.'import copy from 'copy-to-clipboard'import { t } from 'i18next'-import React, { useCallback, useEffect, useState } from 'react'+import * as React from 'react'+import { useCallback, useEffect, useState } from 'react'import Tooltip from '@/app/components/base/tooltip'import s from './index.module.css'diff --git a/web/app/components/header/account-setting/members-page/transfer-ownership-modal/index.tsx b/web/app/components/header/account-setting/members-page/transfer-ownership-modal/index.tsxindex 6ad18d38300..2c6a33dc1fd 100644--- a/web/app/components/header/account-setting/members-page/transfer-ownership-modal/index.tsx+++ b/web/app/components/header/account-setting/members-page/transfer-ownership-modal/index.tsx@@ -1,6 +1,7 @@import { RiCloseLine } from '@remixicon/react'import { noop } from 'lodash-es'-import React, { useState } from 'react'+import * as React from 'react'+import { useState } from 'react'import { Trans, useTranslation } from 'react-i18next'import { useContext } from 'use-context-selector'import Button from '@/app/components/base/button'diff --git a/web/app/components/header/account-setting/members-page/transfer-ownership-modal/member-selector.tsx b/web/app/components/header/account-setting/members-page/transfer-ownership-modal/member-selector.tsxindex dae77317991..043fa13aa06 100644--- a/web/app/components/header/account-setting/members-page/transfer-ownership-modal/member-selector.tsx+++ b/web/app/components/header/account-setting/members-page/transfer-ownership-modal/member-selector.tsx@@ -3,7 +3,8 @@ import type { FC } from 'react'import {RiArrowDownSLine,} from '@remixicon/react'-import React, { useMemo, useState } from 'react'+import * as React from 'react'+import { useMemo, useState } from 'react'import { useTranslation } from 'react-i18next'import Avatar from '@/app/components/base/avatar'import Input from '@/app/components/base/input'diff --git a/web/app/components/header/app-back/index.tsx b/web/app/components/header/app-back/index.tsxindex 716a37b94eb..5f76880fd09 100644--- a/web/app/components/header/app-back/index.tsx+++ b/web/app/components/header/app-back/index.tsx@@ -2,7 +2,8 @@import type { AppDetailResponse } from '@/models/app'import { ArrowLeftIcon, Squares2X2Icon } from '@heroicons/react/24/solid'-import React, { useState } from 'react'+import * as React from 'react'+import { useState } from 'react'import { useTranslation } from 'react-i18next'import { cn } from '@/utils/classnames'diff --git a/web/app/components/header/github-star/index.spec.tsx b/web/app/components/header/github-star/index.spec.tsxindex 78a0017b03d..f60ced41475 100644--- a/web/app/components/header/github-star/index.spec.tsx+++ b/web/app/components/header/github-star/index.spec.tsx@@ -1,7 +1,7 @@import { QueryClient, QueryClientProvider } from '@tanstack/react-query'import { render, screen, waitFor } from '@testing-library/react'import nock from 'nock'-import React from 'react'+import * as React from 'react'import GithubStar from './index'const GITHUB_HOST = 'https://api.github.com'diff --git a/web/app/components/header/header-wrapper.tsx b/web/app/components/header/header-wrapper.tsxindex 69d9e1d421e..1b81c1152cc 100644--- a/web/app/components/header/header-wrapper.tsx+++ b/web/app/components/header/header-wrapper.tsx@@ -1,6 +1,7 @@'use client'import { usePathname } from 'next/navigation'-import React, { useState } from 'react'+import * as React from 'react'+import { useState } from 'react'import { useEventEmitterContextContext } from '@/context/event-emitter'import { cn } from '@/utils/classnames'import s from './index.module.css'diff --git a/web/app/components/header/nav/index.tsx b/web/app/components/header/nav/index.tsxindex a3820fcc499..83e75b85135 100644--- a/web/app/components/header/nav/index.tsx+++ b/web/app/components/header/nav/index.tsx@@ -3,7 +3,8 @@import type { INavSelectorProps } from './nav-selector'import Link from 'next/link'import { usePathname, useSearchParams, useSelectedLayoutSegment } from 'next/navigation'-import React, { useEffect, useState } from 'react'+import * as React from 'react'+import { useEffect, useState } from 'react'import { useStore as useAppStore } from '@/app/components/app/store'import { ArrowNarrowLeft } from '@/app/components/base/icons/src/vender/line/arrows'import { cn } from '@/utils/classnames'diff --git a/web/app/components/i18n-server.tsx b/web/app/components/i18n-server.tsxindex a81d137c591..01dc5f0f131 100644--- a/web/app/components/i18n-server.tsx+++ b/web/app/components/i18n-server.tsx@@ -1,4 +1,4 @@-import React from 'react'+import * as React from 'react'import { getLocaleOnServer } from '@/i18n-config/server'import { ToastProvider } from './base/toast'import I18N from './i18n'diff --git a/web/app/components/i18n.tsx b/web/app/components/i18n.tsxindex 5bd9de617e0..8a95363c154 100644--- a/web/app/components/i18n.tsx+++ b/web/app/components/i18n.tsx@@ -3,7 +3,8 @@import type { FC } from 'react'import type { Locale } from '@/i18n-config'import { usePrefetchQuery } from '@tanstack/react-query'-import React, { useEffect, useState } from 'react'+import * as React from 'react'+import { useEffect, useState } from 'react'import I18NContext from '@/context/i18n'import { setLocaleOnClient } from '@/i18n-config'import { getSystemFeatures } from '@/service/common'diff --git a/web/app/components/plugins/base/badges/icon-with-tooltip.tsx b/web/app/components/plugins/base/badges/icon-with-tooltip.tsxindex 0a75334b5fc..fc2aaaa5729 100644--- a/web/app/components/plugins/base/badges/icon-with-tooltip.tsx+++ b/web/app/components/plugins/base/badges/icon-with-tooltip.tsx@@ -1,5 +1,5 @@import type { FC } from 'react'-import React from 'react'+import * as React from 'react'import Tooltip from '@/app/components/base/tooltip'import { Theme } from '@/types/app'import { cn } from '@/utils/classnames'diff --git a/web/app/components/plugins/base/deprecation-notice.tsx b/web/app/components/plugins/base/deprecation-notice.tsxindex 33594746691..8832c779610 100644--- a/web/app/components/plugins/base/deprecation-notice.tsx+++ b/web/app/components/plugins/base/deprecation-notice.tsx@@ -2,7 +2,8 @@ import type { FC } from 'react'import { RiAlertFill } from '@remixicon/react'import { camelCase } from 'lodash-es'import Link from 'next/link'-import React, { useMemo } from 'react'+import * as React from 'react'+import { useMemo } from 'react'import { Trans } from 'react-i18next'import { cn } from '@/utils/classnames'import { useMixedTranslation } from '../marketplace/hooks'diff --git a/web/app/components/plugins/base/key-value-item.tsx b/web/app/components/plugins/base/key-value-item.tsxindex 07f51937733..5f1732cc0b1 100644--- a/web/app/components/plugins/base/key-value-item.tsx+++ b/web/app/components/plugins/base/key-value-item.tsx@@ -4,7 +4,8 @@ import {RiClipboardLine,} from '@remixicon/react'import copy from 'copy-to-clipboard'-import React, { useCallback, useEffect, useState } from 'react'+import * as React from 'react'+import { useCallback, useEffect, useState } from 'react'import { useTranslation } from 'react-i18next'import ActionButton from '@/app/components/base/action-button'import { cn } from '@/utils/classnames'diff --git a/web/app/components/plugins/card/base/description.tsx b/web/app/components/plugins/card/base/description.tsxindex 9b9d7e34716..79e77c7e6fc 100644--- a/web/app/components/plugins/card/base/description.tsx+++ b/web/app/components/plugins/card/base/description.tsx@@ -1,5 +1,6 @@import type { FC } from 'react'-import React, { useMemo } from 'react'+import * as React from 'react'+import { useMemo } from 'react'import { cn } from '@/utils/classnames'type Props = {diff --git a/web/app/components/plugins/card/base/download-count.tsx b/web/app/components/plugins/card/base/download-count.tsxindex 653b595dde3..91541cb9319 100644--- a/web/app/components/plugins/card/base/download-count.tsx+++ b/web/app/components/plugins/card/base/download-count.tsx@@ -1,5 +1,5 @@import { RiInstallLine } from '@remixicon/react'-import React from 'react'+import * as React from 'react'import { formatNumber } from '@/utils/format'type Props = {diff --git a/web/app/components/plugins/card/card-more-info.tsx b/web/app/components/plugins/card/card-more-info.tsxindex d81c941e967..33f819f31a7 100644--- a/web/app/components/plugins/card/card-more-info.tsx+++ b/web/app/components/plugins/card/card-more-info.tsx@@ -1,4 +1,4 @@-import React from 'react'+import * as React from 'react'import DownloadCount from './base/download-count'type Props = {diff --git a/web/app/components/plugins/card/index.tsx b/web/app/components/plugins/card/index.tsxindex af3468629e2..1cb15bf70b1 100644--- a/web/app/components/plugins/card/index.tsx+++ b/web/app/components/plugins/card/index.tsx@@ -1,7 +1,7 @@'use client'import type { Plugin } from '../types'import { RiAlertFill } from '@remixicon/react'-import React from 'react'+import * as React from 'react'import { useMixedTranslation } from '@/app/components/plugins/marketplace/hooks'import { useGetLanguage } from '@/context/i18n'import useTheme from '@/hooks/use-theme'diff --git a/web/app/components/plugins/install-plugin/base/installed.tsx b/web/app/components/plugins/install-plugin/base/installed.tsxindex aa4ca7c982e..2c5a5cd088c 100644--- a/web/app/components/plugins/install-plugin/base/installed.tsx+++ b/web/app/components/plugins/install-plugin/base/installed.tsx@@ -1,7 +1,7 @@'use client'import type { FC } from 'react'import type { Plugin, PluginDeclaration, PluginManifestInMarket } from '../../types'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import Badge, { BadgeState } from '@/app/components/base/badge/index'import Button from '@/app/components/base/button'diff --git a/web/app/components/plugins/install-plugin/base/loading-error.tsx b/web/app/components/plugins/install-plugin/base/loading-error.tsxindex f0067ed4fd3..dd156fe7ef1 100644--- a/web/app/components/plugins/install-plugin/base/loading-error.tsx+++ b/web/app/components/plugins/install-plugin/base/loading-error.tsx@@ -1,7 +1,7 @@'use client'import type { FC } from 'react'import { RiCloseLine } from '@remixicon/react'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import Checkbox from '@/app/components/base/checkbox'import { LoadingPlaceholder } from '@/app/components/plugins/card/base/placeholder'diff --git a/web/app/components/plugins/install-plugin/base/loading.tsx b/web/app/components/plugins/install-plugin/base/loading.tsxindex 973b574c8fb..7416311dc86 100644--- a/web/app/components/plugins/install-plugin/base/loading.tsx+++ b/web/app/components/plugins/install-plugin/base/loading.tsx@@ -1,5 +1,5 @@'use client'-import React from 'react'+import * as React from 'react'import Checkbox from '@/app/components/base/checkbox'import Placeholder from '../../card/base/placeholder'diff --git a/web/app/components/plugins/install-plugin/base/version.tsx b/web/app/components/plugins/install-plugin/base/version.tsxindex ad91c91af7b..d7bf042ab52 100644--- a/web/app/components/plugins/install-plugin/base/version.tsx+++ b/web/app/components/plugins/install-plugin/base/version.tsx@@ -1,7 +1,7 @@'use client'import type { FC } from 'react'import type { VersionProps } from '../../types'-import React from 'react'+import * as React from 'react'import Badge, { BadgeState } from '@/app/components/base/badge/index'const Version: FC<VersionProps> = ({diff --git a/web/app/components/plugins/install-plugin/install-bundle/index.tsx b/web/app/components/plugins/install-plugin/install-bundle/index.tsxindex 0e32ea71644..6c8a060116c 100644--- a/web/app/components/plugins/install-plugin/install-bundle/index.tsx+++ b/web/app/components/plugins/install-plugin/install-bundle/index.tsx@@ -1,7 +1,8 @@'use client'import type { FC } from 'react'import type { Dependency } from '../../types'-import React, { useCallback, useState } from 'react'+import * as React from 'react'+import { useCallback, useState } from 'react'import { useTranslation } from 'react-i18next'import Modal from '@/app/components/base/modal'import { cn } from '@/utils/classnames'diff --git a/web/app/components/plugins/install-plugin/install-bundle/item/github-item.tsx b/web/app/components/plugins/install-plugin/install-bundle/item/github-item.tsxindex 382f5473ca9..a25c2f59784 100644--- a/web/app/components/plugins/install-plugin/install-bundle/item/github-item.tsx+++ b/web/app/components/plugins/install-plugin/install-bundle/item/github-item.tsx@@ -2,7 +2,8 @@import type { FC } from 'react'import type { GitHubItemAndMarketPlaceDependency, Plugin } from '../../../types'import type { VersionProps } from '@/app/components/plugins/types'-import React, { useEffect } from 'react'+import * as React from 'react'+import { useEffect } from 'react'import { useUploadGitHub } from '@/service/use-plugins'import Loading from '../../base/loading'import { pluginManifestToCardPluginProps } from '../../utils'diff --git a/web/app/components/plugins/install-plugin/install-bundle/item/loaded-item.tsx b/web/app/components/plugins/install-plugin/install-bundle/item/loaded-item.tsxindex 22c48cf55cb..29f4a44ddb2 100644--- a/web/app/components/plugins/install-plugin/install-bundle/item/loaded-item.tsx+++ b/web/app/components/plugins/install-plugin/install-bundle/item/loaded-item.tsx@@ -1,7 +1,7 @@'use client'import type { FC } from 'react'import type { Plugin, VersionProps } from '../../../types'-import React from 'react'+import * as React from 'react'import Checkbox from '@/app/components/base/checkbox'import { MARKETPLACE_API_PREFIX } from '@/config'import Card from '../../../card'diff --git a/web/app/components/plugins/install-plugin/install-bundle/item/marketplace-item.tsx b/web/app/components/plugins/install-plugin/install-bundle/item/marketplace-item.tsxindex 1502fd0d65a..d02cb0f74f0 100644--- a/web/app/components/plugins/install-plugin/install-bundle/item/marketplace-item.tsx+++ b/web/app/components/plugins/install-plugin/install-bundle/item/marketplace-item.tsx@@ -2,7 +2,7 @@import type { FC } from 'react'import type { Plugin } from '../../../types'import type { VersionProps } from '@/app/components/plugins/types'-import React from 'react'+import * as React from 'react'import Loading from '../../base/loading'import LoadedItem from './loaded-item'diff --git a/web/app/components/plugins/install-plugin/install-bundle/item/package-item.tsx b/web/app/components/plugins/install-plugin/install-bundle/item/package-item.tsxindex 84cee52ccc6..63880bde5f0 100644--- a/web/app/components/plugins/install-plugin/install-bundle/item/package-item.tsx+++ b/web/app/components/plugins/install-plugin/install-bundle/item/package-item.tsx@@ -2,7 +2,7 @@import type { FC } from 'react'import type { PackageDependency, Plugin } from '../../../types'import type { VersionProps } from '@/app/components/plugins/types'-import React from 'react'+import * as React from 'react'import LoadingError from '../../base/loading-error'import { pluginManifestToCardPluginProps } from '../../utils'import LoadedItem from './loaded-item'diff --git a/web/app/components/plugins/install-plugin/install-bundle/ready-to-install.tsx b/web/app/components/plugins/install-plugin/install-bundle/ready-to-install.tsxindex f10556924ca..2310063367f 100644--- a/web/app/components/plugins/install-plugin/install-bundle/ready-to-install.tsx+++ b/web/app/components/plugins/install-plugin/install-bundle/ready-to-install.tsx@@ -1,7 +1,8 @@'use client'import type { FC } from 'react'import type { Dependency, InstallStatus, Plugin } from '../../types'-import React, { useCallback, useState } from 'react'+import * as React from 'react'+import { useCallback, useState } from 'react'import { InstallStep } from '../../types'import Install from './steps/install'import Installed from './steps/installed'diff --git a/web/app/components/plugins/install-plugin/install-bundle/steps/install-multi.tsx b/web/app/components/plugins/install-plugin/install-bundle/steps/install-multi.tsxindex f908b4f1c1b..1b08ca5a045 100644--- a/web/app/components/plugins/install-plugin/install-bundle/steps/install-multi.tsx+++ b/web/app/components/plugins/install-plugin/install-bundle/steps/install-multi.tsx@@ -1,7 +1,8 @@'use client'import type { Dependency, GitHubItemAndMarketPlaceDependency, PackageDependency, Plugin, VersionInfo } from '../../../types'import { produce } from 'immer'-import React, { useCallback, useEffect, useImperativeHandle, useMemo, useState } from 'react'+import * as React from 'react'+import { useCallback, useEffect, useImperativeHandle, useMemo, useState } from 'react'import useCheckInstalled from '@/app/components/plugins/install-plugin/hooks/use-check-installed'import { useGlobalPublicStore } from '@/context/global-public-context'import { useFetchPluginsInMarketPlaceByInfo } from '@/service/use-plugins'diff --git a/web/app/components/plugins/install-plugin/install-bundle/steps/install.tsx b/web/app/components/plugins/install-plugin/install-bundle/steps/install.tsxindex 67c3bde8bc9..0373e255a00 100644--- a/web/app/components/plugins/install-plugin/install-bundle/steps/install.tsx+++ b/web/app/components/plugins/install-plugin/install-bundle/steps/install.tsx@@ -3,7 +3,8 @@ import type { FC } from 'react'import type { Dependency, InstallStatus, InstallStatusResponse, Plugin, VersionInfo } from '../../../types'import type { ExposeRefs } from './install-multi'import { RiLoader2Line } from '@remixicon/react'-import React, { useCallback, useRef, useState } from 'react'+import * as React from 'react'+import { useCallback, useRef, useState } from 'react'import { useTranslation } from 'react-i18next'import Button from '@/app/components/base/button'import Checkbox from '@/app/components/base/checkbox'diff --git a/web/app/components/plugins/install-plugin/install-bundle/steps/installed.tsx b/web/app/components/plugins/install-plugin/install-bundle/steps/installed.tsxindex 2fb7aab9d23..48096a13d37 100644--- a/web/app/components/plugins/install-plugin/install-bundle/steps/installed.tsx+++ b/web/app/components/plugins/install-plugin/install-bundle/steps/installed.tsx@@ -1,7 +1,7 @@'use client'import type { FC } from 'react'import type { InstallStatus, Plugin } from '../../../types'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import Badge, { BadgeState } from '@/app/components/base/badge/index'import Button from '@/app/components/base/button'diff --git a/web/app/components/plugins/install-plugin/install-from-github/index.tsx b/web/app/components/plugins/install-plugin/install-from-github/index.tsxindex 291e5d4ecac..4a15b263b77 100644--- a/web/app/components/plugins/install-plugin/install-from-github/index.tsx+++ b/web/app/components/plugins/install-plugin/install-from-github/index.tsx@@ -3,7 +3,8 @@import type { PluginDeclaration, UpdateFromGitHubPayload } from '../../types'import type { Item } from '@/app/components/base/select'import type { InstallState } from '@/app/components/plugins/types'-import React, { useCallback, useState } from 'react'+import * as React from 'react'+import { useCallback, useState } from 'react'import { useTranslation } from 'react-i18next'import Modal from '@/app/components/base/modal'import Toast from '@/app/components/base/toast'diff --git a/web/app/components/plugins/install-plugin/install-from-github/steps/loaded.tsx b/web/app/components/plugins/install-plugin/install-from-github/steps/loaded.tsxindex 27cc8b7498f..3bff22816b8 100644--- a/web/app/components/plugins/install-plugin/install-from-github/steps/loaded.tsx+++ b/web/app/components/plugins/install-plugin/install-from-github/steps/loaded.tsx@@ -2,7 +2,8 @@import type { Plugin, PluginDeclaration, UpdateFromGitHubPayload } from '../../../types'import { RiLoader2Line } from '@remixicon/react'-import React, { useEffect } from 'react'+import * as React from 'react'+import { useEffect } from 'react'import { useTranslation } from 'react-i18next'import Button from '@/app/components/base/button'import useCheckInstalled from '@/app/components/plugins/install-plugin/hooks/use-check-installed'diff --git a/web/app/components/plugins/install-plugin/install-from-github/steps/selectPackage.tsx b/web/app/components/plugins/install-plugin/install-from-github/steps/selectPackage.tsxindex 8fdd0c8b8aa..a5fc79c50b5 100644--- a/web/app/components/plugins/install-plugin/install-from-github/steps/selectPackage.tsx+++ b/web/app/components/plugins/install-plugin/install-from-github/steps/selectPackage.tsx@@ -2,7 +2,7 @@import type { PluginDeclaration, UpdateFromGitHubPayload } from '../../../types'import type { Item } from '@/app/components/base/select'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import Button from '@/app/components/base/button'import { PortalSelect } from '@/app/components/base/select'diff --git a/web/app/components/plugins/install-plugin/install-from-github/steps/setURL.tsx b/web/app/components/plugins/install-plugin/install-from-github/steps/setURL.tsxindex f07005a253f..7d396751620 100644--- a/web/app/components/plugins/install-plugin/install-from-github/steps/setURL.tsx+++ b/web/app/components/plugins/install-plugin/install-from-github/steps/setURL.tsx@@ -1,6 +1,6 @@'use client'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import Button from '@/app/components/base/button'diff --git a/web/app/components/plugins/install-plugin/install-from-local-package/index.tsx b/web/app/components/plugins/install-plugin/install-from-local-package/index.tsxindex 4c0f26a2b9a..b2390e38f31 100644--- a/web/app/components/plugins/install-plugin/install-from-local-package/index.tsx+++ b/web/app/components/plugins/install-plugin/install-from-local-package/index.tsx@@ -1,7 +1,8 @@'use client'import type { Dependency, PluginDeclaration } from '../../types'-import React, { useCallback, useState } from 'react'+import * as React from 'react'+import { useCallback, useState } from 'react'import { useTranslation } from 'react-i18next'import Modal from '@/app/components/base/modal'import useGetIcon from '@/app/components/plugins/install-plugin/base/use-get-icon'diff --git a/web/app/components/plugins/install-plugin/install-from-local-package/ready-to-install.tsx b/web/app/components/plugins/install-plugin/install-from-local-package/ready-to-install.tsxindex 5afe9ccf902..b6f4e9d3ce4 100644--- a/web/app/components/plugins/install-plugin/install-from-local-package/ready-to-install.tsx+++ b/web/app/components/plugins/install-plugin/install-from-local-package/ready-to-install.tsx@@ -1,7 +1,8 @@'use client'import type { FC } from 'react'import type { PluginDeclaration } from '../../types'-import React, { useCallback } from 'react'+import * as React from 'react'+import { useCallback } from 'react'import { InstallStep } from '../../types'import Installed from '../base/installed'import useRefreshPluginList from '../hooks/use-refresh-plugin-list'diff --git a/web/app/components/plugins/install-plugin/install-from-local-package/steps/install.tsx b/web/app/components/plugins/install-plugin/install-from-local-package/steps/install.tsxindex b8a6891d64f..86dda076390 100644--- a/web/app/components/plugins/install-plugin/install-from-local-package/steps/install.tsx+++ b/web/app/components/plugins/install-plugin/install-from-local-package/steps/install.tsx@@ -2,7 +2,8 @@import type { FC } from 'react'import type { PluginDeclaration } from '../../../types'import { RiLoader2Line } from '@remixicon/react'-import React, { useEffect, useMemo } from 'react'+import * as React from 'react'+import { useEffect, useMemo } from 'react'import { Trans, useTranslation } from 'react-i18next'import { gte } from 'semver'import Button from '@/app/components/base/button'diff --git a/web/app/components/plugins/install-plugin/install-from-local-package/steps/uploading.tsx b/web/app/components/plugins/install-plugin/install-from-local-package/steps/uploading.tsxindex fb591064ed9..67b25053946 100644--- a/web/app/components/plugins/install-plugin/install-from-local-package/steps/uploading.tsx+++ b/web/app/components/plugins/install-plugin/install-from-local-package/steps/uploading.tsx@@ -2,7 +2,7 @@import type { FC } from 'react'import type { Dependency, PluginDeclaration } from '../../../types'import { RiLoader2Line } from '@remixicon/react'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import Button from '@/app/components/base/button'import { uploadFile } from '@/service/plugins'diff --git a/web/app/components/plugins/install-plugin/install-from-marketplace/index.tsx b/web/app/components/plugins/install-plugin/install-from-marketplace/index.tsxindex 72ec874d6ff..22ef6cb53a1 100644--- a/web/app/components/plugins/install-plugin/install-from-marketplace/index.tsx+++ b/web/app/components/plugins/install-plugin/install-from-marketplace/index.tsx@@ -1,7 +1,8 @@'use client'import type { Dependency, Plugin, PluginManifestInMarket } from '../../types'-import React, { useCallback, useState } from 'react'+import * as React from 'react'+import { useCallback, useState } from 'react'import { useTranslation } from 'react-i18next'import Modal from '@/app/components/base/modal'import { cn } from '@/utils/classnames'diff --git a/web/app/components/plugins/install-plugin/install-from-marketplace/steps/install.tsx b/web/app/components/plugins/install-plugin/install-from-marketplace/steps/install.tsxindex 8a8af380c3d..99ee1734906 100644--- a/web/app/components/plugins/install-plugin/install-from-marketplace/steps/install.tsx+++ b/web/app/components/plugins/install-plugin/install-from-marketplace/steps/install.tsx@@ -2,7 +2,8 @@import type { FC } from 'react'import type { Plugin, PluginManifestInMarket } from '../../../types'import { RiLoader2Line } from '@remixicon/react'-import React, { useEffect, useMemo } from 'react'+import * as React from 'react'+import { useEffect, useMemo } from 'react'import { useTranslation } from 'react-i18next'import { gte } from 'semver'import Button from '@/app/components/base/button'diff --git a/web/app/components/plugins/marketplace/list/card-wrapper.tsx b/web/app/components/plugins/marketplace/list/card-wrapper.tsxindex 9ca005fe52a..159107eb979 100644--- a/web/app/components/plugins/marketplace/list/card-wrapper.tsx+++ b/web/app/components/plugins/marketplace/list/card-wrapper.tsx@@ -3,7 +3,8 @@ import type { Plugin } from '@/app/components/plugins/types'import { RiArrowRightUpLine } from '@remixicon/react'import { useBoolean } from 'ahooks'import { useTheme } from 'next-themes'-import React, { useMemo } from 'react'+import * as React from 'react'+import { useMemo } from 'react'import Button from '@/app/components/base/button'import Card from '@/app/components/plugins/card'import CardMoreInfo from '@/app/components/plugins/card/card-more-info'diff --git a/web/app/components/plugins/marketplace/search-box/trigger/marketplace.tsx b/web/app/components/plugins/marketplace/search-box/trigger/marketplace.tsxindex 2cc12614ee1..e38c9199c40 100644--- a/web/app/components/plugins/marketplace/search-box/trigger/marketplace.tsx+++ b/web/app/components/plugins/marketplace/search-box/trigger/marketplace.tsx@@ -1,6 +1,6 @@import type { Tag } from '../../../hooks'import { RiArrowDownSLine, RiCloseCircleFill, RiFilter3Line } from '@remixicon/react'-import React from 'react'+import * as React from 'react'import { cn } from '@/utils/classnames'import { useMixedTranslation } from '../../hooks'diff --git a/web/app/components/plugins/marketplace/search-box/trigger/tool-selector.tsx b/web/app/components/plugins/marketplace/search-box/trigger/tool-selector.tsxindex 762a31a4fd4..4e1fbebd467 100644--- a/web/app/components/plugins/marketplace/search-box/trigger/tool-selector.tsx+++ b/web/app/components/plugins/marketplace/search-box/trigger/tool-selector.tsx@@ -1,6 +1,6 @@import type { Tag } from '../../../hooks'import { RiCloseCircleFill, RiPriceTag3Line } from '@remixicon/react'-import React from 'react'+import * as React from 'react'import { cn } from '@/utils/classnames'type ToolSelectorTriggerProps = {diff --git a/web/app/components/plugins/plugin-detail-panel/action-list.tsx b/web/app/components/plugins/plugin-detail-panel/action-list.tsxindex 96e25bbc548..a1cb1198a1b 100644--- a/web/app/components/plugins/plugin-detail-panel/action-list.tsx+++ b/web/app/components/plugins/plugin-detail-panel/action-list.tsx@@ -1,5 +1,6 @@import type { PluginDetail } from '@/app/components/plugins/types'-import React, { useMemo } from 'react'+import * as React from 'react'+import { useMemo } from 'react'import { useTranslation } from 'react-i18next'import ToolItem from '@/app/components/tools/provider/tool-item'import {diff --git a/web/app/components/plugins/plugin-detail-panel/agent-strategy-list.tsx b/web/app/components/plugins/plugin-detail-panel/agent-strategy-list.tsxindex afc75226ea0..e1114853e55 100644--- a/web/app/components/plugins/plugin-detail-panel/agent-strategy-list.tsx+++ b/web/app/components/plugins/plugin-detail-panel/agent-strategy-list.tsx@@ -1,5 +1,6 @@import type { PluginDetail } from '@/app/components/plugins/types'-import React, { useMemo } from 'react'+import * as React from 'react'+import { useMemo } from 'react'import { useTranslation } from 'react-i18next'import StrategyItem from '@/app/components/plugins/plugin-detail-panel/strategy-item'import {diff --git a/web/app/components/plugins/plugin-detail-panel/app-selector/app-inputs-panel.tsx b/web/app/components/plugins/plugin-detail-panel/app-selector/app-inputs-panel.tsxindex 2fc94bd00d9..897bc917076 100644--- a/web/app/components/plugins/plugin-detail-panel/app-selector/app-inputs-panel.tsx+++ b/web/app/components/plugins/plugin-detail-panel/app-selector/app-inputs-panel.tsx@@ -1,7 +1,8 @@'use client'import type { FileUpload } from '@/app/components/base/features/types'import type { App } from '@/types/app'-import React, { useMemo, useRef } from 'react'+import * as React from 'react'+import { useMemo, useRef } from 'react'import { useTranslation } from 'react-i18next'import Loading from '@/app/components/base/loading'import { FILE_EXTS } from '@/app/components/base/prompt-editor/constants'diff --git a/web/app/components/plugins/plugin-detail-panel/app-selector/app-picker.tsx b/web/app/components/plugins/plugin-detail-panel/app-selector/app-picker.tsxindex ca916cf662d..f46588b5e35 100644--- a/web/app/components/plugins/plugin-detail-panel/app-selector/app-picker.tsx+++ b/web/app/components/plugins/plugin-detail-panel/app-selector/app-picker.tsx@@ -5,7 +5,8 @@ import type {} from '@floating-ui/react'import type { FC } from 'react'import type { App } from '@/types/app'-import React, { useCallback, useEffect, useRef } from 'react'+import * as React from 'react'+import { useCallback, useEffect, useRef } from 'react'import { useTranslation } from 'react-i18next'import AppIcon from '@/app/components/base/app-icon'import Input from '@/app/components/base/input'diff --git a/web/app/components/plugins/plugin-detail-panel/app-selector/app-trigger.tsx b/web/app/components/plugins/plugin-detail-panel/app-selector/app-trigger.tsxindex 54dc1562fd0..2841864aa14 100644--- a/web/app/components/plugins/plugin-detail-panel/app-selector/app-trigger.tsx+++ b/web/app/components/plugins/plugin-detail-panel/app-selector/app-trigger.tsx@@ -3,7 +3,7 @@ import type { App } from '@/types/app'import {RiArrowDownSLine,} from '@remixicon/react'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import AppIcon from '@/app/components/base/app-icon'import { cn } from '@/utils/classnames'diff --git a/web/app/components/plugins/plugin-detail-panel/app-selector/index.tsx b/web/app/components/plugins/plugin-detail-panel/app-selector/index.tsxindex 965ae4e47a8..ad7281e88e5 100644--- a/web/app/components/plugins/plugin-detail-panel/app-selector/index.tsx+++ b/web/app/components/plugins/plugin-detail-panel/app-selector/index.tsx@@ -5,7 +5,8 @@ import type {} from '@floating-ui/react'import type { FC } from 'react'import type { App } from '@/types/app'-import React, { useCallback, useMemo, useState } from 'react'+import * as React from 'react'+import { useCallback, useMemo, useState } from 'react'import { useTranslation } from 'react-i18next'import {PortalToFollowElem,diff --git a/web/app/components/plugins/plugin-detail-panel/datasource-action-list.tsx b/web/app/components/plugins/plugin-detail-panel/datasource-action-list.tsxindex 003829b9ffa..e9f5d88a296 100644--- a/web/app/components/plugins/plugin-detail-panel/datasource-action-list.tsx+++ b/web/app/components/plugins/plugin-detail-panel/datasource-action-list.tsx@@ -5,7 +5,8 @@// import ToolItem from '@/app/components/tools/provider/tool-item'// import ConfigCredential from '@/app/components/tools/setting/build-in/config-credentials'import type { PluginDetail } from '@/app/components/plugins/types'-import React, { useMemo } from 'react'+import * as React from 'react'+import { useMemo } from 'react'import { useTranslation } from 'react-i18next'import { transformDataSourceToTool } from '@/app/components/workflow/block-selector/utils'import { useDataSourceList } from '@/service/use-pipeline'diff --git a/web/app/components/plugins/plugin-detail-panel/detail-header.tsx b/web/app/components/plugins/plugin-detail-panel/detail-header.tsxindex 6fe439b6314..0dcd69c01b6 100644--- a/web/app/components/plugins/plugin-detail-panel/detail-header.tsx+++ b/web/app/components/plugins/plugin-detail-panel/detail-header.tsx@@ -6,7 +6,8 @@ import {RiHardDrive3Line,} from '@remixicon/react'import { useBoolean } from 'ahooks'-import React, { useCallback, useMemo, useState } from 'react'+import * as React from 'react'+import { useCallback, useMemo, useState } from 'react'import { useTranslation } from 'react-i18next'import ActionButton from '@/app/components/base/action-button'import { trackEvent } from '@/app/components/base/amplitude'diff --git a/web/app/components/plugins/plugin-detail-panel/endpoint-card.tsx b/web/app/components/plugins/plugin-detail-panel/endpoint-card.tsxindex ba4d26d3dd9..9ddaef1d814 100644--- a/web/app/components/plugins/plugin-detail-panel/endpoint-card.tsx+++ b/web/app/components/plugins/plugin-detail-panel/endpoint-card.tsx@@ -2,7 +2,8 @@ import type { EndpointListItem, PluginDetail } from '../types'import { RiClipboardLine, RiDeleteBinLine, RiEditLine, RiLoginCircleLine } from '@remixicon/react'import { useBoolean } from 'ahooks'import copy from 'copy-to-clipboard'-import React, { useEffect, useMemo, useState } from 'react'+import * as React from 'react'+import { useEffect, useMemo, useState } from 'react'import { useTranslation } from 'react-i18next'import ActionButton from '@/app/components/base/action-button'import Confirm from '@/app/components/base/confirm'diff --git a/web/app/components/plugins/plugin-detail-panel/endpoint-list.tsx b/web/app/components/plugins/plugin-detail-panel/endpoint-list.tsxindex a1ccbcd446d..7acc0653715 100644--- a/web/app/components/plugins/plugin-detail-panel/endpoint-list.tsx+++ b/web/app/components/plugins/plugin-detail-panel/endpoint-list.tsx@@ -5,7 +5,8 @@ import {RiBookOpenLine,} from '@remixicon/react'import { useBoolean } from 'ahooks'-import React, { useMemo } from 'react'+import * as React from 'react'+import { useMemo } from 'react'import { useTranslation } from 'react-i18next'import ActionButton from '@/app/components/base/action-button'import Toast from '@/app/components/base/toast'diff --git a/web/app/components/plugins/plugin-detail-panel/endpoint-modal.tsx b/web/app/components/plugins/plugin-detail-panel/endpoint-modal.tsxindex e2d7da62578..5e84dc3abc5 100644--- a/web/app/components/plugins/plugin-detail-panel/endpoint-modal.tsx+++ b/web/app/components/plugins/plugin-detail-panel/endpoint-modal.tsx@@ -3,7 +3,7 @@ import type { FC } from 'react'import type { FormSchema } from '../../base/form/types'import type { PluginDetail } from '../types'import { RiArrowRightUpLine, RiCloseLine } from '@remixicon/react'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import ActionButton from '@/app/components/base/action-button'import Button from '@/app/components/base/button'diff --git a/web/app/components/plugins/plugin-detail-panel/model-list.tsx b/web/app/components/plugins/plugin-detail-panel/model-list.tsxindex 385c128b869..49d57804511 100644--- a/web/app/components/plugins/plugin-detail-panel/model-list.tsx+++ b/web/app/components/plugins/plugin-detail-panel/model-list.tsx@@ -1,5 +1,5 @@import type { PluginDetail } from '@/app/components/plugins/types'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import ModelIcon from '@/app/components/header/account-setting/model-provider-page/model-icon'import ModelName from '@/app/components/header/account-setting/model-provider-page/model-name'diff --git a/web/app/components/plugins/plugin-detail-panel/model-selector/llm-params-panel.tsx b/web/app/components/plugins/plugin-detail-panel/model-selector/llm-params-panel.tsxindex 3b26b40fb67..2d3d07cfef6 100644--- a/web/app/components/plugins/plugin-detail-panel/model-selector/llm-params-panel.tsx+++ b/web/app/components/plugins/plugin-detail-panel/model-selector/llm-params-panel.tsx@@ -3,7 +3,8 @@ import type {ModelParameterRule,} from '@/app/components/header/account-setting/model-provider-page/declarations'import type { ParameterValue } from '@/app/components/header/account-setting/model-provider-page/model-parameter-modal/parameter-item'-import React, { useMemo } from 'react'+import * as React from 'react'+import { useMemo } from 'react'import { useTranslation } from 'react-i18next'import Loading from '@/app/components/base/loading'import ParameterItem from '@/app/components/header/account-setting/model-provider-page/model-parameter-modal/parameter-item'diff --git a/web/app/components/plugins/plugin-detail-panel/model-selector/tts-params-panel.tsx b/web/app/components/plugins/plugin-detail-panel/model-selector/tts-params-panel.tsxindex db208d349e3..cc4f4d48815 100644--- a/web/app/components/plugins/plugin-detail-panel/model-selector/tts-params-panel.tsx+++ b/web/app/components/plugins/plugin-detail-panel/model-selector/tts-params-panel.tsx@@ -1,4 +1,5 @@-import React, { useMemo } from 'react'+import * as React from 'react'+import { useMemo } from 'react'import { useTranslation } from 'react-i18next'import { PortalSelect } from '@/app/components/base/select'import { languages } from '@/i18n-config/language'diff --git a/web/app/components/plugins/plugin-detail-panel/multiple-tool-selector/index.tsx b/web/app/components/plugins/plugin-detail-panel/multiple-tool-selector/index.tsxindex e0013089b0b..b3d841e86a5 100644--- a/web/app/components/plugins/plugin-detail-panel/multiple-tool-selector/index.tsx+++ b/web/app/components/plugins/plugin-detail-panel/multiple-tool-selector/index.tsx@@ -5,7 +5,7 @@ import {RiAddLine,RiQuestionLine,} from '@remixicon/react'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import ActionButton from '@/app/components/base/action-button'import Divider from '@/app/components/base/divider'diff --git a/web/app/components/plugins/plugin-detail-panel/operation-dropdown.tsx b/web/app/components/plugins/plugin-detail-panel/operation-dropdown.tsxindex e9d794964dc..15e4d6df67e 100644--- a/web/app/components/plugins/plugin-detail-panel/operation-dropdown.tsx+++ b/web/app/components/plugins/plugin-detail-panel/operation-dropdown.tsx@@ -1,7 +1,8 @@'use client'import type { FC } from 'react'import { RiArrowRightUpLine, RiMoreFill } from '@remixicon/react'-import React, { useCallback, useRef, useState } from 'react'+import * as React from 'react'+import { useCallback, useRef, useState } from 'react'import { useTranslation } from 'react-i18next'import ActionButton from '@/app/components/base/action-button'// import Button from '@/app/components/base/button'diff --git a/web/app/components/plugins/plugin-detail-panel/strategy-detail.tsx b/web/app/components/plugins/plugin-detail-panel/strategy-detail.tsxindex 061e44d2084..50c803b81ba 100644--- a/web/app/components/plugins/plugin-detail-panel/strategy-detail.tsx+++ b/web/app/components/plugins/plugin-detail-panel/strategy-detail.tsx@@ -8,7 +8,8 @@ import {RiArrowLeftLine,RiCloseLine,} from '@remixicon/react'-import React, { useMemo } from 'react'+import * as React from 'react'+import { useMemo } from 'react'import { useTranslation } from 'react-i18next'import ActionButton from '@/app/components/base/action-button'import Divider from '@/app/components/base/divider'diff --git a/web/app/components/plugins/plugin-detail-panel/strategy-item.tsx b/web/app/components/plugins/plugin-detail-panel/strategy-item.tsxindex 19adbd707d1..280f1bce49a 100644--- a/web/app/components/plugins/plugin-detail-panel/strategy-item.tsx+++ b/web/app/components/plugins/plugin-detail-panel/strategy-item.tsx@@ -3,7 +3,8 @@ import type {StrategyDetail,} from '@/app/components/plugins/types'import type { Locale } from '@/i18n-config'-import React, { useState } from 'react'+import * as React from 'react'+import { useState } from 'react'import { useRenderI18nObject } from '@/hooks/use-i18n'import { cn } from '@/utils/classnames'import StrategyDetailPanel from './strategy-detail'diff --git a/web/app/components/plugins/plugin-detail-panel/subscription-list/create/common-modal.tsx b/web/app/components/plugins/plugin-detail-panel/subscription-list/create/common-modal.tsxindex 51b661d2ba5..16a789e67be 100644--- a/web/app/components/plugins/plugin-detail-panel/subscription-list/create/common-modal.tsx+++ b/web/app/components/plugins/plugin-detail-panel/subscription-list/create/common-modal.tsx@@ -4,7 +4,8 @@ import type { TriggerSubscriptionBuilder } from '@/app/components/workflow/blockimport type { BuildTriggerSubscriptionPayload } from '@/service/use-triggers'import { RiLoader2Line } from '@remixicon/react'import { debounce } from 'lodash-es'-import React, { useCallback, useEffect, useMemo, useRef, useState } from 'react'+import * as React from 'react'+import { useCallback, useEffect, useMemo, useRef, useState } from 'react'import { useTranslation } from 'react-i18next'// import { CopyFeedbackNew } from '@/app/components/base/copy-feedback'import { EncryptedBottom } from '@/app/components/base/encrypted-bottom'diff --git a/web/app/components/plugins/plugin-detail-panel/subscription-list/create/oauth-client.tsx b/web/app/components/plugins/plugin-detail-panel/subscription-list/create/oauth-client.tsxindex d4c1b79c163..6c1094559e8 100644--- a/web/app/components/plugins/plugin-detail-panel/subscription-list/create/oauth-client.tsx+++ b/web/app/components/plugins/plugin-detail-panel/subscription-list/create/oauth-client.tsx@@ -6,7 +6,8 @@ import {RiClipboardLine,RiInformation2Fill,} from '@remixicon/react'-import React, { useEffect, useMemo, useState } from 'react'+import * as React from 'react'+import { useEffect, useMemo, useState } from 'react'import { useTranslation } from 'react-i18next'import Button from '@/app/components/base/button'import { BaseForm } from '@/app/components/base/form/components/base'diff --git a/web/app/components/plugins/plugin-detail-panel/subscription-list/list-view.tsx b/web/app/components/plugins/plugin-detail-panel/subscription-list/list-view.tsxindex fd007409a4d..628f561ca22 100644--- a/web/app/components/plugins/plugin-detail-panel/subscription-list/list-view.tsx+++ b/web/app/components/plugins/plugin-detail-panel/subscription-list/list-view.tsx@@ -1,5 +1,5 @@'use client'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import Tooltip from '@/app/components/base/tooltip'import { cn } from '@/utils/classnames'diff --git a/web/app/components/plugins/plugin-detail-panel/subscription-list/log-viewer.tsx b/web/app/components/plugins/plugin-detail-panel/subscription-list/log-viewer.tsxindex d042653a1b8..f7ba8d8c358 100644--- a/web/app/components/plugins/plugin-detail-panel/subscription-list/log-viewer.tsx+++ b/web/app/components/plugins/plugin-detail-panel/subscription-list/log-viewer.tsx@@ -8,7 +8,8 @@ import {RiFileCopyLine,} from '@remixicon/react'import dayjs from 'dayjs'-import React, { useState } from 'react'+import * as React from 'react'+import { useState } from 'react'import { useTranslation } from 'react-i18next'import Toast from '@/app/components/base/toast'import CodeEditor from '@/app/components/workflow/nodes/_base/components/editor/code-editor'diff --git a/web/app/components/plugins/plugin-detail-panel/subscription-list/selector-view.tsx b/web/app/components/plugins/plugin-detail-panel/subscription-list/selector-view.tsxindex b98b8cc2023..4fd1cdd7d25 100644--- a/web/app/components/plugins/plugin-detail-panel/subscription-list/selector-view.tsx+++ b/web/app/components/plugins/plugin-detail-panel/subscription-list/selector-view.tsx@@ -1,7 +1,8 @@'use client'import type { TriggerSubscription } from '@/app/components/workflow/block-selector/types'import { RiCheckLine, RiDeleteBinLine, RiWebhookLine } from '@remixicon/react'-import React, { useState } from 'react'+import * as React from 'react'+import { useState } from 'react'import { useTranslation } from 'react-i18next'import ActionButton from '@/app/components/base/action-button'import Tooltip from '@/app/components/base/tooltip'diff --git a/web/app/components/plugins/plugin-detail-panel/tool-selector/index.tsx b/web/app/components/plugins/plugin-detail-panel/tool-selector/index.tsxindex bbfcc1fa097..2402a2af646 100644--- a/web/app/components/plugins/plugin-detail-panel/tool-selector/index.tsx+++ b/web/app/components/plugins/plugin-detail-panel/tool-selector/index.tsx@@ -8,7 +8,8 @@ import type { Node } from 'reactflow'import type { ToolDefaultValue, ToolValue } from '@/app/components/workflow/block-selector/types'import type { NodeOutPutVar } from '@/app/components/workflow/types'import Link from 'next/link'-import React, { useMemo, useState } from 'react'+import * as React from 'react'+import { useMemo, useState } from 'react'import { useTranslation } from 'react-i18next'import Divider from '@/app/components/base/divider'import {diff --git a/web/app/components/plugins/plugin-detail-panel/tool-selector/schema-modal.tsx b/web/app/components/plugins/plugin-detail-panel/tool-selector/schema-modal.tsxindex 6801a6df887..7b19707bb02 100644--- a/web/app/components/plugins/plugin-detail-panel/tool-selector/schema-modal.tsx+++ b/web/app/components/plugins/plugin-detail-panel/tool-selector/schema-modal.tsx@@ -2,7 +2,7 @@import type { FC } from 'react'import type { SchemaRoot } from '@/app/components/workflow/nodes/llm/types'import { RiCloseLine } from '@remixicon/react'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import Modal from '@/app/components/base/modal'import VisualEditor from '@/app/components/workflow/nodes/llm/components/json-schema-config-modal/visual-editor'diff --git a/web/app/components/plugins/plugin-detail-panel/tool-selector/tool-credentials-form.tsx b/web/app/components/plugins/plugin-detail-panel/tool-selector/tool-credentials-form.tsxindex 342d91a0845..eadbb4104c1 100644--- a/web/app/components/plugins/plugin-detail-panel/tool-selector/tool-credentials-form.tsx+++ b/web/app/components/plugins/plugin-detail-panel/tool-selector/tool-credentials-form.tsx@@ -4,7 +4,8 @@ import type { Collection } from '@/app/components/tools/types'import {RiArrowRightUpLine,} from '@remixicon/react'-import React, { useEffect, useState } from 'react'+import * as React from 'react'+import { useEffect, useState } from 'react'import { useTranslation } from 'react-i18next'import Button from '@/app/components/base/button'import Loading from '@/app/components/base/loading'diff --git a/web/app/components/plugins/plugin-detail-panel/tool-selector/tool-item.tsx b/web/app/components/plugins/plugin-detail-panel/tool-selector/tool-item.tsxindex 09d0eb898fb..4cea66e5052 100644--- a/web/app/components/plugins/plugin-detail-panel/tool-selector/tool-item.tsx+++ b/web/app/components/plugins/plugin-detail-panel/tool-selector/tool-item.tsx@@ -4,7 +4,8 @@ import {RiEqualizer2Line,RiErrorWarningFill,} from '@remixicon/react'-import React, { useState } from 'react'+import * as React from 'react'+import { useState } from 'react'import { useTranslation } from 'react-i18next'import ActionButton from '@/app/components/base/action-button'import AppIcon from '@/app/components/base/app-icon'diff --git a/web/app/components/plugins/plugin-detail-panel/tool-selector/tool-trigger.tsx b/web/app/components/plugins/plugin-detail-panel/tool-selector/tool-trigger.tsxindex bfad698fff2..e7c8d1e3e0f 100644--- a/web/app/components/plugins/plugin-detail-panel/tool-selector/tool-trigger.tsx+++ b/web/app/components/plugins/plugin-detail-panel/tool-selector/tool-trigger.tsx@@ -4,7 +4,7 @@ import {RiArrowDownSLine,RiEqualizer2Line,} from '@remixicon/react'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import BlockIcon from '@/app/components/workflow/block-icon'import { BlockEnum } from '@/app/components/workflow/types'diff --git a/web/app/components/plugins/plugin-item/action.tsx b/web/app/components/plugins/plugin-item/action.tsxindex 87830a745b9..3644dee76f0 100644--- a/web/app/components/plugins/plugin-item/action.tsx+++ b/web/app/components/plugins/plugin-item/action.tsx@@ -4,7 +4,8 @@ import type { MetaData } from '../types'import type { PluginCategoryEnum } from '@/app/components/plugins/types'import { RiDeleteBinLine, RiInformation2Line, RiLoopLeftLine } from '@remixicon/react'import { useBoolean } from 'ahooks'-import React, { useCallback } from 'react'+import * as React from 'react'+import { useCallback } from 'react'import { useTranslation } from 'react-i18next'import Toast from '@/app/components/base/toast'import { useModalContext } from '@/context/modal-context'diff --git a/web/app/components/plugins/plugin-item/index.tsx b/web/app/components/plugins/plugin-item/index.tsxindex fe884f69b24..b2ee45bf68e 100644--- a/web/app/components/plugins/plugin-item/index.tsx+++ b/web/app/components/plugins/plugin-item/index.tsx@@ -8,7 +8,8 @@ import {RiHardDrive3Line,RiLoginCircleLine,} from '@remixicon/react'-import React, { useCallback, useMemo } from 'react'+import * as React from 'react'+import { useCallback, useMemo } from 'react'import { useTranslation } from 'react-i18next'import { gte } from 'semver'import Tooltip from '@/app/components/base/tooltip'diff --git a/web/app/components/plugins/plugin-mutation-model/index.tsx b/web/app/components/plugins/plugin-mutation-model/index.tsxindex 09eb72a6569..2ac53683462 100644--- a/web/app/components/plugins/plugin-mutation-model/index.tsx+++ b/web/app/components/plugins/plugin-mutation-model/index.tsx@@ -1,7 +1,8 @@import type { UseMutationResult } from '@tanstack/react-query'import type { FC, ReactNode } from 'react'import type { Plugin } from '../types'-import React, { memo } from 'react'+import * as React from 'react'+import { memo } from 'react'import Button from '@/app/components/base/button'import Modal from '@/app/components/base/modal'import Card from '@/app/components/plugins/card'diff --git a/web/app/components/plugins/plugin-page/debug-info.tsx b/web/app/components/plugins/plugin-page/debug-info.tsxindex 69b22001c95..ea6d0afccf7 100644--- a/web/app/components/plugins/plugin-page/debug-info.tsx+++ b/web/app/components/plugins/plugin-page/debug-info.tsx@@ -4,7 +4,7 @@ import {RiArrowRightUpLine,RiBugLine,} from '@remixicon/react'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import { useContext } from 'use-context-selector'import Button from '@/app/components/base/button'diff --git a/web/app/components/plugins/plugin-page/empty/index.tsx b/web/app/components/plugins/plugin-page/empty/index.tsxindex 83b67c2320c..4d8904d2935 100644--- a/web/app/components/plugins/plugin-page/empty/index.tsx+++ b/web/app/components/plugins/plugin-page/empty/index.tsx@@ -1,6 +1,7 @@'use client'import { noop } from 'lodash-es'-import React, { useEffect, useMemo, useRef, useState } from 'react'+import * as React from 'react'+import { useEffect, useMemo, useRef, useState } from 'react'import { useTranslation } from 'react-i18next'import Button from '@/app/components/base/button'import { Group } from '@/app/components/base/icons/src/vender/other'diff --git a/web/app/components/plugins/plugin-page/filter-management/index.tsx b/web/app/components/plugins/plugin-page/filter-management/index.tsxindex cc4d64759e5..ad1b3329c65 100644--- a/web/app/components/plugins/plugin-page/filter-management/index.tsx+++ b/web/app/components/plugins/plugin-page/filter-management/index.tsx@@ -1,4 +1,5 @@-import React, { useState } from 'react'+import * as React from 'react'+import { useState } from 'react'import { usePluginPageContext } from '../context'import CategoriesFilter from './category-filter'import SearchBox from './search-box'diff --git a/web/app/components/plugins/plugin-page/plugin-info.tsx b/web/app/components/plugins/plugin-page/plugin-info.tsxindex cc41fb88b81..fdc09b91c25 100644--- a/web/app/components/plugins/plugin-page/plugin-info.tsx+++ b/web/app/components/plugins/plugin-page/plugin-info.tsx@@ -1,6 +1,6 @@'use client'import type { FC } from 'react'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import Modal from '../../base/modal'import KeyValueItem from '../base/key-value-item'diff --git a/web/app/components/plugins/provider-card.tsx b/web/app/components/plugins/provider-card.tsxindex ad3f0f005d2..3470d28495f 100644--- a/web/app/components/plugins/provider-card.tsx+++ b/web/app/components/plugins/provider-card.tsx@@ -4,7 +4,8 @@ import type { Plugin } from './types'import { RiArrowRightUpLine } from '@remixicon/react'import { useBoolean } from 'ahooks'import { useTheme } from 'next-themes'-import React, { useMemo } from 'react'+import * as React from 'react'+import { useMemo } from 'react'import { useTranslation } from 'react-i18next'import Button from '@/app/components/base/button'import InstallFromMarketplace from '@/app/components/plugins/install-plugin/install-from-marketplace'diff --git a/web/app/components/plugins/readme-panel/entrance.tsx b/web/app/components/plugins/readme-panel/entrance.tsxindex 611796d70d5..9060041476c 100644--- a/web/app/components/plugins/readme-panel/entrance.tsx+++ b/web/app/components/plugins/readme-panel/entrance.tsx@@ -1,6 +1,6 @@import type { PluginDetail } from '../types'import { RiBookReadLine } from '@remixicon/react'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import { cn } from '@/utils/classnames'import { BUILTIN_TOOLS_ARRAY } from './constants'diff --git a/web/app/components/plugins/reference-setting-modal/auto-update-setting/index.tsx b/web/app/components/plugins/reference-setting-modal/auto-update-setting/index.tsxindex 05b826f22d8..92ff0d87865 100644--- a/web/app/components/plugins/reference-setting-modal/auto-update-setting/index.tsx+++ b/web/app/components/plugins/reference-setting-modal/auto-update-setting/index.tsx@@ -3,7 +3,8 @@ import type { FC } from 'react'import type { AutoUpdateConfig } from './types'import type { TriggerParams } from '@/app/components/base/date-and-time-picker/types'import { RiTimeLine } from '@remixicon/react'-import React, { useCallback, useMemo } from 'react'+import * as React from 'react'+import { useCallback, useMemo } from 'react'import { Trans, useTranslation } from 'react-i18next'import TimePicker from '@/app/components/base/date-and-time-picker/time-picker'import { convertTimezoneToOffsetStr } from '@/app/components/base/date-and-time-picker/utils/dayjs'diff --git a/web/app/components/plugins/reference-setting-modal/auto-update-setting/no-data-placeholder.tsx b/web/app/components/plugins/reference-setting-modal/auto-update-setting/no-data-placeholder.tsxindex 8e2b00dab71..84f78c45cd5 100644--- a/web/app/components/plugins/reference-setting-modal/auto-update-setting/no-data-placeholder.tsx+++ b/web/app/components/plugins/reference-setting-modal/auto-update-setting/no-data-placeholder.tsx@@ -1,6 +1,6 @@'use client'import type { FC } from 'react'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import { SearchMenu } from '@/app/components/base/icons/src/vender/line/general'import { Group } from '@/app/components/base/icons/src/vender/other'diff --git a/web/app/components/plugins/reference-setting-modal/auto-update-setting/no-plugin-selected.tsx b/web/app/components/plugins/reference-setting-modal/auto-update-setting/no-plugin-selected.tsxindex 4e1301e92fa..0f3f6e8b8c0 100644--- a/web/app/components/plugins/reference-setting-modal/auto-update-setting/no-plugin-selected.tsx+++ b/web/app/components/plugins/reference-setting-modal/auto-update-setting/no-plugin-selected.tsx@@ -1,6 +1,6 @@'use client'import type { FC } from 'react'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import { AUTO_UPDATE_MODE } from './types'diff --git a/web/app/components/plugins/reference-setting-modal/auto-update-setting/plugins-picker.tsx b/web/app/components/plugins/reference-setting-modal/auto-update-setting/plugins-picker.tsxindex 7a3f864ac46..ead94726061 100644--- a/web/app/components/plugins/reference-setting-modal/auto-update-setting/plugins-picker.tsx+++ b/web/app/components/plugins/reference-setting-modal/auto-update-setting/plugins-picker.tsx@@ -2,7 +2,7 @@import type { FC } from 'react'import { RiAddLine } from '@remixicon/react'import { useBoolean } from 'ahooks'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import Button from '@/app/components/base/button'import NoPluginSelected from './no-plugin-selected'diff --git a/web/app/components/plugins/reference-setting-modal/auto-update-setting/plugins-selected.tsx b/web/app/components/plugins/reference-setting-modal/auto-update-setting/plugins-selected.tsxindex 72b5b7398a6..0284ec8a7f5 100644--- a/web/app/components/plugins/reference-setting-modal/auto-update-setting/plugins-selected.tsx+++ b/web/app/components/plugins/reference-setting-modal/auto-update-setting/plugins-selected.tsx@@ -1,6 +1,6 @@'use client'import type { FC } from 'react'-import React from 'react'+import * as React from 'react'import Icon from '@/app/components/plugins/card/base/card-icon'import { MARKETPLACE_API_PREFIX } from '@/config'import { cn } from '@/utils/classnames'diff --git a/web/app/components/plugins/reference-setting-modal/auto-update-setting/tool-item.tsx b/web/app/components/plugins/reference-setting-modal/auto-update-setting/tool-item.tsxindex 48f7ff37ab5..5a6dc081812 100644--- a/web/app/components/plugins/reference-setting-modal/auto-update-setting/tool-item.tsx+++ b/web/app/components/plugins/reference-setting-modal/auto-update-setting/tool-item.tsx@@ -1,7 +1,7 @@'use client'import type { FC } from 'react'import type { PluginDetail } from '@/app/components/plugins/types'-import React from 'react'+import * as React from 'react'import Checkbox from '@/app/components/base/checkbox'import Icon from '@/app/components/plugins/card/base/card-icon'import { MARKETPLACE_API_PREFIX } from '@/config'diff --git a/web/app/components/plugins/reference-setting-modal/auto-update-setting/tool-picker.tsx b/web/app/components/plugins/reference-setting-modal/auto-update-setting/tool-picker.tsxindex 3020bd96f1d..b0632774000 100644--- a/web/app/components/plugins/reference-setting-modal/auto-update-setting/tool-picker.tsx+++ b/web/app/components/plugins/reference-setting-modal/auto-update-setting/tool-picker.tsx@@ -1,6 +1,7 @@'use client'import type { FC } from 'react'-import React, { useCallback, useMemo, useState } from 'react'+import * as React from 'react'+import { useCallback, useMemo, useState } from 'react'import { useTranslation } from 'react-i18next'import Loading from '@/app/components/base/loading'import {diff --git a/web/app/components/plugins/reference-setting-modal/label.tsx b/web/app/components/plugins/reference-setting-modal/label.tsxindex dc39c12b285..720361d79a5 100644--- a/web/app/components/plugins/reference-setting-modal/label.tsx+++ b/web/app/components/plugins/reference-setting-modal/label.tsx@@ -1,6 +1,6 @@'use client'import type { FC } from 'react'-import React from 'react'+import * as React from 'react'import { cn } from '@/utils/classnames'type Props = {diff --git a/web/app/components/plugins/reference-setting-modal/modal.tsx b/web/app/components/plugins/reference-setting-modal/modal.tsxindex 7c6ff5df8d4..bc289601574 100644--- a/web/app/components/plugins/reference-setting-modal/modal.tsx+++ b/web/app/components/plugins/reference-setting-modal/modal.tsx@@ -2,7 +2,8 @@import type { FC } from 'react'import type { AutoUpdateConfig } from './auto-update-setting/types'import type { Permissions, ReferenceSetting } from '@/app/components/plugins/types'-import React, { useCallback, useState } from 'react'+import * as React from 'react'+import { useCallback, useState } from 'react'import { useTranslation } from 'react-i18next'import Button from '@/app/components/base/button'import Modal from '@/app/components/base/modal'diff --git a/web/app/components/plugins/update-plugin/from-github.tsx b/web/app/components/plugins/update-plugin/from-github.tsxindex 437837d8d92..c4bf1a8a0ab 100644--- a/web/app/components/plugins/update-plugin/from-github.tsx+++ b/web/app/components/plugins/update-plugin/from-github.tsx@@ -1,7 +1,7 @@'use client'import type { FC } from 'react'import type { UpdateFromGitHubPayload } from '../types'-import React from 'react'+import * as React from 'react'import InstallFromGitHub from '../install-plugin/install-from-github'type Props = {diff --git a/web/app/components/plugins/update-plugin/from-market-place.tsx b/web/app/components/plugins/update-plugin/from-market-place.tsxindex d2802db54d0..b45f8d24d8e 100644--- a/web/app/components/plugins/update-plugin/from-market-place.tsx+++ b/web/app/components/plugins/update-plugin/from-market-place.tsx@@ -1,7 +1,8 @@'use client'import type { FC } from 'react'import type { UpdateFromMarketPlacePayload } from '../types'-import React, { useCallback, useEffect, useMemo, useState } from 'react'+import * as React from 'react'+import { useCallback, useEffect, useMemo, useState } from 'react'import { useTranslation } from 'react-i18next'import Badge, { BadgeState } from '@/app/components/base/badge/index'import Button from '@/app/components/base/button'diff --git a/web/app/components/plugins/update-plugin/index.tsx b/web/app/components/plugins/update-plugin/index.tsxindex 2ed3cef9e4d..f8f77e845a3 100644--- a/web/app/components/plugins/update-plugin/index.tsx+++ b/web/app/components/plugins/update-plugin/index.tsx@@ -1,7 +1,7 @@'use client'import type { FC } from 'react'import type { UpdatePluginModalType } from '../types'-import React from 'react'+import * as React from 'react'import { PluginSource } from '../types'import UpdateFromGitHub from './from-github'import UpdateFromMarketplace from './from-market-place'diff --git a/web/app/components/plugins/update-plugin/plugin-version-picker.tsx b/web/app/components/plugins/update-plugin/plugin-version-picker.tsxindex 3c18d7fc0b1..6562acdb6b6 100644--- a/web/app/components/plugins/update-plugin/plugin-version-picker.tsx+++ b/web/app/components/plugins/update-plugin/plugin-version-picker.tsx@@ -4,7 +4,8 @@ import type {Placement,} from '@floating-ui/react'import type { FC } from 'react'-import React, { useCallback } from 'react'+import * as React from 'react'+import { useCallback } from 'react'import { useTranslation } from 'react-i18next'import { lt } from 'semver'import Badge from '@/app/components/base/badge'diff --git a/web/app/components/rag-pipeline/components/chunk-card-list/chunk-card.tsx b/web/app/components/rag-pipeline/components/chunk-card-list/chunk-card.tsxindex 62e90dbf1c0..7efe1ff76ac 100644--- a/web/app/components/rag-pipeline/components/chunk-card-list/chunk-card.tsx+++ b/web/app/components/rag-pipeline/components/chunk-card-list/chunk-card.tsx@@ -1,6 +1,7 @@import type { QAChunk } from './types'import type { ParentMode } from '@/models/datasets'-import React, { useMemo } from 'react'+import * as React from 'react'+import { useMemo } from 'react'import { useTranslation } from 'react-i18next'import Dot from '@/app/components/datasets/documents/detail/completed/common/dot'import SegmentIndexTag from '@/app/components/datasets/documents/detail/completed/common/segment-index-tag'diff --git a/web/app/components/rag-pipeline/components/chunk-card-list/q-a-item.tsx b/web/app/components/rag-pipeline/components/chunk-card-list/q-a-item.tsxindex 4a34222e1d2..bd317a2ce45 100644--- a/web/app/components/rag-pipeline/components/chunk-card-list/q-a-item.tsx+++ b/web/app/components/rag-pipeline/components/chunk-card-list/q-a-item.tsx@@ -1,4 +1,4 @@-import React from 'react'+import * as React from 'react'import { QAItemType } from './types'type QAItemProps = {diff --git a/web/app/components/rag-pipeline/components/conversion.tsx b/web/app/components/rag-pipeline/components/conversion.tsxindex 3e55350d4c1..8e20df54b43 100644--- a/web/app/components/rag-pipeline/components/conversion.tsx+++ b/web/app/components/rag-pipeline/components/conversion.tsx@@ -1,5 +1,6 @@import { useParams } from 'next/navigation'-import React, { useCallback, useState } from 'react'+import * as React from 'react'+import { useCallback, useState } from 'react'import { useTranslation } from 'react-i18next'import Button from '@/app/components/base/button'import Confirm from '@/app/components/base/confirm'diff --git a/web/app/components/rag-pipeline/components/panel/input-field/editor/form/hidden-fields.tsx b/web/app/components/rag-pipeline/components/panel/input-field/editor/form/hidden-fields.tsxindex 4d052f39cdc..f7b35e79164 100644--- a/web/app/components/rag-pipeline/components/panel/input-field/editor/form/hidden-fields.tsx+++ b/web/app/components/rag-pipeline/components/panel/input-field/editor/form/hidden-fields.tsx@@ -1,5 +1,5 @@import { useStore } from '@tanstack/react-form'-import React from 'react'+import * as React from 'react'import { withForm } from '@/app/components/base/form'import InputField from '@/app/components/base/form/form-scenarios/input-field/field'import { useHiddenConfigurations } from './hooks'diff --git a/web/app/components/rag-pipeline/components/panel/input-field/editor/form/initial-fields.tsx b/web/app/components/rag-pipeline/components/panel/input-field/editor/form/initial-fields.tsxindex 9c6a0535097..1cd6e247894 100644--- a/web/app/components/rag-pipeline/components/panel/input-field/editor/form/initial-fields.tsx+++ b/web/app/components/rag-pipeline/components/panel/input-field/editor/form/initial-fields.tsx@@ -1,4 +1,5 @@-import React, { useCallback } from 'react'+import * as React from 'react'+import { useCallback } from 'react'import { withForm } from '@/app/components/base/form'import InputField from '@/app/components/base/form/form-scenarios/input-field/field'import { useConfigurations } from './hooks'diff --git a/web/app/components/rag-pipeline/components/panel/input-field/editor/form/show-all-settings.tsx b/web/app/components/rag-pipeline/components/panel/input-field/editor/form/show-all-settings.tsxindex 2a27710cd0a..ac8fa0f715f 100644--- a/web/app/components/rag-pipeline/components/panel/input-field/editor/form/show-all-settings.tsx+++ b/web/app/components/rag-pipeline/components/panel/input-field/editor/form/show-all-settings.tsx@@ -1,6 +1,6 @@import { RiArrowRightSLine } from '@remixicon/react'import { useStore } from '@tanstack/react-form'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import { withForm } from '@/app/components/base/form'import { useHiddenFieldNames } from './hooks'diff --git a/web/app/components/rag-pipeline/components/panel/input-field/field-list/field-item.tsx b/web/app/components/rag-pipeline/components/panel/input-field/field-list/field-item.tsxindex a76a4db7ba9..9b566b916c3 100644--- a/web/app/components/rag-pipeline/components/panel/input-field/field-list/field-item.tsx+++ b/web/app/components/rag-pipeline/components/panel/input-field/field-list/field-item.tsx@@ -7,7 +7,8 @@ import {RiEditLine,} from '@remixicon/react'import { useHover } from 'ahooks'-import React, { useCallback, useRef } from 'react'+import * as React from 'react'+import { useCallback, useRef } from 'react'import { useTranslation } from 'react-i18next'import ActionButton from '@/app/components/base/action-button'import Badge from '@/app/components/base/badge'diff --git a/web/app/components/rag-pipeline/components/panel/input-field/field-list/index.tsx b/web/app/components/rag-pipeline/components/panel/input-field/field-list/index.tsxindex 30d05bef408..0449f7c9a4b 100644--- a/web/app/components/rag-pipeline/components/panel/input-field/field-list/index.tsx+++ b/web/app/components/rag-pipeline/components/panel/input-field/field-list/index.tsx@@ -1,6 +1,7 @@import type { InputVar } from '@/models/pipeline'import { RiAddLine } from '@remixicon/react'-import React, { useCallback } from 'react'+import * as React from 'react'+import { useCallback } from 'react'import ActionButton from '@/app/components/base/action-button'import RemoveEffectVarConfirm from '@/app/components/workflow/nodes/_base/components/remove-effect-var-confirm'import { cn } from '@/utils/classnames'diff --git a/web/app/components/rag-pipeline/components/panel/input-field/footer-tip.tsx b/web/app/components/rag-pipeline/components/panel/input-field/footer-tip.tsxindex a173f36230d..4ee55861ec1 100644--- a/web/app/components/rag-pipeline/components/panel/input-field/footer-tip.tsx+++ b/web/app/components/rag-pipeline/components/panel/input-field/footer-tip.tsx@@ -1,5 +1,5 @@import { RiDragDropLine } from '@remixicon/react'-import React from 'react'+import * as React from 'react'const FooterTip = () => {return (diff --git a/web/app/components/rag-pipeline/components/panel/input-field/label-right-content/datasource.tsx b/web/app/components/rag-pipeline/components/panel/input-field/label-right-content/datasource.tsxindex 3f3481b511b..aecb250809c 100644--- a/web/app/components/rag-pipeline/components/panel/input-field/label-right-content/datasource.tsx+++ b/web/app/components/rag-pipeline/components/panel/input-field/label-right-content/datasource.tsx@@ -1,5 +1,5 @@import type { DataSourceNodeType } from '@/app/components/workflow/nodes/data-source/types'-import React from 'react'+import * as React from 'react'import BlockIcon from '@/app/components/workflow/block-icon'import { useToolIcon } from '@/app/components/workflow/hooks'import { BlockEnum } from '@/app/components/workflow/types'diff --git a/web/app/components/rag-pipeline/components/panel/input-field/label-right-content/global-inputs.tsx b/web/app/components/rag-pipeline/components/panel/input-field/label-right-content/global-inputs.tsxindex ead0f3c8518..601efe3221c 100644--- a/web/app/components/rag-pipeline/components/panel/input-field/label-right-content/global-inputs.tsx+++ b/web/app/components/rag-pipeline/components/panel/input-field/label-right-content/global-inputs.tsx@@ -1,4 +1,4 @@-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import Tooltip from '@/app/components/base/tooltip'diff --git a/web/app/components/rag-pipeline/components/panel/input-field/preview/data-source.tsx b/web/app/components/rag-pipeline/components/panel/input-field/preview/data-source.tsxindex cc216a6aaaf..e13336e773f 100644--- a/web/app/components/rag-pipeline/components/panel/input-field/preview/data-source.tsx+++ b/web/app/components/rag-pipeline/components/panel/input-field/preview/data-source.tsx@@ -1,5 +1,5 @@import type { Datasource } from '../../test-run/types'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import { useStore } from '@/app/components/workflow/store'import { useDraftPipelinePreProcessingParams } from '@/service/use-pipeline'diff --git a/web/app/components/rag-pipeline/components/panel/input-field/preview/process-documents.tsx b/web/app/components/rag-pipeline/components/panel/input-field/preview/process-documents.tsxindex c473e13adde..9beb2c364eb 100644--- a/web/app/components/rag-pipeline/components/panel/input-field/preview/process-documents.tsx+++ b/web/app/components/rag-pipeline/components/panel/input-field/preview/process-documents.tsx@@ -1,4 +1,4 @@-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import { useStore } from '@/app/components/workflow/store'import { useDraftPipelineProcessingParams } from '@/service/use-pipeline'diff --git a/web/app/components/rag-pipeline/components/panel/test-run/header.tsx b/web/app/components/rag-pipeline/components/panel/test-run/header.tsxindex a7949dd68f7..bc139201bb5 100644--- a/web/app/components/rag-pipeline/components/panel/test-run/header.tsx+++ b/web/app/components/rag-pipeline/components/panel/test-run/header.tsx@@ -1,5 +1,6 @@import { RiCloseLine } from '@remixicon/react'-import React, { useCallback } from 'react'+import * as React from 'react'+import { useCallback } from 'react'import { useTranslation } from 'react-i18next'import { useWorkflowInteractions } from '@/app/components/workflow/hooks'import { useWorkflowStore } from '@/app/components/workflow/store'diff --git a/web/app/components/rag-pipeline/components/panel/test-run/preparation/actions/index.tsx b/web/app/components/rag-pipeline/components/panel/test-run/preparation/actions/index.tsxindex 2e4e97c665e..4556031f316 100644--- a/web/app/components/rag-pipeline/components/panel/test-run/preparation/actions/index.tsx+++ b/web/app/components/rag-pipeline/components/panel/test-run/preparation/actions/index.tsx@@ -1,4 +1,4 @@-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import Button from '@/app/components/base/button'diff --git a/web/app/components/rag-pipeline/components/panel/test-run/preparation/data-source-options/option-card.tsx b/web/app/components/rag-pipeline/components/panel/test-run/preparation/data-source-options/option-card.tsxindex 1074276552e..7198d4d9886 100644--- a/web/app/components/rag-pipeline/components/panel/test-run/preparation/data-source-options/option-card.tsx+++ b/web/app/components/rag-pipeline/components/panel/test-run/preparation/data-source-options/option-card.tsx@@ -1,5 +1,6 @@import type { DataSourceNodeType } from '@/app/components/workflow/nodes/data-source/types'-import React, { useCallback } from 'react'+import * as React from 'react'+import { useCallback } from 'react'import BlockIcon from '@/app/components/workflow/block-icon'import { useToolIcon } from '@/app/components/workflow/hooks'import { BlockEnum } from '@/app/components/workflow/types'diff --git a/web/app/components/rag-pipeline/components/panel/test-run/preparation/document-processing/actions.tsx b/web/app/components/rag-pipeline/components/panel/test-run/preparation/document-processing/actions.tsxindex 47f06557d4d..a9f0c6bff6d 100644--- a/web/app/components/rag-pipeline/components/panel/test-run/preparation/document-processing/actions.tsx+++ b/web/app/components/rag-pipeline/components/panel/test-run/preparation/document-processing/actions.tsx@@ -1,5 +1,5 @@import type { CustomActionsProps } from '@/app/components/base/form/components/form/actions'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import Button from '@/app/components/base/button'import { useStore } from '@/app/components/workflow/store'diff --git a/web/app/components/rag-pipeline/components/panel/test-run/preparation/document-processing/index.tsx b/web/app/components/rag-pipeline/components/panel/test-run/preparation/document-processing/index.tsxindex c4ad280dceb..3186e5bb7d7 100644--- a/web/app/components/rag-pipeline/components/panel/test-run/preparation/document-processing/index.tsx+++ b/web/app/components/rag-pipeline/components/panel/test-run/preparation/document-processing/index.tsx@@ -1,5 +1,6 @@import type { CustomActionsProps } from '@/app/components/base/form/components/form/actions'-import React, { useCallback } from 'react'+import * as React from 'react'+import { useCallback } from 'react'import { generateZodSchema } from '@/app/components/base/form/form-scenarios/base/utils'import { useConfigurations, useInitialData } from '@/app/components/rag-pipeline/hooks/use-input-fields'import Actions from './actions'diff --git a/web/app/components/rag-pipeline/components/panel/test-run/preparation/footer-tips.tsx b/web/app/components/rag-pipeline/components/panel/test-run/preparation/footer-tips.tsxindex 58ea7489949..a2502838ea3 100644--- a/web/app/components/rag-pipeline/components/panel/test-run/preparation/footer-tips.tsx+++ b/web/app/components/rag-pipeline/components/panel/test-run/preparation/footer-tips.tsx@@ -1,4 +1,4 @@-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'const FooterTips = () => {diff --git a/web/app/components/rag-pipeline/components/panel/test-run/preparation/index.tsx b/web/app/components/rag-pipeline/components/panel/test-run/preparation/index.tsxindex b5ec39d985a..bf4f74493bc 100644--- a/web/app/components/rag-pipeline/components/panel/test-run/preparation/index.tsx+++ b/web/app/components/rag-pipeline/components/panel/test-run/preparation/index.tsx@@ -1,5 +1,6 @@import type { Datasource } from '../types'-import React, { useCallback, useMemo, useState } from 'react'+import * as React from 'react'+import { useCallback, useMemo, useState } from 'react'import { useShallow } from 'zustand/react/shallow'import { trackEvent } from '@/app/components/base/amplitude'import LocalFile from '@/app/components/datasets/documents/create-from-pipeline/data-source/local-file'diff --git a/web/app/components/rag-pipeline/components/panel/test-run/preparation/step-indicator.tsx b/web/app/components/rag-pipeline/components/panel/test-run/preparation/step-indicator.tsxindex 9ab7015e078..93c4af8047a 100644--- a/web/app/components/rag-pipeline/components/panel/test-run/preparation/step-indicator.tsx+++ b/web/app/components/rag-pipeline/components/panel/test-run/preparation/step-indicator.tsx@@ -1,4 +1,4 @@-import React from 'react'+import * as React from 'react'import Divider from '@/app/components/base/divider'import { cn } from '@/utils/classnames'diff --git a/web/app/components/rag-pipeline/components/panel/test-run/result/result-preview/index.tsx b/web/app/components/rag-pipeline/components/panel/test-run/result/result-preview/index.tsxindex 395fdc09e9c..92932dbc5f5 100644--- a/web/app/components/rag-pipeline/components/panel/test-run/result/result-preview/index.tsx+++ b/web/app/components/rag-pipeline/components/panel/test-run/result/result-preview/index.tsx@@ -1,5 +1,6 @@import { RiLoader2Line } from '@remixicon/react'-import React, { useMemo } from 'react'+import * as React from 'react'+import { useMemo } from 'react'import { useTranslation } from 'react-i18next'import Button from '@/app/components/base/button'import { RAG_PIPELINE_PREVIEW_CHUNK_NUM } from '@/config'diff --git a/web/app/components/rag-pipeline/components/panel/test-run/result/tabs/index.tsx b/web/app/components/rag-pipeline/components/panel/test-run/result/tabs/index.tsxindex 4e4d51eb027..7a64810710e 100644--- a/web/app/components/rag-pipeline/components/panel/test-run/result/tabs/index.tsx+++ b/web/app/components/rag-pipeline/components/panel/test-run/result/tabs/index.tsx@@ -1,5 +1,5 @@import type { WorkflowRunningData } from '@/app/components/workflow/types'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import Tab from './tab'diff --git a/web/app/components/rag-pipeline/components/panel/test-run/result/tabs/tab.tsx b/web/app/components/rag-pipeline/components/panel/test-run/result/tabs/tab.tsxindex 640a3feb170..ee9e3f5564e 100644--- a/web/app/components/rag-pipeline/components/panel/test-run/result/tabs/tab.tsx+++ b/web/app/components/rag-pipeline/components/panel/test-run/result/tabs/tab.tsx@@ -1,5 +1,6 @@import type { WorkflowRunningData } from '@/app/components/workflow/types'-import React, { useCallback } from 'react'+import * as React from 'react'+import { useCallback } from 'react'import { cn } from '@/utils/classnames'type TabProps = {diff --git a/web/app/components/rag-pipeline/components/rag-pipeline-header/run-mode.tsx b/web/app/components/rag-pipeline/components/rag-pipeline-header/run-mode.tsxindex 4d5066a285a..be5b4c11bd0 100644--- a/web/app/components/rag-pipeline/components/rag-pipeline-header/run-mode.tsx+++ b/web/app/components/rag-pipeline/components/rag-pipeline-header/run-mode.tsx@@ -1,5 +1,6 @@import { RiCloseLine, RiDatabase2Line, RiLoader2Line, RiPlayLargeLine } from '@remixicon/react'-import React, { useCallback } from 'react'+import * as React from 'react'+import { useCallback } from 'react'import { useTranslation } from 'react-i18next'import { StopCircle } from '@/app/components/base/icons/src/vender/line/mediaAndDevices'import { useWorkflowRun, useWorkflowStartRun } from '@/app/components/workflow/hooks'diff --git a/web/app/components/rag-pipeline/components/screenshot.tsx b/web/app/components/rag-pipeline/components/screenshot.tsxindex dae6f04161f..3138b846d95 100644--- a/web/app/components/rag-pipeline/components/screenshot.tsx+++ b/web/app/components/rag-pipeline/components/screenshot.tsx@@ -1,5 +1,5 @@import Image from 'next/image'-import React from 'react'+import * as React from 'react'import useTheme from '@/hooks/use-theme'import { basePath } from '@/utils/var'diff --git a/web/app/components/share/text-generation/index.tsx b/web/app/components/share/text-generation/index.tsxindex 5c58635e0fd..157ed123d18 100644--- a/web/app/components/share/text-generation/index.tsx+++ b/web/app/components/share/text-generation/index.tsx@@ -15,7 +15,8 @@ import {} from '@remixicon/react'import { useBoolean } from 'ahooks'import { useSearchParams } from 'next/navigation'-import React, { useCallback, useEffect, useRef, useState } from 'react'+import * as React from 'react'+import { useCallback, useEffect, useRef, useState } from 'react'import { useTranslation } from 'react-i18next'import SavedItems from '@/app/components/app/text-generate/saved-items'import AppIcon from '@/app/components/base/app-icon'diff --git a/web/app/components/share/text-generation/info-modal.tsx b/web/app/components/share/text-generation/info-modal.tsxindex e206e6d6c93..9ee6557cef6 100644--- a/web/app/components/share/text-generation/info-modal.tsx+++ b/web/app/components/share/text-generation/info-modal.tsx@@ -1,5 +1,5 @@import type { SiteInfo } from '@/models/share'-import React from 'react'+import * as React from 'react'import AppIcon from '@/app/components/base/app-icon'import Modal from '@/app/components/base/modal'import { appDefaultIconBackground } from '@/config'diff --git a/web/app/components/share/text-generation/menu-dropdown.tsx b/web/app/components/share/text-generation/menu-dropdown.tsxindex 270789f2c6a..c96c9ffa322 100644--- a/web/app/components/share/text-generation/menu-dropdown.tsx+++ b/web/app/components/share/text-generation/menu-dropdown.tsx@@ -6,7 +6,8 @@ import {RiEqualizer2Line,} from '@remixicon/react'import { usePathname, useRouter } from 'next/navigation'-import React, { useCallback, useEffect, useRef, useState } from 'react'+import * as React from 'react'+import { useCallback, useEffect, useRef, useState } from 'react'import { useTranslation } from 'react-i18next'import ActionButton from '@/app/components/base/action-button'import {diff --git a/web/app/components/share/text-generation/no-data/index.spec.tsx b/web/app/components/share/text-generation/no-data/index.spec.tsxindex 14a86a3c1b3..41de9907fda 100644--- a/web/app/components/share/text-generation/no-data/index.spec.tsx+++ b/web/app/components/share/text-generation/no-data/index.spec.tsx@@ -1,5 +1,5 @@import { render, screen } from '@testing-library/react'-import React from 'react'+import * as React from 'react'import NoData from './index'describe('NoData', () => {diff --git a/web/app/components/share/text-generation/no-data/index.tsx b/web/app/components/share/text-generation/no-data/index.tsxindex 5e10c821f8a..f99c0af57d1 100644--- a/web/app/components/share/text-generation/no-data/index.tsx+++ b/web/app/components/share/text-generation/no-data/index.tsx@@ -2,7 +2,7 @@ import type { FC } from 'react'import {RiSparklingFill,} from '@remixicon/react'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'export type INoDataProps = {}diff --git a/web/app/components/share/text-generation/result/content.tsx b/web/app/components/share/text-generation/result/content.tsxindex ec7c439ea91..01161d6dcd0 100644--- a/web/app/components/share/text-generation/result/content.tsx+++ b/web/app/components/share/text-generation/result/content.tsx@@ -1,6 +1,6 @@import type { FC } from 'react'import type { FeedbackType } from '@/app/components/base/chat/chat/type'-import React from 'react'+import * as React from 'react'import { format } from '@/service/base'import Header from './header'diff --git a/web/app/components/share/text-generation/result/header.tsx b/web/app/components/share/text-generation/result/header.tsxindex b2cacfc3c5e..409aad5cefd 100644--- a/web/app/components/share/text-generation/result/header.tsx+++ b/web/app/components/share/text-generation/result/header.tsx@@ -3,7 +3,7 @@ import type { FC } from 'react'import type { FeedbackType } from '@/app/components/base/chat/chat/type'import { ClipboardDocumentIcon, HandThumbDownIcon, HandThumbUpIcon } from '@heroicons/react/24/outline'import copy from 'copy-to-clipboard'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import Button from '@/app/components/base/button'import Toast from '@/app/components/base/toast'diff --git a/web/app/components/share/text-generation/result/index.tsx b/web/app/components/share/text-generation/result/index.tsxindex 1b40b48d450..902da881ae2 100644--- a/web/app/components/share/text-generation/result/index.tsx+++ b/web/app/components/share/text-generation/result/index.tsx@@ -11,7 +11,8 @@ import { RiLoader2Line } from '@remixicon/react'import { useBoolean } from 'ahooks'import { t } from 'i18next'import { produce } from 'immer'-import React, { useCallback, useEffect, useRef, useState } from 'react'+import * as React from 'react'+import { useCallback, useEffect, useRef, useState } from 'react'import TextGenerationRes from '@/app/components/app/text-generate/item'import Button from '@/app/components/base/button'import {diff --git a/web/app/components/share/text-generation/run-batch/csv-download/index.spec.tsx b/web/app/components/share/text-generation/run-batch/csv-download/index.spec.tsxindex 385ccb91df7..120e3ed0c2e 100644--- a/web/app/components/share/text-generation/run-batch/csv-download/index.spec.tsx+++ b/web/app/components/share/text-generation/run-batch/csv-download/index.spec.tsx@@ -1,5 +1,5 @@import { render, screen } from '@testing-library/react'-import React from 'react'+import * as React from 'react'import CSVDownload from './index'const mockType = { Link: 'mock-link' }diff --git a/web/app/components/share/text-generation/run-batch/csv-download/index.tsx b/web/app/components/share/text-generation/run-batch/csv-download/index.tsxindex a7e6d5bf2cc..eb1f9aa86af 100644--- a/web/app/components/share/text-generation/run-batch/csv-download/index.tsx+++ b/web/app/components/share/text-generation/run-batch/csv-download/index.tsx@@ -1,6 +1,6 @@'use client'import type { FC } from 'react'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import {useCSVDownloader,diff --git a/web/app/components/share/text-generation/run-batch/csv-reader/index.spec.tsx b/web/app/components/share/text-generation/run-batch/csv-reader/index.spec.tsxindex 1b93e7b9f9a..83e89a0a045 100644--- a/web/app/components/share/text-generation/run-batch/csv-reader/index.spec.tsx+++ b/web/app/components/share/text-generation/run-batch/csv-reader/index.spec.tsx@@ -1,5 +1,5 @@import { act, render, screen, waitFor } from '@testing-library/react'-import React from 'react'+import * as React from 'react'import CSVReader from './index'let mockAcceptedFile: { name: string } | null = nulldiff --git a/web/app/components/share/text-generation/run-batch/csv-reader/index.tsx b/web/app/components/share/text-generation/run-batch/csv-reader/index.tsxindex 895d472297b..95488c1e852 100644--- a/web/app/components/share/text-generation/run-batch/csv-reader/index.tsx+++ b/web/app/components/share/text-generation/run-batch/csv-reader/index.tsx@@ -1,6 +1,7 @@'use client'import type { FC } from 'react'-import React, { useState } from 'react'+import * as React from 'react'+import { useState } from 'react'import { useTranslation } from 'react-i18next'import {useCSVReader,diff --git a/web/app/components/share/text-generation/run-batch/index.spec.tsx b/web/app/components/share/text-generation/run-batch/index.spec.tsxindex a3c3bbfd402..4359a66a584 100644--- a/web/app/components/share/text-generation/run-batch/index.spec.tsx+++ b/web/app/components/share/text-generation/run-batch/index.spec.tsx@@ -1,6 +1,6 @@import type { Mock } from 'vitest'import { act, fireEvent, render, screen, waitFor } from '@testing-library/react'-import React from 'react'+import * as React from 'react'import useBreakpoints, { MediaType } from '@/hooks/use-breakpoints'import RunBatch from './index'diff --git a/web/app/components/share/text-generation/run-batch/index.tsx b/web/app/components/share/text-generation/run-batch/index.tsxindex 74e77e61656..793817f191b 100644--- a/web/app/components/share/text-generation/run-batch/index.tsx+++ b/web/app/components/share/text-generation/run-batch/index.tsx@@ -4,7 +4,7 @@ import {RiLoader2Line,RiPlayLargeLine,} from '@remixicon/react'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import Button from '@/app/components/base/button'import useBreakpoints, { MediaType } from '@/hooks/use-breakpoints'diff --git a/web/app/components/share/text-generation/run-batch/res-download/index.spec.tsx b/web/app/components/share/text-generation/run-batch/res-download/index.spec.tsxindex 2a4ec0b3c17..b71b252345e 100644--- a/web/app/components/share/text-generation/run-batch/res-download/index.spec.tsx+++ b/web/app/components/share/text-generation/run-batch/res-download/index.spec.tsx@@ -1,5 +1,5 @@import { render, screen } from '@testing-library/react'-import React from 'react'+import * as React from 'react'import ResDownload from './index'const mockType = { Link: 'mock-link' }diff --git a/web/app/components/share/text-generation/run-batch/res-download/index.tsx b/web/app/components/share/text-generation/run-batch/res-download/index.tsxindex cdc2b8f41b0..d7c42362fd1 100644--- a/web/app/components/share/text-generation/run-batch/res-download/index.tsx+++ b/web/app/components/share/text-generation/run-batch/res-download/index.tsx@@ -1,7 +1,7 @@'use client'import type { FC } from 'react'import { RiDownloadLine } from '@remixicon/react'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import {useCSVDownloader,diff --git a/web/app/components/share/text-generation/run-once/index.spec.tsx b/web/app/components/share/text-generation/run-once/index.spec.tsxindex 4283409c1bc..abead21c07e 100644--- a/web/app/components/share/text-generation/run-once/index.spec.tsx+++ b/web/app/components/share/text-generation/run-once/index.spec.tsx@@ -2,7 +2,8 @@ import type { PromptConfig, PromptVariable } from '@/models/debug'import type { SiteInfo } from '@/models/share'import type { VisionSettings } from '@/types/app'import { fireEvent, render, screen, waitFor } from '@testing-library/react'-import React, { useEffect, useRef, useState } from 'react'+import * as React from 'react'+import { useEffect, useRef, useState } from 'react'import { Resolution, TransferMethod } from '@/types/app'import RunOnce from './index'diff --git a/web/app/components/share/text-generation/run-once/index.tsx b/web/app/components/share/text-generation/run-once/index.tsxindex 09bd4872cba..eea2b1592cb 100644--- a/web/app/components/share/text-generation/run-once/index.tsx+++ b/web/app/components/share/text-generation/run-once/index.tsx@@ -6,7 +6,8 @@ import {RiLoader2Line,RiPlayLargeLine,} from '@remixicon/react'-import React, { useCallback, useEffect, useState } from 'react'+import * as React from 'react'+import { useCallback, useEffect, useState } from 'react'import { useTranslation } from 'react-i18next'import Button from '@/app/components/base/button'import { FileUploaderInAttachmentWrapper } from '@/app/components/base/file-uploader'diff --git a/web/app/components/splash.tsx b/web/app/components/splash.tsxindex 031b9b32305..e4103e8c930 100644--- a/web/app/components/splash.tsx+++ b/web/app/components/splash.tsx@@ -1,6 +1,6 @@'use client'import type { FC, PropsWithChildren } from 'react'-import React from 'react'+import * as React from 'react'import { useIsLogin } from '@/service/use-common'import Loading from './base/loading'diff --git a/web/app/components/tools/edit-custom-collection-modal/config-credentials.tsx b/web/app/components/tools/edit-custom-collection-modal/config-credentials.tsxindex 19fa90fc252..1fa5e23347b 100644--- a/web/app/components/tools/edit-custom-collection-modal/config-credentials.tsx+++ b/web/app/components/tools/edit-custom-collection-modal/config-credentials.tsx@@ -1,7 +1,7 @@'use client'import type { FC } from 'react'import type { Credential } from '@/app/components/tools/types'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import Button from '@/app/components/base/button'import Drawer from '@/app/components/base/drawer-plus'diff --git a/web/app/components/tools/edit-custom-collection-modal/get-schema.tsx b/web/app/components/tools/edit-custom-collection-modal/get-schema.tsxindex fa4f45e75f9..4ecee282f98 100644--- a/web/app/components/tools/edit-custom-collection-modal/get-schema.tsx+++ b/web/app/components/tools/edit-custom-collection-modal/get-schema.tsx@@ -5,7 +5,8 @@ import {RiArrowDownSLine,} from '@remixicon/react'import { useClickAway } from 'ahooks'-import React, { useState } from 'react'+import * as React from 'react'+import { useState } from 'react'import { useTranslation } from 'react-i18next'import Button from '@/app/components/base/button'import Input from '@/app/components/base/input'diff --git a/web/app/components/tools/edit-custom-collection-modal/index.tsx b/web/app/components/tools/edit-custom-collection-modal/index.tsxindex 276230aa1ba..93ef9142d90 100644--- a/web/app/components/tools/edit-custom-collection-modal/index.tsx+++ b/web/app/components/tools/edit-custom-collection-modal/index.tsx@@ -4,7 +4,8 @@ import type { Credential, CustomCollectionBackend, CustomParamSchema, Emoji } frimport { RiSettings2Line } from '@remixicon/react'import { useDebounce, useGetState } from 'ahooks'import { produce } from 'immer'-import React, { useEffect, useState } from 'react'+import * as React from 'react'+import { useEffect, useState } from 'react'import { useTranslation } from 'react-i18next'import AppIcon from '@/app/components/base/app-icon'import Button from '@/app/components/base/button'diff --git a/web/app/components/tools/edit-custom-collection-modal/test-api.tsx b/web/app/components/tools/edit-custom-collection-modal/test-api.tsxindex 29cd543e1e4..8aacb7ad072 100644--- a/web/app/components/tools/edit-custom-collection-modal/test-api.tsx+++ b/web/app/components/tools/edit-custom-collection-modal/test-api.tsx@@ -2,7 +2,8 @@import type { FC } from 'react'import type { Credential, CustomCollectionBackend, CustomParamSchema } from '@/app/components/tools/types'import { RiSettings2Line } from '@remixicon/react'-import React, { useState } from 'react'+import * as React from 'react'+import { useState } from 'react'import { useTranslation } from 'react-i18next'import { useContext } from 'use-context-selector'import Button from '@/app/components/base/button'diff --git a/web/app/components/tools/marketplace/index.spec.tsx b/web/app/components/tools/marketplace/index.spec.tsxindex 1056fe9d84d..dcdda155883 100644--- a/web/app/components/tools/marketplace/index.spec.tsx+++ b/web/app/components/tools/marketplace/index.spec.tsx@@ -2,7 +2,7 @@ import type { Plugin } from '@/app/components/plugins/types'import type { Collection } from '@/app/components/tools/types'import { act, render, renderHook, screen, waitFor } from '@testing-library/react'import userEvent from '@testing-library/user-event'-import React from 'react'+import * as React from 'react'import { SCROLL_BOTTOM_THRESHOLD } from '@/app/components/plugins/marketplace/constants'import { getMarketplaceListCondition } from '@/app/components/plugins/marketplace/utils'import { PluginCategoryEnum } from '@/app/components/plugins/types'diff --git a/web/app/components/tools/mcp/detail/content.tsx b/web/app/components/tools/mcp/detail/content.tsxindex bf57515f7de..417d8857f09 100644--- a/web/app/components/tools/mcp/detail/content.tsx+++ b/web/app/components/tools/mcp/detail/content.tsx@@ -8,7 +8,8 @@ import {} from '@remixicon/react'import { useBoolean } from 'ahooks'import copy from 'copy-to-clipboard'-import React, { useCallback, useEffect } from 'react'+import * as React from 'react'+import { useCallback, useEffect } from 'react'import { useTranslation } from 'react-i18next'import ActionButton from '@/app/components/base/action-button'import Button from '@/app/components/base/button'diff --git a/web/app/components/tools/mcp/detail/list-loading.tsx b/web/app/components/tools/mcp/detail/list-loading.tsxindex f770728715e..636865fcce5 100644--- a/web/app/components/tools/mcp/detail/list-loading.tsx+++ b/web/app/components/tools/mcp/detail/list-loading.tsx@@ -1,5 +1,5 @@'use client'-import React from 'react'+import * as React from 'react'import { cn } from '@/utils/classnames'const ListLoading = () => {diff --git a/web/app/components/tools/mcp/detail/operation-dropdown.tsx b/web/app/components/tools/mcp/detail/operation-dropdown.tsxindex 4ec80c5998a..8955a5b50d8 100644--- a/web/app/components/tools/mcp/detail/operation-dropdown.tsx+++ b/web/app/components/tools/mcp/detail/operation-dropdown.tsx@@ -5,7 +5,8 @@ import {RiEditLine,RiMoreFill,} from '@remixicon/react'-import React, { useCallback, useRef, useState } from 'react'+import * as React from 'react'+import { useCallback, useRef, useState } from 'react'import { useTranslation } from 'react-i18next'import ActionButton from '@/app/components/base/action-button'import {diff --git a/web/app/components/tools/mcp/detail/provider-detail.tsx b/web/app/components/tools/mcp/detail/provider-detail.tsxindex d2f23b1887c..f70006cd055 100644--- a/web/app/components/tools/mcp/detail/provider-detail.tsx+++ b/web/app/components/tools/mcp/detail/provider-detail.tsx@@ -1,7 +1,7 @@'use client'import type { FC } from 'react'import type { ToolWithProvider } from '../../../workflow/types'-import React from 'react'+import * as React from 'react'import Drawer from '@/app/components/base/drawer'import { cn } from '@/utils/classnames'import MCPDetailContent from './content'diff --git a/web/app/components/tools/mcp/detail/tool-item.tsx b/web/app/components/tools/mcp/detail/tool-item.tsxindex 83e58817f41..6e7673b3cd8 100644--- a/web/app/components/tools/mcp/detail/tool-item.tsx+++ b/web/app/components/tools/mcp/detail/tool-item.tsx@@ -1,6 +1,6 @@'use client'import type { Tool } from '@/app/components/tools/types'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import { useContext } from 'use-context-selector'import Tooltip from '@/app/components/base/tooltip'diff --git a/web/app/components/tools/mcp/headers-input.tsx b/web/app/components/tools/mcp/headers-input.tsxindex 18ee9b1cc6c..d6bb00bdb92 100644--- a/web/app/components/tools/mcp/headers-input.tsx+++ b/web/app/components/tools/mcp/headers-input.tsx@@ -1,6 +1,6 @@'use client'import { RiAddLine, RiDeleteBinLine } from '@remixicon/react'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import { v4 as uuid } from 'uuid'import ActionButton from '@/app/components/base/action-button'diff --git a/web/app/components/tools/mcp/mcp-server-modal.tsx b/web/app/components/tools/mcp/mcp-server-modal.tsxindex 15fd2a573bf..e0036a3dc44 100644--- a/web/app/components/tools/mcp/mcp-server-modal.tsx+++ b/web/app/components/tools/mcp/mcp-server-modal.tsx@@ -3,7 +3,7 @@ import type {MCPServerDetail,} from '@/app/components/tools/types'import { RiCloseLine } from '@remixicon/react'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import Button from '@/app/components/base/button'import Divider from '@/app/components/base/divider'diff --git a/web/app/components/tools/mcp/mcp-server-param-item.tsx b/web/app/components/tools/mcp/mcp-server-param-item.tsxindex 3d99cc5bad3..d951f19caab 100644--- a/web/app/components/tools/mcp/mcp-server-param-item.tsx+++ b/web/app/components/tools/mcp/mcp-server-param-item.tsx@@ -1,5 +1,5 @@'use client'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import Textarea from '@/app/components/base/textarea'diff --git a/web/app/components/tools/mcp/mcp-service-card.tsx b/web/app/components/tools/mcp/mcp-service-card.tsxindex 521e93222b0..07aa5e01682 100644--- a/web/app/components/tools/mcp/mcp-service-card.tsx+++ b/web/app/components/tools/mcp/mcp-service-card.tsx@@ -2,7 +2,8 @@import type { AppDetailResponse } from '@/models/app'import type { AppSSO } from '@/types/app'import { RiEditLine, RiLoopLeftLine } from '@remixicon/react'-import React, { useEffect, useMemo, useState } from 'react'+import * as React from 'react'+import { useEffect, useMemo, useState } from 'react'import { useTranslation } from 'react-i18next'import Button from '@/app/components/base/button'import Confirm from '@/app/components/base/confirm'diff --git a/web/app/components/tools/mcp/modal.tsx b/web/app/components/tools/mcp/modal.tsxindex a739964ee3a..eb8f280484e 100644--- a/web/app/components/tools/mcp/modal.tsx+++ b/web/app/components/tools/mcp/modal.tsx@@ -6,7 +6,8 @@ import type { AppIconType } from '@/types/app'import { RiCloseLine, RiEditLine } from '@remixicon/react'import { useHover } from 'ahooks'import { noop } from 'lodash-es'-import React, { useCallback, useRef, useState } from 'react'+import * as React from 'react'+import { useCallback, useRef, useState } from 'react'import { useTranslation } from 'react-i18next'import { getDomain } from 'tldts'import { v4 as uuid } from 'uuid'diff --git a/web/app/components/tools/provider/detail.tsx b/web/app/components/tools/provider/detail.tsxindex e881dd3997d..c4b65f353d0 100644--- a/web/app/components/tools/provider/detail.tsx+++ b/web/app/components/tools/provider/detail.tsx@@ -3,7 +3,8 @@ import type { Collection, CustomCollectionBackend, Tool, WorkflowToolProviderReqimport {RiCloseLine,} from '@remixicon/react'-import React, { useCallback, useEffect, useState } from 'react'+import * as React from 'react'+import { useCallback, useEffect, useState } from 'react'import { useTranslation } from 'react-i18next'import { useContext } from 'use-context-selector'import ActionButton from '@/app/components/base/action-button'diff --git a/web/app/components/tools/provider/tool-item.tsx b/web/app/components/tools/provider/tool-item.tsxindex 3248e3c0248..b240bf6a415 100644--- a/web/app/components/tools/provider/tool-item.tsx+++ b/web/app/components/tools/provider/tool-item.tsx@@ -1,6 +1,7 @@'use client'import type { Collection, Tool } from '../types'-import React, { useState } from 'react'+import * as React from 'react'+import { useState } from 'react'import { useContext } from 'use-context-selector'import SettingBuiltInTool from '@/app/components/app/configuration/config/agent/agent-tools/setting-built-in-tool'import I18n from '@/context/i18n'diff --git a/web/app/components/tools/setting/build-in/config-credentials.tsx b/web/app/components/tools/setting/build-in/config-credentials.tsxindex 783d4a64768..43383cdb510 100644--- a/web/app/components/tools/setting/build-in/config-credentials.tsx+++ b/web/app/components/tools/setting/build-in/config-credentials.tsx@@ -2,7 +2,8 @@import type { FC } from 'react'import type { Collection } from '../../types'import { noop } from 'lodash-es'-import React, { useEffect, useState } from 'react'+import * as React from 'react'+import { useEffect, useState } from 'react'import { useTranslation } from 'react-i18next'import Button from '@/app/components/base/button'import Drawer from '@/app/components/base/drawer-plus'diff --git a/web/app/components/tools/workflow-tool/configure-button.tsx b/web/app/components/tools/workflow-tool/configure-button.tsxindex 0d28576de54..f142989ff6a 100644--- a/web/app/components/tools/workflow-tool/configure-button.tsx+++ b/web/app/components/tools/workflow-tool/configure-button.tsx@@ -4,7 +4,8 @@ import type { InputVar, Variable } from '@/app/components/workflow/types'import type { PublishWorkflowParams } from '@/types/workflow'import { RiArrowRightUpLine, RiHammerLine } from '@remixicon/react'import { useRouter } from 'next/navigation'-import React, { useCallback, useEffect, useMemo, useState } from 'react'+import * as React from 'react'+import { useCallback, useEffect, useMemo, useState } from 'react'import { useTranslation } from 'react-i18next'import Button from '@/app/components/base/button'import Loading from '@/app/components/base/loading'diff --git a/web/app/components/tools/workflow-tool/confirm-modal/index.spec.tsx b/web/app/components/tools/workflow-tool/confirm-modal/index.spec.tsxindex 972ac8c8825..a03860d9520 100644--- a/web/app/components/tools/workflow-tool/confirm-modal/index.spec.tsx+++ b/web/app/components/tools/workflow-tool/confirm-modal/index.spec.tsx@@ -1,6 +1,6 @@import { act, render, screen, waitFor } from '@testing-library/react'import userEvent from '@testing-library/user-event'-import React from 'react'+import * as React from 'react'import ConfirmModal from './index'// Test utilitiesdiff --git a/web/app/components/tools/workflow-tool/index.tsx b/web/app/components/tools/workflow-tool/index.tsxindex af226e70717..8804a4128d6 100644--- a/web/app/components/tools/workflow-tool/index.tsx+++ b/web/app/components/tools/workflow-tool/index.tsx@@ -3,7 +3,8 @@ import type { FC } from 'react'import type { Emoji, WorkflowToolProviderOutputParameter, WorkflowToolProviderParameter, WorkflowToolProviderRequest } from '../types'import { RiErrorWarningLine } from '@remixicon/react'import { produce } from 'immer'-import React, { useMemo, useState } from 'react'+import * as React from 'react'+import { useMemo, useState } from 'react'import { useTranslation } from 'react-i18next'import AppIcon from '@/app/components/base/app-icon'import Button from '@/app/components/base/button'diff --git a/web/app/components/workflow-app/components/workflow-onboarding-modal/index.spec.tsx b/web/app/components/workflow-app/components/workflow-onboarding-modal/index.spec.tsxindex b7a2cefd1ce..6dac82a642c 100644--- a/web/app/components/workflow-app/components/workflow-onboarding-modal/index.spec.tsx+++ b/web/app/components/workflow-app/components/workflow-onboarding-modal/index.spec.tsx@@ -1,6 +1,6 @@import { fireEvent, render, screen, waitFor } from '@testing-library/react'import userEvent from '@testing-library/user-event'-import React from 'react'+import * as React from 'react'import { BlockEnum } from '@/app/components/workflow/types'import WorkflowOnboardingModal from './index'diff --git a/web/app/components/workflow-app/components/workflow-onboarding-modal/start-node-option.spec.tsx b/web/app/components/workflow-app/components/workflow-onboarding-modal/start-node-option.spec.tsxindex 0fa5c9f13dd..9c77ebfdfe9 100644--- a/web/app/components/workflow-app/components/workflow-onboarding-modal/start-node-option.spec.tsx+++ b/web/app/components/workflow-app/components/workflow-onboarding-modal/start-node-option.spec.tsx@@ -1,6 +1,6 @@import { render, screen } from '@testing-library/react'import userEvent from '@testing-library/user-event'-import React from 'react'+import * as React from 'react'import StartNodeOption from './start-node-option'describe('StartNodeOption', () => {diff --git a/web/app/components/workflow-app/components/workflow-onboarding-modal/start-node-selection-panel.spec.tsx b/web/app/components/workflow-app/components/workflow-onboarding-modal/start-node-selection-panel.spec.tsxindex 8c59ec3b825..43d8c1a8e18 100644--- a/web/app/components/workflow-app/components/workflow-onboarding-modal/start-node-selection-panel.spec.tsx+++ b/web/app/components/workflow-app/components/workflow-onboarding-modal/start-node-selection-panel.spec.tsx@@ -1,6 +1,6 @@import { render, screen, waitFor } from '@testing-library/react'import userEvent from '@testing-library/user-event'-import React from 'react'+import * as React from 'react'import { BlockEnum } from '@/app/components/workflow/types'import StartNodeSelectionPanel from './start-node-selection-panel'diff --git a/web/app/components/workflow/__tests__/trigger-status-sync.test.tsx b/web/app/components/workflow/__tests__/trigger-status-sync.test.tsxindex 6bf7e8f5421..d3c3d235fe9 100644--- a/web/app/components/workflow/__tests__/trigger-status-sync.test.tsx+++ b/web/app/components/workflow/__tests__/trigger-status-sync.test.tsx@@ -2,7 +2,8 @@ import type { MockedFunction } from 'vitest'import type { EntryNodeStatus } from '../store/trigger-status'import type { BlockEnum } from '../types'import { act, render } from '@testing-library/react'-import React, { useCallback } from 'react'+import * as React from 'react'+import { useCallback } from 'react'import { useTriggerStatusStore } from '../store/trigger-status'import { isTriggerNode } from '../types'diff --git a/web/app/components/workflow/block-selector/market-place-plugin/action.tsx b/web/app/components/workflow/block-selector/market-place-plugin/action.tsxindex a23ca32b50f..bb98f1043f9 100644--- a/web/app/components/workflow/block-selector/market-place-plugin/action.tsx+++ b/web/app/components/workflow/block-selector/market-place-plugin/action.tsx@@ -3,7 +3,8 @@ import type { FC } from 'react'import { RiMoreFill } from '@remixicon/react'import { useQueryClient } from '@tanstack/react-query'import { useTheme } from 'next-themes'-import React, { useCallback, useEffect, useMemo, useRef, useState } from 'react'+import * as React from 'react'+import { useCallback, useEffect, useMemo, useRef, useState } from 'react'import { useTranslation } from 'react-i18next'import ActionButton from '@/app/components/base/action-button'// import Button from '@/app/components/base/button'diff --git a/web/app/components/workflow/block-selector/market-place-plugin/item.tsx b/web/app/components/workflow/block-selector/market-place-plugin/item.tsxindex 18d86292606..545eaca41f1 100644--- a/web/app/components/workflow/block-selector/market-place-plugin/item.tsx+++ b/web/app/components/workflow/block-selector/market-place-plugin/item.tsx@@ -2,7 +2,7 @@import type { FC } from 'react'import type { Plugin } from '@/app/components/plugins/types.ts'import { useBoolean } from 'ahooks'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import { useContext } from 'use-context-selector'import InstallFromMarketplace from '@/app/components/plugins/install-plugin/install-from-marketplace'diff --git a/web/app/components/workflow/block-selector/rag-tool-recommendations/index.tsx b/web/app/components/workflow/block-selector/rag-tool-recommendations/index.tsxindex e9255917aa4..f090fc8e7c0 100644--- a/web/app/components/workflow/block-selector/rag-tool-recommendations/index.tsx+++ b/web/app/components/workflow/block-selector/rag-tool-recommendations/index.tsx@@ -4,7 +4,8 @@ import type { ViewType } from '@/app/components/workflow/block-selector/view-typimport type { OnSelectBlock } from '@/app/components/workflow/types'import { RiMoreLine } from '@remixicon/react'import Link from 'next/link'-import React, { useCallback, useEffect, useMemo, useState } from 'react'+import * as React from 'react'+import { useCallback, useEffect, useMemo, useState } from 'react'import { Trans, useTranslation } from 'react-i18next'import { ArrowDownRoundFill } from '@/app/components/base/icons/src/vender/solid/arrows'import Loading from '@/app/components/base/loading'diff --git a/web/app/components/workflow/block-selector/rag-tool-recommendations/uninstalled-item.tsx b/web/app/components/workflow/block-selector/rag-tool-recommendations/uninstalled-item.tsxindex 9a351c4eff5..125b307ae03 100644--- a/web/app/components/workflow/block-selector/rag-tool-recommendations/uninstalled-item.tsx+++ b/web/app/components/workflow/block-selector/rag-tool-recommendations/uninstalled-item.tsx@@ -1,7 +1,7 @@'use client'import type { Plugin } from '@/app/components/plugins/types'import { useBoolean } from 'ahooks'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import { useContext } from 'use-context-selector'import InstallFromMarketplace from '@/app/components/plugins/install-plugin/install-from-marketplace'diff --git a/web/app/components/workflow/block-selector/tool-picker.tsx b/web/app/components/workflow/block-selector/tool-picker.tsxindex cbb8d5a01e9..235144ae780 100644--- a/web/app/components/workflow/block-selector/tool-picker.tsx+++ b/web/app/components/workflow/block-selector/tool-picker.tsx@@ -8,7 +8,8 @@ import type { ToolDefaultValue, ToolValue } from './types'import type { CustomCollectionBackend } from '@/app/components/tools/types'import type { BlockEnum, OnSelectBlock } from '@/app/components/workflow/types'import { useBoolean } from 'ahooks'-import React, { useMemo, useState } from 'react'+import * as React from 'react'+import { useMemo, useState } from 'react'import { useTranslation } from 'react-i18next'import {PortalToFollowElem,diff --git a/web/app/components/workflow/block-selector/tool/action-item.tsx b/web/app/components/workflow/block-selector/tool/action-item.tsxindex 60fac5e701f..6c1c2465ed1 100644--- a/web/app/components/workflow/block-selector/tool/action-item.tsx+++ b/web/app/components/workflow/block-selector/tool/action-item.tsx@@ -3,7 +3,8 @@ import type { FC } from 'react'import type { ToolWithProvider } from '../../types'import type { ToolDefaultValue } from '../types'import type { Tool } from '@/app/components/tools/types'-import React, { useMemo } from 'react'+import * as React from 'react'+import { useMemo } from 'react'import { useTranslation } from 'react-i18next'import { trackEvent } from '@/app/components/base/amplitude'import Tooltip from '@/app/components/base/tooltip'diff --git a/web/app/components/workflow/block-selector/tool/tool-list-flat-view/list.tsx b/web/app/components/workflow/block-selector/tool/tool-list-flat-view/list.tsxindex 54eb050e06d..a911ea23c3a 100644--- a/web/app/components/workflow/block-selector/tool/tool-list-flat-view/list.tsx+++ b/web/app/components/workflow/block-selector/tool/tool-list-flat-view/list.tsx@@ -2,7 +2,8 @@import type { FC } from 'react'import type { BlockEnum, ToolWithProvider } from '../../../types'import type { ToolDefaultValue, ToolValue } from '../../types'-import React, { useMemo } from 'react'+import * as React from 'react'+import { useMemo } from 'react'import { ViewType } from '../../view-type-select'import Tool from '../tool'diff --git a/web/app/components/workflow/block-selector/tool/tool-list-tree-view/item.tsx b/web/app/components/workflow/block-selector/tool/tool-list-tree-view/item.tsxindex 64a376e3941..308baa45e71 100644--- a/web/app/components/workflow/block-selector/tool/tool-list-tree-view/item.tsx+++ b/web/app/components/workflow/block-selector/tool/tool-list-tree-view/item.tsx@@ -2,7 +2,7 @@import type { FC } from 'react'import type { BlockEnum, ToolWithProvider } from '../../../types'import type { ToolDefaultValue, ToolValue } from '../../types'-import React from 'react'+import * as React from 'react'import { ViewType } from '../../view-type-select'import Tool from '../tool'diff --git a/web/app/components/workflow/block-selector/tool/tool-list-tree-view/list.tsx b/web/app/components/workflow/block-selector/tool/tool-list-tree-view/list.tsxindex 0f790ab0360..2b85121e4dd 100644--- a/web/app/components/workflow/block-selector/tool/tool-list-tree-view/list.tsx+++ b/web/app/components/workflow/block-selector/tool/tool-list-tree-view/list.tsx@@ -2,7 +2,8 @@import type { FC } from 'react'import type { BlockEnum, ToolWithProvider } from '../../../types'import type { ToolDefaultValue, ToolValue } from '../../types'-import React, { useCallback } from 'react'+import * as React from 'react'+import { useCallback } from 'react'import { useTranslation } from 'react-i18next'import { AGENT_GROUP_NAME, CUSTOM_GROUP_NAME, WORKFLOW_GROUP_NAME } from '../../index-bar'import Item from './item'diff --git a/web/app/components/workflow/block-selector/tool/tool.tsx b/web/app/components/workflow/block-selector/tool/tool.tsxindex 366059b311c..337742365e4 100644--- a/web/app/components/workflow/block-selector/tool/tool.tsx+++ b/web/app/components/workflow/block-selector/tool/tool.tsx@@ -5,7 +5,8 @@ import type { ToolWithProvider } from '../../types'import type { ToolDefaultValue, ToolValue } from '../types'import { RiArrowDownSLine, RiArrowRightSLine } from '@remixicon/react'import { useHover } from 'ahooks'-import React, { useCallback, useEffect, useMemo, useRef } from 'react'+import * as React from 'react'+import { useCallback, useEffect, useMemo, useRef } from 'react'import { useTranslation } from 'react-i18next'import { Mcp } from '@/app/components/base/icons/src/vender/other'import { useGetLanguage } from '@/context/i18n'diff --git a/web/app/components/workflow/block-selector/trigger-plugin/action-item.tsx b/web/app/components/workflow/block-selector/trigger-plugin/action-item.tsxindex c0edec474a8..92ee677362d 100644--- a/web/app/components/workflow/block-selector/trigger-plugin/action-item.tsx+++ b/web/app/components/workflow/block-selector/trigger-plugin/action-item.tsx@@ -2,7 +2,7 @@import type { FC } from 'react'import type { TriggerDefaultValue, TriggerWithProvider } from '../types'import type { Event } from '@/app/components/tools/types'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import Tooltip from '@/app/components/base/tooltip'import { useGetLanguage } from '@/context/i18n'diff --git a/web/app/components/workflow/block-selector/trigger-plugin/item.tsx b/web/app/components/workflow/block-selector/trigger-plugin/item.tsxindex a4de7b30ddb..9e3ec77790a 100644--- a/web/app/components/workflow/block-selector/trigger-plugin/item.tsx+++ b/web/app/components/workflow/block-selector/trigger-plugin/item.tsx@@ -2,7 +2,8 @@import type { FC } from 'react'import type { TriggerDefaultValue, TriggerWithProvider } from '@/app/components/workflow/block-selector/types'import { RiArrowDownSLine, RiArrowRightSLine } from '@remixicon/react'-import React, { useEffect, useMemo, useRef } from 'react'+import * as React from 'react'+import { useEffect, useMemo, useRef } from 'react'import { useTranslation } from 'react-i18next'import { CollectionType } from '@/app/components/tools/types'import BlockIcon from '@/app/components/workflow/block-icon'diff --git a/web/app/components/workflow/block-selector/use-sticky-scroll.ts b/web/app/components/workflow/block-selector/use-sticky-scroll.tsindex 67ea70d94e7..4960eea74fc 100644--- a/web/app/components/workflow/block-selector/use-sticky-scroll.ts+++ b/web/app/components/workflow/block-selector/use-sticky-scroll.ts@@ -1,5 +1,5 @@import { useThrottleFn } from 'ahooks'-import React from 'react'+import * as React from 'react'export enum ScrollPosition {belowTheWrap = 'belowTheWrap',diff --git a/web/app/components/workflow/block-selector/view-type-select.tsx b/web/app/components/workflow/block-selector/view-type-select.tsxindex a4830d8e819..c81d09c6dd0 100644--- a/web/app/components/workflow/block-selector/view-type-select.tsx+++ b/web/app/components/workflow/block-selector/view-type-select.tsx@@ -1,7 +1,8 @@'use client'import type { FC } from 'react'import { RiNodeTree, RiSortAlphabetAsc } from '@remixicon/react'-import React, { useCallback } from 'react'+import * as React from 'react'+import { useCallback } from 'react'import { cn } from '@/utils/classnames'export enum ViewType {diff --git a/web/app/components/workflow/dsl-export-confirm-modal.tsx b/web/app/components/workflow/dsl-export-confirm-modal.tsxindex 63100876c65..b616ec5fb57 100644--- a/web/app/components/workflow/dsl-export-confirm-modal.tsx+++ b/web/app/components/workflow/dsl-export-confirm-modal.tsx@@ -2,7 +2,8 @@import type { EnvironmentVariable } from '@/app/components/workflow/types'import { RiCloseLine, RiLock2Line } from '@remixicon/react'import { noop } from 'lodash-es'-import React, { useState } from 'react'+import * as React from 'react'+import { useState } from 'react'import { useTranslation } from 'react-i18next'import Button from '@/app/components/base/button'import Checkbox from '@/app/components/base/checkbox'diff --git a/web/app/components/workflow/header/run-mode.tsx b/web/app/components/workflow/header/run-mode.tsxindex 82e33b5c30a..21195d489a9 100644--- a/web/app/components/workflow/header/run-mode.tsx+++ b/web/app/components/workflow/header/run-mode.tsx@@ -1,6 +1,7 @@import type { TestRunMenuRef, TriggerOption } from './test-run-menu'import { RiLoader2Line, RiPlayLargeLine } from '@remixicon/react'-import React, { useCallback, useEffect, useRef } from 'react'+import * as React from 'react'+import { useCallback, useEffect, useRef } from 'react'import { useTranslation } from 'react-i18next'import { trackEvent } from '@/app/components/base/amplitude'import { StopCircle } from '@/app/components/base/icons/src/vender/line/mediaAndDevices'diff --git a/web/app/components/workflow/header/version-history-button.tsx b/web/app/components/workflow/header/version-history-button.tsxindex b29608a0221..3be0cfbe329 100644--- a/web/app/components/workflow/header/version-history-button.tsx+++ b/web/app/components/workflow/header/version-history-button.tsx@@ -1,7 +1,8 @@import type { FC } from 'react'import { RiHistoryLine } from '@remixicon/react'import { useKeyPress } from 'ahooks'-import React, { useCallback } from 'react'+import * as React from 'react'+import { useCallback } from 'react'import { useTranslation } from 'react-i18next'import useTheme from '@/hooks/use-theme'import { cn } from '@/utils/classnames'diff --git a/web/app/components/workflow/nodes/_base/components/add-button.tsx b/web/app/components/workflow/nodes/_base/components/add-button.tsxindex 99ccc61fe5d..95a0a963fef 100644--- a/web/app/components/workflow/nodes/_base/components/add-button.tsx+++ b/web/app/components/workflow/nodes/_base/components/add-button.tsx@@ -3,7 +3,7 @@ import type { FC } from 'react'import {RiAddLine,} from '@remixicon/react'-import React from 'react'+import * as React from 'react'import Button from '@/app/components/base/button'import { cn } from '@/utils/classnames'diff --git a/web/app/components/workflow/nodes/_base/components/before-run-form/bool-input.tsx b/web/app/components/workflow/nodes/_base/components/before-run-form/bool-input.tsxindex db32627dc27..6e71e1a3568 100644--- a/web/app/components/workflow/nodes/_base/components/before-run-form/bool-input.tsx+++ b/web/app/components/workflow/nodes/_base/components/before-run-form/bool-input.tsx@@ -1,6 +1,7 @@'use client'import type { FC } from 'react'-import React, { useCallback } from 'react'+import * as React from 'react'+import { useCallback } from 'react'import { useTranslation } from 'react-i18next'import Checkbox from '@/app/components/base/checkbox'diff --git a/web/app/components/workflow/nodes/_base/components/before-run-form/form-item.tsx b/web/app/components/workflow/nodes/_base/components/before-run-form/form-item.tsxindex c33deae4384..5cc68c6048c 100644--- a/web/app/components/workflow/nodes/_base/components/before-run-form/form-item.tsx+++ b/web/app/components/workflow/nodes/_base/components/before-run-form/form-item.tsx@@ -6,7 +6,8 @@ import {RiDeleteBinLine,} from '@remixicon/react'import { produce } from 'immer'-import React, { useCallback, useMemo } from 'react'+import * as React from 'react'+import { useCallback, useMemo } from 'react'import { useTranslation } from 'react-i18next'import { FileUploaderInAttachmentWrapper } from '@/app/components/base/file-uploader'import { Line3 } from '@/app/components/base/icons/src/public/common'diff --git a/web/app/components/workflow/nodes/_base/components/before-run-form/form.tsx b/web/app/components/workflow/nodes/_base/components/before-run-form/form.tsxindex e45f0019245..0f695bb884b 100644--- a/web/app/components/workflow/nodes/_base/components/before-run-form/form.tsx+++ b/web/app/components/workflow/nodes/_base/components/before-run-form/form.tsx@@ -2,7 +2,8 @@import type { FC } from 'react'import type { InputVar } from '../../../../types'import { produce } from 'immer'-import React, { useCallback, useEffect, useMemo, useRef } from 'react'+import * as React from 'react'+import { useCallback, useEffect, useMemo, useRef } from 'react'import AddButton from '@/app/components/base/button/add-button'import { RETRIEVAL_OUTPUT_STRUCT } from '@/app/components/workflow/constants'import { InputVarType } from '@/app/components/workflow/types'diff --git a/web/app/components/workflow/nodes/_base/components/before-run-form/index.tsx b/web/app/components/workflow/nodes/_base/components/before-run-form/index.tsxindex 9957d79cf69..f5870cede12 100644--- a/web/app/components/workflow/nodes/_base/components/before-run-form/index.tsx+++ b/web/app/components/workflow/nodes/_base/components/before-run-form/index.tsx@@ -4,7 +4,8 @@ import type { Props as FormProps } from './form'import type { Emoji } from '@/app/components/tools/types'import type { SpecialResultPanelProps } from '@/app/components/workflow/run/special-result-panel'import type { BlockEnum, NodeRunningStatus } from '@/app/components/workflow/types'-import React, { useEffect, useRef } from 'react'+import * as React from 'react'+import { useEffect, useRef } from 'react'import { useTranslation } from 'react-i18next'import Button from '@/app/components/base/button'import { getProcessedFiles } from '@/app/components/base/file-uploader/utils'diff --git a/web/app/components/workflow/nodes/_base/components/before-run-form/panel-wrap.tsx b/web/app/components/workflow/nodes/_base/components/before-run-form/panel-wrap.tsxindex 61e614bb9e6..4d051943140 100644--- a/web/app/components/workflow/nodes/_base/components/before-run-form/panel-wrap.tsx+++ b/web/app/components/workflow/nodes/_base/components/before-run-form/panel-wrap.tsx@@ -3,7 +3,7 @@ import type { FC } from 'react'import {RiCloseLine,} from '@remixicon/react'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'const i18nPrefix = 'workflow.singleRun'diff --git a/web/app/components/workflow/nodes/_base/components/code-generator-button.tsx b/web/app/components/workflow/nodes/_base/components/code-generator-button.tsxindex 6888bff96cf..96b9fe7a844 100644--- a/web/app/components/workflow/nodes/_base/components/code-generator-button.tsx+++ b/web/app/components/workflow/nodes/_base/components/code-generator-button.tsx@@ -3,7 +3,8 @@ import type { FC } from 'react'import type { CodeLanguage } from '../../code/types'import type { GenRes } from '@/service/debug'import { useBoolean } from 'ahooks'-import React, { useCallback } from 'react'+import * as React from 'react'+import { useCallback } from 'react'import { GetCodeGeneratorResModal } from '@/app/components/app/configuration/config/code-generator/get-code-generator-res'import { ActionButton } from '@/app/components/base/action-button'import { Generator } from '@/app/components/base/icons/src/vender/other'diff --git a/web/app/components/workflow/nodes/_base/components/config-vision.tsx b/web/app/components/workflow/nodes/_base/components/config-vision.tsxindex 3c2cc217a7a..f5f47c40124 100644--- a/web/app/components/workflow/nodes/_base/components/config-vision.tsx+++ b/web/app/components/workflow/nodes/_base/components/config-vision.tsx@@ -2,7 +2,8 @@import type { FC } from 'react'import type { ValueSelector, Var, VisionSetting } from '@/app/components/workflow/types'import { produce } from 'immer'-import React, { useCallback } from 'react'+import * as React from 'react'+import { useCallback } from 'react'import { useTranslation } from 'react-i18next'import Switch from '@/app/components/base/switch'import Tooltip from '@/app/components/base/tooltip'diff --git a/web/app/components/workflow/nodes/_base/components/editor/base.tsx b/web/app/components/workflow/nodes/_base/components/editor/base.tsxindex 95aabc0ec0f..3d5ca5f78a2 100644--- a/web/app/components/workflow/nodes/_base/components/editor/base.tsx+++ b/web/app/components/workflow/nodes/_base/components/editor/base.tsx@@ -4,7 +4,8 @@ import type { CodeLanguage } from '../../../code/types'import type { FileEntity } from '@/app/components/base/file-uploader/types'import type { Node, NodeOutPutVar } from '@/app/components/workflow/types'import copy from 'copy-to-clipboard'-import React, { useCallback, useRef, useState } from 'react'+import * as React from 'react'+import { useCallback, useRef, useState } from 'react'import PromptEditorHeightResizeWrap from '@/app/components/app/configuration/config-prompt/prompt-editor-height-resize-wrap'import ActionButton from '@/app/components/base/action-button'import FileListInLog from '@/app/components/base/file-uploader/file-list-in-log'diff --git a/web/app/components/workflow/nodes/_base/components/editor/code-editor/editor-support-vars.tsx b/web/app/components/workflow/nodes/_base/components/editor/code-editor/editor-support-vars.tsxindex d4d43ae7966..e5cb8f258af 100644--- a/web/app/components/workflow/nodes/_base/components/editor/code-editor/editor-support-vars.tsx+++ b/web/app/components/workflow/nodes/_base/components/editor/code-editor/editor-support-vars.tsx@@ -3,7 +3,8 @@ import type { FC } from 'react'import type { Props as EditorProps } from '.'import type { NodeOutPutVar, Variable } from '@/app/components/workflow/types'import { useBoolean } from 'ahooks'-import React, { useEffect, useRef, useState } from 'react'+import * as React from 'react'+import { useEffect, useRef, useState } from 'react'import { useTranslation } from 'react-i18next'import VarReferenceVars from '@/app/components/workflow/nodes/_base/components/variable/var-reference-vars'import { cn } from '@/utils/classnames'diff --git a/web/app/components/workflow/nodes/_base/components/editor/code-editor/index.tsx b/web/app/components/workflow/nodes/_base/components/editor/code-editor/index.tsxindex b98e9085dec..fa7aef90a5b 100644--- a/web/app/components/workflow/nodes/_base/components/editor/code-editor/index.tsx+++ b/web/app/components/workflow/nodes/_base/components/editor/code-editor/index.tsx@@ -2,7 +2,8 @@import type { FC } from 'react'import Editor, { loader } from '@monaco-editor/react'import { noop } from 'lodash-es'-import React, { useEffect, useMemo, useRef, useState } from 'react'+import * as React from 'react'+import { useEffect, useMemo, useRef, useState } from 'react'import {getFilesInLogs,} from '@/app/components/base/file-uploader/utils'diff --git a/web/app/components/workflow/nodes/_base/components/editor/text-editor.tsx b/web/app/components/workflow/nodes/_base/components/editor/text-editor.tsxindex 6fa3c2adfd3..888c1c70170 100644--- a/web/app/components/workflow/nodes/_base/components/editor/text-editor.tsx+++ b/web/app/components/workflow/nodes/_base/components/editor/text-editor.tsx@@ -1,7 +1,8 @@'use client'import type { FC } from 'react'import { useBoolean } from 'ahooks'-import React, { useCallback } from 'react'+import * as React from 'react'+import { useCallback } from 'react'import Base from './base'type Props = {diff --git a/web/app/components/workflow/nodes/_base/components/editor/wrap.tsx b/web/app/components/workflow/nodes/_base/components/editor/wrap.tsxindex 700f5a43178..4ebedfe596c 100644--- a/web/app/components/workflow/nodes/_base/components/editor/wrap.tsx+++ b/web/app/components/workflow/nodes/_base/components/editor/wrap.tsx@@ -1,6 +1,6 @@'use client'import type { FC } from 'react'-import React from 'react'+import * as React from 'react'import { useStore } from '@/app/components/workflow/store'type Props = {diff --git a/web/app/components/workflow/nodes/_base/components/field.tsx b/web/app/components/workflow/nodes/_base/components/field.tsxindex 9f465467009..93fd331f947 100644--- a/web/app/components/workflow/nodes/_base/components/field.tsx+++ b/web/app/components/workflow/nodes/_base/components/field.tsx@@ -4,7 +4,7 @@ import {RiArrowDownSLine,} from '@remixicon/react'import { useBoolean } from 'ahooks'-import React from 'react'+import * as React from 'react'import Tooltip from '@/app/components/base/tooltip'import { cn } from '@/utils/classnames'diff --git a/web/app/components/workflow/nodes/_base/components/file-type-item.tsx b/web/app/components/workflow/nodes/_base/components/file-type-item.tsxindex 3dc1e7b132e..b354d35276e 100644--- a/web/app/components/workflow/nodes/_base/components/file-type-item.tsx+++ b/web/app/components/workflow/nodes/_base/components/file-type-item.tsx@@ -1,7 +1,8 @@'use client'import type { FC } from 'react'import { noop } from 'lodash-es'-import React, { useCallback } from 'react'+import * as React from 'react'+import { useCallback } from 'react'import { useTranslation } from 'react-i18next'import Checkbox from '@/app/components/base/checkbox'import { FileTypeIcon } from '@/app/components/base/file-uploader'diff --git a/web/app/components/workflow/nodes/_base/components/file-upload-setting.tsx b/web/app/components/workflow/nodes/_base/components/file-upload-setting.tsxindex c6330daf4d5..bcbb9b63734 100644--- a/web/app/components/workflow/nodes/_base/components/file-upload-setting.tsx+++ b/web/app/components/workflow/nodes/_base/components/file-upload-setting.tsx@@ -2,7 +2,8 @@import type { FC } from 'react'import type { UploadFileSetting } from '../../../types'import { produce } from 'immer'-import React, { useCallback } from 'react'+import * as React from 'react'+import { useCallback } from 'react'import { useTranslation } from 'react-i18next'import Field from '@/app/components/app/configuration/config-var/config-modal/field'import { useFileSizeLimit } from '@/app/components/base/file-uploader/hooks'diff --git a/web/app/components/workflow/nodes/_base/components/info-panel.tsx b/web/app/components/workflow/nodes/_base/components/info-panel.tsxindex cc2426c24ff..885adab0fd3 100644--- a/web/app/components/workflow/nodes/_base/components/info-panel.tsx+++ b/web/app/components/workflow/nodes/_base/components/info-panel.tsx@@ -1,6 +1,6 @@'use client'import type { FC, ReactNode } from 'react'-import React from 'react'+import * as React from 'react'type Props = {title: stringdiff --git a/web/app/components/workflow/nodes/_base/components/input-number-with-slider.tsx b/web/app/components/workflow/nodes/_base/components/input-number-with-slider.tsxindex 0a021402ba6..cb0dc9064c1 100644--- a/web/app/components/workflow/nodes/_base/components/input-number-with-slider.tsx+++ b/web/app/components/workflow/nodes/_base/components/input-number-with-slider.tsx@@ -1,6 +1,7 @@'use client'import type { FC } from 'react'-import React, { useCallback } from 'react'+import * as React from 'react'+import { useCallback } from 'react'import Slider from '@/app/components/base/slider'export type InputNumberWithSliderProps = {diff --git a/web/app/components/workflow/nodes/_base/components/input-support-select-var.tsx b/web/app/components/workflow/nodes/_base/components/input-support-select-var.tsxindex c06fe55375b..348bb23302c 100644--- a/web/app/components/workflow/nodes/_base/components/input-support-select-var.tsx+++ b/web/app/components/workflow/nodes/_base/components/input-support-select-var.tsx@@ -6,7 +6,8 @@ import type {} from '@/app/components/workflow/types'import { useBoolean } from 'ahooks'import { noop } from 'lodash-es'-import React, { useEffect } from 'react'+import * as React from 'react'+import { useEffect } from 'react'import { useTranslation } from 'react-i18next'import { Variable02 } from '@/app/components/base/icons/src/vender/solid/development'import PromptEditor from '@/app/components/base/prompt-editor'diff --git a/web/app/components/workflow/nodes/_base/components/input-var-type-icon.tsx b/web/app/components/workflow/nodes/_base/components/input-var-type-icon.tsxindex 7e529013cb5..586149d727a 100644--- a/web/app/components/workflow/nodes/_base/components/input-var-type-icon.tsx+++ b/web/app/components/workflow/nodes/_base/components/input-var-type-icon.tsx@@ -10,7 +10,7 @@ import {RiHashtag,RiTextSnippet,} from '@remixicon/react'-import React from 'react'+import * as React from 'react'import { InputVarType } from '../../../types'type Props = {diff --git a/web/app/components/workflow/nodes/_base/components/list-no-data-placeholder.tsx b/web/app/components/workflow/nodes/_base/components/list-no-data-placeholder.tsxindex 98e2dc4f293..c3a30a3ac31 100644--- a/web/app/components/workflow/nodes/_base/components/list-no-data-placeholder.tsx+++ b/web/app/components/workflow/nodes/_base/components/list-no-data-placeholder.tsx@@ -1,6 +1,6 @@'use client'import type { FC } from 'react'-import React from 'react'+import * as React from 'react'type Props = {children: React.ReactNodediff --git a/web/app/components/workflow/nodes/_base/components/mcp-tool-not-support-tooltip.tsx b/web/app/components/workflow/nodes/_base/components/mcp-tool-not-support-tooltip.tsxindex 33da12239b5..49a8f1e4064 100644--- a/web/app/components/workflow/nodes/_base/components/mcp-tool-not-support-tooltip.tsx+++ b/web/app/components/workflow/nodes/_base/components/mcp-tool-not-support-tooltip.tsx@@ -1,7 +1,7 @@'use client'import type { FC } from 'react'import { RiAlertFill } from '@remixicon/react'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import Tooltip from '@/app/components/base/tooltip'diff --git a/web/app/components/workflow/nodes/_base/components/memory-config.tsx b/web/app/components/workflow/nodes/_base/components/memory-config.tsxindex 1272f132a65..70dfdde71f9 100644--- a/web/app/components/workflow/nodes/_base/components/memory-config.tsx+++ b/web/app/components/workflow/nodes/_base/components/memory-config.tsx@@ -2,7 +2,8 @@import type { FC } from 'react'import type { Memory } from '../../../types'import { produce } from 'immer'-import React, { useCallback } from 'react'+import * as React from 'react'+import { useCallback } from 'react'import { useTranslation } from 'react-i18next'import Input from '@/app/components/base/input'import Slider from '@/app/components/base/slider'diff --git a/web/app/components/workflow/nodes/_base/components/option-card.tsx b/web/app/components/workflow/nodes/_base/components/option-card.tsxindex 7c3a06daeb2..d9deb2ab7bb 100644--- a/web/app/components/workflow/nodes/_base/components/option-card.tsx+++ b/web/app/components/workflow/nodes/_base/components/option-card.tsx@@ -2,7 +2,8 @@import type { VariantProps } from 'class-variance-authority'import type { FC } from 'react'import { cva } from 'class-variance-authority'-import React, { useCallback } from 'react'+import * as React from 'react'+import { useCallback } from 'react'import Tooltip from '@/app/components/base/tooltip'import { cn } from '@/utils/classnames'diff --git a/web/app/components/workflow/nodes/_base/components/output-vars.tsx b/web/app/components/workflow/nodes/_base/components/output-vars.tsxindex 2c646148b31..7ec18032ae4 100644--- a/web/app/components/workflow/nodes/_base/components/output-vars.tsx+++ b/web/app/components/workflow/nodes/_base/components/output-vars.tsx@@ -1,6 +1,6 @@'use client'import type { FC, ReactNode } from 'react'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import { FieldCollapse } from '@/app/components/workflow/nodes/_base/components/collapse'import { cn } from '@/utils/classnames'diff --git a/web/app/components/workflow/nodes/_base/components/prompt/editor.tsx b/web/app/components/workflow/nodes/_base/components/prompt/editor.tsxindex c2bc6481ff4..c0dbb181e2f 100644--- a/web/app/components/workflow/nodes/_base/components/prompt/editor.tsx+++ b/web/app/components/workflow/nodes/_base/components/prompt/editor.tsx@@ -11,7 +11,8 @@ import {} from '@remixicon/react'import { useBoolean } from 'ahooks'import copy from 'copy-to-clipboard'-import React, { useCallback, useRef } from 'react'+import * as React from 'react'+import { useCallback, useRef } from 'react'import { useTranslation } from 'react-i18next'import ActionButton from '@/app/components/base/action-button'diff --git a/web/app/components/workflow/nodes/_base/components/readonly-input-with-select-var.tsx b/web/app/components/workflow/nodes/_base/components/readonly-input-with-select-var.tsxindex fbec61d516f..b9a980ae013 100644--- a/web/app/components/workflow/nodes/_base/components/readonly-input-with-select-var.tsx+++ b/web/app/components/workflow/nodes/_base/components/readonly-input-with-select-var.tsx@@ -1,6 +1,6 @@'use client'import type { FC } from 'react'-import React from 'react'+import * as React from 'react'import {VariableLabelInText,} from '@/app/components/workflow/nodes/_base/components/variable/variable-label'diff --git a/web/app/components/workflow/nodes/_base/components/remove-button.tsx b/web/app/components/workflow/nodes/_base/components/remove-button.tsxindex 7b77f956d39..962a3c18284 100644--- a/web/app/components/workflow/nodes/_base/components/remove-button.tsx+++ b/web/app/components/workflow/nodes/_base/components/remove-button.tsx@@ -1,7 +1,7 @@'use client'import type { FC } from 'react'import { RiDeleteBinLine } from '@remixicon/react'-import React from 'react'+import * as React from 'react'import ActionButton from '@/app/components/base/action-button'type Props = {diff --git a/web/app/components/workflow/nodes/_base/components/remove-effect-var-confirm.tsx b/web/app/components/workflow/nodes/_base/components/remove-effect-var-confirm.tsxindex bf3fd868655..02f61ad1787 100644--- a/web/app/components/workflow/nodes/_base/components/remove-effect-var-confirm.tsx+++ b/web/app/components/workflow/nodes/_base/components/remove-effect-var-confirm.tsx@@ -1,6 +1,6 @@'use client'import type { FC } from 'react'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import Confirm from '@/app/components/base/confirm'diff --git a/web/app/components/workflow/nodes/_base/components/selector.tsx b/web/app/components/workflow/nodes/_base/components/selector.tsxindex 58b1ecfa31a..60498a4a6a6 100644--- a/web/app/components/workflow/nodes/_base/components/selector.tsx+++ b/web/app/components/workflow/nodes/_base/components/selector.tsx@@ -1,7 +1,7 @@'use client'import type { FC } from 'react'import { useBoolean, useClickAway } from 'ahooks'-import React from 'react'+import * as React from 'react'import { ChevronSelectorVertical } from '@/app/components/base/icons/src/vender/line/arrows'import { Check } from '@/app/components/base/icons/src/vender/line/general'import { cn } from '@/utils/classnames'diff --git a/web/app/components/workflow/nodes/_base/components/split.tsx b/web/app/components/workflow/nodes/_base/components/split.tsxindex fa5ea3adc18..5cb5153c955 100644--- a/web/app/components/workflow/nodes/_base/components/split.tsx+++ b/web/app/components/workflow/nodes/_base/components/split.tsx@@ -1,6 +1,6 @@'use client'import type { FC } from 'react'-import React from 'react'+import * as React from 'react'import { cn } from '@/utils/classnames'type Props = {diff --git a/web/app/components/workflow/nodes/_base/components/support-var-input/index.tsx b/web/app/components/workflow/nodes/_base/components/support-var-input/index.tsxindex d3753bb5ff3..377e1d8bc51 100644--- a/web/app/components/workflow/nodes/_base/components/support-var-input/index.tsx+++ b/web/app/components/workflow/nodes/_base/components/support-var-input/index.tsx@@ -1,6 +1,6 @@'use client'import type { FC } from 'react'-import React from 'react'+import * as React from 'react'import VarHighlight from '@/app/components/app/configuration/base/var-highlight'import { cn } from '@/utils/classnames'diff --git a/web/app/components/workflow/nodes/_base/components/toggle-expand-btn.tsx b/web/app/components/workflow/nodes/_base/components/toggle-expand-btn.tsxindex 116825ae958..73b221a912b 100644--- a/web/app/components/workflow/nodes/_base/components/toggle-expand-btn.tsx+++ b/web/app/components/workflow/nodes/_base/components/toggle-expand-btn.tsx@@ -4,7 +4,8 @@ import {RiCollapseDiagonalLine,RiExpandDiagonalLine,} from '@remixicon/react'-import React, { useCallback } from 'react'+import * as React from 'react'+import { useCallback } from 'react'import ActionButton from '@/app/components/base/action-button'type Props = {diff --git a/web/app/components/workflow/nodes/_base/components/variable/assigned-var-reference-popup.tsx b/web/app/components/workflow/nodes/_base/components/variable/assigned-var-reference-popup.tsxindex 7907c83fc37..9e3aba9bf01 100644--- a/web/app/components/workflow/nodes/_base/components/variable/assigned-var-reference-popup.tsx+++ b/web/app/components/workflow/nodes/_base/components/variable/assigned-var-reference-popup.tsx@@ -1,7 +1,7 @@'use client'import type { FC } from 'react'import type { NodeOutPutVar, ValueSelector, Var } from '@/app/components/workflow/types'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import ListEmpty from '@/app/components/base/list-empty'import VarReferenceVars from './var-reference-vars'diff --git a/web/app/components/workflow/nodes/_base/components/variable/constant-field.tsx b/web/app/components/workflow/nodes/_base/components/variable/constant-field.tsxindex 310e82ff120..f0d7a04294e 100644--- a/web/app/components/workflow/nodes/_base/components/variable/constant-field.tsx+++ b/web/app/components/workflow/nodes/_base/components/variable/constant-field.tsx@@ -2,7 +2,8 @@import type { FC } from 'react'import type { CredentialFormSchema, CredentialFormSchemaNumberInput, CredentialFormSchemaSelect } from '@/app/components/header/account-setting/model-provider-page/declarations'import type { Var } from '@/app/components/workflow/types'-import React, { useCallback } from 'react'+import * as React from 'react'+import { useCallback } from 'react'import { SimpleSelect } from '@/app/components/base/select'import { FormTypeEnum } from '@/app/components/header/account-setting/model-provider-page/declarations'import { useLanguage } from '@/app/components/header/account-setting/model-provider-page/hooks'diff --git a/web/app/components/workflow/nodes/_base/components/variable/object-child-tree-panel/picker/field.tsx b/web/app/components/workflow/nodes/_base/components/variable/object-child-tree-panel/picker/field.tsxindex f533c331084..18d84db571c 100644--- a/web/app/components/workflow/nodes/_base/components/variable/object-child-tree-panel/picker/field.tsx+++ b/web/app/components/workflow/nodes/_base/components/variable/object-child-tree-panel/picker/field.tsx@@ -3,7 +3,7 @@ import type { FC } from 'react'import type { Field as FieldType } from '../../../../../llm/types'import type { ValueSelector } from '@/app/components/workflow/types'import { RiMoreFill } from '@remixicon/react'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import Tooltip from '@/app/components/base/tooltip'import { cn } from '@/utils/classnames'diff --git a/web/app/components/workflow/nodes/_base/components/variable/object-child-tree-panel/picker/index.tsx b/web/app/components/workflow/nodes/_base/components/variable/object-child-tree-panel/picker/index.tsxindex baf3cfcbd25..b29b1a6992b 100644--- a/web/app/components/workflow/nodes/_base/components/variable/object-child-tree-panel/picker/index.tsx+++ b/web/app/components/workflow/nodes/_base/components/variable/object-child-tree-panel/picker/index.tsx@@ -3,7 +3,8 @@ import type { FC } from 'react'import type { StructuredOutput } from '../../../../../llm/types'import type { ValueSelector } from '@/app/components/workflow/types'import { useHover } from 'ahooks'-import React, { useRef } from 'react'+import * as React from 'react'+import { useRef } from 'react'import { cn } from '@/utils/classnames'import Field from './field'diff --git a/web/app/components/workflow/nodes/_base/components/variable/object-child-tree-panel/show/field.tsx b/web/app/components/workflow/nodes/_base/components/variable/object-child-tree-panel/show/field.tsxindex fc23cda2053..d028bd2c16c 100644--- a/web/app/components/workflow/nodes/_base/components/variable/object-child-tree-panel/show/field.tsx+++ b/web/app/components/workflow/nodes/_base/components/variable/object-child-tree-panel/show/field.tsx@@ -3,7 +3,7 @@ import type { FC } from 'react'import type { Field as FieldType } from '../../../../../llm/types'import { RiArrowDropDownLine } from '@remixicon/react'import { useBoolean } from 'ahooks'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import { cn } from '@/utils/classnames'import { Type } from '../../../../../llm/types'diff --git a/web/app/components/workflow/nodes/_base/components/variable/object-child-tree-panel/show/index.tsx b/web/app/components/workflow/nodes/_base/components/variable/object-child-tree-panel/show/index.tsxindex deaab09e6ca..c0049a54e86 100644--- a/web/app/components/workflow/nodes/_base/components/variable/object-child-tree-panel/show/index.tsx+++ b/web/app/components/workflow/nodes/_base/components/variable/object-child-tree-panel/show/index.tsx@@ -1,7 +1,7 @@'use client'import type { FC } from 'react'import type { StructuredOutput } from '../../../../../llm/types'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import Field from './field'diff --git a/web/app/components/workflow/nodes/_base/components/variable/object-child-tree-panel/tree-indent-line.tsx b/web/app/components/workflow/nodes/_base/components/variable/object-child-tree-panel/tree-indent-line.tsxindex 9e45a4cccc6..786875ddd1d 100644--- a/web/app/components/workflow/nodes/_base/components/variable/object-child-tree-panel/tree-indent-line.tsx+++ b/web/app/components/workflow/nodes/_base/components/variable/object-child-tree-panel/tree-indent-line.tsx@@ -1,6 +1,6 @@'use client'import type { FC } from 'react'-import React from 'react'+import * as React from 'react'import { cn } from '@/utils/classnames'type Props = {diff --git a/web/app/components/workflow/nodes/_base/components/variable/output-var-list.tsx b/web/app/components/workflow/nodes/_base/components/variable/output-var-list.tsxindex 7eccbe23de6..44df18ddf2a 100644--- a/web/app/components/workflow/nodes/_base/components/variable/output-var-list.tsx+++ b/web/app/components/workflow/nodes/_base/components/variable/output-var-list.tsx@@ -5,7 +5,8 @@ import type { ToastHandle } from '@/app/components/base/toast'import type { VarType } from '@/app/components/workflow/types'import { useDebounceFn } from 'ahooks'import { produce } from 'immer'-import React, { useCallback, useState } from 'react'+import * as React from 'react'+import { useCallback, useState } from 'react'import { useTranslation } from 'react-i18next'import Input from '@/app/components/base/input'import Toast from '@/app/components/base/toast'diff --git a/web/app/components/workflow/nodes/_base/components/variable/var-full-path-panel.tsx b/web/app/components/workflow/nodes/_base/components/variable/var-full-path-panel.tsxindex 744567daaed..b2c63be8b61 100644--- a/web/app/components/workflow/nodes/_base/components/variable/var-full-path-panel.tsx+++ b/web/app/components/workflow/nodes/_base/components/variable/var-full-path-panel.tsx@@ -1,7 +1,7 @@'use client'import type { FC } from 'react'import type { Field, StructuredOutput, TypeWithArray } from '../../../llm/types'-import React from 'react'+import * as React from 'react'import BlockIcon from '@/app/components/workflow/block-icon'import { PickerPanelMain as Panel } from '@/app/components/workflow/nodes/_base/components/variable/object-child-tree-panel/picker'import { BlockEnum } from '@/app/components/workflow/types'diff --git a/web/app/components/workflow/nodes/_base/components/variable/var-list.tsx b/web/app/components/workflow/nodes/_base/components/variable/var-list.tsxindex c9cad912363..2d96baaf289 100644--- a/web/app/components/workflow/nodes/_base/components/variable/var-list.tsx+++ b/web/app/components/workflow/nodes/_base/components/variable/var-list.tsx@@ -5,7 +5,8 @@ import type { ValueSelector, Var, Variable } from '@/app/components/workflow/typimport { RiDraggable } from '@remixicon/react'import { useDebounceFn } from 'ahooks'import { produce } from 'immer'-import React, { useCallback, useMemo, useState } from 'react'+import * as React from 'react'+import { useCallback, useMemo, useState } from 'react'import { useTranslation } from 'react-i18next'import { ReactSortable } from 'react-sortablejs'import { v4 as uuid4 } from 'uuid'diff --git a/web/app/components/workflow/nodes/_base/components/variable/var-reference-picker.tsx b/web/app/components/workflow/nodes/_base/components/variable/var-reference-picker.tsxindex 3692cb64135..05e2c913cea 100644--- a/web/app/components/workflow/nodes/_base/components/variable/var-reference-picker.tsx+++ b/web/app/components/workflow/nodes/_base/components/variable/var-reference-picker.tsx@@ -13,7 +13,8 @@ import {} from '@remixicon/react'import { produce } from 'immer'import { noop } from 'lodash-es'-import React, { useCallback, useEffect, useMemo, useRef, useState } from 'react'+import * as React from 'react'+import { useCallback, useEffect, useMemo, useRef, useState } from 'react'import { useTranslation } from 'react-i18next'import {useNodes,diff --git a/web/app/components/workflow/nodes/_base/components/variable/var-reference-popup.tsx b/web/app/components/workflow/nodes/_base/components/variable/var-reference-popup.tsxindex 45ad5d9f8ca..22ea7411745 100644--- a/web/app/components/workflow/nodes/_base/components/variable/var-reference-popup.tsx+++ b/web/app/components/workflow/nodes/_base/components/variable/var-reference-popup.tsx@@ -1,7 +1,8 @@'use client'import type { FC } from 'react'import type { NodeOutPutVar, ValueSelector, Var } from '@/app/components/workflow/types'-import React, { useMemo } from 'react'+import * as React from 'react'+import { useMemo } from 'react'import { useTranslation } from 'react-i18next'import ListEmpty from '@/app/components/base/list-empty'import { useStore } from '@/app/components/workflow/store'diff --git a/web/app/components/workflow/nodes/_base/components/variable/var-reference-vars.tsx b/web/app/components/workflow/nodes/_base/components/variable/var-reference-vars.tsxindex 5482eea9962..dd0dfa86823 100644--- a/web/app/components/workflow/nodes/_base/components/variable/var-reference-vars.tsx+++ b/web/app/components/workflow/nodes/_base/components/variable/var-reference-vars.tsx@@ -5,7 +5,8 @@ import type { Field } from '@/app/components/workflow/nodes/llm/types'import type { NodeOutPutVar, ValueSelector, Var } from '@/app/components/workflow/types'import { useHover } from 'ahooks'import { noop } from 'lodash-es'-import React, { useEffect, useMemo, useRef, useState } from 'react'+import * as React from 'react'+import { useEffect, useMemo, useRef, useState } from 'react'import { useTranslation } from 'react-i18next'import { ChevronRight } from '@/app/components/base/icons/src/vender/line/arrows'import { CodeAssistant, MagicEdit } from '@/app/components/base/icons/src/vender/line/general'diff --git a/web/app/components/workflow/nodes/_base/components/variable/var-type-picker.tsx b/web/app/components/workflow/nodes/_base/components/variable/var-type-picker.tsxindex b6b08bc799f..3af95587cb6 100644--- a/web/app/components/workflow/nodes/_base/components/variable/var-type-picker.tsx+++ b/web/app/components/workflow/nodes/_base/components/variable/var-type-picker.tsx@@ -1,7 +1,8 @@'use client'import type { FC } from 'react'import { RiArrowDownSLine } from '@remixicon/react'-import React, { useCallback, useState } from 'react'+import * as React from 'react'+import { useCallback, useState } from 'react'import { Check } from '@/app/components/base/icons/src/vender/line/general'import {PortalToFollowElem,diff --git a/web/app/components/workflow/nodes/_base/components/workflow-panel/index.tsx b/web/app/components/workflow/nodes/_base/components/workflow-panel/index.tsxindex 3624e10bb11..8e684afa87c 100644--- a/web/app/components/workflow/nodes/_base/components/workflow-panel/index.tsx+++ b/web/app/components/workflow/nodes/_base/components/workflow-panel/index.tsx@@ -7,7 +7,8 @@ import {RiPlayLargeLine,} from '@remixicon/react'import { debounce } from 'lodash-es'-import React, {+import * as React from 'react'+import {cloneElement,memo,useCallback,diff --git a/web/app/components/workflow/nodes/_base/components/workflow-panel/last-run/index.tsx b/web/app/components/workflow/nodes/_base/components/workflow-panel/last-run/index.tsxindex 93d5debb519..31a7e3b9fdd 100644--- a/web/app/components/workflow/nodes/_base/components/workflow-panel/last-run/index.tsx+++ b/web/app/components/workflow/nodes/_base/components/workflow-panel/last-run/index.tsx@@ -3,7 +3,8 @@ import type { FC } from 'react'import type { ResultPanelProps } from '@/app/components/workflow/run/result-panel'import type { NodeTracing } from '@/types/workflow'import { RiLoader2Line } from '@remixicon/react'-import React, { useCallback, useEffect, useMemo, useState } from 'react'+import * as React from 'react'+import { useCallback, useEffect, useMemo, useState } from 'react'import { useHooksStore } from '@/app/components/workflow/hooks-store'import ResultPanel from '@/app/components/workflow/run/result-panel'import { NodeRunningStatus } from '@/app/components/workflow/types'diff --git a/web/app/components/workflow/nodes/_base/components/workflow-panel/last-run/no-data.tsx b/web/app/components/workflow/nodes/_base/components/workflow-panel/last-run/no-data.tsxindex 4ae6ccd31f6..11422bf8589 100644--- a/web/app/components/workflow/nodes/_base/components/workflow-panel/last-run/no-data.tsx+++ b/web/app/components/workflow/nodes/_base/components/workflow-panel/last-run/no-data.tsx@@ -1,7 +1,7 @@'use client'import type { FC } from 'react'import { RiPlayLine } from '@remixicon/react'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import Button from '@/app/components/base/button'import { ClockPlay } from '@/app/components/base/icons/src/vender/line/time'diff --git a/web/app/components/workflow/nodes/_base/components/workflow-panel/tab.tsx b/web/app/components/workflow/nodes/_base/components/workflow-panel/tab.tsxindex 53ae913a8e0..7878f0d476a 100644--- a/web/app/components/workflow/nodes/_base/components/workflow-panel/tab.tsx+++ b/web/app/components/workflow/nodes/_base/components/workflow-panel/tab.tsx@@ -1,6 +1,6 @@'use client'import type { FC } from 'react'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import TabHeader from '@/app/components/base/tab-header'diff --git a/web/app/components/workflow/nodes/answer/node.tsx b/web/app/components/workflow/nodes/answer/node.tsxindex 12c7b10a1a3..80fd07a9003 100644--- a/web/app/components/workflow/nodes/answer/node.tsx+++ b/web/app/components/workflow/nodes/answer/node.tsx@@ -1,7 +1,7 @@import type { FC } from 'react'import type { AnswerNodeType } from './types'import type { NodeProps } from '@/app/components/workflow/types'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import InfoPanel from '../_base/components/info-panel'import ReadonlyInputWithSelectVar from '../_base/components/readonly-input-with-select-var'diff --git a/web/app/components/workflow/nodes/answer/panel.tsx b/web/app/components/workflow/nodes/answer/panel.tsxindex 170cd17bf8b..8d539b92164 100644--- a/web/app/components/workflow/nodes/answer/panel.tsx+++ b/web/app/components/workflow/nodes/answer/panel.tsx@@ -1,7 +1,7 @@import type { FC } from 'react'import type { AnswerNodeType } from './types'import type { NodePanelProps } from '@/app/components/workflow/types'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import Editor from '@/app/components/workflow/nodes/_base/components/prompt/editor'import useAvailableVarList from '@/app/components/workflow/nodes/_base/hooks/use-available-var-list'diff --git a/web/app/components/workflow/nodes/assigner/components/var-list/index.tsx b/web/app/components/workflow/nodes/assigner/components/var-list/index.tsxindex 3f99121835d..422cd5a486b 100644--- a/web/app/components/workflow/nodes/assigner/components/var-list/index.tsx+++ b/web/app/components/workflow/nodes/assigner/components/var-list/index.tsx@@ -5,7 +5,8 @@ import type { ValueSelector, Var } from '@/app/components/workflow/types'import { RiDeleteBinLine } from '@remixicon/react'import { produce } from 'immer'import { noop } from 'lodash-es'-import React, { useCallback } from 'react'+import * as React from 'react'+import { useCallback } from 'react'import { useTranslation } from 'react-i18next'import ActionButton from '@/app/components/base/action-button'import Input from '@/app/components/base/input'diff --git a/web/app/components/workflow/nodes/assigner/node.tsx b/web/app/components/workflow/nodes/assigner/node.tsxindex c7777c45414..be30104242a 100644--- a/web/app/components/workflow/nodes/assigner/node.tsx+++ b/web/app/components/workflow/nodes/assigner/node.tsx@@ -1,7 +1,7 @@import type { FC } from 'react'import type { AssignerNodeType } from './types'import type { Node, NodeProps } from '@/app/components/workflow/types'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import { useNodes } from 'reactflow'import Badge from '@/app/components/base/badge'diff --git a/web/app/components/workflow/nodes/assigner/panel.tsx b/web/app/components/workflow/nodes/assigner/panel.tsxindex 04da330fd4b..b680ba26312 100644--- a/web/app/components/workflow/nodes/assigner/panel.tsx+++ b/web/app/components/workflow/nodes/assigner/panel.tsx@@ -4,7 +4,7 @@ import type { NodePanelProps } from '@/app/components/workflow/types'import {RiAddLine,} from '@remixicon/react'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import ActionButton from '@/app/components/base/action-button'import VarList from './components/var-list'diff --git a/web/app/components/workflow/nodes/code/dependency-picker.tsx b/web/app/components/workflow/nodes/code/dependency-picker.tsxindex 2e0e0c0d59b..1c30ce0818c 100644--- a/web/app/components/workflow/nodes/code/dependency-picker.tsx+++ b/web/app/components/workflow/nodes/code/dependency-picker.tsx@@ -4,7 +4,8 @@ import {RiArrowDownSLine,} from '@remixicon/react'import { t } from 'i18next'-import React, { useCallback, useState } from 'react'+import * as React from 'react'+import { useCallback, useState } from 'react'import { Check } from '@/app/components/base/icons/src/vender/line/general'import Input from '@/app/components/base/input'import { PortalToFollowElem, PortalToFollowElemContent, PortalToFollowElemTrigger } from '@/app/components/base/portal-to-follow-elem'diff --git a/web/app/components/workflow/nodes/code/node.tsx b/web/app/components/workflow/nodes/code/node.tsxindex 5fa002913dc..66e83dbb713 100644--- a/web/app/components/workflow/nodes/code/node.tsx+++ b/web/app/components/workflow/nodes/code/node.tsx@@ -1,7 +1,7 @@import type { FC } from 'react'import type { CodeNodeType } from './types'import type { NodeProps } from '@/app/components/workflow/types'-import React from 'react'+import * as React from 'react'const Node: FC<NodeProps<CodeNodeType>> = () => {return (diff --git a/web/app/components/workflow/nodes/code/panel.tsx b/web/app/components/workflow/nodes/code/panel.tsxindex 261195c4c55..62c2f558348 100644--- a/web/app/components/workflow/nodes/code/panel.tsx+++ b/web/app/components/workflow/nodes/code/panel.tsx@@ -1,7 +1,7 @@import type { FC } from 'react'import type { CodeNodeType } from './types'import type { NodePanelProps } from '@/app/components/workflow/types'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import AddButton from '@/app/components/base/button/add-button'import SyncButton from '@/app/components/base/button/sync-button'diff --git a/web/app/components/workflow/nodes/data-source/before-run-form.tsx b/web/app/components/workflow/nodes/data-source/before-run-form.tsxindex a091211fa54..172570c8020 100644--- a/web/app/components/workflow/nodes/data-source/before-run-form.tsx+++ b/web/app/components/workflow/nodes/data-source/before-run-form.tsx@@ -1,7 +1,8 @@'use client'import type { FC } from 'react'import type { CustomRunFormProps } from './types'-import React, { useCallback } from 'react'+import * as React from 'react'+import { useCallback } from 'react'import { useTranslation } from 'react-i18next'import Button from '@/app/components/base/button'import LocalFile from '@/app/components/datasets/documents/create-from-pipeline/data-source/local-file'diff --git a/web/app/components/workflow/nodes/document-extractor/node.tsx b/web/app/components/workflow/nodes/document-extractor/node.tsxindex c092cd353ae..f1e61b8353d 100644--- a/web/app/components/workflow/nodes/document-extractor/node.tsx+++ b/web/app/components/workflow/nodes/document-extractor/node.tsx@@ -1,7 +1,7 @@import type { FC } from 'react'import type { DocExtractorNodeType } from './types'import type { Node, NodeProps } from '@/app/components/workflow/types'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import { useNodes } from 'reactflow'import { isSystemVar } from '@/app/components/workflow/nodes/_base/components/variable/utils'diff --git a/web/app/components/workflow/nodes/document-extractor/panel.tsx b/web/app/components/workflow/nodes/document-extractor/panel.tsxindex b7cfddea4b3..87a6ab7a373 100644--- a/web/app/components/workflow/nodes/document-extractor/panel.tsx+++ b/web/app/components/workflow/nodes/document-extractor/panel.tsx@@ -1,7 +1,7 @@import type { FC } from 'react'import type { DocExtractorNodeType } from './types'import type { NodePanelProps } from '@/app/components/workflow/types'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import { useContext } from 'use-context-selector'import Field from '@/app/components/workflow/nodes/_base/components/field'diff --git a/web/app/components/workflow/nodes/end/node.tsx b/web/app/components/workflow/nodes/end/node.tsxindex 26e7b7d0222..f6bace70586 100644--- a/web/app/components/workflow/nodes/end/node.tsx+++ b/web/app/components/workflow/nodes/end/node.tsx@@ -1,7 +1,7 @@import type { FC } from 'react'import type { EndNodeType } from './types'import type { NodeProps, Variable } from '@/app/components/workflow/types'-import React from 'react'+import * as React from 'react'import {useIsChatMode,useWorkflow,diff --git a/web/app/components/workflow/nodes/end/panel.tsx b/web/app/components/workflow/nodes/end/panel.tsxindex 3970dc8efe7..b07df2ef928 100644--- a/web/app/components/workflow/nodes/end/panel.tsx+++ b/web/app/components/workflow/nodes/end/panel.tsx@@ -1,7 +1,7 @@import type { FC } from 'react'import type { EndNodeType } from './types'import type { NodePanelProps } from '@/app/components/workflow/types'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import AddButton from '@/app/components/base/button/add-button'import Field from '@/app/components/workflow/nodes/_base/components/field'diff --git a/web/app/components/workflow/nodes/http/components/api-input.tsx b/web/app/components/workflow/nodes/http/components/api-input.tsxindex a72fc9fde03..eeb91288278 100644--- a/web/app/components/workflow/nodes/http/components/api-input.tsx+++ b/web/app/components/workflow/nodes/http/components/api-input.tsx@@ -2,7 +2,8 @@import type { FC } from 'react'import type { Var } from '../../../types'import { RiArrowDownSLine } from '@remixicon/react'-import React, { useState } from 'react'+import * as React from 'react'+import { useState } from 'react'import { useTranslation } from 'react-i18next'import Input from '@/app/components/workflow/nodes/_base/components/input-support-select-var'import { cn } from '@/utils/classnames'diff --git a/web/app/components/workflow/nodes/http/components/authorization/index.tsx b/web/app/components/workflow/nodes/http/components/authorization/index.tsxindex 50505fd4c83..5293df5597c 100644--- a/web/app/components/workflow/nodes/http/components/authorization/index.tsx+++ b/web/app/components/workflow/nodes/http/components/authorization/index.tsx@@ -3,7 +3,8 @@ import type { FC } from 'react'import type { Authorization as AuthorizationPayloadType } from '../../types'import type { Var } from '@/app/components/workflow/types'import { produce } from 'immer'-import React, { useCallback, useState } from 'react'+import * as React from 'react'+import { useCallback, useState } from 'react'import { useTranslation } from 'react-i18next'import Button from '@/app/components/base/button'import BaseInput from '@/app/components/base/input'diff --git a/web/app/components/workflow/nodes/http/components/authorization/radio-group.tsx b/web/app/components/workflow/nodes/http/components/authorization/radio-group.tsxindex 6edd325b181..48ad4066b94 100644--- a/web/app/components/workflow/nodes/http/components/authorization/radio-group.tsx+++ b/web/app/components/workflow/nodes/http/components/authorization/radio-group.tsx@@ -1,6 +1,7 @@'use client'import type { FC } from 'react'-import React, { useCallback } from 'react'+import * as React from 'react'+import { useCallback } from 'react'import { cn } from '@/utils/classnames'type Option = {diff --git a/web/app/components/workflow/nodes/http/components/curl-panel.tsx b/web/app/components/workflow/nodes/http/components/curl-panel.tsxindex 2710fd3c5df..ef4ce45f380 100644--- a/web/app/components/workflow/nodes/http/components/curl-panel.tsx+++ b/web/app/components/workflow/nodes/http/components/curl-panel.tsx@@ -1,7 +1,8 @@'use client'import type { FC } from 'react'import type { HttpNodeType } from '../types'-import React, { useCallback, useState } from 'react'+import * as React from 'react'+import { useCallback, useState } from 'react'import { useTranslation } from 'react-i18next'import Button from '@/app/components/base/button'import Modal from '@/app/components/base/modal'diff --git a/web/app/components/workflow/nodes/http/components/edit-body/index.tsx b/web/app/components/workflow/nodes/http/components/edit-body/index.tsxindex 1770d01ef57..c475f1234aa 100644--- a/web/app/components/workflow/nodes/http/components/edit-body/index.tsx+++ b/web/app/components/workflow/nodes/http/components/edit-body/index.tsx@@ -4,7 +4,8 @@ import type { Body, BodyPayload, KeyValue as KeyValueType } from '../../types'import type { ValueSelector, Var } from '@/app/components/workflow/types'import { produce } from 'immer'import { uniqueId } from 'lodash-es'-import React, { useCallback, useMemo } from 'react'+import * as React from 'react'+import { useCallback, useMemo } from 'react'import InputWithVar from '@/app/components/workflow/nodes/_base/components/prompt/editor'import { VarType } from '@/app/components/workflow/types'import { cn } from '@/utils/classnames'diff --git a/web/app/components/workflow/nodes/http/components/key-value/bulk-edit/index.tsx b/web/app/components/workflow/nodes/http/components/key-value/bulk-edit/index.tsxindex ea43c726e2c..2a5b9484f77 100644--- a/web/app/components/workflow/nodes/http/components/key-value/bulk-edit/index.tsx+++ b/web/app/components/workflow/nodes/http/components/key-value/bulk-edit/index.tsx@@ -1,6 +1,7 @@'use client'import type { FC } from 'react'-import React, { useCallback } from 'react'+import * as React from 'react'+import { useCallback } from 'react'import { useTranslation } from 'react-i18next'import { LayoutGrid02 } from '@/app/components/base/icons/src/vender/line/layout'import TextEditor from '@/app/components/workflow/nodes/_base/components/editor/text-editor'diff --git a/web/app/components/workflow/nodes/http/components/key-value/index.tsx b/web/app/components/workflow/nodes/http/components/key-value/index.tsxindex 0191cb0c7a9..02ba7c641dc 100644--- a/web/app/components/workflow/nodes/http/components/key-value/index.tsx+++ b/web/app/components/workflow/nodes/http/components/key-value/index.tsx@@ -1,7 +1,7 @@'use client'import type { FC } from 'react'import type { KeyValue } from '../../types'-import React from 'react'+import * as React from 'react'import KeyValueEdit from './key-value-edit'type Props = {diff --git a/web/app/components/workflow/nodes/http/components/key-value/key-value-edit/index.tsx b/web/app/components/workflow/nodes/http/components/key-value/key-value-edit/index.tsxindex 61d6292e065..cba9e82b37a 100644--- a/web/app/components/workflow/nodes/http/components/key-value/key-value-edit/index.tsx+++ b/web/app/components/workflow/nodes/http/components/key-value/key-value-edit/index.tsx@@ -2,7 +2,8 @@import type { FC } from 'react'import type { KeyValue } from '../../../types'import { produce } from 'immer'-import React, { useCallback } from 'react'+import * as React from 'react'+import { useCallback } from 'react'import { useTranslation } from 'react-i18next'import { cn } from '@/utils/classnames'import KeyValueItem from './item'diff --git a/web/app/components/workflow/nodes/http/components/key-value/key-value-edit/input-item.tsx b/web/app/components/workflow/nodes/http/components/key-value/key-value-edit/input-item.tsxindex 2f1857f7af2..f463388dad2 100644--- a/web/app/components/workflow/nodes/http/components/key-value/key-value-edit/input-item.tsx+++ b/web/app/components/workflow/nodes/http/components/key-value/key-value-edit/input-item.tsx@@ -1,7 +1,8 @@'use client'import type { FC } from 'react'import type { Var } from '@/app/components/workflow/types'-import React, { useCallback, useState } from 'react'+import * as React from 'react'+import { useCallback, useState } from 'react'import { useTranslation } from 'react-i18next'import Input from '@/app/components/workflow/nodes/_base/components/input-support-select-var'import RemoveButton from '@/app/components/workflow/nodes/_base/components/remove-button'diff --git a/web/app/components/workflow/nodes/http/components/key-value/key-value-edit/item.tsx b/web/app/components/workflow/nodes/http/components/key-value/key-value-edit/item.tsxindex 365367fd97d..a03f09d18a7 100644--- a/web/app/components/workflow/nodes/http/components/key-value/key-value-edit/item.tsx+++ b/web/app/components/workflow/nodes/http/components/key-value/key-value-edit/item.tsx@@ -3,7 +3,8 @@ import type { FC } from 'react'import type { KeyValue } from '../../../types'import type { ValueSelector, Var } from '@/app/components/workflow/types'import { produce } from 'immer'-import React, { useCallback } from 'react'+import * as React from 'react'+import { useCallback } from 'react'import { useTranslation } from 'react-i18next'import { PortalSelect } from '@/app/components/base/select'import { VarType } from '@/app/components/workflow/types'diff --git a/web/app/components/workflow/nodes/http/components/timeout/index.tsx b/web/app/components/workflow/nodes/http/components/timeout/index.tsxindex 11edfa8c93f..0bac909f691 100644--- a/web/app/components/workflow/nodes/http/components/timeout/index.tsx+++ b/web/app/components/workflow/nodes/http/components/timeout/index.tsx@@ -1,7 +1,7 @@'use client'import type { FC } from 'react'import type { Timeout as TimeoutPayloadType } from '../../types'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import Input from '@/app/components/base/input'import { FieldCollapse } from '@/app/components/workflow/nodes/_base/components/collapse'diff --git a/web/app/components/workflow/nodes/http/node.tsx b/web/app/components/workflow/nodes/http/node.tsxindex 332a28c44c7..7ade3a691b4 100644--- a/web/app/components/workflow/nodes/http/node.tsx+++ b/web/app/components/workflow/nodes/http/node.tsx@@ -1,7 +1,7 @@import type { FC } from 'react'import type { HttpNodeType } from './types'import type { NodeProps } from '@/app/components/workflow/types'-import React from 'react'+import * as React from 'react'import ReadonlyInputWithSelectVar from '../_base/components/readonly-input-with-select-var'const Node: FC<NodeProps<HttpNodeType>> = ({diff --git a/web/app/components/workflow/nodes/if-else/components/condition-wrap.tsx b/web/app/components/workflow/nodes/if-else/components/condition-wrap.tsxindex b9f80cb9f04..cdcd7561db8 100644--- a/web/app/components/workflow/nodes/if-else/components/condition-wrap.tsx+++ b/web/app/components/workflow/nodes/if-else/components/condition-wrap.tsx@@ -8,7 +8,8 @@ import {RiDraggable,} from '@remixicon/react'import { noop } from 'lodash-es'-import React, { useCallback, useState } from 'react'+import * as React from 'react'+import { useCallback, useState } from 'react'import { useTranslation } from 'react-i18next'import { ReactSortable } from 'react-sortablejs'import Button from '@/app/components/base/button'diff --git a/web/app/components/workflow/nodes/if-else/node.tsx b/web/app/components/workflow/nodes/if-else/node.tsxindex 41a7ec5d46b..83f61f1f8ed 100644--- a/web/app/components/workflow/nodes/if-else/node.tsx+++ b/web/app/components/workflow/nodes/if-else/node.tsx@@ -1,7 +1,8 @@import type { FC } from 'react'import type { NodeProps } from 'reactflow'import type { Condition, IfElseNodeType } from './types'-import React, { useCallback } from 'react'+import * as React from 'react'+import { useCallback } from 'react'import { useTranslation } from 'react-i18next'import { VarType } from '../../types'import { NodeSourceHandle } from '../_base/components/node-handle'diff --git a/web/app/components/workflow/nodes/iteration/panel.tsx b/web/app/components/workflow/nodes/iteration/panel.tsxindex 5cffb356a29..404fb20b82a 100644--- a/web/app/components/workflow/nodes/iteration/panel.tsx+++ b/web/app/components/workflow/nodes/iteration/panel.tsx@@ -1,7 +1,7 @@import type { FC } from 'react'import type { IterationNodeType } from './types'import type { NodePanelProps } from '@/app/components/workflow/types'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import Input from '@/app/components/base/input'import Select from '@/app/components/base/select'diff --git a/web/app/components/workflow/nodes/knowledge-base/components/chunk-structure/instruction/index.tsx b/web/app/components/workflow/nodes/knowledge-base/components/chunk-structure/instruction/index.tsxindex 82af5f8d2f4..8f288364c83 100644--- a/web/app/components/workflow/nodes/knowledge-base/components/chunk-structure/instruction/index.tsx+++ b/web/app/components/workflow/nodes/knowledge-base/components/chunk-structure/instruction/index.tsx@@ -1,4 +1,4 @@-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import { AddChunks } from '@/app/components/base/icons/src/vender/knowledge'import { useDocLink } from '@/context/i18n'diff --git a/web/app/components/workflow/nodes/knowledge-base/components/chunk-structure/instruction/line.tsx b/web/app/components/workflow/nodes/knowledge-base/components/chunk-structure/instruction/line.tsxindex a2a3835be66..c4eab5d3704 100644--- a/web/app/components/workflow/nodes/knowledge-base/components/chunk-structure/instruction/line.tsx+++ b/web/app/components/workflow/nodes/knowledge-base/components/chunk-structure/instruction/line.tsx@@ -1,4 +1,4 @@-import React from 'react'+import * as React from 'react'type LineProps = {type?: 'vertical' | 'horizontal'diff --git a/web/app/components/workflow/nodes/knowledge-retrieval/components/add-dataset.tsx b/web/app/components/workflow/nodes/knowledge-retrieval/components/add-dataset.tsxindex b51d0851139..a513280dec6 100644--- a/web/app/components/workflow/nodes/knowledge-retrieval/components/add-dataset.tsx+++ b/web/app/components/workflow/nodes/knowledge-retrieval/components/add-dataset.tsx@@ -2,7 +2,8 @@import type { FC } from 'react'import type { DataSet } from '@/models/datasets'import { useBoolean } from 'ahooks'-import React, { useCallback } from 'react'+import * as React from 'react'+import { useCallback } from 'react'import SelectDataset from '@/app/components/app/configuration/dataset-config/select-dataset'import AddButton from '@/app/components/base/button/add-button'diff --git a/web/app/components/workflow/nodes/knowledge-retrieval/components/dataset-item.tsx b/web/app/components/workflow/nodes/knowledge-retrieval/components/dataset-item.tsxindex 440aa9189a5..b3f2701524a 100644--- a/web/app/components/workflow/nodes/knowledge-retrieval/components/dataset-item.tsx+++ b/web/app/components/workflow/nodes/knowledge-retrieval/components/dataset-item.tsx@@ -6,7 +6,8 @@ import {RiEditLine,} from '@remixicon/react'import { useBoolean } from 'ahooks'-import React, { useCallback, useState } from 'react'+import * as React from 'react'+import { useCallback, useState } from 'react'import { useTranslation } from 'react-i18next'import SettingsModal from '@/app/components/app/configuration/dataset-config/settings-modal'import ActionButton, { ActionButtonState } from '@/app/components/base/action-button'diff --git a/web/app/components/workflow/nodes/knowledge-retrieval/components/dataset-list.tsx b/web/app/components/workflow/nodes/knowledge-retrieval/components/dataset-list.tsxindex a804ae89533..8554fdf3e34 100644--- a/web/app/components/workflow/nodes/knowledge-retrieval/components/dataset-list.tsx+++ b/web/app/components/workflow/nodes/knowledge-retrieval/components/dataset-list.tsx@@ -2,7 +2,8 @@import type { FC } from 'react'import type { DataSet } from '@/models/datasets'import { produce } from 'immer'-import React, { useCallback, useMemo } from 'react'+import * as React from 'react'+import { useCallback, useMemo } from 'react'import { useTranslation } from 'react-i18next'import { useSelector as useAppContextSelector } from '@/context/app-context'import { hasEditPermissionForDataset } from '@/utils/permission'diff --git a/web/app/components/workflow/nodes/knowledge-retrieval/components/retrieval-config.tsx b/web/app/components/workflow/nodes/knowledge-retrieval/components/retrieval-config.tsxindex ced1bfcdae0..02ae01ba166 100644--- a/web/app/components/workflow/nodes/knowledge-retrieval/components/retrieval-config.tsx+++ b/web/app/components/workflow/nodes/knowledge-retrieval/components/retrieval-config.tsx@@ -5,7 +5,8 @@ import type { MultipleRetrievalConfig, SingleRetrievalConfig } from '../types'import type { DataSet } from '@/models/datasets'import type { DatasetConfigs } from '@/models/debug'import { RiEqualizer2Line } from '@remixicon/react'-import React, { useCallback, useMemo } from 'react'+import * as React from 'react'+import { useCallback, useMemo } from 'react'import { useTranslation } from 'react-i18next'import ConfigRetrievalContent from '@/app/components/app/configuration/dataset-config/params-config/config-content'import Button from '@/app/components/base/button'diff --git a/web/app/components/workflow/nodes/knowledge-retrieval/node.tsx b/web/app/components/workflow/nodes/knowledge-retrieval/node.tsxindex 55715f2fb0a..9f5fe1f31c7 100644--- a/web/app/components/workflow/nodes/knowledge-retrieval/node.tsx+++ b/web/app/components/workflow/nodes/knowledge-retrieval/node.tsx@@ -2,7 +2,8 @@ import type { FC } from 'react'import type { KnowledgeRetrievalNodeType } from './types'import type { NodeProps } from '@/app/components/workflow/types'import type { DataSet } from '@/models/datasets'-import React, { useEffect, useState } from 'react'+import * as React from 'react'+import { useEffect, useState } from 'react'import AppIcon from '@/app/components/base/app-icon'import { useDatasetsDetailStore } from '../../datasets-detail-store/store'diff --git a/web/app/components/workflow/nodes/list-operator/components/extract-input.tsx b/web/app/components/workflow/nodes/list-operator/components/extract-input.tsxindex 7d4b472fd37..c9a6151d726 100644--- a/web/app/components/workflow/nodes/list-operator/components/extract-input.tsx+++ b/web/app/components/workflow/nodes/list-operator/components/extract-input.tsx@@ -1,7 +1,8 @@'use client'import type { FC } from 'react'import type { Var } from '../../../types'-import React, { useState } from 'react'+import * as React from 'react'+import { useState } from 'react'import { useTranslation } from 'react-i18next'import Input from '@/app/components/workflow/nodes/_base/components/input-support-select-var'import useAvailableVarList from '@/app/components/workflow/nodes/_base/hooks/use-available-var-list'diff --git a/web/app/components/workflow/nodes/list-operator/components/filter-condition.tsx b/web/app/components/workflow/nodes/list-operator/components/filter-condition.tsxindex d77a0c3eb3a..8dd817a5ada 100644--- a/web/app/components/workflow/nodes/list-operator/components/filter-condition.tsx+++ b/web/app/components/workflow/nodes/list-operator/components/filter-condition.tsx@@ -1,7 +1,8 @@'use client'import type { FC } from 'react'import type { Condition } from '../types'-import React, { useCallback, useMemo, useState } from 'react'+import * as React from 'react'+import { useCallback, useMemo, useState } from 'react'import { useTranslation } from 'react-i18next'import { SimpleSelect as Select } from '@/app/components/base/select'import Input from '@/app/components/workflow/nodes/_base/components/input-support-select-var'diff --git a/web/app/components/workflow/nodes/list-operator/components/limit-config.tsx b/web/app/components/workflow/nodes/list-operator/components/limit-config.tsxindex f7356b58aaa..1793deb293c 100644--- a/web/app/components/workflow/nodes/list-operator/components/limit-config.tsx+++ b/web/app/components/workflow/nodes/list-operator/components/limit-config.tsx@@ -1,7 +1,8 @@'use client'import type { FC } from 'react'import type { Limit } from '../types'-import React, { useCallback } from 'react'+import * as React from 'react'+import { useCallback } from 'react'import { useTranslation } from 'react-i18next'import Switch from '@/app/components/base/switch'import Field from '@/app/components/workflow/nodes/_base/components/field'diff --git a/web/app/components/workflow/nodes/list-operator/components/sub-variable-picker.tsx b/web/app/components/workflow/nodes/list-operator/components/sub-variable-picker.tsxindex ee8703ca6c6..52669526c6d 100644--- a/web/app/components/workflow/nodes/list-operator/components/sub-variable-picker.tsx+++ b/web/app/components/workflow/nodes/list-operator/components/sub-variable-picker.tsx@@ -1,7 +1,8 @@'use client'import type { FC } from 'react'import type { Item } from '@/app/components/base/select'-import React, { useCallback } from 'react'+import * as React from 'react'+import { useCallback } from 'react'import { useTranslation } from 'react-i18next'import { Variable02 } from '@/app/components/base/icons/src/vender/solid/development'import { SimpleSelect as Select } from '@/app/components/base/select'diff --git a/web/app/components/workflow/nodes/list-operator/node.tsx b/web/app/components/workflow/nodes/list-operator/node.tsxindex 4d02595fcf3..29b79636ddf 100644--- a/web/app/components/workflow/nodes/list-operator/node.tsx+++ b/web/app/components/workflow/nodes/list-operator/node.tsx@@ -1,7 +1,7 @@import type { FC } from 'react'import type { ListFilterNodeType } from './types'import type { Node, NodeProps } from '@/app/components/workflow/types'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import { useNodes } from 'reactflow'import { isSystemVar } from '@/app/components/workflow/nodes/_base/components/variable/utils'diff --git a/web/app/components/workflow/nodes/list-operator/panel.tsx b/web/app/components/workflow/nodes/list-operator/panel.tsxindex be1d79dcad2..f9d279f966e 100644--- a/web/app/components/workflow/nodes/list-operator/panel.tsx+++ b/web/app/components/workflow/nodes/list-operator/panel.tsx@@ -1,7 +1,7 @@import type { FC } from 'react'import type { ListFilterNodeType } from './types'import type { NodePanelProps } from '@/app/components/workflow/types'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import Switch from '@/app/components/base/switch'import Field from '@/app/components/workflow/nodes/_base/components/field'diff --git a/web/app/components/workflow/nodes/llm/components/config-prompt-item.tsx b/web/app/components/workflow/nodes/llm/components/config-prompt-item.tsxindex a712d6e4089..776ad6804c5 100644--- a/web/app/components/workflow/nodes/llm/components/config-prompt-item.tsx+++ b/web/app/components/workflow/nodes/llm/components/config-prompt-item.tsx@@ -1,7 +1,8 @@'use client'import type { FC } from 'react'import type { ModelConfig, PromptItem, Variable } from '../../../types'-import React, { useCallback } from 'react'+import * as React from 'react'+import { useCallback } from 'react'import { useTranslation } from 'react-i18next'import Tooltip from '@/app/components/base/tooltip'import Editor from '@/app/components/workflow/nodes/_base/components/prompt/editor'diff --git a/web/app/components/workflow/nodes/llm/components/config-prompt.tsx b/web/app/components/workflow/nodes/llm/components/config-prompt.tsxindex 856b88ac00e..228156f009e 100644--- a/web/app/components/workflow/nodes/llm/components/config-prompt.tsx+++ b/web/app/components/workflow/nodes/llm/components/config-prompt.tsx@@ -2,7 +2,8 @@import type { FC } from 'react'import type { ModelConfig, PromptItem, ValueSelector, Var, Variable } from '../../../types'import { produce } from 'immer'-import React, { useCallback } from 'react'+import * as React from 'react'+import { useCallback } from 'react'import { useTranslation } from 'react-i18next'import { ReactSortable } from 'react-sortablejs'import { v4 as uuid4 } from 'uuid'diff --git a/web/app/components/workflow/nodes/llm/components/json-schema-config-modal/code-editor.tsx b/web/app/components/workflow/nodes/llm/components/json-schema-config-modal/code-editor.tsxindex 72620ee2331..0e1aac8a32d 100644--- a/web/app/components/workflow/nodes/llm/components/json-schema-config-modal/code-editor.tsx+++ b/web/app/components/workflow/nodes/llm/components/json-schema-config-modal/code-editor.tsx@@ -2,7 +2,8 @@ import type { FC } from 'react'import { Editor } from '@monaco-editor/react'import { RiClipboardLine, RiIndentIncrease } from '@remixicon/react'import copy from 'copy-to-clipboard'-import React, { useCallback, useEffect, useMemo, useRef } from 'react'+import * as React from 'react'+import { useCallback, useEffect, useMemo, useRef } from 'react'import { useTranslation } from 'react-i18next'import Tooltip from '@/app/components/base/tooltip'import useTheme from '@/hooks/use-theme'diff --git a/web/app/components/workflow/nodes/llm/components/json-schema-config-modal/error-message.tsx b/web/app/components/workflow/nodes/llm/components/json-schema-config-modal/error-message.tsxindex 5cb2a421d5c..041894fee6a 100644--- a/web/app/components/workflow/nodes/llm/components/json-schema-config-modal/error-message.tsx+++ b/web/app/components/workflow/nodes/llm/components/json-schema-config-modal/error-message.tsx@@ -1,6 +1,6 @@import type { FC } from 'react'import { RiErrorWarningFill } from '@remixicon/react'-import React from 'react'+import * as React from 'react'import { cn } from '@/utils/classnames'type ErrorMessageProps = {diff --git a/web/app/components/workflow/nodes/llm/components/json-schema-config-modal/index.tsx b/web/app/components/workflow/nodes/llm/components/json-schema-config-modal/index.tsxindex b7a0a40f32c..66ea3bfc598 100644--- a/web/app/components/workflow/nodes/llm/components/json-schema-config-modal/index.tsx+++ b/web/app/components/workflow/nodes/llm/components/json-schema-config-modal/index.tsx@@ -1,6 +1,6 @@import type { FC } from 'react'import type { SchemaRoot } from '../../types'-import React from 'react'+import * as React from 'react'import Modal from '../../../../../base/modal'import JsonSchemaConfig from './json-schema-config'diff --git a/web/app/components/workflow/nodes/llm/components/json-schema-config-modal/json-importer.tsx b/web/app/components/workflow/nodes/llm/components/json-schema-config-modal/json-importer.tsxindex 0110756b475..b69ce186f98 100644--- a/web/app/components/workflow/nodes/llm/components/json-schema-config-modal/json-importer.tsx+++ b/web/app/components/workflow/nodes/llm/components/json-schema-config-modal/json-importer.tsx@@ -1,6 +1,7 @@import type { FC } from 'react'import { RiCloseLine } from '@remixicon/react'-import React, { useCallback, useEffect, useRef, useState } from 'react'+import * as React from 'react'+import { useCallback, useEffect, useRef, useState } from 'react'import { useTranslation } from 'react-i18next'import Button from '@/app/components/base/button'import { PortalToFollowElem, PortalToFollowElemContent, PortalToFollowElemTrigger } from '@/app/components/base/portal-to-follow-elem'diff --git a/web/app/components/workflow/nodes/llm/components/json-schema-config-modal/json-schema-config.tsx b/web/app/components/workflow/nodes/llm/components/json-schema-config-modal/json-schema-config.tsxindex c5eaea6efdf..38c6539d89d 100644--- a/web/app/components/workflow/nodes/llm/components/json-schema-config-modal/json-schema-config.tsx+++ b/web/app/components/workflow/nodes/llm/components/json-schema-config-modal/json-schema-config.tsx@@ -1,7 +1,8 @@import type { FC } from 'react'import type { SchemaRoot } from '../../types'import { RiBracesLine, RiCloseLine, RiExternalLinkLine, RiTimelineView } from '@remixicon/react'-import React, { useCallback, useState } from 'react'+import * as React from 'react'+import { useCallback, useState } from 'react'import { useTranslation } from 'react-i18next'import Button from '@/app/components/base/button'import Divider from '@/app/components/base/divider'diff --git a/web/app/components/workflow/nodes/llm/components/json-schema-config-modal/json-schema-generator/generated-result.tsx b/web/app/components/workflow/nodes/llm/components/json-schema-config-modal/json-schema-generator/generated-result.tsxindex 0e7d8c8d0c6..5921976c414 100644--- a/web/app/components/workflow/nodes/llm/components/json-schema-config-modal/json-schema-generator/generated-result.tsx+++ b/web/app/components/workflow/nodes/llm/components/json-schema-config-modal/json-schema-generator/generated-result.tsx@@ -1,7 +1,8 @@import type { FC } from 'react'import type { SchemaRoot } from '../../../types'import { RiArrowLeftLine, RiCloseLine, RiSparklingLine } from '@remixicon/react'-import React, { useCallback, useMemo, useState } from 'react'+import * as React from 'react'+import { useCallback, useMemo, useState } from 'react'import { useTranslation } from 'react-i18next'import Button from '@/app/components/base/button'import Loading from '@/app/components/base/loading'diff --git a/web/app/components/workflow/nodes/llm/components/json-schema-config-modal/json-schema-generator/index.tsx b/web/app/components/workflow/nodes/llm/components/json-schema-config-modal/json-schema-generator/index.tsxindex a4da5b69e31..6a34925275f 100644--- a/web/app/components/workflow/nodes/llm/components/json-schema-config-modal/json-schema-generator/index.tsx+++ b/web/app/components/workflow/nodes/llm/components/json-schema-config-modal/json-schema-generator/index.tsx@@ -2,7 +2,8 @@ import type { FC } from 'react'import type { SchemaRoot } from '../../../types'import type { FormValue } from '@/app/components/header/account-setting/model-provider-page/declarations'import type { CompletionParams, Model } from '@/types/app'-import React, { useCallback, useEffect, useState } from 'react'+import * as React from 'react'+import { useCallback, useEffect, useState } from 'react'import {PortalToFollowElem,PortalToFollowElemContent,diff --git a/web/app/components/workflow/nodes/llm/components/json-schema-config-modal/json-schema-generator/prompt-editor.tsx b/web/app/components/workflow/nodes/llm/components/json-schema-config-modal/json-schema-generator/prompt-editor.tsxindex 17641fdf376..b9e0938e9b8 100644--- a/web/app/components/workflow/nodes/llm/components/json-schema-config-modal/json-schema-generator/prompt-editor.tsx+++ b/web/app/components/workflow/nodes/llm/components/json-schema-config-modal/json-schema-generator/prompt-editor.tsx@@ -2,7 +2,8 @@ import type { FC } from 'react'import type { FormValue } from '@/app/components/header/account-setting/model-provider-page/declarations'import type { Model } from '@/types/app'import { RiCloseLine, RiSparklingFill } from '@remixicon/react'-import React, { useCallback } from 'react'+import * as React from 'react'+import { useCallback } from 'react'import { useTranslation } from 'react-i18next'import Button from '@/app/components/base/button'import Textarea from '@/app/components/base/textarea'diff --git a/web/app/components/workflow/nodes/llm/components/json-schema-config-modal/schema-editor.tsx b/web/app/components/workflow/nodes/llm/components/json-schema-config-modal/schema-editor.tsxindex 54753f08b48..fc95b4a998c 100644--- a/web/app/components/workflow/nodes/llm/components/json-schema-config-modal/schema-editor.tsx+++ b/web/app/components/workflow/nodes/llm/components/json-schema-config-modal/schema-editor.tsx@@ -1,5 +1,5 @@import type { FC } from 'react'-import React from 'react'+import * as React from 'react'import LargeDataAlert from '@/app/components/workflow/variable-inspect/large-data-alert'import { cn } from '@/utils/classnames'import CodeEditor from './code-editor'diff --git a/web/app/components/workflow/nodes/llm/components/json-schema-config-modal/visual-editor/add-field.tsx b/web/app/components/workflow/nodes/llm/components/json-schema-config-modal/visual-editor/add-field.tsxindex 54a3b6bb858..967481ac941 100644--- a/web/app/components/workflow/nodes/llm/components/json-schema-config-modal/visual-editor/add-field.tsx+++ b/web/app/components/workflow/nodes/llm/components/json-schema-config-modal/visual-editor/add-field.tsx@@ -1,5 +1,6 @@import { RiAddCircleFill } from '@remixicon/react'-import React, { useCallback } from 'react'+import * as React from 'react'+import { useCallback } from 'react'import { useTranslation } from 'react-i18next'import Button from '@/app/components/base/button'import { useMittContext } from './context'diff --git a/web/app/components/workflow/nodes/llm/components/json-schema-config-modal/visual-editor/card.tsx b/web/app/components/workflow/nodes/llm/components/json-schema-config-modal/visual-editor/card.tsxindex 35104988350..56d7c7dc31d 100644--- a/web/app/components/workflow/nodes/llm/components/json-schema-config-modal/visual-editor/card.tsx+++ b/web/app/components/workflow/nodes/llm/components/json-schema-config-modal/visual-editor/card.tsx@@ -1,5 +1,5 @@import type { FC } from 'react'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'type CardProps = {diff --git a/web/app/components/workflow/nodes/llm/components/json-schema-config-modal/visual-editor/edit-card/actions.tsx b/web/app/components/workflow/nodes/llm/components/json-schema-config-modal/visual-editor/edit-card/actions.tsxindex a612701adc3..fae1d2ab5a7 100644--- a/web/app/components/workflow/nodes/llm/components/json-schema-config-modal/visual-editor/edit-card/actions.tsx+++ b/web/app/components/workflow/nodes/llm/components/json-schema-config-modal/visual-editor/edit-card/actions.tsx@@ -1,6 +1,6 @@import type { FC } from 'react'import { RiAddCircleLine, RiDeleteBinLine, RiEditLine } from '@remixicon/react'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import Tooltip from '@/app/components/base/tooltip'diff --git a/web/app/components/workflow/nodes/llm/components/json-schema-config-modal/visual-editor/edit-card/advanced-actions.tsx b/web/app/components/workflow/nodes/llm/components/json-schema-config-modal/visual-editor/edit-card/advanced-actions.tsxindex ee60195fdb1..1555f20a836 100644--- a/web/app/components/workflow/nodes/llm/components/json-schema-config-modal/visual-editor/edit-card/advanced-actions.tsx+++ b/web/app/components/workflow/nodes/llm/components/json-schema-config-modal/visual-editor/edit-card/advanced-actions.tsx@@ -1,6 +1,6 @@import type { FC } from 'react'import { useKeyPress } from 'ahooks'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import Button from '@/app/components/base/button'import { getKeyboardKeyCodeBySystem, getKeyboardKeyNameBySystem } from '@/app/components/workflow/utils'diff --git a/web/app/components/workflow/nodes/llm/components/json-schema-config-modal/visual-editor/edit-card/advanced-options.tsx b/web/app/components/workflow/nodes/llm/components/json-schema-config-modal/visual-editor/edit-card/advanced-options.tsxindex 28ea12d9a3d..10e6e721a8e 100644--- a/web/app/components/workflow/nodes/llm/components/json-schema-config-modal/visual-editor/edit-card/advanced-options.tsx+++ b/web/app/components/workflow/nodes/llm/components/json-schema-config-modal/visual-editor/edit-card/advanced-options.tsx@@ -1,5 +1,6 @@import type { FC } from 'react'-import React, { useCallback, useState } from 'react'+import * as React from 'react'+import { useCallback, useState } from 'react'import { useTranslation } from 'react-i18next'import Divider from '@/app/components/base/divider'import Textarea from '@/app/components/base/textarea'diff --git a/web/app/components/workflow/nodes/llm/components/json-schema-config-modal/visual-editor/edit-card/auto-width-input.tsx b/web/app/components/workflow/nodes/llm/components/json-schema-config-modal/visual-editor/edit-card/auto-width-input.tsxindex 2dfaa88260a..4f471ec38cd 100644--- a/web/app/components/workflow/nodes/llm/components/json-schema-config-modal/visual-editor/edit-card/auto-width-input.tsx+++ b/web/app/components/workflow/nodes/llm/components/json-schema-config-modal/visual-editor/edit-card/auto-width-input.tsx@@ -1,5 +1,6 @@import type { FC } from 'react'-import React, { useEffect, useState } from 'react'+import * as React from 'react'+import { useEffect, useState } from 'react'import { cn } from '@/utils/classnames'type AutoWidthInputProps = {diff --git a/web/app/components/workflow/nodes/llm/components/json-schema-config-modal/visual-editor/edit-card/index.tsx b/web/app/components/workflow/nodes/llm/components/json-schema-config-modal/visual-editor/edit-card/index.tsxindex e3ae0d16ab3..81899f6b691 100644--- a/web/app/components/workflow/nodes/llm/components/json-schema-config-modal/visual-editor/edit-card/index.tsx+++ b/web/app/components/workflow/nodes/llm/components/json-schema-config-modal/visual-editor/edit-card/index.tsx@@ -3,7 +3,8 @@ import type { SchemaEnumType } from '../../../../types'import type { AdvancedOptionsType } from './advanced-options'import type { TypeItem } from './type-selector'import { useUnmount } from 'ahooks'-import React, { useCallback, useMemo, useRef, useState } from 'react'+import * as React from 'react'+import { useCallback, useMemo, useRef, useState } from 'react'import { useTranslation } from 'react-i18next'import Divider from '@/app/components/base/divider'import { JSON_SCHEMA_MAX_DEPTH } from '@/config'diff --git a/web/app/components/workflow/nodes/llm/components/json-schema-config-modal/visual-editor/edit-card/required-switch.tsx b/web/app/components/workflow/nodes/llm/components/json-schema-config-modal/visual-editor/edit-card/required-switch.tsxindex b84bdd07756..7ee68d1bcb8 100644--- a/web/app/components/workflow/nodes/llm/components/json-schema-config-modal/visual-editor/edit-card/required-switch.tsx+++ b/web/app/components/workflow/nodes/llm/components/json-schema-config-modal/visual-editor/edit-card/required-switch.tsx@@ -1,5 +1,5 @@import type { FC } from 'react'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import Switch from '@/app/components/base/switch'diff --git a/web/app/components/workflow/nodes/llm/components/json-schema-config-modal/visual-editor/schema-node.tsx b/web/app/components/workflow/nodes/llm/components/json-schema-config-modal/visual-editor/schema-node.tsxindex 23cd1ee477e..0fdf5b43496 100644--- a/web/app/components/workflow/nodes/llm/components/json-schema-config-modal/visual-editor/schema-node.tsx+++ b/web/app/components/workflow/nodes/llm/components/json-schema-config-modal/visual-editor/schema-node.tsx@@ -2,7 +2,8 @@ import type { FC } from 'react'import type { Field } from '../../../types'import { RiArrowDropDownLine, RiArrowDropRightLine } from '@remixicon/react'import { useDebounceFn } from 'ahooks'-import React, { useMemo, useState } from 'react'+import * as React from 'react'+import { useMemo, useState } from 'react'import Divider from '@/app/components/base/divider'import { JSON_SCHEMA_MAX_DEPTH } from '@/config'import { cn } from '@/utils/classnames'diff --git a/web/app/components/workflow/nodes/llm/components/prompt-generator-btn.tsx b/web/app/components/workflow/nodes/llm/components/prompt-generator-btn.tsxindex eb285ee3893..da272b4b142 100644--- a/web/app/components/workflow/nodes/llm/components/prompt-generator-btn.tsx+++ b/web/app/components/workflow/nodes/llm/components/prompt-generator-btn.tsx@@ -3,7 +3,8 @@ import type { FC } from 'react'import type { ModelConfig } from '@/app/components/workflow/types'import type { GenRes } from '@/service/debug'import { useBoolean } from 'ahooks'-import React, { useCallback } from 'react'+import * as React from 'react'+import { useCallback } from 'react'import GetAutomaticResModal from '@/app/components/app/configuration/config/automatic/get-automatic-res'import { ActionButton } from '@/app/components/base/action-button'import { Generator } from '@/app/components/base/icons/src/vender/other'diff --git a/web/app/components/workflow/nodes/llm/components/reasoning-format-config.tsx b/web/app/components/workflow/nodes/llm/components/reasoning-format-config.tsxindex 147981e398e..6a20c893157 100644--- a/web/app/components/workflow/nodes/llm/components/reasoning-format-config.tsx+++ b/web/app/components/workflow/nodes/llm/components/reasoning-format-config.tsx@@ -1,5 +1,5 @@import type { FC } from 'react'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import Switch from '@/app/components/base/switch'import Field from '@/app/components/workflow/nodes/_base/components/field'diff --git a/web/app/components/workflow/nodes/llm/components/resolution-picker.tsx b/web/app/components/workflow/nodes/llm/components/resolution-picker.tsxindex fe078ba6fab..e59c2764a0b 100644--- a/web/app/components/workflow/nodes/llm/components/resolution-picker.tsx+++ b/web/app/components/workflow/nodes/llm/components/resolution-picker.tsx@@ -1,6 +1,7 @@'use client'import type { FC } from 'react'-import React, { useCallback } from 'react'+import * as React from 'react'+import { useCallback } from 'react'import { useTranslation } from 'react-i18next'import OptionCard from '@/app/components/workflow/nodes/_base/components/option-card'import { Resolution } from '@/types/app'diff --git a/web/app/components/workflow/nodes/llm/components/structure-output.tsx b/web/app/components/workflow/nodes/llm/components/structure-output.tsxindex b97d5e20b7b..c4db2d66376 100644--- a/web/app/components/workflow/nodes/llm/components/structure-output.tsx+++ b/web/app/components/workflow/nodes/llm/components/structure-output.tsx@@ -3,7 +3,8 @@ import type { FC } from 'react'import type { SchemaRoot, StructuredOutput } from '../types'import { RiEditLine } from '@remixicon/react'import { useBoolean } from 'ahooks'-import React, { useCallback } from 'react'+import * as React from 'react'+import { useCallback } from 'react'import { useTranslation } from 'react-i18next'import Button from '@/app/components/base/button'import ShowPanel from '@/app/components/workflow/nodes/_base/components/variable/object-child-tree-panel/show'diff --git a/web/app/components/workflow/nodes/llm/node.tsx b/web/app/components/workflow/nodes/llm/node.tsxindex 9d44d49475a..6a9574a10b2 100644--- a/web/app/components/workflow/nodes/llm/node.tsx+++ b/web/app/components/workflow/nodes/llm/node.tsx@@ -1,7 +1,7 @@import type { FC } from 'react'import type { LLMNodeType } from './types'import type { NodeProps } from '@/app/components/workflow/types'-import React from 'react'+import * as React from 'react'import {useTextGenerationCurrentProviderAndModelAndModelList,} from '@/app/components/header/account-setting/model-provider-page/hooks'diff --git a/web/app/components/workflow/nodes/llm/panel.tsx b/web/app/components/workflow/nodes/llm/panel.tsxindex 4044989a07c..fd20b1a2bb9 100644--- a/web/app/components/workflow/nodes/llm/panel.tsx+++ b/web/app/components/workflow/nodes/llm/panel.tsx@@ -2,7 +2,8 @@ import type { FC } from 'react'import type { LLMNodeType } from './types'import type { NodePanelProps } from '@/app/components/workflow/types'import { RiAlertFill, RiQuestionLine } from '@remixicon/react'-import React, { useCallback } from 'react'+import * as React from 'react'+import { useCallback } from 'react'import { useTranslation } from 'react-i18next'import AddButton2 from '@/app/components/base/button/add-button'import Switch from '@/app/components/base/switch'diff --git a/web/app/components/workflow/nodes/loop/components/condition-wrap.tsx b/web/app/components/workflow/nodes/loop/components/condition-wrap.tsxindex 00f44ab2448..72dfd92d51a 100644--- a/web/app/components/workflow/nodes/loop/components/condition-wrap.tsx+++ b/web/app/components/workflow/nodes/loop/components/condition-wrap.tsx@@ -5,7 +5,8 @@ import type { Condition, HandleAddCondition, HandleAddSubVariableCondition, Handimport {RiAddLine,} from '@remixicon/react'-import React, { useCallback } from 'react'+import * as React from 'react'+import { useCallback } from 'react'import { useTranslation } from 'react-i18next'import Button from '@/app/components/base/button'import { PortalSelect as Select } from '@/app/components/base/select'diff --git a/web/app/components/workflow/nodes/loop/panel.tsx b/web/app/components/workflow/nodes/loop/panel.tsxindex 45fec4030ff..036abda6dec 100644--- a/web/app/components/workflow/nodes/loop/panel.tsx+++ b/web/app/components/workflow/nodes/loop/panel.tsx@@ -2,7 +2,7 @@ import type { FC } from 'react'import type { LoopNodeType } from './types'import type { NodePanelProps } from '@/app/components/workflow/types'import { RiAddLine } from '@remixicon/react'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import Field from '@/app/components/workflow/nodes/_base/components/field'import { LOOP_NODE_MAX_COUNT } from '@/config'diff --git a/web/app/components/workflow/nodes/parameter-extractor/components/extract-parameter/item.tsx b/web/app/components/workflow/nodes/parameter-extractor/components/extract-parameter/item.tsxindex 6382b331546..317d2583e2e 100644--- a/web/app/components/workflow/nodes/parameter-extractor/components/extract-parameter/item.tsx+++ b/web/app/components/workflow/nodes/parameter-extractor/components/extract-parameter/item.tsx@@ -5,7 +5,7 @@ import {RiDeleteBinLine,RiEditLine,} from '@remixicon/react'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import { Variable02 } from '@/app/components/base/icons/src/vender/solid/development'diff --git a/web/app/components/workflow/nodes/parameter-extractor/components/extract-parameter/list.tsx b/web/app/components/workflow/nodes/parameter-extractor/components/extract-parameter/list.tsxindex 1cd12329837..94343dd5d75 100644--- a/web/app/components/workflow/nodes/parameter-extractor/components/extract-parameter/list.tsx+++ b/web/app/components/workflow/nodes/parameter-extractor/components/extract-parameter/list.tsx@@ -3,7 +3,8 @@ import type { FC } from 'react'import type { Param } from '../../types'import type { MoreInfo } from '@/app/components/workflow/types'import { useBoolean } from 'ahooks'-import React, { useCallback, useState } from 'react'+import * as React from 'react'+import { useCallback, useState } from 'react'import { useTranslation } from 'react-i18next'import ListNoDataPlaceholder from '../../../_base/components/list-no-data-placeholder'import Item from './item'diff --git a/web/app/components/workflow/nodes/parameter-extractor/components/extract-parameter/update.tsx b/web/app/components/workflow/nodes/parameter-extractor/components/extract-parameter/update.tsxindex 3048a78118a..288e486ea7a 100644--- a/web/app/components/workflow/nodes/parameter-extractor/components/extract-parameter/update.tsx+++ b/web/app/components/workflow/nodes/parameter-extractor/components/extract-parameter/update.tsx@@ -3,7 +3,8 @@ import type { FC } from 'react'import type { Param } from '../../types'import type { MoreInfo } from '@/app/components/workflow/types'import { useBoolean } from 'ahooks'-import React, { useCallback, useState } from 'react'+import * as React from 'react'+import { useCallback, useState } from 'react'import { useTranslation } from 'react-i18next'import Field from '@/app/components/app/configuration/config-var/config-modal/field'import ConfigSelect from '@/app/components/app/configuration/config-var/config-select'diff --git a/web/app/components/workflow/nodes/parameter-extractor/components/reasoning-mode-picker.tsx b/web/app/components/workflow/nodes/parameter-extractor/components/reasoning-mode-picker.tsxindex dc5354a21af..7990bcc361e 100644--- a/web/app/components/workflow/nodes/parameter-extractor/components/reasoning-mode-picker.tsx+++ b/web/app/components/workflow/nodes/parameter-extractor/components/reasoning-mode-picker.tsx@@ -1,6 +1,7 @@'use client'import type { FC } from 'react'-import React, { useCallback } from 'react'+import * as React from 'react'+import { useCallback } from 'react'import { useTranslation } from 'react-i18next'import Field from '../../_base/components/field'import OptionCard from '../../_base/components/option-card'diff --git a/web/app/components/workflow/nodes/parameter-extractor/node.tsx b/web/app/components/workflow/nodes/parameter-extractor/node.tsxindex 014706810ff..9e02d657ff6 100644--- a/web/app/components/workflow/nodes/parameter-extractor/node.tsx+++ b/web/app/components/workflow/nodes/parameter-extractor/node.tsx@@ -1,7 +1,7 @@import type { FC } from 'react'import type { ParameterExtractorNodeType } from './types'import type { NodeProps } from '@/app/components/workflow/types'-import React from 'react'+import * as React from 'react'import {useTextGenerationCurrentProviderAndModelAndModelList,} from '@/app/components/header/account-setting/model-provider-page/hooks'diff --git a/web/app/components/workflow/nodes/parameter-extractor/panel.tsx b/web/app/components/workflow/nodes/parameter-extractor/panel.tsxindex 563c124102b..9603da5869a 100644--- a/web/app/components/workflow/nodes/parameter-extractor/panel.tsx+++ b/web/app/components/workflow/nodes/parameter-extractor/panel.tsx@@ -1,7 +1,7 @@import type { FC } from 'react'import type { ParameterExtractorNodeType } from './types'import type { NodePanelProps } from '@/app/components/workflow/types'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import Tooltip from '@/app/components/base/tooltip'import ModelParameterModal from '@/app/components/header/account-setting/model-provider-page/model-parameter-modal'diff --git a/web/app/components/workflow/nodes/question-classifier/components/advanced-setting.tsx b/web/app/components/workflow/nodes/question-classifier/components/advanced-setting.tsxindex 336bd3463ae..0a6b3dbbfbf 100644--- a/web/app/components/workflow/nodes/question-classifier/components/advanced-setting.tsx+++ b/web/app/components/workflow/nodes/question-classifier/components/advanced-setting.tsx@@ -1,7 +1,7 @@'use client'import type { FC } from 'react'import type { Memory, Node, NodeOutPutVar } from '@/app/components/workflow/types'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import Tooltip from '@/app/components/base/tooltip'import Editor from '@/app/components/workflow/nodes/_base/components/prompt/editor'diff --git a/web/app/components/workflow/nodes/question-classifier/components/class-item.tsx b/web/app/components/workflow/nodes/question-classifier/components/class-item.tsxindex eb629a857cd..2af2f8036a9 100644--- a/web/app/components/workflow/nodes/question-classifier/components/class-item.tsx+++ b/web/app/components/workflow/nodes/question-classifier/components/class-item.tsx@@ -3,7 +3,8 @@ import type { FC } from 'react'import type { Topic } from '../types'import type { ValueSelector, Var } from '@/app/components/workflow/types'import { uniqueId } from 'lodash-es'-import React, { useCallback, useEffect, useState } from 'react'+import * as React from 'react'+import { useCallback, useEffect, useState } from 'react'import { useTranslation } from 'react-i18next'import Editor from '@/app/components/workflow/nodes/_base/components/prompt/editor'import useAvailableVarList from '@/app/components/workflow/nodes/_base/hooks/use-available-var-list'diff --git a/web/app/components/workflow/nodes/question-classifier/components/class-list.tsx b/web/app/components/workflow/nodes/question-classifier/components/class-list.tsxindex 387d60d671f..8e61f918a52 100644--- a/web/app/components/workflow/nodes/question-classifier/components/class-list.tsx+++ b/web/app/components/workflow/nodes/question-classifier/components/class-list.tsx@@ -5,7 +5,8 @@ import type { ValueSelector, Var } from '@/app/components/workflow/types'import { RiDraggable } from '@remixicon/react'import { produce } from 'immer'import { noop } from 'lodash-es'-import React, { useCallback, useEffect, useRef, useState } from 'react'+import * as React from 'react'+import { useCallback, useEffect, useRef, useState } from 'react'import { useTranslation } from 'react-i18next'import { ReactSortable } from 'react-sortablejs'import { ArrowDownRoundFill } from '@/app/components/base/icons/src/vender/solid/general'diff --git a/web/app/components/workflow/nodes/question-classifier/node.tsx b/web/app/components/workflow/nodes/question-classifier/node.tsxindex e0a330e110b..e00eee9d41b 100644--- a/web/app/components/workflow/nodes/question-classifier/node.tsx+++ b/web/app/components/workflow/nodes/question-classifier/node.tsx@@ -2,7 +2,7 @@ import type { TFunction } from 'i18next'import type { FC } from 'react'import type { NodeProps } from 'reactflow'import type { QuestionClassifierNodeType } from './types'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import Tooltip from '@/app/components/base/tooltip'import {diff --git a/web/app/components/workflow/nodes/question-classifier/panel.tsx b/web/app/components/workflow/nodes/question-classifier/panel.tsxindex 9496f909151..05b93c98b99 100644--- a/web/app/components/workflow/nodes/question-classifier/panel.tsx+++ b/web/app/components/workflow/nodes/question-classifier/panel.tsx@@ -1,7 +1,7 @@import type { FC } from 'react'import type { QuestionClassifierNodeType } from './types'import type { NodePanelProps } from '@/app/components/workflow/types'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import ModelParameterModal from '@/app/components/header/account-setting/model-provider-page/model-parameter-modal'import { FieldCollapse } from '@/app/components/workflow/nodes/_base/components/collapse'diff --git a/web/app/components/workflow/nodes/start/components/var-item.tsx b/web/app/components/workflow/nodes/start/components/var-item.tsxindex 317a733d9b8..a506c51e31d 100644--- a/web/app/components/workflow/nodes/start/components/var-item.tsx+++ b/web/app/components/workflow/nodes/start/components/var-item.tsx@@ -6,7 +6,8 @@ import {} from '@remixicon/react'import { useBoolean, useHover } from 'ahooks'import { noop } from 'lodash-es'-import React, { useCallback, useRef } from 'react'+import * as React from 'react'+import { useCallback, useRef } from 'react'import { useTranslation } from 'react-i18next'import ConfigVarModal from '@/app/components/app/configuration/config-var/config-modal'import Badge from '@/app/components/base/badge'diff --git a/web/app/components/workflow/nodes/start/components/var-list.tsx b/web/app/components/workflow/nodes/start/components/var-list.tsxindex 5ae45c71926..bda45ca5dda 100644--- a/web/app/components/workflow/nodes/start/components/var-list.tsx+++ b/web/app/components/workflow/nodes/start/components/var-list.tsx@@ -3,7 +3,8 @@ import type { FC } from 'react'import type { InputVar, MoreInfo } from '@/app/components/workflow/types'import { RiDraggable } from '@remixicon/react'import { produce } from 'immer'-import React, { useCallback, useMemo } from 'react'+import * as React from 'react'+import { useCallback, useMemo } from 'react'import { useTranslation } from 'react-i18next'import { ReactSortable } from 'react-sortablejs'import Toast from '@/app/components/base/toast'diff --git a/web/app/components/workflow/nodes/start/node.tsx b/web/app/components/workflow/nodes/start/node.tsxindex e8642ff6164..cc772dfc6a8 100644--- a/web/app/components/workflow/nodes/start/node.tsx+++ b/web/app/components/workflow/nodes/start/node.tsx@@ -1,7 +1,7 @@import type { FC } from 'react'import type { StartNodeType } from './types'import type { NodeProps } from '@/app/components/workflow/types'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import { Variable02 } from '@/app/components/base/icons/src/vender/solid/development'import InputVarTypeIcon from '../_base/components/input-var-type-icon'diff --git a/web/app/components/workflow/nodes/start/panel.tsx b/web/app/components/workflow/nodes/start/panel.tsxindex 5871ab18529..b29ece7266a 100644--- a/web/app/components/workflow/nodes/start/panel.tsx+++ b/web/app/components/workflow/nodes/start/panel.tsx@@ -1,7 +1,7 @@import type { FC } from 'react'import type { StartNodeType } from './types'import type { InputVar, NodePanelProps } from '@/app/components/workflow/types'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import ConfigVarModal from '@/app/components/app/configuration/config-var/config-modal'import AddButton from '@/app/components/base/button/add-button'diff --git a/web/app/components/workflow/nodes/template-transform/node.tsx b/web/app/components/workflow/nodes/template-transform/node.tsxindex 3a4c5c33197..4485d66258d 100644--- a/web/app/components/workflow/nodes/template-transform/node.tsx+++ b/web/app/components/workflow/nodes/template-transform/node.tsx@@ -1,7 +1,7 @@import type { FC } from 'react'import type { TemplateTransformNodeType } from './types'import type { NodeProps } from '@/app/components/workflow/types'-import React from 'react'+import * as React from 'react'const Node: FC<NodeProps<TemplateTransformNodeType>> = () => {return (diff --git a/web/app/components/workflow/nodes/template-transform/panel.tsx b/web/app/components/workflow/nodes/template-transform/panel.tsxindex c8fc293329d..7e2c39247c9 100644--- a/web/app/components/workflow/nodes/template-transform/panel.tsx+++ b/web/app/components/workflow/nodes/template-transform/panel.tsx@@ -4,7 +4,7 @@ import type { NodePanelProps } from '@/app/components/workflow/types'import {RiQuestionLine,} from '@remixicon/react'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import AddButton from '@/app/components/base/button/add-button'import CodeEditor from '@/app/components/workflow/nodes/_base/components/editor/code-editor/editor-support-vars'diff --git a/web/app/components/workflow/nodes/tool/components/copy-id.tsx b/web/app/components/workflow/nodes/tool/components/copy-id.tsxindex 39ffd7edd1b..8e53970749c 100644--- a/web/app/components/workflow/nodes/tool/components/copy-id.tsx+++ b/web/app/components/workflow/nodes/tool/components/copy-id.tsx@@ -2,7 +2,8 @@import { RiFileCopyLine } from '@remixicon/react'import copy from 'copy-to-clipboard'import { debounce } from 'lodash-es'-import React, { useState } from 'react'+import * as React from 'react'+import { useState } from 'react'import { useTranslation } from 'react-i18next'import Tooltip from '@/app/components/base/tooltip'diff --git a/web/app/components/workflow/nodes/tool/components/input-var-list.tsx b/web/app/components/workflow/nodes/tool/components/input-var-list.tsxindex 4f5d5f24bca..8b1bd46eebd 100644--- a/web/app/components/workflow/nodes/tool/components/input-var-list.tsx+++ b/web/app/components/workflow/nodes/tool/components/input-var-list.tsx@@ -6,7 +6,8 @@ import type { Tool } from '@/app/components/tools/types'import type { ToolWithProvider, ValueSelector, Var } from '@/app/components/workflow/types'import { produce } from 'immer'import { noop } from 'lodash-es'-import React, { useCallback, useState } from 'react'+import * as React from 'react'+import { useCallback, useState } from 'react'import { useTranslation } from 'react-i18next'import { FormTypeEnum } from '@/app/components/header/account-setting/model-provider-page/declarations'import { useLanguage } from '@/app/components/header/account-setting/model-provider-page/hooks'diff --git a/web/app/components/workflow/nodes/tool/node.tsx b/web/app/components/workflow/nodes/tool/node.tsxindex e2bcd26bd27..0cf4f0ff58b 100644--- a/web/app/components/workflow/nodes/tool/node.tsx+++ b/web/app/components/workflow/nodes/tool/node.tsx@@ -1,7 +1,8 @@import type { FC } from 'react'import type { ToolNodeType } from './types'import type { NodeProps } from '@/app/components/workflow/types'-import React, { useEffect } from 'react'+import * as React from 'react'+import { useEffect } from 'react'import { FormTypeEnum } from '@/app/components/header/account-setting/model-provider-page/declarations'import { useNodeDataUpdate } from '@/app/components/workflow/hooks/use-node-data-update'import { useNodePluginInstallation } from '@/app/components/workflow/hooks/use-node-plugin-installation'diff --git a/web/app/components/workflow/nodes/tool/panel.tsx b/web/app/components/workflow/nodes/tool/panel.tsxindex 3e1b778a7a3..559d42fd9fd 100644--- a/web/app/components/workflow/nodes/tool/panel.tsx+++ b/web/app/components/workflow/nodes/tool/panel.tsx@@ -1,7 +1,7 @@import type { FC } from 'react'import type { ToolNodeType } from './types'import type { NodePanelProps } from '@/app/components/workflow/types'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import Loading from '@/app/components/base/loading'import Field from '@/app/components/workflow/nodes/_base/components/field'diff --git a/web/app/components/workflow/nodes/trigger-plugin/node.tsx b/web/app/components/workflow/nodes/trigger-plugin/node.tsxindex da4dc83d34a..94f7d0a3147 100644--- a/web/app/components/workflow/nodes/trigger-plugin/node.tsx+++ b/web/app/components/workflow/nodes/trigger-plugin/node.tsx@@ -1,7 +1,8 @@import type { FC } from 'react'import type { PluginTriggerNodeType } from './types'import type { NodeProps } from '@/app/components/workflow/types'-import React, { useEffect, useMemo } from 'react'+import * as React from 'react'+import { useEffect, useMemo } from 'react'import { useTranslation } from 'react-i18next'import NodeStatus, { NodeStatusEnum } from '@/app/components/base/node-status'import { useNodeDataUpdate } from '@/app/components/workflow/hooks/use-node-data-update'diff --git a/web/app/components/workflow/nodes/trigger-plugin/panel.tsx b/web/app/components/workflow/nodes/trigger-plugin/panel.tsxindex ffa3a5503c3..a74639faf56 100644--- a/web/app/components/workflow/nodes/trigger-plugin/panel.tsx+++ b/web/app/components/workflow/nodes/trigger-plugin/panel.tsx@@ -1,7 +1,7 @@import type { FC } from 'react'import type { PluginTriggerNodeType } from './types'import type { NodePanelProps } from '@/app/components/workflow/types'-import React from 'react'+import * as React from 'react'import OutputVars, { VarItem } from '@/app/components/workflow/nodes/_base/components/output-vars'import Split from '@/app/components/workflow/nodes/_base/components/split'import StructureOutputItem from '@/app/components/workflow/nodes/_base/components/variable/object-child-tree-panel/show'diff --git a/web/app/components/workflow/nodes/trigger-schedule/components/frequency-selector.tsx b/web/app/components/workflow/nodes/trigger-schedule/components/frequency-selector.tsxindex b4f62de436d..c257949ca20 100644--- a/web/app/components/workflow/nodes/trigger-schedule/components/frequency-selector.tsx+++ b/web/app/components/workflow/nodes/trigger-schedule/components/frequency-selector.tsx@@ -1,5 +1,6 @@import type { ScheduleFrequency } from '../types'-import React, { useMemo } from 'react'+import * as React from 'react'+import { useMemo } from 'react'import { useTranslation } from 'react-i18next'import { SimpleSelect } from '@/app/components/base/select'diff --git a/web/app/components/workflow/nodes/trigger-schedule/components/mode-switcher.tsx b/web/app/components/workflow/nodes/trigger-schedule/components/mode-switcher.tsxindex 724fedc7b26..7c1f4e8f9d3 100644--- a/web/app/components/workflow/nodes/trigger-schedule/components/mode-switcher.tsx+++ b/web/app/components/workflow/nodes/trigger-schedule/components/mode-switcher.tsx@@ -1,6 +1,6 @@import type { ScheduleMode } from '../types'import { RiCalendarLine, RiCodeLine } from '@remixicon/react'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import { SegmentedControl } from '@/app/components/base/segmented-control'diff --git a/web/app/components/workflow/nodes/trigger-schedule/components/mode-toggle.tsx b/web/app/components/workflow/nodes/trigger-schedule/components/mode-toggle.tsxindex 35ffaff9393..583c92ccaf0 100644--- a/web/app/components/workflow/nodes/trigger-schedule/components/mode-toggle.tsx+++ b/web/app/components/workflow/nodes/trigger-schedule/components/mode-toggle.tsx@@ -1,5 +1,5 @@import type { ScheduleMode } from '../types'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import { Asterisk, CalendarCheckLine } from '@/app/components/base/icons/src/vender/workflow'diff --git a/web/app/components/workflow/nodes/trigger-schedule/components/monthly-days-selector.tsx b/web/app/components/workflow/nodes/trigger-schedule/components/monthly-days-selector.tsxindex e5a50522e1b..16399bea271 100644--- a/web/app/components/workflow/nodes/trigger-schedule/components/monthly-days-selector.tsx+++ b/web/app/components/workflow/nodes/trigger-schedule/components/monthly-days-selector.tsx@@ -1,5 +1,5 @@import { RiQuestionLine } from '@remixicon/react'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import Tooltip from '@/app/components/base/tooltip'diff --git a/web/app/components/workflow/nodes/trigger-schedule/components/next-execution-times.tsx b/web/app/components/workflow/nodes/trigger-schedule/components/next-execution-times.tsxindex c84bca483c2..fe246f1c67f 100644--- a/web/app/components/workflow/nodes/trigger-schedule/components/next-execution-times.tsx+++ b/web/app/components/workflow/nodes/trigger-schedule/components/next-execution-times.tsx@@ -1,5 +1,5 @@import type { ScheduleTriggerNodeType } from '../types'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import { getFormattedExecutionTimes } from '../utils/execution-time-calculator'diff --git a/web/app/components/workflow/nodes/trigger-schedule/components/on-minute-selector.tsx b/web/app/components/workflow/nodes/trigger-schedule/components/on-minute-selector.tsxindex 992a111d192..f9eef3691d9 100644--- a/web/app/components/workflow/nodes/trigger-schedule/components/on-minute-selector.tsx+++ b/web/app/components/workflow/nodes/trigger-schedule/components/on-minute-selector.tsx@@ -1,4 +1,4 @@-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import Slider from '@/app/components/base/slider'diff --git a/web/app/components/workflow/nodes/trigger-schedule/components/weekday-selector.tsx b/web/app/components/workflow/nodes/trigger-schedule/components/weekday-selector.tsxindex 348fd534541..9255a6b4850 100644--- a/web/app/components/workflow/nodes/trigger-schedule/components/weekday-selector.tsx+++ b/web/app/components/workflow/nodes/trigger-schedule/components/weekday-selector.tsx@@ -1,4 +1,4 @@-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'type WeekdaySelectorProps = {diff --git a/web/app/components/workflow/nodes/trigger-schedule/node.tsx b/web/app/components/workflow/nodes/trigger-schedule/node.tsxindex 45e9b2afdb5..6e9226b0be2 100644--- a/web/app/components/workflow/nodes/trigger-schedule/node.tsx+++ b/web/app/components/workflow/nodes/trigger-schedule/node.tsx@@ -1,7 +1,7 @@import type { FC } from 'react'import type { ScheduleTriggerNodeType } from './types'import type { NodeProps } from '@/app/components/workflow/types'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import { getNextExecutionTime } from './utils/execution-time-calculator'diff --git a/web/app/components/workflow/nodes/trigger-schedule/panel.tsx b/web/app/components/workflow/nodes/trigger-schedule/panel.tsxindex 8daedc50a97..b4ca1860b57 100644--- a/web/app/components/workflow/nodes/trigger-schedule/panel.tsx+++ b/web/app/components/workflow/nodes/trigger-schedule/panel.tsx@@ -1,7 +1,7 @@import type { FC } from 'react'import type { ScheduleTriggerNodeType } from './types'import type { NodePanelProps } from '@/app/components/workflow/types'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import TimePicker from '@/app/components/base/date-and-time-picker/time-picker'import Input from '@/app/components/base/input'diff --git a/web/app/components/workflow/nodes/trigger-webhook/components/generic-table.tsx b/web/app/components/workflow/nodes/trigger-webhook/components/generic-table.tsxindex a6644d7312d..d85b622e107 100644--- a/web/app/components/workflow/nodes/trigger-webhook/components/generic-table.tsx+++ b/web/app/components/workflow/nodes/trigger-webhook/components/generic-table.tsx@@ -1,7 +1,8 @@'use client'import type { FC, ReactNode } from 'react'import { RiDeleteBinLine } from '@remixicon/react'-import React, { useCallback, useMemo } from 'react'+import * as React from 'react'+import { useCallback, useMemo } from 'react'import Checkbox from '@/app/components/base/checkbox'import Input from '@/app/components/base/input'import { SimpleSelect } from '@/app/components/base/select'diff --git a/web/app/components/workflow/nodes/trigger-webhook/components/header-table.tsx b/web/app/components/workflow/nodes/trigger-webhook/components/header-table.tsxindex da54cac16a8..b681eec9b1f 100644--- a/web/app/components/workflow/nodes/trigger-webhook/components/header-table.tsx+++ b/web/app/components/workflow/nodes/trigger-webhook/components/header-table.tsx@@ -2,7 +2,7 @@import type { FC } from 'react'import type { WebhookHeader } from '../types'import type { ColumnConfig, GenericTableRow } from './generic-table'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import GenericTable from './generic-table'diff --git a/web/app/components/workflow/nodes/trigger-webhook/components/paragraph-input.tsx b/web/app/components/workflow/nodes/trigger-webhook/components/paragraph-input.tsxindex b26238fdd1b..c49ce9cd5d3 100644--- a/web/app/components/workflow/nodes/trigger-webhook/components/paragraph-input.tsx+++ b/web/app/components/workflow/nodes/trigger-webhook/components/paragraph-input.tsx@@ -1,6 +1,7 @@'use client'import type { FC } from 'react'-import React, { useRef } from 'react'+import * as React from 'react'+import { useRef } from 'react'import { cn } from '@/utils/classnames'type ParagraphInputProps = {diff --git a/web/app/components/workflow/nodes/trigger-webhook/components/parameter-table.tsx b/web/app/components/workflow/nodes/trigger-webhook/components/parameter-table.tsxindex 1fa038ff734..d4dc05f741e 100644--- a/web/app/components/workflow/nodes/trigger-webhook/components/parameter-table.tsx+++ b/web/app/components/workflow/nodes/trigger-webhook/components/parameter-table.tsx@@ -2,7 +2,8 @@import type { FC } from 'react'import type { WebhookParameter } from '../types'import type { ColumnConfig, GenericTableRow } from './generic-table'-import React, { useMemo } from 'react'+import * as React from 'react'+import { useMemo } from 'react'import { useTranslation } from 'react-i18next'import { VarType } from '@/app/components/workflow/types'import { createParameterTypeOptions, normalizeParameterType } from '../utils/parameter-type-utils'diff --git a/web/app/components/workflow/nodes/trigger-webhook/node.tsx b/web/app/components/workflow/nodes/trigger-webhook/node.tsxindex 77f42b6db2e..2de1b30aee7 100644--- a/web/app/components/workflow/nodes/trigger-webhook/node.tsx+++ b/web/app/components/workflow/nodes/trigger-webhook/node.tsx@@ -1,7 +1,7 @@import type { FC } from 'react'import type { WebhookTriggerNodeType } from './types'import type { NodeProps } from '@/app/components/workflow/types'-import React from 'react'+import * as React from 'react'const Node: FC<NodeProps<WebhookTriggerNodeType>> = ({data,diff --git a/web/app/components/workflow/nodes/trigger-webhook/panel.tsx b/web/app/components/workflow/nodes/trigger-webhook/panel.tsxindex efc541bbb3b..e5773e1afd2 100644--- a/web/app/components/workflow/nodes/trigger-webhook/panel.tsx+++ b/web/app/components/workflow/nodes/trigger-webhook/panel.tsx@@ -3,7 +3,8 @@ import type { HttpMethod, WebhookTriggerNodeType } from './types'import type { NodePanelProps } from '@/app/components/workflow/types'import copy from 'copy-to-clipboard'-import React, { useEffect, useRef, useState } from 'react'+import * as React from 'react'+import { useEffect, useRef, useState } from 'react'import { useTranslation } from 'react-i18next'import { InputNumber } from '@/app/components/base/input-number'import InputWithCopy from '@/app/components/base/input-with-copy'diff --git a/web/app/components/workflow/nodes/trigger-webhook/utils/render-output-vars.tsx b/web/app/components/workflow/nodes/trigger-webhook/utils/render-output-vars.tsxindex 984ffc03ddc..d58561b6031 100644--- a/web/app/components/workflow/nodes/trigger-webhook/utils/render-output-vars.tsx+++ b/web/app/components/workflow/nodes/trigger-webhook/utils/render-output-vars.tsx@@ -1,6 +1,6 @@import type { FC } from 'react'import type { Variable } from '@/app/components/workflow/types'-import React from 'react'+import * as React from 'react'type OutputVariablesContentProps = {variables?: Variable[]diff --git a/web/app/components/workflow/nodes/variable-assigner/components/var-group-item.tsx b/web/app/components/workflow/nodes/variable-assigner/components/var-group-item.tsxindex 277c44744b2..8fb1cfba61a 100644--- a/web/app/components/workflow/nodes/variable-assigner/components/var-group-item.tsx+++ b/web/app/components/workflow/nodes/variable-assigner/components/var-group-item.tsx@@ -7,7 +7,8 @@ import {} from '@remixicon/react'import { useBoolean } from 'ahooks'import { produce } from 'immer'-import React, { useCallback } from 'react'+import * as React from 'react'+import { useCallback } from 'react'import { useTranslation } from 'react-i18next'import { Folder } from '@/app/components/base/icons/src/vender/line/files'import Toast from '@/app/components/base/toast'diff --git a/web/app/components/workflow/nodes/variable-assigner/components/var-list/index.tsx b/web/app/components/workflow/nodes/variable-assigner/components/var-list/index.tsxindex a767e704fe3..19ead7ead15 100644--- a/web/app/components/workflow/nodes/variable-assigner/components/var-list/index.tsx+++ b/web/app/components/workflow/nodes/variable-assigner/components/var-list/index.tsx@@ -3,7 +3,8 @@ import type { FC } from 'react'import type { ValueSelector, Var } from '@/app/components/workflow/types'import { produce } from 'immer'import { noop } from 'lodash-es'-import React, { useCallback } from 'react'+import * as React from 'react'+import { useCallback } from 'react'import { useTranslation } from 'react-i18next'import VarReferencePicker from '@/app/components/workflow/nodes/_base/components/variable/var-reference-picker'import { VarType as VarKindType } from '@/app/components/workflow/nodes/tool/types'diff --git a/web/app/components/workflow/nodes/variable-assigner/panel.tsx b/web/app/components/workflow/nodes/variable-assigner/panel.tsxindex 0a6c1c3c845..c7edffc933c 100644--- a/web/app/components/workflow/nodes/variable-assigner/panel.tsx+++ b/web/app/components/workflow/nodes/variable-assigner/panel.tsx@@ -1,7 +1,7 @@import type { FC } from 'react'import type { VariableAssignerNodeType } from './types'import type { NodePanelProps } from '@/app/components/workflow/types'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import Switch from '@/app/components/base/switch'import AddButton from '@/app/components/workflow/nodes/_base/components/add-button'diff --git a/web/app/components/workflow/panel/chat-variable-panel/components/array-bool-list.tsx b/web/app/components/workflow/panel/chat-variable-panel/components/array-bool-list.tsxindex 3d224378302..e1ec55de120 100644--- a/web/app/components/workflow/panel/chat-variable-panel/components/array-bool-list.tsx+++ b/web/app/components/workflow/panel/chat-variable-panel/components/array-bool-list.tsx@@ -2,7 +2,8 @@import type { FC } from 'react'import { RiAddLine } from '@remixicon/react'import { produce } from 'immer'-import React, { useCallback } from 'react'+import * as React from 'react'+import { useCallback } from 'react'import { useTranslation } from 'react-i18next'import Button from '@/app/components/base/button'import RemoveButton from '@/app/components/workflow/nodes/_base/components/remove-button'diff --git a/web/app/components/workflow/panel/chat-variable-panel/components/array-value-list.tsx b/web/app/components/workflow/panel/chat-variable-panel/components/array-value-list.tsxindex e1025eda6ad..42a1d3f2477 100644--- a/web/app/components/workflow/panel/chat-variable-panel/components/array-value-list.tsx+++ b/web/app/components/workflow/panel/chat-variable-panel/components/array-value-list.tsx@@ -2,7 +2,8 @@import type { FC } from 'react'import { RiAddLine } from '@remixicon/react'import { produce } from 'immer'-import React, { useCallback } from 'react'+import * as React from 'react'+import { useCallback } from 'react'import { useTranslation } from 'react-i18next'import Button from '@/app/components/base/button'import Input from '@/app/components/base/input'diff --git a/web/app/components/workflow/panel/chat-variable-panel/components/bool-value.tsx b/web/app/components/workflow/panel/chat-variable-panel/components/bool-value.tsxindex 89b309db582..859a8bc7287 100644--- a/web/app/components/workflow/panel/chat-variable-panel/components/bool-value.tsx+++ b/web/app/components/workflow/panel/chat-variable-panel/components/bool-value.tsx@@ -1,6 +1,7 @@'use client'import type { FC } from 'react'-import React, { useCallback } from 'react'+import * as React from 'react'+import { useCallback } from 'react'import OptionCard from '../../../nodes/_base/components/option-card'type Props = {diff --git a/web/app/components/workflow/panel/chat-variable-panel/components/object-value-item.tsx b/web/app/components/workflow/panel/chat-variable-panel/components/object-value-item.tsxindex 1132434122b..33235e2423f 100644--- a/web/app/components/workflow/panel/chat-variable-panel/components/object-value-item.tsx+++ b/web/app/components/workflow/panel/chat-variable-panel/components/object-value-item.tsx@@ -1,7 +1,8 @@'use client'import type { FC } from 'react'import { produce } from 'immer'-import React, { useCallback, useState } from 'react'+import * as React from 'react'+import { useCallback, useState } from 'react'import { useTranslation } from 'react-i18next'import { useContext } from 'use-context-selector'import { ToastContext } from '@/app/components/base/toast'diff --git a/web/app/components/workflow/panel/chat-variable-panel/components/object-value-list.tsx b/web/app/components/workflow/panel/chat-variable-panel/components/object-value-list.tsxindex 0e39bfcfccf..0c2f8fc4f1b 100644--- a/web/app/components/workflow/panel/chat-variable-panel/components/object-value-list.tsx+++ b/web/app/components/workflow/panel/chat-variable-panel/components/object-value-list.tsx@@ -1,6 +1,6 @@'use client'import type { FC } from 'react'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import ObjectValueItem from '@/app/components/workflow/panel/chat-variable-panel/components/object-value-item'diff --git a/web/app/components/workflow/panel/chat-variable-panel/components/variable-modal-trigger.tsx b/web/app/components/workflow/panel/chat-variable-panel/components/variable-modal-trigger.tsxindex 1fe4e5fe5a6..14cd1b3cf1e 100644--- a/web/app/components/workflow/panel/chat-variable-panel/components/variable-modal-trigger.tsx+++ b/web/app/components/workflow/panel/chat-variable-panel/components/variable-modal-trigger.tsx@@ -1,7 +1,7 @@'use client'import type { ConversationVariable } from '@/app/components/workflow/types'import { RiAddLine } from '@remixicon/react'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import Button from '@/app/components/base/button'import {diff --git a/web/app/components/workflow/panel/chat-variable-panel/components/variable-modal.tsx b/web/app/components/workflow/panel/chat-variable-panel/components/variable-modal.tsxindex e30da0fff39..33e2e073765 100644--- a/web/app/components/workflow/panel/chat-variable-panel/components/variable-modal.tsx+++ b/web/app/components/workflow/panel/chat-variable-panel/components/variable-modal.tsx@@ -1,6 +1,7 @@import type { ConversationVariable } from '@/app/components/workflow/types'import { RiCloseLine, RiDraftLine, RiInputField } from '@remixicon/react'-import React, { useCallback, useEffect, useMemo } from 'react'+import * as React from 'react'+import { useCallback, useEffect, useMemo } from 'react'import { useTranslation } from 'react-i18next'import { useContext } from 'use-context-selector'import { v4 as uuid4 } from 'uuid'diff --git a/web/app/components/workflow/panel/chat-variable-panel/components/variable-type-select.tsx b/web/app/components/workflow/panel/chat-variable-panel/components/variable-type-select.tsxindex 19223749414..69ef1366b9d 100644--- a/web/app/components/workflow/panel/chat-variable-panel/components/variable-type-select.tsx+++ b/web/app/components/workflow/panel/chat-variable-panel/components/variable-type-select.tsx@@ -1,6 +1,7 @@'use client'import { RiArrowDownSLine, RiCheckLine } from '@remixicon/react'-import React, { useState } from 'react'+import * as React from 'react'+import { useState } from 'react'import {PortalToFollowElem,PortalToFollowElemContent,diff --git a/web/app/components/workflow/panel/debug-and-preview/conversation-variable-modal.tsx b/web/app/components/workflow/panel/debug-and-preview/conversation-variable-modal.tsxindex 117247901ef..6e130180d08 100644--- a/web/app/components/workflow/panel/debug-and-preview/conversation-variable-modal.tsx+++ b/web/app/components/workflow/panel/debug-and-preview/conversation-variable-modal.tsx@@ -6,7 +6,8 @@ import { RiCloseLine } from '@remixicon/react'import { useMount } from 'ahooks'import copy from 'copy-to-clipboard'import { capitalize, noop } from 'lodash-es'-import React, { useCallback } from 'react'+import * as React from 'react'+import { useCallback } from 'react'import { useTranslation } from 'react-i18next'import {Copy,diff --git a/web/app/components/workflow/panel/env-panel/variable-modal.tsx b/web/app/components/workflow/panel/env-panel/variable-modal.tsxindex 6cf193fe96c..e253d6c27c9 100644--- a/web/app/components/workflow/panel/env-panel/variable-modal.tsx+++ b/web/app/components/workflow/panel/env-panel/variable-modal.tsx@@ -1,6 +1,7 @@import type { EnvironmentVariable } from '@/app/components/workflow/types'import { RiCloseLine } from '@remixicon/react'-import React, { useEffect } from 'react'+import * as React from 'react'+import { useEffect } from 'react'import { useTranslation } from 'react-i18next'import { useContext } from 'use-context-selector'import { v4 as uuid4 } from 'uuid'diff --git a/web/app/components/workflow/panel/env-panel/variable-trigger.tsx b/web/app/components/workflow/panel/env-panel/variable-trigger.tsxindex 30551562a79..448d6f1aa99 100644--- a/web/app/components/workflow/panel/env-panel/variable-trigger.tsx+++ b/web/app/components/workflow/panel/env-panel/variable-trigger.tsx@@ -1,7 +1,7 @@'use client'import type { EnvironmentVariable } from '@/app/components/workflow/types'import { RiAddLine } from '@remixicon/react'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import Button from '@/app/components/base/button'import {diff --git a/web/app/components/workflow/panel/version-history-panel/context-menu/index.tsx b/web/app/components/workflow/panel/version-history-panel/context-menu/index.tsxindex 47dc68687dd..225f4b08f82 100644--- a/web/app/components/workflow/panel/version-history-panel/context-menu/index.tsx+++ b/web/app/components/workflow/panel/version-history-panel/context-menu/index.tsx@@ -1,6 +1,7 @@import type { FC } from 'react'import { RiMoreFill } from '@remixicon/react'-import React, { useCallback } from 'react'+import * as React from 'react'+import { useCallback } from 'react'import Button from '@/app/components/base/button'import Divider from '@/app/components/base/divider'import {diff --git a/web/app/components/workflow/panel/version-history-panel/context-menu/menu-item.tsx b/web/app/components/workflow/panel/version-history-panel/context-menu/menu-item.tsxindex a3070561481..938b8089cad 100644--- a/web/app/components/workflow/panel/version-history-panel/context-menu/menu-item.tsx+++ b/web/app/components/workflow/panel/version-history-panel/context-menu/menu-item.tsx@@ -1,6 +1,6 @@import type { FC } from 'react'import type { VersionHistoryContextMenuOptions } from '../../../types'-import React from 'react'+import * as React from 'react'import { cn } from '@/utils/classnames'type MenuItemProps = {diff --git a/web/app/components/workflow/panel/version-history-panel/delete-confirm-modal.tsx b/web/app/components/workflow/panel/version-history-panel/delete-confirm-modal.tsxindex 3ad7d0dc8ac..a8795936989 100644--- a/web/app/components/workflow/panel/version-history-panel/delete-confirm-modal.tsx+++ b/web/app/components/workflow/panel/version-history-panel/delete-confirm-modal.tsx@@ -1,6 +1,6 @@import type { FC } from 'react'import type { VersionHistory } from '@/types/workflow'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import Button from '@/app/components/base/button'import Modal from '@/app/components/base/modal'diff --git a/web/app/components/workflow/panel/version-history-panel/empty.tsx b/web/app/components/workflow/panel/version-history-panel/empty.tsxindex c020c076ade..bc81fc75035 100644--- a/web/app/components/workflow/panel/version-history-panel/empty.tsx+++ b/web/app/components/workflow/panel/version-history-panel/empty.tsx@@ -1,6 +1,6 @@import type { FC } from 'react'import { RiHistoryLine } from '@remixicon/react'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import Button from '@/app/components/base/button'diff --git a/web/app/components/workflow/panel/version-history-panel/filter/filter-item.tsx b/web/app/components/workflow/panel/version-history-panel/filter/filter-item.tsxindex c9a7c28112e..d7a37caa5ea 100644--- a/web/app/components/workflow/panel/version-history-panel/filter/filter-item.tsx+++ b/web/app/components/workflow/panel/version-history-panel/filter/filter-item.tsx@@ -1,7 +1,7 @@import type { FC } from 'react'import type { WorkflowVersionFilterOptions } from '../../../types'import { RiCheckLine } from '@remixicon/react'-import React from 'react'+import * as React from 'react'type FilterItemProps = {item: {diff --git a/web/app/components/workflow/panel/version-history-panel/filter/filter-switch.tsx b/web/app/components/workflow/panel/version-history-panel/filter/filter-switch.tsxindex 6db331338bb..d6d79f9a6a0 100644--- a/web/app/components/workflow/panel/version-history-panel/filter/filter-switch.tsx+++ b/web/app/components/workflow/panel/version-history-panel/filter/filter-switch.tsx@@ -1,5 +1,5 @@import type { FC } from 'react'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import Switch from '@/app/components/base/switch'diff --git a/web/app/components/workflow/panel/version-history-panel/filter/index.tsx b/web/app/components/workflow/panel/version-history-panel/filter/index.tsxindex 8def2219263..83156be7323 100644--- a/web/app/components/workflow/panel/version-history-panel/filter/index.tsx+++ b/web/app/components/workflow/panel/version-history-panel/filter/index.tsx@@ -1,6 +1,7 @@import type { FC } from 'react'import { RiFilter3Line } from '@remixicon/react'-import React, { useCallback, useState } from 'react'+import * as React from 'react'+import { useCallback, useState } from 'react'import Divider from '@/app/components/base/divider'import {PortalToFollowElem,diff --git a/web/app/components/workflow/panel/version-history-panel/index.tsx b/web/app/components/workflow/panel/version-history-panel/index.tsxindex 0bdb608d94b..06a27eb7c7a 100644--- a/web/app/components/workflow/panel/version-history-panel/index.tsx+++ b/web/app/components/workflow/panel/version-history-panel/index.tsx@@ -2,7 +2,8 @@import type { VersionHistory } from '@/types/workflow'import { RiArrowDownDoubleLine, RiCloseLine, RiLoader2Line } from '@remixicon/react'import copy from 'copy-to-clipboard'-import React, { useCallback, useState } from 'react'+import * as React from 'react'+import { useCallback, useState } from 'react'import { useTranslation } from 'react-i18next'import VersionInfoModal from '@/app/components/app/app-publisher/version-info-modal'import Divider from '@/app/components/base/divider'diff --git a/web/app/components/workflow/panel/version-history-panel/loading/item.tsx b/web/app/components/workflow/panel/version-history-panel/loading/item.tsxindex c17d725fb39..58d5cc3bd4e 100644--- a/web/app/components/workflow/panel/version-history-panel/loading/item.tsx+++ b/web/app/components/workflow/panel/version-history-panel/loading/item.tsx@@ -1,5 +1,5 @@import type { FC } from 'react'-import React from 'react'+import * as React from 'react'import { cn } from '@/utils/classnames'type ItemProps = {diff --git a/web/app/components/workflow/panel/version-history-panel/restore-confirm-modal.tsx b/web/app/components/workflow/panel/version-history-panel/restore-confirm-modal.tsxindex 09bc5d79b47..a8dfb8b21c1 100644--- a/web/app/components/workflow/panel/version-history-panel/restore-confirm-modal.tsx+++ b/web/app/components/workflow/panel/version-history-panel/restore-confirm-modal.tsx@@ -1,6 +1,6 @@import type { FC } from 'react'import type { VersionHistory } from '@/types/workflow'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import Button from '@/app/components/base/button'import Modal from '@/app/components/base/modal'diff --git a/web/app/components/workflow/panel/version-history-panel/version-history-item.tsx b/web/app/components/workflow/panel/version-history-panel/version-history-item.tsxindex 7739d10af2c..4818c371a73 100644--- a/web/app/components/workflow/panel/version-history-panel/version-history-item.tsx+++ b/web/app/components/workflow/panel/version-history-panel/version-history-item.tsx@@ -1,7 +1,8 @@import type { VersionHistoryContextMenuOptions } from '../../types'import type { VersionHistory } from '@/types/workflow'import dayjs from 'dayjs'-import React, { useEffect, useState } from 'react'+import * as React from 'react'+import { useEffect, useState } from 'react'import { useTranslation } from 'react-i18next'import { cn } from '@/utils/classnames'import { WorkflowVersion } from '../../types'diff --git a/web/app/components/workflow/run/index.tsx b/web/app/components/workflow/run/index.tsxindex 1bff24e2cc7..378daa7b190 100644--- a/web/app/components/workflow/run/index.tsx+++ b/web/app/components/workflow/run/index.tsx@@ -2,7 +2,8 @@import type { FC } from 'react'import type { WorkflowRunDetailResponse } from '@/models/log'import type { NodeTracing } from '@/types/workflow'-import React, { useCallback, useEffect, useMemo, useRef, useState } from 'react'+import * as React from 'react'+import { useCallback, useEffect, useMemo, useRef, useState } from 'react'import { useTranslation } from 'react-i18next'import { useContext } from 'use-context-selector'import Loading from '@/app/components/base/loading'diff --git a/web/app/components/workflow/run/iteration-log/iteration-result-panel.tsx b/web/app/components/workflow/run/iteration-log/iteration-result-panel.tsxindex 5933e897bdb..12812aeef7e 100644--- a/web/app/components/workflow/run/iteration-log/iteration-result-panel.tsx+++ b/web/app/components/workflow/run/iteration-log/iteration-result-panel.tsx@@ -7,7 +7,8 @@ import {RiErrorWarningLine,RiLoader2Line,} from '@remixicon/react'-import React, { useCallback, useState } from 'react'+import * as React from 'react'+import { useCallback, useState } from 'react'import { useTranslation } from 'react-i18next'import { Iteration } from '@/app/components/base/icons/src/vender/workflow'import TracingPanel from '@/app/components/workflow/run/tracing-panel'diff --git a/web/app/components/workflow/run/loop-log/loop-result-panel.tsx b/web/app/components/workflow/run/loop-log/loop-result-panel.tsxindex 758148d8c18..219888a56f5 100644--- a/web/app/components/workflow/run/loop-log/loop-result-panel.tsx+++ b/web/app/components/workflow/run/loop-log/loop-result-panel.tsx@@ -7,7 +7,8 @@ import {RiErrorWarningLine,RiLoader2Line,} from '@remixicon/react'-import React, { useCallback, useState } from 'react'+import * as React from 'react'+import { useCallback, useState } from 'react'import { useTranslation } from 'react-i18next'import { Loop } from '@/app/components/base/icons/src/vender/workflow'import CodeEditor from '@/app/components/workflow/nodes/_base/components/editor/code-editor'diff --git a/web/app/components/workflow/run/loop-result-panel.tsx b/web/app/components/workflow/run/loop-result-panel.tsxindex 61ba6db1152..8238be82f38 100644--- a/web/app/components/workflow/run/loop-result-panel.tsx+++ b/web/app/components/workflow/run/loop-result-panel.tsx@@ -5,7 +5,8 @@ import {RiArrowRightSLine,RiCloseLine,} from '@remixicon/react'-import React, { useCallback, useState } from 'react'+import * as React from 'react'+import { useCallback, useState } from 'react'import { useTranslation } from 'react-i18next'import { Loop } from '@/app/components/base/icons/src/vender/workflow'import { cn } from '@/utils/classnames'diff --git a/web/app/components/workflow/run/tracing-panel.tsx b/web/app/components/workflow/run/tracing-panel.tsxindex 0e1d6578ab8..8931c8f7fe5 100644--- a/web/app/components/workflow/run/tracing-panel.tsx+++ b/web/app/components/workflow/run/tracing-panel.tsx@@ -5,9 +5,8 @@ import {RiArrowDownSLine,RiMenu4Line,} from '@remixicon/react'-import-React,-{+import * as React from 'react'+import {useCallback,useState,} from 'react'diff --git a/web/app/components/workflow/variable-inspect/display-content.tsx b/web/app/components/workflow/variable-inspect/display-content.tsxindex 901c0fa6dca..ebeaa17c42f 100644--- a/web/app/components/workflow/variable-inspect/display-content.tsx+++ b/web/app/components/workflow/variable-inspect/display-content.tsx@@ -2,7 +2,8 @@ import type { VarType } from '../types'import type { ChunkInfo } from '@/app/components/rag-pipeline/components/chunk-card-list/types'import type { ParentMode } from '@/models/datasets'import { RiBracesLine, RiEyeLine } from '@remixicon/react'-import React, { useMemo, useState } from 'react'+import * as React from 'react'+import { useMemo, useState } from 'react'import { useTranslation } from 'react-i18next'import { Markdown } from '@/app/components/base/markdown'import { SegmentedControl } from '@/app/components/base/segmented-control'diff --git a/web/app/components/workflow/variable-inspect/large-data-alert.tsx b/web/app/components/workflow/variable-inspect/large-data-alert.tsxindex a2750c82e74..6ab3e65f41e 100644--- a/web/app/components/workflow/variable-inspect/large-data-alert.tsx+++ b/web/app/components/workflow/variable-inspect/large-data-alert.tsx@@ -1,7 +1,7 @@'use client'import type { FC } from 'react'import { RiInformation2Fill } from '@remixicon/react'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import { cn } from '@/utils/classnames'diff --git a/web/app/components/workflow/variable-inspect/value-content.tsx b/web/app/components/workflow/variable-inspect/value-content.tsxindex 6d6a04434a8..1d4f1cfd137 100644--- a/web/app/components/workflow/variable-inspect/value-content.tsx+++ b/web/app/components/workflow/variable-inspect/value-content.tsx@@ -1,6 +1,7 @@import type { VarInInspect } from '@/types/workflow'import { useDebounceFn } from 'ahooks'-import React, { useEffect, useMemo, useRef, useState } from 'react'+import * as React from 'react'+import { useEffect, useMemo, useRef, useState } from 'react'import { FileUploaderInAttachmentWrapper } from '@/app/components/base/file-uploader'import { getProcessedFiles, getProcessedFilesFromResponse } from '@/app/components/base/file-uploader/utils'import { FILE_EXTS } from '@/app/components/base/prompt-editor/constants'diff --git a/web/app/components/workflow/workflow-preview/components/nodes/if-else/node.tsx b/web/app/components/workflow/workflow-preview/components/nodes/if-else/node.tsxindex b0a9e6903fa..bac19c579fc 100644--- a/web/app/components/workflow/workflow-preview/components/nodes/if-else/node.tsx+++ b/web/app/components/workflow/workflow-preview/components/nodes/if-else/node.tsx@@ -1,7 +1,8 @@import type { FC } from 'react'import type { NodeProps } from 'reactflow'import type { Condition, IfElseNodeType } from '@/app/components/workflow/nodes/if-else/types'-import React, { useCallback } from 'react'+import * as React from 'react'+import { useCallback } from 'react'import { useTranslation } from 'react-i18next'import ConditionFilesListValue from '@/app/components/workflow/nodes/if-else/components/condition-files-list-value'import ConditionValue from '@/app/components/workflow/nodes/if-else/components/condition-value'diff --git a/web/app/components/workflow/workflow-preview/components/nodes/question-classifier/node.tsx b/web/app/components/workflow/workflow-preview/components/nodes/question-classifier/node.tsxindex c164d624e4d..2511483b365 100644--- a/web/app/components/workflow/workflow-preview/components/nodes/question-classifier/node.tsx+++ b/web/app/components/workflow/workflow-preview/components/nodes/question-classifier/node.tsx@@ -1,7 +1,7 @@import type { FC } from 'react'import type { NodeProps } from 'reactflow'import type { QuestionClassifierNodeType } from '@/app/components/workflow/nodes/question-classifier/types'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import InfoPanel from '@/app/components/workflow/nodes/_base/components/info-panel'import { NodeSourceHandle } from '../../node-handle'diff --git a/web/app/education-apply/expire-notice-modal.tsx b/web/app/education-apply/expire-notice-modal.tsxindex 51a3ba66b1c..6755de12414 100644--- a/web/app/education-apply/expire-notice-modal.tsx+++ b/web/app/education-apply/expire-notice-modal.tsx@@ -2,7 +2,7 @@import { RiExternalLinkLine } from '@remixicon/react'import Link from 'next/link'import { useRouter } from 'next/navigation'-import React from 'react'+import * as React from 'react'import { useTranslation } from 'react-i18next'import Button from '@/app/components/base/button'import Modal from '@/app/components/base/modal'diff --git a/web/app/education-apply/verify-state-modal.tsx b/web/app/education-apply/verify-state-modal.tsxindex e4a5cd9bbe6..5d4e89c92e0 100644--- a/web/app/education-apply/verify-state-modal.tsx+++ b/web/app/education-apply/verify-state-modal.tsx@@ -1,7 +1,8 @@import {RiExternalLinkLine,} from '@remixicon/react'-import React, { useEffect, useRef, useState } from 'react'+import * as React from 'react'+import { useEffect, useRef, useState } from 'react'import { createPortal } from 'react-dom'import { useTranslation } from 'react-i18next'import Button from '@/app/components/base/button'diff --git a/web/app/forgot-password/ForgotPasswordForm.tsx b/web/app/forgot-password/ForgotPasswordForm.tsxindex 43aa1006d61..2b50c1c452a 100644--- a/web/app/forgot-password/ForgotPasswordForm.tsx+++ b/web/app/forgot-password/ForgotPasswordForm.tsx@@ -4,7 +4,8 @@ import { zodResolver } from '@hookform/resolvers/zod'import { useRouter } from 'next/navigation'-import React, { useEffect, useState } from 'react'+import * as React from 'react'+import { useEffect, useState } from 'react'import { useForm } from 'react-hook-form'import { useTranslation } from 'react-i18next'import { z } from 'zod'diff --git a/web/app/forgot-password/page.tsx b/web/app/forgot-password/page.tsxindex 4c37e096ca2..338f4eaf13c 100644--- a/web/app/forgot-password/page.tsx+++ b/web/app/forgot-password/page.tsx@@ -1,6 +1,6 @@'use client'import { useSearchParams } from 'next/navigation'-import React from 'react'+import * as React from 'react'import ChangePasswordForm from '@/app/forgot-password/ChangePasswordForm'import { useGlobalPublicStore } from '@/context/global-public-context'import useDocumentTitle from '@/hooks/use-document-title'diff --git a/web/app/init/page.tsx b/web/app/init/page.tsxindex c61457f984b..7c1d849bdd8 100644--- a/web/app/init/page.tsx+++ b/web/app/init/page.tsx@@ -1,4 +1,4 @@-import React from 'react'+import * as React from 'react'import { cn } from '@/utils/classnames'import InitPasswordPopup from './InitPasswordPopup'diff --git a/web/app/install/installForm.tsx b/web/app/install/installForm.tsxindex c3d9c1dfa60..60de8e0501b 100644--- a/web/app/install/installForm.tsx+++ b/web/app/install/installForm.tsx@@ -7,7 +7,8 @@ import { useDebounceFn } from 'ahooks'import Link from 'next/link'import { useRouter } from 'next/navigation'-import React, { useCallback, useEffect } from 'react'+import * as React from 'react'+import { useCallback, useEffect } from 'react'import { useForm } from 'react-hook-form'import { useTranslation } from 'react-i18next'import { z } from 'zod'diff --git a/web/app/install/page.tsx b/web/app/install/page.tsxindex b9a770405f9..db30d5bc5a5 100644--- a/web/app/install/page.tsx+++ b/web/app/install/page.tsx@@ -1,5 +1,5 @@'use client'-import React from 'react'+import * as React from 'react'import { useGlobalPublicStore } from '@/context/global-public-context'import { cn } from '@/utils/classnames'import Header from '../signin/_header'diff --git a/web/app/signin/_header.tsx b/web/app/signin/_header.tsxindex 5ef24cd03e4..01135c2bf6f 100644--- a/web/app/signin/_header.tsx+++ b/web/app/signin/_header.tsx@@ -1,7 +1,7 @@'use client'import type { Locale } from '@/i18n-config'import dynamic from 'next/dynamic'-import React from 'react'+import * as React from 'react'import { useContext } from 'use-context-selector'import Divider from '@/app/components/base/divider'import LocaleSigninSelect from '@/app/components/base/select/locale-signin'diff --git a/web/app/signin/normal-form.tsx b/web/app/signin/normal-form.tsxindex 6bc37e6dd34..a4e6e4607e2 100644--- a/web/app/signin/normal-form.tsx+++ b/web/app/signin/normal-form.tsx@@ -1,7 +1,8 @@import { RiContractLine, RiDoorLockLine, RiErrorWarningFill } from '@remixicon/react'import Link from 'next/link'import { useRouter, useSearchParams } from 'next/navigation'-import React, { useCallback, useEffect, useState } from 'react'+import * as React from 'react'+import { useCallback, useEffect, useState } from 'react'import { useTranslation } from 'react-i18next'import Toast from '@/app/components/base/toast'import { IS_CE_EDITION } from '@/config'diff --git a/web/app/signin/one-more-step.tsx b/web/app/signin/one-more-step.tsxindex 80013e622f3..76f707493bd 100644--- a/web/app/signin/one-more-step.tsx+++ b/web/app/signin/one-more-step.tsx@@ -2,7 +2,8 @@import type { Reducer } from 'react'import Link from 'next/link'import { useRouter, useSearchParams } from 'next/navigation'-import React, { useReducer } from 'react'+import * as React from 'react'+import { useReducer } from 'react'import { useTranslation } from 'react-i18next'import Button from '@/app/components/base/button'import { SimpleSelect } from '@/app/components/base/select'diff --git a/web/app/signin/split.tsx b/web/app/signin/split.tsxindex b6e848357c1..370f108421c 100644--- a/web/app/signin/split.tsx+++ b/web/app/signin/split.tsx@@ -1,6 +1,6 @@'use client'import type { FC } from 'react'-import React from 'react'+import * as React from 'react'import { cn } from '@/utils/classnames'type Props = {diff --git a/web/context/external-api-panel-context.tsx b/web/context/external-api-panel-context.tsxindex 05ae5c45c1b..e50420c1694 100644--- a/web/context/external-api-panel-context.tsx+++ b/web/context/external-api-panel-context.tsx@@ -1,6 +1,7 @@'use client'-import React, { createContext, useContext, useState } from 'react'+import * as React from 'react'+import { createContext, useContext, useState } from 'react'type ExternalApiPanelContextType = {showExternalApiPanel: booleandiff --git a/web/context/modal-context.test.tsx b/web/context/modal-context.test.tsxindex 07a82939a0c..4f41c19df69 100644--- a/web/context/modal-context.test.tsx+++ b/web/context/modal-context.test.tsx@@ -1,5 +1,5 @@import { act, render, screen, waitFor } from '@testing-library/react'-import React from 'react'+import * as React from 'react'import { defaultPlan } from '@/app/components/billing/config'import { Plan } from '@/app/components/billing/type'import { ModalContextProvider } from '@/context/modal-context'diff --git a/web/context/provider-context-mock.tsx b/web/context/provider-context-mock.tsxindex b42847a9ec5..174affca0d1 100644--- a/web/context/provider-context-mock.tsx+++ b/web/context/provider-context-mock.tsx@@ -1,6 +1,6 @@'use client'import type { FC } from 'react'-import React from 'react'+import * as React from 'react'import { useProviderContext } from '@/context/provider-context'const ProviderContextMock: FC = () => {diff --git a/web/eslint.config.mjs b/web/eslint.config.mjsindex da425efb624..9cd4d7831e7 100644--- a/web/eslint.config.mjs+++ b/web/eslint.config.mjs@@ -11,6 +11,7 @@ export default antfu('react/no-context-provider': 'off','react/no-forward-ref': 'off','react/no-use-context': 'off',+ 'react/prefer-namespace-import': 'error',},},nextjs: true,@@ -54,7 +55,6 @@ export default antfu('test/no-identical-title': 'warn','test/prefer-hooks-in-order': 'warn','ts/no-empty-object-type': 'warn',- 'ts/no-require-imports': 'warn','unicorn/prefer-number-properties': 'warn','unused-imports/no-unused-vars': 'warn',},diff --git a/web/hooks/use-breakpoints.ts b/web/hooks/use-breakpoints.tsindex 99c2b75d67b..e0bd45c01c2 100644--- a/web/hooks/use-breakpoints.ts+++ b/web/hooks/use-breakpoints.ts@@ -1,5 +1,5 @@'use client'-import React from 'react'+import * as React from 'react'export enum MediaType {mobile = 'mobile',diff --git a/web/service/demo/index.tsx b/web/service/demo/index.tsxindex d538d6fda29..afce18d4683 100644--- a/web/service/demo/index.tsx+++ b/web/service/demo/index.tsx@@ -1,7 +1,7 @@'use client'import type { FC } from 'react'import { useMutation, useQuery, useQueryClient } from '@tanstack/react-query'-import React from 'react'+import * as React from 'react'import Loading from '@/app/components/base/loading'import { AppModeEnum } from '@/types/app'import { createApp, updateAppApiStatus, updateAppModelConfig, updateAppRateLimit, updateAppSiteAccessToken, updateAppSiteConfig, updateAppSiteStatus } from '../apps'diff --git a/web/utils/context.spec.ts b/web/utils/context.spec.tsindex b70a15639a7..40f39dda6a3 100644--- a/web/utils/context.spec.ts+++ b/web/utils/context.spec.ts@@ -9,7 +9,7 @@ import { renderHook } from '@testing-library/react'* - createCtx: Standard React context using useContext/createContext* - createSelectorCtx: Context with selector support using use-context-selector library*/-import React from 'react'+import * as React from 'react'import { createCtx, createSelectorCtx } from './context'describe('Context Utilities', () => {