From 42b6524954165d3c24e6feac362c6fdcc6cdec92 Mon Sep 17 00:00:00 2001 From: Joel Date: Wed, 18 Jun 2025 15:04:40 +0800 Subject: [PATCH 01/29] feat: type config --- .../components/plugins/plugin-page/index.tsx | 6 +++--- .../auto-update-setting/config.ts | 9 +++++++++ .../auto-update-setting/index.tsx | 19 +++++++++++++++++++ .../auto-update-setting/types.ts | 19 +++++++++++++++++++ .../modal.tsx | 3 ++- .../style.module.css | 0 6 files changed, 52 insertions(+), 4 deletions(-) create mode 100644 web/app/components/plugins/reference-setting-modal/auto-update-setting/config.ts create mode 100644 web/app/components/plugins/reference-setting-modal/auto-update-setting/index.tsx create mode 100644 web/app/components/plugins/reference-setting-modal/auto-update-setting/types.ts rename web/app/components/plugins/{permission-setting-modal => reference-setting-modal}/modal.tsx (96%) rename web/app/components/plugins/{permission-setting-modal => reference-setting-modal}/style.module.css (100%) diff --git a/web/app/components/plugins/plugin-page/index.tsx b/web/app/components/plugins/plugin-page/index.tsx index 7e17459b33..4c7de28f17 100644 --- a/web/app/components/plugins/plugin-page/index.tsx +++ b/web/app/components/plugins/plugin-page/index.tsx @@ -24,7 +24,7 @@ import Button from '@/app/components/base/button' import TabSlider from '@/app/components/base/tab-slider' import Tooltip from '@/app/components/base/tooltip' import cn from '@/utils/classnames' -import PermissionSetModal from '@/app/components/plugins/permission-setting-modal/modal' +import ReferenceSettingModal from '@/app/components/plugins/reference-setting-modal/modal' import InstallFromMarketplace from '../install-plugin/install-from-marketplace' import { useRouter, @@ -130,7 +130,7 @@ const PluginPage = ({ const [showPluginSettingModal, { setTrue: setShowPluginSettingModal, setFalse: setHidePluginSettingModal, - }] = useBoolean() + }] = useBoolean(true) const [currentFile, setCurrentFile] = useState(null) const containerRef = usePluginPageContext(v => v.containerRef) const options = usePluginPageContext(v => v.options) @@ -276,7 +276,7 @@ const PluginPage = ({ } {showPluginSettingModal && ( - = ({ + payload, +}) => { + console.log(payload) + return ( +
+
+ ) +} +export default React.memo(AutoUpdateSetting) diff --git a/web/app/components/plugins/reference-setting-modal/auto-update-setting/types.ts b/web/app/components/plugins/reference-setting-modal/auto-update-setting/types.ts new file mode 100644 index 0000000000..c48a67140a --- /dev/null +++ b/web/app/components/plugins/reference-setting-modal/auto-update-setting/types.ts @@ -0,0 +1,19 @@ +export enum AUTO_UPDATE_STRATEGY { + fixOnly = 'fix_only', + disabled = 'disabled', + latest = 'latest', +} + +export enum AUTO_UPDATE_MODE { + partial = 'partial', + exclude = 'exclude', + update_all = 'update_all', +} + +export type AutoUpdateConfig = { + strategy_setting: AUTO_UPDATE_STRATEGY + upgrade_time_of_day: number + upgrade_mode: AUTO_UPDATE_MODE + exclude_plugins: string[] + include_plugins: string[] +} diff --git a/web/app/components/plugins/permission-setting-modal/modal.tsx b/web/app/components/plugins/reference-setting-modal/modal.tsx similarity index 96% rename from web/app/components/plugins/permission-setting-modal/modal.tsx rename to web/app/components/plugins/reference-setting-modal/modal.tsx index 6fd4d8c2dc..1c45820e8e 100644 --- a/web/app/components/plugins/permission-setting-modal/modal.tsx +++ b/web/app/components/plugins/reference-setting-modal/modal.tsx @@ -7,10 +7,11 @@ import OptionCard from '@/app/components/workflow/nodes/_base/components/option- import Button from '@/app/components/base/button' import type { Permissions } from '@/app/components/plugins/types' import { PermissionType } from '@/app/components/plugins/types' +import type { AutoUpdateConfig } from './auto-update-setting/types' const i18nPrefix = 'plugin.privilege' type Props = { - payload: Permissions + payload: Permissions & { autoUpdate: AutoUpdateConfig } onHide: () => void onSave: (payload: Permissions) => void } diff --git a/web/app/components/plugins/permission-setting-modal/style.module.css b/web/app/components/plugins/reference-setting-modal/style.module.css similarity index 100% rename from web/app/components/plugins/permission-setting-modal/style.module.css rename to web/app/components/plugins/reference-setting-modal/style.module.css From baff25c16020c3ce5298ac41cda6d3621e6dd3e4 Mon Sep 17 00:00:00 2001 From: Joel Date: Thu, 19 Jun 2025 16:11:02 +0800 Subject: [PATCH 02/29] feat: auto update strategy picker --- .../auto-update-setting/index.tsx | 35 ++++++- .../auto-update-setting/strategy-picker.tsx | 98 +++++++++++++++++++ .../plugins/reference-setting-modal/label.tsx | 28 ++++++ .../plugins/reference-setting-modal/modal.tsx | 25 +++-- web/i18n/en-US/plugin.ts | 16 +++ 5 files changed, 191 insertions(+), 11 deletions(-) create mode 100644 web/app/components/plugins/reference-setting-modal/auto-update-setting/strategy-picker.tsx create mode 100644 web/app/components/plugins/reference-setting-modal/label.tsx 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.tsx index 7c7b524d7f..6e143b4523 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 @@ -1,18 +1,47 @@ 'use client' import type { FC } from 'react' -import React from 'react' +import React, { useCallback } from 'react' import type { AutoUpdateConfig } from './types' +import Label from '../label' +import StrategyPicker from './strategy-picker' type Props = { payload: AutoUpdateConfig + onChange: (payload: AutoUpdateConfig) => void } const AutoUpdateSetting: FC = ({ payload, + onChange, }) => { - console.log(payload) + const { strategy_setting } = payload + const handleChange = useCallback((key: keyof AutoUpdateConfig) => { + return (value: AutoUpdateConfig[keyof AutoUpdateConfig]) => { + onChange({ + ...payload, + [key]: value, + }) + } + }, [payload, onChange]) return ( -
+
+
+
Updates Settings
+
+
+ +
+
+
+
+
+
+
+
) } diff --git a/web/app/components/plugins/reference-setting-modal/auto-update-setting/strategy-picker.tsx b/web/app/components/plugins/reference-setting-modal/auto-update-setting/strategy-picker.tsx new file mode 100644 index 0000000000..c8227520f3 --- /dev/null +++ b/web/app/components/plugins/reference-setting-modal/auto-update-setting/strategy-picker.tsx @@ -0,0 +1,98 @@ +import { useState } from 'react' +import { useTranslation } from 'react-i18next' +import { + RiArrowDownSLine, + RiCheckLine, +} from '@remixicon/react' +import { AUTO_UPDATE_STRATEGY } from './types' +import { + PortalToFollowElem, + PortalToFollowElemContent, + PortalToFollowElemTrigger, +} from '@/app/components/base/portal-to-follow-elem' +import Button from '@/app/components/base/button' +const i18nPrefix = 'plugin.autoUpdate.strategy' + +type Props = { + value: AUTO_UPDATE_STRATEGY + onChange: (value: AUTO_UPDATE_STRATEGY) => void +} +const StrategyPicker = ({ + value, + onChange, +}: Props) => { + const { t } = useTranslation() + const [open, setOpen] = useState(false) + const options = [ + { + value: AUTO_UPDATE_STRATEGY.disabled, + label: t(`${i18nPrefix}.disabled.name`), + description: t(`${i18nPrefix}.disabled.description`), + }, + { + value: AUTO_UPDATE_STRATEGY.fixOnly, + label: t(`${i18nPrefix}.fixOnly.name`), + description: t(`${i18nPrefix}.fixOnly.description`), + }, + { + value: AUTO_UPDATE_STRATEGY.latest, + label: t(`${i18nPrefix}.latest.name`), + description: t(`${i18nPrefix}.latest.description`), + }, + ] + const selectedOption = options.find(option => option.value === value) + + return ( + + { + e.stopPropagation() + e.nativeEvent.stopImmediatePropagation() + setOpen(v => !v) + }}> + + + +
+ { + options.map(option => ( +
{ + e.stopPropagation() + e.nativeEvent.stopImmediatePropagation() + onChange(option.value) + setOpen(false) + }} + > +
+ { + value === option.value && ( + + ) + } +
+
+
{option.label}
+
{option.description}
+
+
+ )) + } +
+
+
+ ) +} + +export default StrategyPicker diff --git a/web/app/components/plugins/reference-setting-modal/label.tsx b/web/app/components/plugins/reference-setting-modal/label.tsx new file mode 100644 index 0000000000..6444bf801d --- /dev/null +++ b/web/app/components/plugins/reference-setting-modal/label.tsx @@ -0,0 +1,28 @@ +'use client' +import type { FC } from 'react' +import React from 'react' +import cn from '@/utils/classnames' + +type Props = { + label: string + description?: string +} + +const Label: FC = ({ + label, + description, +}) => { + return ( +
+
+ {label} +
+ {description && ( +
+ {description} +
+ )} +
+ ) +} +export default React.memo(Label) diff --git a/web/app/components/plugins/reference-setting-modal/modal.tsx b/web/app/components/plugins/reference-setting-modal/modal.tsx index 1c45820e8e..3f2b645292 100644 --- a/web/app/components/plugins/reference-setting-modal/modal.tsx +++ b/web/app/components/plugins/reference-setting-modal/modal.tsx @@ -8,12 +8,16 @@ import Button from '@/app/components/base/button' import type { Permissions } from '@/app/components/plugins/types' import { PermissionType } from '@/app/components/plugins/types' import type { AutoUpdateConfig } from './auto-update-setting/types' +import AutoUpdateSetting from './auto-update-setting' +import { defaultValue as autoUpdateDefaultValue } from './auto-update-setting/config' +import Label from './label' +type Payload = Permissions & { autoUpdate: AutoUpdateConfig } const i18nPrefix = 'plugin.privilege' type Props = { - payload: Permissions & { autoUpdate: AutoUpdateConfig } + payload: Payload onHide: () => void - onSave: (payload: Permissions) => void + onSave: (payload: Payload) => void } const PluginSettingModal: FC = ({ @@ -22,7 +26,9 @@ const PluginSettingModal: FC = ({ onSave, }) => { const { t } = useTranslation() - const [tempPrivilege, setTempPrivilege] = useState(payload) + const { autoUpdate: autoUpdateConfig, ...privilege } = payload || {} + const [tempPrivilege, setTempPrivilege] = useState(privilege) + const [tempAutoUpdateConfig, setTempAutoUpdateConfig] = useState(autoUpdateConfig || autoUpdateDefaultValue) const handlePrivilegeChange = useCallback((key: string) => { return (value: PermissionType) => { setTempPrivilege({ @@ -33,9 +39,12 @@ const PluginSettingModal: FC = ({ }, [tempPrivilege]) const handleSave = useCallback(async () => { - await onSave(tempPrivilege) + await onSave({ + ...tempPrivilege, + autoUpdate: tempAutoUpdateConfig, + }) onHide() - }, [onHide, onSave, tempPrivilege]) + }, [onHide, onSave, tempAutoUpdateConfig, tempPrivilege]) return ( = ({ { title: t(`${i18nPrefix}.whoCanDebug`), key: 'debug_permission', value: tempPrivilege?.debug_permission || PermissionType.noOne }, ].map(({ title, key, value }) => (
-
- {title} -
+
+ +
) diff --git a/web/i18n/en-US/plugin.ts b/web/i18n/en-US/plugin.ts index 2b6a517866..948be8fc3b 100644 --- a/web/i18n/en-US/plugin.ts +++ b/web/i18n/en-US/plugin.ts @@ -114,6 +114,9 @@ const translation = { noone: 'No one', }, autoUpdate: { + automaticUpdates: 'Automatic updates', + updateTime: 'Update time', + specifyPluginsToUpdate: 'Specify plugins to update', strategy: { disabled: { name: 'Disabled', @@ -122,10 +125,12 @@ const translation = { fixOnly: { name: 'Fix Only', description: 'Auto-update for patch versions only (e.g., 1.0.1 → 1.0.2). Minor version changes won\'t trigger updates.', + selectedDescription: 'Auto-update for patch versions only', }, latest: { name: 'Latest', description: 'Always update to latest version', + selectedDescription: 'Always update to latest version', }, }, }, diff --git a/web/i18n/zh-Hans/plugin.ts b/web/i18n/zh-Hans/plugin.ts index bc3e6b6784..0c03c27431 100644 --- a/web/i18n/zh-Hans/plugin.ts +++ b/web/i18n/zh-Hans/plugin.ts @@ -113,6 +113,27 @@ const translation = { admins: '管理员', noone: '无人', }, + autoUpdate: { + automaticUpdates: '自动更新', + updateTime: '更新时间', + specifyPluginsToUpdate: '指定要更新的插件', + strategy: { + disabled: { + name: '禁用', + description: '插件将不会自动更新', + }, + fixOnly: { + name: '仅修复', + description: '仅自动更新补丁版本(例如,1.0.1 → 1.0.2)。次要版本更改不会触发更新。', + selectedDescription: '仅自动更新补丁版本', + }, + latest: { + name: '最新', + description: '始终更新到最新版本', + selectedDescription: '始终更新到最新版本', + }, + }, + }, pluginInfoModal: { title: '插件信息', repository: '仓库', From bc75d810c4cfbfa1b93e6265664a9bec3066ec2f Mon Sep 17 00:00:00 2001 From: Joel Date: Thu, 19 Jun 2025 17:47:31 +0800 Subject: [PATCH 04/29] feat: choose time --- .../time-picker/header.tsx | 9 +++++-- .../time-picker/index.tsx | 6 +++-- .../base/date-and-time-picker/types.ts | 2 ++ .../auto-update-setting/config.ts | 2 +- .../auto-update-setting/index.tsx | 24 ++++++++++++++++++- web/i18n/en-US/plugin.ts | 1 + web/i18n/zh-Hans/plugin.ts | 1 + 7 files changed, 39 insertions(+), 6 deletions(-) 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.tsx index 3d85b2ea40..dc6b56f744 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,13 +1,18 @@ import React from 'react' import { useTranslation } from 'react-i18next' -const Header = () => { +type Props = { + title?: string +} +const Header = ({ + title, +}: Props) => { const { t } = useTranslation() return (
- {t('time.title.pickTime')} + {title || t('time.title.pickTime')}
) 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.tsx index a5e666d631..b21c9f9795 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 @@ -20,6 +20,8 @@ const TimePicker = ({ onChange, onClear, renderTrigger, + title, + popupClassName, }: TimePickerProps) => { const { t } = useTranslation() const [isOpen, setIsOpen] = useState(false) @@ -142,10 +144,10 @@ const TimePicker = ({
)} - +
{/* Header */} -
+
{/* Time Options */} void onClear: () => void renderTrigger?: () => React.ReactNode + title?: string + popupClassName?: string } export type TimePickerFooterProps = { diff --git a/web/app/components/plugins/reference-setting-modal/auto-update-setting/config.ts b/web/app/components/plugins/reference-setting-modal/auto-update-setting/config.ts index 084dfc9731..2144293762 100644 --- a/web/app/components/plugins/reference-setting-modal/auto-update-setting/config.ts +++ b/web/app/components/plugins/reference-setting-modal/auto-update-setting/config.ts @@ -1,7 +1,7 @@ import type { AutoUpdateConfig } from './types' import { AUTO_UPDATE_MODE, AUTO_UPDATE_STRATEGY } from './types' export const defaultValue: AutoUpdateConfig = { - strategy_setting: AUTO_UPDATE_STRATEGY.disabled, + strategy_setting: AUTO_UPDATE_STRATEGY.fixOnly, // For test upgrade_time_of_day: 0, upgrade_mode: AUTO_UPDATE_MODE.update_all, exclude_plugins: [], 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.tsx index 71cda8814d..66eb136913 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 @@ -5,9 +5,24 @@ import { AUTO_UPDATE_STRATEGY, type AutoUpdateConfig } from './types' import Label from '../label' import StrategyPicker from './strategy-picker' import { useTranslation } from 'react-i18next' +import TimePicker from '@/app/components/base/date-and-time-picker/time-picker' +import type { Dayjs } from 'dayjs' +import dayjs from 'dayjs' const i18nPrefix = 'plugin.autoUpdate' +const timeOfDayToDayjs = (timeOfDay: number): Dayjs => { + const hours = Math.floor(timeOfDay / 3600) + const minutes = (timeOfDay - hours * 3600) / 60 + const res = dayjs().startOf('day').hour(hours).minute(minutes) + return res +} + +const dayjsToTimeOfDay = (date?: Dayjs): number => { + if(!date) return 0 + return date.hour() * 3600 + date.minute() * 60 +} + type Props = { payload: AutoUpdateConfig onChange: (payload: AutoUpdateConfig) => void @@ -18,7 +33,7 @@ const AutoUpdateSetting: FC = ({ onChange, }) => { const { t } = useTranslation() - const { strategy_setting } = payload + const { strategy_setting, upgrade_time_of_day } = payload const strategyDescription = useMemo(() => { switch (strategy_setting) { case AUTO_UPDATE_STRATEGY.fixOnly: @@ -53,6 +68,13 @@ const AutoUpdateSetting: FC = ({ <>
-
+
)} diff --git a/web/i18n/en-US/plugin.ts b/web/i18n/en-US/plugin.ts index 951595765b..4cdfde7e67 100644 --- a/web/i18n/en-US/plugin.ts +++ b/web/i18n/en-US/plugin.ts @@ -134,6 +134,11 @@ const translation = { }, }, updateTimeTitle: 'Update time', + upgradeMode: { + update_all: 'Update all', + exclude: 'Exclude selected', + partial: 'Only selected', + }, }, pluginInfoModal: { title: 'Plugin info', diff --git a/web/i18n/zh-Hans/plugin.ts b/web/i18n/zh-Hans/plugin.ts index 8529bb3044..091e66648a 100644 --- a/web/i18n/zh-Hans/plugin.ts +++ b/web/i18n/zh-Hans/plugin.ts @@ -134,6 +134,11 @@ const translation = { }, }, updateTimeTitle: '更新时间', + upgradeMode: { + update_all: '更新全部', + exclude: '排除选定', + partial: '仅选定', + }, }, pluginInfoModal: { title: '插件信息', From 01cdffaa082967e17170d22319644a26b17cc820 Mon Sep 17 00:00:00 2001 From: Joel Date: Thu, 19 Jun 2025 18:13:56 +0800 Subject: [PATCH 06/29] feat: plugins picker holder --- .../auto-update-setting/index.tsx | 34 +++++++++++++++++++ .../auto-update-setting/plugins-picker.tsx | 29 ++++++++++++++++ 2 files changed, 63 insertions(+) create mode 100644 web/app/components/plugins/reference-setting-modal/auto-update-setting/plugins-picker.tsx 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.tsx index 03f1ec8d2e..48c8a6c8a6 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 @@ -9,6 +9,7 @@ import TimePicker from '@/app/components/base/date-and-time-picker/time-picker' import type { Dayjs } from 'dayjs' import dayjs from 'dayjs' import OptionCard from '@/app/components/workflow/nodes/_base/components/option-card' +import PluginsPicker from './plugins-picker' const i18nPrefix = 'plugin.autoUpdate' @@ -38,6 +39,8 @@ const AutoUpdateSetting: FC = ({ strategy_setting, upgrade_time_of_day, upgrade_mode, + exclude_plugins, + include_plugins, } = payload const strategyDescription = useMemo(() => { switch (strategy_setting) { @@ -49,6 +52,32 @@ const AutoUpdateSetting: FC = ({ return '' } }, [strategy_setting, t]) + + const plugins = useMemo(() => { + switch (upgrade_mode) { + case AUTO_UPDATE_MODE.partial: + return include_plugins + case AUTO_UPDATE_MODE.exclude: + return exclude_plugins + default: + return [] + } + }, [upgrade_mode, exclude_plugins, include_plugins]) + + const handlePluginsChange = useCallback((newPlugins: string[]) => { + if (upgrade_mode === AUTO_UPDATE_MODE.partial) { + onChange({ + ...payload, + include_plugins: newPlugins, + }) + } + else if (upgrade_mode === AUTO_UPDATE_MODE.exclude) { + onChange({ + ...payload, + exclude_plugins: newPlugins, + }) + } + }, [payload, upgrade_mode, onChange]) const handleChange = useCallback((key: keyof AutoUpdateConfig) => { return (value: AutoUpdateConfig[keyof AutoUpdateConfig]) => { onChange({ @@ -94,6 +123,11 @@ const AutoUpdateSetting: FC = ({ /> ))}
+ +
)} 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.tsx new file mode 100644 index 0000000000..148f121fd0 --- /dev/null +++ b/web/app/components/plugins/reference-setting-modal/auto-update-setting/plugins-picker.tsx @@ -0,0 +1,29 @@ +'use client' +import type { FC } from 'react' +import React from 'react' + +type Props = { + value: string[] // plugin ids + onChange: (value: string[]) => void +} + +const PluginsPicker: FC = ({ + value, + onChange, +}) => { + const hasSelected = value.length > 0 + return ( +
+ {hasSelected ? ( +
+
Selected plugins will not auto-update
+
+ ) : ( +
+ Only selected plugins will auto-update. No plugins are currently selected, so no plugins will auto-update. +
+ )} +
+ ) +} +export default React.memo(PluginsPicker) From 8b290ac7a100f4143fbaf5e77dff7dccc039858b Mon Sep 17 00:00:00 2001 From: Joel Date: Mon, 23 Jun 2025 16:45:48 +0800 Subject: [PATCH 07/29] feat: only choose 15 time --- .../base/date-and-time-picker/time-picker/index.tsx | 2 ++ .../base/date-and-time-picker/time-picker/options.tsx | 3 ++- web/app/components/base/date-and-time-picker/types.ts | 3 +++ .../reference-setting-modal/auto-update-setting/index.tsx | 8 ++++++++ 4 files changed, 15 insertions(+), 1 deletion(-) 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.tsx index b21c9f9795..7a6f9f94fd 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 @@ -21,6 +21,7 @@ const TimePicker = ({ onClear, renderTrigger, title, + minuteFilter, popupClassName, }: TimePickerProps) => { const { t } = useTranslation() @@ -152,6 +153,7 @@ const TimePicker = ({ {/* Time Options */} = ({ selectedTime, + minuteFilter, handleSelectHour, handleSelectMinute, handleSelectPeriod, @@ -33,7 +34,7 @@ const Options: FC = ({ {/* Minute */}
    { - minuteOptions.map((minute) => { + (minuteFilter ? minuteFilter(minuteOptions) : minuteOptions).map((minute) => { const isSelected = selectedTime?.format('mm') === minute return ( void triggerWrapClassName?: string renderTrigger?: (props: TriggerProps) => React.ReactNode + minuteFilter?: (minutes: string[]) => string[] popupZIndexClassname?: string } @@ -55,6 +56,7 @@ export type TimePickerProps = { onClear: () => void renderTrigger?: () => React.ReactNode title?: string + minuteFilter?: (minutes: string[]) => string[] popupClassName?: string } @@ -83,6 +85,7 @@ export type CalendarItemProps = { export type TimeOptionsProps = { selectedTime: Dayjs | undefined + minuteFilter?: (minutes: string[]) => string[] handleSelectHour: (hour: string) => void handleSelectMinute: (minute: string) => void handleSelectPeriod: (period: Period) => void 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.tsx index 48c8a6c8a6..67f4f5e034 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 @@ -42,6 +42,13 @@ const AutoUpdateSetting: FC = ({ exclude_plugins, include_plugins, } = payload + + const minuteFilter = useCallback((minutes: string[]) => { + return minutes.filter((m) => { + const time = Number.parseInt(m, 10) + return time % 15 === 0 + }) + }, []) const strategyDescription = useMemo(() => { switch (strategy_setting) { case AUTO_UPDATE_STRATEGY.fixOnly: @@ -108,6 +115,7 @@ const AutoUpdateSetting: FC = ({ onClear={() => handleChange('upgrade_time_of_day')(0)} popupClassName='z-[99]' title={t(`${i18nPrefix}.updateTime`)} + minuteFilter={minuteFilter} />
    From 29cac85b124634b7af93ecbc49fcb170587b1aca Mon Sep 17 00:00:00 2001 From: Joel Date: Mon, 23 Jun 2025 18:09:32 +0800 Subject: [PATCH 08/29] feat: plugin no data --- .../auto-update-setting/config.ts | 2 +- .../auto-update-setting/index.tsx | 11 +++++++---- .../auto-update-setting/plugins-picker.tsx | 11 +++++++---- web/i18n/en-US/plugin.ts | 4 ++++ web/i18n/zh-Hans/plugin.ts | 4 ++++ 5 files changed, 23 insertions(+), 9 deletions(-) diff --git a/web/app/components/plugins/reference-setting-modal/auto-update-setting/config.ts b/web/app/components/plugins/reference-setting-modal/auto-update-setting/config.ts index 2144293762..6c325e0719 100644 --- a/web/app/components/plugins/reference-setting-modal/auto-update-setting/config.ts +++ b/web/app/components/plugins/reference-setting-modal/auto-update-setting/config.ts @@ -3,7 +3,7 @@ import { AUTO_UPDATE_MODE, AUTO_UPDATE_STRATEGY } from './types' export const defaultValue: AutoUpdateConfig = { strategy_setting: AUTO_UPDATE_STRATEGY.fixOnly, // For test upgrade_time_of_day: 0, - upgrade_mode: AUTO_UPDATE_MODE.update_all, + upgrade_mode: AUTO_UPDATE_MODE.exclude, // For test exclude_plugins: [], include_plugins: [], } 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.tsx index 67f4f5e034..1219fe9c78 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 @@ -132,10 +132,13 @@ const AutoUpdateSetting: FC = ({ ))}
    - + {upgrade_mode !== AUTO_UPDATE_MODE.update_all && ( + + )} )} 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.tsx index 148f121fd0..fa348efa0a 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 @@ -1,28 +1,31 @@ 'use client' import type { FC } from 'react' import React from 'react' +import NoPluginSelected from './no-plugin-selected' +import type { AUTO_UPDATE_MODE } from './types' type Props = { + updateMode: AUTO_UPDATE_MODE value: string[] // plugin ids onChange: (value: string[]) => void } const PluginsPicker: FC = ({ + updateMode, value, onChange, }) => { const hasSelected = value.length > 0 return ( -
    +
    {hasSelected ? (
    Selected plugins will not auto-update
    ) : ( -
    - Only selected plugins will auto-update. No plugins are currently selected, so no plugins will auto-update. -
    + )} +
    ) } diff --git a/web/i18n/en-US/plugin.ts b/web/i18n/en-US/plugin.ts index 4cdfde7e67..a596ee044b 100644 --- a/web/i18n/en-US/plugin.ts +++ b/web/i18n/en-US/plugin.ts @@ -139,6 +139,10 @@ const translation = { exclude: 'Exclude selected', partial: 'Only selected', }, + upgradeModePlaceholder: { + exclude: 'Selected plugins will not auto-update', + partial: 'Only selected plugins will auto-update. No plugins are currently selected, so no plugins will auto-update.', + }, }, pluginInfoModal: { title: 'Plugin info', diff --git a/web/i18n/zh-Hans/plugin.ts b/web/i18n/zh-Hans/plugin.ts index 091e66648a..1384e979ab 100644 --- a/web/i18n/zh-Hans/plugin.ts +++ b/web/i18n/zh-Hans/plugin.ts @@ -139,6 +139,10 @@ const translation = { exclude: '排除选定', partial: '仅选定', }, + upgradeModePlaceholder: { + exclude: '选定的插件将不会自动更新', + partial: '仅选定的插件将自动更新。目前未选择任何插件,因此不会自动更新任何插件。', + }, }, pluginInfoModal: { title: '插件信息', From ccef71626ddb2e2db97dc1eea61a0dd5afa96d4a Mon Sep 17 00:00:00 2001 From: Joel Date: Mon, 23 Jun 2025 18:31:21 +0800 Subject: [PATCH 09/29] feat: show list and select --- .../auto-update-setting/config.ts | 4 +-- .../no-plugin-selected.tsx | 22 +++++++++++++ .../auto-update-setting/plugins-picker.tsx | 19 ++++++++++-- .../auto-update-setting/plugins-selected.tsx | 31 +++++++++++++++++++ 4 files changed, 71 insertions(+), 5 deletions(-) create mode 100644 web/app/components/plugins/reference-setting-modal/auto-update-setting/no-plugin-selected.tsx create mode 100644 web/app/components/plugins/reference-setting-modal/auto-update-setting/plugins-selected.tsx diff --git a/web/app/components/plugins/reference-setting-modal/auto-update-setting/config.ts b/web/app/components/plugins/reference-setting-modal/auto-update-setting/config.ts index 6c325e0719..a247061200 100644 --- a/web/app/components/plugins/reference-setting-modal/auto-update-setting/config.ts +++ b/web/app/components/plugins/reference-setting-modal/auto-update-setting/config.ts @@ -4,6 +4,6 @@ export const defaultValue: AutoUpdateConfig = { strategy_setting: AUTO_UPDATE_STRATEGY.fixOnly, // For test upgrade_time_of_day: 0, upgrade_mode: AUTO_UPDATE_MODE.exclude, // For test - exclude_plugins: [], - include_plugins: [], + exclude_plugins: ['a', 'c'], + include_plugins: ['b'], } 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.tsx new file mode 100644 index 0000000000..e255be0525 --- /dev/null +++ b/web/app/components/plugins/reference-setting-modal/auto-update-setting/no-plugin-selected.tsx @@ -0,0 +1,22 @@ +'use client' +import type { FC } from 'react' +import React from 'react' +import { AUTO_UPDATE_MODE } from './types' +import { useTranslation } from 'react-i18next' + +type Props = { + updateMode: AUTO_UPDATE_MODE +} + +const NoPluginSelected: FC = ({ + updateMode, +}) => { + const { t } = useTranslation() + const text = `${t(`plugin.autoUpdate.upgradeModePlaceholder.${updateMode === AUTO_UPDATE_MODE.partial ? 'partial' : 'exclude'}`)}` + return ( +
    + {text} +
    + ) +} +export default React.memo(NoPluginSelected) 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.tsx index fa348efa0a..ce5104764e 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 @@ -3,9 +3,12 @@ import type { FC } from 'react' import React from 'react' import NoPluginSelected from './no-plugin-selected' import type { AUTO_UPDATE_MODE } from './types' +import PluginsSelected from './plugins-selected' +import Button from '@/app/components/base/button' +import { RiAddLine } from '@remixicon/react' type Props = { - updateMode: AUTO_UPDATE_MODE + updateMode: AUTO_UPDATE_MODE value: string[] // plugin ids onChange: (value: string[]) => void } @@ -19,13 +22,23 @@ const PluginsPicker: FC = ({ return (
    {hasSelected ? ( -
    -
    Selected plugins will not auto-update
    +
    +
    The following 21 plugins will not auto-update
    +
    Clear all
    ) : ( )} + + +
    ) } 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.tsx new file mode 100644 index 0000000000..8bdf97c668 --- /dev/null +++ b/web/app/components/plugins/reference-setting-modal/auto-update-setting/plugins-selected.tsx @@ -0,0 +1,31 @@ +'use client' +import type { FC } from 'react' +import React from 'react' +import cn from '@/utils/classnames' + +const MAX_DISPLAY_COUNT = 14 +type Props = { + className?: string + plugins: string[] +} + +const PluginsSelected: FC = ({ + className, + plugins, +}) => { + const isShowAll = plugins.length < MAX_DISPLAY_COUNT + const displayPlugins = isShowAll ? plugins.slice(0, MAX_DISPLAY_COUNT) : plugins + return ( +
    + {displayPlugins.map((plugin, index) => ( +
    +
    + ))} + {!isShowAll &&
    +{plugins.length - MAX_DISPLAY_COUNT}
    } +
    + ) +} +export default React.memo(PluginsSelected) From 825fbcc6f8614cc3de23d9d30144fa0e5695e723 Mon Sep 17 00:00:00 2001 From: Joel Date: Tue, 24 Jun 2025 11:04:04 +0800 Subject: [PATCH 10/29] feat: auto update button --- .../assets/vender/system/auto-update-line.svg | 4 ++ .../base/icons/src/public/avatar/Robot.json | 2 +- .../base/icons/src/public/avatar/User.json | 2 +- .../icons/src/public/billing/ArCube1.json | 2 +- .../icons/src/public/billing/Asterisk.json | 2 +- .../src/public/billing/AwsMarketplace.json | 2 +- .../base/icons/src/public/billing/Azure.json | 2 +- .../icons/src/public/billing/Buildings.json | 2 +- .../icons/src/public/billing/Diamond.json | 2 +- .../icons/src/public/billing/GoogleCloud.json | 2 +- .../base/icons/src/public/billing/Group2.json | 2 +- .../icons/src/public/billing/Keyframe.json | 2 +- .../icons/src/public/billing/Sparkles.json | 2 +- .../src/public/billing/SparklesSoft.json | 2 +- .../base/icons/src/public/common/D.json | 2 +- .../public/common/DiagonalDividingLine.json | 2 +- .../base/icons/src/public/common/Dify.json | 2 +- .../base/icons/src/public/common/Gdpr.json | 2 +- .../base/icons/src/public/common/Github.json | 2 +- .../icons/src/public/common/Highlight.json | 2 +- .../base/icons/src/public/common/Iso.json | 2 +- .../base/icons/src/public/common/Line3.json | 2 +- .../base/icons/src/public/common/Lock.json | 2 +- .../src/public/common/MessageChatSquare.json | 2 +- .../src/public/common/MultiPathRetrieval.json | 2 +- .../src/public/common/NTo1Retrieval.json | 2 +- .../base/icons/src/public/common/Notion.json | 2 +- .../base/icons/src/public/common/Soc2.json | 2 +- .../icons/src/public/common/SparklesSoft.json | 2 +- .../icons/src/public/education/Triangle.json | 2 +- .../base/icons/src/public/files/Csv.json | 2 +- .../base/icons/src/public/files/Doc.json | 2 +- .../base/icons/src/public/files/Docx.json | 2 +- .../base/icons/src/public/files/Html.json | 2 +- .../base/icons/src/public/files/Json.json | 2 +- .../base/icons/src/public/files/Md.json | 2 +- .../base/icons/src/public/files/Pdf.json | 2 +- .../base/icons/src/public/files/Txt.json | 2 +- .../base/icons/src/public/files/Unknown.json | 2 +- .../base/icons/src/public/files/Xlsx.json | 2 +- .../base/icons/src/public/files/Yaml.json | 2 +- .../icons/src/public/knowledge/Chunk.json | 2 +- .../icons/src/public/knowledge/Collapse.json | 2 +- .../src/public/knowledge/GeneralType.json | 2 +- .../public/knowledge/LayoutRight2LineMod.json | 2 +- .../src/public/knowledge/ParentChildType.json | 2 +- .../src/public/knowledge/SelectionMod.json | 2 +- .../base/icons/src/public/llm/Anthropic.json | 2 +- .../icons/src/public/llm/AnthropicDark.json | 2 +- .../icons/src/public/llm/AnthropicLight.json | 2 +- .../icons/src/public/llm/AnthropicText.json | 2 +- .../src/public/llm/AzureOpenaiService.json | 2 +- .../public/llm/AzureOpenaiServiceText.json | 2 +- .../base/icons/src/public/llm/Azureai.json | 2 +- .../icons/src/public/llm/AzureaiText.json | 2 +- .../base/icons/src/public/llm/Baichuan.json | 2 +- .../icons/src/public/llm/BaichuanText.json | 2 +- .../base/icons/src/public/llm/Chatglm.json | 2 +- .../icons/src/public/llm/ChatglmText.json | 2 +- .../base/icons/src/public/llm/Cohere.json | 2 +- .../base/icons/src/public/llm/CohereText.json | 2 +- .../base/icons/src/public/llm/Gpt3.json | 2 +- .../base/icons/src/public/llm/Gpt4.json | 2 +- .../icons/src/public/llm/Huggingface.json | 2 +- .../icons/src/public/llm/HuggingfaceText.json | 2 +- .../src/public/llm/HuggingfaceTextHub.json | 2 +- .../icons/src/public/llm/IflytekSpark.json | 2 +- .../src/public/llm/IflytekSparkText.json | 2 +- .../src/public/llm/IflytekSparkTextCn.json | 2 +- .../base/icons/src/public/llm/Jina.json | 2 +- .../base/icons/src/public/llm/JinaText.json | 2 +- .../base/icons/src/public/llm/Localai.json | 2 +- .../icons/src/public/llm/LocalaiText.json | 2 +- .../base/icons/src/public/llm/Microsoft.json | 2 +- .../icons/src/public/llm/OpenaiBlack.json | 2 +- .../base/icons/src/public/llm/OpenaiBlue.json | 2 +- .../icons/src/public/llm/OpenaiGreen.json | 2 +- .../base/icons/src/public/llm/OpenaiTeal.json | 37 ------------------- .../base/icons/src/public/llm/OpenaiText.json | 2 +- .../src/public/llm/OpenaiTransparent.json | 2 +- .../icons/src/public/llm/OpenaiViolet.json | 2 +- .../icons/src/public/llm/OpenaiYellow.json | 37 ------------------- .../icons/src/public/llm/OpenaiYellow.tsx | 20 ---------- .../base/icons/src/public/llm/Openllm.json | 2 +- .../icons/src/public/llm/OpenllmText.json | 2 +- .../base/icons/src/public/llm/Replicate.json | 2 +- .../icons/src/public/llm/ReplicateText.json | 2 +- .../src/public/llm/XorbitsInference.json | 2 +- .../src/public/llm/XorbitsInferenceText.json | 2 +- .../base/icons/src/public/llm/Zhipuai.json | 2 +- .../icons/src/public/llm/ZhipuaiText.json | 2 +- .../icons/src/public/llm/ZhipuaiTextCn.json | 2 +- .../base/icons/src/public/llm/index.ts | 2 - .../base/icons/src/public/model/Checked.json | 2 +- .../src/public/other/DefaultToolIcon.json | 2 +- .../icons/src/public/other/Icon3Dots.json | 2 +- .../icons/src/public/other/Message3Fill.json | 2 +- .../icons/src/public/other/RowStruct.json | 2 +- .../base/icons/src/public/plugins/Google.json | 2 +- .../icons/src/public/plugins/PartnerDark.json | 2 +- .../src/public/plugins/PartnerLight.json | 2 +- .../src/public/plugins/VerifiedDark.json | 2 +- .../src/public/plugins/VerifiedLight.json | 2 +- .../icons/src/public/plugins/WebReader.json | 2 +- .../icons/src/public/plugins/Wikipedia.json | 2 +- .../icons/src/public/thought/DataSet.json | 2 +- .../icons/src/public/thought/Loading.json | 2 +- .../base/icons/src/public/thought/Search.json | 2 +- .../icons/src/public/thought/ThoughtList.json | 2 +- .../icons/src/public/thought/WebReader.json | 2 +- .../src/public/tracing/LangfuseIcon.json | 2 +- .../src/public/tracing/LangfuseIconBig.json | 2 +- .../src/public/tracing/LangsmithIcon.json | 2 +- .../src/public/tracing/LangsmithIconBig.json | 2 +- .../icons/src/public/tracing/OpikIcon.json | 2 +- .../icons/src/public/tracing/OpikIconBig.json | 2 +- .../icons/src/public/tracing/TracingIcon.json | 2 +- .../icons/src/public/tracing/WeaveIcon.json | 2 +- .../icons/src/public/tracing/WeaveIcon.tsx | 14 ++++--- .../src/public/tracing/WeaveIconBig.json | 2 +- .../icons/src/public/tracing/WeaveIconBig.tsx | 14 ++++--- .../src/vender/system/AutoUpdateLine.json | 37 +++++++++++++++++++ .../system/AutoUpdateLine.tsx} | 4 +- .../base/icons/src/vender/system/index.ts | 1 + .../plugin-detail-panel/detail-header.tsx | 11 ++++++ .../components/plugins/plugin-page/index.tsx | 2 +- .../auto-update-setting/index.tsx | 15 +------- .../auto-update-setting/utils.ts | 14 +++++++ web/i18n/en-US/plugin.ts | 1 + 129 files changed, 204 insertions(+), 237 deletions(-) create mode 100644 web/app/components/base/icons/assets/vender/system/auto-update-line.svg delete mode 100644 web/app/components/base/icons/src/public/llm/OpenaiTeal.json delete mode 100644 web/app/components/base/icons/src/public/llm/OpenaiYellow.json delete mode 100644 web/app/components/base/icons/src/public/llm/OpenaiYellow.tsx create mode 100644 web/app/components/base/icons/src/vender/system/AutoUpdateLine.json rename web/app/components/base/icons/src/{public/llm/OpenaiTeal.tsx => vender/system/AutoUpdateLine.tsx} (85%) create mode 100644 web/app/components/base/icons/src/vender/system/index.ts create mode 100644 web/app/components/plugins/reference-setting-modal/auto-update-setting/utils.ts diff --git a/web/app/components/base/icons/assets/vender/system/auto-update-line.svg b/web/app/components/base/icons/assets/vender/system/auto-update-line.svg new file mode 100644 index 0000000000..c6bff78400 --- /dev/null +++ b/web/app/components/base/icons/assets/vender/system/auto-update-line.svg @@ -0,0 +1,4 @@ + + + + diff --git a/web/app/components/base/icons/src/public/avatar/Robot.json b/web/app/components/base/icons/src/public/avatar/Robot.json index 8969a2a649..babc0f87a0 100644 --- a/web/app/components/base/icons/src/public/avatar/Robot.json +++ b/web/app/components/base/icons/src/public/avatar/Robot.json @@ -89,4 +89,4 @@ ] }, "name": "Robot" -} +} \ No newline at end of file diff --git a/web/app/components/base/icons/src/public/avatar/User.json b/web/app/components/base/icons/src/public/avatar/User.json index 4b9ad7615f..01fb8e39c3 100644 --- a/web/app/components/base/icons/src/public/avatar/User.json +++ b/web/app/components/base/icons/src/public/avatar/User.json @@ -86,4 +86,4 @@ ] }, "name": "User" -} +} \ No newline at end of file diff --git a/web/app/components/base/icons/src/public/billing/ArCube1.json b/web/app/components/base/icons/src/public/billing/ArCube1.json index 89d9786c04..f341c9218f 100644 --- a/web/app/components/base/icons/src/public/billing/ArCube1.json +++ b/web/app/components/base/icons/src/public/billing/ArCube1.json @@ -26,4 +26,4 @@ ] }, "name": "ArCube1" -} +} \ No newline at end of file diff --git a/web/app/components/base/icons/src/public/billing/Asterisk.json b/web/app/components/base/icons/src/public/billing/Asterisk.json index d4a2e91b45..6f70b27a1f 100644 --- a/web/app/components/base/icons/src/public/billing/Asterisk.json +++ b/web/app/components/base/icons/src/public/billing/Asterisk.json @@ -35,4 +35,4 @@ ] }, "name": "Asterisk" -} +} \ No newline at end of file diff --git a/web/app/components/base/icons/src/public/billing/AwsMarketplace.json b/web/app/components/base/icons/src/public/billing/AwsMarketplace.json index 8aeb93f7b2..8a0b1003cd 100644 --- a/web/app/components/base/icons/src/public/billing/AwsMarketplace.json +++ b/web/app/components/base/icons/src/public/billing/AwsMarketplace.json @@ -176,4 +176,4 @@ ] }, "name": "AwsMarketplace" -} +} \ No newline at end of file diff --git a/web/app/components/base/icons/src/public/billing/Azure.json b/web/app/components/base/icons/src/public/billing/Azure.json index fb6a9b9e95..ad4cd429a6 100644 --- a/web/app/components/base/icons/src/public/billing/Azure.json +++ b/web/app/components/base/icons/src/public/billing/Azure.json @@ -190,4 +190,4 @@ ] }, "name": "Azure" -} +} \ No newline at end of file diff --git a/web/app/components/base/icons/src/public/billing/Buildings.json b/web/app/components/base/icons/src/public/billing/Buildings.json index 62d22f97c6..f9dd338328 100644 --- a/web/app/components/base/icons/src/public/billing/Buildings.json +++ b/web/app/components/base/icons/src/public/billing/Buildings.json @@ -36,4 +36,4 @@ ] }, "name": "Buildings" -} +} \ No newline at end of file diff --git a/web/app/components/base/icons/src/public/billing/Diamond.json b/web/app/components/base/icons/src/public/billing/Diamond.json index 6717026232..69ab74606b 100644 --- a/web/app/components/base/icons/src/public/billing/Diamond.json +++ b/web/app/components/base/icons/src/public/billing/Diamond.json @@ -36,4 +36,4 @@ ] }, "name": "Diamond" -} +} \ No newline at end of file diff --git a/web/app/components/base/icons/src/public/billing/GoogleCloud.json b/web/app/components/base/icons/src/public/billing/GoogleCloud.json index 0c55bdaf03..244f05776f 100644 --- a/web/app/components/base/icons/src/public/billing/GoogleCloud.json +++ b/web/app/components/base/icons/src/public/billing/GoogleCloud.json @@ -63,4 +63,4 @@ ] }, "name": "GoogleCloud" -} +} \ No newline at end of file diff --git a/web/app/components/base/icons/src/public/billing/Group2.json b/web/app/components/base/icons/src/public/billing/Group2.json index 8cc0896d5d..b2424ba881 100644 --- a/web/app/components/base/icons/src/public/billing/Group2.json +++ b/web/app/components/base/icons/src/public/billing/Group2.json @@ -26,4 +26,4 @@ ] }, "name": "Group2" -} +} \ No newline at end of file diff --git a/web/app/components/base/icons/src/public/billing/Keyframe.json b/web/app/components/base/icons/src/public/billing/Keyframe.json index ed0dcb4fba..c721854d14 100644 --- a/web/app/components/base/icons/src/public/billing/Keyframe.json +++ b/web/app/components/base/icons/src/public/billing/Keyframe.json @@ -25,4 +25,4 @@ ] }, "name": "Keyframe" -} +} \ No newline at end of file diff --git a/web/app/components/base/icons/src/public/billing/Sparkles.json b/web/app/components/base/icons/src/public/billing/Sparkles.json index 5317b50936..ea2bae44e7 100644 --- a/web/app/components/base/icons/src/public/billing/Sparkles.json +++ b/web/app/components/base/icons/src/public/billing/Sparkles.json @@ -92,4 +92,4 @@ ] }, "name": "Sparkles" -} +} \ No newline at end of file diff --git a/web/app/components/base/icons/src/public/billing/SparklesSoft.json b/web/app/components/base/icons/src/public/billing/SparklesSoft.json index b6a5a6ddf4..ce4f11f489 100644 --- a/web/app/components/base/icons/src/public/billing/SparklesSoft.json +++ b/web/app/components/base/icons/src/public/billing/SparklesSoft.json @@ -33,4 +33,4 @@ ] }, "name": "SparklesSoft" -} +} \ No newline at end of file diff --git a/web/app/components/base/icons/src/public/common/D.json b/web/app/components/base/icons/src/public/common/D.json index ab4ed79135..2090b8909d 100644 --- a/web/app/components/base/icons/src/public/common/D.json +++ b/web/app/components/base/icons/src/public/common/D.json @@ -122,4 +122,4 @@ ] }, "name": "D" -} +} \ No newline at end of file diff --git a/web/app/components/base/icons/src/public/common/DiagonalDividingLine.json b/web/app/components/base/icons/src/public/common/DiagonalDividingLine.json index a9e7cd7217..04475c2288 100644 --- a/web/app/components/base/icons/src/public/common/DiagonalDividingLine.json +++ b/web/app/components/base/icons/src/public/common/DiagonalDividingLine.json @@ -25,4 +25,4 @@ ] }, "name": "DiagonalDividingLine" -} +} \ No newline at end of file diff --git a/web/app/components/base/icons/src/public/common/Dify.json b/web/app/components/base/icons/src/public/common/Dify.json index a954b66757..9926e91986 100644 --- a/web/app/components/base/icons/src/public/common/Dify.json +++ b/web/app/components/base/icons/src/public/common/Dify.json @@ -59,4 +59,4 @@ ] }, "name": "Dify" -} +} \ No newline at end of file diff --git a/web/app/components/base/icons/src/public/common/Gdpr.json b/web/app/components/base/icons/src/public/common/Gdpr.json index 1e030b54d1..3605030eb8 100644 --- a/web/app/components/base/icons/src/public/common/Gdpr.json +++ b/web/app/components/base/icons/src/public/common/Gdpr.json @@ -337,4 +337,4 @@ ] }, "name": "Gdpr" -} +} \ No newline at end of file diff --git a/web/app/components/base/icons/src/public/common/Github.json b/web/app/components/base/icons/src/public/common/Github.json index 523bcd55b8..abccde4f5e 100644 --- a/web/app/components/base/icons/src/public/common/Github.json +++ b/web/app/components/base/icons/src/public/common/Github.json @@ -33,4 +33,4 @@ ] }, "name": "Github" -} +} \ No newline at end of file diff --git a/web/app/components/base/icons/src/public/common/Highlight.json b/web/app/components/base/icons/src/public/common/Highlight.json index 055d9f79ca..d18386eb01 100644 --- a/web/app/components/base/icons/src/public/common/Highlight.json +++ b/web/app/components/base/icons/src/public/common/Highlight.json @@ -64,4 +64,4 @@ ] }, "name": "Highlight" -} +} \ No newline at end of file diff --git a/web/app/components/base/icons/src/public/common/Iso.json b/web/app/components/base/icons/src/public/common/Iso.json index 50f0267b60..6864a591c4 100644 --- a/web/app/components/base/icons/src/public/common/Iso.json +++ b/web/app/components/base/icons/src/public/common/Iso.json @@ -118,4 +118,4 @@ ] }, "name": "Iso" -} +} \ No newline at end of file diff --git a/web/app/components/base/icons/src/public/common/Line3.json b/web/app/components/base/icons/src/public/common/Line3.json index 2beb66a5f4..32f6d50bb8 100644 --- a/web/app/components/base/icons/src/public/common/Line3.json +++ b/web/app/components/base/icons/src/public/common/Line3.json @@ -25,4 +25,4 @@ ] }, "name": "Line3" -} +} \ No newline at end of file diff --git a/web/app/components/base/icons/src/public/common/Lock.json b/web/app/components/base/icons/src/public/common/Lock.json index a5a1f4b781..24af41a73d 100644 --- a/web/app/components/base/icons/src/public/common/Lock.json +++ b/web/app/components/base/icons/src/public/common/Lock.json @@ -35,4 +35,4 @@ ] }, "name": "Lock" -} +} \ No newline at end of file diff --git a/web/app/components/base/icons/src/public/common/MessageChatSquare.json b/web/app/components/base/icons/src/public/common/MessageChatSquare.json index 71cf6d0c98..18069eda39 100644 --- a/web/app/components/base/icons/src/public/common/MessageChatSquare.json +++ b/web/app/components/base/icons/src/public/common/MessageChatSquare.json @@ -34,4 +34,4 @@ ] }, "name": "MessageChatSquare" -} +} \ No newline at end of file diff --git a/web/app/components/base/icons/src/public/common/MultiPathRetrieval.json b/web/app/components/base/icons/src/public/common/MultiPathRetrieval.json index 9d64edadd4..d37b263688 100644 --- a/web/app/components/base/icons/src/public/common/MultiPathRetrieval.json +++ b/web/app/components/base/icons/src/public/common/MultiPathRetrieval.json @@ -150,4 +150,4 @@ ] }, "name": "MultiPathRetrieval" -} +} \ No newline at end of file diff --git a/web/app/components/base/icons/src/public/common/NTo1Retrieval.json b/web/app/components/base/icons/src/public/common/NTo1Retrieval.json index 74ca34573f..086522046f 100644 --- a/web/app/components/base/icons/src/public/common/NTo1Retrieval.json +++ b/web/app/components/base/icons/src/public/common/NTo1Retrieval.json @@ -143,4 +143,4 @@ ] }, "name": "NTo1Retrieval" -} +} \ No newline at end of file diff --git a/web/app/components/base/icons/src/public/common/Notion.json b/web/app/components/base/icons/src/public/common/Notion.json index d27aeb8190..27bb0081d0 100644 --- a/web/app/components/base/icons/src/public/common/Notion.json +++ b/web/app/components/base/icons/src/public/common/Notion.json @@ -80,4 +80,4 @@ ] }, "name": "Notion" -} +} \ No newline at end of file diff --git a/web/app/components/base/icons/src/public/common/Soc2.json b/web/app/components/base/icons/src/public/common/Soc2.json index 38b9c5e606..34080b0adb 100644 --- a/web/app/components/base/icons/src/public/common/Soc2.json +++ b/web/app/components/base/icons/src/public/common/Soc2.json @@ -935,4 +935,4 @@ ] }, "name": "Soc2" -} +} \ No newline at end of file diff --git a/web/app/components/base/icons/src/public/common/SparklesSoft.json b/web/app/components/base/icons/src/public/common/SparklesSoft.json index 11ac030c5e..e22cec82a3 100644 --- a/web/app/components/base/icons/src/public/common/SparklesSoft.json +++ b/web/app/components/base/icons/src/public/common/SparklesSoft.json @@ -44,4 +44,4 @@ ] }, "name": "SparklesSoft" -} +} \ No newline at end of file diff --git a/web/app/components/base/icons/src/public/education/Triangle.json b/web/app/components/base/icons/src/public/education/Triangle.json index ab00049ce1..92d7c82c43 100644 --- a/web/app/components/base/icons/src/public/education/Triangle.json +++ b/web/app/components/base/icons/src/public/education/Triangle.json @@ -24,4 +24,4 @@ ] }, "name": "Triangle" -} +} \ No newline at end of file diff --git a/web/app/components/base/icons/src/public/files/Csv.json b/web/app/components/base/icons/src/public/files/Csv.json index 533dcd7525..d4d2bd9f3e 100644 --- a/web/app/components/base/icons/src/public/files/Csv.json +++ b/web/app/components/base/icons/src/public/files/Csv.json @@ -178,4 +178,4 @@ ] }, "name": "Csv" -} +} \ No newline at end of file diff --git a/web/app/components/base/icons/src/public/files/Doc.json b/web/app/components/base/icons/src/public/files/Doc.json index 9d219addd2..f4513177a6 100644 --- a/web/app/components/base/icons/src/public/files/Doc.json +++ b/web/app/components/base/icons/src/public/files/Doc.json @@ -166,4 +166,4 @@ ] }, "name": "Doc" -} +} \ No newline at end of file diff --git a/web/app/components/base/icons/src/public/files/Docx.json b/web/app/components/base/icons/src/public/files/Docx.json index ffa9ef8d3b..5054f083b4 100644 --- a/web/app/components/base/icons/src/public/files/Docx.json +++ b/web/app/components/base/icons/src/public/files/Docx.json @@ -175,4 +175,4 @@ ] }, "name": "Docx" -} +} \ No newline at end of file diff --git a/web/app/components/base/icons/src/public/files/Html.json b/web/app/components/base/icons/src/public/files/Html.json index f267073c47..86134d1df9 100644 --- a/web/app/components/base/icons/src/public/files/Html.json +++ b/web/app/components/base/icons/src/public/files/Html.json @@ -175,4 +175,4 @@ ] }, "name": "Html" -} +} \ No newline at end of file diff --git a/web/app/components/base/icons/src/public/files/Json.json b/web/app/components/base/icons/src/public/files/Json.json index 0801fecc1c..ae2943dac6 100644 --- a/web/app/components/base/icons/src/public/files/Json.json +++ b/web/app/components/base/icons/src/public/files/Json.json @@ -175,4 +175,4 @@ ] }, "name": "Json" -} +} \ No newline at end of file diff --git a/web/app/components/base/icons/src/public/files/Md.json b/web/app/components/base/icons/src/public/files/Md.json index 4a3cb687e6..da1669658c 100644 --- a/web/app/components/base/icons/src/public/files/Md.json +++ b/web/app/components/base/icons/src/public/files/Md.json @@ -141,4 +141,4 @@ ] }, "name": "Md" -} +} \ No newline at end of file diff --git a/web/app/components/base/icons/src/public/files/Pdf.json b/web/app/components/base/icons/src/public/files/Pdf.json index 7770f2790d..e5ff4bc33b 100644 --- a/web/app/components/base/icons/src/public/files/Pdf.json +++ b/web/app/components/base/icons/src/public/files/Pdf.json @@ -166,4 +166,4 @@ ] }, "name": "Pdf" -} +} \ No newline at end of file diff --git a/web/app/components/base/icons/src/public/files/Txt.json b/web/app/components/base/icons/src/public/files/Txt.json index c689fc680d..e511b9271c 100644 --- a/web/app/components/base/icons/src/public/files/Txt.json +++ b/web/app/components/base/icons/src/public/files/Txt.json @@ -177,4 +177,4 @@ ] }, "name": "Txt" -} +} \ No newline at end of file diff --git a/web/app/components/base/icons/src/public/files/Unknown.json b/web/app/components/base/icons/src/public/files/Unknown.json index f1351e039e..c39df990d0 100644 --- a/web/app/components/base/icons/src/public/files/Unknown.json +++ b/web/app/components/base/icons/src/public/files/Unknown.json @@ -196,4 +196,4 @@ ] }, "name": "Unknown" -} +} \ No newline at end of file diff --git a/web/app/components/base/icons/src/public/files/Xlsx.json b/web/app/components/base/icons/src/public/files/Xlsx.json index 5f0e7a96fc..9cd6a618bf 100644 --- a/web/app/components/base/icons/src/public/files/Xlsx.json +++ b/web/app/components/base/icons/src/public/files/Xlsx.json @@ -142,4 +142,4 @@ ] }, "name": "Xlsx" -} +} \ No newline at end of file diff --git a/web/app/components/base/icons/src/public/files/Yaml.json b/web/app/components/base/icons/src/public/files/Yaml.json index aa05cb468e..e35087a8e8 100644 --- a/web/app/components/base/icons/src/public/files/Yaml.json +++ b/web/app/components/base/icons/src/public/files/Yaml.json @@ -178,4 +178,4 @@ ] }, "name": "Yaml" -} +} \ No newline at end of file diff --git a/web/app/components/base/icons/src/public/knowledge/Chunk.json b/web/app/components/base/icons/src/public/knowledge/Chunk.json index 91e85f2ce1..469d85d1a7 100644 --- a/web/app/components/base/icons/src/public/knowledge/Chunk.json +++ b/web/app/components/base/icons/src/public/knowledge/Chunk.json @@ -113,4 +113,4 @@ ] }, "name": "Chunk" -} +} \ No newline at end of file diff --git a/web/app/components/base/icons/src/public/knowledge/Collapse.json b/web/app/components/base/icons/src/public/knowledge/Collapse.json index 726b074007..66d457155d 100644 --- a/web/app/components/base/icons/src/public/knowledge/Collapse.json +++ b/web/app/components/base/icons/src/public/knowledge/Collapse.json @@ -59,4 +59,4 @@ ] }, "name": "Collapse" -} +} \ No newline at end of file diff --git a/web/app/components/base/icons/src/public/knowledge/GeneralType.json b/web/app/components/base/icons/src/public/knowledge/GeneralType.json index 5cbfb1a83c..9a87d00a60 100644 --- a/web/app/components/base/icons/src/public/knowledge/GeneralType.json +++ b/web/app/components/base/icons/src/public/knowledge/GeneralType.json @@ -35,4 +35,4 @@ ] }, "name": "GeneralType" -} +} \ No newline at end of file diff --git a/web/app/components/base/icons/src/public/knowledge/LayoutRight2LineMod.json b/web/app/components/base/icons/src/public/knowledge/LayoutRight2LineMod.json index 194bec705e..26c5cf1d4f 100644 --- a/web/app/components/base/icons/src/public/knowledge/LayoutRight2LineMod.json +++ b/web/app/components/base/icons/src/public/knowledge/LayoutRight2LineMod.json @@ -33,4 +33,4 @@ ] }, "name": "LayoutRight2LineMod" -} +} \ No newline at end of file diff --git a/web/app/components/base/icons/src/public/knowledge/ParentChildType.json b/web/app/components/base/icons/src/public/knowledge/ParentChildType.json index 2d3270e418..250da77fc8 100644 --- a/web/app/components/base/icons/src/public/knowledge/ParentChildType.json +++ b/web/app/components/base/icons/src/public/knowledge/ParentChildType.json @@ -53,4 +53,4 @@ ] }, "name": "ParentChildType" -} +} \ No newline at end of file diff --git a/web/app/components/base/icons/src/public/knowledge/SelectionMod.json b/web/app/components/base/icons/src/public/knowledge/SelectionMod.json index c88e27809f..ff8174a572 100644 --- a/web/app/components/base/icons/src/public/knowledge/SelectionMod.json +++ b/web/app/components/base/icons/src/public/knowledge/SelectionMod.json @@ -113,4 +113,4 @@ ] }, "name": "SelectionMod" -} +} \ No newline at end of file diff --git a/web/app/components/base/icons/src/public/llm/Anthropic.json b/web/app/components/base/icons/src/public/llm/Anthropic.json index db33abd6cc..f237bba80e 100644 --- a/web/app/components/base/icons/src/public/llm/Anthropic.json +++ b/web/app/components/base/icons/src/public/llm/Anthropic.json @@ -34,4 +34,4 @@ ] }, "name": "Anthropic" -} +} \ No newline at end of file diff --git a/web/app/components/base/icons/src/public/llm/AnthropicDark.json b/web/app/components/base/icons/src/public/llm/AnthropicDark.json index ca066c2e78..4f3af3ce79 100644 --- a/web/app/components/base/icons/src/public/llm/AnthropicDark.json +++ b/web/app/components/base/icons/src/public/llm/AnthropicDark.json @@ -1043,4 +1043,4 @@ ] }, "name": "AnthropicDark" -} +} \ No newline at end of file diff --git a/web/app/components/base/icons/src/public/llm/AnthropicLight.json b/web/app/components/base/icons/src/public/llm/AnthropicLight.json index 2d2b0aab3e..3e84eb4dd6 100644 --- a/web/app/components/base/icons/src/public/llm/AnthropicLight.json +++ b/web/app/components/base/icons/src/public/llm/AnthropicLight.json @@ -1043,4 +1043,4 @@ ] }, "name": "AnthropicLight" -} +} \ No newline at end of file diff --git a/web/app/components/base/icons/src/public/llm/AnthropicText.json b/web/app/components/base/icons/src/public/llm/AnthropicText.json index 7f89795d2f..72b3e6ebb7 100644 --- a/web/app/components/base/icons/src/public/llm/AnthropicText.json +++ b/web/app/components/base/icons/src/public/llm/AnthropicText.json @@ -536,4 +536,4 @@ ] }, "name": "AnthropicText" -} +} \ No newline at end of file diff --git a/web/app/components/base/icons/src/public/llm/AzureOpenaiService.json b/web/app/components/base/icons/src/public/llm/AzureOpenaiService.json index bf07b59a51..42cba3143b 100644 --- a/web/app/components/base/icons/src/public/llm/AzureOpenaiService.json +++ b/web/app/components/base/icons/src/public/llm/AzureOpenaiService.json @@ -71,4 +71,4 @@ ] }, "name": "AzureOpenaiService" -} +} \ No newline at end of file diff --git a/web/app/components/base/icons/src/public/llm/AzureOpenaiServiceText.json b/web/app/components/base/icons/src/public/llm/AzureOpenaiServiceText.json index f4342d7c39..12cdeec971 100644 --- a/web/app/components/base/icons/src/public/llm/AzureOpenaiServiceText.json +++ b/web/app/components/base/icons/src/public/llm/AzureOpenaiServiceText.json @@ -233,4 +233,4 @@ ] }, "name": "AzureOpenaiServiceText" -} +} \ No newline at end of file diff --git a/web/app/components/base/icons/src/public/llm/Azureai.json b/web/app/components/base/icons/src/public/llm/Azureai.json index 004da326da..8662cfb937 100644 --- a/web/app/components/base/icons/src/public/llm/Azureai.json +++ b/web/app/components/base/icons/src/public/llm/Azureai.json @@ -177,4 +177,4 @@ ] }, "name": "Azureai" -} +} \ No newline at end of file diff --git a/web/app/components/base/icons/src/public/llm/AzureaiText.json b/web/app/components/base/icons/src/public/llm/AzureaiText.json index 44976aa8e2..2eb359960e 100644 --- a/web/app/components/base/icons/src/public/llm/AzureaiText.json +++ b/web/app/components/base/icons/src/public/llm/AzureaiText.json @@ -240,4 +240,4 @@ ] }, "name": "AzureaiText" -} +} \ No newline at end of file diff --git a/web/app/components/base/icons/src/public/llm/Baichuan.json b/web/app/components/base/icons/src/public/llm/Baichuan.json index 196fbada8c..ad93703002 100644 --- a/web/app/components/base/icons/src/public/llm/Baichuan.json +++ b/web/app/components/base/icons/src/public/llm/Baichuan.json @@ -73,4 +73,4 @@ ] }, "name": "Baichuan" -} +} \ No newline at end of file diff --git a/web/app/components/base/icons/src/public/llm/BaichuanText.json b/web/app/components/base/icons/src/public/llm/BaichuanText.json index c4dc1d1101..cda52e97fd 100644 --- a/web/app/components/base/icons/src/public/llm/BaichuanText.json +++ b/web/app/components/base/icons/src/public/llm/BaichuanText.json @@ -153,4 +153,4 @@ ] }, "name": "BaichuanText" -} +} \ No newline at end of file diff --git a/web/app/components/base/icons/src/public/llm/Chatglm.json b/web/app/components/base/icons/src/public/llm/Chatglm.json index c01787f8eb..37a6aa9913 100644 --- a/web/app/components/base/icons/src/public/llm/Chatglm.json +++ b/web/app/components/base/icons/src/public/llm/Chatglm.json @@ -69,4 +69,4 @@ ] }, "name": "Chatglm" -} +} \ No newline at end of file diff --git a/web/app/components/base/icons/src/public/llm/ChatglmText.json b/web/app/components/base/icons/src/public/llm/ChatglmText.json index 1fe28ea749..80b765cfc8 100644 --- a/web/app/components/base/icons/src/public/llm/ChatglmText.json +++ b/web/app/components/base/icons/src/public/llm/ChatglmText.json @@ -132,4 +132,4 @@ ] }, "name": "ChatglmText" -} +} \ No newline at end of file diff --git a/web/app/components/base/icons/src/public/llm/Cohere.json b/web/app/components/base/icons/src/public/llm/Cohere.json index 70628917da..255514e8b0 100644 --- a/web/app/components/base/icons/src/public/llm/Cohere.json +++ b/web/app/components/base/icons/src/public/llm/Cohere.json @@ -109,4 +109,4 @@ ] }, "name": "Cohere" -} +} \ No newline at end of file diff --git a/web/app/components/base/icons/src/public/llm/CohereText.json b/web/app/components/base/icons/src/public/llm/CohereText.json index 89657ccac6..588b345814 100644 --- a/web/app/components/base/icons/src/public/llm/CohereText.json +++ b/web/app/components/base/icons/src/public/llm/CohereText.json @@ -87,4 +87,4 @@ ] }, "name": "CohereText" -} +} \ No newline at end of file diff --git a/web/app/components/base/icons/src/public/llm/Gpt3.json b/web/app/components/base/icons/src/public/llm/Gpt3.json index 383cb98d3a..253b9a3d3f 100644 --- a/web/app/components/base/icons/src/public/llm/Gpt3.json +++ b/web/app/components/base/icons/src/public/llm/Gpt3.json @@ -48,4 +48,4 @@ ] }, "name": "Gpt3" -} +} \ No newline at end of file diff --git a/web/app/components/base/icons/src/public/llm/Gpt4.json b/web/app/components/base/icons/src/public/llm/Gpt4.json index b0d1941df1..0e50c5f712 100644 --- a/web/app/components/base/icons/src/public/llm/Gpt4.json +++ b/web/app/components/base/icons/src/public/llm/Gpt4.json @@ -48,4 +48,4 @@ ] }, "name": "Gpt4" -} +} \ No newline at end of file diff --git a/web/app/components/base/icons/src/public/llm/Huggingface.json b/web/app/components/base/icons/src/public/llm/Huggingface.json index 57e10e2b45..b3bd943da7 100644 --- a/web/app/components/base/icons/src/public/llm/Huggingface.json +++ b/web/app/components/base/icons/src/public/llm/Huggingface.json @@ -155,4 +155,4 @@ ] }, "name": "Huggingface" -} +} \ No newline at end of file diff --git a/web/app/components/base/icons/src/public/llm/HuggingfaceText.json b/web/app/components/base/icons/src/public/llm/HuggingfaceText.json index d113e64f17..4e80364b55 100644 --- a/web/app/components/base/icons/src/public/llm/HuggingfaceText.json +++ b/web/app/components/base/icons/src/public/llm/HuggingfaceText.json @@ -319,4 +319,4 @@ ] }, "name": "HuggingfaceText" -} +} \ No newline at end of file diff --git a/web/app/components/base/icons/src/public/llm/HuggingfaceTextHub.json b/web/app/components/base/icons/src/public/llm/HuggingfaceTextHub.json index 0500abf2db..9dcc6d64a8 100644 --- a/web/app/components/base/icons/src/public/llm/HuggingfaceTextHub.json +++ b/web/app/components/base/icons/src/public/llm/HuggingfaceTextHub.json @@ -347,4 +347,4 @@ ] }, "name": "HuggingfaceTextHub" -} +} \ No newline at end of file diff --git a/web/app/components/base/icons/src/public/llm/IflytekSpark.json b/web/app/components/base/icons/src/public/llm/IflytekSpark.json index 1803b5f573..03f50d7e39 100644 --- a/web/app/components/base/icons/src/public/llm/IflytekSpark.json +++ b/web/app/components/base/icons/src/public/llm/IflytekSpark.json @@ -41,4 +41,4 @@ ] }, "name": "IflytekSpark" -} +} \ No newline at end of file diff --git a/web/app/components/base/icons/src/public/llm/IflytekSparkText.json b/web/app/components/base/icons/src/public/llm/IflytekSparkText.json index 2b01c14a6d..bd51f88aeb 100644 --- a/web/app/components/base/icons/src/public/llm/IflytekSparkText.json +++ b/web/app/components/base/icons/src/public/llm/IflytekSparkText.json @@ -184,4 +184,4 @@ ] }, "name": "IflytekSparkText" -} +} \ No newline at end of file diff --git a/web/app/components/base/icons/src/public/llm/IflytekSparkTextCn.json b/web/app/components/base/icons/src/public/llm/IflytekSparkTextCn.json index 22d1411037..4c874ad6ec 100644 --- a/web/app/components/base/icons/src/public/llm/IflytekSparkTextCn.json +++ b/web/app/components/base/icons/src/public/llm/IflytekSparkTextCn.json @@ -95,4 +95,4 @@ ] }, "name": "IflytekSparkTextCn" -} +} \ No newline at end of file diff --git a/web/app/components/base/icons/src/public/llm/Jina.json b/web/app/components/base/icons/src/public/llm/Jina.json index 88d70a3ff1..fc40c022f5 100644 --- a/web/app/components/base/icons/src/public/llm/Jina.json +++ b/web/app/components/base/icons/src/public/llm/Jina.json @@ -32,4 +32,4 @@ ] }, "name": "Jina" -} +} \ No newline at end of file diff --git a/web/app/components/base/icons/src/public/llm/JinaText.json b/web/app/components/base/icons/src/public/llm/JinaText.json index 08e76ef580..04831fa4aa 100644 --- a/web/app/components/base/icons/src/public/llm/JinaText.json +++ b/web/app/components/base/icons/src/public/llm/JinaText.json @@ -79,4 +79,4 @@ ] }, "name": "JinaText" -} +} \ No newline at end of file diff --git a/web/app/components/base/icons/src/public/llm/Localai.json b/web/app/components/base/icons/src/public/llm/Localai.json index e0f85498d7..30b9786182 100644 --- a/web/app/components/base/icons/src/public/llm/Localai.json +++ b/web/app/components/base/icons/src/public/llm/Localai.json @@ -104,4 +104,4 @@ ] }, "name": "Localai" -} +} \ No newline at end of file diff --git a/web/app/components/base/icons/src/public/llm/LocalaiText.json b/web/app/components/base/icons/src/public/llm/LocalaiText.json index 849f7ae4f4..e7a45194aa 100644 --- a/web/app/components/base/icons/src/public/llm/LocalaiText.json +++ b/web/app/components/base/icons/src/public/llm/LocalaiText.json @@ -167,4 +167,4 @@ ] }, "name": "LocalaiText" -} +} \ No newline at end of file diff --git a/web/app/components/base/icons/src/public/llm/Microsoft.json b/web/app/components/base/icons/src/public/llm/Microsoft.json index ab2c0522c7..692cd25eae 100644 --- a/web/app/components/base/icons/src/public/llm/Microsoft.json +++ b/web/app/components/base/icons/src/public/llm/Microsoft.json @@ -73,4 +73,4 @@ ] }, "name": "Microsoft" -} +} \ No newline at end of file diff --git a/web/app/components/base/icons/src/public/llm/OpenaiBlack.json b/web/app/components/base/icons/src/public/llm/OpenaiBlack.json index 9f4a9914d3..ad722849e7 100644 --- a/web/app/components/base/icons/src/public/llm/OpenaiBlack.json +++ b/web/app/components/base/icons/src/public/llm/OpenaiBlack.json @@ -34,4 +34,4 @@ ] }, "name": "OpenaiBlack" -} +} \ No newline at end of file diff --git a/web/app/components/base/icons/src/public/llm/OpenaiBlue.json b/web/app/components/base/icons/src/public/llm/OpenaiBlue.json index 5c716f7cdd..60b3fc6cf8 100644 --- a/web/app/components/base/icons/src/public/llm/OpenaiBlue.json +++ b/web/app/components/base/icons/src/public/llm/OpenaiBlue.json @@ -34,4 +34,4 @@ ] }, "name": "OpenaiBlue" -} +} \ No newline at end of file diff --git a/web/app/components/base/icons/src/public/llm/OpenaiGreen.json b/web/app/components/base/icons/src/public/llm/OpenaiGreen.json index 8980e858ca..9ca36b6aa4 100644 --- a/web/app/components/base/icons/src/public/llm/OpenaiGreen.json +++ b/web/app/components/base/icons/src/public/llm/OpenaiGreen.json @@ -34,4 +34,4 @@ ] }, "name": "OpenaiGreen" -} +} \ No newline at end of file diff --git a/web/app/components/base/icons/src/public/llm/OpenaiTeal.json b/web/app/components/base/icons/src/public/llm/OpenaiTeal.json deleted file mode 100644 index 1e85c161be..0000000000 --- a/web/app/components/base/icons/src/public/llm/OpenaiTeal.json +++ /dev/null @@ -1,37 +0,0 @@ -{ - "icon": { - "type": "element", - "isRootNode": true, - "name": "svg", - "attributes": { - "width": "24", - "height": "24", - "viewBox": "0 0 24 24", - "fill": "none", - "xmlns": "http://www.w3.org/2000/svg" - }, - "children": [ - { - "type": "element", - "name": "rect", - "attributes": { - "width": "24", - "height": "24", - "rx": "6", - "fill": "#009688" - }, - "children": [] - }, - { - "type": "element", - "name": "path", - "attributes": { - "d": "M19.7758 11.5959C19.9546 11.9948 20.0681 12.4213 20.1145 12.8563C20.1592 13.2913 20.1369 13.7315 20.044 14.1596C19.9529 14.5878 19.7947 14.9987 19.5746 15.377C19.4302 15.6298 19.2599 15.867 19.0639 16.0854C18.8696 16.3021 18.653 16.4981 18.4174 16.67C18.1801 16.842 17.9274 16.9864 17.6591 17.105C17.3926 17.222 17.1141 17.3114 16.8286 17.3698C16.6945 17.7859 16.4951 18.1797 16.2371 18.5339C15.9809 18.8881 15.6697 19.1993 15.3155 19.4555C14.9613 19.7134 14.5693 19.9129 14.1532 20.047C13.7371 20.1829 13.302 20.2499 12.8636 20.2499C12.573 20.2516 12.2807 20.2207 11.9953 20.1622C11.7116 20.102 11.433 20.0109 11.1665 19.8923C10.9 19.7736 10.6472 19.6258 10.4116 19.4538C10.1778 19.2819 9.96115 19.0841 9.76857 18.8658C9.33871 18.9586 8.89853 18.981 8.46351 18.9363C8.02849 18.8898 7.60207 18.7763 7.20143 18.5975C6.80252 18.4204 6.43284 18.1797 6.10786 17.8857C5.78289 17.5916 5.50606 17.2478 5.28769 16.8695C5.14153 16.6167 5.02117 16.3502 4.93004 16.0734C4.83891 15.7965 4.77873 15.5111 4.74778 15.2205C4.71683 14.9317 4.71855 14.6393 4.7495 14.3488C4.78045 14.0599 4.84407 13.7745 4.9352 13.4976C4.64289 13.1727 4.40217 12.803 4.22335 12.4041C4.04624 12.0034 3.93104 11.5787 3.88634 11.1437C3.83991 10.7087 3.86398 10.2685 3.95511 9.84036C4.04624 9.41222 4.20443 9.00127 4.42452 8.62299C4.56896 8.37023 4.73918 8.13123 4.93348 7.91458C5.12778 7.69793 5.34615 7.50191 5.58171 7.32997C5.81728 7.15802 6.07176 7.01187 6.33827 6.89495C6.6065 6.7763 6.88506 6.68861 7.17048 6.63015C7.3046 6.21232 7.50406 5.82029 7.76026 5.46608C8.01817 5.11188 8.32939 4.80066 8.6836 4.54274C9.03781 4.28654 9.42984 4.08708 9.84595 3.95125C10.2621 3.81713 10.6971 3.74835 11.1355 3.75007C11.4261 3.74835 11.7184 3.77758 12.0039 3.83776C12.2893 3.89794 12.5678 3.98736 12.8344 4.106C13.1009 4.22636 13.3536 4.37251 13.5892 4.54446C13.8248 4.71812 14.0414 4.91414 14.234 5.13251C14.6621 5.04138 15.1023 5.01903 15.5373 5.06373C15.9723 5.10844 16.3971 5.22364 16.7977 5.40074C17.1966 5.57957 17.5663 5.81857 17.8913 6.1126C18.2162 6.4049 18.4931 6.74707 18.7114 7.12707C18.8576 7.37811 18.9779 7.64463 19.0691 7.92318C19.1602 8.20001 19.2221 8.48544 19.2513 8.77602C19.2823 9.06661 19.2823 9.35892 19.2496 9.64951C19.2187 9.94009 19.155 10.2255 19.0639 10.5024C19.3579 10.8273 19.5969 11.1953 19.7758 11.5959ZM14.0466 18.9363C14.4214 18.7815 14.7619 18.5528 15.049 18.2657C15.3362 17.9785 15.5648 17.6381 15.7196 17.2615C15.8743 16.8867 15.9552 16.4843 15.9552 16.0785V12.2442C15.954 12.2407 15.9529 12.2367 15.9517 12.2321C15.9506 12.2287 15.9488 12.2252 15.9466 12.2218C15.9443 12.2184 15.9414 12.2155 15.938 12.2132C15.9345 12.2098 15.9311 12.2075 15.9276 12.2063L14.54 11.4051V16.0373C14.54 16.0837 14.5332 16.1318 14.5211 16.1765C14.5091 16.223 14.4919 16.2659 14.4678 16.3072C14.4438 16.3485 14.4162 16.3863 14.3819 16.419C14.3484 16.4523 14.3109 16.4812 14.2701 16.505L10.9842 18.4015C10.9567 18.4187 10.9103 18.4428 10.8862 18.4565C11.0221 18.5717 11.1699 18.6732 11.3247 18.7626C11.4811 18.852 11.6428 18.9277 11.8113 18.9896C11.9798 19.0497 12.1535 19.0962 12.3288 19.1271C12.5059 19.1581 12.6848 19.1735 12.8636 19.1735C13.2694 19.1735 13.6717 19.0927 14.0466 18.9363ZM6.22135 16.333C6.42596 16.6855 6.69592 16.9916 7.01745 17.2392C7.34071 17.4868 7.70695 17.6673 8.09899 17.7722C8.49102 17.8771 8.90025 17.9046 9.3026 17.8513C9.70495 17.798 10.0918 17.6673 10.4443 17.4644L13.7663 15.5472L13.7749 15.5386C13.7772 15.5363 13.7789 15.5329 13.78 15.5283C13.7823 15.5249 13.7841 15.5214 13.7852 15.518V13.9017L9.77545 16.2212C9.73418 16.2453 9.6912 16.2625 9.64649 16.2763C9.60007 16.2883 9.55364 16.2935 9.5055 16.2935C9.45907 16.2935 9.41265 16.2883 9.36622 16.2763C9.32152 16.2625 9.27681 16.2453 9.23554 16.2212L5.94967 14.323C5.92044 14.3058 5.87746 14.28 5.85339 14.2645C5.82244 14.4416 5.80696 14.6204 5.80696 14.7993C5.80696 14.9781 5.82415 15.1569 5.85511 15.334C5.88605 15.5094 5.9342 15.6831 5.99438 15.8516C6.05628 16.0201 6.13194 16.1817 6.22135 16.3364V16.333ZM5.35818 9.1629C5.15529 9.51539 5.02461 9.90398 4.97131 10.3063C4.918 10.7087 4.94552 11.1162 5.0504 11.51C5.15529 11.902 5.33583 12.2682 5.58343 12.5915C5.83103 12.913 6.13881 13.183 6.48958 13.3859L9.80984 15.3048C9.81328 15.3059 9.81729 15.3071 9.82188 15.3082H9.83391C9.8385 15.3082 9.84251 15.3071 9.84595 15.3048C9.84939 15.3036 9.85283 15.3019 9.85627 15.2996L11.249 14.4949L7.23926 12.1805C7.19971 12.1565 7.16189 12.1272 7.1275 12.0946C7.09418 12.0611 7.06529 12.0236 7.04153 11.9828C7.01917 11.9415 7.00026 11.8985 6.98822 11.8521C6.97619 11.8074 6.96931 11.761 6.97103 11.7128V7.80797C6.80252 7.86987 6.63917 7.94553 6.48442 8.03494C6.32967 8.12607 6.18352 8.22924 6.04596 8.34444C5.91013 8.45965 5.78289 8.58688 5.66769 8.72444C5.55248 8.86028 5.45103 9.00815 5.36162 9.1629H5.35818ZM16.7633 11.8177C16.8046 11.8418 16.8424 11.8693 16.8768 11.9037C16.9094 11.9364 16.9387 11.9742 16.9628 12.0155C16.9851 12.0567 17.004 12.1014 17.0161 12.1461C17.0264 12.1926 17.0332 12.239 17.0315 12.2871V16.192C17.5835 15.9891 18.0649 15.6332 18.4208 15.1655C18.7785 14.6978 18.9934 14.139 19.0433 13.5544C19.0931 12.9698 18.9762 12.3817 18.7046 11.8607C18.4329 11.3397 18.0185 10.9064 17.5095 10.6141L14.1893 8.69521C14.1858 8.69406 14.1818 8.69292 14.1772 8.69177H14.1652C14.1618 8.69292 14.1578 8.69406 14.1532 8.69521C14.1497 8.69636 14.1463 8.69808 14.1429 8.70037L12.757 9.50163L16.7667 11.8177H16.7633ZM18.1475 9.7372H18.1457V9.73892L18.1475 9.7372ZM18.1457 9.73548C18.2455 9.15774 18.1784 8.56281 17.9514 8.02119C17.7262 7.47956 17.3496 7.01359 16.8682 6.67658C16.3867 6.34128 15.8193 6.1487 15.233 6.12291C14.6449 6.09884 14.0638 6.24155 13.5548 6.53386L10.2345 8.45105C10.2311 8.45334 10.2282 8.45621 10.2259 8.45965L10.2191 8.46996C10.2179 8.4734 10.2168 8.47741 10.2156 8.482C10.2145 8.48544 10.2139 8.48945 10.2139 8.49403V10.0966L14.2237 7.78046C14.2649 7.75639 14.3096 7.7392 14.3543 7.72544C14.4008 7.7134 14.4472 7.70825 14.4936 7.70825C14.5418 7.70825 14.5882 7.7134 14.6346 7.72544C14.6793 7.7392 14.7223 7.75639 14.7636 7.78046L18.0494 9.67874C18.0787 9.69593 18.1217 9.72 18.1457 9.73548ZM9.45735 7.96101C9.45735 7.91458 9.46423 7.86816 9.47627 7.82173C9.4883 7.77702 9.5055 7.73232 9.52957 7.69105C9.55364 7.6515 9.58115 7.61368 9.61554 7.57929C9.64821 7.54662 9.68604 7.51739 9.72731 7.49503L13.0132 5.59848C13.0441 5.57957 13.0871 5.55549 13.1112 5.54346C12.6607 5.1669 12.1105 4.92618 11.5276 4.85224C10.9447 4.77658 10.3532 4.86943 9.82188 5.11875C9.28885 5.36807 8.83835 5.76527 8.52369 6.26047C8.20903 6.75739 8.04224 7.33169 8.04224 7.91974V11.7541C8.04339 11.7587 8.04454 11.7627 8.04568 11.7661C8.04683 11.7696 8.04855 11.773 8.05084 11.7765C8.05313 11.7799 8.056 11.7833 8.05944 11.7868C8.06173 11.7891 8.06517 11.7914 8.06976 11.7937L9.45735 12.5949V7.96101ZM10.2105 13.0282L11.997 14.0599L13.7835 13.0282V10.9666L11.9987 9.93493L10.2122 10.9666L10.2105 13.0282Z", - "fill": "white" - }, - "children": [] - } - ] - }, - "name": "OpenaiTeal" -} diff --git a/web/app/components/base/icons/src/public/llm/OpenaiText.json b/web/app/components/base/icons/src/public/llm/OpenaiText.json index f5fc3de6b9..469aacf9d3 100644 --- a/web/app/components/base/icons/src/public/llm/OpenaiText.json +++ b/web/app/components/base/icons/src/public/llm/OpenaiText.json @@ -74,4 +74,4 @@ ] }, "name": "OpenaiText" -} +} \ No newline at end of file diff --git a/web/app/components/base/icons/src/public/llm/OpenaiTransparent.json b/web/app/components/base/icons/src/public/llm/OpenaiTransparent.json index 13b9cb4905..00a410dce0 100644 --- a/web/app/components/base/icons/src/public/llm/OpenaiTransparent.json +++ b/web/app/components/base/icons/src/public/llm/OpenaiTransparent.json @@ -23,4 +23,4 @@ ] }, "name": "OpenaiTransparent" -} +} \ No newline at end of file diff --git a/web/app/components/base/icons/src/public/llm/OpenaiViolet.json b/web/app/components/base/icons/src/public/llm/OpenaiViolet.json index efff2feacf..927699bec2 100644 --- a/web/app/components/base/icons/src/public/llm/OpenaiViolet.json +++ b/web/app/components/base/icons/src/public/llm/OpenaiViolet.json @@ -34,4 +34,4 @@ ] }, "name": "OpenaiViolet" -} +} \ No newline at end of file diff --git a/web/app/components/base/icons/src/public/llm/OpenaiYellow.json b/web/app/components/base/icons/src/public/llm/OpenaiYellow.json deleted file mode 100644 index d0a4f10744..0000000000 --- a/web/app/components/base/icons/src/public/llm/OpenaiYellow.json +++ /dev/null @@ -1,37 +0,0 @@ -{ - "icon": { - "type": "element", - "isRootNode": true, - "name": "svg", - "attributes": { - "width": "24", - "height": "24", - "viewBox": "0 0 24 24", - "fill": "none", - "xmlns": "http://www.w3.org/2000/svg" - }, - "children": [ - { - "type": "element", - "name": "rect", - "attributes": { - "width": "24", - "height": "24", - "rx": "6", - "fill": "#FAB005" - }, - "children": [] - }, - { - "type": "element", - "name": "path", - "attributes": { - "d": "M19.7758 11.5959C19.9546 11.9948 20.0681 12.4213 20.1145 12.8563C20.1592 13.2913 20.1369 13.7315 20.044 14.1596C19.9529 14.5878 19.7947 14.9987 19.5746 15.377C19.4302 15.6298 19.2599 15.867 19.0639 16.0854C18.8696 16.3021 18.653 16.4981 18.4174 16.67C18.1801 16.842 17.9274 16.9864 17.6591 17.105C17.3926 17.222 17.1141 17.3114 16.8286 17.3698C16.6945 17.7859 16.4951 18.1797 16.2371 18.5339C15.9809 18.8881 15.6697 19.1993 15.3155 19.4555C14.9613 19.7134 14.5693 19.9129 14.1532 20.047C13.7371 20.1829 13.302 20.2499 12.8636 20.2499C12.573 20.2516 12.2807 20.2207 11.9953 20.1622C11.7116 20.102 11.433 20.0109 11.1665 19.8923C10.9 19.7736 10.6472 19.6258 10.4116 19.4538C10.1778 19.2819 9.96115 19.0841 9.76857 18.8658C9.33871 18.9586 8.89853 18.981 8.46351 18.9363C8.02849 18.8898 7.60207 18.7763 7.20143 18.5975C6.80252 18.4204 6.43284 18.1797 6.10786 17.8857C5.78289 17.5916 5.50606 17.2478 5.28769 16.8695C5.14153 16.6167 5.02117 16.3502 4.93004 16.0734C4.83891 15.7965 4.77873 15.5111 4.74778 15.2205C4.71683 14.9317 4.71855 14.6393 4.7495 14.3488C4.78045 14.0599 4.84407 13.7745 4.9352 13.4976C4.64289 13.1727 4.40217 12.803 4.22335 12.4041C4.04624 12.0034 3.93104 11.5787 3.88634 11.1437C3.83991 10.7087 3.86398 10.2685 3.95511 9.84036C4.04624 9.41222 4.20443 9.00127 4.42452 8.62299C4.56896 8.37023 4.73918 8.13123 4.93348 7.91458C5.12778 7.69793 5.34615 7.50191 5.58171 7.32997C5.81728 7.15802 6.07176 7.01187 6.33827 6.89495C6.6065 6.7763 6.88506 6.68861 7.17048 6.63015C7.3046 6.21232 7.50406 5.82029 7.76026 5.46608C8.01817 5.11188 8.32939 4.80066 8.6836 4.54274C9.03781 4.28654 9.42984 4.08708 9.84595 3.95125C10.2621 3.81713 10.6971 3.74835 11.1355 3.75007C11.4261 3.74835 11.7184 3.77758 12.0039 3.83776C12.2893 3.89794 12.5678 3.98736 12.8344 4.106C13.1009 4.22636 13.3536 4.37251 13.5892 4.54446C13.8248 4.71812 14.0414 4.91414 14.234 5.13251C14.6621 5.04138 15.1023 5.01903 15.5373 5.06373C15.9723 5.10844 16.3971 5.22364 16.7977 5.40074C17.1966 5.57957 17.5663 5.81857 17.8913 6.1126C18.2162 6.4049 18.4931 6.74707 18.7114 7.12707C18.8576 7.37811 18.9779 7.64463 19.0691 7.92318C19.1602 8.20001 19.2221 8.48544 19.2513 8.77602C19.2823 9.06661 19.2823 9.35892 19.2496 9.64951C19.2187 9.94009 19.155 10.2255 19.0639 10.5024C19.3579 10.8273 19.5969 11.1953 19.7758 11.5959ZM14.0466 18.9363C14.4214 18.7815 14.7619 18.5528 15.049 18.2657C15.3362 17.9785 15.5648 17.6381 15.7196 17.2615C15.8743 16.8867 15.9552 16.4843 15.9552 16.0785V12.2442C15.954 12.2407 15.9529 12.2367 15.9517 12.2321C15.9506 12.2287 15.9488 12.2252 15.9466 12.2218C15.9443 12.2184 15.9414 12.2155 15.938 12.2132C15.9345 12.2098 15.9311 12.2075 15.9276 12.2063L14.54 11.4051V16.0373C14.54 16.0837 14.5332 16.1318 14.5211 16.1765C14.5091 16.223 14.4919 16.2659 14.4678 16.3072C14.4438 16.3485 14.4162 16.3863 14.3819 16.419C14.3484 16.4523 14.3109 16.4812 14.2701 16.505L10.9842 18.4015C10.9567 18.4187 10.9103 18.4428 10.8862 18.4565C11.0221 18.5717 11.1699 18.6732 11.3247 18.7626C11.4811 18.852 11.6428 18.9277 11.8113 18.9896C11.9798 19.0497 12.1535 19.0962 12.3288 19.1271C12.5059 19.1581 12.6848 19.1735 12.8636 19.1735C13.2694 19.1735 13.6717 19.0927 14.0466 18.9363ZM6.22135 16.333C6.42596 16.6855 6.69592 16.9916 7.01745 17.2392C7.34071 17.4868 7.70695 17.6673 8.09899 17.7722C8.49102 17.8771 8.90025 17.9046 9.3026 17.8513C9.70495 17.798 10.0918 17.6673 10.4443 17.4644L13.7663 15.5472L13.7749 15.5386C13.7772 15.5363 13.7789 15.5329 13.78 15.5283C13.7823 15.5249 13.7841 15.5214 13.7852 15.518V13.9017L9.77545 16.2212C9.73418 16.2453 9.6912 16.2625 9.64649 16.2763C9.60007 16.2883 9.55364 16.2935 9.5055 16.2935C9.45907 16.2935 9.41265 16.2883 9.36622 16.2763C9.32152 16.2625 9.27681 16.2453 9.23554 16.2212L5.94967 14.323C5.92044 14.3058 5.87746 14.28 5.85339 14.2645C5.82244 14.4416 5.80696 14.6204 5.80696 14.7993C5.80696 14.9781 5.82415 15.1569 5.85511 15.334C5.88605 15.5094 5.9342 15.6831 5.99438 15.8516C6.05628 16.0201 6.13194 16.1817 6.22135 16.3364V16.333ZM5.35818 9.1629C5.15529 9.51539 5.02461 9.90398 4.97131 10.3063C4.918 10.7087 4.94552 11.1162 5.0504 11.51C5.15529 11.902 5.33583 12.2682 5.58343 12.5915C5.83103 12.913 6.13881 13.183 6.48958 13.3859L9.80984 15.3048C9.81328 15.3059 9.81729 15.3071 9.82188 15.3082H9.83391C9.8385 15.3082 9.84251 15.3071 9.84595 15.3048C9.84939 15.3036 9.85283 15.3019 9.85627 15.2996L11.249 14.4949L7.23926 12.1805C7.19971 12.1565 7.16189 12.1272 7.1275 12.0946C7.09418 12.0611 7.06529 12.0236 7.04153 11.9828C7.01917 11.9415 7.00026 11.8985 6.98822 11.8521C6.97619 11.8074 6.96931 11.761 6.97103 11.7128V7.80797C6.80252 7.86987 6.63917 7.94553 6.48442 8.03494C6.32967 8.12607 6.18352 8.22924 6.04596 8.34444C5.91013 8.45965 5.78289 8.58688 5.66769 8.72444C5.55248 8.86028 5.45103 9.00815 5.36162 9.1629H5.35818ZM16.7633 11.8177C16.8046 11.8418 16.8424 11.8693 16.8768 11.9037C16.9094 11.9364 16.9387 11.9742 16.9628 12.0155C16.9851 12.0567 17.004 12.1014 17.0161 12.1461C17.0264 12.1926 17.0332 12.239 17.0315 12.2871V16.192C17.5835 15.9891 18.0649 15.6332 18.4208 15.1655C18.7785 14.6978 18.9934 14.139 19.0433 13.5544C19.0931 12.9698 18.9762 12.3817 18.7046 11.8607C18.4329 11.3397 18.0185 10.9064 17.5095 10.6141L14.1893 8.69521C14.1858 8.69406 14.1818 8.69292 14.1772 8.69177H14.1652C14.1618 8.69292 14.1578 8.69406 14.1532 8.69521C14.1497 8.69636 14.1463 8.69808 14.1429 8.70037L12.757 9.50163L16.7667 11.8177H16.7633ZM18.1475 9.7372H18.1457V9.73892L18.1475 9.7372ZM18.1457 9.73548C18.2455 9.15774 18.1784 8.56281 17.9514 8.02119C17.7262 7.47956 17.3496 7.01359 16.8682 6.67658C16.3867 6.34128 15.8193 6.1487 15.233 6.12291C14.6449 6.09884 14.0638 6.24155 13.5548 6.53386L10.2345 8.45105C10.2311 8.45334 10.2282 8.45621 10.2259 8.45965L10.2191 8.46996C10.2179 8.4734 10.2168 8.47741 10.2156 8.482C10.2145 8.48544 10.2139 8.48945 10.2139 8.49403V10.0966L14.2237 7.78046C14.2649 7.75639 14.3096 7.7392 14.3543 7.72544C14.4008 7.7134 14.4472 7.70825 14.4936 7.70825C14.5418 7.70825 14.5882 7.7134 14.6346 7.72544C14.6793 7.7392 14.7223 7.75639 14.7636 7.78046L18.0494 9.67874C18.0787 9.69593 18.1217 9.72 18.1457 9.73548ZM9.45735 7.96101C9.45735 7.91458 9.46423 7.86816 9.47627 7.82173C9.4883 7.77702 9.5055 7.73232 9.52957 7.69105C9.55364 7.6515 9.58115 7.61368 9.61554 7.57929C9.64821 7.54662 9.68604 7.51739 9.72731 7.49503L13.0132 5.59848C13.0441 5.57957 13.0871 5.55549 13.1112 5.54346C12.6607 5.1669 12.1105 4.92618 11.5276 4.85224C10.9447 4.77658 10.3532 4.86943 9.82188 5.11875C9.28885 5.36807 8.83835 5.76527 8.52369 6.26047C8.20903 6.75739 8.04224 7.33169 8.04224 7.91974V11.7541C8.04339 11.7587 8.04454 11.7627 8.04568 11.7661C8.04683 11.7696 8.04855 11.773 8.05084 11.7765C8.05313 11.7799 8.056 11.7833 8.05944 11.7868C8.06173 11.7891 8.06517 11.7914 8.06976 11.7937L9.45735 12.5949V7.96101ZM10.2105 13.0282L11.997 14.0599L13.7835 13.0282V10.9666L11.9987 9.93493L10.2122 10.9666L10.2105 13.0282Z", - "fill": "white" - }, - "children": [] - } - ] - }, - "name": "OpenaiYellow" -} diff --git a/web/app/components/base/icons/src/public/llm/OpenaiYellow.tsx b/web/app/components/base/icons/src/public/llm/OpenaiYellow.tsx deleted file mode 100644 index 77dac7e322..0000000000 --- a/web/app/components/base/icons/src/public/llm/OpenaiYellow.tsx +++ /dev/null @@ -1,20 +0,0 @@ -// GENERATE BY script -// DON NOT EDIT IT MANUALLY - -import * as React from 'react' -import data from './OpenaiYellow.json' -import IconBase from '@/app/components/base/icons/IconBase' -import type { IconData } from '@/app/components/base/icons/IconBase' - -const Icon = ( - { - ref, - ...props - }: React.SVGProps & { - ref?: React.RefObject>; - }, -) => - -Icon.displayName = 'OpenaiYellow' - -export default Icon diff --git a/web/app/components/base/icons/src/public/llm/Openllm.json b/web/app/components/base/icons/src/public/llm/Openllm.json index 93eec11dfe..1c71fa9c6f 100644 --- a/web/app/components/base/icons/src/public/llm/Openllm.json +++ b/web/app/components/base/icons/src/public/llm/Openllm.json @@ -80,4 +80,4 @@ ] }, "name": "Openllm" -} +} \ No newline at end of file diff --git a/web/app/components/base/icons/src/public/llm/OpenllmText.json b/web/app/components/base/icons/src/public/llm/OpenllmText.json index d5705de10e..ad5179e9ee 100644 --- a/web/app/components/base/icons/src/public/llm/OpenllmText.json +++ b/web/app/components/base/icons/src/public/llm/OpenllmText.json @@ -140,4 +140,4 @@ ] }, "name": "OpenllmText" -} +} \ No newline at end of file diff --git a/web/app/components/base/icons/src/public/llm/Replicate.json b/web/app/components/base/icons/src/public/llm/Replicate.json index 303c239193..089d111eef 100644 --- a/web/app/components/base/icons/src/public/llm/Replicate.json +++ b/web/app/components/base/icons/src/public/llm/Replicate.json @@ -36,4 +36,4 @@ ] }, "name": "Replicate" -} +} \ No newline at end of file diff --git a/web/app/components/base/icons/src/public/llm/ReplicateText.json b/web/app/components/base/icons/src/public/llm/ReplicateText.json index b2d597c2ed..c163ccbe74 100644 --- a/web/app/components/base/icons/src/public/llm/ReplicateText.json +++ b/web/app/components/base/icons/src/public/llm/ReplicateText.json @@ -113,4 +113,4 @@ ] }, "name": "ReplicateText" -} +} \ No newline at end of file diff --git a/web/app/components/base/icons/src/public/llm/XorbitsInference.json b/web/app/components/base/icons/src/public/llm/XorbitsInference.json index b2d3b1a072..fae25b37f9 100644 --- a/web/app/components/base/icons/src/public/llm/XorbitsInference.json +++ b/web/app/components/base/icons/src/public/llm/XorbitsInference.json @@ -173,4 +173,4 @@ ] }, "name": "XorbitsInference" -} +} \ No newline at end of file diff --git a/web/app/components/base/icons/src/public/llm/XorbitsInferenceText.json b/web/app/components/base/icons/src/public/llm/XorbitsInferenceText.json index 967ee6d6c4..b8dac91644 100644 --- a/web/app/components/base/icons/src/public/llm/XorbitsInferenceText.json +++ b/web/app/components/base/icons/src/public/llm/XorbitsInferenceText.json @@ -326,4 +326,4 @@ ] }, "name": "XorbitsInferenceText" -} +} \ No newline at end of file diff --git a/web/app/components/base/icons/src/public/llm/Zhipuai.json b/web/app/components/base/icons/src/public/llm/Zhipuai.json index 87955688a5..7f93c634d0 100644 --- a/web/app/components/base/icons/src/public/llm/Zhipuai.json +++ b/web/app/components/base/icons/src/public/llm/Zhipuai.json @@ -50,4 +50,4 @@ ] }, "name": "Zhipuai" -} +} \ No newline at end of file diff --git a/web/app/components/base/icons/src/public/llm/ZhipuaiText.json b/web/app/components/base/icons/src/public/llm/ZhipuaiText.json index 12eb65a53a..455a60695c 100644 --- a/web/app/components/base/icons/src/public/llm/ZhipuaiText.json +++ b/web/app/components/base/icons/src/public/llm/ZhipuaiText.json @@ -41,4 +41,4 @@ ] }, "name": "ZhipuaiText" -} +} \ No newline at end of file diff --git a/web/app/components/base/icons/src/public/llm/ZhipuaiTextCn.json b/web/app/components/base/icons/src/public/llm/ZhipuaiTextCn.json index c5b1755f0c..6002e07f6f 100644 --- a/web/app/components/base/icons/src/public/llm/ZhipuaiTextCn.json +++ b/web/app/components/base/icons/src/public/llm/ZhipuaiTextCn.json @@ -59,4 +59,4 @@ ] }, "name": "ZhipuaiTextCn" -} +} \ No newline at end of file diff --git a/web/app/components/base/icons/src/public/llm/index.ts b/web/app/components/base/icons/src/public/llm/index.ts index fa4a1bdd10..cc9b531ebf 100644 --- a/web/app/components/base/icons/src/public/llm/index.ts +++ b/web/app/components/base/icons/src/public/llm/index.ts @@ -28,11 +28,9 @@ export { default as Microsoft } from './Microsoft' export { default as OpenaiBlack } from './OpenaiBlack' export { default as OpenaiBlue } from './OpenaiBlue' export { default as OpenaiGreen } from './OpenaiGreen' -export { default as OpenaiTeal } from './OpenaiTeal' export { default as OpenaiText } from './OpenaiText' export { default as OpenaiTransparent } from './OpenaiTransparent' export { default as OpenaiViolet } from './OpenaiViolet' -export { default as OpenaiYellow } from './OpenaiYellow' export { default as OpenllmText } from './OpenllmText' export { default as Openllm } from './Openllm' export { default as ReplicateText } from './ReplicateText' diff --git a/web/app/components/base/icons/src/public/model/Checked.json b/web/app/components/base/icons/src/public/model/Checked.json index 7e96db728f..f8ea944818 100644 --- a/web/app/components/base/icons/src/public/model/Checked.json +++ b/web/app/components/base/icons/src/public/model/Checked.json @@ -26,4 +26,4 @@ ] }, "name": "Checked" -} +} \ No newline at end of file diff --git a/web/app/components/base/icons/src/public/other/DefaultToolIcon.json b/web/app/components/base/icons/src/public/other/DefaultToolIcon.json index 32786d2281..32412e8d01 100644 --- a/web/app/components/base/icons/src/public/other/DefaultToolIcon.json +++ b/web/app/components/base/icons/src/public/other/DefaultToolIcon.json @@ -78,4 +78,4 @@ ] }, "name": "DefaultToolIcon" -} +} \ No newline at end of file diff --git a/web/app/components/base/icons/src/public/other/Icon3Dots.json b/web/app/components/base/icons/src/public/other/Icon3Dots.json index b59b293cec..9c6d232839 100644 --- a/web/app/components/base/icons/src/public/other/Icon3Dots.json +++ b/web/app/components/base/icons/src/public/other/Icon3Dots.json @@ -26,4 +26,4 @@ ] }, "name": "Icon3Dots" -} +} \ No newline at end of file diff --git a/web/app/components/base/icons/src/public/other/Message3Fill.json b/web/app/components/base/icons/src/public/other/Message3Fill.json index ae84890abc..250ce5cdea 100644 --- a/web/app/components/base/icons/src/public/other/Message3Fill.json +++ b/web/app/components/base/icons/src/public/other/Message3Fill.json @@ -170,4 +170,4 @@ ] }, "name": "Message3Fill" -} +} \ No newline at end of file diff --git a/web/app/components/base/icons/src/public/other/RowStruct.json b/web/app/components/base/icons/src/public/other/RowStruct.json index 49ef71753c..0d1ef43f4f 100644 --- a/web/app/components/base/icons/src/public/other/RowStruct.json +++ b/web/app/components/base/icons/src/public/other/RowStruct.json @@ -53,4 +53,4 @@ ] }, "name": "RowStruct" -} +} \ No newline at end of file diff --git a/web/app/components/base/icons/src/public/plugins/Google.json b/web/app/components/base/icons/src/public/plugins/Google.json index 198050e04c..6f04dddb9b 100644 --- a/web/app/components/base/icons/src/public/plugins/Google.json +++ b/web/app/components/base/icons/src/public/plugins/Google.json @@ -50,4 +50,4 @@ ] }, "name": "Google" -} +} \ No newline at end of file diff --git a/web/app/components/base/icons/src/public/plugins/PartnerDark.json b/web/app/components/base/icons/src/public/plugins/PartnerDark.json index af3f2083e4..37135d4b21 100644 --- a/web/app/components/base/icons/src/public/plugins/PartnerDark.json +++ b/web/app/components/base/icons/src/public/plugins/PartnerDark.json @@ -444,4 +444,4 @@ ] }, "name": "PartnerDark" -} +} \ No newline at end of file diff --git a/web/app/components/base/icons/src/public/plugins/PartnerLight.json b/web/app/components/base/icons/src/public/plugins/PartnerLight.json index 3d7391bcaa..f726fca7d8 100644 --- a/web/app/components/base/icons/src/public/plugins/PartnerLight.json +++ b/web/app/components/base/icons/src/public/plugins/PartnerLight.json @@ -443,4 +443,4 @@ ] }, "name": "PartnerLight" -} +} \ No newline at end of file diff --git a/web/app/components/base/icons/src/public/plugins/VerifiedDark.json b/web/app/components/base/icons/src/public/plugins/VerifiedDark.json index ed228262b5..4da3a28a74 100644 --- a/web/app/components/base/icons/src/public/plugins/VerifiedDark.json +++ b/web/app/components/base/icons/src/public/plugins/VerifiedDark.json @@ -454,4 +454,4 @@ ] }, "name": "VerifiedDark" -} +} \ No newline at end of file diff --git a/web/app/components/base/icons/src/public/plugins/VerifiedLight.json b/web/app/components/base/icons/src/public/plugins/VerifiedLight.json index b31fe655b3..b41bdb72e1 100644 --- a/web/app/components/base/icons/src/public/plugins/VerifiedLight.json +++ b/web/app/components/base/icons/src/public/plugins/VerifiedLight.json @@ -453,4 +453,4 @@ ] }, "name": "VerifiedLight" -} +} \ No newline at end of file diff --git a/web/app/components/base/icons/src/public/plugins/WebReader.json b/web/app/components/base/icons/src/public/plugins/WebReader.json index 58c828309c..42ec3d9e78 100644 --- a/web/app/components/base/icons/src/public/plugins/WebReader.json +++ b/web/app/components/base/icons/src/public/plugins/WebReader.json @@ -36,4 +36,4 @@ ] }, "name": "WebReader" -} +} \ No newline at end of file diff --git a/web/app/components/base/icons/src/public/plugins/Wikipedia.json b/web/app/components/base/icons/src/public/plugins/Wikipedia.json index af2d505c85..7a16433be7 100644 --- a/web/app/components/base/icons/src/public/plugins/Wikipedia.json +++ b/web/app/components/base/icons/src/public/plugins/Wikipedia.json @@ -23,4 +23,4 @@ ] }, "name": "Wikipedia" -} +} \ No newline at end of file diff --git a/web/app/components/base/icons/src/public/thought/DataSet.json b/web/app/components/base/icons/src/public/thought/DataSet.json index 5be61dac9d..55952fe9d2 100644 --- a/web/app/components/base/icons/src/public/thought/DataSet.json +++ b/web/app/components/base/icons/src/public/thought/DataSet.json @@ -61,4 +61,4 @@ ] }, "name": "DataSet" -} +} \ No newline at end of file diff --git a/web/app/components/base/icons/src/public/thought/Loading.json b/web/app/components/base/icons/src/public/thought/Loading.json index 23e68662c4..f19a3b1009 100644 --- a/web/app/components/base/icons/src/public/thought/Loading.json +++ b/web/app/components/base/icons/src/public/thought/Loading.json @@ -61,4 +61,4 @@ ] }, "name": "Loading" -} +} \ No newline at end of file diff --git a/web/app/components/base/icons/src/public/thought/Search.json b/web/app/components/base/icons/src/public/thought/Search.json index 1ad8876bcc..9213419bbc 100644 --- a/web/app/components/base/icons/src/public/thought/Search.json +++ b/web/app/components/base/icons/src/public/thought/Search.json @@ -61,4 +61,4 @@ ] }, "name": "Search" -} +} \ No newline at end of file diff --git a/web/app/components/base/icons/src/public/thought/ThoughtList.json b/web/app/components/base/icons/src/public/thought/ThoughtList.json index d5e13c339f..8b97633444 100644 --- a/web/app/components/base/icons/src/public/thought/ThoughtList.json +++ b/web/app/components/base/icons/src/public/thought/ThoughtList.json @@ -80,4 +80,4 @@ ] }, "name": "ThoughtList" -} +} \ No newline at end of file diff --git a/web/app/components/base/icons/src/public/thought/WebReader.json b/web/app/components/base/icons/src/public/thought/WebReader.json index ba2bc485f0..ecf85d9ec9 100644 --- a/web/app/components/base/icons/src/public/thought/WebReader.json +++ b/web/app/components/base/icons/src/public/thought/WebReader.json @@ -61,4 +61,4 @@ ] }, "name": "WebReader" -} +} \ No newline at end of file diff --git a/web/app/components/base/icons/src/public/tracing/LangfuseIcon.json b/web/app/components/base/icons/src/public/tracing/LangfuseIcon.json index c2c8a73112..ab0b8fbc1c 100644 --- a/web/app/components/base/icons/src/public/tracing/LangfuseIcon.json +++ b/web/app/components/base/icons/src/public/tracing/LangfuseIcon.json @@ -233,4 +233,4 @@ ] }, "name": "LangfuseIcon" -} +} \ No newline at end of file diff --git a/web/app/components/base/icons/src/public/tracing/LangfuseIconBig.json b/web/app/components/base/icons/src/public/tracing/LangfuseIconBig.json index 8172de6cf6..0fee622bd8 100644 --- a/web/app/components/base/icons/src/public/tracing/LangfuseIconBig.json +++ b/web/app/components/base/icons/src/public/tracing/LangfuseIconBig.json @@ -233,4 +233,4 @@ ] }, "name": "LangfuseIconBig" -} +} \ No newline at end of file diff --git a/web/app/components/base/icons/src/public/tracing/LangsmithIcon.json b/web/app/components/base/icons/src/public/tracing/LangsmithIcon.json index 293c4bfd18..04d480bd20 100644 --- a/web/app/components/base/icons/src/public/tracing/LangsmithIcon.json +++ b/web/app/components/base/icons/src/public/tracing/LangsmithIcon.json @@ -185,4 +185,4 @@ ] }, "name": "LangsmithIcon" -} +} \ No newline at end of file diff --git a/web/app/components/base/icons/src/public/tracing/LangsmithIconBig.json b/web/app/components/base/icons/src/public/tracing/LangsmithIconBig.json index 18b1761e7f..4aa76acc8d 100644 --- a/web/app/components/base/icons/src/public/tracing/LangsmithIconBig.json +++ b/web/app/components/base/icons/src/public/tracing/LangsmithIconBig.json @@ -185,4 +185,4 @@ ] }, "name": "LangsmithIconBig" -} +} \ No newline at end of file diff --git a/web/app/components/base/icons/src/public/tracing/OpikIcon.json b/web/app/components/base/icons/src/public/tracing/OpikIcon.json index c9f3ad7985..5bab796c78 100644 --- a/web/app/components/base/icons/src/public/tracing/OpikIcon.json +++ b/web/app/components/base/icons/src/public/tracing/OpikIcon.json @@ -160,4 +160,4 @@ ] }, "name": "OpikIcon" -} +} \ No newline at end of file diff --git a/web/app/components/base/icons/src/public/tracing/OpikIconBig.json b/web/app/components/base/icons/src/public/tracing/OpikIconBig.json index 44e1e2c521..1372a92c0e 100644 --- a/web/app/components/base/icons/src/public/tracing/OpikIconBig.json +++ b/web/app/components/base/icons/src/public/tracing/OpikIconBig.json @@ -159,4 +159,4 @@ ] }, "name": "OpikIconBig" -} +} \ No newline at end of file diff --git a/web/app/components/base/icons/src/public/tracing/TracingIcon.json b/web/app/components/base/icons/src/public/tracing/TracingIcon.json index 2157a08fa3..508b555b0f 100644 --- a/web/app/components/base/icons/src/public/tracing/TracingIcon.json +++ b/web/app/components/base/icons/src/public/tracing/TracingIcon.json @@ -44,4 +44,4 @@ ] }, "name": "TracingIcon" -} +} \ No newline at end of file diff --git a/web/app/components/base/icons/src/public/tracing/WeaveIcon.json b/web/app/components/base/icons/src/public/tracing/WeaveIcon.json index 1a96e70b6e..141727a643 100644 --- a/web/app/components/base/icons/src/public/tracing/WeaveIcon.json +++ b/web/app/components/base/icons/src/public/tracing/WeaveIcon.json @@ -276,4 +276,4 @@ ] }, "name": "WeaveIcon" -} +} \ No newline at end of file diff --git a/web/app/components/base/icons/src/public/tracing/WeaveIcon.tsx b/web/app/components/base/icons/src/public/tracing/WeaveIcon.tsx index fd66bd79ae..9261604bfe 100644 --- a/web/app/components/base/icons/src/public/tracing/WeaveIcon.tsx +++ b/web/app/components/base/icons/src/public/tracing/WeaveIcon.tsx @@ -4,12 +4,16 @@ import * as React from 'react' import data from './WeaveIcon.json' import IconBase from '@/app/components/base/icons/IconBase' -import type { IconBaseProps, IconData } from '@/app/components/base/icons/IconBase' +import type { IconData } from '@/app/components/base/icons/IconBase' -const Icon = React.forwardRef, Omit>(( - props, - ref, -) => ) +const Icon = ( + { + ref, + ...props + }: React.SVGProps & { + ref?: React.RefObject>; + }, +) => Icon.displayName = 'WeaveIcon' diff --git a/web/app/components/base/icons/src/public/tracing/WeaveIconBig.json b/web/app/components/base/icons/src/public/tracing/WeaveIconBig.json index 5557e237e0..29be86f9a2 100644 --- a/web/app/components/base/icons/src/public/tracing/WeaveIconBig.json +++ b/web/app/components/base/icons/src/public/tracing/WeaveIconBig.json @@ -276,4 +276,4 @@ ] }, "name": "WeaveIconBig" -} +} \ No newline at end of file diff --git a/web/app/components/base/icons/src/public/tracing/WeaveIconBig.tsx b/web/app/components/base/icons/src/public/tracing/WeaveIconBig.tsx index 1d2bb9fcc2..79267467db 100644 --- a/web/app/components/base/icons/src/public/tracing/WeaveIconBig.tsx +++ b/web/app/components/base/icons/src/public/tracing/WeaveIconBig.tsx @@ -4,12 +4,16 @@ import * as React from 'react' import data from './WeaveIconBig.json' import IconBase from '@/app/components/base/icons/IconBase' -import type { IconBaseProps, IconData } from '@/app/components/base/icons/IconBase' +import type { IconData } from '@/app/components/base/icons/IconBase' -const Icon = React.forwardRef, Omit>(( - props, - ref, -) => ) +const Icon = ( + { + ref, + ...props + }: React.SVGProps & { + ref?: React.RefObject>; + }, +) => Icon.displayName = 'WeaveIconBig' diff --git a/web/app/components/base/icons/src/vender/system/AutoUpdateLine.json b/web/app/components/base/icons/src/vender/system/AutoUpdateLine.json new file mode 100644 index 0000000000..1821d9bfd7 --- /dev/null +++ b/web/app/components/base/icons/src/vender/system/AutoUpdateLine.json @@ -0,0 +1,37 @@ +{ + "icon": { + "type": "element", + "isRootNode": true, + "name": "svg", + "attributes": { + "width": "24", + "height": "24", + "viewBox": "0 0 24 24", + "fill": "none", + "xmlns": "http://www.w3.org/2000/svg" + }, + "children": [ + { + "type": "element", + "name": "path", + "attributes": { + "d": "M5.46257 4.43262C7.21556 2.91688 9.5007 2 12 2C17.5228 2 22 6.47715 22 12C22 14.1361 21.3302 16.1158 20.1892 17.7406L17 12H20C20 7.58172 16.4183 4 12 4C9.84982 4 7.89777 4.84827 6.46023 6.22842L5.46257 4.43262ZM18.5374 19.5674C16.7844 21.0831 14.4993 22 12 22C6.47715 22 2 17.5228 2 12C2 9.86386 2.66979 7.88416 3.8108 6.25944L7 12H4C4 16.4183 7.58172 20 12 20C14.1502 20 16.1022 19.1517 17.5398 17.7716L18.5374 19.5674Z", + "fill": "currentColor" + }, + "children": [] + }, + { + "type": "element", + "name": "path", + "attributes": { + "fill-rule": "evenodd", + "clip-rule": "evenodd", + "d": "M16.3308 16H14.2915L13.6249 13.9476H10.3761L9.70846 16H7.66918L10.7759 7H13.2281L16.3308 16ZM10.8595 12.4622H13.1435L12.0378 9.05639H11.9673L10.8595 12.4622Z", + "fill": "currentColor" + }, + "children": [] + } + ] + }, + "name": "AutoUpdateLine" +} \ No newline at end of file diff --git a/web/app/components/base/icons/src/public/llm/OpenaiTeal.tsx b/web/app/components/base/icons/src/vender/system/AutoUpdateLine.tsx similarity index 85% rename from web/app/components/base/icons/src/public/llm/OpenaiTeal.tsx rename to web/app/components/base/icons/src/vender/system/AutoUpdateLine.tsx index ab50b42a1e..d162edaa5a 100644 --- a/web/app/components/base/icons/src/public/llm/OpenaiTeal.tsx +++ b/web/app/components/base/icons/src/vender/system/AutoUpdateLine.tsx @@ -2,7 +2,7 @@ // DON NOT EDIT IT MANUALLY import * as React from 'react' -import data from './OpenaiTeal.json' +import data from './AutoUpdateLine.json' import IconBase from '@/app/components/base/icons/IconBase' import type { IconData } from '@/app/components/base/icons/IconBase' @@ -15,6 +15,6 @@ const Icon = ( }, ) => -Icon.displayName = 'OpenaiTeal' +Icon.displayName = 'AutoUpdateLine' export default Icon diff --git a/web/app/components/base/icons/src/vender/system/index.ts b/web/app/components/base/icons/src/vender/system/index.ts new file mode 100644 index 0000000000..01553789b8 --- /dev/null +++ b/web/app/components/base/icons/src/vender/system/index.ts @@ -0,0 +1 @@ +export { default as AutoUpdateLine } from './AutoUpdateLine' diff --git a/web/app/components/plugins/plugin-detail-panel/detail-header.tsx b/web/app/components/plugins/plugin-detail-panel/detail-header.tsx index 7548c90ac5..7fcbad408c 100644 --- a/web/app/components/plugins/plugin-detail-panel/detail-header.tsx +++ b/web/app/components/plugins/plugin-detail-panel/detail-header.tsx @@ -35,6 +35,8 @@ import { useProviderContext } from '@/context/provider-context' import { useInvalidateAllToolProviders } from '@/service/use-tools' import { API_PREFIX, MARKETPLACE_URL_PREFIX } from '@/config' import cn from '@/utils/classnames' +import { AutoUpdateLine } from '../../base/icons/src/vender/system' +import { timeOfDayToDayjs } from '../reference-setting-modal/auto-update-setting/utils' const i18nPrefix = 'plugin.action' @@ -205,6 +207,15 @@ const DetailHeader = ({ /> } /> + {/* Auto update info */} + + {/* add a a div to fix tooltip hover not show problem */} +
    + + + +
    +
    {(hasNewVersion || isFromGitHub) && (
    ) } diff --git a/web/app/components/plugins/update-plugin/plugin-version-picker.tsx b/web/app/components/plugins/update-plugin/plugin-version-picker.tsx index 424f76d790..36a4faace1 100644 --- a/web/app/components/plugins/update-plugin/plugin-version-picker.tsx +++ b/web/app/components/plugins/update-plugin/plugin-version-picker.tsx @@ -15,6 +15,7 @@ import type { import { useVersionListOfPlugin } from '@/service/use-plugins' import useTimestamp from '@/hooks/use-timestamp' import cn from '@/utils/classnames' +import { lt } from 'semver' type Props = { disabled?: boolean @@ -28,9 +29,11 @@ type Props = { onSelect: ({ version, unique_identifier, + isDowngrade, }: { version: string unique_identifier: string + isDowngrade: boolean }) => void } @@ -59,13 +62,14 @@ const PluginVersionPicker: FC = ({ const { data: res } = useVersionListOfPlugin(pluginID) - const handleSelect = useCallback(({ version, unique_identifier }: { + const handleSelect = useCallback(({ version, unique_identifier, isDowngrade }: { version: string unique_identifier: string + isDowngrade: boolean }) => { if (currentVersion === version) return - onSelect({ version, unique_identifier }) + onSelect({ version, unique_identifier, isDowngrade }) onShowChange(false) }, [currentVersion, onSelect, onShowChange]) @@ -99,6 +103,7 @@ const PluginVersionPicker: FC = ({ onClick={() => handleSelect({ version: version.version, unique_identifier: version.unique_identifier, + isDowngrade: lt(version.version, currentVersion), })} >
    From c6fa8102eba47df67cedb2ca53a13c001a0c5903 Mon Sep 17 00:00:00 2001 From: Joel Date: Tue, 24 Jun 2025 15:36:10 +0800 Subject: [PATCH 12/29] feat: downgrade modal --- .../plugin-detail-panel/detail-header.tsx | 16 +++++--- .../update-plugin/downgrade-warning-modal.tsx | 37 +++++++++++++++++++ 2 files changed, 47 insertions(+), 6 deletions(-) create mode 100644 web/app/components/plugins/update-plugin/downgrade-warning-modal.tsx diff --git a/web/app/components/plugins/plugin-detail-panel/detail-header.tsx b/web/app/components/plugins/plugin-detail-panel/detail-header.tsx index 0f9e2b9ea3..a1f049f134 100644 --- a/web/app/components/plugins/plugin-detail-panel/detail-header.tsx +++ b/web/app/components/plugins/plugin-detail-panel/detail-header.tsx @@ -37,6 +37,7 @@ import { API_PREFIX, MARKETPLACE_URL_PREFIX } from '@/config' import cn from '@/utils/classnames' import { AutoUpdateLine } from '../../base/icons/src/vender/system' import { timeOfDayToDayjs } from '../reference-setting-modal/auto-update-setting/utils' +import DowngradeWarningModal from '../update-plugin/downgrade-warning-modal' const i18nPrefix = 'plugin.action' @@ -77,7 +78,6 @@ const DetailHeader = ({ const [targetVersion, setTargetVersion] = useState({ version: latest_version, unique_identifier: latest_unique_identifier, - isDowngrade: false, }) const hasNewVersion = useMemo(() => { if (isFromMarketplace) @@ -105,9 +105,9 @@ const DetailHeader = ({ setFalse: hideDowngradeWarningModal, }] = useBoolean(false) - const handleUpdate = async () => { + const handleUpdate = async (isDowngrade?: boolean) => { if (isFromMarketplace) { - if(isAutoUpgradeEnabled && targetVersion.isDowngrade) { + if(isAutoUpgradeEnabled && isDowngrade) { showDowngradeWarningModal() return } @@ -198,7 +198,7 @@ const DetailHeader = ({ currentVersion={version} onSelect={(state) => { setTargetVersion(state) - handleUpdate() + handleUpdate(state.isDowngrade) }} trigger={ ) } - { isShowDowngradeWarningModal && (
    aaa
    )} + { isShowDowngradeWarningModal && ( + + )}
    ) } diff --git a/web/app/components/plugins/update-plugin/downgrade-warning-modal.tsx b/web/app/components/plugins/update-plugin/downgrade-warning-modal.tsx new file mode 100644 index 0000000000..fa5e90d182 --- /dev/null +++ b/web/app/components/plugins/update-plugin/downgrade-warning-modal.tsx @@ -0,0 +1,37 @@ +import { useTranslation } from 'react-i18next' +import Modal from '@/app/components/base/modal' +import Button from '@/app/components/base/button' + +type Props = { + onCancel: () => void + onSave: () => void + confirmDisabled?: boolean +} +const DowngradeWarningModal = ({ + onCancel, + onSave, + confirmDisabled = false, +}: Props) => { + const { t } = useTranslation() + + return ( + onCancel()} + className='w-[480px]' + > +
    +
    Plugin Downgrade
    +
    + Auto-update is currently enabled for this plugin. Downgrading the version may cause your changes to be overwritten during the next automatic update. +
    +
    +
    + + +
    +
    + ) +} + +export default DowngradeWarningModal From a0804786fdf3558170d2b02697a6ea036a8e6cc3 Mon Sep 17 00:00:00 2001 From: Joel Date: Tue, 24 Jun 2025 16:15:26 +0800 Subject: [PATCH 13/29] feat: downgrade modal i18n --- .../plugin-detail-panel/detail-header.tsx | 10 +++++++- .../update-plugin/downgrade-warning-modal.tsx | 25 +++++++++++-------- web/i18n/en-US/plugin.ts | 6 +++++ web/i18n/zh-Hans/plugin.ts | 7 ++++++ 4 files changed, 36 insertions(+), 12 deletions(-) diff --git a/web/app/components/plugins/plugin-detail-panel/detail-header.tsx b/web/app/components/plugins/plugin-detail-panel/detail-header.tsx index a1f049f134..cb5d623460 100644 --- a/web/app/components/plugins/plugin-detail-panel/detail-header.tsx +++ b/web/app/components/plugins/plugin-detail-panel/detail-header.tsx @@ -146,6 +146,13 @@ const DetailHeader = ({ const handleUpdatedFromMarketplace = () => { onUpdate() hideUpdateModal() + hideDowngradeWarningModal() + } + + const handleExcludeAndDownload = async () => { + // TODO: exclude logic + onUpdate() + hideDowngradeWarningModal() } const [isShowPluginInfo, { @@ -330,7 +337,8 @@ const DetailHeader = ({ { isShowDowngradeWarningModal && ( )}
    diff --git a/web/app/components/plugins/update-plugin/downgrade-warning-modal.tsx b/web/app/components/plugins/update-plugin/downgrade-warning-modal.tsx index fa5e90d182..9443a349ba 100644 --- a/web/app/components/plugins/update-plugin/downgrade-warning-modal.tsx +++ b/web/app/components/plugins/update-plugin/downgrade-warning-modal.tsx @@ -2,15 +2,17 @@ import { useTranslation } from 'react-i18next' import Modal from '@/app/components/base/modal' import Button from '@/app/components/base/button' +const i18nPrefix = 'plugin.autoUpdate.pluginDowngradeWarning' + type Props = { onCancel: () => void - onSave: () => void - confirmDisabled?: boolean + onJustDowngrade: () => void + onExcludeAndDowngrade: () => void } const DowngradeWarningModal = ({ onCancel, - onSave, - confirmDisabled = false, + onJustDowngrade, + onExcludeAndDowngrade, }: Props) => { const { t } = useTranslation() @@ -18,17 +20,18 @@ const DowngradeWarningModal = ({ onCancel()} - className='w-[480px]' + className='w-[640px] max-w-[640px]' > -
    -
    Plugin Downgrade
    -
    - Auto-update is currently enabled for this plugin. Downgrading the version may cause your changes to be overwritten during the next automatic update. +
    +
    {t(`${i18nPrefix}.title`)}
    +
    + {t(`${i18nPrefix}.description`)}
    -
    +
    - + +
    ) diff --git a/web/i18n/en-US/plugin.ts b/web/i18n/en-US/plugin.ts index 9915046454..4befade891 100644 --- a/web/i18n/en-US/plugin.ts +++ b/web/i18n/en-US/plugin.ts @@ -144,6 +144,12 @@ const translation = { partial: 'Only selected plugins will auto-update. No plugins are currently selected, so no plugins will auto-update.', }, nextUpdateTime: 'Next auto-update: {{time}}', + pluginDowngradeWarning: { + title: 'Plugin Downgrade', + description: 'Auto-update is currently enabled for this plugin. Downgrading the version may cause your changes to be overwritten during the next automatic update.', + downgrade: 'Downgrade anyway', + exclude: 'Exclude from auto-update', + }, }, pluginInfoModal: { title: 'Plugin info', diff --git a/web/i18n/zh-Hans/plugin.ts b/web/i18n/zh-Hans/plugin.ts index 1384e979ab..47cf534b57 100644 --- a/web/i18n/zh-Hans/plugin.ts +++ b/web/i18n/zh-Hans/plugin.ts @@ -143,6 +143,13 @@ const translation = { exclude: '选定的插件将不会自动更新', partial: '仅选定的插件将自动更新。目前未选择任何插件,因此不会自动更新任何插件。', }, + nextUpdateTime: '下次自动更新时间: {{time}}', + pluginDowngradeWarning: { + title: '插件降级', + description: '此插件目前已启用自动更新。降级版本可能会导致您的更改在下次自动更新时被覆盖。', + downgrade: '仍然降级', + exclude: '从自动更新中排除', + }, }, pluginInfoModal: { title: '插件信息', From 2f241d932c81dba2bf680e595de52dc93ee7741e Mon Sep 17 00:00:00 2001 From: Joel Date: Tue, 24 Jun 2025 16:29:54 +0800 Subject: [PATCH 14/29] chore: temp i18n --- .../auto-update-setting/plugins-picker.tsx | 9 +++++++-- web/i18n/en-US/plugin.ts | 6 ++++++ 2 files changed, 13 insertions(+), 2 deletions(-) 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.tsx index ce5104764e..fbddcc1f60 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,10 +2,13 @@ import type { FC } from 'react' import React from 'react' import NoPluginSelected from './no-plugin-selected' -import type { AUTO_UPDATE_MODE } from './types' +import { AUTO_UPDATE_MODE } from './types' import PluginsSelected from './plugins-selected' import Button from '@/app/components/base/button' import { RiAddLine } from '@remixicon/react' +import { useTranslation } from 'react-i18next' + +const i18nPrefix = 'plugin.autoUpdate' type Props = { updateMode: AUTO_UPDATE_MODE @@ -18,12 +21,14 @@ const PluginsPicker: FC = ({ value, onChange, }) => { + const { t } = useTranslation() const hasSelected = value.length > 0 + const isExcludeMode = updateMode === AUTO_UPDATE_MODE.exclude return (
    {hasSelected ? (
    -
    The following 21 plugins will not auto-update
    +
    {t(`${i18nPrefix}.${isExcludeMode ? 'excludeUpdate' : 'partialUPdate'}`, { num: value.length })}
    Clear all
    ) : ( diff --git a/web/i18n/en-US/plugin.ts b/web/i18n/en-US/plugin.ts index 4befade891..069c00103b 100644 --- a/web/i18n/en-US/plugin.ts +++ b/web/i18n/en-US/plugin.ts @@ -143,6 +143,12 @@ const translation = { exclude: 'Selected plugins will not auto-update', partial: 'Only selected plugins will auto-update. No plugins are currently selected, so no plugins will auto-update.', }, + excludeUpdate: 'The following {{num}} plugins will not auto-update', + partialUPdate: 'Only the following {{num}} plugins will auto-update', + operation: { + clearAll: 'Clear all', + select: 'Select plugins', + }, nextUpdateTime: 'Next auto-update: {{time}}', pluginDowngradeWarning: { title: 'Plugin Downgrade', From 93a560ee5481cb008727b546346fbb8c2e928dd6 Mon Sep 17 00:00:00 2001 From: Joel Date: Wed, 25 Jun 2025 16:45:21 +0800 Subject: [PATCH 15/29] chore: ui and clear --- .../auto-update-setting/plugins-picker.tsx | 17 +++++++++++------ web/i18n/zh-Hans/plugin.ts | 6 ++++++ 2 files changed, 17 insertions(+), 6 deletions(-) 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.tsx index fbddcc1f60..7523259318 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 @@ -24,25 +24,30 @@ const PluginsPicker: FC = ({ const { t } = useTranslation() const hasSelected = value.length > 0 const isExcludeMode = updateMode === AUTO_UPDATE_MODE.exclude + const handleClear = () => { + onChange([]) + } return (
    {hasSelected ? (
    {t(`${i18nPrefix}.${isExcludeMode ? 'excludeUpdate' : 'partialUPdate'}`, { num: value.length })}
    -
    Clear all
    +
    {t(`${i18nPrefix}.operation.clearAll`)}
    ) : ( )} - + {hasSelected && ( + + )}
    ) diff --git a/web/i18n/zh-Hans/plugin.ts b/web/i18n/zh-Hans/plugin.ts index 47cf534b57..efae760fcc 100644 --- a/web/i18n/zh-Hans/plugin.ts +++ b/web/i18n/zh-Hans/plugin.ts @@ -143,6 +143,12 @@ const translation = { exclude: '选定的插件将不会自动更新', partial: '仅选定的插件将自动更新。目前未选择任何插件,因此不会自动更新任何插件。', }, + excludeUpdate: '以下 {{num}} 个插件将不会自动更新', + partialUPdate: '仅以下 {{num}} 个插件将自动更新', + operation: { + clearAll: '清除所有', + select: '选择插件', + }, nextUpdateTime: '下次自动更新时间: {{time}}', pluginDowngradeWarning: { title: '插件降级', From 1ff5969b92bf3dd44717512de0c7e785bae49dfd Mon Sep 17 00:00:00 2001 From: Joel Date: Wed, 25 Jun 2025 17:41:33 +0800 Subject: [PATCH 16/29] feat: select tool template --- .../auto-update-setting/plugins-picker.tsx | 22 +++++++-- .../auto-update-setting/tool-picker.tsx | 47 +++++++++++++++++++ 2 files changed, 65 insertions(+), 4 deletions(-) create mode 100644 web/app/components/plugins/reference-setting-modal/auto-update-setting/tool-picker.tsx 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.tsx index 7523259318..d7c8c31043 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 @@ -7,6 +7,8 @@ import PluginsSelected from './plugins-selected' import Button from '@/app/components/base/button' import { RiAddLine } from '@remixicon/react' import { useTranslation } from 'react-i18next' +import { useBoolean } from 'ahooks' +import ToolPicker from './tool-picker' const i18nPrefix = 'plugin.autoUpdate' @@ -27,6 +29,10 @@ const PluginsPicker: FC = ({ const handleClear = () => { onChange([]) } + + const [isShowToolPicker, { + set: setToolPicker, + }] = useBoolean(false) return (
    {hasSelected ? ( @@ -45,10 +51,18 @@ const PluginsPicker: FC = ({ /> )} - + + + {t(`${i18nPrefix}.operation.select`)} + + } + value={value} + onChange={onChange} + isShow={isShowToolPicker} + onShowChange={setToolPicker} + />
    ) } 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.tsx new file mode 100644 index 0000000000..5bcadcc3d4 --- /dev/null +++ b/web/app/components/plugins/reference-setting-modal/auto-update-setting/tool-picker.tsx @@ -0,0 +1,47 @@ +'use client' +import type { FC } from 'react' +import React, { useCallback } from 'react' +import { + PortalToFollowElem, + PortalToFollowElemContent, + PortalToFollowElemTrigger, +} from '@/app/components/base/portal-to-follow-elem' + +type Props = { + trigger: React.ReactNode + value: string[] + onChange: (value: string[]) => void + isShow: boolean + onShowChange: (isShow: boolean) => void + +} + +const ToolPicker: FC = ({ + trigger, + value, + onChange, + isShow, + onShowChange, +}) => { + const toggleShowPopup = useCallback(() => { + onShowChange(!isShow) + }, [onShowChange, isShow]) + return ( + + + {trigger} + + +
    aafdf
    +
    +
    + ) +} +export default React.memo(ToolPicker) From c43d992f2b7054810b7752bc49c2646a7be5ed67 Mon Sep 17 00:00:00 2001 From: Joel Date: Wed, 25 Jun 2025 18:40:12 +0800 Subject: [PATCH 17/29] feat: fetch plugin list --- .../auto-update-setting/tool-picker.tsx | 16 ++++++++- web/service/use-plugins.ts | 33 +++++++++++++++++++ 2 files changed, 48 insertions(+), 1 deletion(-) 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.tsx index 5bcadcc3d4..9f96e4a7aa 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,11 +1,13 @@ 'use client' import type { FC } from 'react' -import React, { useCallback } from 'react' +import React, { useCallback, useState } from 'react' import { PortalToFollowElem, PortalToFollowElemContent, PortalToFollowElemTrigger, } from '@/app/components/base/portal-to-follow-elem' +import { useFetchPluginListOrBundleList } from '@/service/use-plugins' +import { PLUGIN_TYPE_SEARCH_MAP } from '../../marketplace/plugin-type-switch' type Props = { trigger: React.ReactNode @@ -16,6 +18,8 @@ type Props = { } +const allPluginTypes = [PLUGIN_TYPE_SEARCH_MAP.all, PLUGIN_TYPE_SEARCH_MAP.model, PLUGIN_TYPE_SEARCH_MAP.tool, PLUGIN_TYPE_SEARCH_MAP.agent, PLUGIN_TYPE_SEARCH_MAP.extension, PLUGIN_TYPE_SEARCH_MAP.bundle] + const ToolPicker: FC = ({ trigger, value, @@ -26,6 +30,16 @@ const ToolPicker: FC = ({ const toggleShowPopup = useCallback(() => { onShowChange(!isShow) }, [onShowChange, isShow]) + + const [pluginType, setPluginType] = useState(PLUGIN_TYPE_SEARCH_MAP.all) + const [query, setQuery] = useState('') + const { data } = useFetchPluginListOrBundleList({ + query, + category: pluginType, + }) + const isBundle = pluginType === PLUGIN_TYPE_SEARCH_MAP.bundle + const list = (isBundle ? data?.data?.bundles : data?.data?.plugins) || [] + console.log(list) return ( { + return useQuery({ + queryKey: [NAME_SPACE, 'fetchPluginListOrBundleList', pluginsSearchParams], + queryFn: () => { + const { + query, + sortBy, + sortOrder, + category, + tags, + exclude, + type, + page = 1, + pageSize = 40, + } = pluginsSearchParams + const pluginOrBundle = type === 'bundle' ? 'bundles' : 'plugins' + return postMarketplace<{ data: PluginsFromMarketplaceResponse }>(`/${pluginOrBundle}/search/advanced`, { + body: { + page, + page_size: pageSize, + query, + sort_by: sortBy, + sort_order: sortOrder, + category: category !== 'all' ? category : '', + tags, + exclude, + type, + }, + }) + }, + }) +} + export const useFetchPluginsInMarketPlaceByInfo = (infos: Record[]) => { return useQuery({ queryKey: [NAME_SPACE, 'fetchPluginsInMarketPlaceByInfo', infos], From 52b845a5bbfdf3b3ed5c2c0e1fa55109daddd45a Mon Sep 17 00:00:00 2001 From: Joel Date: Thu, 26 Jun 2025 10:48:11 +0800 Subject: [PATCH 18/29] feat: select box setting --- .../plugins/marketplace/search-box/index.tsx | 90 +++++++++++-------- .../marketplace/search-box/tags-filter.tsx | 50 ++--------- .../auto-update-setting/tool-picker.tsx | 73 +++++++++++++-- 3 files changed, 131 insertions(+), 82 deletions(-) diff --git a/web/app/components/plugins/marketplace/search-box/index.tsx b/web/app/components/plugins/marketplace/search-box/index.tsx index 217007846c..5f19afbba6 100644 --- a/web/app/components/plugins/marketplace/search-box/index.tsx +++ b/web/app/components/plugins/marketplace/search-box/index.tsx @@ -1,8 +1,9 @@ 'use client' -import { RiCloseLine } from '@remixicon/react' +import { RiCloseLine, RiSearchLine } from '@remixicon/react' import TagsFilter from './tags-filter' import ActionButton from '@/app/components/base/action-button' import cn from '@/utils/classnames' +import { RiAddLine } from '@remixicon/react' type SearchBoxProps = { search: string @@ -13,6 +14,9 @@ type SearchBoxProps = { size?: 'small' | 'large' placeholder?: string locale?: string + supportAddCustomTool?: boolean + onShowAddCustomCollectionModal?: () => void + onAddedCustomTool?: () => void } const SearchBox = ({ search, @@ -23,46 +27,62 @@ const SearchBox = ({ size = 'small', placeholder = '', locale, + supportAddCustomTool, + onShowAddCustomCollectionModal, }: SearchBoxProps) => { return (
    - -
    -
    -
    - { - onSearchChange(e.target.value) - }} - placeholder={placeholder} - /> - { - search && ( -
    - onSearchChange('')}> - - -
    - ) - } +
    +
    +
    + + { + onSearchChange(e.target.value) + }} + placeholder={placeholder} + /> + { + search && ( +
    + onSearchChange('')}> + + +
    + ) + } +
    +
    +
    + {supportAddCustomTool && ( +
    + + + +
    + )}
    ) } diff --git a/web/app/components/plugins/marketplace/search-box/tags-filter.tsx b/web/app/components/plugins/marketplace/search-box/tags-filter.tsx index edf50dc874..bae6491727 100644 --- a/web/app/components/plugins/marketplace/search-box/tags-filter.tsx +++ b/web/app/components/plugins/marketplace/search-box/tags-filter.tsx @@ -2,9 +2,7 @@ import { useState } from 'react' import { - RiArrowDownSLine, - RiCloseCircleFill, - RiFilter3Line, + RiPriceTag3Line, } from '@remixicon/react' import { PortalToFollowElem, @@ -57,47 +55,15 @@ const TagsFilter = ({ onClick={() => setOpen(v => !v)} >
    -
    - +
    +
    -
    - { - !selectedTagsLength && t('pluginTags.allTags') - } - { - !!selectedTagsLength && tags.map(tag => tagsMap[tag].label).slice(0, 2).join(',') - } - { - selectedTagsLength > 2 && ( -
    - +{selectedTagsLength - 2} -
    - ) - } -
    - { - !!selectedTagsLength && ( - onTagsChange([])} - /> - ) - } - { - !selectedTagsLength && ( - - ) - }
    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.tsx index 9f96e4a7aa..5108bb7b96 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 @@ -8,9 +8,12 @@ import { } from '@/app/components/base/portal-to-follow-elem' import { useFetchPluginListOrBundleList } from '@/service/use-plugins' import { PLUGIN_TYPE_SEARCH_MAP } from '../../marketplace/plugin-type-switch' +import SearchBox from '@/app/components/plugins/marketplace/search-box' +import { useTranslation } from 'react-i18next' +import cn from '@/utils/classnames' type Props = { - trigger: React.ReactNode + trigger: React.ReactNode value: string[] onChange: (value: string[]) => void isShow: boolean @@ -18,8 +21,6 @@ type Props = { } -const allPluginTypes = [PLUGIN_TYPE_SEARCH_MAP.all, PLUGIN_TYPE_SEARCH_MAP.model, PLUGIN_TYPE_SEARCH_MAP.tool, PLUGIN_TYPE_SEARCH_MAP.agent, PLUGIN_TYPE_SEARCH_MAP.extension, PLUGIN_TYPE_SEARCH_MAP.bundle] - const ToolPicker: FC = ({ trigger, value, @@ -27,24 +28,55 @@ const ToolPicker: FC = ({ isShow, onShowChange, }) => { + const { t } = useTranslation() const toggleShowPopup = useCallback(() => { onShowChange(!isShow) }, [onShowChange, isShow]) + const tabs = [ + { + key: PLUGIN_TYPE_SEARCH_MAP.all, + name: t('plugin.category.all'), + }, + { + key: PLUGIN_TYPE_SEARCH_MAP.model, + name: t('plugin.category.models'), + }, + { + key: PLUGIN_TYPE_SEARCH_MAP.tool, + name: t('plugin.category.tools'), + }, + { + key: PLUGIN_TYPE_SEARCH_MAP.agent, + name: t('plugin.category.agents'), + }, + { + key: PLUGIN_TYPE_SEARCH_MAP.extension, + name: t('plugin.category.extensions'), + }, + { + key: PLUGIN_TYPE_SEARCH_MAP.bundle, + name: t('plugin.category.bundles'), + }, + ] + const [pluginType, setPluginType] = useState(PLUGIN_TYPE_SEARCH_MAP.all) const [query, setQuery] = useState('') + const [tags, setTags] = useState([]) const { data } = useFetchPluginListOrBundleList({ query, + tags, category: pluginType, }) const isBundle = pluginType === PLUGIN_TYPE_SEARCH_MAP.bundle const list = (isBundle ? data?.data?.bundles : data?.data?.plugins) || [] + console.log(list) return ( = ({ {trigger} -
    aafdf
    +
    +
    + +
    +
    +
    + { + tabs.map(tab => ( +
    setPluginType(tab.key)} + > + {tab.name} +
    + )) + } +
    +
    +
    ) From 4c583f3d9afd5c187901410b5f68a39fcf78575c Mon Sep 17 00:00:00 2001 From: Joel Date: Thu, 26 Jun 2025 15:31:50 +0800 Subject: [PATCH 19/29] feat: can select plugins --- .../auto-update-setting/config.ts | 4 +- .../auto-update-setting/plugins-picker.tsx | 2 +- .../auto-update-setting/plugins-selected.tsx | 16 +++---- .../auto-update-setting/tool-item.tsx | 44 +++++++++++++++++++ .../auto-update-setting/tool-picker.tsx | 29 +++++++++--- .../plugins/reference-setting-modal/modal.tsx | 4 +- 6 files changed, 80 insertions(+), 19 deletions(-) create mode 100644 web/app/components/plugins/reference-setting-modal/auto-update-setting/tool-item.tsx diff --git a/web/app/components/plugins/reference-setting-modal/auto-update-setting/config.ts b/web/app/components/plugins/reference-setting-modal/auto-update-setting/config.ts index a247061200..384a3db086 100644 --- a/web/app/components/plugins/reference-setting-modal/auto-update-setting/config.ts +++ b/web/app/components/plugins/reference-setting-modal/auto-update-setting/config.ts @@ -4,6 +4,6 @@ export const defaultValue: AutoUpdateConfig = { strategy_setting: AUTO_UPDATE_STRATEGY.fixOnly, // For test upgrade_time_of_day: 0, upgrade_mode: AUTO_UPDATE_MODE.exclude, // For test - exclude_plugins: ['a', 'c'], - include_plugins: ['b'], + exclude_plugins: ['langgenius/openai_api_compatible', 'langgenius/openai', 'langgenius/openai', 'langgenius/openai', 'langgenius/openai', 'langgenius/openai', 'langgenius/openai', 'langgenius/openai', 'langgenius/openai', 'langgenius/openai', 'langgenius/openai', 'langgenius/openai', 'langgenius/openai', 'langgenius/openai', 'langgenius/openai', 'langgenius/openai', 'langgenius/openai', 'langgenius/openai', 'langgenius/openai', 'langgenius/openai', 'langgenius/openai', 'langgenius/openai', 'langgenius/openai', 'langgenius/openai', 'langgenius/openai', 'langgenius/openai', 'langgenius/openai', 'langgenius/openai'], + include_plugins: ['langgenius/openai'], } 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.tsx index d7c8c31043..77ffd66670 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 @@ -53,7 +53,7 @@ const PluginsPicker: FC = ({ + 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.tsx index 8bdf97c668..42c2a34ee8 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 @@ -2,6 +2,8 @@ import type { FC } from 'react' import React from 'react' import cn from '@/utils/classnames' +import { MARKETPLACE_API_PREFIX } from '@/config' +import Icon from '@/app/components/plugins/card/base/card-icon' const MAX_DISPLAY_COUNT = 14 type Props = { @@ -14,17 +16,13 @@ const PluginsSelected: FC = ({ plugins, }) => { const isShowAll = plugins.length < MAX_DISPLAY_COUNT - const displayPlugins = isShowAll ? plugins.slice(0, MAX_DISPLAY_COUNT) : plugins + const displayPlugins = plugins.slice(0, MAX_DISPLAY_COUNT) return ( -
    - {displayPlugins.map((plugin, index) => ( -
    -
    +
    + {displayPlugins.map(plugin => ( + ))} - {!isShowAll &&
    +{plugins.length - MAX_DISPLAY_COUNT}
    } + {!isShowAll &&
    +{plugins.length - MAX_DISPLAY_COUNT}
    }
    ) } 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.tsx new file mode 100644 index 0000000000..f60faa734f --- /dev/null +++ b/web/app/components/plugins/reference-setting-modal/auto-update-setting/tool-item.tsx @@ -0,0 +1,44 @@ +'use client' +import type { FC } from 'react' +import React from 'react' +import type { Plugin } from '@/app/components/plugins/types' +import Icon from '@/app/components/plugins/card/base/card-icon' +import { renderI18nObject } from '@/i18n' +import { useGetLanguage } from '@/context/i18n' +import { MARKETPLACE_API_PREFIX } from '@/config' +import Checkbox from '@/app/components/base/checkbox' + +type Props = { + payload: Plugin + isChecked?: boolean + onCheckChange: () => void +} + +const ToolItem: FC = ({ + payload, + isChecked, + onCheckChange, +}) => { + const language = useGetLanguage() + + const { plugin_id, label, org } = payload + return ( +
    +
    +
    + +
    {renderI18nObject(label, language)}
    +
    {org}
    +
    + +
    +
    + ) +} +export default React.memo(ToolItem) 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.tsx index 5108bb7b96..0c3fa83cf0 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 @@ -11,6 +11,7 @@ import { PLUGIN_TYPE_SEARCH_MAP } from '../../marketplace/plugin-type-switch' import SearchBox from '@/app/components/plugins/marketplace/search-box' import { useTranslation } from 'react-i18next' import cn from '@/utils/classnames' +import ToolItem from './tool-item' type Props = { trigger: React.ReactNode @@ -70,13 +71,19 @@ const ToolPicker: FC = ({ }) const isBundle = pluginType === PLUGIN_TYPE_SEARCH_MAP.bundle const list = (isBundle ? data?.data?.bundles : data?.data?.plugins) || [] - - console.log(list) + const handleCheckChange = useCallback((pluginId: string) => { + return () => { + const newValue = value.includes(pluginId) + ? value.filter(id => id !== pluginId) + : [...value, pluginId] + onChange(newValue) + } + }, [onChange, value]) return ( = ({ {trigger} -
    +
    = ({ }
    + {list.length > 0 && ( +
    + {list.map(item => ( + + ))} +
    + )}
    diff --git a/web/app/components/plugins/reference-setting-modal/modal.tsx b/web/app/components/plugins/reference-setting-modal/modal.tsx index 3f2b645292..0bf12cb2b5 100644 --- a/web/app/components/plugins/reference-setting-modal/modal.tsx +++ b/web/app/components/plugins/reference-setting-modal/modal.tsx @@ -51,9 +51,9 @@ const PluginSettingModal: FC = ({ isShow onClose={onHide} closable - className='w-[420px] !p-0' + className='w-[480px] !p-0' > -
    +
    {t(`${i18nPrefix}.title`)}
    From 3e8a4a66fe2bf7e26b4f94c8c8ec89d8251dbdef Mon Sep 17 00:00:00 2001 From: Joel Date: Fri, 27 Jun 2025 09:55:25 +0800 Subject: [PATCH 20/29] feat: api to refernce settings --- .../install-bundle/steps/install.tsx | 2 +- .../components/plugins/plugin-page/index.tsx | 12 +++++----- ...permission.ts => use-reference-setting.ts} | 22 +++++++++-------- .../plugins/reference-setting-modal/modal.tsx | 13 +++++----- web/app/components/plugins/types.ts | 6 +++++ web/service/use-plugins.ts | 24 +++++++++---------- 6 files changed, 43 insertions(+), 36 deletions(-) rename web/app/components/plugins/plugin-page/{use-permission.ts => use-reference-setting.ts} (68%) 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.tsx index 2d8bdcd3d9..fabad62397 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 @@ -10,7 +10,7 @@ import type { ExposeRefs } from './install-multi' import InstallMulti from './install-multi' import { useInstallOrUpdate } from '@/service/use-plugins' import useRefreshPluginList from '../../hooks/use-refresh-plugin-list' -import { useCanInstallPluginFromMarketplace } from '@/app/components/plugins/plugin-page/use-permission' +import { useCanInstallPluginFromMarketplace } from '@/app/components/plugins/plugin-page/use-reference-setting' import { useMittContextSelector } from '@/context/mitt-context' import Checkbox from '@/app/components/base/checkbox' const i18nPrefix = 'plugin.installModal' diff --git a/web/app/components/plugins/plugin-page/index.tsx b/web/app/components/plugins/plugin-page/index.tsx index 78e60aa37b..a0734790b9 100644 --- a/web/app/components/plugins/plugin-page/index.tsx +++ b/web/app/components/plugins/plugin-page/index.tsx @@ -17,7 +17,7 @@ import { } from './context' import InstallPluginDropdown from './install-plugin-dropdown' import { useUploader } from './use-uploader' -import usePermission from './use-permission' +import useReferenceSetting from './use-reference-setting' import DebugInfo from './debug-info' import PluginTasks from './plugin-tasks' import Button from '@/app/components/base/button' @@ -121,12 +121,12 @@ const PluginPage = ({ }, [packageId, bundleInfo]) const { + referenceSetting, canManagement, canDebugger, canSetPermissions, - permissions, - setPermissions, - } = usePermission() + setReferenceSettings, + } = useReferenceSetting() const [showPluginSettingModal, { setTrue: setShowPluginSettingModal, setFalse: setHidePluginSettingModal, @@ -277,9 +277,9 @@ const PluginPage = ({ {showPluginSettingModal && ( )} diff --git a/web/app/components/plugins/plugin-page/use-permission.ts b/web/app/components/plugins/plugin-page/use-reference-setting.ts similarity index 68% rename from web/app/components/plugins/plugin-page/use-permission.ts rename to web/app/components/plugins/plugin-page/use-reference-setting.ts index 918813fb44..dbf5097c07 100644 --- a/web/app/components/plugins/plugin-page/use-permission.ts +++ b/web/app/components/plugins/plugin-page/use-reference-setting.ts @@ -2,7 +2,7 @@ import { PermissionType } from '../types' import { useAppContext } from '@/context/app-context' import Toast from '../../base/toast' import { useTranslation } from 'react-i18next' -import { useInvalidatePermissions, useMutationPermissions, usePermissions } from '@/service/use-plugins' +import { useInvalidateReferenceSettings, useMutationReferenceSettings, useReferenceSettings } from '@/service/use-plugins' import { useMemo } from 'react' import { useGlobalPublicStore } from '@/context/global-public-context' @@ -19,14 +19,16 @@ const hasPermission = (permission: PermissionType | undefined, isAdmin: boolean) return isAdmin } -const usePermission = () => { +const useReferenceSetting = () => { const { t } = useTranslation() const { isCurrentWorkspaceManager, isCurrentWorkspaceOwner } = useAppContext() - const { data: permissions } = usePermissions() - const invalidatePermissions = useInvalidatePermissions() - const { mutate: updatePermission, isPending: isUpdatePending } = useMutationPermissions({ + const { data } = useReferenceSettings() + // console.log(data) + const { permission: permissions } = data || {} + const invalidateReferenceSettings = useInvalidateReferenceSettings() + const { mutate: updateReferenceSetting, isPending: isUpdatePending } = useMutationReferenceSettings({ onSuccess: () => { - invalidatePermissions() + invalidateReferenceSettings() Toast.notify({ type: 'success', message: t('common.api.actionSuccess'), @@ -36,18 +38,18 @@ const usePermission = () => { const isAdmin = isCurrentWorkspaceManager || isCurrentWorkspaceOwner return { + referenceSetting: data, + setReferenceSettings: updateReferenceSetting, canManagement: hasPermission(permissions?.install_permission, isAdmin), canDebugger: hasPermission(permissions?.debug_permission, isAdmin), canSetPermissions: isAdmin, - permissions, - setPermissions: updatePermission, isUpdatePending, } } export const useCanInstallPluginFromMarketplace = () => { const { enable_marketplace } = useGlobalPublicStore(s => s.systemFeatures) - const { canManagement } = usePermission() + const { canManagement } = useReferenceSetting() const canInstallPluginFromMarketplace = useMemo(() => { return enable_marketplace && canManagement @@ -58,4 +60,4 @@ export const useCanInstallPluginFromMarketplace = () => { } } -export default usePermission +export default useReferenceSetting diff --git a/web/app/components/plugins/reference-setting-modal/modal.tsx b/web/app/components/plugins/reference-setting-modal/modal.tsx index 0bf12cb2b5..9fefbdbb55 100644 --- a/web/app/components/plugins/reference-setting-modal/modal.tsx +++ b/web/app/components/plugins/reference-setting-modal/modal.tsx @@ -5,19 +5,18 @@ import { useTranslation } from 'react-i18next' import Modal from '@/app/components/base/modal' import OptionCard from '@/app/components/workflow/nodes/_base/components/option-card' import Button from '@/app/components/base/button' -import type { Permissions } from '@/app/components/plugins/types' +import type { Permissions, ReferenceSetting } from '@/app/components/plugins/types' import { PermissionType } from '@/app/components/plugins/types' import type { AutoUpdateConfig } from './auto-update-setting/types' import AutoUpdateSetting from './auto-update-setting' import { defaultValue as autoUpdateDefaultValue } from './auto-update-setting/config' import Label from './label' -type Payload = Permissions & { autoUpdate: AutoUpdateConfig } const i18nPrefix = 'plugin.privilege' type Props = { - payload: Payload + payload: ReferenceSetting onHide: () => void - onSave: (payload: Payload) => void + onSave: (payload: ReferenceSetting) => void } const PluginSettingModal: FC = ({ @@ -26,7 +25,7 @@ const PluginSettingModal: FC = ({ onSave, }) => { const { t } = useTranslation() - const { autoUpdate: autoUpdateConfig, ...privilege } = payload || {} + const { auto_upgrade: autoUpdateConfig, permission: privilege } = payload || {} const [tempPrivilege, setTempPrivilege] = useState(privilege) const [tempAutoUpdateConfig, setTempAutoUpdateConfig] = useState(autoUpdateConfig || autoUpdateDefaultValue) const handlePrivilegeChange = useCallback((key: string) => { @@ -40,8 +39,8 @@ const PluginSettingModal: FC = ({ const handleSave = useCallback(async () => { await onSave({ - ...tempPrivilege, - autoUpdate: tempAutoUpdateConfig, + permission: tempPrivilege, + auto_upgrade: tempAutoUpdateConfig, }) onHide() }, [onHide, onSave, tempAutoUpdateConfig, tempPrivilege]) diff --git a/web/app/components/plugins/types.ts b/web/app/components/plugins/types.ts index ac62d77437..0479d5461a 100644 --- a/web/app/components/plugins/types.ts +++ b/web/app/components/plugins/types.ts @@ -2,6 +2,7 @@ import type { CredentialFormSchemaBase } from '../header/account-setting/model-p import type { ToolCredential } from '@/app/components/tools/types' import type { Locale } from '@/i18n' import type { AgentFeature } from '@/app/components/workflow/nodes/agent/types' +import type { AutoUpdateConfig } from './reference-setting-modal/auto-update-setting/types' export enum PluginType { tool = 'tool', model = 'model', @@ -167,6 +168,11 @@ export type Permissions = { debug_permission: PermissionType } +export type ReferenceSetting = { + permission: Permissions + auto_upgrade: AutoUpdateConfig +} + export type UpdateFromMarketPlacePayload = { category: PluginType originalPackageInfo: { diff --git a/web/service/use-plugins.ts b/web/service/use-plugins.ts index 57829ebd5c..802c1e6428 100644 --- a/web/service/use-plugins.ts +++ b/web/service/use-plugins.ts @@ -12,7 +12,6 @@ import type { InstalledLatestVersionResponse, InstalledPluginListWithTotalResponse, PackageDependency, - Permissions, Plugin, PluginDeclaration, PluginDetail, @@ -21,6 +20,7 @@ import type { PluginType, PluginsFromMarketplaceByInfoResponse, PluginsFromMarketplaceResponse, + ReferenceSetting, VersionInfo, VersionListResponse, uploadGitHubResponse, @@ -39,7 +39,7 @@ import { useQueryClient, } from '@tanstack/react-query' import { useInvalidateAllBuiltInTools } from './use-tools' -import usePermission from '@/app/components/plugins/plugin-page/use-permission' +import useReferenceSetting from '@/app/components/plugins/plugin-page/use-reference-setting' import { uninstallPlugin } from '@/service/plugins' import useRefreshPluginList from '@/app/components/plugins/install-plugin/hooks/use-refresh-plugin-list' import { cloneDeep } from 'lodash-es' @@ -349,32 +349,32 @@ export const useDebugKey = () => { }) } -const usePermissionsKey = [NAME_SPACE, 'permissions'] -export const usePermissions = () => { +const useReferenceSettingKey = [NAME_SPACE, 'referenceSettings'] +export const useReferenceSettings = () => { return useQuery({ - queryKey: usePermissionsKey, - queryFn: () => get('/workspaces/current/plugin/permission/fetch'), + queryKey: useReferenceSettingKey, + queryFn: () => get('/workspaces/current/plugin/preferences/fetch'), }) } -export const useInvalidatePermissions = () => { +export const useInvalidateReferenceSettings = () => { const queryClient = useQueryClient() return () => { queryClient.invalidateQueries( { - queryKey: usePermissionsKey, + queryKey: useReferenceSettingKey, }) } } -export const useMutationPermissions = ({ +export const useMutationReferenceSettings = ({ onSuccess, }: { onSuccess?: () => void }) => { return useMutation({ - mutationFn: (payload: Permissions) => { - return post('/workspaces/current/plugin/permission/change', { body: payload }) + mutationFn: (payload: ReferenceSetting) => { + return post('/workspaces/current/plugin/preferences/change', { body: payload }) }, onSuccess, }) @@ -480,7 +480,7 @@ const usePluginTaskListKey = [NAME_SPACE, 'pluginTaskList'] export const usePluginTaskList = (category?: PluginType) => { const { canManagement, - } = usePermission() + } = useReferenceSetting() const { refreshPluginList } = useRefreshPluginList() const { data, From d114485abddde0460fa266b5ed0c2422515dd173 Mon Sep 17 00:00:00 2001 From: Joel Date: Fri, 27 Jun 2025 10:10:02 +0800 Subject: [PATCH 21/29] feat: pluging loading --- .../auto-update-setting/tool-picker.tsx | 38 ++++++++++++------- 1 file changed, 25 insertions(+), 13 deletions(-) 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.tsx index 0c3fa83cf0..d8375f6aec 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 @@ -12,6 +12,7 @@ import SearchBox from '@/app/components/plugins/marketplace/search-box' import { useTranslation } from 'react-i18next' import cn from '@/utils/classnames' import ToolItem from './tool-item' +import Loading from '@/app/components/base/loading' type Props = { trigger: React.ReactNode @@ -64,7 +65,7 @@ const ToolPicker: FC = ({ const [pluginType, setPluginType] = useState(PLUGIN_TYPE_SEARCH_MAP.all) const [query, setQuery] = useState('') const [tags, setTags] = useState([]) - const { data } = useFetchPluginListOrBundleList({ + const { data, isLoading } = useFetchPluginListOrBundleList({ query, tags, category: pluginType, @@ -79,6 +80,26 @@ const ToolPicker: FC = ({ onChange(newValue) } }, [onChange, value]) + + const listContent = ( +
    + {list.map(item => ( + + ))} +
    + ) + + const loadingContent = ( +
    + +
    + ) + return ( = ({ }
    - {list.length > 0 && ( -
    - {list.map(item => ( - - ))} -
    - )} + {!isLoading && list.length > 0 && listContent} + {isLoading && loadingContent}
    ) } + export default React.memo(ToolPicker) From bc1e4c88e0118218874bbd77a18c34214aaf2401 Mon Sep 17 00:00:00 2001 From: Joel Date: Fri, 27 Jun 2025 10:36:54 +0800 Subject: [PATCH 22/29] feat: no data placeholder --- .../vender/line/general/search-menu.svg | 7 ++ .../src/vender/line/general/SearchMenu.json | 77 +++++++++++++++++++ .../src/vender/line/general/SearchMenu.tsx | 20 +++++ .../icons/src/vender/line/general/index.ts | 1 + .../no-data-placeholder.tsx | 31 ++++++++ .../auto-update-setting/tool-picker.tsx | 6 ++ web/i18n/en-US/plugin.ts | 4 + web/i18n/zh-Hans/plugin.ts | 4 + 8 files changed, 150 insertions(+) create mode 100644 web/app/components/base/icons/assets/vender/line/general/search-menu.svg create mode 100644 web/app/components/base/icons/src/vender/line/general/SearchMenu.json create mode 100644 web/app/components/base/icons/src/vender/line/general/SearchMenu.tsx create mode 100644 web/app/components/plugins/reference-setting-modal/auto-update-setting/no-data-placeholder.tsx diff --git a/web/app/components/base/icons/assets/vender/line/general/search-menu.svg b/web/app/components/base/icons/assets/vender/line/general/search-menu.svg new file mode 100644 index 0000000000..f61f69f4ba --- /dev/null +++ b/web/app/components/base/icons/assets/vender/line/general/search-menu.svg @@ -0,0 +1,7 @@ + + + + + + + diff --git a/web/app/components/base/icons/src/vender/line/general/SearchMenu.json b/web/app/components/base/icons/src/vender/line/general/SearchMenu.json new file mode 100644 index 0000000000..5222574040 --- /dev/null +++ b/web/app/components/base/icons/src/vender/line/general/SearchMenu.json @@ -0,0 +1,77 @@ +{ + "icon": { + "type": "element", + "isRootNode": true, + "name": "svg", + "attributes": { + "width": "32", + "height": "32", + "viewBox": "0 0 32 32", + "fill": "none", + "xmlns": "http://www.w3.org/2000/svg" + }, + "children": [ + { + "type": "element", + "name": "path", + "attributes": { + "d": "M28.0049 16C28.0049 20.4183 24.4231 24 20.0049 24C15.5866 24 12.0049 20.4183 12.0049 16C12.0049 11.5817 15.5866 8 20.0049 8C24.4231 8 28.0049 11.5817 28.0049 16Z", + "stroke": "currentColor", + "stroke-width": "2", + "stroke-linecap": "round", + "stroke-linejoin": "round" + }, + "children": [] + }, + { + "type": "element", + "name": "path", + "attributes": { + "d": "M4.00488 16H6.67155", + "stroke": "currentColor", + "stroke-width": "2", + "stroke-linecap": "round", + "stroke-linejoin": "round" + }, + "children": [] + }, + { + "type": "element", + "name": "path", + "attributes": { + "d": "M4.00488 9.33334H8.00488", + "stroke": "currentColor", + "stroke-width": "2", + "stroke-linecap": "round", + "stroke-linejoin": "round" + }, + "children": [] + }, + { + "type": "element", + "name": "path", + "attributes": { + "d": "M4.00488 22.6667H8.00488", + "stroke": "currentColor", + "stroke-width": "2", + "stroke-linecap": "round", + "stroke-linejoin": "round" + }, + "children": [] + }, + { + "type": "element", + "name": "path", + "attributes": { + "d": "M26 22L29.3333 25.3333", + "stroke": "currentColor", + "stroke-width": "2", + "stroke-linecap": "round", + "stroke-linejoin": "round" + }, + "children": [] + } + ] + }, + "name": "SearchMenu" +} \ No newline at end of file diff --git a/web/app/components/base/icons/src/vender/line/general/SearchMenu.tsx b/web/app/components/base/icons/src/vender/line/general/SearchMenu.tsx new file mode 100644 index 0000000000..4826abb20f --- /dev/null +++ b/web/app/components/base/icons/src/vender/line/general/SearchMenu.tsx @@ -0,0 +1,20 @@ +// GENERATE BY script +// DON NOT EDIT IT MANUALLY + +import * as React from 'react' +import data from './SearchMenu.json' +import IconBase from '@/app/components/base/icons/IconBase' +import type { IconData } from '@/app/components/base/icons/IconBase' + +const Icon = ( + { + ref, + ...props + }: React.SVGProps & { + ref?: React.RefObject>; + }, +) => + +Icon.displayName = 'SearchMenu' + +export default Icon diff --git a/web/app/components/base/icons/src/vender/line/general/index.ts b/web/app/components/base/icons/src/vender/line/general/index.ts index b5c7a7bbc1..1b6c7e7303 100644 --- a/web/app/components/base/icons/src/vender/line/general/index.ts +++ b/web/app/components/base/icons/src/vender/line/general/index.ts @@ -19,6 +19,7 @@ export { default as Pin01 } from './Pin01' export { default as Pin02 } from './Pin02' export { default as Plus02 } from './Plus02' export { default as Refresh } from './Refresh' +export { default as SearchMenu } from './SearchMenu' export { default as Settings01 } from './Settings01' export { default as Settings04 } from './Settings04' export { default as Target04 } from './Target04' 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.tsx new file mode 100644 index 0000000000..979dc626e8 --- /dev/null +++ b/web/app/components/plugins/reference-setting-modal/auto-update-setting/no-data-placeholder.tsx @@ -0,0 +1,31 @@ +'use client' +import type { FC } from 'react' +import React from 'react' +import cn from '@/utils/classnames' +import { Group } from '@/app/components/base/icons/src/vender/other' +import { SearchMenu } from '@/app/components/base/icons/src/vender/line/general' +import { useTranslation } from 'react-i18next' + +type Props = { + className: string + noPlugins?: boolean +} + +const NoDataPlaceholder: FC = ({ + className, + noPlugins, +}) => { + const { t } = useTranslation() + const icon = noPlugins ? () : () + const text = t(`plugin.autoUpdate.noPluginPlaceholder.${noPlugins ? 'noInstalled' : 'noFound'}`) + return ( +
    +
    + {icon} +
    {text}
    +
    +
    + ) +} + +export default React.memo(NoDataPlaceholder) 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.tsx index d8375f6aec..62989f9460 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 @@ -13,6 +13,7 @@ import { useTranslation } from 'react-i18next' import cn from '@/utils/classnames' import ToolItem from './tool-item' import Loading from '@/app/components/base/loading' +import NoDataPlaceholder from './no-data-placeholder' type Props = { trigger: React.ReactNode @@ -100,6 +101,10 @@ const ToolPicker: FC = ({
    ) + const noData = ( + + ) + return ( = ({
    {!isLoading && list.length > 0 && listContent} + {!isLoading && list.length === 0 && noData} {isLoading && loadingContent}
    diff --git a/web/i18n/en-US/plugin.ts b/web/i18n/en-US/plugin.ts index b422767176..a4d8aad4e9 100644 --- a/web/i18n/en-US/plugin.ts +++ b/web/i18n/en-US/plugin.ts @@ -156,6 +156,10 @@ const translation = { downgrade: 'Downgrade anyway', exclude: 'Exclude from auto-update', }, + noPluginPlaceholder: { + noFound: 'No plugins were found', + noInstalled: 'No plugins installed', + }, }, pluginInfoModal: { title: 'Plugin info', diff --git a/web/i18n/zh-Hans/plugin.ts b/web/i18n/zh-Hans/plugin.ts index 85d0d0df08..1faeea43f1 100644 --- a/web/i18n/zh-Hans/plugin.ts +++ b/web/i18n/zh-Hans/plugin.ts @@ -156,6 +156,10 @@ const translation = { downgrade: '仍然降级', exclude: '从自动更新中排除', }, + noPluginPlaceholder: { + noFound: '未找到插件', + noInstalled: '未安装插件', + }, }, pluginInfoModal: { title: '插件信息', From f3cbfe2223856be10b559af930a98efb7c9ac7dd Mon Sep 17 00:00:00 2001 From: Joel Date: Fri, 27 Jun 2025 10:49:22 +0800 Subject: [PATCH 23/29] feat: config can save --- .../reference-setting-modal/auto-update-setting/config.ts | 8 ++++---- .../reference-setting-modal/auto-update-setting/types.ts | 2 +- web/i18n/en-US/plugin.ts | 2 +- web/i18n/zh-Hans/plugin.ts | 2 +- 4 files changed, 7 insertions(+), 7 deletions(-) diff --git a/web/app/components/plugins/reference-setting-modal/auto-update-setting/config.ts b/web/app/components/plugins/reference-setting-modal/auto-update-setting/config.ts index 384a3db086..084dfc9731 100644 --- a/web/app/components/plugins/reference-setting-modal/auto-update-setting/config.ts +++ b/web/app/components/plugins/reference-setting-modal/auto-update-setting/config.ts @@ -1,9 +1,9 @@ import type { AutoUpdateConfig } from './types' import { AUTO_UPDATE_MODE, AUTO_UPDATE_STRATEGY } from './types' export const defaultValue: AutoUpdateConfig = { - strategy_setting: AUTO_UPDATE_STRATEGY.fixOnly, // For test + strategy_setting: AUTO_UPDATE_STRATEGY.disabled, upgrade_time_of_day: 0, - upgrade_mode: AUTO_UPDATE_MODE.exclude, // For test - exclude_plugins: ['langgenius/openai_api_compatible', 'langgenius/openai', 'langgenius/openai', 'langgenius/openai', 'langgenius/openai', 'langgenius/openai', 'langgenius/openai', 'langgenius/openai', 'langgenius/openai', 'langgenius/openai', 'langgenius/openai', 'langgenius/openai', 'langgenius/openai', 'langgenius/openai', 'langgenius/openai', 'langgenius/openai', 'langgenius/openai', 'langgenius/openai', 'langgenius/openai', 'langgenius/openai', 'langgenius/openai', 'langgenius/openai', 'langgenius/openai', 'langgenius/openai', 'langgenius/openai', 'langgenius/openai', 'langgenius/openai', 'langgenius/openai'], - include_plugins: ['langgenius/openai'], + upgrade_mode: AUTO_UPDATE_MODE.update_all, + exclude_plugins: [], + include_plugins: [], } diff --git a/web/app/components/plugins/reference-setting-modal/auto-update-setting/types.ts b/web/app/components/plugins/reference-setting-modal/auto-update-setting/types.ts index c48a67140a..b734150b49 100644 --- a/web/app/components/plugins/reference-setting-modal/auto-update-setting/types.ts +++ b/web/app/components/plugins/reference-setting-modal/auto-update-setting/types.ts @@ -7,7 +7,7 @@ export enum AUTO_UPDATE_STRATEGY { export enum AUTO_UPDATE_MODE { partial = 'partial', exclude = 'exclude', - update_all = 'update_all', + update_all = 'all', } export type AutoUpdateConfig = { diff --git a/web/i18n/en-US/plugin.ts b/web/i18n/en-US/plugin.ts index a4d8aad4e9..0145976415 100644 --- a/web/i18n/en-US/plugin.ts +++ b/web/i18n/en-US/plugin.ts @@ -135,7 +135,7 @@ const translation = { }, updateTimeTitle: 'Update time', upgradeMode: { - update_all: 'Update all', + all: 'Update all', exclude: 'Exclude selected', partial: 'Only selected', }, diff --git a/web/i18n/zh-Hans/plugin.ts b/web/i18n/zh-Hans/plugin.ts index 1faeea43f1..eb8c116288 100644 --- a/web/i18n/zh-Hans/plugin.ts +++ b/web/i18n/zh-Hans/plugin.ts @@ -135,7 +135,7 @@ const translation = { }, updateTimeTitle: '更新时间', upgradeMode: { - update_all: '更新全部', + all: '更新全部', exclude: '排除选定', partial: '仅选定', }, From 836027cb33e32d2009740b4ea3329ac87dd72a07 Mon Sep 17 00:00:00 2001 From: Joel Date: Fri, 27 Jun 2025 11:36:08 +0800 Subject: [PATCH 24/29] chore: add auto update show config --- .../base/icons/src/public/llm/OpenaiTale.json | 37 +++++++++++++++++++ .../base/icons/src/public/llm/OpenaiTale.tsx | 20 ++++++++++ .../icons/src/public/llm/OpenaiYellow.json | 37 +++++++++++++++++++ .../icons/src/public/llm/OpenaiYellow.tsx | 20 ++++++++++ .../base/icons/src/public/llm/index.ts | 2 + .../plugin-detail-panel/detail-header.tsx | 36 +++++++++++++----- 6 files changed, 142 insertions(+), 10 deletions(-) create mode 100644 web/app/components/base/icons/src/public/llm/OpenaiTale.json create mode 100644 web/app/components/base/icons/src/public/llm/OpenaiTale.tsx create mode 100644 web/app/components/base/icons/src/public/llm/OpenaiYellow.json create mode 100644 web/app/components/base/icons/src/public/llm/OpenaiYellow.tsx diff --git a/web/app/components/base/icons/src/public/llm/OpenaiTale.json b/web/app/components/base/icons/src/public/llm/OpenaiTale.json new file mode 100644 index 0000000000..b5d5a015ff --- /dev/null +++ b/web/app/components/base/icons/src/public/llm/OpenaiTale.json @@ -0,0 +1,37 @@ +{ + "icon": { + "type": "element", + "isRootNode": true, + "name": "svg", + "attributes": { + "width": "24", + "height": "24", + "viewBox": "0 0 24 24", + "fill": "none", + "xmlns": "http://www.w3.org/2000/svg" + }, + "children": [ + { + "type": "element", + "name": "rect", + "attributes": { + "width": "24", + "height": "24", + "rx": "6", + "fill": "#009688" + }, + "children": [] + }, + { + "type": "element", + "name": "path", + "attributes": { + "d": "M19.7758 11.5959C19.9546 11.9948 20.0681 12.4213 20.1145 12.8563C20.1592 13.2913 20.1369 13.7315 20.044 14.1596C19.9529 14.5878 19.7947 14.9987 19.5746 15.377C19.4302 15.6298 19.2599 15.867 19.0639 16.0854C18.8696 16.3021 18.653 16.4981 18.4174 16.67C18.1801 16.842 17.9274 16.9864 17.6591 17.105C17.3926 17.222 17.1141 17.3114 16.8286 17.3698C16.6945 17.7859 16.4951 18.1797 16.2371 18.5339C15.9809 18.8881 15.6697 19.1993 15.3155 19.4555C14.9613 19.7134 14.5693 19.9129 14.1532 20.047C13.7371 20.1829 13.302 20.2499 12.8636 20.2499C12.573 20.2516 12.2807 20.2207 11.9953 20.1622C11.7116 20.102 11.433 20.0109 11.1665 19.8923C10.9 19.7736 10.6472 19.6258 10.4116 19.4538C10.1778 19.2819 9.96115 19.0841 9.76857 18.8658C9.33871 18.9586 8.89853 18.981 8.46351 18.9363C8.02849 18.8898 7.60207 18.7763 7.20143 18.5975C6.80252 18.4204 6.43284 18.1797 6.10786 17.8857C5.78289 17.5916 5.50606 17.2478 5.28769 16.8695C5.14153 16.6167 5.02117 16.3502 4.93004 16.0734C4.83891 15.7965 4.77873 15.5111 4.74778 15.2205C4.71683 14.9317 4.71855 14.6393 4.7495 14.3488C4.78045 14.0599 4.84407 13.7745 4.9352 13.4976C4.64289 13.1727 4.40217 12.803 4.22335 12.4041C4.04624 12.0034 3.93104 11.5787 3.88634 11.1437C3.83991 10.7087 3.86398 10.2685 3.95511 9.84036C4.04624 9.41222 4.20443 9.00127 4.42452 8.62299C4.56896 8.37023 4.73918 8.13123 4.93348 7.91458C5.12778 7.69793 5.34615 7.50191 5.58171 7.32997C5.81728 7.15802 6.07176 7.01187 6.33827 6.89495C6.6065 6.7763 6.88506 6.68861 7.17048 6.63015C7.3046 6.21232 7.50406 5.82029 7.76026 5.46608C8.01817 5.11188 8.32939 4.80066 8.6836 4.54274C9.03781 4.28654 9.42984 4.08708 9.84595 3.95125C10.2621 3.81713 10.6971 3.74835 11.1355 3.75007C11.4261 3.74835 11.7184 3.77758 12.0039 3.83776C12.2893 3.89794 12.5678 3.98736 12.8344 4.106C13.1009 4.22636 13.3536 4.37251 13.5892 4.54446C13.8248 4.71812 14.0414 4.91414 14.234 5.13251C14.6621 5.04138 15.1023 5.01903 15.5373 5.06373C15.9723 5.10844 16.3971 5.22364 16.7977 5.40074C17.1966 5.57957 17.5663 5.81857 17.8913 6.1126C18.2162 6.4049 18.4931 6.74707 18.7114 7.12707C18.8576 7.37811 18.9779 7.64463 19.0691 7.92318C19.1602 8.20001 19.2221 8.48544 19.2513 8.77602C19.2823 9.06661 19.2823 9.35892 19.2496 9.64951C19.2187 9.94009 19.155 10.2255 19.0639 10.5024C19.3579 10.8273 19.5969 11.1953 19.7758 11.5959ZM14.0466 18.9363C14.4214 18.7815 14.7619 18.5528 15.049 18.2657C15.3362 17.9785 15.5648 17.6381 15.7196 17.2615C15.8743 16.8867 15.9552 16.4843 15.9552 16.0785V12.2442C15.954 12.2407 15.9529 12.2367 15.9517 12.2321C15.9506 12.2287 15.9488 12.2252 15.9466 12.2218C15.9443 12.2184 15.9414 12.2155 15.938 12.2132C15.9345 12.2098 15.9311 12.2075 15.9276 12.2063L14.54 11.4051V16.0373C14.54 16.0837 14.5332 16.1318 14.5211 16.1765C14.5091 16.223 14.4919 16.2659 14.4678 16.3072C14.4438 16.3485 14.4162 16.3863 14.3819 16.419C14.3484 16.4523 14.3109 16.4812 14.2701 16.505L10.9842 18.4015C10.9567 18.4187 10.9103 18.4428 10.8862 18.4565C11.0221 18.5717 11.1699 18.6732 11.3247 18.7626C11.4811 18.852 11.6428 18.9277 11.8113 18.9896C11.9798 19.0497 12.1535 19.0962 12.3288 19.1271C12.5059 19.1581 12.6848 19.1735 12.8636 19.1735C13.2694 19.1735 13.6717 19.0927 14.0466 18.9363ZM6.22135 16.333C6.42596 16.6855 6.69592 16.9916 7.01745 17.2392C7.34071 17.4868 7.70695 17.6673 8.09899 17.7722C8.49102 17.8771 8.90025 17.9046 9.3026 17.8513C9.70495 17.798 10.0918 17.6673 10.4443 17.4644L13.7663 15.5472L13.7749 15.5386C13.7772 15.5363 13.7789 15.5329 13.78 15.5283C13.7823 15.5249 13.7841 15.5214 13.7852 15.518V13.9017L9.77545 16.2212C9.73418 16.2453 9.6912 16.2625 9.64649 16.2763C9.60007 16.2883 9.55364 16.2935 9.5055 16.2935C9.45907 16.2935 9.41265 16.2883 9.36622 16.2763C9.32152 16.2625 9.27681 16.2453 9.23554 16.2212L5.94967 14.323C5.92044 14.3058 5.87746 14.28 5.85339 14.2645C5.82244 14.4416 5.80696 14.6204 5.80696 14.7993C5.80696 14.9781 5.82415 15.1569 5.85511 15.334C5.88605 15.5094 5.9342 15.6831 5.99438 15.8516C6.05628 16.0201 6.13194 16.1817 6.22135 16.3364V16.333ZM5.35818 9.1629C5.15529 9.51539 5.02461 9.90398 4.97131 10.3063C4.918 10.7087 4.94552 11.1162 5.0504 11.51C5.15529 11.902 5.33583 12.2682 5.58343 12.5915C5.83103 12.913 6.13881 13.183 6.48958 13.3859L9.80984 15.3048C9.81328 15.3059 9.81729 15.3071 9.82188 15.3082H9.83391C9.8385 15.3082 9.84251 15.3071 9.84595 15.3048C9.84939 15.3036 9.85283 15.3019 9.85627 15.2996L11.249 14.4949L7.23926 12.1805C7.19971 12.1565 7.16189 12.1272 7.1275 12.0946C7.09418 12.0611 7.06529 12.0236 7.04153 11.9828C7.01917 11.9415 7.00026 11.8985 6.98822 11.8521C6.97619 11.8074 6.96931 11.761 6.97103 11.7128V7.80797C6.80252 7.86987 6.63917 7.94553 6.48442 8.03494C6.32967 8.12607 6.18352 8.22924 6.04596 8.34444C5.91013 8.45965 5.78289 8.58688 5.66769 8.72444C5.55248 8.86028 5.45103 9.00815 5.36162 9.1629H5.35818ZM16.7633 11.8177C16.8046 11.8418 16.8424 11.8693 16.8768 11.9037C16.9094 11.9364 16.9387 11.9742 16.9628 12.0155C16.9851 12.0567 17.004 12.1014 17.0161 12.1461C17.0264 12.1926 17.0332 12.239 17.0315 12.2871V16.192C17.5835 15.9891 18.0649 15.6332 18.4208 15.1655C18.7785 14.6978 18.9934 14.139 19.0433 13.5544C19.0931 12.9698 18.9762 12.3817 18.7046 11.8607C18.4329 11.3397 18.0185 10.9064 17.5095 10.6141L14.1893 8.69521C14.1858 8.69406 14.1818 8.69292 14.1772 8.69177H14.1652C14.1618 8.69292 14.1578 8.69406 14.1532 8.69521C14.1497 8.69636 14.1463 8.69808 14.1429 8.70037L12.757 9.50163L16.7667 11.8177H16.7633ZM18.1475 9.7372H18.1457V9.73892L18.1475 9.7372ZM18.1457 9.73548C18.2455 9.15774 18.1784 8.56281 17.9514 8.02119C17.7262 7.47956 17.3496 7.01359 16.8682 6.67658C16.3867 6.34128 15.8193 6.1487 15.233 6.12291C14.6449 6.09884 14.0638 6.24155 13.5548 6.53386L10.2345 8.45105C10.2311 8.45334 10.2282 8.45621 10.2259 8.45965L10.2191 8.46996C10.2179 8.4734 10.2168 8.47741 10.2156 8.482C10.2145 8.48544 10.2139 8.48945 10.2139 8.49403V10.0966L14.2237 7.78046C14.2649 7.75639 14.3096 7.7392 14.3543 7.72544C14.4008 7.7134 14.4472 7.70825 14.4936 7.70825C14.5418 7.70825 14.5882 7.7134 14.6346 7.72544C14.6793 7.7392 14.7223 7.75639 14.7636 7.78046L18.0494 9.67874C18.0787 9.69593 18.1217 9.72 18.1457 9.73548ZM9.45735 7.96101C9.45735 7.91458 9.46423 7.86816 9.47627 7.82173C9.4883 7.77702 9.5055 7.73232 9.52957 7.69105C9.55364 7.6515 9.58115 7.61368 9.61554 7.57929C9.64821 7.54662 9.68604 7.51739 9.72731 7.49503L13.0132 5.59848C13.0441 5.57957 13.0871 5.55549 13.1112 5.54346C12.6607 5.1669 12.1105 4.92618 11.5276 4.85224C10.9447 4.77658 10.3532 4.86943 9.82188 5.11875C9.28885 5.36807 8.83835 5.76527 8.52369 6.26047C8.20903 6.75739 8.04224 7.33169 8.04224 7.91974V11.7541C8.04339 11.7587 8.04454 11.7627 8.04568 11.7661C8.04683 11.7696 8.04855 11.773 8.05084 11.7765C8.05313 11.7799 8.056 11.7833 8.05944 11.7868C8.06173 11.7891 8.06517 11.7914 8.06976 11.7937L9.45735 12.5949V7.96101ZM10.2105 13.0282L11.997 14.0599L13.7835 13.0282V10.9666L11.9987 9.93493L10.2122 10.9666L10.2105 13.0282Z", + "fill": "white" + }, + "children": [] + } + ] + }, + "name": "OpenaiTale" +} diff --git a/web/app/components/base/icons/src/public/llm/OpenaiTale.tsx b/web/app/components/base/icons/src/public/llm/OpenaiTale.tsx new file mode 100644 index 0000000000..e7ae45e293 --- /dev/null +++ b/web/app/components/base/icons/src/public/llm/OpenaiTale.tsx @@ -0,0 +1,20 @@ +// GENERATE BY script +// DON NOT EDIT IT MANUALLY + +import * as React from 'react' +import data from './OpenaiTale.json' +import IconBase from '@/app/components/base/icons/IconBase' +import type { IconData } from '@/app/components/base/icons/IconBase' + +const Icon = ( + { + ref, + ...props + }: React.SVGProps & { + ref?: React.RefObject>; + }, +) => + +Icon.displayName = 'OpenaiTale' + +export default Icon diff --git a/web/app/components/base/icons/src/public/llm/OpenaiYellow.json b/web/app/components/base/icons/src/public/llm/OpenaiYellow.json new file mode 100644 index 0000000000..10a3f675b4 --- /dev/null +++ b/web/app/components/base/icons/src/public/llm/OpenaiYellow.json @@ -0,0 +1,37 @@ +{ + "icon": { + "type": "element", + "isRootNode": true, + "name": "svg", + "attributes": { + "width": "24", + "height": "24", + "viewBox": "0 0 24 24", + "fill": "none", + "xmlns": "http://www.w3.org/2000/svg" + }, + "children": [ + { + "type": "element", + "name": "rect", + "attributes": { + "width": "24", + "height": "24", + "rx": "6", + "fill": "#FAB005" + }, + "children": [] + }, + { + "type": "element", + "name": "path", + "attributes": { + "d": "M19.7758 11.5959C19.9546 11.9948 20.0681 12.4213 20.1145 12.8563C20.1592 13.2913 20.1369 13.7315 20.044 14.1596C19.9529 14.5878 19.7947 14.9987 19.5746 15.377C19.4302 15.6298 19.2599 15.867 19.0639 16.0854C18.8696 16.3021 18.653 16.4981 18.4174 16.67C18.1801 16.842 17.9274 16.9864 17.6591 17.105C17.3926 17.222 17.1141 17.3114 16.8286 17.3698C16.6945 17.7859 16.4951 18.1797 16.2371 18.5339C15.9809 18.8881 15.6697 19.1993 15.3155 19.4555C14.9613 19.7134 14.5693 19.9129 14.1532 20.047C13.7371 20.1829 13.302 20.2499 12.8636 20.2499C12.573 20.2516 12.2807 20.2207 11.9953 20.1622C11.7116 20.102 11.433 20.0109 11.1665 19.8923C10.9 19.7736 10.6472 19.6258 10.4116 19.4538C10.1778 19.2819 9.96115 19.0841 9.76857 18.8658C9.33871 18.9586 8.89853 18.981 8.46351 18.9363C8.02849 18.8898 7.60207 18.7763 7.20143 18.5975C6.80252 18.4204 6.43284 18.1797 6.10786 17.8857C5.78289 17.5916 5.50606 17.2478 5.28769 16.8695C5.14153 16.6167 5.02117 16.3502 4.93004 16.0734C4.83891 15.7965 4.77873 15.5111 4.74778 15.2205C4.71683 14.9317 4.71855 14.6393 4.7495 14.3488C4.78045 14.0599 4.84407 13.7745 4.9352 13.4976C4.64289 13.1727 4.40217 12.803 4.22335 12.4041C4.04624 12.0034 3.93104 11.5787 3.88634 11.1437C3.83991 10.7087 3.86398 10.2685 3.95511 9.84036C4.04624 9.41222 4.20443 9.00127 4.42452 8.62299C4.56896 8.37023 4.73918 8.13123 4.93348 7.91458C5.12778 7.69793 5.34615 7.50191 5.58171 7.32997C5.81728 7.15802 6.07176 7.01187 6.33827 6.89495C6.6065 6.7763 6.88506 6.68861 7.17048 6.63015C7.3046 6.21232 7.50406 5.82029 7.76026 5.46608C8.01817 5.11188 8.32939 4.80066 8.6836 4.54274C9.03781 4.28654 9.42984 4.08708 9.84595 3.95125C10.2621 3.81713 10.6971 3.74835 11.1355 3.75007C11.4261 3.74835 11.7184 3.77758 12.0039 3.83776C12.2893 3.89794 12.5678 3.98736 12.8344 4.106C13.1009 4.22636 13.3536 4.37251 13.5892 4.54446C13.8248 4.71812 14.0414 4.91414 14.234 5.13251C14.6621 5.04138 15.1023 5.01903 15.5373 5.06373C15.9723 5.10844 16.3971 5.22364 16.7977 5.40074C17.1966 5.57957 17.5663 5.81857 17.8913 6.1126C18.2162 6.4049 18.4931 6.74707 18.7114 7.12707C18.8576 7.37811 18.9779 7.64463 19.0691 7.92318C19.1602 8.20001 19.2221 8.48544 19.2513 8.77602C19.2823 9.06661 19.2823 9.35892 19.2496 9.64951C19.2187 9.94009 19.155 10.2255 19.0639 10.5024C19.3579 10.8273 19.5969 11.1953 19.7758 11.5959ZM14.0466 18.9363C14.4214 18.7815 14.7619 18.5528 15.049 18.2657C15.3362 17.9785 15.5648 17.6381 15.7196 17.2615C15.8743 16.8867 15.9552 16.4843 15.9552 16.0785V12.2442C15.954 12.2407 15.9529 12.2367 15.9517 12.2321C15.9506 12.2287 15.9488 12.2252 15.9466 12.2218C15.9443 12.2184 15.9414 12.2155 15.938 12.2132C15.9345 12.2098 15.9311 12.2075 15.9276 12.2063L14.54 11.4051V16.0373C14.54 16.0837 14.5332 16.1318 14.5211 16.1765C14.5091 16.223 14.4919 16.2659 14.4678 16.3072C14.4438 16.3485 14.4162 16.3863 14.3819 16.419C14.3484 16.4523 14.3109 16.4812 14.2701 16.505L10.9842 18.4015C10.9567 18.4187 10.9103 18.4428 10.8862 18.4565C11.0221 18.5717 11.1699 18.6732 11.3247 18.7626C11.4811 18.852 11.6428 18.9277 11.8113 18.9896C11.9798 19.0497 12.1535 19.0962 12.3288 19.1271C12.5059 19.1581 12.6848 19.1735 12.8636 19.1735C13.2694 19.1735 13.6717 19.0927 14.0466 18.9363ZM6.22135 16.333C6.42596 16.6855 6.69592 16.9916 7.01745 17.2392C7.34071 17.4868 7.70695 17.6673 8.09899 17.7722C8.49102 17.8771 8.90025 17.9046 9.3026 17.8513C9.70495 17.798 10.0918 17.6673 10.4443 17.4644L13.7663 15.5472L13.7749 15.5386C13.7772 15.5363 13.7789 15.5329 13.78 15.5283C13.7823 15.5249 13.7841 15.5214 13.7852 15.518V13.9017L9.77545 16.2212C9.73418 16.2453 9.6912 16.2625 9.64649 16.2763C9.60007 16.2883 9.55364 16.2935 9.5055 16.2935C9.45907 16.2935 9.41265 16.2883 9.36622 16.2763C9.32152 16.2625 9.27681 16.2453 9.23554 16.2212L5.94967 14.323C5.92044 14.3058 5.87746 14.28 5.85339 14.2645C5.82244 14.4416 5.80696 14.6204 5.80696 14.7993C5.80696 14.9781 5.82415 15.1569 5.85511 15.334C5.88605 15.5094 5.9342 15.6831 5.99438 15.8516C6.05628 16.0201 6.13194 16.1817 6.22135 16.3364V16.333ZM5.35818 9.1629C5.15529 9.51539 5.02461 9.90398 4.97131 10.3063C4.918 10.7087 4.94552 11.1162 5.0504 11.51C5.15529 11.902 5.33583 12.2682 5.58343 12.5915C5.83103 12.913 6.13881 13.183 6.48958 13.3859L9.80984 15.3048C9.81328 15.3059 9.81729 15.3071 9.82188 15.3082H9.83391C9.8385 15.3082 9.84251 15.3071 9.84595 15.3048C9.84939 15.3036 9.85283 15.3019 9.85627 15.2996L11.249 14.4949L7.23926 12.1805C7.19971 12.1565 7.16189 12.1272 7.1275 12.0946C7.09418 12.0611 7.06529 12.0236 7.04153 11.9828C7.01917 11.9415 7.00026 11.8985 6.98822 11.8521C6.97619 11.8074 6.96931 11.761 6.97103 11.7128V7.80797C6.80252 7.86987 6.63917 7.94553 6.48442 8.03494C6.32967 8.12607 6.18352 8.22924 6.04596 8.34444C5.91013 8.45965 5.78289 8.58688 5.66769 8.72444C5.55248 8.86028 5.45103 9.00815 5.36162 9.1629H5.35818ZM16.7633 11.8177C16.8046 11.8418 16.8424 11.8693 16.8768 11.9037C16.9094 11.9364 16.9387 11.9742 16.9628 12.0155C16.9851 12.0567 17.004 12.1014 17.0161 12.1461C17.0264 12.1926 17.0332 12.239 17.0315 12.2871V16.192C17.5835 15.9891 18.0649 15.6332 18.4208 15.1655C18.7785 14.6978 18.9934 14.139 19.0433 13.5544C19.0931 12.9698 18.9762 12.3817 18.7046 11.8607C18.4329 11.3397 18.0185 10.9064 17.5095 10.6141L14.1893 8.69521C14.1858 8.69406 14.1818 8.69292 14.1772 8.69177H14.1652C14.1618 8.69292 14.1578 8.69406 14.1532 8.69521C14.1497 8.69636 14.1463 8.69808 14.1429 8.70037L12.757 9.50163L16.7667 11.8177H16.7633ZM18.1475 9.7372H18.1457V9.73892L18.1475 9.7372ZM18.1457 9.73548C18.2455 9.15774 18.1784 8.56281 17.9514 8.02119C17.7262 7.47956 17.3496 7.01359 16.8682 6.67658C16.3867 6.34128 15.8193 6.1487 15.233 6.12291C14.6449 6.09884 14.0638 6.24155 13.5548 6.53386L10.2345 8.45105C10.2311 8.45334 10.2282 8.45621 10.2259 8.45965L10.2191 8.46996C10.2179 8.4734 10.2168 8.47741 10.2156 8.482C10.2145 8.48544 10.2139 8.48945 10.2139 8.49403V10.0966L14.2237 7.78046C14.2649 7.75639 14.3096 7.7392 14.3543 7.72544C14.4008 7.7134 14.4472 7.70825 14.4936 7.70825C14.5418 7.70825 14.5882 7.7134 14.6346 7.72544C14.6793 7.7392 14.7223 7.75639 14.7636 7.78046L18.0494 9.67874C18.0787 9.69593 18.1217 9.72 18.1457 9.73548ZM9.45735 7.96101C9.45735 7.91458 9.46423 7.86816 9.47627 7.82173C9.4883 7.77702 9.5055 7.73232 9.52957 7.69105C9.55364 7.6515 9.58115 7.61368 9.61554 7.57929C9.64821 7.54662 9.68604 7.51739 9.72731 7.49503L13.0132 5.59848C13.0441 5.57957 13.0871 5.55549 13.1112 5.54346C12.6607 5.1669 12.1105 4.92618 11.5276 4.85224C10.9447 4.77658 10.3532 4.86943 9.82188 5.11875C9.28885 5.36807 8.83835 5.76527 8.52369 6.26047C8.20903 6.75739 8.04224 7.33169 8.04224 7.91974V11.7541C8.04339 11.7587 8.04454 11.7627 8.04568 11.7661C8.04683 11.7696 8.04855 11.773 8.05084 11.7765C8.05313 11.7799 8.056 11.7833 8.05944 11.7868C8.06173 11.7891 8.06517 11.7914 8.06976 11.7937L9.45735 12.5949V7.96101ZM10.2105 13.0282L11.997 14.0599L13.7835 13.0282V10.9666L11.9987 9.93493L10.2122 10.9666L10.2105 13.0282Z", + "fill": "white" + }, + "children": [] + } + ] + }, + "name": "OpenaiYellow" +} diff --git a/web/app/components/base/icons/src/public/llm/OpenaiYellow.tsx b/web/app/components/base/icons/src/public/llm/OpenaiYellow.tsx new file mode 100644 index 0000000000..77dac7e322 --- /dev/null +++ b/web/app/components/base/icons/src/public/llm/OpenaiYellow.tsx @@ -0,0 +1,20 @@ +// GENERATE BY script +// DON NOT EDIT IT MANUALLY + +import * as React from 'react' +import data from './OpenaiYellow.json' +import IconBase from '@/app/components/base/icons/IconBase' +import type { IconData } from '@/app/components/base/icons/IconBase' + +const Icon = ( + { + ref, + ...props + }: React.SVGProps & { + ref?: React.RefObject>; + }, +) => + +Icon.displayName = 'OpenaiYellow' + +export default Icon diff --git a/web/app/components/base/icons/src/public/llm/index.ts b/web/app/components/base/icons/src/public/llm/index.ts index cc9b531ebf..289942ab86 100644 --- a/web/app/components/base/icons/src/public/llm/index.ts +++ b/web/app/components/base/icons/src/public/llm/index.ts @@ -31,7 +31,9 @@ export { default as OpenaiGreen } from './OpenaiGreen' export { default as OpenaiText } from './OpenaiText' export { default as OpenaiTransparent } from './OpenaiTransparent' export { default as OpenaiViolet } from './OpenaiViolet' +export { default as OpenaiTale } from './OpenaiTale' export { default as OpenllmText } from './OpenllmText' +export { default as OpenaiYellow } from './OpenaiYellow' export { default as Openllm } from './Openllm' export { default as ReplicateText } from './ReplicateText' export { default as Replicate } from './Replicate' diff --git a/web/app/components/plugins/plugin-detail-panel/detail-header.tsx b/web/app/components/plugins/plugin-detail-panel/detail-header.tsx index a4ae424baa..bdfea05a19 100644 --- a/web/app/components/plugins/plugin-detail-panel/detail-header.tsx +++ b/web/app/components/plugins/plugin-detail-panel/detail-header.tsx @@ -39,6 +39,8 @@ import { AutoUpdateLine } from '../../base/icons/src/vender/system' import { timeOfDayToDayjs } from '../reference-setting-modal/auto-update-setting/utils' import DowngradeWarningModal from '../update-plugin/downgrade-warning-modal' import { getMarketplaceUrl } from '@/utils/var' +import useReferenceSetting from '../plugin-page/use-reference-setting' +import { AUTO_UPDATE_MODE } from '../reference-setting-modal/auto-update-setting/types' const i18nPrefix = 'plugin.action' @@ -185,8 +187,19 @@ const DetailHeader = ({ } }, [showDeleting, installation_id, hideDeleting, hideDeleteConfirm, onUpdate, category, refreshModelProviders, invalidateAllToolProviders]) - // #plugin TODO# used in apps - // const usedInApps = 3 + const { referenceSetting } = useReferenceSetting() + const { auto_upgrade: autoUpgradeInfo } = referenceSetting || {} + const isShowAutoUpdate = useMemo(() => { + if(!autoUpgradeInfo) + return false + if(autoUpgradeInfo.upgrade_mode === AUTO_UPDATE_MODE.update_all) + return true + if(autoUpgradeInfo.upgrade_mode === AUTO_UPDATE_MODE.partial && autoUpgradeInfo.include_plugins.includes(plugin_id)) + return true + if(autoUpgradeInfo.upgrade_mode === AUTO_UPDATE_MODE.exclude && !autoUpgradeInfo.exclude_plugins.includes(plugin_id)) + return true + return false + }, [autoUpgradeInfo, plugin_id]) return (
    @@ -227,14 +240,17 @@ const DetailHeader = ({ } /> {/* Auto update info */} - - {/* add a a div to fix tooltip hover not show problem */} -
    - - - -
    -
    + {isShowAutoUpdate && ( + + {/* add a a div to fix tooltip hover not show problem */} +
    + + + +
    +
    + )} + {(hasNewVersion || isFromGitHub) && (
    - + ) } diff --git a/web/app/components/plugins/update-plugin/from-market-place.tsx b/web/app/components/plugins/update-plugin/from-market-place.tsx index 98994d9b9c..70bc7399f5 100644 --- a/web/app/components/plugins/update-plugin/from-market-place.tsx +++ b/web/app/components/plugins/update-plugin/from-market-place.tsx @@ -13,13 +13,18 @@ import { updateFromMarketPlace } from '@/service/plugins' import checkTaskStatus from '@/app/components/plugins/install-plugin/base/check-task-status' import { usePluginTaskList } from '@/service/use-plugins' import Toast from '../../base/toast' +import DowngradeWarningModal from './downgrade-warning' +import { useInvalidateReferenceSettings, useRemoveAutoUpgrade } from '@/service/use-plugins' +import cn from '@/utils/classnames' const i18nPrefix = 'plugin.upgrade' type Props = { payload: UpdateFromMarketPlacePayload + pluginId: string onSave: () => void onCancel: () => void + isShowDowngradeWarningModal?: boolean } enum UploadStep { @@ -30,8 +35,10 @@ enum UploadStep { const UpdatePluginModal: FC = ({ payload, + pluginId, onSave, onCancel, + isShowDowngradeWarningModal, }) => { const { originalPackageInfo, @@ -103,51 +110,74 @@ const UpdatePluginModal: FC = ({ onSave() }, [onSave, uploadStep, check, originalPackageInfo.id, handleRefetch, targetPackageInfo.id]) + const { mutateAsync } = useRemoveAutoUpgrade() + const invalidateReferenceSettings = useInvalidateReferenceSettings() + const handleExcludeAndDownload = async () => { + await mutateAsync({ + plugin_id: pluginId, + }) + invalidateReferenceSettings() + handleConfirm() + } + const doShowDowngradeWarningModal = isShowDowngradeWarningModal && uploadStep === UploadStep.notStarted + return ( -
    - {t(`${i18nPrefix}.description`)} -
    -
    - - - {`${originalPackageInfo.payload.version} -> ${targetPackageInfo.version}`} - - - } + {doShowDowngradeWarningModal && ( + -
    -
    - {uploadStep === UploadStep.notStarted && ( + )} + {!doShowDowngradeWarningModal && ( + <> +
    + {t(`${i18nPrefix}.description`)} +
    +
    + + + {`${originalPackageInfo.payload.version} -> ${targetPackageInfo.version}`} + + + } + /> +
    +
    + {uploadStep === UploadStep.notStarted && ( + + )} - )} - -
    +
    + + )} +
    ) } From 0af646d947bca8d4f2fe183bf30fb2eb904d75ec Mon Sep 17 00:00:00 2001 From: Joel Date: Fri, 27 Jun 2025 19:35:18 +0800 Subject: [PATCH 29/29] fix: fetch installed plugin instead of all plugins --- .../auto-update-setting/tool-item.tsx | 7 +++-- .../auto-update-setting/tool-picker.tsx | 28 +++++++++++-------- 2 files changed, 20 insertions(+), 15 deletions(-) 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.tsx index f60faa734f..99a01bcd0f 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 React from 'react' -import type { Plugin } from '@/app/components/plugins/types' +import type { PluginDetail } from '@/app/components/plugins/types' import Icon from '@/app/components/plugins/card/base/card-icon' import { renderI18nObject } from '@/i18n' import { useGetLanguage } from '@/context/i18n' @@ -9,7 +9,7 @@ import { MARKETPLACE_API_PREFIX } from '@/config' import Checkbox from '@/app/components/base/checkbox' type Props = { - payload: Plugin + payload: PluginDetail isChecked?: boolean onCheckChange: () => void } @@ -21,7 +21,8 @@ const ToolItem: FC = ({ }) => { const language = useGetLanguage() - const { plugin_id, label, org } = payload + const { plugin_id, declaration } = payload + const { label, author: org } = declaration return (
    = ({ const [pluginType, setPluginType] = useState(PLUGIN_TYPE_SEARCH_MAP.all) const [query, setQuery] = useState('') const [tags, setTags] = useState([]) - const { data, isLoading } = useFetchPluginListOrBundleList({ - query, - tags, - category: pluginType, - }) - const isBundle = pluginType === PLUGIN_TYPE_SEARCH_MAP.bundle - const list = (isBundle ? data?.data?.bundles : data?.data?.plugins) || [] + const { data, isLoading } = useInstalledPluginList() + const filteredList = useMemo(() => { + const list = data ? data.plugins : [] + return list.filter((plugin) => { + return ( + (pluginType === PLUGIN_TYPE_SEARCH_MAP.all || plugin.declaration.category === pluginType) + && (tags.length === 0 || tags.some(tag => plugin.declaration.tags.includes(tag))) + && (query === '' || plugin.plugin_id.toLowerCase().includes(query.toLowerCase())) + ) + }) + }, [data, pluginType, query, tags]) const handleCheckChange = useCallback((pluginId: string) => { return () => { const newValue = value.includes(pluginId) @@ -84,7 +88,7 @@ const ToolPicker: FC = ({ const listContent = (
    - {list.map(item => ( + {filteredList.map(item => ( = ({ }
    - {!isLoading && list.length > 0 && listContent} - {!isLoading && list.length === 0 && noData} + {!isLoading && filteredList.length > 0 && listContent} + {!isLoading && filteredList.length === 0 && noData} {isLoading && loadingContent}