From 71f6245a016f6ced0c6929f4d5ea119a243ad01b Mon Sep 17 00:00:00 2001 From: tecvan <84165678+Tecvan-fe@users.noreply.github.com> Date: Thu, 31 Jul 2025 10:32:15 +0800 Subject: [PATCH] chore: replace all cn comments of fe to en version by volc api (#320) --- frontend/apps/coze-studio/rsbuild.config.ts | 4 +- frontend/apps/coze-studio/src/index.tsx | 6 +- .../src/routes/async-components.tsx | 44 +- .../apps/coze-studio/src/routes/index.tsx | 26 +- frontend/apps/coze-studio/tailwind.config.ts | 4 +- .../config/eslint-config/eslint.config.web.js | 2 +- .../eslint-config/rules/common-standard.js | 4 +- frontend/config/eslint-config/rules/import.js | 6 +- .../config/eslint-config/rules/ts-standard.js | 18 +- .../config/eslint-config/scripts/reslint.sh | 2 +- .../config/eslint-config/scripts/rprettier.sh | 2 +- frontend/config/eslint-config/src/index.js | 4 +- frontend/config/rsbuild-config/src/index.ts | 4 +- .../config/stylelint-config/.stylelintrc.js | 4 +- frontend/config/tailwind-config/src/coze.js | 4 +- frontend/config/tailwind-config/src/dark.js | 2 +- .../tailwind-config/src/design-token.ts | 4 +- frontend/config/tailwind-config/src/light.js | 8 +- .../tailwind-config/src/tailwind-contents.ts | 2 +- frontend/config/ts-config/scripts/rtsc.sh | 2 +- frontend/config/ts-config/tsconfig.base.json | 2 +- .../config/vitest-config/src/define-config.ts | 2 +- .../vitest-config/src/preset-default.ts | 6 +- frontend/disallowed_3rd_libraries.json | 8 +- frontend/infra/eslint-plugin/src/index.ts | 8 +- .../src/rules/max-lines-per-function/index.ts | 18 +- .../src/rules/no-duplicated-deps/index.ts | 2 +- .../src/rules/no-pkg-dir-import/index.ts | 10 +- .../no-pkg-dir-import/test/index.test.ts | 16 +- .../src/rules/package-disallow-deps/index.ts | 2 +- .../src/rules/tsx-no-leaked-render/index.ts | 4 +- .../rules/prefer-shallow/index.test.ts | 2 +- .../idl/idl-parser/__tests__/demo.thrift.ts | 4 +- .../idl/idl-parser/__tests__/demo.unify.ts | 4 +- .../infra/idl/idl-parser/src/unify/proto.ts | 2 +- frontend/infra/idl/idl2ts-cli/src/mock-dev.ts | 2 +- .../src/plugins/filter-types-plugin.ts | 2 +- .../idl/idl2ts-cli/src/plugins/mock-plugin.ts | 14 +- frontend/infra/idl/idl2ts-cli/src/types.ts | 24 +- .../infra/idl/idl2ts-generator/src/core.ts | 2 +- .../src/plugin/adapter-plugin.ts | 16 +- .../src/plugin/client-plugin.ts | 2 +- .../src/plugin/comment-format-plugin.ts | 2 +- .../src/plugin/ignore-struct-field.ts | 2 +- .../src/plugin/meta-plugin.ts | 8 +- .../src/plugin/mock-transformer.ts | 18 +- .../src/plugin/pkg-entry-plugin.ts | 4 +- .../src/plugin/schema-plugin.ts | 6 +- .../infra/idl/idl2ts-generator/src/types.ts | 6 +- frontend/infra/idl/idl2ts-helper/src/ctx.ts | 10 +- .../infra/idl/idl2ts-helper/src/helper.ts | 10 +- .../infra/idl/idl2ts-plugin/src/program.ts | 12 +- .../idl/idl2ts-runtime/src/create-api.ts | 22 +- .../infra/idl/idl2ts-runtime/src/types.ts | 10 +- .../infra/idl/idl2ts-runtime/src/utils.ts | 22 +- .../__tests__/index.test.ts | 18 +- .../pkg-root-webpack-plugin/lib/index.js | 2 +- .../pkg-root-webpack-plugin/src/index.ts | 2 +- .../infra/utils/monorepo-kits/docs/llms.txt | 88 ++-- frontend/infra/utils/rush-logger/src/index.ts | 2 +- .../bot-publish/hooks/use-auth-fail.ts | 2 +- .../bot-publish/hooks/use-get-bot-info.ts | 6 +- .../src/components/bot-publish/index.tsx | 2 +- .../bot-publish/publish-result/index.tsx | 6 +- .../table-collection/config-status.tsx | 6 +- .../connector-action/store-bind.tsx | 4 +- .../hooks/use-auth-success.ts | 2 +- .../publish-table/table-collection/index.tsx | 12 +- .../table-collection/plugin-limit-tooltip.tsx | 2 +- .../single-agent-model-view/index.tsx | 2 +- .../src/query-collect/utils.ts | 4 +- .../src/store/dataset.ts | 4 +- .../src/store/free-grab-modal-hierarchy.ts | 4 +- .../src/store/model.ts | 12 +- .../onboarding-dirty-logic-compatibility.ts | 2 +- .../src/utils/model-capability/index.ts | 4 +- .../utils/model/convert-model-value-type.ts | 2 +- .../__tests__/services.test.ts | 40 +- .../src/services/type.ts | 14 +- .../bot-plugin/entry/__tests__/setup.ts | 20 +- .../entry/__tests__/util/get-env.test.ts | 28 +- .../components/plugin-apis/plugin-modal.tsx | 2 +- .../plugin-apis/use-plugin-apis-modal.tsx | 2 +- .../components/plugin-tool-detail/index.tsx | 24 +- .../plugin-tool-detail/tool-header.tsx | 4 +- .../use-content-base-more.tsx | 6 +- .../use-content-baseinfo.tsx | 6 +- .../plugin-tool-detail/use-content-debug.tsx | 4 +- .../use-content-request.tsx | 6 +- .../use-content-response.tsx | 8 +- .../src/hooks/auth/use-auth-for-api-tool.ts | 4 +- .../pages/mock-set-detail/index.module.less | 2 +- .../entry/src/pages/mock-set-detail/index.tsx | 18 +- .../entry/src/pages/mock-set/index.tsx | 22 +- .../entry/src/pages/plugin-id/create-tool.tsx | 6 +- .../entry/src/pages/plugin-id/index.tsx | 30 +- .../content/index.tsx | 14 +- .../agent-skill-plugin-modal/hooks.tsx | 20 +- .../agent-skill-plugin-modal/sider/index.tsx | 6 +- .../use-request-cache.tsx | 2 +- .../src/component/bot_edit/bot-code-edit.tsx | 4 +- .../bot_edit/bot-form-edit/index.tsx | 4 +- .../component/file-import/import-content.tsx | 2 +- .../src/component/file-import/index.tsx | 2 +- .../plugin-info-confirm/fields.tsx | 10 +- .../file-import/plugin-info-confirm/index.tsx | 20 +- .../file-import/plugin-info-confirm/utils.ts | 4 +- .../export/src/component/file-import/utils.ts | 4 +- .../use-mock-set-in-setting-modal.test.ts | 26 +- .../hook/mock-set/use-save-mock-data.test.ts | 2 +- .../bot-plugin/mock-set/__tests__/setup.ts | 20 +- .../mock-set/src/component/const.ts | 2 +- .../src/component/hooks/use-get-mockset.ts | 2 +- .../mock-set/src/component/index.module.less | 6 +- .../src/component/mock-data-card/index.tsx | 2 +- .../src/component/mock-data-create-card.tsx | 12 +- .../mock-set/src/component/mock-data-list.tsx | 12 +- .../component/mock-data-page-breadcrumb.tsx | 4 +- .../src/component/mock-select/index.tsx | 4 +- .../component/mockset-delete-modal/index.tsx | 2 +- .../mock-set/src/hook/use-gen-tree-branch.ts | 4 +- .../src/hook/use-mock-set-in-setting-modal.ts | 2 +- .../mock-set/src/hook/use-save-mock-data.ts | 2 +- .../mock-set/src/hook/use-trans-schema.ts | 16 +- .../bot-plugin/mock-set/src/util/typings.ts | 16 +- .../bot-plugin/mock-set/src/util/utils.ts | 26 +- .../plugin-risk-warning/src/store.ts | 2 +- ...meters-in-setting-modal-controller.test.ts | 2 +- .../__tests__/plugin_modal/utils.test.ts | 40 +- .../components/info_popover/info-popover.tsx | 8 +- .../src/components/plugin_modal/base-info.tsx | 2 +- .../src/components/plugin_modal/base-more.tsx | 2 +- .../components/cascader-item/index.tsx | 4 +- .../components/file-upload-item/index.tsx | 4 +- .../src/components/plugin_modal/config.ts | 24 +- .../debug-components/debug-check.tsx | 2 +- .../debug-components/debug-params.tsx | 4 +- .../params-form/columns/param-value-col.tsx | 2 +- .../debug-components/params-form/index.tsx | 14 +- .../src/components/plugin_modal/debug.tsx | 4 +- .../plugin_modal/input-and-variable/index.tsx | 2 +- .../columns/param-type-col.tsx | 6 +- .../params-components/default-value-input.tsx | 8 +- .../params-components/form-components.tsx | 16 +- .../plugin_modal/params-components/index.tsx | 40 +- .../plugin_modal/request-params.tsx | 10 +- .../plugin_modal/response-params.tsx | 6 +- .../src/components/plugin_modal/utils.ts | 94 ++-- .../tools/src/hooks/example/utils.ts | 6 +- .../message-box-action-bar/index.tsx | 6 +- .../src/index.ts | 6 +- .../src/plugin.ts | 12 +- .../src/services/life-cycle/message.ts | 2 +- .../src/utils/index.ts | 4 +- .../hooks/use-bot-editor-chat-background.ts | 4 +- .../cropper-upload/cropper-cover/index.tsx | 2 +- .../cropper-upload/cropper/index.tsx | 12 +- .../cropper-upload/index.tsx | 4 +- .../chat-background-config-content/index.tsx | 6 +- .../__tests__/util.test.ts | 6 +- .../src/hooks/use-background-content.ts | 16 +- .../src/hooks/use-crop-image.ts | 16 +- .../src/hooks/use-submit-cropped-image.ts | 4 +- .../chat-background-shared/src/utils/index.ts | 16 +- .../use-chat-background-uploader/index.tsx | 4 +- .../onboarding-message-pop/index.tsx | 6 +- .../agent-ide/chat-debug-area/src/index.tsx | 4 +- .../src/plugins/shortcut/index.tsx | 6 +- .../agent-ide/commons/src/constants/index.ts | 6 +- .../components/tool-pane/index.tsx | 38 +- .../single-mode-tool-pane-list/index.tsx | 4 +- .../workflow-mode-tool-pane-list/index.tsx | 2 +- .../entry-adapter/src/editor/agent-editor.tsx | 6 +- .../shortcut-skills-modal/index.tsx | 4 +- .../entry/src/modes/single-mode/index.tsx | 2 +- .../agent-config-area/tool-area.tsx | 14 +- .../entry/src/modes/workflow-mode/index.tsx | 8 +- .../layout-adapter/src/header/index.tsx | 12 +- .../header/bot-status/origin-status.tsx | 2 +- .../layout/src/components/header/index.tsx | 8 +- .../header/more-menu-button/index.tsx | 12 +- .../more-menu-button/link-drop-item.tsx | 2 +- .../packages/agent-ide/layout/src/layout.tsx | 8 +- .../src/components/memory-tool-pane/index.tsx | 4 +- .../get-fixed-single-agent-schema.test.ts | 2 +- .../model-capability-confirm-model/base.tsx | 8 +- .../model-capability-confirm-model/index.tsx | 24 +- .../model-form/group-item/index.tsx | 6 +- .../src/components/model-form/index.tsx | 4 +- .../model-form/model-select/index.tsx | 2 +- .../model-select/ui-model-select.tsx | 12 +- .../model-option-avatar/index.tsx | 26 +- .../model-option-group/index.tsx | 4 +- .../model-option-thumb/index.tsx | 2 +- .../model-select-v2/model-option/index.tsx | 26 +- .../model-select-v2/model-select-ui/index.tsx | 48 +- .../model-select-v2/model-select/index.tsx | 14 +- .../popover-model-config-view/index.tsx | 30 +- .../popover-model-list-view/index.tsx | 12 +- .../context/model-form-context/context.tsx | 2 +- .../src/context/model-form-context/type.ts | 4 +- .../hooks/model-form/use-handle-model-form.ts | 28 +- .../src/utils/field-init-strategy.ts | 8 +- .../model-func-config-check/agent-check.ts | 2 +- .../model/convert-form-value-to-model-info.ts | 2 +- .../model/get-fixed-model-form-values.ts | 6 +- .../utils/model/get-model-class-sort-list.ts | 2 +- .../navigate/src/hooks/navigate-tools-page.ts | 4 +- .../components/insert-link-popover/index.tsx | 2 +- .../helpers/get-insert-text.ts | 2 +- .../hooks/use-markdown-editor.ts | 2 +- .../markdown-editor/hooks/use-upload-file.ts | 2 +- .../src/components/markdown-editor/index.tsx | 4 +- .../markdown-description-popover/index.tsx | 4 +- .../onboarding-markdown-modal/index.tsx | 2 +- .../src/utils/onboarding-variable.ts | 4 +- .../onboarding/src/utils/onboarding.ts | 4 +- .../src/components/plugin-content/index.tsx | 14 +- .../components/plugin-modal/filter/index.tsx | 4 +- .../plugin-modal/plugin-filter/index.tsx | 2 +- .../agent-skill-setting-modal/index.tsx | 6 +- .../agent-skill-setting-modal/part-main.tsx | 2 +- .../part-params-set/index.tsx | 6 +- .../src/components/plugin-panel/index.tsx | 26 +- .../src/components/plugin-panel/item.tsx | 4 +- .../plugin-shared/src/service/fetch-plugin.ts | 12 +- .../src/types/plugin-modal-types.ts | 38 +- .../prompt-editor/agent-ide-prompt/index.tsx | 2 +- .../src/expection-display/index.tsx | 4 +- .../field-line/input-config-line.tsx | 2 +- .../field-line/output-struct-line.tsx | 20 +- .../methods/slice-editor.test.ts | 10 +- .../agent-ide/space-bot/__tests__/setup.ts | 20 +- .../src/component/authorize-button/index.tsx | 6 +- .../src/component/auto-generate-btn/index.tsx | 6 +- .../connector-field/index.tsx | 6 +- .../connector-form/index.tsx | 4 +- .../connector-link/index.tsx | 2 +- .../use-connector-form-modal.tsx | 10 +- .../components/item-grid-view/index.tsx | 2 +- .../components/select-space-pane/index.tsx | 2 +- .../bot-move-modal/move-failed-modal.tsx | 16 +- .../component/bot-move-modal/move-modal.tsx | 18 +- .../src/component/chat-background/index.tsx | 2 +- .../component/collapsible-textarea/index.tsx | 20 +- .../connector-action/kv-bind-button.tsx | 12 +- .../components/group-wrapper/index.tsx | 2 +- .../src/component/data-memory/hooks.tsx | 10 +- .../data-memory/memory-add-modal.tsx | 8 +- .../data-memory/utils/exhaustive-check.ts | 2 +- .../src/component/data-set/data-set-area.tsx | 8 +- .../component/input-slider/input-slider.tsx | 2 +- .../component/mode-select/change-button.tsx | 2 +- .../src/component/mode-select/index.tsx | 4 +- .../hooks/use-init-editor.ts | 2 +- .../onboarding-editor/index.tsx | 12 +- .../onboarding-editor/method/slice-editor.ts | 2 +- .../hooks/use-add-empty-suggestion.ts | 2 +- .../suggestion-list/suggestion-item.tsx | 6 +- .../publish-platform-setting/index.tsx | 8 +- .../rc-slider-wrapper/handle-render.tsx | 2 +- .../sheet-view/multiple-sheet/index.tsx | 8 +- .../sheet-view/single-sheet/index.tsx | 4 +- .../suggestion-content.module.less | 4 +- .../suggestion-content/suggestion-content.tsx | 12 +- .../src/component/table-memory/index.tsx | 14 +- .../agent-ide/space-bot/src/constant.ts | 4 +- .../agent-ide/space-bot/src/hook/index.ts | 22 +- .../src/hook/tools-publish-back-modal.ts | 20 +- .../use-create-bot/use-agent-persistence.ts | 4 +- .../space-bot/src/hook/use-edit-confirm.ts | 6 +- .../agent-ide/space-bot/src/hook/use-init.tsx | 32 +- .../src/hook/use-monetize-config-readonly.ts | 4 +- .../space-bot/src/hook/use-node-id.ts | 18 +- .../index.ts | 2 +- .../index.ts | 2 +- .../space-bot/src/store/bot-mode/index.ts | 2 +- .../space-bot/src/store/debug-panel/store.ts | 4 +- .../space-bot/src/store/risk-warning/store.ts | 2 +- .../packages/agent-ide/space-bot/src/type.ts | 14 +- .../agent-ide/space-bot/src/util/index.ts | 16 +- .../get-strict-shortcuts.test.ts | 8 +- .../agent-ide/tool-config/src/constants.ts | 2 +- .../agent-ide/tool-config/src/types.ts | 6 +- .../agent-skill-content-block/index.tsx | 16 +- .../src/components/agent-skill-view/index.tsx | 2 +- .../components/grouping-container/index.tsx | 4 +- .../model-capability-tips/index.tsx | 10 +- .../src/components/tool-container/index.tsx | 2 +- .../components/tool-content-block/index.tsx | 16 +- .../src/components/tool-item-action/index.tsx | 2 +- .../tool/src/components/tool-item/index.tsx | 14 +- .../tool/src/components/tool-view/index.tsx | 4 +- .../tool/src/constants/tool-content-block.ts | 2 +- .../tool/src/context/ability-area-context.tsx | 2 +- .../tool/src/context/preference-context.tsx | 4 +- .../use-agent-modal-trigger-event.ts | 2 +- .../src/hooks/agent-skill/use-agent-skill.ts | 4 +- .../src/hooks/builtin/use-ability-config.ts | 2 +- .../builtin/use-register-agent-skill-key.ts | 2 +- .../hooks/builtin/use-register-tool-key.ts | 2 +- .../use-tool-content-block-default-expand.tsx | 20 +- .../public/container/use-tool-valid-data.ts | 4 +- .../src/hooks/public/store/use-tool-store.ts | 18 +- .../hooks/tool/use-tool-toggle-collapse.ts | 2 +- frontend/packages/agent-ide/tool/src/index.ts | 12 +- .../agent-ide/tool/src/store/agent-area.ts | 4 +- .../tool/src/typings/scoped-events.ts | 10 +- .../model-function-config-type-mapping.ts | 4 +- .../tool/src/utils/tool-content-block.ts | 4 +- .../components/workflow-card/add-button.tsx | 4 +- .../src/components/workflow-card/index.tsx | 4 +- .../src/hooks/use-navigate-workflow.ts | 2 +- .../src/components/workflow-modal/base.tsx | 6 +- .../src/components/workflow-modal/hooks.tsx | 6 +- .../use-agent-workflow-modal.tsx | 6 +- .../packages/arch/api-schema/api.config.js | 10 +- .../product_common.ts | 82 +-- .../flow/marketplace/marketplace_common.ts | 14 +- .../api-schema/src/idl/passport/passport.ts | 12 +- .../arch/bot-api/__tests__/axios.test.ts | 44 +- .../arch/bot-api/__tests__/basic-api.test.ts | 8 +- frontend/packages/arch/bot-api/src/axios.ts | 6 +- .../arch/bot-env-adapter/scripts/build.ts | 22 +- .../packages/arch/bot-env-adapter/src/base.ts | 16 +- .../arch/bot-env-adapter/src/configs.ts | 14 +- .../arch/bot-env-adapter/src/features.ts | 20 +- .../arch/bot-env-adapter/src/typings.d.ts | 3 +- .../src/utils/current-branch.ts | 14 +- .../packages/arch/bot-env/src/global.d.ts | 18 +- .../bot-error/__tests__/certain-error.test.ts | 4 +- .../arch/bot-error/src/certain-error.ts | 14 +- frontend/packages/arch/bot-error/src/const.ts | 22 +- .../arch/bot-error/src/custom-error.ts | 2 +- .../arch/bot-error/src/use-error-catch.ts | 2 +- .../bot-error/src/use-route-error-catch.ts | 4 +- .../__tests__/pull-feature-flags.test.ts | 2 +- .../arch/bot-flags/src/pull-feature-flags.ts | 38 +- frontend/packages/arch/bot-flags/src/types.ts | 4 +- .../packages/arch/bot-flags/src/use-flags.ts | 2 +- .../arch/bot-flags/src/utils/persist-cache.ts | 2 +- .../arch/bot-flags/src/utils/storage.ts | 2 +- .../arch/bot-flags/src/utils/tools.ts | 10 +- .../arch/bot-hooks-adapter/src/global.d.ts | 2 +- .../bot-hooks-adapter/src/use-responsive.ts | 2 +- .../__tests__/use-line-clamp.test.tsx | 8 +- .../bot-hooks-base/src/editor-layout/index.ts | 2 +- .../arch/bot-hooks-base/src/global.d.ts | 2 +- .../src/router/use-reset-location-state.ts | 4 +- .../bot-hooks-base/src/use-component-state.ts | 6 +- .../src/use-default-expand-check/index.ts | 22 +- .../src/use-drag-and-paste-upload/index.ts | 30 +- .../arch/bot-hooks-base/src/use-exposure.ts | 14 +- .../arch/bot-hooks-base/src/use-loggedin.ts | 2 +- .../arch/bot-hooks-base/src/use-page-state.ts | 6 +- .../bot-hooks-base/src/use-route-config.ts | 42 +- .../bot-hooks/__tests__/page-jump.test.tsx | 2 +- .../packages/arch/bot-hooks/src/global.d.ts | 2 +- .../arch/bot-hooks/src/page-jump/config.ts | 150 +++--- .../arch/bot-hooks/src/page-jump/index.ts | 58 +-- .../packages/arch/bot-http/src/api-error.ts | 4 +- frontend/packages/arch/bot-http/src/axios.ts | 18 +- .../packages/arch/bot-http/src/eventbus.ts | 12 +- .../arch/bot-space-api/src/global.d.ts | 2 +- .../packages/arch/bot-space-api/src/index.ts | 6 +- .../arch/bot-space-api/src/space-api-v2.ts | 2 +- .../bot-store/__tests__/auth/index.test.tsx | 20 +- .../__tests__/space-gray/index.test.ts | 26 +- .../__tests__/utils/get-storage.test.ts | 2 +- .../arch/bot-store/src/auth/index.tsx | 22 +- .../arch/bot-store/src/data_item.d.ts | 6 +- frontend/packages/arch/bot-store/src/index.ts | 8 +- .../arch/bot-store/src/space-gray/index.ts | 2 +- .../arch/bot-store/src/utils/get-storage.ts | 4 +- .../arch/bot-tea/__tests__/index.test.ts | 9 +- frontend/packages/arch/bot-tea/src/index.ts | 14 +- .../packages/arch/bot-typings/src/common.ts | 14 +- .../arch/bot-typings/src/data_item.d.ts | 6 +- .../arch/bot-typings/src/teamspace.ts | 2 +- .../packages/arch/bot-typings/src/window.d.ts | 2 +- .../arch/bot-utils/__tests__/date.test.ts | 6 +- .../__tests__/responsive-table-column.test.ts | 14 +- frontend/packages/arch/bot-utils/src/array.ts | 26 +- frontend/packages/arch/bot-utils/src/date.ts | 36 +- frontend/packages/arch/bot-utils/src/dom.ts | 4 +- .../arch/bot-utils/src/event-handler.ts | 28 +- .../arch/bot-utils/src/get-report-error.ts | 4 +- frontend/packages/arch/bot-utils/src/index.ts | 2 +- .../arch/bot-utils/src/message-report.ts | 6 +- .../packages/arch/bot-utils/src/number.ts | 14 +- .../packages/arch/bot-utils/src/platform.ts | 8 +- .../bot-utils/src/post-message-channel.ts | 2 +- .../bot-utils/src/responsive-table-column.ts | 4 +- .../arch/bot-utils/src/safe-json-parse.ts | 2 +- frontend/packages/arch/bot-utils/src/skill.ts | 4 +- .../arch/bot-utils/src/upload-file-v2.ts | 24 +- .../arch/bot-utils/src/upload-file.ts | 10 +- .../arch/fetch-stream/src/fetch-stream.ts | 66 +-- .../packages/arch/fetch-stream/src/type.ts | 46 +- .../packages/arch/fetch-stream/src/utils.ts | 6 +- .../packages/arch/foundation-sdk/src/index.ts | 62 +-- .../arch/foundation-sdk/src/types/layout.ts | 14 +- .../arch/foundation-sdk/src/types/passport.ts | 22 +- .../arch/foundation-sdk/src/types/user.ts | 6 +- .../__tests__/index.test.ts | 2 +- .../hooks/src/use-state-realtime/index.ts | 2 +- .../arch/hooks/src/use-url-params/index.ts | 6 +- .../__tests__/i18n-provider/context.test.tsx | 16 +- .../__tests__/i18n-provider/index.test.tsx | 8 +- .../arch/i18n/__tests__/raw/index.test.ts | 2 +- frontend/packages/arch/i18n/src/index.ts | 12 +- .../packages/arch/i18n/src/intl/i18n-impl.ts | 8 +- frontend/packages/arch/i18n/src/intl/i18n.ts | 18 +- frontend/packages/arch/i18n/src/intl/types.ts | 6 +- frontend/packages/arch/idl/src/index.ts | 2 +- .../__tests__/index.test.ts | 14 +- .../load-remote-worker/__tests__/setup.ts | 10 +- .../arch/load-remote-worker/src/index.ts | 10 +- .../arch/logger/src/console-disable.ts | 4 +- .../arch/logger/src/error-boundary/index.tsx | 20 +- frontend/packages/arch/logger/src/index.ts | 6 +- .../packages/arch/logger/src/logger/logger.ts | 6 +- .../arch/logger/src/reporter/index.ts | 24 +- .../packages/arch/logger/src/slardar/index.ts | 18 +- .../arch/logger/src/slardar/runtime.ts | 2 +- .../packages/arch/logger/src/slardar/utils.ts | 4 +- .../packages/arch/logger/src/types/index.ts | 62 +-- .../__tests__/generate-assets.test.ts | 22 +- .../arch/pdfjs-shadow/__tests__/index.test.ts | 10 +- .../__tests__/init-pdfjs-dist.test.ts | 28 +- .../arch/pdfjs-shadow/scripts/build-assets.ts | 12 +- .../arch/pdfjs-shadow/src/generate-assets.ts | 4 +- .../arch/pdfjs-shadow/src/init-pdfjs-dist.ts | 2 +- .../arch/report-events/src/common-error.ts | 22 +- .../arch/report-events/src/feature-event.ts | 28 +- .../report-events/src/interaction-event.ts | 18 +- .../arch/report-events/src/knowledge-event.ts | 4 +- .../arch/report-events/src/report-event.ts | 34 +- .../arch/report-tti/__tests__/index.test.tsx | 4 +- .../utils/custom-perf-metric.test.ts | 120 ++--- .../packages/arch/report-tti/src/global.d.ts | 2 +- .../packages/arch/report-tti/src/index.ts | 6 +- .../src/utils/custom-perf-metric.ts | 18 +- .../studio-i18n-resource/src/index.ts | 2 +- .../components/layout/ResponsiveBox.test.tsx | 6 +- .../components/layout/ResponsiveList.test.tsx | 6 +- .../__tests__/hooks/media-query.test.ts | 36 +- .../__tests__/utils/token-map-to-str.test.ts | 2 +- .../src/components/layout/ResponsiveList.tsx | 8 +- .../responsive-kit/src/hooks/media-query.ts | 6 +- .../arch/slardar-interface/src/index.ts | 2 +- .../arch/tea-adapter/__tests__/index.test.ts | 4 +- .../packages/arch/tea-interface/src/events.ts | 466 +++++++++--------- .../url/__tests__/parse-hash-or-query.test.ts | 2 +- .../__tests__/const/community.test.ts | 6 +- .../__tests__/const/custom.test.ts | 6 +- .../web-context/__tests__/global-var.test.ts | 8 +- .../arch/web-context/src/const/app.ts | 24 +- .../arch/web-context/src/const/custom.ts | 4 +- .../arch/web-context/src/event-bus.ts | 24 +- .../arch/web-context/src/global-var.ts | 6 +- .../packages/arch/web-context/src/index.ts | 2 +- .../packages/arch/web-context/src/location.ts | 2 +- .../project/use-init-project-role.test.ts | 6 +- .../space/use-init-space-role.test.ts | 6 +- .../src/project/use-init-project-role.ts | 2 +- .../src/space/use-init-space-role.ts | 2 +- .../__tests__/project/calc-permission.test.ts | 108 ++-- .../auth/__tests__/project/constants.test.ts | 20 +- .../auth/__tests__/project/store.test.ts | 14 +- .../project/use-destory-project.test.ts | 44 +- .../project/use-project-auth.test.ts | 48 +- .../project/use-project-role.test.ts | 32 +- .../__tests__/space/calc-permission.test.ts | 56 +-- .../auth/__tests__/space/constants.test.ts | 12 +- .../common/auth/__tests__/space/store.test.ts | 26 +- .../__tests__/space/use-destory-space.test.ts | 34 +- .../__tests__/space/use-space-auth.test.ts | 34 +- .../__tests__/space/use-space-role.test.ts | 48 +- .../common/auth/src/project/constants.ts | 26 +- .../packages/common/auth/src/project/store.ts | 12 +- .../auth/src/project/use-destory-project.ts | 2 +- .../auth/src/project/use-project-auth.ts | 8 +- .../common/auth/src/space/constants.ts | 20 +- .../packages/common/auth/src/space/store.ts | 12 +- .../auth/src/space/use-destory-space.ts | 2 +- .../common/auth/src/space/use-space-auth.ts | 4 +- .../common/auth/src/space/use-space-role.ts | 2 +- .../packages/common/auth/vitest.config.ts | 8 +- .../biz-components/src/coachmark/index.tsx | 12 +- .../line-component/index.module.less | 4 +- .../components/line-component/index.tsx | 4 +- .../components/param-description/index.tsx | 2 +- .../components/param-operator/index.tsx | 2 +- .../components/param-type/index.tsx | 2 +- .../components/workflow-sl-textarea/index.tsx | 10 +- .../components/custom-tree-node/index.tsx | 28 +- .../components/custom-tree-node/type.ts | 32 +- .../parameters/components/header/index.tsx | 2 +- .../src/parameters/constants.ts | 8 +- .../src/parameters/parameters.tsx | 24 +- .../biz-components/src/parameters/types.ts | 22 +- .../utils/convert-map-to-options.ts | 12 +- .../src/parameters/utils/utils.ts | 16 +- .../picture-upload/auto-generate/index.tsx | 12 +- .../src/picture-upload/picture-upload.tsx | 16 +- .../utils/custom-upload-request.ts | 6 +- .../components/intelligence-list.tsx | 6 +- .../intelligence-search.service.ts | 2 +- .../src/update-user-avatar/index.tsx | 2 +- .../stories/parameters/valid-value.ts | 4 +- .../action-bar-hover-container/index.tsx | 2 +- .../components/copy-text-message/index.tsx | 8 +- .../src/components/delete-message/index.tsx | 2 +- .../src/components/frown-upon/index.tsx | 10 +- .../src/components/more-operations/index.tsx | 2 +- .../src/components/quote-message/index.tsx | 6 +- .../src/components/thumbs-up/index.tsx | 2 +- .../src/hooks/use-dispatch-mouse-leave.ts | 8 +- .../src/hooks/use-report-message-feedback.ts | 24 +- .../src/report-events/index.ts | 6 +- .../src/utils/get-show-feedback.ts | 4 +- .../src/utils/get-show-regenerate.ts | 4 +- .../message-inner-addon-bottom/index.tsx | 2 +- .../chat-area-plugin-reasoning/src/index.ts | 6 +- .../chat-area-plugin-reasoning/src/plugin.ts | 14 +- .../chat-area/__tests__/messages.test.ts | 8 +- .../load-more/message-index-helper.test.ts | 2 +- .../utils/find-respond-record.test.ts | 14 +- .../__tests__/utils/proxy-freeze.test.ts | 4 +- .../chat-area/__tests__/waiting.test.ts | 58 +-- .../chat-area/src/chat-area-main/index.tsx | 4 +- .../src/components/chat-input/index.tsx | 6 +- .../src/components/content-box/index.tsx | 4 +- .../src/components/context-divider/index.tsx | 2 +- .../collapse-panel-header.tsx | 12 +- .../collapse-panel-with-header.tsx | 10 +- .../function-call-message.tsx | 24 +- .../function-call-content/index.module.less | 2 +- .../function-call-content/index.tsx | 2 +- .../knowledge-recall/index.tsx | 2 +- .../components/fuction-call-message/index.tsx | 6 +- .../src/components/load-more/load-more.tsx | 2 +- .../components/message-box/actions/index.tsx | 2 +- .../src/components/message-box/index.tsx | 26 +- .../components/message-group-list/index.tsx | 2 +- .../components/message-group/body/index.tsx | 4 +- .../message-group/wrapper/index.tsx | 2 +- .../components/onborading-message/index.tsx | 2 +- .../components/plugin-async-quote/index.tsx | 8 +- .../src/components/preview/index.tsx | 2 +- .../src/components/send-message-box/index.tsx | 4 +- .../src/components/suggestion/index.tsx | 12 +- .../chat-area/src/components/types.ts | 26 +- .../chat-area/src/constants/agent.ts | 4 +- .../chat-area/src/constants/message.ts | 6 +- .../chat-area/src/constants/scroll-list.ts | 2 +- .../after-init-service-context.tsx | 2 +- .../chat-area-context/chat-area-callback.ts | 14 +- .../helpers/generate-chat-core-props.ts | 2 +- .../chat-area-context/provider-new.tsx | 4 +- .../context/chat-area-context/provider.tsx | 2 +- .../src/context/chat-area-context/type.ts | 34 +- .../chat-area-custom-component-context.tsx | 2 +- .../context/load-more/load-more-context.tsx | 2 +- .../src/context/message-box/context.tsx | 4 +- .../src/context/message-box/index.ts | 4 +- .../src/context/message-box/provider.tsx | 4 +- .../chat-area/src/context/preference/types.ts | 80 +-- .../load-more/listen-message-length-change.ts | 4 +- .../load-more/use-prepare-load-more.ts | 4 +- .../hooks/context/use-chat-area-context.ts | 4 +- .../context/use-create-chat-area-store.ts | 4 +- .../hooks/context/use-method-common-deps.ts | 2 +- .../controller/use-chat-area-controller.ts | 2 +- .../src/hooks/file/use-drag-upload.ts | 16 +- .../src/hooks/file/use-paste-upload.ts | 6 +- .../src/hooks/file/use-validate-file-list.ts | 2 +- .../use-create-and-update-init-service.ts | 2 +- .../src/hooks/init/use-init-chat-area.ts | 20 +- .../messages/use-anwer-message-helper.ts | 2 +- .../src/hooks/messages/use-clear-context.ts | 10 +- .../src/hooks/messages/use-clear-history.ts | 4 +- .../messages/use-delete-message-group.ts | 2 +- .../hooks/messages/use-mark-message-read.ts | 6 +- .../hooks/messages/use-reset-to-newest-tip.ts | 2 +- .../messages/use-send-message/new-message.ts | 10 +- .../messages/use-send-message/regenerate.ts | 2 +- .../messages/use-send-message/text-message.ts | 2 +- .../src/hooks/public/use-bot-info.ts | 2 +- .../src/hooks/public/use-messages-overview.ts | 4 +- .../public/use-onboarding-center-offset.ts | 2 +- .../src/hooks/uikit/use-background-scroll.ts | 8 +- .../common/chat-area/chat-area/src/index.tsx | 8 +- .../src/plugin/constants/plugin-name.ts | 6 +- .../chat-area/src/plugin/constants/plugin.ts | 8 +- .../hooks/use-plugin-custom-components.ts | 2 +- .../plugin/life-cycle/app-life-cycle/index.ts | 2 +- .../life-cycle/command-life-cycle/index.ts | 2 +- .../life-cycle/message-life-cycle/index.ts | 2 +- .../life-cycle/render-life-cycle/index.ts | 2 +- .../src/plugin/plugin-class/plugin/index.ts | 20 +- .../service/app-life-cycle-service.ts | 58 +-- .../service/command-life-cycle-service.ts | 90 ++-- .../service/message-life-cycle-service.ts | 70 +-- .../service/render-life-cycle-service.ts | 6 +- .../types/plugin-class/command-life-cycle.ts | 2 +- .../types/plugin-class/render-life-cycle.ts | 6 +- .../src/plugin/types/register-plugin.ts | 10 +- .../plugin/utils/create-custom-component.ts | 2 +- .../plugin/utils/create-life-cycle-service.ts | 10 +- .../service/extend-data-lifecycle/index.ts | 4 +- .../service/fix-message/fix-image-message.ts | 4 +- .../service/fix-message/fix-message-struct.ts | 8 +- .../src/service/ignore-message/index.ts | 10 +- .../src/service/init-service/index.ts | 104 ++-- .../src/service/init-service/init-store.ts | 10 +- .../service/init-service/pre-init-store.ts | 2 +- .../src/service/listen-message-update.ts | 22 +- .../load-more/command/load-by-scroll.ts | 2 +- .../service/load-more/command/load-eagerly.ts | 4 +- .../command/on-initial-load-effect.ts | 14 +- .../helper/load-lock-error-helper.ts | 6 +- .../load-more/helper/message-index-helper.ts | 14 +- .../chat-area/src/service/load-more/index.ts | 18 +- .../service/load-more/load-more-env-tools.ts | 4 +- .../chat-area/src/store/batch-upload-file.ts | 4 +- .../chat-area/chat-area/src/store/file.ts | 6 +- .../chat-area/src/store/global-init.ts | 2 +- .../src/store/helpers/add-answer-location.ts | 2 +- .../store/helpers/add-message-deduplicate.ts | 2 +- .../src/store/helpers/add-verbose-info.ts | 2 +- .../src/store/helpers/get-bot-state.ts | 4 +- .../src/store/helpers/get-meta-by-message.ts | 2 +- .../src/store/helpers/group-message-list.ts | 8 +- .../src/store/helpers/hide-avatar.ts | 6 +- .../helpers/mark-group-context-divider.ts | 4 +- .../store/helpers/mutate-meta-by-groups.ts | 2 +- .../store/helpers/scan-meta-suggestions.ts | 2 +- .../src/store/helpers/split-section.ts | 12 +- .../chat-area/src/store/message-index.ts | 12 +- .../chat-area/src/store/message-meta.ts | 34 +- .../chat-area/chat-area/src/store/messages.ts | 26 +- .../chat-area/src/store/onboarding.ts | 6 +- .../chat-area/chat-area/src/store/plugins.ts | 2 +- .../chat-area/src/store/selection.ts | 4 +- .../chat-area/src/store/sender-info.ts | 8 +- .../chat-area/src/store/suggestions.ts | 2 +- .../chat-area/chat-area/src/store/types.ts | 78 +-- .../chat-area/chat-area/src/store/waiting.ts | 46 +- .../chat-area/src/typing/util-types.ts | 4 +- .../chat-area/src/utils/add-file-type.ts | 2 +- .../chat-area/chat-area/src/utils/array.ts | 2 +- .../chat-area/src/utils/batch-file-upload.ts | 2 +- .../get-receive-message-box-theme.ts | 2 +- .../src/utils/event-bus/uikit-event-bus.ts | 6 +- .../chat-area/src/utils/fake-chat-core.ts | 2 +- .../fucntion-call/function-message-unit.ts | 48 +- .../fucntion-call/get-is-function-calling.ts | 10 +- .../src/utils/fucntion-call/types.ts | 28 +- .../src/utils/function-call-message-type.ts | 2 +- .../src/utils/get-is-policy-exception.ts | 8 +- .../chat-area/src/utils/init-plugins.ts | 10 +- .../src/utils/message-group/message-group.ts | 8 +- .../src/utils/message-security-strategy.ts | 14 +- .../chat-area/chat-area/src/utils/message.ts | 32 +- .../chat-area/src/utils/proxy-freeze.ts | 2 +- .../chat-area/src/utils/resume-message.ts | 8 +- .../chat-area/src/utils/stop-responding.ts | 16 +- .../chat-area/src/utils/suggestions.ts | 4 +- .../chat-area/chat-area/src/utils/upload.ts | 12 +- .../chat-area/chat-area/src/utils/verbose.ts | 28 +- .../services/create-message-service.test.ts | 30 +- .../services/send-message-service.test.ts | 6 +- .../chat-core/__tests__/chunk-process.test.ts | 20 +- .../chat-area/chat-core/__tests__/setup.ts | 2 +- .../http-chunk/events/http-chunk-events.ts | 22 +- .../http-chunk/events/slardar-events.ts | 4 +- .../chat-core/src/channel/http-chunk/index.ts | 22 +- .../src/channel/http-chunk/types/index.ts | 4 +- .../chat-core/src/channel/http-chunk/utils.ts | 2 +- .../src/chat-sdk/events/sdk-events.ts | 2 +- .../src/chat-sdk/events/slardar-events.ts | 30 +- .../chat-area/chat-core/src/chat-sdk/index.ts | 54 +- .../services/create-message-service.ts | 10 +- .../chat-sdk/services/http-chunk-service.ts | 24 +- .../services/message-manager-service.ts | 14 +- .../src/chat-sdk/services/plugins-service.ts | 8 +- .../chat-sdk/services/send-message-service.ts | 30 +- .../chat-core/src/chat-sdk/types/interface.ts | 60 +-- .../chat-core/src/credential/token-manager.ts | 16 +- .../chat-core/src/custom-error/index.ts | 2 +- .../chat-core/src/message/chunk-processor.ts | 72 +-- .../src/message/events/slardar-events.ts | 16 +- .../chat-area/chat-core/src/message/index.ts | 4 +- .../chat-core/src/message/message-manager.ts | 30 +- .../presend-local-message-events-manager.ts | 14 +- .../presend-local-message-factory.ts | 50 +- .../presend-local-message.ts | 24 +- .../chat-core/src/message/types/index.ts | 174 +++---- .../src/message/types/message-manager.ts | 42 +- .../src/plugins/upload-plugin/index.ts | 6 +- .../upload-plugin/types/plugin-upload.ts | 20 +- .../chat-core/src/report-log/index.ts | 34 +- .../chat-core/src/request-manager/index.ts | 24 +- .../src/request-manager/request-config.ts | 4 +- .../chat-core/src/request-manager/types.ts | 2 +- .../chat-area/chat-core/src/shared/const.ts | 18 +- .../src/shared/utils/data-handler.ts | 2 +- .../chat-core/src/shared/utils/env.ts | 4 +- .../src/context/event-center/type.ts | 2 +- .../types/chat-input/audio-record/index.ts | 2 +- .../src/types/chat-input/index.ts | 64 +-- .../chat-input/input-native-callbacks.ts | 2 +- .../chat-uikit-shared/src/types/common.ts | 2 +- .../chat-uikit-shared/src/types/event.ts | 16 +- .../utils/get-image-display-attribute.test.ts | 14 +- .../audio-record/audio-wave/index.module.less | 2 +- .../components/more-button/index.tsx | 2 +- .../src/components/chat/chat-input/index.tsx | 10 +- .../chat/chat-input/use-text-area.ts | 6 +- .../src/components/chat/chat-upload/index.tsx | 18 +- .../src/components/chat/on-boarding/index.tsx | 4 +- .../chat/with-rule-img-background/index.tsx | 8 +- .../chat/with-rule-img-background/types.ts | 12 +- .../chat/with-rule-img-background/utils.ts | 6 +- .../components/common/content-box/index.tsx | 32 +- .../common/full-width-aligner/index.tsx | 2 +- .../common/message-box/message-box-wrap.tsx | 6 +- .../src/components/common/message-box/type.ts | 78 +-- .../components/common/user-label/index.tsx | 2 +- .../components/FileCard/index.tsx | 2 +- .../file-content/components/FileCard/type.ts | 12 +- .../contents/file-content/index.tsx | 8 +- .../contents/image-content/image-box.tsx | 2 +- .../multimodal-content/file-item-list.tsx | 6 +- .../multimodal-content/image-item-list.tsx | 2 +- .../contents/multimodal-content/index.tsx | 6 +- .../multimodal-content/text-item-list.tsx | 4 +- .../contents/plain-text-content/index.tsx | 2 +- .../single-image-content/auto-size.tsx | 12 +- .../contents/single-image-content/index.tsx | 14 +- .../single-image-content-ui.tsx | 2 +- .../components/md-box-slots/coze-image.tsx | 4 +- .../components/md-box-slots/link/index.tsx | 2 +- .../src/context/onboarding/index.ts | 2 +- .../src/hooks/use-audio-record-interaction.ts | 6 +- .../src/hooks/use-observe-card-container.ts | 2 +- .../chat-uikit/src/utils/date-time.ts | 2 +- .../image/get-image-display-attribute.ts | 16 +- .../chat-uikit/src/utils/is-apple-webkit.ts | 4 +- .../chat-uikit/src/utils/local-cache/type.ts | 2 +- .../chat-uikit/src/utils/platform.ts | 8 +- .../chat-uikit/src/utils/safe-json-parse.ts | 2 +- .../workflow-render/components/type.ts | 2 +- .../src/components/workflow-render/index.tsx | 2 +- .../src/hooks/use-imperative-layout-effect.ts | 2 +- .../chat-area/hooks/src/hooks/use-search.ts | 8 +- .../plugin-chat-background/src/index.ts | 2 +- .../__tests__/hooks/shortcut.test.ts | 8 +- .../choose-send-type-radio/method.test.ts | 2 +- .../components-table/method.test.ts | 4 +- .../src/components/load-more-list/index.tsx | 2 +- .../short-cut-panel/widgets/form/index.tsx | 2 +- .../short-cut-panel/widgets/index.tsx | 2 +- .../short-cut-panel/widgets/layout/index.tsx | 2 +- .../widgets/text-input/index.tsx | 2 +- .../short-cut-panel/widgets/types.ts | 4 +- .../short-cut-panel/widgets/upload/index.tsx | 22 +- .../src/hooks/shortcut.ts | 20 +- .../src/hooks/use-imperative-layout-effect.ts | 2 +- .../src/hooks/use-upload-plugin.ts | 14 +- .../plugin-chat-shortcuts/src/index.tsx | 2 +- .../src/shortcut-bar/index.tsx | 16 +- .../src/shortcut-bar/types/index.ts | 6 +- .../src/shortcut-template/index.tsx | 2 +- .../src/shortcut-tool/index.tsx | 2 +- .../shortcut-tool/shortcut-config/index.tsx | 8 +- .../shortcut-list/shortcut-item.tsx | 2 +- .../action-switch-area/index.tsx | 4 +- .../action-switch-area/method.ts | 2 +- .../action-switch-area/skill-switch/method.ts | 12 +- .../shortcut-edit/button-name/index.tsx | 2 +- .../button-name/shortcut-icon/icon-list.tsx | 4 +- .../component-default-value/index.tsx | 2 +- .../component-default-value/method.ts | 6 +- .../shortcut-edit/components-table/index.tsx | 20 +- .../shortcut-edit/components-table/method.ts | 20 +- .../components-table/table-components.tsx | 6 +- .../shortcut-edit/components.tsx | 4 +- .../src/shortcut-tool/shortcut-edit/method.ts | 30 +- .../src/shortcut-tool/shortcut-edit/modal.tsx | 10 +- .../shortcut-edit/switch-agent/index.tsx | 4 +- .../var-query-textarea/container.tsx | 4 +- .../var-query-textarea/index.tsx | 2 +- .../var-query-textarea/suggestion/index.tsx | 2 +- .../src/shortcut-tool/types.ts | 8 +- .../src/shortcut/query-shortcut/index.tsx | 2 +- .../src/utils/dsl-template/index.ts | 12 +- .../src/utils/dsl-template/templates.ts | 34 +- .../src/utils/file-const.ts | 8 +- .../src/utils/shortcut-query.ts | 4 +- .../src/utils/tool-params.ts | 12 +- .../plugin-chat-shortcuts/src/utils/uuid.ts | 6 +- .../plugin-message-grab/src/create.ts | 2 +- .../message-inner-top-slot/index.tsx | 2 +- .../message-inner-top-slot/local-slot.tsx | 2 +- .../message-inner-top-slot/remote-slot.tsx | 4 +- .../message-list-float-slot/grab-menu.tsx | 40 +- .../src/hooks/use-float-menu-listener.ts | 4 +- .../src/hooks/use-grab-plugin.ts | 4 +- .../src/services/life-cycle/app.ts | 2 +- .../src/types/plugin-biz-context.ts | 2 +- .../src/utils/extract-text-from-react-node.ts | 8 +- .../interrupt-message/index.tsx | 4 +- .../interrupt-message-content/index.tsx | 2 +- .../src/hooks/use-get-position.tsx | 4 +- .../__tests__/compare-node-position.test.ts | 6 +- .../find-ancestor-node-by-tag-name.test.ts | 4 +- .../__tests__/find-last-child-node.test.ts | 12 +- .../__tests__/find-last-sibling-node.test.ts | 2 +- .../__tests__/find-nearest-link-node.test.ts | 2 +- .../get-all-child-nodes-in-node.test.ts | 8 +- .../__tests__/get-all-node-in-range.test.ts | 12 +- .../__tests__/get-range-direction.test.ts | 6 +- .../chat-area/text-grab/src/hooks/use-grab.ts | 76 +-- .../utils/find-picture-valid-child-node.ts | 4 +- .../src/utils/get-picture-node-url.ts | 4 +- .../text-grab/src/utils/get-selection-data.ts | 18 +- .../src/utils/helper/compare-node-position.ts | 16 +- .../helper/find-ancestor-node-by-tag-name.ts | 14 +- .../src/utils/helper/find-last-child-node.ts | 2 +- .../utils/helper/find-last-sibling-node.ts | 4 +- .../utils/helper/find-nearest-link-node.ts | 10 +- .../find-not-contains-previous-sibling.ts | 4 +- .../helper/get-all-child-nodes-in-node.ts | 4 +- .../utils/helper/get-all-nodes-in-range.ts | 4 +- .../src/utils/helper/get-range-direction.ts | 2 +- .../utils/helper/get-selection-direction.ts | 16 +- .../src/utils/helper/is-range-collapsed.ts | 8 +- .../normalizer/get-humanize-content-text.ts | 2 +- .../normalizer/get-normalize-node-list.ts | 12 +- .../normalizer/get-origin-content-text.ts | 4 +- .../src/utils/parse-markdown-to-grab-node.ts | 8 +- .../process-node/process-special-node.ts | 8 +- .../src/utils/refine-range/fix-end-empty.ts | 22 +- .../src/utils/refine-range/fix-end-node.ts | 8 +- .../src/utils/refine-range/fix-link.ts | 12 +- .../src/utils/refine-range/fix-start-node.ts | 8 +- .../src/utils/refine-range/refine-range.ts | 26 +- .../src/utils/should-refine-range.ts | 6 +- .../utils/__tests__/rate-limit.test.ts | 4 +- .../chat-area/utils/src/exhaustive-check.ts | 2 +- .../chat-area/utils/src/get-report-error.ts | 4 +- .../common/chat-area/utils/src/int64.ts | 2 +- .../common/chat-area/utils/src/json-parse.ts | 8 +- .../parse-markdown/parse-markdown-to-text.ts | 6 +- .../common/chat-area/utils/src/rate-limit.ts | 18 +- .../chat-area/utils/src/safe-async-throw.ts | 2 +- .../common/chat-area/utils/src/type-helper.ts | 4 +- .../utils/src/update-only-defined.ts | 4 +- .../packages/common/coze-mitt/src/index.ts | 32 +- .../src/action-bar/context/index.ts | 2 +- .../src/action-bar/ui-component.tsx | 2 +- .../src/expression/core/parser/index.ts | 34 +- .../src/expression/core/tree-helper/index.ts | 16 +- .../src/expression/core/type.ts | 2 +- .../expression/popover/hooks/use-selection.ts | 2 +- .../src/expression/popover/hooks/use-tree.ts | 4 +- .../src/expression/popover/popover.tsx | 12 +- .../src/expression/popover/shared.ts | 4 +- .../editor-plugins/src/expression/shared.ts | 6 +- .../src/expression/validation/index.tsx | 6 +- .../src/expression/variable-types.ts | 4 +- .../src/input-slot/hooks/use-in-jinja-raw.ts | 2 +- .../input-slot-widget/config-mode-popover.tsx | 2 +- .../library-block-widget-type.tsx | 4 +- .../library-search-popover/index.tsx | 6 +- .../library-insert/utils/get-library-info.ts | 2 +- .../content-search-popover/index.tsx | 2 +- .../library/use-options-operations.tsx | 2 +- .../variable/use-variables-tree.tsx | 4 +- .../src/shared/utils/template-parser.ts | 26 +- .../free-layout-editor/src/use-entity.ts | 4 +- .../src/workflow-json-format.ts | 12 +- .../common/md-editor-adapter/src/editor.tsx | 4 +- .../common/md-editor-adapter/src/types.ts | 26 +- .../common/md-editor-adapter/src/utils.ts | 2 +- .../base/src/create-prompt/types.ts | 14 +- .../prompt-kit/base/src/editor/render.tsx | 10 +- .../index.ts | 2 +- .../store.ts | 4 +- .../src/shared/utils/insert-to-newline.ts | 8 +- .../prompt-kit/base/src/shared/utils/rect.ts | 12 +- .../main/src/prompt-library/index.tsx | 10 +- .../prompt-library/infinite-list/index.tsx | 4 +- .../src/prompt-library/infinite-list/type.ts | 28 +- .../infinite-list/use-scroll.ts | 28 +- .../main/src/prompt-library/library-list.tsx | 2 +- .../recommend-pannel/index.tsx | 8 +- .../uploader-adapter/__tests__/index.test.ts | 6 +- .../common/uploader-adapter/src/index.ts | 4 +- .../common/uploader-adapter/src/utils.ts | 2 +- .../common/uploader-interface/src/index.ts | 114 ++--- .../websocket-manager-adapter/src/index.tsx | 22 +- .../src/card/plugin/index.module.less | 6 +- .../component/src/favorite-button/index.tsx | 6 +- .../hooks/use-farvorite-request.ts | 2 +- .../hooks/use-favorite-change.ts | 4 +- .../component/src/favorite-icon-btn/type.ts | 4 +- .../src/infinite-list/hooks/use-scroll.ts | 28 +- .../component/src/infinite-list/index.tsx | 6 +- .../component/src/infinite-list/type.ts | 28 +- .../src/components/ui-empty/index.tsx | 2 +- .../src/components/ui-form/input/index.tsx | 4 +- .../src/components/ui-form/select/index.tsx | 2 +- .../src/components/ui-icon-button/index.tsx | 4 +- .../src/components/ui-modal/ui-drag-modal.tsx | 2 +- .../components/ui-modal/ui-mobile-modal.tsx | 2 +- .../src/components/ui-modal/ui-modal.tsx | 2 +- .../src/components/ui-search-input/index.tsx | 2 +- .../src/components/ui-select/index.tsx | 2 +- .../src/components/ui-tab-bar/index.tsx | 2 +- .../src/components/ui-table-meta/index.tsx | 12 +- .../src/components/ui-table/index.tsx | 8 +- .../src/components/ui-toast/index.tsx | 8 +- .../components/bot-semi/src/hooks/use-grab.ts | 26 +- .../components/bot-semi/src/semi/index.ts | 6 +- .../src/components/json-field/index.tsx | 2 +- .../components/json-viewer/src/constants.ts | 4 +- .../components/json-viewer/src/context.tsx | 8 +- .../json-viewer/src/hooks/use-value.tsx | 4 +- .../json-viewer/src/index.module.less | 2 +- .../components/json-viewer/src/index.tsx | 10 +- .../components/json-viewer/src/types.ts | 20 +- .../json-viewer/src/utils/big-number.ts | 4 +- .../json-viewer/src/utils/generate-field.ts | 28 +- .../src/utils/generate-str-avoid-escape.ts | 2 +- .../src/utils/generate-str-to-link.tsx | 22 +- .../components/loading-button/src/index.tsx | 2 +- .../mouse-pad-selector/src/utils.ts | 2 +- .../src/with-guiding-popover.tsx | 2 +- .../src/components/base-node/icon.tsx | 2 +- .../src/components/base-node/index.tsx | 10 +- .../src/components/collapse/index.tsx | 12 +- .../src/components/lines-render/index.tsx | 6 +- .../components/lines-render/render-line.tsx | 2 +- .../src/components/lines-render/utils.tsx | 6 +- .../src/components/tools/interactive.tsx | 8 +- .../src/components/tools/zoom-select.tsx | 2 +- .../resource-tree/src/constants/line.ts | 2 +- .../src/entities/custom-render-state.ts | 2 +- .../src/entities/render-state-entity.ts | 2 +- .../preset/fixed-layout-preset.ts | 12 +- .../preset/fixed-layout-props.ts | 6 +- .../preset/flow-registers.ts | 48 +- .../src/hooks/use-custom-node-render.tsx | 24 +- .../src/hooks/use-editor-props.tsx | 8 +- .../resource-tree/src/initial-data.ts | 4 +- .../src/layers/flow-lines-layer.tsx | 4 +- .../resource-tree/src/node-registries.ts | 6 +- .../src/services/custom-hover-service.ts | 12 +- .../src/services/custom-lines-manager.ts | 8 +- .../src/services/tree-service.ts | 34 +- .../resource-tree/src/typings/line.ts | 18 +- .../resource-tree/src/typings/tree.ts | 2 +- .../resource-tree/src/utils/transform-tree.ts | 6 +- .../scroll-view/src/scroll-view/hooks.ts | 24 +- .../scroll-view/src/scroll-view/index.tsx | 8 +- .../scroll-view/src/scroll-view/type.ts | 50 +- .../scroll-view/src/scroll-view/utils.ts | 6 +- .../scroll-view/src/utils/is-apple-webkit.ts | 4 +- .../components/image-render/index.test.tsx | 24 +- .../image-render/use-image-preview.test.tsx | 22 +- .../components/image-render/utils.test.ts | 104 ++-- .../renders/actions-render.test.tsx | 22 +- .../renders/edit-header-render.test.tsx | 40 +- .../components/renders/tag-render.test.tsx | 8 +- .../components/renders/text-render.test.tsx | 60 +-- .../components/table-view/edit-menu.test.tsx | 12 +- .../components/table-view/index.test.tsx | 50 +- .../components/table-view/service.test.ts | 54 +- .../components/table-view/utils.test.tsx | 22 +- .../src/components/renders/actions-render.tsx | 4 +- .../components/renders/edit-header-render.tsx | 18 +- .../components/renders/image-render/index.tsx | 6 +- .../image-render/use-image-preview.tsx | 2 +- .../src/components/renders/text-render.tsx | 8 +- .../src/components/table-view/edit-menu.tsx | 2 +- .../components/table-view/index.module.less | 12 +- .../src/components/table-view/index.tsx | 42 +- .../src/components/table-view/service.ts | 18 +- .../src/components/table-view/utils.tsx | 4 +- .../components/virtual-list/src/index.ts | 2 +- .../packages/data/common/e2e/src/bot-e2e.ts | 4 +- .../data/common/e2e/src/knowledge-e2e.ts | 26 +- .../src/feature-registry-manager.ts | 2 +- .../data/common/feature-register/src/index.ts | 44 +- .../data/common/feature-register/src/react.ts | 2 +- .../reporter/src/reporter/data-reporter.ts | 12 +- .../data/common/utils/src/abortable.ts | 4 +- .../src/components/input-with-count/index.tsx | 2 +- .../data/common/utils/src/database-page.ts | 4 +- .../data/common/utils/src/update-interval.ts | 4 +- .../packages/data/common/utils/src/url.ts | 4 +- .../src/doc-preview/use-preview-pdf/index.tsx | 2 +- .../components/common-file-picker.tsx | 60 +-- .../components/src/file-picker/consts.ts | 4 +- .../hooks/useDefaultLabelRenderer.tsx | 34 +- .../components/src/file-picker/types.ts | 38 +- .../components/src/segment-menu/index.tsx | 4 +- .../src/segment-menu/segment-tree.tsx | 4 +- .../src/segment-menu/use-context-menu.tsx | 4 +- .../src/segment-menu/utils/level-tree-op.ts | 8 +- .../preview-chunk/document/index.tsx | 22 +- .../src/text-knowledge-editor/event/index.tsx | 32 +- .../editor-actions/upload-image/base.tsx | 4 +- .../upload-image/custom-upload.tsx | 2 +- .../features/editor/editor.tsx | 22 +- .../add-after-action.tsx | 2 +- .../add-before-action.tsx | 4 +- .../hover-edit-bar-actions/delete-action.tsx | 12 +- .../hover-edit-bar-actions/edit-action.tsx | 6 +- .../add-after-action.tsx | 6 +- .../add-before-action.tsx | 4 +- .../delete-action.tsx | 4 +- .../edit-action.tsx | 6 +- .../features/preview/preview.tsx | 12 +- .../hooks/inner/use-control-context-menu.ts | 10 +- .../inner/use-control-editor-context-menu.ts | 8 +- .../inner/use-control-preview-context-menu.ts | 6 +- .../hooks/inner/use-hover-effect.ts | 4 +- .../hooks/inner/use-out-editor-mode.ts | 4 +- .../use-add-empty-chunk-action.ts | 18 +- .../chunk-actions/use-delete-action.ts | 12 +- .../hooks/use-case/use-create-local-chunk.ts | 2 +- .../hooks/use-case/use-delete-local-chunk.ts | 2 +- .../hooks/use-case/use-delete-remote-chunk.ts | 2 +- .../hooks/use-case/use-init-editor.ts | 20 +- .../use-case/use-preview-context-menu.ts | 22 +- .../hooks/use-case/use-save-chunk.ts | 6 +- .../hooks/use-case/use-update-remote-chunk.ts | 2 +- .../src/text-knowledge-editor/index.tsx | 4 +- .../scenes/base/main.tsx | 8 +- .../level/hooks/inner/use-active-chunk.ts | 14 +- .../hooks/inner/use-chunk-render-path.ts | 20 +- .../hooks/use-case/use-scroll-to-selection.ts | 4 +- .../scenes/level/main.tsx | 16 +- .../scenes/level/services/chunk-op.service.ts | 2 +- .../scenes/level/types/level-document.ts | 2 +- .../services/inner/chunk-op.service.ts | 12 +- .../services/inner/document-editor.service.ts | 12 +- .../services/inner/get-editor-table-cls.ts | 2 +- .../services/inner/get-editor-words-cls.ts | 8 +- .../services/use-case/get-editor-content.ts | 20 +- .../use-case/get-init-editor-content.ts | 2 +- .../use-case/get-render-editor-content.ts | 6 +- .../use-case/is-editor-content-change.ts | 2 +- .../utils/escape-html.ts | 14 +- .../src/use-case/use-knowledge-navigate.ts | 2 +- .../src/use-case/get-knowledge-ide-query.ts | 2 +- .../common/stores/src/knowledge-preview.ts | 8 +- .../common/stores/src/params-store.ts | 2 +- .../src/store/data-set.ts | 2 +- .../index.tsx | 6 +- .../src/components/header-tags/index.tsx | 6 +- .../knowledge-modal-nav-bar/index.tsx | 2 +- .../components/knowledge-nav-bar/index.tsx | 2 +- .../components/photo-detail-modal/index.tsx | 10 +- .../components/render-document-icon/index.tsx | 2 +- .../image-knowledge-workspace/index.tsx | 28 +- .../use-photo-list.ts | 2 +- .../base/index.tsx | 2 +- .../services/use-case/disabled-tooltip.ts | 12 +- .../features/nav-bar-action-button/index.tsx | 10 +- .../use-case/use-before-knowledgeide-close.ts | 8 +- .../components/main.tsx | 6 +- .../components/table-data-view.tsx | 16 +- .../context/table-actions-context.tsx | 2 +- .../context/table-data-context.tsx | 2 +- .../context/table-ui-context.tsx | 2 +- .../hooks/inner/use-create-slice.ts | 2 +- .../hooks/inner/use-get-slice-list-data.ts | 2 +- .../hooks/inner/use-scroll.ts | 2 +- .../hooks/inner/use-table-height.ts | 2 +- .../hooks/use-case/use-add-row.ts | 2 +- .../hooks/use-case/use-delete-slice-modal.tsx | 6 +- .../use-case/use-table-segment-modal.tsx | 2 +- .../use-case/use-table-slice-operations.tsx | 14 +- .../table-knowledge-workspace/index.tsx | 2 +- .../get-table-render-columns-data.tsx | 4 +- .../components/doc-selector.tsx | 2 +- .../components/level-content.tsx | 2 +- .../components/main.tsx | 20 +- .../components/text-toolbar.tsx | 10 +- .../text-knowledge-workspace/doc-selector.tsx | 6 +- .../text-knowledge-workspace/hooks/index.ts | 16 +- .../hooks/life-cycle/use-document-info.ts | 8 +- .../hooks/life-cycle/use-slice-data.ts | 12 +- .../hooks/use-case/use-document-management.ts | 12 +- .../hooks/use-case/use-file-preview.ts | 2 +- .../hooks/use-case/use-level-segments.ts | 14 +- .../hooks/use-case/use-modals.ts | 4 +- .../hooks/use-case/use-slice-counter.ts | 6 +- .../utils/document-utils.tsx | 6 +- .../hooks/use-case/use-get-knowledge-type.ts | 2 +- .../use-case/use-reload-knowledge-ide.ts | 2 +- .../src/layout/base/index.tsx | 12 +- .../knowledge-ide-base/src/layout/module.ts | 30 +- .../knowledge-ide-base/src/service/dataset.ts | 4 +- .../src/service/document.ts | 10 +- .../knowledge-ide-base/src/types/index.ts | 6 +- .../knowledge-ide-base/src/types/slice.ts | 2 +- .../knowledge-ide-base/src/utils/index.ts | 8 +- .../knowledge-ide-base/src/utils/preview.tsx | 4 +- .../scenes/base/index.tsx | 2 +- .../scenes/base/index.tsx | 6 +- .../scenes/base/use-content.tsx | 4 +- .../src/batch-checkbox-doc/hooks.tsx | 2 +- .../add-type-content/coze-knowledge/index.tsx | 2 +- .../src/knowledge-list-modal/index.tsx | 2 +- .../use-knowledge-filter/index.tsx | 10 +- .../src/rag-mode-configuration/index.tsx | 4 +- .../components/account-frequency-item.tsx | 2 +- .../components/main.tsx | 6 +- .../src/table-segment-modal/hooks.tsx | 2 +- .../src/table-segment-modal/modal.tsx | 4 +- .../knowledge-modal-base/src/utils/slice.ts | 8 +- .../src/scenes/base/config.ts | 12 +- .../browser-url-modal/hooks/get-web-info.ts | 6 +- .../src/components/card-radio-group/index.tsx | 2 +- .../src/components/collapse-panel/index.tsx | 2 +- .../src/components/document-list/index.tsx | 4 +- .../table-preview/index.module.less | 2 +- .../components/table-preview/index.tsx | 6 +- .../components/table-setting-bar/index.tsx | 4 +- .../table-structure/index.module.less | 4 +- .../components/table-structure/index.tsx | 4 +- .../src/components/table-format/index.tsx | 2 +- .../unit-progress/unit-progress.tsx | 2 +- .../upload-footer/upload-footer.tsx | 2 +- .../src/components/upload-navbar/index.tsx | 4 +- .../upload-unit-file/before-upload.ts | 6 +- .../upload-unit-file/custom-request.ts | 4 +- .../src/components/upload-unit-file/utils.ts | 2 +- .../components/unit-name/index.tsx | 2 +- .../components/unit-name/unit-name.tsx | 2 +- .../src/components/upload-unit-table/types.ts | 2 +- .../upload-unit-table/upload-unit-table.tsx | 2 +- .../src/constants/components.ts | 4 +- .../custom/add/steps/create/create-v2.tsx | 4 +- .../custom/add/steps/create/create.tsx | 2 +- .../custom/incremental/steps/upload/utils.tsx | 2 +- .../first-party/local/add/steps/services.ts | 6 +- .../local/add/steps/upload/upload.tsx | 2 +- .../local/incremental/steps/services.ts | 6 +- .../local/incremental/steps/upload/upload.tsx | 2 +- .../features/knowledge-type/table/hooks.ts | 26 +- .../features/knowledge-type/table/utils.ts | 30 +- .../add/steps/processing/processing.tsx | 2 +- .../local/add/steps/preview/index.tsx | 10 +- .../local/add/steps/processing/utils.ts | 2 +- .../local/add/steps/segment/segment.tsx | 2 +- .../local/add/store/doc-review-slice.ts | 12 +- .../local/resegment/steps/preview/index.tsx | 12 +- .../local/resegment/steps/processing/hooks.ts | 2 +- .../local/resegment/steps/segment/segment.tsx | 4 +- .../local/resegment/steps/segment/utils.ts | 2 +- .../local/resegment/store/doc-review-slice.ts | 12 +- .../features/knowledge-type/text/interface.ts | 6 +- .../src/features/segment-preview/index.tsx | 4 +- .../upload-task-list/image-local/index.tsx | 2 +- .../upload-task-list/table-local/index.tsx | 2 +- .../upload-task-list/text-local/index.tsx | 2 +- .../src/hooks/common.ts | 2 +- .../src/index.tsx | 2 +- .../src/layout/base/index.tsx | 4 +- .../src/types/components.ts | 4 +- .../src/types/index.ts | 2 +- .../src/types/process.ts | 6 +- .../src/types/table.ts | 2 +- .../src/types/text.ts | 2 +- .../src/utils/common.ts | 6 +- .../src/utils/get-storage-strategy-enabled.ts | 4 +- .../src/utils/render-document-filter-value.ts | 6 +- .../src/utils/table.ts | 12 +- .../src/constants/common.ts | 62 +-- .../src/index.module.less | 2 +- .../src/main.tsx | 2 +- .../src/types/common.ts | 24 +- .../src/types/index.ts | 2 +- .../__tests__/mock-components/mock-form.tsx | 2 +- .../components/step-footer/index.tsx | 12 +- .../components/table-preview/index.tsx | 2 +- .../components/table-structure/index.tsx | 12 +- .../components/upload/index.tsx | 12 +- .../database-create-from-excel/const.ts | 2 +- .../datamodel/index.ts | 6 +- .../datamodel/namespaces/table_base.ts | 62 +-- .../datamodel/namespaces/table_import.ts | 24 +- .../hooks/use-upload-progress.ts | 10 +- .../store/initial-config.ts | 2 +- .../src/components/database-modal/index.tsx | 14 +- .../helpers/validate.ts | 14 +- .../database-table-structure/index.tsx | 22 +- .../memory/database-creator/src/const.tsx | 6 +- .../data/memory/database-creator/src/types.ts | 4 +- .../components/create-table-modal/index.tsx | 10 +- .../helpers/validate.ts | 14 +- .../database-table-structure/index.tsx | 34 +- .../src/components/singleline-input/index.tsx | 4 +- .../src/constants/database-field.tsx | 10 +- .../src/types/database-field.ts | 12 +- .../src/types/database-tabs.ts | 8 +- .../batch-import-modal/steps/config.tsx | 6 +- .../batch-import-modal/steps/process.tsx | 14 +- .../src/components/database-detail/index.tsx | 4 +- .../src/components/database-modal/index.tsx | 16 +- .../database-table-data/formatter.tsx | 10 +- .../database-table-data/index.module.less | 4 +- .../components/database-table-data/index.tsx | 6 +- .../database-table-data/sortable-row.tsx | 6 +- .../components/database-table-data/type.ts | 2 +- .../index.tsx | 4 +- .../components/field-edit-kit/date/index.tsx | 10 +- .../src/components/row-edit-modal/index.tsx | 6 +- .../select-database-modal/index.tsx | 6 +- .../src/hooks/use-connector-options.ts | 16 +- .../src/hooks/use-expert-mode-config.ts | 4 +- .../src/hooks/use-get-table-data.ts | 2 +- .../use-library-create-database-modal.tsx | 2 +- .../src/utils/get-default-value.ts | 2 +- .../src/utils/is-empty-value.ts | 4 +- .../src/utils/is-in-int64-range.ts | 14 +- .../database-v2-main/src/utils/table.ts | 8 +- .../__tests__/components/multi-table.test.tsx | 6 +- .../database-debug/table/get-columns.tsx | 10 +- .../components/database-debug/table/index.tsx | 2 +- .../database-debug/table/reset-btn.tsx | 2 +- .../src/components/filebox-list/const.ts | 2 +- .../filebox-list/hooks/use-file-list.ts | 2 +- .../filebox-list/hooks/use-upload-modal.tsx | 8 +- .../filebox-list/image-list/index.tsx | 4 +- .../src/components/filebox-list/index.tsx | 12 +- .../components/memory-debug-modal/index.tsx | 2 +- .../src/components/variable-debug/index.tsx | 2 +- .../use-send-tea-event-for-memory-debug.ts | 2 +- .../filter-unnecessary-content-from-slice.ts | 2 +- .../src/plugins/recall-slices/index.tsx | 2 +- .../components/param-name/index.tsx | 2 +- .../param-name/services/check-rules.ts | 20 +- .../components/param-operator/index.tsx | 14 +- .../components/param-type/utils.tsx | 14 +- .../components/custom-tree-node/constants.ts | 2 +- .../components/custom-tree-node/index.tsx | 10 +- .../components/json-editor/index.tsx | 4 +- .../components/json-import/index.tsx | 16 +- .../life-cycle-service/init-service.ts | 8 +- .../export-variable-service.ts | 18 +- .../components/json-import/utils/merge.ts | 8 +- .../components/json-import/utils/traverse.ts | 30 +- .../src/components/variable-tree/constants.ts | 12 +- .../src/components/variable-tree/index.tsx | 28 +- .../src/components/variable-tree/type.ts | 12 +- .../src/components/variable-tree/utils.ts | 6 +- .../data/memory/variables/src/index.tsx | 2 +- .../use-case-service/submit-service.ts | 8 +- .../src/store/variable-groups/store.ts | 22 +- .../store/variable-groups/transform/dto2vo.ts | 2 +- .../store/variable-groups/transform/vo2dto.ts | 8 +- .../src/store/variable-groups/types.ts | 6 +- .../components/flamethread/config.ts | 2 +- .../components/flamethread/index.tsx | 26 +- .../components/flamethread/typing.ts | 2 +- .../topology-flow/custom-edges/common.tsx | 2 +- .../topology-flow/custom-nodes/common.tsx | 2 +- .../components/topology-flow/hook.tsx | 32 +- .../components/topology-flow/index.tsx | 10 +- .../components/topology-flow/typing.ts | 4 +- .../components/topology-flow/util.tsx | 42 +- .../components/trace-flamethread/index.tsx | 2 +- .../components/trace-flamethread/util.ts | 14 +- .../components/trace-tree/index.tsx | 2 +- .../components/trace-tree/typing.ts | 4 +- .../components/trace-tree/util.tsx | 10 +- .../query-trace/components/tree/index.tsx | 32 +- .../query-trace/components/tree/typing.ts | 28 +- .../query-trace/components/tree/util.ts | 14 +- .../src/modules/query-trace/config/cspan.ts | 2 +- .../query-trace/hooks/use-span-transform.ts | 32 +- .../src/modules/query-trace/index.ts | 6 +- .../src/modules/query-trace/typings/cspan.ts | 10 +- .../src/modules/query-trace/typings/graph.ts | 6 +- .../modules/query-trace/utils/cspan-graph.ts | 36 +- .../query-trace/utils/cspan-transform.ts | 22 +- .../src/modules/query-trace/utils/cspan.ts | 4 +- .../query-trace/utils/field-item-handler.ts | 2 +- .../debug-panel/side-panel/index.tsx | 4 +- .../debug/debug-panel/src/consts/index.ts | 10 +- .../hooks/use-debug-panel-layout-config.tsx | 2 +- .../debug/debug-panel/src/store/index.ts | 16 +- .../debug/debug-panel/src/utils/index.ts | 4 +- .../debug/debug-panel/src/utils/span.ts | 2 +- .../src/plugins/pdf/index.tsx | 2 +- .../src/components/mock-select/index.tsx | 14 +- .../components/mockset-delete-modal/index.tsx | 2 +- .../components/mockset-edit-modal/index.tsx | 16 +- .../devops/mockset-manage/src/const.ts | 4 +- .../src/hooks/use-get-mockset.ts | 8 +- .../testset-edit-sidesheet/auto-fill.tsx | 4 +- .../testset-edit-sidesheet/form-label.tsx | 2 +- .../testset-edit-sidesheet/index.tsx | 24 +- .../node-form-section.tsx | 6 +- .../testset-name-input.tsx | 2 +- .../testset-edit-sidesheet/utils.ts | 50 +- .../testset-select/index.module.less | 2 +- .../src/components/testset-select/index.tsx | 28 +- .../testset-select/testset-option-item.tsx | 8 +- .../components/testset-sidesheet/index.tsx | 16 +- .../testset-sidesheet/testset-list-item.tsx | 4 +- .../devops/testset-manage/src/events.ts | 4 +- .../src/hooks/use-check-schema.ts | 12 +- .../devops/testset-manage/src/store.ts | 8 +- .../devops/testset-manage/src/types.ts | 4 +- .../src/passport-api/__tests__/index.test.ts | 2 +- .../account-adapter/src/passport-api/index.ts | 2 +- .../account-adapter/src/utils/index.ts | 2 +- .../use-sync-local-storage-uid.test.ts | 4 +- .../account-base/src/hooks/factory.ts | 14 +- .../account-base/src/hooks/index.ts | 20 +- .../account-base/src/types/index.ts | 14 +- .../account-base/src/types/passport.ts | 14 +- .../account-base/src/utils/factory.ts | 4 +- .../account-base/src/utils/index.ts | 8 +- .../require-auth-container/index.tsx | 2 +- .../src/components/user-info-panel/index.tsx | 6 +- .../user-info-panel/username-input/index.tsx | 2 +- .../account-ui-base/src/hooks/logout.tsx | 2 +- .../use-account-settings/index.module.less | 4 +- .../src/hooks/use-account-settings/index.tsx | 2 +- .../browser-upgrade-wrap/index.module.less | 16 +- .../src/utils/compare-version.ts | 12 +- .../browser-upgrade-banner/src/utils/index.ts | 4 +- .../src/utils/is-mobile.ts | 2 +- .../src/hooks/use-check-enterprise-exist.ts | 2 +- .../src/hooks/use-current-enterprise-info.ts | 34 +- .../src/hooks/use-enterprise-list.ts | 8 +- .../enterprise-store-adapter/src/index.ts | 4 +- .../src/stores/enterprise.ts | 4 +- .../src/utils/personal.ts | 4 +- .../src/utils/switch-enterprise.ts | 6 +- .../foundation/foundation-sdk/src/user.ts | 8 +- .../hooks/use-has-sider.ts | 4 +- .../src/components/global-layout/index.tsx | 4 +- .../src/hooks/use-app-init/index.ts | 4 +- .../use-app-init/use-init-common-config.ts | 2 +- .../src/hooks/use-create-bot-action.tsx | 2 +- .../global/src/utils/global-loading.ts | 10 +- .../components/global-error/index.module.less | 2 +- .../src/components/global-error/index.tsx | 4 +- .../global-layout/component/action-btn.tsx | 2 +- .../global-layout/component/menu-item.tsx | 2 +- .../global-layout/component/sider.tsx | 4 +- .../src/components/global-layout/hooks.ts | 2 +- .../layout/src/components/side-sheet-menu.tsx | 2 +- .../packages/foundation/layout/src/index.tsx | 2 +- .../layout/src/store/bot-mobile/index.ts | 2 +- .../core/local-storage-service.test.ts | 20 +- .../__tests__/hooks/use-value.test.tsx | 26 +- .../__tests__/utils/parse.test.ts | 4 +- .../foundation/local-storage/src/config.ts | 2 +- .../local-storage/src/core/index.ts | 4 +- .../local-storage/src/utils/parse.ts | 2 +- .../space-store-adapter/__mocks__/zustand.ts | 4 +- .../__tests__/space.test.ts | 4 +- .../space-store-adapter/src/space/const.ts | 4 +- .../space-store-adapter/src/space/index.ts | 6 +- .../space-store/__mocks__/zustand.ts | 4 +- .../space-store/src/hooks/use-space-app.ts | 6 +- .../foundation/space-store/src/space/hooks.ts | 2 +- .../src/components/space-id-layout.tsx | 6 +- .../components/favorites-list-item.tsx | 8 +- .../components/favorites-list.tsx | 28 +- .../workspace-sub-menu/components/list.css | 4 +- .../space-ui-base/src/hooks/use-init-space.ts | 24 +- .../src/services/options-service.ts | 2 +- .../src/context/create-store.ts | 6 +- .../base-interface/src/types/index.ts | 2 +- .../src/resource-folder-coze/constants.tsx | 4 +- .../hooks/use-resource-folder-config.tsx | 4 +- .../plugins/resource-folder-contribution.ts | 22 +- .../resource-folder-coze.tsx | 4 +- .../src/resource-folder-coze/type.ts | 62 +-- .../src/resource-folder-coze/utils.tsx | 6 +- .../src/stores/primary-sidebar-store.ts | 16 +- .../biz-data/src/database-main.tsx | 4 +- .../src/hooks/use-database-resource.tsx | 2 +- .../src/hooks/use-knowledge-resource.tsx | 4 +- .../project-ide/biz-data/src/main.tsx | 4 +- .../src/hooks/use-plugin-resource.tsx | 4 +- .../project-ide/biz-plugin/src/main.tsx | 6 +- .../src/conversation/chat-history/index.tsx | 10 +- .../src/conversation/constants/index.ts | 8 +- .../conversation-content/edit-input.tsx | 6 +- .../conversation-content/index.tsx | 6 +- .../conversation/dynamic-chat-list/index.tsx | 4 +- .../hooks/use-conversation-list.ts | 4 +- .../hooks/use-delete-chat/index.tsx | 4 +- .../conversation/static-chat-list/index.tsx | 8 +- .../biz-workflow/src/hooks/debug.ts | 2 +- .../src/hooks/use-change-flow-mode.ts | 2 +- .../src/hooks/use-name-validators.ts | 2 +- .../biz-workflow/src/hooks/use-project-api.ts | 4 +- .../src/hooks/use-workflow-resource.tsx | 2 +- .../project-ide/biz-workflow/src/index.tsx | 2 +- .../client/src/components/ide-client.tsx | 2 +- .../client-default-contribution.ts | 4 +- .../client/src/create-default-preset.ts | 28 +- .../core/src/application/application.ts | 4 +- .../core/src/common/context-key-service.ts | 4 +- .../core/src/common/lifecycle-contribution.ts | 14 +- .../core/src/common/open-service.ts | 4 +- .../project-ide/core/src/common/plugin.ts | 34 +- .../core/src/common/storage-service.ts | 2 +- .../project-ide/core/src/common/uri.ts | 24 +- .../core/src/event/event-contribution.ts | 10 +- .../core/src/event/event-registry.ts | 8 +- .../packages/project-ide/core/src/index.ts | 2 +- .../core/src/label/label-handler.ts | 2 +- .../core/src/label/label-manager.ts | 12 +- .../core/src/label/label-service.ts | 12 +- .../project-ide/core/src/label/uri-label.tsx | 2 +- .../core/src/navigation/browser-history.ts | 12 +- .../core/src/navigation/navigation-history.ts | 14 +- .../src/preference/preferences-manager.ts | 6 +- .../core/src/renderer/ide-provider.tsx | 10 +- .../core/src/renderer/use-ide-container.ts | 2 +- .../core/src/renderer/use-ide-service.ts | 2 +- .../core/src/renderer/use-navigation.ts | 2 +- .../core/src/resource/auto-save-resource.ts | 10 +- .../project-ide/core/src/resource/resource.ts | 6 +- .../src/shortcut/keybinding/keybinding.ts | 14 +- .../core/src/shortcut/shortcuts-service.tsx | 28 +- .../core/src/shortcut/utils/key-match.ts | 22 +- .../core/src/styles/color/color-service.ts | 20 +- .../src/styles/styling/styling-service.ts | 4 +- .../core/src/styles/theme/theme-service.ts | 8 +- .../project-ide/core/vitest.config.ts | 2 +- .../framework/src/components/ide-client.tsx | 4 +- .../components/resource-folder/constant.ts | 4 +- .../hooks/use-create-edit-resource/index.tsx | 14 +- .../hooks/use-focus-resource/index.ts | 2 +- .../hooks/use-mouse-event/index.tsx | 32 +- .../hooks/use-mouse-event/utils.ts | 14 +- .../hooks/use-register-command/index.ts | 2 +- .../hooks/use-right-click-panel/util.ts | 4 +- .../hooks/use-selected-change.ts | 2 +- .../src/components/resource-folder/index.tsx | 106 ++-- .../components/more-tools.tsx | 2 +- .../src/components/resource-folder/type.ts | 58 +-- .../components/resource-folder/utils/index.ts | 32 +- .../framework/src/context/widget-context.ts | 6 +- .../src/hooks/use-activate-widget-context.ts | 2 +- .../src/hooks/use-commit-version.tsx | 2 +- .../src/hooks/use-current-split-screen.ts | 14 +- .../src/hooks/use-current-widget-context.ts | 4 +- .../framework/src/hooks/use-ide-location.ts | 4 +- .../framework/src/hooks/use-ide-navigate.ts | 4 +- .../src/hooks/use-ide-service-in-biz.ts | 4 +- .../framework/src/hooks/use-message-event.ts | 20 +- .../framework/src/hooks/use-view-service.ts | 2 +- .../project-ide/framework/src/index.ts | 2 +- .../create-context-menu-plugin/index.ts | 32 +- .../preset-contribution.ts | 6 +- .../project-ide-services.ts | 10 +- .../tooltip-contribution.tsx | 12 +- .../create-preset-plugin/view-service.ts | 30 +- .../create-preset-plugin/widget-service.ts | 2 +- .../with-registry-content/use-lifecycle.ts | 2 +- .../with-registry-content/use-mount.ts | 20 +- .../src/services/message-event-service.ts | 8 +- .../framework/src/services/modal-service.tsx | 30 +- .../project-ide/framework/src/types/client.ts | 20 +- .../framework/src/types/registry.ts | 16 +- .../framework/src/types/resource.ts | 4 +- .../framework/src/types/services.ts | 24 +- .../src/utils/add-preserved-search-params.ts | 6 +- .../framework/src/utils/custom-layout.ts | 2 +- .../framework/src/utils/resource-tools.ts | 12 +- .../src/components/global-handler/index.tsx | 8 +- .../close-confirm-modal/index.tsx | 12 +- .../src/components/global-modals/index.tsx | 4 +- .../src/components/primary-sidebar/index.tsx | 2 +- .../src/components/resource-list/index.tsx | 12 +- .../components/resource-tree-modal/index.tsx | 2 +- .../src/components/sidebar-expand/index.tsx | 4 +- .../toolbar/full-screen-button/index.tsx | 4 +- .../toolbar/reload-button/index.tsx | 2 +- .../main/src/components/top-bar/index.tsx | 6 +- .../components/top-bar/operators/index.tsx | 6 +- .../top-bar/operators/monetize/index.tsx | 2 +- .../components/top-bar/project-info/index.tsx | 12 +- .../widget-default-renderer/index.tsx | 4 +- .../src/components/widget-title/index.tsx | 2 +- .../packages/project-ide/main/src/index.less | 2 +- .../packages/project-ide/main/src/index.tsx | 2 +- .../packages/project-ide/main/src/layout.tsx | 2 +- .../create-app-plugin/app-contribution.ts | 12 +- .../src/plugins/create-app-plugin/index.ts | 2 +- .../layout-restore-service.ts | 36 +- .../open-url-resource-service.ts | 8 +- .../create-app-plugin/project-info-service.ts | 14 +- .../create-app-plugin/utils/layout-store.ts | 44 +- .../create-app-plugin/widget-event-service.ts | 12 +- .../components/left-content-buttons/index.tsx | 2 +- .../src/components/mode-tab/index.tsx | 2 +- .../components/secondary-sidebar/index.tsx | 2 +- .../src/components/ui-builder/index.ts | 2 +- .../src/hooks/use-commit-version.ts | 2 +- .../src/components/activity-bar/index.tsx | 6 +- .../scroll-bar/handlers/mouse-wheel.js | 2 +- .../view/src/constants/class-names.ts | 8 +- .../context-menu/context-menu.ts | 20 +- .../context-menu/menu-registry.ts | 2 +- .../src/contributions/context-menu/menu.ts | 14 +- .../contributions/view-common-contribution.ts | 18 +- .../view/src/create-view-plugin.tsx | 10 +- .../view/src/lumino/dragdrop/index.ts | 4 +- .../view/src/lumino/widgets/dockpanel.ts | 22 +- .../view/src/services/debug-service.ts | 2 +- .../view/src/services/drag-service.ts | 14 +- .../view/src/services/hover-service.ts | 2 +- .../view/src/services/view-service.ts | 24 +- .../view/src/shell/application-shell.ts | 32 +- .../view/src/shell/layout-restorer.ts | 66 +-- .../project-ide/view/src/shell/types.ts | 6 +- .../project-ide/view/src/types/view.ts | 52 +- .../project-ide/view/src/view-manager.tsx | 4 +- .../project-ide/view/src/view-renderer.tsx | 6 +- .../project-ide/view/src/widget-manager.ts | 2 +- .../project-ide/view/src/widget/dock-panel.ts | 4 +- .../widget/handlers/side-panel-handler.tsx | 2 +- .../view/src/widget/react-widget.tsx | 8 +- .../widget/react-widgets/debug-bar-widget.tsx | 2 +- .../src/widget/react-widgets/split-widget.tsx | 62 +-- .../view/src/widget/tab-bar/custom-tabbar.ts | 4 +- .../view/src/widget/tab-bar/tab-renderer.ts | 16 +- .../view/src/widget/tab-bar/toolbar.tsx | 2 +- .../view/src/widget/widget-factory.ts | 22 +- .../view/src/widget/widget-open-handler.ts | 8 +- .../autosave/__tests__/core/manager.test.ts | 4 +- .../autosave/__tests__/core/observer.test.ts | 8 +- .../studio/autosave/src/core/manager.ts | 18 +- .../studio/autosave/src/core/observer.ts | 28 +- .../studio/autosave/src/type/index.ts | 42 +- .../studio/autosave/src/utils/index.ts | 2 +- .../__tests__/with-slardar-id-button.test.tsx | 10 +- .../common/file-kit/__tests__/util.test.ts | 4 +- .../studio/common/file-kit/src/file-type.ts | 4 +- .../studio/common/file-kit/src/util.ts | 2 +- .../__tests__/select-space-modal.test.tsx | 4 +- .../studio/components/src/carousel/index.tsx | 24 +- .../src/collapsible-icon-button/context.ts | 4 +- .../src/collapsible-icon-button/index.tsx | 12 +- .../components/src/duplicate-bot/index.tsx | 16 +- .../components/src/generate-button/index.tsx | 4 +- .../src/generate-gif/image-picker.tsx | 2 +- .../components/src/generate-gif/index.tsx | 12 +- .../components/src/generate-img-tab/index.tsx | 14 +- .../components/src/image-list/index.tsx | 10 +- .../packages/studio/components/src/index.ts | 4 +- .../src/input-controls/input-slider/index.tsx | 4 +- .../components/src/input-with-count/index.tsx | 2 +- .../components/src/list-tab/list-tab.tsx | 2 +- .../components/src/loading-button/index.tsx | 2 +- .../components/action-bar/index.tsx | 2 +- .../components/insert-link-popover/index.tsx | 2 +- .../helpers/get-insert-text.ts | 2 +- .../hooks/use-markdown-editor.ts | 4 +- .../markdown-editor/hooks/use-upload-file.ts | 2 +- .../components/src/markdown-editor/index.tsx | 2 +- .../components/src/markdown-editor/type.ts | 6 +- .../utils/onboarding-variable.ts | 4 +- .../src/model-option/option-item.tsx | 8 +- .../monetize/monetize-config-panel/index.tsx | 10 +- .../personal-header/space-app-list/index.tsx | 16 +- .../components/src/popover-content/index.tsx | 2 +- .../src/project-duplicate-modal/index.tsx | 8 +- .../src/resizable-layout/handle.tsx | 8 +- .../components/src/resizable-layout/index.tsx | 10 +- .../studio/components/src/search/index.tsx | 2 +- .../src/select-space-modal/index.tsx | 2 +- .../components/src/sortable-list/hooks.ts | 4 +- .../components/src/sortable-list/index.tsx | 4 +- .../src/space-form-select/index.tsx | 2 +- .../studio/components/src/sticky/index.tsx | 34 +- .../src/table-select-all-popover/index.tsx | 2 +- .../components/src/tea-exposure/index.tsx | 16 +- .../studio/components/vitest.setup.ts | 6 +- .../use-create-or-update-agent/index.tsx | 14 +- .../components/mockset-edit-modal/index.tsx | 10 +- .../mockset-editor/editor.module.less | 2 +- .../studio/mockset-shared/src/types/index.ts | 16 +- .../studio/mockset-shared/src/utils/index.ts | 12 +- .../table-column/column-expire-at.tsx | 2 +- .../src/components/pat/result-modal/index.tsx | 2 +- .../open-platform/open-auth/src/utils/time.ts | 6 +- .../open-platform/open-auth/vitest.config.ts | 16 +- .../open-platform/open-chat/src/types/base.ts | 6 +- .../open-chat/src/types/builder-chat.ts | 30 +- .../open-env-adapter/src/chat/index.ts | 4 +- .../components/plugin-form-content/hooks.ts | 2 +- .../components/plugin-form-content/index.tsx | 56 +-- .../components/plugin-form-content/utils.tsx | 8 +- .../src/hooks/use-get-tool-columns.tsx | 10 +- .../premium-paywall-banner/index.tsx | 4 +- .../src/components/premium-paywall/index.tsx | 22 +- .../src/hooks/use-benefit-basic.ts | 24 +- .../src/hooks/use-premium-quota.ts | 4 +- .../src/stores/premium.ts | 46 +- .../premium-store-adapter/src/types/index.ts | 14 +- .../src/hooks/use-is-publish-record-ready.ts | 2 +- .../bot-skill/configs/chat-background.test.ts | 28 +- .../auto-save/bot-skill/configs/index.test.ts | 6 +- .../bot-skill/configs/knowledge.test.ts | 2 +- .../configs/onboarding-content.test.ts | 2 +- .../auto-save/bot-skill/index.test.ts | 18 +- .../save-manager/auto-save/index.test.ts | 16 +- .../save-manager/auto-save/request.test.ts | 12 +- .../manual-save/dev-hooks.test.ts | 8 +- .../manual-save/memory-table.test.ts | 10 +- .../manual-save/multi-agent.test.ts | 36 +- .../manual-save/query-collect.test.ts | 12 +- .../manual-save/shortcuts.test.ts | 8 +- .../manual-save/time-capsule.test.ts | 10 +- .../save-manager/manual-save/tts.test.ts | 18 +- .../save-manager/utils/bot-dto-info.test.ts | 22 +- .../save-manager/utils/save-fetcher.test.ts | 38 +- .../__tests__/store/diff-task.test.ts | 22 +- .../__tests__/store/multi-agent.test.ts | 6 +- .../execute-draft-bot-request-id.test.ts | 6 +- .../__tests__/utils/generate-image.test.ts | 30 +- .../__tests__/utils/get-dot-status.test.ts | 6 +- .../__tests__/utils/handle-status.test.ts | 16 +- .../__tests__/utils/plugin-apis.test.ts | 4 +- .../utils/replace-bot-prompt.test.ts | 14 +- .../bot-detail/__tests__/utils/save.test.ts | 8 +- .../__tests__/utils/setter-factory.test.ts | 50 +- .../__tests__/utils/storage.test.ts | 36 +- .../bot-detail/__tests__/utils/submit.test.ts | 2 +- .../__tests__/utils/uniq-memory-list.test.ts | 4 +- .../src/init/init-bot-detail-store.ts | 6 +- .../src/init/init-generate-image.ts | 2 +- .../auto-save/bot-skill/configs/plugin.ts | 4 +- .../bot-skill/configs/voices-info.ts | 2 +- .../auto-save/bot-skill/configs/workflows.ts | 2 +- .../auto-save/multi-agent/config.ts | 2 +- .../src/save-manager/auto-save/request.ts | 2 +- .../save-manager/manual-save/multi-agent.ts | 2 +- .../bot-detail/src/save-manager/types.ts | 2 +- .../src/save-manager/utils/save-fetcher.ts | 4 +- .../stores/bot-detail/src/store/bot-info.ts | 44 +- .../src/store/bot-skill/defaults.ts | 2 +- .../bot-detail/src/store/bot-skill/store.ts | 42 +- .../src/store/bot-skill/transform.ts | 18 +- .../bot-detail/src/store/collaborate-quota.ts | 6 +- .../bot-detail/src/store/collaboration.ts | 26 +- .../stores/bot-detail/src/store/diff-task.ts | 10 +- .../src/store/manually-switch-agent-store.ts | 12 +- .../stores/bot-detail/src/store/model.ts | 4 +- .../src/store/monetize-config-store.ts | 6 +- .../bot-detail/src/store/multi-agent/store.ts | 44 +- .../src/store/multi-agent/transform.ts | 4 +- .../src/store/page-runtime/store.ts | 34 +- .../stores/bot-detail/src/store/persona.ts | 2 +- .../stores/bot-detail/src/types/agent.ts | 18 +- .../bot-detail/src/types/generate-image.ts | 10 +- .../stores/bot-detail/src/types/model.ts | 4 +- .../stores/bot-detail/src/types/skill.ts | 60 +-- .../utils/avatar-background-socket/index.ts | 10 +- .../stores/bot-detail/src/utils/find-agent.ts | 4 +- .../bot-detail/src/utils/generate-image.ts | 16 +- .../bot-detail/src/utils/get-read-only.ts | 2 +- .../bot-detail/src/utils/handle-agent.ts | 10 +- .../bot-detail/src/utils/plugin-apis.ts | 2 +- .../bot-detail/src/utils/setter-factory.ts | 4 +- .../stores/bot-detail/src/utils/storage.ts | 2 +- .../stores/bot-detail/src/utils/submit.ts | 2 +- .../stores/bot-plugin/src/store/plugin.ts | 4 +- .../stores/bot-plugin/src/types/index.ts | 4 +- .../studio/stores/bot-plugin/src/utils/api.ts | 2 +- .../entry-adapter/src/pages/develop/index.tsx | 28 +- .../entry-base/src/components/creator.tsx | 2 +- .../src/components/workspace-empty.tsx | 4 +- .../studio/workspace/entry-base/src/index.tsx | 4 +- .../develop/components/bot-card/index.tsx | 34 +- .../components/bot-card/intelligence-tag.tsx | 2 +- .../develop/hooks/use-cached-query-params.ts | 6 +- .../hooks/use-global-event-listeners.ts | 2 +- .../develop/hooks/use-intelligence-list.ts | 6 +- .../hooks/use-project-copy-polling.tsx | 2 +- .../src/pages/develop/page-utils/copy.ts | 2 +- .../pages/develop/page-utils/parameters.ts | 4 +- .../entry-base/src/pages/develop/type.ts | 2 +- .../src/pages/knowledge-preview/index.tsx | 2 +- .../entry-base/src/pages/library/consts.ts | 14 +- .../library/hooks/use-cached-query-params.ts | 12 +- .../src/pages/library/hooks/use-columns.tsx | 4 +- .../use-database-config.tsx | 4 +- .../use-knowledge-config.tsx | 12 +- .../use-entity-configs/use-prompt-config.tsx | 4 +- .../use-workflow-config.tsx | 4 +- .../entry-base/src/pages/library/index.tsx | 4 +- .../entry-base/src/pages/library/types.ts | 46 +- .../studio/workspace/entry-base/src/utils.ts | 10 +- .../src/components/guide-modal/index.tsx | 2 +- .../components/project-form-modal/index.tsx | 4 +- .../project-template-modal/index.tsx | 8 +- .../project-template-card.tsx | 2 +- .../src/hooks/use-create-project-modal.tsx | 6 +- .../hooks/use-project-template-copy-modal.tsx | 4 +- .../src/context/publish-container-context.tsx | 2 +- .../src/hooks/use-mcp-config-modal.tsx | 12 +- .../src/hooks/use-publish-status.tsx | 18 +- .../src/publish-button/index.tsx | 4 +- .../components/bind-actions/api-bind.tsx | 2 +- .../components/bind-actions/store-bind.tsx | 2 +- .../bind-actions/template-bind/index.tsx | 8 +- .../template-bind/template-config-form.tsx | 12 +- .../template-bind/template-preview-card.tsx | 2 +- .../bind-actions/template-bind/types.ts | 8 +- .../components/bind-actions/undo-button.tsx | 2 +- .../components/bind-actions/web-sdk-bind.tsx | 6 +- .../publish-main/components/config-status.tsx | 4 +- .../components/connector-action.tsx | 12 +- .../components/connector-card.tsx | 30 +- .../connector-group-header.module.less | 2 +- .../components/connector-group-header.tsx | 2 +- .../components/connector-tab-bar/index.tsx | 2 +- .../components/mcp-config-btn.tsx | 2 +- .../components/social-platform-chatflow.tsx | 4 +- .../hooks/use-connector-scroll.ts | 22 +- .../src/publish-main/publish-basic-info.tsx | 2 +- .../src/publish-main/publish-connectors.tsx | 8 +- .../src/publish-main/publish-record.tsx | 4 +- .../src/publish-main/publish-title-bar.tsx | 6 +- .../utils/connector-disabled-publish.ts | 16 +- .../utils/format-connector-groups.ts | 4 +- .../publish-main/utils/get-config-status.ts | 2 +- .../utils/increment-version-number.ts | 8 +- .../publish-main/utils/init-publish-store.ts | 18 +- .../utils/is-store-bind-configured.ts | 4 +- .../components/connector-status.tsx | 8 +- .../src/publish-progress/index.tsx | 16 +- .../src/service/connector-anchor.ts | 2 +- .../workspace/project-publish/src/store.ts | 38 +- .../project-publish/src/utils/constants.ts | 16 +- .../src/utils/is-publish-finish.ts | 6 +- .../src/utils/setter-factory.ts | 4 +- .../src/web-sdk-guide/index.tsx | 2 +- .../base/src/utils/get-enabled-node-types.ts | 2 +- .../src/components/editor/preset.ts | 2 +- .../adapter/code-editor/src/interface.ts | 4 +- .../workflow/adapter/nodes/src/demo/index.tsx | 4 +- .../src/hooks/use-navigate-back.tsx | 14 +- .../playground/src/hooks/use-page-params.ts | 18 +- .../workflow/adapter/playground/src/page.tsx | 10 +- .../adapter/resources/src/audio/index.ts | 70 +-- .../__tests__/api/with-query-client.test.tsx | 10 +- .../__tests__/entities/workflow-node.test.ts | 4 +- .../__tests__/hooks/use-node-test-id.test.tsx | 22 +- .../__tests__/store/workflow/index.test.ts | 14 +- .../base/__tests__/types/node-type.test.ts | 2 +- .../utils/is-general-workflow.test.ts | 2 +- .../parsers/default-parser.test.ts | 20 +- .../parsers/ref-input-parameters.test.ts | 2 +- .../packages/workflow/base/src/api/index.ts | 2 +- .../workflow/base/src/constants/index.ts | 18 +- .../base/src/entities/workflow-node.ts | 4 +- .../base/src/hooks/use-node-test-id.ts | 14 +- .../workflow/base/src/services/index.ts | 2 +- .../base/src/services/validation-service.ts | 42 +- .../workflow/base/src/store/workflow/index.ts | 8 +- .../base/src/types/block-input-dto.ts | 4 +- .../workflow/base/src/types/condition.ts | 10 +- .../workflow/base/src/types/database.ts | 6 +- .../packages/workflow/base/src/types/dto.ts | 34 +- .../packages/workflow/base/src/types/index.ts | 12 +- .../packages/workflow/base/src/types/llm.ts | 2 +- .../workflow/base/src/types/node-type.ts | 48 +- .../packages/workflow/base/src/types/node.ts | 2 +- .../base/src/types/param-definition.ts | 18 +- .../workflow/base/src/types/registry.ts | 76 +-- .../base/src/types/view-variable-tree.ts | 10 +- .../base/src/types/view-variable-type.ts | 34 +- .../packages/workflow/base/src/types/vo.ts | 26 +- .../workflow/base/src/utils/concat-test-id.ts | 6 +- .../workflow/base/src/utils/form-helpers.ts | 12 +- .../base/src/utils/is-general-workflow.ts | 2 +- .../parsers/default-parser.ts | 8 +- .../base/src/utils/output-image-parser.ts | 8 +- .../__tests__/parser-dataset.test.ts | 4 +- .../__tests__/parser-default.test.ts | 4 +- .../__tests__/parser-input-parameter.test.ts | 4 +- .../__tests__/parser-intents.test.ts | 4 +- .../__tests__/parser-json-string.test.ts | 4 +- .../__tests__/parser-outputs.test.ts | 4 +- .../__tests__/parser-variable-assign.test.ts | 6 +- .../__tests__/resource/imageflow-config.ts | 4 +- .../__tests__/resource/workflow-config.ts | 158 +++--- .../base/src/utils/schema-extractor/index.ts | 10 +- .../utils/schema-extractor/parsers/output.ts | 6 +- .../parsers/variable-assign.ts | 2 +- .../base/src/utils/schema-extractor/type.ts | 4 +- .../base/src/utils/schema-extractor/utils.ts | 4 +- .../base/src/utils/slardar-reporter.ts | 4 +- .../workflow/base/src/utils/start-params.ts | 4 +- .../workflow/base/src/utils/traverse.ts | 30 +- .../popover/hooks/use-selection.ts | 2 +- .../popover/hooks/use-tree.ts | 4 +- .../popover/popover.tsx | 12 +- .../expression-editor-next/popover/shared.ts | 4 +- .../expression-editor-next/renderer/hooks.ts | 6 +- .../renderer/renderer.tsx | 6 +- .../src/expression-editor-next/shared.ts | 6 +- .../components/counter/index.tsx | 2 +- .../components/render/index.tsx | 4 +- .../components/suggestion/hooks.ts | 110 ++--- .../components/suggestion/index.tsx | 2 +- .../components/suggestion/state.ts | 20 +- .../src/expression-editor/model/index.ts | 44 +- .../src/expression-editor/parser/index.ts | 38 +- .../expression-editor/tree-helper/index.ts | 14 +- .../src/hooks/use-open-workflow-detail.ts | 2 +- .../components/src/hooks/use-workflow-list.ts | 68 +-- .../use-workflow-resource-action/type.ts | 12 +- .../use-copy-action.ts | 6 +- .../use-create-workflow-modal.tsx | 10 +- .../use-delete-action.tsx | 8 +- .../use-publish-action.tsx | 6 +- .../use-workflow-resource-click.ts | 2 +- .../use-workflow-resource-menu-actions.tsx | 4 +- .../use-workflow-resource-action/utils.ts | 2 +- .../src/image-uploader/image-uploader.ts | 92 ++-- .../components/src/image-uploader/index.tsx | 8 +- .../src/image-uploader/use-image-uploader.ts | 50 +- .../workflow/components/src/text/index.tsx | 2 +- .../components/src/types/workflow-list.ts | 28 +- .../src/utils/cronjob-translator.ts | 28 +- .../workflow/components/src/utils/utils.ts | 14 +- .../src/workflow-commit-list/commit-item.tsx | 6 +- .../src/workflow-commit-list/index.tsx | 16 +- .../src/workflow-commit-list/type.ts | 26 +- .../use-version-history.ts | 4 +- .../components/src/workflow-edit/index.tsx | 20 +- .../src/workflow-modal/constants.ts | 6 +- .../content/card/bot-button/index.tsx | 8 +- .../content/card/delete-button/index.tsx | 4 +- .../src/workflow-modal/content/card/index.tsx | 8 +- .../content/card/parameters/index.tsx | 2 +- .../src/workflow-modal/content/index.tsx | 26 +- .../src/workflow-modal/filter/index.tsx | 2 +- .../src/workflow-modal/hooks/use-i18n-text.ts | 12 +- .../hooks/use-workflow-action.tsx | 50 +- .../hooks/use-workflow-modal-parts.tsx | 14 +- .../hooks/use-workflow-product-list.ts | 4 +- .../hooks/use-workflow-search.tsx | 8 +- .../sider/create-workflow-btn.tsx | 6 +- .../workflow-modal/sider/workflow-filter.tsx | 4 +- .../components/src/workflow-modal/type.ts | 114 ++--- .../components/src/workflow-modal/utils.ts | 2 +- .../workflow-modal/workflow-modal-context.tsx | 10 +- .../workflow/components/tailwind.config.ts | 2 +- .../__tests__/hooks/use-align.test.tsx | 2 +- .../__tests__/hooks/use-background.test.tsx | 4 +- .../hooks/use-canvas-change.test.tsx | 22 +- .../__tests__/hooks/use-canvas-clip.test.tsx | 4 +- .../__tests__/hooks/use-group.test.tsx | 2 +- .../__tests__/hooks/use-init-canvas.test.tsx | 2 +- .../hooks/use-mouse-position.test.tsx | 12 +- .../__tests__/hooks/use-snap-move.test.tsx | 16 +- .../fabric-canvas/__tests__/typings.test.ts | 8 +- .../fabric-canvas/src/assert/font.tsx | 8 +- .../src/components/fabric-editor/const.ts | 14 +- .../fabric-editor/fabric-editor.tsx | 58 +-- .../components/fabric-editor/use-shortcut.tsx | 38 +- .../fabric-preview/fabric-preview.tsx | 2 +- .../src/components/form/index.tsx | 4 +- .../src/components/icon-button/index.tsx | 2 +- .../src/components/pop-in-screen/index.tsx | 6 +- .../src/components/setters/color-picker.tsx | 4 +- .../src/components/setters/font-size.tsx | 4 +- .../src/components/setters/input-number.tsx | 4 +- .../src/components/setters/line-height.tsx | 4 +- .../src/components/topbar/align.tsx | 2 +- .../src/components/topbar/index.tsx | 22 +- .../src/hooks/use-active-object-change.tsx | 100 ++-- .../fabric-canvas/src/hooks/use-align.tsx | 20 +- .../src/hooks/use-background.tsx | 2 +- .../src/hooks/use-canvas-change.tsx | 48 +- .../src/hooks/use-common-operation.tsx | 8 +- .../src/hooks/use-copy-paste.tsx | 68 +-- .../fabric-canvas/src/hooks/use-drag-add.tsx | 8 +- .../src/hooks/use-fabric-editor.tsx | 8 +- .../src/hooks/use-free-pencil.tsx | 16 +- .../fabric-canvas/src/hooks/use-group.tsx | 28 +- .../src/hooks/use-init-canvas.tsx | 4 +- .../fabric-canvas/src/hooks/use-position.tsx | 4 +- .../fabric-canvas/src/hooks/use-redo-undo.tsx | 30 +- .../src/hooks/use-schema-change.tsx | 6 +- .../fabric-canvas/src/hooks/use-storage.tsx | 2 +- .../fabric-canvas/src/hooks/use-viewport.tsx | 2 +- .../fabric-canvas/src/share/fabric-image.ts | 20 +- .../workflow/fabric-canvas/src/share/font.ts | 4 +- .../fabric-canvas/src/share/typings.ts | 16 +- .../workflow/fabric-canvas/src/typings.ts | 2 +- .../fabric-canvas/src/utils/controls.tsx | 104 ++-- .../src/utils/create-controls.tsx | 78 +-- .../fabric-canvas/src/utils/default-props.tsx | 4 +- .../src/utils/element-factory.tsx | 42 +- .../fabric-canvas/src/utils/fabric-utils.tsx | 28 +- .../src/utils/schema-to-form-value.ts | 6 +- .../fabric-canvas/src/utils/snap/helpline.tsx | 2 +- .../src/utils/snap/rule/align.tsx | 30 +- .../src/utils/snap/rule/padding.tsx | 42 +- .../src/utils/snap/rule/resize.tsx | 8 +- .../fabric-canvas/src/utils/snap/snap.tsx | 10 +- .../fabric-canvas/src/utils/snap/util.tsx | 6 +- .../workflow/fabric-canvas/tailwind.config.js | 2 +- .../workflow/fabric-canvas/tailwind.config.ts | 2 +- .../encapsulate-lines-service.test.ts | 4 +- .../src/api/encapsulate-api-service.ts | 2 +- .../feature-encapsulate/src/api/types.ts | 6 +- .../encapsulate/encapsulate-lines-service.ts | 52 +- .../encapsulate/encapsulate-nodes-service.ts | 40 +- .../src/encapsulate/encapsulate-service.ts | 28 +- .../encapsulate-variable-service.ts | 68 +-- .../src/encapsulate/types.ts | 44 +- .../generate/encapsulate-generate-service.ts | 30 +- .../feature-encapsulate/src/generate/types.ts | 8 +- .../src/render/encapsulate-button/index.tsx | 2 +- .../encapsulate-shortcuts-contribution.ts | 6 +- .../src/render/encapsulate-tooltip/index.tsx | 4 +- .../src/render/hooks/use-selected-nodes.ts | 2 +- .../src/render/hooks/use-validate.tsx | 8 +- .../feature-encapsulate/src/render/types.ts | 6 +- .../src/utils/check-encapsulate-gray.ts | 4 +- .../src/utils/exclude-start-end.ts | 2 +- .../src/utils/get-node-point.ts | 2 +- .../src/utils/get-nodes-parent-id.ts | 2 +- .../src/utils/get-nodes-with-sub-canvas.ts | 4 +- .../src/utils/get-sub-workflow-info.ts | 6 +- .../src/utils/has-sub-canvas-nodes.ts | 2 +- .../src/utils/set-node-position.ts | 4 +- .../src/utils/subcanvas.ts | 8 +- .../feature-encapsulate/src/utils/variable.ts | 6 +- .../validate/encapsulate-validate-service.ts | 4 +- .../feature-encapsulate/src/validate/types.ts | 56 +-- .../validators/encapsulate-form-validator.ts | 2 +- .../history/src/hooks/use-clear-history.ts | 2 +- .../workflow-operation-report-service.ts | 2 +- ...workflow-history-shortcuts-contribution.ts | 6 +- .../packages/workflow/nodes/src/constants.ts | 16 +- .../entity-datas/workflow-node-data/types.ts | 30 +- .../workflow-node-data/workflow-node-data.ts | 24 +- .../src/service/workflow-nodes-service.ts | 18 +- .../nodes/src/setting-on-error/constants.ts | 20 +- .../src/setting-on-error/data-transformer.ts | 4 +- .../hooks/use-timeout-config.ts | 2 +- .../nodes/src/setting-on-error/types.ts | 38 +- .../nodes/src/setting-on-error/utils.ts | 6 +- .../utils/get-timeout-config.ts | 4 +- .../src/setting-on-error/utils/outputs.ts | 18 +- .../nodes/src/typings/form-value-to-dto.ts | 2 +- .../workflow/nodes/src/typings/node.ts | 8 +- .../nodes/src/typings/playground-context.ts | 4 +- .../workflow/nodes/src/typings/test-run.ts | 2 +- .../workflow/nodes/src/typings/trigger.ts | 2 +- .../utils/__tests__/get-llm-models.test.ts | 4 +- .../src/utils/__tests__/llm-utils.test.ts | 2 +- .../workflow/nodes/src/utils/add-node-data.ts | 4 +- .../nodes/src/utils/get-llm-model-ids.ts | 4 +- .../nodes/src/utils/get-llm-models.ts | 32 +- .../src/utils/get-sorted-input-parameters.ts | 10 +- .../workflow/nodes/src/utils/llm-utils.ts | 4 +- .../workflow/nodes/src/utils/node-utils.ts | 16 +- .../workflow/nodes/src/utils/trigger-form.ts | 8 +- .../__tests__/code-empty-validator.test.ts | 2 +- .../__tests__/node-meta-validator.test.ts | 4 +- .../question-option-validator.test.ts | 2 +- .../src/validators/input-tree-validator.ts | 20 +- .../src/validators/json-schema-validator.ts | 2 +- .../src/validators/node-meta-validator.ts | 2 +- .../output-tree-validator/schema.ts | 26 +- .../validators/question-option-validator.ts | 6 +- .../validators/setting-on-error-validator.ts | 2 +- .../src/workflow-document-with-format.ts | 24 +- .../nodes/src/workflow-json-format.ts | 48 +- .../src/workflow-nodes-container-module.ts | 2 +- .../scripts/create-node/plopfile.js | 26 +- .../related-bot-panel/use-related.tsx | 2 +- .../components/bot-project-select/bots.tsx | 12 +- .../components/bot-project-select/index.tsx | 4 +- .../components/bot-project-select/types.ts | 2 +- .../bot-project-select/use-bot-info.ts | 10 +- .../bot-project-select/use-ltm-info.ts | 2 +- .../bot-project-select/use-table-info.ts | 2 +- .../src/components/bot-select/bots.tsx | 4 +- .../src/components/bot-select/index.tsx | 4 +- .../src/components/bot-select/types.ts | 2 +- .../src/components/bot-select/use-bot-info.ts | 10 +- .../src/components/bot-select/use-ltm-info.ts | 2 +- .../components/bot-select/use-table-info.ts | 2 +- .../components/code-editor/code-editor.tsx | 6 +- .../components/code-editor/text-editor.tsx | 2 +- .../comment/commands/block-prefix.ts | 8 +- .../comment/commands/clear-format.ts | 2 +- .../comment/components/blank-area.tsx | 2 +- .../comment/components/border-area.tsx | 18 +- .../comment/components/container.tsx | 6 +- .../comment/components/content-drag-area.tsx | 8 +- .../comment/components/drag-area.tsx | 2 +- .../comment/components/editor/block.tsx | 20 +- .../comment/components/editor/index.tsx | 2 +- .../comment/components/editor/leaf.tsx | 6 +- .../comment/components/editor/placeholder.tsx | 2 +- .../components/comment/components/render.tsx | 14 +- .../comment/components/resize-area.tsx | 2 +- .../toolbar-container/use-activate.ts | 6 +- .../components/comment/components/toolbar.tsx | 28 +- .../src/components/comment/constant.ts | 48 +- .../src/components/comment/hooks/use-model.ts | 10 +- .../components/comment/hooks/use-overflow.ts | 6 +- .../src/components/comment/hooks/use-size.ts | 10 +- .../src/components/comment/model.ts | 130 ++--- .../src/components/comment/parsers/html.ts | 20 +- .../src/components/comment/parsers/json.ts | 8 +- .../components/comment/parsers/markdown.ts | 22 +- .../src/components/comment/parsers/text.ts | 14 +- .../condition-item-logic.tsx | 4 +- .../conversation-select/conversations.tsx | 10 +- .../src/components/copy-button/index.tsx | 4 +- .../src/components/custom-port/index.tsx | 4 +- .../database-detail-model.tsx | 4 +- .../src/components/drag-tooltip/index.tsx | 4 +- .../editor-container/expand-editor/index.tsx | 20 +- .../editor-container/inner-editor/index.tsx | 6 +- .../components/float-layout/float-layout.tsx | 12 +- .../components/float-layout/float-panel.tsx | 14 +- .../flow-role/role-button/index.tsx | 10 +- .../auto-generate/index.tsx | 12 +- .../role-avatar-upload/picture-upload.tsx | 6 +- .../utils/custom-upload-request.ts | 6 +- .../cropper/cropper-cover.tsx | 2 +- .../background-upload/cropper/cropper-img.tsx | 12 +- .../cropper/use-crop-image.ts | 16 +- .../background-upload/use-drag-image.tsx | 2 +- .../use-submit-cropped-image.ts | 2 +- .../background-upload/utils.ts | 16 +- .../role-config-form/role-name-input.tsx | 2 +- .../role-onboarding/ai-generate-btn.tsx | 6 +- .../role-onboarding/suggestion-list.tsx | 4 +- .../voice-data-select/use-voice-options.ts | 2 +- .../voice-data-select/voice-select.tsx | 2 +- .../flow-role/role-config-form/utils.ts | 16 +- .../src/components/line-add-button/index.tsx | 2 +- .../components/line-popover/line-popover.tsx | 4 +- .../model-select/components/model-setting.tsx | 32 +- .../components/selector/option-item.tsx | 4 +- .../model-select/components/settings.tsx | 2 +- .../src/components/model-select/index.tsx | 8 +- .../components/model-select/utils/index.tsx | 14 +- .../src/components/node-context-provider.tsx | 2 +- .../components/custom-drag-card.tsx | 6 +- .../components/node-panel/components/list.tsx | 4 +- .../node-panel/components/panel.tsx | 8 +- .../plugin-node/plugin-node-list.tsx | 6 +- .../search-result-node-list/index.tsx | 4 +- .../sub-workflow-category-list/index.tsx | 2 +- .../node-panel/hooks/node-panel-context.tsx | 2 +- .../hooks/use-favorite-plugin-node-list.ts | 2 +- .../content/database-content/database.tsx | 2 +- .../content/image-generate-content/model.tsx | 2 +- .../node-render-new/content/index.tsx | 6 +- .../content/llm-content/update-node-skills.ts | 2 +- .../content/variable-merge-content/index.tsx | 2 +- .../use-variable-merge-variable-tags.ts | 8 +- .../variable-merge-item.tsx | 2 +- .../fields/condition-branch.tsx | 4 +- .../fields/database-setting-fields.tsx | 6 +- .../fields/exception-field/exception-port.tsx | 6 +- .../node-render-new/fields/intents.tsx | 2 +- .../node-render-new/fields/knowledge.tsx | 6 +- .../fields/label-with-tooltip.tsx | 2 +- .../node-render-new/fields/model.tsx | 4 +- .../node-render-new/fields/outputs.tsx | 2 +- .../fields/overflow-tag-list.tsx | 2 +- .../node-render-new/fields/question-pairs.tsx | 2 +- .../use-input-parameters-variable-tags.ts | 24 +- .../fields/use-outputs-variable-tags.ts | 2 +- .../fields/use-valid-variable.tsx | 2 +- .../fields/variable-tag-list.tsx | 10 +- .../hooks/use-available-node-variables.ts | 2 +- .../hooks/use-http-url-variables.ts | 10 +- .../node-render/node-render-new/index.tsx | 2 +- .../node-render/node-render-new/ports.tsx | 2 +- .../src/components/node-side-sheet/index.tsx | 4 +- .../execute-result-panel/index.tsx | 4 +- .../reference-node-origin.tsx | 2 +- .../reference-node-version.tsx | 4 +- .../reference-node-info/use-node-origin.ts | 20 +- .../components/resizable-side-panel/index.tsx | 2 +- .../retrieve-banner/use-retrieve.ts | 4 +- .../components/custom-drag-layer.tsx | 8 +- .../components/sortable-item.tsx | 20 +- .../components/sortable-list.tsx | 12 +- .../sortable-list/hooks/use-sort.ts | 10 +- .../sub-canvas/components/container/index.tsx | 4 +- .../sub-canvas/components/tips/use-control.ts | 4 +- .../template-panel/template-card-list.tsx | 8 +- .../template-panel/template-card.tsx | 6 +- .../template-panel/template-panel.tsx | 8 +- .../template-panel/template-preview.tsx | 2 +- .../bot-project-variable-select/select.tsx | 4 +- .../conversation-select.tsx | 4 +- .../test-form-panel.tsx | 8 +- .../testset-bot-project-select.tsx | 4 +- .../test-run/chat-history/index.tsx | 6 +- .../test-run/common-side-sheet-v2/index.tsx | 2 +- .../common-side-sheet-v2/sheet-keys.ts | 4 +- .../components/test-run/constants/index.ts | 6 +- .../test-run/constants/test-form.ts | 42 +- .../error-item.tsx | 2 +- .../execute-result-panel/index.tsx | 10 +- .../execute-result-panel/log-detail.tsx | 28 +- .../components/error-item.tsx | 2 +- .../components/execute-result.tsx | 6 +- .../components/execute-state.tsx | 4 +- .../hooks/use-result-side-sheet-visible.ts | 8 +- .../execute-result-side-sheet/index.tsx | 2 +- .../execute-status-bar-v2/content.tsx | 18 +- .../test-run/execute-status-bar-v2/index.tsx | 16 +- .../test-run/hooks/use-copilot-generate.ts | 2 +- .../hooks/use-generate-test-form-fields.tsx | 12 +- .../use-get-scene-flow-role-list-schema.tsx | 2 +- .../components/test-run/hooks/use-need-bot.ts | 50 +- .../test-run/hooks/use-need-scene-bot.ts | 4 +- .../test-run/hooks/use-save-testset.ts | 2 +- .../hooks/use-test-form-initial-value-v2.ts | 2 +- .../test-run/hooks/use-test-form-schema.tsx | 36 +- .../test-run/hooks/use-test-run-flow-v2.ts | 14 +- .../test-run/hooks/use-test-run-flow.tsx | 12 +- .../test-run/hooks/use-test-run-node.ts | 6 +- .../test-run/hooks/use-test-run-status.ts | 2 +- .../test-run/img-log/use-element-width.ts | 8 +- .../img-log/use-test-run-outputs-value.ts | 4 +- .../log-navigation-v2/custom-selector.tsx | 8 +- .../test-run/log-navigation-v2/index.tsx | 18 +- .../navigate-item-disabled.tsx | 6 +- .../log-navigation-v2/page-selector.tsx | 6 +- .../test-form-materials/file/base-adapter.tsx | 8 +- .../test-form-materials/file/index.tsx | 2 +- .../test-form-materials/file/types.ts | 10 +- .../test-form-materials/json-editor/index.tsx | 12 +- .../test-form-materials/json-editor/new.tsx | 6 +- .../test-form-materials/json-editor/utils.ts | 4 +- .../testset/testset-select.tsx | 4 +- .../ai-generate/generate-button.tsx | 4 +- .../test-run/test-form-sheet-v2/footer.tsx | 4 +- .../test-run/test-form-sheet-v2/index.tsx | 8 +- .../test-form-sheet-v2/test-node-form.tsx | 6 +- .../mode-form-kit/format-values.ts | 16 +- .../get-json-mode-field-default-value.ts | 8 +- .../mode-form-kit/merge-form-values.ts | 6 +- .../mode-form-kit/set-cache-values.ts | 2 +- .../mode-form-kit/to-json-mode-schema.ts | 4 +- .../mode-form-kit/to-json-values.ts | 2 +- .../mode-form-kit/try-save-testset.ts | 2 +- .../test-form-v3/test-run-form-model.ts | 16 +- .../test-form-v3/use-mode-form-schema.ts | 2 +- .../test-run/test-run-button/single-node.tsx | 6 +- .../trigger-test-run-button.tsx | 20 +- .../test-run/test-set-select-field/index.tsx | 2 +- .../components/test-run/test-set/provider.tsx | 8 +- .../test-run/trace/use-goto-node.ts | 6 +- .../src/components/test-run/types/index.ts | 10 +- .../components/test-run/types/test-form.ts | 20 +- .../utils/generate-copilot-form-data.ts | 4 +- .../test-run/utils/generate-copilot-query.ts | 2 +- ...enerate-crud-nodes-test-run-form-fields.ts | 8 +- ...ate-imageflow-generate-test-form-fields.ts | 2 +- .../components/test-run/utils/generate-log.ts | 50 +- .../utils/generate-test-form-fields.ts | 50 +- .../utils/generate-test-form-initial-value.ts | 16 +- .../test-run/utils/generate-testset-data.ts | 4 +- .../utils/generate-update-trigger-fields.ts | 2 +- .../utils/ignore-rehaje-expression.ts | 4 +- .../test-run/utils/is-static-object-ref.ts | 6 +- .../test-run/utils/stringify-value.ts | 6 +- .../toolbar/components/auto-layout.tsx | 4 +- .../components/toolbar/components/comment.tsx | 8 +- .../toolbar/components/interactive.tsx | 2 +- .../components/toolbar/components/tools.tsx | 2 +- .../components/toolbar/components/zoom.tsx | 2 +- .../components/toolbar/hooks/use-add-node.ts | 14 +- .../components/workflow-container/index.tsx | 20 +- .../use-data-compensation.ts | 8 +- .../workflow-float-layout.tsx | 2 +- .../components/workflow-status.tsx | 6 +- .../components/workflow-header-info/index.tsx | 10 +- .../components/collaborators-button/index.tsx | 4 +- .../use-collaborators-pay.tsx | 10 +- .../components/duplicate-button.tsx | 12 +- .../force-push-popover/use-force-push.ts | 8 +- .../components/history-drawer/index.tsx | 4 +- .../history-drawer/use-commit-action.ts | 4 +- .../components/history-button/index.tsx | 2 +- .../publish-button-v2/publish-button.tsx | 4 +- .../publish-button-v2/publish-with-diff.tsx | 2 +- .../publish-button-v2/publish-with-env.tsx | 8 +- .../publish-with-version-v2.tsx | 2 +- .../publish-with-version.tsx | 2 +- .../use-is-publish-disabled.ts | 14 +- .../components/reference-modal/link-node.tsx | 4 +- .../components/reference-modal/utils.tsx | 2 +- .../components/submit-button.tsx | 4 +- .../hooks/use-diff-confirm/index.tsx | 8 +- .../hooks/use-merge-confirm/index.tsx | 2 +- .../hooks/use-merge-confirm/merge-context.tsx | 4 +- .../hooks/use-merge-confirm/use-merge.ts | 4 +- .../hooks/use-plugin-credits/index.ts | 2 +- .../hooks/use-publish-reference-confirm.tsx | 2 +- .../components/inner-side-sheet-holder.tsx | 6 +- .../components/singleton-inner-side-sheet.tsx | 2 +- .../hooks/use-inner-side-sheet-store.tsx | 12 +- .../workflow-outer-side-sheet/index.tsx | 4 +- .../publish-confirm-content.tsx | 2 +- .../workflow-references/references-tip.tsx | 2 +- .../playground/src/constants/index.ts | 24 +- .../workflow-nodes-v2-contribution.ts | 4 +- .../workflow-page-container-module.ts | 6 +- .../container/workflow-page-contribution.ts | 10 +- .../src/contexts/node-render-context.tsx | 2 +- .../entities/workflow-dataset-store-entity.ts | 16 +- .../entities/workflow-exec-state-entity.ts | 26 +- .../entities/workflow-global-state-entity.ts | 118 ++--- .../workflow-template-state-entity.ts | 2 +- .../workflow-test-form-state-entity.ts | 30 +- .../components/dataset-select/index.tsx | 12 +- .../components/dataset-setting/index.tsx | 28 +- .../components/dataset-write-chunk/index.tsx | 16 +- .../components/dataset-write-parser/index.tsx | 8 +- .../components/file-input/upload-context.tsx | 2 +- .../components/form-card/index.tsx | 14 +- .../components/form-item/index.tsx | 2 +- .../components/input-header/index.tsx | 4 +- .../components/input-name/index.tsx | 4 +- .../components/input-operator/index.tsx | 2 +- .../components/input-tree-node/index.tsx | 8 +- .../components/input-value/index.tsx | 6 +- .../components/input-tree/constants.ts | 4 +- .../components/input-tree/index.tsx | 48 +- .../components/input-tree/types.ts | 30 +- .../components/input-tree/utils.ts | 16 +- .../components/level-line/index.module.less | 2 +- .../components/level-line/level-line.tsx | 10 +- .../components/level-line/utils.ts | 2 +- .../literal-value-input/input-integer.tsx | 2 +- .../literal-value-input/input-json.tsx | 2 +- .../components/literal-value-input/type.ts | 4 +- .../components/literal-value-input/utils.tsx | 4 +- .../components/loop-output-select/index.tsx | 12 +- .../components/model-selector/index.tsx | 12 +- .../components/model-selector/option-item.tsx | 2 +- .../mutable-variable-assign/index.tsx | 16 +- .../node-header/components/PluginMockSet.tsx | 6 +- .../components/node-header/index.tsx | 12 +- .../node-header/utils/get-bg-color.ts | 10 +- .../components/conversation-select/index.tsx | 4 +- .../expand-content/default-value-input.tsx | 4 +- .../components/expand-content/input-time.tsx | 2 +- .../components/param-description/index.tsx | 2 +- .../components/param-name/index.tsx | 2 +- .../components/param-operator/index.tsx | 2 +- .../components/param-type/index.tsx | 6 +- .../components/param-type/utils.tsx | 28 +- .../components/custom-tree-node/constants.ts | 2 +- .../components/custom-tree-node/index.tsx | 32 +- .../components/custom-tree-node/type.ts | 40 +- .../output-tree/components/header/index.tsx | 6 +- .../components/json-editor/index.tsx | 2 +- .../components/json-import/index.tsx | 20 +- .../json-import/utils/add-readonly-data.ts | 6 +- .../components/json-import/utils/merge.ts | 8 +- .../components/response-format/index.tsx | 12 +- .../components/output-tree/constants.ts | 4 +- .../components/output-tree/index.tsx | 86 ++-- .../components/output-tree/utils.ts | 16 +- .../components/radio/index.tsx | 2 +- .../components/error-form/index.tsx | 4 +- .../components/error-form/use-exapand.ts | 2 +- .../setting-on-error/components/ext/index.tsx | 2 +- .../components/json/index.tsx | 2 +- .../components/process-type/index.tsx | 2 +- .../components/retry-times/index.tsx | 2 +- .../components/timeout/index.tsx | 14 +- .../setting-on-error/error-form.tsx | 4 +- .../hooks/use-batch-change.ts | 2 +- .../hooks/use-exception-change.ts | 12 +- .../hooks/use-json-with-outputs.tsx | 16 +- .../hooks/use-refresh-on-variable-change.ts | 2 +- .../hooks/use-setting-on-error.ts | 14 +- .../utils/generate-json-schema.ts | 4 +- .../setting-on-error/utils/index.ts | 66 +-- .../components/tag-selector/index.tsx | 28 +- .../components/tag-selector/use-slot-node.tsx | 8 +- .../composite-select-tree-panel.tsx | 2 +- .../tree-variable-selector/utils.tsx | 22 +- .../variable-selector.tsx | 28 +- .../components/validation/hooks.ts | 6 +- .../components/validation/with-validation.tsx | 2 +- .../value-expression-input/const.ts | 6 +- .../ref-value-display.tsx | 6 +- .../typed-value-expression-input.tsx | 40 +- .../value-expression-input.tsx | 28 +- .../voice/use-voice.tsx | 2 +- .../variable-type-selector/utils.tsx | 28 +- .../variable-type-selector.tsx | 4 +- .../decorators/form-layout/index.tsx | 8 +- .../hooks/use-fit-view-port.ts | 4 +- .../hooks/use-get-current-input-parameters.ts | 2 +- .../hooks/use-llm-prompt-history.ts | 2 +- .../hooks/use-node-available-variables.ts | 2 +- .../setters/answer-option/index.tsx | 20 +- .../setters/answer-option/utils.ts | 2 +- .../setters/canvas/components/canvas.tsx | 2 +- .../form-extensions/setters/canvas/index.tsx | 8 +- .../setters/code/biz-ide-panel/biz-ide.tsx | 4 +- .../setters/code/biz-ide-panel/index.tsx | 2 +- .../setters/code/code-with-biz-ide.tsx | 4 +- .../code/hooks/use-ide-input-output-type.ts | 4 +- .../hidden-condition/condition-item.tsx | 6 +- .../multi-condition/condition-branch.tsx | 2 +- .../multi-condition/condition-item-logic.tsx | 4 +- .../condition-params-item/constants.ts | 14 +- .../condition-params-item/index.tsx | 18 +- .../operator/convert-map2options.ts | 12 +- .../condition-params-item/operator/index.tsx | 2 +- .../condition-params-item/utils.ts | 32 +- .../value-expression-with-state/index.tsx | 2 +- .../condition/multi-condition/constants.tsx | 4 +- .../draggable/condition-branch.tsx | 18 +- .../draggable/custom-drag-layer.tsx | 2 +- .../condition/multi-condition/index.tsx | 10 +- .../condition/multi-condition/types.ts | 8 +- .../validate/ValidationField.tsx | 4 +- .../multi-condition/validate/validate.ts | 12 +- .../setters/cronjob-select/fix-cronjob.tsx | 12 +- .../database-select/database-select.tsx | 2 +- .../setters/dataset-write-index/index.tsx | 8 +- .../setters/delimiter-selector/index.tsx | 10 +- .../expression-editor/container/index.tsx | 12 +- .../setters/expression-editor/index.tsx | 24 +- .../expression-editor/utils/convert-inputs.ts | 2 +- .../setters/file-upload/index.tsx | 4 +- .../src/form-extensions/setters/helper.ts | 2 +- .../hooks/use-image-preview-visible.ts | 8 +- .../hooks/use-input-contains-image.ts | 2 +- .../hooks/use-ref-variable-path-list.ts | 4 +- .../player-checkbox-group.tsx | 2 +- .../setters/message-visibility/types.ts | 10 +- .../model-select/components/model-setting.tsx | 32 +- .../components/selector/option-item.tsx | 4 +- .../model-select/components/settings.tsx | 2 +- .../setters/model-select/index.tsx | 8 +- .../setters/model-select/utils/index.tsx | 14 +- .../setters/node-header/index.tsx | 4 +- .../setters/node-input-name/index.ts | 4 +- .../node-input-name/node-input-name.tsx | 4 +- .../setters/node-input-name/type.ts | 10 +- .../setters/node-input-name/utils.ts | 22 +- .../setters/node-output-name/index.ts | 2 +- .../form-extensions/setters/notify/index.tsx | 2 +- .../setters/output-tree/index.tsx | 16 +- .../speaker-message-set-array/index.tsx | 6 +- .../use-normalize-value-with-role-list.ts | 6 +- .../setters/sql/sql/auto-generate/form.tsx | 2 +- .../sql/auto-generate/use-nl2sql-mutation.ts | 2 +- .../system-prompt/expand-sheet-editor.tsx | 2 +- .../setters/system-prompt/index.tsx | 2 +- .../form-extensions/setters/timezone/const.ts | 8 +- .../setters/timezone/index.tsx | 16 +- .../setters/timezone/utils/timezone.ts | 12 +- .../setters/to-standard-setter.tsx | 2 +- .../setters/view-variable-select/index.tsx | 2 +- .../validators/value-expression-validator.ts | 6 +- .../src/form/components/field-array.tsx | 2 +- .../src/form/components/section.tsx | 2 +- .../src/form/components/sortable-item.tsx | 2 +- .../src/form/contexts/form-context.ts | 2 +- .../playground/src/form/hooks/use-watch.ts | 6 +- .../workflow/playground/src/form/type.ts | 24 +- .../src/hooks/use-add-node-modal/index.tsx | 20 +- .../src/hooks/use-add-node-visible.ts | 2 +- .../playground/src/hooks/use-add-node.ts | 14 +- .../src/hooks/use-biz-ide-state.tsx | 28 +- .../src/hooks/use-current-database-id.ts | 4 +- .../src/hooks/use-current-database-query.ts | 12 +- .../src/hooks/use-get-workflow-mode.ts | 2 +- .../playground/src/hooks/use-global-state.ts | 2 +- .../src/hooks/use-have-collaborators.ts | 2 +- .../src/hooks/use-input-variables.ts | 2 +- .../src/hooks/use-new-database-query.ts | 12 +- .../src/hooks/use-node-render-data.ts | 4 +- .../use-ref-input/use-ref-input-node.tsx | 2 +- .../use-ref-input/use-ref-input-props.tsx | 4 +- .../hooks/use-resizable-side-panel-store.ts | 2 +- .../playground/src/hooks/use-test-run.ts | 32 +- .../src/hooks/use-update-sorted-port-lines.ts | 12 +- .../src/hooks/use-upload/constant.ts | 4 +- .../playground/src/hooks/use-upload/types.ts | 8 +- .../src/hooks/use-upload/use-upload.ts | 4 +- .../hooks/use-upload/utils/format-bytes.ts | 6 +- .../use-upload/utils/get-file-extension.ts | 2 +- .../hooks/use-upload/utils/get-image-size.ts | 2 +- .../use-upload/validate/accept-validate.ts | 2 +- .../validate/image-size-validate.ts | 4 +- .../use-upload/validate/size-validate.ts | 2 +- .../src/hooks/use-validate-workflow.ts | 2 +- .../src/hooks/use-workflow-models.ts | 2 +- .../src/hooks/use-workflow-preset.tsx | 4 +- .../src/hooks/use-workflow-references.ts | 4 +- .../create-batch-function-json.ts | 2 +- .../create-batch-function-lines.ts | 4 +- .../create-batch-function-template-data.ts | 2 +- .../batch-function/create-batch-function.ts | 2 +- .../node-registries/batch/data-transformer.ts | 6 +- .../src/node-registries/batch/form-meta.tsx | 12 +- .../node-registries/batch/node-registry.ts | 4 +- .../node-registries/break/data-transformer.ts | 4 +- .../src/node-registries/break/form-meta.tsx | 12 +- .../node-registries/break/node-registry.ts | 2 +- .../src/node-registries/code/constants.ts | 4 +- .../node-registries/code/data-transformer.ts | 6 +- .../src/node-registries/code/form-meta.tsx | 12 +- .../src/node-registries/code/node-registry.ts | 2 +- .../src/node-registries/comment/constant.ts | 4 +- .../src/node-registries/comment/index.tsx | 8 +- .../components/cronjob-select/fix-cronjob.tsx | 12 +- .../components/dynamic-form/dynamic-form.tsx | 2 +- .../common/components/dynamic-form/types.ts | 6 +- .../components/expression-editor-field.tsx | 2 +- .../components/image-model-select-field.tsx | 2 +- .../common/components/input-parameters.tsx | 2 +- .../common/components/node-config-form.tsx | 6 +- .../common/components/outputs.tsx | 2 +- .../common/components/timezone/const.ts | 8 +- .../common/components/timezone/index.tsx | 16 +- .../components/timezone/utils/timezone.ts | 12 +- .../node-input-name/node-input-name.tsx | 4 +- .../node-input-name/type.ts | 10 +- .../outputs/output-tree-meta-validator.ts | 12 +- .../common/fields/outputs/outputs.tsx | 8 +- .../param-type/index.tsx | 4 +- .../parameters-input-group-field.tsx | 2 +- .../common/hocs/with-node-config-form.tsx | 8 +- .../common/utils/custom-setter-helpers.ts | 10 +- .../common/utils/with-setting-on-error.ts | 4 +- .../validators/create-input-tree-validator.ts | 2 +- .../continue/data-transformer.ts | 4 +- .../node-registries/continue/form-meta.tsx | 12 +- .../node-registries/continue/node-registry.ts | 2 +- .../condition-field/condition-item-field.tsx | 2 +- .../common/hooks/use-reset-condition.ts | 2 +- .../validators/create-condition-validator.ts | 4 +- .../create-select-and-set-fields-validator.ts | 2 +- .../database/database-base/form-meta.tsx | 14 +- .../order-by-field/use-order-by-visible.ts | 2 +- .../use-validate-order-by-fields.ts | 2 +- .../query-fields-column-titles.tsx | 2 +- .../dataset-search/data-transformer.ts | 12 +- .../dataset/dataset-search/form-meta.tsx | 12 +- .../components/dataset-write-setting.tsx | 6 +- .../dataset/dataset-write/data-transformer.ts | 2 +- .../dataset/dataset-write/form-meta.tsx | 4 +- .../src/node-registries/end/constants.ts | 2 +- .../node-registries/end/data-transformer.ts | 6 +- .../src/node-registries/end/form-meta.tsx | 12 +- .../src/node-registries/end/form.tsx | 2 +- .../src/node-registries/end/node-registry.ts | 2 +- .../components/base-editor/bash-editor.tsx | 2 +- .../components/base-editor/json-editor.tsx | 2 +- .../base-editor/raw-text-editor.tsx | 2 +- .../http/components/base-editor/validate.ts | 2 +- .../components/variable-support/constants.ts | 4 +- .../hooks/use-keyboard-actions.ts | 12 +- .../hooks/use-options-operations.ts | 8 +- .../variable-support/hooks/use-selection.ts | 2 +- .../hooks/use-variable-injector.ts | 12 +- .../http/components/variable-support/utils.ts | 22 +- .../variable-deleted-widget.ts | 2 +- .../variable-support/variable-extension.tsx | 28 +- .../variable-prefix-widget.ts | 2 +- .../variable-subfix-widget.ts | 4 +- .../src/node-registries/http/constants.ts | 4 +- .../node-registries/http/data-transformer.ts | 16 +- .../http/fields/hooks/use-variable-tree.ts | 2 +- .../fields/hooks/use-variable-with-node.ts | 4 +- .../json-import-editor/inner-editor.tsx | 6 +- .../json-import-editor/json-editor-field.tsx | 2 +- .../http/fields/raw-text-editor/index.tsx | 2 +- .../fields/raw-text-editor/inner-editor.tsx | 6 +- .../src/node-registries/http/form-meta.tsx | 12 +- .../src/node-registries/http/node-test.ts | 8 +- .../http/setters/api/index.tsx | 4 +- .../components/condition/multi-condition.tsx | 12 +- .../src/node-registries/if/constants.ts | 2 +- .../node-registries/if/data-transformer.ts | 4 +- .../src/node-registries/if/form-meta.tsx | 12 +- .../components/canvas/components/canvas.tsx | 2 +- .../image-canvas/components/index.tsx | 6 +- .../node-registries/image-canvas/constants.ts | 4 +- .../image-canvas/data-transformer.ts | 4 +- .../image-canvas/form-meta.tsx | 14 +- .../image-canvas/node-registry.ts | 2 +- .../components/prompt-field.tsx | 2 +- .../create-preprocessor-options.ts | 6 +- .../image-generate/form-meta.tsx | 16 +- .../node-registries/image-generate/form.tsx | 4 +- .../playground/src/node-registries/index.ts | 2 +- .../src/node-registries/input/constants.ts | 2 +- .../node-registries/input/data-transformer.ts | 2 +- .../src/node-registries/input/form-meta.tsx | 12 +- .../src/node-registries/input/types.ts | 2 +- .../intent/components/intents/index.tsx | 20 +- .../src/node-registries/intent/constants.ts | 2 +- .../intent/data-transformer.ts | 12 +- .../intent/effects/intent-mode-effect.ts | 20 +- .../src/node-registries/intent/form-meta.tsx | 14 +- .../node-registries/intent/node-registry.ts | 2 +- .../src/node-registries/intent/node-test.ts | 2 +- .../json-stringify/constants.ts | 4 +- .../json-stringify/data-transformer.ts | 4 +- .../json-stringify/form-meta.tsx | 14 +- .../node-registries/loop/data-transformer.ts | 6 +- .../src/node-registries/loop/form-meta.tsx | 12 +- .../loop/hooks/use-loop-type.ts | 4 +- .../loop/loop-content/loop-variables.tsx | 2 +- .../loop-outputs/format-loop-output-name.ts | 4 +- .../create-loop-function-json.ts | 2 +- .../create-loop-function-lines.ts | 4 +- .../create-loop-function-template-data.ts | 2 +- .../loop-function/create-loop-function.ts | 2 +- .../src/node-registries/loop/node-registry.ts | 4 +- .../src/node-registries/loop/node-test.ts | 6 +- .../node-registries/ltm/components/inputs.tsx | 2 +- .../src/node-registries/ltm/constants.ts | 4 +- .../node-registries/ltm/data-transformer.ts | 14 +- .../src/node-registries/ltm/form-meta.tsx | 14 +- .../src/node-registries/ltm/node-registry.ts | 2 +- .../src/node-registries/output/constants.ts | 2 +- .../output/data-transformer.ts | 6 +- .../src/node-registries/output/form-meta.tsx | 12 +- .../src/node-registries/output/form.tsx | 2 +- .../node-registries/output/node-content.tsx | 2 +- .../node-registries/output/node-registry.ts | 2 +- .../plugin/components/plugin-link.tsx | 8 +- .../plugin/components/view-example.tsx | 6 +- .../plugin/data-transformer.ts | 34 +- .../src/node-registries/plugin/form-meta.tsx | 20 +- .../plugin/hooks/use-plugin-detail.ts | 8 +- .../node-registries/plugin/node-registry.ts | 2 +- .../src/node-registries/plugin/types.ts | 12 +- .../plugin/utils/api-node-checker.ts | 62 +-- .../plugin/utils/api-node-error-setting.ts | 12 +- .../plugin/utils/get-api-node-identifier.ts | 4 +- .../answer-option-field/add-option-button.tsx | 12 +- .../components/answer-option-field/index.tsx | 10 +- .../components/answer-option-field/utils.ts | 2 +- .../question/data-transformer.ts | 2 +- .../effects/sync-question-answer-type.ts | 4 +- .../question/effects/sync-question-outputs.ts | 2 +- .../node-registries/question/form-meta.tsx | 12 +- .../node-registries/set-variable/constants.ts | 2 +- .../content/set-tags/use-set-tags.ts | 4 +- .../set-variable/data-transformer.ts | 4 +- .../set-variable/form-meta.tsx | 12 +- .../set-variable/node-registry.ts | 2 +- .../src/node-registries/start/constants.ts | 4 +- .../node-registries/start/data-transformer.ts | 16 +- .../src/node-registries/start/form-meta.tsx | 16 +- .../src/node-registries/start/form.tsx | 2 +- .../src/node-registries/start/index.ts | 2 +- .../node-registries/start/node-registry.ts | 2 +- .../src/node-registries/start/node-test.ts | 10 +- .../components/sub-workflow-link.tsx | 8 +- .../node-registries/sub-workflow/constants.ts | 4 +- .../sub-workflow/data-transformer.ts | 24 +- .../sub-workflow/form-meta.tsx | 20 +- .../sub-workflow/node-content.tsx | 2 +- .../sub-workflow/node-registry.ts | 8 +- .../node-registries/sub-workflow/node-test.ts | 8 +- .../services/subworkflow-node-service.ts | 2 +- .../services/subworkflow-node-store.ts | 4 +- .../src/node-registries/sub-workflow/types.ts | 16 +- .../utils/get-input-default-value.ts | 4 +- .../utils/sync-to-latest-release.ts | 8 +- .../components/concat-setting/index.tsx | 4 +- .../concat-setting/setting-form.tsx | 2 +- .../node-registries/text-process/constants.ts | 42 +- .../text-process/data-transformer.ts | 50 +- .../text-process/form-meta.tsx | 12 +- .../src/node-registries/text-process/form.tsx | 16 +- .../src/node-registries/text-process/types.ts | 20 +- .../trigger-delete/constants.ts | 4 +- .../trigger-delete/data-transformer.ts | 4 +- .../trigger-delete/form-meta.tsx | 14 +- .../trigger-delete/node-registry.ts | 2 +- .../node-registries/trigger-read/constants.ts | 4 +- .../trigger-read/form-meta.tsx | 14 +- .../trigger-read/node-registry.ts | 2 +- .../trigger-upsert/constants.ts | 4 +- .../trigger-upsert/data-transformer.ts | 24 +- .../trigger-upsert/form-meta.tsx | 14 +- .../trigger-upsert/node-content.tsx | 2 +- .../trigger-upsert/node-registry.ts | 2 +- .../node-registries/trigger-upsert/types.ts | 2 +- .../trigger-upsert/utils/trigger-form.ts | 4 +- .../trigger-upsert/utils/validators.ts | 2 +- .../variable/data-transformer.ts | 6 +- .../node-registries/variable/form-meta.tsx | 12 +- .../clear-conversation-history/form-meta.tsx | 14 +- .../chat/clear-conversation-history/index.ts | 2 +- .../chat/create-conversation/form-meta.tsx | 14 +- .../chat/create-conversation/index.ts | 2 +- .../src/nodes-v2/chat/create-form-meta.tsx | 18 +- .../nodes-v2/chat/create-message/constants.ts | 6 +- .../src/nodes-v2/chat/create-message/index.ts | 2 +- .../src/nodes-v2/chat/create-node-registry.ts | 14 +- .../chat/delete-conversation/index.ts | 2 +- .../src/nodes-v2/chat/delete-message/index.ts | 2 +- .../chat/query-conversation-history/index.ts | 2 +- .../chat/query-conversation-list/index.ts | 2 +- .../chat/query-message-list/form-meta.tsx | 14 +- .../nodes-v2/chat/query-message-list/index.ts | 2 +- .../chat/sync-conversation-name-effect.ts | 6 +- .../src/nodes-v2/chat/transform-on-init.ts | 6 +- .../src/nodes-v2/chat/transform-on-submit.ts | 2 +- .../chat/update-conversation/index.ts | 2 +- .../src/nodes-v2/chat/update-message/index.ts | 2 +- .../components/batch/batch-setting-form.tsx | 4 +- .../expression-editor/container/index.tsx | 10 +- .../fixed-input-parameters/index.tsx | 2 +- .../components/form-item-feedback/index.tsx | 2 +- .../global-variable-select/index.tsx | 6 +- .../nodes-v2/components/node-header/index.tsx | 6 +- .../node-input-name/node-input-name.tsx | 4 +- .../components/node-input-name/type.ts | 10 +- .../components/node-input-name/validate.ts | 4 +- .../src/nodes-v2/components/outputs/index.tsx | 12 +- .../system-prompt/expand-sheet-editor.tsx | 2 +- .../components/system-prompt/index.tsx | 2 +- .../system-prompt/prompt-editor-with-kit.tsx | 6 +- .../value-expression-input/index.tsx | 4 +- .../components/view-variable-select/index.tsx | 2 +- .../playground/src/nodes-v2/constants.ts | 4 +- .../playground/src/nodes-v2/llm/cot/utils.ts | 18 +- .../src/nodes-v2/llm/hooks/use-model-type.ts | 2 +- .../src/nodes-v2/llm/llm-form-meta.tsx | 22 +- .../playground/src/nodes-v2/llm/node-test.ts | 2 +- .../nodes-v2/llm/skills/data-transformer.ts | 4 +- .../src/nodes-v2/llm/skills/index.tsx | 2 +- .../src/nodes-v2/llm/skills/skill-modal.tsx | 2 +- .../src/nodes-v2/llm/skills/types.ts | 8 +- .../llm/skills/use-model-skill-disabled.tsx | 2 +- .../skills/use-query-latest-fc-settings.ts | 52 +- .../llm/skills/use-query-setting-detail.ts | 2 +- .../src/nodes-v2/llm/skills/utils.ts | 8 +- .../src/nodes-v2/llm/user-prompt/index.tsx | 2 +- .../playground/src/nodes-v2/llm/utils.ts | 12 +- .../validators/llm-input-name-validator.ts | 8 +- .../llm-output-tree-meta-validator.ts | 12 +- .../vision/components/vision-input-field.tsx | 2 +- .../vision/components/vision-name-field.tsx | 2 +- .../vision/components/vision-value-field.tsx | 4 +- .../nodes-v2/llm/vision/components/vision.tsx | 2 +- .../vision/hooks/use-model-enabled-types.ts | 2 +- .../llm/vision/utils/is-vision-equal.ts | 2 +- .../llm/vision/utils/is-vision-input.ts | 2 +- .../create-value-expression-input-validate.ts | 2 +- .../nodes-v2/materials/node-meta-validate.ts | 2 +- .../materials/setting-on-error-validate.ts | 2 +- .../components/add-group-button/index.tsx | 2 +- .../components/delete-group-button/index.tsx | 2 +- .../components/group-header/group-name.tsx | 2 +- .../components/group-header/index.tsx | 2 +- .../components/group-header/use-edit-name.ts | 2 +- .../group-type-tag/use-group-type-alias.ts | 2 +- .../group-variables/group-variables-item.tsx | 2 +- .../components/group-variables/index.tsx | 8 +- .../group-variables/use-is-output-variable.ts | 2 +- .../group-variables/use-variables-filter.ts | 6 +- .../components/merge-groups-field/index.tsx | 2 +- .../components/merge-strategy-field/index.tsx | 2 +- .../components/variable-merge-form/index.tsx | 2 +- .../src/nodes-v2/variable-merge/constants.ts | 6 +- .../effects/variables-change-effects.ts | 2 +- .../utils/generate-group-name.ts | 2 +- .../utils/get-group-type-alias.ts | 2 +- .../utils/get-matched-variable-types.ts | 2 +- .../utils/get-variable-type-alias.ts | 2 +- .../utils/get-variable-view-type.ts | 2 +- .../utils/is-output-variable.ts | 2 +- .../utils/is-variable-type-matched.ts | 2 +- .../variable-merge/utils/to-field-error.ts | 2 +- .../validators/group-name-validator.ts | 4 +- .../validators/variable-validator.ts | 8 +- .../variable-merge-form-meta.tsx | 6 +- .../workflow-document-custom-options.ts | 24 +- .../src/services/chatflow-service.ts | 2 +- .../services/database-node-service-impl.ts | 4 +- .../src/services/database-node-service.ts | 50 +- .../src/services/node-version-service.ts | 44 +- .../src/services/plugin-node-service.ts | 28 +- .../src/services/related-case-data-service.ts | 2 +- .../playground/src/services/role-service.ts | 8 +- .../src/services/test-run-reporter-service.ts | 2 +- .../services/value-expression-service-impl.ts | 4 +- .../src/services/value-expression-service.ts | 46 +- .../services/workflow-dependency-service.ts | 26 +- .../src/services/workflow-drag-service.ts | 28 +- .../src/services/workflow-edit-service.ts | 26 +- .../src/services/workflow-line-service.ts | 16 +- .../src/services/workflow-models-service.ts | 14 +- .../services/workflow-operation-service.ts | 16 +- .../src/services/workflow-run-service.ts | 122 ++--- .../src/services/workflow-save-service.ts | 78 +-- .../services/workflow-validation-service.ts | 34 +- .../contributions/copy/get-valid-nodes.ts | 2 +- .../src/shortcuts/contributions/copy/index.ts | 36 +- .../contributions/copy/is-system-nodes.ts | 2 +- .../shortcuts/contributions/delete/index.ts | 14 +- .../shortcuts/contributions/export/index.ts | 10 +- .../layout/comment-node-handler.ts | 2 +- .../shortcuts/contributions/layout/index.ts | 4 +- .../contributions/layout/quad-tree.ts | 42 +- .../src/shortcuts/contributions/load/index.ts | 18 +- .../shortcuts/contributions/paste/index.ts | 52 +- .../contributions/paste/is-valid-data.ts | 8 +- .../contributions/paste/is-valid-node.ts | 8 +- .../paste/validators/api-node-validator.ts | 2 +- .../validators/cross-space-node-validator.ts | 2 +- .../validators/loop-context-validator.ts | 2 +- .../validators/nested-loop-batch-validator.ts | 2 +- .../paste/validators/scene-node-validator.ts | 2 +- .../sub-workflow-self-ref-validator.ts | 2 +- .../contributions/select-all/index.ts | 4 +- .../src/shortcuts/contributions/zoom/index.ts | 4 +- .../workflow/playground/src/shortcuts/type.ts | 2 +- .../src/shortcuts/utils/unique-workflow.ts | 24 +- .../hooks/use-form-default-values.ts | 2 +- .../test-run-kit/hooks/use-open-workflow.ts | 16 +- .../src/test-run-kit/types/index.ts | 8 +- .../utils/generate-form-related-field.ts | 2 +- .../utils/generate-form-schema.ts | 4 +- .../generate-form-schema/testset-field.ts | 2 +- .../utils/generate-input-to-field.ts | 8 +- .../generate-parameters-to-properties.ts | 6 +- .../test-run-kit/utils/get-related-info.ts | 6 +- .../workflow/playground/src/typing/index.ts | 166 +++---- .../workflow/playground/src/typing/sidebar.ts | 4 +- .../src/ui-components/banner/index.tsx | 2 +- .../workflow-sl-textarea/index.tsx | 10 +- .../src/use-workflow-playground.tsx | 48 +- .../playground/src/utils/curl-parser.ts | 16 +- .../src/utils/get-is-init-workflow.ts | 10 +- .../playground/src/utils/get-workflow-url.ts | 6 +- .../src/utils/get-workflow-version.ts | 4 +- .../playground/src/utils/promise-limiter.ts | 2 +- .../src/workflow-playground-context.ts | 12 +- .../playground/src/workflow-playground.tsx | 4 +- .../workflow/playground/tailwind.config.js | 2 +- .../components/lines/bezier-line/index.tsx | 8 +- .../src/components/lines/fold-line/index.tsx | 4 +- .../src/components/selector-bounds/index.tsx | 2 +- .../workflow-port-render/cross-hair.tsx | 2 +- .../components/workflow-port-render/index.tsx | 10 +- .../workflow/render/src/constants/lines.ts | 2 +- .../workflow/render/src/constants/points.ts | 2 +- .../render/src/layer/background-layer.tsx | 28 +- .../workflow/render/src/layer/hover-layer.tsx | 64 +-- .../workflow/render/src/layer/lines-layer.tsx | 16 +- .../render/src/layer/shortcuts-layer.tsx | 8 +- .../render/src/utils/selection-utils.ts | 4 +- .../render/src/utils/shortcuts-utils.ts | 24 +- .../workflow/render/src/workflow-loader.tsx | 6 +- .../src/workflow-render-contribution.ts | 34 +- .../render/src/workflow-render-provider.tsx | 14 +- .../src/workflow-shorcuts-contribution.ts | 2 +- .../workflow/setters/scripts/create-setter.js | 14 +- .../workflow/setters/src/array/array.tsx | 8 +- .../setters/src/number/index.test.tsx | 4 +- .../workflow/setters/src/string/string.tsx | 2 +- .../base-form-materials/field-item.test.tsx | 14 +- .../group-collapse.test.tsx | 16 +- .../__tests__/utils/is-property-empty.test.ts | 6 +- .../stringify-form-values-from-backed.test.ts | 8 +- .../group-collapse/collapse.tsx | 4 +- .../components/base-form-materials/index.ts | 2 +- .../input-number/input-number.tsx | 16 +- .../form-materials/field-item/index.tsx | 2 +- .../src/components/form-materials/index.ts | 2 +- .../test-run-next/form/src/constants/index.ts | 4 +- .../test-run-next/form/src/context/form.tsx | 2 +- .../src/form-engine/fields/reactive-field.tsx | 4 +- .../form-engine/fields/recursion-field.tsx | 2 +- .../form/src/form-engine/index.ts | 2 +- .../src/form-engine/shared/form-schema.ts | 6 +- .../form/src/form-engine/types/schema.ts | 34 +- .../src/utils/generate-field-component.ts | 10 +- .../src/utils/generate-field-validator.ts | 12 +- .../form/src/utils/generate-field.ts | 6 +- .../form/src/utils/is-property-empty.ts | 2 +- .../__tests__/utils/safe-json-parse.test.ts | 6 +- .../src/components/bottom-panel/panel.tsx | 10 +- .../src/components/bottom-panel/use-resize.ts | 20 +- .../shared/src/utils/debug-url.ts | 2 +- .../src/components/trace-graph/use-trace.ts | 2 +- .../components/trace-select/use-options.ts | 8 +- .../test-run-next/trace/src/constants.ts | 2 +- .../trace/src/contexts/trace-list/index.tsx | 6 +- .../common/flamethread/config.ts | 2 +- .../common/flamethread/index.tsx | 26 +- .../common/flamethread/typing.ts | 4 +- .../common/tree/index.tsx | 32 +- .../common/tree/typing.ts | 28 +- .../common/tree/util.ts | 14 +- .../trace/src/observation-components/index.ts | 4 +- .../observation-components/typings/graph.ts | 6 +- .../src/observation-components/typings/idl.ts | 26 +- .../src/components/file-icon/constants.ts | 2 +- .../src/components/file-icon/utils.ts | 2 +- .../components/file-upload/file-upload.tsx | 4 +- .../src/components/file-upload/types.ts | 8 +- .../src/components/file-upload/use-upload.ts | 4 +- .../src/components/file-upload/utils.ts | 16 +- .../form-materials/form-item/index.tsx | 2 +- .../form-materials/full-input/full-input.tsx | 4 +- .../input-number/base-input-number-v2.tsx | 18 +- .../workflow/test-run/src/components/index.ts | 2 +- .../hooks/use-get-current-result.ts | 6 +- .../src/components/log-detail/index.ts | 2 +- .../src/components/log-detail/log-detail.tsx | 8 +- .../components/log-detail/log-images/index.ts | 2 +- .../log-detail/pagination/index.tsx | 2 +- .../log-detail/pagination/more-selector.tsx | 6 +- .../log-detail/pagination/page-selector.tsx | 4 +- .../components/resizable-panel/base-panel.tsx | 10 +- .../src/components/resizable-panel/index.tsx | 14 +- .../resizable-panel.module.less | 2 +- .../components/resizable-panel/use-resize.ts | 20 +- .../edit-panel/chat-flow-edit-form.tsx | 6 +- .../testset/edit-panel/edit-form-section.tsx | 12 +- .../testset/edit-panel/edit-form.tsx | 6 +- .../testset/edit-panel/name-input.tsx | 2 +- .../edit-panel/use-edit-form-schemas.ts | 4 +- .../components/testset/manage-provider.tsx | 18 +- .../src/components/testset/select/select.tsx | 4 +- .../testset/select/use-testset-options.ts | 4 +- .../test-run/src/constants/condition.ts | 14 +- .../workflow/test-run/src/constants/form.ts | 2 +- .../workflow/test-run/src/constants/index.ts | 2 +- .../test-run/src/constants/testset.ts | 6 +- .../input/components/input-form/use-sync.ts | 2 +- .../test-run/src/features/input/utils.ts | 2 +- .../log/components/data-viewer/constants.ts | 4 +- .../data-viewer/context/create-store.ts | 2 +- .../data-viewer/context/provider.tsx | 2 +- .../data-viewer/data-viewer.module.less | 2 +- .../components/data-viewer/data-viewer.tsx | 2 +- .../data-viewer/hooks/use-value.tsx | 2 +- .../data-viewer/json-field/index.tsx | 6 +- .../log/components/data-viewer/types.ts | 20 +- .../data-viewer/utils/big-number.ts | 4 +- .../data-viewer/utils/generate-field.ts | 28 +- .../log-images/images-preview.module.less | 2 +- .../output-log-parser/is-different-output.ts | 42 +- .../sync-output-to-node/use-sync-output.ts | 2 +- .../output-log-parser/use-output-log.ts | 4 +- .../node-status-bar/node-status-bar.tsx | 6 +- .../src/features/log/constants/condition.ts | 14 +- .../src/features/log/constants/index.ts | 14 +- .../test-run/src/features/log/types.ts | 12 +- .../test-run/src/features/log/utils/field.ts | 8 +- .../src/features/log/utils/generate-log.ts | 40 +- .../src/features/log/utils/markdown.ts | 8 +- .../features/log/utils/parse-function-call.ts | 6 +- .../components/problem-item/node-item.tsx | 2 +- .../features/problem/hooks/use-problems.ts | 6 +- .../test-run/src/features/problem/types.ts | 10 +- .../components/message-list/message-list.tsx | 2 +- .../question-form/use-question-form.ts | 2 +- .../features/question/context/create-store.ts | 2 +- .../question/hooks/use-send-message.ts | 2 +- .../src/hooks/use-document-content-change.ts | 6 +- .../packages/workflow/test-run/src/index.ts | 2 +- .../test-run-plugin/test-form-service.ts | 2 +- .../test-run-reporter-service.ts | 16 +- .../test-run-plugin/test-run-service.ts | 4 +- .../workflow/test-run/src/types/log.ts | 10 +- .../workflow/test-run/src/types/testset.ts | 4 +- .../test-run/src/utils/safe-json-parse.ts | 2 +- .../test-run/src/utils/stringify-value.ts | 2 +- .../testset/get-form-item-custom-props.ts | 4 +- .../testset/get-form-item-placeholder.ts | 4 +- .../utils/testset/get-test-data-by-testset.ts | 2 +- .../utils/testset/get-testset-name-rules.ts | 22 +- .../is-testset-form-same-field-type.ts | 2 +- .../src/utils/testset/validate-schema.ts | 12 +- .../workflow/test-run/src/utils/tracker.ts | 6 +- .../src/core/extend-ast/custom-array-type.ts | 4 +- .../extend-ast/custom-key-path-expression.ts | 20 +- .../core/extend-ast/merge-group-expression.ts | 16 +- .../core/extend-ast/wrap-array-expression.ts | 2 +- .../workflow/variable/src/core/index.tsx | 2 +- .../workflow/variable/src/core/types.tsx | 6 +- .../variable/src/core/utils/create-ast.ts | 18 +- .../variable/src/core/utils/expression.ts | 20 +- .../variable/src/core/utils/name-path.ts | 6 +- .../variable/src/core/utils/parse-ast.ts | 2 +- .../core/workflow-variable-facade-service.ts | 32 +- .../src/core/workflow-variable-facade.ts | 24 +- .../src/create-workflow-variable-plugin.tsx | 8 +- .../workflow-node-input-variables-data.ts | 4 +- .../datas/workflow-node-ref-variables-data.ts | 22 +- .../consume-ref-value-expression.ts | 2 +- .../provide-loop-input-variables.tsx | 6 +- .../provide-loop-output-variables.tsx | 8 +- .../provide-merge-group-variables.tsx | 6 +- .../use-available-workflow-variables.tsx | 2 +- .../use-global-variable-service-state.tsx | 2 +- .../src/hooks/use-variable-dispose.tsx | 4 +- .../src/hooks/use-variable-type-change.tsx | 2 +- .../packages/workflow/variable/src/index.ts | 2 +- .../variable/src/legacy/variable-utils.ts | 56 +-- .../src/legacy/workflow-variable-service.ts | 34 +- .../src/services/global-variable-service.ts | 12 +- .../workflow/variable/src/utils/form.ts | 4 +- .../src/utils/generate-input-json-schema.ts | 4 +- .../variable/src/utils/sub-canvas.tsx | 12 +- .../variable/src/utils/variable-provider.ts | 8 +- frontend/scripts/block-unresolved-conflict.sh | 6 +- frontend/scripts/del-branch.sh | 10 +- frontend/scripts/find-empty-files.sh | 12 +- frontend/scripts/post-rush-install.sh | 4 +- frontend/scripts/pre-push-hook.sh | 4 +- frontend/scripts/publish-pro.sh | 8 +- frontend/scripts/retry.sh | 4 +- frontend/scripts/setup-env.sh | 4 +- frontend/scripts/subdir-cloc.sh | 10 +- 2960 files changed, 15545 insertions(+), 15545 deletions(-) diff --git a/frontend/apps/coze-studio/rsbuild.config.ts b/frontend/apps/coze-studio/rsbuild.config.ts index a92e459b..91916f56 100644 --- a/frontend/apps/coze-studio/rsbuild.config.ts +++ b/frontend/apps/coze-studio/rsbuild.config.ts @@ -83,7 +83,7 @@ const mergedConfig = defineConfig({ source: { define: { 'process.env.IS_REACT18': JSON.stringify(true), - // arcosite editor sdk 内部使用 + // Arcosite editor sdk internal use 'process.env.ARCOSITE_SDK_REGION': JSON.stringify( GLOBAL_ENVS.IS_OVERSEA ? 'VA' : 'CN', ), @@ -99,7 +99,7 @@ const mergedConfig = defineConfig({ include: [ path.resolve(__dirname, '../../packages'), path.resolve(__dirname, '../../infra/flags-devtool'), - // 以下几个包包含未降级的 ES 2022 语法(private methods)需要参与打包 + // The following packages contain undegraded ES 2022 syntax (private methods) that need to be packaged /\/node_modules\/(marked|@dagrejs|@tanstack)\//, ], alias: { diff --git a/frontend/apps/coze-studio/src/index.tsx b/frontend/apps/coze-studio/src/index.tsx index 7debde66..8ede3aa5 100644 --- a/frontend/apps/coze-studio/src/index.tsx +++ b/frontend/apps/coze-studio/src/index.tsx @@ -31,15 +31,15 @@ const initFlags = () => { }; const main = () => { - // 初始化功能开关的值 + // Initialize the value of the function switch initFlags(); - // 初始化i18n + // Initialize i18n initI18nInstance({ lng: (localStorage.getItem('i18next') ?? (IS_OVERSEA ? 'en' : 'zh-CN')) as | 'en' | 'zh-CN', }); - // 动态导入mdbox 样式 + // Import mdbox styles dynamically dynamicImportMdBoxStyle(); const $root = document.getElementById('root'); diff --git a/frontend/apps/coze-studio/src/routes/async-components.tsx b/frontend/apps/coze-studio/src/routes/async-components.tsx index daec62ac..f812a0c8 100644 --- a/frontend/apps/coze-studio/src/routes/async-components.tsx +++ b/frontend/apps/coze-studio/src/routes/async-components.tsx @@ -16,128 +16,128 @@ import { lazy } from 'react'; -// 登录页面 +// login page export const LoginPage = lazy(() => import('@coze-foundation/account-ui-adapter').then(res => ({ default: res.LoginPage, })), ); -// 文档页面 +// documentation page export const Redirect = lazy(() => import('../pages/redirect')); -// 工作空间侧边栏组件 +// Workspace Sidebar Component export const spaceSubMenu = lazy(() => import('@coze-foundation/space-ui-adapter').then(exps => ({ default: exps.WorkspaceSubMenu, })), ); -// 工作空间布局组件 +// Workspace Layout Component export const SpaceLayout = lazy(() => import('@coze-foundation/space-ui-adapter').then(exps => ({ default: exps.SpaceLayout, })), ); -// 某个具体的工作空间布局组件 +// A specific workspace layout component export const SpaceIdLayout = lazy(() => import('@coze-foundation/space-ui-base').then(exps => ({ default: exps.SpaceIdLayout, })), ); -// 项目开发页面 +// project development page export const Develop = lazy(() => import('../pages/develop')); -// 资源库页面 +// resource library page export const Library = lazy(() => import('../pages/library')); -// Agent IDE布局组件 +// Agent IDE Layout Component export const AgentIDELayout = lazy( () => import('@coze-agent-ide/layout-adapter'), ); -// Agent IDE页面 +// Agent IDE page export const AgentIDE = lazy(() => import('@coze-agent-ide/entry-adapter').then(res => ({ default: res.BotEditor, })), ); -// Agent IDE发布页面 +// Agent IDE Release Page export const AgentPublishPage = lazy(() => import('@coze-agent-ide/agent-publish').then(exps => ({ default: exps.AgentPublishPage, })), ); -// Project IDE页面 +// Project IDE Page export const ProjectIDE = lazy(() => import('@coze-project-ide/main').then(exps => ({ default: exps.IDELayout, })), ); -// Project IDE发布页面 +// Project IDE Release Page export const ProjectIDEPublish = lazy(() => import('@coze-studio/project-publish').then(exps => ({ default: exps.ProjectPublish, })), ); -// 知识库预览页面 +// Knowledge Base Preview Page export const KnowledgePreview = lazy(() => import('@coze-studio/workspace-base/knowledge-preview').then(exps => ({ default: exps.KnowledgePreviewPage, })), ); -// 知识库上传页面 +// Knowledge base upload page export const KnowledgeUpload = lazy(() => import('@coze-studio/workspace-base/knowledge-upload').then(exps => ({ default: exps.KnowledgeUploadPage, })), ); -// 数据库资源页面 +// database resource page export const DatabaseDetail = lazy(() => import('@coze-studio/workspace-base').then(exps => ({ default: exps.DatabaseDetailPage, })), ); -// 工作流页面 +// workflow page export const WorkflowPage = lazy(() => import('@coze-workflow/playground-adapter').then(res => ({ default: res.WorkflowPage, })), ); -// 插件资源页面布局组件 +// plugin resource page layout component export const PluginLayout = lazy(() => import('../pages/plugin/layout')); -// 插件资源页面 +// plugin resource page export const PluginPage = lazy(() => import('../pages/plugin/page')); -// 插件工具页面 +// plugin tool page export const PluginToolPage = lazy(() => import('../pages/plugin/tool/page')); -// 探索体验页面二级导航组件 +// Explore the experience page secondary navigation component export const exploreSubMenu = lazy(() => import('@coze-community/explore').then(exps => ({ default: exps.ExploreSubMenu, })), ); -// 模版页面 +// template page export const ExploreTemplatePage = lazy(() => import('@coze-community/explore').then(exps => ({ default: exps.TemplatePage, })), ); -// 插件商店页面 +// plugin store page export const ExplorePluginPage = lazy(() => import('@coze-community/explore').then(exps => ({ default: exps.PluginPage, diff --git a/frontend/apps/coze-studio/src/routes/index.tsx b/frontend/apps/coze-studio/src/routes/index.tsx index 6a918a30..db73e97a 100644 --- a/frontend/apps/coze-studio/src/routes/index.tsx +++ b/frontend/apps/coze-studio/src/routes/index.tsx @@ -48,7 +48,7 @@ import { export const router: ReturnType = createBrowserRouter([ - // 文档路由 + // Document routing { path: '/open/docs/*', Component: Redirect, @@ -73,7 +73,7 @@ export const router: ReturnType = requireAuth: false, }), }, - // 主应用路由 + // main application route { path: '/', Component: Layout, @@ -83,7 +83,7 @@ export const router: ReturnType = index: true, element: , }, - // 登录页路由 + // login page routing { path: 'sign', Component: LoginPage, @@ -94,7 +94,7 @@ export const router: ReturnType = }), }, - // 工作空间路由 + // Workspace Routing { path: 'space', Component: SpaceLayout, @@ -114,7 +114,7 @@ export const router: ReturnType = element: , }, - // 项目开发 + // Project Development { path: 'develop', Component: Develop, @@ -171,7 +171,7 @@ export const router: ReturnType = }), }, - // 资源库 + // resource library { path: 'library', Component: Library, @@ -180,7 +180,7 @@ export const router: ReturnType = }), }, - // 知识库资源 + // Knowledge Base Resources { path: 'knowledge', children: [ @@ -198,7 +198,7 @@ export const router: ReturnType = }), }, - // 数据库资源 + // database resources { path: 'database', children: [ @@ -213,7 +213,7 @@ export const router: ReturnType = }), }, - // 插件资源 + // plugin resources { path: 'plugin/:plugin_id', Component: PluginLayout, @@ -238,7 +238,7 @@ export const router: ReturnType = ], }, - // 工作流路由 + // workflow routing { path: 'work_flow', Component: WorkflowPage, @@ -248,7 +248,7 @@ export const router: ReturnType = }), }, - // 探索 + // explore { path: 'explore', Component: null, @@ -263,7 +263,7 @@ export const router: ReturnType = index: true, element: , }, - // 插件商店 + // plugin store { path: 'plugin', element: , @@ -271,7 +271,7 @@ export const router: ReturnType = type: 'plugin', }), }, - // 模版 + // template { path: 'template', element: , diff --git a/frontend/apps/coze-studio/tailwind.config.ts b/frontend/apps/coze-studio/tailwind.config.ts index 15488f1c..f04210ca 100644 --- a/frontend/apps/coze-studio/tailwind.config.ts +++ b/frontend/apps/coze-studio/tailwind.config.ts @@ -27,7 +27,7 @@ console.log(`Got ${contents.length} contents for tailwind`); export default { content: contents, - // safelist的内容可以允许动态生成tailwind className + // Safelist content can allow dynamic tailwind className safelist: [ { pattern: /(gap-|grid-).+/, @@ -47,7 +47,7 @@ export default { }, }, corePlugins: { - preflight: false, // 关闭@tailwind base默认样式,避免对现有样式影响 + preflight: false, // Turn off @tailwind base default styles to avoid affecting existing styles }, // eslint-disable-next-line @typescript-eslint/no-require-imports plugins: [require('@coze-arch/tailwind-config/coze')], diff --git a/frontend/config/eslint-config/eslint.config.web.js b/frontend/config/eslint-config/eslint.config.web.js index f84b14e3..f98c06af 100644 --- a/frontend/config/eslint-config/eslint.config.web.js +++ b/frontend/config/eslint-config/eslint.config.web.js @@ -5,7 +5,7 @@ module.exports = [ ...require('./eslint.config.base.js'), { plugins: { - // TODO: 需要根据不同类型配置plugin?需要阅读源码确认是否影响性能 + // TODO: Need to configure plugins according to different types? You need to read the source code to confirm whether it affects performance 'react-hooks': require('eslint-plugin-react-hooks'), react: require('eslint-plugin-react'), risxss: require('eslint-plugin-risxss'), diff --git a/frontend/config/eslint-config/rules/common-standard.js b/frontend/config/eslint-config/rules/common-standard.js index 1050f460..4183bfd0 100644 --- a/frontend/config/eslint-config/rules/common-standard.js +++ b/frontend/config/eslint-config/rules/common-standard.js @@ -28,7 +28,7 @@ const readBlockList = () => /** @type {(import('eslint').Linter.Config)[]} */ module.exports = [ - // NOTE: 不能和下一项配置合并 + // NOTE: Cannot be merged with the next configuration { ignores: [ '**/*.d.ts', @@ -68,7 +68,7 @@ module.exports = [ ...require('@coze-arch/eslint-plugin').configs.recommended, require('@coze-arch/eslint-plugin/zustand').configs.recommended, { - files: ['**/*.?(m|c)?(j|t)s?(x)'], // 排除规则对package.json生效 + files: ['**/*.?(m|c)?(j|t)s?(x)'], // Exclusion rules take effect for package.json plugins: { prettier: require('eslint-plugin-prettier'), '@babel': require('@babel/eslint-plugin'), diff --git a/frontend/config/eslint-config/rules/import.js b/frontend/config/eslint-config/rules/import.js index 9da7d5d2..6c1b42fa 100644 --- a/frontend/config/eslint-config/rules/import.js +++ b/frontend/config/eslint-config/rules/import.js @@ -5,7 +5,7 @@ module.exports = [ { files: ['**/*.?(m|c)?(j|t)s?(x)'], settings: { - // TODO: 全局保留一份配置 + // TODO: Keep a configuration globally 'import/resolver': { node: { moduleDirectory: ['node_modules', 'src'], @@ -72,8 +72,8 @@ module.exports = [ }, }, rules: { - // TODO: 目前由于 edenx 会动态生成一些插件模块,因此启动会报错 - // 后续需要修复问题,启动下述规则 + // TODO: At present, because edenx will dynamically generate some plug-in modules, an error will be reported when starting. + // You need to fix the problem later, and start the following rules. // "import/no-unresolved": "error" }, }, diff --git a/frontend/config/eslint-config/rules/ts-standard.js b/frontend/config/eslint-config/rules/ts-standard.js index e8b9d073..7571bdd8 100644 --- a/frontend/config/eslint-config/rules/ts-standard.js +++ b/frontend/config/eslint-config/rules/ts-standard.js @@ -59,9 +59,9 @@ module.exports = [ { vars: 'all', args: 'none', // function arguments should not force to match this rule. - argsIgnorePattern: '^_', // 规范允许下划线 - ignoreRestSiblings: true, //使用rest语法(如 `var { foo, ...rest } = data`) 忽略foo。 - destructuredArrayIgnorePattern: '^_', //结构数组允许使用_ + argsIgnorePattern: '^_', // Specifications allow underlining + ignoreRestSiblings: true, //Use rest syntax (such as'var {foo,... rest} = data ') to ignore foo. + destructuredArrayIgnorePattern: '^_', //Structural arrays allow _ caughtErrors: 'none', // "caughtErrorsIgnorePattern": "^e$" }, @@ -314,7 +314,7 @@ module.exports = [ }, }, - // TODO: 之前overides的内容,后需可考虑直接合入上面标准配置 + // TODO: The content of overides before can be considered to be directly integrated into the above standard configuration later { files: ['**/*.?(m|c)ts?(x)'], rules: { @@ -324,8 +324,8 @@ module.exports = [ fixStyle: 'inline-type-imports', }, ], - // 这些规则都是从 packages/config/.eslintrc.react.js 复制迁移过来 - // 后续在做调整 + // These rules are copied and migrated from packages/config/.eslintrc.react.js + // Adjustments are being made later. '@typescript-eslint/no-redundant-type-constituents': 0, '@typescript-eslint/no-throw-literal': 'off', '@typescript-eslint/no-unnecessary-condition': 0, @@ -335,14 +335,14 @@ module.exports = [ '@typescript-eslint/explicit-function-return-type': 'off', 'no-shadow': 'off', '@typescript-eslint/no-shadow': 'error', - // TODO: 后续开启 + // TODO: Follow-up opening // 'import/no-cycle': 'error', '@typescript-eslint/prefer-string-starts-ends-with': 0, '@typescript-eslint/no-unnecessary-boolean-literal-compare': 0, '@typescript-eslint/no-implied-eval': 0, // warning - // TODO: 打开下面这些配置 + // TODO: Open the following configurations // fix: https://stackoverflow.com/questions/63961803/eslint-says-all-enums-in-typescript-app-are-already-declared-in-the-upper-scope // 'no-shadow': 'off', // '@typescript-eslint/no-shadow': ['error'], @@ -364,7 +364,7 @@ module.exports = [ // }, // ], // complexity: ['error', { max: 15 }], - // 后面统一使用CustomError后 再开启 + // After using CustomError uniformly later, open it again. '@coze-arch/no-new-error': 'off', }, }, diff --git a/frontend/config/eslint-config/scripts/reslint.sh b/frontend/config/eslint-config/scripts/reslint.sh index 13944a4e..4f2c6082 100755 --- a/frontend/config/eslint-config/scripts/reslint.sh +++ b/frontend/config/eslint-config/scripts/reslint.sh @@ -1,7 +1,7 @@ #!/usr/bin/env bash BASE_DIR=$(dirname "$(echo "$0" | sed -e 's,\\,/,g')") -# 某些系统可能没有 realpath 命令, +# Some systems may not have the realpath command. if ! command -v realpath &>/dev/null; then echo "未找到 realpath 命令" echo "请执行以下命令安装必要依赖" diff --git a/frontend/config/eslint-config/scripts/rprettier.sh b/frontend/config/eslint-config/scripts/rprettier.sh index 213727ca..e56c5c40 100755 --- a/frontend/config/eslint-config/scripts/rprettier.sh +++ b/frontend/config/eslint-config/scripts/rprettier.sh @@ -1,7 +1,7 @@ #!/usr/bin/env bash BASE_DIR=$(dirname "$(echo "$0" | sed -e 's,\\,/,g')") -# 某些系统可能没有 realpath 命令, +# Some systems may not have the realpath command. if ! command -v realpath &>/dev/null; then echo "未找到 realpath 命令" echo "请执行以下命令安装必要依赖" diff --git a/frontend/config/eslint-config/src/index.js b/frontend/config/eslint-config/src/index.js index 2f1d137e..d47833ac 100644 --- a/frontend/config/eslint-config/src/index.js +++ b/frontend/config/eslint-config/src/index.js @@ -2,9 +2,9 @@ require('sucrase/register/ts'); const { defineConfig } = require('./define-config'); -// node@16 没有 structuredClone 方法导致报错: +// node@16 no structuredClone method causes an error: // ReferenceError: Error while loading rule '@typescript-eslint/naming-convention': structuredClone is not defined -// 此处做个简单 polyfill +// Make a simple polyfill here if (typeof structuredClone === 'undefined') { global.structuredClone = obj => JSON.parse(JSON.stringify(obj)); } diff --git a/frontend/config/rsbuild-config/src/index.ts b/frontend/config/rsbuild-config/src/index.ts index 462cd3b9..776fb841 100644 --- a/frontend/config/rsbuild-config/src/index.ts +++ b/frontend/config/rsbuild-config/src/index.ts @@ -28,7 +28,7 @@ import { SemiRspackPlugin } from '@douyinfe/semi-rspack-plugin'; const getDefine = () => { const define = {}; Object.keys(GLOBAL_ENVS).forEach(key => { - // 在rspack的define中,字符串需要前后拼接上双引号,才能在代码中作为字符串使用。 + // In the definition of rspack, strings need to be enclosed in double quotes before they can be used as strings in code. if (typeof GLOBAL_ENVS[key] === 'string') { define[key] = `"${GLOBAL_ENVS[key]}"`; } else { @@ -115,7 +115,7 @@ export const defineConfig = (options: Partial) => { ), }, include: [ - // 以下几个包包含未降级的 ES 2022 语法(private methods)需要参与打包 + // The following packages contain undegraded ES 2022 syntax (private methods) that need to be packaged /\/node_modules\/(marked|@dagrejs|@tanstack)\//, ], }, diff --git a/frontend/config/stylelint-config/.stylelintrc.js b/frontend/config/stylelint-config/.stylelintrc.js index 448fa2ef..6a5cb666 100644 --- a/frontend/config/stylelint-config/.stylelintrc.js +++ b/frontend/config/stylelint-config/.stylelintrc.js @@ -6,9 +6,9 @@ module.exports = { ], plugins: ['./plugins/plugin-disallow-nesting-level-one-global.js'], rules: { - // 变量命名规则,适应仓库内的代码风格 + // Variable naming rules to adapt to the code style in the warehouse 'custom-property-pattern': '^([A-Za-z0-9]*)([-_]+[A-Za-z0-9]+)*$', - // 对于less函数判断有问题 + // There is a problem with judging the less function 'less/no-duplicate-variables': null, 'media-feature-range-notation': null, 'max-nesting-depth': [ diff --git a/frontend/config/tailwind-config/src/coze.js b/frontend/config/tailwind-config/src/coze.js index 90111b3c..26dae8f4 100644 --- a/frontend/config/tailwind-config/src/coze.js +++ b/frontend/config/tailwind-config/src/coze.js @@ -5,7 +5,7 @@ const plugin = require('tailwindcss/plugin'); const lightModeVariables = require('./light'); const darkModeVariables = require('./dark'); -// 用于生成 CSS 变量的帮助函数 +// Helper functions for generating CSS variables function generateCssVariables(variables, theme) { return Object.entries(variables).reduce((acc, [key, value]) => { acc[`--${key}`] = theme ? theme(value) : value; @@ -13,7 +13,7 @@ function generateCssVariables(variables, theme) { }, {}); } -// 样式语义化 +// style semantics function generateSemanticVariables(semantics, theme, property) { return Object.entries(semantics).map(([key, value]) => ({ [`.${key}`]: { diff --git a/frontend/config/tailwind-config/src/dark.js b/frontend/config/tailwind-config/src/dark.js index 3792812c..7f4f62bb 100644 --- a/frontend/config/tailwind-config/src/dark.js +++ b/frontend/config/tailwind-config/src/dark.js @@ -1,4 +1,4 @@ -// 暗色模式的 CSS 变量 +// CSS Variables for Dark Mode const darkModeVariables = { background: '2, 8, 23', foreground: '249, 249, 249', diff --git a/frontend/config/tailwind-config/src/design-token.ts b/frontend/config/tailwind-config/src/design-token.ts index 6aecebe6..e36b6fdf 100644 --- a/frontend/config/tailwind-config/src/design-token.ts +++ b/frontend/config/tailwind-config/src/design-token.ts @@ -14,7 +14,7 @@ * limitations under the License. */ -// 消费者和生产者公共的 tailwind 配置和工具函数 +// Common tailwind configurations and tool functions for consumers and producers export function designTokenToTailwindConfig( tokenJson: Record, @@ -103,6 +103,6 @@ function borderRadiusTransformer(borderRadiusObj: Record) { return res; } -// 获取其他packages,并且拼接上 /src/**/*.{ts,tsx} +// Get other packages and splice /src /**/*.{ ts, tsx} export { getTailwindContents } from './tailwind-contents'; diff --git a/frontend/config/tailwind-config/src/light.js b/frontend/config/tailwind-config/src/light.js index 8d214eb5..0d6251bf 100644 --- a/frontend/config/tailwind-config/src/light.js +++ b/frontend/config/tailwind-config/src/light.js @@ -1,4 +1,4 @@ -// 浅色模式的 CSS 变量 +// CSS Variables for Light Mode const lightModeVariables = { background: '255, 255, 255', foreground: '28, 28, 35', @@ -27,7 +27,7 @@ const lightModeVariables = { 'coze-fg-3': '15, 21, 40', 'coze-fg-2': '32, 41, 69', 'coze-fg-1': '55, 67, 106', - // TODO: 需要删除bg9 + // TODO: need to remove bg9 'coze-bg-9': '6, 7, 9', 'coze-bg-8': '68, 83, 130', 'coze-bg-7': '75, 90, 140', @@ -151,7 +151,7 @@ const lightModeVariables = { 'coze-3': '3px', 'coze-2': '2px', 'coze-1': '1px', - // TODO: rspress编译不出来,需要通过一些工具处理,目前没有用到,暂时注释处理 + // TODO: rspress cannot be compiled, and it needs to be processed by some tools. It is not used at present. Temporary comment processing // 'coze-0.5': '0.5px', 'coze-0-5': '0.5px', @@ -174,7 +174,7 @@ const lightModeVariables = { 'coze-bg-6-alpha': '0.13', 'coze-bg-7-alpha': '0.19', 'coze-bg-8-alpha': '0.25', - // TODO: 需要删除bg9 + // TODO: need to remove bg9 'coze-bg-9-alpha': '0.16', 'coze-stroke-5-alpha': '0.13', 'coze-stroke-6-alpha': '0.25', diff --git a/frontend/config/tailwind-config/src/tailwind-contents.ts b/frontend/config/tailwind-config/src/tailwind-contents.ts index 588ee4ce..9281c296 100644 --- a/frontend/config/tailwind-config/src/tailwind-contents.ts +++ b/frontend/config/tailwind-config/src/tailwind-contents.ts @@ -46,7 +46,7 @@ export const getTailwindContents = (projectRoot: string) => { .map(location => path.resolve(location, 'src/**/*.{ts,tsx}')), ); - // 兼容 coze-design 内部 tailwind 样式 + // Compatible with coze-design internal tailwind style contents.push('./node_modules/@coze-arch/coze-design/**/*.{js,jsx}'); return contents; diff --git a/frontend/config/ts-config/scripts/rtsc.sh b/frontend/config/ts-config/scripts/rtsc.sh index 3eaaffd7..53020592 100755 --- a/frontend/config/ts-config/scripts/rtsc.sh +++ b/frontend/config/ts-config/scripts/rtsc.sh @@ -1,7 +1,7 @@ #!/usr/bin/env bash BASE_DIR=$(dirname "$(echo "$0" | sed -e 's,\\,/,g')") -# 某些系统可能没有 realpath 命令, +# Some systems may not have the realpath command. if ! command -v realpath &>/dev/null; then echo "未找到 realpath 命令" echo "请执行以下命令安装必要依赖" diff --git a/frontend/config/ts-config/tsconfig.base.json b/frontend/config/ts-config/tsconfig.base.json index 32bd7034..e44af0ea 100644 --- a/frontend/config/ts-config/tsconfig.base.json +++ b/frontend/config/ts-config/tsconfig.base.json @@ -16,7 +16,7 @@ "moduleResolution": "node", "module": "CommonJS", "noFallthroughCasesInSwitch": true, - // 这个普遍反馈会让代码变得啰嗦,暂定遵循原本 bot 的设置,关闭 + // This general feedback will make the code verbose, tentatively follow the original bot's settings, close "noImplicitReturns": false, "removeComments": false, "resolveJsonModule": true, diff --git a/frontend/config/vitest-config/src/define-config.ts b/frontend/config/vitest-config/src/define-config.ts index d7631e05..0c45abad 100644 --- a/frontend/config/vitest-config/src/define-config.ts +++ b/frontend/config/vitest-config/src/define-config.ts @@ -46,7 +46,7 @@ const calBasePreset = (preset: string) => { export interface OtherConfig { /** - * 用于修复semi的package.json导出的配置问题 + * Used to fix the configuration issue of semi's package.json export */ fixSemi: boolean; } diff --git a/frontend/config/vitest-config/src/preset-default.ts b/frontend/config/vitest-config/src/preset-default.ts index 49fd2fbe..d7a2ee63 100644 --- a/frontend/config/vitest-config/src/preset-default.ts +++ b/frontend/config/vitest-config/src/preset-default.ts @@ -20,7 +20,7 @@ import tsconfigPaths from 'vite-tsconfig-paths'; export const defaultVitestConfig: UserConfig = { plugins: [tsconfigPaths()], resolve: { - // 优先识别 main,如果没有配置 main,则识别 module + // Priority to identify main, if main is not configured, identify the module mainFields: ['main', 'module', 'exports'], }, server: { @@ -38,14 +38,14 @@ export const defaultVitestConfig: UserConfig = { }, }, sequence: { - // vitest 2.0之后,所有钩子默认串行运行 + // After vitest 2.0, all hooks run serially by default hooks: 'parallel', }, globals: true, mockReset: false, silent: process.env.CI === 'true', coverage: { - // 逐步对各包开启 + // Gradually open each package all: false, include: ['src/**/*.ts', 'src/**/*.tsx'], exclude: coverageConfigDefaults.exclude, diff --git a/frontend/disallowed_3rd_libraries.json b/frontend/disallowed_3rd_libraries.json index c2676b61..f8919a1a 100644 --- a/frontend/disallowed_3rd_libraries.json +++ b/frontend/disallowed_3rd_libraries.json @@ -1,16 +1,16 @@ [ - // 可使用 @vitest/coverage-v8 替代 + // Can be replaced by @vitest/coverage-v8 ["@vitest/coverage-c8", null, "请使用 @vitest/coverage-v8"], "husky", "lint-staged", "jest", ["jsdom", null, "请使用 happy-dom 代替"], - // TODO: 等待完全修复后开启@tanjizhen + // TODO: Open @tanjizhen after waiting for full repair // "@oceanos/logger", ["inquirer", null, "请使用 @inquirer/prompts 代替"], ["pdfjs-dist", null, "请使用 @coze-arch/pdfjs-shadow 代替"], // todo: should turn on this - // ["valtio", null, "请使用 zustand"], - // ["jotai", null, "请使用 zustand"] + // ["Valtio", null, "Please use zustand"], + // ["Jotai", null, "Please use zustand"] ["@flow-web/md-box", null, "请使用 @coze-arch/bot-md-box-adapter 代替"] ] diff --git a/frontend/infra/eslint-plugin/src/index.ts b/frontend/infra/eslint-plugin/src/index.ts index 62e06bad..28f8d51e 100644 --- a/frontend/infra/eslint-plugin/src/index.ts +++ b/frontend/infra/eslint-plugin/src/index.ts @@ -48,7 +48,7 @@ export const flowPreset = { '@coze-arch/tsx-no-leaked-render': 'warn', '@coze-arch/no-pkg-dir-import': 'error', '@coze-arch/no-duplicated-deps': 'error', - // 不允许超过 4 层的相对应用 + // Relative applications with more than 4 layers are not allowed '@coze-arch/no-deep-relative-import': [ 'error', { @@ -56,7 +56,7 @@ export const flowPreset = { }, ], '@coze-arch/package-require-author': 'error', - // 函数代码行不要超过 150 + // Function code lines should not exceed 150. '@coze-arch/max-line-per-function': [ 'error', { @@ -73,11 +73,11 @@ export const flowPreset = { files: ['package.json'], processor: '@coze-arch/json-processor', rules: { - // TODO: 需要重构为直接解析json,否则全局规则都会对processor处理后的文件`package.js`生效. + // TODO: It needs to be refactored to parse json directly, otherwise the global rules will take effect on the file'package.js' processed by the processor. //https://github.com/eslint/json '@coze-arch/package-require-author': 'error', '@coze-arch/package-disallow-deps': 'error', - // 关闭prettier规则,因为该规则lint package.js存在bug + // Close the prettier rule because there is a bug in the rule lint package.js 'prettier/prettier': 'off', }, }, diff --git a/frontend/infra/eslint-plugin/src/rules/max-lines-per-function/index.ts b/frontend/infra/eslint-plugin/src/rules/max-lines-per-function/index.ts index b8861b9b..07647d38 100644 --- a/frontend/infra/eslint-plugin/src/rules/max-lines-per-function/index.ts +++ b/frontend/infra/eslint-plugin/src/rules/max-lines-per-function/index.ts @@ -36,7 +36,7 @@ const getStaticStringValue = node => { * * @param node * @returns - * 为什么需要这个判断,对于下面这种函数 + * Why is this judgment necessary for a function such as * ``` * var obj1 = { * set @@ -46,9 +46,9 @@ const getStaticStringValue = node => { * } * } *``` - * 如果不采用下面这个判断,函数判断将得到3,实际应该为5. 类似的还有 + * If you don't use the following judgment, the function judgment will get 3, which should actually be 5. Similarly, there are * ``` - * //如果不采用下面这个判断,函数判断将得到3,实际应该为8 + * //If the following judgment is not used, the function judgment will get 3, which should actually be 8ing judgment, the function judgment will get 3, which should actually be 8. * class A { static [ @@ -85,14 +85,14 @@ const isEmbedded = node => { * * @param node * @returns function name - * Q:为什么不直接用 node.id.value获取函数名称 ? - * A:这种方式对于 传统的函数写法没问题,但是对于 + * Q: Why not get the function name directly with node.id? + * A: This method is fine for traditional function writing, but for * const tips = { * fun: () => {} * }; - * 或者 + * or * const fun2 = () => {} - * 方式书写函数得到的名称为null,所以采取下面这种方式获取, + * The name of the function written in the following way is null, so it is obtained in the following way. * */ @@ -192,7 +192,7 @@ const getStaticPropertyName = node => { case 'VariableDeclarator': prop = node.id; break; - //TODO: CallExpression 场景较为复杂,目前应该没有完全覆盖 + //TODO: The CallExpression scenario is more complex and should not be fully covered at present case 'CallExpression': prop = node.callee; break; @@ -240,7 +240,7 @@ export const maxLinePerFunctionRule: Rule.RuleModule = { function checkFunctionLength(funcNode) { const node = isEmbedded(funcNode) ? funcNode.parent : funcNode; - // 针对函数声明,函数表达式,箭头函数,函数定义四种类型 + // Four types of function declarations, function expressions, arrow functions, and function definitions if ( node.type === 'FunctionDeclaration' || node.type === 'FunctionExpression' || diff --git a/frontend/infra/eslint-plugin/src/rules/no-duplicated-deps/index.ts b/frontend/infra/eslint-plugin/src/rules/no-duplicated-deps/index.ts index 72bd8142..6e846150 100644 --- a/frontend/infra/eslint-plugin/src/rules/no-duplicated-deps/index.ts +++ b/frontend/infra/eslint-plugin/src/rules/no-duplicated-deps/index.ts @@ -40,7 +40,7 @@ export const noDuplicatedDepsRule: Rule.RuleModule = { if (!properties) { return; } - // 对比 dependencies 与 devDependencies 之间是否存在重复依赖 + // Compare dependencies with devDependencies for duplicate dependencies const dependencies = properties.find( p => p.key.value === 'dependencies', ); diff --git a/frontend/infra/eslint-plugin/src/rules/no-pkg-dir-import/index.ts b/frontend/infra/eslint-plugin/src/rules/no-pkg-dir-import/index.ts index c2f90b9f..cda8c9e8 100644 --- a/frontend/infra/eslint-plugin/src/rules/no-pkg-dir-import/index.ts +++ b/frontend/infra/eslint-plugin/src/rules/no-pkg-dir-import/index.ts @@ -40,7 +40,7 @@ export const noPkgDirImport: Rule.RuleModule = { const modulePath = resolve(importPath, context); if (!modulePath) { - // 解析不到的情况,暂不处理 + // If it cannot be resolved, it will not be dealt with for the time being. return; } @@ -56,15 +56,15 @@ export const noPkgDirImport: Rule.RuleModule = { return; } - // 本地link会解析到node_modules目录,需要拿到pkg name再次解析。 + // The local link will resolve to the node_modules directory, and you need to get the pkg name to resolve it again. const moduleRealPath = resolve(pkg.name, context); if ( - // 包名称就是引用路径 + // The package name is the reference path pkg.name === importPath || - // 解析到其他包,如@type + // Parse to other packages, such as @type !importPath.startsWith(pkg.name) || - // 解析到自己包的文件 + // Parse to the file of your own package currentPkgPath === importPkgPath || !moduleRealPath || moduleRealPath.includes('node_modules') diff --git a/frontend/infra/eslint-plugin/src/rules/no-pkg-dir-import/test/index.test.ts b/frontend/infra/eslint-plugin/src/rules/no-pkg-dir-import/test/index.test.ts index 4c3ee690..46f64890 100644 --- a/frontend/infra/eslint-plugin/src/rules/no-pkg-dir-import/test/index.test.ts +++ b/frontend/infra/eslint-plugin/src/rules/no-pkg-dir-import/test/index.test.ts @@ -32,7 +32,7 @@ vi.mock('eslint-module-utils/readPkgUp', () => ({ const validCases = [ { code: 'import "xxx"', - modulePath: undefined, // modulePath 为 空 + modulePath: undefined, // modulePath is empty moduleRealPath: undefined, importPkgPath: 'path/to/import/pkg', currentPkgPath: 'path/to/current/pkg', @@ -48,7 +48,7 @@ const validCases = [ importPkgPath: 'path/to/import/pkg', currentPkgPath: 'path/to/current/pkg', pkg: { - name: 'some/pkg', // 包名称与引用路径相同 + name: 'some/pkg', // The package name is the same as the reference path exports: {}, }, }, @@ -59,7 +59,7 @@ const validCases = [ importPkgPath: 'path/to/import/pkg', currentPkgPath: 'path/to/current/pkg', pkg: { - name: undefined, // 解析到不规范配置的package.json + name: undefined, // Parse to the non-canonical package.json }, }, { @@ -69,7 +69,7 @@ const validCases = [ importPkgPath: 'path/to/import/pkg', currentPkgPath: 'path/to/current/pkg', pkg: { - name: '@types/pkg', // 解析到类型包 + name: '@types/pkg', // Parse to type package exports: {}, }, }, @@ -77,7 +77,7 @@ const validCases = [ code: "import pkg from 'pkg';", modulePath: 'path/to/module', moduleRealPath: 'path/to/module', - importPkgPath: 'path/to/same/pkg', // 相同路径 + importPkgPath: 'path/to/same/pkg', // same path currentPkgPath: 'path/to/same/pkg', pkg: { name: '@types/pkg', @@ -98,7 +98,7 @@ const validCases = [ { code: "import pkg from 'pkg';", modulePath: 'path/to/module', - moduleRealPath: 'path/to/node_modules/pkg', // 解析到node_modules + moduleRealPath: 'path/to/node_modules/pkg', // Parse to node_modules importPkgPath: 'path/to/import/pkg', currentPkgPath: 'path/to/current/pkg', pkg: { @@ -134,7 +134,7 @@ const validCases = [ if (!c.modulePath) { return { code: c.code, - // TODO: 避免eslint duplication检测。可能需要改为其他方式 + // TODO: Avoid eslint duplication. It may need to be changed to another way settings: c, }; } @@ -167,7 +167,7 @@ const invalidCases = [ currentPkgPath: 'path/to/current/pkg', pkg: { name: 'pkg', - exports: undefined, // 为空 + exports: undefined, // empty }, messageId: 'noExportsCfg', }, diff --git a/frontend/infra/eslint-plugin/src/rules/package-disallow-deps/index.ts b/frontend/infra/eslint-plugin/src/rules/package-disallow-deps/index.ts index 378293c9..56981f59 100644 --- a/frontend/infra/eslint-plugin/src/rules/package-disallow-deps/index.ts +++ b/frontend/infra/eslint-plugin/src/rules/package-disallow-deps/index.ts @@ -56,7 +56,7 @@ export const disallowDepRule: Rule.RuleModule = { return; } const [, blockVersion, tips] = definition; - // 没有提供 version 参数,判定为不允许所有版本号 + // No version parameter is provided, and it is determined that all version numbers are not allowed if (typeof blockVersion !== 'string' || blockVersion.length <= 0) { context.report({ node, diff --git a/frontend/infra/eslint-plugin/src/rules/tsx-no-leaked-render/index.ts b/frontend/infra/eslint-plugin/src/rules/tsx-no-leaked-render/index.ts index 2598c9ba..ab5a7476 100644 --- a/frontend/infra/eslint-plugin/src/rules/tsx-no-leaked-render/index.ts +++ b/frontend/infra/eslint-plugin/src/rules/tsx-no-leaked-render/index.ts @@ -20,12 +20,12 @@ import reactPlugin from 'eslint-plugin-react'; const originRule = reactPlugin.rules['jsx-no-leaked-render']; -// 扩展react/jsx-no-leaked-render。增加判断 「&&」 表达式左边为 boolean 、 null 、 undefined TS类型,则不报错。 +// Expand the react/jsx-no-leaked-render. If the left side of the "& &" expression is boolean, null, undefined TS type, no error will be reported. export const tsxNoLeakedRender = ruleComposer.filterReports( originRule, problem => { const { parent } = problem.node; - // 如果表达式是用于jsx属性,则不需要修复。 如 + // If the expression is used for jsx properties, it does not need to be fixed. Such as < Comp prop = {{foo: 1} & & obj}/> if ( parent?.type === AST_NODE_TYPES.JSXExpressionContainer && parent?.parent?.type === AST_NODE_TYPES.JSXAttribute diff --git a/frontend/infra/eslint-plugin/src/zustand/rules/prefer-shallow/index.test.ts b/frontend/infra/eslint-plugin/src/zustand/rules/prefer-shallow/index.test.ts index 6b556570..24c317a5 100644 --- a/frontend/infra/eslint-plugin/src/zustand/rules/prefer-shallow/index.test.ts +++ b/frontend/infra/eslint-plugin/src/zustand/rules/prefer-shallow/index.test.ts @@ -25,7 +25,7 @@ ruleTester.run('prefer-shallow', preferShallow, { 'new Foo()', 'useShallowedFooStore()', 'useFooStore((s) => s.value)', - 'useFooStore(selector)', // 暂时豁免 + 'useFooStore(selector)', // Temporary exemption 'useShallowFooStore(() => ({}))', 'useFooStore(useShallow(() => ({})))', 'useFooStore(useShallow(() => ([])))', diff --git a/frontend/infra/idl/idl-parser/__tests__/demo.thrift.ts b/frontend/infra/idl/idl-parser/__tests__/demo.thrift.ts index 117741aa..8bd1582c 100644 --- a/frontend/infra/idl/idl-parser/__tests__/demo.thrift.ts +++ b/frontend/infra/idl/idl-parser/__tests__/demo.thrift.ts @@ -32,8 +32,8 @@ struct UserDeleteDataMap { We */ enum AvatarMetaType { - UNKNOWN = 0, // 没有数据, 错误数据或者系统错误降级 - RANDOM = 1, // 在修改 or 创建时,用户未指定 name 或者选中推荐的文字时,程序随机选择的头像 + UNKNOWN = 0, // No data, incorrect data, or system error downgrade + RANDOM = 1, // When modifying or creating, the user does not specify a name or select the recommended text, the program randomly selects the avatar } `; diff --git a/frontend/infra/idl/idl-parser/__tests__/demo.unify.ts b/frontend/infra/idl/idl-parser/__tests__/demo.unify.ts index 19565b21..8457b7e1 100644 --- a/frontend/infra/idl/idl-parser/__tests__/demo.unify.ts +++ b/frontend/infra/idl/idl-parser/__tests__/demo.unify.ts @@ -46,8 +46,8 @@ enum Gender { } // const map genderMap = { -// Gender.Male: '男性', -// Gender.Female: '女性', +// Gender. Male: 'Male', +// Gender. Female: 'Female', // } union FuncRequest { diff --git a/frontend/infra/idl/idl-parser/src/unify/proto.ts b/frontend/infra/idl/idl-parser/src/unify/proto.ts index 08e37998..4a5f0187 100644 --- a/frontend/infra/idl/idl-parser/src/unify/proto.ts +++ b/frontend/infra/idl/idl-parser/src/unify/proto.ts @@ -686,7 +686,7 @@ function convertFieldDefinition( if (!isProto3) { requiredness = optional ? 'optional' : 'required'; } else if (rule === 'required') { - // TODO: 处理 optional 的情况,需要修改 proto-parser + // TODO: Handle optional cases, need to modify proto-parser requiredness = 'required'; } diff --git a/frontend/infra/idl/idl2ts-cli/src/mock-dev.ts b/frontend/infra/idl/idl2ts-cli/src/mock-dev.ts index efc4e8e5..421cdf0e 100644 --- a/frontend/infra/idl/idl2ts-cli/src/mock-dev.ts +++ b/frontend/infra/idl/idl2ts-cli/src/mock-dev.ts @@ -25,7 +25,7 @@ function requiredWithoutCache(src, onError?) { // eslint-disable-next-line @typescript-eslint/no-require-imports const { Module } = require('module'); try { - // disable 了 require 的缓存,这样可以改变了 mock 数据后,无需重启服务。 + // Disable the required cache so that you can change the mock data without restarting the service. const originCache = Module._cache; Module._cache = {}; // eslint-disable-next-line security/detect-non-literal-require, @typescript-eslint/no-require-imports diff --git a/frontend/infra/idl/idl2ts-cli/src/plugins/filter-types-plugin.ts b/frontend/infra/idl/idl2ts-cli/src/plugins/filter-types-plugin.ts index e6081483..0fe19788 100644 --- a/frontend/infra/idl/idl2ts-cli/src/plugins/filter-types-plugin.ts +++ b/frontend/infra/idl/idl2ts-cli/src/plugins/filter-types-plugin.ts @@ -186,7 +186,7 @@ export class FilterTypesPlugin { } else if (isIdentifier(fieldType)) { const statement = getStatementById(fieldType, current); if (isEnumDefinition(statement)) { - // 强制转位 number + // Forced indexing number // @ts-expect-error fixme late fieldType.type = SyntaxType.I32Keyword; let namespace = current.unifyNamespace; diff --git a/frontend/infra/idl/idl2ts-cli/src/plugins/mock-plugin.ts b/frontend/infra/idl/idl2ts-cli/src/plugins/mock-plugin.ts index 53d6c901..0f2cbd97 100644 --- a/frontend/infra/idl/idl2ts-cli/src/plugins/mock-plugin.ts +++ b/frontend/infra/idl/idl2ts-cli/src/plugins/mock-plugin.ts @@ -55,15 +55,15 @@ export class MockPlugin implements IPlugin { if (context) { const { fieldDefinition } = context; const fieldName = fieldDefinition.name.value; - // 各类 ID + // various types of ID if (fieldName.toLocaleUpperCase().endsWith('ID')) { value = String(faker.number.int()); } - // email 处理 + // Email processing if (fieldName.includes('Email')) { value = `${faker.person.lastName()}@foo.com`; } - // 直接映射值 + // direct mapping value value = StrMapper[fieldName] || value; } ctx.output = t.stringLiteral(value); @@ -76,20 +76,20 @@ export class MockPlugin implements IPlugin { const { fieldDefinition } = context; const fieldName = fieldDefinition.name.value; const formatName = fieldName.toLocaleUpperCase(); - // 各类 ID + // various types of ID if (formatName.endsWith('ID')) { value = faker.number.int(); } - // 时间戳 + // timestamp if (formatName.endsWith('TIME') || formatName.includes('TIMESTAMP')) { value = dayjs(faker.date.anytime()).valueOf(); } - // 类型状态 + // type state if (formatName.endsWith('STATUS') || formatName.includes('TYPE')) { value = faker.number.int({ min: 0, max: 1 }); } - // 直接映射值 + // direct mapping value const mapVal = NumMapper[fieldName]; value = typeof mapVal !== 'undefined' ? mapVal : value; } diff --git a/frontend/infra/idl/idl2ts-cli/src/types.ts b/frontend/infra/idl/idl2ts-cli/src/types.ts index 4a05be7e..08a82849 100644 --- a/frontend/infra/idl/idl2ts-cli/src/types.ts +++ b/frontend/infra/idl/idl2ts-cli/src/types.ts @@ -17,27 +17,27 @@ import { type IPlugin } from '@coze-arch/idl2ts-generator'; export interface ApiConfig { - // idl 入口 + // IDL entrance entries: Record; - // idl 根目录 + // IDL root directory idlRoot: string; - // 服务别名 - // 自定义 api 方法 + // service alias + // Custom API method commonCodePath: string; - // api 产物目录 + // API Product Catalog output: string; - // 仓库信息设置 + // Warehouse information settings repository?: { - // 仓库地址 + // Warehouse address url: string; - // clone 到本地的位置 + // Clone to local location dest: string; }; - // 插件 + // plugin plugins?: IPlugin[]; - // 聚合导出的文件名 + // aggregate exported filename aggregationExport?: string; - // 格式化文件 + // Format file formatter: (name: string, content: string) => string; idlFetchConfig?: { source: string; @@ -48,6 +48,6 @@ export interface ApiConfig { } export interface ApiTypeConfig extends ApiConfig { - // 需要过滤的方法 + // Methods that require filtering filters: Record; } diff --git a/frontend/infra/idl/idl2ts-generator/src/core.ts b/frontend/infra/idl/idl2ts-generator/src/core.ts index 09de230d..188e80c2 100644 --- a/frontend/infra/idl/idl2ts-generator/src/core.ts +++ b/frontend/infra/idl/idl2ts-generator/src/core.ts @@ -163,7 +163,7 @@ export class ClientGenerator { private processIdlAst(ast: IParseResultItem) { try { - // 新的解析器貌似不是按原来位置排序的,这里要重新排序 + // The new parser doesn't seem to be sorted by the original position, so it needs to be reordered here. // eslint-disable-next-line @typescript-eslint/no-non-null-assertion ast.statements.sort((a, b) => a.loc!.start.line - b.loc!.start.line); } catch (error) { diff --git a/frontend/infra/idl/idl2ts-generator/src/plugin/adapter-plugin.ts b/frontend/infra/idl/idl2ts-generator/src/plugin/adapter-plugin.ts index 91c513be..2aeddf81 100644 --- a/frontend/infra/idl/idl2ts-generator/src/plugin/adapter-plugin.ts +++ b/frontend/infra/idl/idl2ts-generator/src/plugin/adapter-plugin.ts @@ -139,14 +139,14 @@ export class AdapterPlugin implements IPlugin { getAnnotation(f.annotations, 'api.converter') === 'atoi_comp_empty' ) { if (isInt(f.fieldType)) { - // 类型转换为 string + // Type conversion to string f.fieldType.type = SyntaxType.StringKeyword; } } - // api.converter 对 int 以及 map 类型生效 + // Api.converter works for int and map types if (getAnnotation(f.annotations, 'api.converter') === 'itoa') { if (isInt(f.fieldType)) { - // 类型转换为 string + // Type conversion to string f.fieldType.type = SyntaxType.StringKeyword; } if (isMapType(f.fieldType)) { @@ -156,7 +156,7 @@ export class AdapterPlugin implements IPlugin { } } } - // item_converter 对 list 类型生效 + // item_converter for list types if ( ['atoi_comp_empty', 'itoa'].includes( // eslint-disable-next-line @typescript-eslint/no-non-null-assertion @@ -168,24 +168,24 @@ export class AdapterPlugin implements IPlugin { } } - // 收集 decode encode 注解处理 + // Collection decoding encoding annotation processing if (getTypeFromDynamicJsonAnnotation(f.annotations)) { decodeEncodeFields.push(f.name.value); } - // api.json 注解处理 + // api.json annotation processing const jsonAnnotation = getAnnotation(f.annotations, 'api.json'); if (jsonAnnotation) { f.extensionConfig = f.extensionConfig || {}; f.extensionConfig.key = jsonAnnotation; } - // api.json_string 注解处理 + // API. json_string annotation handling const jsonStrAnnotation = getAnnotation( f.annotations, 'api.json_string', ); if (jsonStrAnnotation) { if (isInt(f.fieldType)) { - // 类型转换为 string + // Type conversion to string f.fieldType.type = SyntaxType.StringKeyword; f.extensionConfig = f.extensionConfig || {}; f.extensionConfig.key = jsonStrAnnotation; diff --git a/frontend/infra/idl/idl2ts-generator/src/plugin/client-plugin.ts b/frontend/infra/idl/idl2ts-generator/src/plugin/client-plugin.ts index 0d84f342..19352c4f 100644 --- a/frontend/infra/idl/idl2ts-generator/src/plugin/client-plugin.ts +++ b/frontend/infra/idl/idl2ts-generator/src/plugin/client-plugin.ts @@ -403,7 +403,7 @@ export class ClientPlugin implements IPlugin { }); const enumAst = t.tsEnumDeclaration(t.identifier(name.value), enumArr); - // 从后向前删除枚举项,避免索引变化影响 + // Delete enumeration items from back to front to avoid the impact of index changes enumItemIndexArray .sort((a, b) => b - a) .forEach(index => { diff --git a/frontend/infra/idl/idl2ts-generator/src/plugin/comment-format-plugin.ts b/frontend/infra/idl/idl2ts-generator/src/plugin/comment-format-plugin.ts index 47f403e2..487dc1f3 100644 --- a/frontend/infra/idl/idl2ts-generator/src/plugin/comment-format-plugin.ts +++ b/frontend/infra/idl/idl2ts-generator/src/plugin/comment-format-plugin.ts @@ -21,7 +21,7 @@ import { type Contexts, HOOK } from '../context'; const MAGIC_COMMENT_KEY = '\n*@magic-comment'; -// 忽略 struct 中的字段 +// Ignore fields in struct export class CommentFormatPlugin { apply(p: Program) { p.register(after('PARSE_ENTRY'), ctx => { diff --git a/frontend/infra/idl/idl2ts-generator/src/plugin/ignore-struct-field.ts b/frontend/infra/idl/idl2ts-generator/src/plugin/ignore-struct-field.ts index a92f0f80..83225775 100644 --- a/frontend/infra/idl/idl2ts-generator/src/plugin/ignore-struct-field.ts +++ b/frontend/infra/idl/idl2ts-generator/src/plugin/ignore-struct-field.ts @@ -26,7 +26,7 @@ interface IPops { filter: Filter; } -// 忽略 struct 中的字段 +// Ignore fields in struct export class IgnoreStructFiledPlugin { private filter: Filter; constructor({ filter }: IPops) { diff --git a/frontend/infra/idl/idl2ts-generator/src/plugin/meta-plugin.ts b/frontend/infra/idl/idl2ts-generator/src/plugin/meta-plugin.ts index 479e9f23..f84d1c08 100644 --- a/frontend/infra/idl/idl2ts-generator/src/plugin/meta-plugin.ts +++ b/frontend/infra/idl/idl2ts-generator/src/plugin/meta-plugin.ts @@ -56,7 +56,7 @@ export class MetaPlugin implements IPlugin { ctx => { const node = ctx.node as ServiceDefinition; node.functions.forEach(fun => { - // 过滤非泛化接口 + // Filtering non-generalized interfaces if (!fun.extensionConfig?.method) { return; } @@ -103,7 +103,7 @@ export class MetaPlugin implements IPlugin { schemaRoot: getSchemaRootByPath(ast.idlPath, this.options.idlRoot), service, } as IMeta; - // 不是 json 时,需要加上 serializer 标识 + // When not json, you need to add the serializer flag. if (extensionConfig?.serializer && extensionConfig?.serializer !== 'json') { res.serializer = extensionConfig?.serializer; } @@ -117,7 +117,7 @@ export class MetaPlugin implements IPlugin { if (isStructDefinition(statement)) { const wholeBody = statement.fields.find(isFullBody); if (wholeBody) { - // 处理 api.body="." 以及 api.full_body='' + // Handle api.body = "." and api.full_body = " return `${id.value}['${getFieldsAlias(wholeBody)}']`; } else { return id.value; @@ -184,7 +184,7 @@ export class MetaPlugin implements IPlugin { } }); } - // 如果没有指定,根据method默认指定为query 或者 body + // If not specified, it is specified as query or body by default according to method. if (!specificPositionFiled.has(alias)) { const filedMapping = mapping[defaultPosition]; mapping[defaultPosition] = filedMapping diff --git a/frontend/infra/idl/idl2ts-generator/src/plugin/mock-transformer.ts b/frontend/infra/idl/idl2ts-generator/src/plugin/mock-transformer.ts index 7d8f3c4e..8a9357be 100644 --- a/frontend/infra/idl/idl2ts-generator/src/plugin/mock-transformer.ts +++ b/frontend/infra/idl/idl2ts-generator/src/plugin/mock-transformer.ts @@ -110,7 +110,7 @@ export class MockTransformerPlugin implements IPlugin { nextOrder[name] = index; } }); - // 按照 mock 文件中的顺序优先排序 + // Prioritize in order in the mock file const getOrder = (name: string) => typeof mockVarOrder[name] !== 'undefined' ? mockVarOrder[name] @@ -210,7 +210,7 @@ export class MockTransformerPlugin implements IPlugin { if (isStructDefinition(statement)) { const wholeBody = statement.fields.find(isFullBody); if (wholeBody) { - // 处理 api.body="." + // Processing api.body = "." const { annotations } = wholeBody; if (hasDynamicJsonAnnotation(annotations)) { return '{}'; @@ -273,7 +273,7 @@ export class MockTransformerPlugin implements IPlugin { if (!fieldNames.has(fieldName)) { return; } - // 没有的,需要重新生成 + // No, it needs to be regenerated. newPros.push( t.objectProperty( fieldName.includes('-') @@ -351,11 +351,11 @@ export class MockTransformerPlugin implements IPlugin { const { valueType } = fieldType; output = t.arrayExpression([this.processValue(valueType)]); } else if (isSetType(fieldType)) { - // set 处理成array校验 + // Set to array validation const { valueType } = fieldType; output = t.arrayExpression([this.processValue(valueType)]); } else if (isIdentifier(fieldType)) { - // 引用类型 + // reference type const { refName, namespace } = parseIdFiledType(fieldType); if (!namespace) { output = t.callExpression(t.identifier(refName), []); @@ -375,7 +375,7 @@ export class MockTransformerPlugin implements IPlugin { throw new Error(`can not process fieldType : ${fieldType.type}`); } private processConst(constVal: ConstValue) { - // 暂时统一处理成0 + // Temporarily unified processing to 0 if (isStringLiteral(constVal)) { return t.stringLiteral(constVal.value); } @@ -410,11 +410,11 @@ export class MockTransformerPlugin implements IPlugin { const comment = { type: 'CommentLine', value: commentValues } as any; const target = this.findTarget(name.value, ctx); if (target) { - // 需要更新注释 + // Comments need to be updated // target.trailingComments = [comment]; return; } - // 枚举类型统一处理成常量 + // Enumeration types are uniformly processed into constants const builder = template(`var ${name.value}= () => %%value%% `); const node = builder({ value: t.numericLiteral(values[0] || 0), @@ -437,7 +437,7 @@ export class MockTransformerPlugin implements IPlugin { // const variableDeclaration = t.addComment( // , // 'leading', - // '暂时对const默认处理为0,如有需要请自行重新赋值' + // 'Temporarily, the default processing for const is 0, please reassign it yourself if necessary ' // ); return node; } diff --git a/frontend/infra/idl/idl2ts-generator/src/plugin/pkg-entry-plugin.ts b/frontend/infra/idl/idl2ts-generator/src/plugin/pkg-entry-plugin.ts index c227572e..f9b85254 100644 --- a/frontend/infra/idl/idl2ts-generator/src/plugin/pkg-entry-plugin.ts +++ b/frontend/infra/idl/idl2ts-generator/src/plugin/pkg-entry-plugin.ts @@ -29,7 +29,7 @@ import { type Options } from '../types'; import { type Contexts, HOOK } from '../context'; /** - * 提供统一 api 入口 + * Provide unified API entry */ export class PkgEntryPlugin implements IPlugin { private options: Options; @@ -52,7 +52,7 @@ export class PkgEntryPlugin implements IPlugin { ); this.funcs.set( relativePath, - // 只支持单 service + // Only single service supported meta[0].service, ); return ctx; diff --git a/frontend/infra/idl/idl2ts-generator/src/plugin/schema-plugin.ts b/frontend/infra/idl/idl2ts-generator/src/plugin/schema-plugin.ts index 0b02c7eb..b321a6c1 100644 --- a/frontend/infra/idl/idl2ts-generator/src/plugin/schema-plugin.ts +++ b/frontend/infra/idl/idl2ts-generator/src/plugin/schema-plugin.ts @@ -223,7 +223,7 @@ export class SchemaPlugin implements IPlugin { }; return schema; } else if (isSetType(fieldType)) { - // set 处理成array校验 + // Set to array validation const { valueType } = fieldType; const schema: ListType = { type: 'array', @@ -231,7 +231,7 @@ export class SchemaPlugin implements IPlugin { }; return schema; } else if (isIdentifier(fieldType)) { - // 引用类型 + // reference type const { refName, namespace } = parseIdFiledType(fieldType); if (!namespace) { const schema: RefType = { $ref: `#/definitions/${refName}` }; @@ -249,7 +249,7 @@ export class SchemaPlugin implements IPlugin { throw new Error(`can not process fieldType : ${fieldType.type}`); } private processConst(constVal: ConstValue) { - // 暂时统一处理成0 + // Temporarily unified processing to 0 const schema = {} as ConstType; if (isStringLiteral(constVal)) { schema.const = constVal.value; diff --git a/frontend/infra/idl/idl2ts-generator/src/types.ts b/frontend/infra/idl/idl2ts-generator/src/types.ts index 850657a7..48184b12 100644 --- a/frontend/infra/idl/idl2ts-generator/src/types.ts +++ b/frontend/infra/idl/idl2ts-generator/src/types.ts @@ -29,11 +29,11 @@ export interface Options { genMock: boolean; genClient: boolean; entryName?: string; - // createAPI 所在文件路径 + // createAPI file path commonCodePath?: string; - // decode encode 会丢失类型,这里提供一种方式,业务手动补充上对应的类型 + // Decoding encoding will lose the type, here provides a way to manually add the corresponding type patchTypesOutput?: string; - // patchTypesOutput 的别名,patch type 需要使用额外的 pkg 组织时需要提供 + // PatchTypesOutput alias, patch type needs to be provided when using additional pkg organization patchTypesAliasOutput?: string; } diff --git a/frontend/infra/idl/idl2ts-helper/src/ctx.ts b/frontend/infra/idl/idl2ts-helper/src/ctx.ts index 143e0ec5..469fa962 100644 --- a/frontend/infra/idl/idl2ts-helper/src/ctx.ts +++ b/frontend/infra/idl/idl2ts-helper/src/ctx.ts @@ -42,11 +42,11 @@ export interface IMeta { type Fields = string[]; export interface IHttpRpcMapping { - path?: Fields; // path参数 - query?: Fields; // query参数 - body?: Fields; // body 参数 - header?: Fields; // header 参数 - status_code?: Fields; // http状态码 + path?: Fields; // path parameter + query?: Fields; // query parameters + body?: Fields; // Body parameters + header?: Fields; // header parameter + status_code?: Fields; // HTTP status code cookie?: Fields; // cookie entire_body?: Fields; raw_body?: Fields; diff --git a/frontend/infra/idl/idl2ts-helper/src/helper.ts b/frontend/infra/idl/idl2ts-helper/src/helper.ts index b8e68cb4..3b730d5d 100644 --- a/frontend/infra/idl/idl2ts-helper/src/helper.ts +++ b/frontend/infra/idl/idl2ts-helper/src/helper.ts @@ -68,7 +68,7 @@ export function formatCode(code: string, root = '.') { printWidth: 120, singleQuote: true, }; - const file = path.resolve(process.cwd(), root, './for-prettier-bug'); // 这里一定要加多一级目录 + const file = path.resolve(process.cwd(), root, './for-prettier-bug'); // Be sure to add an extra level catalog here. const config = prettier.resolveConfig(file, { editorconfig: true }); return prettier.format(code, { ...(config || defaultConfig), @@ -166,7 +166,7 @@ export function parseId(id: string) { export function uniformNs(ns: string) { if (ReservedKeyWord.includes(ns)) { - // 命中保留字,处理为下划线开头 + // Hit the reserved word, treated as an underscore return `_${ns}`; } return ns.replace(/\./g, '_'); @@ -182,7 +182,7 @@ export function getValuesFromEnum(params: h.EnumDefinition) { if (h.isIntegerLiteral(initializer.value)) { currentVal = Number(initializer.value.value); } else if (h.isHexLiteral(initializer.value)) { - // 16进制 + // hexadecimal currentVal = Number(initializer.value.value); } enumArr.push(currentVal); @@ -322,8 +322,8 @@ export function hasDynamicJsonAnnotation(annotations?: h.Annotations) { } /** - * 从 api.(request|response).converter 中解析出前端与网关之间的真实类型, - * 能搞出这两个注解来,这个协议着实恶心😭 + * Parse the real type between the front end and the gateway from api. (request | response).converter. + * To be able to come up with these two annotations, this protocol is disgusting😭 * @param annotations * @returns */ diff --git a/frontend/infra/idl/idl2ts-plugin/src/program.ts b/frontend/infra/idl/idl2ts-plugin/src/program.ts index 70b2d6d1..ed77fa20 100644 --- a/frontend/infra/idl/idl2ts-plugin/src/program.ts +++ b/frontend/infra/idl/idl2ts-plugin/src/program.ts @@ -42,7 +42,7 @@ export class Program { } = {}; /** - * 加载插件 + * Load plugin * @param plugins */ loadPlugins(plugins: IPlugin[]) { @@ -51,10 +51,10 @@ export class Program { } } /** - * 注册钩子 - * @param event 事件名称 - * @param handler 钩子 - * @param priority 优先级,数值越小,优先级越高 + * registration hook + * @param event name + * @param handler hook + * @Param priority, the smaller the value, the higher the priority */ register< K extends keyof C, @@ -87,7 +87,7 @@ export class Program { } } /** - * 触发事件 + * trigger event * @param event * @param args * @returns diff --git a/frontend/infra/idl/idl2ts-runtime/src/create-api.ts b/frontend/infra/idl/idl2ts-runtime/src/create-api.ts index 72f21651..f69b8018 100644 --- a/frontend/infra/idl/idl2ts-runtime/src/create-api.ts +++ b/frontend/infra/idl/idl2ts-runtime/src/create-api.ts @@ -20,20 +20,20 @@ import type { IMeta, CustomAPIMeta } from './types'; export interface ApiLike { (req: T, option?: O extends object ? IOptions & O : IOptions): Promise; meta: IMeta; - /** fork 一份实例,该实例具有可中止请求的能力 */ + /** Fork an instance that has the ability to abort requests */ withAbort: () => CancelAbleApi; } export interface CancelAbleApi extends ApiLike { - // 中止请求 + // abort request abort: () => void; - // 是否是取消 + // Is it cancelled? isAborted: () => boolean; } /** - * 自定义构建 api 方法 + * Custom build API method * @param meta * @param cancelable * @param useCustom @@ -56,7 +56,7 @@ export function createAPI meta.reqMapping[key]) @@ -98,12 +98,12 @@ export function createAPI; } export interface IdlConfig { - // client 工厂方法,要求返回一个 fetchClient 函数,使用 meta 总的信息,可实现灵活的 client 配置 + // The client factory method requires a fetchClient function to be returned, which uses the meta total information to achieve flexible client configuration clientFactory?: ( meta: IMeta, ) => (uri: string, init: RequestInit, opt: any) => any; - // uri 前缀,如果 client 中设置了,这里可以不设置 + // URI prefix, if set in client, you can leave it unset here uriPrefix?: string; getParams?: (key: string) => string; - // 服务级别的配置 + // Service level configuration services?: ServiceConfig; - // 开发时,如果本地校验失败,这里可回调,通常是弹 toast + // During development, if the local verification fails, it can be called back here, usually by playing toast. onVerifyReqError?: (message: string, ctx: any) => void; } export interface IOptions { config?: IdlConfig; - // 透传 request options 的选项 + // Passthrough request options requestOptions?: Record; [key: string]: any; } @@ -52,7 +52,7 @@ export interface PathPrams { } export function getConfig(service: string, method: string): IdlConfig { - // 手动注册的配置优先级比全局变量高 + // Manually registered configuration takes precedence over global variables let config: IdlConfig | undefined = configCenter.getConfig(service); if (!config) { config = {}; @@ -137,7 +137,7 @@ export function normalizeRequest( ); const { uriPrefix = '', clientFactory } = config; if (!clientFactory) { - // todo 这里考虑给个默认的 client,防止某些公共 package 在一些异常情况下使用 + // Todo here considers giving a default client to prevent some public packages from being used in some abnormal cases throw new Error('Lack of clientFactory config'); } let uri = uriPrefix + apiUri; @@ -149,11 +149,11 @@ export function normalizeRequest( : 'application/json'; if (option?.requestOptions?.headers) { headers = { ...headers, ...option.requestOptions.headers }; - // 合并了 header,可删除 + // Merged headers, can be deleted delete option.requestOptions.headers; } if (meta.reqMapping.query && meta.reqMapping.query.length > 0) { - // 这里默认 skipNulls,网关后端需要忽略 null + // The default here is skipNulls, and the gateway backend needs to ignore null. uri = `${uri}?${qs.stringify(getValue(req, meta.reqMapping.query), { skipNulls: true, arrayFormat: 'comma', @@ -168,7 +168,7 @@ export function normalizeRequest( if (meta.reqMapping.entire_body && meta.reqMapping.entire_body.length > 0) { if (meta.reqMapping.entire_body.length === 1) { - // 默认处理为 json ,如有其他场景需要支持,后需要再支持 + // The default processing is json. If there are other scenarios that need to be supported, they need to be supported later. requestOption.body = req[meta.reqMapping.entire_body[0]]; } else { throw new Error('idl invalid entire_body should be only one filed'); @@ -203,7 +203,7 @@ export function normalizeRequest( }; } - // 旧版的 ferry 中,即使 idl 没有声明body,也需要加一个 空的 body + // In the old version of ferry, even if idl does not declare body, you need to add an empty body. if ( !requestOption.body && ['POST', 'PUT', 'PATCH'].includes( diff --git a/frontend/infra/plugins/pkg-root-webpack-plugin/__tests__/index.test.ts b/frontend/infra/plugins/pkg-root-webpack-plugin/__tests__/index.test.ts index 25fbfd1a..97117c02 100644 --- a/frontend/infra/plugins/pkg-root-webpack-plugin/__tests__/index.test.ts +++ b/frontend/infra/plugins/pkg-root-webpack-plugin/__tests__/index.test.ts @@ -89,17 +89,17 @@ describe('PkgRootWebpackPlugin', () => { new PkgRootWebpackPlugin(customOptions); - // 注意:Object.assign 中后面的对象会覆盖前面的对象,所以默认配置会覆盖用户配置 + // Note: Subsequent objects in Object.assign overwrite the preceding objects, so the default configuration overrides the user configuration expect(OriginPkgRootWebpackPlugin).toHaveBeenCalledWith({ customProp: 'customValue', - root: '@', // 被默认值覆盖 + root: '@', // Overwritten by default packagesDirs: [ 'packages/project1', 'packages/project2', 'apps/app1', 'apps/app2', ], - excludeFolders: [], // 被默认值覆盖 + excludeFolders: [], // Overwritten by default }); }); @@ -110,9 +110,9 @@ describe('PkgRootWebpackPlugin', () => { new PkgRootWebpackPlugin(customOptions); - // Object.assign 的行为:后面的对象会覆盖前面的对象属性 + // Object.assign behavior: subsequent objects overwrite previous object properties expect(OriginPkgRootWebpackPlugin).toHaveBeenCalledWith({ - root: '@', // 被默认值覆盖 + root: '@', // Overwritten by default packagesDirs: [ 'packages/project1', 'packages/project2', @@ -139,7 +139,7 @@ describe('PkgRootWebpackPlugin', () => { }); it('验证所有导出都正确', () => { - // 验证模块导出了正确的类和默认导出 + // Verify that the module exported the correct class and the default export expect(PkgRootWebpackPlugin).toBeDefined(); expect(typeof PkgRootWebpackPlugin).toBe('function'); }); @@ -147,7 +147,7 @@ describe('PkgRootWebpackPlugin', () => { it('应该正确处理 Rush 配置中的项目文件夹', () => { new PkgRootWebpackPlugin(); - // 验证传递给父类的 packagesDirs 包含所有项目文件夹 + // Verify that the packagesDirs passed to the parent class contain all project folders const call = (OriginPkgRootWebpackPlugin as any).mock.calls[0]; const options = call[0]; @@ -160,10 +160,10 @@ describe('PkgRootWebpackPlugin', () => { }); it('测试插件基本功能正常工作', () => { - // 这个测试验证插件能正常实例化并调用父类构造函数 + // This test verifies that the plugin can instantiate and call the parent class constructor normally new PkgRootWebpackPlugin(); - // 验证确实调用了父类构造函数 + // Verify that the parent class constructor is indeed called expect(OriginPkgRootWebpackPlugin).toHaveBeenCalled(); }); }); diff --git a/frontend/infra/plugins/pkg-root-webpack-plugin/lib/index.js b/frontend/infra/plugins/pkg-root-webpack-plugin/lib/index.js index c5e282ce..7953619e 100644 --- a/frontend/infra/plugins/pkg-root-webpack-plugin/lib/index.js +++ b/frontend/infra/plugins/pkg-root-webpack-plugin/lib/index.js @@ -38,7 +38,7 @@ class PkgRootWebpackPlugin extends pkg_root_webpack_plugin_origin_1.default { const mergedOptions = Object.assign({}, options || {}, { root: '@', packagesDirs: rushJsonPackagesDir, - // 排除apps/*,减少处理时间 + // Exclude apps/* to reduce processing time excludeFolders: [], }); super(mergedOptions); diff --git a/frontend/infra/plugins/pkg-root-webpack-plugin/src/index.ts b/frontend/infra/plugins/pkg-root-webpack-plugin/src/index.ts index 8e8ea94b..8497d3e2 100644 --- a/frontend/infra/plugins/pkg-root-webpack-plugin/src/index.ts +++ b/frontend/infra/plugins/pkg-root-webpack-plugin/src/index.ts @@ -41,7 +41,7 @@ class PkgRootWebpackPlugin extends OriginPkgRootWebpackPlugin { const mergedOptions = Object.assign({}, options || {}, { root: '@', packagesDirs: rushJsonPackagesDir, - // 排除apps/*,减少处理时间 + // Exclude apps/* to reduce processing time excludeFolders: [], }); super(mergedOptions); diff --git a/frontend/infra/utils/monorepo-kits/docs/llms.txt b/frontend/infra/utils/monorepo-kits/docs/llms.txt index 03dd944e..6842672c 100644 --- a/frontend/infra/utils/monorepo-kits/docs/llms.txt +++ b/frontend/infra/utils/monorepo-kits/docs/llms.txt @@ -1,79 +1,79 @@ # @coze-arch/monorepo-kits -## 功能概述 +/* Function Overview */ -`@coze-arch/monorepo-kits` 是一个用于管理 monorepo 项目的工具包,提供了基于 Rush 框架的项目查找、依赖分析和配置管理功能。 +/* "@Coze-arch/monorepo-kits" is a toolkit for managing monorepo projects, providing project lookup, dependency analysis, and configuration management capabilities based on the Rush framework. */ -## 主要功能模块 +/* Main Functional Modules */ -### 1. 子包管理 (sub-packages.ts) +/* ###1. Subpackage management (sub-packages.ts) */ #### lookupSubPackages(packageName: string): string[] -- **功能**: 递归查找指定包的所有子依赖包 -- **特性**: 使用缓存机制避免重复计算 -- **返回**: 所有依赖包的名称数组(去重后) +/* - ** Function **: Recursively find all child dependencies of the specified package */ +/* - ** Features **: Use caching mechanism to avoid double counting */ +/* - ** Returns **: Array of names of all dependent packages (after deduplicate) */ #### getPackageLocation(packageName: string): string -- **功能**: 获取指定包的文件系统路径 -- **返回**: 包的项目文件夹路径 +/* - ** Function **: Get the file system path of the specified package */ +/* - ** return **: the project folder path of the package */ #### getPackageJson(packageName: string): RushConfigurationProject['packageJson'] -- **功能**: 获取指定包的 package.json 配置信息 -- **返回**: 包的 package.json 对象 +/* - ** Function **: Get the package.json configuration information of the specified package */ +/* - ** returns **: package's package.json object */ -### 2. Rush 配置管理 (rush-config.ts) +/* ###2. Rush configuration management (rush-config.ts) */ #### getRushConfiguration(): RushConfiguration -- **功能**: 获取 Rush 配置实例 -- **特性**: 单例模式,首次调用时从默认位置加载配置,后续调用复用实例 -- **返回**: RushConfiguration 对象 +/* - ** Features **: Get Rush Configuration Instance */ +/* - ** Features **: Singleton mode, first call loads configuration from default location, subsequent calls reuse instance */ +/* - ** returns **: RushConfiguration object */ -### 3. 项目查找 (lookup.ts) +/* ###3. Project lookup (lookup.ts) */ #### lookupTo(to: string): string[] -- **功能**: 查找指定包的直接依赖项 -- **参数**: 目标包名称 -- **返回**: 依赖包名称数组 +/* - ** Features **: Find direct dependencies of a specified package */ +/* - ** Parameter **: Target package name */ +/* - ** Returns **: Array of dependency package names */ #### lookupFrom(from: string): void -- **功能**: 查找从指定包出发的相关信息(当前实现不完整) -- **参数**: 源包名称 +/* - ** Features **: Find information about outgoing from a specified package (current implementation is incomplete) */ +/* - ** parameter **: source package name */ #### lookupOnly(packageName: string): RushConfigurationProject -- **功能**: 查找并返回指定包的项目配置对象 -- **参数**: 包名称 -- **返回**: 完整的项目配置对象 +/* - ** Features **: Find and return the project configuration object of the specified package */ +/* - ** parameter **: package name */ +/* - ** Return **: complete project configuration object */ -## 依赖关系 +/* ##dependencies */ -- **主要依赖**: `@rushstack/rush-sdk@5.100.2` -- **开发依赖**: 包含 ESLint、TypeScript、Vitest 等工具链 +/* - ** Major dependencies **: '@rushstack/rush-sdk@5.100.2' */ +/* - ** Development dependencies **: Includes ESLint, TypeScript, Vitest and other toolchains */ -## 使用场景 +/* ##usage scenario */ -1. **依赖分析**: 分析 monorepo 中包之间的依赖关系 -2. **路径解析**: 获取包在文件系统中的实际位置 -3. **配置查询**: 查询包的配置信息和元数据 -4. **自动化工具**: 为构建脚本、部署工具等提供 monorepo 项目信息 +/* 1. ** Dependency Analysis **: Analyze the dependencies between packages in Monorepo */ +/* 2. ** Path parsing **: Get the actual location of the package in the file system */ +/* 3. ** Configuration query **: Query the configuration information and metadata of the package */ +/* 4. ** Automation Tools **: Provide monorepo project information for build scripts, deployment tools, etc */ -## 架构特点 +/* ##Architecture Features */ -- **缓存优化**: 对递归依赖查找进行缓存,提高性能 -- **错误处理**: 包含完善的包不存在异常处理 -- **单例模式**: Rush 配置采用单例模式,避免重复加载 -- **类型安全**: 基于 TypeScript,提供完整的类型定义 +/* - ** Cache optimization **: Cache recursive dependency lookups to improve performance */ +/* - ** Error Handling **: Includes perfect package without exception handling */ +/* - ** Singleton mode **: Rush configuration adopts singleton mode to avoid repeated loading */ +/* Type safety: Based on TypeScript, complete type definition is provided */ -## 代码结构 +/* ##Code structure */ ``` src/ -├── index.ts # 主入口文件,导出所有公共 API -├── sub-packages.ts # 子包管理和依赖查找功能 -├── rush-config.ts # Rush 配置管理 -└── lookup.ts # 项目查找相关功能 +/* < unk > ─ index.ts #Main entry file, export all public APIs */ +/* < unk > ─ Sub-packages.ts #Subpackage management and dependency lookup function */ +/* 🥰 ─ rush-config.ts #Rush configuration management */ +/* 🥰 ─ ─ lookup.ts #Project lookup related functions */ ``` -## API 导出 +/* ##API export */ ```typescript export { @@ -87,4 +87,4 @@ export { getRushConfiguration } from './rush-config'; export { lookupTo, lookupFrom, lookupOnly } from './lookup'; ``` -这个工具包为 monorepo 环境下的包管理、依赖分析和自动化工具开发提供了基础支持。 +/* This toolkit provides fundamental support for package management, dependency analysis, and automated tool development in Monorepo environments. */ diff --git a/frontend/infra/utils/rush-logger/src/index.ts b/frontend/infra/utils/rush-logger/src/index.ts index 15ab9521..e657ec62 100644 --- a/frontend/infra/utils/rush-logger/src/index.ts +++ b/frontend/infra/utils/rush-logger/src/index.ts @@ -80,5 +80,5 @@ const logger = new Logger(); export { logger }; -/** @deprecated 该使用方式已废弃,请使用`import { logger } from '@coze-arch/rush-logger' */ +/** @Deprecated This usage is deprecated, please use'import {logger} from '@code-arch/rush-logger' */ export default logger; diff --git a/frontend/packages/agent-ide/agent-publish/src/components/bot-publish/hooks/use-auth-fail.ts b/frontend/packages/agent-ide/agent-publish/src/components/bot-publish/hooks/use-auth-fail.ts index f73dc861..d5a37574 100644 --- a/frontend/packages/agent-ide/agent-publish/src/components/bot-publish/hooks/use-auth-fail.ts +++ b/frontend/packages/agent-ide/agent-publish/src/components/bot-publish/hooks/use-auth-fail.ts @@ -22,7 +22,7 @@ import { I18n } from '@coze-arch/i18n'; import { UIModal } from '@coze-arch/bot-semi'; import { useResetLocationState } from '@coze-arch/bot-hooks'; -// 三方授权失败,callback至发布页需要显式阻塞弹窗 +// Tripartite authorization failed, callback to the release page needs to explicitly block the pop-up window export const useAuthFail = () => { const { state } = useLocation(); const { authFailMessage = '', authStatus } = (state ?? diff --git a/frontend/packages/agent-ide/agent-publish/src/components/bot-publish/hooks/use-get-bot-info.ts b/frontend/packages/agent-ide/agent-publish/src/components/bot-publish/hooks/use-get-bot-info.ts index eebd3584..285f9bef 100644 --- a/frontend/packages/agent-ide/agent-publish/src/components/bot-publish/hooks/use-get-bot-info.ts +++ b/frontend/packages/agent-ide/agent-publish/src/components/bot-publish/hooks/use-get-bot-info.ts @@ -41,7 +41,7 @@ const DEFAULT_BOT_INFO: PublisherBotInfo = { prompt: '', }; -// 获取plugin收费插件信息 +// Get plugin charging plugin information const getPricingRules: ( pluginApiDetailMap?: Record, ) => Promise = async pluginApiDetailMap => { @@ -58,7 +58,7 @@ const getPricingRules: ( return pricing_rules; }; -// 是否有plugin +// Is there a plugin? const hasPluginApi: ( pluginApiDetailMap?: Record, ) => boolean = pluginApiDetailMap => @@ -113,7 +113,7 @@ export const useGetPublisherInitInfo: () => { bot_option_data, } = botInfoResp?.data ?? {}; - // 获取plugin扣费信息 + // Get plugin deduction information let pluginPricingRules: Array = []; if ( hasPluginApi(bot_option_data?.plugin_api_detail_map) && diff --git a/frontend/packages/agent-ide/agent-publish/src/components/bot-publish/index.tsx b/frontend/packages/agent-ide/agent-publish/src/components/bot-publish/index.tsx index 5fcec6b9..55139b6b 100644 --- a/frontend/packages/agent-ide/agent-publish/src/components/bot-publish/index.tsx +++ b/frontend/packages/agent-ide/agent-publish/src/components/bot-publish/index.tsx @@ -126,7 +126,7 @@ export const AgentPublishPage = () => { const publishBtn = (