diff --git a/web/app/components/app/configuration/config-prompt/advanced-prompt-input.tsx b/web/app/components/app/configuration/config-prompt/advanced-prompt-input.tsx index 437e25fde4..e2d37bb9de 100644 --- a/web/app/components/app/configuration/config-prompt/advanced-prompt-input.tsx +++ b/web/app/components/app/configuration/config-prompt/advanced-prompt-input.tsx @@ -17,8 +17,8 @@ import PromptEditorHeightResizeWrap from './prompt-editor-height-resize-wrap' import cn from '@/utils/classnames' import type { PromptRole, PromptVariable } from '@/models/debug' import { - Clipboard, - ClipboardCheck, + Copy, + CopyCheck, } from '@/app/components/base/icons/src/vender/line/files' import Button from '@/app/components/base/button' import Tooltip from '@/app/components/base/tooltip' @@ -188,13 +188,13 @@ const AdvancedPromptInput: FC = ({ )} {!isCopied ? ( - { + { copy(value) setIsCopied(true) }} /> ) : ( - + )} diff --git a/web/app/components/app/configuration/config/agent/prompt-editor.tsx b/web/app/components/app/configuration/config/agent/prompt-editor.tsx index 579b7c4d64..98b23e5379 100644 --- a/web/app/components/app/configuration/config/agent/prompt-editor.tsx +++ b/web/app/components/app/configuration/config/agent/prompt-editor.tsx @@ -6,8 +6,8 @@ import { useContext } from 'use-context-selector' import { useTranslation } from 'react-i18next' import cn from '@/utils/classnames' import { - Clipboard, - ClipboardCheck, + Copy, + CopyCheck, } from '@/app/components/base/icons/src/vender/line/files' import PromptEditor from '@/app/components/base/prompt-editor' import type { ExternalDataTool } from '@/models/common' @@ -81,13 +81,13 @@ const Editor: FC = ({
{!isCopied ? ( - { + { copy(value) setIsCopied(true) }} /> ) : ( - + )}
diff --git a/web/app/components/base/copy-icon/index.tsx b/web/app/components/base/copy-icon/index.tsx index c9e8a5ad14..196e256978 100644 --- a/web/app/components/base/copy-icon/index.tsx +++ b/web/app/components/base/copy-icon/index.tsx @@ -5,8 +5,8 @@ import { debounce } from 'lodash-es' import copy from 'copy-to-clipboard' import Tooltip from '../tooltip' import { - Clipboard, - ClipboardCheck, + Copy, + CopyCheck, } from '@/app/components/base/icons/src/vender/line/files' type Props = { @@ -39,10 +39,10 @@ export const CopyIcon = ({ content }: Props) => {
{!isCopied ? ( - + ) : ( - + ) }
diff --git a/web/app/components/base/icons/assets/vender/line/files/clipboard-check.svg b/web/app/components/base/icons/assets/vender/line/files/clipboard-check.svg deleted file mode 100644 index 48c70edd74..0000000000 --- a/web/app/components/base/icons/assets/vender/line/files/clipboard-check.svg +++ /dev/null @@ -1,3 +0,0 @@ - - - diff --git a/web/app/components/base/icons/assets/vender/line/files/clipboard.svg b/web/app/components/base/icons/assets/vender/line/files/clipboard.svg deleted file mode 100644 index 8abaaa9c39..0000000000 --- a/web/app/components/base/icons/assets/vender/line/files/clipboard.svg +++ /dev/null @@ -1,3 +0,0 @@ - - - diff --git a/web/app/components/base/icons/assets/vender/line/files/copy-check.svg b/web/app/components/base/icons/assets/vender/line/files/copy-check.svg new file mode 100644 index 0000000000..de5f86cc19 --- /dev/null +++ b/web/app/components/base/icons/assets/vender/line/files/copy-check.svg @@ -0,0 +1,3 @@ + + + diff --git a/web/app/components/base/icons/assets/vender/line/files/copy.svg b/web/app/components/base/icons/assets/vender/line/files/copy.svg new file mode 100644 index 0000000000..18d2b4e7fc --- /dev/null +++ b/web/app/components/base/icons/assets/vender/line/files/copy.svg @@ -0,0 +1,3 @@ + + + diff --git a/web/app/components/base/icons/src/vender/line/files/Clipboard.json b/web/app/components/base/icons/src/vender/line/files/Clipboard.json deleted file mode 100644 index f256747558..0000000000 --- a/web/app/components/base/icons/src/vender/line/files/Clipboard.json +++ /dev/null @@ -1,29 +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": "path", - "attributes": { - "d": "M16 4C16.93 4 17.395 4 17.7765 4.10222C18.8117 4.37962 19.6204 5.18827 19.8978 6.22354C20 6.60504 20 7.07003 20 8V17.2C20 18.8802 20 19.7202 19.673 20.362C19.3854 20.9265 18.9265 21.3854 18.362 21.673C17.7202 22 16.8802 22 15.2 22H8.8C7.11984 22 6.27976 22 5.63803 21.673C5.07354 21.3854 4.6146 20.9265 4.32698 20.362C4 19.7202 4 18.8802 4 17.2V8C4 7.07003 4 6.60504 4.10222 6.22354C4.37962 5.18827 5.18827 4.37962 6.22354 4.10222C6.60504 4 7.07003 4 8 4M9.6 6H14.4C14.9601 6 15.2401 6 15.454 5.89101C15.6422 5.79513 15.7951 5.64215 15.891 5.45399C16 5.24008 16 4.96005 16 4.4V3.6C16 3.03995 16 2.75992 15.891 2.54601C15.7951 2.35785 15.6422 2.20487 15.454 2.10899C15.2401 2 14.9601 2 14.4 2H9.6C9.03995 2 8.75992 2 8.54601 2.10899C8.35785 2.20487 8.20487 2.35785 8.10899 2.54601C8 2.75992 8 3.03995 8 3.6V4.4C8 4.96005 8 5.24008 8.10899 5.45399C8.20487 5.64215 8.35785 5.79513 8.54601 5.89101C8.75992 6 9.03995 6 9.6 6Z", - "stroke": "currentColor", - "stroke-width": "2", - "stroke-linecap": "round", - "stroke-linejoin": "round" - }, - "children": [] - } - ] - }, - "name": "Clipboard" -} \ No newline at end of file diff --git a/web/app/components/base/icons/src/vender/line/files/ClipboardCheck.json b/web/app/components/base/icons/src/vender/line/files/ClipboardCheck.json deleted file mode 100644 index 273b115001..0000000000 --- a/web/app/components/base/icons/src/vender/line/files/ClipboardCheck.json +++ /dev/null @@ -1,29 +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": "path", - "attributes": { - "d": "M16 4C16.93 4 17.395 4 17.7765 4.10222C18.8117 4.37962 19.6204 5.18827 19.8978 6.22354C20 6.60504 20 7.07003 20 8V17.2C20 18.8802 20 19.7202 19.673 20.362C19.3854 20.9265 18.9265 21.3854 18.362 21.673C17.7202 22 16.8802 22 15.2 22H8.8C7.11984 22 6.27976 22 5.63803 21.673C5.07354 21.3854 4.6146 20.9265 4.32698 20.362C4 19.7202 4 18.8802 4 17.2V8C4 7.07003 4 6.60504 4.10222 6.22354C4.37962 5.18827 5.18827 4.37962 6.22354 4.10222C6.60504 4 7.07003 4 8 4M9 15L11 17L15.5 12.5M9.6 6H14.4C14.9601 6 15.2401 6 15.454 5.89101C15.6422 5.79513 15.7951 5.64215 15.891 5.45399C16 5.24008 16 4.96005 16 4.4V3.6C16 3.03995 16 2.75992 15.891 2.54601C15.7951 2.35785 15.6422 2.20487 15.454 2.10899C15.2401 2 14.9601 2 14.4 2H9.6C9.03995 2 8.75992 2 8.54601 2.10899C8.35785 2.20487 8.20487 2.35785 8.10899 2.54601C8 2.75992 8 3.03995 8 3.6V4.4C8 4.96005 8 5.24008 8.10899 5.45399C8.20487 5.64215 8.35785 5.79513 8.54601 5.89101C8.75992 6 9.03995 6 9.6 6Z", - "stroke": "currentColor", - "stroke-width": "2", - "stroke-linecap": "round", - "stroke-linejoin": "round" - }, - "children": [] - } - ] - }, - "name": "ClipboardCheck" -} \ No newline at end of file diff --git a/web/app/components/base/icons/src/vender/line/files/Copy.json b/web/app/components/base/icons/src/vender/line/files/Copy.json new file mode 100644 index 0000000000..0aa0935e0f --- /dev/null +++ b/web/app/components/base/icons/src/vender/line/files/Copy.json @@ -0,0 +1,29 @@ +{ + "icon": { + "type": "element", + "isRootNode": true, + "name": "svg", + "attributes": { + "width": "16", + "height": "16", + "viewBox": "0 0 16 16", + "fill": "none", + "xmlns": "http://www.w3.org/2000/svg" + }, + "children": [ + { + "type": "element", + "name": "path", + "attributes": { + "d": "M10.6665 2.66634H11.9998C12.3535 2.66634 12.6926 2.80682 12.9426 3.05687C13.1927 3.30691 13.3332 3.64605 13.3332 3.99967V13.333C13.3332 13.6866 13.1927 14.0258 12.9426 14.2758C12.6926 14.5259 12.3535 14.6663 11.9998 14.6663H3.99984C3.64622 14.6663 3.30708 14.5259 3.05703 14.2758C2.80698 14.0258 2.6665 13.6866 2.6665 13.333V3.99967C2.6665 3.64605 2.80698 3.30691 3.05703 3.05687C3.30708 2.80682 3.64622 2.66634 3.99984 2.66634H5.33317M5.99984 1.33301H9.99984C10.368 1.33301 10.6665 1.63148 10.6665 1.99967V3.33301C10.6665 3.7012 10.368 3.99967 9.99984 3.99967H5.99984C5.63165 3.99967 5.33317 3.7012 5.33317 3.33301V1.99967C5.33317 1.63148 5.63165 1.33301 5.99984 1.33301Z", + "stroke": "currentColor", + "stroke-width": "1.5", + "stroke-linecap": "round", + "stroke-linejoin": "round" + }, + "children": [] + } + ] + }, + "name": "Copy" +} \ No newline at end of file diff --git a/web/app/components/base/icons/src/vender/line/files/Clipboard.tsx b/web/app/components/base/icons/src/vender/line/files/Copy.tsx similarity index 87% rename from web/app/components/base/icons/src/vender/line/files/Clipboard.tsx rename to web/app/components/base/icons/src/vender/line/files/Copy.tsx index c49d15d19d..155b825fa1 100644 --- a/web/app/components/base/icons/src/vender/line/files/Clipboard.tsx +++ b/web/app/components/base/icons/src/vender/line/files/Copy.tsx @@ -2,7 +2,7 @@ // DON NOT EDIT IT MANUALLY import * as React from 'react' -import data from './Clipboard.json' +import data from './Copy.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 = 'Clipboard' +Icon.displayName = 'Copy' export default Icon diff --git a/web/app/components/base/icons/src/vender/line/files/CopyCheck.json b/web/app/components/base/icons/src/vender/line/files/CopyCheck.json new file mode 100644 index 0000000000..f1f3a2e1bd --- /dev/null +++ b/web/app/components/base/icons/src/vender/line/files/CopyCheck.json @@ -0,0 +1,29 @@ +{ + "icon": { + "type": "element", + "isRootNode": true, + "name": "svg", + "attributes": { + "width": "16", + "height": "16", + "viewBox": "0 0 16 16", + "fill": "none", + "xmlns": "http://www.w3.org/2000/svg" + }, + "children": [ + { + "type": "element", + "name": "path", + "attributes": { + "d": "M10.6665 2.66683C11.2865 2.66683 11.5965 2.66683 11.8508 2.73498C12.541 2.91991 13.0801 3.45901 13.265 4.14919C13.3332 4.40352 13.3332 4.71352 13.3332 5.3335V11.4668C13.3332 12.5869 13.3332 13.147 13.1152 13.5748C12.9234 13.9511 12.6175 14.2571 12.2412 14.4488C11.8133 14.6668 11.2533 14.6668 10.1332 14.6668H5.8665C4.7464 14.6668 4.18635 14.6668 3.75852 14.4488C3.3822 14.2571 3.07624 13.9511 2.88449 13.5748C2.6665 13.147 2.6665 12.5869 2.6665 11.4668V5.3335C2.6665 4.71352 2.6665 4.40352 2.73465 4.14919C2.91959 3.45901 3.45868 2.91991 4.14887 2.73498C4.4032 2.66683 4.71319 2.66683 5.33317 2.66683M5.99984 10.0002L7.33317 11.3335L10.3332 8.3335M6.39984 4.00016H9.59984C9.9732 4.00016 10.1599 4.00016 10.3025 3.9275C10.4279 3.86359 10.5299 3.7616 10.5938 3.63616C10.6665 3.49355 10.6665 3.30686 10.6665 2.9335V2.40016C10.6665 2.02679 10.6665 1.84011 10.5938 1.6975C10.5299 1.57206 10.4279 1.47007 10.3025 1.40616C10.1599 1.3335 9.97321 1.3335 9.59984 1.3335H6.39984C6.02647 1.3335 5.83978 1.3335 5.69718 1.40616C5.57174 1.47007 5.46975 1.57206 5.40583 1.6975C5.33317 1.84011 5.33317 2.02679 5.33317 2.40016V2.9335C5.33317 3.30686 5.33317 3.49355 5.40583 3.63616C5.46975 3.7616 5.57174 3.86359 5.69718 3.9275C5.83978 4.00016 6.02647 4.00016 6.39984 4.00016Z", + "stroke": "currentColor", + "stroke-width": "1.5", + "stroke-linecap": "round", + "stroke-linejoin": "round" + }, + "children": [] + } + ] + }, + "name": "CopyCheck" +} \ No newline at end of file diff --git a/web/app/components/base/icons/src/vender/line/files/ClipboardCheck.tsx b/web/app/components/base/icons/src/vender/line/files/CopyCheck.tsx similarity index 85% rename from web/app/components/base/icons/src/vender/line/files/ClipboardCheck.tsx rename to web/app/components/base/icons/src/vender/line/files/CopyCheck.tsx index 586b55e616..90eca4c04d 100644 --- a/web/app/components/base/icons/src/vender/line/files/ClipboardCheck.tsx +++ b/web/app/components/base/icons/src/vender/line/files/CopyCheck.tsx @@ -2,7 +2,7 @@ // DON NOT EDIT IT MANUALLY import * as React from 'react' -import data from './ClipboardCheck.json' +import data from './CopyCheck.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 = 'ClipboardCheck' +Icon.displayName = 'CopyCheck' export default Icon diff --git a/web/app/components/base/icons/src/vender/line/files/index.ts b/web/app/components/base/icons/src/vender/line/files/index.ts index 4c0ddc2289..631f7915b0 100644 --- a/web/app/components/base/icons/src/vender/line/files/index.ts +++ b/web/app/components/base/icons/src/vender/line/files/index.ts @@ -1,5 +1,5 @@ -export { default as ClipboardCheck } from './ClipboardCheck' -export { default as Clipboard } from './Clipboard' +export { default as CopyCheck } from './CopyCheck' +export { default as Copy } from './Copy' export { default as File02 } from './File02' export { default as FileArrow01 } from './FileArrow01' export { default as FileCheck02 } from './FileCheck02' diff --git a/web/app/components/plugins/base/key-value-item.tsx b/web/app/components/plugins/base/key-value-item.tsx index cfc81aa177..b616b5ee18 100644 --- a/web/app/components/plugins/base/key-value-item.tsx +++ b/web/app/components/plugins/base/key-value-item.tsx @@ -6,7 +6,7 @@ import { RiClipboardLine, } from '@remixicon/react' import { useTranslation } from 'react-i18next' -import { ClipboardCheck } from '../../base/icons/src/vender/line/files' +import { CopyCheck } from '../../base/icons/src/vender/line/files' import Tooltip from '../../base/tooltip' import cn from '@/utils/classnames' import ActionButton from '@/app/components/base/action-button' @@ -44,7 +44,7 @@ const KeyValueItem: FC = ({ } }, [isCopied]) - const CopyIcon = isCopied ? ClipboardCheck : RiClipboardLine + const CopyIcon = isCopied ? CopyCheck : RiClipboardLine return (
diff --git a/web/app/components/plugins/plugin-detail-panel/endpoint-card.tsx b/web/app/components/plugins/plugin-detail-panel/endpoint-card.tsx index cc3688aebc..00cd1b88ae 100644 --- a/web/app/components/plugins/plugin-detail-panel/endpoint-card.tsx +++ b/web/app/components/plugins/plugin-detail-panel/endpoint-card.tsx @@ -7,7 +7,7 @@ import type { EndpointListItem } from '../types' import EndpointModal from './endpoint-modal' import { NAME_FIELD } from './utils' import { addDefaultValue, toolCredentialToFormSchemas } from '@/app/components/tools/utils/to-form-schema' -import { ClipboardCheck } from '@/app/components/base/icons/src/vender/line/files' +import { CopyCheck } from '@/app/components/base/icons/src/vender/line/files' import ActionButton from '@/app/components/base/action-button' import Confirm from '@/app/components/base/confirm' import Indicator from '@/app/components/header/indicator' @@ -130,7 +130,7 @@ const EndpointCard = ({ } }, [isCopied]) - const CopyIcon = isCopied ? ClipboardCheck : RiClipboardLine + const CopyIcon = isCopied ? CopyCheck : RiClipboardLine return (
diff --git a/web/app/components/workflow/nodes/_base/components/editor/base.tsx b/web/app/components/workflow/nodes/_base/components/editor/base.tsx index 284c6c77eb..56917bc447 100644 --- a/web/app/components/workflow/nodes/_base/components/editor/base.tsx +++ b/web/app/components/workflow/nodes/_base/components/editor/base.tsx @@ -9,8 +9,8 @@ import Wrap from './wrap' import cn from '@/utils/classnames' import PromptEditorHeightResizeWrap from '@/app/components/app/configuration/config-prompt/prompt-editor-height-resize-wrap' import { - Clipboard, - ClipboardCheck, + Copy, + CopyCheck, } from '@/app/components/base/icons/src/vender/line/files' import useToggleExpend from '@/app/components/workflow/nodes/_base/hooks/use-toggle-expend' import type { FileEntity } from '@/app/components/base/file-uploader/types' @@ -92,10 +92,10 @@ const Base: FC = ({ {!isCopied ? ( - + ) : ( - + ) } diff --git a/web/app/components/workflow/nodes/_base/components/prompt/editor.tsx b/web/app/components/workflow/nodes/_base/components/prompt/editor.tsx index b28e8a1ca3..4cf0fa037a 100644 --- a/web/app/components/workflow/nodes/_base/components/prompt/editor.tsx +++ b/web/app/components/workflow/nodes/_base/components/prompt/editor.tsx @@ -23,8 +23,8 @@ import ToggleExpandBtn from '@/app/components/workflow/nodes/_base/components/to import useToggleExpend from '@/app/components/workflow/nodes/_base/hooks/use-toggle-expend' import PromptEditor from '@/app/components/base/prompt-editor' import { - Clipboard, - ClipboardCheck, + Copy, + CopyCheck, } from '@/app/components/base/icons/src/vender/line/files' import { useEventEmitterContextContext } from '@/context/event-emitter' import { PROMPT_EDITOR_INSERT_QUICKLY } from '@/app/components/base/prompt-editor/plugins/update-block' @@ -204,12 +204,12 @@ const Editor: FC = ({ {!isCopied ? ( - + ) : ( - + ) } diff --git a/web/app/components/workflow/panel/debug-and-preview/conversation-variable-modal.tsx b/web/app/components/workflow/panel/debug-and-preview/conversation-variable-modal.tsx index 57fe461e03..ee3eded719 100644 --- a/web/app/components/workflow/panel/debug-and-preview/conversation-variable-modal.tsx +++ b/web/app/components/workflow/panel/debug-and-preview/conversation-variable-modal.tsx @@ -9,8 +9,8 @@ import Modal from '@/app/components/base/modal' import { BubbleX } from '@/app/components/base/icons/src/vender/line/others' import CodeEditor from '@/app/components/workflow/nodes/_base/components/editor/code-editor' import { - Clipboard, - ClipboardCheck, + Copy, + CopyCheck, } from '@/app/components/base/icons/src/vender/line/files' import { useStore } from '@/app/components/workflow/store' import type { @@ -122,10 +122,10 @@ const ConversationVariableModal = ({
{!isCopied ? ( - + ) : ( - + ) }